{% extends "includes/user-info.html" %}

{% block user-info %}
  <li class="toplinks--list-item toplinks--list-item-home">
    <span class="theme-back-home">
      <a href="{{portal_url}}" title="retour à l’accueil">Accueil</a>
    </span>
  </li>

  {% if user.is_authenticated %}
    <ul class="toplinks--sublist toplinks--sublist--logged-in">
      <li class="toplinks--sublist-item">
        {% if account_url %}<a class="account-link" href="{{ account_url }}">{% endif %}
        <span class="connected-user">{% block user-info-user-name %}{{user.first_name}} {{user.last_name}}{% endblock %}</span>{% if account_url %}</a>{% endif %}
      </li>
      <li class="toplinks--sublist-item">
        <a accesskey="o" class="logout" href="{{ logout_url }}">{% block user-info-logout-label %}Déconnexion{% endblock %}</a>
      </li>
    </ul>
  {% else %}
    <ul class="toplinks--sublist toplinks--sublist--login">
      <li class="toplinks--sublist-item">
        <span class="login"><a accesskey="2" class="login-link" href="{{ login_url }}"
        >{% block user-info-login-label %}Connexion{% endblock %}
          {% if registration_url and include_registration_link != False %}</a>{% endif %}
        </li>
          <li class="toplinks--sublist-item">
            {% if registration_url and include_registration_link != False %}<a class="registration" href="{{registration_url}}"
            >{% block user-info-registration-label %}Inscription{% endblock %}{% endif %}</a></li>
      </ul>
  {% endif %}
{% endblock %}
