@alea-design/ui 0.2.0 → 0.3.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 (184) hide show
  1. package/README.md +2 -2
  2. package/dist/components/accordion/Accordion.js +29 -0
  3. package/dist/components/ai/AI.d.ts +5 -1
  4. package/dist/components/ai/AI.js +187 -0
  5. package/dist/components/app/AppParts.d.ts +16 -4
  6. package/dist/components/app/AppParts.js +134 -0
  7. package/dist/components/button/Button.d.ts +1 -1
  8. package/dist/components/button/Button.js +137 -0
  9. package/dist/components/button/Groups.d.ts +1 -1
  10. package/dist/components/button/Groups.js +112 -0
  11. package/dist/components/card/Card.d.ts +3 -2
  12. package/dist/components/card/Card.js +47 -0
  13. package/dist/components/chat/Chat.d.ts +4 -2
  14. package/dist/components/chat/Chat.js +275 -0
  15. package/dist/components/choice/Choice.js +69 -0
  16. package/dist/components/color/Color.d.ts +3 -3
  17. package/dist/components/color/Color.js +98 -0
  18. package/dist/components/combobox/Autocomplete.d.ts +5 -5
  19. package/dist/components/combobox/Autocomplete.js +126 -0
  20. package/dist/components/combobox/ComboBox.d.ts +4 -4
  21. package/dist/components/combobox/ComboBox.js +112 -0
  22. package/dist/components/combobox/Highlight.js +50 -0
  23. package/dist/components/command/CommandPalette.d.ts +10 -3
  24. package/dist/components/command/CommandPalette.js +56 -0
  25. package/dist/components/content/Content.d.ts +1 -1
  26. package/dist/components/content/Content.js +125 -0
  27. package/dist/components/data/Data.js +79 -0
  28. package/dist/components/date/Date.js +109 -0
  29. package/dist/components/display/Display.d.ts +5 -3
  30. package/dist/components/display/Display.js +89 -0
  31. package/dist/components/display/Display2.d.ts +3 -1
  32. package/dist/components/display/Display2.js +75 -0
  33. package/dist/components/emoji/EmojiPicker.js +52 -0
  34. package/dist/components/emoji/emoji-data.js +27 -0
  35. package/dist/components/extras/CodeSteps.d.ts +1 -0
  36. package/dist/components/extras/CodeSteps.js +19 -0
  37. package/dist/components/extras/Extras.d.ts +1 -1
  38. package/dist/components/extras/Extras.js +116 -0
  39. package/dist/components/feedback/Feedback.d.ts +11 -8
  40. package/dist/components/feedback/Feedback.js +185 -0
  41. package/dist/components/feedback/Spinner.js +18 -0
  42. package/dist/components/feedback/Status.d.ts +6 -2
  43. package/dist/components/feedback/Status.js +48 -0
  44. package/dist/components/field/Field.d.ts +1 -1
  45. package/dist/components/field/Field.js +187 -0
  46. package/dist/components/field/FieldLoading.d.ts +1 -1
  47. package/dist/components/field/FieldLoading.js +18 -0
  48. package/dist/components/filter/FilterBar.js +96 -0
  49. package/dist/components/form/Form.d.ts +5 -5
  50. package/dist/components/form/Form.js +53 -0
  51. package/dist/components/icon/Icon.d.ts +2 -2
  52. package/dist/components/icon/Icon.js +66 -0
  53. package/dist/components/icon/icon-cells.js +39 -0
  54. package/dist/components/icon/icon-contexts.d.ts +1 -1
  55. package/dist/components/icon/icon-contexts.js +38 -0
  56. package/dist/components/icon/icon-names.d.ts +1 -1
  57. package/dist/components/icon/icon-names.js +376 -0
  58. package/dist/components/layout/Bento.d.ts +1 -1
  59. package/dist/components/layout/Bento.js +38 -0
  60. package/dist/components/layout/Layout.d.ts +1 -1
  61. package/dist/components/layout/Layout.js +54 -0
  62. package/dist/components/layout/Layout2.d.ts +36 -6
  63. package/dist/components/layout/Layout2.js +105 -0
  64. package/dist/components/layout/Layout3.js +35 -0
  65. package/dist/components/layout/Responsive.d.ts +1 -1
  66. package/dist/components/layout/Responsive.js +32 -0
  67. package/dist/components/list/List.d.ts +3 -2
  68. package/dist/components/list/List.js +82 -0
  69. package/dist/components/list/Lists2.d.ts +6 -4
  70. package/dist/components/list/Lists2.js +60 -0
  71. package/dist/components/media/Media.d.ts +8 -4
  72. package/dist/components/media/Media.js +188 -0
  73. package/dist/components/menu/Menu.d.ts +23 -12
  74. package/dist/components/menu/Menu.js +68 -0
  75. package/dist/components/more/More.d.ts +7 -7
  76. package/dist/components/more/More.js +182 -0
  77. package/dist/components/navigation/Navbar.d.ts +1 -1
  78. package/dist/components/navigation/Navbar.js +27 -0
  79. package/dist/components/navigation/Navigation.js +121 -0
  80. package/dist/components/navigation/Navigation2.d.ts +6 -2
  81. package/dist/components/navigation/Navigation2.js +355 -0
  82. package/dist/components/overlay/Drawer.d.ts +11 -6
  83. package/dist/components/overlay/Drawer.js +39 -0
  84. package/dist/components/overlay/Modal.d.ts +6 -3
  85. package/dist/components/overlay/Modal.js +27 -0
  86. package/dist/components/overlay/Overlay.d.ts +14 -9
  87. package/dist/components/overlay/Overlay.js +76 -0
  88. package/dist/components/overlay/Sheet.d.ts +11 -5
  89. package/dist/components/overlay/Sheet.js +52 -0
  90. package/dist/components/page/Page.d.ts +5 -5
  91. package/dist/components/page/Page.js +132 -0
  92. package/dist/components/page/PageParts.d.ts +5 -5
  93. package/dist/components/page/PageParts.js +109 -0
  94. package/dist/components/picker/Picker.d.ts +11 -11
  95. package/dist/components/picker/Picker.js +294 -0
  96. package/dist/components/picker/Wheel.js +132 -0
  97. package/dist/components/rating/Rating.d.ts +2 -1
  98. package/dist/components/rating/Rating.js +66 -0
  99. package/dist/components/select/Select.d.ts +8 -6
  100. package/dist/components/select/Select.js +146 -0
  101. package/dist/components/shell/AppShell.d.ts +3 -3
  102. package/dist/components/shell/AppShell.js +56 -0
  103. package/dist/components/shell/AppSidebar.d.ts +5 -5
  104. package/dist/components/shell/AppSidebar.js +62 -0
  105. package/dist/components/slider/Slider.d.ts +2 -1
  106. package/dist/components/slider/Slider.js +36 -0
  107. package/dist/components/surface/Surface.d.ts +16 -0
  108. package/dist/components/surface/Surface.js +7 -0
  109. package/dist/components/table/Table.d.ts +4 -3
  110. package/dist/components/table/Table.js +58 -0
  111. package/dist/components/tabs/Tabs.d.ts +1 -0
  112. package/dist/components/tabs/Tabs.js +120 -0
  113. package/dist/components/theme/Theme.d.ts +11 -6
  114. package/dist/components/theme/Theme.js +186 -0
  115. package/dist/components/theme/lens.js +104 -0
  116. package/dist/components/tree/Tree.js +303 -0
  117. package/dist/components/typography/Typography.js +43 -0
  118. package/dist/components/upload/Upload.js +71 -0
  119. package/dist/components/work/Ops.js +24 -0
  120. package/dist/components/work/Work.d.ts +4 -2
  121. package/dist/components/work/Work.js +241 -0
  122. package/dist/css/accordion.css +1 -0
  123. package/dist/css/ai.css +1 -0
  124. package/dist/css/app.css +1 -0
  125. package/dist/css/base.css +1 -0
  126. package/dist/css/button.css +1 -0
  127. package/dist/css/card.css +1 -0
  128. package/dist/css/chat.css +1 -0
  129. package/dist/css/choice.css +1 -0
  130. package/dist/css/color.css +1 -0
  131. package/dist/css/combobox.css +1 -0
  132. package/dist/css/command.css +1 -0
  133. package/dist/css/content.css +1 -0
  134. package/dist/css/data.css +1 -0
  135. package/dist/css/date.css +1 -0
  136. package/dist/css/display.css +1 -0
  137. package/dist/css/emoji.css +1 -0
  138. package/dist/css/extras.css +1 -0
  139. package/dist/css/feedback.css +1 -0
  140. package/dist/css/field.css +1 -0
  141. package/dist/css/filter.css +1 -0
  142. package/dist/css/form.css +1 -0
  143. package/dist/css/groups.json +346 -0
  144. package/dist/css/icon.css +1 -0
  145. package/dist/css/layout.css +1 -0
  146. package/dist/css/list.css +1 -0
  147. package/dist/css/media.css +1 -0
  148. package/dist/css/menu.css +1 -0
  149. package/dist/css/more.css +1 -0
  150. package/dist/css/navigation.css +1 -0
  151. package/dist/css/overlay.css +1 -0
  152. package/dist/css/page.css +1 -0
  153. package/dist/css/picker.css +1 -0
  154. package/dist/css/rating.css +1 -0
  155. package/dist/css/select.css +1 -0
  156. package/dist/css/shell.css +1 -0
  157. package/dist/css/slider.css +1 -0
  158. package/dist/css/surface.css +1 -0
  159. package/dist/css/table.css +1 -0
  160. package/dist/css/tabs.css +1 -0
  161. package/dist/css/tree.css +1 -0
  162. package/dist/css/typography.css +1 -0
  163. package/dist/css/upload.css +1 -0
  164. package/dist/css/work.css +1 -0
  165. package/dist/i18n/strings.js +842 -0
  166. package/dist/index.d.ts +71 -70
  167. package/dist/index.js +398 -7436
  168. package/dist/styles.css +1 -1
  169. package/dist/utils/Blueprint.js +131 -0
  170. package/dist/utils/DotField.js +32 -0
  171. package/dist/utils/attr.d.ts +1 -1
  172. package/dist/utils/attr.js +18 -0
  173. package/dist/utils/blueprintScene.js +161 -0
  174. package/dist/utils/controlled.js +11 -0
  175. package/dist/utils/cx.js +11 -0
  176. package/dist/utils/inert.js +9 -0
  177. package/dist/utils/refs.d.ts +3 -0
  178. package/dist/utils/refs.js +11 -0
  179. package/dist/utils/responsive.js +12 -0
  180. package/dist/utils/scrollEdges.js +31 -0
  181. package/dist/utils/space.js +10 -0
  182. package/dist/utils/vocabulary.d.ts +6 -0
  183. package/dist/utils/vocabulary.js +17 -0
  184. package/package.json +12 -8
@@ -1,8 +1,9 @@
1
+ import { type CSSProperties, type RefAttributes, type ReactElement } from 'react';
1
2
  import type { ReactNode } from 'react';
2
- import { type MenuProps as RACMenuProps, type MenuItemProps as RACMenuItemProps, type MenuTriggerProps, type SubmenuTriggerProps } from 'react-aria-components';
3
+ import { type SectionProps, type SeparatorProps, type MenuProps as RACMenuProps, type MenuItemProps as RACMenuItemProps, type MenuTriggerProps, type SubmenuTriggerProps } from 'react-aria-components';
3
4
  import type { MotionProp } from '@alea-design/motion';
4
- import { type PopoverProps } from '../overlay/Overlay';
5
- import { type BadgeProps } from '../display/Display';
5
+ import { type PopoverProps } from '../overlay/Overlay.js';
6
+ import { type BadgeProps } from '../display/Display.js';
6
7
  export interface MenuProps<T extends object> extends RACMenuProps<T> {
7
8
  /** sm (32 px items, for dense apps and context menus) or md (40 px, default). */
8
9
  size?: 'sm' | 'md';
@@ -17,8 +18,8 @@ export interface MenuItemProps extends Omit<RACMenuItemProps, 'children'> {
17
18
  description?: ReactNode;
18
19
  /** A shortcut shown at the end, e.g. ⌘D. A list of keys, like ['⌘', '⇧', 'P'], shows each key as a keycap. Display only: wire the keys yourself. It is also set as aria-keyshortcuts. */
19
20
  shortcut?: string | string[];
20
- /** danger turns it red, for destructive actions. */
21
- tone?: 'default' | 'danger';
21
+ /** danger turns it red, for destructive actions; neutral (default). */
22
+ tone?: 'neutral' | 'danger' | /** @deprecated Use neutral. */ 'default';
22
23
  /** Something at the end: a count, a status, an icon button. */
23
24
  end?: ReactNode;
24
25
  /** A small badge at the end, after end: a count, New, Beta. It is read with the item. */
@@ -29,18 +30,20 @@ export interface MenuItemProps extends Omit<RACMenuItemProps, 'children'> {
29
30
  chevron?: boolean;
30
31
  }
31
32
  /** One item: an action, a link (href), or a choice in a selectable menu. Slots at the end, in order: end, badge, shortcut and a chevron. */
32
- export declare function MenuItem({ children, icon, description, shortcut, tone, end, badge, badgeTone, chevron, className, textValue, ...props }: MenuItemProps): import("react").JSX.Element;
33
+ export declare function MenuItem({ children, icon, description, shortcut, tone: toneProp, end, badge, badgeTone, chevron, className, textValue, ...props }: MenuItemProps): import("react").JSX.Element;
33
34
  /** A titled group of items. */
34
- export interface MenuSectionProps {
35
+ export interface MenuSectionProps extends Omit<SectionProps<object>, 'children' | 'title' | 'className'> {
36
+ /** Extra class names for the section. */
37
+ className?: string;
35
38
  /** The group heading. */
36
39
  title?: ReactNode;
37
40
  /** The MenuItems. */
38
41
  children: ReactNode;
39
42
  }
40
43
  /** A group of menu items under a title. */
41
- export declare function MenuSection({ title, children }: MenuSectionProps): import("react").JSX.Element;
44
+ export declare const MenuSection: import("react").ForwardRefExoticComponent<MenuSectionProps & RefAttributes<HTMLElement>>;
42
45
  /** A line between groups of items. */
43
- export declare function MenuSeparator(): import("react").JSX.Element;
46
+ export declare const MenuSeparator: import("react").ForwardRefExoticComponent<SeparatorProps & RefAttributes<HTMLElement>>;
44
47
  export interface DropdownMenuProps<T extends object> extends Omit<MenuTriggerProps, 'children' | 'trigger'> {
45
48
  /** The button that opens it (usually a Button or IconButton). */
46
49
  trigger: ReactNode;
@@ -63,9 +66,13 @@ export interface DropdownMenuProps<T extends object> extends Omit<MenuTriggerPro
63
66
  minWidth?: string | number;
64
67
  /** Most height before it scrolls, in px. */
65
68
  maxHeight?: number;
69
+ /** Extra class names for the popup. */
70
+ className?: string;
71
+ /** Inline style for the popup. */
72
+ style?: CSSProperties;
66
73
  }
67
- /** A button that opens a menu: two sizes, a header and footer, a width and a height limit. */
68
- export declare function DropdownMenu<T extends object>({ motion, trigger, children, placement, menuProps, size, header, footer, minWidth, maxHeight, 'aria-label': label, ...props }: DropdownMenuProps<T>): import("react").JSX.Element;
74
+ /** A button that opens a menu: two sizes, a header and footer, a width and a height limit. className, style and ref go to the popup. */
75
+ export declare const DropdownMenu: <T extends object>(props: DropdownMenuProps<T> & RefAttributes<HTMLElement>) => ReactElement | null;
69
76
  export interface SubmenuProps extends Omit<SubmenuTriggerProps, 'children'> {
70
77
  /** The item that opens the submenu. */
71
78
  label: ReactNode;
@@ -82,6 +89,10 @@ export interface SubmenuProps extends Omit<SubmenuTriggerProps, 'children'> {
82
89
  /** Not available: the item is dimmed and the submenu does not open. */
83
90
  isDisabled?: boolean;
84
91
  children: ReactNode;
92
+ /** Extra class names for the submenu popup. */
93
+ className?: string;
94
+ /** Inline style for the submenu popup. */
95
+ style?: CSSProperties;
85
96
  }
86
97
  /** An item that opens another menu (arrow right or hover). It takes the same slots as MenuItem. */
87
- export declare function Submenu({ label, icon, description, end, badge, badgeTone, isDisabled, children, ...props }: SubmenuProps): import("react").JSX.Element;
98
+ export declare const Submenu: import("react").ForwardRefExoticComponent<SubmenuProps & RefAttributes<HTMLElement>>;
@@ -0,0 +1,68 @@
1
+ "use client";
2
+ import { jsx as n, jsxs as u, Fragment as k } from "react/jsx-runtime";
3
+ import { forwardRef as h } from "react";
4
+ import { Menu as z, MenuItem as j, Text as B, Keyboard as C, MenuSection as D, Header as R, Separator as T, SubmenuTrigger as V, MenuTrigger as $ } from "react-aria-components";
5
+ import { Check as K, ChevronRight as F } from "lucide-react";
6
+ import { withBase as y, cx as M } from "../../utils/cx.js";
7
+ import { menuIcon as H } from "../icon/icon-contexts.js";
8
+ import { Popover as S } from "../overlay/Overlay.js";
9
+ import { Badge as L } from "../display/Display.js";
10
+ import { useAttrRef as O } from "../../utils/attr.js";
11
+ import { renamedValue as P } from "../../utils/vocabulary.js";
12
+ function g({ className: a, size: e, ...o }) {
13
+ return /* @__PURE__ */ n(z, { ...o, "data-size": e, className: y("alea-menu", a) });
14
+ }
15
+ const x = { "⌘": "Meta", "⇧": "Shift", "⌥": "Alt", "⌃": "Control" }, q = (a) => {
16
+ if (Array.isArray(a)) return a;
17
+ if (a.includes("+")) return a.split("+");
18
+ let e = 0;
19
+ for (; e < a.length && x[a[e]]; ) e++;
20
+ return [...a.slice(0, e), a.slice(e)].filter(Boolean);
21
+ }, E = (a) => q(a).map((e) => x[e] ?? e).join("+");
22
+ function G({ children: a, icon: e, description: o, shortcut: r, tone: l, end: t, badge: i, badgeTone: m, chevron: c, className: d, textValue: p, ...f }) {
23
+ const s = P("MenuItem", "tone", l, { default: "neutral" }) ?? "neutral", N = O("aria-keyshortcuts", r ? E(r) : void 0);
24
+ return /* @__PURE__ */ n(j, { ...f, ref: N, textValue: p ?? (typeof a == "string" ? a : void 0), "data-tone": s, className: y("alea-option alea-menu-item", d), children: ({ isSelected: v, selectionMode: A, hasSubmenu: w }) => /* @__PURE__ */ u(k, { children: [
25
+ A !== "none" && /* @__PURE__ */ n(K, { size: 16, className: "alea-menu-check", "aria-hidden": "true", "data-on": v || void 0 }),
26
+ e && /* @__PURE__ */ n("span", { className: "alea-option-icon", "aria-hidden": "true", ...H(s), children: e }),
27
+ /* @__PURE__ */ u(B, { slot: "label", className: "alea-option-text", children: [
28
+ /* @__PURE__ */ n("span", { children: a }),
29
+ o && /* @__PURE__ */ n("span", { className: "alea-option-desc", children: o })
30
+ ] }),
31
+ t && /* @__PURE__ */ n("span", { className: "alea-menu-end", children: t }),
32
+ i != null && i !== !1 && /* @__PURE__ */ n(L, { size: "sm", tone: m, className: "alea-menu-badge", children: i }),
33
+ r && /* @__PURE__ */ n(C, { className: "alea-menu-shortcut", "data-keys": Array.isArray(r) || void 0, children: Array.isArray(r) ? r.map((I, b) => /* @__PURE__ */ n("span", { className: "alea-menu-key", children: I }, b)) : r }),
34
+ (w || c) && /* @__PURE__ */ n(F, { size: 16, "aria-hidden": "true", className: "alea-menu-chevron" })
35
+ ] }) });
36
+ }
37
+ const re = h(function({ title: e, children: o, className: r, ...l }, t) {
38
+ return /* @__PURE__ */ u(D, { ...l, ref: t, className: M("alea-option-section", r), children: [
39
+ e && /* @__PURE__ */ n(R, { className: "alea-option-header", children: e }),
40
+ o
41
+ ] });
42
+ }), oe = h(function({ className: e, ...o }, r) {
43
+ return /* @__PURE__ */ n(T, { ...o, ref: r, className: M("alea-menu-separator", e) });
44
+ });
45
+ function J({ motion: a, trigger: e, children: o, placement: r = "bottom start", menuProps: l, size: t, header: i, footer: m, minWidth: c, maxHeight: d, "aria-label": p, className: f, style: s, ...N }, v) {
46
+ return /* @__PURE__ */ u($, { ...N, children: [
47
+ e,
48
+ /* @__PURE__ */ u(S, { ref: v, placement: r, className: M("alea-popover alea-menu-popover", f), motion: a, maxHeight: d, style: c !== void 0 ? { minWidth: c, ...s } : s, children: [
49
+ i && /* @__PURE__ */ n("div", { className: "alea-menu-header", children: i }),
50
+ /* @__PURE__ */ n(g, { "aria-label": p, size: t, ...l, children: o }),
51
+ m && /* @__PURE__ */ n("div", { className: "alea-menu-footer", children: m })
52
+ ] })
53
+ ] });
54
+ }
55
+ const te = h(J), ie = h(function({ label: e, icon: o, description: r, end: l, badge: t, badgeTone: i, isDisabled: m, children: c, className: d, style: p, ...f }, s) {
56
+ return /* @__PURE__ */ u(V, { ...f, children: [
57
+ /* @__PURE__ */ n(G, { icon: o, description: r, end: l, badge: t, badgeTone: i, isDisabled: m, textValue: typeof e == "string" ? e : void 0, children: e }),
58
+ /* @__PURE__ */ n(S, { ref: s, className: M("alea-popover alea-menu-popover", d), style: p, offset: -4, children: /* @__PURE__ */ n(g, { children: c }) })
59
+ ] });
60
+ });
61
+ export {
62
+ te as DropdownMenu,
63
+ g as Menu,
64
+ G as MenuItem,
65
+ re as MenuSection,
66
+ oe as MenuSeparator,
67
+ ie as Submenu
68
+ };
@@ -1,20 +1,20 @@
1
- import { type ReactNode, type CSSProperties } from 'react';
2
- export interface SkipLinkProps {
1
+ import { type ReactNode, type CSSProperties, type HTMLAttributes, type AnchorHTMLAttributes } from 'react';
2
+ export interface SkipLinkProps extends Omit<AnchorHTMLAttributes<HTMLAnchorElement>, 'target'> {
3
3
  /** The id of the main content, without #. Default "main". */
4
4
  target?: string;
5
5
  /** The link text. Default "Skip to content". */
6
6
  children?: ReactNode;
7
7
  }
8
8
  /** The first link on the page: hidden until focused, it jumps past the navigation to the content. */
9
- export declare function SkipLink({ target, children }: SkipLinkProps): import("react").JSX.Element;
10
- export interface VisuallyHiddenProps {
9
+ export declare const SkipLink: import("react").ForwardRefExoticComponent<SkipLinkProps & import("react").RefAttributes<HTMLAnchorElement>>;
10
+ export interface VisuallyHiddenProps extends Omit<HTMLAttributes<HTMLElement>, 'children'> {
11
11
  /** Text only screen readers should hear. */
12
12
  children: ReactNode;
13
13
  /** Render as another element. Default span. */
14
14
  as?: 'span' | 'div' | 'p' | 'h1' | 'h2' | 'h3';
15
15
  }
16
16
  /** Content for screen readers only: still read, never shown. */
17
- export declare function VisuallyHidden({ children, as: Tag }: VisuallyHiddenProps): import("react").JSX.Element;
17
+ export declare const VisuallyHidden: import("react").ForwardRefExoticComponent<VisuallyHiddenProps & import("react").RefAttributes<HTMLElement>>;
18
18
  export interface CollapsibleProps {
19
19
  /** The always-visible trigger text. */
20
20
  title: ReactNode;
@@ -162,8 +162,8 @@ export declare function Prose({ children, size, className }: ProseProps): import
162
162
  export interface BannerProps {
163
163
  /** The message. Keep it to one line on desktop. */
164
164
  children: ReactNode;
165
- /** accent (default, gradient), info, warning or danger. */
166
- tone?: 'accent' | 'info' | 'warning' | 'danger';
165
+ /** accent (default, gradient), neutral, success, info, warning or danger. */
166
+ tone?: 'accent' | 'neutral' | 'success' | 'info' | 'warning' | 'danger';
167
167
  /** A link or button after the message. */
168
168
  action?: ReactNode;
169
169
  /** Shows a close button; called when closed. */
@@ -0,0 +1,182 @@
1
+ "use client";
2
+ import { jsxs as u, jsx as a, Fragment as I } from "react/jsx-runtime";
3
+ import { useState as k, useRef as D, useEffect as z, useId as T, forwardRef as M } from "react";
4
+ import { Disclosure as j, Button as A, DisclosurePanel as F } from "react-aria-components";
5
+ import { X as P, ChevronDown as K, Pencil as O, Check as B } from "lucide-react";
6
+ import { cx as m } from "../../utils/cx.js";
7
+ import { Spinner as H } from "../feedback/Spinner.js";
8
+ import { useStrings as $ } from "../../i18n/strings.js";
9
+ import { inertProps as L } from "../../utils/inert.js";
10
+ const Z = M(function({ target: t = "main", children: l, className: s, ...c }, r) {
11
+ const o = $();
12
+ return l ?? (l = o.skipToContent), /* @__PURE__ */ a("a", { ref: r, href: `#${t}`, ...c, className: m("alea-skip-link", s), children: l });
13
+ }), _ = M(function({ children: t, as: l = "span", className: s, ...c }, r) {
14
+ return /* @__PURE__ */ a(l, { ref: r, ...c, className: m("alea-visually-hidden", s), children: t });
15
+ });
16
+ function aa({ title: e, children: t, isExpanded: l, defaultExpanded: s, onExpandedChange: c, className: r }) {
17
+ return /* @__PURE__ */ u(j, { isExpanded: l, defaultExpanded: s, onExpandedChange: c, className: m("alea-collapsible", r), children: [
18
+ /* @__PURE__ */ u(A, { slot: "trigger", className: "alea-collapsible-trigger alea-focus-ring", children: [
19
+ /* @__PURE__ */ a(K, { size: 16, "aria-hidden": "true", className: "alea-collapsible-chevron" }),
20
+ e
21
+ ] }),
22
+ /* @__PURE__ */ a(F, { className: "alea-collapsible-panel", children: /* @__PURE__ */ a("div", { className: "alea-collapsible-content", children: t }) })
23
+ ] });
24
+ }
25
+ function ea({ value: e, defaultValue: t = "", onSave: l, label: s, placeholder: c = "Empty", multiline: r, className: o }) {
26
+ const p = $(), [h, g] = k(t), n = e ?? h, [i, f] = k(!1), [N, C] = k(n), [v, w] = k(!1), x = D(null), b = D(null);
27
+ z(() => {
28
+ var d, q;
29
+ i && ((d = x.current) == null || d.focus(), (q = x.current) == null || q.select());
30
+ }, [i]);
31
+ const y = () => {
32
+ if ((l == null ? void 0 : l(N)) === !1) {
33
+ w(!0);
34
+ return;
35
+ }
36
+ e === void 0 && g(N), f(!1), w(!1), requestAnimationFrame(() => {
37
+ var d;
38
+ return (d = b.current) == null ? void 0 : d.focus();
39
+ });
40
+ }, S = () => {
41
+ f(!1), w(!1), requestAnimationFrame(() => {
42
+ var d;
43
+ return (d = b.current) == null ? void 0 : d.focus();
44
+ });
45
+ };
46
+ if (!i)
47
+ return /* @__PURE__ */ u("button", { ref: b, type: "button", className: m("alea-editable alea-focus-ring", o), "data-empty": !n || void 0, "aria-label": `${s}: ${n || c}. Edit`, onClick: () => {
48
+ C(n), f(!0);
49
+ }, children: [
50
+ /* @__PURE__ */ a("span", { className: "alea-editable-text", children: n || c }),
51
+ /* @__PURE__ */ a(O, { size: 14, "aria-hidden": "true", className: "alea-editable-icon" })
52
+ ] });
53
+ const E = r ? "textarea" : "input";
54
+ return /* @__PURE__ */ u("span", { className: m("alea-editable-edit", o), children: [
55
+ /* @__PURE__ */ a(
56
+ E,
57
+ {
58
+ ref: x,
59
+ className: r ? "alea-textarea" : "alea-input alea-editable-input",
60
+ "aria-label": s,
61
+ "aria-invalid": v || void 0,
62
+ value: N,
63
+ rows: r ? 3 : void 0,
64
+ onChange: (d) => {
65
+ C(d.target.value), w(!1);
66
+ },
67
+ onKeyDown: (d) => {
68
+ d.key === "Escape" && (d.preventDefault(), S()), d.key === "Enter" && (!r || d.metaKey || d.ctrlKey) && (d.preventDefault(), y());
69
+ }
70
+ }
71
+ ),
72
+ /* @__PURE__ */ a("button", { type: "button", className: "alea-editable-btn alea-focus-ring", "aria-label": p.save, onClick: y, children: /* @__PURE__ */ a(B, { size: 14 }) }),
73
+ /* @__PURE__ */ a("button", { type: "button", className: "alea-editable-btn alea-focus-ring", "aria-label": p.cancel, onClick: S, children: /* @__PURE__ */ a(P, { size: 14 }) })
74
+ ] });
75
+ }
76
+ function la({ value: e, format: t, locale: l }) {
77
+ return /* @__PURE__ */ a(I, { children: new Intl.NumberFormat(l, t).format(e) });
78
+ }
79
+ const R = (e) => String(e).padStart(2, "0");
80
+ function ta({ to: e, label: t, onEnd: l, showDays: s, className: c }) {
81
+ const r = $(), o = typeof e == "number" ? e : e.getTime(), [p, h] = k(() => Date.now()), g = D(!1);
82
+ z(() => {
83
+ const b = setInterval(() => h(Date.now()), 1e3);
84
+ return () => clearInterval(b);
85
+ }, []);
86
+ const n = Math.max(0, o - p);
87
+ z(() => {
88
+ n === 0 && !g.current && (g.current = !0, l == null || l());
89
+ }, [n, l]);
90
+ const i = Math.floor(n / 864e5), f = Math.floor(n / 36e5) % 24, N = Math.floor(n / 6e4) % 60, C = Math.floor(n / 1e3) % 60, v = s ?? i > 0, w = [...v ? [[i, "d"]] : [], [v ? f : f + i * 24, "h"], [N, "m"], [C, "s"]], x = `${v ? `${i} days, ` : ""}${v ? f : f + i * 24} hours, ${N} minutes`;
91
+ return /* @__PURE__ */ u("div", { className: m("alea-stat alea-countdown", c), children: [
92
+ /* @__PURE__ */ a("span", { className: "alea-stat-label", children: t }),
93
+ /* @__PURE__ */ a("span", { className: "alea-stat-value alea-countdown-value", "aria-hidden": "true", children: w.map(([b, y]) => /* @__PURE__ */ u("span", { children: [
94
+ /* @__PURE__ */ a("b", { children: y === "d" ? b : R(b) }),
95
+ /* @__PURE__ */ a("small", { children: y })
96
+ ] }, y)) }),
97
+ /* @__PURE__ */ a("span", { className: "alea-visually-hidden", "aria-live": "polite", children: n === 0 ? r.ended : x })
98
+ ] });
99
+ }
100
+ function na({ tone: e = "neutral", children: t, pulse: l, className: s }) {
101
+ return /* @__PURE__ */ u("span", { className: m("alea-status", s), "data-tone": e, children: [
102
+ /* @__PURE__ */ a("span", { className: "alea-status-dot", "data-pulse": l || void 0, "aria-hidden": "true" }),
103
+ t
104
+ ] });
105
+ }
106
+ function sa({ color: e, label: t, size: l = 28, shape: s = "circle", showValue: c, className: r, style: o }) {
107
+ const p = /* @__PURE__ */ a("span", { className: "alea-swatch", "data-shape": s, role: "img", "aria-label": t, style: { width: l, height: l, "--alea-swatch": e, ...o } });
108
+ return c ? /* @__PURE__ */ u("span", { className: m("alea-swatch-wrap", r), "data-labeled": !0, children: [
109
+ p,
110
+ /* @__PURE__ */ a("span", { className: "alea-swatch-name", "aria-hidden": "true", children: t }),
111
+ /* @__PURE__ */ a("code", { className: "alea-swatch-value", children: e })
112
+ ] }) : /* @__PURE__ */ a("span", { className: m("alea-swatch-wrap", r), children: p });
113
+ }
114
+ function ra({ isLoading: e, children: t, label: l, blur: s = !0, className: c }) {
115
+ const r = $();
116
+ return l ?? (l = r.loading), /* @__PURE__ */ u("div", { className: m("alea-loading", c), "aria-busy": e || void 0, children: [
117
+ /* @__PURE__ */ a("div", { className: "alea-loading-content", ...L(e), children: t }),
118
+ e && /* @__PURE__ */ a("div", { className: "alea-loading-overlay", "data-blur": s || void 0, children: /* @__PURE__ */ a(H, { size: "md", "aria-label": l }) })
119
+ ] });
120
+ }
121
+ function ia({ segments: e, total: t, label: l, valueFormat: s = (o) => String(o), showLegend: c = !0, className: r }) {
122
+ const o = T(), p = t ?? e.reduce((n, i) => n + i.value, 0), h = (n, i) => n.color || `var(--alea-chart-${i % 8 + 1})`, g = e.reduce((n, i) => n + i.value, 0);
123
+ return /* @__PURE__ */ u("div", { className: m("alea-progress-seg", r), children: [
124
+ /* @__PURE__ */ u("div", { className: "alea-progress-seg-head", children: [
125
+ /* @__PURE__ */ a("span", { id: o, className: "alea-label", children: l }),
126
+ /* @__PURE__ */ u("span", { className: "alea-progress-seg-total", children: [
127
+ s(g),
128
+ " of ",
129
+ s(p)
130
+ ] })
131
+ ] }),
132
+ /* @__PURE__ */ a("div", { className: "alea-progress-seg-bar", role: "meter", "aria-labelledby": o, "aria-valuemin": 0, "aria-valuemax": p, "aria-valuenow": g, "aria-valuetext": e.map((n) => `${n.label} ${s(n.value)}`).join(", "), children: e.map((n, i) => /* @__PURE__ */ a("span", { className: "alea-progress-seg-part", style: { width: `${n.value / (p || 1) * 100}%`, background: h(n, i), animationDelay: `${i * 60}ms` } }, n.label)) }),
133
+ c && /* @__PURE__ */ a("ul", { className: "alea-progress-seg-legend", "aria-hidden": "true", children: e.map((n, i) => /* @__PURE__ */ u("li", { children: [
134
+ /* @__PURE__ */ a("span", { style: { background: h(n, i) } }),
135
+ n.label,
136
+ /* @__PURE__ */ a("b", { children: s(n.value) })
137
+ ] }, n.label)) })
138
+ ] });
139
+ }
140
+ function ca({ children: e, cite: t, source: l, className: s }) {
141
+ return /* @__PURE__ */ u("figure", { className: m("alea-blockquote", s), children: [
142
+ /* @__PURE__ */ a("blockquote", { cite: l, children: e }),
143
+ t && /* @__PURE__ */ a("figcaption", { children: t })
144
+ ] });
145
+ }
146
+ function oa({ items: e, marker: t = "bullet", spacing: l = "md", className: s }) {
147
+ return /* @__PURE__ */ a(t === "number" ? "ol" : "ul", { className: m("alea-text-list", s), "data-marker": t, "data-spacing": l, children: e.map((r, o) => /* @__PURE__ */ u("li", { children: [
148
+ t === "check" && /* @__PURE__ */ a(B, { size: 16, "aria-hidden": "true", className: "alea-text-list-check" }),
149
+ /* @__PURE__ */ a("span", { children: r })
150
+ ] }, o)) });
151
+ }
152
+ function da({ children: e, size: t = "base", className: l }) {
153
+ return /* @__PURE__ */ a("div", { className: m("alea-prose alea-markdown", l), "data-size": t, children: e });
154
+ }
155
+ function ua({ children: e, tone: t = "accent", action: l, onDismiss: s, className: c, "aria-label": r }) {
156
+ const o = $();
157
+ r ?? (r = o.announcement);
158
+ const [p, h] = k(!0);
159
+ return p ? /* @__PURE__ */ u("div", { className: m("alea-banner", c), "data-tone": t, role: "region", "aria-label": r, children: [
160
+ /* @__PURE__ */ a("p", { className: "alea-banner-text", children: e }),
161
+ l && /* @__PURE__ */ a("span", { className: "alea-banner-action", children: l }),
162
+ s && /* @__PURE__ */ a("button", { type: "button", className: "alea-banner-close alea-focus-ring", "aria-label": o.dismissAnnouncement, onClick: () => {
163
+ h(!1), s();
164
+ }, children: /* @__PURE__ */ a(P, { size: 16 }) })
165
+ ] }) : null;
166
+ }
167
+ export {
168
+ ua as Banner,
169
+ ca as Blockquote,
170
+ aa as Collapsible,
171
+ sa as ColorSwatch,
172
+ ta as Countdown,
173
+ ea as Editable,
174
+ la as FormattedNumber,
175
+ oa as List,
176
+ ra as LoadingOverlay,
177
+ ia as ProgressSegments,
178
+ da as Prose,
179
+ Z as SkipLink,
180
+ na as Status,
181
+ _ as VisuallyHidden
182
+ };
@@ -1,5 +1,5 @@
1
1
  import { type CSSProperties, type ReactNode } from 'react';
2
- import { type NavigationMenuProps } from './Navigation2';
2
+ import { type NavigationMenuProps } from './Navigation2.js';
3
3
  export interface NavbarProps {
4
4
  /** The logo or name, usually a link home. */
5
5
  brand: ReactNode;
@@ -0,0 +1,27 @@
1
+ "use client";
2
+ import { jsxs as l, jsx as a } from "react/jsx-runtime";
3
+ import { useState as u, useId as N } from "react";
4
+ import { cx as f } from "../../utils/cx.js";
5
+ import { NavigationMenu as d, Burger as g } from "./Navigation2.js";
6
+ import { Drawer as w, DrawerContent as x } from "../overlay/Drawer.js";
7
+ import { useStrings as O } from "../../i18n/strings.js";
8
+ function S({ brand: m, items: s, current: t, actions: e, collapseBelow: v = "md", sticky: p = !0, className: b, style: h, "aria-label": r }) {
9
+ const n = O();
10
+ r ?? (r = n.mainNav);
11
+ const [o, i] = u(!1), c = N();
12
+ return /* @__PURE__ */ l("header", { className: f("alea-navbar", b), style: h, "data-sticky": p || void 0, "data-collapse": v, children: [
13
+ /* @__PURE__ */ l("div", { className: "alea-navbar-inner", children: [
14
+ /* @__PURE__ */ a("div", { className: "alea-navbar-brand", children: m }),
15
+ /* @__PURE__ */ a(d, { "aria-label": r, items: s, current: t, className: "alea-navbar-links" }),
16
+ /* @__PURE__ */ a("div", { className: "alea-navbar-actions", children: e }),
17
+ /* @__PURE__ */ a("span", { className: "alea-navbar-burger", children: /* @__PURE__ */ a(g, { isOpen: o, onChange: i, "aria-controls": c, "aria-label": n.menu }) })
18
+ ] }),
19
+ /* @__PURE__ */ a(w, { isOpen: o, onOpenChange: i, placement: "end", size: 320, children: /* @__PURE__ */ a(x, { title: n.menu, children: /* @__PURE__ */ l("div", { id: c, className: "alea-navbar-drawer", children: [
20
+ /* @__PURE__ */ a(d, { orientation: "vertical", size: "lg", "aria-label": r, items: s, current: t, onNavigate: () => i(!1) }),
21
+ e && /* @__PURE__ */ a("div", { className: "alea-navbar-drawer-actions", children: e })
22
+ ] }) }) })
23
+ ] });
24
+ }
25
+ export {
26
+ S as Navbar
27
+ };
@@ -0,0 +1,121 @@
1
+ "use client";
2
+ import { jsx as a, jsxs as c, Fragment as D } from "react/jsx-runtime";
3
+ import { Children as j, isValidElement as E, useMemo as P } from "react";
4
+ import { Breadcrumb as B, Link as R, Button as z, Breadcrumbs as L } from "react-aria-components";
5
+ import { ChevronsLeft as O, ChevronLeft as T, ChevronRight as _, ChevronsRight as A, X as K, Check as V } from "lucide-react";
6
+ import { DropdownMenu as W, MenuItem as X } from "../menu/Menu.js";
7
+ import { withBase as q, cx as k } from "../../utils/cx.js";
8
+ import { useStrings as M } from "../../i18n/strings.js";
9
+ function I({ separator: e, maxItems: n, size: h, className: l, children: u, ...m }) {
10
+ const o = M();
11
+ let d = u;
12
+ if (n && typeof u != "function") {
13
+ const p = j.toArray(u).filter(E);
14
+ if (p.length > n && n >= 2) {
15
+ const f = p.slice(1, p.length - (n - 1));
16
+ d = [
17
+ p[0],
18
+ /* @__PURE__ */ a(B, { className: "alea-crumb", children: /* @__PURE__ */ a(W, { "aria-label": o.showMore, trigger: /* @__PURE__ */ a(z, { className: "alea-crumb-link alea-crumb-more alea-focus-ring", "aria-label": o.showMore, children: "…" }), children: f.map((s, g) => /* @__PURE__ */ a(X, { id: `c${g}`, href: s.props.href, children: s.props.children }, g)) }) }, "__more"),
19
+ ...p.slice(p.length - (n - 1))
20
+ ];
21
+ }
22
+ }
23
+ return /* @__PURE__ */ a(L, { ...m, className: k("alea-breadcrumbs", l), "data-size": h, "data-separator": e ? void 0 : "chevron", style: { "--alea-crumb-sep": typeof e == "string" ? `"${e}"` : void 0, ...m.style }, children: d });
24
+ }
25
+ function S({ href: e, icon: n, children: h, className: l, ...u }) {
26
+ return /* @__PURE__ */ a(B, { ...u, className: q("alea-crumb", l), children: /* @__PURE__ */ c(R, { href: e, className: "alea-crumb-link alea-focus-ring", children: [
27
+ n && /* @__PURE__ */ a("span", { className: "alea-crumb-icon", "aria-hidden": "true", children: n }),
28
+ h
29
+ ] }) });
30
+ }
31
+ function F(e, n, h) {
32
+ const l = [], u = Math.max(2, e - h), m = Math.min(n - 1, e + h);
33
+ l.push(1), u > 2 && l.push("gap");
34
+ for (let o = u; o <= m; o++) l.push(o);
35
+ return m < n - 1 && l.push("gap"), n > 1 && l.push(n), l;
36
+ }
37
+ function aa({ page: e, total: n, onChange: h, siblings: l = 1, appearance: u = "pages", size: m, showFirstLast: o, pageSize: d, pageSizeOptions: p = [10, 25, 50, 100], onPageSizeChange: f, totalItems: s, showJumper: g, className: t, "aria-label": N }) {
38
+ const r = M();
39
+ N ?? (N = r.pagination);
40
+ const v = P(() => F(e, Math.max(1, n), l), [e, n, l]), b = (i) => h(Math.min(Math.max(1, i), n)), w = d ? (e - 1) * d + 1 : 0, $ = d && s != null ? Math.min(s, e * d) : 0, C = s != null && d || f || g, x = /* @__PURE__ */ c("nav", { "aria-label": N, className: k("alea-pagination", !C && t), "data-size": m, children: [
41
+ o && /* @__PURE__ */ a("button", { type: "button", className: "alea-page alea-focus-ring", "data-far": !0, "aria-label": r.firstPage, disabled: e <= 1, onClick: () => b(1), children: /* @__PURE__ */ a(O, { size: 16, "aria-hidden": "true" }) }),
42
+ /* @__PURE__ */ a("button", { type: "button", className: "alea-page alea-focus-ring", "aria-label": r.previousPage, disabled: e <= 1, onClick: () => b(e - 1), children: /* @__PURE__ */ a(T, { size: 16, "aria-hidden": "true" }) }),
43
+ u === "compact" ? /* @__PURE__ */ a("span", { className: "alea-page-status", "aria-live": "polite", children: r.nOfTotal(e, n) }) : /* @__PURE__ */ a("ul", { children: v.map((i, y) => i === "gap" ? /* @__PURE__ */ a("li", { className: "alea-page-gap", "aria-hidden": "true", children: "…" }, `g${y}`) : /* @__PURE__ */ a("li", { "data-far": v.length > 5 && Math.abs(i - e) > 1 || void 0, children: /* @__PURE__ */ a("button", { type: "button", className: "alea-page alea-focus-ring", "aria-current": i === e ? "page" : void 0, "aria-label": r.pageN(i), onClick: () => b(i), children: i }) }, i)) }),
44
+ /* @__PURE__ */ a("button", { type: "button", className: "alea-page alea-focus-ring", "aria-label": r.nextPage, disabled: e >= n, onClick: () => b(e + 1), children: /* @__PURE__ */ a(_, { size: 16, "aria-hidden": "true" }) }),
45
+ o && /* @__PURE__ */ a("button", { type: "button", className: "alea-page alea-focus-ring", "data-far": !0, "aria-label": r.lastPage, disabled: e >= n, onClick: () => b(n), children: /* @__PURE__ */ a(A, { size: 16, "aria-hidden": "true" }) })
46
+ ] });
47
+ return C ? /* @__PURE__ */ c("div", { className: k("alea-pagination-bar", t), "data-size": m, children: [
48
+ s != null && d ? /* @__PURE__ */ a("span", { className: "alea-pagination-total", "aria-live": "polite", children: r.itemRange(w, $, s) }) : /* @__PURE__ */ a("span", {}),
49
+ /* @__PURE__ */ c("div", { className: "alea-pagination-controls", children: [
50
+ f && d && /* @__PURE__ */ c("label", { className: "alea-pagination-size", children: [
51
+ /* @__PURE__ */ a("span", { children: r.perPage }),
52
+ /* @__PURE__ */ a("select", { className: "alea-cal-select alea-focus-ring", value: d, onChange: (i) => f(Number(i.target.value)), children: p.map((i) => /* @__PURE__ */ a("option", { value: i, children: i }, i)) })
53
+ ] }),
54
+ x,
55
+ g && /* @__PURE__ */ c("label", { className: "alea-pagination-jump", children: [
56
+ /* @__PURE__ */ a("span", { children: r.goToPage }),
57
+ /* @__PURE__ */ a(
58
+ "input",
59
+ {
60
+ className: "alea-pagination-input alea-focus-ring",
61
+ type: "number",
62
+ inputMode: "numeric",
63
+ min: 1,
64
+ max: n,
65
+ placeholder: String(e),
66
+ onKeyDown: (i) => {
67
+ if (i.key === "Enter") {
68
+ const y = Number(i.target.value);
69
+ y && (b(y), i.target.value = "");
70
+ }
71
+ }
72
+ }
73
+ )
74
+ ] })
75
+ ] })
76
+ ] }) : x;
77
+ }
78
+ function ea({ steps: e, current: n, orientation: h = "horizontal", responsive: l = !0, onStepPress: u, size: m, variant: o = "numbers", labelPlacement: d, className: p, "aria-label": f }) {
79
+ const s = M();
80
+ f ?? (f = s.progress);
81
+ const g = Math.max(0, e.findIndex((t) => t.id === n));
82
+ return /* @__PURE__ */ a("ol", { "aria-label": f, className: k("alea-steps", p), "data-orientation": h, "data-responsive": l || void 0, "data-size": m, "data-variant": o !== "numbers" ? o : void 0, "data-label-placement": d !== "end" ? d : void 0, children: e.map((t, N) => {
83
+ const r = t.status ?? (N < g ? "done" : N === g ? "current" : "upcoming"), v = r === "error" ? /* @__PURE__ */ a(K, { size: 14 }) : r === "warning" ? "!" : r === "done" ? /* @__PURE__ */ a(V, { size: 14 }) : o === "dots" ? null : o === "icons" && t.icon ? t.icon : N + 1, b = /* @__PURE__ */ c(D, { children: [
84
+ /* @__PURE__ */ a("span", { className: "alea-step-dot", "aria-hidden": "true", children: v }),
85
+ /* @__PURE__ */ c("span", { className: "alea-step-text", children: [
86
+ /* @__PURE__ */ c("span", { className: "alea-step-title", children: [
87
+ t.title,
88
+ t.isOptional && /* @__PURE__ */ c("span", { className: "alea-step-optional", children: [
89
+ " (",
90
+ s.optional,
91
+ ")"
92
+ ] })
93
+ ] }),
94
+ t.description && /* @__PURE__ */ a("span", { className: "alea-step-desc", children: t.description }),
95
+ (r === "error" || r === "warning") && /* @__PURE__ */ c("span", { className: "alea-visually-hidden", children: [
96
+ " ",
97
+ r === "error" ? s.stepError : s.stepWarning
98
+ ] })
99
+ ] })
100
+ ] });
101
+ return /* @__PURE__ */ a("li", { className: "alea-step", "data-status": r, "aria-current": r === "current" ? "step" : void 0, children: u && r === "done" ? /* @__PURE__ */ c("button", { type: "button", className: "alea-step-button alea-focus-ring", onClick: () => u(t.id), children: [
102
+ b,
103
+ /* @__PURE__ */ c("span", { className: "alea-visually-hidden", children: [
104
+ " ",
105
+ s.stepDoneBack
106
+ ] })
107
+ ] }) : /* @__PURE__ */ c("div", { className: "alea-step-button", children: [
108
+ b,
109
+ r === "done" && /* @__PURE__ */ c("span", { className: "alea-visually-hidden", children: [
110
+ " ",
111
+ s.stepDone
112
+ ] })
113
+ ] }) }, t.id != null ? String(t.id) : N);
114
+ }) });
115
+ }
116
+ export {
117
+ S as Breadcrumb,
118
+ I as Breadcrumbs,
119
+ aa as Pagination,
120
+ ea as Steps
121
+ };
@@ -1,4 +1,4 @@
1
- import { type MouseEvent, type ReactNode } from 'react';
1
+ import { type CSSProperties, type MouseEvent, type ReactNode } from 'react';
2
2
  import { type Key } from 'react-aria-components';
3
3
  import { type MotionProp } from '@alea-design/motion';
4
4
  /** One item of a menu built from data: an action, or a separator. */
@@ -62,9 +62,13 @@ export interface HoverCardProps {
62
62
  placement?: 'top' | 'bottom' | 'start' | 'end';
63
63
  /** How the popup enters and leaves: a preset (fade, scale, pop, slide-down, blur...), false for none, or options. */
64
64
  motion?: MotionProp;
65
+ /** Extra class names for the trigger wrapper. */
66
+ className?: string;
67
+ /** Inline style for the trigger wrapper. */
68
+ style?: CSSProperties;
65
69
  }
66
70
  /** A rich preview on hover or keyboard focus, which people can move into. */
67
- export declare function HoverCard({ motion, trigger, children, openDelay, closeDelay, placement }: HoverCardProps): import("react").JSX.Element;
71
+ export declare const HoverCard: import("react").ForwardRefExoticComponent<HoverCardProps & import("react").RefAttributes<HTMLSpanElement>>;
68
72
  /** A link in a NavigationMenu. */
69
73
  export interface NavLinkItem {
70
74
  label: string;