{% load i18n wagtailadmin_tags %}
{% if page_types_restricted %}
    {% trans "Choose" as choose_str %}
{% else %}
    {% trans "Choose a page" as choose_str %}
{% endif %}

{% include "wagtailadmin/shared/header.html" with title=choose_str subtitle=page_type_names|join:", " search_url="wagtailadmin_choose_page_search" query_parameters="page_type="|add:page_type_string icon="doc-empty-inverse" %}

<div class="nice-padding">
    {% include 'wagtailadmin/chooser/_link_types.html' with current='internal' %}

    {% if page_types_restricted %}
        <p class="help-block help-warning">
            {% icon name='warning' %}
            {% blocktrans trimmed with type=page_type_names|join:", " count counter=page_type_names|length %}
                Only pages of type "{{ type }}" may be chosen for this field. Search results will exclude pages of other types.
            {% plural %}
                Only the following page types may be chosen for this field: {{ type }}. Search results will exclude pages of other types.
            {% endblocktrans %}
        </p>
    {% endif %}

    <div class="page-results">
        {% include 'wagtailadmin/chooser/_browse_results.html' %}
    </div>
</div>
