{% extends "admin/change_form.html" %}
{% load static i18n %}
{% block extrahead %}{{ block.super }}
{% if not dar_is_unfold %}
{% endif %}
{% endblock %}
{% block footer %}{{ block.super }}
{% if not dar_is_unfold %}
{% endif %}
{# Stop / Force Stop — server-rendered when RUNNING, live-updated by #}
{# terminal-output.js (PENDING → RUNNING transition inserts it without reload). #}
{# The container is always present so the widget can populate it later. #}
{% if dar_stop_url %}
{% if dar_stop_force %}{% trans "Force Stop" %}{% else %}{% trans "Stop" %}{% endif %}
{% endif %}
{% if dar_rerun_url %}
{# The submit row is rendered by an inclusion tag, so blocks cannot inject #}
{# into it — render the link here and move it into the row (first child = #}
{# rightmost slot in both themes: float-right / flex-row-reverse). #}
{% if dar_rerun_running %}
{% trans "Rerun" %}
{% else %}
{% trans "Rerun" %}
{% endif %}
{% endif %}
{% endblock %}