import { type DayPickerBase } from "https://deno.land/x/netzo@0.4.72/deps/react-day-picker.ts";
The base props for the DayPicker component and the DayPickerContext.
Properties
The CSS class to add to the container element. To change the name of the
class instead, use classNames.root
.
Change the class names of the HTML elements.
Use this prop when you need to change the default class names — for example when using CSS modules.
Change the class name for the day matching the modifiers.
Style to apply to the container element.
Change the inline styles of the HTML elements.
Change the inline style for the day matching the modifiers.
A unique id to replace the random generated id – used by DayPicker for accessibility.
The initial month to show in the calendar. Use this prop to let DayPicker control the current month. If you need to set the month programmatically, use month]] | and [[onMonthChange.
The month displayed in the calendar.
As opposed to DayPickerBase.defaultMonth, use this prop with DayPickerBase.onMonthChange to change the month programmatically.
Event fired when the user navigates between months.
The earliest day to start the month navigation.
The latest day to end the month navigation.
The earliest month to start the month navigation.
The latest month to end the month navigation.
Render the months in reversed order (when numberOfMonths is greater
than 1
) to display the most recent month first.
Display six weeks per months, regardless the month’s number of weeks. To use this prop, showOutsideDays must be set.
Show the outside days. An outside day is a day falling in the next or the previous month.
Show the week numbers column. Weeks are numbered according to the local week index.
- to use ISO week numbering, use the ISOWeek prop.
- to change how the week numbers are displayed, use the Formatters prop.
The index of the first day of the week (0 - Sunday). Overrides the locale's one.
The day of January, which is always in the first week of the year. Can be
either Monday (1
) or Thursday (4
).
Use ISO week dates instead of the locale setting. Setting this prop will ignore weekStartsOn and firstWeekContainsDate.
Map of components used to create the layout. Look at the components source to understand how internal components are built and provide your custom components.
When a selection mode is set, DayPicker will focus the first selected day (if set) or the today's date (if not disabled).
Use this prop when you need to focus DayPicker after a user actions, for improved accessibility.
The today’s date. Default is the current date. This Date will get the
today
modifier to style the day.
Add modifiers to the matching days.
The date-fns locale object used to localize dates.
Labels creators to override the defaults. Use this prop to customize the ARIA labels attributes.
A map of formatters. Use the formatters to override the default formatting functions.
The text direction of the calendar. Use ltr
for left-to-right (default)
or rtl
for right-to-left.
A cryptographic nonce ("number used once") which can be used by Content
Security Policy for the inline style
attributes.
Event callback fired when the next month button is clicked.
Event callback fired when the previous month button is clicked.
Event callback fired when the week number is clicked. Requires
showWeekNumbers
set.
Event callback fired when the user clicks on a day.
Event callback fired when the user focuses on a day.
Event callback fired when the user blurs from a day.
Event callback fired when the user hovers on a day.
Event callback fired when the user hovers away from a day.
Event callback fired when the user presses a key on a day.
Event callback fired when the user presses a key on a day.
Event callback fired when the user presses a key on a day.
Event callback fired when the pointer enters a day.
Event callback fired when the pointer leaves a day.
Event callback when a day touch event is canceled.
Event callback when a day touch event ends.
Event callback when a day touch event moves.
Event callback when a day touch event starts.