ui: haromize bottom sheet radii w/cover radii

This commit is contained in:
Alexander Capehart 2024-10-22 21:57:14 -06:00
parent bd685f1f9c
commit 97b0a8aa68
No known key found for this signature in database
GPG key ID: 37DBE3621FE9AD47
3 changed files with 12 additions and 3 deletions

View file

@ -48,7 +48,7 @@ class PlaybackBottomSheetBehavior<V : View>(context: Context, attributeSet: Attr
shapeAppearanceModel =
ShapeAppearanceModel.builder(
context,
MR.style.ShapeAppearance_Material3_Corner_ExtraLarge,
R.style.ShapeAppearance_Auxio_BottomSheet,
MR.style.ShapeAppearanceOverlay_Material3_Corner_Top)
.build()
}

View file

@ -72,7 +72,7 @@ class QueueBottomSheetBehavior<V : View>(context: Context, attributeSet: Attribu
shapeAppearanceModel =
ShapeAppearanceModel.builder(
context,
MR.style.ShapeAppearance_Material3_Corner_ExtraLarge,
R.style.ShapeAppearance_Auxio_BottomSheet,
MR.style.ShapeAppearanceOverlay_Material3_Corner_Top)
.build()
}

View file

@ -37,10 +37,15 @@
<item name="marginRightSystemWindowInsets">false</item>
<item name="paddingBottomSystemWindowInsets">false</item>
<item name="paddingTopSystemWindowInsets">false</item>
<item name="shapeAppearance">@style/ShapeAppearance.Material3.Corner.None</item>
<item name="shapeAppearance">@style/ShapeAppearance.Auxio.BottomSheet</item>
<item name="shouldRemoveExpandedCorners">true</item>
</style>
<style name="ShapeAppearance.Auxio.BottomSheet" parent="ShapeAppearance.Material3.Corner.ExtraLarge">
<!-- This is really badly off-spec, but is needed to nicely harmonize the corner radii in the playback bar -->
<item name="cornerSize">20dp</item>
</style>
<style name="Widget.Auxio.BottomSheet.Modal" parent="Widget.Material3.BottomSheet.Modal">
<item name="marginLeftSystemWindowInsets">false</item>
<item name="marginRightSystemWindowInsets">false</item>
@ -63,6 +68,10 @@
<item name="android:paddingBottom">0dp</item>
</style>
<style name="ShapeAppearance.Auxio.PlaybackBarCover" parent="">
<item name="cornerSize">20dp</item>
</style>
<style name="Widget.Auxio.Image.Small" parent="">
<item name="android:layout_width">@dimen/size_touchable_small</item>
<item name="android:layout_height">@dimen/size_touchable_small</item>