{
  "$schema": "https://registry.buildy.tw/schema/registry-item.json",
  "dependencies": [],
  "description": "A long read in one reading column, or beside a table of contents that links to the sections.",
  "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/article-body.json\n    A long read: sections with headings, text and an optional pull quote, in one reading column or beside a table of contents that links to each section. Axes: layout (column, toc), quotes (show, hide), tone. Highlighting the section being read is a port contract.\n    Props (p): id, title, sections, empty, tocTitle, layout, quotes, tone, landmarkLabel. -#}\n{%- set v_id = og_def(p['id'], none) -%}\n{%- set v_title = og_def(p['title'], none) -%}\n{%- set v_sections = og_def(p['sections'], none) -%}\n{%- set v_empty = og_def(p['empty'], '') -%}\n{%- set v_tocTitle = og_def(p['tocTitle'], none) -%}\n{%- set v_layout = og_def(p['layout'], 'column') -%}\n{%- set v_quotes = og_def(p['quotes'], 'show') -%}\n{%- set v_tone = og_def(p['tone'], 'default') -%}\n{%- set v_landmarkLabel = og_def(p['landmarkLabel'], none) -%}\n{%- set c_13 -%}\n  {%- if og_t(og_eq(og_len(v_sections), 0)) %}\n    {{ og_include('blocks/empty-state.html.j2', {'p': {'icon': 'file-text', 'title': v_empty}}) }}\n  {%- else %}\n    {%- set c_12 -%}\n      {%- if og_t(og_eq(v_layout, 'toc')) %}\n        {%- set c_6 -%}\n          {%- set c_5 -%}\n            {%- set c_1 -%}\n              {{ og_text(v_tocTitle) }}\n            {%- endset -%}\n            {{ og_include('compose/text.html.j2', {'p': {'Size': 'sm', 'Weight': 'semibold'}, 'children': c_1}) }}\n            {%- set c_4 -%}\n              {%- for v_s in og_l(v_sections) %}\n                {%- set c_3 -%}\n                  {%- set c_2 -%}\n                    {{ og_text(og_get(v_s, ['title'])) }}\n                  {%- endset -%}\n                  {{ og_include('compose/link.html.j2', {'p': {'Href': og_url(og_s(og_tpl('#{0}-{1}', [v_id, og_get(v_s, ['id'])]))), 'Variant': 'default', 'Class': 'text-sm text-muted-foreground', 'Attrs': og_attrs(['data-slot', 'toc-link'])}, 'children': c_2}) }}\n                {%- endset -%}\n                {{ og_include('compose/list-item.html.j2', {'p': {'Attrs': og_attrs(['data-slot', 'sections-row'])}, 'children': c_3}) }}\n              {%- endfor %}\n            {%- endset -%}\n            {{ og_include('compose/list.html.j2', {'p': {'Class': 'm-0 flex list-none flex-col gap-2 p-0'}, 'children': c_4}) }}\n          {%- endset -%}\n          {{ og_include('compose/stack.html.j2', {'p': {'Gap': '2'}, 'children': c_5}) }}\n        {%- endset -%}\n        {{ og_include('blocks/nav-block.html.j2', {'p': {'label': (og_uniq(og_tpl('{0}, {1}', [v_tocTitle, v_landmarkLabel])) if og_t(v_landmarkLabel) else v_tocTitle), 'className': og_cnv(['md:sticky md:top-4']), 'testid': 'toc'}, 'children': og_markup(c_6)}) }}\n      {%- endif %}\n      {%- set c_11 -%}\n        {%- for v_s in og_l(v_sections) %}\n          {%- set c_10 -%}\n            {%- set c_7 -%}\n              {{ og_text(og_get(v_s, ['title'])) }}\n            {%- endset -%}\n            {{ og_include('compose/title.html.j2', {'p': {'As': 3, 'Size': '2xl', 'Weight': 'bold'}, 'children': c_7}) }}\n            {%- set c_8 -%}\n              {{ og_text(og_get(v_s, ['text'])) }}\n            {%- endset -%}\n            {{ og_include('compose/text.html.j2', {'p': {'Size': 'base'}, 'children': c_8}) }}\n            {%- if og_t(og_eq(v_quotes, 'show')) %}\n              {%- if og_t(og_get(v_s, ['quote'])) %}\n                {%- set c_9 -%}\n                  {{ og_text(og_get(v_s, ['quote'])) }}\n                {%- endset -%}\n                {{ og_include('compose/text.html.j2', {'p': {'Tag': 'blockquote', 'Class': 'm-0 border-l border-border pl-4 text-lg', 'Attrs': og_attrs(['data-slot', 'quote'])}, 'children': c_9}) }}\n              {%- endif %}\n            {%- endif %}\n          {%- endset -%}\n          {{ og_include('compose/box.html.j2', {'p': {'Class': 'flex flex-col gap-4', 'Attrs': og_attrs(['id', og_tpl('{0}-{1}', [v_id, og_get(v_s, ['id'])]), 'data-slot', 'item'])}, 'children': c_10}) }}\n        {%- endfor %}\n      {%- endset -%}\n      {{ og_include('compose/stack.html.j2', {'p': {'Gap': '8', 'Align': 'stretch', 'Class': 'mx-auto w-full max-w-2xl min-w-0', 'Attrs': og_attrs(['data-slot', 'article'])}, 'children': c_11}) }}\n    {%- endset -%}\n    {{ og_include('compose/grid.html.j2', {'p': {'Cols': '1', 'Class': og_s(og_cnv(['items-start gap-8', ('md:grid-cols-[14rem_minmax(0,1fr)]' if og_t(og_eq(v_layout, 'toc')) else '')]))}, 'children': c_12}) }}\n  {%- endif %}\n{%- endset -%}\n{{ og_include('blocks/section-frame.html.j2', {'p': {'id': v_id, 'title': v_title, 'tone': v_tone, 'landmarkLabel': v_landmarkLabel}, 'children': og_markup(c_13)}) }}\n",
      "path": "blocks/article-body.html.j2",
      "target": "blocks/article-body.html.j2"
    }
  ],
  "meta": {
    "category": "content",
    "group": "blog",
    "kind": "block",
    "tags": [
      "jinja2",
      "block"
    ]
  },
  "name": "article-body",
  "registryDependencies": [
    "box",
    "empty-state",
    "grid",
    "link",
    "list",
    "list-item",
    "nav-block",
    "section-frame",
    "stack",
    "text",
    "title",
    "utils"
  ],
  "runtime": "jinja2",
  "title": "Article Body",
  "type": "registry:block"
}
