<div id="admin-media" class="files js__files card-row grid fixed-blocks pure-g">
    {% if not is_modal %}
        {% include 'partials/media-list-wrapper__list__dropzone.html.twig' ignore missing %}
    {% endif %}

    {% if admin.files is empty %}
        <div class="empty-state">
            {% if (uri.param('type') or uri.param('date')) %}
                <h2>Filtering by {{ uri.param('type') }} {{ uri.param('date') }}</h2>
            {% endif %}

            <h2>No media files found</h2>

            <p>You need to add media to a page in order to display it here.</p>
        </div>
    {% else %}
        {% include 'media-list-content.html.twig' with { is_modal: is_modal } %} {# not a partial as used by AJAX #}
    {% endif %}

    {{ nonce_field('admin-form', 'admin-nonce')|raw }}
</div>

{% include 'partials/spinning-wheel.html.twig' %}
