A custom shadcn/ui component registry for distributing high-quality, reusable React components built with TypeScript, Tailwind CSS v4, and Radix UI primitives.
Install components directly using the shadcn CLI:
npx shadcn@latest add https://ui.clocket.io/r/date-range-picker.jsonOr add the registry to your project:
npx shadcn@latest add --registry https://ui.clocket.ioA comprehensive, accessible date range picker component with:
- Predefined ranges (Today, Yesterday, Last 7 days, etc.)
- Custom range selection with calendar interface
- Business-friendly ranges (This Week, Last 90 Days, This Year)
- Date constraints (min/max date support)
- Flexible layout options (single/dual month view)
- Full accessibility support with ARIA labels
- TypeScript support with proper type definitions
Features:
- 🎯 Highly configurable - 15+ props for customization
- ♿ Fully accessible - ARIA compliant with keyboard navigation
- 🎨 Consistent styling - Built with Tailwind CSS and Radix UI
- 📱 Responsive design - Works on all screen sizes
- ⚡ Performance optimized - Memoized components and callbacks
- 🔧 Developer friendly - TypeScript support and clear API
- React 18+
- Next.js 13+ (for App Router support)
- Tailwind CSS v4
- TypeScript (recommended)
# Install the date range picker
npx shadcn@latest add https://ui.clocket.io/r/date-range-picker.json
# Or install from registry
npx shadcn@latest add date-range-picker --registry https://ui.clocket.io- Install dependencies:
npm install date-fns react-day-picker lucide-react- Add required shadcn/ui components:
npx shadcn@latest add button calendar popover scroll-area select- Copy the component files from this registry.
import { DateRangePicker } from "@/components/ui/date-range-picker";
import { DateRange } from "react-day-picker";
import { useState } from "react";
function MyComponent() {
const [dateRange, setDateRange] = useState<DateRange | undefined>();
return (
<DateRangePicker
value={dateRange}
onChange={setDateRange}
placeholder="Select date range..."
buttonWidth="w-full sm:w-[300px]"
/>
);
}import {
DateRangePicker,
PredefinedRange,
} from "@/components/ui/date-range-picker";
import { subDays, startOfWeek, endOfWeek } from "date-fns";
const customRanges: PredefinedRange[] = [
{
label: "This Week",
value: {
from: startOfWeek(new Date(), { weekStartsOn: 1 }),
to: endOfWeek(new Date(), { weekStartsOn: 1 }),
},
description: "Current week (Monday to Sunday)",
},
{
label: "Last 30 Days",
value: { from: subDays(new Date(), 29), to: new Date() },
description: "Previous 30 days",
},
];
function AdvancedExample() {
const [dateRange, setDateRange] = useState<DateRange | undefined>();
return (
<DateRangePicker
value={dateRange}
onChange={setDateRange}
predefinedRanges={customRanges}
applyOnPredefinedSelect={true}
numberOfMonths={2}
minDate={subDays(new Date(), 90)}
maxDate={new Date()}
placeholder="Select reporting period..."
/>
);
}Visit https://ui.clocket.io to see all components in action with:
- Interactive examples
- Configuration options
- Code snippets
- Usage instructions
# Clone the repository
git clone https://github.com/clocket/clocket-ui-registry.git
cd clocket-ui-registry
# Install dependencies
pnpm install
# Start development server
pnpm dev
# Build registry
pnpm registry:build├── app/ # Next.js app directory
├── components/ui/ # shadcn/ui components
├── registry/ # Registry component definitions
│ └── new-york/
│ ├── ui/ # UI components
│ └── blocks/ # Demo/example blocks
├── public/r/ # Built registry files (JSON)
├── registry.json # Registry configuration
└── package.json
- Create component in
registry/new-york/ui/ - Add demo/example in
registry/new-york/blocks/ - Update
registry.jsonwith component definition - Run
pnpm registry:buildto generate JSON files - Update the demo page in
app/page.tsx
The registry follows the shadcn/ui registry schema:
{
"name": "component-name",
"type": "registry:ui",
"title": "Component Title",
"description": "Component description",
"dependencies": ["date-fns", "lucide-react"],
"registryDependencies": ["button", "popover"],
"files": [
{
"path": "registry/new-york/ui/component.tsx",
"type": "registry:ui"
}
]
}We welcome contributions! Please:
- Fork the repository
- Create a feature branch
- Make your changes
- Add tests and documentation
- Submit a pull request
This project is licensed under the MIT License - see the LICENSE file for details.
- Registry: https://ui.clocket.io
- Documentation: shadcn/ui Registry Docs
- Issues: GitHub Issues
Built with ❤️ using shadcn/ui, Next.js, Tailwind CSS, and Radix UI.