{
  "$schema": "https://registry.buildy.tw/schema/registry-item.json",
  "dependencies": [],
  "description": "The filled body of the CartDrawer: the lines with a quantity field, then the free-delivery bar, the subtotal and total and the button.",
  "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/drawer-lines.json\n    The filled body of the CartDrawer: the lines with a quantity field, then the free-delivery bar, the subtotal and total and the button.\n    Props (p): lines, rows, labels, drawer, media, field. -#}\n{%- set v_lines = (p.lines ?? null) -%}\n{%- set v_rows = (p.rows ?? null) -%}\n{%- set v_labels = (p.labels ?? null) -%}\n{%- set v_drawer = (p.drawer ?? null) -%}\n{%- set v_media = (p.media ?? 'image') -%}\n{%- set v_field = (p.field ?? 'qty') -%}\n{%- set c_7 -%}\n  {%- for v_line in og_l(v_lines) %}\n    {%- set c_6 -%}\n      {%- if og_t(og_eq(v_media, 'image')) %}\n        {{ include('blocks/media-frame.html.twig', {'p': {'alt': og_get(v_line, ['name']), 'src': og_get(v_line, ['image']), 'ratio': '1/1', 'className': og_cnv(['size-16 shrink-0'])}}, with_context = false) }}\n      {%- endif %}\n      {%- set c_5 -%}\n        {%- set c_3 -%}\n          {%- set c_1 -%}\n            {{ og_text(og_get(v_line, ['name'])) }}\n          {%- endset -%}\n          {{ include('compose/Text.html.twig', {'size': 'sm', 'weight': 'semibold', 'children': c_1}, with_context = false) }}\n          {%- set c_2 -%}\n            {{ og_text(og_money(og_mul(og_get(v_line, ['price']), og_get(v_line, ['qty'])), og_get(v_line, ['currency']))) }}\n          {%- endset -%}\n          {{ include('compose/Inline.html.twig', {'class': 'text-sm font-medium', 'children': c_2}, with_context = false) }}\n        {%- endset -%}\n        {{ include('compose/Group.html.twig', {'gap': '2', 'justify': 'between', 'align': 'start', 'children': c_3}, with_context = false) }}\n        {%- set c_4 -%}\n          {{ og_text(og_get(v_line, ['variant'])) }}\n        {%- endset -%}\n        {{ include('compose/Text.html.twig', {'size': 'xs', 'class': 'text-muted-foreground', 'children': c_4}, with_context = false) }}\n        {{ include('blocks/number-field.html.twig', {'p': {'value': og_str(og_get(v_line, ['qty'])), 'name': og_tpl('{0}-{1}', [v_field, og_get(v_line, ['id'])]), 'min': '1', 'label': og_get(v_labels, ['qty']), 'decrease': og_get(v_labels, ['decrease']), 'increase': og_get(v_labels, ['increase'])}}, with_context = false) }}\n      {%- endset -%}\n      {{ include('compose/Stack.html.twig', {'gap': '2', 'align': 'stretch', 'class': 'flex-1', 'children': c_5}, with_context = false) }}\n    {%- endset -%}\n    {{ include('compose/Group.html.twig', {'gap': '4', 'align': 'start', 'attrs': og_attrs(['data-slot', 'item']), 'children': c_6}, with_context = false) }}\n  {%- endfor %}\n{%- endset -%}\n{{ include('compose/Stack.html.twig', {'gap': '4', 'align': 'stretch', 'class': 'flex-1 p-4', 'attrs': og_attrs(['data-slot', 'lines']), 'children': c_7}, with_context = false) }}\n{%- set c_15 -%}\n  {%- set c_9 -%}\n    {%- set c_8 -%}\n      {{ og_text(og_get(v_drawer, ['progress'])) }}\n    {%- endset -%}\n    {{ include('compose/Text.html.twig', {'size': 'sm', 'children': c_8}, with_context = false) }}\n    {{ include('compose/Progress.html.twig', {'value': '96', 'max': '100', 'attrs': og_attrs(['aria-label', og_get(v_drawer, ['progress'])])}, with_context = false) }}\n  {%- endset -%}\n  {{ include('compose/Stack.html.twig', {'gap': '2', 'align': 'stretch', 'class': 'rounded bg-muted p-4', 'attrs': og_attrs(['data-slot', 'progress']), 'children': c_9}, with_context = false) }}\n  {%- set c_13 -%}\n    {%- for v_row in og_l(v_rows) %}\n      {%- set v_i = loop.index0 -%}\n      {%- if og_t((og_t(og_get(v_row, ['strong'])) ? true : og_eq(v_i, 0))) %}\n        {%- set c_12 -%}\n          {%- set c_10 -%}\n            {{ og_text(og_get(v_row, ['label'])) }}\n          {%- endset -%}\n          {{ include('compose/Inline.html.twig', {'children': c_10}, with_context = false) }}\n          {%- set c_11 -%}\n            {{ og_text(og_money(og_get(v_row, ['amount']), og_get(v_row, ['currency']))) }}\n          {%- endset -%}\n          {{ include('compose/Inline.html.twig', {'children': c_11}, with_context = false) }}\n        {%- endset -%}\n        {{ include('compose/ListItem.html.twig', {'class': og_s((og_t(og_get(v_row, ['strong'])) ? 'flex justify-between text-base font-bold' : 'flex justify-between text-sm text-muted-foreground')), 'attrs': og_attrs(['data-slot', 'summary-row']), 'children': c_12}, with_context = false) }}\n      {%- endif %}\n    {%- endfor %}\n  {%- endset -%}\n  {{ include('compose/List.html.twig', {'tag': 'ul', 'class': 'flex flex-col gap-2', 'children': c_13}, with_context = false) }}\n  {%- set c_14 -%}\n    {{ og_text(og_get(v_labels, ['checkout'])) }}\n  {%- endset -%}\n  {{ include('compose/Button.html.twig', {'variant': 'default', 'size': 'lg', 'class': 'w-full', 'children': c_14}, with_context = false) }}\n{%- endset -%}\n{{ include('compose/Stack.html.twig', {'gap': '4', 'align': 'stretch', 'class': 'border-t border-border p-4', 'attrs': og_attrs(['data-slot', 'drawer-lines']), 'children': c_15}, with_context = false) }}\n",
      "path": "blocks/drawer-lines.html.twig",
      "target": "blocks/drawer-lines.html.twig"
    }
  ],
  "meta": {
    "category": "components",
    "kind": "component",
    "tags": [
      "twig",
      "component"
    ]
  },
  "name": "drawer-lines",
  "registryDependencies": [
    "button",
    "group",
    "inline",
    "list",
    "list-item",
    "media-frame",
    "number-field",
    "progress",
    "stack",
    "text",
    "utils"
  ],
  "runtime": "twig",
  "title": "Drawer Lines",
  "type": "registry:component"
}
