opui-css 4.0.1 → 5.0.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/CHANGELOG.md +35 -0
- package/MIGRATING.md +23 -1
- package/README.md +2 -3
- package/components/AGENTS.md +20 -19
- package/components/Accordion/Accordion.astro +3 -3
- package/components/Anchor/Anchor.astro +2 -2
- package/components/Avatar/Avatar.astro +2 -8
- package/components/Badge/Badge.astro +12 -7
- package/components/Button/Button.astro +1 -1
- package/components/ButtonGroup/ButtonGroup.astro +1 -1
- package/components/Callout/Callout.astro +3 -3
- package/components/Card/Card.astro +5 -7
- package/components/Checkbox/Checkbox.astro +6 -6
- package/components/Chip/Chip.astro +5 -5
- package/components/ClassicSelect/ClassicSelect.astro +6 -6
- package/components/DescriptionList/Description.astro +1 -1
- package/components/DescriptionList/DescriptionList.astro +2 -2
- package/components/DescriptionList/Item.astro +1 -1
- package/components/DescriptionList/Term.astro +1 -1
- package/components/Dialog/Dialog.astro +5 -7
- package/components/Divider/Divider.astro +4 -1
- package/components/Drawer/Drawer.astro +5 -5
- package/components/Drawer/DrawerFooter.astro +1 -1
- package/components/Drawer/DrawerHeader.astro +1 -1
- package/components/FieldDescription/FieldDescription.astro +1 -1
- package/components/FieldGroup/FieldGroup.astro +1 -1
- package/components/FieldLegend/FieldLegend.astro +1 -1
- package/components/FieldSet/FieldSet.astro +1 -1
- package/components/Form/Form.astro +1 -1
- package/components/IconButton/IconButton.astro +1 -1
- package/components/List/List.astro +5 -5
- package/components/ListItem/ListItem.astro +12 -12
- package/components/Progress/Progress.astro +1 -1
- package/components/Radio/Radio.astro +5 -5
- package/components/Range/Range.astro +8 -8
- package/components/Select/Select.astro +13 -13
- package/components/Switch/Switch.astro +8 -8
- package/components/Table/Table.astro +4 -1
- package/components/Tabs/Tabs.astro +1 -1
- package/components/Tabs/TabsItem.astro +1 -1
- package/components/Tabs/TabsPanel.astro +1 -1
- package/components/Tabs/TabsTab.astro +1 -1
- package/components/TextField/TextField.astro +13 -13
- package/components/Textarea/Textarea.astro +13 -13
- package/components/Toast/Toast.astro +6 -6
- package/components/ToggleButton/ToggleButton.astro +3 -3
- package/components/ToggleGroup/ToggleGroup.astro +3 -3
- package/components/Tooltip/Tooltip.astro +1 -1
- package/core/utils.css +4 -4
- package/css/components/accordion.css +11 -11
- package/css/components/anchor.css +3 -3
- package/css/components/avatar.css +5 -5
- package/css/components/badge.css +14 -14
- package/css/components/button-group.css +16 -16
- package/css/components/button.css +12 -12
- package/css/components/callout.css +9 -9
- package/css/components/card.css +12 -12
- package/css/components/checkbox.css +13 -13
- package/css/components/chip.css +5 -5
- package/css/components/description-list.css +11 -8
- package/css/components/dialog.css +3 -3
- package/css/components/divider.css +4 -4
- package/css/components/drawer.css +21 -21
- package/css/components/form.css +18 -18
- package/css/components/icon-button.css +9 -9
- package/css/components/link.css +1 -1
- package/css/components/list.css +29 -29
- package/css/components/progress.css +4 -4
- package/css/components/radio.css +10 -10
- package/css/components/range.css +31 -31
- package/css/components/select.css +4 -4
- package/css/components/spinner.css +1 -1
- package/css/components/switch.css +23 -23
- package/css/components/table.css +3 -3
- package/css/components/tabs.css +14 -8
- package/css/components/text-field.css +47 -47
- package/css/components/text-input.css +7 -7
- package/css/components/textarea.css +3 -3
- package/css/components/toast.css +12 -12
- package/css/components/toggle-button.css +6 -6
- package/css/components/toggle-group.css +10 -10
- package/css/components/tooltip.css +6 -6
- package/css/components/typography.css +30 -30
- package/css/js/toast.js +7 -7
- package/css/theme.css +8 -8
- package/dist/opui.components.css +407 -398
- package/dist/opui.components.css.map +1 -1
- package/dist/opui.css +419 -410
- package/dist/opui.css.map +1 -1
- package/package.json +1 -1
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
- Common styling for input, textarea and select
|
|
5
5
|
- Form related styles such as: label, supporting text, error handling
|
|
6
6
|
*/
|
|
7
|
-
:where(.text-field, .textarea, .select) {
|
|
7
|
+
:where(.ui-text-field, .ui-textarea, .ui-select) {
|
|
8
8
|
--_accent-color: var(--primary);
|
|
9
9
|
--_bg-color: var(--surface-default);
|
|
10
10
|
--_border-color: var(--field-border-color);
|
|
@@ -20,7 +20,7 @@
|
|
|
20
20
|
position: relative;
|
|
21
21
|
|
|
22
22
|
/* Field - the actual input with a border around it */
|
|
23
|
-
.field {
|
|
23
|
+
.ui-field {
|
|
24
24
|
background-color: var(--_bg-color);
|
|
25
25
|
border: var(--field-border-width) solid var(--_border-color);
|
|
26
26
|
border-radius: var(--field-border-radius);
|
|
@@ -39,7 +39,7 @@
|
|
|
39
39
|
}
|
|
40
40
|
}
|
|
41
41
|
|
|
42
|
-
:where(.field) :where(input, textarea, select) {
|
|
42
|
+
:where(.ui-field) :where(input, textarea, select) {
|
|
43
43
|
background: transparent;
|
|
44
44
|
border: 0;
|
|
45
45
|
color: var(--text-primary);
|
|
@@ -58,8 +58,8 @@
|
|
|
58
58
|
}
|
|
59
59
|
|
|
60
60
|
/* Affixes */
|
|
61
|
-
.prefix,
|
|
62
|
-
.suffix {
|
|
61
|
+
.ui-prefix,
|
|
62
|
+
.ui-suffix {
|
|
63
63
|
align-items: center;
|
|
64
64
|
color: var(--_label-color);
|
|
65
65
|
display: inline-flex;
|
|
@@ -67,16 +67,16 @@
|
|
|
67
67
|
white-space: nowrap;
|
|
68
68
|
}
|
|
69
69
|
|
|
70
|
-
.prefix {
|
|
70
|
+
.ui-prefix {
|
|
71
71
|
grid-area: prefix;
|
|
72
72
|
}
|
|
73
73
|
|
|
74
|
-
.suffix {
|
|
74
|
+
.ui-suffix {
|
|
75
75
|
grid-area: suffix;
|
|
76
76
|
}
|
|
77
77
|
|
|
78
|
-
.header,
|
|
79
|
-
.footer {
|
|
78
|
+
.ui-header,
|
|
79
|
+
.ui-footer {
|
|
80
80
|
align-items: center;
|
|
81
81
|
color: var(--_label-color);
|
|
82
82
|
display: flex;
|
|
@@ -85,30 +85,30 @@
|
|
|
85
85
|
padding: var(--size-1) var(--_field-padding-inline);
|
|
86
86
|
}
|
|
87
87
|
|
|
88
|
-
.header {
|
|
88
|
+
.ui-header {
|
|
89
89
|
border-block-end: 1px solid var(--_border-color);
|
|
90
90
|
grid-area: header;
|
|
91
91
|
}
|
|
92
92
|
|
|
93
|
-
.footer {
|
|
93
|
+
.ui-footer {
|
|
94
94
|
border-block-start: 1px solid var(--_border-color);
|
|
95
95
|
grid-area: footer;
|
|
96
96
|
}
|
|
97
97
|
|
|
98
98
|
/* Remove padding on the input when affixes are next to it */
|
|
99
|
-
.field:has(> .prefix) :where(input, textarea, select) {
|
|
99
|
+
.ui-field:has(> .ui-prefix) :where(input, textarea, select) {
|
|
100
100
|
padding-inline-start: 0;
|
|
101
101
|
}
|
|
102
102
|
|
|
103
|
-
.field:has(> .suffix) :where(input, textarea, select) {
|
|
103
|
+
.ui-field:has(> .ui-suffix) :where(input, textarea, select) {
|
|
104
104
|
padding-inline-end: 0;
|
|
105
105
|
}
|
|
106
106
|
|
|
107
107
|
/* Textarea - keep affix aligned with the first line */
|
|
108
|
-
&.textarea .field {
|
|
108
|
+
&.ui-textarea .ui-field {
|
|
109
109
|
|
|
110
|
-
.prefix,
|
|
111
|
-
.suffix {
|
|
110
|
+
.ui-prefix,
|
|
111
|
+
.ui-suffix {
|
|
112
112
|
align-self: start;
|
|
113
113
|
padding-block: var(--_field-padding-block);
|
|
114
114
|
}
|
|
@@ -116,7 +116,7 @@
|
|
|
116
116
|
|
|
117
117
|
/* Required/Invalid */
|
|
118
118
|
&:has(:invalid) {
|
|
119
|
-
.label:after {
|
|
119
|
+
.ui-label:after {
|
|
120
120
|
color: var(--red);
|
|
121
121
|
content: "*";
|
|
122
122
|
margin: -0.25em auto auto 0.25em;
|
|
@@ -151,7 +151,7 @@
|
|
|
151
151
|
}
|
|
152
152
|
|
|
153
153
|
/* Variants */
|
|
154
|
-
&.filled {
|
|
154
|
+
&.ui-filled {
|
|
155
155
|
input {
|
|
156
156
|
|
|
157
157
|
&::-webkit-file-upload-button,
|
|
@@ -166,7 +166,7 @@
|
|
|
166
166
|
}
|
|
167
167
|
|
|
168
168
|
/* Sizes */
|
|
169
|
-
&.small {
|
|
169
|
+
&.ui-small {
|
|
170
170
|
input {
|
|
171
171
|
font-size: var(--font-size-05);
|
|
172
172
|
|
|
@@ -181,7 +181,7 @@
|
|
|
181
181
|
|
|
182
182
|
/* Autosuggest */
|
|
183
183
|
&:has(input[list]) {
|
|
184
|
-
.label {
|
|
184
|
+
.ui-label {
|
|
185
185
|
/* Make sure chevron is visible */
|
|
186
186
|
inline-size: calc(100% - var(--size-6));
|
|
187
187
|
}
|
|
@@ -189,7 +189,7 @@
|
|
|
189
189
|
|
|
190
190
|
/* Select */
|
|
191
191
|
&:has(select) {
|
|
192
|
-
.label {
|
|
192
|
+
.ui-label {
|
|
193
193
|
/* Make sure chevron is visible */
|
|
194
194
|
inline-size: calc(100% - var(--size-6));
|
|
195
195
|
|
|
@@ -217,7 +217,7 @@
|
|
|
217
217
|
|
|
218
218
|
/* Input - color */
|
|
219
219
|
&:has(input[type="color"]) {
|
|
220
|
-
.field {
|
|
220
|
+
.ui-field {
|
|
221
221
|
block-size: var(--_height);
|
|
222
222
|
inline-size: var(--_height);
|
|
223
223
|
min-block-size: 0;
|
|
@@ -245,21 +245,21 @@
|
|
|
245
245
|
/* Element states */
|
|
246
246
|
&:hover {
|
|
247
247
|
&:not([data-invalid]) {
|
|
248
|
-
.field {
|
|
248
|
+
.ui-field {
|
|
249
249
|
border-color: var(--text-primary);
|
|
250
250
|
}
|
|
251
251
|
}
|
|
252
252
|
}
|
|
253
253
|
|
|
254
254
|
&:focus-within {
|
|
255
|
-
.field {
|
|
255
|
+
.ui-field {
|
|
256
256
|
border-color: var(--_accent-color);
|
|
257
257
|
outline-offset: -2px;
|
|
258
258
|
}
|
|
259
259
|
}
|
|
260
260
|
|
|
261
261
|
/* Label */
|
|
262
|
-
.label {
|
|
262
|
+
.ui-label {
|
|
263
263
|
color: var(--text-primary);
|
|
264
264
|
font-size: var(--font-size-05);
|
|
265
265
|
font-weight: 600;
|
|
@@ -269,7 +269,7 @@
|
|
|
269
269
|
}
|
|
270
270
|
|
|
271
271
|
/* End text */
|
|
272
|
-
:where(.end-text) {
|
|
272
|
+
:where(.ui-end-text) {
|
|
273
273
|
color: var(--_end-text-color);
|
|
274
274
|
font-size: var(--font-size-0);
|
|
275
275
|
grid-column: 1/-1;
|
|
@@ -278,10 +278,10 @@
|
|
|
278
278
|
}
|
|
279
279
|
|
|
280
280
|
/* Auto-fit */
|
|
281
|
-
&.auto-fit {
|
|
281
|
+
&.ui-auto-fit {
|
|
282
282
|
inline-size: auto;
|
|
283
283
|
|
|
284
|
-
.field {
|
|
284
|
+
.ui-field {
|
|
285
285
|
inline-size: auto;
|
|
286
286
|
}
|
|
287
287
|
|
|
@@ -305,7 +305,7 @@
|
|
|
305
305
|
/*
|
|
306
306
|
* Variant: Filled
|
|
307
307
|
*/
|
|
308
|
-
&.filled {
|
|
308
|
+
&.ui-filled {
|
|
309
309
|
--_bg-color: var(--surface-tonal);
|
|
310
310
|
|
|
311
311
|
&:not(:has([disabled], :has(input[type="color"]))) {
|
|
@@ -328,7 +328,7 @@
|
|
|
328
328
|
display: none;
|
|
329
329
|
}
|
|
330
330
|
|
|
331
|
-
.field {
|
|
331
|
+
.ui-field {
|
|
332
332
|
cursor: not-allowed;
|
|
333
333
|
}
|
|
334
334
|
|
|
@@ -340,9 +340,9 @@
|
|
|
340
340
|
}
|
|
341
341
|
}
|
|
342
342
|
|
|
343
|
-
.label,
|
|
344
|
-
.start-text,
|
|
345
|
-
.end-text {
|
|
343
|
+
.ui-label,
|
|
344
|
+
.ui-start-text,
|
|
345
|
+
.ui-end-text {
|
|
346
346
|
cursor: not-allowed;
|
|
347
347
|
}
|
|
348
348
|
}
|
|
@@ -363,31 +363,31 @@
|
|
|
363
363
|
}
|
|
364
364
|
|
|
365
365
|
/* Sizes */
|
|
366
|
-
&.small {
|
|
366
|
+
&.ui-small {
|
|
367
367
|
--_field-padding-block: var(--size-2);
|
|
368
368
|
--_height: var(--field-size-small);
|
|
369
369
|
|
|
370
370
|
&:has(input[type="color"]) {
|
|
371
|
-
.label {
|
|
371
|
+
.ui-label {
|
|
372
372
|
line-height: 1.5;
|
|
373
373
|
}
|
|
374
374
|
}
|
|
375
375
|
}
|
|
376
376
|
|
|
377
377
|
/* Orientation */
|
|
378
|
-
&.spread {
|
|
378
|
+
&.ui-spread {
|
|
379
379
|
align-items: start;
|
|
380
380
|
column-gap: var(--size-4);
|
|
381
381
|
container-type: inline-size;
|
|
382
382
|
grid-template-columns: 1fr auto;
|
|
383
383
|
|
|
384
|
-
.label {
|
|
384
|
+
.ui-label {
|
|
385
385
|
font-weight: 600;
|
|
386
386
|
grid-column: 1;
|
|
387
387
|
grid-row: 1;
|
|
388
388
|
}
|
|
389
389
|
|
|
390
|
-
.start-text {
|
|
390
|
+
.ui-start-text {
|
|
391
391
|
color: var(--_end-text-color);
|
|
392
392
|
font-size: var(--font-size-0);
|
|
393
393
|
grid-column: 1;
|
|
@@ -395,16 +395,16 @@
|
|
|
395
395
|
line-height: 1.5;
|
|
396
396
|
}
|
|
397
397
|
|
|
398
|
-
.field {
|
|
398
|
+
.ui-field {
|
|
399
399
|
align-self: start;
|
|
400
400
|
grid-column: 2;
|
|
401
401
|
grid-row: 1 / span 2;
|
|
402
402
|
}
|
|
403
403
|
|
|
404
|
-
.field:has(textarea) {
|
|
404
|
+
.ui-field:has(textarea) {
|
|
405
405
|
grid-row: 1 / span 3;
|
|
406
406
|
|
|
407
|
-
+.end-text {
|
|
407
|
+
+.ui-end-text {
|
|
408
408
|
grid-row: 4;
|
|
409
409
|
}
|
|
410
410
|
}
|
|
@@ -413,7 +413,7 @@
|
|
|
413
413
|
min-inline-size: 30ch;
|
|
414
414
|
}
|
|
415
415
|
|
|
416
|
-
:where(.end-text) {
|
|
416
|
+
:where(.ui-end-text) {
|
|
417
417
|
grid-column: 2;
|
|
418
418
|
text-align: end;
|
|
419
419
|
}
|
|
@@ -423,23 +423,23 @@
|
|
|
423
423
|
column-gap: 0;
|
|
424
424
|
grid-template-columns: 1fr;
|
|
425
425
|
|
|
426
|
-
.label {
|
|
426
|
+
.ui-label {
|
|
427
427
|
grid-column: 1;
|
|
428
428
|
grid-row: 1;
|
|
429
429
|
}
|
|
430
430
|
|
|
431
|
-
.start-text {
|
|
431
|
+
.ui-start-text {
|
|
432
432
|
grid-column: 1;
|
|
433
433
|
grid-row: 2;
|
|
434
434
|
}
|
|
435
435
|
|
|
436
|
-
.field,
|
|
437
|
-
.field:has(textarea) {
|
|
436
|
+
.ui-field,
|
|
437
|
+
.ui-field:has(textarea) {
|
|
438
438
|
grid-column: 1;
|
|
439
439
|
grid-row: 3;
|
|
440
440
|
}
|
|
441
441
|
|
|
442
|
-
:where(.end-text) {
|
|
442
|
+
:where(.ui-end-text) {
|
|
443
443
|
grid-column: 1;
|
|
444
444
|
grid-row: 4;
|
|
445
445
|
text-align: start;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
@layer components.extended {
|
|
2
2
|
|
|
3
|
-
:where(.text-field:has( :where(input[type="date"],
|
|
3
|
+
:where(.ui-text-field:has( :where(input[type="date"],
|
|
4
4
|
input[type="datetime-local"],
|
|
5
5
|
input[type="email"],
|
|
6
6
|
input[type="month"],
|
|
@@ -14,7 +14,7 @@
|
|
|
14
14
|
input[type="week"]))) {
|
|
15
15
|
|
|
16
16
|
/* Sizes */
|
|
17
|
-
&.small {
|
|
17
|
+
&.ui-small {
|
|
18
18
|
input {
|
|
19
19
|
padding-inline: var(--size-2);
|
|
20
20
|
}
|
|
@@ -22,8 +22,8 @@
|
|
|
22
22
|
}
|
|
23
23
|
|
|
24
24
|
/* Autosuggest */
|
|
25
|
-
:where(.text-field:has(input[list])) {
|
|
26
|
-
.field {
|
|
25
|
+
:where(.ui-text-field:has(input[list])) {
|
|
26
|
+
.ui-field {
|
|
27
27
|
position: relative;
|
|
28
28
|
}
|
|
29
29
|
|
|
@@ -39,7 +39,7 @@
|
|
|
39
39
|
padding-inline-end: var(--size-8);
|
|
40
40
|
}
|
|
41
41
|
|
|
42
|
-
.field::after {
|
|
42
|
+
.ui-field::after {
|
|
43
43
|
block-size: 0;
|
|
44
44
|
border-block-start: 5px solid;
|
|
45
45
|
border-inline: 5px solid transparent;
|
|
@@ -51,12 +51,12 @@
|
|
|
51
51
|
translate: 0 -50%;
|
|
52
52
|
}
|
|
53
53
|
|
|
54
|
-
&.small {
|
|
54
|
+
&.ui-small {
|
|
55
55
|
input[list] {
|
|
56
56
|
padding-inline-end: var(--size-7);
|
|
57
57
|
}
|
|
58
58
|
|
|
59
|
-
.field::after {
|
|
59
|
+
.ui-field::after {
|
|
60
60
|
inset-inline-end: var(--size-2);
|
|
61
61
|
}
|
|
62
62
|
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
@layer components.extended {
|
|
2
|
-
:where(.textarea) {
|
|
2
|
+
:where(.ui-textarea) {
|
|
3
3
|
textarea {
|
|
4
4
|
block-size: auto;
|
|
5
5
|
field-sizing: content;
|
|
@@ -8,14 +8,14 @@
|
|
|
8
8
|
}
|
|
9
9
|
|
|
10
10
|
/* Size */
|
|
11
|
-
&.small {
|
|
11
|
+
&.ui-small {
|
|
12
12
|
textarea {
|
|
13
13
|
min-block-size: var(--size-9);
|
|
14
14
|
}
|
|
15
15
|
}
|
|
16
16
|
|
|
17
17
|
/* Auto-fit */
|
|
18
|
-
&.auto-fit {
|
|
18
|
+
&.ui-auto-fit {
|
|
19
19
|
textarea {
|
|
20
20
|
resize: both;
|
|
21
21
|
}
|
package/css/components/toast.css
CHANGED
|
@@ -29,7 +29,7 @@
|
|
|
29
29
|
/* > .toast:nth-last-child(n + 6) { display: none; } */
|
|
30
30
|
}
|
|
31
31
|
|
|
32
|
-
:where(.toast) {
|
|
32
|
+
:where(.ui-toast) {
|
|
33
33
|
--_anim-enter: 0.3s;
|
|
34
34
|
--_anim-exit: 0.3s;
|
|
35
35
|
|
|
@@ -57,11 +57,11 @@
|
|
|
57
57
|
animation-play-state: paused;
|
|
58
58
|
}
|
|
59
59
|
|
|
60
|
-
&.exiting {
|
|
60
|
+
&.ui-exiting {
|
|
61
61
|
animation: toast-exit var(--_anim-exit) var(--ease-in-3) forwards;
|
|
62
62
|
}
|
|
63
63
|
|
|
64
|
-
.icon {
|
|
64
|
+
.ui-icon {
|
|
65
65
|
background: no-repeat center / contain;
|
|
66
66
|
block-size: var(--size-4);
|
|
67
67
|
flex-shrink: 0;
|
|
@@ -69,25 +69,25 @@
|
|
|
69
69
|
}
|
|
70
70
|
|
|
71
71
|
/* Hide the icon slot when there's no severity to render against. */
|
|
72
|
-
&:not([data-severity]) .icon {
|
|
72
|
+
&:not([data-severity]) .ui-icon {
|
|
73
73
|
display: none;
|
|
74
74
|
}
|
|
75
75
|
|
|
76
|
-
.content {
|
|
76
|
+
.ui-content {
|
|
77
77
|
font-size: var(--font-size-05);
|
|
78
78
|
word-break: break-word;
|
|
79
79
|
}
|
|
80
80
|
|
|
81
|
-
.title {
|
|
81
|
+
.ui-title {
|
|
82
82
|
font-weight: 600;
|
|
83
83
|
}
|
|
84
84
|
|
|
85
|
-
.description {
|
|
85
|
+
.ui-description {
|
|
86
86
|
color: oklch(from currentColor l c h / 75%);
|
|
87
87
|
font-size: var(--font-size-0);
|
|
88
88
|
}
|
|
89
89
|
|
|
90
|
-
.close-button {
|
|
90
|
+
.ui-close-button {
|
|
91
91
|
background: none;
|
|
92
92
|
border: none;
|
|
93
93
|
color: inherit;
|
|
@@ -104,19 +104,19 @@
|
|
|
104
104
|
}
|
|
105
105
|
|
|
106
106
|
/* Severity icons via CSS data URIs — keeps icon assets out of JS strings. */
|
|
107
|
-
&[data-severity="success"] .icon {
|
|
107
|
+
&[data-severity="success"] .ui-icon {
|
|
108
108
|
background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='20' height='20' viewBox='0 0 24 24' fill='none' stroke='%2322c55e' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'><path d='M22 11.08V12a10 10 0 1 1-5.93-9.14'/><path d='m9 11 3 3L22 4'/></svg>");
|
|
109
109
|
}
|
|
110
110
|
|
|
111
|
-
&[data-severity="info"] .icon {
|
|
111
|
+
&[data-severity="info"] .ui-icon {
|
|
112
112
|
background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='20' height='20' viewBox='0 0 24 24' fill='none' stroke='%233b82f6' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'><circle cx='12' cy='12' r='10'/><path d='M12 16v-4'/><path d='M12 8h.01'/></svg>");
|
|
113
113
|
}
|
|
114
114
|
|
|
115
|
-
&[data-severity="warning"] .icon {
|
|
115
|
+
&[data-severity="warning"] .ui-icon {
|
|
116
116
|
background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='20' height='20' viewBox='0 0 24 24' fill='none' stroke='%23f59e0b' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'><path d='m21.73 18-8-14a2 2 0 0 0-3.48 0l-8 14A2 2 0 0 0 4 21h16a2 2 0 0 0 1.73-3'/><path d='M12 9v4'/><path d='M12 17h.01'/></svg>");
|
|
117
117
|
}
|
|
118
118
|
|
|
119
|
-
&[data-severity="critical"] .icon {
|
|
119
|
+
&[data-severity="critical"] .ui-icon {
|
|
120
120
|
background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='20' height='20' viewBox='0 0 24 24' fill='none' stroke='%23ef4444' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'><circle cx='12' cy='12' r='10'/><path d='m15 9-6 6'/><path d='m9 9 6 6'/></svg>");
|
|
121
121
|
}
|
|
122
122
|
}
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
* Somehow handle when a group gets too wide for its container. Should it be handled?
|
|
3
3
|
*/
|
|
4
4
|
@layer components.root {
|
|
5
|
-
:where(.toggle-button) {
|
|
5
|
+
:where(.ui-toggle-button) {
|
|
6
6
|
--_button-bg-color: transparent;
|
|
7
7
|
--_size: var(--field-size);
|
|
8
8
|
--_svg-size: var(--size-4);
|
|
@@ -27,7 +27,7 @@
|
|
|
27
27
|
|
|
28
28
|
input[type="checkbox"],
|
|
29
29
|
input[type="radio"] {
|
|
30
|
-
/* utils.css > .sr-only */
|
|
30
|
+
/* utils.css > .ui-sr-only */
|
|
31
31
|
block-size: 1px;
|
|
32
32
|
clip-path: inset(50%);
|
|
33
33
|
inline-size: 1px;
|
|
@@ -38,7 +38,7 @@
|
|
|
38
38
|
|
|
39
39
|
/* Element states */
|
|
40
40
|
@media (pointer: fine) {
|
|
41
|
-
&:hover:not(.disabled) {
|
|
41
|
+
&:hover:not(.ui-disabled) {
|
|
42
42
|
--_button-bg-color: light-dark(oklch(0% 0 0 / 0.04), oklch(100% 0 0 / 0.08));
|
|
43
43
|
}
|
|
44
44
|
}
|
|
@@ -51,7 +51,7 @@
|
|
|
51
51
|
}
|
|
52
52
|
|
|
53
53
|
/* Disabled */
|
|
54
|
-
&.disabled {
|
|
54
|
+
&.ui-disabled {
|
|
55
55
|
border-color: color-mix(in oklch, var(--border-color) 50%, transparent);
|
|
56
56
|
color: color-mix(in oklch, var(--text-primary) 30%, transparent);
|
|
57
57
|
cursor: not-allowed;
|
|
@@ -76,11 +76,11 @@
|
|
|
76
76
|
}
|
|
77
77
|
|
|
78
78
|
/* Sizes */
|
|
79
|
-
&.small {
|
|
79
|
+
&.ui-small {
|
|
80
80
|
--_size: var(--field-size-small);
|
|
81
81
|
}
|
|
82
82
|
|
|
83
|
-
&.x-small {
|
|
83
|
+
&.ui-x-small {
|
|
84
84
|
--_size: var(--field-size-x-small);
|
|
85
85
|
}
|
|
86
86
|
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
@layer components.root {
|
|
2
|
-
:where(.toggle-group) {
|
|
2
|
+
:where(.ui-toggle-group) {
|
|
3
3
|
--_bg-color: var(--surface-default);
|
|
4
4
|
--_border-color: var(--border-color);
|
|
5
5
|
--_border-radius: var(--button-border-radius);
|
|
@@ -12,27 +12,27 @@
|
|
|
12
12
|
overflow: hidden;
|
|
13
13
|
|
|
14
14
|
/* Sizes */
|
|
15
|
-
&.small {
|
|
16
|
-
.toggle-button {
|
|
15
|
+
&.ui-small {
|
|
16
|
+
.ui-toggle-button {
|
|
17
17
|
--_size: var(--field-size-small);
|
|
18
18
|
}
|
|
19
19
|
}
|
|
20
20
|
|
|
21
|
-
&.x-small {
|
|
22
|
-
.toggle-button {
|
|
21
|
+
&.ui-x-small {
|
|
22
|
+
.ui-toggle-button {
|
|
23
23
|
--_size: var(--field-size-x-small);
|
|
24
24
|
}
|
|
25
25
|
}
|
|
26
26
|
|
|
27
27
|
/* Toggle button */
|
|
28
|
-
.toggle-button {
|
|
28
|
+
.ui-toggle-button {
|
|
29
29
|
border: 0;
|
|
30
30
|
border-radius: 0;
|
|
31
31
|
margin: 0;
|
|
32
32
|
}
|
|
33
33
|
|
|
34
|
-
&:not(.vertical) {
|
|
35
|
-
.toggle-button {
|
|
34
|
+
&:not(.ui-vertical) {
|
|
35
|
+
.ui-toggle-button {
|
|
36
36
|
border-inline-end: 1px solid var(--_border-color);
|
|
37
37
|
|
|
38
38
|
&:last-of-type {
|
|
@@ -41,10 +41,10 @@
|
|
|
41
41
|
}
|
|
42
42
|
}
|
|
43
43
|
|
|
44
|
-
&.vertical {
|
|
44
|
+
&.ui-vertical {
|
|
45
45
|
flex-direction: column;
|
|
46
46
|
|
|
47
|
-
.toggle-button {
|
|
47
|
+
.ui-toggle-button {
|
|
48
48
|
border-block-end: 1px solid var(--_border-color);
|
|
49
49
|
|
|
50
50
|
&:last-of-type {
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
@layer components.extended {
|
|
2
|
-
:where(.tooltip) {
|
|
2
|
+
:where(.ui-tooltip) {
|
|
3
3
|
--_tooltip-bg: light-dark(var(--gray-13), var(--gray-3));
|
|
4
4
|
--_tooltip-color: light-dark(var(--gray-1), var(--gray-15));
|
|
5
5
|
--_tooltip-offset: var(--size-2);
|
|
6
6
|
|
|
7
|
-
&>.anchor-floating {
|
|
7
|
+
&>.ui-anchor-floating {
|
|
8
8
|
background-color: var(--_tooltip-bg);
|
|
9
9
|
border-radius: var(--radius-2);
|
|
10
10
|
color: var(--_tooltip-color);
|
|
@@ -26,15 +26,15 @@
|
|
|
26
26
|
/* Optional arrow pointing from the tooltip toward the trigger.
|
|
27
27
|
Anchored to the same --anchor so it flips together with the
|
|
28
28
|
tooltip when position-try-fallbacks kicks in. */
|
|
29
|
-
&.with-arrow {
|
|
29
|
+
&.ui-with-arrow {
|
|
30
30
|
--_arrow-size: var(--size-2);
|
|
31
31
|
|
|
32
|
-
&>.anchor-floating {
|
|
32
|
+
&>.ui-anchor-floating {
|
|
33
33
|
/* Reserve space so the arrow doesn't overlap the trigger. */
|
|
34
34
|
--_tooltip-offset: calc(var(--size-2) + var(--_arrow-size) / 2);
|
|
35
35
|
}
|
|
36
36
|
|
|
37
|
-
&>.anchor-floating::before {
|
|
37
|
+
&>.ui-anchor-floating::before {
|
|
38
38
|
background-color: var(--_tooltip-bg);
|
|
39
39
|
block-size: var(--_arrow-size);
|
|
40
40
|
content: "";
|
|
@@ -48,7 +48,7 @@
|
|
|
48
48
|
}
|
|
49
49
|
|
|
50
50
|
/* Fade */
|
|
51
|
-
&>.anchor-floating[popover] {
|
|
51
|
+
&>.ui-anchor-floating[popover] {
|
|
52
52
|
opacity: 0;
|
|
53
53
|
transition:
|
|
54
54
|
display 0.15s allow-discrete,
|