package com.revenuecat.purchases.paywalls.components;

import Q4.c;
import androidx.compose.runtime.Immutable;
import com.revenuecat.purchases.InternalRevenueCatAPI;
import com.revenuecat.purchases.paywalls.components.StackComponent;
import com.revenuecat.purchases.paywalls.components.common.Background;
import com.revenuecat.purchases.paywalls.components.common.BackgroundDeserializer;
import com.revenuecat.purchases.paywalls.components.properties.Badge;
import com.revenuecat.purchases.paywalls.components.properties.Badge$$serializer;
import com.revenuecat.purchases.paywalls.components.properties.Border;
import com.revenuecat.purchases.paywalls.components.properties.Border$$serializer;
import com.revenuecat.purchases.paywalls.components.properties.ColorScheme;
import com.revenuecat.purchases.paywalls.components.properties.ColorScheme$$serializer;
import com.revenuecat.purchases.paywalls.components.properties.Dimension;
import com.revenuecat.purchases.paywalls.components.properties.Dimension$Horizontal$$serializer;
import com.revenuecat.purchases.paywalls.components.properties.Dimension$Vertical$$serializer;
import com.revenuecat.purchases.paywalls.components.properties.Dimension$ZLayer$$serializer;
import com.revenuecat.purchases.paywalls.components.properties.Padding;
import com.revenuecat.purchases.paywalls.components.properties.Padding$$serializer;
import com.revenuecat.purchases.paywalls.components.properties.Shadow;
import com.revenuecat.purchases.paywalls.components.properties.Shadow$$serializer;
import com.revenuecat.purchases.paywalls.components.properties.Shape;
import com.revenuecat.purchases.paywalls.components.properties.ShapeDeserializer;
import com.revenuecat.purchases.paywalls.components.properties.Size;
import com.revenuecat.purchases.paywalls.components.properties.Size$$serializer;
import g5.a;
import g5.e;
import i5.g;
import j5.b;
import java.lang.annotation.Annotation;
import k5.C2419g;
import k5.C2437z;
import k5.a0;
import kotlin.jvm.internal.D;
import kotlin.jvm.internal.h;
import kotlin.jvm.internal.o;
import w4.InterfaceC3141c;

/* JADX INFO: loaded from: classes3.dex */
@Immutable
@InternalRevenueCatAPI
public final class PartialStackComponent implements PartialComponent {
    private final Background background;
    private final ColorScheme backgroundColor;
    private final Badge badge;
    private final Border border;
    private final Dimension dimension;
    private final Padding margin;
    private final StackComponent.Overflow overflow;
    private final Padding padding;
    private final Shadow shadow;
    private final Shape shape;
    private final Size size;
    private final Float spacing;
    private final Boolean visible;
    public static final Companion Companion = new Companion(null);
    private static final a[] $childSerializers = {null, new e("com.revenuecat.purchases.paywalls.components.properties.Dimension", D.a(Dimension.class), new c[]{D.a(Dimension.Horizontal.class), D.a(Dimension.Vertical.class), D.a(Dimension.ZLayer.class)}, new a[]{Dimension$Horizontal$$serializer.INSTANCE, Dimension$Vertical$$serializer.INSTANCE, Dimension$ZLayer$$serializer.INSTANCE}, new Annotation[0]), null, null, null, null, null, null, null, null, null, null, null};

    public static final class Companion {
        public /* synthetic */ Companion(h hVar) {
            this();
        }

        public final a serializer() {
            return PartialStackComponent$$serializer.INSTANCE;
        }

        private Companion() {
        }
    }

    public PartialStackComponent() {
        this((Boolean) null, (Dimension) null, (Size) null, (Float) null, (ColorScheme) null, (Background) null, (Padding) null, (Padding) null, (Shape) null, (Border) null, (Shadow) null, (Badge) null, (StackComponent.Overflow) null, 8191, (h) null);
    }

    public static /* synthetic */ void getBackgroundColor$annotations() {
    }

    public static final /* synthetic */ void write$Self$purchases_defaultsBc8Release(PartialStackComponent partialStackComponent, b bVar, g gVar) {
        a[] aVarArr = $childSerializers;
        if (bVar.g(gVar) || !o.c(partialStackComponent.visible, Boolean.TRUE)) {
            bVar.E(gVar, 0, C2419g.f20053a, partialStackComponent.visible);
        }
        if (bVar.g(gVar) || partialStackComponent.dimension != null) {
            bVar.E(gVar, 1, aVarArr[1], partialStackComponent.dimension);
        }
        if (bVar.g(gVar) || partialStackComponent.size != null) {
            bVar.E(gVar, 2, Size$$serializer.INSTANCE, partialStackComponent.size);
        }
        if (bVar.g(gVar) || partialStackComponent.spacing != null) {
            bVar.E(gVar, 3, C2437z.f20111a, partialStackComponent.spacing);
        }
        if (bVar.g(gVar) || partialStackComponent.backgroundColor != null) {
            bVar.E(gVar, 4, ColorScheme$$serializer.INSTANCE, partialStackComponent.backgroundColor);
        }
        if (bVar.g(gVar) || partialStackComponent.background != null) {
            bVar.E(gVar, 5, BackgroundDeserializer.INSTANCE, partialStackComponent.background);
        }
        if (bVar.g(gVar) || partialStackComponent.padding != null) {
            bVar.E(gVar, 6, Padding$$serializer.INSTANCE, partialStackComponent.padding);
        }
        if (bVar.g(gVar) || partialStackComponent.margin != null) {
            bVar.E(gVar, 7, Padding$$serializer.INSTANCE, partialStackComponent.margin);
        }
        if (bVar.g(gVar) || partialStackComponent.shape != null) {
            bVar.E(gVar, 8, ShapeDeserializer.INSTANCE, partialStackComponent.shape);
        }
        if (bVar.g(gVar) || partialStackComponent.border != null) {
            bVar.E(gVar, 9, Border$$serializer.INSTANCE, partialStackComponent.border);
        }
        if (bVar.g(gVar) || partialStackComponent.shadow != null) {
            bVar.E(gVar, 10, Shadow$$serializer.INSTANCE, partialStackComponent.shadow);
        }
        if (bVar.g(gVar) || partialStackComponent.badge != null) {
            bVar.E(gVar, 11, Badge$$serializer.INSTANCE, partialStackComponent.badge);
        }
        if (!bVar.g(gVar) && partialStackComponent.overflow == null) {
            return;
        }
        bVar.E(gVar, 12, StackOverflowDeserializer.INSTANCE, partialStackComponent.overflow);
    }

    public boolean equals(Object obj) {
        if (this == obj) {
            return true;
        }
        if (!(obj instanceof PartialStackComponent)) {
            return false;
        }
        PartialStackComponent partialStackComponent = (PartialStackComponent) obj;
        return o.c(this.visible, partialStackComponent.visible) && o.c(this.dimension, partialStackComponent.dimension) && o.c(this.size, partialStackComponent.size) && o.c(this.spacing, partialStackComponent.spacing) && o.c(this.backgroundColor, partialStackComponent.backgroundColor) && o.c(this.background, partialStackComponent.background) && o.c(this.padding, partialStackComponent.padding) && o.c(this.margin, partialStackComponent.margin) && o.c(this.shape, partialStackComponent.shape) && o.c(this.border, partialStackComponent.border) && o.c(this.shadow, partialStackComponent.shadow) && o.c(this.badge, partialStackComponent.badge) && this.overflow == partialStackComponent.overflow;
    }

    public final /* synthetic */ Background getBackground() {
        return this.background;
    }

    public final /* synthetic */ ColorScheme getBackgroundColor() {
        return this.backgroundColor;
    }

    public final /* synthetic */ Badge getBadge() {
        return this.badge;
    }

    public final /* synthetic */ Border getBorder() {
        return this.border;
    }

    public final /* synthetic */ Dimension getDimension() {
        return this.dimension;
    }

    public final /* synthetic */ Padding getMargin() {
        return this.margin;
    }

    public final /* synthetic */ StackComponent.Overflow getOverflow() {
        return this.overflow;
    }

    public final /* synthetic */ Padding getPadding() {
        return this.padding;
    }

    public final /* synthetic */ Shadow getShadow() {
        return this.shadow;
    }

    public final /* synthetic */ Shape getShape() {
        return this.shape;
    }

    public final /* synthetic */ Size getSize() {
        return this.size;
    }

    public final /* synthetic */ Float getSpacing() {
        return this.spacing;
    }

    public final /* synthetic */ Boolean getVisible() {
        return this.visible;
    }

    public int hashCode() {
        Boolean bool = this.visible;
        int iHashCode = (bool == null ? 0 : bool.hashCode()) * 31;
        Dimension dimension = this.dimension;
        int iHashCode2 = (iHashCode + (dimension == null ? 0 : dimension.hashCode())) * 31;
        Size size = this.size;
        int iHashCode3 = (iHashCode2 + (size == null ? 0 : size.hashCode())) * 31;
        Float f6 = this.spacing;
        int iHashCode4 = (iHashCode3 + (f6 == null ? 0 : f6.hashCode())) * 31;
        ColorScheme colorScheme = this.backgroundColor;
        int iHashCode5 = (iHashCode4 + (colorScheme == null ? 0 : colorScheme.hashCode())) * 31;
        Background background = this.background;
        int iHashCode6 = (iHashCode5 + (background == null ? 0 : background.hashCode())) * 31;
        Padding padding = this.padding;
        int iHashCode7 = (iHashCode6 + (padding == null ? 0 : padding.hashCode())) * 31;
        Padding padding2 = this.margin;
        int iHashCode8 = (iHashCode7 + (padding2 == null ? 0 : padding2.hashCode())) * 31;
        Shape shape = this.shape;
        int iHashCode9 = (iHashCode8 + (shape == null ? 0 : shape.hashCode())) * 31;
        Border border = this.border;
        int iHashCode10 = (iHashCode9 + (border == null ? 0 : border.hashCode())) * 31;
        Shadow shadow = this.shadow;
        int iHashCode11 = (iHashCode10 + (shadow == null ? 0 : shadow.hashCode())) * 31;
        Badge badge = this.badge;
        int iHashCode12 = (iHashCode11 + (badge == null ? 0 : badge.hashCode())) * 31;
        StackComponent.Overflow overflow = this.overflow;
        return iHashCode12 + (overflow != null ? overflow.hashCode() : 0);
    }

    public String toString() {
        return "PartialStackComponent(visible=" + this.visible + ", dimension=" + this.dimension + ", size=" + this.size + ", spacing=" + this.spacing + ", backgroundColor=" + this.backgroundColor + ", background=" + this.background + ", padding=" + this.padding + ", margin=" + this.margin + ", shape=" + this.shape + ", border=" + this.border + ", shadow=" + this.shadow + ", badge=" + this.badge + ", overflow=" + this.overflow + ')';
    }

    @InterfaceC3141c
    public /* synthetic */ PartialStackComponent(int i6, Boolean bool, Dimension dimension, Size size, Float f6, ColorScheme colorScheme, Background background, Padding padding, Padding padding2, Shape shape, Border border, Shadow shadow, Badge badge, StackComponent.Overflow overflow, a0 a0Var) {
        this.visible = (i6 & 1) == 0 ? Boolean.TRUE : bool;
        if ((i6 & 2) == 0) {
            this.dimension = null;
        } else {
            this.dimension = dimension;
        }
        if ((i6 & 4) == 0) {
            this.size = null;
        } else {
            this.size = size;
        }
        if ((i6 & 8) == 0) {
            this.spacing = null;
        } else {
            this.spacing = f6;
        }
        if ((i6 & 16) == 0) {
            this.backgroundColor = null;
        } else {
            this.backgroundColor = colorScheme;
        }
        if ((i6 & 32) == 0) {
            this.background = null;
        } else {
            this.background = background;
        }
        if ((i6 & 64) == 0) {
            this.padding = null;
        } else {
            this.padding = padding;
        }
        if ((i6 & 128) == 0) {
            this.margin = null;
        } else {
            this.margin = padding2;
        }
        if ((i6 & 256) == 0) {
            this.shape = null;
        } else {
            this.shape = shape;
        }
        if ((i6 & 512) == 0) {
            this.border = null;
        } else {
            this.border = border;
        }
        if ((i6 & 1024) == 0) {
            this.shadow = null;
        } else {
            this.shadow = shadow;
        }
        if ((i6 & 2048) == 0) {
            this.badge = null;
        } else {
            this.badge = badge;
        }
        if ((i6 & 4096) == 0) {
            this.overflow = null;
        } else {
            this.overflow = overflow;
        }
    }

    public PartialStackComponent(Boolean bool, Dimension dimension, Size size, Float f6, ColorScheme colorScheme, Background background, Padding padding, Padding padding2, Shape shape, Border border, Shadow shadow, Badge badge, StackComponent.Overflow overflow) {
        this.visible = bool;
        this.dimension = dimension;
        this.size = size;
        this.spacing = f6;
        this.backgroundColor = colorScheme;
        this.background = background;
        this.padding = padding;
        this.margin = padding2;
        this.shape = shape;
        this.border = border;
        this.shadow = shadow;
        this.badge = badge;
        this.overflow = overflow;
    }

    public /* synthetic */ PartialStackComponent(Boolean bool, Dimension dimension, Size size, Float f6, ColorScheme colorScheme, Background background, Padding padding, Padding padding2, Shape shape, Border border, Shadow shadow, Badge badge, StackComponent.Overflow overflow, int i6, h hVar) {
        this((i6 & 1) != 0 ? Boolean.TRUE : bool, (i6 & 2) != 0 ? null : dimension, (i6 & 4) != 0 ? null : size, (i6 & 8) != 0 ? null : f6, (i6 & 16) != 0 ? null : colorScheme, (i6 & 32) != 0 ? null : background, (i6 & 64) != 0 ? null : padding, (i6 & 128) != 0 ? null : padding2, (i6 & 256) != 0 ? null : shape, (i6 & 512) != 0 ? null : border, (i6 & 1024) != 0 ? null : shadow, (i6 & 2048) != 0 ? null : badge, (i6 & 4096) != 0 ? null : overflow);
    }
}
