mirror of
https://github.com/hanzoai/shadcn.git
synced 2026-11-03 03:18:52 +00:00
Squash merge of shadcn-ui/ui main branch into hanzo/ui, bringing in: - [email protected] through [email protected] releases - New apps/v4 directory structure - Registry system improvements and MCP server - Framework support (Vue, Svelte, React Native) - New templates (vite-app, monorepo-next, laravel) - Zod 4 compatibility (scoped override for zod@>4) - Test fixture corrections for alias resolution All 867 merge conflicts resolved preserving Hanzo customizations. 1020/1020 shadcn tests pass.
15 lines
2.2 KiB
JSON
15 lines
2.2 KiB
JSON
{
|
|
"$schema": "https://ui.shadcn.com/schema/registry-item.json",
|
|
"name": "item-group",
|
|
"registryDependencies": [
|
|
"item"
|
|
],
|
|
"files": [
|
|
{
|
|
"path": "registry/new-york-v4/examples/item-group.tsx",
|
|
"content": "import * as React from \"react\"\nimport { PlusIcon } from \"lucide-react\"\n\nimport {\n Avatar,\n AvatarFallback,\n AvatarImage,\n} from \"@/registry/new-york-v4/ui/avatar\"\nimport { Button } from \"@/registry/new-york-v4/ui/button\"\nimport {\n Item,\n ItemActions,\n ItemContent,\n ItemDescription,\n ItemGroup,\n ItemMedia,\n ItemSeparator,\n ItemTitle,\n} from \"@/registry/new-york-v4/ui/item\"\n\nconst people = [\n {\n username: \"shadcn\",\n avatar: \"https://github.com/shadcn.png\",\n email: \"[email protected]\",\n },\n {\n username: \"maxleiter\",\n avatar: \"https://github.com/maxleiter.png\",\n email: \"[email protected]\",\n },\n {\n username: \"evilrabbit\",\n avatar: \"https://github.com/evilrabbit.png\",\n email: \"[email protected]\",\n },\n]\n\nexport default function ItemGroupExample() {\n return (\n <div className=\"flex w-full max-w-md flex-col gap-6\">\n <ItemGroup>\n {people.map((person, index) => (\n <React.Fragment key={person.username}>\n <Item>\n <ItemMedia>\n <Avatar>\n <AvatarImage src={person.avatar} className=\"grayscale\" />\n <AvatarFallback>{person.username.charAt(0)}</AvatarFallback>\n </Avatar>\n </ItemMedia>\n <ItemContent className=\"gap-1\">\n <ItemTitle>{person.username}</ItemTitle>\n <ItemDescription>{person.email}</ItemDescription>\n </ItemContent>\n <ItemActions>\n <Button variant=\"ghost\" size=\"icon\" className=\"rounded-full\">\n <PlusIcon />\n </Button>\n </ItemActions>\n </Item>\n {index !== people.length - 1 && <ItemSeparator />}\n </React.Fragment>\n ))}\n </ItemGroup>\n </div>\n )\n}\n",
|
|
"type": "registry:example"
|
|
}
|
|
],
|
|
"type": "registry:example"
|
|
} |