652: Don't show empty field labels.
If the label for a field is empty, don't show it at all. And don't translate it!
This commit is contained in:
parent
ea33f63635
commit
4d4e5b435b
@ -18,7 +18,9 @@
|
|||||||
|
|
||||||
{# Generically render a field #}
|
{# Generically render a field #}
|
||||||
{% macro render_field_div(field) %}
|
{% macro render_field_div(field) %}
|
||||||
|
{% if field.label.text -%}
|
||||||
<p class="form_field_label"><label for="{{ field.name }}">{{ _(field.label.text) }}</label></p>
|
<p class="form_field_label"><label for="{{ field.name }}">{{ _(field.label.text) }}</label></p>
|
||||||
|
{%- endif %}
|
||||||
<div class="form_field_input">
|
<div class="form_field_input">
|
||||||
{{ field }}
|
{{ field }}
|
||||||
{%- if field.errors -%}
|
{%- if field.errors -%}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user