Skip to content

Date picker

A month calendar for picking one date.

Date picker Date picker

var date by remember {
    mutableStateOf<LocalDate?>(
        value = LocalDate(
            year = 2026,
            month = 3,
            day = 18,
        ),
    )
}
JengaDatePicker(
    selectedDate = date,
    onSelectedDateChange = { date = it },
    monthTitle = { yearMonth ->
        val monthName = yearMonth.month.name.lowercase().replaceFirstChar(
            transform = Char::uppercase,
        )
        "$monthName ${yearMonth.year}"
    },
    dayOfWeekLabel = {
        it.name.take(
            n = 2,
        ).lowercase().replaceFirstChar(
            transform = Char::uppercase,
        )
    },
    previousMonthContentDescription = "Previous month",
    nextMonthContentDescription = "Next month",
)