Object

ModalBottomSheetDefaults

Default values for ModalBottomSheet

Source set: Common
@ExperimentalMaterial3Api
expect object ModalBottomSheetDefaults

Default values for ModalBottomSheet

Properties

properties

Source set: Common
val properties: ModalBottomSheetProperties

Properties used to customize the behavior of a ModalBottomSheet.

Source set: Android
@ExperimentalMaterial3Api
actual object ModalBottomSheetDefaults

Default values for ModalBottomSheet

Properties

properties

Source set: Android
actual val properties = ModalBottomSheetProperties()

Properties used to customize the behavior of a ModalBottomSheet.

Functions

properties

fun properties(
        securePolicy: SecureFlagPolicy = SecureFlagPolicy.Inherit,
        isFocusable: Boolean = true,
        shouldDismissOnBackPress: Boolean = true,
    ) =
        ModalBottomSheetProperties(
            securePolicy = securePolicy,
            shouldDismissOnBackPress = shouldDismissOnBackPress,
        )

Properties used to customize the behavior of a ModalBottomSheet.

Parameters

securePolicy Policy for setting WindowManager.LayoutParams.FLAG_SECURE on the bottom sheet's window.
isFocusable Whether the modal bottom sheet is focusable. When true, the modal bottom sheet will receive IME events and key presses, such as when the back button is pressed.
shouldDismissOnBackPress Whether the modal bottom sheet can be dismissed by pressing the back button. If true, pressing the back button will call onDismissRequest. Note that isFocusable must be set to true in order to receive key events such as the back button - if the modal bottom sheet is not focusable then this property does nothing.

Last updated: