{% load static %}
{% load i18n %}
{% load navactive %}

<nav class="navbar navbar-default">
    <div class="container-fluid">
        <div class="navbar-header">
            <button type="button" class="navbar-toggle collapsed" data-toggle="collapse" data-target="#bs-example-navbar-collapse-1" aria-expanded="false">
                <span class="sr-only">{% trans "Toggle navigation" %}</span>
                <span class="icon-bar"></span>
                <span class="icon-bar"></span>
                <span class="icon-bar"></span>
            </button>
            <a class="navbar-brand" href="{% url 'standingsmanager:request_standings' %}">{{ app_title }}</a>
        </div>
        <div class="collapse navbar-collapse" id="bs-example-navbar-collapse-1">
            <ul class="nav navbar-nav">
                {% if perms.standingsmanager.add_syncedcharacter %}
                    <li class="{% navactive request 'standingsmanager:request_standings' %}">
                        <a href="{% url 'standingsmanager:request_standings' %}">
                            <i class="fas fa-user-plus"></i> Request Standings
                        </a>
                    </li>
                    <li class="{% navactive request 'standingsmanager:my_synced_characters' %}">
                        <a href="{% url 'standingsmanager:my_synced_characters' %}">
                            <i class="fas fa-sync"></i> My Synced Characters
                        </a>
                    </li>
                {% endif %}
                {% if perms.standingsmanager.approve_standings %}
                    <li class="{% navactive request 'standingsmanager:manage_requests' %}">
                        <a href="{% url 'standingsmanager:manage_requests' %}">
                            <i class="fas fa-tasks"></i> Manage Requests
                        </a>
                    </li>
                    <li class="{% navactive request 'standingsmanager:manage_revocations' %}">
                        <a href="{% url 'standingsmanager:manage_revocations' %}">
                            <i class="fas fa-user-times"></i> Manage Revocations
                        </a>
                    </li>
                    <li class="{% navactive request 'standingsmanager:view_standings' %}">
                        <a href="{% url 'standingsmanager:view_standings' %}">
                            <i class="fas fa-list"></i> View Standings
                        </a>
                    </li>
                {% endif %}
            </ul>
        </div>
    </div>
</nav>
