mirror of
https://github.com/Novaloop-AG/element-x-android.git
synced 2026-11-02 12:07:28 +00:00
Bottom sheet: initial state must be Hidden else there is no animation when opening the bottom sheet.
This commit is contained in:
+1
-1
@@ -111,7 +111,7 @@ fun ActionListView(
|
||||
modifier: Modifier = Modifier,
|
||||
) {
|
||||
val sheetState = rememberBottomSheetState(
|
||||
initialValue = SheetValue.Expanded,
|
||||
initialValue = SheetValue.Hidden,
|
||||
)
|
||||
val coroutineScope = rememberCoroutineScope()
|
||||
val targetItem = (state.target as? ActionListState.Target.Success)?.event
|
||||
|
||||
+1
-1
@@ -45,7 +45,7 @@ fun ResolveVerifiedUserSendFailureView(
|
||||
modifier: Modifier = Modifier,
|
||||
) {
|
||||
val sheetState = rememberBottomSheetState(
|
||||
initialValue = SheetValue.Expanded,
|
||||
initialValue = SheetValue.Hidden,
|
||||
enabledValues = setOf(SheetValue.Hidden, SheetValue.Expanded),
|
||||
)
|
||||
var showSheet by remember { mutableStateOf(false) }
|
||||
|
||||
+1
-1
@@ -74,7 +74,7 @@ internal fun AttachmentsBottomSheet(
|
||||
ModalBottomSheet(
|
||||
modifier = modifier,
|
||||
sheetState = rememberBottomSheetState(
|
||||
initialValue = SheetValue.Expanded,
|
||||
initialValue = SheetValue.Hidden,
|
||||
enabledValues = setOf(SheetValue.Hidden, SheetValue.Expanded),
|
||||
),
|
||||
onDismissRequest = { isVisible = false },
|
||||
|
||||
+1
-1
@@ -32,7 +32,7 @@ fun CustomReactionBottomSheet(
|
||||
modifier: Modifier = Modifier,
|
||||
) {
|
||||
val sheetState = rememberBottomSheetState(
|
||||
initialValue = SheetValue.Expanded,
|
||||
initialValue = SheetValue.Hidden,
|
||||
)
|
||||
val coroutineScope = rememberCoroutineScope()
|
||||
val target = state.target as? CustomReactionState.Target.Success
|
||||
|
||||
+1
-1
@@ -46,7 +46,7 @@ internal fun ReadReceiptBottomSheet(
|
||||
val isVisible = state.selectedEvent != null
|
||||
|
||||
val sheetState = rememberBottomSheetState(
|
||||
initialValue = SheetValue.Expanded,
|
||||
initialValue = SheetValue.Hidden,
|
||||
)
|
||||
val coroutineScope = rememberCoroutineScope()
|
||||
if (isVisible) {
|
||||
|
||||
Reference in New Issue
Block a user