diff options
author | Matthew Lemon <y@yulqen.org> | 2024-10-15 21:01:31 +0100 |
---|---|---|
committer | Matthew Lemon <y@yulqen.org> | 2024-10-15 21:01:31 +0100 |
commit | eeaddb27560d723ca7d61359744ceb2709fccd2d (patch) | |
tree | 04ddbc49ae7b73d5f5a9e1716d7227aecd3b9f85 /alphabetlearning/templates/allauth/elements/field.html | |
parent | 7a3044c859043837e6c7c95bb4894d04e9b2cbc2 (diff) |
Renamed from pyblackbird_cc to alphabetlearning - everywhere
Diffstat (limited to 'alphabetlearning/templates/allauth/elements/field.html')
-rw-r--r-- | alphabetlearning/templates/allauth/elements/field.html | 66 |
1 files changed, 66 insertions, 0 deletions
diff --git a/alphabetlearning/templates/allauth/elements/field.html b/alphabetlearning/templates/allauth/elements/field.html new file mode 100644 index 0000000..dc5f303 --- /dev/null +++ b/alphabetlearning/templates/allauth/elements/field.html @@ -0,0 +1,66 @@ +{% load allauth %} +{% load crispy_forms_tags %} + +{% if attrs.type == "textarea" %} + <div class="row mb-3"> + <div class="col-sm-10"> + <label for="{{ attrs.id }}"> + {% slot label %} + {% endslot %} + </label> + </div> + <textarea {% if attrs.required %}required{% endif %} + {% if attrs.rows %}rows="{{ attrs.rows }}"{% endif %} + {% if attrs.disabled %}disabled{% endif %} + {% if attrs.readonly %}readonly{% endif %} + {% if attrs.checked %}checked{% endif %} + {% if attrs.name %}name="{{ attrs.name }}"{% endif %} + {% if attrs.id %}id="{{ attrs.id }}"{% endif %} + {% if attrs.placeholder %}placeholder="{{ attrs.placeholder }}"{% endif %} + class="form-control">{% slot value %}{% endslot %}</textarea> +</div> +{% elif attrs.type == "radio" %} +<div class="row mb-3"> + <div class="col-sm-10"> + <div class="form-check"> + <input {% if attrs.required %}required{% endif %} + {% if attrs.disabled %}disabled{% endif %} + {% if attrs.readonly %}readonly{% endif %} + {% if attrs.checked %}checked{% endif %} + {% if attrs.name %}name="{{ attrs.name }}"{% endif %} + {% if attrs.id %}id="{{ attrs.id }}"{% endif %} + {% if attrs.placeholder %}placeholder="{{ attrs.placeholder }}"{% endif %} + {% if attrs.autocomplete %}autocomplete="{{ attrs.autocomplete }}"{% endif %} + value="{{ attrs.value|default_if_none:"" }}" + type="{{ attrs.type }}" /> + <label class="form-check-label" for="{{ attrs.id }}"> + {% slot label %} + {% endslot %} + </label> + </div> +</div> +</div> +{% else %} +<div class="col-sm-10"> + <label for="{{ attrs.id }}"> + {% slot label %} + {% endslot %} +</label> +</div> +<div class="col-sm-10"> + <input {% if attrs.required %}required{% endif %} + {% if attrs.disabled %}disabled{% endif %} + {% if attrs.readonly %}readonly{% endif %} + {% if attrs.checked %}checked{% endif %} + {% if attrs.name %}name="{{ attrs.name }}"{% endif %} + {% if attrs.id %}id="{{ attrs.id }}"{% endif %} + {% if attrs.placeholder %}placeholder="{{ attrs.placeholder }}"{% endif %} + {% if attrs.autocomplete %}autocomplete="{{ attrs.autocomplete }}"{% endif %} + value="{{ attrs.value|default_if_none:"" }}" + type="{{ attrs.type }}" + class="form-control" /> +</div> +{% endif %} +{% if slots.help_text %} + <div class="form-text">{% slot help_text %}{% endslot %}</div> +{% endif %} |