Skip to content

Commit cdb1b6a

Browse files
javiereguiluzfabpot
authored andcommitted
[WebProfilerBundle] Tweak the colors of the security panel
1 parent 7ad25f7 commit cdb1b6a

File tree

1 file changed

+2
-10
lines changed

1 file changed

+2
-10
lines changed

Resources/views/Collector/security.html.twig

Lines changed: 2 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -4,15 +4,7 @@
44

55
{% block toolbar %}
66
{% if collector.firewall %}
7-
{% if collector.token %}
8-
{% set is_authenticated = collector.enabled and collector.authenticated %}
9-
{% set color_code = not is_authenticated ? 'yellow' %}
10-
{% elseif collector.enabled %}
11-
{% set color_code = collector.authenticatorManagerEnabled ? 'yellow' : 'red' %}
12-
{% else %}
13-
{% set color_code = '' %}
14-
{% endif %}
15-
7+
{% set color_code = collector.enabled and not collector.authenticatorManagerEnabled ? 'yellow' %}
168
{% set icon %}
179
{{ include('@Security/Collector/icon.svg') }}
1810
<span class="sf-toolbar-value">{{ collector.user|default('n/a') }}</span>
@@ -38,7 +30,7 @@
3830

3931
<div class="sf-toolbar-info-piece">
4032
<b>Authenticated</b>
41-
<span class="sf-toolbar-status sf-toolbar-status-{{ is_authenticated ? 'green' : 'yellow' }}">{{ is_authenticated ? 'Yes' : 'No' }}</span>
33+
<span class="sf-toolbar-status sf-toolbar-status-{{ collector.authenticated ? 'green' : 'yellow' }}">{{ collector.authenticated ? 'Yes' : 'No' }}</span>
4234
</div>
4335

4436
<div class="sf-toolbar-info-piece">

0 commit comments

Comments
 (0)