
<!-- header -->

<!-- embed -->
<div class="temp-embed"></div>

<!-- large header bg image -->
<div class="bgimage"></div>

<!-- wrapper & responsive navigation -->
<div class="wrapper clearfix">
  <div class="main-navigation-inner clearfix inner">

<!-- service-navigation vlaanderen-->
<ul id="service-navigation" class="clearfix">
  {% set default_service_nav = [
    ('home', 'Home Onroerend Erfgoed', 'http://www.onroerenderfgoed.be')
    ]
  -%}
  {% set service_nav = service_nav|default(default_service_nav) -%}
  {% for id, caption, href in service_nav %}
    <li><a href="{{ href }}">{{ caption }}</a></li>
  {% endfor %}
</ul>

{% set home_link = home_link|default('/') -%}
<!-- logo -->
<div class="logo-block">
  <a href="{{ home_link }}">
    {% set active_title= active_title|default('Erfgoedstijl') -%}
    <div class="logo-block-title"><h1>{{active_title}}</h1></div>
    <img src="{{ request.static_path(app_package + ':static/img/pyoes/OE-vlaanderen-logo.png') }}" width="65">
    <h2>Vlaanderen</h2>
    <h4>is Onroerend Erfgoed</h4>
  </a>
</div>

  </div>
</div>

<!-- navigation -->
{% block main_nav %}
  <nav class="top-bar" data-topbar role="navigation">
    <ul class="title-area">
      <li class="name">  
      </li>
      <li class="toggle-topbar menu-icon"><a href="#"><span>menu</span></a></li>
    </ul>
    <section class="top-bar-section inner-nav">
      {% set active_main_nav = active_main_nav|default('home') -%}
      {% set default_main_nav = [
        ('home', 'Home', '/'), 
        ('zoeken', 'Zoeken', '/'),
        ('vinden', 'Vinden', '/')
        ]
      -%}

      {% set default_login_nav = [('Aanmelden', '/')] %}
      {% set default_login_sub_nav = [('Profiel', '/'), ('Afmelden', '/')] %}

      {% set main_nav = main_nav|default(default_main_nav) -%}

      <ul class="left">
        {% for id, caption, href in main_nav %}
            <li{% if id == active_main_nav %} class="active"{% endif
            %}><a href="{{ href }}">{{ caption }}</a></li>
        {% endfor %}
      </ul>

      {% set login_nav = login_nav|default(default_login_nav) -%}
      {% set login_sub_nav = login_sub_nav|default(default_login_sub_nav) -%}

      {% if login_nav|length > 0 %}
        {% if not request.user %}
          <ul class="right">
           {% if request.authenticated_userid != None %}
            <li class="has-dropdown">
              <a href="#">{{ request.authenticated_userid }}</a>
              <ul class="dropdown">
           {% endif %}
               {% for caption, href in login_nav %}
                <li><a href="{{ href }}">{{ caption }}</a></li>
               {% endfor %}
           {% if request.authenticated_userid != None %}
              </ul></li>
           {% endif %}
          </ul>
        {% else %}
          <ul class="right">
            <li class="has-dropdown">
              <a href="#">{{ request.user.userid }}</a>
              <ul class="dropdown">
                 {% for caption, href in login_sub_nav %}
                  <li><a href="{{ href }}">{{ caption }}</a></li>
                 {% endfor %}
              </ul>
            </li>
          </ul>
        {% endif %}
      {% endif %}

    </section>
  </nav>
{% endblock %}

<!-- end header -->


