{% extends "./base_iframe.html" %}

{% load i18n wagtailadmin_tags %}

{% block content %}
    <div class="wagtail-fedit-form-wrapper{% if form.block.block.meta.fedit_full %} fedit-full{% endif %}">

        {{ block.super }}

        <form id="wagtail-fedit-form" data-edit-form action="{{ edit_url }}" method="post" {% for k, v in form_attrs.items %}{{ k }}="{{ v|safe }}" {% endfor %}>
            {% csrf_token %}
            {% block form %}
                {% panel id="wagtail-fedit-editor" icon="draft" heading=meta_field.verbose_name %}
                    <div class="wagtail-fedit-form">
                        {% for field in form %}
                            {% include "./field.html" %}
                        {% endfor %}
                    </div>
                {% endpanel %}
            {% endblock %}
        </form>
    </div>
{% endblock %}