Skip to main content

⚙️ Date & Date-Time Picker

PropTypeDefaultDescription
valueDate | Moment | nullnullThe currently selected date.
defaultValueDate | Moment | nullnullUncontrolled selected date.
onChange(date: Date | null) => voidCallback fired when a date is selected.
minDateDate | Moment"1937-03-14"The earliest date a user can select. Dates before this are disabled.
maxDateDate | Moment"2077-10-17"The latest date a user can select. Dates after this are disabled.
disabledDates(Date | Moment)[]Array of Date objects that should be disabled in the calendar.
disabledDatesFn(date: Date) => booleanFunction to disable dates dynamically.
localestring"en"Moment.js locale (e.g. "ar", "ar-sa", "en-gb").
formatstring"YYYY/MM/DD"Specifies the format pattern used to display and interpret dates.
calendargregorian | hijri"gregorian"Specifies the calendar system used for date calculations and display.
anchorElHTMLElement | nullnullWhen in popover mode, the element to anchor the calendar to.
closeOnSelectbooleantrueDetermines whether the calendar should close immediately after a date is selected.
readOnlybooleanfalsePrevents manual input/editing but still allows interaction (e.g. calendar popover).
disabledbooleanfalseFully disables the component—no input, no interaction, and typically styled as inactive.
themelight | darklightSets the calendar's color scheme to either light or dark mode.
renderInput(props: DateFieldExtraProps) => ReactNodeA function that receives input props and returns a custom input component.
renderCalendar(props: CalendarProps) => ReactNodeA function that receives calendar props and returns a custom calendar layout.
onOpenChange(open: boolean) => voidCalled with a boolean value whenever the calendar's visibility changes.
calendarPropsCalendarPropsAn object containing props that customize the rendering and behavior of the calendar.
fieldPropsFieldPropsAn object containing props that customize the rendering and behavior of the date field.