Skip to content

Navigation Menu

Sign in
Appearance settings

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 92422f9

Browse filesBrowse files
committed
bug symfony#17561 [WebProfilerBundle] Fix design issue in profiler when having errors in forms (Pierstoval)
This PR was squashed before being merged into the 2.8 branch (closes symfony#17561). Discussion ---------- [WebProfilerBundle] Fix design issue in profiler when having errors in forms | Q | A | ------------- | --- | Bug fix? | yes | New feature? | no | BC breaks? | no | Deprecations? | no | Tests pass? | yes | Fixed tickets | n/a | License | MIT | Doc PR | n/a This error occurs mostly when having long form field names or types, **Before:** ![before](https://cloud.githubusercontent.com/assets/3369266/12610913/89bddfd8-c4ea-11e5-9372-2b7740d8c4b3.png) **After:** ![after](https://cloud.githubusercontent.com/assets/3369266/12610915/8ae22a4a-c4ea-11e5-94ce-9257a9409b4a.png) That said, I don't know what to do about z-index, whether the error count prevails on the type or *vice-versa* 😕 @javiereguiluz, an idea ? Commits ------- 76e1c0a [WebProfilerBundle] Fix design issue in profiler when having errors in forms
2 parents b99c74f + ffafc7d commit 92422f9
Copy full SHA for 92422f9

File tree

1 file changed

+4
-4
lines changed
Filter options

1 file changed

+4
-4
lines changed

‎Resources/views/Collector/form.html.twig

Copy file name to clipboardExpand all lines: Resources/views/Collector/form.html.twig
+4-4Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -427,17 +427,17 @@
427427
{% import _self as tree %}
428428
<li>
429429
<div class="tree-inner" data-tab-target-id="{{ data.id }}-details">
430+
{% if data.errors is defined and data.errors|length > 0 %}
431+
<div class="badge-error">{{ data.errors|length }}</div>
432+
{% endif %}
433+
430434
{% if data.children is not empty %}
431435
<a class="toggle-button" data-toggle-target-id="{{ data.id }}-children" href="#"><span class="toggle-icon"></span></a>
432436
{% else %}
433437
<div class="toggle-icon empty"></div>
434438
{% endif %}
435439

436440
{{ name|default('(no name)') }} {% if data.type_class is defined and data.type is defined %}[<abbr title="{{ data.type_class }}">{{ data.type|split('\\')|last }}</abbr>]{% endif %}
437-
438-
{% if data.errors is defined and data.errors|length > 0 %}
439-
<div class="badge-error">{{ data.errors|length }}</div>
440-
{% endif %}
441441
</div>
442442

443443
{% if data.children is not empty %}

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.