Date Picker
A typed date input paired with a calendar popover over one value, for single dates (DatePicker) or ranges (DateRangePicker). Supports month- and year-only granularity, unavailableRanges, and a non-modal popover: the input stays editable while the calendar is open, and the calendar follows what is typed.
Installation
CLI
Manual
- 1
Register the @fma-ui namespace in components.json (once)
components.json{ "registries": { "@fma-ui": "https://ui.fmartinsandre.dev.br/r/{name}.json" } } - 2
Add the item
pnpm dlx shadcn@latest add @fma-ui/date-pickerFiles land in
components/fma-ui/date-picker.tsx; npm and registry dependencies are installed along with them.
Dependencies
- npm
- @internationalized/date@^3.12.4cn@^0.4.0lucide-react@^1.52.0react-aria-components@^1.21.1
- Registry
- @fma-ui/calendar@fma-ui/date-field@fma-ui/input-group@fma-ui/popover@fma-ui/date-granularity@fma-ui/types