Browse Source

Fix top padding in room list when app is opened in offline mode (#1299)

* Fix top padding in room list when app is opened in offline mode

* Fix `avatarBloom` not passing the `bottomSoftEdgeColor` to `bloom`
pull/1319/head
Jorge Martin Espinosa 1 year ago committed by GitHub
parent
commit
4bf439d5ec
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 1
      changelog.d/1297.bugfix
  2. 4
      features/networkmonitor/api/src/main/kotlin/io/element/android/features/networkmonitor/api/ui/ConnectivityIndicatorView.kt
  3. 1
      libraries/designsystem/src/main/kotlin/io/element/android/libraries/designsystem/components/Bloom.kt

1
changelog.d/1297.bugfix

@ -0,0 +1 @@ @@ -0,0 +1 @@
Fix top padding in room list when app is opened in offline mode.

4
features/networkmonitor/api/src/main/kotlin/io/element/android/features/networkmonitor/api/ui/ConnectivityIndicatorView.kt

@ -109,7 +109,9 @@ fun ConnectivityIndicatorContainer( @@ -109,7 +109,9 @@ fun ConnectivityIndicatorContainer(
} else {
WindowInsets.statusBars.asPaddingValues().calculateTopPadding() + 6.dp
}
val target = remember(isOnline) { if (isOnline) 0.dp else statusBarTopPadding }
val target = remember(isIndicatorVisible.targetState, statusBarTopPadding) {
if (!isIndicatorVisible.targetState) 0.dp else statusBarTopPadding
}
val animationStateOffset by animateDpAsState(
targetValue = target,
animationSpec = spring(

1
libraries/designsystem/src/main/kotlin/io/element/android/libraries/designsystem/components/Bloom.kt

@ -363,6 +363,7 @@ fun Modifier.avatarBloom( @@ -363,6 +363,7 @@ fun Modifier.avatarBloom(
blurSize = blurSize,
offset = offset,
clipToSize = clipToSize,
bottomSoftEdgeColor = bottomSoftEdgeColor,
bottomSoftEdgeHeight = bottomSoftEdgeHeight,
bottomSoftEdgeAlpha = bottomSoftEdgeAlpha,
alpha = alpha,

Loading…
Cancel
Save