<!DOCTYPE html>
<html lang="en">

<head>
  {% block title %}<title>Local Library</title>{% endblock %}
  <meta charset="utf-8">
  <meta name="viewport" content="width=device-width, initial-scale=1">

  <script src="https://ajax.googleapis.com/ajax/libs/jquery/2.1.1/jquery.min.js"></script>
  <link href="https://fonts.googleapis.com/icon?family=Material+Icons" rel="stylesheet">
  <!-- Compiled and minified CSS -->
  <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/materialize/1.0.0-beta/css/materialize.min.css">
  <!-- Compiled and minified JavaScript -->
  <script src="https://cdnjs.cloudflare.com/ajax/libs/materialize/1.0.0-beta/js/materialize.min.js"></script>
</head>

<body>

<div class="navbar-fixed">
  <nav>
    <div class="nav-wrapper row green darken-1">

      <ul class="right">
      {% if user.is_authenticated %}
        <li class="active"><a href="{{user.get_absolute_url}}"> {{ user.get_username }}</a></li>
        <li><a href="{% url 'logout'%}?next={{request.path}}">Logout</a></li>
      </ul>
      {% else %}
        <li><a href="{% url 'sign-up'%}?next={{request.path}}">Sign up</a></li>
        <li><a href="{% url 'login'%}?next={{request.path}}">Login</a></li>
      </ul>
      {% endif %}
    </div>
  </nav>
</div>
<div class="container">
  <div class="row">
    <div class="col s10 ">{% block content %}{% endblock %}</div>
  </div>
</div>

</body>

</html>