Eduardo Ruesta
11/14/2024, 2:15 AMEduardo Ruesta
11/14/2024, 2:17 AM@Composable
fun TabNavigatorScreen(tab: Tab, isLoggedOut: Boolean = false) {
if (!isLoggedOut) {
Surface(modifier = Modifier.fillMaxSize()) {
TabNavigator(tab) {
Scaffold(
bottomBar = {
BottomNavigation(
backgroundColor = Color.White,
elevation = 8.dp,
modifier = Modifier.navigationBarsPadding()
) {
TabNavigationItem(HomeTab)
TabNavigationItem(ResultTab)
TabNavigationItem(ProfileTab)
}
}) {
Box(
modifier = Modifier.padding(it)
) {
CurrentTab()
}
}
}
}
} else {
Scaffold(
bottomBar = {}) {
}
}
}
but the issue is the first time isLoggedOut is false and i show the bottomBar, then when is logged out the condition is true but since its already visible i can't hide itHiroki Horiguchi
11/14/2024, 2:54 AMHiroki Horiguchi
11/14/2024, 2:56 AMHiroki Horiguchi
11/14/2024, 5:01 AMNermeen
11/14/2024, 5:13 AMHiroki Horiguchi
11/14/2024, 5:48 AMEduardo Ruesta
11/14/2024, 2:21 PMEduardo Ruesta
11/15/2024, 3:29 PM