Date picker
Accepts a date that you type or select from a calendar popover.
Appointment date
6152026
date-picker-demo.tsx
Installation
The CLI adds the files, packages, theme variables, and Tailwind plugin that this component uses. Before you run it, set up your project.
npm
yarn
pnpm
bun
Presets
Due date
mmddyyyy
date-picker-presets-demo.tsx
Disabled
Contract start
612026
date-picker-disabled-demo.tsx
Controlled value
Delivery date
6152026
date-picker-controlled-demo.tsx
Sizes
6152026
date-picker-sizes-demo.tsx
API reference
vip/ui adds or changes the props below. For all other props, see React Aria DatePicker (opens in a new tab).
- size: "xs" | "sm" | "md" | "lg" | "xl" = "lg"
- Sets the size of the field and of the calendar button.
- presets: DatePickerPreset[]
- Shortcuts beside the calendar, such as Today. Each has a label and a value. A preset sets the value and closes the calendar.
- label: string
- Label above the field. Without a label, pass aria-label.
- description: string
- Help text below the field.