KwikDatePickerDialog

fun KwikDatePickerDialog(title: String = "Select date", confirmText: String = "Confirm", cancelText: String = "Cancel", minSelectableDate: Long? = null, maxSelectableDate: Long? = null, onDateSelected: (LocalDate) -> Unit, showModeToggle: Boolean = false, confirmOnSelection: Boolean = true, colors: DatePickerColors = kwikDatePickerColors(), shape: Shape = MaterialTheme.shapes.medium, onDismiss: () -> Unit)

A date picker dialog that allows the user to select a date range.

Parameters

title

: The title of the dialog.

confirmText

: The text for the confirm button.

cancelText

: The text for the cancel button.

minSelectableDate

: The minimum selectable date in milliseconds since epoch. If null, 99 years before today is used.

maxSelectableDate

: The maximum selectable date in milliseconds since epoch. If null, 99 years from today is used.

onDateSelected

: Callback that is called when a date range is selected. The Pair contains the start and end dates.

showModeToggle

: Whether to show the mode toggle button.

confirmOnSelection

: Whether to confirm the selection on date selection.

colors

: The colors to use for the date picker.

onDismiss

: Callback that is called when the dialog is dismissed.