Skip to main content

Calendar

Pick a day or a range of days from a month of keys.

View as Markdown

Installation

Component API

PropTypeDefaultDescription
modesingle | rangesinglePicks one day, or a range from its first day to its last.
Picks one day, or a range from its first day to its last.
defaultValueDate | DateRange-The picked day or range on first render, uncontrolled.
The picked day or range on first render, uncontrolled.
valueDate | DateRange-
onValueChange(value: Date | DateRange | undefined, day?: Date) => void-Called with the new day or range whenever it changes, and the day that was clicked.
Called with the new day or range whenever it changes, and the day that was clicked.
weekStartsOnnumber0The first day of the week, from 0 for Sunday to 6 for Saturday.
The first day of the week, from 0 for Sunday to 6 for Saturday.
startMonthDate-The earliest month to show, and the first year in the list. 100 years back by default.
The earliest month to show, and the first year in the list. 100 years back by default.
endMonthDate-The latest month to show, and the last year in the list. 10 years ahead by default.
The latest month to show, and the last year in the list. 10 years ahead by default.
slidingbooleantrue
footerbooleantrueThe line under the grid: the picked day and a Today key, or the range and its nights.
The line under the grid: the picked day and a Today key, or the range and its nights.
disabledDaysMatcher | Matcher[]-Days that cannot be picked: a date, a list of them, a range, or a function of the date.
Days that cannot be picked: a date, a list of them, a range, or a function of the date.
shapenone | rounded | pillrounded
disabledbooleanfalseBlocks picking and dims every day.
Blocks picking and dims every day.
animatedbooleantrue
classNamestring-
focusboolean | stringtrue
containerHTMLElement | null-