Skip to content

Commit 9e88521

Browse files
committed
Remove duplicate field.help and field.errors from radio/checkboxes input templates
These were rendered inside the foreach loop (once per choice), but the field-level rendering already outputs help and errors separately. Fixes #638
1 parent ea71eb6 commit 9e88521

5 files changed

Lines changed: 0 additions & 15 deletions

File tree

iommi/templates/iommi/form/checkboxes.html

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,5 @@
22
<div{{ field.attrs }}>
33
<input type="checkbox" value="{{ choice.1|stringformat:'s' }}" id="{{ field.extra_evaluated.id }}_{{ choice.4 }}" {{ field.input.attrs }} {% if choice.3 %}checked{% endif %}/>
44
<label for="{{ field.extra_evaluated.id }}_{{ choice.4 }}">{{ choice.2 }}</label>
5-
6-
{{ field.help }}
7-
{{ field.errors }}
85
</div>
96
{% endfor %}

iommi/templates/iommi/form/radio.html

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,5 @@
22
<div{{ field.attrs }}>
33
<input type="radio" value="{{ choice.1|stringformat:'s' }}" id="{{ field.extra_evaluated.id }}_{{ choice.4 }}" {{ field.input.attrs }} {% if choice.3 %}checked{% endif %}/>
44
<label for="{{ field.extra_evaluated.id }}_{{ choice.4 }}">{{ choice.2 }}</label>
5-
6-
{{ field.help }}
7-
{{ field.errors }}
85
</div>
96
{% endfor %}

iommi/templates/iommi/form/semantic_ui/checkboxes.html

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,9 +3,6 @@
33
<div class="ui radio checkbox"> {# TODO: use fields.attrs #}
44
<input type="checkbox" value="{{ choice.1 }}" id="{{ field.extra_evaluated.id }}_{{ choice.4 }}" {{ field.input.attrs }} {% if choice.3 %}checked{% endif %}/>
55
<label for="{{ field.extra_evaluated.id }}_{{ choice.4 }}">{{ choice.2 }}</label>
6-
7-
{{ field.help }}
8-
{{ field.errors }}
96
</div>
107
</div>
118
{% endfor %}

iommi/templates/iommi/form/semantic_ui/radio.html

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,9 +3,6 @@
33
<div class="ui radio checkbox"> {# TODO: use fields.attrs #}
44
<input type="radio" value="{{ choice.1 }}" id="{{ field.extra_evaluated.id }}_{{ choice.4 }}" {{ field.input.attrs }} {% if choice.3 %}checked{% endif %}/>
55
<label for="{{ field.extra_evaluated.id }}_{{ choice.4 }}">{{ choice.2 }}</label>
6-
7-
{{ field.help }}
8-
{{ field.errors }}
96
</div>
107
</div>
118
{% endfor %}

iommi/templates/iommi/form/us_web_design_system/radio.html

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,5 @@
22
<div{{ field.attrs }}>
33
<input type="radio" value="{{ choice.1|stringformat:'s' }}" id="{{ field.extra_evaluated.id }}_{{ choice.4 }}" {{ field.input.attrs }} {% if choice.3 %}checked{% endif %}/>
44
<label class="usa-radio__label" for="{{ field.extra_evaluated.id }}_{{ choice.4 }}">{{ choice.2 }}</label>
5-
6-
{{ field.help }}
7-
{{ field.errors }}
85
</div>
96
{% endfor %}

0 commit comments

Comments
 (0)