{%- extends "_layout.html" %}

{%- block content %}

            <!-- Item action confirmation form styled as bootstrap modal dialog. -->
            <div class="modal position-static d-block">

                <div class="modal-dialog">
                    <div class="modal-content">

                        <div class="modal-header">
                            <h4 class="modal-title">
                                {{ get_icon('modal-question') }} {{ hawat_current_view.get_view_title() }}
                            </h4>
                        </div>

                        <div class="modal-body">
                        {%- block modalcontent %}{%- endblock modalcontent %}
                        </div>

                        <div class="modal-footer">
                            <form method="POST" action="{{ confirm_url }}">
                                {{ macros_form.render_form_errors(confirm_form.next.errors) }}
                                {{ confirm_form.next }}
                                {#- CSRF option may be turned off, for example for unit testing. #}
                                {%- if 'csrf_token' in confirm_form %}
                                {{ macros_form.render_form_errors(confirm_form.csrf_token.errors) }}
                                {{ confirm_form.csrf_token }}
                                {%- endif %}
                                {% if referrer %}
                                <a href="{{ referrer }}" class="btn btn-secondary">{{ _('Cancel') }}</a>
                                {% endif %}
                                {{ confirm_form.submit(class_='btn btn-primary') }}
                            </form>
                        </div>

                    </div><!-- /.modal-content -->
                </div><!-- /.modal-dialog -->
            </div>

{% endblock content %}
