10000 Hide label button when its setted to false · symfony/symfony@e319075 · GitHub
[go: up one dir, main page]

Skip to content

Commit e319075

Browse files
TeLiXjfabpot
authored andcommitted
Hide label button when its setted to false
Added same behaviour in buttons like in other form components when label is setted to false, don't show it. It's very useful with buttons with icon and without text
1 parent 7799881 commit e319075

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/Symfony/Bridge/Twig/Resources/views/Form/form_div_layout.html.twig

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -216,7 +216,7 @@
216216
{%- endblock range_widget %}
217217

218218
{%- block button_widget -%}
219-
{%- if label is empty -%}
219+
{%- if label is not same as(false) and label is empty -%}
220220
{%- if label_format is not empty -%}
221221
{% set label = label_format|replace({
222222
'%name%': name,

0 commit comments

Comments
 (0)
0