Template source: header.html

{% load staticfiles accounts_tags front_tags publication_tags mptt_tags languages_tags i18n cache notification_tags %} {% get_master_category %} {% url 'trending' as trending %} <header class="{% if user.is_authenticated or user.is_staff %}logged-in{% endif %}"> <nav id="main-nav" class="navbar"> <div class="container-fluid containerpadding whitebg"> <a class="box-logo logo {% if cat_color_class %}{{ cat_color_class }}-bg{% else %}mainbg{% endif %}" href="{% url 'home' %}"><img src="/static/dist/images/logo.png"></a> <div class="user-actions-group"> <ul id="user-actions" class="nav navbar-nav"> {% if user.is_author or user.is_staff %} {% load_notifications %} {% endif %} {% if not request.user.is_authenticated %} <li id="btn-login" class="social-icon-nav visible-xs"> <a href="#" target="_blank" data-toggle="modal" data-target="#modal-login"> <i class="fa fa-sign-in" aria-hidden="true"></i> {% trans "Login" %} </a> </li> {% endif %} </ul> </div> <ul id="searching-container" class="nav navbar-nav nav-center hidden-xs"> {% include "_search_form.html" %} </ul> </div> </nav> <nav id="secondary-nav" class="navbar"> <div class="container-fluid containerpadding"> <ul id="cat-nav" class="nav navbar-nav"> <li class="menu-left"><a href="{% url 'trending' %}" class="cat-red-hover {% ifequal request.path trending %}active{% endifequal %} "><i class="fa fa-line-chart"></i> {% trans "Trending" %}</a></li> <li class="menu-left"><a href="{% url 'viral' %}" class="cat-red-hover {% ifequal request.path trending %}active{% endifequal %} "><i class="fa fa-line-chart"></i> {% trans "Viral" %}</a></li> {% for category in master_category %} {% if category.slug in city_category_slugs %} {% include '_city_category_dropdown.html' %} {% else %} <li class="menu-left"><a href="{% url 'category_single' category.slug %}" class="{{ category.get_color_class }}-hover {% if request.path|get_cat_from_path:category.slug %}active{% endif %} ">{{ category.title }}</a></li> {% endif %} {% endfor %} {# {% video_categories %} #} <li class="menu-left"> <a class="more" id="more" href="#">{% trans "More" %} <i class="fa fa-angle-down"></i> </a> </li> </ul> <ul id="mobile-nav" class="nav navbar-nav nav-right"> <li id="search-form" class="social-icon-nav visible-xs"> {% include "_search_form.html" %} </li> <li id="language-nav" class="social-icon-nav"> {% language_selector %} </li> <li id="more-mobile-el" class="social-icon-nav"> <a id="more-mobile" href="#"> <i class="fa fa-bars"></i> </a> </li> </ul> <ul id="extra-tools" class="nav navbar-nav nav-right hidden-xs"> {% if user.is_author %} <li class="social-icon-nav"> <a href="{% url 'tips' %}"> <i class="fa fa-lightbulb-o" aria-hidden="true"></i> {% trans "Tips" %} </a> </li> {% endif %} {% if user.is_authenticated and user.is_staff %} <li class="social-icon-nav"> <a href="{% url 'admin:index' %}"> <i class="fa fa-lock" aria-hidden="true"></i> {% trans "Admin" %} </a> </li> <li class="social-icon-nav"> <a href="{% url 'admin:publications_article_add' %}"> <i class="fa fa-plus" aria-hidden="true"></i> {% trans "New Article" %} </a> </li> {% endif %} {% if user.is_authenticated %} <li class="social-icon-nav"> <a href="{% url 'account_logout' %}"> <i class="fa fa-sign-out" aria-hidden="true"></i> {% trans "Logout" %} </a> </li> {% endif %} {% if not request.user.is_authenticated %} <li class="social-icon-nav"> <a href="#" target="_blank" data-toggle="modal" data-target="#modal-login"> <i class="fa fa-sign-in" aria-hidden="true"></i> {% trans "Login" %} </a> </li> {% endif %} </ul> <div class="topmenu hide" id="topbar-menu"> <div class="container-fluid containerpadding"> <div class="box-submenu"> {% for category in master_category %} {% if category.slug != 'city' and category.slug != 'ville' and category.slug != 'ciudad' %} <div class="list-submenu"> <div class="title-submenu" data-color="{{ category.get_color_class }}"> <h2> <a href="{% url 'category_single' category.slug %}">{{ category.title }}</a> </h2> </div> <ul> {% for sub_category in category.get_children|cache_tree_children %} <li> <a href="{% url 'category_single' sub_category.slug %}">{{ sub_category.title }}</a> </li> {% endfor %} </ul> </div> {% endif %} {% endfor %} </div> </div> </div> </div> </nav> </header> <div class="topmenu hide" id="topbar-menu-mobile"> <div class="container-fluid containerpadding"> <div class="box-submenu"> <div class="list-submenu"> <div class="title-submenu" data-color="cat-red"> <h2> <a href="{% url 'trending' %}" class="{% ifequal request.path trending %}active{% endifequal %} "><i class="fa fa-line-chart"></i> {% trans "Trending" %}</a> </h2> </div> </div> <div class="list-submenu"> <div class="title-submenu" data-color="cat-red"> <h2> <a href="{% url 'viral' %}" class="{% ifequal request.path trending %}active{% endifequal %} "><i class="fa fa-line-chart"></i> {% trans "Viral" %}</a> </h2> </div> </div> {% for category in master_category %} <div class="list-submenu"> <div class="title-submenu" data-color="{{ category.get_color_class }}"> <h2> <a {% if category.slug in city_category_slugs %}id="city-mobile"{% endif %} href="{% url 'category_single' category.slug %}"> {{ category.title }} </a> </h2> </div> <ul> {% for sub_category in category.get_children|cache_tree_children %} <li><a href="{% url 'category_single' sub_category.slug %}">{{ sub_category.title }}</a> </li> {% endfor %} </ul> </div> {% endfor %} {# {% video_categories_mobile %} #} </div> </div> </div>