htdocs/assets/templates/header.html

Summary

Maintainability
Test Coverage
<nav class="navbar navbar-inverse navbar-fixed-top" role="navigation">
  <div class="container-fluid">
    <div class="navbar-header">
      <button type="button" class="navbar-toggle collapsed" data-toggle="collapse" data-target="#main-navbar-collapse">
        <span class="sr-only">Toggle navigation</span>
        <span class="icon-bar"></span>
        <span class="icon-bar"></span>
        <span class="icon-bar"></span>
      </button>
      <a class="navbar-brand" href="/">{{ app_name }}</a>
    </div>

    <!-- Collect the nav links, forms, and other content for toggling -->
    <div class="collapse navbar-collapse" id="main-navbar-collapse">
      <ul class="nav navbar-nav">
        {{#each links}}
        <li><a href="{{ link }}" class="navbar-link-{{@index}}">{{ name }}</a></li>
        {{/each}}
      </ul>

      <ul class="nav navbar-nav navbar-right">
        <li class="dropdown">
          <a class="dropdown-toggle" data-toggle="dropdown" tabindex="0">{{#if name}}{{ name }}{{else}}Settings{{/if}} <b class="caret"></b></a>
          <ul class="dropdown-menu">
            {{#each sidelinks}}
              {{#if divider}}
              <li class="divider"></li>
              {{else}}
              <li><a {{#if link}}href="{{ link }}"{{/if}} tabindex="0" {{#if action}}class="{{ action }}-button"{{/if}}>{{ name }}</a></li>
              {{/if}}
            {{/each}}
          </ul>
        </li>
      </ul>

    </div>
  </div>
</nav>