Simplifying a question I asked earlier:
I need a modal bottom sheet that is only ever HIDDEN or EXPANDED. I never want it to be in a half-expanded state. Is that possible when using
ModalBottomSheetLayout
?
t
Tin Tran
11/10/2021, 4:14 AM
I think you can use
confirmStateChange
and reject if the status change to
HalfExpanded
. Once you do that the user have to swipe longer distance to close the bottom sheet.
Another way is to extend the
ModalBottomSheetState
and set is
isHalfExpandedEnabled
to false
c
Colton Idle
11/10/2021, 5:32 AM
This might be a dumb question... but by "extend" ModalBottomSheetState, how would you do that?
Colton Idle
11/10/2021, 5:35 AM
I tried this too for your first suggestion, but not really sure how to use that api.