Constrain reader sheet to max 75% of height

This commit is contained in:
arkon
2023-07-16 09:59:17 -04:00
parent 22c6dbda3f
commit a3a3f44056
4 changed files with 41 additions and 28 deletions

View File

@ -56,6 +56,7 @@ private val sheetAnimationSpec = tween<Float>(durationMillis = 350)
@Composable
fun AdaptiveSheet(
modifier: Modifier = Modifier,
isTabletUi: Boolean,
tonalElevation: Dp,
enableSwipeDismiss: Boolean,
@ -97,7 +98,8 @@ fun AdaptiveSheet(
onClick = {},
)
.systemBarsPadding()
.padding(vertical = 16.dp),
.padding(vertical = 16.dp)
.then(modifier),
shape = MaterialTheme.shapes.extraLarge,
tonalElevation = tonalElevation,
content = {
@ -160,6 +162,7 @@ fun AdaptiveSheet(
Modifier
},
)
.then(modifier)
.offset {
IntOffset(
0,