Skip to content

Navigation Menu

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit 0c6eca3

Browse filesBrowse files
committed
feature #24148 [Form] Hide label button when its setted to false (TeLiXj)
This PR was submitted for the 2.7 branch but it was merged into the 3.4 branch instead (closes #24148). Discussion ---------- [Form] Hide label button when its setted to false | Q | A | ------------- | --- | Branch? | 2.7 | Bug fix? | yes | New feature? | no | BC breaks? | no | Deprecations? | no | Tests pass? | no | Fixed tickets | | License | MIT | Doc PR | 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. Commits ------- e319075 Hide label button when its setted to false
2 parents 7799881 + e319075 commit 0c6eca3
Copy full SHA for 0c6eca3

File tree

1 file changed

+1
-1
lines changed
Filter options

1 file changed

+1
-1
lines changed

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

Copy file name to clipboardExpand all lines: src/Symfony/Bridge/Twig/Resources/views/Form/form_div_layout.html.twig
+1-1Lines 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)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.