I’m trying to add a force update screen to my app that imitates a bottom sheet. The force update flow has a separate NavGraphBuilder, so I show it like this:
LaunchedEffect(uiState.isNewUpdateRequired, uiState.showState) { Timber.tag("ForceUpdate").d("uiState changed to: $uiState") if (uiState.isNewUpdateRequired && uiState.showState == NewUpdateSheetState.Show) { navigate(Graph.ForceUpdate) { popUpTo(0) { inclusive = true } launchSingleTop = true } } }
This displays my ForceUpdateScreen correctly, but while the new screen is sliding up with slideInVertically, I can still see the exitTransition of the previous screen, which does not fit this behavior at all.
What I want is for the new screen to slide over the previous one.
I found that solution but I'm looking for something a bit cleaner:
composable<Route.LoginAuth>( exitTransition = { if(forceUpdateManager.isForceUpdateVisible){ ExitTransition.None } else { exitTransition() }},