bug #41242 [SecurityBundle] Change information label from red to yellow (94noni)

This PR was submitted for the 5.4 branch but it was merged into the 5.2 branch instead.

Discussion
----------

[SecurityBundle] Change information label from red to yellow

| Q             | A
| ------------- | ---
| Branch?       | 5.x
| Bug fix?      | no
| New feature?  | no
| Deprecations? | no
| Tickets       | .
| License       | MIT
| Doc PR        | .

The red colour feels like an error, but being not authenticated is more like a warning (generally associated with yellow/orange) than an error (generally in red).
Feel free to close, cheers :)

Commits
-------

41ebc32373 [SecurityBundle] Change n/a information label from red to yellow
This commit is contained in:
Wouter de Jong 2021-06-27 13:37:11 +02:00
commit e67587f3b9
1 changed files with 5 additions and 3 deletions

View File

@ -6,8 +6,10 @@
{% if collector.token %}
{% set is_authenticated = collector.enabled and collector.authenticated %}
{% set color_code = is_authenticated ? '' : 'yellow' %}
{% elseif collector.enabled %}
{% set color_code = collector.authenticatorManagerEnabled ? 'yellow' : 'red' %}
{% else %}
{% set color_code = collector.enabled ? 'red' : '' %}
{% set color_code = '' %}
{% endif %}
{% set icon %}
@ -35,7 +37,7 @@
<div class="sf-toolbar-info-piece">
<b>Authenticated</b>
<span class="sf-toolbar-status sf-toolbar-status-{{ is_authenticated ? 'green' : 'red' }}">{{ is_authenticated ? 'Yes' : 'No' }}</span>
<span class="sf-toolbar-status sf-toolbar-status-{{ is_authenticated ? 'green' : 'yellow' }}">{{ is_authenticated ? 'Yes' : 'No' }}</span>
</div>
<div class="sf-toolbar-info-piece">
@ -45,7 +47,7 @@
{% else %}
<div class="sf-toolbar-info-piece">
<b>Authenticated</b>
<span class="sf-toolbar-status sf-toolbar-status-red">No</span>
<span class="sf-toolbar-status sf-toolbar-status-yellow">No</span>
</div>
{% endif %}