NepaliDatePickerFullScreenDialog

fun NepaliDatePickerFullScreenDialog(onDismissRequest: () -> Unit, confirmButton: @Composable () -> Unit, modifier: Modifier = Modifier, dismissButton: @Composable () -> Unit? = null, title: @Composable () -> Unit? = null, colors: NepaliDatePickerColors = NepaliDatePickerDefaults.colors(), properties: DialogProperties = DialogProperties(usePlatformDefaultWidth = false), content: @Composable ColumnScope.() -> Unit)(source)

A full-screen dialog host for the Nepali date/range pickers.

Where NepaliDatePickerDialog is a centered modal with a fixed width, this fills the whole screen

  • the Material 3 pattern that fits a range selection on a phone, or any picker on a small screen where the 360dp modal would be cramped. The top bar carries the dismiss and confirm slots; the picker goes in content and takes the remaining height (its own month list scrolls inside).

Parameters

onDismissRequest

called when the user dismisses the dialog (back press / scrim).

confirmButton

the confirm action shown at the end of the top bar (e.g. an OK button).

modifier

the Modifier applied to the full-screen surface.

dismissButton

the optional dismiss action shown at the start of the top bar.

title

an optional centered title in the top bar.

colors

the NepaliDatePickerColors used for the surface and divider.

properties

the DialogProperties; defaults to non-platform width so the surface fills the screen.

content

the picker to host - typically NepaliDatePicker, NepaliDateRangePicker, or an English-date variant. Receives a ColumnScope.

Example usage:

if (showDialog) {
NepaliDatePickerFullScreenDialog(
onDismissRequest = { showDialog = false },
confirmButton = { NepaliDatePickerDefaults.DialogButton("OK", { showDialog = false }) },
dismissButton = { NepaliDatePickerDefaults.DialogButton("Cancel", { showDialog = false }) }
) {
NepaliDateRangePicker(state = rangeState, showMonthsVertically = true)
}
}

See also