package com.revenuecat.purchases.ui.revenuecatui.components.timeline;

import J4.c;
import Q4.m;
import com.revenuecat.purchases.paywalls.components.TimelineComponent;
import kotlin.jvm.internal.o;
import kotlin.jvm.internal.p;
import m1.b;
import m1.d;
import m1.e;
import m1.f;
import q1.C2833e;
import q1.C2835g;
import w4.C3137A;

/* JADX INFO: loaded from: classes3.dex */
public final class TimelineComponentViewKt$TimelineComponentView$2$4$1 extends p implements c {
    final /* synthetic */ e $currentPreviousItem;
    final /* synthetic */ f $iconEndBarrier;
    final /* synthetic */ m1.c $iconRef;
    final /* synthetic */ TimelineComponentState $timelineState;

    public /* synthetic */ class WhenMappings {
        public static final /* synthetic */ int[] $EnumSwitchMapping$0;

        static {
            int[] iArr = new int[TimelineComponent.IconAlignment.values().length];
            try {
                iArr[TimelineComponent.IconAlignment.Title.ordinal()] = 1;
            } catch (NoSuchFieldError unused) {
            }
            try {
                iArr[TimelineComponent.IconAlignment.TitleAndDescription.ordinal()] = 2;
            } catch (NoSuchFieldError unused2) {
            }
            $EnumSwitchMapping$0 = iArr;
        }
    }

    /* JADX WARN: 'super' call moved to the top of the method (can break code semantics) */
    public TimelineComponentViewKt$TimelineComponentView$2$4$1(TimelineComponentState timelineComponentState, m1.c cVar, e eVar, f fVar) {
        super(1);
        this.$timelineState = timelineComponentState;
        this.$iconRef = cVar;
        this.$currentPreviousItem = eVar;
        this.$iconEndBarrier = fVar;
    }

    @Override // J4.c
    public /* bridge */ /* synthetic */ Object invoke(Object obj) {
        invoke((b) obj);
        return C3137A.f25453a;
    }

    public final void invoke(b constrainAs) {
        o.h(constrainAs, "$this$constrainAs");
        int i6 = WhenMappings.$EnumSwitchMapping$0[this.$timelineState.getIconAlignment().ordinal()];
        C2835g c2835g = constrainAs.f20408b;
        m1.c cVar = constrainAs.f20409c;
        d dVar = constrainAs.f20411e;
        if (i6 == 1) {
            m1.c cVar2 = this.$iconRef;
            m[] mVarArr = b.f20406j;
            float f6 = 0;
            dVar.a(cVar2.f20418d, f6, f6);
            constrainAs.f20413g.a(cVar2.f20420f, f6, f6);
            c2835g.getClass();
            c2835g.C("vBias", new C2833e(0.5f));
        } else if (i6 == 2) {
            e eVar = this.$currentPreviousItem;
            if (eVar == null) {
                eVar = cVar.f20418d;
            }
            d.b(dVar, eVar, 0.0f, 6);
        }
        d.c(constrainAs.f20410d, this.$iconEndBarrier, 0.0f, 6);
        d.c(constrainAs.f20412f, cVar.f20419e, 0.0f, 6);
        m1.m mVar = new m1.m(null, "preferWrap");
        m[] mVarArr2 = b.f20406j;
        constrainAs.f20414h.v(mVarArr2[0], mVar);
        constrainAs.f20415i.v(mVarArr2[1], new m1.m(null, "preferWrap"));
        if (Float.isNaN(0.0f)) {
            return;
        }
        c2835g.getClass();
        c2835g.C("hBias", new C2833e(0.0f));
    }
}
