datepicker

@Composable
fun MaterialDialogScope.datepicker(initialDate: LocalDate = LocalDate.now(), title: String = "SELECT DATE", colors: DatePickerColors = DatePickerDefaults.colors(), yearRange: IntRange = IntRange(1900, 2100), waitForPositiveButton: Boolean = true, onDateChange: (LocalDate) -> Unit = {})

Parameters

initialDate

time to be shown to the user when the dialog is first shown. Defaults to the current date if this is not set

yearRange

the range of years the user should be allowed to pick from

waitForPositiveButton

if true the onDateChange callback will only be called when the positive button is pressed, otherwise it will be called on every input change

onDateChange

callback with a LocalDateTime object when the user completes their input