android / socialite

Apache License 2.0
346 stars 60 forks source link

Fix window insets on ChatScreen with safeContentPadding() #77

Closed cartland closed 2 months ago

cartland commented 2 months ago

The issue is more visible with 3 button navigation. The InputBar is obscured by the navigation bar. Modifier.safeContentPadding() ensures that the ChatScreen is not obscured.

cartland commented 2 months ago

Before:

0-Before

After:

1-After
calren commented 2 months ago

adding sysui expert @ashnohe

ashnohe commented 2 months ago

Thanks! Somehow this got removed from the main branch while we were working on the I/O codelabs.

This is the correct fix in ChatScreen around line 220:

InputBar(
    ...
    contentPadding = innerPadding.copy(layoutDirection, top = 0.dp), //Add this line.
    // contentPadding = innerPadding, // Remove this line.
    ...
 )
cartland commented 2 months ago

@ashnohe thanks! I updated with your suggestion.