Merge pull request #1419 from android/av/fix-state-loss-with-workaround

Fix state loss with workaround
pull/1478/head
Don Turner 7 months ago committed by GitHub
commit 8a15a61a50
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

@ -219,13 +219,14 @@ internal fun NiaApp(
} }
Box( Box(
modifier = if (shouldShowTopAppBar) { // Workaround for https://issuetracker.google.com/338478720
Modifier.consumeWindowInsets( modifier = Modifier.consumeWindowInsets(
WindowInsets.safeDrawing.only(WindowInsetsSides.Top), if (shouldShowTopAppBar) {
) WindowInsets.safeDrawing.only(WindowInsetsSides.Top)
} else { } else {
Modifier WindowInsets(0, 0, 0, 0)
}, },
),
) { ) {
NiaNavHost( NiaNavHost(
appState = appState, appState = appState,

Loading…
Cancel
Save