@slotted/styles 0.1.0-beta.3 → 0.1.0-beta.31

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 (205) hide show
  1. package/package.json +13 -1
  2. package/src/accordion/accordion.css +11 -11
  3. package/src/action-bar/action-bar.css +47 -44
  4. package/src/action-bar/action-bar.tokens.json +1 -0
  5. package/src/action-sheet/action-sheet.css +39 -39
  6. package/src/alert/alert.css +97 -97
  7. package/src/alert/alert.tokens.json +6 -1
  8. package/src/app-shell/app-shell.css +456 -329
  9. package/src/app-shell/app-shell.tokens.json +6 -3
  10. package/src/aspect-ratio/aspect-ratio.css +9 -9
  11. package/src/attachment/attachment.css +118 -114
  12. package/src/avatar/avatar.css +96 -66
  13. package/src/avatar/avatar.tokens.json +7 -0
  14. package/src/avatar-group/avatar-group.css +22 -23
  15. package/src/badge/badge.css +54 -46
  16. package/src/badge/badge.tokens.json +5 -0
  17. package/src/breadcrumb/breadcrumb.css +52 -52
  18. package/src/button/button.css +137 -89
  19. package/src/button/button.tokens.json +5 -0
  20. package/src/button-group/button-group.css +80 -79
  21. package/src/button-group/button-group.tokens.json +1 -0
  22. package/src/calendar/calendar.css +139 -109
  23. package/src/calendar/calendar.tokens.json +5 -1
  24. package/src/card/card.css +70 -67
  25. package/src/card/card.tokens.json +1 -0
  26. package/src/carousel/carousel.css +158 -169
  27. package/src/cascader/cascader.css +161 -159
  28. package/src/cascader/cascader.tokens.json +2 -0
  29. package/src/chart/chart.css +288 -267
  30. package/src/chart/chart.tokens.json +4 -0
  31. package/src/checkbox/checkbox.css +143 -148
  32. package/src/checkbox-group/checkbox-group.css +7 -7
  33. package/src/code-block/code-block.css +85 -89
  34. package/src/collapsible/collapsible.css +81 -80
  35. package/src/collapsible/collapsible.tokens.json +1 -0
  36. package/src/color-picker/color-picker.css +106 -114
  37. package/src/column-manager/column-manager.css +111 -119
  38. package/src/combobox/combobox.css +206 -132
  39. package/src/combobox/combobox.tokens.json +4 -0
  40. package/src/command-palette/command-palette.css +155 -102
  41. package/src/command-palette/command-palette.tokens.json +2 -0
  42. package/src/container/container.css +27 -27
  43. package/src/context-menu/context-menu.css +9 -9
  44. package/src/currency-field/currency-field.css +119 -119
  45. package/src/currency-field/currency-field.tokens.json +1 -0
  46. package/src/dashboard-grid/dashboard-grid.css +204 -115
  47. package/src/data-grid/data-grid.css +598 -496
  48. package/src/data-grid/data-grid.tokens.json +5 -1
  49. package/src/data-list/data-list.css +82 -71
  50. package/src/data-list/data-list.tokens.json +2 -1
  51. package/src/date-field/date-field.css +62 -57
  52. package/src/date-field/date-field.tokens.json +1 -0
  53. package/src/date-picker/date-picker.css +117 -58
  54. package/src/date-picker/date-picker.tokens.json +5 -0
  55. package/src/date-range-picker/date-range-picker.css +157 -127
  56. package/src/date-range-picker/date-range-picker.tokens.json +4 -0
  57. package/src/datetime-field/datetime-field.css +90 -90
  58. package/src/datetime-field/datetime-field.tokens.json +1 -0
  59. package/src/datetime-picker/datetime-picker.css +123 -70
  60. package/src/datetime-picker/datetime-picker.tokens.json +4 -1
  61. package/src/datetime-range-picker/datetime-range-picker.css +191 -163
  62. package/src/datetime-range-picker/datetime-range-picker.tokens.json +4 -0
  63. package/src/description-list/description-list.css +105 -75
  64. package/src/description-list/description-list.tokens.json +1 -0
  65. package/src/detail-panel/detail-panel.css +86 -71
  66. package/src/detail-panel/detail-panel.tokens.json +2 -0
  67. package/src/dialog/dialog.css +435 -199
  68. package/src/dialog/dialog.tokens.json +9 -0
  69. package/src/divider/divider.css +20 -20
  70. package/src/drawer/drawer.css +598 -237
  71. package/src/drawer/drawer.tokens.json +14 -0
  72. package/src/entity-picker/entity-picker.css +326 -272
  73. package/src/entity-picker/entity-picker.tokens.json +4 -0
  74. package/src/event-calendar/event-calendar.css +357 -399
  75. package/src/field/field.css +106 -93
  76. package/src/field/field.tokens.json +2 -0
  77. package/src/field-group/field-group.css +43 -33
  78. package/src/field-group/field-group.tokens.json +3 -0
  79. package/src/filter-bar/filter-bar.css +200 -216
  80. package/src/form/form.css +100 -26
  81. package/src/form/form.tokens.json +6 -1
  82. package/src/fullscreen/fullscreen.css +26 -27
  83. package/src/grid/grid.css +29 -29
  84. package/src/highlight/highlight.css +11 -11
  85. package/src/hover-card/hover-card.css +9 -9
  86. package/src/icon/icon.css +67 -20
  87. package/src/icon/icon.tokens.json +1 -0
  88. package/src/image/image.css +42 -42
  89. package/src/import-export-center/import-export-center.css +147 -168
  90. package/src/import-export-center/import-export-center.tokens.json +1 -0
  91. package/src/inline/inline.css +28 -28
  92. package/src/inline-message/inline-message.css +162 -86
  93. package/src/inline-message/inline-message.tokens.json +4 -0
  94. package/src/kbd/kbd.css +62 -50
  95. package/src/kbd/kbd.tokens.json +3 -0
  96. package/src/link/link.css +54 -33
  97. package/src/link/link.tokens.json +4 -0
  98. package/src/list/list.css +23 -23
  99. package/src/list-item/list-item.css +89 -75
  100. package/src/list-item/list-item.tokens.json +7 -0
  101. package/src/listbox/listbox.css +71 -70
  102. package/src/listbox/listbox.tokens.json +0 -1
  103. package/src/loading-overlay/loading-overlay.css +86 -103
  104. package/src/markdown/markdown.css +20 -20
  105. package/src/media-viewer/media-viewer.css +790 -0
  106. package/src/media-viewer/media-viewer.tokens.json +53 -0
  107. package/src/menu/menu.css +166 -83
  108. package/src/menu/menu.tokens.json +3 -1
  109. package/src/menubar/menubar.css +16 -16
  110. package/src/message/message.css +1253 -1246
  111. package/src/message/message.tokens.json +5 -0
  112. package/src/message-scroller/message-scroller.css +323 -320
  113. package/src/multi-select/multi-select.css +233 -174
  114. package/src/multi-select/multi-select.tokens.json +3 -0
  115. package/src/navigation-menu/navigation-menu.css +170 -191
  116. package/src/navigation-menu/navigation-menu.tokens.json +1 -0
  117. package/src/notification-center/notification-center.css +155 -163
  118. package/src/notification-center/notification-center.tokens.json +4 -0
  119. package/src/number-field/number-field.css +93 -93
  120. package/src/number-field/number-field.tokens.json +1 -0
  121. package/src/otp-input/otp-input.css +74 -64
  122. package/src/otp-input/otp-input.tokens.json +1 -0
  123. package/src/page/page.css +41 -27
  124. package/src/page/page.tokens.json +1 -0
  125. package/src/page-header/page-header.css +342 -287
  126. package/src/page-header/page-header.tokens.json +6 -1
  127. package/src/pagination/pagination.css +75 -79
  128. package/src/popover/popover.css +85 -65
  129. package/src/popover/popover.tokens.json +2 -0
  130. package/src/progress-indicator/progress-indicator.css +192 -136
  131. package/src/progress-indicator/progress-indicator.tokens.json +1 -0
  132. package/src/prompt-composer/prompt-composer.css +260 -113
  133. package/src/prompt-composer/prompt-composer.tokens.json +15 -0
  134. package/src/prose/prose.css +77 -82
  135. package/src/radio-group/radio-group.css +107 -112
  136. package/src/rating/rating.css +146 -142
  137. package/src/rating/rating.tokens.json +1 -0
  138. package/src/result-state/result-state.css +95 -102
  139. package/src/result-state/result-state.tokens.json +1 -0
  140. package/src/runtime-properties.mjs +19 -6
  141. package/src/saved-views/saved-views.css +43 -49
  142. package/src/scroll-area/scroll-area.css +50 -37
  143. package/src/section/section.css +179 -44
  144. package/src/section/section.tokens.json +9 -3
  145. package/src/segmented-control/segmented-control.css +210 -133
  146. package/src/segmented-control/segmented-control.tokens.json +7 -11
  147. package/src/select/select.css +213 -149
  148. package/src/select/select.tokens.json +4 -0
  149. package/src/side-navigation/side-navigation.css +201 -198
  150. package/src/side-navigation/side-navigation.tokens.json +1 -0
  151. package/src/skeleton/skeleton.css +57 -58
  152. package/src/slider/slider.css +101 -103
  153. package/src/sparkline/sparkline.css +75 -53
  154. package/src/sparkline/sparkline.tokens.json +2 -0
  155. package/src/spinner/spinner.css +83 -180
  156. package/src/spinner/spinner.tokens.json +0 -1
  157. package/src/split-button/split-button.css +34 -35
  158. package/src/split-button/split-button.tokens.json +1 -0
  159. package/src/splitter/splitter.css +47 -48
  160. package/src/stack/stack.css +25 -25
  161. package/src/stat-card/stat-card.css +415 -245
  162. package/src/stat-card/stat-card.tokens.json +8 -0
  163. package/src/status-indicator/status-indicator.css +124 -100
  164. package/src/status-indicator/status-indicator.tokens.json +0 -3
  165. package/src/stepper/stepper.css +78 -82
  166. package/src/switch/switch.css +100 -106
  167. package/src/table/table.css +270 -198
  168. package/src/table/table.tokens.json +2 -0
  169. package/src/table-of-contents/table-of-contents.css +60 -59
  170. package/src/table-of-contents/table-of-contents.tokens.json +1 -0
  171. package/src/tabs/tabs.css +327 -294
  172. package/src/tabs/tabs.tokens.json +7 -1
  173. package/src/tag/tag.css +109 -88
  174. package/src/tag/tag.tokens.json +10 -0
  175. package/src/tags-input/tags-input.css +152 -87
  176. package/src/tags-input/tags-input.tokens.json +7 -1
  177. package/src/text-field/text-field.css +146 -148
  178. package/src/text-field/text-field.tokens.json +1 -0
  179. package/src/textarea/textarea.css +38 -33
  180. package/src/textarea/textarea.tokens.json +1 -0
  181. package/src/time-field/time-field.css +82 -77
  182. package/src/time-field/time-field.tokens.json +1 -0
  183. package/src/time-picker/time-picker.css +116 -64
  184. package/src/time-picker/time-picker.tokens.json +4 -1
  185. package/src/time-range-picker/time-range-picker.css +168 -140
  186. package/src/time-range-picker/time-range-picker.tokens.json +4 -0
  187. package/src/timeline/timeline.css +280 -292
  188. package/src/timeline/timeline.tokens.json +5 -0
  189. package/src/toast/toast.css +139 -122
  190. package/src/toast/toast.tokens.json +7 -0
  191. package/src/toggle/toggle.css +34 -38
  192. package/src/toggle-group/toggle-group.css +73 -77
  193. package/src/toolbar/toolbar.css +33 -38
  194. package/src/tooltip/tooltip.css +65 -39
  195. package/src/tooltip/tooltip.tokens.json +1 -0
  196. package/src/top-navigation/top-navigation.css +252 -268
  197. package/src/tour/tour.css +68 -74
  198. package/src/tour/tour.tokens.json +1 -0
  199. package/src/transfer/transfer.css +164 -168
  200. package/src/tree/tree.css +113 -121
  201. package/src/typography/typography.css +42 -38
  202. package/src/typography/typography.tokens.json +1 -0
  203. package/src/upload/upload.css +256 -257
  204. package/src/visually-hidden/visually-hidden.css +1 -1
  205. package/src/wizard/wizard.css +187 -199
@@ -19,12 +19,12 @@
19
19
  * a field in a 240-pixel drawer has to stack while the same field in a page
20
20
  * grid stays beside its control.
21
21
  */
22
- [data-ui='field'][data-part='root'] {
22
+ [data-ui-field][data-part-root] {
23
23
  /**
24
24
  * Type, control height and glyph come from the control scales, the only
25
25
  * ones the theme restates per density, so a field in a dense table shrinks
26
26
  * whole rather than in parts. The control height is read for one reason:
27
- * the side label is centred on the control's first line, and that is the
27
+ * the side label is centerd on the control's first line, and that is the
28
28
  * only distance in the family that depends on the control's own size.
29
29
  */
30
30
  --_font-size: var(--slotted-control-font-size-md, 13px);
@@ -79,7 +79,7 @@
79
79
  }
80
80
 
81
81
  /* Every child spans the field, and the two that do not say so below. */
82
- [data-ui='field'][data-part='root'] > * {
82
+ [data-ui-field][data-part-root] > * {
83
83
  grid-column: 1 / -1;
84
84
  }
85
85
 
@@ -90,10 +90,25 @@
90
90
  * rather than the control. Nothing here paints the control, sizes its type or
91
91
  * touches its border: `text-field` owns all three.
92
92
  */
93
- [data-ui='field'] > [data-part='control'] {
93
+ [data-ui-field] > [data-part-control] {
94
94
  min-inline-size: 0;
95
95
  }
96
96
 
97
+ /**
98
+ * The width says what the field expects: the control stands no wider than
99
+ * the step, and still shrinks with a narrower field. The control is the
100
+ * child that is another family's root, or the part a consumer wrote.
101
+ */
102
+ [data-ui-field][data-part-root][data-width='short']
103
+ > :is([data-part-control], [data-ui]:not([data-ui-inline-message])) {
104
+ max-inline-size: var(--slotted-field-width-short, 6rem);
105
+ }
106
+
107
+ [data-ui-field][data-part-root][data-width='medium']
108
+ > :is([data-part-control], [data-ui]:not([data-ui-inline-message])) {
109
+ max-inline-size: var(--slotted-field-width-medium, 15rem);
110
+ }
111
+
97
112
  /* ── Size ─────────────────────────────────────────────────────────────
98
113
  *
99
114
  * Three steps, matching the control the field wraps. Fluent ships the same
@@ -101,7 +116,7 @@
101
116
  * inside it, which makes a field with no control an unsized box.
102
117
  */
103
118
 
104
- [data-ui='field'][data-part='root'][data-size='sm'] {
119
+ [data-ui-field][data-part-root][data-size='sm'] {
105
120
  --_help-glyph: max(
106
121
  var(--slotted-field-icon-size-min, 14px),
107
122
  var(--slotted-control-icon-size-sm, 14px)
@@ -111,7 +126,7 @@
111
126
  --_control-block-size: var(--slotted-control-height-sm, 30px);
112
127
  }
113
128
 
114
- [data-ui='field'][data-part='root'][data-size='md'] {
129
+ [data-ui-field][data-part-root][data-size='md'] {
115
130
  --_help-glyph: max(
116
131
  var(--slotted-field-icon-size-min, 14px),
117
132
  var(--slotted-control-icon-size-sm, 14px)
@@ -121,7 +136,7 @@
121
136
  --_control-block-size: var(--slotted-control-height-md, 34px);
122
137
  }
123
138
 
124
- [data-ui='field'][data-part='root'][data-size='lg'] {
139
+ [data-ui-field][data-part-root][data-size='lg'] {
125
140
  --_help-glyph: max(
126
141
  var(--slotted-field-icon-size-min, 14px),
127
142
  var(--slotted-control-icon-size-md, 16px)
@@ -142,8 +157,8 @@
142
157
  * line height is for a box holding one line, and a label of twelve words
143
158
  * beside a narrow control holds three.
144
159
  */
145
- [data-ui='field'] > [data-part='label'],
146
- [data-ui='field'] > [data-part='header'] > [data-part='label'] {
160
+ [data-ui-field] > [data-part-label],
161
+ [data-ui-field] > [data-part-header] > [data-part-label] {
147
162
  color: var(--slotted-field-label-color, var(--slotted-text));
148
163
  font-size: var(--_font-size);
149
164
  font-weight: var(--slotted-field-label-font-weight, var(--slotted-font-weight-medium, 500));
@@ -163,8 +178,8 @@
163
178
  * The first row is the label's, or the header's when the label has company.
164
179
  * Either spans the field when the label sits above the control.
165
180
  */
166
- [data-ui='field'] > [data-part='label'],
167
- [data-ui='field'] > [data-part='header'] {
181
+ [data-ui-field] > [data-part-label],
182
+ [data-ui-field] > [data-part-header] {
168
183
  grid-column: 1 / -1;
169
184
  grid-row: 1;
170
185
  }
@@ -175,7 +190,7 @@
175
190
  * label under it; a field without one would otherwise lose the counter's track
176
191
  * from the label's width for a part that is not there.
177
192
  */
178
- [data-ui='field'][data-part='root']:has(> [data-part='counter']) > [data-part='label'] {
193
+ [data-ui-field][data-part-root]:has(> [data-part-counter]) > [data-part-label] {
179
194
  grid-column: 1 / 3;
180
195
  }
181
196
 
@@ -189,12 +204,14 @@
189
204
  * a red asterisk is the convention every surveyed implementation follows, and
190
205
  * the field deliberately does *not* repaint the label when it is invalid: a
191
206
  * red marker on a red label is a marker nobody can see, and the error already
192
- * says the same thing in words, in colour and in a glyph.
207
+ * says the same thing in words, in color and in a glyph.
193
208
  */
194
- [data-ui='field'] > [data-part='label'] > [data-part='mark'],
195
- [data-ui='field'] > [data-part='header'] > [data-part='label'] > [data-part='mark'] {
209
+ [data-ui-field] > [data-part-label] > [data-part-mark],
210
+ [data-ui-field] > [data-part-header] > [data-part-label] > [data-part-mark] {
196
211
  color: var(--slotted-field-mark-color, var(--slotted-tone-danger-text));
197
- margin-inline-start: var(--slotted-field-mark-gap, var(--slotted-space-2, 0.25rem));
212
+ /* The distance is the space written before the mark, which the accessible
213
+ name needs as text; the token adds to it. */
214
+ margin-inline-start: var(--slotted-field-mark-gap, 0);
198
215
  /* The label breaks anywhere; the necessity word never does. `(required)`
199
216
  split across two lines as `(re` and `quired)` in the 240-pixel capture,
200
217
  because a rule for one unbreakable German noun had reached the one part
@@ -217,13 +234,13 @@
217
234
  * a qualifier rather than as two labels. `optional` writes the word only on
218
235
  * the fields a reader may skip; `words` writes both.
219
236
  */
220
- [data-ui='field']:is([data-necessity='optional'], [data-necessity='words'])
221
- > [data-part='label']
222
- > [data-part='mark'],
223
- [data-ui='field']:is([data-necessity='optional'], [data-necessity='words'])
224
- > [data-part='header']
225
- > [data-part='label']
226
- > [data-part='mark'] {
237
+ [data-ui-field]:is([data-necessity='optional'], [data-necessity='words'])
238
+ > [data-part-label]
239
+ > [data-part-mark],
240
+ [data-ui-field]:is([data-necessity='optional'], [data-necessity='words'])
241
+ > [data-part-header]
242
+ > [data-part-label]
243
+ > [data-part-mark] {
227
244
  color: var(--slotted-field-mark-text-color, var(--slotted-text-muted));
228
245
  font-size: var(--slotted-control-font-size-sm, 12px);
229
246
  font-weight: var(--slotted-font-weight-regular, 400);
@@ -234,16 +251,16 @@
234
251
  * The label row, when the label has company: the help behind an icon, an
235
252
  * indicator such as `Beta`, an action such as `Forgot password?`, and the
236
253
  * counter. ReUI writes the same row by hand in four of its examples — a
237
- * `div` with `justify-between` around the label — and centres every item in
254
+ * `div` with `justify-between` around the label — and centers every item in
238
255
  * it; here the row is a part, and it aligns its items on the label's first
239
256
  * baseline instead, so a 13-pixel label, a 12-pixel count and an emblem with
240
- * a box of its own sit on one line of text rather than on one centre.
257
+ * a box of its own sit on one line of text rather than on one center.
241
258
  *
242
259
  * The row takes the label's type, so `1lh`, `1cap` and `1ex` measured by
243
260
  * anything inside it are the label's line. It wraps: in a narrow field the
244
261
  * action and the counter move to a second line, still at its end.
245
262
  */
246
- [data-ui='field'] > [data-part='header'] {
263
+ [data-ui-field] > [data-part-header] {
247
264
  align-items: baseline;
248
265
  column-gap: var(--slotted-field-header-gap, var(--slotted-space-3, 0.375rem));
249
266
  display: flex;
@@ -253,7 +270,7 @@
253
270
  min-inline-size: 0;
254
271
  }
255
272
 
256
- [data-ui='field'] > [data-part='header'] > [data-part='label'] {
273
+ [data-ui-field] > [data-part-header] > [data-part-label] {
257
274
  flex: 0 1 auto;
258
275
  }
259
276
 
@@ -264,12 +281,12 @@
264
281
  * distance a side label keeps from its control, so a link and a number do
265
282
  * not read as one phrase.
266
283
  */
267
- [data-ui='field'] > [data-part='header'] > [data-part='action'],
268
- [data-ui='field'] > [data-part='header'] > [data-part='counter'] {
284
+ [data-ui-field] > [data-part-header] > [data-part-action],
285
+ [data-ui-field] > [data-part-header] > [data-part-counter] {
269
286
  margin-inline-start: auto;
270
287
  }
271
288
 
272
- [data-ui='field'] > [data-part='header'] > [data-part='action'] ~ [data-part='counter'] {
289
+ [data-ui-field] > [data-part-header] > [data-part-action] ~ [data-part-counter] {
273
290
  margin-inline-start: var(--slotted-space-3, 0.375rem);
274
291
  }
275
292
 
@@ -288,7 +305,7 @@
288
305
  * label's type at its own height and gives the difference back in the block
289
306
  * axis, so a field with a help icon is exactly as tall as one without. The
290
307
  * line inside it is the label's own — `font: inherit` — and a `button`
291
- * centres its content in the block axis, so the button's baseline stands
308
+ * centers its content in the block axis, so the button's baseline stands
292
309
  * where the label's does; a line as tall as the box put it 0.44 pixels lower
293
310
  * at comfortable and 0.69 at dense, and the row grew by that much. Only
294
311
  * the block axis gives it back: a negative inline margin would pull the box
@@ -299,14 +316,14 @@
299
316
  *
300
317
  * The glyph is placed on the label's text rather than on its line box: the
301
318
  * button holds one line of the label's type, and the glyph sits on that
302
- * line's baseline and centred on the band between the middle of the
319
+ * line's baseline and centerd on the band between the middle of the
303
320
  * capitals and the middle of the lowercase — `(1cap + 1ex) / 2` — the band
304
321
  * `toast` settled on (`docs/build-briefing.md`, a mark beside a line of
305
322
  * text). The first capture raised the glyph's bottom by the band less half
306
- * the glyph, which put its centre on the band's top: four pixels high, and a
323
+ * the glyph, which put its center on the band's top: four pixels high, and a
307
324
  * line box 3.3 pixels taller than the label's.
308
325
  */
309
- [data-ui='field'] > [data-part='header'] > [data-part='help'] {
326
+ [data-ui-field] > [data-part-header] > [data-part-help] {
310
327
  /* Never shorter than the label's line: at dense the inside of a control is
311
328
  16 pixels and the line 17.39, and a button shorter than its own line
312
329
  overflows downward and pushes the row 0.69 pixels taller. */
@@ -345,16 +362,16 @@
345
362
  var(--slotted-control-transition-easing);
346
363
  }
347
364
 
348
- /* The pointer target: a transparent square centred on the box that reaches
365
+ /* The pointer target: a transparent square centerd on the box that reaches
349
366
  the WCAG minimum wherever the box falls short of it — 22 pixels at
350
367
  comfortable, 16 at dense. It takes no room, so the row keeps its height. */
351
- [data-ui='field'] > [data-part='header'] > [data-part='help']::before {
368
+ [data-ui-field] > [data-part-header] > [data-part-help]::before {
352
369
  content: '';
353
370
  inset: min(0px, calc((100% - var(--slotted-target-min, 24px)) / 2));
354
371
  position: absolute;
355
372
  }
356
373
 
357
- [data-ui='field'] > [data-part='header'] > [data-part='help'] > [data-ui='icon'] {
374
+ [data-ui-field] > [data-part-header] > [data-part-help] > [data-ui-icon] {
358
375
  vertical-align: calc(((1cap + 1ex) / 2 - var(--_help-glyph)) / 2);
359
376
  }
360
377
 
@@ -363,22 +380,22 @@
363
380
  * hover ground while its tooltip is showing, so the reader sees which icon
364
381
  * the layer belongs to after the pointer has moved onto the layer.
365
382
  */
366
- [data-ui='field'] > [data-part='header'] > [data-part='help']:enabled:hover,
367
- [data-ui='field'] > [data-part='header'] > [data-part='help'][data-open] {
383
+ [data-ui-field] > [data-part-header] > [data-part-help]:enabled:hover,
384
+ [data-ui-field] > [data-part-header] > [data-part-help][data-open] {
368
385
  background-color: var(
369
386
  --slotted-field-help-surface-hover,
370
387
  var(--slotted-tone-secondary-subtle-hover, ButtonFace)
371
388
  );
372
389
  }
373
390
 
374
- [data-ui='field'] > [data-part='header'] > [data-part='help']:enabled:active {
391
+ [data-ui-field] > [data-part-header] > [data-part-help]:enabled:active {
375
392
  background-color: var(
376
393
  --slotted-field-help-surface-active,
377
394
  var(--slotted-tone-secondary-subtle-active, ButtonFace)
378
395
  );
379
396
  }
380
397
 
381
- [data-ui='field'] > [data-part='header'] > [data-part='help']:focus-visible {
398
+ [data-ui-field] > [data-part-header] > [data-part-help]:focus-visible {
382
399
  outline: var(--slotted-focus-ring-width, 2px) solid var(--slotted-focus-ring-color, Highlight);
383
400
  outline-offset: var(--slotted-focus-ring-offset, 2px);
384
401
  }
@@ -391,11 +408,11 @@
391
408
  * description rather than with its name. The badges are the badge family's;
392
409
  * the field only spaces them.
393
410
  */
394
- [data-ui='field'] > [data-part='header'] > [data-part='indicator'] {
411
+ [data-ui-field] > [data-part-header] > [data-part-indicator] {
395
412
  align-items: center;
396
413
  /* A badge is a box, not a line of text. Set on the label's baseline, its
397
414
  own inset stood it 1.77 pixels above the label's line and the row grew
398
- by that much; centred on the line, an 18.8-pixel badge fits in the
415
+ by that much; centerd on the line, an 18.8-pixel badge fits in the
399
416
  18.85-pixel line and the row is the label's height with or without it. */
400
417
  align-self: center;
401
418
  column-gap: var(--slotted-space-2, 0.25rem);
@@ -408,7 +425,7 @@
408
425
  * A link or a button at the end of the label row: `Forgot password?`,
409
426
  * `Generate`, `Use the billing address`. It is a text control, so it speaks
410
427
  * the vocabulary `link` settled for text that answers a pointer: accent ink
411
- * at rest, a hover a third of the way to the body colour with the underline
428
+ * at rest, a hover a third of the way to the body color with the underline
412
429
  * drawn, and a press two thirds of the way. ReUI paints the same action in
413
430
  * muted ink, where it reads as inert text beside the counter, and answers
414
431
  * press with a one-pixel shift of a line of 12-pixel type.
@@ -419,7 +436,7 @@
419
436
  * from a padding and a line — the sum measured 23.98 — and a flex box's
420
437
  * baseline is its words', so the row still aligns on it.
421
438
  */
422
- [data-ui='field'] > [data-part='header'] > [data-part='action'] {
439
+ [data-ui-field] > [data-part-header] > [data-part-action] {
423
440
  --_rest: var(--slotted-field-action-color, var(--slotted-tone-accent-text, LinkText));
424
441
 
425
442
  align-items: center;
@@ -453,9 +470,9 @@
453
470
  unicode-bidi: plaintext;
454
471
  }
455
472
 
456
- [data-ui='field']
457
- > [data-part='header']
458
- > [data-part='action']:not(:disabled, [aria-disabled='true']):hover {
473
+ [data-ui-field]
474
+ > [data-part-header]
475
+ > [data-part-action]:not(:disabled, [aria-disabled='true']):hover {
459
476
  color: var(
460
477
  --slotted-field-action-color-hover,
461
478
  color-mix(in oklab, var(--_rest) 65%, var(--slotted-text, CanvasText))
@@ -463,9 +480,9 @@
463
480
  text-decoration-color: currentColor;
464
481
  }
465
482
 
466
- [data-ui='field']
467
- > [data-part='header']
468
- > [data-part='action']:not(:disabled, [aria-disabled='true']):active {
483
+ [data-ui-field]
484
+ > [data-part-header]
485
+ > [data-part-action]:not(:disabled, [aria-disabled='true']):active {
469
486
  color: var(
470
487
  --slotted-field-action-color-active,
471
488
  color-mix(in oklab, var(--_rest) 35%, var(--slotted-text, CanvasText))
@@ -473,31 +490,29 @@
473
490
  text-decoration-color: currentColor;
474
491
  }
475
492
 
476
- [data-ui='field'] > [data-part='header'] > [data-part='action']:focus-visible {
493
+ [data-ui-field] > [data-part-header] > [data-part-action]:focus-visible {
477
494
  outline: var(--slotted-focus-ring-width, 2px) solid var(--slotted-focus-ring-color, Highlight);
478
495
  outline-offset: var(--slotted-focus-ring-offset, 2px);
479
496
  text-decoration-color: currentColor;
480
497
  }
481
498
 
482
- [data-ui='field']
483
- > [data-part='header']
484
- > [data-part='action']:is(:disabled, [aria-disabled='true']) {
499
+ [data-ui-field] > [data-part-header] > [data-part-action]:is(:disabled, [aria-disabled='true']) {
485
500
  color: var(--slotted-disabled-foreground, GrayText);
486
501
  cursor: not-allowed;
487
502
  }
488
503
 
489
504
  /**
490
505
  * On a finger both controls of the row reach the comfortable target with a
491
- * transparent halo centred on the box. The halo takes no room, so the row
506
+ * transparent halo centerd on the box. The halo takes no room, so the row
492
507
  * keeps its height and the ground and the ring stay the box a mouse sees.
493
508
  */
494
509
  @media (pointer: coarse) {
495
- [data-ui='field'] > [data-part='header'] > [data-part='action'] {
510
+ [data-ui-field] > [data-part-header] > [data-part-action] {
496
511
  position: relative;
497
512
  }
498
513
 
499
- [data-ui='field'] > [data-part='header'] > [data-part='help']::before,
500
- [data-ui='field'] > [data-part='header'] > [data-part='action']::before {
514
+ [data-ui-field] > [data-part-header] > [data-part-help]::before,
515
+ [data-ui-field] > [data-part-header] > [data-part-action]::before {
501
516
  content: '';
502
517
  inset: min(0px, calc((100% - var(--slotted-target-comfortable, 44px)) / 2));
503
518
  position: absolute;
@@ -514,8 +529,8 @@
514
529
  * Tabular figures, because a counter that jitters as it counts is a counter
515
530
  * the eye follows instead of the field.
516
531
  */
517
- [data-ui='field'] > [data-part='counter'],
518
- [data-ui='field'] > [data-part='header'] > [data-part='counter'] {
532
+ [data-ui-field] > [data-part-counter],
533
+ [data-ui-field] > [data-part-header] > [data-part-counter] {
519
534
  color: var(--slotted-field-counter-color, var(--slotted-text-muted));
520
535
  font-size: var(--slotted-control-font-size-sm, 12px);
521
536
  font-variant-numeric: tabular-nums;
@@ -528,7 +543,7 @@
528
543
  * The counter the family draws on a field with no header: the end of the
529
544
  * label row, in the third track, apart from the label by the side gap.
530
545
  */
531
- [data-ui='field'] > [data-part='counter'] {
546
+ [data-ui-field] > [data-part-counter] {
532
547
  align-self: end;
533
548
  grid-column: 3;
534
549
  grid-row: 1;
@@ -541,8 +556,8 @@
541
556
  * its maximum while validation has not yet run, and a counter that only turned
542
557
  * at submit would say nothing at the moment it is being read.
543
558
  */
544
- [data-ui='field'] > [data-part='counter'][data-invalid],
545
- [data-ui='field'] > [data-part='header'] > [data-part='counter'][data-invalid] {
559
+ [data-ui-field] > [data-part-counter][data-invalid],
560
+ [data-ui-field] > [data-part-header] > [data-part-counter][data-invalid] {
546
561
  color: var(--slotted-field-counter-invalid-color, var(--slotted-tone-danger-text));
547
562
  font-weight: var(--slotted-font-weight-medium, 500);
548
563
  }
@@ -560,7 +575,7 @@
560
575
  * form that renders its error unconditionally so nothing below it moves when
561
576
  * the error arrives.
562
577
  */
563
- [data-ui='field'] > [data-ui='inline-message']:not([data-reserve]):has([data-part='text']:empty) {
578
+ [data-ui-field] > [data-ui-inline-message]:not([data-reserve]):has([data-part-text]:empty) {
564
579
  display: none;
565
580
  }
566
581
 
@@ -575,7 +590,7 @@
575
590
  * own root rule, which has the same two attributes; equal specificity would
576
591
  * leave the winner to stylesheet order.
577
592
  */
578
- [data-ui='field'][data-part='root'] > [data-ui='inline-message'] {
593
+ [data-ui-field][data-part-root] > [data-ui-inline-message] {
579
594
  font-size: var(--slotted-font-size-xs, 0.75rem);
580
595
  }
581
596
 
@@ -586,8 +601,8 @@
586
601
  * size (`inline-message`, R5) and its own ink, and the weight is what makes
587
602
  * the two read as two kinds of sentence rather than one.
588
603
  */
589
- [data-ui='field'][data-part='root'] > [data-ui='inline-message'][data-tone='danger'],
590
- [data-ui='field'][data-part='root'] > [data-ui='inline-message'][data-tone='success'] {
604
+ [data-ui-field][data-part-root] > [data-ui-inline-message][data-tone='danger'],
605
+ [data-ui-field][data-part-root] > [data-ui-inline-message][data-tone='success'] {
591
606
  font-weight: var(--slotted-font-weight-medium, 500);
592
607
  }
593
608
 
@@ -618,19 +633,19 @@
618
633
  * and a label of three lines — or a header whose action wrapped under the
619
634
  * label — stretched a one-line input beside it to 43 pixels.
620
635
  */
621
- [data-ui='field'][data-part='root'][data-label-placement='side'] > * {
636
+ [data-ui-field][data-part-root][data-label-placement='side'] > * {
622
637
  align-self: start;
623
638
  grid-column: 2 / 3;
624
639
  }
625
640
 
626
641
  /**
627
- * Centred on the control's first line rather than on the control, so the
642
+ * Centerd on the control's first line rather than on the control, so the
628
643
  * label stays level with the text a reader is typing when the control is a
629
644
  * textarea four lines tall. `max()` keeps a label taller than its control —
630
645
  * three wrapped lines beside a 30-pixel input — from being pushed down.
631
646
  */
632
- [data-ui='field'][data-part='root'][data-label-placement='side'] > [data-part='label'],
633
- [data-ui='field'][data-part='root'][data-label-placement='side'] > [data-part='header'] {
647
+ [data-ui-field][data-part-root][data-label-placement='side'] > [data-part-label],
648
+ [data-ui-field][data-part-root][data-label-placement='side'] > [data-part-header] {
634
649
  grid-column: 1;
635
650
  grid-row: 1;
636
651
  padding-block-start: max(0px, calc((var(--_control-block-size) - 1lh) / 2));
@@ -644,7 +659,7 @@
644
659
  * control, where it sat until the header existed, was a second place. Restated inside the query because `> *` above is one selector
645
660
  * more specific than the counter's own rule.
646
661
  */
647
- [data-ui='field'][data-part='root'][data-label-placement='side'] > [data-part='counter'] {
662
+ [data-ui-field][data-part-root][data-label-placement='side'] > [data-part-counter] {
648
663
  grid-column: 1;
649
664
  grid-row: 2;
650
665
  justify-self: end;
@@ -657,9 +672,9 @@
657
672
  * part of the name — `Assunto 12/60` — and it stood one line higher than
658
673
  * the counter a field without a header draws.
659
674
  */
660
- [data-ui='field'][data-part='root'][data-label-placement='side']
661
- > [data-part='header']
662
- > [data-part='counter'] {
675
+ [data-ui-field][data-part-root][data-label-placement='side']
676
+ > [data-part-header]
677
+ > [data-part-counter] {
663
678
  flex-basis: 100%;
664
679
  margin-inline-start: 0;
665
680
  text-align: end;
@@ -668,27 +683,25 @@
668
683
 
669
684
  /* ── Disabled ─────────────────────────────────────────────────────────
670
685
  *
671
- * Muted to the colour the theme measures rather than faded by opacity: a
686
+ * Muted to the color the theme measures rather than faded by opacity: a
672
687
  * label nobody can read is a field nobody can identify, and a form that
673
688
  * disables a section still has to say what the section was for.
674
689
  *
675
690
  * The messages need no rule here. The field passes `disabled` to them, and
676
- * `inline-message` mutes itself to the same colour and stops its own ring.
691
+ * `inline-message` mutes itself to the same color and stops its own ring.
677
692
  */
678
- [data-ui='field'][data-part='root'][data-disabled] > [data-part='label'],
679
- [data-ui='field'][data-part='root'][data-disabled] > [data-part='counter'],
680
- [data-ui='field'][data-part='root'][data-disabled] > [data-part='header'] > [data-part='label'],
681
- [data-ui='field'][data-part='root'][data-disabled]
682
- > [data-part='header']
683
- > [data-part='counter'] {
693
+ [data-ui-field][data-part-root][data-disabled] > [data-part-label],
694
+ [data-ui-field][data-part-root][data-disabled] > [data-part-counter],
695
+ [data-ui-field][data-part-root][data-disabled] > [data-part-header] > [data-part-label],
696
+ [data-ui-field][data-part-root][data-disabled] > [data-part-header] > [data-part-counter] {
684
697
  color: var(--slotted-disabled-foreground);
685
698
  }
686
699
 
687
- [data-ui='field'][data-part='root'][data-disabled] > [data-part='label'] > [data-part='mark'],
688
- [data-ui='field'][data-part='root'][data-disabled]
689
- > [data-part='header']
690
- > [data-part='label']
691
- > [data-part='mark'] {
700
+ [data-ui-field][data-part-root][data-disabled] > [data-part-label] > [data-part-mark],
701
+ [data-ui-field][data-part-root][data-disabled]
702
+ > [data-part-header]
703
+ > [data-part-label]
704
+ > [data-part-mark] {
692
705
  color: var(--slotted-disabled-foreground);
693
706
  }
694
707
 
@@ -697,10 +710,10 @@
697
710
  * whose counter is over its limit paints the counter muted rather than red.
698
711
  * A control nobody can type in is not over a limit; it is off.
699
712
  */
700
- [data-ui='field'][data-part='root'][data-disabled] > [data-part='counter'][data-invalid],
701
- [data-ui='field'][data-part='root'][data-disabled]
702
- > [data-part='header']
703
- > [data-part='counter'][data-invalid] {
713
+ [data-ui-field][data-part-root][data-disabled] > [data-part-counter][data-invalid],
714
+ [data-ui-field][data-part-root][data-disabled]
715
+ > [data-part-header]
716
+ > [data-part-counter][data-invalid] {
704
717
  color: var(--slotted-disabled-foreground);
705
718
  font-weight: var(--slotted-font-weight-regular, 400);
706
719
  }
@@ -36,6 +36,8 @@
36
36
  "--slotted-field-mark-gap",
37
37
  "--slotted-field-mark-text-color",
38
38
  "--slotted-field-row-gap",
39
+ "--slotted-field-width-medium",
40
+ "--slotted-field-width-short",
39
41
  "--slotted-focus-ring-color",
40
42
  "--slotted-focus-ring-offset",
41
43
  "--slotted-focus-ring-width",