—
Uncontrolled picker
—
Controlled picker
—
Responsiveness
The date range picker component is designed to be optimized for the device it runs on.
- The
MobileNextDateRangePicker
component works best for touch devices and small screens. - The
DesktopNextDateRangePicker
component works best for mouse devices and large screens.
By default, the NextDateRangePicker
component renders the desktop version if the media query @media (pointer: fine)
matches.
This can be customized with the desktopModeMediaQuery
prop.
There are certain caveats when testing pickers, please refer to this section for more information.
For mobile
—
For desktop
—
Responsive
—
Static mode
It is also possible to render any date range picker without the modal/popover and text field. This will enable building custom popover/modal containers.
disabled
—
readOnly
—
Validation
You can find the documentation in the Validation page
Different number of months
Note that the calendars
prop only works in desktop mode.
1 calendar
—
2 calendars
—
3 calendars
—
Custom input component
You can customize the rendering of the input with the Input
component slot.
Make sure to spread inputProps
correctly to the custom input component.
—
Customized day rendering
The displayed days are customizable with the Day
component slot.
You can take advantage of the internal DateRangePickerDay component.
🚧 Pre-defined range shortcuts
Range shortcuts allows your users to select a commonly-used range in one click (eg: last week, last month, …)
🚧 Month range Picker
Month range picker allows setting date ranges by picking months only.