Also tidied forms.py a little by consolidating into widget and moving help text to template.
11 lines
549 B
HTML
11 lines
549 B
HTML
{# Labels on a separate line, custom help text layout #}
|
|
{% if field.use_fieldset %}
|
|
<fieldset{% if field.help_text and field.auto_id and "aria-describedby" not in field.field.widget.attrs %} aria-describedby="{{ field.auto_id }}_helptext"{% endif %}>
|
|
{% if field.label %}{{ field.legend_tag }}{% endif %}
|
|
{% else %}
|
|
{% if field.label %}{{ field.label_tag }}{% endif %}
|
|
{% endif %}
|
|
{{ field.errors }}
|
|
<div class="mt1">{{ field }}</div>
|
|
<div class="f7 black-60 mt1">{{ field.help_text }}</div>
|
|
{% if field.use_fieldset %}</fieldset>{% endif %}
|