Skip to content

Commit

Permalink
Fix state loss with workaround
Browse files Browse the repository at this point in the history
Change-Id: I96025bd8b2f4f59019df95d1391b832249e7dc91
  • Loading branch information
alexvanyo committed May 6, 2024
1 parent 3dd4240 commit a324fcc
Showing 1 changed file with 7 additions and 7 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -201,13 +201,13 @@ internal fun NiaApp(
}

Box(
modifier = if (shouldShowTopAppBar) {
Modifier.consumeWindowInsets(
WindowInsets.safeDrawing.only(WindowInsetsSides.Top),
)
} else {
Modifier
},
modifier = Modifier.consumeWindowInsets(
if (shouldShowTopAppBar) {
WindowInsets.safeDrawing.only(WindowInsetsSides.Top)
} else {
WindowInsets(0, 0, 0, 0)
},
),
) {
NiaNavHost(
appState = appState,
Expand Down

0 comments on commit a324fcc

Please sign in to comment.