From 6c3743a3da9c338e6e6bccadcb70afdd04acda7b Mon Sep 17 00:00:00 2001 From: Yuri Schimke Date: Mon, 6 Nov 2023 12:27:47 +1000 Subject: [PATCH 1/3] Change responsive to work better on Square devices --- .../horologist/compose/layout/ScalingLazyColumnDefaults.kt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/compose-layout/src/main/java/com/google/android/horologist/compose/layout/ScalingLazyColumnDefaults.kt b/compose-layout/src/main/java/com/google/android/horologist/compose/layout/ScalingLazyColumnDefaults.kt index 0254b105a2..9e36e3048c 100644 --- a/compose-layout/src/main/java/com/google/android/horologist/compose/layout/ScalingLazyColumnDefaults.kt +++ b/compose-layout/src/main/java/com/google/android/horologist/compose/layout/ScalingLazyColumnDefaults.kt @@ -166,7 +166,7 @@ public object ScalingLazyColumnDefaults { val screenWidthDp = configuration.screenWidthDp.toFloat() val screenHeightDp = configuration.screenHeightDp.toFloat() val padding = screenWidthDp * horizontalPaddingPercent - val topPaddingDp: Dp = if (firstItemIsFullWidth) { + val topPaddingDp: Dp = if (configuration.isScreenRound && firstItemIsFullWidth) { calculateVerticalOffsetForChip(screenWidthDp, horizontalPaddingPercent) } else { 32.dp From 51b70c77630dced8fc4d4d56b81609c724a9c88b Mon Sep 17 00:00:00 2001 From: yschimke Date: Mon, 6 Nov 2023 03:15:18 +0000 Subject: [PATCH 2/3] =?UTF-8?q?=F0=9F=A4=96=20Updates=20screenshots?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- ...ownloadBrowseScreenA11yTallScreenshotTest_browseScreen.png | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/media/ui/src/test/snapshots/images/com.google.android.horologist.media.ui.screens.browse_PlaylistDownloadBrowseScreenA11yTallScreenshotTest_browseScreen.png b/media/ui/src/test/snapshots/images/com.google.android.horologist.media.ui.screens.browse_PlaylistDownloadBrowseScreenA11yTallScreenshotTest_browseScreen.png index 4252fcde90..a4e93f37e5 100644 --- a/media/ui/src/test/snapshots/images/com.google.android.horologist.media.ui.screens.browse_PlaylistDownloadBrowseScreenA11yTallScreenshotTest_browseScreen.png +++ b/media/ui/src/test/snapshots/images/com.google.android.horologist.media.ui.screens.browse_PlaylistDownloadBrowseScreenA11yTallScreenshotTest_browseScreen.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:f784f1abdcba844532595bf464a0bcefbd829cf90d9ba6b4a76319d04b15708f -size 34878 +oid sha256:9ba10001fce917d4ba44652b67833e9ba7e9b9a910da501dff0f3fa7b71dd533 +size 34938 From 7b7cc12935ba34d5532f6967c48c1ed97ce6f8d7 Mon Sep 17 00:00:00 2001 From: Yuri Schimke Date: Mon, 6 Nov 2023 13:38:28 +1000 Subject: [PATCH 3/3] Update ScalingLazyColumnDefaults.kt --- .../horologist/compose/layout/ScalingLazyColumnDefaults.kt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/compose-layout/src/main/java/com/google/android/horologist/compose/layout/ScalingLazyColumnDefaults.kt b/compose-layout/src/main/java/com/google/android/horologist/compose/layout/ScalingLazyColumnDefaults.kt index 9e36e3048c..01be8faff3 100644 --- a/compose-layout/src/main/java/com/google/android/horologist/compose/layout/ScalingLazyColumnDefaults.kt +++ b/compose-layout/src/main/java/com/google/android/horologist/compose/layout/ScalingLazyColumnDefaults.kt @@ -166,7 +166,7 @@ public object ScalingLazyColumnDefaults { val screenWidthDp = configuration.screenWidthDp.toFloat() val screenHeightDp = configuration.screenHeightDp.toFloat() val padding = screenWidthDp * horizontalPaddingPercent - val topPaddingDp: Dp = if (configuration.isScreenRound && firstItemIsFullWidth) { + val topPaddingDp: Dp = if (firstItemIsFullWidth && configuration.isScreenRound) { calculateVerticalOffsetForChip(screenWidthDp, horizontalPaddingPercent) } else { 32.dp