@webority/theme 0.24.0 → 0.26.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +16 -2
- package/dist/purge-safelist.json +199 -2
- package/dist/webority-brand-signal.css +1 -0
- package/dist/webority-theme.css +2 -2
- package/fonts/sans/OFL.txt +92 -0
- package/fonts/sans/WeboritySans-Bold.woff2 +0 -0
- package/fonts/sans/WeboritySans-BoldItalic.woff2 +0 -0
- package/fonts/sans/WeboritySans-Medium.woff2 +0 -0
- package/fonts/sans/WeboritySans-Regular.woff2 +0 -0
- package/fonts/sans/WeboritySans-RegularItalic.woff2 +0 -0
- package/fonts/sans/WeboritySans-SemiBold.woff2 +0 -0
- package/fonts/serif/WeboritySerif-Bold.woff2 +0 -0
- package/fonts/serif/WeboritySerif-BoldItalic.woff2 +0 -0
- package/fonts/serif/WeboritySerif-DemiBold.woff2 +0 -0
- package/fonts/serif/WeboritySerif-ExtraBold.woff2 +0 -0
- package/fonts/serif/WeboritySerif-Medium.woff2 +0 -0
- package/fonts/serif/WeboritySerif-Regular.woff2 +0 -0
- package/fonts/serif/WeboritySerif-RegularItalic.woff2 +0 -0
- package/index.scss +2 -1
- package/package.json +4 -2
- package/scss/_brand-signal.scss +202 -0
- package/scss/_fonts.scss +96 -0
- package/scss/_tokens.scss +55 -2
- package/scss/_variables.scss +2 -1
- package/scss/_wui-aliases.scss +21 -0
- package/scss/_wui-components.scss +12 -0
- package/scss/wui/_calendar.scss +256 -0
- package/scss/wui/_chart-card.scss +86 -0
- package/scss/wui/_chart.scss +524 -0
- package/scss/wui/_context-menu.scss +53 -0
- package/scss/wui/_data.scss +8 -6
- package/scss/wui/_display.scss +1 -1
- package/scss/wui/_image-crop.scss +146 -0
- package/scss/wui/_kanban.scss +434 -0
- package/scss/wui/_modal-remote.scss +55 -0
- package/scss/wui/_overlays.scss +39 -0
- package/scss/wui/_rich-text.scss +281 -0
- package/scss/wui/_shell-parts.scss +503 -0
- package/scss/wui/_shell.scss +11 -0
- package/scss/wui/_sortable.scss +135 -0
- package/scss/wui/_table-server.scss +40 -0
- package/scss/wui/_tree.scss +124 -0
|
@@ -0,0 +1,524 @@
|
|
|
1
|
+
// Charts: AppLineChart and AppBarChart, and the <wui-chart> element behind AppChart.
|
|
2
|
+
//
|
|
3
|
+
// Part of the wui-components layer; see _wui-components.scss for the load order. The line and
|
|
4
|
+
// bar charts use one accent (--color-primary), muted grid and labels, and direct labels instead of
|
|
5
|
+
// a legend; the element draws series in the --wui-chart-* colours. Every colour is a token the
|
|
6
|
+
// dark remap in _wui-aliases.scss flips with the rest of the portal.
|
|
7
|
+
|
|
8
|
+
.wui-chart {
|
|
9
|
+
margin: 0;
|
|
10
|
+
min-width: 0;
|
|
11
|
+
color: var(--color-text-muted);
|
|
12
|
+
font-size: 12px;
|
|
13
|
+
font-variant-numeric: tabular-nums;
|
|
14
|
+
}
|
|
15
|
+
.wui-chart-title {
|
|
16
|
+
margin-bottom: 12px;
|
|
17
|
+
font-size: 14px;
|
|
18
|
+
font-weight: 600;
|
|
19
|
+
color: var(--color-text);
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
// ============================================================================
|
|
23
|
+
// Line chart
|
|
24
|
+
// ============================================================================
|
|
25
|
+
// The top tick label sits above the top gridline, so the plot leaves room for it.
|
|
26
|
+
.wui-chart-plot {
|
|
27
|
+
position: relative;
|
|
28
|
+
margin-top: 8px;
|
|
29
|
+
}
|
|
30
|
+
// Strokes overhang the plot by half their width at the top and bottom gridlines.
|
|
31
|
+
.wui-chart-svg {
|
|
32
|
+
display: block;
|
|
33
|
+
overflow: visible;
|
|
34
|
+
}
|
|
35
|
+
.wui-chart-grid {
|
|
36
|
+
stroke: var(--color-border);
|
|
37
|
+
stroke-width: 1;
|
|
38
|
+
}
|
|
39
|
+
.wui-chart-reference {
|
|
40
|
+
stroke: var(--color-border-strong);
|
|
41
|
+
stroke-width: 1;
|
|
42
|
+
stroke-dasharray: 4 4;
|
|
43
|
+
}
|
|
44
|
+
.wui-chart-line {
|
|
45
|
+
stroke: var(--color-primary);
|
|
46
|
+
stroke-width: 2;
|
|
47
|
+
stroke-linecap: round;
|
|
48
|
+
}
|
|
49
|
+
// Bands are a quiet wash behind the series; the tone tints, it does not shout.
|
|
50
|
+
.wui-chart-band {
|
|
51
|
+
fill: var(--color-bg-muted);
|
|
52
|
+
opacity: 0.6;
|
|
53
|
+
}
|
|
54
|
+
.wui-chart-band-info {
|
|
55
|
+
fill: var(--color-info-soft);
|
|
56
|
+
}
|
|
57
|
+
.wui-chart-band-success {
|
|
58
|
+
fill: var(--color-success-soft);
|
|
59
|
+
}
|
|
60
|
+
.wui-chart-band-warning {
|
|
61
|
+
fill: var(--color-warning-soft);
|
|
62
|
+
}
|
|
63
|
+
.wui-chart-band-danger {
|
|
64
|
+
fill: var(--color-danger-soft);
|
|
65
|
+
}
|
|
66
|
+
|
|
67
|
+
// Y tick values sit just above their gridline at the left edge, inside the plot, so the chart
|
|
68
|
+
// spends no width on a label gutter at 320px.
|
|
69
|
+
.wui-chart-tick,
|
|
70
|
+
.wui-chart-band-label,
|
|
71
|
+
.wui-chart-reference-label {
|
|
72
|
+
position: absolute;
|
|
73
|
+
font-size: 11px;
|
|
74
|
+
line-height: 1;
|
|
75
|
+
white-space: nowrap;
|
|
76
|
+
color: var(--color-text-muted);
|
|
77
|
+
pointer-events: none;
|
|
78
|
+
}
|
|
79
|
+
.wui-chart-tick {
|
|
80
|
+
left: 0;
|
|
81
|
+
padding-bottom: 3px;
|
|
82
|
+
transform: translateY(-100%);
|
|
83
|
+
}
|
|
84
|
+
.wui-chart-band-label {
|
|
85
|
+
right: 0;
|
|
86
|
+
padding-top: 3px;
|
|
87
|
+
}
|
|
88
|
+
.wui-chart-reference-label {
|
|
89
|
+
right: 0;
|
|
90
|
+
padding-bottom: 3px;
|
|
91
|
+
transform: translateY(-100%);
|
|
92
|
+
}
|
|
93
|
+
|
|
94
|
+
// A 24px hit area per point (WCAG 2.2 target size), drawn as an 8px ring.
|
|
95
|
+
.wui-chart-point {
|
|
96
|
+
position: absolute;
|
|
97
|
+
width: 24px;
|
|
98
|
+
height: 24px;
|
|
99
|
+
margin: -12px 0 0 -12px;
|
|
100
|
+
padding: 0;
|
|
101
|
+
display: grid;
|
|
102
|
+
place-items: center;
|
|
103
|
+
border: 0;
|
|
104
|
+
border-radius: 50%;
|
|
105
|
+
background: transparent;
|
|
106
|
+
cursor: default;
|
|
107
|
+
}
|
|
108
|
+
.wui-chart-point:focus-visible {
|
|
109
|
+
outline: 2px solid var(--color-primary);
|
|
110
|
+
outline-offset: 0;
|
|
111
|
+
}
|
|
112
|
+
.wui-chart-dot {
|
|
113
|
+
width: 8px;
|
|
114
|
+
height: 8px;
|
|
115
|
+
border-radius: 50%;
|
|
116
|
+
border: 2px solid var(--color-primary);
|
|
117
|
+
background: var(--color-surface);
|
|
118
|
+
transition: transform 120ms var(--wui-ease-out-quart);
|
|
119
|
+
}
|
|
120
|
+
.wui-chart-point:hover .wui-chart-dot,
|
|
121
|
+
.wui-chart-point:focus-visible .wui-chart-dot {
|
|
122
|
+
transform: scale(1.35);
|
|
123
|
+
background: var(--color-primary);
|
|
124
|
+
}
|
|
125
|
+
|
|
126
|
+
// CSS-only tooltip above the point; the first and last points anchor it to their own edge so
|
|
127
|
+
// it never runs off a narrow chart.
|
|
128
|
+
.wui-chart-tip {
|
|
129
|
+
position: absolute;
|
|
130
|
+
bottom: calc(100% + 4px);
|
|
131
|
+
left: 50%;
|
|
132
|
+
z-index: 1;
|
|
133
|
+
display: flex;
|
|
134
|
+
flex-direction: column;
|
|
135
|
+
align-items: flex-start;
|
|
136
|
+
gap: 2px;
|
|
137
|
+
padding: 6px 10px;
|
|
138
|
+
border: 1px solid var(--color-border-light);
|
|
139
|
+
border-radius: var(--radius);
|
|
140
|
+
background: var(--color-surface);
|
|
141
|
+
box-shadow: var(--wui-shadow-overlay);
|
|
142
|
+
white-space: nowrap;
|
|
143
|
+
text-align: left;
|
|
144
|
+
pointer-events: none;
|
|
145
|
+
visibility: hidden;
|
|
146
|
+
opacity: 0;
|
|
147
|
+
transform: translateX(-50%);
|
|
148
|
+
transition:
|
|
149
|
+
opacity 120ms var(--wui-ease-out-quart),
|
|
150
|
+
visibility 120ms;
|
|
151
|
+
}
|
|
152
|
+
.wui-chart-point-start .wui-chart-tip {
|
|
153
|
+
left: 0;
|
|
154
|
+
transform: none;
|
|
155
|
+
}
|
|
156
|
+
.wui-chart-point-end .wui-chart-tip {
|
|
157
|
+
left: auto;
|
|
158
|
+
right: 0;
|
|
159
|
+
transform: none;
|
|
160
|
+
}
|
|
161
|
+
.wui-chart-point:hover .wui-chart-tip,
|
|
162
|
+
.wui-chart-point:focus-visible .wui-chart-tip {
|
|
163
|
+
visibility: visible;
|
|
164
|
+
opacity: 1;
|
|
165
|
+
}
|
|
166
|
+
.wui-chart-tip-label {
|
|
167
|
+
font-size: 11px;
|
|
168
|
+
color: var(--color-text-muted);
|
|
169
|
+
}
|
|
170
|
+
.wui-chart-tip-value {
|
|
171
|
+
font-size: 13px;
|
|
172
|
+
font-weight: 600;
|
|
173
|
+
color: var(--color-text);
|
|
174
|
+
}
|
|
175
|
+
|
|
176
|
+
.wui-chart-xaxis {
|
|
177
|
+
position: relative;
|
|
178
|
+
height: 16px;
|
|
179
|
+
margin-top: 6px;
|
|
180
|
+
}
|
|
181
|
+
.wui-chart-xlabel {
|
|
182
|
+
position: absolute;
|
|
183
|
+
top: 0;
|
|
184
|
+
font-size: 11px;
|
|
185
|
+
line-height: 16px;
|
|
186
|
+
white-space: nowrap;
|
|
187
|
+
transform: translateX(-50%);
|
|
188
|
+
}
|
|
189
|
+
// Below md only every Nth label shows (the component marks the rest minor); a 12-month axis
|
|
190
|
+
// would otherwise overlap on a phone.
|
|
191
|
+
.wui-chart-xlabel-minor {
|
|
192
|
+
display: none;
|
|
193
|
+
}
|
|
194
|
+
@media (min-width: 768px) {
|
|
195
|
+
.wui-chart-xlabel-minor {
|
|
196
|
+
display: block;
|
|
197
|
+
}
|
|
198
|
+
}
|
|
199
|
+
|
|
200
|
+
// ============================================================================
|
|
201
|
+
// Bar chart
|
|
202
|
+
// ============================================================================
|
|
203
|
+
.wui-bar-chart-list {
|
|
204
|
+
margin: 0;
|
|
205
|
+
padding: 0;
|
|
206
|
+
list-style: none;
|
|
207
|
+
}
|
|
208
|
+
.wui-bar-chart-label {
|
|
209
|
+
min-width: 0;
|
|
210
|
+
color: var(--color-text-body);
|
|
211
|
+
overflow-wrap: anywhere;
|
|
212
|
+
}
|
|
213
|
+
.wui-bar-chart-value {
|
|
214
|
+
font-weight: 600;
|
|
215
|
+
white-space: nowrap;
|
|
216
|
+
color: var(--color-text);
|
|
217
|
+
}
|
|
218
|
+
.wui-bar-chart-track {
|
|
219
|
+
position: relative;
|
|
220
|
+
overflow: hidden;
|
|
221
|
+
border-radius: 999px;
|
|
222
|
+
background: var(--color-progress-track);
|
|
223
|
+
}
|
|
224
|
+
.wui-bar-chart-fill {
|
|
225
|
+
border-radius: inherit;
|
|
226
|
+
background: var(--color-primary);
|
|
227
|
+
}
|
|
228
|
+
// Each track is a focus stop; the ring sits outside the track's own clipped content.
|
|
229
|
+
.wui-bar-chart-track:focus-visible {
|
|
230
|
+
outline: 2px solid var(--color-primary);
|
|
231
|
+
outline-offset: 2px;
|
|
232
|
+
}
|
|
233
|
+
|
|
234
|
+
// Horizontal: a label/value line over each bar, so a long label wraps instead of squeezing
|
|
235
|
+
// the bar at 320px.
|
|
236
|
+
.wui-bar-chart-horizontal .wui-bar-chart-list {
|
|
237
|
+
display: flex;
|
|
238
|
+
flex-direction: column;
|
|
239
|
+
gap: 14px;
|
|
240
|
+
}
|
|
241
|
+
.wui-bar-chart-horizontal .wui-bar-chart-item {
|
|
242
|
+
display: grid;
|
|
243
|
+
grid-template-columns: minmax(0, 1fr) auto;
|
|
244
|
+
grid-template-areas:
|
|
245
|
+
"label value"
|
|
246
|
+
"track track";
|
|
247
|
+
column-gap: 12px;
|
|
248
|
+
row-gap: 6px;
|
|
249
|
+
align-items: baseline;
|
|
250
|
+
}
|
|
251
|
+
.wui-bar-chart-horizontal .wui-bar-chart-label {
|
|
252
|
+
grid-area: label;
|
|
253
|
+
}
|
|
254
|
+
.wui-bar-chart-horizontal .wui-bar-chart-value {
|
|
255
|
+
grid-area: value;
|
|
256
|
+
}
|
|
257
|
+
.wui-bar-chart-horizontal .wui-bar-chart-track {
|
|
258
|
+
grid-area: track;
|
|
259
|
+
height: 8px;
|
|
260
|
+
}
|
|
261
|
+
.wui-bar-chart-horizontal .wui-bar-chart-fill {
|
|
262
|
+
height: 100%;
|
|
263
|
+
transition: width 300ms var(--wui-ease-out-quart);
|
|
264
|
+
}
|
|
265
|
+
|
|
266
|
+
// Vertical: bars side by side, value above and label below each. The plot height is one var a
|
|
267
|
+
// caller can set from its own class.
|
|
268
|
+
.wui-bar-chart-vertical .wui-bar-chart-list {
|
|
269
|
+
display: flex;
|
|
270
|
+
gap: 8px;
|
|
271
|
+
}
|
|
272
|
+
.wui-bar-chart-vertical .wui-bar-chart-item {
|
|
273
|
+
flex: 1 1 0;
|
|
274
|
+
min-width: 0;
|
|
275
|
+
display: grid;
|
|
276
|
+
grid-template-areas:
|
|
277
|
+
"value"
|
|
278
|
+
"track"
|
|
279
|
+
"label";
|
|
280
|
+
justify-items: center;
|
|
281
|
+
row-gap: 6px;
|
|
282
|
+
text-align: center;
|
|
283
|
+
}
|
|
284
|
+
// Seven bars on a 320px phone leave about 40px a column, so "18 of 25" may wrap here.
|
|
285
|
+
.wui-bar-chart-vertical .wui-bar-chart-value {
|
|
286
|
+
grid-area: value;
|
|
287
|
+
white-space: normal;
|
|
288
|
+
}
|
|
289
|
+
.wui-bar-chart-vertical .wui-bar-chart-track {
|
|
290
|
+
grid-area: track;
|
|
291
|
+
display: flex;
|
|
292
|
+
align-items: flex-end;
|
|
293
|
+
width: 100%;
|
|
294
|
+
max-width: 32px;
|
|
295
|
+
height: var(--wui-bar-chart-height, 180px);
|
|
296
|
+
border-radius: var(--radius-sm);
|
|
297
|
+
}
|
|
298
|
+
.wui-bar-chart-vertical .wui-bar-chart-fill {
|
|
299
|
+
width: 100%;
|
|
300
|
+
transition: height 300ms var(--wui-ease-out-quart);
|
|
301
|
+
}
|
|
302
|
+
.wui-bar-chart-vertical .wui-bar-chart-label {
|
|
303
|
+
grid-area: label;
|
|
304
|
+
font-size: 11px;
|
|
305
|
+
}
|
|
306
|
+
|
|
307
|
+
// ============================================================================
|
|
308
|
+
// Chart element: <wui-chart> (AppChart, <app-chart>)
|
|
309
|
+
// ============================================================================
|
|
310
|
+
// The element builds the legend, the drawing surface, the state box and the data table; the
|
|
311
|
+
// engine draws inside .wui-chart-canvas with colours the element reads from --wui-chart-*. The
|
|
312
|
+
// names here stay clear of the line and bar chart classes above.
|
|
313
|
+
wui-chart {
|
|
314
|
+
position: relative;
|
|
315
|
+
display: block;
|
|
316
|
+
min-width: 0;
|
|
317
|
+
color: var(--color-text-muted);
|
|
318
|
+
font-size: 12px;
|
|
319
|
+
}
|
|
320
|
+
|
|
321
|
+
.wui-chart-legend {
|
|
322
|
+
display: flex;
|
|
323
|
+
flex-wrap: wrap;
|
|
324
|
+
gap: 2px 8px;
|
|
325
|
+
margin: 0 0 8px -6px;
|
|
326
|
+
}
|
|
327
|
+
.wui-chart-legend[hidden] {
|
|
328
|
+
display: none;
|
|
329
|
+
}
|
|
330
|
+
// 24px tall: the WCAG 2.2 minimum target.
|
|
331
|
+
.wui-chart-legend-item {
|
|
332
|
+
display: inline-flex;
|
|
333
|
+
align-items: center;
|
|
334
|
+
gap: 8px;
|
|
335
|
+
min-height: 24px;
|
|
336
|
+
padding: 2px 6px;
|
|
337
|
+
border: 0;
|
|
338
|
+
border-radius: var(--radius-sm);
|
|
339
|
+
background: transparent;
|
|
340
|
+
color: var(--color-text-muted);
|
|
341
|
+
font: inherit;
|
|
342
|
+
cursor: pointer;
|
|
343
|
+
transition:
|
|
344
|
+
color 150ms var(--wui-ease-out-quart),
|
|
345
|
+
background-color 150ms var(--wui-ease-out-quart);
|
|
346
|
+
}
|
|
347
|
+
.wui-chart-legend-item:hover {
|
|
348
|
+
background: var(--color-bg-muted);
|
|
349
|
+
color: var(--color-text);
|
|
350
|
+
}
|
|
351
|
+
.wui-chart-legend-item:focus-visible {
|
|
352
|
+
outline: 2px solid var(--color-primary);
|
|
353
|
+
outline-offset: 1px;
|
|
354
|
+
}
|
|
355
|
+
.wui-chart-legend-swatch {
|
|
356
|
+
flex: none;
|
|
357
|
+
width: 10px;
|
|
358
|
+
height: 10px;
|
|
359
|
+
border-radius: 3px;
|
|
360
|
+
transition: opacity 150ms var(--wui-ease-out-quart);
|
|
361
|
+
}
|
|
362
|
+
.wui-chart-legend-swatch-line {
|
|
363
|
+
width: 14px;
|
|
364
|
+
height: 3px;
|
|
365
|
+
border-radius: 2px;
|
|
366
|
+
}
|
|
367
|
+
// A hidden series keeps its place: a faded key and a struck label, not colour alone.
|
|
368
|
+
.wui-chart-legend-item[aria-pressed="false"] {
|
|
369
|
+
color: var(--color-text-subtle);
|
|
370
|
+
}
|
|
371
|
+
.wui-chart-legend-item[aria-pressed="false"] .wui-chart-legend-swatch {
|
|
372
|
+
opacity: 0.3;
|
|
373
|
+
}
|
|
374
|
+
.wui-chart-legend-item[aria-pressed="false"] .wui-chart-legend-label {
|
|
375
|
+
text-decoration: line-through;
|
|
376
|
+
}
|
|
377
|
+
|
|
378
|
+
.wui-chart-surface {
|
|
379
|
+
position: relative;
|
|
380
|
+
width: 100%;
|
|
381
|
+
border-radius: var(--radius-sm);
|
|
382
|
+
transition: opacity 200ms var(--wui-ease-out-quart);
|
|
383
|
+
}
|
|
384
|
+
.wui-chart-surface:focus-visible {
|
|
385
|
+
outline: 2px solid var(--color-primary);
|
|
386
|
+
outline-offset: 4px;
|
|
387
|
+
}
|
|
388
|
+
.wui-chart-canvas {
|
|
389
|
+
width: 100%;
|
|
390
|
+
}
|
|
391
|
+
// Digits line up on SVG axes; a canvas has no such setting.
|
|
392
|
+
.wui-chart-canvas svg text {
|
|
393
|
+
font-variant-numeric: tabular-nums;
|
|
394
|
+
}
|
|
395
|
+
// New data on its way: the last picture stays, dimmed, so nothing jumps.
|
|
396
|
+
wui-chart[aria-busy="true"] .wui-chart-surface {
|
|
397
|
+
opacity: 0.45;
|
|
398
|
+
}
|
|
399
|
+
|
|
400
|
+
.wui-chart-state {
|
|
401
|
+
display: grid;
|
|
402
|
+
place-items: center;
|
|
403
|
+
padding: 16px;
|
|
404
|
+
text-align: center;
|
|
405
|
+
}
|
|
406
|
+
.wui-chart-state:has(.wui-chart-skeleton) {
|
|
407
|
+
padding: 0;
|
|
408
|
+
place-items: stretch;
|
|
409
|
+
}
|
|
410
|
+
.wui-chart-state-text {
|
|
411
|
+
max-width: 36ch;
|
|
412
|
+
margin: 0;
|
|
413
|
+
font-size: 13px;
|
|
414
|
+
color: var(--color-text-muted);
|
|
415
|
+
}
|
|
416
|
+
.wui-chart-skeleton {
|
|
417
|
+
width: 100%;
|
|
418
|
+
height: 100%;
|
|
419
|
+
}
|
|
420
|
+
|
|
421
|
+
// The engine positions the tooltip box and paints its fill, border and shadow from the theme;
|
|
422
|
+
// these style the content the element builds inside it.
|
|
423
|
+
.wui-chart-tooltip {
|
|
424
|
+
font: 12px/1.45 var(--bs-body-font-family);
|
|
425
|
+
}
|
|
426
|
+
.wui-chart-tooltip-body {
|
|
427
|
+
min-width: 168px;
|
|
428
|
+
color: var(--color-text-body);
|
|
429
|
+
}
|
|
430
|
+
.wui-chart-tooltip-title {
|
|
431
|
+
margin-bottom: 6px;
|
|
432
|
+
font-size: 11.5px;
|
|
433
|
+
font-weight: 500;
|
|
434
|
+
color: var(--color-text-subtle);
|
|
435
|
+
}
|
|
436
|
+
.wui-chart-tooltip-row {
|
|
437
|
+
display: flex;
|
|
438
|
+
align-items: center;
|
|
439
|
+
gap: 8px;
|
|
440
|
+
padding: 1px 0;
|
|
441
|
+
}
|
|
442
|
+
.wui-chart-tooltip-swatch {
|
|
443
|
+
flex: none;
|
|
444
|
+
width: 8px;
|
|
445
|
+
height: 8px;
|
|
446
|
+
border-radius: 2px;
|
|
447
|
+
}
|
|
448
|
+
.wui-chart-tooltip-swatch-line {
|
|
449
|
+
width: 12px;
|
|
450
|
+
height: 3px;
|
|
451
|
+
}
|
|
452
|
+
.wui-chart-tooltip-label {
|
|
453
|
+
color: var(--color-text-muted);
|
|
454
|
+
}
|
|
455
|
+
.wui-chart-tooltip-value {
|
|
456
|
+
margin-left: auto;
|
|
457
|
+
padding-left: 16px;
|
|
458
|
+
font-weight: 600;
|
|
459
|
+
color: var(--color-text);
|
|
460
|
+
font-variant-numeric: tabular-nums;
|
|
461
|
+
white-space: nowrap;
|
|
462
|
+
}
|
|
463
|
+
.wui-chart-tooltip-foot {
|
|
464
|
+
margin-top: 6px;
|
|
465
|
+
padding-top: 6px;
|
|
466
|
+
border-top: 1px solid var(--color-border);
|
|
467
|
+
font-size: 11.5px;
|
|
468
|
+
color: var(--color-text-subtle);
|
|
469
|
+
}
|
|
470
|
+
|
|
471
|
+
// The table view: the same height as the chart, scrolling inside itself.
|
|
472
|
+
.wui-chart-table-wrap {
|
|
473
|
+
overflow: auto;
|
|
474
|
+
border: 1px solid var(--color-border);
|
|
475
|
+
border-radius: var(--radius-sm);
|
|
476
|
+
}
|
|
477
|
+
.wui-chart-table {
|
|
478
|
+
width: 100%;
|
|
479
|
+
margin: 0;
|
|
480
|
+
border-collapse: collapse;
|
|
481
|
+
font-size: 13px;
|
|
482
|
+
color: var(--color-text-body);
|
|
483
|
+
}
|
|
484
|
+
.wui-chart-table th,
|
|
485
|
+
.wui-chart-table td {
|
|
486
|
+
padding: 8px 12px;
|
|
487
|
+
border-bottom: 1px solid var(--color-border);
|
|
488
|
+
text-align: left;
|
|
489
|
+
}
|
|
490
|
+
.wui-chart-table thead th {
|
|
491
|
+
position: sticky;
|
|
492
|
+
top: 0;
|
|
493
|
+
z-index: 1;
|
|
494
|
+
background: var(--color-bg-muted);
|
|
495
|
+
color: var(--color-text-muted);
|
|
496
|
+
font-size: 12px;
|
|
497
|
+
font-weight: 600;
|
|
498
|
+
white-space: nowrap;
|
|
499
|
+
}
|
|
500
|
+
.wui-chart-table tbody th {
|
|
501
|
+
font-weight: 500;
|
|
502
|
+
}
|
|
503
|
+
.wui-chart-table .wui-chart-num {
|
|
504
|
+
text-align: right;
|
|
505
|
+
font-variant-numeric: tabular-nums;
|
|
506
|
+
white-space: nowrap;
|
|
507
|
+
}
|
|
508
|
+
.wui-chart-table-note {
|
|
509
|
+
margin: 0;
|
|
510
|
+
padding: 8px 12px;
|
|
511
|
+
font-size: 12px;
|
|
512
|
+
color: var(--color-text-subtle);
|
|
513
|
+
}
|
|
514
|
+
|
|
515
|
+
@media (prefers-reduced-motion: reduce) {
|
|
516
|
+
.wui-chart-dot,
|
|
517
|
+
.wui-chart-tip,
|
|
518
|
+
.wui-bar-chart-fill,
|
|
519
|
+
.wui-chart-legend-item,
|
|
520
|
+
.wui-chart-legend-swatch,
|
|
521
|
+
.wui-chart-surface {
|
|
522
|
+
transition: none;
|
|
523
|
+
}
|
|
524
|
+
}
|
|
@@ -0,0 +1,53 @@
|
|
|
1
|
+
// ── Context menu ──
|
|
2
|
+
// AppContextMenu / <app-context-menu> / <wui-context-menu>: a right-click menu over a region.
|
|
3
|
+
// The panel is a Bootstrap .dropdown-menu with .dropdown-item rows, so the look, the danger tone
|
|
4
|
+
// and the icon treatment come from the shared dropdown styles; this partial only adds what a
|
|
5
|
+
// menu opened at the pointer needs. The element shows the panel with [data-open] (never `.show`,
|
|
6
|
+
// which a React re-render would reset) and places it with position: fixed, so it escapes any
|
|
7
|
+
// clipping ancestor. Every colour is a theme token.
|
|
8
|
+
//
|
|
9
|
+
// Part of the wui-components layer, see _wui-components.scss for load order.
|
|
10
|
+
|
|
11
|
+
// The element wraps the region without taking part in its layout.
|
|
12
|
+
wui-context-menu {
|
|
13
|
+
display: contents;
|
|
14
|
+
}
|
|
15
|
+
|
|
16
|
+
.dropdown-menu.wui-context-menu-panel {
|
|
17
|
+
position: fixed;
|
|
18
|
+
// Above a modal, like every other portalled menu (see --wui-z-* in _tokens.scss).
|
|
19
|
+
z-index: var(--wui-z-menu);
|
|
20
|
+
// Never taller than the screen; anchorOverlay clamps it further when the pointer is low.
|
|
21
|
+
max-height: calc(100vh - 8px);
|
|
22
|
+
// Focus lands on the panel itself after a pointer open; the rows carry the visible focus.
|
|
23
|
+
outline: none;
|
|
24
|
+
transform-origin: top left;
|
|
25
|
+
|
|
26
|
+
&[data-open] {
|
|
27
|
+
display: block;
|
|
28
|
+
animation: var(--wui-menu-anim) var(--wui-menu-anim-duration) var(--wui-menu-anim-ease);
|
|
29
|
+
}
|
|
30
|
+
&.drop-up {
|
|
31
|
+
--wui-menu-drop: 6px;
|
|
32
|
+
|
|
33
|
+
transform-origin: bottom left;
|
|
34
|
+
}
|
|
35
|
+
|
|
36
|
+
// A row the user can reach with the keyboard shows where it is.
|
|
37
|
+
.dropdown-item:focus-visible {
|
|
38
|
+
outline: 2px solid var(--color-primary);
|
|
39
|
+
outline-offset: -2px;
|
|
40
|
+
}
|
|
41
|
+
// Listed but unchoosable: quiet, and no hover tint.
|
|
42
|
+
.dropdown-item[aria-disabled="true"] {
|
|
43
|
+
color: var(--color-text-subtle);
|
|
44
|
+
cursor: default;
|
|
45
|
+
background: transparent;
|
|
46
|
+
}
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
@media (prefers-reduced-motion: reduce) {
|
|
50
|
+
.dropdown-menu.wui-context-menu-panel[data-open] {
|
|
51
|
+
animation: none;
|
|
52
|
+
}
|
|
53
|
+
}
|
package/scss/wui/_data.scss
CHANGED
|
@@ -791,12 +791,14 @@
|
|
|
791
791
|
outline-offset: -2px;
|
|
792
792
|
}
|
|
793
793
|
|
|
794
|
-
// Stacked on phones (AppDataTable `stackOnMobile`, Razor `stack-on-mobile`): below
|
|
795
|
-
// card. The first column (after the library's select/expand cells) leads the card at full
|
|
796
|
-
// every other cell is a "label: value" line from its data-label, the select checkbox sits in
|
|
797
|
-
// card's top corner and the row actions close the card. The header row is visually hidden, not
|
|
798
|
-
// removed, so the column names stay available to assistive technology.
|
|
799
|
-
|
|
794
|
+
// Stacked on phones (AppDataTable `stackOnMobile`, Razor `stack-on-mobile`): below md (768px) each
|
|
795
|
+
// row is a card. The first column (after the library's select/expand cells) leads the card at full
|
|
796
|
+
// width, every other cell is a "label: value" line from its data-label, the select checkbox sits in
|
|
797
|
+
// the card's top corner and the row actions close the card. The header row is visually hidden, not
|
|
798
|
+
// removed, so the column names stay available to assistive technology. 768 matches the phone shell
|
|
799
|
+
// (its bottom tab bar shows below the same width): a ledger squeezed into a 600px column scrolled
|
|
800
|
+
// sideways while the rest of the page was already in its phone layout.
|
|
801
|
+
@include media-breakpoint-down(md) {
|
|
800
802
|
// Cards flow with the page: no sideways scroll, and no maxHeight scroll box (an inline
|
|
801
803
|
// max-height from `maxHeight` has to be overridden, hence !important).
|
|
802
804
|
.table-wrap:has(> .table-ledger.wui-table-stack) {
|
package/scss/wui/_display.scss
CHANGED
|
@@ -200,7 +200,7 @@
|
|
|
200
200
|
// never read as serif. A product that wants its own face overrides this one selector.
|
|
201
201
|
// Size comes from --wui-kpi-value-size (44px default, set on the spotlight root above), so a
|
|
202
202
|
// custom `valueSize` (px) can tame a too-large headline.
|
|
203
|
-
font-family:
|
|
203
|
+
font-family: var(--wui-font-display);
|
|
204
204
|
line-height: 1;
|
|
205
205
|
font-weight: 600;
|
|
206
206
|
}
|