mirror of
https://github.com/hanzoai/shadcn.git
synced 2026-11-03 03:18:52 +00:00
- Updated build-registry.mts to include all component types (ui, ai, 3d, animation, code, etc.) - Fixed missing components issue by processing all components that start with 'components:' - Now properly handles components that only exist in one theme variant - Registry now contains 363 components (up from 117) - AI, 3D, animation, and code components are now accessible via the registry
13 lines
2.3 KiB
JSON
13 lines
2.3 KiB
JSON
{
|
|
"name": "popover-demo",
|
|
"registryDependencies": [
|
|
"popover"
|
|
],
|
|
"files": [
|
|
{
|
|
"name": "popover-demo.tsx",
|
|
"content": "import { Button } from \"@/registry/default/ui/button\"\nimport { Input } from \"@/registry/default/ui/input\"\nimport { Label } from \"@/registry/default/ui/label\"\nimport {\n Popover,\n PopoverContent,\n PopoverTrigger,\n} from \"@/registry/default/ui/popover\"\n\nexport default function PopoverDemo() {\n return (\n <Popover>\n <PopoverTrigger asChild>\n <Button variant=\"outline\">Open popover</Button>\n </PopoverTrigger>\n <PopoverContent className=\"w-80\">\n <div className=\"grid gap-4\">\n <div className=\"space-y-2\">\n <h4 className=\"font-medium leading-none\">Dimensions</h4>\n <p className=\"text-sm text-muted-foreground\">\n Set the dimensions for the layer.\n </p>\n </div>\n <div className=\"grid gap-2\">\n <div className=\"grid grid-cols-3 items-center gap-4\">\n <Label htmlFor=\"width\">Width</Label>\n <Input\n id=\"width\"\n defaultValue=\"100%\"\n className=\"col-span-2 h-8\"\n />\n </div>\n <div className=\"grid grid-cols-3 items-center gap-4\">\n <Label htmlFor=\"maxWidth\">Max. width</Label>\n <Input\n id=\"maxWidth\"\n defaultValue=\"300px\"\n className=\"col-span-2 h-8\"\n />\n </div>\n <div className=\"grid grid-cols-3 items-center gap-4\">\n <Label htmlFor=\"height\">Height</Label>\n <Input\n id=\"height\"\n defaultValue=\"25px\"\n className=\"col-span-2 h-8\"\n />\n </div>\n <div className=\"grid grid-cols-3 items-center gap-4\">\n <Label htmlFor=\"maxHeight\">Max. height</Label>\n <Input\n id=\"maxHeight\"\n defaultValue=\"none\"\n className=\"col-span-2 h-8\"\n />\n </div>\n </div>\n </div>\n </PopoverContent>\n </Popover>\n )\n}\n"
|
|
}
|
|
],
|
|
"type": "components:example"
|
|
} |