{
  "$schema": "https://registry.buildy.tw/schema/registry-item.json",
  "dependencies": [],
  "description": "Questions as native disclosures.",
  "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/faq-list.json\n    A section with a heading and the questions. Axes: layout (accordion: native disclosures that open without script; chat: question and answer as alternating bubbles), columns (1, 2), search mode (none, field: a search field above; the page filters by `search.query`), filter mode (none, categories: tabs above; the page filters by `filter.category`), density, tone.\n    Props (p): id, title, items, search, filter, layout, cols, empty, multiple, tone, density, landmarkLabel. -#}\n{%- set v_id = og_def(p['id'], none) -%}\n{%- set v_title = og_def(p['title'], none) -%}\n{%- set v_items = og_def(p['items'], none) -%}\n{%- set v_search = og_def(p['search'], none) -%}\n{%- set v_filter = og_def(p['filter'], none) -%}\n{%- set v_layout = og_def(p['layout'], 'accordion') -%}\n{%- set v_cols = og_def(p['cols'], '1') -%}\n{%- set v_empty = og_def(p['empty'], '') -%}\n{%- set v_multiple = og_def(p['multiple'], false) -%}\n{%- set v_tone = og_def(p['tone'], 'default') -%}\n{%- set v_density = og_def(p['density'], 'default') -%}\n{%- set v_landmarkLabel = og_def(p['landmarkLabel'], none) -%}\n{%- set v_inCategory = og_where(v_items, 'category', og_get(v_filter, ['category'])) -%}\n{%- set v_shown = og_match(v_inCategory, 'question', og_get(v_search, ['query'])) -%}\n{%- set c_13 -%}\n  {%- if og_t(og_eq(og_get(v_search, ['mode']), 'field')) %}\n    {{ og_include('blocks/search-field.html.j2', {'p': {'label': og_coalesce([og_get(v_search, ['label']), '']), 'placeholder': og_get(v_search, ['label']), 'value': og_coalesce([og_get(v_search, ['query']), ''])}}) }}\n  {%- endif %}\n  {%- if og_t(og_eq(og_get(v_filter, ['mode']), 'categories')) %}\n    {%- set c_2 -%}\n      {%- for v_tab in og_l(og_get(v_filter, ['tabs'])) %}\n        {%- set c_1 -%}\n          {{ og_text(og_get(v_tab, ['title'])) }}\n        {%- endset -%}\n        {{ og_include('blocks/switcher-item.html.j2', {'p': {'active': og_eq(og_get(v_tab, ['value']), og_get(v_filter, ['category']))}, 'children': og_markup(c_1)}) }}\n      {%- endfor %}\n    {%- endset -%}\n    {{ og_include('blocks/switcher.html.j2', {'p': {'label': og_get(v_filter, ['label'])}, 'children': og_markup(c_2)}) }}\n  {%- endif %}\n  {%- if og_t(og_eq(og_len(v_shown), 0)) %}\n    {{ og_include('blocks/empty-state.html.j2', {'p': {'icon': 'circle-question-mark', 'title': v_empty}}) }}\n  {%- endif %}\n  {%- if og_t(og_eq(v_layout, 'chat')) %}\n    {%- set c_8 -%}\n      {%- for v_item in og_l(v_shown) %}\n        {%- set c_7 -%}\n          {%- set c_4 -%}\n            {%- set c_3 -%}\n              {{ og_text(og_get(v_item, ['question'])) }}\n            {%- endset -%}\n            {{ og_include('compose/text.html.j2', {'p': {'Size': 'sm', 'Weight': 'semibold'}, 'children': c_3}) }}\n          {%- endset -%}\n          {{ og_include('compose/box.html.j2', {'p': {'Class': 'ml-auto max-w-xs sm:max-w-md rounded bg-primary px-4 py-4 text-primary-foreground'}, 'children': c_4}) }}\n          {%- set c_6 -%}\n            {%- set c_5 -%}\n              {{ og_text(og_get(v_item, ['answer'])) }}\n            {%- endset -%}\n            {{ og_include('compose/text.html.j2', {'p': {'Size': 'sm'}, 'children': c_5}) }}\n          {%- endset -%}\n          {{ og_include('compose/box.html.j2', {'p': {'Class': 'mr-auto max-w-xs sm:max-w-md rounded bg-muted px-4 py-4'}, 'children': c_6}) }}\n        {%- endset -%}\n        {{ og_include('compose/stack.html.j2', {'p': {'Gap': '2', 'Align': 'stretch', 'Attrs': og_attrs(['data-slot', 'faq-item'])}, 'children': c_7}) }}\n      {%- endfor %}\n    {%- endset -%}\n    {{ og_include('compose/stack.html.j2', {'p': {'Gap': '4', 'Align': 'stretch', 'Attrs': og_attrs(['data-slot', 'faq'])}, 'children': c_8}) }}\n  {%- else %}\n    {%- set c_12 -%}\n      {%- for v_item in og_l(v_shown) %}\n        {%- set c_11 -%}\n          {%- set c_9 -%}\n            {{ og_text(og_get(v_item, ['question'])) }}\n          {%- endset -%}\n          {{ og_include('compose/summary.html.j2', {'p': {'Variant': 'item'}, 'children': c_9}) }}\n          {%- set c_10 -%}\n            {{ og_text(og_get(v_item, ['answer'])) }}\n          {%- endset -%}\n          {{ og_include('compose/text.html.j2', {'p': {'Size': 'sm', 'Class': 'pb-4 text-muted-foreground'}, 'children': c_10}) }}\n        {%- endset -%}\n        {{ og_include('compose/disclosure.html.j2', {'p': {'Variant': 'item', 'Name': og_s((none if og_t(v_multiple) else og_tpl('{0}-faq', [og_coalesce([v_id, 'faq'])]))), 'Attrs': og_attrs(['data-slot', 'faq-item'])}, 'children': c_11}) }}\n      {%- endfor %}\n    {%- endset -%}\n    {{ og_include('compose/grid.html.j2', {'p': {'Cols': og_s(('1-2' if og_t(og_eq(v_cols, '2')) else '1')), 'Class': 'items-start gap-x-8', 'Attrs': og_attrs(['data-slot', 'faq'])}, '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, 'density': v_density, 'measure': ('2xl' if og_t(og_eq(v_layout, 'chat')) else 'default'), 'landmarkLabel': v_landmarkLabel}, 'children': og_markup(c_13)}) }}\n",
      "path": "blocks/faq-list.html.j2",
      "target": "blocks/faq-list.html.j2"
    }
  ],
  "meta": {
    "category": "marketing",
    "group": "faq",
    "kind": "block",
    "tags": [
      "jinja2",
      "block"
    ]
  },
  "name": "faq-list",
  "registryDependencies": [
    "box",
    "disclosure",
    "empty-state",
    "grid",
    "search-field",
    "section-frame",
    "stack",
    "summary",
    "switcher",
    "switcher-item",
    "text",
    "utils"
  ],
  "runtime": "jinja2",
  "title": "Faq List",
  "type": "registry:block"
}
