wimui 0.59.0 → 0.60.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/components/ai/SourceCitation/SourceCitation.cjs +1 -1
- package/dist/components/ai/SourceCitation/SourceCitation.d.ts +5 -1
- package/dist/components/ai/SourceCitation/SourceCitation.js +10 -8
- package/dist/components/data-display/DataGrid/DataGrid.cjs +1 -1
- package/dist/components/data-display/DataGrid/DataGrid.d.ts +5 -1
- package/dist/components/data-display/DataGrid/DataGrid.js +54 -53
- package/dist/components/data-display/FAQSection/FAQSection.cjs +1 -1
- package/dist/components/data-display/FAQSection/FAQSection.d.ts +5 -1
- package/dist/components/data-display/FAQSection/FAQSection.js +5 -3
- package/dist/components/data-display/TreeView/TreeView.cjs +1 -1
- package/dist/components/data-display/TreeView/TreeView.d.ts +5 -1
- package/dist/components/data-display/TreeView/TreeView.js +87 -87
- package/dist/components/feedback/Notification/Notification.cjs +1 -1
- package/dist/components/feedback/Notification/Notification.d.ts +5 -1
- package/dist/components/feedback/Notification/Notification.js +10 -8
- package/dist/components/feedback/Toast/Toast.cjs +1 -1
- package/dist/components/feedback/Toast/Toast.d.ts +5 -1
- package/dist/components/feedback/Toast/Toast.js +11 -9
- package/dist/components/form/SignaturePad/SignaturePad.cjs +1 -1
- package/dist/components/form/SignaturePad/SignaturePad.d.ts +5 -1
- package/dist/components/form/SignaturePad/SignaturePad.js +47 -47
- package/dist/components/navigation/CommandPalette/CommandPalette.cjs +1 -1
- package/dist/components/navigation/CommandPalette/CommandPalette.d.ts +5 -1
- package/dist/components/navigation/CommandPalette/CommandPalette.js +11 -6
- package/dist/components/navigation/Pagination/Pagination.cjs +1 -1
- package/dist/components/navigation/Pagination/Pagination.d.ts +5 -1
- package/dist/components/navigation/Pagination/Pagination.js +65 -63
- package/dist/components/overlay/Menu/Menu.cjs +1 -1
- package/dist/components/overlay/Menu/Menu.d.ts +4 -0
- package/dist/components/overlay/Menu/Menu.js +23 -21
- package/dist/llms-full.txt +19 -1
- package/dist/llms.txt +1 -1
- package/dist/wimui.umd.js +2 -2
- package/package.json +1 -1
|
@@ -21,21 +21,21 @@ var f = s.createContext({
|
|
|
21
21
|
let e = s.useContext(f);
|
|
22
22
|
if (!e) throw Error("Menu sub-components must be used within a Menu");
|
|
23
23
|
return e;
|
|
24
|
-
}, m = ({ children: n, className: r, asChild: i = !1, mode: a = "vertical", defaultOpenKeys: d = [] }) => {
|
|
25
|
-
let [
|
|
24
|
+
}, m = ({ children: n, className: r, asChild: i = !1, mode: a = "vertical", defaultOpenKeys: d = [], "aria-label": p, "aria-labelledby": m }) => {
|
|
25
|
+
let [h, g] = c(new Set(d)), [_, v] = c(0), y = s.useRef(0);
|
|
26
26
|
s.useEffect(() => {
|
|
27
|
-
|
|
27
|
+
y.current = 0;
|
|
28
28
|
});
|
|
29
|
-
let
|
|
30
|
-
let e =
|
|
31
|
-
return
|
|
32
|
-
},
|
|
33
|
-
|
|
29
|
+
let b = () => {
|
|
30
|
+
let e = y.current;
|
|
31
|
+
return y.current += 1, e;
|
|
32
|
+
}, x = (e) => {
|
|
33
|
+
g((t) => {
|
|
34
34
|
let n = new Set(t);
|
|
35
35
|
return n.has(e) ? n.delete(e) : n.add(e), n;
|
|
36
36
|
});
|
|
37
|
-
},
|
|
38
|
-
let t = Array.from(
|
|
37
|
+
}, S = s.useRef(null), C = (e) => {
|
|
38
|
+
let t = Array.from(S.current?.querySelectorAll("[role=\"menuitem\"]:not([aria-disabled=\"true\"])") || []), n = t.indexOf(document.activeElement);
|
|
39
39
|
if (n !== -1) {
|
|
40
40
|
if (a === "vertical" || a === "inline") {
|
|
41
41
|
if (e.key === "ArrowDown") e.preventDefault(), t[(n + 1) % t.length]?.focus();
|
|
@@ -55,24 +55,26 @@ var f = s.createContext({
|
|
|
55
55
|
r.getAttribute("aria-haspopup") === "true" && r.getAttribute("aria-expanded") === "false" && (e.preventDefault(), r.click());
|
|
56
56
|
}
|
|
57
57
|
}
|
|
58
|
-
e.key === "Home" ? (e.preventDefault(),
|
|
58
|
+
e.key === "Home" ? (e.preventDefault(), v(0), t[0]?.focus()) : e.key === "End" && (e.preventDefault(), v(t.length - 1), t[t.length - 1]?.focus());
|
|
59
59
|
}
|
|
60
|
-
},
|
|
60
|
+
}, w = i ? e : "ul";
|
|
61
61
|
return /* @__PURE__ */ u(f.Provider, {
|
|
62
62
|
value: {
|
|
63
|
-
expandedItems:
|
|
64
|
-
toggleItem:
|
|
65
|
-
containerRef:
|
|
63
|
+
expandedItems: h,
|
|
64
|
+
toggleItem: x,
|
|
65
|
+
containerRef: S,
|
|
66
66
|
mode: a,
|
|
67
|
-
focusedIndex:
|
|
68
|
-
setFocusedIndex:
|
|
69
|
-
registerItem:
|
|
67
|
+
focusedIndex: _,
|
|
68
|
+
setFocusedIndex: v,
|
|
69
|
+
registerItem: b
|
|
70
70
|
},
|
|
71
|
-
children: /* @__PURE__ */ u(
|
|
72
|
-
ref:
|
|
71
|
+
children: /* @__PURE__ */ u(w, {
|
|
72
|
+
ref: S,
|
|
73
73
|
className: l("wim-menu", o.root, o[a], r),
|
|
74
74
|
role: "menu",
|
|
75
|
-
|
|
75
|
+
"aria-label": m ? void 0 : p,
|
|
76
|
+
"aria-labelledby": m,
|
|
77
|
+
onKeyDown: C,
|
|
76
78
|
children: /* @__PURE__ */ u(t, { children: n })
|
|
77
79
|
})
|
|
78
80
|
});
|
package/dist/llms-full.txt
CHANGED
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
|
|
5
5
|
## What this is
|
|
6
6
|
|
|
7
|
-
**wimui** v0.
|
|
7
|
+
**wimui** v0.60.0 — a React 19 component library: 228 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
|
|
|
@@ -1703,6 +1703,8 @@ so the unit does not have to be repeated in the label.
|
|
|
1703
1703
|
- `required: boolean` — Whether to show the required indicator
|
|
1704
1704
|
- `layout: "vertical" | "horizontal"` = "vertical" — Layout direction of label and field
|
|
1705
1705
|
- `canvasAriaLabel: string` — Aria label for the canvas
|
|
1706
|
+
- `aria-label: string` — Accessible name for the canvas when no visible `label` is provided. Takes precedence over `canvasAriaLabel`.
|
|
1707
|
+
- `aria-labelledby: string` — ID of the element that labels the canvas when no visible `label` is provided.
|
|
1706
1708
|
- **Slider** — An input to capture a numeric value from a specified range by dragging a knob
|
|
1707
1709
|
- `value: number` — Current value (controlled)
|
|
1708
1710
|
- `defaultValue: number` = 0 — Default value (uncontrolled)
|
|
@@ -2001,6 +2003,8 @@ origin while the card it was meant to cover was 1248x75.
|
|
|
2001
2003
|
- `onClose: (id?: string) => void` — Callback when notification is closed
|
|
2002
2004
|
- `closable: boolean` = true — Whether to show close button
|
|
2003
2005
|
- `className: string` — Additional class name
|
|
2006
|
+
- `aria-label: string` — Accessible name for the notification.
|
|
2007
|
+
- `aria-labelledby: string` — ID of the element that labels the notification. Takes precedence over `aria-label`.
|
|
2004
2008
|
- **Progress** — Progress bar
|
|
2005
2009
|
- ⚠️ 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`.
|
|
2006
2010
|
- `value: number` = 0 — Current value of the progress bar.
|
|
@@ -2114,6 +2118,8 @@ follows the theme and never needs a hand-mixed colour.
|
|
|
2114
2118
|
@default true
|
|
2115
2119
|
- `onClose: (id?: string) => void` — Called with the toast id when the toast is closed.
|
|
2116
2120
|
- `className: string` — Additional CSS class name.
|
|
2121
|
+
- `aria-label: string` — Accessible name for the toast.
|
|
2122
|
+
- `aria-labelledby: string` — ID of the element that labels the toast. Takes precedence over `aria-label`.
|
|
2117
2123
|
- **Tour** — Sequential guided walkthroughs to onboard users or highlight features
|
|
2118
2124
|
- `steps: TourStep[]` (required) — Steps of the tour. Each step targets an element via a CSS selector.
|
|
2119
2125
|
- `open: boolean` (required) — Whether the tour is shown.
|
|
@@ -2222,6 +2228,8 @@ Useful for URL-based pagination (e.g. wrap with a Link via PaginationPage asChil
|
|
|
2222
2228
|
- `showTotal: (total: number, range: [number, number]) => React.ReactNode` — Function to display the total count
|
|
2223
2229
|
- `showQuickJumper: boolean` = false — Whether to show quick jumper
|
|
2224
2230
|
- `labels: { prevPage?: string; nextPage?: string; pageAriaLabel?: (page: number) => string; itemsPerPage?: string; goTo?: string; go?: string; pageSizeAriaLabel?: string; jumpToPageAriaLabel?: string; navAriaLabel?: string; totalLabel?: string; }` = {} — Labels for internationalization
|
|
2231
|
+
- `aria-label: string` — Accessible name for the navigation landmark. Takes precedence over `labels.navAriaLabel`.
|
|
2232
|
+
- `aria-labelledby: string` — ID of the element that labels the navigation landmark. Takes precedence over `aria-label`.
|
|
2225
2233
|
- **SpeedDial** — Floating action button that expands sub-actions on hover or click.
|
|
2226
2234
|
- `actions: SpeedDialAction[]` (required) — Actions to display when SpeedDial is open
|
|
2227
2235
|
- `icon: keyof typeof ALL_ICONS` = "PlusIcon" — Icon name for the main button when closed
|
|
@@ -2479,6 +2487,8 @@ drops secondary text below the AA contrast floor.
|
|
|
2479
2487
|
- `infiniteScroll: { hasMore: boolean; onLoadMore: () => void; threshold?: number; }` — Infinite-scroll configuration for dynamic loading
|
|
2480
2488
|
- `className: string` — Additional class names
|
|
2481
2489
|
- `ariaLabel: string` — Accessibility label for the grid
|
|
2490
|
+
- `aria-label: string` — Accessible name for the grid. Takes precedence over `ariaLabel`.
|
|
2491
|
+
- `aria-labelledby: string` — ID of the element that labels the grid. Takes precedence over `aria-label`.
|
|
2482
2492
|
- **DescriptionList** — Key-value pairs
|
|
2483
2493
|
- `children: React.ReactNode` (required) — DescriptionListItem elements
|
|
2484
2494
|
- `className: string` — Additional class names
|
|
@@ -2503,6 +2513,8 @@ in; use `"center"` only when the empty state is the only thing in its region.
|
|
|
2503
2513
|
- left: title and description on the left, accordion on the right (desktop and up).
|
|
2504
2514
|
- `accordionProps: Omit<AccordionProps, "children">` — Props passed to the inner Accordion component.
|
|
2505
2515
|
- `className: string` — Additional class names.
|
|
2516
|
+
- `aria-label: string` — Accessible name for the section. A named section is exposed as a region landmark.
|
|
2517
|
+
- `aria-labelledby: string` — ID of the element that labels the section. Takes precedence over `aria-label`.
|
|
2506
2518
|
- **InfiniteScroll** — Infinite scroll control
|
|
2507
2519
|
- `children: React.ReactNode` (required) — Content to display.
|
|
2508
2520
|
- `hasMore: boolean` = false — Whether there is more data to load.
|
|
@@ -2786,6 +2798,8 @@ anything is measured; long text is truncated and read in full by assistive techn
|
|
|
2786
2798
|
- `virtualThreshold: number` = 100 — Node count threshold at which virtualization kicks in.
|
|
2787
2799
|
- `labels: { searchPlaceholder?: string; searchAriaLabel?: string; expandLabel?: (label: string) => string; collapseLabel?: (label: string) => string; treeAriaLabel?: string; }` = {} — Labels for internationalization
|
|
2788
2800
|
- `labelId: string` — Accessibility label ID
|
|
2801
|
+
- `aria-label: string` — Accessible name for the tree. Takes precedence over `labels.treeAriaLabel`.
|
|
2802
|
+
- `aria-labelledby: string` — ID of the element that labels the tree. Takes precedence over `aria-label`.
|
|
2789
2803
|
- `styles: { root?: string; item?: string; search?: string; searchInput?: string; labelContainer?: string; iconWrapper?: string; expandBtn?: string; checkbox?: string; icon?: string; }` — Custom styles for internal parts
|
|
2790
2804
|
- **VirtualList** — Efficiently renders large lists by virtualizing off-screen items
|
|
2791
2805
|
- `items: T[]` (required) — Array of items to display
|
|
@@ -2869,6 +2883,8 @@ dismissed by an outside click or Escape.
|
|
|
2869
2883
|
- `mode: "vertical" | "horizontal" | "inline"` = "vertical" — Mode of the menu
|
|
2870
2884
|
- `defaultSelectedKeys: string[]` — Default selected keys
|
|
2871
2885
|
- `defaultOpenKeys: string[]` = [] — Default opened submenu keys
|
|
2886
|
+
- `aria-label: string` — Accessible name for the menu.
|
|
2887
|
+
- `aria-labelledby: string` — ID of the element that labels the menu. Takes precedence over `aria-label`.
|
|
2872
2888
|
- **Popconfirm** — Confirmation overlay
|
|
2873
2889
|
- `title: ReactNode` (required) — The title of the confirmation box
|
|
2874
2890
|
- `description: ReactNode` — The description of the confirmation box
|
|
@@ -3484,6 +3500,8 @@ written in the markdown. Default `"2xl"` keeps the historical mapping
|
|
|
3484
3500
|
- `index: number` — Numeric citation index shown as a badge (e.g. 1, 2, 3)
|
|
3485
3501
|
- `domain: string` — Domain label shown below the title (auto-derived from url when omitted)
|
|
3486
3502
|
- `className: string` — Additional CSS class
|
|
3503
|
+
- `aria-label: string` — Accessible name for the citation.
|
|
3504
|
+
- `aria-labelledby: string` — ID of the element that labels the citation. Takes precedence over `aria-label`.
|
|
3487
3505
|
- **StreamingText** — Renders text with a typewriter-like animation, ideal for AI chat responses.
|
|
3488
3506
|
- `content: string` (required) — The markdown text content to render
|
|
3489
3507
|
- `isStreaming: boolean` = false — When true, a blinking cursor is shown at the end of the content
|
package/dist/llms.txt
CHANGED
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
|
|
5
5
|
## What this is
|
|
6
6
|
|
|
7
|
-
**wimui** v0.
|
|
7
|
+
**wimui** v0.60.0 — a React 19 component library: 228 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
|
|