{% comment %} Panel header for the Device "Module Bays" tab: the standard table title/count badge plus an "Expand all"/"Collapse all" toggle. The toggle fetches the module-bays distinct-view URL with (or without) `expand_all=true` — that URL is required because the tab's panels only render when the request path matches it — extracts just this panel from the response (`hx-select`), swaps it in place, and pushes the URL so the state survives a full reload and is shareable. {% endcomment %} {% include "components/panel/header_extra_content_table.html" %} {% if module_bays_have_nesting or expand_all %} {% if expand_all %} Collapse All {% else %} Expand All {% endif %} {% endif %}