{
  "$schema": "https://registry.buildy.tw/schema/registry-item.json",
  "dependencies": [],
  "description": "What HeroSplit shows beside the text: a picture, a picture with a floating card, a grid of four pictures with captions, or a picture with two plan cards floating over it.",
  "devDependencies": [],
  "digest": "0.1.0",
  "files": [
    {
      "content": "// Code generated by packages/kit-compose/src/organisms.ts from packages/compose-gen/specs (compose-gen organism emitters on kit-compose). DO NOT EDIT.\n/**\n * What HeroSplit shows beside the text: a picture, a picture with a floating card, a grid of four pictures with\n * captions, or a picture with two plan cards floating over it.\n */\nimport { Fragment, type ReactNode } from \"react\";\nimport { Box, Group, Stack, Text } from \"../compose\";\nimport { LucideIcon } from \"../icons/LucideIcon\";\nimport { FigureBlock } from \"../components/figure-block\";\nimport { MediaFrame } from \"../components/media-frame\";\nimport { OfferMedia } from \"../components/offer-media\";\nimport { cn } from \"../utils\";\nimport type { HeroContent } from \"../blocks/hero-split.types\";\n\nexport type HeroSplitMediaProps = {\n  content: HeroContent;\n  alt: string;\n  image?: string;\n  media?: \"picture\" | \"card\" | \"grid\" | \"plans\";\n};\n\nexport function HeroSplitMedia({ content, alt, image, media = \"picture\" }: HeroSplitMediaProps) {\n  return (\n    <>\n      {((media as string) === \"picture\") ? (\n        <MediaFrame alt={alt} src={image} ratio=\"4/3\" />\n      ) : null}\n      {((media as string) === \"card\") ? (\n        <OfferMedia alt={alt} image={image} card={content.card} />\n      ) : null}\n      {(((media as string) === \"grid\") && ((content.features?.length ?? 0) > 0)) ? (\n        <Box className=\"grid grid-cols-2 gap-4\" data-slot=\"hero-grid\">\n          {(content.features ?? []).map((f, i) => (\n            <Fragment key={f.id}>\n              {(i < 4) ? (\n                <FigureBlock className=\"flex flex-col gap-2\" testid=\"hero-tile\">\n                  <MediaFrame alt={f.title} src={f.image} ratio=\"1/1\" />\n                  <Text size=\"xs\" className=\"text-muted-foreground\">\n                    {f.title}\n                  </Text>\n                </FigureBlock>\n              ) : null}\n            </Fragment>\n          ))}\n        </Box>\n      ) : null}\n      {(((media as string) === \"plans\") && ((content.plans?.length ?? 0) > 0)) ? (\n        <Box className=\"relative\" data-slot=\"hero-media\">\n          <MediaFrame alt={alt} src={image} ratio=\"4/3\" />\n          {(content.plans ?? []).map((p, i) => (\n            <Fragment key={p.id}>\n              {(i < 2) ? (\n                <Stack\n                  gap=\"2\"\n                  className={cn(\n                    \"absolute w-48 rounded bg-card p-4 shadow-lg\",\n                    ((i === 0) ? \"top-8 left-4\" : \"right-4 bottom-8\")\n                  )}\n                  data-slot=\"hero-plan\"\n                >\n                  <Text size=\"sm\" weight=\"semibold\">\n                    {p.name}\n                  </Text>\n                  <Group gap=\"2\" align=\"center\">\n                    <LucideIcon name=\"check\" size={16} />\n                    <Text size=\"xs\" className=\"text-muted-foreground\">\n                      {p.tagline}\n                    </Text>\n                  </Group>\n                </Stack>\n              ) : null}\n            </Fragment>\n          ))}\n        </Box>\n      ) : null}\n    </>\n  );\n}\n",
      "path": "components/hero-split-media.tsx",
      "target": "components/hero-split-media.tsx"
    }
  ],
  "meta": {
    "category": "components",
    "kind": "component",
    "tags": [
      "react",
      "component"
    ]
  },
  "name": "hero-split-media",
  "registryDependencies": [
    "compose",
    "figure-block",
    "hero-split",
    "lucide-icon",
    "media-frame",
    "offer-media",
    "utils"
  ],
  "runtime": "react",
  "title": "Hero Split Media",
  "type": "registry:component"
}
