Skip to content

Commit 9cb6f18

Browse files
bug #26327 [Form][WCAG] Errors sign for people that do not see colors (Nyholm)
This PR was squashed before being merged into the 3.4 branch (closes #26327). Discussion ---------- [Form][WCAG] Errors sign for people that do not see colors | Q | A | ------------- | --- | Branch? | 3.4 | Bug fix? | no | New feature? | yes | BC breaks? | no | Deprecations? | no | Tests pass? | yes | Fixed tickets | | License | MIT | Doc PR | According to my friend and WCAG2 expect [Sandra](https://twitter.com/sandrability): > The form errors is correctly encoded and works great. But visually they may be hard to see for people that do not see colors very well. Try to improve errors with an icon to make it more visual clear that an error has occurred. ![screen shot 2018-02-26 at 17 42 01](https://user-images.githubusercontent.com/1275206/36802282-c81357c6-1cb4-11e8-843c-4592e3d597f9.png) Commits ------- 3f8cd05 [Form][WCAG] Errors sign for people that do not see colors
2 parents 8928c5d + 5757dfa commit 9cb6f18

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

Resources/views/Form/bootstrap_4_layout.html.twig

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -264,7 +264,7 @@
264264
<div class="{% if form is not rootform %}invalid-feedback d-block{% else %}alert alert-danger{% endif %}">
265265
<ul class="list-unstyled mb-0">
266266
{%- for error in errors -%}
267-
<li>{{ error.message }}</li>
267+
<li><span class="initialism form-error-icon badge badge-danger">{{ 'Error'|trans({}, 'validators') }}</span> <span class="form-error-message">{{ error.message }}</span></li>
268268
{%- endfor -%}
269269
</ul>
270270
</div>

0 commit comments

Comments
 (0)