package com.revenuecat.purchases.ui.revenuecatui.data.processed;

import android.net.Uri;
import androidx.compose.runtime.Composable;
import androidx.compose.runtime.Composer;
import androidx.compose.runtime.ComposerKt;
import androidx.compose.runtime.Immutable;
import androidx.compose.runtime.ReadOnlyComposable;
import androidx.compose.runtime.Stable;
import com.google.android.recaptcha.internal.a;
import com.revenuecat.purchases.Package;
import com.revenuecat.purchases.paywalls.PaywallData;
import com.revenuecat.purchases.ui.revenuecatui.PaywallMode;
import java.util.ArrayList;
import java.util.Iterator;
import java.util.List;
import java.util.Locale;
import java.util.Map;
import kotlin.jvm.internal.h;
import kotlin.jvm.internal.o;
import n2.AbstractC2612c;
import p0.C2714u;
import q.AbstractC2761L;
import v.AbstractC3058z;
import x4.AbstractC3253s;

/* JADX INFO: loaded from: classes3.dex */
@Immutable
public final class TemplateConfiguration {
    public static final int $stable = 0;
    private final PaywallData.Configuration.ColorInformation colors;
    private final PaywallData.Configuration configuration;
    private final Colors darkModeColors;
    private final Images images;
    private final Map<String, Images> imagesByTier;
    private final Colors lightModeColors;
    private final Locale locale;
    private final PaywallMode mode;
    private final PackageConfiguration packages;
    private final PaywallTemplate template;

    @Immutable
    public static final class Colors {
        public static final int $stable = 0;
        private final long accent1;
        private final long accent2;
        private final long accent3;
        private final long background;
        private final long callToActionBackground;
        private final long callToActionForeground;
        private final C2714u callToActionSecondaryBackground;
        private final C2714u closeButton;
        private final long text1;
        private final long text2;
        private final long text3;
        private final C2714u tierControlBackground;
        private final C2714u tierControlForeground;
        private final C2714u tierControlSelectedBackground;
        private final C2714u tierControlSelectedForeground;

        public /* synthetic */ Colors(long j4, long j6, long j7, long j8, long j9, long j10, C2714u c2714u, long j11, long j12, long j13, C2714u c2714u2, C2714u c2714u3, C2714u c2714u4, C2714u c2714u5, C2714u c2714u6, h hVar) {
            this(j4, j6, j7, j8, j9, j10, c2714u, j11, j12, j13, c2714u2, c2714u3, c2714u4, c2714u5, c2714u6);
        }

        /* JADX INFO: renamed from: copy-VbAgQ-U$default, reason: not valid java name */
        public static /* synthetic */ Colors m1025copyVbAgQU$default(Colors colors, long j4, long j6, long j7, long j8, long j9, long j10, C2714u c2714u, long j11, long j12, long j13, C2714u c2714u2, C2714u c2714u3, C2714u c2714u4, C2714u c2714u5, C2714u c2714u6, int i6, Object obj) {
            long j14;
            long j15;
            long j16 = (i6 & 1) != 0 ? colors.background : j4;
            long j17 = (i6 & 2) != 0 ? colors.text1 : j6;
            long j18 = (i6 & 4) != 0 ? colors.text2 : j7;
            long j19 = (i6 & 8) != 0 ? colors.text3 : j8;
            long j20 = (i6 & 16) != 0 ? colors.callToActionBackground : j9;
            long j21 = (i6 & 32) != 0 ? colors.callToActionForeground : j10;
            C2714u c2714u7 = (i6 & 64) != 0 ? colors.callToActionSecondaryBackground : c2714u;
            if ((i6 & 128) != 0) {
                j14 = j16;
                j15 = colors.accent1;
            } else {
                j14 = j16;
                j15 = j11;
            }
            return colors.m1041copyVbAgQU(j14, j17, j18, j19, j20, j21, c2714u7, j15, (i6 & 256) != 0 ? colors.accent2 : j12, (i6 & 512) != 0 ? colors.accent3 : j13, (i6 & 1024) != 0 ? colors.closeButton : c2714u2, (i6 & 2048) != 0 ? colors.tierControlBackground : c2714u3, (i6 & 4096) != 0 ? colors.tierControlForeground : c2714u4, (i6 & 8192) != 0 ? colors.tierControlSelectedBackground : c2714u5, (i6 & 16384) != 0 ? colors.tierControlSelectedForeground : c2714u6);
        }

        /* JADX INFO: renamed from: component1-0d7_KjU, reason: not valid java name */
        public final long m1026component10d7_KjU() {
            return this.background;
        }

        /* JADX INFO: renamed from: component10-0d7_KjU, reason: not valid java name */
        public final long m1027component100d7_KjU() {
            return this.accent3;
        }

        /* JADX INFO: renamed from: component11-QN2ZGVo, reason: not valid java name */
        public final C2714u m1028component11QN2ZGVo() {
            return this.closeButton;
        }

        /* JADX INFO: renamed from: component12-QN2ZGVo, reason: not valid java name */
        public final C2714u m1029component12QN2ZGVo() {
            return this.tierControlBackground;
        }

        /* JADX INFO: renamed from: component13-QN2ZGVo, reason: not valid java name */
        public final C2714u m1030component13QN2ZGVo() {
            return this.tierControlForeground;
        }

        /* JADX INFO: renamed from: component14-QN2ZGVo, reason: not valid java name */
        public final C2714u m1031component14QN2ZGVo() {
            return this.tierControlSelectedBackground;
        }

        /* JADX INFO: renamed from: component15-QN2ZGVo, reason: not valid java name */
        public final C2714u m1032component15QN2ZGVo() {
            return this.tierControlSelectedForeground;
        }

        /* JADX INFO: renamed from: component2-0d7_KjU, reason: not valid java name */
        public final long m1033component20d7_KjU() {
            return this.text1;
        }

        /* JADX INFO: renamed from: component3-0d7_KjU, reason: not valid java name */
        public final long m1034component30d7_KjU() {
            return this.text2;
        }

        /* JADX INFO: renamed from: component4-0d7_KjU, reason: not valid java name */
        public final long m1035component40d7_KjU() {
            return this.text3;
        }

        /* JADX INFO: renamed from: component5-0d7_KjU, reason: not valid java name */
        public final long m1036component50d7_KjU() {
            return this.callToActionBackground;
        }

        /* JADX INFO: renamed from: component6-0d7_KjU, reason: not valid java name */
        public final long m1037component60d7_KjU() {
            return this.callToActionForeground;
        }

        /* JADX INFO: renamed from: component7-QN2ZGVo, reason: not valid java name */
        public final C2714u m1038component7QN2ZGVo() {
            return this.callToActionSecondaryBackground;
        }

        /* JADX INFO: renamed from: component8-0d7_KjU, reason: not valid java name */
        public final long m1039component80d7_KjU() {
            return this.accent1;
        }

        /* JADX INFO: renamed from: component9-0d7_KjU, reason: not valid java name */
        public final long m1040component90d7_KjU() {
            return this.accent2;
        }

        /* JADX INFO: renamed from: copy-VbAgQ-U, reason: not valid java name */
        public final Colors m1041copyVbAgQU(long j4, long j6, long j7, long j8, long j9, long j10, C2714u c2714u, long j11, long j12, long j13, C2714u c2714u2, C2714u c2714u3, C2714u c2714u4, C2714u c2714u5, C2714u c2714u6) {
            return new Colors(j4, j6, j7, j8, j9, j10, c2714u, j11, j12, j13, c2714u2, c2714u3, c2714u4, c2714u5, c2714u6, null);
        }

        public boolean equals(Object obj) {
            if (this == obj) {
                return true;
            }
            if (!(obj instanceof Colors)) {
                return false;
            }
            Colors colors = (Colors) obj;
            return C2714u.d(this.background, colors.background) && C2714u.d(this.text1, colors.text1) && C2714u.d(this.text2, colors.text2) && C2714u.d(this.text3, colors.text3) && C2714u.d(this.callToActionBackground, colors.callToActionBackground) && C2714u.d(this.callToActionForeground, colors.callToActionForeground) && o.c(this.callToActionSecondaryBackground, colors.callToActionSecondaryBackground) && C2714u.d(this.accent1, colors.accent1) && C2714u.d(this.accent2, colors.accent2) && C2714u.d(this.accent3, colors.accent3) && o.c(this.closeButton, colors.closeButton) && o.c(this.tierControlBackground, colors.tierControlBackground) && o.c(this.tierControlForeground, colors.tierControlForeground) && o.c(this.tierControlSelectedBackground, colors.tierControlSelectedBackground) && o.c(this.tierControlSelectedForeground, colors.tierControlSelectedForeground);
        }

        /* JADX INFO: renamed from: getAccent1-0d7_KjU, reason: not valid java name */
        public final long m1042getAccent10d7_KjU() {
            return this.accent1;
        }

        /* JADX INFO: renamed from: getAccent2-0d7_KjU, reason: not valid java name */
        public final long m1043getAccent20d7_KjU() {
            return this.accent2;
        }

        /* JADX INFO: renamed from: getAccent3-0d7_KjU, reason: not valid java name */
        public final long m1044getAccent30d7_KjU() {
            return this.accent3;
        }

        /* JADX INFO: renamed from: getBackground-0d7_KjU, reason: not valid java name */
        public final long m1045getBackground0d7_KjU() {
            return this.background;
        }

        /* JADX INFO: renamed from: getCallToActionBackground-0d7_KjU, reason: not valid java name */
        public final long m1046getCallToActionBackground0d7_KjU() {
            return this.callToActionBackground;
        }

        /* JADX INFO: renamed from: getCallToActionForeground-0d7_KjU, reason: not valid java name */
        public final long m1047getCallToActionForeground0d7_KjU() {
            return this.callToActionForeground;
        }

        /* JADX INFO: renamed from: getCallToActionSecondaryBackground-QN2ZGVo, reason: not valid java name */
        public final C2714u m1048getCallToActionSecondaryBackgroundQN2ZGVo() {
            return this.callToActionSecondaryBackground;
        }

        /* JADX INFO: renamed from: getCloseButton-QN2ZGVo, reason: not valid java name */
        public final C2714u m1049getCloseButtonQN2ZGVo() {
            return this.closeButton;
        }

        /* JADX INFO: renamed from: getText1-0d7_KjU, reason: not valid java name */
        public final long m1050getText10d7_KjU() {
            return this.text1;
        }

        /* JADX INFO: renamed from: getText2-0d7_KjU, reason: not valid java name */
        public final long m1051getText20d7_KjU() {
            return this.text2;
        }

        /* JADX INFO: renamed from: getText3-0d7_KjU, reason: not valid java name */
        public final long m1052getText30d7_KjU() {
            return this.text3;
        }

        /* JADX INFO: renamed from: getTierControlBackground-QN2ZGVo, reason: not valid java name */
        public final C2714u m1053getTierControlBackgroundQN2ZGVo() {
            return this.tierControlBackground;
        }

        /* JADX INFO: renamed from: getTierControlForeground-QN2ZGVo, reason: not valid java name */
        public final C2714u m1054getTierControlForegroundQN2ZGVo() {
            return this.tierControlForeground;
        }

        /* JADX INFO: renamed from: getTierControlSelectedBackground-QN2ZGVo, reason: not valid java name */
        public final C2714u m1055getTierControlSelectedBackgroundQN2ZGVo() {
            return this.tierControlSelectedBackground;
        }

        /* JADX INFO: renamed from: getTierControlSelectedForeground-QN2ZGVo, reason: not valid java name */
        public final C2714u m1056getTierControlSelectedForegroundQN2ZGVo() {
            return this.tierControlSelectedForeground;
        }

        public int hashCode() {
            long j4 = this.background;
            int i6 = C2714u.f22946n;
            int iE = a.e(a.e(a.e(a.e(a.e(Long.hashCode(j4) * 31, 31, this.text1), 31, this.text2), 31, this.text3), 31, this.callToActionBackground), 31, this.callToActionForeground);
            C2714u c2714u = this.callToActionSecondaryBackground;
            int iE2 = a.e(a.e(a.e((iE + (c2714u == null ? 0 : Long.hashCode(c2714u.f22947a))) * 31, 31, this.accent1), 31, this.accent2), 31, this.accent3);
            C2714u c2714u2 = this.closeButton;
            int iHashCode = (iE2 + (c2714u2 == null ? 0 : Long.hashCode(c2714u2.f22947a))) * 31;
            C2714u c2714u3 = this.tierControlBackground;
            int iHashCode2 = (iHashCode + (c2714u3 == null ? 0 : Long.hashCode(c2714u3.f22947a))) * 31;
            C2714u c2714u4 = this.tierControlForeground;
            int iHashCode3 = (iHashCode2 + (c2714u4 == null ? 0 : Long.hashCode(c2714u4.f22947a))) * 31;
            C2714u c2714u5 = this.tierControlSelectedBackground;
            int iHashCode4 = (iHashCode3 + (c2714u5 == null ? 0 : Long.hashCode(c2714u5.f22947a))) * 31;
            C2714u c2714u6 = this.tierControlSelectedForeground;
            return iHashCode4 + (c2714u6 != null ? Long.hashCode(c2714u6.f22947a) : 0);
        }

        public String toString() {
            StringBuilder sb = new StringBuilder("Colors(background=");
            AbstractC2761L.n(this.background, ", text1=", sb);
            AbstractC2761L.n(this.text1, ", text2=", sb);
            AbstractC2761L.n(this.text2, ", text3=", sb);
            AbstractC2761L.n(this.text3, ", callToActionBackground=", sb);
            AbstractC2761L.n(this.callToActionBackground, ", callToActionForeground=", sb);
            AbstractC2761L.n(this.callToActionForeground, ", callToActionSecondaryBackground=", sb);
            sb.append(this.callToActionSecondaryBackground);
            sb.append(", accent1=");
            AbstractC2761L.n(this.accent1, ", accent2=", sb);
            AbstractC2761L.n(this.accent2, ", accent3=", sb);
            AbstractC2761L.n(this.accent3, ", closeButton=", sb);
            sb.append(this.closeButton);
            sb.append(", tierControlBackground=");
            sb.append(this.tierControlBackground);
            sb.append(", tierControlForeground=");
            sb.append(this.tierControlForeground);
            sb.append(", tierControlSelectedBackground=");
            sb.append(this.tierControlSelectedBackground);
            sb.append(", tierControlSelectedForeground=");
            sb.append(this.tierControlSelectedForeground);
            sb.append(')');
            return sb.toString();
        }

        private Colors(long j4, long j6, long j7, long j8, long j9, long j10, C2714u c2714u, long j11, long j12, long j13, C2714u c2714u2, C2714u c2714u3, C2714u c2714u4, C2714u c2714u5, C2714u c2714u6) {
            this.background = j4;
            this.text1 = j6;
            this.text2 = j7;
            this.text3 = j8;
            this.callToActionBackground = j9;
            this.callToActionForeground = j10;
            this.callToActionSecondaryBackground = c2714u;
            this.accent1 = j11;
            this.accent2 = j12;
            this.accent3 = j13;
            this.closeButton = c2714u2;
            this.tierControlBackground = c2714u3;
            this.tierControlForeground = c2714u4;
            this.tierControlSelectedBackground = c2714u5;
            this.tierControlSelectedForeground = c2714u6;
        }
    }

    @Immutable
    public static final class Images {
        public static final int $stable = 0;
        private final Uri backgroundUri;
        private final Uri headerUri;
        private final Uri iconUri;

        public Images(Uri uri, Uri uri2, Uri uri3) {
            this.iconUri = uri;
            this.backgroundUri = uri2;
            this.headerUri = uri3;
        }

        public static /* synthetic */ Images copy$default(Images images, Uri uri, Uri uri2, Uri uri3, int i6, Object obj) {
            if ((i6 & 1) != 0) {
                uri = images.iconUri;
            }
            if ((i6 & 2) != 0) {
                uri2 = images.backgroundUri;
            }
            if ((i6 & 4) != 0) {
                uri3 = images.headerUri;
            }
            return images.copy(uri, uri2, uri3);
        }

        public final Uri component1() {
            return this.iconUri;
        }

        public final Uri component2() {
            return this.backgroundUri;
        }

        public final Uri component3() {
            return this.headerUri;
        }

        public final Images copy(Uri uri, Uri uri2, Uri uri3) {
            return new Images(uri, uri2, uri3);
        }

        public boolean equals(Object obj) {
            if (this == obj) {
                return true;
            }
            if (!(obj instanceof Images)) {
                return false;
            }
            Images images = (Images) obj;
            return o.c(this.iconUri, images.iconUri) && o.c(this.backgroundUri, images.backgroundUri) && o.c(this.headerUri, images.headerUri);
        }

        public final Uri getBackgroundUri() {
            return this.backgroundUri;
        }

        public final Uri getHeaderUri() {
            return this.headerUri;
        }

        public final Uri getIconUri() {
            return this.iconUri;
        }

        public int hashCode() {
            Uri uri = this.iconUri;
            int iHashCode = (uri == null ? 0 : uri.hashCode()) * 31;
            Uri uri2 = this.backgroundUri;
            int iHashCode2 = (iHashCode + (uri2 == null ? 0 : uri2.hashCode())) * 31;
            Uri uri3 = this.headerUri;
            return iHashCode2 + (uri3 != null ? uri3.hashCode() : 0);
        }

        public String toString() {
            return "Images(iconUri=" + this.iconUri + ", backgroundUri=" + this.backgroundUri + ", headerUri=" + this.headerUri + ')';
        }
    }

    @Stable
    public static abstract class PackageConfiguration {
        public static final int $stable = 0;

        @Immutable
        public static final class MultiPackage {
            public static final int $stable = 0;
            private final List<PackageInfo> all;

            /* JADX INFO: renamed from: default, reason: not valid java name */
            private final PackageInfo f33default;
            private final PackageInfo first;

            public MultiPackage(PackageInfo first, PackageInfo packageInfo, List<PackageInfo> all) {
                o.h(first, "first");
                o.h(packageInfo, "default");
                o.h(all, "all");
                this.first = first;
                this.f33default = packageInfo;
                this.all = all;
            }

            /* JADX WARN: Multi-variable type inference failed */
            public static /* synthetic */ MultiPackage copy$default(MultiPackage multiPackage, PackageInfo packageInfo, PackageInfo packageInfo2, List list, int i6, Object obj) {
                if ((i6 & 1) != 0) {
                    packageInfo = multiPackage.first;
                }
                if ((i6 & 2) != 0) {
                    packageInfo2 = multiPackage.f33default;
                }
                if ((i6 & 4) != 0) {
                    list = multiPackage.all;
                }
                return multiPackage.copy(packageInfo, packageInfo2, list);
            }

            public final PackageInfo component1() {
                return this.first;
            }

            public final PackageInfo component2() {
                return this.f33default;
            }

            public final List<PackageInfo> component3() {
                return this.all;
            }

            public final MultiPackage copy(PackageInfo first, PackageInfo packageInfo, List<PackageInfo> all) {
                o.h(first, "first");
                o.h(packageInfo, "default");
                o.h(all, "all");
                return new MultiPackage(first, packageInfo, all);
            }

            public boolean equals(Object obj) {
                if (this == obj) {
                    return true;
                }
                if (!(obj instanceof MultiPackage)) {
                    return false;
                }
                MultiPackage multiPackage = (MultiPackage) obj;
                return o.c(this.first, multiPackage.first) && o.c(this.f33default, multiPackage.f33default) && o.c(this.all, multiPackage.all);
            }

            public final List<PackageInfo> getAll() {
                return this.all;
            }

            public final PackageInfo getDefault() {
                return this.f33default;
            }

            public final PackageInfo getFirst() {
                return this.first;
            }

            public int hashCode() {
                return this.all.hashCode() + ((this.f33default.hashCode() + (this.first.hashCode() * 31)) * 31);
            }

            public String toString() {
                StringBuilder sb = new StringBuilder("MultiPackage(first=");
                sb.append(this.first);
                sb.append(", default=");
                sb.append(this.f33default);
                sb.append(", all=");
                return A0.a.o(sb, this.all, ')');
            }
        }

        @Immutable
        public static final class MultiTier extends PackageConfiguration {
            public static final int $stable = 0;
            private final List<TierInfo> allTiers;
            private final TierInfo defaultTier;

            /* JADX WARN: 'super' call moved to the top of the method (can break code semantics) */
            public MultiTier(TierInfo defaultTier, List<TierInfo> allTiers) {
                super(null);
                o.h(defaultTier, "defaultTier");
                o.h(allTiers, "allTiers");
                this.defaultTier = defaultTier;
                this.allTiers = allTiers;
            }

            /* JADX WARN: Multi-variable type inference failed */
            public static /* synthetic */ MultiTier copy$default(MultiTier multiTier, TierInfo tierInfo, List list, int i6, Object obj) {
                if ((i6 & 1) != 0) {
                    tierInfo = multiTier.defaultTier;
                }
                if ((i6 & 2) != 0) {
                    list = multiTier.allTiers;
                }
                return multiTier.copy(tierInfo, list);
            }

            public final TierInfo component1() {
                return this.defaultTier;
            }

            public final List<TierInfo> component2() {
                return this.allTiers;
            }

            public final MultiTier copy(TierInfo defaultTier, List<TierInfo> allTiers) {
                o.h(defaultTier, "defaultTier");
                o.h(allTiers, "allTiers");
                return new MultiTier(defaultTier, allTiers);
            }

            public boolean equals(Object obj) {
                if (this == obj) {
                    return true;
                }
                if (!(obj instanceof MultiTier)) {
                    return false;
                }
                MultiTier multiTier = (MultiTier) obj;
                return o.c(this.defaultTier, multiTier.defaultTier) && o.c(this.allTiers, multiTier.allTiers);
            }

            @Override // com.revenuecat.purchases.ui.revenuecatui.data.processed.TemplateConfiguration.PackageConfiguration
            public List<PackageInfo> getAll() {
                List<TierInfo> list = this.allTiers;
                ArrayList arrayList = new ArrayList(AbstractC3253s.G(list, 10));
                Iterator<T> it = list.iterator();
                while (it.hasNext()) {
                    arrayList.add(((TierInfo) it.next()).getPackages());
                }
                return AbstractC3253s.H(arrayList);
            }

            public final List<TierInfo> getAllTiers() {
                return this.allTiers;
            }

            @Override // com.revenuecat.purchases.ui.revenuecatui.data.processed.TemplateConfiguration.PackageConfiguration
            public PackageInfo getDefault() {
                return this.defaultTier.getDefaultPackage();
            }

            public final TierInfo getDefaultTier() {
                return this.defaultTier;
            }

            public int hashCode() {
                return this.allTiers.hashCode() + (this.defaultTier.hashCode() * 31);
            }

            public String toString() {
                StringBuilder sb = new StringBuilder("MultiTier(defaultTier=");
                sb.append(this.defaultTier);
                sb.append(", allTiers=");
                return A0.a.o(sb, this.allTiers, ')');
            }
        }

        @Immutable
        public static final class Multiple extends PackageConfiguration {
            public static final int $stable = 0;
            private final MultiPackage multiPackage;

            /* JADX WARN: 'super' call moved to the top of the method (can break code semantics) */
            public Multiple(MultiPackage multiPackage) {
                super(null);
                o.h(multiPackage, "multiPackage");
                this.multiPackage = multiPackage;
            }

            public static /* synthetic */ Multiple copy$default(Multiple multiple, MultiPackage multiPackage, int i6, Object obj) {
                if ((i6 & 1) != 0) {
                    multiPackage = multiple.multiPackage;
                }
                return multiple.copy(multiPackage);
            }

            public final MultiPackage component1() {
                return this.multiPackage;
            }

            public final Multiple copy(MultiPackage multiPackage) {
                o.h(multiPackage, "multiPackage");
                return new Multiple(multiPackage);
            }

            public boolean equals(Object obj) {
                if (this == obj) {
                    return true;
                }
                return (obj instanceof Multiple) && o.c(this.multiPackage, ((Multiple) obj).multiPackage);
            }

            @Override // com.revenuecat.purchases.ui.revenuecatui.data.processed.TemplateConfiguration.PackageConfiguration
            public List<PackageInfo> getAll() {
                return this.multiPackage.getAll();
            }

            @Override // com.revenuecat.purchases.ui.revenuecatui.data.processed.TemplateConfiguration.PackageConfiguration
            public PackageInfo getDefault() {
                return this.multiPackage.getDefault();
            }

            public final MultiPackage getMultiPackage() {
                return this.multiPackage;
            }

            public int hashCode() {
                return this.multiPackage.hashCode();
            }

            public String toString() {
                return "Multiple(multiPackage=" + this.multiPackage + ')';
            }
        }

        @Immutable
        public static final class Single extends PackageConfiguration {
            public static final int $stable = 0;
            private final PackageInfo singlePackage;

            /* JADX WARN: 'super' call moved to the top of the method (can break code semantics) */
            public Single(PackageInfo singlePackage) {
                super(null);
                o.h(singlePackage, "singlePackage");
                this.singlePackage = singlePackage;
            }

            public static /* synthetic */ Single copy$default(Single single, PackageInfo packageInfo, int i6, Object obj) {
                if ((i6 & 1) != 0) {
                    packageInfo = single.singlePackage;
                }
                return single.copy(packageInfo);
            }

            public final PackageInfo component1() {
                return this.singlePackage;
            }

            public final Single copy(PackageInfo singlePackage) {
                o.h(singlePackage, "singlePackage");
                return new Single(singlePackage);
            }

            public boolean equals(Object obj) {
                if (this == obj) {
                    return true;
                }
                return (obj instanceof Single) && o.c(this.singlePackage, ((Single) obj).singlePackage);
            }

            @Override // com.revenuecat.purchases.ui.revenuecatui.data.processed.TemplateConfiguration.PackageConfiguration
            public List<PackageInfo> getAll() {
                return AbstractC2612c.q(this.singlePackage);
            }

            @Override // com.revenuecat.purchases.ui.revenuecatui.data.processed.TemplateConfiguration.PackageConfiguration
            public PackageInfo getDefault() {
                return this.singlePackage;
            }

            public final PackageInfo getSinglePackage() {
                return this.singlePackage;
            }

            public int hashCode() {
                return this.singlePackage.hashCode();
            }

            public String toString() {
                return "Single(singlePackage=" + this.singlePackage + ')';
            }
        }

        public /* synthetic */ PackageConfiguration(h hVar) {
            this();
        }

        public abstract List<PackageInfo> getAll();

        public abstract PackageInfo getDefault();

        private PackageConfiguration() {
        }
    }

    @Immutable
    public static final class PackageInfo {
        public static final int $stable = 0;
        private final Double discountRelativeToMostExpensivePerMonth;
        private final ProcessedLocalizedConfiguration localization;
        private final Package rcPackage;

        public PackageInfo(Package rcPackage, ProcessedLocalizedConfiguration localization, Double d6) {
            o.h(rcPackage, "rcPackage");
            o.h(localization, "localization");
            this.rcPackage = rcPackage;
            this.localization = localization;
            this.discountRelativeToMostExpensivePerMonth = d6;
        }

        public static /* synthetic */ PackageInfo copy$default(PackageInfo packageInfo, Package r12, ProcessedLocalizedConfiguration processedLocalizedConfiguration, Double d6, int i6, Object obj) {
            if ((i6 & 1) != 0) {
                r12 = packageInfo.rcPackage;
            }
            if ((i6 & 2) != 0) {
                processedLocalizedConfiguration = packageInfo.localization;
            }
            if ((i6 & 4) != 0) {
                d6 = packageInfo.discountRelativeToMostExpensivePerMonth;
            }
            return packageInfo.copy(r12, processedLocalizedConfiguration, d6);
        }

        public final Package component1() {
            return this.rcPackage;
        }

        public final ProcessedLocalizedConfiguration component2() {
            return this.localization;
        }

        public final Double component3() {
            return this.discountRelativeToMostExpensivePerMonth;
        }

        public final PackageInfo copy(Package rcPackage, ProcessedLocalizedConfiguration localization, Double d6) {
            o.h(rcPackage, "rcPackage");
            o.h(localization, "localization");
            return new PackageInfo(rcPackage, localization, d6);
        }

        public boolean equals(Object obj) {
            if (this == obj) {
                return true;
            }
            if (!(obj instanceof PackageInfo)) {
                return false;
            }
            PackageInfo packageInfo = (PackageInfo) obj;
            return o.c(this.rcPackage, packageInfo.rcPackage) && o.c(this.localization, packageInfo.localization) && o.c(this.discountRelativeToMostExpensivePerMonth, packageInfo.discountRelativeToMostExpensivePerMonth);
        }

        public final Double getDiscountRelativeToMostExpensivePerMonth() {
            return this.discountRelativeToMostExpensivePerMonth;
        }

        public final ProcessedLocalizedConfiguration getLocalization() {
            return this.localization;
        }

        public final Package getRcPackage() {
            return this.rcPackage;
        }

        public int hashCode() {
            int iHashCode = (this.localization.hashCode() + (this.rcPackage.hashCode() * 31)) * 31;
            Double d6 = this.discountRelativeToMostExpensivePerMonth;
            return iHashCode + (d6 == null ? 0 : d6.hashCode());
        }

        public String toString() {
            return "PackageInfo(rcPackage=" + this.rcPackage + ", localization=" + this.localization + ", discountRelativeToMostExpensivePerMonth=" + this.discountRelativeToMostExpensivePerMonth + ')';
        }
    }

    @Immutable
    public static final class TierInfo {
        public static final int $stable = 0;
        private final PackageInfo defaultPackage;
        private final String id;
        private final String name;
        private final List<PackageInfo> packages;

        public TierInfo(String name, String id, PackageInfo defaultPackage, List<PackageInfo> packages) {
            o.h(name, "name");
            o.h(id, "id");
            o.h(defaultPackage, "defaultPackage");
            o.h(packages, "packages");
            this.name = name;
            this.id = id;
            this.defaultPackage = defaultPackage;
            this.packages = packages;
        }

        /* JADX WARN: Multi-variable type inference failed */
        public static /* synthetic */ TierInfo copy$default(TierInfo tierInfo, String str, String str2, PackageInfo packageInfo, List list, int i6, Object obj) {
            if ((i6 & 1) != 0) {
                str = tierInfo.name;
            }
            if ((i6 & 2) != 0) {
                str2 = tierInfo.id;
            }
            if ((i6 & 4) != 0) {
                packageInfo = tierInfo.defaultPackage;
            }
            if ((i6 & 8) != 0) {
                list = tierInfo.packages;
            }
            return tierInfo.copy(str, str2, packageInfo, list);
        }

        public final String component1() {
            return this.name;
        }

        public final String component2() {
            return this.id;
        }

        public final PackageInfo component3() {
            return this.defaultPackage;
        }

        public final List<PackageInfo> component4() {
            return this.packages;
        }

        public final TierInfo copy(String name, String id, PackageInfo defaultPackage, List<PackageInfo> packages) {
            o.h(name, "name");
            o.h(id, "id");
            o.h(defaultPackage, "defaultPackage");
            o.h(packages, "packages");
            return new TierInfo(name, id, defaultPackage, packages);
        }

        public boolean equals(Object obj) {
            if (this == obj) {
                return true;
            }
            if (!(obj instanceof TierInfo)) {
                return false;
            }
            TierInfo tierInfo = (TierInfo) obj;
            return o.c(this.name, tierInfo.name) && o.c(this.id, tierInfo.id) && o.c(this.defaultPackage, tierInfo.defaultPackage) && o.c(this.packages, tierInfo.packages);
        }

        public final PackageInfo getDefaultPackage() {
            return this.defaultPackage;
        }

        public final String getId() {
            return this.id;
        }

        public final String getName() {
            return this.name;
        }

        public final List<PackageInfo> getPackages() {
            return this.packages;
        }

        public int hashCode() {
            return this.packages.hashCode() + ((this.defaultPackage.hashCode() + AbstractC2761L.b(this.name.hashCode() * 31, 31, this.id)) * 31);
        }

        public String toString() {
            StringBuilder sb = new StringBuilder("TierInfo(name=");
            sb.append(this.name);
            sb.append(", id=");
            sb.append(this.id);
            sb.append(", defaultPackage=");
            sb.append(this.defaultPackage);
            sb.append(", packages=");
            return A0.a.o(sb, this.packages, ')');
        }
    }

    public TemplateConfiguration(PaywallTemplate template, PaywallMode mode, PackageConfiguration packages, PaywallData.Configuration configuration, Images images, Map<String, Images> imagesByTier, PaywallData.Configuration.ColorInformation colors, Locale locale) {
        o.h(template, "template");
        o.h(mode, "mode");
        o.h(packages, "packages");
        o.h(configuration, "configuration");
        o.h(images, "images");
        o.h(imagesByTier, "imagesByTier");
        o.h(colors, "colors");
        o.h(locale, "locale");
        this.template = template;
        this.mode = mode;
        this.packages = packages;
        this.configuration = configuration;
        this.images = images;
        this.imagesByTier = imagesByTier;
        this.colors = colors;
        this.locale = locale;
        ColorsFactory colorsFactory = ColorsFactory.INSTANCE;
        PaywallData.Configuration.Colors dark = colors.getDark();
        this.darkModeColors = colorsFactory.create(dark == null ? colors.getLight() : dark);
        this.lightModeColors = colorsFactory.create(colors.getLight());
    }

    /* JADX WARN: Multi-variable type inference failed */
    public static /* synthetic */ TemplateConfiguration copy$default(TemplateConfiguration templateConfiguration, PaywallTemplate paywallTemplate, PaywallMode paywallMode, PackageConfiguration packageConfiguration, PaywallData.Configuration configuration, Images images, Map map, PaywallData.Configuration.ColorInformation colorInformation, Locale locale, int i6, Object obj) {
        if ((i6 & 1) != 0) {
            paywallTemplate = templateConfiguration.template;
        }
        if ((i6 & 2) != 0) {
            paywallMode = templateConfiguration.mode;
        }
        if ((i6 & 4) != 0) {
            packageConfiguration = templateConfiguration.packages;
        }
        if ((i6 & 8) != 0) {
            configuration = templateConfiguration.configuration;
        }
        if ((i6 & 16) != 0) {
            images = templateConfiguration.images;
        }
        if ((i6 & 32) != 0) {
            map = templateConfiguration.imagesByTier;
        }
        if ((i6 & 64) != 0) {
            colorInformation = templateConfiguration.colors;
        }
        if ((i6 & 128) != 0) {
            locale = templateConfiguration.locale;
        }
        PaywallData.Configuration.ColorInformation colorInformation2 = colorInformation;
        Locale locale2 = locale;
        Images images2 = images;
        Map map2 = map;
        return templateConfiguration.copy(paywallTemplate, paywallMode, packageConfiguration, configuration, images2, map2, colorInformation2, locale2);
    }

    public final PaywallTemplate component1() {
        return this.template;
    }

    public final PaywallMode component2() {
        return this.mode;
    }

    public final PackageConfiguration component3() {
        return this.packages;
    }

    public final PaywallData.Configuration component4() {
        return this.configuration;
    }

    public final Images component5() {
        return this.images;
    }

    public final Map<String, Images> component6() {
        return this.imagesByTier;
    }

    public final PaywallData.Configuration.ColorInformation component7() {
        return this.colors;
    }

    public final Locale component8() {
        return this.locale;
    }

    public final TemplateConfiguration copy(PaywallTemplate template, PaywallMode mode, PackageConfiguration packages, PaywallData.Configuration configuration, Images images, Map<String, Images> imagesByTier, PaywallData.Configuration.ColorInformation colors, Locale locale) {
        o.h(template, "template");
        o.h(mode, "mode");
        o.h(packages, "packages");
        o.h(configuration, "configuration");
        o.h(images, "images");
        o.h(imagesByTier, "imagesByTier");
        o.h(colors, "colors");
        o.h(locale, "locale");
        return new TemplateConfiguration(template, mode, packages, configuration, images, imagesByTier, colors, locale);
    }

    public boolean equals(Object obj) {
        if (this == obj) {
            return true;
        }
        if (!(obj instanceof TemplateConfiguration)) {
            return false;
        }
        TemplateConfiguration templateConfiguration = (TemplateConfiguration) obj;
        return this.template == templateConfiguration.template && this.mode == templateConfiguration.mode && o.c(this.packages, templateConfiguration.packages) && o.c(this.configuration, templateConfiguration.configuration) && o.c(this.images, templateConfiguration.images) && o.c(this.imagesByTier, templateConfiguration.imagesByTier) && o.c(this.colors, templateConfiguration.colors) && o.c(this.locale, templateConfiguration.locale);
    }

    public final PaywallData.Configuration.ColorInformation getColors() {
        return this.colors;
    }

    public final PaywallData.Configuration getConfiguration() {
        return this.configuration;
    }

    @Composable
    @ReadOnlyComposable
    public final Colors getCurrentColors(Composer composer, int i6) {
        if (ComposerKt.isTraceInProgress()) {
            ComposerKt.traceEventStart(-1598555926, i6, -1, "com.revenuecat.purchases.ui.revenuecatui.data.processed.TemplateConfiguration.getCurrentColors (TemplateConfiguration.kt:30)");
        }
        Colors colors = AbstractC3058z.v(composer) ? this.darkModeColors : this.lightModeColors;
        if (ComposerKt.isTraceInProgress()) {
            ComposerKt.traceEventEnd();
        }
        return colors;
    }

    @Composable
    @ReadOnlyComposable
    public final Colors getCurrentColorsForTier(TierInfo tier, Composer composer, int i6) {
        Colors colorsCreate;
        o.h(tier, "tier");
        if (ComposerKt.isTraceInProgress()) {
            ComposerKt.traceEventStart(844077603, i6, -1, "com.revenuecat.purchases.ui.revenuecatui.data.processed.TemplateConfiguration.getCurrentColorsForTier (TemplateConfiguration.kt:36)");
        }
        Map<String, PaywallData.Configuration.ColorInformation> colorsByTier = this.configuration.getColorsByTier();
        Colors currentColors = null;
        PaywallData.Configuration.ColorInformation colorInformation = colorsByTier != null ? colorsByTier.get(tier.getId()) : null;
        if (colorInformation != null) {
            if (AbstractC3058z.v(composer)) {
                ColorsFactory colorsFactory = ColorsFactory.INSTANCE;
                PaywallData.Configuration.Colors dark = colorInformation.getDark();
                if (dark == null) {
                    dark = colorInformation.getLight();
                }
                colorsCreate = colorsFactory.create(dark);
            } else {
                colorsCreate = ColorsFactory.INSTANCE.create(colorInformation.getLight());
            }
            currentColors = colorsCreate;
        }
        if (currentColors == null) {
            currentColors = getCurrentColors(composer, (i6 >> 3) & 14);
        }
        if (ComposerKt.isTraceInProgress()) {
            ComposerKt.traceEventEnd();
        }
        return currentColors;
    }

    public final Images getImages() {
        return this.images;
    }

    public final Map<String, Images> getImagesByTier() {
        return this.imagesByTier;
    }

    public final Locale getLocale() {
        return this.locale;
    }

    public final PaywallMode getMode() {
        return this.mode;
    }

    public final PackageConfiguration getPackages() {
        return this.packages;
    }

    public final PaywallTemplate getTemplate() {
        return this.template;
    }

    public int hashCode() {
        return this.locale.hashCode() + ((this.colors.hashCode() + A0.a.d(this.imagesByTier, (this.images.hashCode() + ((this.configuration.hashCode() + ((this.packages.hashCode() + ((this.mode.hashCode() + (this.template.hashCode() * 31)) * 31)) * 31)) * 31)) * 31, 31)) * 31);
    }

    public String toString() {
        return "TemplateConfiguration(template=" + this.template + ", mode=" + this.mode + ", packages=" + this.packages + ", configuration=" + this.configuration + ", images=" + this.images + ", imagesByTier=" + this.imagesByTier + ", colors=" + this.colors + ", locale=" + this.locale + ')';
    }
}
