{
  "$schema": "https://registry.buildy.tw/schema/registry-item.json",
  "dependencies": [],
  "description": "A dish as a card: picture, category, portion/weight, price and an order button. No rating.",
  "devDependencies": [],
  "digest": "0.1.0",
  "files": [
    {
      "content": "{* Code generated by packages/kit-compose/src/server-organisms.ts from packages/compose-gen/specs (compose-gen organism emitters on kit-compose). DO NOT EDIT.\n    Source: packages/compose-gen/specs/organisms/dish-card.json\n    A dish as a card: picture, optional badge, category, name, portion/weight, summary, price and an order button. No rating. Axes: layout (vertical, horizontal), media (image, none), density, action (button, none). Records map from Codex kind `dish`.\n    Props (p): dish, labels, layout, media, prices, action, density. *}\n{var $v_dish = ($p['dish'] ?? null)}\n{var $v_labels = ($p['labels'] ?? null)}\n{var $v_layout = ($p['layout'] ?? 'vertical')}\n{var $v_media = ($p['media'] ?? 'image')}\n{var $v_prices = ($p['prices'] ?? 'show')}\n{var $v_action = ($p['action'] ?? 'button')}\n{var $v_density = ($p['density'] ?? 'default')}\n{capture $c_14}\n  {if og_t(og_eq($v_media, 'image'))}\n    {capture $c_2}\n      {=og_include('blocks/media-frame.latte', ['p' => ['alt' => og_get($v_dish, ['name']), 'src' => og_get($v_dish, ['image']), 'ratio' => '4/3', 'className' => og_cnv(['h-full'])]])|noescape}\n      {if og_t(og_get($v_dish, ['badge']))}\n        {capture $c_1}\n          {=og_text(og_get($v_dish, ['badge']))}\n        {/capture}\n        {=og_include('compose/Badge.latte', ['variant' => 'default', 'size' => 'default', 'class' => 'absolute left-4 top-4', 'children' => (string) $c_1])|noescape}\n      {/if}\n    {/capture}\n    {=og_include('compose/Box.latte', ['class' => og_s(og_cnv(['relative shrink-0', (og_t(og_eq($v_layout, 'horizontal')) ? 'sm:w-48' : '')])), 'children' => (string) $c_2])|noescape}\n  {/if}\n  {capture $c_13}\n    {capture $c_5}\n      {capture $c_3}\n        {=og_text(og_get($v_dish, ['tag']))}\n      {/capture}\n      {=og_include('compose/Text.latte', ['size' => 'xs', 'class' => 'uppercase tracking-wide text-muted-foreground', 'attrs' => og_attrs(['data-slot', 'category']), 'children' => (string) $c_3])|noescape}\n      {if og_t(og_eq($v_media, 'none'))}\n        {if og_t(og_get($v_dish, ['badge']))}\n          {capture $c_4}\n            {=og_text(og_get($v_dish, ['badge']))}\n          {/capture}\n          {=og_include('compose/Badge.latte', ['variant' => 'secondary', 'size' => 'sm', 'children' => (string) $c_4])|noescape}\n        {/if}\n      {/if}\n    {/capture}\n    {=og_include('compose/Group.latte', ['gap' => '2', 'align' => 'center', 'class' => 'flex-wrap', 'children' => (string) $c_5])|noescape}\n    {capture $c_7}\n      {if og_t(og_get($v_dish, ['href']))}\n        {capture $c_6}\n          {=og_text(og_get($v_dish, ['name']))}\n        {/capture}\n        {=og_include('compose/Link.latte', ['href' => og_url(og_s(og_get($v_dish, ['href']))), 'variant' => 'default', 'attrs' => og_attrs(['data-slot', 'open']), 'children' => (string) $c_6])|noescape}\n      {else}\n        {=og_text(og_get($v_dish, ['name']))}\n      {/if}\n    {/capture}\n    {=og_include('compose/Title.latte', ['as' => 3, 'size' => 'base', 'weight' => 'bold', 'children' => (string) $c_7])|noescape}\n    {if og_t(og_get($v_dish, ['weight']))}\n      {capture $c_8}\n        {=og_text(og_get($v_dish, ['weight']))}\n      {/capture}\n      {=og_include('compose/Text.latte', ['size' => 'xs', 'class' => 'text-muted-foreground', 'attrs' => og_attrs(['data-slot', 'portion']), 'children' => (string) $c_8])|noescape}\n    {/if}\n    {if og_t(og_eq($v_density, 'default'))}\n      {capture $c_9}\n        {=og_text(og_get($v_dish, ['summary']))}\n      {/capture}\n      {=og_include('compose/Text.latte', ['size' => 'sm', 'class' => 'text-muted-foreground', 'children' => (string) $c_9])|noescape}\n    {/if}\n    {capture $c_12}\n      {if og_t(og_eq($v_prices, 'show'))}\n        {capture $c_10}\n          {=og_text(og_money(og_get($v_dish, ['price']), og_get($v_dish, ['currency'])))}\n        {/capture}\n        {=og_include('compose/Text.latte', ['size' => 'xl', 'weight' => 'bold', 'attrs' => og_attrs(['data-slot', 'price']), 'children' => (string) $c_10])|noescape}\n      {/if}\n      {if og_t(og_eq($v_action, 'button'))}\n        {capture $c_11}\n          {=og_text(og_get($v_labels, ['add']))}\n        {/capture}\n        {=og_include('compose/Button.latte', ['variant' => 'default', 'size' => 'sm', 'type' => 'button', 'children' => (string) $c_11])|noescape}\n      {/if}\n    {/capture}\n    {=og_include('compose/Group.latte', ['gap' => '4', 'justify' => 'between', 'class' => 'mt-auto pt-2', 'children' => (string) $c_12])|noescape}\n  {/capture}\n  {=og_include('compose/CardContent.latte', ['class' => 'flex flex-1 flex-col gap-2', 'children' => (string) $c_13])|noescape}\n{/capture}\n{=og_include('compose/Block.latte', ['tag' => 'article', 'class' => og_s(og_cnv(['flex flex-col gap-8 bg-card p-6 text-card-foreground inset-ring inset-ring-border rounded', 'h-full gap-4 overflow-hidden', (og_t(og_eq($v_layout, 'horizontal')) ? 'flex flex-col sm:flex-row' : 'flex flex-col')])), 'attrs' => og_attrs(['data-slot', 'card', 'data-layout', $v_layout]), 'children' => (string) $c_14])|noescape}\n",
      "path": "blocks/dish-card.latte",
      "target": "blocks/dish-card.latte"
    }
  ],
  "meta": {
    "category": "commerce",
    "group": "restaurant",
    "kind": "block",
    "tags": [
      "latte",
      "block"
    ]
  },
  "name": "dish-card",
  "registryDependencies": [
    "badge",
    "block",
    "box",
    "button",
    "card-content",
    "group",
    "link",
    "media-frame",
    "text",
    "title",
    "utils"
  ],
  "runtime": "latte",
  "title": "Dish Card",
  "type": "registry:block"
}
