{% extends "django_spellbook/bases/sidebar_left.html" %}
{% load spellbook_tags %}

{% block spellbook_md %}
    <div class="sb-directory-index">
        <!-- Back to Parent Directory -->
        {% if parent_dir_url %}
        <div class="sb-mb-3">
            <a href="/{{ parent_dir_url }}"
               class="sb-flex sb-items-center sb-gap-1 sb-text-sm sb-secondary sb-no-underline sb-hover:primary sb-transition">
                <span>←</span>
                <span>{{ parent_dir_name }}</span>
            </a>
        </div>
        {% endif %}

        <h2 class="sb-text-2xl sb-mb-4 sb-font-bold sb-text-text">{{ directory_name }}</h2>
        {% include "django_spellbook/directory_index/listing.html" %}
    </div>
{% endblock %}
