package com.sistemasolton.itranvias.home.presentation.prices;

import androidx.compose.foundation.layout.Arrangement;
import androidx.compose.foundation.layout.BoxKt;
import androidx.compose.foundation.layout.BoxScopeInstance;
import androidx.compose.foundation.layout.PaddingKt;
import androidx.compose.foundation.layout.PaddingValues;
import androidx.compose.foundation.layout.SizeKt;
import androidx.compose.foundation.lazy.LazyDslKt;
import androidx.compose.foundation.lazy.LazyListScope;
import androidx.compose.material3.AppBarKt;
import androidx.compose.material3.IconButtonKt;
import androidx.compose.material3.MaterialTheme;
import androidx.compose.material3.ScaffoldKt;
import androidx.compose.material3.TextKt;
import androidx.compose.material3.TopAppBarDefaults;
import androidx.compose.runtime.Applier;
import androidx.compose.runtime.ComposablesKt;
import androidx.compose.runtime.Composer;
import androidx.compose.runtime.ComposerKt;
import androidx.compose.runtime.CompositionLocalMap;
import androidx.compose.runtime.RecomposeScopeImplKt;
import androidx.compose.runtime.ScopeUpdateScope;
import androidx.compose.runtime.SnapshotStateKt;
import androidx.compose.runtime.State;
import androidx.compose.runtime.Updater;
import androidx.compose.runtime.internal.ComposableLambda;
import androidx.compose.runtime.internal.ComposableLambdaKt;
import androidx.compose.ui.Alignment;
import androidx.compose.ui.ComposedModifierKt;
import androidx.compose.ui.Modifier;
import androidx.compose.ui.layout.MeasurePolicy;
import androidx.compose.ui.node.ComposeUiNode;
import androidx.compose.ui.semantics.Role;
import androidx.compose.ui.semantics.SemanticsModifierKt;
import androidx.compose.ui.semantics.SemanticsPropertiesKt;
import androidx.compose.ui.semantics.SemanticsPropertyReceiver;
import androidx.compose.ui.text.TextLayoutResult;
import androidx.compose.ui.text.TextStyle;
import androidx.compose.ui.text.font.FontFamily;
import androidx.compose.ui.text.font.FontStyle;
import androidx.compose.ui.text.font.FontWeight;
import androidx.compose.ui.text.style.TextAlign;
import androidx.compose.ui.text.style.TextDecoration;
import androidx.compose.ui.unit.Dp;
import androidx.lifecycle.ViewModel;
import androidx.lifecycle.ViewModelStoreOwner;
import androidx.lifecycle.viewmodel.compose.LocalViewModelStoreOwner;
import androidx.profileinstaller.ProfileVerifier;
import com.sistemasolton.itranvias.core.presentation.ConnectionErrorScreenKt;
import com.sistemasolton.itranvias.core.presentation.LoadingScreenKt;
import com.sistemasolton.itranvias.data.preferences.SettingsRepository;
import com.sistemasolton.itranvias.home.data.remote.dto.infodto.InfoDto;
import com.sistemasolton.itranvias.home.data.remote.dto.infodto.TarifaDto;
import com.sistemasolton.itranvias.home.presentation.prices.PricesScreenKt;
import com.sistemasolton.itranvias.ui.theme.ColorKt;
import itranvias.composeapp.generated.resources.Res;
import itranvias.composeapp.generated.resources.String0_commonMainKt;
import itranvias.composeapp.generated.resources.String1_commonMainKt;
import java.util.List;
import kotlin.Metadata;
import kotlin.Unit;
import kotlin.jvm.functions.Function0;
import kotlin.jvm.functions.Function1;
import kotlin.jvm.functions.Function2;
import kotlin.jvm.functions.Function3;
import kotlin.jvm.internal.Intrinsics;
import kotlin.jvm.internal.Reflection;
import kotlin.text.StringsKt;
import org.jetbrains.compose.resources.StringResourcesKt;
import org.koin.compose.KoinApplicationKt;
import org.koin.core.parameter.ParametersHolder;
import org.koin.core.parameter.ParametersHolderKt;
import org.koin.core.scope.Scope;
import org.koin.viewmodel.CreationExtrasExtKt;
import org.koin.viewmodel.GetViewModelKt;

/* JADX INFO: compiled from: PricesScreen.kt */
/* JADX INFO: loaded from: classes2.dex */
@Metadata(d1 = {"\u0000$\n\u0000\n\u0002\u0010\u0002\n\u0000\n\u0002\u0018\u0002\n\u0002\b\u0003\n\u0002\u0018\u0002\n\u0002\b\u0002\n\u0002\u0010\u000e\n\u0002\u0010\u0006\n\u0002\b\u0002\u001a\u001b\u0010\u0000\u001a\u00020\u00012\f\u0010\u0002\u001a\b\u0012\u0004\u0012\u00020\u00010\u0003H\u0007¢\u0006\u0002\u0010\u0004\u001a\u0015\u0010\u0005\u001a\u00020\u00012\u0006\u0010\u0006\u001a\u00020\u0007H\u0007¢\u0006\u0002\u0010\b\u001a\n\u0010\t\u001a\u00020\n*\u00020\u000b¨\u0006\f²\u0006\n\u0010\r\u001a\u00020\nX\u008a\u0084\u0002"}, d2 = {"PricesScreen", "", "onBackPressed", "Lkotlin/Function0;", "(Lkotlin/jvm/functions/Function0;Landroidx/compose/runtime/Composer;I)V", "TariffsList", "info", "Lcom/sistemasolton/itranvias/home/data/remote/dto/infodto/InfoDto;", "(Lcom/sistemasolton/itranvias/home/data/remote/dto/infodto/InfoDto;Landroidx/compose/runtime/Composer;I)V", "toEuroFormat", "", "", "composeApp_release", "language"}, k = 2, mv = {2, 1, 0}, xi = 48)
public final class PricesScreenKt {
    /* JADX INFO: Access modifiers changed from: private */
    public static final Unit PricesScreen$lambda$3(Function0 function0, int i, Composer composer, int i2) {
        PricesScreen(function0, composer, RecomposeScopeImplKt.updateChangedFlags(i | 1));
        return Unit.INSTANCE;
    }

    /* JADX INFO: Access modifiers changed from: private */
    public static final Unit TariffsList$lambda$8(InfoDto infoDto, int i, Composer composer, int i2) {
        TariffsList(infoDto, composer, RecomposeScopeImplKt.updateChangedFlags(i | 1));
        return Unit.INSTANCE;
    }

    public static final void PricesScreen(final Function0<Unit> onBackPressed, Composer composer, final int i) {
        int i2;
        Composer composer2;
        Intrinsics.checkNotNullParameter(onBackPressed, "onBackPressed");
        Composer composerStartRestartGroup = composer.startRestartGroup(1320949454);
        if ((i & 6) == 0) {
            i2 = (composerStartRestartGroup.changedInstance(onBackPressed) ? 4 : 2) | i;
        } else {
            i2 = i;
        }
        if ((i2 & 3) != 2 || !composerStartRestartGroup.getSkipping()) {
            if (ComposerKt.isTraceInProgress()) {
                ComposerKt.traceEventStart(1320949454, i2, -1, "com.sistemasolton.itranvias.home.presentation.prices.PricesScreen (PricesScreen.kt:58)");
            }
            composerStartRestartGroup.startReplaceGroup(-1168520582);
            Scope scopeCurrentKoinScope = KoinApplicationKt.currentKoinScope(composerStartRestartGroup, 0);
            composerStartRestartGroup.startReplaceGroup(-1633490746);
            boolean zChanged = composerStartRestartGroup.changed((Object) null) | composerStartRestartGroup.changed(scopeCurrentKoinScope);
            Object objRememberedValue = composerStartRestartGroup.rememberedValue();
            if (zChanged || objRememberedValue == Composer.INSTANCE.getEmpty()) {
                objRememberedValue = Scope.get$default(scopeCurrentKoinScope, Reflection.getOrCreateKotlinClass(SettingsRepository.class), null, null, 4, null);
                composerStartRestartGroup.updateRememberedValue(objRememberedValue);
            }
            composerStartRestartGroup.endReplaceGroup();
            composerStartRestartGroup.endReplaceGroup();
            final State stateCollectAsState = SnapshotStateKt.collectAsState(((SettingsRepository) objRememberedValue).getLanguageFlow(), "es", null, composerStartRestartGroup, 48, 2);
            composerStartRestartGroup.startReplaceGroup(5004770);
            boolean zChanged2 = composerStartRestartGroup.changed(stateCollectAsState);
            Object objRememberedValue2 = composerStartRestartGroup.rememberedValue();
            if (zChanged2 || objRememberedValue2 == Composer.INSTANCE.getEmpty()) {
                objRememberedValue2 = new Function0() { // from class: com.sistemasolton.itranvias.home.presentation.prices.PricesScreenKt$$ExternalSyntheticLambda3
                    @Override // kotlin.jvm.functions.Function0
                    public final Object invoke() {
                        return PricesScreenKt.PricesScreen$lambda$2$lambda$1(stateCollectAsState);
                    }
                };
                composerStartRestartGroup.updateRememberedValue(objRememberedValue2);
            }
            Function0 function0 = (Function0) objRememberedValue2;
            composerStartRestartGroup.endReplaceGroup();
            composerStartRestartGroup.startReplaceGroup(-924953623);
            ViewModelStoreOwner current = LocalViewModelStoreOwner.INSTANCE.getCurrent(composerStartRestartGroup, LocalViewModelStoreOwner.$stable);
            if (current == null) {
                throw new IllegalStateException("No ViewModelStoreOwner was provided via LocalViewModelStoreOwner".toString());
            }
            ViewModel viewModelResolveViewModel = GetViewModelKt.resolveViewModel(Reflection.getOrCreateKotlinClass(PricesViewModel.class), current.getViewModelStore(), null, CreationExtrasExtKt.defaultExtras(current), null, KoinApplicationKt.currentKoinScope(composerStartRestartGroup, 0), function0);
            composerStartRestartGroup.endReplaceGroup();
            PricesViewModel pricesViewModel = (PricesViewModel) viewModelResolveViewModel;
            PricesState state = pricesViewModel.getState();
            ComposableLambda composableLambdaRememberComposableLambda = ComposableLambdaKt.rememberComposableLambda(-853183086, true, new Function2<Composer, Integer, Unit>() { // from class: com.sistemasolton.itranvias.home.presentation.prices.PricesScreenKt.PricesScreen.1
                @Override // kotlin.jvm.functions.Function2
                public /* bridge */ /* synthetic */ Unit invoke(Composer composer3, Integer num) {
                    invoke(composer3, num.intValue());
                    return Unit.INSTANCE;
                }

                /* JADX INFO: renamed from: com.sistemasolton.itranvias.home.presentation.prices.PricesScreenKt$PricesScreen$1$1, reason: invalid class name and collision with other inner class name */
                /* JADX INFO: compiled from: PricesScreen.kt */
                @Metadata(k = 3, mv = {2, 1, 0}, xi = 48)
                static final class C01201 implements Function2<Composer, Integer, Unit> {
                    final /* synthetic */ String $pricesTitleText;

                    C01201(String str) {
                        this.$pricesTitleText = str;
                    }

                    @Override // kotlin.jvm.functions.Function2
                    public /* bridge */ /* synthetic */ Unit invoke(Composer composer, Integer num) {
                        invoke(composer, num.intValue());
                        return Unit.INSTANCE;
                    }

                    public final void invoke(Composer composer, int i) {
                        if ((i & 3) == 2 && composer.getSkipping()) {
                            composer.skipToGroupEnd();
                            return;
                        }
                        if (ComposerKt.isTraceInProgress()) {
                            ComposerKt.traceEventStart(-533833394, i, -1, "com.sistemasolton.itranvias.home.presentation.prices.PricesScreen.<anonymous>.<anonymous> (PricesScreen.kt:73)");
                        }
                        long whiteTranvias = ColorKt.getWhiteTranvias();
                        Modifier.Companion companion = Modifier.INSTANCE;
                        composer.startReplaceGroup(5004770);
                        boolean zChanged = composer.changed(this.$pricesTitleText);
                        final String str = this.$pricesTitleText;
                        Object objRememberedValue = composer.rememberedValue();
                        if (zChanged || objRememberedValue == Composer.INSTANCE.getEmpty()) {
                            objRememberedValue = new Function1() { // from class: com.sistemasolton.itranvias.home.presentation.prices.PricesScreenKt$PricesScreen$1$1$$ExternalSyntheticLambda0
                                @Override // kotlin.jvm.functions.Function1
                                public final Object invoke(Object obj) {
                                    return PricesScreenKt.AnonymousClass1.C01201.invoke$lambda$1$lambda$0(str, (SemanticsPropertyReceiver) obj);
                                }
                            };
                            composer.updateRememberedValue(objRememberedValue);
                        }
                        composer.endReplaceGroup();
                        TextKt.m2803Text4IGK_g(this.$pricesTitleText, SemanticsModifierKt.semantics$default(companion, false, (Function1) objRememberedValue, 1, null), whiteTranvias, 0L, (FontStyle) null, (FontWeight) null, (FontFamily) null, 0L, (TextDecoration) null, (TextAlign) null, 0L, 0, false, 0, 0, (Function1<? super TextLayoutResult, Unit>) null, (TextStyle) null, composer, 384, 0, 131064);
                        if (ComposerKt.isTraceInProgress()) {
                            ComposerKt.traceEventEnd();
                        }
                    }

                    /* JADX INFO: Access modifiers changed from: private */
                    public static final Unit invoke$lambda$1$lambda$0(String str, SemanticsPropertyReceiver semantics) {
                        Intrinsics.checkNotNullParameter(semantics, "$this$semantics");
                        SemanticsPropertiesKt.heading(semantics);
                        SemanticsPropertiesKt.setContentDescription(semantics, str);
                        return Unit.INSTANCE;
                    }
                }

                public final void invoke(Composer composer3, int i3) {
                    if ((i3 & 3) == 2 && composer3.getSkipping()) {
                        composer3.skipToGroupEnd();
                        return;
                    }
                    if (ComposerKt.isTraceInProgress()) {
                        ComposerKt.traceEventStart(-853183086, i3, -1, "com.sistemasolton.itranvias.home.presentation.prices.PricesScreen.<anonymous> (PricesScreen.kt:68)");
                    }
                    AppBarKt.m1882TopAppBarGHTll3U(ComposableLambdaKt.rememberComposableLambda(-533833394, true, new C01201(StringResourcesKt.stringResource(String0_commonMainKt.getPrices_title(Res.string.INSTANCE), composer3, 0)), composer3, 54), null, ComposableLambdaKt.rememberComposableLambda(-1223664884, true, new AnonymousClass2(onBackPressed, StringResourcesKt.stringResource(String1_commonMainKt.getVolver(Res.string.INSTANCE), composer3, 0)), composer3, 54), null, 0.0f, null, TopAppBarDefaults.INSTANCE.m2974topAppBarColorszjMxDiM(MaterialTheme.INSTANCE.getColorScheme(composer3, MaterialTheme.$stable).getInversePrimary(), 0L, 0L, 0L, 0L, composer3, TopAppBarDefaults.$stable << 15, 30), null, composer3, 390, 186);
                    if (ComposerKt.isTraceInProgress()) {
                        ComposerKt.traceEventEnd();
                    }
                }

                /* JADX INFO: renamed from: com.sistemasolton.itranvias.home.presentation.prices.PricesScreenKt$PricesScreen$1$2, reason: invalid class name */
                /* JADX INFO: compiled from: PricesScreen.kt */
                @Metadata(k = 3, mv = {2, 1, 0}, xi = 48)
                static final class AnonymousClass2 implements Function2<Composer, Integer, Unit> {
                    final /* synthetic */ Function0<Unit> $onBackPressed;
                    final /* synthetic */ String $volverText;

                    AnonymousClass2(Function0<Unit> function0, String str) {
                        this.$onBackPressed = function0;
                        this.$volverText = str;
                    }

                    @Override // kotlin.jvm.functions.Function2
                    public /* bridge */ /* synthetic */ Unit invoke(Composer composer, Integer num) {
                        invoke(composer, num.intValue());
                        return Unit.INSTANCE;
                    }

                    public final void invoke(Composer composer, int i) {
                        if ((i & 3) == 2 && composer.getSkipping()) {
                            composer.skipToGroupEnd();
                            return;
                        }
                        if (ComposerKt.isTraceInProgress()) {
                            ComposerKt.traceEventStart(-1223664884, i, -1, "com.sistemasolton.itranvias.home.presentation.prices.PricesScreen.<anonymous>.<anonymous> (PricesScreen.kt:83)");
                        }
                        Function0<Unit> function0 = this.$onBackPressed;
                        Modifier.Companion companion = Modifier.INSTANCE;
                        composer.startReplaceGroup(5004770);
                        boolean zChanged = composer.changed(this.$volverText);
                        final String str = this.$volverText;
                        Object objRememberedValue = composer.rememberedValue();
                        if (zChanged || objRememberedValue == Composer.INSTANCE.getEmpty()) {
                            objRememberedValue = new Function1() { // from class: com.sistemasolton.itranvias.home.presentation.prices.PricesScreenKt$PricesScreen$1$2$$ExternalSyntheticLambda0
                                @Override // kotlin.jvm.functions.Function1
                                public final Object invoke(Object obj) {
                                    return PricesScreenKt.AnonymousClass1.AnonymousClass2.invoke$lambda$1$lambda$0(str, (SemanticsPropertyReceiver) obj);
                                }
                            };
                            composer.updateRememberedValue(objRememberedValue);
                        }
                        composer.endReplaceGroup();
                        IconButtonKt.IconButton(function0, SemanticsModifierKt.semantics$default(companion, false, (Function1) objRememberedValue, 1, null), false, null, null, ComposableSingletons$PricesScreenKt.INSTANCE.m7989getLambda$1751554481$composeApp_release(), composer, ProfileVerifier.CompilationStatus.RESULT_CODE_ERROR_CANT_WRITE_PROFILE_VERIFICATION_RESULT_CACHE_FILE, 28);
                        if (ComposerKt.isTraceInProgress()) {
                            ComposerKt.traceEventEnd();
                        }
                    }

                    /* JADX INFO: Access modifiers changed from: private */
                    public static final Unit invoke$lambda$1$lambda$0(String str, SemanticsPropertyReceiver semantics) {
                        Intrinsics.checkNotNullParameter(semantics, "$this$semantics");
                        SemanticsPropertiesKt.m6444setRolekuIjeqM(semantics, Role.INSTANCE.m6425getButtono7Vup1c());
                        SemanticsPropertiesKt.setContentDescription(semantics, str);
                        return Unit.INSTANCE;
                    }
                }
            }, composerStartRestartGroup, 54);
            ComposableLambda composableLambdaRememberComposableLambda2 = ComposableLambdaKt.rememberComposableLambda(-1571985443, true, new AnonymousClass2(state, pricesViewModel), composerStartRestartGroup, 54);
            composer2 = composerStartRestartGroup;
            ScaffoldKt.m2518ScaffoldTvnljyQ(null, composableLambdaRememberComposableLambda, null, null, null, 0, 0L, 0L, null, composableLambdaRememberComposableLambda2, composerStartRestartGroup, 805306416, 509);
            if (ComposerKt.isTraceInProgress()) {
                ComposerKt.traceEventEnd();
            }
        } else {
            composerStartRestartGroup.skipToGroupEnd();
            composer2 = composerStartRestartGroup;
        }
        ScopeUpdateScope scopeUpdateScopeEndRestartGroup = composer2.endRestartGroup();
        if (scopeUpdateScopeEndRestartGroup != null) {
            scopeUpdateScopeEndRestartGroup.updateScope(new Function2() { // from class: com.sistemasolton.itranvias.home.presentation.prices.PricesScreenKt$$ExternalSyntheticLambda4
                @Override // kotlin.jvm.functions.Function2
                public final Object invoke(Object obj, Object obj2) {
                    return PricesScreenKt.PricesScreen$lambda$3(onBackPressed, i, (Composer) obj, ((Integer) obj2).intValue());
                }
            });
        }
    }

    /* JADX INFO: Access modifiers changed from: private */
    public static final ParametersHolder PricesScreen$lambda$2$lambda$1(State state) {
        return ParametersHolderKt.parametersOf(PricesScreen$lambda$0(state));
    }

    /* JADX INFO: renamed from: com.sistemasolton.itranvias.home.presentation.prices.PricesScreenKt$PricesScreen$2, reason: invalid class name */
    /* JADX INFO: compiled from: PricesScreen.kt */
    @Metadata(k = 3, mv = {2, 1, 0}, xi = 48)
    static final class AnonymousClass2 implements Function3<PaddingValues, Composer, Integer, Unit> {
        final /* synthetic */ PricesState $state;
        final /* synthetic */ PricesViewModel $viewModel;

        AnonymousClass2(PricesState pricesState, PricesViewModel pricesViewModel) {
            this.$state = pricesState;
            this.$viewModel = pricesViewModel;
        }

        @Override // kotlin.jvm.functions.Function3
        public /* bridge */ /* synthetic */ Unit invoke(PaddingValues paddingValues, Composer composer, Integer num) {
            invoke(paddingValues, composer, num.intValue());
            return Unit.INSTANCE;
        }

        /* JADX INFO: Access modifiers changed from: private */
        public static final Unit invoke$lambda$2$lambda$1$lambda$0(PricesViewModel pricesViewModel) {
            pricesViewModel.loadInfo();
            return Unit.INSTANCE;
        }

        public final void invoke(PaddingValues padding, Composer composer, int i) {
            Intrinsics.checkNotNullParameter(padding, "padding");
            if ((i & 6) == 0) {
                i |= composer.changed(padding) ? 4 : 2;
            }
            if ((i & 19) == 18 && composer.getSkipping()) {
                composer.skipToGroupEnd();
                return;
            }
            if (ComposerKt.isTraceInProgress()) {
                ComposerKt.traceEventStart(-1571985443, i, -1, "com.sistemasolton.itranvias.home.presentation.prices.PricesScreen.<anonymous> (PricesScreen.kt:101)");
            }
            Modifier modifierFillMaxSize$default = SizeKt.fillMaxSize$default(PaddingKt.padding(Modifier.INSTANCE, padding), 0.0f, 1, null);
            Alignment center = Alignment.INSTANCE.getCenter();
            PricesState pricesState = this.$state;
            final PricesViewModel pricesViewModel = this.$viewModel;
            ComposerKt.sourceInformationMarkerStart(composer, 1042775818, "CC(Box)N(modifier,contentAlignment,propagateMinConstraints,content)71@3424L131:Box.kt#2w3rfo");
            MeasurePolicy measurePolicyMaybeCachedBoxMeasurePolicy = BoxKt.maybeCachedBoxMeasurePolicy(center, false);
            ComposerKt.sourceInformationMarkerStart(composer, -1159599143, "CC(Layout)P(!1,2)80@3267L27,83@3433L360:Layout.kt#80mrfh");
            int iHashCode = Long.hashCode(ComposablesKt.getCurrentCompositeKeyHashCode(composer, 0));
            CompositionLocalMap currentCompositionLocalMap = composer.getCurrentCompositionLocalMap();
            Modifier modifierMaterializeModifier = ComposedModifierKt.materializeModifier(composer, modifierFillMaxSize$default);
            Function0<ComposeUiNode> constructor = ComposeUiNode.INSTANCE.getConstructor();
            ComposerKt.sourceInformationMarkerStart(composer, -553112988, "CC(ReusableComposeNode)N(factory,update,content)399@15590L9:Composables.kt#9igjgp");
            if (!(composer.getApplier() instanceof Applier)) {
                ComposablesKt.invalidApplier();
            }
            composer.startReusableNode();
            if (composer.getInserting()) {
                composer.createNode(constructor);
            } else {
                composer.useNode();
            }
            Composer composerM3820constructorimpl = Updater.m3820constructorimpl(composer);
            Updater.m3827setimpl(composerM3820constructorimpl, measurePolicyMaybeCachedBoxMeasurePolicy, ComposeUiNode.INSTANCE.getSetMeasurePolicy());
            Updater.m3827setimpl(composerM3820constructorimpl, currentCompositionLocalMap, ComposeUiNode.INSTANCE.getSetResolvedCompositionLocals());
            Function2<ComposeUiNode, Integer, Unit> setCompositeKeyHash = ComposeUiNode.INSTANCE.getSetCompositeKeyHash();
            if (composerM3820constructorimpl.getInserting() || !Intrinsics.areEqual(composerM3820constructorimpl.rememberedValue(), Integer.valueOf(iHashCode))) {
                composerM3820constructorimpl.updateRememberedValue(Integer.valueOf(iHashCode));
                composerM3820constructorimpl.apply(Integer.valueOf(iHashCode), setCompositeKeyHash);
            }
            Updater.m3827setimpl(composerM3820constructorimpl, modifierMaterializeModifier, ComposeUiNode.INSTANCE.getSetModifier());
            ComposerKt.sourceInformationMarkerStart(composer, 1833054614, "C72@3469L9:Box.kt#2w3rfo");
            BoxScopeInstance boxScopeInstance = BoxScopeInstance.INSTANCE;
            if (pricesState.isLoading()) {
                composer.startReplaceGroup(-719873740);
                LoadingScreenKt.LoadingScreen(composer, 0);
                composer.endReplaceGroup();
            } else if (pricesState.isError()) {
                composer.startReplaceGroup(-719784491);
                composer.startReplaceGroup(5004770);
                boolean zChangedInstance = composer.changedInstance(pricesViewModel);
                Object objRememberedValue = composer.rememberedValue();
                if (zChangedInstance || objRememberedValue == Composer.INSTANCE.getEmpty()) {
                    objRememberedValue = new Function0() { // from class: com.sistemasolton.itranvias.home.presentation.prices.PricesScreenKt$PricesScreen$2$$ExternalSyntheticLambda0
                        @Override // kotlin.jvm.functions.Function0
                        public final Object invoke() {
                            return PricesScreenKt.AnonymousClass2.invoke$lambda$2$lambda$1$lambda$0(pricesViewModel);
                        }
                    };
                    composer.updateRememberedValue(objRememberedValue);
                }
                composer.endReplaceGroup();
                ConnectionErrorScreenKt.ConnectionErrorScreen(null, (Function0) objRememberedValue, composer, 0, 1);
                composer.endReplaceGroup();
            } else if (pricesState.getInfoDto() != null) {
                composer.startReplaceGroup(-719657918);
                PricesScreenKt.TariffsList(pricesState.getInfoDto(), composer, 0);
                composer.endReplaceGroup();
            } else {
                composer.startReplaceGroup(-719573877);
                composer.endReplaceGroup();
            }
            ComposerKt.sourceInformationMarkerEnd(composer);
            composer.endNode();
            ComposerKt.sourceInformationMarkerEnd(composer);
            ComposerKt.sourceInformationMarkerEnd(composer);
            ComposerKt.sourceInformationMarkerEnd(composer);
            if (ComposerKt.isTraceInProgress()) {
                ComposerKt.traceEventEnd();
            }
        }
    }

    public static final void TariffsList(final InfoDto info, Composer composer, final int i) {
        int i2;
        Composer composer2;
        Intrinsics.checkNotNullParameter(info, "info");
        Composer composerStartRestartGroup = composer.startRestartGroup(-1940316998);
        if ((i & 6) == 0) {
            i2 = (composerStartRestartGroup.changedInstance(info) ? 4 : 2) | i;
        } else {
            i2 = i;
        }
        if ((i2 & 3) != 2 || !composerStartRestartGroup.getSkipping()) {
            if (ComposerKt.isTraceInProgress()) {
                ComposerKt.traceEventStart(-1940316998, i2, -1, "com.sistemasolton.itranvias.home.presentation.prices.TariffsList (PricesScreen.kt:123)");
            }
            final List<TarifaDto> tarifas = info.getITranvias().getActualizacion().getPrecios().getTarifas();
            final List<String> observaciones = info.getITranvias().getActualizacion().getPrecios().getObservaciones();
            final String strStringResource = StringResourcesKt.stringResource(String0_commonMainKt.getObservations_title(Res.string.INSTANCE), composerStartRestartGroup, 0);
            Modifier modifierM832padding3ABfNKs = PaddingKt.m832padding3ABfNKs(SizeKt.fillMaxSize$default(Modifier.INSTANCE, 0.0f, 1, null), Dp.m7215constructorimpl(16));
            composerStartRestartGroup.startReplaceGroup(1849434622);
            Object objRememberedValue = composerStartRestartGroup.rememberedValue();
            if (objRememberedValue == Composer.INSTANCE.getEmpty()) {
                objRememberedValue = new Function1() { // from class: com.sistemasolton.itranvias.home.presentation.prices.PricesScreenKt$$ExternalSyntheticLambda0
                    @Override // kotlin.jvm.functions.Function1
                    public final Object invoke(Object obj) {
                        return PricesScreenKt.TariffsList$lambda$5$lambda$4((SemanticsPropertyReceiver) obj);
                    }
                };
                composerStartRestartGroup.updateRememberedValue(objRememberedValue);
            }
            composerStartRestartGroup.endReplaceGroup();
            Modifier modifierSemantics$default = SemanticsModifierKt.semantics$default(modifierM832padding3ABfNKs, false, (Function1) objRememberedValue, 1, null);
            Arrangement.HorizontalOrVertical horizontalOrVerticalM691spacedBy0680j_4 = Arrangement.INSTANCE.m691spacedBy0680j_4(Dp.m7215constructorimpl(12));
            composerStartRestartGroup.startReplaceGroup(-1746271574);
            boolean zChangedInstance = composerStartRestartGroup.changedInstance(tarifas) | composerStartRestartGroup.changedInstance(observaciones) | composerStartRestartGroup.changed(strStringResource);
            Object objRememberedValue2 = composerStartRestartGroup.rememberedValue();
            if (zChangedInstance || objRememberedValue2 == Composer.INSTANCE.getEmpty()) {
                objRememberedValue2 = new Function1() { // from class: com.sistemasolton.itranvias.home.presentation.prices.PricesScreenKt$$ExternalSyntheticLambda1
                    @Override // kotlin.jvm.functions.Function1
                    public final Object invoke(Object obj) {
                        return PricesScreenKt.TariffsList$lambda$7$lambda$6(observaciones, tarifas, strStringResource, (LazyListScope) obj);
                    }
                };
                composerStartRestartGroup.updateRememberedValue(objRememberedValue2);
            }
            composerStartRestartGroup.endReplaceGroup();
            composer2 = composerStartRestartGroup;
            LazyDslKt.LazyColumn(modifierSemantics$default, null, null, false, horizontalOrVerticalM691spacedBy0680j_4, null, null, false, null, (Function1) objRememberedValue2, composerStartRestartGroup, 24576, 494);
            if (ComposerKt.isTraceInProgress()) {
                ComposerKt.traceEventEnd();
            }
        } else {
            composerStartRestartGroup.skipToGroupEnd();
            composer2 = composerStartRestartGroup;
        }
        ScopeUpdateScope scopeUpdateScopeEndRestartGroup = composer2.endRestartGroup();
        if (scopeUpdateScopeEndRestartGroup != null) {
            scopeUpdateScopeEndRestartGroup.updateScope(new Function2() { // from class: com.sistemasolton.itranvias.home.presentation.prices.PricesScreenKt$$ExternalSyntheticLambda2
                @Override // kotlin.jvm.functions.Function2
                public final Object invoke(Object obj, Object obj2) {
                    return PricesScreenKt.TariffsList$lambda$8(info, i, (Composer) obj, ((Integer) obj2).intValue());
                }
            });
        }
    }

    /* JADX INFO: Access modifiers changed from: private */
    public static final Unit TariffsList$lambda$5$lambda$4(SemanticsPropertyReceiver semantics) {
        Intrinsics.checkNotNullParameter(semantics, "$this$semantics");
        SemanticsPropertiesKt.setContentDescription(semantics, "Lista de tarifas y observaciones");
        return Unit.INSTANCE;
    }

    /* JADX INFO: Access modifiers changed from: private */
    public static final Unit TariffsList$lambda$7$lambda$6(List list, List list2, String str, LazyListScope LazyColumn) {
        Intrinsics.checkNotNullParameter(LazyColumn, "$this$LazyColumn");
        LazyListScope.item$default(LazyColumn, null, null, ComposableLambdaKt.composableLambdaInstance(357081605, true, new PricesScreenKt$TariffsList$2$1$1(list2)), 3, null);
        if (!list.isEmpty()) {
            LazyListScope.item$default(LazyColumn, null, null, ComposableLambdaKt.composableLambdaInstance(-1565107830, true, new PricesScreenKt$TariffsList$2$1$2(str, list)), 3, null);
        }
        return Unit.INSTANCE;
    }

    public static final String toEuroFormat(double d) {
        StringBuilder sbAppend;
        double d2 = 100;
        double d3 = ((double) ((int) (d * d2))) / 100.0d;
        int i = (int) d3;
        int i2 = (int) ((d3 - ((double) i)) * d2);
        if (i2 == 0) {
            sbAppend = new StringBuilder().append(i);
        } else {
            sbAppend = new StringBuilder().append(i).append(",").append(StringsKt.padStart(String.valueOf(i2), 2, '0'));
        }
        return sbAppend.append(" €").toString();
    }

    private static final String PricesScreen$lambda$0(State<String> state) {
        return state.getValue();
    }
}