06/15 Phase 1 + 2 codes

This commit is contained in:
2026-06-15 11:23:05 -04:00
commit c2064b84b4
62 changed files with 2937 additions and 0 deletions
+18
View File
@@ -0,0 +1,18 @@
{% macro field(f) %}
<div class="field">
{{ f.label }}
{{ f(class="input") }}
{% if f.errors %}
<ul class="errors">
{% for e in f.errors %}<li>{{ e }}</li>{% endfor %}
</ul>
{% endif %}
</div>
{% endmacro %}
{% macro turnstile_widget(enabled) %}
{% if enabled and TURNSTILE_SITE_KEY %}
<div class="cf-turnstile" data-sitekey="{{ TURNSTILE_SITE_KEY }}"></div>
<script src="https://challenges.cloudflare.com/turnstile/v0/api.js" async defer></script>
{% endif %}
{% endmacro %}
+19
View File
@@ -0,0 +1,19 @@
{% extends "base.html" %}
{% from "auth/_macros.html" import field %}
{% block title %}{{ _('Sign in') }}{% endblock %}
{% block content %}
<div class="card narrow">
<h2>{{ _('Sign in') }}</h2>
<form method="post" novalidate>
{{ form.hidden_tag() }}
{{ field(form.email) }}
{{ field(form.password) }}
<label class="check">{{ form.remember() }} {{ form.remember.label.text }}</label>
{{ form.submit(class="btn") }}
</form>
<p class="muted">
<a href="{{ url_for('auth.reset_request') }}">{{ _('Forgot password?') }}</a> ·
<a href="{{ url_for('auth.register') }}">{{ _('Create account') }}</a>
</p>
</div>
{% endblock %}
+18
View File
@@ -0,0 +1,18 @@
{% extends "base.html" %}
{% from "auth/_macros.html" import field, turnstile_widget %}
{% block title %}{{ _('Register') }}{% endblock %}
{% block content %}
<div class="card narrow">
<h2>{{ _('Create account') }}</h2>
<form method="post" novalidate>
{{ form.hidden_tag() }}
{{ field(form.display_name) }}
{{ field(form.email) }}
{{ field(form.password) }}
{{ field(form.confirm) }}
{{ turnstile_widget(turnstile) }}
{{ form.submit(class="btn") }}
</form>
<p class="muted"><a href="{{ url_for('auth.login') }}">{{ _('Already have an account? Sign in') }}</a></p>
</div>
{% endblock %}
+14
View File
@@ -0,0 +1,14 @@
{% extends "base.html" %}
{% from "auth/_macros.html" import field %}
{% block title %}{{ _('Set new password') }}{% endblock %}
{% block content %}
<div class="card narrow">
<h2>{{ _('Set new password') }}</h2>
<form method="post" novalidate>
{{ form.hidden_tag() }}
{{ field(form.password) }}
{{ field(form.confirm) }}
{{ form.submit(class="btn") }}
</form>
</div>
{% endblock %}
+13
View File
@@ -0,0 +1,13 @@
{% extends "base.html" %}
{% from "auth/_macros.html" import field %}
{% block title %}{{ _('Reset password') }}{% endblock %}
{% block content %}
<div class="card narrow">
<h2>{{ _('Reset password') }}</h2>
<form method="post" novalidate>
{{ form.hidden_tag() }}
{{ field(form.email) }}
{{ form.submit(class="btn") }}
</form>
</div>
{% endblock %}