{% load i18n apphooks_config_tags %}

<div class="aldryn aldryn-dashboards_app aldryn-dashboards_app-tags">
    <ul class="list-unstyled">
        <li{% if not dashboards_app_tag %} class="active"{% endif %}>
            <a href="{% namespace_url "dashboard-list" namespace=instance.app_config.namespace default='' %}">{% trans "All" %}</a>
        </li>
        {% for tag in tags %}
            <li{% if dashboards_app_tag.id == tag.id %} class="active"{% endif %}>
                <a href="{% namespace_url "dashboard-list-by-tag" tag.slug namespace=instance.app_config.namespace default='' %}">
                    {{ tag.name }}
                    <span class="badge">{{ tag.dashboard_count }}</span>
                </a>
            </li>
        {% endfor %}
    </ul>
</div>
