<nav class="navbar fixed-top navbar-expand-md navbar-dark bg-dark bg-gray-900 mb-4">
      <a class="navbar-brand" href="/">Scrapydd</a>
      <button class="navbar-toggler" type="button" data-toggle="collapse" data-target="#navbarCollapse" aria-controls="navbarCollapse" aria-expanded="false" aria-label="Toggle navigation">
        <span class="navbar-toggler-icon"></span>
      </button>
      <div class="collapse navbar-collapse" id="navbarCollapse">
        <ul class="navbar-nav mr-auto">
          <li class="nav-item">
            <a class="nav-link" href="/spiders">Spiders</a>
          </li>
          <li class="nav-item">
            <a class="nav-link" href="/jobs">Jobs</a>
          </li>
          {% if current_user.is_admin %}
            <li class="nav-item">
            <a class="nav-link" href="/admin/nodes">Nodes</a>
          </li>
          {% end %}
        </ul>
        <ul class="navbar-nav">
          <li class="nav-item dropdown">
            <a class="nav-link dropdown-toggle" href="#" id="navbarDropdownMenuLink" role="button" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false">
              New
            </a>
            <div class="dropdown-menu" aria-labelledby="navbarDropdownMenuLink">
              <a class="dropdown-item" href="/uploadproject">Upload project</a>
            </div>
          </li>
          <li class="nav-item dropdown">
            <a class="nav-link dropdown-toggle" href="#" id="profileDropdownMenuLink" role="button" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false">
              {{ current_user.username }}
            </a>
            <div class="dropdown-menu dropdown-menu-right" aria-labelledby="profileDropdownMenuLink">
              <a class="dropdown-item" href="/profile">Profile</a>
              {% if current_user.is_admin %}
              <a class="dropdown-item" href="/admin">System Settings</a>
              {% end %}
              <div class="dropdown-divider"></div>
              <a class="dropdown-item" href="/logout">Logout</a>
            </div>
          </li>
        </ul>
      </div>
    </nav>