Installation
npx shadcn@latest add @iconiq/date-pickerProps
DatePicker
Collapsible date field with a formatted trigger button and the shared Iconiq Calendar panel underneath.
valueDate | nullplaceholderstringDefault Select a date
onChange(date: Date) => voidclassNamestringdefaultOpenbooleanDefault false
calendarPropsOmit<CalendarProps, 'selected' | 'defaultSelected' | 'onSelect' | 'month' | 'onMonthChange'>Also exported as `AnimatedDatePicker` for backwards compatibility.
The trigger formats the selected date as `EEE, MMM d, yyyy` and toggles the panel open and closed.
Choosing a date closes the panel automatically while keeping the visible month aligned with the selected value.
Click outside or press Escape to close the panel. The embedded Calendar stays mounted after the first open to avoid repeat entrance motion.
Install the `calendar` registry entry alongside `date-picker` so `@/components/ui/calendar` resolves in consumer apps.
Registry bundle
Install the exact registry entry shown on the right when you want the component file and its declared runtime dependencies together.
Dependencies: motion, lucide-react, date-fns.
Registry dependency: calendar. Install date-picker together with the shared Calendar component.
The generated registry file is /r/date-picker.json.