{% comment %} The detail panel, swapped into #media-detail. Every mutation here returns a 204 with a `mediaChanged` event, so the grid refreshes itself and this panel does not have to know it exists. {% endcomment %} {% load media_library %}
{{ asset.id }}{% media_url asset %}
{% if can_manage %} {% comment %} hx-swap="none" on all three: they answer 204 and carry their result in HX-Trigger. Without it htmx swaps the response into the form itself, so an unexpected body — a session-expiry redirect to the login page, say — is injected into the panel. {% endcomment %} {% endif %}