Skip to content

Instantly share code, notes, and snippets.

@skydoves
Created Jun 27, 2022
Embed
What would you like to do?
adaptive_layout
Scaffold(
modifier = Modifier,
containerColor = Color.Transparent,
bottomBar = {
if (windowSizeClass.widthSizeClass == WindowWidthSizeClass.Compact) {
NiABottomBar(
onNavigateToTopLevelDestination = niaTopLevelNavigation::navigateTo,
currentDestination = currentDestination
)
}
}
) { padding -> {
..
if (windowSizeClass.widthSizeClass != WindowWidthSizeClass.Compact) {
NiANavRail(
onNavigateToTopLevelDestination = niaTopLevelNavigation::navigateTo,
currentDestination = currentDestination,
modifier = Modifier.safeDrawingPadding()
)
}
..
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment