@helixds/react 0.1.0 → 0.2.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (114) hide show
  1. package/AGENTS.md +4 -1
  2. package/dist/archetypes/actions-navigation.md +62 -0
  3. package/dist/archetypes/data-display.md +68 -0
  4. package/dist/archetypes/feedback-status.md +54 -0
  5. package/dist/archetypes/form-selection.md +61 -0
  6. package/dist/archetypes/foundation.md +56 -0
  7. package/dist/archetypes/layout.md +53 -0
  8. package/dist/archetypes/overlays.md +54 -0
  9. package/dist/archetypes/text-input.md +58 -0
  10. package/dist/components/Badge/Badge.types.d.ts +1 -1
  11. package/dist/components/Combobox/Combobox.d.ts +17 -0
  12. package/dist/components/Combobox/Combobox.doc.d.ts +4 -0
  13. package/dist/components/Combobox/Combobox.doc.js +41 -0
  14. package/dist/components/Combobox/Combobox.js +141 -0
  15. package/dist/components/Combobox/Combobox.types.d.ts +31 -0
  16. package/dist/components/Combobox/Combobox.types.js +2 -0
  17. package/dist/components/Combobox/index.d.ts +9 -0
  18. package/dist/components/Combobox/index.js +2 -0
  19. package/dist/components/Icon/Icon.doc.js +2 -2
  20. package/dist/components/Icon/Icon.js +1 -1
  21. package/dist/components/Icon/Icon.types.d.ts +1 -1
  22. package/dist/components/Icon/iconStroke.d.ts +1 -1
  23. package/dist/components/Icon/iconStroke.js +1 -1
  24. package/dist/components/Menu/Menu.doc.js +4 -4
  25. package/dist/components/Menu/Menu.js +3 -3
  26. package/dist/components/Menu/Menu.types.d.ts +1 -1
  27. package/dist/components/Modal/Modal.doc.js +1 -1
  28. package/dist/components/Modal/Modal.types.d.ts +1 -1
  29. package/dist/components/MultiSelect/MultiSelect.d.ts +2 -2
  30. package/dist/components/MultiSelect/MultiSelect.doc.js +1 -1
  31. package/dist/components/MultiSelect/MultiSelect.js +4 -4
  32. package/dist/components/Popover/Popover.d.ts +14 -0
  33. package/dist/components/Popover/Popover.doc.d.ts +4 -0
  34. package/dist/components/Popover/Popover.doc.js +47 -0
  35. package/dist/components/Popover/Popover.js +157 -0
  36. package/dist/components/Popover/Popover.types.d.ts +27 -0
  37. package/dist/components/Popover/Popover.types.js +2 -0
  38. package/dist/components/Popover/index.d.ts +9 -0
  39. package/dist/components/Popover/index.js +2 -0
  40. package/dist/components/SegmentedControl/SegmentedControl.doc.js +2 -2
  41. package/dist/components/SegmentedControl/SegmentedControl.js +1 -1
  42. package/dist/components/Select/Select.doc.js +2 -2
  43. package/dist/components/Select/Select.js +1 -1
  44. package/dist/components/SidePanel/SidePanel.doc.js +1 -1
  45. package/dist/components/SidePanel/SidePanel.types.d.ts +1 -1
  46. package/dist/components/Tabs/Tabs.d.ts +13 -0
  47. package/dist/components/Tabs/Tabs.doc.d.ts +4 -0
  48. package/dist/components/Tabs/Tabs.doc.js +47 -0
  49. package/dist/components/Tabs/Tabs.js +61 -0
  50. package/dist/components/Tabs/Tabs.types.d.ts +33 -0
  51. package/dist/components/Tabs/Tabs.types.js +2 -0
  52. package/dist/components/Tabs/index.d.ts +9 -0
  53. package/dist/components/Tabs/index.js +2 -0
  54. package/dist/components/Toast/Toast.doc.js +1 -1
  55. package/dist/components/Toast/Toast.js +2 -2
  56. package/dist/components/Toast/toastStore.d.ts +1 -1
  57. package/dist/components/Tooltip/Tooltip.doc.js +1 -1
  58. package/dist/components/Tooltip/Tooltip.js +5 -5
  59. package/dist/components/Tooltip/Tooltip.types.d.ts +1 -1
  60. package/dist/contracts/Accordion.json +5 -4
  61. package/dist/contracts/AppShell.json +111 -28
  62. package/dist/contracts/Avatar.json +3 -2
  63. package/dist/contracts/AvatarGroup.json +1 -0
  64. package/dist/contracts/Badge.json +2 -1
  65. package/dist/contracts/Button.json +2 -1
  66. package/dist/contracts/Card.json +3 -2
  67. package/dist/contracts/Chart.json +2 -1
  68. package/dist/contracts/Checkbox.json +1 -0
  69. package/dist/contracts/CheckboxGroup.json +1 -0
  70. package/dist/contracts/Chip.json +3 -2
  71. package/dist/contracts/ChipGroup.json +1 -0
  72. package/dist/contracts/Combobox.json +431 -0
  73. package/dist/contracts/FAB.json +3 -2
  74. package/dist/contracts/Icon.json +10 -9
  75. package/dist/contracts/IconButton.json +2 -1
  76. package/dist/contracts/Input.json +2 -1
  77. package/dist/contracts/Menu.json +7 -6
  78. package/dist/contracts/Modal.json +5 -4
  79. package/dist/contracts/MultiSelect.json +6 -5
  80. package/dist/contracts/NavItem.json +2 -1
  81. package/dist/contracts/PageHeader.json +1 -0
  82. package/dist/contracts/Popover.json +322 -0
  83. package/dist/contracts/RadioButton.json +1 -0
  84. package/dist/contracts/RadioGroup.json +1 -0
  85. package/dist/contracts/SegmentedControl.json +4 -3
  86. package/dist/contracts/Select.json +9 -9
  87. package/dist/contracts/SideNav.json +2 -1
  88. package/dist/contracts/SidePanel.json +5 -4
  89. package/dist/contracts/Switch.json +1 -0
  90. package/dist/contracts/Table.json +1 -0
  91. package/dist/contracts/Tabs.json +353 -0
  92. package/dist/contracts/Textarea.json +2 -1
  93. package/dist/contracts/Toast.json +6 -5
  94. package/dist/contracts/Tooltip.json +4 -3
  95. package/dist/contracts/TopBar.json +2 -0
  96. package/dist/contracts/manifest.json +1539 -44
  97. package/dist/index.d.ts +9 -0
  98. package/dist/index.js +6 -0
  99. package/dist/layout/AppShell/AppShell.d.ts +1 -1
  100. package/dist/layout/AppShell/AppShell.doc.js +5 -0
  101. package/dist/layout/AppShell/AppShell.js +109 -2
  102. package/dist/layout/AppShell/AppShell.types.d.ts +6 -0
  103. package/dist/layout/AppShell/AppShellContext.d.ts +17 -0
  104. package/dist/layout/AppShell/AppShellContext.js +4 -0
  105. package/dist/layout/SideNav/SideNav.doc.js +1 -0
  106. package/dist/layout/TopBar/TopBar.js +7 -1
  107. package/dist/lib/useDialogTransition.d.ts +1 -1
  108. package/dist/lib/useDialogTransition.js +1 -1
  109. package/dist/lib/useDisclosureTransition.d.ts +1 -1
  110. package/dist/lib/useDisclosureTransition.js +1 -1
  111. package/dist/patterns/expand-collapse-chevron.md +1 -1
  112. package/dist/patterns/motion-effects.md +2 -4
  113. package/package.json +26 -4
  114. package/src/globals.css +338 -22
@@ -0,0 +1,431 @@
1
+ {
2
+ "$schema": "../component.schema.json",
3
+ "name": "Combobox",
4
+ "version": "0.1.0",
5
+ "status": "stable",
6
+ "purpose": "Lets users find and choose a single value from a long list by typing to filter it.",
7
+ "import": "import { Combobox } from '@helixds/react';",
8
+ "archetype": "form-selection",
9
+ "neverUseFor": [
10
+ "A short list (about 7 options or fewer) - use Select or RadioGroup",
11
+ "Free-form text entry, or a value that isn't one of the options - use Input",
12
+ "Multiple simultaneous selections - use MultiSelect"
13
+ ],
14
+ "rationale": "Combobox is Select's field with a real <input> as the trigger, filtering Menu's listbox as the user types: the WAI-ARIA editable combobox with list autocomplete. A native <datalist> was rejected because every browser draws it differently (Safari puts it beside the field), and it can't be styled or positioned. It shares Select's --helix-select-* tokens and its one 32px height on purpose, so both read as the same field, and a change to Select's field changes Combobox too. A search icon always marks it as searchable. Real focus stays on the input, and aria-activedescendant points at the highlighted option, which starts on the first match. Matching is case-insensitive \"contains\" on the visible label only. Opening from a chosen value shows every option, and focusing selects the field's text so typing replaces it. The popup is Menu itself (its portal, below-only placement and 32px rows), and when nothing matches it shows one disabled \"No results\" row, a fixed English string for now. A value is always an option from the list: leaving the field puts the chosen label back or empties it, and free text is never kept, because that would be an Input. Grouped options, async loading, multi-select and free-text values are out of scope.",
15
+ "governance": {
16
+ "mayExtendLocally": [
17
+ "Provide the options, label, placeholder and helper text",
18
+ "Control the value and validation from product logic"
19
+ ],
20
+ "mustEscalateToDS": [
21
+ "Adding a size prop or new heights",
22
+ "Async loading, grouped options, multi-select or free-text values",
23
+ "Changing the matching rule or the combobox/listbox keyboard model"
24
+ ]
25
+ },
26
+ "states": {
27
+ "intrinsic": [
28
+ "hover",
29
+ "focus"
30
+ ],
31
+ "authored": [
32
+ {
33
+ "name": "invalid",
34
+ "description": "The chosen value fails validation.",
35
+ "aria": "aria-invalid='true'"
36
+ },
37
+ {
38
+ "name": "disabled",
39
+ "description": "The field is non-interactive.",
40
+ "aria": "disabled (native)"
41
+ },
42
+ {
43
+ "name": "required",
44
+ "description": "The field must have a value before form submission.",
45
+ "aria": "aria-required='true'"
46
+ },
47
+ {
48
+ "name": "open",
49
+ "description": "The filtered listbox is showing.",
50
+ "aria": "aria-expanded='true'/'false' on the input"
51
+ }
52
+ ]
53
+ },
54
+ "anatomy": [
55
+ {
56
+ "part": "combobox-root",
57
+ "element": "div",
58
+ "description": "Layout wrapper for label, field and messages (Select's spacing: 8px between them)."
59
+ },
60
+ {
61
+ "part": "combobox-label",
62
+ "element": "label",
63
+ "description": "Accessible label. Always rendered - visible or sr-only. Disabled: dims to text.disabled with the rest of the text."
64
+ },
65
+ {
66
+ "part": "combobox-required",
67
+ "element": "span",
68
+ "optional": true,
69
+ "description": "The required indicator (*) inside the label - shown by `required`."
70
+ },
71
+ {
72
+ "part": "combobox-wrapper",
73
+ "element": "div",
74
+ "description": "Positions the input with its search icon and chevron."
75
+ },
76
+ {
77
+ "part": "combobox-icon",
78
+ "element": "slot",
79
+ "description": "Leading search icon, always shown (see rationale): marks the field as searchable. 16px, Select's icon color."
80
+ },
81
+ {
82
+ "part": "combobox-input",
83
+ "element": "input",
84
+ "description": "The visible field, a native <input> with role=combobox. Real DOM focus stays here; aria-activedescendant points at the highlighted option of the portaled Menu."
85
+ },
86
+ {
87
+ "part": "combobox-chevron",
88
+ "element": "slot",
89
+ "optional": true,
90
+ "description": "Trailing chevron. Flips while open, same scaleY treatment as Select's."
91
+ },
92
+ {
93
+ "part": "combobox-description",
94
+ "element": "span",
95
+ "optional": true,
96
+ "description": "Helper text below the field."
97
+ },
98
+ {
99
+ "part": "combobox-error",
100
+ "element": "span",
101
+ "optional": true,
102
+ "description": "Error text shown when invalid=true."
103
+ }
104
+ ],
105
+ "props": [
106
+ {
107
+ "name": "label",
108
+ "type": "string",
109
+ "required": true,
110
+ "description": "Visible or screen-reader-only label. Required for a11y."
111
+ },
112
+ {
113
+ "name": "options",
114
+ "type": "ComboboxOption[]",
115
+ "required": true,
116
+ "description": "The options to search and pick from. Each option: { value, label, disabled? }. Typing filters them by label (case-insensitive, contains)."
117
+ },
118
+ {
119
+ "name": "value",
120
+ "type": "string | undefined",
121
+ "description": "Controlled selected value."
122
+ },
123
+ {
124
+ "name": "defaultValue",
125
+ "type": "string | undefined",
126
+ "description": "Uncontrolled initial value."
127
+ },
128
+ {
129
+ "name": "onChange",
130
+ "type": "(value: string) => void | undefined",
131
+ "description": "Value change handler."
132
+ },
133
+ {
134
+ "name": "placeholder",
135
+ "type": "string | undefined",
136
+ "description": "Hint shown in the empty field before anything is typed or chosen."
137
+ },
138
+ {
139
+ "name": "description",
140
+ "type": "string | undefined",
141
+ "description": "Helper text shown below the field."
142
+ },
143
+ {
144
+ "name": "errorMessage",
145
+ "type": "string | undefined",
146
+ "description": "Error text shown when invalid=true."
147
+ },
148
+ {
149
+ "name": "invalid",
150
+ "type": "boolean",
151
+ "default": false,
152
+ "description": "Shows error styling and message."
153
+ },
154
+ {
155
+ "name": "disabled",
156
+ "type": "boolean",
157
+ "default": false,
158
+ "description": "Non-interactive state."
159
+ },
160
+ {
161
+ "name": "required",
162
+ "type": "boolean",
163
+ "default": false,
164
+ "description": "Marks field as required. Enforced natively: an invisible form input carries the value, so an empty required Combobox blocks form submit like a native field."
165
+ },
166
+ {
167
+ "name": "fullWidth",
168
+ "type": "boolean",
169
+ "default": false,
170
+ "description": "Expands to container width."
171
+ },
172
+ {
173
+ "name": "hideLabel",
174
+ "type": "boolean",
175
+ "default": false,
176
+ "description": "Hides the label visually but keeps it accessible."
177
+ },
178
+ {
179
+ "name": "id",
180
+ "type": "string | undefined",
181
+ "description": "Optional field id override."
182
+ },
183
+ {
184
+ "name": "name",
185
+ "type": "string | undefined",
186
+ "description": "Native form field name."
187
+ },
188
+ {
189
+ "name": "className",
190
+ "type": "string | undefined",
191
+ "description": "Additional className for the root."
192
+ }
193
+ ],
194
+ "sizing": {
195
+ "height": {
196
+ "mode": "fixed",
197
+ "values": {
198
+ "default": 32
199
+ },
200
+ "unit": "px",
201
+ "note": "One fixed size only, deliberately — no size prop. Matches semantic.size.m, Select's height, the same height Input/Textarea's own 'm' field uses, so a Combobox field and its Menu items read as one continuous, aligned scale (see Menu's contract rationale)."
202
+ },
203
+ "width": {
204
+ "default": "fixed",
205
+ "value": 320,
206
+ "unit": "px",
207
+ "modes": {
208
+ "fixed": "320px — every form field shares it and never grows or shrinks with its content (owner's rule 2026-10-21, form-field pattern); max-width 100% so a narrow container can still hold it.",
209
+ "fill": "fullWidth=true: 100% of the container (Figma: drawn at 600px, the field and its popup on Fill so they stretch)."
210
+ },
211
+ "exceptions": "A field that must be narrower (a number stepper, a short code) says so here, with its width and why — the only way off 320px."
212
+ }
213
+ },
214
+ "tokenPolicy": {
215
+ "allowed": [
216
+ "color.fill",
217
+ "color.text",
218
+ "color.border",
219
+ "spacing",
220
+ "radius",
221
+ "fontSize"
222
+ ],
223
+ "forbidden": [
224
+ "primitive.color"
225
+ ]
226
+ },
227
+ "a11y": {
228
+ "role": "combobox on a native <input> (WAI-ARIA editable combobox with list autocomplete, aria-autocomplete=list) + the Menu listbox popup - see rationale.",
229
+ "keyboardNav": [
230
+ "Typing - filters the options and opens the menu, highlighting the first match",
231
+ "Arrow Up/Down - opens the menu, or moves the highlighted option while open",
232
+ "Enter - confirms the highlighted option while open",
233
+ "Escape - closes the menu and puts the chosen option's label back",
234
+ "Tab - move focus (closes the menu first and puts the chosen option's label back)"
235
+ ],
236
+ "wcag": [
237
+ "1.3.1 Info and Relationships",
238
+ "1.4.3 Contrast (AA)",
239
+ "2.1.1 Keyboard",
240
+ "2.4.7 Focus Visible",
241
+ "4.1.2 Name Role Value"
242
+ ],
243
+ "applied": {
244
+ "nativeElement": "div",
245
+ "innerComponents": [
246
+ "Button",
247
+ "Menu"
248
+ ],
249
+ "focus": [
250
+ {
251
+ "part": "combobox-wrapper",
252
+ "when": ":focus",
253
+ "border-color": "var(--helix-select-border-hover)"
254
+ },
255
+ {
256
+ "part": "combobox-input",
257
+ "when": ":focus",
258
+ "box-shadow": "0 0 0 3px color-mix(in srgb, var(--helix-select-border-focus) 20%, transparent)",
259
+ "border-color": "var(--helix-select-border-focus)"
260
+ }
261
+ ],
262
+ "aria": {
263
+ "combobox-icon": {
264
+ "aria-hidden": [
265
+ "true"
266
+ ]
267
+ },
268
+ "combobox-input": {
269
+ "role": [
270
+ "combobox"
271
+ ],
272
+ "aria-autocomplete": [
273
+ "list"
274
+ ],
275
+ "aria-expanded": [
276
+ "false",
277
+ "true"
278
+ ],
279
+ "aria-controls": [
280
+ "(id)"
281
+ ],
282
+ "aria-activedescendant": [
283
+ "(id)"
284
+ ],
285
+ "aria-invalid": [
286
+ "true"
287
+ ],
288
+ "aria-describedby": [
289
+ "(id)"
290
+ ],
291
+ "aria-required": [
292
+ "true"
293
+ ]
294
+ },
295
+ "combobox-chevron": {
296
+ "aria-hidden": [
297
+ "true"
298
+ ]
299
+ },
300
+ "combobox-error": {
301
+ "role": [
302
+ "alert"
303
+ ]
304
+ },
305
+ "combobox-required": {
306
+ "aria-hidden": [
307
+ "true"
308
+ ]
309
+ }
310
+ },
311
+ "announced": [
312
+ "combobox \"Country\": Spain",
313
+ "combobox \"Country\"",
314
+ "combobox \"Country\" [disabled]: Spain",
315
+ "combobox \"Country\" [expanded]: land",
316
+ "combobox \"Country\" [invalid]"
317
+ ],
318
+ "contrast": {
319
+ "combobox-label": {
320
+ "light": "17.85:1 — #0f172a on #ffffff",
321
+ "dark": "16.29:1 — #f1f5f9 on #0f172a"
322
+ },
323
+ "combobox-input": {
324
+ "light": "17.85:1 — #0f172a on #ffffff",
325
+ "dark": "16.29:1 — #f1f5f9 on #0f172a"
326
+ },
327
+ "combobox-error": {
328
+ "light": "6.47:1 — #b91c1c on #ffffff",
329
+ "dark": "12.65:1 — #fecdd3 on #0f172a"
330
+ },
331
+ "combobox-description": {
332
+ "light": "7.57:1 — #475569 on #ffffff",
333
+ "dark": "6.96:1 — #94a3b8 on #0f172a"
334
+ }
335
+ },
336
+ "targetSize": {
337
+ "combobox-input": "smallest 320×32 px"
338
+ },
339
+ "motion": [
340
+ "CSS transitions/animations: neutralised by the global prefers-reduced-motion rule"
341
+ ]
342
+ },
343
+ "results": {
344
+ "score": 100,
345
+ "meetsMinimum": true,
346
+ "checks": {
347
+ "contract": "pass",
348
+ "keys": "pass",
349
+ "focus-return": "pass",
350
+ "keyboard": "pass",
351
+ "axe": "pass",
352
+ "contrast": "pass",
353
+ "focus-visible": "pass",
354
+ "target-size": "pass",
355
+ "reflow": "n/a",
356
+ "screen-reader": "pass",
357
+ "ai-visual": "pending",
358
+ "human": "pending"
359
+ },
360
+ "notScored": [
361
+ "ai-visual",
362
+ "human"
363
+ ],
364
+ "changed": "2026-12-05"
365
+ }
366
+ },
367
+ "figma": {
368
+ "states": [
369
+ "default",
370
+ "hover",
371
+ "focus",
372
+ "open"
373
+ ],
374
+ "properties": [
375
+ {
376
+ "name": "state",
377
+ "type": "VARIANT",
378
+ "values": [
379
+ "default",
380
+ "hover",
381
+ "focus",
382
+ "open"
383
+ ],
384
+ "figmaOnly": true,
385
+ "description": "Figma-only axis: hover/focus are CSS pseudo-classes, open is the list showing (aria-expanded). invalid, disabled and the secondary toggles are their own variants (contracts/figma-conversion.json, pattern form-field) — same as Select."
386
+ }
387
+ ],
388
+ "propertyMap": {
389
+ "value": {
390
+ "codeType": "string | undefined",
391
+ "figma": [
392
+ {
393
+ "name": "value.",
394
+ "type": "VARIANT",
395
+ "values": [
396
+ "empty",
397
+ "selected"
398
+ ]
399
+ },
400
+ {
401
+ "name": "value",
402
+ "type": "TEXT"
403
+ }
404
+ ],
405
+ "approved": "2026-12-05",
406
+ "reason": "same model as Select (approved 2026-10-20): the field shows either the placeholder (empty) or the chosen option's label (selected) in one text layer — value. picks the look and value is the text; selected is drawn once"
407
+ }
408
+ },
409
+ "structure": "combobox-root (8px gap) > combobox-label (text + combobox-required), combobox-wrapper (the field: Select's tokens, 32px, border always) > combobox-icon (Search, 16px, always shown) + combobox-input (placeholder or the chosen label) + combobox-chevron (ChevronDown; open uses an unrotated ChevronUp, code flips it), combobox-description, combobox-error. state=open holds the list as a nested Menu instance named menu (multiple=false, options=5, exposed so its options 2–7 are picked from the Combobox's panel): absolute, 4px below the field at its width, like Select.",
410
+ "variantCombinations": "72 variants, like Select: invalid × state default/hover/focus/open = 8, disabled (state=default, valid) = 1 — those 9 for each value. empty/selected × fullWidth false/true × hideLabel false/true = 72. The option count is the nested Menu's options property, not a Combobox variant (list-delegated).",
411
+ "stories": {
412
+ "Default": "value.=empty",
413
+ "Controlled": "value.=selected",
414
+ "WithDescription": "description.=true",
415
+ "Invalid": "invalid=true, errorMessage.=true",
416
+ "Disabled": "disabled=true, value.=selected",
417
+ "Required": "required=true",
418
+ "Open": "state=open",
419
+ "Filtered": "state=open",
420
+ "NoResults": {
421
+ "figma": null,
422
+ "reason": "the filter's empty result — behaviour; Menu draws the disabled row",
423
+ "approved": "2026-12-05"
424
+ },
425
+ "KeyboardNavigation": {
426
+ "figma": "state=focus",
427
+ "reason": "keyboard focus — the focus ring is drawn in Figma (owner 2026-10-21: focus states are drawn)"
428
+ }
429
+ }
430
+ }
431
+ }
@@ -6,10 +6,11 @@
6
6
 
7
7
  "purpose": "A single, prominent floating action reachable from anywhere in the current view — optionally expanding into 1-3 closely related actions via a speed-dial.",
8
8
  "import": "import { FAB } from '@helixds/react';",
9
+ "archetype": "actions-navigation",
9
10
 
10
11
  "neverUseFor": [
11
12
  "The only way to reach an action also available inline — FAB is a shortcut, not the sole path; if removing it would make an action unreachable, it belongs in the page's normal flow instead",
12
- "A toggle/pressed state — same exclusion as IconButton; compose a dedicated toggle control instead",
13
+ "A toggle/pressed state — same exclusion as IconButton; use Switch instead",
13
14
  "More than 3 revealed actions — a speed-dial with many actions is a Menu wearing a costume; use Menu once it exists",
14
15
  "Anything other than the single most important action in the current view — a second FAB on the same screen competes with itself"
15
16
  ],
@@ -33,7 +34,7 @@
33
34
  "authored": [
34
35
  {
35
36
  "name": "expanded",
36
- "description": "The speed-dial actions are revealed. Rendered inline (no portal) — same hand-rolled-disclosure category as Select/Checkbox, not a Dialog/Popover/Menu primitive decision.",
37
+ "description": "The speed-dial actions are revealed. Rendered inline (no portal) — same hand-rolled-disclosure category as Select/Checkbox, not a Modal/Popover/Menu primitive decision.",
37
38
  "aria": "aria-expanded={expanded}"
38
39
  },
39
40
  {
@@ -2,10 +2,11 @@
2
2
  "$schema": "../component.schema.json",
3
3
  "name": "Icon",
4
4
  "version": "1.0.0",
5
- "status": "beta",
5
+ "status": "stable",
6
6
 
7
7
  "purpose": "Communicates meaning, action, or status through a recognizable visual symbol. Always supplemental to text — never the sole conveyor of information without a tooltip or label.",
8
8
  "import": "import { Icon, createIconAdapter, iconStrokeForSize } from '@helixds/react';",
9
+ "archetype": "foundation",
9
10
 
10
11
  "neverUseFor": [
11
12
  "Decorative illustration — use an Illustration component instead",
@@ -13,7 +14,7 @@
13
14
  "Animated icons — Tabler outline icons are static; wrap in a motion component if animation is needed"
14
15
  ],
15
16
 
16
- "rationale": "Every Tabler icon renders through Icon so size, stroke, color and aria-hidden are decided once instead of at each call site, which is how components drifted before. Stroke is derived from size by the stroke rule (ADR-017), the icon set is swappable (ADR-014), and Icon is always supplemental to text — accessibility lives at the usage site.",
17
+ "rationale": "Every Tabler icon renders through Icon so size, stroke, color and aria-hidden are decided once instead of at each call site, which is how components drifted before. Stroke is derived from size by the stroke rule (ADR-014), the icon set is swappable (ADR-014), and Icon is always supplemental to text — accessibility lives at the usage site.",
17
18
 
18
19
  "governance": {
19
20
  "mayExtendLocally": [
@@ -40,13 +41,13 @@
40
41
  "note": "Tabler default. Goes on the root <svg> ONLY — never on <path> children. Configurable via CSS."
41
42
  },
42
43
  "helixStrokeRule": {
43
- "adr": "docs/ADR/ADR-017-icon-stroke-rule.md",
44
+ "adr": "docs/ADR/ADR-014-icon-agnostic.md",
44
45
  "source": "packages/core/src/components/Icon/iconStroke.ts (ICON_STROKE_PX_BY_SIZE + iconStrokeForSize)",
45
46
  "unit": "Line width as seen on screen, in CSS px. The SVG stroke attribute is converted from this in code (iconStrokeForSize) — never documented or edited by hand.",
46
47
  "realPxBySize": { "12": 1.3, "14": 1.4, "16": 1.5, "18": 1.6, "20": 1.7, "24": 1.8, "28": 2.0, "32": 2.2, "36": 2.4, "40": 2.8 },
47
48
  "rules": [
48
49
  "Icon applies the rule automatically — never pass stroke at a call site to make an icon heavier or lighter.",
49
- "To change icon weight system-wide, edit ICON_STROKE_PX_BY_SIZE (and this block + ADR-017), nothing else.",
50
+ "To change icon weight system-wide, edit ICON_STROKE_PX_BY_SIZE (and this block + ADR-014), nothing else.",
50
51
  "Real px must never decrease as size grows — each rung is at least as thick as the one below it.",
51
52
  "Line weight grows faster as icons get larger: +0.1px per step up to 24px, +0.2px per 4px from 24 to 36, +0.4px from 36 to 40 — large icons need visibly heavier lines to hold their presence. Sizes between rungs interpolate real px linearly; outside 12–40 the edge rung's svg stroke is held.",
52
53
  "A deliberate one-off override (e.g. Checkbox's stroke={3} checkmark) must be at least as thick as the rule at that size, and commented at the call site."
@@ -145,7 +146,7 @@
145
146
  {
146
147
  "part": "icon-vector",
147
148
  "element": "path (or g > path for compound icons)",
148
- "description": "The drawn artwork. stroke=currentColor, fill=none, stroke-width derived from size by the ADR-017 stroke rule (see iconStyle.helixStrokeRule). Generated inside the Tabler icon component — not addressable as a data-helix-part from the Helix Icon wrapper; only icon-root carries the attribute."
149
+ "description": "The drawn artwork. stroke=currentColor, fill=none, stroke-width derived from size by the ADR-014 stroke rule (see iconStyle.helixStrokeRule). Generated inside the Tabler icon component — not addressable as a data-helix-part from the Helix Icon wrapper; only icon-root carries the attribute."
149
150
  }
150
151
  ],
151
152
 
@@ -166,7 +167,7 @@
166
167
  "name": "stroke",
167
168
  "type": "number",
168
169
  "default": "iconStrokeForSize(size)",
169
- "description": "Stroke width applied to the icon path. Defaults to the ADR-017 stroke rule for the rendered size (see iconStyle.helixStrokeRule) — don't pass it to adjust weight; only for a deliberate, commented one-off."
170
+ "description": "Stroke width applied to the icon path. Defaults to the ADR-014 stroke rule for the rendered size (see iconStyle.helixStrokeRule) — don't pass it to adjust weight; only for a deliberate, commented one-off."
170
171
  },
171
172
  {
172
173
  "name": "color",
@@ -196,7 +197,7 @@
196
197
  "naming": "Bare PascalCase — 'Plus', not 'IconPlus', not 'tabler/Plus'",
197
198
  "vector": "Named 'vector', constraints: SCALE/SCALE",
198
199
  "skill": ".ai/skills/icons-to-figma.md",
199
- "codeOnly": "Icon is a code-only wrapper (owner's decision 2026-10-21, option A): in code it sets the size, derives the stroke weight from it (ADR-017) and handles color and aria; in Figma every component already places its icon instance at the right size and stroke per variant, so there is nothing for an Icon set to add. Designers use the icon components on the Icons page directly. A loose icon scaled by hand in Figma does not re-derive its stroke like code does — pick the size from the icon component, don't scale it.",
200
+ "codeOnly": "Icon is a code-only wrapper (owner's decision 2026-10-21, option A): in code it sets the size, derives the stroke weight from it (ADR-014) and handles color and aria; in Figma every component already places its icon instance at the right size and stroke per variant, so there is nothing for an Icon set to add. Designers use the icon components on the Icons page directly. A loose icon scaled by hand in Figma does not re-derive its stroke like code does — pick the size from the icon component, don't scale it.",
200
201
  "propertyMap": {
201
202
  "icon": {
202
203
  "codeType": "HelixIconComponent",
@@ -208,7 +209,7 @@
208
209
  "codeType": "12 | 14 | 16 | 18 | 20 | 24 | 28 | 32 | 36 | 40",
209
210
  "figma": [],
210
211
  "approved": "2026-10-21",
211
- "reason": "code-only wrapper: each component variant already draws its icon at the size and stroke ADR-017 gives that size"
212
+ "reason": "code-only wrapper: each component variant already draws its icon at the size and stroke ADR-014 gives that size"
212
213
  }
213
214
  },
214
215
  "stories": {
@@ -295,7 +296,7 @@
295
296
  "importFromTabler": ".ai/skills/icons-to-figma.md",
296
297
  "createCustomIcon": [
297
298
  "1. Study 2–3 reference icons from customIconRules.referenceIcons",
298
- "2. Sketch paths on 24×24 grid, stroke-width=1.8 (the ADR-017 rule at 24px), rounded caps",
299
+ "2. Sketch paths on 24×24 grid, stroke-width=1.8 (the ADR-014 rule at 24px), rounded caps",
299
300
  "3. Export SVG — extract the path d= attribute",
300
301
  "4. Add to Icons.stories.tsx ICONS array",
301
302
  "5. Create .mjs file in packages/core/node_modules/@tabler/icons-react/dist/esm/icons/ (if custom)",
@@ -5,10 +5,11 @@
5
5
  "status": "stable",
6
6
  "purpose": "Triggers an action via a single icon, with no visible text label — a toolbar action, a row action, a close/dismiss control.",
7
7
  "import": "import { IconButton } from '@helixds/react';",
8
+ "archetype": "actions-navigation",
8
9
  "neverUseFor": [
9
10
  "Any action without an unambiguous, universally recognizable icon — use Button with a text label instead; a mystery-meat icon is worse than no shortcut at all",
10
11
  "The primary CTA of a view — a labelled Button reads with more intent and is easier to scan for",
11
- "A toggle/pressed state (e.g. bold/italic in a toolbar) — that needs aria-pressed and a distinct on/off visual, neither of which IconButton models; compose a dedicated toggle control instead"
12
+ "A toggle/pressed state (e.g. bold/italic in a toolbar) — that needs aria-pressed and a distinct on/off visual, neither of which IconButton models; use Switch instead"
12
13
  ],
13
14
 
14
15
  "rationale": "IconButton shares Button's exact height scale (ADR-004) by aliasing the same semantic.size rungs, so an icon-only action always lines up with a labelled Button beside it. Because there is no visible text, the accessible label is required by the type system (4.1.2), and it's limited to universally recognizable icons.",
@@ -2,9 +2,10 @@
2
2
  "$schema": "../component.schema.json",
3
3
  "name": "Input",
4
4
  "version": "2.0.0",
5
- "status": "stable",
5
+ "status": "draft",
6
6
  "purpose": "Allows users to enter a single line of free-form text.",
7
7
  "import": "import { Input } from '@helixds/react';",
8
+ "archetype": "text-input",
8
9
  "neverUseFor": [
9
10
  "Multi-line text — use Textarea instead",
10
11
  "File uploads — use FileInput",
@@ -4,20 +4,21 @@
4
4
  "version": "0.3.0",
5
5
  "status": "stable",
6
6
 
7
- "purpose": "A Helix-styled, portaled popup listbox anchored to a trigger element — the internal primitive Select uses instead of a native <select> dropdown, and the foundation for any future popup list (Combobox, a context menu, a DatePicker's own internals).",
7
+ "purpose": "A Helix-styled, portaled popup listbox anchored to a trigger element — the internal primitive Select uses instead of a native <select> dropdown, and the foundation for any future popup list (a context menu, a DatePicker's own internals).",
8
8
  "import": "import { Menu } from '@helixds/react';",
9
+ "archetype": "overlays",
9
10
 
10
11
  "neverUseFor": [
11
12
  "A standalone navigable menu bar — this is a single anchored popup list, not a menubar widget",
12
13
  "Content that isn't a flat or single-level-grouped list of choices — this is a listbox, not a generic popover"
13
14
  ],
14
15
 
15
- "rationale": "Menu is the hand-rolled, portaled listbox (ADR-013) that Select and MultiSelect use instead of a native <select> popup, so options can be styled with tokens and rendered in the top layer. Rows are semantic.size.m (32px) to match field triggers, and keyboard handling lives in the consumer's trigger so one primitive serves every future popup list. It grows in from its trigger (scale-enter 0.97 to 1 over semantic.duration.enter) and, when closed, stays on screen for semantic.duration.exit settling to scale-exit 0.99 — inert and hidden from assistive tech while it does — eased with semantic.easing.gentle (transitions.dev menu dropdown); under prefers-reduced-motion it appears and goes at once.",
16
+ "rationale": "Menu is a hand-rolled WAI-ARIA listbox (role=\"listbox\", role=\"option\" with aria-selected), the popup that Select, MultiSelect and Combobox use instead of a native <select>, whose OS-drawn dropdown can't be styled. It gives up the native mobile picker sheet, a known trade-off. It's portaled to document.body so no ancestor's overflow: hidden or z-index can clip or bury it. It always opens below its trigger, left-aligned, and never flips above: the page scrolls instead, because a field's menu belongs under the field. It's clamped only horizontally, 8px from the viewport edge. Keyboard handling lives in the consumer's trigger, so one primitive serves every popup list; multiple selection is the same listbox with aria-multiselectable, not a second component. Rows are semantic.size.m (32px) to match field triggers, with a min-height and paddingY so a wrapped label grows the row instead of being clipped. The 2px gap between items is a literal, smaller than the 4px bottom of the spacing scale, so hovering between rows always shows a seam. The group divider is asymmetric on purpose: 8px above and 16px before the group label. Menu grows in from its trigger (scale-enter 0.97 to 1 over semantic.duration.enter) and, when closed, stays on screen for semantic.duration.exit settling to scale-exit 0.99, inert and hidden from assistive tech while it does, eased with semantic.easing.gentle (transitions.dev menu dropdown). Under prefers-reduced-motion it appears and disappears at once. Both scales are Menu-local literals, tuned to its size.",
16
17
 
17
18
  "governance": {
18
19
  "mayExtendLocally": [
19
20
  "Supply options and groups through the documented props",
20
- "Build new DS popup lists (Combobox, context menu) on top of Menu"
21
+ "Build new DS popup lists (a context menu) on top of Menu"
21
22
  ],
22
23
  "mustEscalateToDS": [
23
24
  "Using Menu as a generic popover or a menubar",
@@ -47,7 +48,7 @@
47
48
  { "name": "anchorRef", "type": "React.RefObject<HTMLElement | null>", "required": true, "description": "The trigger element the menu positions itself against." },
48
49
  { "name": "options", "type": "(MenuOption | MenuOptionGroup)[]", "required": true, "description": "Flat options or grouped options: { value, label, labelEnd?, disabled? } or { label, options }. labelEnd renders on the option's end edge (menu-item-label-end)." },
49
50
  { "name": "value", "type": "string | undefined", "description": "Currently selected value, for aria-selected + visual highlight." },
50
- { "name": "multiple", "type": "boolean", "default": false, "description": "Multi-selection (ADR-019): aria-multiselectable on the listbox, every value in `values` marked aria-selected. `value` is ignored when set." },
51
+ { "name": "multiple", "type": "boolean", "default": false, "description": "Multi-selection (see MultiSelect's contract rationale): aria-multiselectable on the listbox, every value in `values` marked aria-selected. `value` is ignored when set." },
51
52
  { "name": "values", "type": "string[] | undefined", "description": "Selected values when `multiple` is set." },
52
53
  { "name": "activeValue", "type": "string | undefined", "description": "Keyboard-highlighted value (not yet selected) — the consumer owns keyboard nav on its trigger and passes this down; Menu renders the highlight and exposes ids for aria-activedescendant." },
53
54
  { "name": "onSelect", "type": "(value: string) => void", "required": true, "description": "Fires when an option is clicked." },
@@ -74,8 +75,8 @@
74
75
  },
75
76
 
76
77
  "a11y": {
77
- "role": "listbox (hand-rolled — see ADR-013)",
78
- "keyboardNav": ["Handled by the consumer's trigger, not Menu itself — Menu is presentational plus click-to-select. See Select's own contract for the actual Arrow/Home/End/typeahead handling."],
78
+ "role": "listbox (hand-rolled — see rationale)",
79
+ "keyboardNav": ["Handled by the consumer's trigger, not Menu itself — Menu is presentational plus click-to-select. See Select's own contract for the actual Arrow/Home/End/Enter/Escape handling (no typeahead)."],
79
80
  "wcag": ["1.3.1 Info and Relationships", "2.1.1 Keyboard", "2.4.7 Focus Visible", "4.1.2 Name Role Value"],
80
81
  "applied": {
81
82
  "nativeElement": "div",