Skip to content

Commit 6297faa

Browse files
javiereguiluzfabpot
authored andcommitted
[WebProfilerBundle] [WebProfilerPanel] Update the design of the workflow profiler panel
1 parent 60d0315 commit 6297faa

File tree

1 file changed

+38
-23
lines changed

1 file changed

+38
-23
lines changed

src/Symfony/Bundle/WebProfilerBundle/Resources/views/Collector/workflow.html.twig

Lines changed: 38 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,15 @@
33
{% block stylesheets %}
44
{{ parent() }}
55
<style>
6+
:root {
7+
--workflow-dialog-background: var(--gray-200);
8+
}
9+
.theme-dark {
10+
--workflow-dialog-background: var(--gray-900);
11+
}
12+
613
dialog {
14+
background: var(--workflow-dialog-background);
715
border: none;
816
border-radius: 6px;
917
box-shadow: var(--settings-modal-shadow);
@@ -32,7 +40,10 @@
3240
}
3341
3442
dialog h2 {
35-
margin-top: 0.2em
43+
box-shadow: none !important;
44+
color: var(--page-color);
45+
font-size: 18px;
46+
margin: 0 0 .5em;
3647
}
3748
3849
dialog i.cancel {
@@ -42,47 +53,37 @@
4253
}
4354
4455
dialog table {
45-
border: 1px solid #ccc;
56+
background: var(--page-background);
4657
border-collapse: collapse;
58+
border-radius: 4px;
59+
box-shadow: inset 0 0 0 1px var(--table-border-color);
60+
color: var(--page-color);
4761
margin: 0 0 1em 0;
4862
margin-bottom: 1em;
4963
padding: 0;
50-
table-layout: fixed;
5164
}
5265
5366
dialog table tr {
54-
background-color: #f8f8f8;
55-
border: 1px solid #ddd;
67+
border: 1px solid var(--table-border-color);
5668
padding: .35em;
5769
}
5870
5971
dialog table th,
6072
dialog table td {
73+
border: 1px solid var(--table-border-color);
6174
padding: .625em;
62-
text-align: center;
75+
text-align: left;
6376
}
6477
65-
dialog table th {
78+
dialog table thead th {
79+
background: var(--table-header);
80+
border-top-left-radius: 4px;
81+
border-top-right-radius: 4px;
6682
font-size: .85em;
67-
letter-spacing: .1em;
68-
text-transform: uppercase;
6983
}
7084
7185
dialog menu {
72-
padding: 0;
73-
margin: 0;
74-
display: flex;
75-
align-items: center;
76-
flex-direction: row;
77-
vertical-align: middle;
78-
justify-content: center;
79-
}
80-
81-
dialog menu small {
82-
margin-right: auto;
83-
}
84-
dialog menu small i {
85-
margin-right: 3px;
86+
display: none;
8687
}
8788
8889
@keyframes scale {
@@ -133,9 +134,23 @@
133134
{% else %}
134135
<script type="module">
135136
import mermaid from 'https://cdn.jsdelivr.net/npm/mermaid@10/dist/mermaid.esm.min.mjs';
137+
const isDarkMode = document.querySelector('body').classList.contains('theme-dark');
136138
mermaid.initialize({
137139
flowchart: { useMaxWidth: false },
138140
securityLevel: 'loose',
141+
'theme': 'base',
142+
'themeVariables': {
143+
darkMode: isDarkMode,
144+
'fontFamily': 'var(--font-family-system)',
145+
'fontSize': 'var(--font-size-body)',
146+
// the properties below don't support CSS variables
147+
'primaryColor': isDarkMode ? 'lightsteelblue' : 'aliceblue',
148+
'primaryTextColor': isDarkMode ? '#000' : '#000',
149+
'primaryBorderColor': isDarkMode ? 'steelblue' : 'lightsteelblue',
150+
'lineColor': isDarkMode ? '#939393' : '#d4d4d4',
151+
'secondaryColor': isDarkMode ? 'lightyellow' : 'lightyellow',
152+
'tertiaryColor': isDarkMode ? 'lightSalmon' : 'lightSalmon',
153+
}
139154
});
140155
141156
{% for name, data in collector.workflows %}

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy