{% extends "wagtailadmin/base.html" %}

{% load static wagtailadmin_tags i18n %}

{% block titletag %}{{ action_title }}{% endblock %}

{% block extra_css %}
    <link rel="stylesheet" href="{% static 'wagtail_fedit/css/admin.css' %}">
{% endblock %}

{% block content %}
    {% include "wagtailadmin/shared/header.html" with title=action_title icon=view.get_header_icon %}

    <div class="nice-padding">
        <div class="wagtail-fedit-form-wrapper{% if form.block.block.meta.fedit_full %} fedit-full{% endif %}">
            <form id="wagtail-fedit-form" method="post">
                {% csrf_token %}

                {% panel id="wagtail-fedit-help-text" icon="help" heading=action_help_text_title %}
                    {% help_block status="warning" %}
                        {% for text in action_help_text %}
                            <p>{{ text }}</p>
                        {% endfor %}
                    {% endhelp_block %}
                {% endpanel %}

                <div class="wagtail-fedit-form-help">
                    <h2>{% translate "Are you sure you want to continue?" %}</h2>
                </div>

                <input type="hidden" name="action" value="{{ action }}" />

                <div class="wagtail-fedit-form-buttons">
                    <button type="submit" class="button button-primary button-large">
                        {{ action_text }}
                    </button>
                    <a href="{{ cancel_url }}" class="button no button-large">
                        {% translate "Cancel" %}
                    </a>
                </div>

            </form>
        </div>
    </div>
{% endblock %}