wimui 0.9.0 → 0.11.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 (106) hide show
  1. package/dist/components/_internal/FieldCharacterCount/field-character-count.module.cjs +1 -1
  2. package/dist/components/_internal/FieldCharacterCount/field-character-count.module.js +1 -1
  3. package/dist/components/_internal/accessibleName.cjs +2 -0
  4. package/dist/components/_internal/accessibleName.d.ts +54 -0
  5. package/dist/components/_internal/accessibleName.js +7 -0
  6. package/dist/components/_internal/useIndicator.cjs +1 -1
  7. package/dist/components/_internal/useIndicator.d.ts +16 -1
  8. package/dist/components/_internal/useIndicator.js +15 -12
  9. package/dist/components/ai/CodeBlock/code-block.module.cjs +1 -1
  10. package/dist/components/ai/CodeBlock/code-block.module.js +1 -1
  11. package/dist/components/ai/CodeDiffViewer/code-diff-viewer.module.cjs +1 -1
  12. package/dist/components/ai/CodeDiffViewer/code-diff-viewer.module.js +2 -2
  13. package/dist/components/ai/MarkdownRenderer/markdown-renderer.module.cjs +1 -1
  14. package/dist/components/ai/MarkdownRenderer/markdown-renderer.module.js +1 -1
  15. package/dist/components/ai/StreamingText/streaming-text.module.cjs +1 -1
  16. package/dist/components/ai/StreamingText/streaming-text.module.js +1 -1
  17. package/dist/components/ai/Terminal/terminal.module.cjs +1 -1
  18. package/dist/components/ai/Terminal/terminal.module.js +1 -1
  19. package/dist/components/data-display/Badge/badge.module.cjs +1 -1
  20. package/dist/components/data-display/Badge/badge.module.js +1 -1
  21. package/dist/components/data-display/Calendar/calendar.module.cjs +1 -1
  22. package/dist/components/data-display/Calendar/calendar.module.js +1 -1
  23. package/dist/components/data-display/Chip/chip.module.cjs +1 -1
  24. package/dist/components/data-display/Chip/chip.module.js +2 -2
  25. package/dist/components/data-display/JsonViewer/json-viewer.module.cjs +1 -1
  26. package/dist/components/data-display/JsonViewer/json-viewer.module.js +3 -3
  27. package/dist/components/data-display/Markdown/markdown.module.cjs +1 -1
  28. package/dist/components/data-display/Markdown/markdown.module.js +1 -1
  29. package/dist/components/data-display/PullToRefresh/PullToRefresh.cjs +1 -1
  30. package/dist/components/data-display/PullToRefresh/PullToRefresh.js +22 -20
  31. package/dist/components/data-display/Stats/stats.module.cjs +1 -1
  32. package/dist/components/data-display/Stats/stats.module.js +1 -1
  33. package/dist/components/data-display/Tag/tag.module.cjs +1 -1
  34. package/dist/components/data-display/Tag/tag.module.js +1 -1
  35. package/dist/components/data-display/TreeView/tree-view.module.cjs +1 -1
  36. package/dist/components/data-display/TreeView/tree-view.module.js +2 -2
  37. package/dist/components/feedback/Alert/alert.module.cjs +1 -1
  38. package/dist/components/feedback/Alert/alert.module.js +2 -2
  39. package/dist/components/feedback/ErrorBoundary/errorboundary.module.cjs +1 -1
  40. package/dist/components/feedback/ErrorBoundary/errorboundary.module.js +1 -1
  41. package/dist/components/feedback/Notification/notification.module.cjs +1 -1
  42. package/dist/components/feedback/Notification/notification.module.js +2 -2
  43. package/dist/components/feedback/Progress/Progress.cjs +1 -1
  44. package/dist/components/feedback/Progress/Progress.d.ts +15 -6
  45. package/dist/components/feedback/Progress/Progress.js +29 -28
  46. package/dist/components/feedback/ProgressRing/ProgressRing.cjs +2 -0
  47. package/dist/components/feedback/ProgressRing/ProgressRing.d.ts +57 -0
  48. package/dist/components/feedback/ProgressRing/ProgressRing.js +51 -0
  49. package/dist/components/feedback/ProgressRing/progress-ring.module.cjs +2 -0
  50. package/dist/components/feedback/ProgressRing/progress-ring.module.js +25 -0
  51. package/dist/components/feedback/Result/Result.cjs +1 -1
  52. package/dist/components/feedback/Result/Result.d.ts +11 -1
  53. package/dist/components/feedback/Result/Result.js +3 -3
  54. package/dist/components/feedback/Result/result.module.cjs +1 -1
  55. package/dist/components/feedback/Result/result.module.js +8 -3
  56. package/dist/components/form/Cascader/cascader.module.cjs +1 -1
  57. package/dist/components/form/Cascader/cascader.module.js +6 -6
  58. package/dist/components/form/SignaturePad/signature-pad.module.cjs +1 -1
  59. package/dist/components/form/SignaturePad/signature-pad.module.js +6 -6
  60. package/dist/components/form/SplitButton/SplitButton.cjs +2 -0
  61. package/dist/components/form/SplitButton/SplitButton.d.ts +78 -0
  62. package/dist/components/form/SplitButton/SplitButton.js +48 -0
  63. package/dist/components/form/SplitButton/split-button.module.cjs +2 -0
  64. package/dist/components/form/SplitButton/split-button.module.js +11 -0
  65. package/dist/components/form/Transfer/transfer.module.cjs +1 -1
  66. package/dist/components/form/Transfer/transfer.module.js +6 -6
  67. package/dist/components/form/TreeSelect/tree-select.module.cjs +1 -1
  68. package/dist/components/form/TreeSelect/tree-select.module.js +6 -6
  69. package/dist/components/typography/Code/code.module.cjs +1 -1
  70. package/dist/components/typography/Code/code.module.js +1 -1
  71. package/dist/components/typography/Text/Text.cjs +1 -1
  72. package/dist/components/typography/Text/Text.d.ts +24 -0
  73. package/dist/components/typography/Text/Text.js +13 -12
  74. package/dist/components/typography/Text/text.module.cjs +1 -1
  75. package/dist/components/typography/Text/text.module.js +11 -10
  76. package/dist/feedback.cjs +1 -1
  77. package/dist/feedback.d.ts +1 -0
  78. package/dist/feedback.js +2 -1
  79. package/dist/form.cjs +1 -1
  80. package/dist/form.d.ts +1 -0
  81. package/dist/form.js +2 -1
  82. package/dist/i18n/generated/keys.d.ts +1 -1
  83. package/dist/icon/grid.cjs +2 -0
  84. package/dist/icon/grid.js +72 -0
  85. package/dist/icon/index.cjs +1 -1
  86. package/dist/icon/index.d.ts +5 -1
  87. package/dist/icon/index.js +98 -94
  88. package/dist/icon/menu.cjs +2 -0
  89. package/dist/icon/menu.js +36 -0
  90. package/dist/icons.cjs +1 -1
  91. package/dist/icons.js +51 -49
  92. package/dist/index.cjs +1 -1
  93. package/dist/index.js +218 -214
  94. package/dist/llms-full.txt +76 -54
  95. package/dist/llms.txt +50 -41
  96. package/dist/locales/en/components.json +3 -1
  97. package/dist/locales/ja/components.json +3 -1
  98. package/dist/locales/pt/components.json +3 -1
  99. package/dist/overlay.cjs +1 -1
  100. package/dist/overlay.js +4 -4
  101. package/dist/reset.css +1 -1
  102. package/dist/styles.css +2 -2
  103. package/dist/types/generated-tokens.d.ts +1 -1
  104. package/dist/wimui.umd.css +1 -1
  105. package/dist/wimui.umd.js +5 -5
  106. package/package.json +32 -5
@@ -4,7 +4,7 @@
4
4
 
5
5
  ## What this is
6
6
 
7
- **wimui** v0.9.0 — a React 19 component library: 216 documented components across 10 categories, with design tokens, dark mode, i18n (en/ja/pt-BR) and WAI-ARIA compliant a11y. Peer deps: react ^19, react-dom ^19 (plus optional peers for specific components — see package.json).
7
+ **wimui** v0.11.0 — a React 19 component library: 218 documented components across 10 categories, with design tokens, dark mode, i18n (en/ja/pt-BR) and WAI-ARIA compliant a11y. Peer deps: react ^19, react-dom ^19 (plus optional peers for specific components — see package.json).
8
8
 
9
9
  ## Install & required setup
10
10
 
@@ -75,9 +75,13 @@ Single components are judged by state/a11y/token compliance. **Composed screens*
75
75
  5. Keep one radius stance per screen (`radius.component` / `radius.container` / `radius.overlay`); don't mix 0 and lg arbitrarily.
76
76
  6. Limit accent color: primary surfaces (solid buttons, emphasis backgrounds) 1–2 per view.
77
77
  7. Give demo content real substance (product-context copy, internally consistent numbers/dates/names — active ≤ total, dates not evenly spaced).
78
- 8. Add intentional "wobble": mix in 1–2 incomplete rows (a truncated long name, a missing optional field, an extreme value, an error/unread state) and show non-happy-path states (hover/focus/disabled/error/empty/loading).
79
- 9. Keep the chrome quiet. Breadcrumb, page title, summary line, toolbar and filter bar frame the content; they must not compete with the protagonist. Don't promote a one-line summary to an `Alert`/`Banner`, don't wrap the filter bar in a `Card` (its border doubles up with the data region's), keep primary surfaces out of the chrome, and don't stack a KPI tile row above a table screen. Corollary of 1 and 6, but it is the rule most often broken on admin/list screens the test is whether the eye lands on the data first.
80
- 10. Check the screen at 390px and 768px before calling it done. The page itself must never scroll sideways (`document.scrollWidth > document.documentElement.clientWidth` is a bug — the usual cause is a group of controls that cannot wrap, e.g. several buttons packed into one `Toolbar.Group`; split them into separate groups). Data tables need their narrow mode turned on (`<DataGrid mobileCard>`) rather than an inner scrollbar: without it columns collapse and a short string like a `Code` lot number breaks one character per line. The switch to cards happens at the `md` container width, so tablets get cards too.
78
+ 8. Keep one elevation stance per screen: don't mix surfaces raised by shadow with surfaces cut by borders. `Card` and `Stats` default to `elevated`, so pass `variant="outline"` when the screen is border-led. If the outer container already casts a shadow, its contents need only a border.
79
+ 9. Never wrap a component that already draws its own frame. `<Card><Table card /></Card>` doubles the border and nests radii (12px inside 4px). `Table` takes a `card` prop and `Stats` is already a Cardplace them directly.
80
+ 10. Always pass `intent` on `Badge` / `Tag` / `Chip`. Their default is `primary` (the accent), so an ordinary value like `pending` or `member` gets painted as loudly as an exception and the colour stops carrying information. Use `intent="neutral"` for ordinary values.
81
+ 11. Pick colour by good/bad, not by direction. `Stats.Trend` ties the arrow and the colour together, so `up` is always the success colour — using it for a metric where up is bad (failures, error rate) renders the bad news as good. Use a colourless form such as `Stats.Description` instead. Don't approximate a meaning the API cannot express.
82
+ 12. Keep the chrome quiet. Breadcrumb, page title, summary line, toolbar and filter bar frame the content; they must not compete with the protagonist. Don't promote a one-line summary to an `Alert`/`Banner`, don't wrap the filter bar in a `Card` (its border doubles up with the data region's), keep primary surfaces out of the chrome, and don't stack a KPI tile row above a table screen. Corollary of protagonist and accent limits, but it is the rule most often broken on admin/list screens — the test is whether the eye lands on the data first.
83
+ 13. Add intentional "wobble": mix in 1–2 incomplete rows (a truncated long name, a missing optional field, an extreme value, an error/unread state) and show non-happy-path states (hover/focus/disabled/error/empty/loading).
84
+ 14. Check the screen at 390px and 768px before calling it done. The page itself must never scroll sideways (`document.scrollWidth > document.documentElement.clientWidth` is a bug — the usual cause is a group of controls that cannot wrap, e.g. several buttons packed into one `Toolbar.Group`; split them into separate groups). Data tables need their narrow mode turned on (`<DataGrid mobileCard>`) rather than an inner scrollbar: without it columns collapse and a short string like a `Code` lot number breaks one character per line. The switch to cards happens at the `md` container width, so tablets get cards too.
81
85
 
82
86
  ## Recipes — copy-paste starting points
83
87
 
@@ -616,7 +620,7 @@ export function RenameWorkspace() {
616
620
  - **AspectRatio** — Fixed ratio container
617
621
  - `ratio: number` = 1 — Aspect ratio (e.g. 16 / 9, 1, 4 / 3)
618
622
  - `children: React.ReactNode` (required) — Child content
619
- - **BentoGrid** — Modern card grid
623
+ - **BentoGrid** — Modern card grid (aka Waffle Menu, Bento Menu, Grid Menu, Candy Bar Menu, Chocolate Bar Menu, ベントーメニュー, ワッフルメニュー)
620
624
  - `children: React.ReactNode` — Grid items (typically BentoGrid.Item elements)
621
625
  - `rowHeight: string` — Fixed height of each grid row (`grid-auto-rows`). Any CSS length; defaults to `18rem`. Lower it when tiles hold compact content so they don't read as mostly-empty panels.
622
626
  - **Box** — Polymorphic box
@@ -706,7 +710,7 @@ export function RenameWorkspace() {
706
710
  - `gap: "xs" | "sm" | "md" | "lg" | "xl"` = "md" — Gap between widgets. Default: "md".
707
711
  - `showEditToggle: boolean` = true — Show the edit toggle button in the header. Default: true.
708
712
  - `label: string` — Dashboard heading label.
709
- - **Divider** — Content separator
713
+ - **Divider** — Content separator (aka Separator, Horizontal Rule)
710
714
  - `orientation: "horizontal" | "vertical"` = "horizontal" — Orientation of the divider
711
715
  - `thickness: number` = 1 — Thickness of the line (px)
712
716
  - **Flex** — Flexible layout
@@ -777,7 +781,7 @@ The container-query wrapper div is preserved to maintain responsive column behav
777
781
  - `children: React.ReactNode` — Content to display
778
782
  - `scrollAxis: "x" | "y" | "both"` = "y" — Axis along which scrolling is allowed
779
783
  - `maxHeight: string` — Maximum height before scrolling (a CSS value, so units other than px are supported)
780
- - **Sidebar** — A collapsible navigation or informational panel on the side of the screen
784
+ - **Sidebar** — A collapsible navigation or informational panel on the side of the screen (aka Source List, Inspector)
781
785
  - `fixed: boolean` — Fixed position
782
786
  - `collapsed: boolean` — Collapsed state
783
787
  - `width: number | string` = 260 — Width when expanded
@@ -822,7 +826,7 @@ The container-query wrapper div is preserved to maintain responsive column behav
822
826
  - `shadow: T | (string & {})` — Box shadow
823
827
  - `display: React.CSSProperties["display"]` — Display
824
828
  - `position: React.CSSProperties["position"]` — Position
825
- - **Toolbar** — Action strip for IconButton, ToggleGroup, and related controls with toolbar keyboard navigation.
829
+ - **Toolbar** — Action strip for IconButton, ToggleGroup, and related controls with toolbar keyboard navigation. (aka Action Bar)
826
830
  - `asChild: boolean` = false — If true, the component will be rendered as its child, merging its props onto that child.
827
831
  - `size: ComponentSizeBasic` = "md" — Visual density for padding and gap. Cascades to `--wim-toolbar-*` CSS variables.
828
832
  @default "md"
@@ -841,7 +845,7 @@ The container-query wrapper div is preserved to maintain responsive column behav
841
845
  - `unmount: boolean` = true — Whether to unmount the content when hidden
842
846
  - `appear: boolean` = false — Whether to run the enter transition on initial mount
843
847
  - `className: string` — Additional class names
844
- - **VisuallyHidden** — Hide content visually while keeping it accessible to screen readers
848
+ - **VisuallyHidden** — Hide content visually while keeping it accessible to screen readers (aka Screen Reader Only, SR Only)
845
849
  - `children: React.ReactNode` (required) — Content that is visually hidden but still read out by screen readers.
846
850
  - **Watermark** — Translucent text or images overlaid on content to indicate ownership or status
847
851
  - `content: string | string[]` — Text content of the watermark (a string or multiple lines)
@@ -880,7 +884,7 @@ Useful for using the button styles with Link components (e.g. from React Router
880
884
  - `joined: boolean` = false — Whether to join the buttons into a single connected unit
881
885
  - `variant: "solid" | "outline" | "ghost"` — Variant applied to all child buttons
882
886
  - `asChild: boolean` = false — Whether to render as a child element.
883
- - **Cascader** — Hierarchical selection
887
+ - **Cascader** — Hierarchical selection (aka Column View, Miller Columns)
884
888
  - `options: CascaderOption[]` = [] — Hierarchical options to select from
885
889
  - `value: string[]` — Selected value path (controlled)
886
890
  - `onChange: (value: string[], selectedOptions: CascaderOption[]) => void` — Callback when the selection changes
@@ -916,7 +920,7 @@ Useful for using the button styles with Link components (e.g. from React Router
916
920
  - `error: string` — Error message
917
921
  - `required: boolean` — Whether to show the required indicator
918
922
  - `disabled: boolean` — Whether the whole group is disabled
919
- - **ColorInput** — Input with color preview
923
+ - **ColorInput** — Input with color preview (aka Color Well, Color Field)
920
924
  - `intent: FieldIntent` = "default" — Semantic intent of the field (e.g. error state)
921
925
  - `variant: "outline" | "ghost"` = "outline" — Visual style variant of the field
922
926
  - `fullWidth: boolean` = false — Whether to take full width of parent
@@ -1166,7 +1170,7 @@ it undefined to let the field track its own selection.
1166
1170
  - `showApplyButton: boolean` = true — Whether to show the apply button
1167
1171
  - `applyLabel: string` — Label of the apply button
1168
1172
  - `onApply: (dataUrl: string) => void` — Callback when the crop is applied (after confirming in the dialog)
1169
- - **InlineEdit** — A component that allows users to switch between a view-only mode and an editable mode in-place.
1173
+ - **InlineEdit** — A component that allows users to switch between a view-only mode and an editable mode in-place. (aka Editable Text)
1170
1174
  - `value: string` — Current text (controlled)
1171
1175
  - `defaultValue: string` — Initial text (uncontrolled)
1172
1176
  - `onChange: (value: string) => void` — Callback when the text changes while editing
@@ -1292,7 +1296,7 @@ so the unit does not have to be repeated in the label.
1292
1296
  - `aria-describedby: string` — ID of the element that describes the field
1293
1297
  - `width: FieldWidth | string | number` — Fixed width of the field (width token, CSS value, or number in px)
1294
1298
  - `fullWidth: boolean` = false — Whether to take full width of parent
1295
- - **NumberInput** — Input with step adjustments
1299
+ - **NumberInput** — Input with step adjustments (aka Spin Button, Numeric Stepper)
1296
1300
  - `mode: "number" | "text"` = "number" — 'number': uses the native type="number" (e.g. quantity steppers)
1297
1301
  'text': uses type="text" + inputmode (e.g. card numbers or IDs where leading zeros must be kept)
1298
1302
  - `hideSpinButton: boolean` = true — Whether to hide the spin buttons
@@ -1337,7 +1341,7 @@ box and receives a **1-based** position — the first box is `1`, not `0`.
1337
1341
  so the unit does not have to be repeated in the label.
1338
1342
  - `styles: React.ComponentProps<typeof InputBase>["styles"]` — Custom styles for internal parts
1339
1343
  - `asChild: boolean` = false — Whether to render as a child element.
1340
- - **PasswordStrength** — Visual meter to indicate password security level
1344
+ - **PasswordStrength** — Visual meter to indicate password security level (aka Strength Meter)
1341
1345
  - `password: string` = "" — Password string to evaluate
1342
1346
  - `score: 0 | 1 | 2 | 3 | 4` — Strength score (the default calculation is used when omitted)
1343
1347
  0: very weak, 1: weak, 2: fair, 3: strong, 4: very strong
@@ -1409,7 +1413,7 @@ so the unit does not have to be repeated in the label.
1409
1413
  - `aria-label: string` — Accessible label when no visible label is provided
1410
1414
  - `aria-labelledby: string` — ID of the element that labels the slider
1411
1415
  - `asChild: boolean` = false — Whether to render as a child element.
1412
- - **Rating** — Star rating
1416
+ - **Rating** — Star rating (aka Star Rating, Rating Indicator)
1413
1417
  - `value: number` — Current value (controlled)
1414
1418
  - `defaultValue: number` = 0 — Default value (uncontrolled)
1415
1419
  - `count: number` = 5 — Total number of stars
@@ -1463,7 +1467,7 @@ so the unit does not have to be repeated in the label.
1463
1467
  - `labels: { bold?: string; italic?: string; underline?: string; strikethrough?: string; h1?: string; h2?: string; h3?: string; ul?: string; ol?: string; link?: string; unlink?: string; removeFormat?: string; toolbar?: string; linkPrompt?: string; linkApply?: string; linkCancel?: string; }` = {} — Labels for internationalization
1464
1468
  - `aria-label: string` — Accessible label when no visible label is provided
1465
1469
  - `aria-labelledby: string` — ID of the element that labels the editor
1466
- - **SearchInput** — Search with clear button
1470
+ - **SearchInput** — Search with clear button (aka Search Field, Search Bar)
1467
1471
  - `intent: FieldIntent` = "default" — Semantic intent of the field (e.g. error state)
1468
1472
  - `variant: "outline" | "ghost"` = "outline" — Visual style variant of the field
1469
1473
  - `fullWidth: boolean` = false — Whether to take full width of parent
@@ -1491,7 +1495,7 @@ so the unit does not have to be repeated in the label.
1491
1495
  so the unit does not have to be repeated in the label.
1492
1496
  - `styles: React.ComponentProps<typeof InputBase>["styles"]` — Custom styles for internal parts
1493
1497
  - `asChild: boolean` = false — Whether to render as a child element.
1494
- - **SegmentedControl** — Button-style controls for switching between a small set of mutually exclusive options
1498
+ - **SegmentedControl** — Button-style controls for switching between a small set of mutually exclusive options (aka Segmented Buttons, Segmented Picker)
1495
1499
  - `options: Option[]` (required) — List of segment options
1496
1500
  - `value: string` (required) — Selected value
1497
1501
  - `onChange: (value: string) => void` (required) — Callback when the selected value changes
@@ -1507,7 +1511,7 @@ so the unit does not have to be repeated in the label.
1507
1511
  - `children: React.ReactNode` — Optional children used when asChild is true
1508
1512
  - `id: string` — Unique ID for the component
1509
1513
  - `styles: { root?: string; item?: string; slider?: string; label?: string; }` — Custom styles for internal parts
1510
- - **Select** — A dropdown menu for selecting one option from a predefined list
1514
+ - **Select** — A dropdown menu for selecting one option from a predefined list (aka Pop-Up Button, Select Menu)
1511
1515
  - `options: SelectOption[] | SelectOptionGroup[]` = [] — List of options (flat or grouped)
1512
1516
  - `value: string` — Selected value (controlled)
1513
1517
  - `onChange: (value: string) => void` — Callback when the selected value changes
@@ -1578,7 +1582,18 @@ so the unit does not have to be repeated in the label.
1578
1582
  - `onChange: (value: string) => void` — Callback when the value changes
1579
1583
  - `defaultValue: string` = "" — Initial value (uncontrolled)
1580
1584
  - `maxLength: number` — Maximum number of characters
1581
- - **Switch** — A binary switch for instantly toggling settings between on and off states
1585
+ - **SplitButton** — SplitButton description.
1586
+ - `children: React.ReactNode` — Text of the main action.
1587
+ - `onClick: React.MouseEventHandler<HTMLButtonElement>` — Called when the main action is pressed.
1588
+ - `actions: SplitButtonAction[]` (required) — Secondary actions listed behind the toggle.
1589
+ - `variant: "solid" | "outline" | "ghost"` = "solid" — Visual style, applied to both halves so they read as one control.
1590
+ - `intent: "default" | "danger" | "success"` = "default" — Intent (semantic color), applied to both halves.
1591
+ - `size: Extract<ComponentSize, "sm" | "md" | "lg">` = "md" — Size of both halves.
1592
+ - `disabled: boolean` = false — Disable the whole control.
1593
+ - `loading: boolean` = false — Show a loading state on the main action.
1594
+ - `toggleLabel: string` (required) — Accessible name for the toggle half. The main half is named by its own text,
1595
+ but the toggle only shows a chevron, so it needs one of its own.
1596
+ - **Switch** — A binary switch for instantly toggling settings between on and off states (aka Toggle, Toggle Switch)
1582
1597
  - `asChild: boolean` = false — If true, the component will be rendered as its child, merging its props onto that child.
1583
1598
  - `size: Extract<ComponentSize, "sm" | "md" | "lg">` = "md" — Size of the switch
1584
1599
  - `className: string` — Additional class names
@@ -1596,7 +1611,7 @@ so the unit does not have to be repeated in the label.
1596
1611
  - `error: string` — Error message
1597
1612
  - `required: boolean` — Whether to show the required indicator
1598
1613
  - `disabled: boolean` — Whether the whole group is disabled
1599
- - **TagInput** — Field for entering free-form text as tags
1614
+ - **TagInput** — Field for entering free-form text as tags (aka Token Field, Chips Input)
1600
1615
  - `value: string[]` — List of tags (controlled)
1601
1616
  - `defaultValue: string[]` = [] — Initial list of tags (uncontrolled)
1602
1617
  - `onChange: (tags: string[]) => void` — Callback when the tags change
@@ -1813,19 +1828,8 @@ When a function is passed, it is called as (error, errorInfo, reset) => ReactNod
1813
1828
  - `closable: boolean` = true — Whether to show close button
1814
1829
  - `className: string` — Additional class name
1815
1830
  - **Progress** — Progress bar
1816
- - `value: number` = 0 Current value of the progress bar.
1817
- @default 0
1818
- - `max: number` = 100 — Maximum value of the progress bar.
1819
- @default 100
1820
- - `intent: IndicatorIntent` = "primary" — Intent (semantic color) of the bar.
1821
- @default "primary"
1822
- - `size: Extract<ComponentSize, "sm" | "md" | "lg">` = "md" — Size of the bar.
1823
- @default "md"
1824
- - `label: string` — Text label displayed above the bar.
1825
- - `showValue: boolean` = false — Whether to display the current value as a percentage.
1826
- @default false
1827
- - `indeterminate: boolean` = false — If true, shows an indeterminate animation instead of a value.
1828
- @default false
1831
+ - ⚠️ Not the same as elsewhere: Material's "Progress Indicator" covers indeterminate spinners as well. WIM's `Progress` is determinate and linear only for the indeterminate case use `Spinner`.
1832
+ - **ProgressRing** — ProgressRing description.
1829
1833
  - **Result** — Task status indicator
1830
1834
  - `intent: Extract< WimIntent, "default" | "success" | "danger" | "info" | "warning" >` = "default" — Semantic intent — determines the icon and color.
1831
1835
  @default "default"
@@ -1835,13 +1839,20 @@ Use for error pages (404, 403, 500).
1835
1839
  - `description: ReactNode` — The description
1836
1840
  - `extra: ReactNode` — Operating area
1837
1841
  - `icon: ReactNode` — Custom icon
1842
+ - `iconSurface: boolean` = false — Sit the icon on a tinted circle in the intent's colour, instead of drawing it bare.
1843
+
1844
+ Off by default so existing pages keep their look. Turn it on when the icon is
1845
+ the page's main visual — a maintenance or error page, where a bare glyph reads
1846
+ as an afterthought. The tint comes from `--wim-color-<intent>-subtle`, so it
1847
+ follows the theme and never needs a hand-mixed colour.
1848
+ @default false
1838
1849
  - `className: string` — Custom class name
1839
1850
  - `children: ReactNode` — The children
1840
1851
  - **ScrollProgress** — Reading progress indicator
1841
1852
  - `color: "primary" | "secondary" | "success" | "warning" | "danger"` = "primary" — Color of the progress bar.
1842
1853
  @default "primary"
1843
1854
  - `target: React.RefObject<HTMLElement | null>` — Element whose scroll position is tracked. Defaults to `window`.
1844
- - **Skeleton** — Placeholder for content loading states.
1855
+ - **Skeleton** — Placeholder for content loading states. (aka Shimmer)
1845
1856
  - `variant: "text" | "rect" | "circle"` = "text" — Shape of the skeleton.
1846
1857
  - `text`: shaped like a line of text.
1847
1858
  - `rect`: rectangle.
@@ -1870,7 +1881,7 @@ Use for error pages (404, 403, 500).
1870
1881
  - `onAction: () => void` — Called when the action button is clicked
1871
1882
  - `onClose: () => void` — Called when the snackbar is closed
1872
1883
  - `className: string` — Additional CSS class name
1873
- - **Spinner** — A rotating icon indicating background activity or data fetching
1884
+ - **Spinner** — A rotating icon indicating background activity or data fetching (aka Activity Indicator)
1874
1885
  - `size: Extract<ComponentSize, "sm" | "md" | "lg" | "xl">` = "md" — Size of the spinner.
1875
1886
  @default "md"
1876
1887
  - `color: "currentColor" | WimColor` = "primary" — Color of the spinner. Accepts a design token color name or "currentColor".
@@ -1898,7 +1909,7 @@ Use for error pages (404, 403, 500).
1898
1909
 
1899
1910
  ### navigation — `import { … } from "wimui/navigation"`
1900
1911
 
1901
- - **Affix** — Sticky elements
1912
+ - **Affix** — Sticky elements (aka Sticky)
1902
1913
  - `offsetTop: number` — Offset distance from the top of the window (in pixels)
1903
1914
  - `offsetBottom: number` — Offset distance from the bottom of the window (in pixels)
1904
1915
  - `onChange: (lastAffixed: boolean) => void` — Callback when the affix state changes
@@ -1906,14 +1917,14 @@ Use for error pages (404, 403, 500).
1906
1917
  - `children: React.ReactNode` (required) — Children to be rendered inside the affix
1907
1918
  - `className: string` — Additional class names
1908
1919
  - `style: React.CSSProperties` — Style attribute
1909
- - **Anchor** — Smooth scroll links
1920
+ - **Anchor** — Smooth scroll links (aka Scrollspy)
1910
1921
  - `items: AnchorLinkItem[]` = [] — Array of anchor link configurations
1911
1922
  - `bounds: number` = 5 — Bounding distance (in pixels) for triggering active state
1912
1923
  - `offset: number` = 0 — Offset (in pixels) from top when clicking to scroll
1913
1924
  - `direction: "vertical" | "horizontal"` = "vertical" — Orientation of the anchor links
1914
1925
  - `className: string` — Additional class names
1915
1926
  - `style: React.CSSProperties` — Style attribute
1916
- - **BackTop** — Back to top button
1927
+ - **BackTop** — Back to top button (aka Back to Top)
1917
1928
  - `target: () => HTMLElement | Window | Document | null` = () => window — Target container that will be scrolled
1918
1929
  - `visibilityHeight: number` = 400 — Scroll height after which the button becomes visible
1919
1930
  - `onClick: (e: React.MouseEvent<HTMLDivElement>) => void` — Callback when clicked
@@ -1922,7 +1933,7 @@ Use for error pages (404, 403, 500).
1922
1933
  - `style: React.CSSProperties` — Style attribute
1923
1934
  - `aria-label: string` — Accessible label for the button
1924
1935
  - `asChild: boolean` = false — Whether to render as a child element.
1925
- - **Breadcrumb** — Location trace
1936
+ - **Breadcrumb** — Location trace (aka Path Bar, Path Control)
1926
1937
  - `items: BreadcrumbItem[]` (required) — Items to display, from the root to the current page.
1927
1938
  - `separator: React.ReactNode` — Separator displayed between items. Defaults to a chevron icon.
1928
1939
  - `size: Extract<ComponentSize, "sm" | "md" | "lg">` = "md" — Size of the breadcrumb.
@@ -1930,11 +1941,11 @@ Use for error pages (404, 403, 500).
1930
1941
  - `className: string` — Additional CSS class name for the container.
1931
1942
  - `ariaLabel: string` — Accessible label of the navigation landmark. Defaults to a localized "breadcrumb" label.
1932
1943
  - `asChild: boolean` — If true, the breadcrumb will be rendered as its child, merging its props onto that child.
1933
- - **CommandPalette** — Cmd+K search overlay
1944
+ - **CommandPalette** — Cmd+K search overlay (aka Command Bar, Quick Open)
1934
1945
  - `children: ReactNode` (required) — Palette parts (CommandPaletteTrigger, CommandPaletteContent, etc.).
1935
1946
  - `open: boolean` — Controlled open state. Use together with onOpenChange.
1936
1947
  - `onOpenChange: (open: boolean) => void` — Called with the next state when the palette is opened or closed.
1937
- - **HamburgerMenu** — Toggleable menu
1948
+ - **HamburgerMenu** — Toggleable menu (aka Sandwich Menu, Navigation Drawer Trigger, Nav Toggle, Cheeseburger Menu, Veggie Burger Menu, Pancake Menu, Bacon Menu, Hot Dog Menu, ハンバーガーメニュー, サンドイッチメニュー)
1938
1949
  - `asChild: boolean` = false — If true, merge button props onto the child element.
1939
1950
  - `open: boolean` = false — Whether the menu is open
1940
1951
  - `onClick: React.MouseEventHandler<HTMLButtonElement>` — Callback function when the menu is toggled
@@ -1993,6 +2004,7 @@ Useful for URL-based pagination (e.g. wrap with a Link via PaginationPage asChil
1993
2004
  - `open: boolean` — Controlled open state
1994
2005
  - `onOpenChange: (open: boolean) => void` — Callback when open state changes
1995
2006
  - **Stepper** — Visual sequence steps
2007
+ - ⚠️ Not the same as elsewhere: In Apple HIG and macOS, a "Stepper" is the control that increments a number — that is `NumberInput` here. WIM's `Stepper` shows progress through a sequence of steps, which is what Material calls a Stepper.
1996
2008
  - `steps: Step[]` = [] — Array of step configurations
1997
2009
  - `current: number` = 0 — Index of the current active step (0-indexed)
1998
2010
  - `direction: "horizontal" | "vertical"` = "horizontal" — Direction of the stepper
@@ -2020,7 +2032,7 @@ Useful for URL-based pagination (e.g. wrap with a Link via PaginationPage asChil
2020
2032
 
2021
2033
  ### data-display — `import { … } from "wimui/data-display"`
2022
2034
 
2023
- - **Accordion** — Collapsible panels
2035
+ - **Accordion** — Collapsible panels (aka Disclosure, Disclosure Group, Expander)
2024
2036
  - `type: "single" | "multiple"` = "single" — Whether one or multiple items can be open at a time
2025
2037
  - `defaultValue: string | string[]` — Initially open item value(s) (uncontrolled)
2026
2038
  - `value: string | string[]` — Open item value(s) (controlled)
@@ -2038,7 +2050,7 @@ Useful for URL-based pagination (e.g. wrap with a Link via PaginationPage asChil
2038
2050
  - `size: Extract<ComponentSize, "sm" | "md" | "lg">` = "md" — Size of the avatar
2039
2051
  - `shape: "circle" | "rounded"` = "circle" — Shape of the avatar
2040
2052
  - `intent: IndicatorIntent` — Intent (semantic color) applied to the avatar
2041
- - **AvatarGroup** — Stacked avatars
2053
+ - **AvatarGroup** — Stacked avatars (aka Face Pile)
2042
2054
  - `children: React.ReactNode` (required) — Avatar elements to group
2043
2055
  - `max: number` — Maximum number of avatars to show before collapsing into a count
2044
2056
  - `size: Extract<ComponentSize, "sm" | "md" | "lg">` = "md" — Size applied to the avatars
@@ -2102,7 +2114,7 @@ Useful for URL-based pagination (e.g. wrap with a Link via PaginationPage asChil
2102
2114
  - `labels: { slideLabel?: (number: number) => string; prevSlide?: string; nextSlide?: string; goToSlide?: (number: number) => string; }` — Labels for manual translation.
2103
2115
  - `className: string` — Additional class names
2104
2116
  - `asChild: boolean` — Whether to use the Radix Slot pattern
2105
- - **Chip** — Filter/Selection tokens
2117
+ - **Chip** — Filter/Selection tokens (aka Pill, Token)
2106
2118
  - `asChild: boolean` = false — If true, the chip will be rendered as its child, merging its props onto that child.
2107
2119
  - `children: React.ReactNode` — Content to display
2108
2120
  - `content: React.ReactNode` — Content to display (alternative to children)
@@ -2173,7 +2185,7 @@ drops secondary text below the AA contrast floor.
2173
2185
  - `size: Extract<ComponentSize, "sm" | "md" | "lg">` = "md" — Size of the text
2174
2186
  - `border: boolean` = false — Whether to show borders (alias of bordered)
2175
2187
  - `bordered: boolean` = false — Whether to show borders
2176
- - **EmptyState** — Missing data placeholder
2188
+ - **EmptyState** — Missing data placeholder (aka Blank Slate, Zero State)
2177
2189
  - `title: React.ReactNode` (required) — Title to display.
2178
2190
  - `description: React.ReactNode` — Description text to display.
2179
2191
  - `icon: React.ReactNode` — Icon to display.
@@ -2231,7 +2243,7 @@ drops secondary text below the AA contrast floor.
2231
2243
  - `children: string` — Markdown string to render (when passed as children).
2232
2244
  - `gfm: boolean` = true — Whether to enable GitHub Flavored Markdown (default: true).
2233
2245
  - `className: string` — Additional class names.
2234
- - **Marquee** — Scrolling text animation
2246
+ - **Marquee** — Scrolling text animation (aka Ticker)
2235
2247
  - `duration: number` = 20 — Animation speed (in seconds). Defaults to `20`.
2236
2248
  - `reverse: boolean` = false — Whether to run the animation in reverse.
2237
2249
  - `pauseOnHover: boolean` = true — Whether to pause the animation on hover.
@@ -2370,7 +2382,7 @@ drops secondary text below the AA contrast floor.
2370
2382
  - `align: "left" | "right" | "alternate"` = "left" — Alignment of the items relative to the line
2371
2383
  - `className: string` — Additional class names
2372
2384
  - `asChild: boolean` — Whether to render as a child element.
2373
- - **TreeView** — Hierarchical data
2385
+ - **TreeView** — Hierarchical data (aka Outline View)
2374
2386
  - `children: React.ReactNode` — JSX-based items (children API). Use this when not using `nodes`.
2375
2387
  - `nodes: TreeViewNode[]` — Node array for data-driven mode.
2376
2388
  - `className: string` — Additional class names
@@ -2404,7 +2416,7 @@ drops secondary text below the AA contrast floor.
2404
2416
 
2405
2417
  ### overlay — `import { … } from "wimui/overlay"`
2406
2418
 
2407
- - **BottomSheet** — Mobile bottom overlay
2419
+ - **BottomSheet** — Mobile bottom overlay (aka Sheet, Action Sheet)
2408
2420
  - `children: React.ReactNode` (required) — Bottom sheet parts (BottomSheetTrigger, BottomSheetContent, etc.).
2409
2421
  - `open: boolean` — Controlled open state. Use together with onOpenChange.
2410
2422
  - `defaultOpen: boolean` = false — Initial open state for uncontrolled usage.
@@ -2416,7 +2428,7 @@ drops secondary text below the AA contrast floor.
2416
2428
  - `className: string` — Additional CSS class name for the container.
2417
2429
  - `disabled: boolean` = false — Disable the context menu
2418
2430
  - `asChild: boolean` = false — If true, merge trigger props onto the child element.
2419
- - **Dialog** — Focused task windows
2431
+ - **Dialog** — Focused task windows (aka Modal, Modal Dialog)
2420
2432
  - `children: React.ReactNode` (required) — Dialog parts (Dialog.Trigger, Dialog.Content, etc.).
2421
2433
  - `open: boolean` — Controlled open state. Use together with onOpenChange.
2422
2434
  - `onOpenChange: (open: boolean) => void` — Called with the next state when the dialog is opened or closed.
@@ -2425,7 +2437,7 @@ drops secondary text below the AA contrast floor.
2425
2437
  - `className: string` — Additional CSS class name.
2426
2438
  - `closeOnOverlayClick: boolean` = true — Whether clicking the overlay closes the dialog.
2427
2439
  @default true
2428
- - **Drawer** — Slide-out detail panels
2440
+ - **Drawer** — Slide-out detail panels (aka Navigation Drawer)
2429
2441
  - `children: React.ReactNode` (required) — Drawer parts (DrawerTrigger, DrawerContent, etc.).
2430
2442
  - `open: boolean` — Controlled open state. Use together with onOpenChange.
2431
2443
  - `onOpenChange: (open: boolean) => void` — Called with the next state when the drawer is opened or closed.
@@ -2437,7 +2449,7 @@ drops secondary text below the AA contrast floor.
2437
2449
  @default true
2438
2450
  - `slideOut: boolean` = true — Whether to animate the drawer when closing.
2439
2451
  @default true
2440
- - **Dropdown** — Overlay selection menu
2452
+ - **Dropdown** — Overlay selection menu (aka Overflow Menu, Kebab Menu, Meatball Menu, Vertical Ellipsis, Horizontal Ellipsis, Three Dots Menu, More Menu, App Switcher, オーバーフローメニュー, ケバブメニュー, ミートボールメニュー)
2441
2453
  - `children: ReactNode` (required) — Dropdown parts (Dropdown.Trigger and Dropdown.Menu).
2442
2454
  - `asChild: boolean` = false — If true, the dropdown will be rendered as its child, merging its props onto that child.
2443
2455
  - **FocusTrap** — Focus management
@@ -2454,6 +2466,7 @@ drops secondary text below the AA contrast floor.
2454
2466
  - `open: boolean` — If provided, controls the open state.
2455
2467
  - `onOpenChange: (open: boolean) => void` — Callback when open state changes.
2456
2468
  - **Menu** — General menus
2469
+ - ⚠️ Not the same as elsewhere: In macOS, a "Menu" is the pull-down from a menu bar. WIM's `Menu` is the list of choices itself; for one that opens from a trigger, use `Dropdown`.
2457
2470
  - `children: ReactNode` (required) — Menu items (MenuItem, MenuItemGroup, SubMenu, MenuDivider).
2458
2471
  - `className: string` — Additional CSS class name for the container.
2459
2472
  - `asChild: boolean` = false — If true, the menu root will be rendered as its child, merging its props onto that child.
@@ -2482,7 +2495,7 @@ drops secondary text below the AA contrast floor.
2482
2495
  - **Portal** — Out-of-hierarchy render
2483
2496
  - `children: React.ReactNode` (required) — The content to be rendered in the portal
2484
2497
  - `container: HTMLElement | null` — The container where the portal will be rendered. Defaults to document.body
2485
- - **Tooltip** — Information on hover
2498
+ - **Tooltip** — Information on hover (aka Help Tag)
2486
2499
  - `children: ReactNode` (required) — Tooltip parts (TooltipTrigger and TooltipContent).
2487
2500
  - `className: string` — Additional CSS class name for the container.
2488
2501
  - `delay: number` = 200 — Delay before showing the tooltip in ms.
@@ -2591,6 +2604,15 @@ use `truncate` to clip it with an ellipsis.
2591
2604
  - `truncate: boolean` = false — Keep the text on one line and clip the overflow with an ellipsis.
2592
2605
  Implies `nowrap`.
2593
2606
  @default false
2607
+ - `lineClamp: number` — Clip the text after this many lines and end it with an ellipsis.
2608
+
2609
+ `truncate` is the one-line case; this is the multi-line one. Use it when the
2610
+ text simply has to stop — a card blurb, a table cell, a list subtitle. If the
2611
+ reader needs a way to see the rest, use `Spoiler` instead: it always renders
2612
+ a toggle, which is the point of that component and the reason it cannot be
2613
+ used for "just stop at three lines".
2614
+
2615
+ Ignored when `truncate` is set (one line wins; they cannot both apply).
2594
2616
  - `content: React.ReactNode` — Content of the text. Alternative to children (children take precedence only with asChild).
2595
2617
  - **Title** — Possesses visual weight (boldness/size) to indicate page structure.
2596
2618
  - `asChild: boolean` = false — If true, the heading will be rendered as its child, merging its props onto that child.
@@ -2692,7 +2714,7 @@ Implies `nowrap`.
2692
2714
  - `radius: "none" | "sm" | "md" | "lg" | "full"` = "md" — Corner radius size
2693
2715
  - `labels: { /** Accessible label for the drag handle */ handleAriaLabel?: string; }` — Labels for internationalization
2694
2716
  - `className: string` — Additional class names
2695
- - **Lightbox** — A high-quality overlay component for displaying images and media with gallery and zoom functionality.
2717
+ - **Lightbox** — A high-quality overlay component for displaying images and media with gallery and zoom functionality. (aka Image Viewer)
2696
2718
  - `children: React.ReactNode` (required) — Lightbox parts (Lightbox.Trigger, Lightbox.Content, etc.)
2697
2719
  - `open: boolean` — Controlled open state
2698
2720
  - `onOpenChange: (open: boolean) => void` — Callback when the open state changes
@@ -3002,7 +3024,7 @@ When set, an expand/collapse toggle is shown.
3002
3024
  - `onNewThread: () => void` — Callback when the new-conversation button is clicked (shows the button when set)
3003
3025
  - `labels: { /** Label of the new-conversation button */ newThread?: string; /** Text shown when there are no threads */ empty?: string; /** Accessible label for each delete button */ delete?: string; /** Accessible label for the list */ listAriaLabel?: string; }` — Labels for internationalization
3004
3026
  - `className: string` — Additional class names
3005
- - **UsageMeter** — UsageMeter (also exported as TokenCounter) visualizes token consumption against a budget such as a model's context window — a labeled bar plus a numeric readout that shifts to warning and danger colors near the limit.
3027
+ - **UsageMeter** — UsageMeter (also exported as TokenCounter) visualizes token consumption against a budget such as a model's context window — a labeled bar plus a numeric readout that shifts to warning and danger colors near the limit. (aka Level Indicator, Capacity Indicator, Meter)
3006
3028
  - `used: number` (required) — Number of tokens used so far
3007
3029
  - `max: number` — Maximum available tokens (e.g. the context window). Omit for a counter-only display.
3008
3030
  - `size: Extract<ComponentSize, "sm" | "md" | "lg">` = "md" — Size of the meter