mirror of
https://github.com/shadcn-ui/ui.git
synced 2026-02-09 02:49:29 +08:00
* feat: add base and radix docs * feat: transform code for display * fix * fix * fix * fix * fix * chore: remove claude files * fix * fix * fix * chore: run format:write * fix * feat: add more examples * fix * feat: add aspect-ratio * feat: add avatar * feat: add badge * feat: add breadcrumb * fix * feat: add button * fix * fix * fix * feat: add calendar and card * feat: add carousel * fix: chart * feat: add checkbox * feat: add collapsible * feat: add combobox * feat: add command * feat: add context menu * feat: add data-table dialog and drawer * feat: dropdown-menu * feat: add date-picker * feat: add empty * feat: add field and hover-card * fix: input * feat: add input * feat: add input-group * feat: add input-otp * feat: add item * feat: add kbd and label * feat: add menubar * feat: add native-select * feat: add more components * feat: more components * feat: more components * feat: add skeleton, slider and sonner * feat: add spinner and switch * feat: add more components * fix: tabs * fix: tabs * feat: add docs for sidebar * fix * fix * fi * docs: update * fix: create page * fix * fix * chore: add changelog * fix
13 lines
1.7 KiB
JSON
13 lines
1.7 KiB
JSON
{
|
|
"$schema": "https://ui.shadcn.com/schema/registry-item.json",
|
|
"name": "example",
|
|
"title": "Example",
|
|
"files": [
|
|
{
|
|
"path": "registry/radix-nova/components/example.tsx",
|
|
"content": "import { cn } from \"@/registry/radix-nova/lib/utils\"\n\nfunction ExampleWrapper({ className, ...props }: React.ComponentProps<\"div\">) {\n return (\n <div className=\"bg-background w-full\">\n <div\n data-slot=\"example-wrapper\"\n className={cn(\n \"mx-auto grid min-h-screen w-full max-w-5xl min-w-0 content-center items-start gap-8 p-4 pt-2 sm:gap-12 sm:p-6 md:grid-cols-2 md:gap-8 lg:p-12 2xl:max-w-6xl\",\n className\n )}\n {...props}\n />\n </div>\n )\n}\n\nfunction Example({\n title,\n children,\n className,\n containerClassName,\n ...props\n}: React.ComponentProps<\"div\"> & {\n title?: string\n containerClassName?: string\n}) {\n return (\n <div\n data-slot=\"example\"\n className={cn(\n \"mx-auto flex w-full max-w-lg min-w-0 flex-col gap-1 self-stretch lg:max-w-none\",\n containerClassName\n )}\n {...props}\n >\n {title && (\n <div className=\"text-muted-foreground px-1.5 py-2 text-xs font-medium\">\n {title}\n </div>\n )}\n <div\n data-slot=\"example-content\"\n className={cn(\n \"bg-background text-foreground flex min-w-0 flex-1 flex-col items-start gap-6 border border-dashed p-4 sm:p-6 *:[div:not([class*='w-'])]:w-full\",\n className\n )}\n >\n {children}\n </div>\n </div>\n )\n}\n\nexport { ExampleWrapper, Example }\n",
|
|
"type": "registry:component"
|
|
}
|
|
],
|
|
"type": "registry:component"
|
|
} |