From 1b7631b84e443b27cfce16d749057572743cd151 Mon Sep 17 00:00:00 2001 From: hayaksi1 <193020925+hayaksi1@users.noreply.github.com> Date: Sun, 9 Aug 2026 15:09:33 +0300 Subject: [PATCH] Do not draw the media loading progress bar under the status bar The media viewer is edge to edge and the loading progress indicator was the top-most child of a container that only applied navigation bar padding, so it was laid out at y=0, behind the status bar and any display cutout. Give it safeDrawing horizontal and top padding, reusing the idiom already used by MediaViewerBottomBar in the same file. The inset deliberately does not come from the scaffold content padding, which collapses to zero when the user taps to hide the overlay. --- .../android/libraries/mediaviewer/impl/viewer/MediaViewerView.kt | 1 + 1 file changed, 1 insertion(+) diff --git a/libraries/mediaviewer/impl/src/main/kotlin/io/element/android/libraries/mediaviewer/impl/viewer/MediaViewerView.kt b/libraries/mediaviewer/impl/src/main/kotlin/io/element/android/libraries/mediaviewer/impl/viewer/MediaViewerView.kt index 6eca5e9dbc..1b12d59360 100644 --- a/libraries/mediaviewer/impl/src/main/kotlin/io/element/android/libraries/mediaviewer/impl/viewer/MediaViewerView.kt +++ b/libraries/mediaviewer/impl/src/main/kotlin/io/element/android/libraries/mediaviewer/impl/viewer/MediaViewerView.kt @@ -414,6 +414,7 @@ private fun MediaViewerPage( if (showProgress) { LinearProgressIndicator( modifier = Modifier + .padding(WindowInsets.safeDrawing.only(WindowInsetsSides.Horizontal + WindowInsetsSides.Top).asPaddingValues()) .fillMaxWidth() .height(2.dp) )