{% extends "security/layout.html" %}

{% from "security/_macros.html" import render_field_with_errors, render_field %}

{% block content %}
<div class="alert alert-danger alert-dismissible" role="alert">
    <strong>Here be dragons!</strong> Contextualise is in its alpha stage of development, so it is not advised to use it
    for anything other than testing purposes. Data could be irrevocably lost!
    <button aria-label="Close" class="close" data-dismiss="alert" type="button">
        <span aria-hidden="true">&times;</span>
    </button>
</div>
<form action="{{ url_for_security('login') }}" class="form-signin" method="POST" name="login_user_form">
    {{ login_user_form.hidden_tag() }}
    <input name="_csrf_token" type="hidden" value="{{ csrf_token() }}">
    <h1 class="h3 mb-3 font-weight-normal">Log In</h1>
    <label class="sr-only" for="email">Email address</label>
    <input autofocus class="form-control" id="email" name="email" placeholder="Email address" required autofocus
        type="email">
    <label class="sr-only" for="password">Password</label>
    <input class="form-control" id="password" name="password" placeholder="Password" required type="password">
    <div class="checkbox mb-3">
        <label>
            <input id="remember" name="remember" type="checkbox"> Remember me
        </label>
    </div>
    <button class="btn btn-lg btn-primary btn-block" id="submit" name="submit" type="submit">Log in</button>
    {% include "security/_menu.html" %}
    <p class="mt-5 mb-3 text-muted"><a href="/">Contextualise</a> &mdash; Copyright &copy; 2019-2022 by Brett Kromkamp
    </p>
</form>
{% endblock %}