{
  "$schema": "https://registry.buildy.tw/schema/registry-item.json",
  "dependencies": [],
  "description": "How delivery works: the facts, then the zones.",
  "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\nexport type DeliveryLabels = {\n  zones: string;\n  freeFrom: string;\n};\n",
      "path": "blocks/delivery-info.types.ts",
      "target": "blocks/delivery-info.types.ts"
    },
    {
      "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  How delivery works: the facts as icon cards, then the zones with their time and the order that ships free.\n  Axes: layout (full: facts over zone cards, facts: the facts only, split: the facts beside a list of zones),\n  tone, density.\n-->\n<script lang=\"ts\">\nimport type { DeliveryLabels } from \"./delivery-info.types\";\nimport type { Feature } from \"./feature-grid.types\";\nimport type { Zone } from \"./zone-table.types\";\n\nexport type DeliveryInfoProps = {\n  id: string;\n  title: string;\n  lead?: string;\n  facts: Feature[];\n  zones: Zone[];\n  labels: DeliveryLabels;\n  layout?: \"full\" | \"facts\" | \"split\";\n  tone?: \"default\" | \"muted\";\n  density?: \"default\" | \"compact\";\n  landmarkLabel?: string;\n};\n</script>\n\n<script setup lang=\"ts\">\nimport Badge from \"../compose/Badge.vue\";\nimport Box from \"../compose/Box.vue\";\nimport Grid from \"../compose/Grid.vue\";\nimport Group from \"../compose/Group.vue\";\nimport LucideIcon from \"../icons/LucideIcon.vue\";\nimport Stack from \"../compose/Stack.vue\";\nimport Text from \"../compose/Text.vue\";\nimport Title from \"../compose/Title.vue\";\nimport SectionFrame from \"../components/section-frame.vue\";\nimport { cn, fmtMoney, tpl } from \"../utils\";\n\nconst {\n  id,\n  title,\n  lead = \"\",\n  facts,\n  zones,\n  labels,\n  layout = \"full\",\n  tone = \"default\",\n  density = \"default\",\n  landmarkLabel,\n} = defineProps<DeliveryInfoProps>();\n</script>\n\n<template>\n  <SectionFrame\n    :id=\"id\"\n    :title=\"title\"\n    :lead=\"lead\"\n    :tone=\"tone\"\n    :density=\"density\"\n    :landmarkLabel=\"landmarkLabel\"\n  >\n    <Box\n      :class=\"cn(\n        'grid grid-cols-1 gap-8',\n        (((layout as string) === 'split') ? 'items-start md:grid-cols-2' : '')\n      )\"\n    >\n      <Grid\n        v-if=\"((facts?.length ?? 0) > 0)\"\n        :cols=\"(((layout as string) === 'split') ? '1-2' : '1-4')\"\n        class=\"gap-4\"\n        data-slot=\"facts\"\n      >\n        <Stack\n          v-for=\"f in facts\"\n          :key=\"f.id\"\n          gap=\"4\"\n          class=\"rounded bg-card inset-ring inset-ring-border p-6\"\n          data-slot=\"fact\"\n        >\n          <Box class=\"flex size-10 shrink-0 items-center justify-center rounded bg-muted\">\n            <LucideIcon :name=\"f.icon\" :size=\"20\" />\n          </Box>\n          <Stack gap=\"2\">\n            <Text size=\"sm\" weight=\"semibold\">\n              {{ f.title }}\n            </Text>\n            <Text size=\"sm\" class=\"text-muted-foreground\">\n              {{ f.text }}\n            </Text>\n          </Stack>\n        </Stack>\n      </Grid>\n      <Stack v-if=\"(((layout as string) !== 'facts') && ((zones?.length ?? 0) > 0))\" gap=\"4\" align=\"stretch\">\n        <Title :as=\"3\" size=\"lg\" weight=\"bold\">\n          {{ labels.zones }}\n        </Title>\n        <Box\n          :class=\"\n            (layout as string) === 'split' ? 'flex flex-col gap-4'\n            : 'grid grid-cols-1 gap-4 md:grid-cols-3'\n          \"\n        >\n          <Stack v-for=\"z in zones\" :key=\"z.id\"\n            gap=\"2\"\n            :class=\"\n              (layout as string) === 'split' ? 'border-b border-border pb-4'\n              : 'rounded bg-card inset-ring inset-ring-border p-6'\n            \"\n            data-slot=\"zone\"\n          >\n            <Group gap=\"4\" align=\"baseline\" justify=\"between\">\n              <Text size=\"sm\" weight=\"semibold\">\n                {{ z.name }}\n              </Text>\n              <Badge variant=\"secondary\" size=\"default\">\n                {{ z.time }}\n              </Badge>\n            </Group>\n            <Text size=\"sm\" class=\"text-muted-foreground\">\n              {{ z.area }}\n            </Text>\n            <Text size=\"sm\" weight=\"medium\">\n              {{ tpl(labels.freeFrom, fmtMoney(z.freeFrom, z.currency)) }}\n            </Text>\n          </Stack>\n        </Box>\n      </Stack>\n    </Box>\n  </SectionFrame>\n</template>\n",
      "path": "blocks/delivery-info.vue",
      "target": "blocks/delivery-info.vue"
    }
  ],
  "meta": {
    "category": "commerce",
    "group": "delivery",
    "kind": "block",
    "tags": [
      "vue",
      "block"
    ]
  },
  "name": "delivery-info",
  "registryDependencies": [
    "badge",
    "box",
    "feature-grid",
    "grid",
    "group",
    "lucide-icon",
    "section-frame",
    "stack",
    "text",
    "title",
    "utils",
    "zone-table"
  ],
  "runtime": "vue",
  "title": "Delivery Info",
  "type": "registry:block"
}
