{% macro header(id=False, oob=False) %}
  <div
      {% if id %}id="{{id}}"{% endif %}
    {% if oob %}hx-swap-oob="outerHTML"{% endif %}
    class="w-full"
  >
    {{ caller() }}
  </div>
{% endmacro %}


{% macro oob_header(id, child_id, row_macro) %}
  {% call header(id=id, oob=True) %}
    {% call header() %}
      {% from row_macro import header_row with context %}
      {{header_row()}}
      <div id="{{child_id}}">    
      </div>
    {% endcall %}
  {% endcall %}
{% endmacro %}


{% macro index_row(id, row_macro) %}
  {% from '_types/root/_n/macros.html' import header with context %}
  {% set _caller = caller %}
  {% call header() %}
    {% from row_macro import header_row with context %}
    {{ header_row() }}
    <div id="{{id}}">
      {{_caller()}}  
    </div>
  {% endcall %}

{% endmacro %}