{
  "$schema": "https://registry.buildy.tw/schema/registry-item.json",
  "dependencies": [],
  "description": "The questions of FaqSplit as cards: the topic, the question, the answer and a read-more link; with an icon square on top in the icons shape. Shapes: grid3, grid4, icons (three columns).",
  "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 * The questions of FaqSplit as cards: the topic, the question, the answer and a read-more link; with an icon\n * square on top in the icons shape. Shapes: grid3, grid4, icons (three columns).\n */\nimport { type ReactNode } from \"react\";\nimport { Badge, Box, Button, Stack, Text, Title } from \"../compose\";\nimport { LucideIcon } from \"../icons/LucideIcon\";\nimport { ArticleBlock } from \"../components/article-block\";\nimport type { Question, FaqSplitLabels } from \"../blocks/faq-split.types\";\n\nexport type FaqCardsProps = {\n  items: Question[];\n  labels: FaqSplitLabels;\n  cards?: \"grid3\" | \"grid4\" | \"icons\";\n};\n\nexport function FaqCards({ items, labels, cards = \"grid3\" }: FaqCardsProps) {\n  return (\n    <Box\n      className={\n        (cards as string) === \"grid4\" ? \"grid grid-cols-1 gap-4 sm:grid-cols-2 lg:grid-cols-4\"\n        : \"grid grid-cols-1 gap-4 sm:grid-cols-2 lg:grid-cols-3\"\n      }\n      data-slot=\"faq\"\n    >\n      {(items ?? []).map((q) => (\n        <ArticleBlock key={q.id}\n          className=\"rounded bg-card inset-ring inset-ring-border flex flex-col gap-4 p-6\"\n          testid=\"faq-card\"\n        >\n          {((cards as string) === \"icons\") ? (\n            <Box className=\"flex size-10 shrink-0 items-center justify-center rounded bg-muted\">\n              <LucideIcon name={q.icon} size={20} />\n            </Box>\n          ) : null}\n          <Stack gap=\"2\">\n            <Badge variant=\"secondary\" size=\"sm\" className=\"w-fit\">\n              {q.category}\n            </Badge>\n            <Title as={3} size=\"base\" weight=\"semibold\">\n              {q.question}\n            </Title>\n            <Text size=\"sm\" className=\"text-muted-foreground\">\n              {q.answer}\n            </Text>\n          </Stack>\n          <Box className=\"mt-auto\">\n            <Button variant=\"link\" size=\"sm\" className=\"gap-2 px-0 font-medium\">\n              {labels.more}\n              <LucideIcon name=\"arrow-right\" size={16} />\n            </Button>\n          </Box>\n        </ArticleBlock>\n      ))}\n    </Box>\n  );\n}\n",
      "path": "components/faq-cards.tsx",
      "target": "components/faq-cards.tsx"
    }
  ],
  "meta": {
    "category": "components",
    "kind": "component",
    "tags": [
      "react",
      "component"
    ]
  },
  "name": "faq-cards",
  "registryDependencies": [
    "article-block",
    "compose",
    "faq-split",
    "lucide-icon",
    "utils"
  ],
  "runtime": "react",
  "title": "Faq Cards",
  "type": "registry:component"
}
