opui-css 5.0.1 → 5.1.1

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.
Files changed (58) hide show
  1. package/CHANGELOG.md +45 -0
  2. package/MIGRATING.md +11 -0
  3. package/README.md +1 -1
  4. package/components/Accordion/Accordion.astro +12 -2
  5. package/components/Anchor/Anchor.astro +5 -1
  6. package/components/ButtonGroup/ButtonGroup.astro +8 -1
  7. package/components/Card/Card.astro +3 -1
  8. package/components/Checkbox/Checkbox.astro +3 -3
  9. package/components/ClassicSelect/ClassicSelect.astro +3 -3
  10. package/components/Dialog/Dialog.astro +3 -1
  11. package/components/Radio/Radio.astro +3 -3
  12. package/components/Select/Select.astro +3 -3
  13. package/components/Switch/Switch.astro +3 -3
  14. package/components/TextField/TextField.astro +3 -3
  15. package/components/Textarea/Textarea.astro +3 -3
  16. package/core/normalize.css +16 -10
  17. package/core/palette.css +313 -58
  18. package/core/utils.css +2 -2
  19. package/css/components/accordion.css +7 -7
  20. package/css/components/anchor.css +23 -23
  21. package/css/components/badge.css +4 -4
  22. package/css/components/button-group.css +28 -14
  23. package/css/components/button.css +29 -17
  24. package/css/components/callout.css +95 -92
  25. package/css/components/card.css +6 -8
  26. package/css/components/checkbox.css +209 -203
  27. package/css/components/chip.css +11 -6
  28. package/css/components/description-list.css +2 -1
  29. package/css/components/dialog.css +2 -1
  30. package/css/components/drawer.css +167 -167
  31. package/css/components/form.css +8 -7
  32. package/css/components/icon-button.css +32 -13
  33. package/css/components/list.css +10 -12
  34. package/css/components/progress.css +4 -3
  35. package/css/components/radio.css +168 -170
  36. package/css/components/range.css +14 -9
  37. package/css/components/select.css +9 -6
  38. package/css/components/spinner.css +4 -3
  39. package/css/components/switch.css +8 -5
  40. package/css/components/table.css +4 -10
  41. package/css/components/tabs.css +17 -16
  42. package/css/components/text-field.css +9 -10
  43. package/css/components/text-input.css +8 -4
  44. package/css/components/textarea.css +3 -1
  45. package/css/components/toast.css +156 -157
  46. package/css/components/toggle-button.css +76 -72
  47. package/css/components/tooltip.css +59 -56
  48. package/css/components/typography.css +31 -31
  49. package/css/imports.css +5 -4
  50. package/css/theme.css +14 -20
  51. package/dist/op.css +0 -62
  52. package/dist/op.css.map +1 -1
  53. package/dist/opui.components.css +1259 -1184
  54. package/dist/opui.components.css.map +1 -1
  55. package/dist/opui.css +1719 -1393
  56. package/dist/opui.css.map +1 -1
  57. package/open-props.css +0 -1
  58. package/package.json +1 -1
package/dist/opui.css CHANGED
@@ -1,4 +1,4 @@
1
- @layer openprops, normalize, theme, components.root, components.extended, utils;
1
+ @layer openprops, theme, normalize, components.root, components.extended, utils;
2
2
 
3
3
  /* Open Props */
4
4
 
@@ -995,73 +995,453 @@
995
995
  }
996
996
  }
997
997
 
998
- @layer openprops{
998
+ /* Theme */
999
999
 
1000
- :where(:root) {
1001
- --palette-hue: 250;
1002
- /* <angle */
1003
- --palette-hue-rotate-by: 0;
1004
- /* +- deg : warm or cool the palette */
1005
- --palette-chroma: 0.15;
1006
- /* 0-1 : lower to mute and pastel, over 2 at own risk */
1000
+ @property --color-1 {
1001
+ syntax: "<color>";
1002
+ inherits: true;
1003
+ initial-value: transparent;
1004
+ }
1005
+
1006
+ @property --color-2 {
1007
+ syntax: "<color>";
1008
+ inherits: true;
1009
+ initial-value: transparent;
1010
+ }
1011
+
1012
+ @property --color-3 {
1013
+ syntax: "<color>";
1014
+ inherits: true;
1015
+ initial-value: transparent;
1016
+ }
1017
+
1018
+ @property --color-4 {
1019
+ syntax: "<color>";
1020
+ inherits: true;
1021
+ initial-value: transparent;
1022
+ }
1023
+
1024
+ @property --color-5 {
1025
+ syntax: "<color>";
1026
+ inherits: true;
1027
+ initial-value: transparent;
1028
+ }
1029
+
1030
+ @property --color-6 {
1031
+ syntax: "<color>";
1032
+ inherits: true;
1033
+ initial-value: transparent;
1034
+ }
1035
+
1036
+ @property --color-7 {
1037
+ syntax: "<color>";
1038
+ inherits: true;
1039
+ initial-value: transparent;
1040
+ }
1041
+
1042
+ @property --color-8 {
1043
+ syntax: "<color>";
1044
+ inherits: true;
1045
+ initial-value: transparent;
1046
+ }
1047
+
1048
+ @property --color-9 {
1049
+ syntax: "<color>";
1050
+ inherits: true;
1051
+ initial-value: transparent;
1052
+ }
1053
+
1054
+ @property --color-10 {
1055
+ syntax: "<color>";
1056
+ inherits: true;
1057
+ initial-value: transparent;
1058
+ }
1059
+
1060
+ @property --color-11 {
1061
+ syntax: "<color>";
1062
+ inherits: true;
1063
+ initial-value: transparent;
1064
+ }
1065
+
1066
+ @property --color-12 {
1067
+ syntax: "<color>";
1068
+ inherits: true;
1069
+ initial-value: transparent;
1070
+ }
1071
+
1072
+ @property --color-13 {
1073
+ syntax: "<color>";
1074
+ inherits: true;
1075
+ initial-value: transparent;
1076
+ }
1077
+
1078
+ @property --color-14 {
1079
+ syntax: "<color>";
1080
+ inherits: true;
1081
+ initial-value: transparent;
1082
+ }
1083
+
1084
+ @property --color-15 {
1085
+ syntax: "<color>";
1086
+ inherits: true;
1087
+ initial-value: transparent;
1088
+ }
1089
+
1090
+ @property --color-16 {
1091
+ syntax: "<color>";
1092
+ inherits: true;
1093
+ initial-value: transparent;
1094
+ }
1095
+
1096
+ @property --gray-1 {
1097
+ syntax: "<color>";
1098
+ inherits: true;
1099
+ initial-value: transparent;
1100
+ }
1101
+
1102
+ @property --gray-2 {
1103
+ syntax: "<color>";
1104
+ inherits: true;
1105
+ initial-value: transparent;
1106
+ }
1107
+
1108
+ @property --gray-3 {
1109
+ syntax: "<color>";
1110
+ inherits: true;
1111
+ initial-value: transparent;
1112
+ }
1113
+
1114
+ @property --gray-4 {
1115
+ syntax: "<color>";
1116
+ inherits: true;
1117
+ initial-value: transparent;
1118
+ }
1119
+
1120
+ @property --gray-5 {
1121
+ syntax: "<color>";
1122
+ inherits: true;
1123
+ initial-value: transparent;
1124
+ }
1125
+
1126
+ @property --gray-6 {
1127
+ syntax: "<color>";
1128
+ inherits: true;
1129
+ initial-value: transparent;
1130
+ }
1131
+
1132
+ @property --gray-7 {
1133
+ syntax: "<color>";
1134
+ inherits: true;
1135
+ initial-value: transparent;
1136
+ }
1137
+
1138
+ @property --gray-8 {
1139
+ syntax: "<color>";
1140
+ inherits: true;
1141
+ initial-value: transparent;
1142
+ }
1143
+
1144
+ @property --gray-9 {
1145
+ syntax: "<color>";
1146
+ inherits: true;
1147
+ initial-value: transparent;
1148
+ }
1149
+
1150
+ @property --gray-10 {
1151
+ syntax: "<color>";
1152
+ inherits: true;
1153
+ initial-value: transparent;
1154
+ }
1155
+
1156
+ @property --gray-11 {
1157
+ syntax: "<color>";
1158
+ inherits: true;
1159
+ initial-value: transparent;
1160
+ }
1161
+
1162
+ @property --gray-12 {
1163
+ syntax: "<color>";
1164
+ inherits: true;
1165
+ initial-value: transparent;
1166
+ }
1167
+
1168
+ @property --gray-13 {
1169
+ syntax: "<color>";
1170
+ inherits: true;
1171
+ initial-value: transparent;
1172
+ }
1173
+
1174
+ @property --gray-14 {
1175
+ syntax: "<color>";
1176
+ inherits: true;
1177
+ initial-value: transparent;
1178
+ }
1007
1179
 
1008
- /* New API: a single OKLCH source that drives the entire ramp.
1009
- The default below derives from the legacy --palette-hue / --palette-chroma
1010
- vars so themes that haven't migrated keep working unchanged. Themes opting
1011
- into the new API just set --palette-source directly. */
1012
- --palette-source: oklch(58% calc(0.21 * var(--palette-chroma, 1)) var(--palette-hue, 250));
1180
+ @property --gray-15 {
1181
+ syntax: "<color>";
1182
+ inherits: true;
1183
+ initial-value: transparent;
1013
1184
  }
1014
1185
 
1015
- * {
1016
- --color-1: oklch(from var(--palette-source) 98% calc(0.03 * (c / 0.21)) calc(h + (0 * var(--palette-hue-rotate-by))));
1017
- --color-2: oklch(from var(--palette-source) 97% calc(0.06 * (c / 0.21)) calc(h + (1 * var(--palette-hue-rotate-by))));
1018
- --color-3: oklch(from var(--palette-source) 93% calc(0.1 * (c / 0.21)) calc(h + (2 * var(--palette-hue-rotate-by))));
1019
- --color-4: oklch(from var(--palette-source) 84% calc(0.12 * (c / 0.21)) calc(h + (3 * var(--palette-hue-rotate-by))));
1020
- --color-5: oklch(from var(--palette-source) 80% calc(0.16 * (c / 0.21)) calc(h + (4 * var(--palette-hue-rotate-by))));
1021
- --color-6: oklch(from var(--palette-source) 71% calc(0.19 * (c / 0.21)) calc(h + (5 * var(--palette-hue-rotate-by))));
1022
- --color-7: oklch(from var(--palette-source) 66% calc(0.2 * (c / 0.21)) calc(h + (6 * var(--palette-hue-rotate-by))));
1023
- --color-8: oklch(from var(--palette-source) 58% calc(0.21 * (c / 0.21)) calc(h + (7 * var(--palette-hue-rotate-by))));
1024
- --color-9: oklch(from var(--palette-source) 53% calc(0.2 * (c / 0.21)) calc(h + (8 * var(--palette-hue-rotate-by))));
1025
- --color-10: oklch(from var(--palette-source) 49% calc(0.19 * (c / 0.21)) calc(h + (9 * var(--palette-hue-rotate-by))));
1026
- --color-11: oklch(from var(--palette-source) 42% calc(0.17 * (c / 0.21)) calc(h + (10 * var(--palette-hue-rotate-by))));
1027
- --color-12: oklch(from var(--palette-source) 35% calc(0.15 * (c / 0.21)) calc(h + (11 * var(--palette-hue-rotate-by))));
1028
- --color-13: oklch(from var(--palette-source) 27% calc(0.12 * (c / 0.21)) calc(h + (12 * var(--palette-hue-rotate-by))));
1029
- --color-14: oklch(from var(--palette-source) 20% calc(0.09 * (c / 0.21)) calc(h + (13 * var(--palette-hue-rotate-by))));
1030
- --color-15: oklch(from var(--palette-source) 16% calc(0.07 * (c / 0.21)) calc(h + (14 * var(--palette-hue-rotate-by))));
1031
- --color-16: oklch(from var(--palette-source) 10% calc(0.05 * (c / 0.21)) calc(h + (15 * var(--palette-hue-rotate-by))));
1186
+ @property --gray-16 {
1187
+ syntax: "<color>";
1188
+ inherits: true;
1189
+ initial-value: transparent;
1032
1190
  }
1033
1191
 
1034
- /* Gray ramp — derived from each --color-N step so it shares the palette's
1035
- per-step lightness curve. --gray-chroma / --gray-hue follow the Open Props
1036
- convention (hue is the third oklch arg, NOT lightness). Override either
1037
- in a theme to warm/cool the grays without redefining each --gray-N. */
1038
- * {
1039
- --gray-chroma: 0.01;
1040
- --gray-hue: 255;
1041
-
1042
- --gray-1: oklch(from var(--color-1) l var(--gray-chroma) var(--gray-hue));
1043
- --gray-2: oklch(from var(--color-2) l var(--gray-chroma) var(--gray-hue));
1044
- --gray-3: oklch(from var(--color-3) l var(--gray-chroma) var(--gray-hue));
1045
- --gray-4: oklch(from var(--color-4) l var(--gray-chroma) var(--gray-hue));
1046
- --gray-5: oklch(from var(--color-5) l var(--gray-chroma) var(--gray-hue));
1047
- --gray-6: oklch(from var(--color-6) l var(--gray-chroma) var(--gray-hue));
1048
- --gray-7: oklch(from var(--color-7) l var(--gray-chroma) var(--gray-hue));
1049
- --gray-8: oklch(from var(--color-8) l var(--gray-chroma) var(--gray-hue));
1050
- --gray-9: oklch(from var(--color-9) l var(--gray-chroma) var(--gray-hue));
1051
- --gray-10: oklch(from var(--color-10) l var(--gray-chroma) var(--gray-hue));
1052
- --gray-11: oklch(from var(--color-11) l var(--gray-chroma) var(--gray-hue));
1053
- --gray-12: oklch(from var(--color-12) l var(--gray-chroma) var(--gray-hue));
1054
- --gray-13: oklch(from var(--color-13) l var(--gray-chroma) var(--gray-hue));
1055
- --gray-14: oklch(from var(--color-14) l var(--gray-chroma) var(--gray-hue));
1056
- --gray-15: oklch(from var(--color-15) l var(--gray-chroma) var(--gray-hue));
1057
- --gray-16: oklch(from var(--color-16) l var(--gray-chroma) var(--gray-hue));
1192
+ @property --palette-source {
1193
+ syntax: "<color>";
1194
+ inherits: true;
1195
+ initial-value: transparent;
1058
1196
  }
1197
+
1198
+ @property --palette-hue {
1199
+ syntax: "<number>";
1200
+ inherits: true;
1201
+ initial-value: 240;
1202
+ }
1203
+
1204
+ @layer theme.palette {
1205
+ :where(
1206
+ :root,
1207
+ .ui-warning,
1208
+ .ui-critical,
1209
+ .ui-info,
1210
+ .ui-success,
1211
+ [data-invalid],
1212
+ del,
1213
+ ins,
1214
+ abbr,
1215
+ dfn,
1216
+ .ui-palette
1217
+ ) {
1218
+ --palette-hue: 250;
1219
+ --palette-hue-rotate-by: 0;
1220
+ --palette-chroma: 0.15;
1221
+
1222
+ --palette-source: oklch(
1223
+ 58% calc(0.21 * var(--palette-chroma, 1)) var(--palette-hue, 250)
1224
+ );
1225
+
1226
+ /* Colors */
1227
+ --color-1: oklch(
1228
+ from var(--palette-source) 98% calc(0.03 * (c / 0.21))
1229
+ calc(h + (0 * var(--palette-hue-rotate-by)))
1230
+ );
1231
+ --color-2: oklch(
1232
+ from var(--palette-source) 97% calc(0.06 * (c / 0.21))
1233
+ calc(h + (1 * var(--palette-hue-rotate-by)))
1234
+ );
1235
+ --color-3: oklch(
1236
+ from var(--palette-source) 93% calc(0.1 * (c / 0.21))
1237
+ calc(h + (2 * var(--palette-hue-rotate-by)))
1238
+ );
1239
+ --color-4: oklch(
1240
+ from var(--palette-source) 84% calc(0.12 * (c / 0.21))
1241
+ calc(h + (3 * var(--palette-hue-rotate-by)))
1242
+ );
1243
+ --color-5: oklch(
1244
+ from var(--palette-source) 80% calc(0.16 * (c / 0.21))
1245
+ calc(h + (4 * var(--palette-hue-rotate-by)))
1246
+ );
1247
+ --color-6: oklch(
1248
+ from var(--palette-source) 71% calc(0.19 * (c / 0.21))
1249
+ calc(h + (5 * var(--palette-hue-rotate-by)))
1250
+ );
1251
+ --color-7: oklch(
1252
+ from var(--palette-source) 66% calc(0.2 * (c / 0.21))
1253
+ calc(h + (6 * var(--palette-hue-rotate-by)))
1254
+ );
1255
+ --color-8: oklch(
1256
+ from var(--palette-source) 58% calc(0.21 * (c / 0.21))
1257
+ calc(h + (7 * var(--palette-hue-rotate-by)))
1258
+ );
1259
+ --color-9: oklch(
1260
+ from var(--palette-source) 53% calc(0.2 * (c / 0.21))
1261
+ calc(h + (8 * var(--palette-hue-rotate-by)))
1262
+ );
1263
+ --color-10: oklch(
1264
+ from var(--palette-source) 49% calc(0.19 * (c / 0.21))
1265
+ calc(h + (9 * var(--palette-hue-rotate-by)))
1266
+ );
1267
+ --color-11: oklch(
1268
+ from var(--palette-source) 42% calc(0.17 * (c / 0.21))
1269
+ calc(h + (10 * var(--palette-hue-rotate-by)))
1270
+ );
1271
+ --color-12: oklch(
1272
+ from var(--palette-source) 35% calc(0.15 * (c / 0.21))
1273
+ calc(h + (11 * var(--palette-hue-rotate-by)))
1274
+ );
1275
+ --color-13: oklch(
1276
+ from var(--palette-source) 27% calc(0.12 * (c / 0.21))
1277
+ calc(h + (12 * var(--palette-hue-rotate-by)))
1278
+ );
1279
+ --color-14: oklch(
1280
+ from var(--palette-source) 20% calc(0.09 * (c / 0.21))
1281
+ calc(h + (13 * var(--palette-hue-rotate-by)))
1282
+ );
1283
+ --color-15: oklch(
1284
+ from var(--palette-source) 16% calc(0.07 * (c / 0.21))
1285
+ calc(h + (14 * var(--palette-hue-rotate-by)))
1286
+ );
1287
+ --color-16: oklch(
1288
+ from var(--palette-source) 10% calc(0.05 * (c / 0.21))
1289
+ calc(h + (15 * var(--palette-hue-rotate-by)))
1290
+ );
1291
+
1292
+ /* Grays */
1293
+ --gray-chroma: 0.01;
1294
+ --gray-hue: 255;
1295
+
1296
+ --gray-1: oklch(from var(--color-1) l var(--gray-chroma) var(--gray-hue));
1297
+ --gray-2: oklch(from var(--color-2) l var(--gray-chroma) var(--gray-hue));
1298
+ --gray-3: oklch(from var(--color-3) l var(--gray-chroma) var(--gray-hue));
1299
+ --gray-4: oklch(from var(--color-4) l var(--gray-chroma) var(--gray-hue));
1300
+ --gray-5: oklch(from var(--color-5) l var(--gray-chroma) var(--gray-hue));
1301
+ --gray-6: oklch(from var(--color-6) l var(--gray-chroma) var(--gray-hue));
1302
+ --gray-7: oklch(from var(--color-7) l var(--gray-chroma) var(--gray-hue));
1303
+ --gray-8: oklch(from var(--color-8) l var(--gray-chroma) var(--gray-hue));
1304
+ --gray-9: oklch(from var(--color-9) l var(--gray-chroma) var(--gray-hue));
1305
+ --gray-10: oklch(from var(--color-10) l var(--gray-chroma) var(--gray-hue));
1306
+ --gray-11: oklch(from var(--color-11) l var(--gray-chroma) var(--gray-hue));
1307
+ --gray-12: oklch(from var(--color-12) l var(--gray-chroma) var(--gray-hue));
1308
+ --gray-13: oklch(from var(--color-13) l var(--gray-chroma) var(--gray-hue));
1309
+ --gray-14: oklch(from var(--color-14) l var(--gray-chroma) var(--gray-hue));
1310
+ --gray-15: oklch(from var(--color-15) l var(--gray-chroma) var(--gray-hue));
1311
+ --gray-16: oklch(from var(--color-16) l var(--gray-chroma) var(--gray-hue));
1312
+ }
1313
+ }
1314
+
1315
+ @layer theme {
1316
+
1317
+ /* 1. Color scheme */
1318
+ .ui-light {
1319
+ --color-scheme: light;
1320
+ }
1321
+
1322
+ .ui-dark {
1323
+ --color-scheme: dark;
1324
+ }
1325
+
1326
+ :where(html) {
1327
+ color-scheme: var(--color-scheme, light dark);
1328
+
1329
+ /* 2. Palette - override the values in core/palette.css */
1330
+ --palette-hue: light-dark(var(--hue-green), var(--hue-blue));
1331
+ --palette-chroma: 0.5;
1332
+ /* --palette-source: oklch(.58 calc(.21 * .5) var(--hue-blue)); */
1333
+
1334
+ /* Gray palette also lives in core/palette.css. */
1335
+ /*
1336
+ --gray-hue: 255;
1337
+ --gray-chroma: 0.01;
1338
+ */
1339
+
1340
+ /* 3. Named colors (no severity meaning) — use when you literally want a green/red/etc. dot */
1341
+ --blue: oklch(from var(--color-9) l 0.2 210);
1342
+ --green: oklch(from var(--color-9) l 0.2 145);
1343
+ --orange: oklch(from var(--color-7) l 0.2 75);
1344
+ --red: oklch(from var(--color-9) l 0.2 25);
1345
+
1346
+ /* 4. Intent tokens
1347
+ Severity (have scope classes below): --success, --info, --warning, --critical
1348
+ Non-severity (value-only): --primary, --neutral */
1349
+ --success: var(--green);
1350
+ --info: var(--blue);
1351
+ --warning: var(--orange);
1352
+ --critical: var(--red);
1353
+ --neutral: var(--gray-9);
1354
+
1355
+ /* 5. Primary */
1356
+ --primary: var(--color-8);
1357
+ --primary-light: oklch(from var(--primary) calc(l * 1.25) c h);
1358
+ --primary-dark: oklch(from var(--primary) calc(l * 0.75) c h);
1359
+ --primary-contrast: var(--gray-1);
1360
+
1361
+ /* 6. Text */
1362
+ --text-primary: light-dark(var(--gray-15), var(--gray-1));
1363
+ --text-primary-contrast: light-dark(var(--gray-2), var(--gray-15));
1364
+ --text-muted: light-dark(var(--gray-13), var(--gray-4));
1365
+ --text-muted-contrast: light-dark(var(--gray-4), var(--gray-13));
1366
+
1367
+ /* 7. Surfaces */
1368
+ --surface-default: light-dark(var(--gray-1), var(--gray-13));
1369
+ --surface-filled: light-dark(var(--gray-4), var(--gray-15));
1370
+ --surface-tonal: light-dark(var(--gray-3), var(--gray-12));
1371
+ --surface-elevated: light-dark(var(--gray-1), var(--gray-12));
1372
+
1373
+ /* 8. Borders */
1374
+ --border-color: light-dark(var(--gray-4), var(--gray-12));
1375
+ --border-radius: var(--size-2);
1376
+ --border-width: 1px;
1377
+
1378
+ /* 9. Focus ring */
1379
+ --focus-ring-color: var(--primary);
1380
+ --focus-ring-width: 2px;
1381
+ --focus-ring-offset: 2px;
1382
+ --focus-ring-style: solid;
1383
+
1384
+ /* 10. Typography */
1385
+ --font-size-h1: var(--font-size-fluid-3);
1386
+ --font-size-h2: var(--font-size-fluid-2);
1387
+ --font-size-h3: var(--font-size-fluid-1);
1388
+ --font-size-h4: var(--font-size-3);
1389
+ --font-size-h5: var(--font-size-2);
1390
+ --font-size-h6: var(--font-size-fluid-0);
1391
+
1392
+ /* Sneaking in an extra font size I want but Open Props doesn't provide. You can do whatever you want with your own theme. It's just CSS. */
1393
+ --font-size-05: 0.875rem;
1394
+
1395
+ /* 11. Control sizes — shared scale for fields and buttons so they line up. */
1396
+ --control-size-x-small: 28px;
1397
+ --control-size-small: 32px;
1398
+ --control-size: 40px;
1399
+ --control-size-large: 46px;
1400
+
1401
+ --field-size-x-small: var(--control-size-x-small);
1402
+ --field-size-small: var(--control-size-small);
1403
+ --field-size: var(--control-size);
1404
+ --field-size-large: var(--control-size-large);
1405
+
1406
+ --button-size-x-small: var(--control-size-x-small);
1407
+ --button-size-small: var(--control-size-small);
1408
+ --button-size: var(--control-size);
1409
+ --button-size-large: var(--control-size-large);
1410
+
1411
+ /* 12. Field / input */
1412
+ --field-border-color: var(--border-color);
1413
+ --field-border-radius: var(--size-2);
1414
+ --field-border-width: 1px;
1415
+
1416
+ /* 13. Button */
1417
+ --button-border-radius: var(--size-2);
1418
+ }
1419
+
1420
+ /* 14. Severity scope classes */
1421
+ :where(.ui-critical, [data-invalid], del) {
1422
+ --palette-source: oklch(0.58 0.21 var(--hue-red));
1423
+ --palette-hue-rotate-by: 1;
1424
+ }
1425
+
1426
+ :where(.ui-info, abbr, dfn) {
1427
+ --palette-source: oklch(0.58 0.21 var(--hue-blue));
1428
+ --palette-hue-rotate-by: 1;
1429
+ }
1430
+
1431
+ :where(.ui-success, ins) {
1432
+ --palette-source: oklch(0.58 0.21 var(--hue-green));
1433
+ --palette-hue-rotate-by: 1;
1434
+ }
1435
+
1436
+ :where(.ui-warning) {
1437
+ --palette-source: oklch(0.58 0.21 var(--hue-orange));
1438
+ --palette-hue-rotate-by: 1;
1439
+ }
1059
1440
  }
1060
1441
 
1061
1442
  /* Normalize */
1062
1443
 
1063
1444
  @layer normalize {
1064
-
1065
1445
  *,
1066
1446
  ::before,
1067
1447
  ::after {
@@ -1120,7 +1500,6 @@
1120
1500
  outline: none !important;
1121
1501
  }
1122
1502
 
1123
-
1124
1503
  :where(:not(fieldset, progress, meter)) {
1125
1504
  background-origin: border-box;
1126
1505
  background-repeat: no-repeat;
@@ -1176,7 +1555,9 @@
1176
1555
 
1177
1556
  :focus-visible {
1178
1557
  /* Inverts the --_page-bg-color */
1179
- --_focus-visible-color: rgb(from var(--_page-bg-color) calc(255 - r) calc(255 - g) calc(255 - b));
1558
+ --_focus-visible-color: rgb(
1559
+ from var(--_page-bg-color) calc(255 - r) calc(255 - g) calc(255 - b)
1560
+ );
1180
1561
 
1181
1562
  border-radius: var(--border-radius, 0px);
1182
1563
  outline: 2px solid var(--_focus-visible-color);
@@ -1185,7 +1566,7 @@
1185
1566
 
1186
1567
  @media (prefers-reduced-motion: no-preference) {
1187
1568
  :where(:focus-visible) {
1188
- transition: outline-offset .15 var(--ease-2);
1569
+ transition: outline-offset 0.15 var(--ease-2);
1189
1570
  }
1190
1571
 
1191
1572
  :where(:not(:active):focus-visible) {
@@ -1197,23 +1578,28 @@
1197
1578
  outline-offset: var(--outline-offset, 0px);
1198
1579
  }
1199
1580
 
1200
- :where(a[href],
1581
+ :where(
1582
+ a[href],
1201
1583
  area,
1202
1584
  button,
1203
- input:not([type="text"],
1585
+ input:not(
1586
+ [type="text"],
1204
1587
  [type="email"],
1205
1588
  [type="number"],
1206
1589
  [type="password"],
1207
1590
  [type=""],
1208
1591
  [type="tel"],
1209
- [type="url"]),
1592
+ [type="url"]
1593
+ ),
1210
1594
  label[for],
1211
1595
  select,
1212
- summary) {
1596
+ summary
1597
+ ) {
1213
1598
  cursor: pointer;
1214
1599
  }
1215
1600
 
1216
- :where(a[href],
1601
+ :where(
1602
+ a[href],
1217
1603
  area,
1218
1604
  button,
1219
1605
  [role="button"],
@@ -1222,7 +1608,8 @@
1222
1608
  select,
1223
1609
  summary,
1224
1610
  textarea,
1225
- [tabindex]:not([tabindex*="-"])) {
1611
+ [tabindex]:not([tabindex*="-"])
1612
+ ) {
1226
1613
  -webkit-tap-highlight-color: transparent;
1227
1614
  touch-action: manipulation;
1228
1615
  }
@@ -1255,179 +1642,51 @@
1255
1642
  }
1256
1643
  }
1257
1644
 
1258
- /* Theme */
1645
+ /* Components */
1259
1646
 
1260
1647
  /*
1261
- theme three theme setup
1648
+ * Components are divided into two categories - if they are stand-alone (root) or if they are built on top of others (extended).
1262
1649
  */
1263
1650
 
1264
- @layer theme {
1265
-
1266
- /* 1. Color scheme */
1267
- .ui-light {
1268
- --color-scheme: light;
1269
- }
1651
+ /*** Root components (no dependencies) */
1270
1652
 
1271
- .ui-dark {
1272
- --color-scheme: dark;
1273
- }
1653
+ @layer components.root {
1654
+ :where(.ui-button) {
1655
+ --_color: light-dark(var(--color-16), var(--color-1));
1656
+ --_color-contrast: light-dark(var(--color-1), var(--color-16));
1657
+ --_color-tonal: var(--surface-tonal);
1274
1658
 
1275
- :where(html) {
1276
- color-scheme: var(--color-scheme, light dark);
1659
+ --_accent: var(--_color);
1660
+ --_accent-contrast: var(--_color-contrast);
1661
+ --_accent-tonal: var(--_color-tonal);
1662
+ --_accent-tonal-contrast: var(--_color);
1277
1663
 
1278
- /* 2. Palette source - one value to rule them all. Every other color is derived from this one.
1279
- Both light/dark branches are wired up via light-dark() so prefers-color-scheme works
1280
- automatically. Set them to different OKLCH values if you want a distinct dark-mode palette. */
1281
- --palette-source: light-dark(oklch(0.58 calc(0.21 * 0.5) var(--hue-blue)),
1282
- oklch(0.58 calc(0.21 * 0.5) var(--hue-blue)));
1283
- --palette-hue-rotate-by: 0;
1664
+ --_default-hover-bg-color: light-dark(
1665
+ oklch(from var(--_accent) l 0.01 h / 10%),
1666
+ oklch(from var(--_accent) l 0.01 h / 20%)
1667
+ );
1668
+ --_default-active-bg-color: light-dark(
1669
+ oklch(from var(--_accent) l 0.06 h / 20%),
1670
+ oklch(from var(--_accent) l 0.06 h / 30%)
1671
+ );
1284
1672
 
1285
- /* Gray ramp lives in core/palette.css. Override --gray-chroma or
1286
- --gray-hue here if this theme wants warmer/cooler grays. */
1673
+ --_filled-hover-bg-color: light-dark(
1674
+ oklch(from var(--_accent) calc(l + 0.2) c h),
1675
+ oklch(from var(--_accent) calc(l - 0.1) c h)
1676
+ );
1677
+ --_filled-active-bg-color: light-dark(
1678
+ oklch(from var(--_accent) calc(l + 0.3) c h),
1679
+ oklch(from var(--_accent) calc(l - 0.15) c h)
1680
+ );
1681
+ --_outlined-active-bg-color: var(--_filled-active-bg-color);
1287
1682
 
1288
- /* 3. Named colors (no severity meaning) — use when you literally want a green/red/etc. dot */
1289
- --blue: oklch(from var(--color-9) l 0.2 210);
1290
- --green: oklch(from var(--color-9) l 0.2 145);
1291
- --orange: oklch(from var(--color-7) l 0.2 75);
1292
- --red: oklch(from var(--color-9) l 0.2 25);
1293
-
1294
- /* 4. Intent tokens
1295
- Severity (have scope classes below): --success, --info, --warning, --critical
1296
- Non-severity (value-only): --primary, --neutral */
1297
- --success: var(--green);
1298
- --info: var(--blue);
1299
- --warning: var(--orange);
1300
- --critical: var(--red);
1301
- --neutral: var(--gray-9);
1302
-
1303
- /* 5. Primary */
1304
- --primary: var(--color-8);
1305
- --primary-light: oklch(from var(--primary) calc(l * 1.25) c h);
1306
- --primary-dark: oklch(from var(--primary) calc(l * 0.75) c h);
1307
- --primary-contrast: var(--gray-1);
1308
-
1309
- /* 6. Text */
1310
- --text-primary: light-dark(var(--gray-15), var(--gray-1));
1311
- --text-primary-contrast: light-dark(var(--gray-2), var(--gray-15));
1312
- --text-muted: light-dark(var(--gray-13), var(--gray-4));
1313
- --text-muted-contrast: light-dark(var(--gray-4), var(--gray-13));
1314
-
1315
- /* 7. Surfaces */
1316
- --surface-default: light-dark(var(--gray-1), var(--gray-13));
1317
- --surface-filled: light-dark(var(--gray-4), var(--gray-15));
1318
- --surface-tonal: light-dark(var(--gray-3), var(--gray-12));
1319
- --surface-elevated: light-dark(var(--gray-1), var(--gray-12));
1320
-
1321
- /* 8. Borders */
1322
- --border-color: light-dark(var(--gray-4), var(--gray-12));
1323
- --border-radius: var(--size-2);
1324
- --border-width: 1px;
1325
-
1326
- /* 9. Focus ring — components consume these and may override locally
1327
- (e.g. .ui-button.ui-filled { --focus-ring-offset: 3px; }, .ui-checkbox { --focus-ring-offset: 0; }) */
1328
- --focus-ring-color: var(--primary);
1329
- --focus-ring-width: 2px;
1330
- --focus-ring-offset: 2px;
1331
- --focus-ring-style: solid;
1332
-
1333
- /* 10. Typography */
1334
- --font-size-h1: var(--font-size-fluid-3);
1335
- --font-size-h2: var(--font-size-fluid-2);
1336
- --font-size-h3: var(--font-size-fluid-1);
1337
- --font-size-h4: var(--font-size-3);
1338
- --font-size-h5: var(--font-size-2);
1339
- --font-size-h6: var(--font-size-fluid-0);
1340
-
1341
- /* Sneaking in an extra font size I want but Open Props doesn't provide. You can do whatever you want with your own theme. It's just CSS. */
1342
- --font-size-05: 0.875rem;
1343
-
1344
- /* 11. Control sizes — shared scale for fields and buttons so they line up
1345
- visually. --field-size-* and --button-size-* alias from --control-size-*. */
1346
- --control-size-x-small: 28px;
1347
- --control-size-small: 32px;
1348
- --control-size: 40px;
1349
- --control-size-large: 46px;
1350
-
1351
- --field-size-x-small: var(--control-size-x-small);
1352
- --field-size-small: var(--control-size-small);
1353
- --field-size: var(--control-size);
1354
- --field-size-large: var(--control-size-large);
1355
-
1356
- --button-size-x-small: var(--control-size-x-small);
1357
- --button-size-small: var(--control-size-small);
1358
- --button-size: var(--control-size);
1359
- --button-size-large: var(--control-size-large);
1360
-
1361
- /* 12. Field / input */
1362
- --field-border-color: var(--border-color);
1363
- --field-border-radius: var(--size-2);
1364
- --field-border-width: 1px;
1365
-
1366
- /* 13. Button */
1367
- --button-border-radius: var(--size-2);
1368
- }
1369
-
1370
- /* 14. Severity scope classes — re-source the palette inside these contexts.
1371
- Authoring `<div class="ui-warning">` paints the entire subtree warning-orange.
1372
- Non-severity tokens (--primary, --neutral) deliberately have no scope class. */
1373
- :where(.ui-critical, [data-invalid], del) {
1374
- --palette-source: oklch(0.58 0.21 var(--hue-red));
1375
- --palette-hue-rotate-by: 1;
1376
- }
1377
-
1378
- :where(.ui-info, abbr, dfn) {
1379
- --palette-source: oklch(0.58 0.21 var(--hue-blue));
1380
- --palette-hue-rotate-by: 1;
1381
- }
1382
-
1383
- :where(.ui-success, ins) {
1384
- --palette-source: oklch(0.58 0.21 var(--hue-green));
1385
- --palette-hue-rotate-by: 1;
1386
- }
1387
-
1388
- :where(.ui-warning) {
1389
- --palette-source: oklch(0.58 0.21 var(--hue-orange));
1390
- --palette-hue-rotate-by: 1;
1391
- }
1392
- }
1393
-
1394
- /* Components */
1395
-
1396
- /*
1397
- * Components are divided into two categories - if they are stand-alone (root) or if they are built on top of others (extended).
1398
- */
1399
-
1400
- /*** Root components (no dependencies) */
1401
-
1402
- @layer components.root {
1403
- :where(.ui-button) {
1404
- --_color: light-dark(var(--color-16), var(--color-1));
1405
- --_color-contrast: light-dark(var(--color-1), var(--color-16));
1406
- --_color-tonal: var(--surface-tonal);
1407
-
1408
- --_accent: var(--_color);
1409
- --_accent-contrast: var(--_color-contrast);
1410
- --_accent-tonal: var(--_color-tonal);
1411
- --_accent-tonal-contrast: var(--_color);
1412
-
1413
- --_default-hover-bg-color: light-dark(oklch(from var(--_accent) l 0.01 h / 10%),
1414
- oklch(from var(--_accent) l 0.01 h / 20%));
1415
- --_default-active-bg-color: light-dark(oklch(from var(--_accent) l 0.06 h / 20%),
1416
- oklch(from var(--_accent) l 0.06 h / 30%));
1417
-
1418
- --_filled-hover-bg-color: light-dark(oklch(from var(--_accent) calc(l + 0.2) c h),
1419
- oklch(from var(--_accent) calc(l - 0.1) c h));
1420
- --_filled-active-bg-color: light-dark(oklch(from var(--_accent) calc(l + 0.3) c h),
1421
- oklch(from var(--_accent) calc(l - 0.15) c h));
1422
- --_outlined-active-bg-color: var(--_filled-active-bg-color);
1423
-
1424
- --_bg-color: transparent;
1425
- --_border-color: transparent;
1426
- --_border-width: var(--border-size-1);
1427
- --_font-size: var(--font-size-1);
1428
- --_min-height: var(--button-size);
1429
- --_border-radius: var(--button-border-radius, var(--radius-2));
1430
- --_text-color: var(--_accent);
1683
+ --_bg-color: transparent;
1684
+ --_border-color: transparent;
1685
+ --_border-width: var(--border-size-1);
1686
+ --_font-size: var(--font-size-1);
1687
+ --_min-height: var(--button-size);
1688
+ --_border-radius: var(--button-border-radius, var(--radius-2));
1689
+ --_text-color: var(--_accent);
1431
1690
 
1432
1691
  -webkit-tap-highlight-color: transparent;
1433
1692
  -webkit-touch-callout: none;
@@ -1446,8 +1705,11 @@
1446
1705
  padding-inline: 1.5ex;
1447
1706
  text-align: center;
1448
1707
  text-decoration: none;
1449
- transition: background-color .1s ease, color .1s ease,
1450
- border-color .1s ease, box-shadow .1s ease;
1708
+ transition:
1709
+ background-color 0.1s ease,
1710
+ color 0.1s ease,
1711
+ border-color 0.1s ease,
1712
+ box-shadow 0.1s ease;
1451
1713
  user-select: none;
1452
1714
 
1453
1715
  /* Colors — shared interaction model for critical and primary.
@@ -1480,9 +1742,11 @@
1480
1742
 
1481
1743
  /* Disabled */
1482
1744
  &:where([disabled]) {
1483
- --_text-color: color-mix(in oklch,
1484
- var(--text-muted) 50%,
1485
- var(--surface-default));
1745
+ --_text-color: color-mix(
1746
+ in oklch,
1747
+ var(--text-muted) 50%,
1748
+ var(--surface-default)
1749
+ );
1486
1750
 
1487
1751
  cursor: not-allowed;
1488
1752
  opacity: 0.64;
@@ -1500,7 +1764,6 @@
1500
1764
  }
1501
1765
  }
1502
1766
 
1503
-
1504
1767
  /* Icons / Keyboard */
1505
1768
  &:where(:has(svg), &.ui-icon-only) {
1506
1769
  gap: 1ex;
@@ -1527,14 +1790,14 @@
1527
1790
  --_min-height: var(--button-size-x-small);
1528
1791
  --_font-size: var(--font-size-0);
1529
1792
  padding-block: 0;
1530
- padding-inline: .5ex;
1793
+ padding-inline: 0.5ex;
1531
1794
  }
1532
1795
 
1533
1796
  &.ui-small {
1534
1797
  --_min-height: var(--button-size-small);
1535
1798
  --_font-size: var(--font-size-05);
1536
1799
  padding-block: 0;
1537
- padding-inline: .75ex;
1800
+ padding-inline: 0.75ex;
1538
1801
  }
1539
1802
 
1540
1803
  &.ui-large {
@@ -1616,113 +1879,116 @@
1616
1879
  }
1617
1880
 
1618
1881
  @layer components.root {
1619
- :where(.ui-callout) {
1620
- --_bg-color: var(--surface-tonal);
1621
- --_border-color: var(--surface-tonal);
1622
- --_color: var(--text-primary);
1623
- --_icon-color: currentColor;
1624
- --_link-hover-color: var(--primary);
1625
- --_padding: var(--size-3);
1626
- --_border-radius: var(--border-radius);
1627
- --_gap: var(--size-3);
1628
- --_content-gap: var(--size-2);
1629
- --_font-size: var(--font-size-05);
1630
- --_title-font-size: var(--font-size-1);
1631
- --_icon-size: var(--size-4);
1632
- --_surface-bg: var(--surface-default);
1633
-
1634
- --_outlined-bg-color: var(--surface-default);
1635
- --_outlined-border-color: var(--border-color);
1636
- --_outlined-color: var(--text-primary);
1637
- --_outlined-icon-color: currentColor;
1638
-
1639
- background-color: var(--_bg-color, var(--_surface-bg));
1640
- border: 1px solid var(--_border-color, var(--border-color));
1641
- border-radius: var(--_border-radius);
1642
- color: var(--_color);
1643
- isolation: isolate;
1644
- padding: var(--_padding);
1645
- position: relative;
1646
-
1647
- &.ui-critical,
1648
- &.ui-info,
1649
- &.ui-neutral,
1650
- &.ui-success,
1651
- &.ui-warning {
1652
- --_bg-color: light-dark(oklch(from var(--color-2) l c h / 20%), oklch(from var(--color-6) l c h / 5%));
1653
- --_border-color: light-dark(var(--color-5), var(--color-11));
1654
- --_color: light-dark(var(--color-16), var(--color-1));
1655
- --_icon-color: var(--color-9);
1656
-
1657
- --_outlined-bg-color: var(--surface-default);
1658
- --_outlined-border-color: var(--color-9);
1659
- --_outlined-color: light-dark(var(--color-15), var(--color-1));
1660
- --_outlined-icon-color: var(--color-9);
1661
- }
1662
-
1663
- &.ui-outlined {
1664
- --_bg-color: var(--_outlined-bg-color);
1665
- --_border-color: var(--_outlined-border-color);
1666
- --_color: var(--_outlined-color);
1667
- --_icon-color: var(--_outlined-icon-color);
1668
- }
1669
-
1670
- &::before {
1671
- background-color: var(--_bg-color);
1672
- border-radius: inherit;
1673
- content: "";
1674
- inset: 0;
1675
- pointer-events: none;
1676
- position: absolute;
1677
- z-index: -1;
1678
- }
1679
-
1680
- &>.ui-content {
1681
- display: grid;
1682
- font-size: var(--_font-size);
1683
- gap: var(--_content-gap);
1684
-
1685
- h1,
1686
- h2,
1687
- h3,
1688
- h4,
1689
- h5,
1690
- h6 {
1691
- color: inherit;
1692
- font-size: var(--_title-font-size);
1693
- font-weight: 600;
1694
-
1695
- * {
1696
- font-size: inherit;
1697
- }
1698
- }
1699
- }
1700
-
1701
- /* Links
1882
+ :where(.ui-callout) {
1883
+ --_bg-color: var(--surface-tonal);
1884
+ --_border-color: var(--surface-tonal);
1885
+ --_color: var(--text-primary);
1886
+ --_icon-color: currentColor;
1887
+ --_link-hover-color: var(--primary);
1888
+ --_padding: var(--size-3);
1889
+ --_border-radius: var(--border-radius);
1890
+ --_gap: var(--size-3);
1891
+ --_content-gap: var(--size-2);
1892
+ --_font-size: var(--font-size-05);
1893
+ --_title-font-size: var(--font-size-1);
1894
+ --_icon-size: var(--size-4);
1895
+ --_surface-bg: var(--surface-default);
1896
+
1897
+ --_outlined-bg-color: var(--surface-default);
1898
+ --_outlined-border-color: var(--border-color);
1899
+ --_outlined-color: var(--text-primary);
1900
+ --_outlined-icon-color: currentColor;
1901
+
1902
+ background-color: var(--_bg-color, var(--_surface-bg));
1903
+ border: 1px solid var(--_border-color, var(--border-color));
1904
+ border-radius: var(--_border-radius);
1905
+ color: var(--_color);
1906
+ isolation: isolate;
1907
+ padding: var(--_padding);
1908
+ position: relative;
1909
+
1910
+ &.ui-critical,
1911
+ &.ui-info,
1912
+ &.ui-neutral,
1913
+ &.ui-success,
1914
+ &.ui-warning {
1915
+ --_bg-color: light-dark(
1916
+ oklch(from var(--color-2) l c h / 20%),
1917
+ oklch(from var(--color-6) l c h / 5%)
1918
+ );
1919
+ --_border-color: light-dark(var(--color-5), var(--color-11));
1920
+ --_color: light-dark(var(--color-16), var(--color-1));
1921
+ --_icon-color: var(--color-9);
1922
+
1923
+ --_outlined-bg-color: var(--surface-default);
1924
+ --_outlined-border-color: var(--color-9);
1925
+ --_outlined-color: light-dark(var(--color-15), var(--color-1));
1926
+ --_outlined-icon-color: var(--color-9);
1927
+ }
1928
+
1929
+ &.ui-outlined {
1930
+ --_bg-color: var(--_outlined-bg-color);
1931
+ --_border-color: var(--_outlined-border-color);
1932
+ --_color: var(--_outlined-color);
1933
+ --_icon-color: var(--_outlined-icon-color);
1934
+ }
1935
+
1936
+ &::before {
1937
+ background-color: var(--_bg-color);
1938
+ border-radius: inherit;
1939
+ content: "";
1940
+ inset: 0;
1941
+ pointer-events: none;
1942
+ position: absolute;
1943
+ z-index: -1;
1944
+ }
1945
+
1946
+ & > .ui-content {
1947
+ display: grid;
1948
+ font-size: var(--_font-size);
1949
+ gap: var(--_content-gap);
1950
+
1951
+ h1,
1952
+ h2,
1953
+ h3,
1954
+ h4,
1955
+ h5,
1956
+ h6 {
1957
+ color: inherit;
1958
+ font-size: var(--_title-font-size);
1959
+ font-weight: 600;
1960
+
1961
+ * {
1962
+ font-size: inherit;
1963
+ }
1964
+ }
1965
+ }
1966
+
1967
+ /* Links
1702
1968
  * Can't make sure contrast will be acceptable (yet) so we use the current text color instead.
1703
1969
  */
1704
- &:not(.ui-outlined) {
1705
- a[href] {
1706
- color: inherit;
1707
-
1708
- &:hover {
1709
- color: var(--_link-hover-color);
1710
- }
1711
- }
1712
- }
1713
-
1714
- /* Icon */
1715
- &:has(svg) {
1716
- display: grid;
1717
- gap: var(--_gap);
1718
- grid-template-columns: var(--_icon-size) 1fr;
1719
-
1720
- svg {
1721
- margin-block-start: 0.15rem;
1722
- stroke: var(--_icon-color);
1723
- }
1724
- }
1725
- }
1970
+ &:not(.ui-outlined) {
1971
+ a[href] {
1972
+ color: inherit;
1973
+
1974
+ &:hover {
1975
+ color: var(--_link-hover-color);
1976
+ }
1977
+ }
1978
+ }
1979
+
1980
+ /* Icon */
1981
+ &:has(svg) {
1982
+ display: grid;
1983
+ gap: var(--_gap);
1984
+ grid-template-columns: var(--_icon-size) 1fr;
1985
+
1986
+ svg {
1987
+ margin-block-start: 0.15rem;
1988
+ stroke: var(--_icon-color);
1989
+ }
1990
+ }
1991
+ }
1726
1992
  }
1727
1993
 
1728
1994
  @layer components.root {
@@ -1735,14 +2001,22 @@
1735
2001
  --_accent-contrast: var(--_color-contrast);
1736
2002
  --_accent-tonal: var(--_color-tonal);
1737
2003
  --_accent-tonal-contrast: var(--_color);
1738
- --_default-hover-bg-color: light-dark(oklch(from var(--_accent) l 0.01 h / 10%),
1739
- oklch(from var(--_accent) l 0.01 h / 20%));
1740
- --_default-active-bg-color: light-dark(oklch(from var(--_accent) l 0.06 h / 20%),
1741
- oklch(from var(--_accent) l 0.06 h / 30%));
1742
- --_filled-hover-bg-color: light-dark(oklch(from var(--_accent) calc(l + 0.2) c h),
1743
- oklch(from var(--_accent) calc(l - 0.1) c h));
1744
- --_filled-active-bg-color: light-dark(oklch(from var(--_accent) calc(l + 0.3) c h),
1745
- oklch(from var(--_accent) calc(l - 0.15) c h));
2004
+ --_default-hover-bg-color: light-dark(
2005
+ oklch(from var(--_accent) l 0.01 h / 10%),
2006
+ oklch(from var(--_accent) l 0.01 h / 20%)
2007
+ );
2008
+ --_default-active-bg-color: light-dark(
2009
+ oklch(from var(--_accent) l 0.06 h / 20%),
2010
+ oklch(from var(--_accent) l 0.06 h / 30%)
2011
+ );
2012
+ --_filled-hover-bg-color: light-dark(
2013
+ oklch(from var(--_accent) calc(l + 0.2) c h),
2014
+ oklch(from var(--_accent) calc(l - 0.1) c h)
2015
+ );
2016
+ --_filled-active-bg-color: light-dark(
2017
+ oklch(from var(--_accent) calc(l + 0.3) c h),
2018
+ oklch(from var(--_accent) calc(l - 0.15) c h)
2019
+ );
1746
2020
  --_outlined-active-bg-color: var(--_filled-active-bg-color);
1747
2021
 
1748
2022
  --_bg-color: transparent;
@@ -1762,8 +2036,11 @@
1762
2036
  justify-content: center;
1763
2037
  padding: 0;
1764
2038
  transform-style: preserve-3d;
1765
- transition: background-color .1s ease, color .1s ease,
1766
- border-color .1s ease, box-shadow .1s ease;
2039
+ transition:
2040
+ background-color 0.1s ease,
2041
+ color 0.1s ease,
2042
+ border-color 0.1s ease,
2043
+ box-shadow 0.1s ease;
1767
2044
 
1768
2045
  &:where([disabled]) {
1769
2046
  --_text-color: light-dark(rgb(0, 0, 0/0.3), rgb(255, 255, 255/0.26));
@@ -1785,7 +2062,9 @@
1785
2062
  background-color: transparent;
1786
2063
 
1787
2064
  @media (prefers-reduced-motion: no-preference) {
1788
- transition: transform 0.2s ease, background-color .1s ease;
2065
+ transition:
2066
+ transform 0.2s ease,
2067
+ background-color 0.1s ease;
1789
2068
  }
1790
2069
  }
1791
2070
 
@@ -1821,14 +2100,20 @@
1821
2100
  &:where(:not([disabled])) {
1822
2101
  &:where(:not(:active):hover) {
1823
2102
  &::before {
1824
- background-color: var(--_interaction-hover-color, var(--_default-hover-bg-color));
2103
+ background-color: var(
2104
+ --_interaction-hover-color,
2105
+ var(--_default-hover-bg-color)
2106
+ );
1825
2107
  }
1826
2108
  }
1827
2109
 
1828
2110
  &:where(:hover:active),
1829
2111
  &[aria-current="page"] {
1830
2112
  &::before {
1831
- background-color: var(--_interaction-active-color, var(--_default-active-bg-color));
2113
+ background-color: var(
2114
+ --_interaction-active-color,
2115
+ var(--_default-active-bg-color)
2116
+ );
1832
2117
  }
1833
2118
  }
1834
2119
  }
@@ -1876,7 +2161,7 @@
1876
2161
  gap: 0 var(--size-1);
1877
2162
  position: relative;
1878
2163
 
1879
- &>.ui-tab-input[type="radio"] {
2164
+ & > .ui-tab-input[type="radio"] {
1880
2165
  /* utils > .ui-sr-only */
1881
2166
  /* TODO: use mixin for this when available */
1882
2167
  block-size: 1px;
@@ -1887,36 +2172,35 @@
1887
2172
  white-space: nowrap;
1888
2173
 
1889
2174
  &:checked {
1890
-
1891
2175
  /* Checked Tab */
1892
- &+[role="tab"],
1893
- &+.ui-tab-label {
2176
+ & + [role="tab"],
2177
+ & + .ui-tab-label {
1894
2178
  border-block-end-color: var(--_accent-color);
1895
2179
  color: var(--_accent-color);
1896
2180
 
1897
2181
  /* Checked Panel */
1898
- &+[role="tabpanel"],
1899
- &+.ui-tab-panel {
2182
+ & + [role="tabpanel"],
2183
+ & + .ui-tab-panel {
1900
2184
  display: block;
1901
2185
  }
1902
2186
  }
1903
2187
  }
1904
2188
 
1905
2189
  &:focus-visible {
1906
-
1907
- &+[role="tab"],
1908
- &+.ui-tab-label {
2190
+ & + [role="tab"],
2191
+ & + .ui-tab-label {
1909
2192
  --focus-ring-color: var(--text-muted);
1910
2193
  --focus-ring-offset: calc(-1 * var(--size-2));
1911
- outline: var(--focus-ring-width) var(--focus-ring-style) var(--focus-ring-color);
2194
+ outline: var(--focus-ring-width) var(--focus-ring-style)
2195
+ var(--focus-ring-color);
1912
2196
  outline-offset: var(--focus-ring-offset);
1913
2197
  }
1914
2198
  }
1915
2199
  }
1916
2200
 
1917
2201
  /* Tab */
1918
- &>[role="tab"],
1919
- &>.ui-tab-label {
2202
+ & > [role="tab"],
2203
+ & > .ui-tab-label {
1920
2204
  align-items: center;
1921
2205
  background-color: transparent;
1922
2206
  border-bottom: 2px solid transparent;
@@ -1934,14 +2218,16 @@
1934
2218
  user-select: none;
1935
2219
 
1936
2220
  &:hover {
1937
- background-color: light-dark(oklch(from var(--_accent-color) calc(l * 0.75) none h / 5%),
1938
- oklch(from var(--_accent-color) calc(l * 1.25) none h / 5%));
2221
+ background-color: light-dark(
2222
+ oklch(from var(--_accent-color) calc(l * 0.75) none h / 5%),
2223
+ oklch(from var(--_accent-color) calc(l * 1.25) none h / 5%)
2224
+ );
1939
2225
  }
1940
2226
  }
1941
2227
 
1942
2228
  /* Tab Panel */
1943
- &>[role="tabpanel"],
1944
- &>.ui-tab-panel {
2229
+ & > [role="tabpanel"],
2230
+ & > .ui-tab-panel {
1945
2231
  display: none;
1946
2232
  inline-size: 100%;
1947
2233
  order: 2;
@@ -2011,116 +2297,120 @@
2011
2297
  */
2012
2298
 
2013
2299
  @layer components.root {
2014
- :where(.ui-toggle-button) {
2015
- --_button-bg-color: transparent;
2016
- --_size: var(--field-size);
2017
- --_svg-size: var(--size-4);
2018
-
2019
- align-items: center;
2020
- background-color: var(--_button-bg-color);
2021
- block-size: var(--_size);
2022
- border: 1px solid var(--border-color);
2023
- border-radius: var(--button-border-radius);
2024
- color: var(--text-primary);
2025
- cursor: pointer;
2026
- display: inline-flex;
2027
- flex: auto;
2028
- gap: var(--size-2);
2029
- inline-size: fit-content;
2030
- justify-content: center;
2031
- min-inline-size: var(--_size);
2032
- outline-offset: calc(-1 * var(--size-2));
2033
- padding: 0 var(--size-2);
2034
- position: relative;
2035
- user-select: none;
2036
-
2037
- input[type="checkbox"],
2038
- input[type="radio"] {
2039
- /* utils.css > .ui-sr-only */
2040
- block-size: 1px;
2041
- clip-path: inset(50%);
2042
- inline-size: 1px;
2043
- overflow: hidden;
2044
- position: absolute;
2045
- white-space: nowrap;
2046
- }
2047
-
2048
- /* Element states */
2049
- @media (pointer: fine) {
2050
- &:hover:not(.ui-disabled) {
2051
- --_button-bg-color: light-dark(oklch(0% 0 0 / 0.04), oklch(100% 0 0 / 0.08));
2052
- }
2053
- }
2054
-
2055
- &:has(input:focus-visible) {
2056
- --focus-ring-color: var(--text-muted);
2057
- --focus-ring-offset: -6px;
2058
- outline: var(--focus-ring-width) var(--focus-ring-style) var(--focus-ring-color);
2059
- outline-offset: var(--focus-ring-offset);
2060
- }
2061
-
2062
- /* Disabled */
2063
- &.ui-disabled {
2064
- border-color: color-mix(in oklch, var(--border-color) 50%, transparent);
2065
- color: color-mix(in oklch, var(--text-primary) 30%, transparent);
2066
- cursor: not-allowed;
2067
- }
2068
-
2069
- /* svgs */
2070
- svg {
2071
- block-size: var(--_svg-size);
2072
- flex-shrink: 0;
2073
- inline-size: var(--_svg-size);
2074
- }
2075
-
2076
- /* Selected */
2077
- &:has(:where(input[type="checkbox"], input[type="radio"]):checked) {
2078
- --_button-bg-color: oklch(from var(--primary) l c h / 25%);
2079
-
2080
- @media (pointer: fine) {
2081
- &:hover {
2082
- --_button-bg-color: oklch(from var(--primary) l c h / 35%);
2083
- }
2084
- }
2085
- }
2086
-
2087
- /* Sizes */
2088
- &.ui-small {
2089
- --_size: var(--field-size-small);
2090
- }
2091
-
2092
- &.ui-x-small {
2093
- --_size: var(--field-size-x-small);
2094
- }
2095
- }
2300
+ :where(.ui-toggle-button) {
2301
+ --_button-bg-color: transparent;
2302
+ --_size: var(--field-size);
2303
+ --_svg-size: var(--size-4);
2304
+
2305
+ align-items: center;
2306
+ background-color: var(--_button-bg-color);
2307
+ block-size: var(--_size);
2308
+ border: 1px solid var(--border-color);
2309
+ border-radius: var(--button-border-radius);
2310
+ color: var(--text-primary);
2311
+ cursor: pointer;
2312
+ display: inline-flex;
2313
+ flex: auto;
2314
+ gap: var(--size-2);
2315
+ inline-size: fit-content;
2316
+ justify-content: center;
2317
+ min-inline-size: var(--_size);
2318
+ outline-offset: calc(-1 * var(--size-2));
2319
+ padding: 0 var(--size-2);
2320
+ position: relative;
2321
+ user-select: none;
2322
+
2323
+ input[type="checkbox"],
2324
+ input[type="radio"] {
2325
+ /* utils.css > .ui-sr-only */
2326
+ block-size: 1px;
2327
+ clip-path: inset(50%);
2328
+ inline-size: 1px;
2329
+ overflow: hidden;
2330
+ position: absolute;
2331
+ white-space: nowrap;
2332
+ }
2333
+
2334
+ /* Element states */
2335
+ @media (pointer: fine) {
2336
+ &:hover:not(.ui-disabled) {
2337
+ --_button-bg-color: light-dark(
2338
+ oklch(0% 0 0 / 0.04),
2339
+ oklch(100% 0 0 / 0.08)
2340
+ );
2341
+ }
2342
+ }
2343
+
2344
+ &:has(input:focus-visible) {
2345
+ --focus-ring-color: var(--text-muted);
2346
+ --focus-ring-offset: -6px;
2347
+ outline: var(--focus-ring-width) var(--focus-ring-style)
2348
+ var(--focus-ring-color);
2349
+ outline-offset: var(--focus-ring-offset);
2350
+ }
2351
+
2352
+ /* Disabled */
2353
+ &.ui-disabled {
2354
+ border-color: color-mix(in oklch, var(--border-color) 50%, transparent);
2355
+ color: color-mix(in oklch, var(--text-primary) 30%, transparent);
2356
+ cursor: not-allowed;
2357
+ }
2358
+
2359
+ /* svgs */
2360
+ svg {
2361
+ block-size: var(--_svg-size);
2362
+ flex-shrink: 0;
2363
+ inline-size: var(--_svg-size);
2364
+ }
2365
+
2366
+ /* Selected */
2367
+ &:has(:where(input[type="checkbox"], input[type="radio"]):checked) {
2368
+ --_button-bg-color: oklch(from var(--primary) l c h / 25%);
2369
+
2370
+ @media (pointer: fine) {
2371
+ &:hover {
2372
+ --_button-bg-color: oklch(from var(--primary) l c h / 35%);
2373
+ }
2374
+ }
2375
+ }
2376
+
2377
+ /* Sizes */
2378
+ &.ui-small {
2379
+ --_size: var(--field-size-small);
2380
+ }
2381
+
2382
+ &.ui-x-small {
2383
+ --_size: var(--field-size-x-small);
2384
+ }
2385
+ }
2096
2386
  }
2097
2387
 
2098
2388
  @layer components.root {
2099
- :where(.ui-anchor) {
2100
- anchor-name: --anchor;
2101
- anchor-scope: --anchor;
2102
- display: inline-block;
2103
- inline-size: fit-content;
2104
-
2105
- /* Always-visible */
2106
- &>.ui-anchor-floating:not([popover]) {
2107
- block-size: max-content;
2108
- inline-size: max-content;
2109
- position: absolute;
2110
- position-anchor: --anchor;
2111
- position-area: var(--anchor-position-area, start end);
2112
- translate: var(--_anchor-tx, 0) var(--_anchor-ty, 0);
2113
- }
2114
-
2115
- /* Hover-triggered */
2116
- &>.ui-anchor-floating[popover] {
2117
- inset: unset;
2118
- margin: 0;
2119
- position: absolute;
2120
- position-area: var(--anchor-position-area, start end);
2121
- translate: var(--_anchor-tx, 0) var(--_anchor-ty, 0);
2122
- }
2123
- }
2389
+ :where(.ui-anchor) {
2390
+ anchor-name: --anchor;
2391
+ anchor-scope: --anchor;
2392
+ display: inline-block;
2393
+ inline-size: fit-content;
2394
+
2395
+ /* Always-visible */
2396
+ & > .ui-anchor-floating:not([popover]) {
2397
+ block-size: max-content;
2398
+ inline-size: max-content;
2399
+ position: absolute;
2400
+ position-anchor: --anchor;
2401
+ position-area: var(--anchor-position-area, start end);
2402
+ translate: var(--_anchor-tx, 0) var(--_anchor-ty, 0);
2403
+ }
2404
+
2405
+ /* Hover-triggered */
2406
+ & > .ui-anchor-floating[popover] {
2407
+ inset: unset;
2408
+ margin: 0;
2409
+ position: absolute;
2410
+ position-area: var(--anchor-position-area, start end);
2411
+ translate: var(--_anchor-tx, 0) var(--_anchor-ty, 0);
2412
+ }
2413
+ }
2124
2414
  }
2125
2415
 
2126
2416
  @layer components.root {
@@ -2245,7 +2535,7 @@
2245
2535
  --_card-border-width: 1px;
2246
2536
  }
2247
2537
 
2248
- &> :where(hgroup, .ui-content) {
2538
+ & > :where(hgroup, .ui-content) {
2249
2539
  padding-inline: var(--size-3);
2250
2540
 
2251
2541
  &:last-child {
@@ -2254,11 +2544,11 @@
2254
2544
  }
2255
2545
 
2256
2546
  /* Header */
2257
- &>hgroup {
2547
+ & > hgroup {
2258
2548
  padding-block: var(--size-3) 0;
2259
2549
 
2260
2550
  /* Top paragraph */
2261
- &>p:first-of-type:first-child {
2551
+ & > p:first-of-type:first-child {
2262
2552
  line-height: 1.3;
2263
2553
  }
2264
2554
 
@@ -2267,18 +2557,18 @@
2267
2557
  }
2268
2558
 
2269
2559
  /* Bottom paragraph */
2270
- &>p:last-of-type:last-child:not(:first-child) {
2560
+ & > p:last-of-type:last-child:not(:first-child) {
2271
2561
  font-size: var(--font-size-1);
2272
2562
  }
2273
2563
  }
2274
2564
 
2275
2565
  /* Content */
2276
- &>.ui-content:where(:only-child, :first-child) {
2566
+ & > .ui-content:where(:only-child, :first-child) {
2277
2567
  padding-block: var(--size-3) var(--size-4);
2278
2568
  }
2279
2569
 
2280
2570
  /* Actions */
2281
- &>.ui-actions {
2571
+ & > .ui-actions {
2282
2572
  display: flex;
2283
2573
  gap: var(--size-2);
2284
2574
  margin-block: var(--size-2) 0;
@@ -2302,8 +2592,6 @@
2302
2592
  }
2303
2593
  }
2304
2594
  }
2305
-
2306
-
2307
2595
  }
2308
2596
  }
2309
2597
 
@@ -2338,8 +2626,10 @@
2338
2626
 
2339
2627
  &:where(button, a):where(:not([disabled])) {
2340
2628
  &:where(:not(:active)):hover {
2341
- --_bg-color: light-dark(oklch(from var(--surface-tonal) calc(l * 0.98) c h),
2342
- oklch(from var(--surface-tonal) calc(l * 1.1) c h));
2629
+ --_bg-color: light-dark(
2630
+ oklch(from var(--surface-tonal) calc(l * 0.98) c h),
2631
+ oklch(from var(--surface-tonal) calc(l * 1.1) c h)
2632
+ );
2343
2633
  }
2344
2634
  }
2345
2635
 
@@ -2373,7 +2663,8 @@
2373
2663
 
2374
2664
  &:where(:not([disabled])) {
2375
2665
  &:where(:not(:active):hover) {
2376
- --ripple: radial-gradient(circle, transparent 1%, var(--_bg-color) 1%) center/15000%;
2666
+ --ripple: radial-gradient(circle, transparent 1%, var(--_bg-color) 1%)
2667
+ center/15000%;
2377
2668
 
2378
2669
  transition: background var(--button-ripple-duration);
2379
2670
  }
@@ -2387,9 +2678,11 @@
2387
2678
  /* Disabled */
2388
2679
  &:where([disabled]) {
2389
2680
  opacity: 0.64;
2390
- --_color: color-mix(in oklch,
2391
- var(--text-muted) 50%,
2392
- var(--surface-default));
2681
+ --_color: color-mix(
2682
+ in oklch,
2683
+ var(--text-muted) 50%,
2684
+ var(--surface-default)
2685
+ );
2393
2686
  cursor: not-allowed;
2394
2687
  }
2395
2688
  }
@@ -2467,7 +2760,8 @@
2467
2760
  &::after {
2468
2761
  background-color: transparent;
2469
2762
  block-size: 2px;
2470
- border-block-end: var(--_border-width) var(--_border-style) var(--border-color);
2763
+ border-block-end: var(--_border-width) var(--_border-style)
2764
+ var(--border-color);
2471
2765
  content: "";
2472
2766
  order: 1;
2473
2767
  }
@@ -2553,8 +2847,7 @@
2553
2847
  }
2554
2848
 
2555
2849
  /* Remove bottom border only on the last row of the table */
2556
- &>*:last-child tr:last-child {
2557
-
2850
+ & > *:last-child tr:last-child {
2558
2851
  th,
2559
2852
  td {
2560
2853
  border-block-end: none;
@@ -2574,7 +2867,7 @@
2574
2867
  }
2575
2868
 
2576
2869
  /* Round corner cells */
2577
- &>thead:first-of-type tr:first-child {
2870
+ & > thead:first-of-type tr:first-child {
2578
2871
  th:first-child {
2579
2872
  border-start-start-radius: var(--_table-border-radius);
2580
2873
  }
@@ -2585,7 +2878,7 @@
2585
2878
  }
2586
2879
 
2587
2880
  /* Logic for tables without thead */
2588
- &>tbody:first-of-type:not(thead ~ tbody) tr:first-child {
2881
+ & > tbody:first-of-type:not(thead ~ tbody) tr:first-child {
2589
2882
  td:first-child {
2590
2883
  border-start-start-radius: var(--_table-border-radius);
2591
2884
  }
@@ -2596,7 +2889,7 @@
2596
2889
  }
2597
2890
 
2598
2891
  /* Logic for bottom corners (whether in tbody or tfoot) */
2599
- &>*:last-child tr:last-child {
2892
+ & > *:last-child tr:last-child {
2600
2893
  :where(th, td):first-child {
2601
2894
  border-end-start-radius: var(--_table-border-radius);
2602
2895
  }
@@ -2646,7 +2939,6 @@
2646
2939
  }
2647
2940
 
2648
2941
  @container (width < 60ch) {
2649
-
2650
2942
  th,
2651
2943
  td {
2652
2944
  padding: var(--size-1) 0.875rem;
@@ -2655,7 +2947,6 @@
2655
2947
 
2656
2948
  /* Spacious */
2657
2949
  &.ui-spacious {
2658
-
2659
2950
  th,
2660
2951
  td {
2661
2952
  padding: var(--size-3);
@@ -2667,7 +2958,6 @@
2667
2958
  }
2668
2959
 
2669
2960
  @container (width < 60ch) {
2670
-
2671
2961
  th,
2672
2962
  td {
2673
2963
  padding: var(--size-3);
@@ -2677,7 +2967,6 @@
2677
2967
 
2678
2968
  /* Dense */
2679
2969
  &.ui-dense {
2680
-
2681
2970
  th,
2682
2971
  td {
2683
2972
  padding: var(--size-1);
@@ -2689,7 +2978,6 @@
2689
2978
  }
2690
2979
 
2691
2980
  @container (width < 60ch) {
2692
-
2693
2981
  th,
2694
2982
  td {
2695
2983
  padding: var(--size-1);
@@ -2726,7 +3014,7 @@
2726
3014
  --_bg-color: var(--surface-tonal);
2727
3015
  }
2728
3016
 
2729
- &>progress {
3017
+ & > progress {
2730
3018
  appearance: none;
2731
3019
  background: none;
2732
3020
  block-size: 100%;
@@ -2743,7 +3031,8 @@
2743
3031
  background-color: var(--_accent-color);
2744
3032
 
2745
3033
  @media (prefers-reduced-motion: no-preference) {
2746
- transition: inline-size 0.2s var(--ease-out-4, cubic-bezier(0, 0, 0.1, 1));
3034
+ transition: inline-size 0.2s
3035
+ var(--ease-out-4, cubic-bezier(0, 0, 0.1, 1));
2747
3036
  }
2748
3037
  }
2749
3038
 
@@ -2764,7 +3053,7 @@
2764
3053
  will-change: inset-inline-start, inset-inline-end;
2765
3054
  }
2766
3055
 
2767
- &>progress {
3056
+ & > progress {
2768
3057
  &::-webkit-progress-value {
2769
3058
  background-color: transparent;
2770
3059
  }
@@ -2803,13 +3092,14 @@
2803
3092
  }
2804
3093
 
2805
3094
  @layer components.root {
2806
-
2807
- [aria-busy="true"]:not(input,
3095
+ [aria-busy="true"]:not(
3096
+ input,
2808
3097
  select,
2809
3098
  textarea,
2810
3099
  html,
2811
3100
  progress,
2812
- [aria-describedby]) {
3101
+ [aria-describedby]
3102
+ ) {
2813
3103
  position: relative;
2814
3104
 
2815
3105
  &::before {
@@ -2826,397 +3116,401 @@
2826
3116
  vertical-align: -0.14em;
2827
3117
  }
2828
3118
 
2829
- &:not(button.ui-button):not(:empty) {
3119
+ &:not(button.ui-button):not(:empty) {
3120
+ &::before {
3121
+ margin-inline-end: 0.5em;
3122
+ }
3123
+ }
3124
+ }
3125
+
3126
+ @keyframes spin {
3127
+ to {
3128
+ transform: rotate(1turn);
3129
+ }
3130
+ }
3131
+ }
3132
+
3133
+ @layer components.root {
3134
+ label.ui-checkbox {
3135
+ --_input-size: var(--size-4);
3136
+
3137
+ align-items: center;
3138
+ color: var(--text-primary);
3139
+ cursor: pointer;
3140
+ display: inline-grid;
3141
+ gap: 0 var(--size-2);
3142
+ grid-auto-columns: auto;
3143
+ grid-auto-flow: column;
3144
+ inline-size: fit-content;
3145
+ line-height: 1.5;
3146
+ transform: translateZ(0);
3147
+ user-select: none;
3148
+
3149
+ /* Disabled */
3150
+ &:has([disabled]) {
3151
+ cursor: not-allowed;
3152
+ opacity: 0.64;
3153
+ user-select: none;
3154
+
3155
+ input {
3156
+ cursor: not-allowed;
3157
+ }
3158
+ }
3159
+
3160
+ /* Required dot */
3161
+ &:has(:invalid) {
3162
+ .ui-label:after {
3163
+ color: var(--red);
3164
+ content: "*";
3165
+ inset: 0 -0.25ex auto auto;
3166
+ position: absolute;
3167
+ }
3168
+ }
3169
+
3170
+ /* Label */
3171
+ .ui-label {
3172
+ color: var(--text-primary);
3173
+ font-size: var(--font-size-05);
3174
+ grid-column: 2;
3175
+ grid-row: 1;
3176
+ position: relative;
3177
+ padding-inline: 0 1ex;
3178
+ }
3179
+
3180
+ /* End text */
3181
+ :where(.ui-end-text) {
3182
+ color: var(--text-muted);
3183
+ font-size: var(--font-size-0);
3184
+ grid-column: 2;
3185
+ grid-row: 2;
3186
+ line-height: 1.5;
3187
+ z-index: 1;
3188
+ }
3189
+
3190
+ /* Spread layout */
3191
+ &.ui-spread {
3192
+ align-items: center;
3193
+ column-gap: var(--size-4);
3194
+ grid-auto-flow: unset;
3195
+ grid-template-columns: 1fr auto;
3196
+ inline-size: 100%;
3197
+
3198
+ .ui-label {
3199
+ font-weight: 600;
3200
+ grid-column: 1;
3201
+ grid-row: 1;
3202
+ inline-size: fit-content;
3203
+ }
3204
+
3205
+ input {
3206
+ grid-column: 2;
3207
+ grid-row: 1;
3208
+ }
3209
+
3210
+ :where(.ui-end-text) {
3211
+ grid-column: 1;
3212
+ grid-row: 2;
3213
+ }
3214
+ }
3215
+
3216
+ /* Stacked layout */
3217
+ &.ui-stack {
3218
+ justify-items: center;
3219
+ grid-auto-columns: unset;
3220
+
3221
+ .ui-label {
3222
+ grid-column: 1/-1;
3223
+ grid-row: 2;
3224
+ margin-block-start: var(--size-1);
3225
+ padding-inline: 1ex;
3226
+
3227
+ /* Required dot */
3228
+ &::after {
3229
+ inset: 0 -0.25ex auto auto;
3230
+ }
3231
+ }
3232
+
3233
+ .ui-end-text {
3234
+ grid-column: 1/-1;
3235
+ grid-row: 3;
3236
+ }
3237
+ }
3238
+
3239
+ /* Input */
3240
+ input[type="checkbox"] {
3241
+ --_input-size: var(--size-4);
3242
+
3243
+ appearance: none;
3244
+ aspect-ratio: 1;
3245
+ background-color: var(--surface-default);
3246
+ block-size: var(--_input-size);
3247
+ border-radius: var(--radius-1);
3248
+ border: 1px solid var(--border-color);
3249
+ box-sizing: border-box;
3250
+ cursor: pointer;
3251
+ display: grid;
3252
+ font-size: var(--_input-size);
3253
+ inline-size: var(--_input-size);
3254
+ margin: 0;
3255
+ padding: 0;
3256
+ place-items: center;
3257
+ position: relative;
3258
+
3259
+ &:checked,
3260
+ &:indeterminate {
3261
+ background-color: var(--primary);
3262
+ border-color: var(--primary);
3263
+ }
3264
+
3265
+ /* Checkmark */
3266
+ &::after {
3267
+ background-color: var(--primary-contrast);
3268
+ clip-path: polygon(
3269
+ 15% 52%,
3270
+ 40% 77%,
3271
+ 85% 32%,
3272
+ 75% 22%,
3273
+ 40% 57%,
3274
+ 25% 42%
3275
+ );
3276
+ content: "";
3277
+ inset: 0;
3278
+ opacity: 0;
3279
+ position: absolute;
3280
+ }
3281
+
3282
+ &:checked::after,
3283
+ &:indeterminate::after {
3284
+ opacity: 1;
3285
+ }
3286
+
3287
+ /* Indeterminate dash */
3288
+ &:indeterminate::after {
3289
+ clip-path: polygon(20% 45%, 80% 45%, 80% 55%, 20% 55%);
3290
+ }
3291
+
3292
+ &::before {
3293
+ --highlight-size: 175%;
3294
+ }
3295
+ }
3296
+
3297
+ /* Sizes */
3298
+ &.ui-small {
3299
+ input[type="checkbox"] {
3300
+ --_input-size: var(--size-3);
3301
+ }
3302
+ }
3303
+
3304
+ &.ui-large {
3305
+ input[type="checkbox"] {
3306
+ --_input-size: var(--size-5);
3307
+ }
3308
+ }
3309
+
3310
+ /* Validation */
3311
+ &[data-invalid],
3312
+ &:has(:user-invalid) {
3313
+ --primary: var(--critical);
3314
+
3315
+ :where(.ui-end-text) {
3316
+ color: var(--critical);
3317
+ }
3318
+ }
3319
+
3320
+ /* Touch devices */
3321
+ @media (pointer: coarse) {
3322
+ input {
3323
+ --_input-size: var(--size-4);
3324
+ }
3325
+ }
3326
+
3327
+ @media (forced-colors: active) {
3328
+ input {
3329
+ border: 1px solid CanvasText;
3330
+
3331
+ &:checked,
3332
+ &:indeterminate {
3333
+ background-color: SelectedItem;
3334
+ border-color: SelectedItem;
3335
+
3336
+ &::after {
3337
+ background-color: SelectedItemText;
3338
+ }
3339
+ }
3340
+ }
3341
+ }
3342
+ }
3343
+ }
3344
+
3345
+ @layer components.root {
3346
+ label.ui-radio {
3347
+ --_input-size: 1.125rem;
3348
+ --_indicator-size: 50%;
3349
+
3350
+ align-items: center;
3351
+ color: var(--text-primary);
3352
+ cursor: pointer;
3353
+ display: inline-grid;
3354
+ gap: 0 var(--size-2);
3355
+ grid-auto-columns: auto;
3356
+ grid-auto-flow: column;
3357
+ inline-size: fit-content;
3358
+ line-height: 1.5;
3359
+ transform: translateZ(0);
3360
+ user-select: none;
3361
+
3362
+ /* Disabled */
3363
+ &:has([disabled]) {
3364
+ cursor: not-allowed;
3365
+ opacity: 0.64;
3366
+ user-select: none;
3367
+
3368
+ input {
3369
+ cursor: not-allowed;
3370
+ }
3371
+ }
3372
+
3373
+ /* Required dot */
3374
+ &:has(:invalid) {
3375
+ .ui-label:after {
3376
+ color: var(--red);
3377
+ content: "*";
3378
+ inset: 0 -0.25ex auto auto;
3379
+ position: absolute;
3380
+ }
3381
+ }
3382
+
3383
+ /* Label */
3384
+ .ui-label {
3385
+ color: var(--text-primary);
3386
+ font-size: var(--font-size-05);
3387
+ grid-column: 2;
3388
+ grid-row: 1;
3389
+ padding-inline: 0 1ex;
3390
+ position: relative;
3391
+ }
3392
+
3393
+ /* End text */
3394
+ :where(.ui-end-text) {
3395
+ color: var(--text-muted);
3396
+ font-size: var(--font-size-0);
3397
+ grid-column: 2;
3398
+ grid-row: 2;
3399
+ line-height: 1.5;
3400
+ z-index: 1;
3401
+ }
3402
+
3403
+ /* Stacked layout */
3404
+ &.ui-stack {
3405
+ grid-auto-columns: unset;
3406
+ justify-items: center;
3407
+
3408
+ .ui-label {
3409
+ grid-column: 1/-1;
3410
+ grid-row: 2;
3411
+ margin-block-start: var(--size-1);
3412
+ padding-inline: 1ex;
3413
+
3414
+ /* Required dot */
3415
+ &::after {
3416
+ inset: 0 -0.25ex auto auto;
3417
+ }
3418
+ }
3419
+
3420
+ .ui-end-text {
3421
+ grid-column: 1/-1;
3422
+ grid-row: 3;
3423
+ }
3424
+ }
3425
+
3426
+ /* Input */
3427
+ input[type="radio"] {
3428
+ appearance: none;
3429
+ aspect-ratio: 1;
3430
+ background-color: var(--surface-default);
3431
+ block-size: var(--_input-size);
3432
+ border: 1px solid var(--field-border-color);
3433
+ border-radius: var(--radius-round);
3434
+ box-sizing: border-box;
3435
+ cursor: pointer;
3436
+ display: grid;
3437
+ inline-size: var(--_input-size);
3438
+ margin: 0;
3439
+ padding: 0;
3440
+ place-items: center;
3441
+ position: relative;
3442
+
3443
+ &:checked {
3444
+ background-color: var(--primary);
3445
+ border-color: var(--primary);
3446
+ }
3447
+
3448
+ /* Dot */
3449
+ &::after {
3450
+ background-color: var(--primary-contrast);
3451
+ block-size: var(--_indicator-size);
3452
+ border-radius: var(--radius-round);
3453
+ content: "";
3454
+ inline-size: var(--_indicator-size);
3455
+ margin: auto;
3456
+ opacity: 0;
3457
+ }
3458
+
3459
+ &:checked::after {
3460
+ opacity: 1;
3461
+ }
3462
+
2830
3463
  &::before {
2831
- margin-inline-end: 0.5em;
3464
+ --highlight-size: 175%;
2832
3465
  }
2833
3466
  }
2834
- }
2835
3467
 
2836
- @keyframes spin {
2837
- to {
2838
- transform: rotate(1turn);
3468
+ /* Sizes */
3469
+ &.ui-small {
3470
+ input[type="radio"] {
3471
+ --_input-size: var(--size-3);
3472
+ }
2839
3473
  }
2840
- }
2841
- }
2842
3474
 
2843
- @layer components.root {
2844
- label.ui-checkbox {
2845
- --_input-size: var(--size-4);
2846
-
2847
- align-items: center;
2848
- color: var(--text-primary);
2849
- cursor: pointer;
2850
- display: inline-grid;
2851
- gap: 0 var(--size-2);
2852
- grid-auto-columns: auto;
2853
- grid-auto-flow: column;
2854
- inline-size: fit-content;
2855
- line-height: 1.5;
2856
- transform: translateZ(0);
2857
- user-select: none;
2858
-
2859
- /* Disabled */
2860
- &:has([disabled]) {
2861
- cursor: not-allowed;
2862
- opacity: 0.64;
2863
- user-select: none;
2864
-
2865
- input {
2866
- cursor: not-allowed;
2867
- }
2868
- }
2869
-
2870
- /* Required dot */
2871
- &:has(:invalid) {
2872
- .ui-label:after {
2873
- color: var(--red);
2874
- content: "*";
2875
- inset: 0 -0.25ex auto auto;
2876
- position: absolute;
2877
- }
2878
- }
2879
-
2880
- /* Label */
2881
- .ui-label {
2882
- color: var(--text-primary);
2883
- font-size: var(--font-size-05);
2884
- grid-column: 2;
2885
- grid-row: 1;
2886
- position: relative;
2887
- padding-inline: 0 1ex;
2888
- }
2889
-
2890
- /* End text */
2891
- :where(.ui-end-text) {
2892
- color: var(--text-muted);
2893
- font-size: var(--font-size-0);
2894
- grid-column: 2;
2895
- grid-row: 2;
2896
- line-height: 1.5;
2897
- z-index: 1;
2898
- }
2899
-
2900
- /* Spread layout */
2901
- &.ui-spread {
2902
- align-items: center;
2903
- column-gap: var(--size-4);
2904
- grid-auto-flow: unset;
2905
- grid-template-columns: 1fr auto;
2906
- inline-size: 100%;
2907
-
2908
- .ui-label {
2909
- font-weight: 600;
2910
- grid-column: 1;
2911
- grid-row: 1;
2912
- inline-size: fit-content;
2913
- }
2914
-
2915
- input {
2916
- grid-column: 2;
2917
- grid-row: 1;
2918
- }
2919
-
2920
- :where(.ui-end-text) {
2921
- grid-column: 1;
2922
- grid-row: 2;
2923
- }
2924
- }
2925
-
2926
- /* Stacked layout */
2927
- &.ui-stack {
2928
- justify-items: center;
2929
- grid-auto-columns: unset;
2930
-
2931
- .ui-label {
2932
- grid-column: 1/-1;
2933
- grid-row: 2;
2934
- margin-block-start: var(--size-1);
2935
- padding-inline: 1ex;
2936
-
2937
- /* Required dot */
2938
- &::after {
2939
- inset: 0 -0.25ex auto auto;
2940
- }
2941
- }
2942
-
2943
- .ui-end-text {
2944
- grid-column: 1/-1;
2945
- grid-row: 3;
2946
- }
2947
- }
2948
-
2949
- /* Input */
2950
- input[type="checkbox"] {
2951
- --_input-size: var(--size-4);
2952
-
2953
- appearance: none;
2954
- aspect-ratio: 1;
2955
- background-color: var(--surface-default);
2956
- block-size: var(--_input-size);
2957
- border-radius: var(--radius-1);
2958
- border: 1px solid var(--border-color);
2959
- box-sizing: border-box;
2960
- cursor: pointer;
2961
- display: grid;
2962
- font-size: var(--_input-size);
2963
- inline-size: var(--_input-size);
2964
- margin: 0;
2965
- padding: 0;
2966
- place-items: center;
2967
- position: relative;
2968
-
2969
- &:checked,
2970
- &:indeterminate {
2971
- background-color: var(--primary);
2972
- border-color: var(--primary);
2973
- }
2974
-
2975
-
2976
- /* Checkmark */
2977
- &::after {
2978
- background-color: var(--primary-contrast);
2979
- clip-path: polygon(15% 52%, 40% 77%, 85% 32%, 75% 22%, 40% 57%, 25% 42%);
2980
- content: "";
2981
- inset: 0;
2982
- opacity: 0;
2983
- position: absolute;
2984
- }
2985
-
2986
- &:checked::after,
2987
- &:indeterminate::after {
2988
- opacity: 1;
2989
- }
2990
-
2991
- /* Indeterminate dash */
2992
- &:indeterminate::after {
2993
- clip-path: polygon(20% 45%, 80% 45%, 80% 55%, 20% 55%);
2994
- }
2995
-
2996
- &::before {
2997
- --highlight-size: 175%;
2998
- }
2999
- }
3000
-
3001
- /* Sizes */
3002
- &.ui-small {
3003
- input[type="checkbox"] {
3004
- --_input-size: var(--size-3);
3005
- }
3006
- }
3007
-
3008
- &.ui-large {
3009
- input[type="checkbox"] {
3010
- --_input-size: var(--size-5);
3011
- }
3012
- }
3013
-
3014
- /* Validation */
3015
- &[data-invalid],
3016
- &:has(:user-invalid) {
3017
- --palette-source: oklch(0.58 0.21 var(--hue-red));
3018
-
3019
- :where(.ui-end-text) {
3020
- color: var(--primary);
3021
- }
3022
- }
3023
-
3024
- /* Touch devices */
3025
- @media (pointer: coarse) {
3026
- input {
3027
- --_input-size: var(--size-4);
3028
- }
3029
- }
3030
-
3031
- @media (forced-colors: active) {
3032
- input {
3033
- border: 1px solid CanvasText;
3034
-
3035
- &:checked,
3036
- &:indeterminate {
3037
- background-color: SelectedItem;
3038
- border-color: SelectedItem;
3039
-
3040
- &::after {
3041
- background-color: SelectedItemText;
3042
- }
3043
- }
3044
- }
3045
- }
3046
- }
3047
- }
3475
+ &.ui-large {
3476
+ input[type="radio"] {
3477
+ --_input-size: var(--size-4);
3478
+ }
3479
+ }
3048
3480
 
3049
- @layer components.root {
3050
- label.ui-radio {
3051
- --_input-size: 1.125rem;
3052
- --_indicator-size: 50%;
3053
-
3054
- align-items: center;
3055
- color: var(--text-primary);
3056
- cursor: pointer;
3057
- display: inline-grid;
3058
- gap: 0 var(--size-2);
3059
- grid-auto-columns: auto;
3060
- grid-auto-flow: column;
3061
- inline-size: fit-content;
3062
- line-height: 1.5;
3063
- transform: translateZ(0);
3064
- user-select: none;
3065
-
3066
- /* Disabled */
3067
- &:has([disabled]) {
3068
- cursor: not-allowed;
3069
- opacity: 0.64;
3070
- user-select: none;
3071
-
3072
- input {
3073
- cursor: not-allowed;
3074
- }
3075
- }
3076
-
3077
- /* Required dot */
3078
- &:has(:invalid) {
3079
- .ui-label:after {
3080
- color: var(--red);
3081
- content: "*";
3082
- inset: 0 -0.25ex auto auto;
3083
- position: absolute;
3084
- }
3085
- }
3086
-
3087
- /* Label */
3088
- .ui-label {
3089
- color: var(--text-primary);
3090
- font-size: var(--font-size-05);
3091
- grid-column: 2;
3092
- grid-row: 1;
3093
- padding-inline: 0 1ex;
3094
- position: relative;
3095
- }
3096
-
3097
- /* End text */
3098
- :where(.ui-end-text) {
3099
- color: var(--text-muted);
3100
- font-size: var(--font-size-0);
3101
- grid-column: 2;
3102
- grid-row: 2;
3103
- line-height: 1.5;
3104
- z-index: 1;
3105
- }
3106
-
3107
- /* Stacked layout */
3108
- &.ui-stack {
3109
- grid-auto-columns: unset;
3110
- justify-items: center;
3111
-
3112
- .ui-label {
3113
- grid-column: 1/-1;
3114
- grid-row: 2;
3115
- margin-block-start: var(--size-1);
3116
- padding-inline: 1ex;
3117
-
3118
- /* Required dot */
3119
- &::after {
3120
- inset: 0 -0.25ex auto auto;
3121
- }
3122
- }
3123
-
3124
- .ui-end-text {
3125
- grid-column: 1/-1;
3126
- grid-row: 3;
3127
- }
3128
- }
3129
-
3130
- /* Input */
3131
- input[type="radio"] {
3132
- appearance: none;
3133
- aspect-ratio: 1;
3134
- background-color: var(--surface-default);
3135
- block-size: var(--_input-size);
3136
- border: 1px solid var(--field-border-color);
3137
- border-radius: var(--radius-round);
3138
- box-sizing: border-box;
3139
- cursor: pointer;
3140
- display: grid;
3141
- inline-size: var(--_input-size);
3142
- margin: 0;
3143
- padding: 0;
3144
- place-items: center;
3145
- position: relative;
3146
-
3147
- &:checked {
3148
- background-color: var(--primary);
3149
- border-color: var(--primary);
3150
- }
3151
-
3152
- /* Dot */
3153
- &::after {
3154
- background-color: var(--primary-contrast);
3155
- block-size: var(--_indicator-size);
3156
- border-radius: var(--radius-round);
3157
- content: "";
3158
- inline-size: var(--_indicator-size);
3159
- margin: auto;
3160
- opacity: 0;
3161
- }
3162
-
3163
- &:checked::after {
3164
- opacity: 1;
3165
- }
3166
-
3167
- &::before {
3168
- --highlight-size: 175%;
3169
- }
3170
- }
3171
-
3172
- /* Sizes */
3173
- &.ui-small {
3174
- input[type="radio"] {
3175
- --_input-size: var(--size-3);
3176
-
3177
- }
3178
- }
3179
-
3180
- &.ui-large {
3181
- input[type="radio"] {
3182
- --_input-size: var(--size-4);
3183
-
3184
- }
3185
- }
3186
-
3187
- /* Validation */
3188
- &[data-invalid],
3189
- &:has(:user-invalid) {
3190
- --palette-source: oklch(0.58 0.21 var(--hue-red));
3191
-
3192
- :where(.ui-end-text) {
3193
- color: var(--primary);
3194
- }
3195
- }
3196
-
3197
- /* Touch devices */
3198
- @media (pointer: coarse) {
3199
- input[type="radio"] {
3200
- block-size: var(--size-4);
3201
- inline-size: var(--size-4);
3202
- }
3203
- }
3204
-
3205
- @media (forced-colors: active) {
3206
- input[type="radio"] {
3207
- border: 1px solid CanvasText;
3208
-
3209
- &:checked {
3210
- background-color: SelectedItem;
3211
- border-color: SelectedItem;
3212
-
3213
- &::after {
3214
- background-color: SelectedItemText;
3215
- }
3216
- }
3217
- }
3218
- }
3219
- }
3481
+ /* Validation */
3482
+ &[data-invalid],
3483
+ &:has(:user-invalid) {
3484
+ --primary: var(--critical);
3485
+
3486
+ :where(.ui-end-text) {
3487
+ color: var(--critical);
3488
+ }
3489
+ }
3490
+
3491
+ /* Touch devices */
3492
+ @media (pointer: coarse) {
3493
+ input[type="radio"] {
3494
+ block-size: var(--size-4);
3495
+ inline-size: var(--size-4);
3496
+ }
3497
+ }
3498
+
3499
+ @media (forced-colors: active) {
3500
+ input[type="radio"] {
3501
+ border: 1px solid CanvasText;
3502
+
3503
+ &:checked {
3504
+ background-color: SelectedItem;
3505
+ border-color: SelectedItem;
3506
+
3507
+ &::after {
3508
+ background-color: SelectedItemText;
3509
+ }
3510
+ }
3511
+ }
3512
+ }
3513
+ }
3220
3514
  }
3221
3515
 
3222
3516
  @layer components.root {
@@ -3277,7 +3571,7 @@
3277
3571
  margin-top: calc(var(--size-1) * -1);
3278
3572
  padding-inline: calc(3ex / 2);
3279
3573
 
3280
- &>option {
3574
+ & > option {
3281
3575
  display: flex;
3282
3576
  inline-size: 0;
3283
3577
  justify-content: center;
@@ -3458,9 +3752,11 @@
3458
3752
  /* Track */
3459
3753
  &::-webkit-slider-runnable-track {
3460
3754
  appearance: none;
3461
- background: linear-gradient(to right,
3462
- var(--_track-fill-color) var(--_track-fill, 0%),
3463
- var(--_track-color) 0%);
3755
+ background: linear-gradient(
3756
+ to right,
3757
+ var(--_track-fill-color) var(--_track-fill, 0%),
3758
+ var(--_track-color) 0%
3759
+ );
3464
3760
  block-size: var(--_track-height);
3465
3761
  border-radius: var(--_track-radius);
3466
3762
  }
@@ -3486,7 +3782,8 @@
3486
3782
  block-size: var(--_thumb-size);
3487
3783
  border: 3px solid var(--surface-default);
3488
3784
  border-radius: 50%;
3489
- box-shadow: 0 0 0 var(--_thumb-highlight-size) var(--_thumb-highlight-color);
3785
+ box-shadow: 0 0 0 var(--_thumb-highlight-size)
3786
+ var(--_thumb-highlight-color);
3490
3787
  cursor: ew-resize;
3491
3788
  inline-size: var(--_thumb-size);
3492
3789
  margin-block-start: var(--_thumb-offset);
@@ -3506,7 +3803,8 @@
3506
3803
  block-size: var(--_thumb-size);
3507
3804
  border: 3px solid var(--surface-default);
3508
3805
  border-radius: 50%;
3509
- box-shadow: 0 0 0 var(--_thumb-highlight-size) var(--_thumb-highlight-color);
3806
+ box-shadow: 0 0 0 var(--_thumb-highlight-size)
3807
+ var(--_thumb-highlight-color);
3510
3808
  cursor: ew-resize;
3511
3809
  inline-size: var(--_thumb-size);
3512
3810
  margin-block-start: var(--_thumb-offset);
@@ -3533,8 +3831,10 @@
3533
3831
 
3534
3832
  &:active {
3535
3833
  --_thumb-highlight-size: var(--size-2);
3536
- --_track-color: light-dark(oklch(from var(--field-border-color) calc(l * 0.9) c h),
3537
- oklch(from var(--field-border-color) calc(l * 1.1) c h));
3834
+ --_track-color: light-dark(
3835
+ oklch(from var(--field-border-color) calc(l * 0.9) c h),
3836
+ oklch(from var(--field-border-color) calc(l * 1.1) c h)
3837
+ );
3538
3838
  }
3539
3839
  }
3540
3840
 
@@ -3554,7 +3854,6 @@
3554
3854
  }
3555
3855
  }
3556
3856
  }
3557
-
3558
3857
  }
3559
3858
 
3560
3859
  @layer components.root {
@@ -3603,7 +3902,8 @@
3603
3902
 
3604
3903
  &:focus-visible {
3605
3904
  --focus-ring-color: currentColor;
3606
- outline: var(--focus-ring-width) var(--focus-ring-style) var(--focus-ring-color);
3905
+ outline: var(--focus-ring-width) var(--focus-ring-style)
3906
+ var(--focus-ring-color);
3607
3907
  outline-offset: var(--focus-ring-offset);
3608
3908
  }
3609
3909
 
@@ -3635,13 +3935,14 @@
3635
3935
  --_dot-bg-color: var(--_accent-contrast);
3636
3936
  --_dot-outline-size: calc(var(--size-1) - 1px);
3637
3937
 
3638
- inset-inline-start: calc(var(--_track-width) - var(--_dot-size) - var(--size-1));
3938
+ inset-inline-start: calc(
3939
+ var(--_track-width) - var(--_dot-size) - var(--size-1)
3940
+ );
3639
3941
  }
3640
3942
  }
3641
3943
 
3642
3944
  /* Animation */
3643
3945
  @media (prefers-reduced-motion: no-preference) {
3644
-
3645
3946
  /* Track */
3646
3947
  &::before {
3647
3948
  transition:
@@ -3701,7 +4002,9 @@
3701
4002
  }
3702
4003
 
3703
4004
  .ui-icon-unchecked {
3704
- margin-inline-start: calc(var(--_track-width) - var(--_dot-size) - var(--size-1));
4005
+ margin-inline-start: calc(
4006
+ var(--_track-width) - var(--_dot-size) - var(--size-1)
4007
+ );
3705
4008
  }
3706
4009
 
3707
4010
  .ui-icon-checked {
@@ -3780,7 +4083,6 @@
3780
4083
  }
3781
4084
 
3782
4085
  &:has(.ui-icon-checked, .ui-icon-unchecked) {
3783
-
3784
4086
  input[role="switch"],
3785
4087
  .ui-icon-checked,
3786
4088
  .ui-icon-unchecked {
@@ -3827,169 +4129,167 @@
3827
4129
  }
3828
4130
 
3829
4131
  @layer components.extended {
3830
- :where(#toast-manager) {
3831
- background: none;
3832
- block-size: auto;
3833
- border: none;
3834
- display: none;
3835
- flex-direction: column-reverse;
3836
- gap: var(--size-3);
3837
- inline-size: auto;
3838
- inset: auto var(--size-4) var(--size-4) auto;
3839
- margin: 0;
3840
- max-inline-size: calc(100vi - var(--size-8));
3841
- overflow: visible;
3842
- padding: 0;
3843
- pointer-events: none;
3844
- position: fixed;
3845
- z-index: 1000;
3846
-
3847
- &:popover-open {
3848
- display: flex;
3849
- }
3850
-
3851
- &::backdrop {
3852
- display: none;
3853
- }
3854
-
3855
- /* Optional cap on visible toasts. Older toasts beyond this depth are hidden
4132
+ :where(#toast-manager) {
4133
+ background: none;
4134
+ block-size: auto;
4135
+ border: none;
4136
+ display: none;
4137
+ flex-direction: column-reverse;
4138
+ gap: var(--size-3);
4139
+ inline-size: auto;
4140
+ inset: auto var(--size-4) var(--size-4) auto;
4141
+ margin: 0;
4142
+ max-inline-size: calc(100vi - var(--size-8));
4143
+ overflow: visible;
4144
+ padding: 0;
4145
+ pointer-events: none;
4146
+ position: fixed;
4147
+ z-index: 1000;
4148
+
4149
+ &:popover-open {
4150
+ display: flex;
4151
+ }
4152
+
4153
+ &::backdrop {
4154
+ display: none;
4155
+ }
4156
+
4157
+ /* Optional cap on visible toasts. Older toasts beyond this depth are hidden
3856
4158
  but still in the DOM so they animate cleanly when newer ones are removed. */
3857
- /* > .toast:nth-last-child(n + 6) { display: none; } */
3858
- }
3859
-
3860
- :where(.ui-toast) {
3861
- --_anim-enter: 0.3s;
3862
- --_anim-exit: 0.3s;
3863
-
3864
- align-items: center;
3865
- animation:
3866
- toast-enter var(--_anim-enter) var(--ease-out-3) both,
3867
- toast-hold attr(data-duration type(<time>), 5s) linear both,
3868
- toast-exit var(--_anim-exit) var(--ease-in-3) both;
3869
- animation-delay:
3870
- 0s,
3871
- var(--_anim-enter),
3872
- calc(var(--_anim-enter) + attr(data-duration type(<time>), 5s));
3873
- background-color: light-dark(var(--gray-15), var(--gray-2));
3874
- border-radius: var(--border-radius);
3875
- box-shadow: var(--shadow-3);
3876
- color: var(--text-primary-contrast);
3877
- display: flex;
3878
- gap: var(--size-3);
3879
- justify-content: space-between;
3880
- min-inline-size: 30ch;
3881
- padding: var(--size-3) var(--size-4);
3882
- pointer-events: auto;
3883
-
3884
- &:hover {
3885
- animation-play-state: paused;
3886
- }
3887
-
3888
- &.ui-exiting {
3889
- animation: toast-exit var(--_anim-exit) var(--ease-in-3) forwards;
3890
- }
3891
-
3892
- .ui-icon {
3893
- background: no-repeat center / contain;
3894
- block-size: var(--size-4);
3895
- flex-shrink: 0;
3896
- inline-size: var(--size-4);
3897
- }
3898
-
3899
- /* Hide the icon slot when there's no severity to render against. */
3900
- &:not([data-severity]) .ui-icon {
3901
- display: none;
3902
- }
3903
-
3904
- .ui-content {
3905
- font-size: var(--font-size-05);
3906
- word-break: break-word;
3907
- }
3908
-
3909
- .ui-title {
3910
- font-weight: 600;
3911
- }
3912
-
3913
- .ui-description {
3914
- color: oklch(from currentColor l c h / 75%);
3915
- font-size: var(--font-size-0);
3916
- }
3917
-
3918
- .ui-close-button {
3919
- background: none;
3920
- border: none;
3921
- color: inherit;
3922
- cursor: pointer;
3923
- display: grid;
3924
- opacity: 0.7;
3925
- padding: var(--size-1);
3926
- place-items: center;
3927
- transition: opacity 0.2s;
3928
-
3929
- &:hover {
3930
- opacity: 1;
3931
- }
3932
- }
3933
-
3934
- /* Severity icons via CSS data URIs — keeps icon assets out of JS strings. */
3935
- &[data-severity="success"] .ui-icon {
3936
- 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>");
3937
- }
3938
-
3939
- &[data-severity="info"] .ui-icon {
3940
- 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>");
3941
- }
3942
-
3943
- &[data-severity="warning"] .ui-icon {
3944
- 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>");
3945
- }
3946
-
3947
- &[data-severity="critical"] .ui-icon {
3948
- 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>");
3949
- }
3950
- }
3951
-
3952
- @keyframes toast-enter {
3953
- from {
3954
- opacity: 0;
3955
- translate: var(--size-4) 0;
3956
- }
3957
-
3958
- to {
3959
- opacity: 1;
3960
- translate: 0 0;
3961
- }
3962
- }
3963
-
3964
- /* Identity keyframe — only purpose is to delay the exit animation by the
4159
+ /* > .toast:nth-last-child(n + 6) { display: none; } */
4160
+ }
4161
+
4162
+ :where(.ui-toast) {
4163
+ --_anim-enter: 0.3s;
4164
+ --_anim-exit: 0.3s;
4165
+
4166
+ align-items: center;
4167
+ animation:
4168
+ toast-enter var(--_anim-enter) var(--ease-out-3) both,
4169
+ toast-hold attr(data-duration type(<time>), 5s) linear both,
4170
+ toast-exit var(--_anim-exit) var(--ease-in-3) both;
4171
+ animation-delay:
4172
+ 0s, var(--_anim-enter),
4173
+ calc(var(--_anim-enter) + attr(data-duration type(<time>), 5s));
4174
+ background-color: light-dark(var(--gray-15), var(--gray-2));
4175
+ border-radius: var(--border-radius);
4176
+ box-shadow: var(--shadow-3);
4177
+ color: var(--text-primary-contrast);
4178
+ display: flex;
4179
+ gap: var(--size-3);
4180
+ justify-content: space-between;
4181
+ min-inline-size: 30ch;
4182
+ padding: var(--size-3) var(--size-4);
4183
+ pointer-events: auto;
4184
+
4185
+ &:hover {
4186
+ animation-play-state: paused;
4187
+ }
4188
+
4189
+ &.ui-exiting {
4190
+ animation: toast-exit var(--_anim-exit) var(--ease-in-3) forwards;
4191
+ }
4192
+
4193
+ .ui-icon {
4194
+ background: no-repeat center / contain;
4195
+ block-size: var(--size-4);
4196
+ flex-shrink: 0;
4197
+ inline-size: var(--size-4);
4198
+ }
4199
+
4200
+ /* Hide the icon slot when there's no severity to render against. */
4201
+ &:not([data-severity]) .ui-icon {
4202
+ display: none;
4203
+ }
4204
+
4205
+ .ui-content {
4206
+ font-size: var(--font-size-05);
4207
+ word-break: break-word;
4208
+ }
4209
+
4210
+ .ui-title {
4211
+ font-weight: 600;
4212
+ }
4213
+
4214
+ .ui-description {
4215
+ color: oklch(from currentColor l c h / 75%);
4216
+ font-size: var(--font-size-0);
4217
+ }
4218
+
4219
+ .ui-close-button {
4220
+ background: none;
4221
+ border: none;
4222
+ color: inherit;
4223
+ cursor: pointer;
4224
+ display: grid;
4225
+ opacity: 0.7;
4226
+ padding: var(--size-1);
4227
+ place-items: center;
4228
+ transition: opacity 0.2s;
4229
+
4230
+ &:hover {
4231
+ opacity: 1;
4232
+ }
4233
+ }
4234
+
4235
+ /* Severity icons via CSS data URIs — keeps icon assets out of JS strings. */
4236
+ &[data-severity="success"] .ui-icon {
4237
+ 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>");
4238
+ }
4239
+
4240
+ &[data-severity="info"] .ui-icon {
4241
+ 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>");
4242
+ }
4243
+
4244
+ &[data-severity="warning"] .ui-icon {
4245
+ 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>");
4246
+ }
4247
+
4248
+ &[data-severity="critical"] .ui-icon {
4249
+ 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>");
4250
+ }
4251
+ }
4252
+
4253
+ @keyframes toast-enter {
4254
+ from {
4255
+ opacity: 0;
4256
+ translate: var(--size-4) 0;
4257
+ }
4258
+
4259
+ to {
4260
+ opacity: 1;
4261
+ translate: 0 0;
4262
+ }
4263
+ }
4264
+
4265
+ /* Identity keyframe — only purpose is to delay the exit animation by the
3965
4266
  author-defined duration. */
3966
- @keyframes toast-hold {
3967
- from {
3968
- opacity: 1;
3969
- }
3970
-
3971
- to {
3972
- opacity: 1;
3973
- }
3974
- }
3975
-
3976
- @keyframes toast-exit {
3977
- from {
3978
- opacity: 1;
3979
- scale: 1;
3980
- translate: 0 0;
3981
- }
3982
-
3983
- to {
3984
- opacity: 0;
3985
- scale: 0.9;
3986
- translate: 0 var(--size-4);
3987
- }
3988
- }
4267
+ @keyframes toast-hold {
4268
+ from {
4269
+ opacity: 1;
4270
+ }
4271
+
4272
+ to {
4273
+ opacity: 1;
4274
+ }
4275
+ }
4276
+
4277
+ @keyframes toast-exit {
4278
+ from {
4279
+ opacity: 1;
4280
+ scale: 1;
4281
+ translate: 0 0;
4282
+ }
4283
+
4284
+ to {
4285
+ opacity: 0;
4286
+ scale: 0.9;
4287
+ translate: 0 var(--size-4);
4288
+ }
4289
+ }
3989
4290
  }
3990
4291
 
3991
4292
  @layer components.root {
3992
-
3993
4293
  :where(.ui-p) {
3994
4294
  text-wrap: pretty;
3995
4295
 
@@ -4044,8 +4344,10 @@
4044
4344
 
4045
4345
  /** Overline */
4046
4346
  :where(.ui-overline) {
4047
- color: light-dark(oklch(from var(--text-muted) calc(l * 1.25) c h),
4048
- oklch(from var(--text-muted) calc(l * 0.75) c h));
4347
+ color: light-dark(
4348
+ oklch(from var(--text-muted) calc(l * 1.25) c h),
4349
+ oklch(from var(--text-muted) calc(l * 0.75) c h)
4350
+ );
4049
4351
  font-size: var(--font-size-0);
4050
4352
  font-weight: 500;
4051
4353
  letter-spacing: 0.06em;
@@ -4053,18 +4355,20 @@
4053
4355
  }
4054
4356
 
4055
4357
  :where(.ui-hgroup) {
4056
- &>p {
4358
+ & > p {
4057
4359
  margin: 0;
4058
4360
  }
4059
4361
 
4060
- &> :where(h1, h2, h3, h4, h5, h6) {
4362
+ & > :where(h1, h2, h3, h4, h5, h6) {
4061
4363
  margin-block: 0 0.4em;
4062
4364
  }
4063
4365
 
4064
4366
  /* First p element (overline) */
4065
- &>p:first-of-type:first-child {
4066
- color: light-dark(oklch(from var(--text-muted) calc(l * 1.25) c h),
4067
- oklch(from var(--text-muted) calc(l * 0.75) c h));
4367
+ & > p:first-of-type:first-child {
4368
+ color: light-dark(
4369
+ oklch(from var(--text-muted) calc(l * 1.25) c h),
4370
+ oklch(from var(--text-muted) calc(l * 0.75) c h)
4371
+ );
4068
4372
  font-size: var(--font-size-0);
4069
4373
  font-weight: 500;
4070
4374
  letter-spacing: 0.06em;
@@ -4072,13 +4376,13 @@
4072
4376
  }
4073
4377
 
4074
4378
  /* Body paragraphs after the heading */
4075
- &>p:not(:first-of-type:first-child) {
4379
+ & > p:not(:first-of-type:first-child) {
4076
4380
  color: oklch(from currentColor l c h / 75%);
4077
4381
  font-size: var(--font-size-3);
4078
4382
  line-height: 1.6;
4079
4383
  }
4080
4384
 
4081
- &>p+p {
4385
+ & > p + p {
4082
4386
  margin-block-start: 0.75em;
4083
4387
  }
4084
4388
  }
@@ -4090,8 +4394,6 @@
4090
4394
  line-height: 1.6;
4091
4395
  }
4092
4396
 
4093
-
4094
-
4095
4397
  /* Inline text elements — class utilities (work anywhere) */
4096
4398
  :where(.ui-u, .ui-abbr, .ui-dfn) {
4097
4399
  text-decoration: underline;
@@ -4144,7 +4446,7 @@
4144
4446
  :where(.ui-mark) {
4145
4447
  border-radius: var(--radius-2);
4146
4448
  box-decoration-break: clone;
4147
- padding: .1ex .3ex;
4449
+ padding: 0.1ex 0.3ex;
4148
4450
  vertical-align: baseline;
4149
4451
  }
4150
4452
 
@@ -4217,7 +4519,7 @@
4217
4519
  scrollbar-width: thin;
4218
4520
  white-space: pre;
4219
4521
 
4220
- >code {
4522
+ > code {
4221
4523
  background: none;
4222
4524
  border-radius: 0;
4223
4525
  color: inherit;
@@ -4227,7 +4529,6 @@
4227
4529
  writing-mode: inherit;
4228
4530
  }
4229
4531
  }
4230
-
4231
4532
  }
4232
4533
 
4233
4534
  /* Rich text */
@@ -4245,7 +4546,6 @@
4245
4546
  text-underline-offset: 2px;
4246
4547
 
4247
4548
  &[href] {
4248
-
4249
4549
  &:hover,
4250
4550
  &:focus-visible {
4251
4551
  color: var(--primary-light);
@@ -4295,7 +4595,7 @@
4295
4595
  overflow-x: auto;
4296
4596
  scrollbar-width: thin;
4297
4597
 
4298
- >code {
4598
+ > code {
4299
4599
  background: none;
4300
4600
  border-radius: 0;
4301
4601
  color: inherit;
@@ -4306,7 +4606,6 @@
4306
4606
  }
4307
4607
  }
4308
4608
 
4309
-
4310
4609
  /* Text */
4311
4610
  p {
4312
4611
  font-size: inherit;
@@ -4320,7 +4619,7 @@
4320
4619
  font-weight: 700;
4321
4620
  text-wrap: pretty;
4322
4621
 
4323
- &+*:not(&) {
4622
+ & + *:not(&) {
4324
4623
  margin-block-start: 0;
4325
4624
  }
4326
4625
  }
@@ -4367,8 +4666,10 @@
4367
4666
 
4368
4667
  /** Overline */
4369
4668
  :is(.ui-overline, hgroup p:first-of-type:first-child) {
4370
- color: light-dark(oklch(from var(--text-muted) calc(l * 1.25) c h),
4371
- oklch(from var(--text-muted) calc(l * 0.75) c h));
4669
+ color: light-dark(
4670
+ oklch(from var(--text-muted) calc(l * 1.25) c h),
4671
+ oklch(from var(--text-muted) calc(l * 0.75) c h)
4672
+ );
4372
4673
  font-size: var(--font-size-0);
4373
4674
  font-weight: 500;
4374
4675
  letter-spacing: 0.06em;
@@ -4376,26 +4677,26 @@
4376
4677
  }
4377
4678
 
4378
4679
  hgroup {
4379
- &>p {
4680
+ & > p {
4380
4681
  margin: 0;
4381
4682
  }
4382
4683
 
4383
- &> :where(h1, h2, h3, h4, h5, h6) {
4684
+ & > :where(h1, h2, h3, h4, h5, h6) {
4384
4685
  margin-block: 0 0.4em;
4385
4686
  }
4386
4687
 
4387
- &+* {
4688
+ & + * {
4388
4689
  margin-block-start: 3em;
4389
4690
  }
4390
4691
 
4391
4692
  /* Body paragraphs after the heading */
4392
- &>p:not(:first-of-type:first-child) {
4693
+ & > p:not(:first-of-type:first-child) {
4393
4694
  color: oklch(from currentColor l c h / 75%);
4394
4695
  font-size: var(--font-size-3);
4395
4696
  line-height: 1.6;
4396
4697
  }
4397
4698
 
4398
- &>p+p {
4699
+ & > p + p {
4399
4700
  margin-block-start: 0.75em;
4400
4701
  }
4401
4702
  }
@@ -4457,7 +4758,7 @@
4457
4758
  margin-block: var(--size-7);
4458
4759
  place-items: center;
4459
4760
 
4460
- &>* {
4761
+ & > * {
4461
4762
  margin-block: 0;
4462
4763
  }
4463
4764
 
@@ -4468,18 +4769,18 @@
4468
4769
  }
4469
4770
 
4470
4771
  /* Remove top margin from first child */
4471
- &> :first-child {
4772
+ & > :first-child {
4472
4773
  margin-block-start: 0;
4473
4774
  }
4474
4775
 
4475
4776
  /* Remove bottom margin from last child */
4476
- &> :last-child {
4777
+ & > :last-child {
4477
4778
  margin-block-end: 0;
4478
4779
  }
4479
4780
 
4480
4781
  /* Horizontal rules */
4481
4782
  hr {
4482
- &+* {
4783
+ & + * {
4483
4784
  margin-block-start: 0;
4484
4785
  }
4485
4786
  }
@@ -4560,7 +4861,7 @@
4560
4861
  mark {
4561
4862
  border-radius: var(--radius-2);
4562
4863
  box-decoration-break: clone;
4563
- padding: .1ex .3ex;
4864
+ padding: 0.1ex 0.3ex;
4564
4865
  vertical-align: baseline;
4565
4866
  }
4566
4867
 
@@ -4594,14 +4895,14 @@
4594
4895
 
4595
4896
  /* Floating wrapper: traditional inset-based positioning so this works
4596
4897
  in browsers without position-area support (Firefox, older Safari). */
4597
- &>.ui-anchor-floating:not([popover]) {
4898
+ & > .ui-anchor-floating:not([popover]) {
4598
4899
  inset: var(--_badge-inset);
4599
4900
  position-anchor: auto;
4600
4901
  position-area: none;
4601
4902
  }
4602
4903
 
4603
4904
  /* Indicator */
4604
- &>.ui-anchor-floating>.ui-badge-indicator {
4905
+ & > .ui-anchor-floating > .ui-badge-indicator {
4605
4906
  background-color: var(--_bg-color);
4606
4907
  block-size: var(--_size);
4607
4908
  border: 2px solid var(--_border-color);
@@ -4670,7 +4971,7 @@
4670
4971
  --_anchor-ty: var(--_dot-size);
4671
4972
  }
4672
4973
 
4673
- &.ui-dot>.ui-anchor-floating>.ui-badge-indicator {
4974
+ &.ui-dot > .ui-anchor-floating > .ui-badge-indicator {
4674
4975
  block-size: var(--_dot-size);
4675
4976
  inline-size: var(--_dot-size);
4676
4977
  min-inline-size: var(--_dot-size);
@@ -4678,7 +4979,7 @@
4678
4979
  }
4679
4980
 
4680
4981
  /* Visibility */
4681
- &.ui-invisible>.ui-anchor-floating>.ui-badge-indicator {
4982
+ &.ui-invisible > .ui-anchor-floating > .ui-badge-indicator {
4682
4983
  opacity: 0;
4683
4984
  pointer-events: none;
4684
4985
  }
@@ -4698,8 +4999,10 @@
4698
4999
  border-radius: 0;
4699
5000
 
4700
5001
  /* button.css > --_accent-tonal */
4701
- --_divider-color: light-dark(oklch(from var(--_accent-tonal) calc(l - 0.1) c h),
4702
- oklch(from var(--_accent-tonal) calc(l + 0.1) c h));
5002
+ --_divider-color: light-dark(
5003
+ oklch(from var(--_accent-tonal) calc(l - 0.1) c h),
5004
+ oklch(from var(--_accent-tonal) calc(l + 0.1) c h)
5005
+ );
4703
5006
 
4704
5007
  &.ui-outlined {
4705
5008
  --_divider-color: var(--_border-color);
@@ -4716,16 +5019,19 @@
4716
5019
  /* Color inheritance from Button Group — shared interaction model.
4717
5020
  The .critical scope class in theme.css redirects --palette-source so
4718
5021
  --color-6 below becomes a tint of the active color. */
4719
- :where(.ui-button-group.ui-critical,
4720
- .ui-button-group.ui-primary) & {
5022
+ :where(.ui-button-group.ui-critical, .ui-button-group.ui-primary) & {
4721
5023
  --_color-contrast: var(--gray-1);
4722
5024
  --_color-tonal: var(--color-6);
4723
5025
  --_accent-tonal-contrast: var(--text-primary-contrast);
4724
5026
  --_default-hover-bg-color: oklch(from var(--_accent) l c h / 15%);
4725
5027
  --_default-active-bg-color: oklch(from var(--_accent) l c h / 25%);
4726
5028
  --_filled-hover-bg-color: oklch(from var(--_accent) calc(l - 0.1) c h);
4727
- --_filled-active-bg-color: oklch(from var(--_accent) calc(l - 0.15) c h);
4728
- --_outlined-active-bg-color: oklch(from var(--_accent) calc(l - 0.1) c h);
5029
+ --_filled-active-bg-color: oklch(
5030
+ from var(--_accent) calc(l - 0.15) c h
5031
+ );
5032
+ --_outlined-active-bg-color: oklch(
5033
+ from var(--_accent) calc(l - 0.1) c h
5034
+ );
4729
5035
  }
4730
5036
 
4731
5037
  :where(.ui-button-group.ui-critical) & {
@@ -4788,10 +5094,11 @@
4788
5094
  --_text-color: var(--_accent-contrast);
4789
5095
  --_divider-color: currentColor;
4790
5096
 
4791
- :where(.ui-button-group.ui-critical,
4792
- .ui-button-group.ui-primary) & {
4793
- --_divider-color: light-dark(oklch(from var(--_accent) calc(l - 0.1) c h),
4794
- oklch(from var(--_accent) calc(l + 0.1) c h));
5097
+ :where(.ui-button-group.ui-critical, .ui-button-group.ui-primary) & {
5098
+ --_divider-color: light-dark(
5099
+ oklch(from var(--_accent) calc(l - 0.1) c h),
5100
+ oklch(from var(--_accent) calc(l + 0.1) c h)
5101
+ );
4795
5102
  }
4796
5103
 
4797
5104
  &:where(:not([disabled])) {
@@ -4819,13 +5126,17 @@
4819
5126
  }
4820
5127
 
4821
5128
  /* Siblings */
4822
- &+& {
5129
+ & + & {
4823
5130
  border-inline-start-color: var(--_divider-color);
4824
5131
  border-inline-width: 1px;
4825
5132
  margin-inline-start: -1px;
4826
5133
 
4827
5134
  &[disabled] {
4828
- border-inline-start-color: color-mix(in oklch, var(--_divider-color) 40%, transparent);
5135
+ border-inline-start-color: color-mix(
5136
+ in oklch,
5137
+ var(--_divider-color) 40%,
5138
+ transparent
5139
+ );
4829
5140
  }
4830
5141
  }
4831
5142
  }
@@ -4852,12 +5163,16 @@
4852
5163
  border-end-end-radius: var(--_border-radius);
4853
5164
  }
4854
5165
 
4855
- &+& {
5166
+ & + & {
4856
5167
  border-block-start: 1px solid var(--_divider-color);
4857
5168
  margin-block-start: -1px;
4858
5169
 
4859
5170
  &[disabled] {
4860
- border-block-start-color: color-mix(in oklch, var(--_divider-color) 40%, transparent);
5171
+ border-block-start-color: color-mix(
5172
+ in oklch,
5173
+ var(--_divider-color) 40%,
5174
+ transparent
5175
+ );
4861
5176
  }
4862
5177
  }
4863
5178
  }
@@ -4936,7 +5251,7 @@
4936
5251
  }
4937
5252
 
4938
5253
  /* Layout */
4939
- &>summary {
5254
+ & > summary {
4940
5255
  background-color: inherit;
4941
5256
  cursor: pointer;
4942
5257
  font-weight: 700;
@@ -4961,17 +5276,17 @@
4961
5276
  }
4962
5277
  }
4963
5278
 
4964
- &[open]>summary svg {
5279
+ &[open] > summary svg {
4965
5280
  rotate: 180deg;
4966
5281
  }
4967
5282
 
4968
- &>.ui-content {
5283
+ & > .ui-content {
4969
5284
  margin-block-start: 0;
4970
5285
  padding-block: var(--_content-padding-block);
4971
5286
  padding-inline: var(--_content-padding-inline);
4972
5287
  }
4973
5288
 
4974
- &>.ui-actions {
5289
+ & > .ui-actions {
4975
5290
  display: flex;
4976
5291
  gap: var(--_actions-gap);
4977
5292
  justify-content: end;
@@ -4996,12 +5311,12 @@
4996
5311
  }
4997
5312
  }
4998
5313
 
4999
- &>.ui-content {
5314
+ & > .ui-content {
5000
5315
  margin-block: 0;
5001
5316
  padding: 0;
5002
5317
  }
5003
5318
 
5004
- &>details.ui-accordion {
5319
+ & > details.ui-accordion {
5005
5320
  --_border-color: transparent;
5006
5321
  --_border-width: 0;
5007
5322
  --_margin-inline: 0;
@@ -5010,7 +5325,7 @@
5010
5325
  --_summary-padding-inline: var(--_item-summary-padding-inline);
5011
5326
 
5012
5327
  /* Border between accordion items */
5013
- &+& {
5328
+ & + & {
5014
5329
  border-block-start: 1px solid var(--_gutter-color);
5015
5330
  border-radius: 0;
5016
5331
  }
@@ -5041,7 +5356,6 @@
5041
5356
  }
5042
5357
 
5043
5358
  @layer components.extended {
5044
-
5045
5359
  /*
5046
5360
  Lists meant to be used stand-alone or as part of Select elements
5047
5361
 
@@ -5059,7 +5373,6 @@ Lists meant to be used stand-alone or as part of Select elements
5059
5373
  padding: var(--size-2) 0;
5060
5374
 
5061
5375
  @media (pointer: coarse) {
5062
-
5063
5376
  &,
5064
5377
  * {
5065
5378
  user-select: none;
@@ -5119,14 +5432,14 @@ Lists meant to be used stand-alone or as part of Select elements
5119
5432
  padding: 0;
5120
5433
  }
5121
5434
 
5122
- &> :where(a, button, label) {
5435
+ & > :where(a, button, label) {
5123
5436
  gap: var(--size-2);
5124
5437
  min-block-size: var(--size-7);
5125
5438
  padding: var(--size-1) var(--size-2);
5126
5439
  }
5127
5440
 
5128
5441
  /* Checkbox / Radio */
5129
- &>label {
5442
+ & > label {
5130
5443
  .ui-end {
5131
5444
  padding-inline-end: 0.125rem;
5132
5445
  }
@@ -5161,7 +5474,7 @@ Lists meant to be used stand-alone or as part of Select elements
5161
5474
  :where(li, option) {
5162
5475
  padding-inline: 0;
5163
5476
 
5164
- &> :where(a, button, label) {
5477
+ & > :where(a, button, label) {
5165
5478
  padding-inline: 0;
5166
5479
  }
5167
5480
  }
@@ -5195,9 +5508,9 @@ Lists meant to be used stand-alone or as part of Select elements
5195
5508
  min-block-size: auto;
5196
5509
  padding: 0;
5197
5510
 
5198
- &[aria-selected="true"]> :where(a, button, label),
5511
+ &[aria-selected="true"] > :where(a, button, label),
5199
5512
  &[aria-selected="true"],
5200
- &:has(> [aria-current="page"])> :where(a, button, label) {
5513
+ &:has(> [aria-current="page"]) > :where(a, button, label) {
5201
5514
  background-color: var(--_bg-color-hover);
5202
5515
  }
5203
5516
  }
@@ -5232,9 +5545,9 @@ Lists meant to be used stand-alone or as part of Select elements
5232
5545
  }
5233
5546
  }
5234
5547
 
5235
- &>a,
5236
- &>button,
5237
- &>label {
5548
+ & > a,
5549
+ & > button,
5550
+ & > label {
5238
5551
  align-items: center;
5239
5552
  background-color: var(--_bg-color);
5240
5553
  color: inherit;
@@ -5261,7 +5574,7 @@ Lists meant to be used stand-alone or as part of Select elements
5261
5574
  }
5262
5575
 
5263
5576
  /* Checkbox / Radio / Switch */
5264
- &>label {
5577
+ & > label {
5265
5578
  &:where(.ui-checkbox, .ui-radio, .ui-switch) {
5266
5579
  display: flex;
5267
5580
  }
@@ -5312,7 +5625,7 @@ Lists meant to be used stand-alone or as part of Select elements
5312
5625
  font-weight: 400;
5313
5626
  }
5314
5627
 
5315
- p+p {
5628
+ p + p {
5316
5629
  color: var(--text-muted);
5317
5630
  font-size: var(--font-size-0);
5318
5631
  }
@@ -5429,7 +5742,8 @@ Lists meant to be used stand-alone or as part of Select elements
5429
5742
 
5430
5743
  &[open] {
5431
5744
  opacity: 1;
5432
- transition: display 0.2s allow-discrete,
5745
+ transition:
5746
+ display 0.2s allow-discrete,
5433
5747
  overlay 0.2s allow-discrete,
5434
5748
  opacity 0.2s var(--ease-out-1);
5435
5749
 
@@ -5456,179 +5770,178 @@ Lists meant to be used stand-alone or as part of Select elements
5456
5770
  }
5457
5771
 
5458
5772
  @layer components.root {
5459
- :where(dialog.ui-drawer) {
5460
- --_backdrop-bg-color: transparent;
5461
- --_backdrop-blur: blur(2px);
5462
- --_bg-color: var(--surface-default);
5463
- --_block-size: min(80vb, 650px);
5464
- --_border-color: var(--border-color);
5465
- --_border-width: var(--border-width);
5466
- --_color: var(--text-primary);
5467
- --_content-padding: var(--size-4);
5468
- --_footer-gap: var(--size-3);
5469
- --_footer-padding: var(--size-3);
5470
- --_header-font-size: var(--font-size-3);
5471
- --_header-padding: var(--size-3);
5472
- --_inline-size: min(375px, 100vi);
5473
- --_shadow: var(--shadow-2);
5474
- --_transition-duration: 0.2s;
5475
- --_transition-timing: var(--ease-out-3);
5476
-
5477
- background-color: var(--_bg-color);
5478
- border: none;
5479
- box-shadow: var(--_shadow);
5480
- color: var(--_color);
5481
- display: flex;
5482
- flex-direction: column;
5483
- margin: 0;
5484
- max-inline-size: 100%;
5485
- padding: 0;
5486
- position: fixed;
5487
- transition:
5488
- display var(--_transition-duration) allow-discrete,
5489
- overlay var(--_transition-duration) allow-discrete,
5490
- translate var(--_transition-duration) var(--_transition-timing);
5491
- z-index: 1000;
5492
-
5493
- &::backdrop {
5494
- backdrop-filter: var(--_backdrop-blur);
5495
- background-color: var(--_backdrop-bg-color);
5496
- opacity: 0;
5497
- transition:
5498
- display var(--_transition-duration) allow-discrete,
5499
- overlay var(--_transition-duration) allow-discrete,
5500
- opacity var(--_transition-duration) var(--_transition-timing);
5501
- }
5502
-
5503
- &.ui-backdrop-transparent {
5504
- --_backdrop-blur: none;
5505
- }
5506
-
5507
- .ui-header {
5508
- align-items: center;
5509
- border-block-end: var(--_border-width) solid var(--_border-color);
5510
- display: flex;
5511
- padding: var(--_header-padding);
5512
-
5513
- :where(h1, h2, h3, h4, h5, h6) {
5514
- font-size: var(--_header-font-size);
5515
- margin: 0;
5516
- }
5517
-
5518
- :where(.ui-icon-button) {
5519
- margin-inline-start: auto;
5520
- }
5521
- }
5522
-
5523
- .ui-content {
5524
- flex: 1;
5525
- overflow-y: auto;
5526
- padding: var(--_content-padding);
5527
- }
5528
-
5529
- .ui-footer {
5530
- border-block-start: var(--_border-width) solid var(--_border-color);
5531
- display: flex;
5532
- gap: var(--_footer-gap);
5533
- justify-content: end;
5534
- padding: var(--_footer-padding);
5535
- }
5536
-
5537
- &.ui-inline-start,
5538
- &.ui-inline-end {
5539
- block-size: 100dvb;
5540
- inline-size: var(--_inline-size);
5541
- inset-block: 0;
5542
- max-block-size: 100%;
5543
- }
5544
-
5545
- &.ui-inline-start {
5546
- border-inline-end: var(--_border-width) solid var(--_border-color);
5547
- inset-inline-end: auto;
5548
- inset-inline-start: 0;
5549
- translate: -100% 0;
5550
- }
5551
-
5552
- &.ui-inline-end {
5553
- border-inline-start: var(--_border-width) solid var(--_border-color);
5554
- inset-inline-end: 0;
5555
- inset-inline-start: auto;
5556
- translate: 100% 0;
5557
-
5558
- .ui-footer {
5559
- justify-content: start;
5560
- }
5561
- }
5562
-
5563
- &.ui-block-start,
5564
- &.ui-block-end {
5565
- block-size: var(--_block-size);
5566
- inline-size: 100dvi;
5567
- inset-inline: 0;
5568
- max-block-size: 80dvb;
5569
- }
5570
-
5571
- &.ui-block-start {
5572
- border-block-end: var(--_border-width) solid var(--_border-color);
5573
- inset-block-end: auto;
5574
- inset-block-start: 0;
5575
- translate: 0 -100%;
5576
- }
5577
-
5578
- &.ui-block-end {
5579
- border-block-start: var(--_border-width) solid var(--_border-color);
5580
- inset-block-end: 0;
5581
- inset-block-start: auto;
5582
- translate: 0 100%;
5583
- }
5584
-
5585
- &[open] {
5586
- translate: 0 0;
5587
-
5588
- &::backdrop {
5589
- opacity: 1;
5590
- }
5591
-
5592
- @starting-style {
5593
- &::backdrop {
5594
- opacity: 0;
5595
- }
5596
-
5597
- &.ui-inline-start {
5598
- translate: -100% 0;
5599
- }
5600
-
5601
- &.ui-inline-end {
5602
- translate: 100% 0;
5603
- }
5604
-
5605
- &.ui-block-start {
5606
- translate: 0 -100%;
5607
- }
5608
-
5609
- &.ui-block-end {
5610
- translate: 0 100%;
5611
- }
5612
- }
5613
- }
5614
- }
5615
-
5616
- /* Scroll-lock is provided by the shared `.ui-scroll-lock` utility in core/utils.css.
5773
+ :where(dialog.ui-drawer) {
5774
+ --_backdrop-bg-color: transparent;
5775
+ --_backdrop-blur: blur(2px);
5776
+ --_bg-color: var(--surface-default);
5777
+ --_block-size: min(80vb, 650px);
5778
+ --_border-color: var(--border-color);
5779
+ --_border-width: var(--border-width);
5780
+ --_color: var(--text-primary);
5781
+ --_content-padding: var(--size-4);
5782
+ --_footer-gap: var(--size-3);
5783
+ --_footer-padding: var(--size-3);
5784
+ --_header-font-size: var(--font-size-3);
5785
+ --_header-padding: var(--size-3);
5786
+ --_inline-size: min(375px, 100vi);
5787
+ --_shadow: var(--shadow-2);
5788
+ --_transition-duration: 0.2s;
5789
+ --_transition-timing: var(--ease-out-3);
5790
+
5791
+ background-color: var(--_bg-color);
5792
+ border: none;
5793
+ box-shadow: var(--_shadow);
5794
+ color: var(--_color);
5795
+ display: flex;
5796
+ flex-direction: column;
5797
+ margin: 0;
5798
+ max-inline-size: 100%;
5799
+ padding: 0;
5800
+ position: fixed;
5801
+ transition:
5802
+ display var(--_transition-duration) allow-discrete,
5803
+ overlay var(--_transition-duration) allow-discrete,
5804
+ translate var(--_transition-duration) var(--_transition-timing);
5805
+ z-index: 1000;
5806
+
5807
+ &::backdrop {
5808
+ backdrop-filter: var(--_backdrop-blur);
5809
+ background-color: var(--_backdrop-bg-color);
5810
+ opacity: 0;
5811
+ transition:
5812
+ display var(--_transition-duration) allow-discrete,
5813
+ overlay var(--_transition-duration) allow-discrete,
5814
+ opacity var(--_transition-duration) var(--_transition-timing);
5815
+ }
5816
+
5817
+ &.ui-backdrop-transparent {
5818
+ --_backdrop-blur: none;
5819
+ }
5820
+
5821
+ .ui-header {
5822
+ align-items: center;
5823
+ border-block-end: var(--_border-width) solid var(--_border-color);
5824
+ display: flex;
5825
+ padding: var(--_header-padding);
5826
+
5827
+ :where(h1, h2, h3, h4, h5, h6) {
5828
+ font-size: var(--_header-font-size);
5829
+ margin: 0;
5830
+ }
5831
+
5832
+ :where(.ui-icon-button) {
5833
+ margin-inline-start: auto;
5834
+ }
5835
+ }
5836
+
5837
+ .ui-content {
5838
+ flex: 1;
5839
+ overflow-y: auto;
5840
+ padding: var(--_content-padding);
5841
+ }
5842
+
5843
+ .ui-footer {
5844
+ border-block-start: var(--_border-width) solid var(--_border-color);
5845
+ display: flex;
5846
+ gap: var(--_footer-gap);
5847
+ justify-content: end;
5848
+ padding: var(--_footer-padding);
5849
+ }
5850
+
5851
+ &.ui-inline-start,
5852
+ &.ui-inline-end {
5853
+ block-size: 100dvb;
5854
+ inline-size: var(--_inline-size);
5855
+ inset-block: 0;
5856
+ max-block-size: 100%;
5857
+ }
5858
+
5859
+ &.ui-inline-start {
5860
+ border-inline-end: var(--_border-width) solid var(--_border-color);
5861
+ inset-inline-end: auto;
5862
+ inset-inline-start: 0;
5863
+ translate: -100% 0;
5864
+ }
5865
+
5866
+ &.ui-inline-end {
5867
+ border-inline-start: var(--_border-width) solid var(--_border-color);
5868
+ inset-inline-end: 0;
5869
+ inset-inline-start: auto;
5870
+ translate: 100% 0;
5871
+
5872
+ .ui-footer {
5873
+ justify-content: start;
5874
+ }
5875
+ }
5876
+
5877
+ &.ui-block-start,
5878
+ &.ui-block-end {
5879
+ block-size: var(--_block-size);
5880
+ inline-size: 100dvi;
5881
+ inset-inline: 0;
5882
+ max-block-size: 80dvb;
5883
+ }
5884
+
5885
+ &.ui-block-start {
5886
+ border-block-end: var(--_border-width) solid var(--_border-color);
5887
+ inset-block-end: auto;
5888
+ inset-block-start: 0;
5889
+ translate: 0 -100%;
5890
+ }
5891
+
5892
+ &.ui-block-end {
5893
+ border-block-start: var(--_border-width) solid var(--_border-color);
5894
+ inset-block-end: 0;
5895
+ inset-block-start: auto;
5896
+ translate: 0 100%;
5897
+ }
5898
+
5899
+ &[open] {
5900
+ translate: 0 0;
5901
+
5902
+ &::backdrop {
5903
+ opacity: 1;
5904
+ }
5905
+
5906
+ @starting-style {
5907
+ &::backdrop {
5908
+ opacity: 0;
5909
+ }
5910
+
5911
+ &.ui-inline-start {
5912
+ translate: -100% 0;
5913
+ }
5914
+
5915
+ &.ui-inline-end {
5916
+ translate: 100% 0;
5917
+ }
5918
+
5919
+ &.ui-block-start {
5920
+ translate: 0 -100%;
5921
+ }
5922
+
5923
+ &.ui-block-end {
5924
+ translate: 0 100%;
5925
+ }
5926
+ }
5927
+ }
5928
+ }
5929
+
5930
+ /* Scroll-lock is provided by the shared `.ui-scroll-lock` utility in core/utils.css.
5617
5931
  This carve-out re-enables page scrolling when a transparent-backdrop drawer is
5618
5932
  open on wide viewports (where the drawer doesn't visually cover the page). */
5619
- html:has(dialog.ui-drawer.ui-scroll-lock[open].ui-backdrop-transparent) {
5620
- overflow: unset;
5621
- overscroll-behavior: auto;
5622
-
5623
- @media (width < 500px) {
5624
- overflow: clip;
5625
- overscroll-behavior: contain;
5626
- }
5627
- }
5933
+ html:has(dialog.ui-drawer.ui-scroll-lock[open].ui-backdrop-transparent) {
5934
+ overflow: unset;
5935
+ overscroll-behavior: auto;
5936
+
5937
+ @media (width < 500px) {
5938
+ overflow: clip;
5939
+ overscroll-behavior: contain;
5940
+ }
5941
+ }
5628
5942
  }
5629
5943
 
5630
5944
  @layer components.extended {
5631
-
5632
5945
  /* Form */
5633
5946
  :where(.ui-form) {
5634
5947
  display: grid;
@@ -5700,21 +6013,21 @@ Lists meant to be used stand-alone or as part of Select elements
5700
6013
  /* Error / validation */
5701
6014
  &[data-invalid] {
5702
6015
  :where(.ui-end-text) {
5703
- color: var(--primary);
6016
+ color: var(--critical);
5704
6017
  }
5705
6018
 
5706
6019
  :where(.ui-checkbox, .ui-radio, .ui-switch) {
5707
- --palette-source: oklch(0.58 0.21 var(--hue-red));
6020
+ --primary: var(--critical);
5708
6021
 
5709
6022
  :where(.ui-end-text) {
5710
- color: var(--primary);
6023
+ color: var(--critical);
5711
6024
  }
5712
6025
  }
5713
6026
 
5714
6027
  :where(.ui-switch) {
5715
6028
  input {
5716
6029
  border-radius: var(--radius-round);
5717
- outline: 2px solid var(--primary);
6030
+ outline: 2px solid var(--critical);
5718
6031
  }
5719
6032
  }
5720
6033
  }
@@ -5742,7 +6055,9 @@ Lists meant to be used stand-alone or as part of Select elements
5742
6055
  gap: var(--size-4);
5743
6056
 
5744
6057
  /* If it only has checkboxes, radios, or switches */
5745
- &:has(> :where(.ui-checkbox, .ui-radio, .ui-switch)):not(:has(> :not(.ui-checkbox, .ui-radio, .ui-switch))) {
6058
+ &:has(> :where(.ui-checkbox, .ui-radio, .ui-switch)):not(
6059
+ :has(> :not(.ui-checkbox, .ui-radio, .ui-switch))
6060
+ ) {
5746
6061
  gap: var(--size-2);
5747
6062
  }
5748
6063
 
@@ -5758,7 +6073,7 @@ Lists meant to be used stand-alone or as part of Select elements
5758
6073
  }
5759
6074
  }
5760
6075
 
5761
- &+& {
6076
+ & + & {
5762
6077
  margin-block-start: var(--size-5);
5763
6078
  }
5764
6079
 
@@ -5775,7 +6090,6 @@ Lists meant to be used stand-alone or as part of Select elements
5775
6090
  }
5776
6091
 
5777
6092
  @layer components.extended {
5778
-
5779
6093
  /*
5780
6094
  - Common styling for input, textarea and select
5781
6095
  - Form related styles such as: label, supporting text, error handling
@@ -5882,7 +6196,6 @@ Lists meant to be used stand-alone or as part of Select elements
5882
6196
 
5883
6197
  /* Textarea - keep affix aligned with the first line */
5884
6198
  &.ui-textarea .ui-field {
5885
-
5886
6199
  .ui-prefix,
5887
6200
  .ui-suffix {
5888
6201
  align-self: start;
@@ -5929,7 +6242,6 @@ Lists meant to be used stand-alone or as part of Select elements
5929
6242
  /* Variants */
5930
6243
  &.ui-filled {
5931
6244
  input {
5932
-
5933
6245
  &::-webkit-file-upload-button,
5934
6246
  &::file-selector-button {
5935
6247
  background-color: var(--surface-default);
@@ -5968,7 +6280,6 @@ Lists meant to be used stand-alone or as part of Select elements
5968
6280
  .ui-label {
5969
6281
  /* Make sure chevron is visible */
5970
6282
  inline-size: calc(100% - var(--size-6));
5971
-
5972
6283
  }
5973
6284
  }
5974
6285
 
@@ -5979,7 +6290,8 @@ Lists meant to be used stand-alone or as part of Select elements
5979
6290
 
5980
6291
  button {
5981
6292
  outline: 0;
5982
- padding: var(--_field-padding-block) var(--size-8) var(--_field-padding-block) var(--_field-padding-inline);
6293
+ padding: var(--_field-padding-block) var(--size-8)
6294
+ var(--_field-padding-block) var(--_field-padding-inline);
5983
6295
  }
5984
6296
  }
5985
6297
  }
@@ -5987,7 +6299,8 @@ Lists meant to be used stand-alone or as part of Select elements
5987
6299
  /* Non-customizable Select */
5988
6300
  &:has(select):not(:has(button)) {
5989
6301
  select {
5990
- padding: var(--_field-padding-block) var(--size-8) var(--_field-padding-block) var(--_field-padding-inline);
6302
+ padding: var(--_field-padding-block) var(--size-8)
6303
+ var(--_field-padding-block) var(--_field-padding-inline);
5991
6304
  }
5992
6305
  }
5993
6306
 
@@ -6085,11 +6398,12 @@ Lists meant to be used stand-alone or as part of Select elements
6085
6398
  --_bg-color: var(--surface-tonal);
6086
6399
 
6087
6400
  &:not(:has([disabled], :has(input[type="color"]))) {
6088
-
6089
6401
  /* Hover */
6090
6402
  &:hover {
6091
- --_bg-color: light-dark(oklch(from var(--surface-tonal) calc(l * 0.93) c h),
6092
- oklch(from var(--surface-tonal) calc(l * 1.1) c h));
6403
+ --_bg-color: light-dark(
6404
+ oklch(from var(--surface-tonal) calc(l * 0.93) c h),
6405
+ oklch(from var(--surface-tonal) calc(l * 1.1) c h)
6406
+ );
6093
6407
  }
6094
6408
  }
6095
6409
  }
@@ -6180,7 +6494,7 @@ Lists meant to be used stand-alone or as part of Select elements
6180
6494
  .ui-field:has(textarea) {
6181
6495
  grid-row: 1 / span 3;
6182
6496
 
6183
- +.ui-end-text {
6497
+ + .ui-end-text {
6184
6498
  grid-row: 4;
6185
6499
  }
6186
6500
  }
@@ -6265,8 +6579,11 @@ Lists meant to be used stand-alone or as part of Select elements
6265
6579
  }
6266
6580
 
6267
6581
  @media (prefers-reduced-motion: no-preference) {
6268
- transition: display 0.2s allow-discrete, opacity 0.2s var(--ease-3),
6269
- overlay 0.2s allow-discrete, scale 0.2s var(--ease-3);
6582
+ transition:
6583
+ display 0.2s allow-discrete,
6584
+ opacity 0.2s var(--ease-3),
6585
+ overlay 0.2s allow-discrete,
6586
+ scale 0.2s var(--ease-3);
6270
6587
  }
6271
6588
  }
6272
6589
 
@@ -6300,8 +6617,10 @@ Lists meant to be used stand-alone or as part of Select elements
6300
6617
  [role="group"] {
6301
6618
  label {
6302
6619
  background-color: light-dark(var(--gray-3), var(--gray-13));
6303
- color: light-dark(oklch(from var(--text-primary) calc(l * 0.75) c h),
6304
- oklch(from var(--text-primary) calc(l * 1.25) c h));
6620
+ color: light-dark(
6621
+ oklch(from var(--text-primary) calc(l * 0.75) c h),
6622
+ oklch(from var(--text-primary) calc(l * 1.25) c h)
6623
+ );
6305
6624
  font-weight: 500;
6306
6625
  overflow: hidden;
6307
6626
  padding-inline: var(--size-2);
@@ -6324,7 +6643,6 @@ Lists meant to be used stand-alone or as part of Select elements
6324
6643
 
6325
6644
  /* Option */
6326
6645
  option {
6327
-
6328
6646
  /* Checkmark */
6329
6647
  /* TODO - checkmark should be the final version of the checkmark API. Follow the development of this and remove redundant psuedo stuff. */
6330
6648
  &::check {
@@ -6347,7 +6665,6 @@ Lists meant to be used stand-alone or as part of Select elements
6347
6665
  }
6348
6666
 
6349
6667
  :where(.ui-select:has(select)) {
6350
-
6351
6668
  /* Size */
6352
6669
  &.ui-small {
6353
6670
  button {
@@ -6396,8 +6713,10 @@ Lists meant to be used stand-alone or as part of Select elements
6396
6713
  }
6397
6714
 
6398
6715
  @layer components.extended {
6399
-
6400
- :where(.ui-text-field:has( :where(input[type="date"],
6716
+ :where(
6717
+ .ui-text-field:has(
6718
+ :where(
6719
+ input[type="date"],
6401
6720
  input[type="datetime-local"],
6402
6721
  input[type="email"],
6403
6722
  input[type="month"],
@@ -6408,8 +6727,10 @@ Lists meant to be used stand-alone or as part of Select elements
6408
6727
  input[type="text"],
6409
6728
  input[type="time"],
6410
6729
  input[type="url"],
6411
- input[type="week"]))) {
6412
-
6730
+ input[type="week"]
6731
+ )
6732
+ )
6733
+ ) {
6413
6734
  /* Sizes */
6414
6735
  &.ui-small {
6415
6736
  input {
@@ -6465,7 +6786,9 @@ Lists meant to be used stand-alone or as part of Select elements
6465
6786
  textarea {
6466
6787
  block-size: auto;
6467
6788
  field-sizing: content;
6468
- min-block-size: calc(var(--_field-padding-block) * 2 + (var(--border-width) * 2) + 3lh);
6789
+ min-block-size: calc(
6790
+ var(--_field-padding-block) * 2 + (var(--border-width) * 2) + 3lh
6791
+ );
6469
6792
  resize: vertical;
6470
6793
  }
6471
6794
 
@@ -6486,77 +6809,79 @@ Lists meant to be used stand-alone or as part of Select elements
6486
6809
  }
6487
6810
 
6488
6811
  @layer components.extended {
6489
- :where(.ui-tooltip) {
6490
- --_tooltip-bg: light-dark(var(--gray-13), var(--gray-3));
6491
- --_tooltip-color: light-dark(var(--gray-1), var(--gray-15));
6492
- --_tooltip-offset: var(--size-2);
6493
-
6494
- &>.ui-anchor-floating {
6495
- background-color: var(--_tooltip-bg);
6496
- border-radius: var(--radius-2);
6497
- color: var(--_tooltip-color);
6498
- font-size: var(--font-size-05);
6499
- line-height: 1.3;
6500
- margin: var(--_tooltip-offset);
6501
- max-inline-size: 240px;
6502
- /* UA sets overflow: auto on [popover], which clips the arrow. */
6503
- overflow: visible;
6504
- padding-block: var(--size-1);
6505
- padding-inline: var(--size-2);
6506
- position-area: var(--anchor-position-area, block-start);
6507
- position-try-fallbacks: flip-block, flip-inline, flip-block flip-inline;
6508
- position-visibility: anchors-visible;
6509
- text-align: center;
6510
- text-wrap: pretty;
6511
- }
6512
-
6513
- /* Optional arrow pointing from the tooltip toward the trigger.
6812
+ :where(.ui-tooltip) {
6813
+ --_tooltip-bg: light-dark(var(--gray-13), var(--gray-3));
6814
+ --_tooltip-color: light-dark(var(--gray-1), var(--gray-15));
6815
+ --_tooltip-offset: var(--size-2);
6816
+
6817
+ & > .ui-anchor-floating {
6818
+ background-color: var(--_tooltip-bg);
6819
+ border-radius: var(--radius-2);
6820
+ color: var(--_tooltip-color);
6821
+ font-size: var(--font-size-05);
6822
+ line-height: 1.3;
6823
+ margin: var(--_tooltip-offset);
6824
+ max-inline-size: 240px;
6825
+ /* UA sets overflow: auto on [popover], which clips the arrow. */
6826
+ overflow: visible;
6827
+ padding-block: var(--size-1);
6828
+ padding-inline: var(--size-2);
6829
+ position-area: var(--anchor-position-area, block-start);
6830
+ position-try-fallbacks:
6831
+ flip-block,
6832
+ flip-inline,
6833
+ flip-block flip-inline;
6834
+ position-visibility: anchors-visible;
6835
+ text-align: center;
6836
+ text-wrap: pretty;
6837
+ }
6838
+
6839
+ /* Optional arrow pointing from the tooltip toward the trigger.
6514
6840
  Anchored to the same --anchor so it flips together with the
6515
6841
  tooltip when position-try-fallbacks kicks in. */
6516
- &.ui-with-arrow {
6517
- --_arrow-size: var(--size-2);
6518
-
6519
- &>.ui-anchor-floating {
6520
- /* Reserve space so the arrow doesn't overlap the trigger. */
6521
- --_tooltip-offset: calc(var(--size-2) + var(--_arrow-size) / 2);
6522
- }
6523
-
6524
- &>.ui-anchor-floating::before {
6525
- background-color: var(--_tooltip-bg);
6526
- block-size: var(--_arrow-size);
6527
- content: "";
6528
- inline-size: var(--_arrow-size);
6529
- inset-block-end: calc(var(--_arrow-size) / -2);
6530
- inset-inline-start: 50%;
6531
- position: absolute;
6532
- rotate: 45deg;
6533
- translate: -50% 0;
6534
- }
6535
- }
6536
-
6537
- /* Fade */
6538
- &>.ui-anchor-floating[popover] {
6539
- opacity: 0;
6540
- transition:
6541
- display 0.15s allow-discrete,
6542
- opacity 0.15s var(--ease-out-1),
6543
- overlay 0.15s allow-discrete;
6544
-
6545
- &:popover-open {
6546
- opacity: 1;
6547
-
6548
- @starting-style {
6549
- opacity: 0;
6550
- }
6551
- }
6552
- }
6553
- }
6842
+ &.ui-with-arrow {
6843
+ --_arrow-size: var(--size-2);
6844
+
6845
+ & > .ui-anchor-floating {
6846
+ /* Reserve space so the arrow doesn't overlap the trigger. */
6847
+ --_tooltip-offset: calc(var(--size-2) + var(--_arrow-size) / 2);
6848
+ }
6849
+
6850
+ & > .ui-anchor-floating::before {
6851
+ background-color: var(--_tooltip-bg);
6852
+ block-size: var(--_arrow-size);
6853
+ content: "";
6854
+ inline-size: var(--_arrow-size);
6855
+ inset-block-end: calc(var(--_arrow-size) / -2);
6856
+ inset-inline-start: 50%;
6857
+ position: absolute;
6858
+ rotate: 45deg;
6859
+ translate: -50% 0;
6860
+ }
6861
+ }
6862
+
6863
+ /* Fade */
6864
+ & > .ui-anchor-floating[popover] {
6865
+ opacity: 0;
6866
+ transition:
6867
+ display 0.15s allow-discrete,
6868
+ opacity 0.15s var(--ease-out-1),
6869
+ overlay 0.15s allow-discrete;
6870
+
6871
+ &:popover-open {
6872
+ opacity: 1;
6873
+
6874
+ @starting-style {
6875
+ opacity: 0;
6876
+ }
6877
+ }
6878
+ }
6879
+ }
6554
6880
  }
6555
6881
 
6556
6882
  /* Utils */
6557
6883
 
6558
6884
  @layer utils {
6559
-
6560
6885
  /*
6561
6886
  Screen-reader only
6562
6887
  When you visibly want to hide an element but make it accessible for screen readers.
@@ -6616,7 +6941,8 @@ Add `.ui-scroll-lock` to any element that uses the [open] attribute (native <dia
6616
6941
  inset-inline-start: 50%;
6617
6942
  position: absolute;
6618
6943
  transform-origin: center center;
6619
- transform: translateX(calc(var(--isRTL) * 50%)) translateY(-50%) translateZ(-1px) scale(var(--thumb-scale));
6944
+ transform: translateX(calc(var(--isRTL) * 50%)) translateY(-50%)
6945
+ translateZ(-1px) scale(var(--thumb-scale));
6620
6946
  will-change: transform;
6621
6947
 
6622
6948
  @media (prefers-reduced-motion: no-preference) {