<!DOCTYPE html>
<html lang="en">
  <head>
    <!-- meta tags -->
    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
    <meta name="description" content="Simple paste app friendly with browser and command line.">
    <meta name="author" content="Óscar García Amor">
    <meta name="keywords" content="lesma, paste, pastebin, sprunge, pastein, hastebin, friendly, command line">
    <meta name="url" content="{{ url_for('.index', _external=True) }}" itemprop="url">
    <meta property="og:title" content="lesma">
    <meta property="og:url" content="{{ url_for('.index', _external=True) }}">
    <meta property="og:description" content="Simple paste app friendly with browser and command line.">
    <meta property="og:image" content="{{ url_for('static', filename='img/favicon-512.png', _external=True) }}">
    <title>lesma{% if lesma_id %}/{{ lesma_id }}{% endif %}</title>

    <!-- Bootstrap CSS -->
    <link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/4.0.0-alpha.6/css/bootstrap.min.css" integrity="sha384-rwoIResjU2yc3z8GV/NPeZWAv56rSmLldC3R/AZzGRnGxQQKnKkoFVhFQhNUwEyJ" crossorigin="anonymous">

    <!-- lesma CSS -->
    <link rel="stylesheet" href="{{ url_for('static', filename='css/lesma.css') }}">

    <!-- Favicons -->
    <link rel="icon" type="image/png" href="{{ url_for('static', filename='img/favicon-512.png') }}" sizes="512x512">
    <link rel="icon" type="image/png" href="{{ url_for('static', filename='img/favicon-256.png') }}" sizes="256x256">
    <link rel="icon" type="image/png" href="{{ url_for('static', filename='img/favicon-128.png') }}" sizes="128x128">
    <link rel="icon" type="image/png" href="{{ url_for('static', filename='img/favicon-64.png') }}" sizes="64x64">
    <link rel="icon" type="image/png" href="{{ url_for('static', filename='img/favicon-32.png') }}" sizes="32x32">
    <link rel="icon" type="image/png" href="{{ url_for('static', filename='img/favicon-16.png') }}" sizes="16x16">

  </head>
  <body class="py-2">

    <div class="container-fluid pb-5 {% if editable or error %}lesma-input{% endif %}">
      {% block body %}{% endblock %}
    </div>

    <nav class="navbar fixed-bottom navbar-toggleable-md navbar-inverse bg-primary">
      <button class="navbar-toggler navbar-toggler-right" type="button" data-toggle="collapse" data-target="#navbarNav" aria-controls="navbarNav" aria-expanded="false" aria-label="Toggle navigation">
        <span class="navbar-toggler-icon"></span>
      </button>
      <div class="collapse navbar-collapse" id="navbarNav">
        <ul class="navbar-nav">
          <li class="nav-item">
            <button id="savelesma" type="submit" class="btn btn-primary" form="lesmafrm" {% if not editable %}disabled{% endif %}>Save</button>
          </li>
          <li class="nav-item">
            {% if editable %}
            <button id="newlesma" class="btn btn-primary">New</button>
            {% else %}
            <a id="newlesma" class="btn btn-primary" href="{{ url_for('.index') }}">New</a>
            {% endif %}
          </li>
          <li class="nav-item">
            {% if editable or error or help %}
            <button id="newlesma" class="btn btn-primary" disabled>Clone</button>
            {% else %}
            <a id="clonelesma" class="btn btn-primary" href="{{ url_for('.clone_lesma', lesma_id=lesma_id) }}">Clone</a>
            {% endif %}
          </li>
          <li class="nav-item">
            {% if editable %}
            <button id="rawlesma" class="btn btn-primary" disabled>Raw</button>
            {% else %}
            <a id="rawlesma" class="btn btn-primary" href="?raw">Raw</a>
            {% endif %}
          </li>
        </ul>
      </div>
      <a class="navbar-brand" href="{{ url_for('.get_help') }}">lesma</a>
    </nav>

    <!-- jQuery first, then Tether, then Bootstrap JS. -->
    <script src="https://code.jquery.com/jquery-3.1.1.slim.min.js" integrity="sha384-A7FZj7v+d/sdmMqp/nOQwliLvUsJfDHW+k9Omg/a/EheAdgtzNs3hpfag6Ed950n" crossorigin="anonymous"></script>
    <script src="https://cdnjs.cloudflare.com/ajax/libs/tether/1.4.0/js/tether.min.js" integrity="sha384-DztdAPBWPRXSA/3eYEEUWrWCy7G5KFbe8fFjk5JAIxUYHKkDx6Qin1DkWx51bBrb" crossorigin="anonymous"></script>
    <script src="https://maxcdn.bootstrapcdn.com/bootstrap/4.0.0-alpha.6/js/bootstrap.min.js" integrity="sha384-vBWWzlZJ8ea9aCX4pEW3rVHjgjt7zpkNpZk+02D9phzyeVkE+jo0ieGizqPLForn" crossorigin="anonymous"></script>

    <script src="{{ url_for('static', filename='js/lesma.js') }}"></script>
  </body>
</html>
