{
  "$schema": "https://registry.buildy.tw/schema/registry-item.json",
  "dependencies": [],
  "description": "Pick a main, a side and a drink beside the total.",
  "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 set (combo) builder: three numbered steps, each a radio group of cards with the price (main, side, drink),\n  beside or under a summary with the live total and the order button. Axes: layout (split, stacked), tone.\n-->\n<script lang=\"ts\" module>\n  import type { Snippet } from \"svelte\";\n  import type { Dish, FoodLabels } from \"./dish-showcase.types\";\n  import type { DishOption } from \"../components/option-chips.types\";\n\n  export type ComboBuilderProps = {\n    id: string;\n    title: string;\n    lead?: string;\n    labels: FoodLabels;\n    mains: DishOption[];\n    sides: DishOption[];\n    drinks: DishOption[];\n    total: number;\n    currency: string;\n    layout?: \"split\" | \"stacked\";\n    tone?: \"default\" | \"muted\";\n    landmarkLabel?: string;\n  };\n</script>\n\n<script lang=\"ts\">\n  import Box from \"../compose/Box.svelte\";\n  import Button from \"../compose/Button.svelte\";\n  import Group from \"../compose/Group.svelte\";\n  import Inline from \"../compose/Inline.svelte\";\n  import LucideIcon from \"../icons/LucideIcon.svelte\";\n  import Stack from \"../compose/Stack.svelte\";\n  import Text from \"../compose/Text.svelte\";\n  import OptionChips from \"../components/option-chips.svelte\";\n  import SectionFrame from \"../components/section-frame.svelte\";\n  import { fmtMoney, tpl } from \"../utils\";\n\n  let {\n    id,\n    title,\n    lead = \"\",\n    labels,\n    mains,\n    sides,\n    drinks,\n    total,\n    currency,\n    layout = \"split\",\n    tone = \"default\",\n    landmarkLabel,\n  }: ComboBuilderProps = $props();\n</script>\n\n<SectionFrame id={id} title={title} lead={lead} tone={tone} landmarkLabel={landmarkLabel}>\n  <Box class=\"grid grid-cols-1 items-start gap-8 lg:grid-cols-3\">\n    <Box\n      class={\n        (layout as string) === \"split\" ? \"flex flex-col gap-8 lg:col-span-2\"\n        : \"flex flex-col gap-8 lg:col-span-3\"\n      }\n      data-slot=\"steps\"\n    >\n      <OptionChips name={tpl(\"{0}-main\", id)} legend={labels.main} options={mains} extra=\"price\" layout=\"column\" />\n      <OptionChips name={tpl(\"{0}-side\", id)} legend={labels.side} options={sides} extra=\"price\" layout=\"column\" />\n      <OptionChips name={tpl(\"{0}-drink\", id)} legend={labels.drink} options={drinks} extra=\"price\" layout=\"column\" />\n    </Box>\n    <Stack\n      gap=\"4\"\n      class={\n        (layout as string) === \"split\" ? \"rounded bg-card inset-ring inset-ring-border flex flex-col gap-4 p-6 lg:sticky lg:top-8\"\n        : \"rounded bg-card inset-ring inset-ring-border flex flex-col gap-4 p-6\"\n      }\n      data-slot=\"summary\"\n    >\n      <Text size=\"lg\" weight=\"semibold\">\n        {labels.summary}\n      </Text>\n      <Group gap=\"2\" align=\"baseline\" justify=\"between\">\n        <Text size=\"sm\" class=\"text-muted-foreground\">\n          {labels.total}\n        </Text>\n        <Inline class=\"text-2xl font-bold\" role=\"status\" aria-live=\"polite\" data-slot=\"total\">\n          {fmtMoney(total, currency)}\n        </Inline>\n      </Group>\n      <Button variant=\"default\" size=\"lg\" type=\"button\" class=\"w-full\">\n        <LucideIcon name=\"shopping-bag\" size={16} />\n        {labels.add}\n      </Button>\n    </Stack>\n  </Box>\n</SectionFrame>\n",
      "path": "blocks/combo-builder.svelte",
      "target": "blocks/combo-builder.svelte"
    }
  ],
  "meta": {
    "category": "commerce",
    "group": "food",
    "kind": "block",
    "tags": [
      "svelte",
      "block"
    ]
  },
  "name": "combo-builder",
  "registryDependencies": [
    "box",
    "button",
    "dish-showcase",
    "group",
    "inline",
    "lucide-icon",
    "option-chips",
    "section-frame",
    "stack",
    "text",
    "utils"
  ],
  "runtime": "svelte",
  "title": "Combo Builder",
  "type": "registry:block"
}
