A date picker combines a DateField and a Calendar popover to allow users to enter or select a date and time value.
Features
The DatePicker is a custom component following the DatePicker Aria Pattern. It has the following features:
- Dates & times – Choose dates, times, or both with configurable precision.
- International – 13+ calendar systems, locale formats, number systems, RTL, and hour cycles.
- Time zone aware – Handles daylight saving and time zone rules.
- Accessible – Keyboard navigation, screen reader support, and a calendar popover.
- Touch friendly – Optimized for mobile keyboards and touch screen readers.
- Validation – Works with forms, supports required/min/max, disabled dates, and custom rules.
- Customizable – Full control over DOM and styling.
Usage
TSX
import { DatePicker } from '@console/nimbus-ui/core';Examples
Granularity
Time Zones
Minimum And Maximum Values
Invalid
API
| Prop | Type | Default | Description |
|---|---|---|---|
| autoFocus | boolean | — | |
| className | string | — | |
| defaultOpen | boolean | — | |
| defaultValue | DateValue | — | |
| description | string | — | |
| errorMessage | string | ((validation: ValidationResult) => string) | — | |
| granularity | enum | — | |
| hideTimeZone | boolean | — | |
| id | string | — | |
| isDateUnavailable | (date: DateValue) => boolean | — | |
| isDisabled | boolean | — | |
| isInvalid | boolean | — | |
| isOpen | boolean | — | |
| isReadOnly | boolean | — | |
| isRequired | boolean | — | |
| label | ReactNode | — | |
| maxValue | DateValue | — | |
| minValue | DateValue | — | |
| name | string | — | |
| onChange | (value: MappedDateValue<T>) => void | — | |
| onOpenChange | (isOpen: boolean) => void | — | |
| placeholderValue | DateValue | — | |
| ref | ForwardedRef<HTMLDivElement> | — | |
| validate | (value: MappedDateValue<T>) => true | ValidationError | — | |
| value | DateValue | — |
React Aria
Figma