{% load i18n admin_urls %}
<div class="submit-row btn-toolbar justify-content-between">
    {% block submit-row %}
        <div class="btn-group me-2" role="group" aria-label="Save group">
            {% if show_save %}
                <input type="submit"
                       value="{% translate "Save" %}"
                       class="btn btn-primary "
                       name="_save"/>
            {% endif %}
            {% if show_save_as_new %}
                <input class="btn btn-primary"
                       type="submit"
                       value="{% translate "Save as new" %}"
                       name="_saveasnew"/>
            {% endif %}
            {% if show_save_and_add_another %}
                <input class="btn btn-primary"
                       type="submit"
                       value="{% translate "Save and add another" %}"
                       name="_addanother"/>
            {% endif %}
            {% if show_save_and_continue %}
                <input class="btn btn-primary"
                       type="submit"
                       value="{% if can_change %}{% translate "Save and continue editing" %}{% else %}{% translate "Save and view" %}{% endif %}"
                       name="_continue"/>
            {% endif %}
            {% if show_close %}
                <div class="btn-group me-2" role="group" aria-label="Close group">
                    <a href="{% url opts|admin_urlname:'changelist' %}"
                    class="btn btn-secondary closelink">{% translate "Close" %}</a>
                </div>
            {% endif %}
        </div>
        {% if show_delete_link and original %}
            {% url opts|admin_urlname:'delete' original.pk|admin_urlquote as delete_url %}
            <div class="btn-group me-2" role="group" aria-label="Delete group">
                <a class="btn btn-danger deletelink"
                   href="{% add_preserved_filters delete_url %}">{% translate "Delete" %}</a>
            </div>
        {% endif %}
    {% endblock submit-row %}
</div>
