{% extends "wagtailadmin/base.html" %}
{% load i18n %}
{% load wagtailadmin_tags %}

{% block bodyclass %}menu-explorer{% endblock %}
{% block titletag %}{% blocktrans with title=parent_page.title %}Create a page in {{ title }}{% endblocktrans %}{% endblock %}

{% block content %}
    {% trans "Create a page in" as create_str %}
    {% include "wagtailadmin/shared/header.html" with title=create_str subtitle=parent_page.title icon="doc-empty-inverse" %}

    <div class="nice-padding">
        <p>{% trans "Choose which type of page you'd like to create." %}</p>

        {% if page_types %}
            <ul class="listing">
                {% for content_type in page_types %}
                    <li>
                        <div class="row row-flush">
                            <div class="col6">
                                <a href="{% url 'wagtailadmin_pages_create' content_type.app_label content_type.model parent_page.id %}" class="icon icon-plus-inverse icon-larger">{{ content_type.model_class.get_verbose_name }}</a>
                            </div>

                            <small class="col6" style="text-align:right">
                                {{ content_type|meta_description }}
                                <a href="{% url 'wagtailadmin_pages_type_use' content_type.app_label content_type.model %}" class="nolink">{% blocktrans with page_type=content_type.model_class.get_verbose_name %}Pages using {{ page_type }}{% endblocktrans %}</a>
                            </small>
                            
                        </div>
                    </li>
                {% endfor %}
            </ul>
        {% endif %}
    </div>
{% endblock %}
