{% set tab_panes = tab_panes | default({}) %} {% macro area_style_classes(style) -%} {%- if style.width %} cm-area-width-{{ style.width | e }}{% endif -%} {%- if style.gap %} cm-area-gap-{{ style.gap | e }}{% endif -%} {%- if style.padding %} cm-area-pad-{{ style.padding | e }}{% endif -%} {%- if style.surface %} cm-area-surface-{{ style.surface | e }}{% endif -%} {%- endmacro %} {% macro render_area(area) -%} {% set pane = tab_panes.get(area.id) %}
{% for block_id in area.blocks %} {% set resolved = ctx.blocks.get(block_id) %} {% if resolved %} {% set block = resolved.block %} {% include "block.html" %} {% endif %} {% endfor %} {% for child in area.areas %} {{ render_area(child) }} {% endfor %}
{%- endmacro %}
{{ render_area(spec.layout.root) }}
{# Package runtime bundles (grid-view, ag-grid-*) are host-loaded via grid_view_spec_assets; only host/domain GridViewTemplateAsset entries are emitted inline here. #} {% set _seen_ids = namespace(v=[]) %} {% for asset in (ctx.assets.config_assets + ctx.assets.block_assets) %} {% if not asset.id or asset.id not in _seen_ids.v %} {% if asset.id %}{% set _seen_ids.v = _seen_ids.v + [asset.id] %}{% endif %} {% if asset.kind == "script" %} {% elif asset.kind == "module" %} {% elif asset.kind == "style" %} {% endif %} {% endif %} {% endfor %}