{
  "$schema": "https://registry.buildy.tw/schema/registry-item.json",
  "dependencies": [],
  "description": "Compact rows with a one-click order button and a phone field.",
  "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  Quick order in one click: compact rows (name, weight, summary, price) each with an order button named after\n  the dish, under a phone field that the one click uses. Axes: phone (show, hide), tone.\n-->\n<script lang=\"ts\">\nimport type { Dish, FoodLabels } from \"./dish-showcase.types\";\n\nexport type QuickOrderProps = {\n  id: string;\n  title: string;\n  lead?: string;\n  dishes: Dish[];\n  empty?: string;\n  labels: FoodLabels;\n  phone?: \"show\" | \"hide\";\n  tone?: \"default\" | \"muted\";\n  landmarkLabel?: string;\n};\n</script>\n\n<script setup lang=\"ts\">\nimport Button from \"../compose/Button.vue\";\nimport Group from \"../compose/Group.vue\";\nimport Inline from \"../compose/Inline.vue\";\nimport Input from \"../compose/Input.vue\";\nimport List from \"../compose/List.vue\";\nimport ListItem from \"../compose/ListItem.vue\";\nimport LucideIcon from \"../icons/LucideIcon.vue\";\nimport Stack from \"../compose/Stack.vue\";\nimport Text from \"../compose/Text.vue\";\nimport EmptyState from \"../components/empty-state.vue\";\nimport Field from \"../components/field.vue\";\nimport SectionFrame from \"../components/section-frame.vue\";\nimport { fmtMoney, tpl } from \"../utils\";\n\nconst {\n  id,\n  title,\n  lead = \"\",\n  dishes,\n  empty = \"\",\n  labels,\n  phone = \"show\",\n  tone = \"default\",\n  landmarkLabel,\n} = defineProps<QuickOrderProps>();\n</script>\n\n<template>\n  <SectionFrame :id=\"id\" :title=\"title\" :lead=\"lead\" :tone=\"tone\" :landmarkLabel=\"landmarkLabel\">\n    <EmptyState v-if=\"((dishes?.length ?? 0) === 0)\" icon=\"zap\" :title=\"empty\" />\n    <Stack v-else gap=\"4\" align=\"stretch\" class=\"mx-auto w-full max-w-3xl\">\n      <Field v-if=\"((phone as string) === 'show')\" :label=\"labels.phone\" :htmlFor=\"tpl('{0}-phone', id)\">\n        <Input type=\"tel\" :name=\"tpl('{0}-phone', id)\" :id=\"tpl('{0}-phone', id)\" />\n      </Field>\n      <List tag=\"ul\" class=\"flex flex-col\" data-slot=\"items\">\n        <ListItem\n          v-for=\"d in dishes\"\n          :key=\"d.id\"\n          class=\"flex flex-wrap items-center gap-4 border-b border-border py-4\"\n          data-slot=\"item\"\n        >\n          <Stack gap=\"0\" class=\"min-w-0 flex-1\">\n            <Group gap=\"2\" align=\"baseline\">\n              <Text size=\"base\" weight=\"semibold\">\n                {{ d.name }}\n              </Text>\n              <Text size=\"xs\" class=\"text-muted-foreground\">\n                {{ d.weight }}\n              </Text>\n            </Group>\n            <Text size=\"sm\" class=\"text-muted-foreground\">\n              {{ d.summary }}\n            </Text>\n          </Stack>\n          <Inline class=\"text-base font-bold\">\n            {{ fmtMoney(d.price, d.currency) }}\n          </Inline>\n          <Button variant=\"default\" size=\"sm\" type=\"button\" :aria-label=\"tpl(labels.orderOf, d.name)\">\n            <LucideIcon name=\"zap\" :size=\"16\" />\n            {{ labels.order }}\n          </Button>\n        </ListItem>\n      </List>\n    </Stack>\n  </SectionFrame>\n</template>\n",
      "path": "blocks/quick-order.vue",
      "target": "blocks/quick-order.vue"
    }
  ],
  "meta": {
    "category": "commerce",
    "group": "food",
    "kind": "block",
    "tags": [
      "vue",
      "block"
    ]
  },
  "name": "quick-order",
  "registryDependencies": [
    "button",
    "dish-showcase",
    "empty-state",
    "field",
    "group",
    "inline",
    "input",
    "list",
    "list-item",
    "lucide-icon",
    "section-frame",
    "stack",
    "text",
    "utils"
  ],
  "runtime": "vue",
  "title": "Quick Order",
  "type": "registry:block"
}
