feat(templates/allauth): style allauth elements

This commit is contained in:
2026-03-10 14:19:20 +01:00
parent 8fb52132bb
commit 12200ad663
29 changed files with 414 additions and 0 deletions

View File

@@ -0,0 +1,14 @@
{% load allauth %}
{% for err in attrs.form.non_field_errors %}<div role="alert" class="mb-4 rounded-md border border-red-200 bg-red-50 px-4 py-3 text-sm text-red-700">{{ err }}</div>{% endfor %}
<form class="{% block form_class %}{% if not attrs.no_visible_fields %}rounded-xl border border-slate-200 bg-white shadow-sm{% endif %}{% endblock %}"
method="{{ attrs.method }}"
{% if attrs.action %}action="{{ attrs.action }}"{% endif %}>
{% if not attrs.no_visible_fields %}<div class="space-y-4 p-6">{% endif %}
{% slot body %}
{% endslot %}
{% if not attrs.no_visible_fields %}</div>{% endif %}
{% if not attrs.no_visible_fields %}<div class="flex flex-wrap justify-end gap-2 border-t border-slate-200 bg-slate-50 p-4">{% endif %}
{% slot actions %}
{% endslot %}
{% if not attrs.no_visible_fields %}</div>{% endif %}
</form>