Props List

Here's the full list of available props:

<Calendar /> props

PropTypeDefaultDescription
valueObjectnullThe value of the date picker. if initial value is null, it's a single date picker. if it's an empty array, then it's a multiple date picker, and if its of shape { from: null, to: null}, then it's a range date picker.
onChangeFunctionnewValue => nullGets called when value of the picker changes
localeStringenLocale language of the calendar. It can be one of 'fa' or 'en'
minimumDateObjectnullSpecifies the minimum selectable day by user
maximumDateObjectnullSpecifies the maximum selectable day by user
disabledDaysArray[]An array of disabled calendar days. Disabled days won't be selectable, and they can't be included in a day range. If user tries to select/include them onDisabledDayError will be called
onDisabledDayErrorFunctiondisabledDay => nullGets called when user tries to select/include a disabled day
selectorStartingYearNumbercurrent year - 100The minimum selectable year when user opens the year selector
selectorEndingYearNumbercurrent year + 50The maximum selectable year when user opens the year selector
shouldHighlightWeekendsBooleanfalseDetermines whether to mark weekend days with red or not. (weekend days are Saturday and Sunday for locale="en" calendar and Friday for locale="fa" calendar)
renderFooterFunction() => nullRenders a footer for the calendar below the days list. You can use this prop to render a "Go to Today" button or anything you'd like to add there.
customDaysClassNameArray[]An array of custom class names for your days. Each item is an object which contains day(number), month(number), year(number), and className(string) properties. There are samples for this in Customization page of this document.
colorPrimaryString#0eca2dThe color of selected day in the single date picker and the color of range start and range end in range date picker
colorPrimaryLightString#cff4d5The color of range-between days
slideAnimationDurationString0.4sDuration of month slide animation. It can be any CSS valid time value
calendarClassNameString''Additional CSS class for the calendar element
calendarTodayClassNameString''Additional CSS class for today day
calendarSelectedDayClassNameString''Additional CSS class for the selected day
calendarRangeStartClassNameString''Additional CSS class for the range start day in the range date picker
calendarRangeBetweenClassNameString''Additional CSS class for the range-between day(s) in the range date picker
calendarRangeEndClassNameString''Additional CSS class for the range end day in the range date picker

<DatePicker /> props

PropTypeDefaultDescription
calendarPopperPositionString'auto'Calendar pooper position when clicked on the input, it can be one of 'auto' or 'top' or 'bottom'. Left/right position of the calendar will always be automatic due to screen boundaries
wrapperClassNameString''Additional CSS class for the date picker wrapper element
inputClassNameString''Additional CSS class for the date picker input element
inputPlaceholderStringانتخابPlaceholder of the picker's input
inputNameString''name of the date picker input
formatInputTextFunction() => ''If returns a true JavaScript value, the returned value of this function will be the input's value
renderInputFunction({ ref }) => nullThe returned value of this function will be the custom input element rendered for picker

Note: You can pass all <Calendar /> props via <DatePicker /> props as well.