{
  "$schema": "https://registry.buildy.tw/schema/registry-item.json",
  "dependencies": [],
  "description": "A footer with the brand, groups of links and the copyright; a single row, a sign-up first or a status pill.",
  "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 * A footer with the brand, a tagline, groups of links and the copyright. Axes: layout (columns: brand above,\n * equal columns per group, row: the brand, the group names and the copyright in one row), signup mode (none,\n * first: a sign-up above the links), status mode (none, show: a live status pill), density. The live status\n * itself is a port contract.\n */\nimport { type ReactNode } from \"react\";\nimport { Block, Box, Button, Container, Form, Group, Input, Label, Stack, Text, Title } from \"../compose\";\nimport { FooterCard } from \"../components/footer-card\";\nimport { FooterColumns } from \"../components/footer-columns\";\nimport { MenuEntry } from \"../components/menu-entry\";\nimport { NavBlock } from \"../components/nav-block\";\nimport { Pill } from \"../components/pill\";\nimport { cn, tpl, uniqLabel } from \"../utils\";\nimport type { FooterSignup, FooterStatus } from \"./sitemap-footer.types\";\nimport type { MegaGroup } from \"./mega-menu.types\";\n\nexport type SitemapFooterProps = {\n  label: string;\n  brand: string;\n  tagline: string;\n  copyright: string;\n  groups: MegaGroup[];\n  signup?: FooterSignup;\n  status?: FooterStatus;\n  id?: string;\n  layout?: \"columns\" | \"row\" | \"card\";\n  density?: \"default\" | \"compact\";\n  landmarkLabel?: string;\n};\n\nexport function SitemapFooter({\n  label,\n  brand,\n  tagline,\n  copyright,\n  groups,\n  signup,\n  status,\n  id = \"footer\",\n  layout = \"columns\",\n  density = \"default\",\n  landmarkLabel,\n}: SitemapFooterProps) {\n  return (\n    <>\n      {((layout as string) === \"card\") ? (\n        <FooterCard label={label} brand={brand} groups={groups} landmarkLabel={landmarkLabel} />\n      ) : (\n        <Block\n          tag=\"footer\"\n          className=\"mt-12 border-t border-border\"\n          data-layout={layout}\n          aria-label={landmarkLabel}\n          data-slot=\"site-footer\"\n        >\n          <Container\n            className={cn(\n              \"mx-auto w-full max-w-6xl px-4\",\n              \"flex flex-col gap-8\",\n              (((density as string) === \"compact\") ? \"py-6\" : \"py-12\")\n            )}\n            data-slot=\"container\"\n          >\n            {(signup?.mode === \"first\") ? (\n              <Stack gap=\"4\" className=\"max-w-md\" data-slot=\"signup\">\n                <Title as={3} size=\"xl\" weight=\"bold\">\n                  {signup?.title}\n                </Title>\n                <Form method=\"dialog\" className={cn(\"w-full max-w-md\", (false ? \"mx-auto\" : \"\"))} data-slot=\"email-form\">\n                  <Label htmlFor={tpl(\"{0}-email\", id)} className=\"sr-only\">\n                    {signup?.label}\n                  </Label>\n                  <Group gap=\"2\" align=\"start\" className=\"w-full flex-wrap\">\n                    <Input type=\"email\" name=\"email\" className=\"min-w-0 flex-1\" id={tpl(\"{0}-email\", id)} data-slot=\"field\" />\n                    <Button variant=\"default\" size=\"default\" type=\"submit\">\n                      {signup?.submit}\n                    </Button>\n                  </Group>\n                </Form>\n              </Stack>\n            ) : null}\n            {((layout as string) === \"columns\") ? (\n              <Box className=\"flex flex-col gap-8 md:flex-row md:items-start md:gap-12\" data-slot=\"footer-top\">\n                <Stack gap=\"2\" className=\"md:w-64 md:shrink-0\">\n                  <Text size=\"xl\" weight=\"bold\">\n                    {brand}\n                  </Text>\n                  <Text size=\"sm\" className=\"text-muted-foreground\">\n                    {tagline}\n                  </Text>\n                </Stack>\n                <Box className=\"min-w-0 flex-1\">\n                  <FooterColumns label={label} groups={groups} landmarkLabel={landmarkLabel} />\n                </Box>\n              </Box>\n            ) : (\n              <Group gap=\"6\" align=\"center\" justify=\"between\" className=\"flex-wrap\">\n                <Text size=\"base\" weight=\"bold\">\n                  {brand}\n                </Text>\n                {((groups?.length ?? 0) > 0) ? (\n                  <NavBlock label={(landmarkLabel ? uniqLabel(tpl(\"{0}, {1}\", label, landmarkLabel)) : label)}>\n                    <Group gap=\"4\" className=\"flex-wrap\">\n                      {(groups ?? []).map((g) => (\n                        <MenuEntry key={g.id} href={g.href} className=\"text-sm\" testid=\"group\">\n                          {g.title}\n                        </MenuEntry>\n                      ))}\n                    </Group>\n                  </NavBlock>\n                ) : null}\n              </Group>\n            )}\n            <Group gap=\"4\" align=\"center\" justify=\"between\" className=\"flex-wrap border-t border-border pt-6\">\n              <Text size=\"sm\" className=\"text-muted-foreground\">\n                {copyright}\n              </Text>\n              {(status?.mode === \"show\") ? (\n                <Pill tone=\"green\" icon=\"circle-check\">\n                  {status?.label}\n                </Pill>\n              ) : null}\n            </Group>\n          </Container>\n        </Block>\n      )}\n    </>\n  );\n}\n",
      "path": "blocks/sitemap-footer.tsx",
      "target": "blocks/sitemap-footer.tsx"
    },
    {
      "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\nexport type FooterSignup = {\n  /** first: the sign-up comes before the links */\n  mode?: \"none\" | \"first\";\n  title?: string;\n  /** accessible name of the email field */\n  label?: string;\n  submit?: string;\n};\n\nexport type FooterStatus = {\n  /** show: the status pill is drawn */\n  mode?: \"none\" | \"show\";\n  /** text of the pill */\n  label?: string;\n};\n",
      "path": "blocks/sitemap-footer.types.ts",
      "target": "blocks/sitemap-footer.types.ts"
    }
  ],
  "meta": {
    "category": "marketing",
    "group": "navigation",
    "kind": "block",
    "tags": [
      "react",
      "block"
    ]
  },
  "name": "sitemap-footer",
  "registryDependencies": [
    "compose",
    "footer-card",
    "footer-columns",
    "mega-menu",
    "menu-entry",
    "nav-block",
    "pill",
    "utils"
  ],
  "runtime": "react",
  "title": "Sitemap Footer",
  "type": "registry:block"
}
