<!doctype html>
<html>
<head>
  <meta charset="utf-8">
  <meta http-equiv="X-UA-Compatible" content="IE=edge">
  <title>Poff admin</title>
  <link rel="stylesheet" href="//maxcdn.bootstrapcdn.com/bootstrap/3.2.0/css/bootstrap.min.css">
  <meta name="viewport" content="width=device-width, initial-scale=1, user-scalable=no">
  <style>
    /* Styles inlined because of very small amount of styles, and to remove
    the need to serve static files separatey. */
    body {
        background-color: #ddd;
        /* Margin bottom by footer height */
        margin-bottom: 68px;
    }

    .form-inline {
        display: inline-block;
    }

    html {
      position: relative;
      min-height: 100%;
    }

    .footer {
      position: absolute;
      bottom: 0;
      width: 100%;
      /* Set the fixed height of the footer here */
      height: 68px;
      background-color: #ccc;
    }

    .footer p {
        margin-top: 8px;
    }

    .input-copyable-key {
        font-family: "Courier", "monospace";
        width: 41ch;
    }

    .input-copyable-tsig {
        font-family: "Courier", "monospace";
        width: 26ch;
    }
  </style>
</head>
<body>
  <div class="wrapper container">
    <header>

      {% for category, msg in get_flashed_messages(with_categories=true) %}
        <div class="alert alert-{{ category }}">
          <span>
            <strong>{{ category.upper() }}: </strong>
            {{ msg }}
            {% if form_errors %}
              <ul>
                {% for field, errors in form_errors.items() %}
                  <li>
                    {{ field }}: {{ ', '.join(errors) }}
                  </li>
                {% endfor %}
              </ul>
            {% endif %}
          </span>
        </div>
      {% endfor %}

    </header>

    {% block content %}
    {% endblock %}

  </div><!-- /wrapper -->

  <footer class="footer">
    <div class="container">
      <p class="text-muted"><a href="https://github.com/thusoy/poff">Poff</a> v{{ version }}, the minimal pdns frontend</p>
      <p class="text-muted">Maintained by <a href="http://github.com/thusoy">Tarjei Husøy</a>
    </div>
  </footer>

</body>
</html>
