{% extends "admin/change_form.html" %}
{% load i18n admin_modify static filer_admin_tags %}

{% block breadcrumbs %}
    <div class="breadcrumbs">
        <a href="{% url 'admin:index' %}" title="{% translate 'Go back to' %} {% translate 'admin homepage' %}">{% translate "Home" %}</a>
        &rsaquo; <a href="{% url 'admin:app_list' app_label='filer' %}" title="{% translate 'Go back to' %} {% translate 'Filer' %}"> {% translate "Filer" %}</a>
        &rsaquo; <a href="{% url 'admin:filer-directory_listing-root' %}" title="{% translate 'Go back to' %} '{% translate 'root'|title %}' {% translate 'folder' %}">{% translate "root"|title %}</a>
        {% for ancestor_folder in original.logical_path %}
            &rsaquo; <a href="{% url 'admin:filer-directory_listing' ancestor_folder.id %}" title="{% blocktrans with ancestor_folder.name as folder_name %}Go back to '{{ folder_name }}' folder{% endblocktrans %}">{{ ancestor_folder.name }}</a>
        {% endfor %}
        &rsaquo; {{ original.name }}
    </div>
{% endblock %}

{% block coltype %}{% if is_popup %}colM{% else %}colMS{% endif %}{% endblock %}

{% block object-tools %}
    {% if change and not is_popup %}
        <ul class="object-tools">
            <li><a href="{% url history_url object_id %}" class="historylink">{% translate "History" %}</a></li>
            {% if has_absolute_url %}
                <li><a href="../../../r/{{ content_type_id }}/{{ object_id }}/" class="viewsitelink">{% translate "View on site" %}</a></li>
            {% endif%}
        </ul>
    {% endif %}
{% endblock %}

{% block after_field_sets %}
    {% filer_admin_context_hidden_formfields %}
{% endblock %}

{% block sidebar %}
    {% if not is_popup %}
        <div id="content-related">
            <div id="navcontainer">
                <img src="{% static 'filer/icons/folder.svg' %}" alt="{% translate 'Folder Icon' %}" width="128" height="128" />
            </div>
        </div>
    {% endif %}
{% endblock %}
