androidx.compose.material3

DatePickerState

Interface

No hand-written docs yet.

A state object that can be hoisted to observe the date picker state. See rememberDatePickerState.

interface DatePickerState

How to get one

Create it

Ready-made values and functions that return it

Used by

Parameters that take a DatePickerState.

Properties

selectedDateMillis

val selectedDateMillis: Long?

A timestamp that represents the selected date start of the day in UTC milliseconds from the epoch.

displayedMonthMillis

val displayedMonthMillis: Long

A timestamp that represents the currently displayed month start date in UTC milliseconds from the epoch.

displayMode

val displayMode: DisplayMode

A DisplayMode that represents the current UI mode (i.e. picker or input).

yearRange

val yearRange: IntRange

An IntRange that holds the year range that the date picker will be limited to.

selectableDates

val selectableDates: SelectableDates

A SelectableDates that is consulted to check if a date is allowed.

localeSince 1.9

val locale: CalendarLocale

A locale that will be used when formatting dates, determining the input format, week-days, and more.

Library docs

A state object that can be hoisted to observe the date picker state. See rememberDatePickerState.