webseite/templates/header_slim.html
2021-02-18 19:21:18 +01:00

69 lines
3.3 KiB
HTML

{% extends "layout.html" %}
{% block header %}
<div class="header__top_box">
<div class="header__logo_box">
<a class="header__homelink" href="{{ '/'|url }}" title="Startseite">
<img class="header__logo" src="{{ '/images/wtf_logo.svg'|url }}" style="height: 7rem;">
</a>
</div>
<nav class="header__secondary_nav">
<ul class="secondary_nav__navlist">
<!--
<li class="secondary_nav__navitem">
<a class="secondary_nav__navlink" href="#">EN</a>
</li>
-->
<li class="secondary_nav__navitem">
<a class="secondary_nav__navlink" href="https://meta.vebit.xyz">Login</a>
</li>
</ul>
</nav>
</div>
<div class="header__slim_box">
<nav class="header__primary_nav">
<div class="primary_nav__toggle">
<svg viewBox="0 0 100 80" width="32" height="32">
<rect width="100" height="15"></rect>
<rect y="30" width="100" height="15"></rect>
<rect y="60" width="100" height="15"></rect>
</svg>
<p>menu</p>
</div>
<ul class="primary_nav__navlist">
{% for title, mapping in bag("navigation").items() %}
{% if mapping.visible|default(true) %}
<li class="primary_nav__navitem
{%- if this._path == mapping.href or mapping.href != '/' and this.is_child_of(mapping.href) %}
-active
{%- endif -%}
{%- if loop.index == 1 %}
-first
{%- endif -%}
">
<a class="primary_nav__navlink {% if this._path == mapping.href %}-active{% endif %}" href="{{ mapping.href|url }}">
{{ title }}
</a>
{% if mapping.list_childs %}
<ul class="primary_nav__sub_navlist">
{% set sub_menu = mapping['items'].items() %}
{% for sub_title, href in sub_menu %}
<li class="primary_nav__sub_navitem {%- if this._path == href %} -active{%- endif %}">
<a class="primary_nav__navlink {% if this._path == href %}-active{% endif %}" href="{{ href|url }}">
{{ sub_title }}
</a>
</li>
{% endfor %}
</ul>
{% endif %}
</li>
{% endif %}
{% endfor %}
</ul>
</nav>
<!-- background for header box - start -->
<div class="bg_box__top_bar_left"></div>
<div class="bg_box__top_bar_middle"></div>
<div class="bg_box__top_bar_right"></div>
{% endblock %}