@alea-design/ui 0.6.0 → 0.6.1

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.
@@ -1,91 +1,93 @@
1
1
  "use client";
2
2
  import { jsx as n, jsxs as m } from "react/jsx-runtime";
3
- import { forwardRef as $, useState as N, useEffect as C, useMemo as j, useRef as q } from "react";
4
- import { cx as B } from "../../utils/cx.js";
5
- import { useFilter as J, Autocomplete as P, SearchField as Y, Input as Z, Menu as Q, MenuSection as G, Header as ee, Collection as te, MenuItem as z, Keyboard as ne } from "react-aria-components";
6
- import { Search as se } from "lucide-react";
7
- import { DialogModal as ie, Dialog as ae } from "../overlay/Overlay.js";
8
- import { Kbd as oe } from "../typography/Typography.js";
9
- import { useStrings as le } from "../../i18n/strings.js";
10
- const E = "__more:";
11
- function re({ children: g }) {
12
- const o = q(null), [u, w] = N(!1);
13
- return C(() => {
14
- const i = o.current;
15
- if (!i) return;
16
- const f = () => w(i.scrollHeight > i.clientHeight + 1);
3
+ import { forwardRef as B, useState as N, useEffect as D, useMemo as j, useRef as J } from "react";
4
+ import { cx as P } from "../../utils/cx.js";
5
+ import { useFilter as Y, Autocomplete as Z, SearchField as Q, Input as G, Menu as ee, MenuSection as te, Header as ne, Collection as se, MenuItem as z, Keyboard as ie } from "react-aria-components";
6
+ import { Search as ae } from "lucide-react";
7
+ import { DialogModal as le, Dialog as oe } from "../overlay/Overlay.js";
8
+ import { Kbd as re } from "../typography/Typography.js";
9
+ import { useStrings as ce } from "../../i18n/strings.js";
10
+ const M = "__more:";
11
+ function de({ children: K }) {
12
+ const o = J(null), [h, w] = N(!1);
13
+ return D(() => {
14
+ const a = o.current;
15
+ if (!a) return;
16
+ const f = () => w(a.scrollHeight > a.clientHeight + 1);
17
17
  if (f(), typeof ResizeObserver > "u") return;
18
- const r = new ResizeObserver(f);
19
- return r.observe(i), i.firstElementChild && r.observe(i.firstElementChild), () => r.disconnect();
20
- }, []), /* @__PURE__ */ n("div", { ref: o, className: "alea-command-scroll", tabIndex: u ? 0 : void 0, children: g });
18
+ const c = new ResizeObserver(f);
19
+ return c.observe(a), a.firstElementChild && c.observe(a.firstElementChild), () => c.disconnect();
20
+ }, []), /* @__PURE__ */ n("div", { ref: o, className: "alea-command-scroll", tabIndex: h ? 0 : void 0, children: K });
21
21
  }
22
- const we = $(function({ commands: o, isOpen: u, defaultOpen: w, onOpenChange: i, motion: f, hotkey: r = !0, slashHotkey: M, onQueryChange: b, filter: h, isLoading: p, maxPerGroup: c, placeholder: K, emptyText: R, className: D, style: F, surface: T, radius: V }, H) {
23
- const a = le();
24
- K ?? (K = a.commandPlaceholder), R ?? (R = a.noResults);
25
- const [L, O] = N(w ?? !1), v = u ?? L, [d, _] = N(""), [I, k] = N(/* @__PURE__ */ new Set()), x = (s) => {
26
- _(s), b == null || b(s);
27
- }, S = (s) => {
28
- s || (d && x(""), k(/* @__PURE__ */ new Set())), u === void 0 && O(s), i == null || i(s);
22
+ const ve = B(function({ commands: o, isOpen: h, defaultOpen: w, onOpenChange: a, motion: f, hotkey: c = !0, slashHotkey: R, onQueryChange: b, filter: p, isLoading: v, maxPerGroup: d, placeholder: I, emptyText: k, className: F, style: L, surface: T, radius: V }, H) {
23
+ const l = ce();
24
+ I ?? (I = l.commandPlaceholder), k ?? (k = l.noResults);
25
+ const [O, _] = N(w ?? !1), g = h ?? O, [r, U] = N(""), [x, A] = N(/* @__PURE__ */ new Set()), C = (i) => {
26
+ U(i), b == null || b(i);
27
+ }, S = (i) => {
28
+ i || (r && C(""), A(/* @__PURE__ */ new Set())), h === void 0 && _(i), a == null || a(i);
29
29
  };
30
- C(() => {
31
- if (!r && !M) return;
32
- const s = (t) => {
33
- if (r && t.key.toLowerCase() === "k" && (t.metaKey || t.ctrlKey)) {
34
- t.preventDefault(), S(!v);
30
+ D(() => {
31
+ if (!c && !R) return;
32
+ const i = (t) => {
33
+ if (c && t.key.toLowerCase() === "k" && (t.metaKey || t.ctrlKey)) {
34
+ t.preventDefault(), S(!g);
35
35
  return;
36
36
  }
37
- if (M && !v && t.key === "/" && !t.metaKey && !t.ctrlKey && !t.altKey) {
37
+ if (R && !g && t.key === "/" && !t.metaKey && !t.ctrlKey && !t.altKey) {
38
38
  const e = t.target;
39
39
  if (e && (e.isContentEditable || /^(INPUT|TEXTAREA|SELECT)$/.test(e.tagName))) return;
40
40
  t.preventDefault(), S(!0);
41
41
  }
42
42
  };
43
- return window.addEventListener("keydown", s), () => window.removeEventListener("keydown", s);
43
+ return window.addEventListener("keydown", i), () => window.removeEventListener("keydown", i);
44
44
  });
45
- const { contains: U } = J({ sensitivity: "base" }), A = j(() => {
46
- const s = (e) => h === !1 || !d ? !0 : h ? h(e, d) : U([e.label, ...e.keywords || []].join(" "), d), t = [];
47
- for (const e of o) {
48
- if (!s(e)) continue;
49
- const l = e.group || "";
50
- let y = t.find((X) => X.id === l);
51
- y || t.push(y = { id: l, title: l, items: [] }), y.items.push(e);
45
+ const { contains: W } = Y({ sensitivity: "base" }), { groups: y, total: X } = j(() => {
46
+ const i = (s) => p === !1 || !r ? !0 : p ? p(s, r) : W([s.label, ...s.keywords || []].join(" "), r), t = [];
47
+ let e = 0;
48
+ for (const s of o) {
49
+ if (!i(s)) continue;
50
+ e++;
51
+ const u = s.group || "";
52
+ let E = t.find((q) => q.id === u);
53
+ E || t.push(E = { id: u, title: u, items: [] }), E.items.push(s);
52
54
  }
53
- if (c && c > 0) for (const e of t) {
54
- if (I.has(e.id) || e.items.length <= c) continue;
55
- const l = e.items.length - c;
56
- e.items = [...e.items.slice(0, c), { id: E + e.id, more: l, group: e.id }];
55
+ if (d && d > 0) for (const s of t) {
56
+ if (x.has(s.id) || s.items.length <= d) continue;
57
+ const u = s.items.length - d;
58
+ s.items = [...s.items.slice(0, d), { id: M + s.id, more: u, group: s.id }];
57
59
  }
58
- return t;
59
- }, [o, d, h, c, I]), W = j(() => new Map(o.map((s) => [s.id, s])), [o]);
60
- return /* @__PURE__ */ n(ie, { isOpen: v, onOpenChange: S, size: "md", className: "alea-command-overlay", motion: f, surface: T, radius: V, children: /* @__PURE__ */ n(ae, { ref: H, style: F, "aria-label": a.commandPalette, hideClose: !0, className: B("alea-command", D), children: ({ close: s }) => /* @__PURE__ */ m(P, { inputValue: d, onInputChange: x, filter: () => !0, children: [
61
- /* @__PURE__ */ m(Y, { "aria-label": a.searchCommands, autoFocus: !0, className: "alea-command-search", children: [
62
- /* @__PURE__ */ n(se, { size: 18, "aria-hidden": "true" }),
63
- /* @__PURE__ */ n(Z, { placeholder: K, className: "alea-command-input" }),
64
- /* @__PURE__ */ n(oe, { children: a.esc })
60
+ return { groups: t, total: e };
61
+ }, [o, r, p, d, x]), $ = j(() => new Map(o.map((i) => [i.id, i])), [o]);
62
+ return /* @__PURE__ */ n(le, { isOpen: g, onOpenChange: S, size: "md", className: "alea-command-overlay", motion: f, surface: T, radius: V, children: /* @__PURE__ */ n(oe, { ref: H, style: L, "aria-label": l.commandPalette, hideClose: !0, className: P("alea-command", F), children: ({ close: i }) => /* @__PURE__ */ m(Z, { inputValue: r, onInputChange: C, filter: () => !0, children: [
63
+ /* @__PURE__ */ m(Q, { "aria-label": l.searchCommands, autoFocus: !0, className: "alea-command-search", children: [
64
+ /* @__PURE__ */ n(ae, { size: 18, "aria-hidden": "true" }),
65
+ /* @__PURE__ */ n(G, { placeholder: I, className: "alea-command-input" }),
66
+ /* @__PURE__ */ n(re, { children: l.esc })
65
67
  ] }),
66
- /* @__PURE__ */ m(re, { children: [
67
- /* @__PURE__ */ n(Q, { items: A, className: "alea-command-list", "aria-busy": p || void 0, onAction: (t) => {
68
- if (String(t).startsWith(E)) {
69
- k((l) => new Set(l).add(String(t).slice(E.length)));
68
+ /* @__PURE__ */ m(de, { children: [
69
+ y.length > 0 && /* @__PURE__ */ n(ee, { items: y, className: "alea-command-list", "aria-busy": v || void 0, onAction: (t) => {
70
+ if (String(t).startsWith(M)) {
71
+ A((s) => new Set(s).add(String(t).slice(M.length)));
70
72
  return;
71
73
  }
72
- const e = W.get(t);
73
- s(), e == null || e.onAction();
74
- }, renderEmptyState: () => /* @__PURE__ */ n("p", { className: "alea-command-empty", role: p ? "status" : void 0, children: p ? a.loading : R }), children: (t) => /* @__PURE__ */ m(G, { id: t.id, className: "alea-option-section", children: [
75
- t.title && /* @__PURE__ */ n(ee, { className: "alea-option-header", children: t.title }),
76
- /* @__PURE__ */ n(te, { items: t.items, children: (e) => "more" in e ? /* @__PURE__ */ n(z, { id: e.id, textValue: a.showNMore(e.more), className: "alea-option alea-command-item alea-command-more", children: /* @__PURE__ */ n("span", { className: "alea-option-text", children: /* @__PURE__ */ n("span", { slot: "label", children: a.showNMore(e.more) }) }) }) : /* @__PURE__ */ m(z, { id: e.id, textValue: [e.label, ...e.keywords || []].join(" "), className: "alea-option alea-command-item", children: [
74
+ const e = $.get(t);
75
+ i(), e == null || e.onAction();
76
+ }, children: (t) => /* @__PURE__ */ m(te, { id: t.id, className: "alea-option-section", children: [
77
+ t.title && /* @__PURE__ */ n(ne, { className: "alea-option-header", children: t.title }),
78
+ /* @__PURE__ */ n(se, { items: t.items, children: (e) => "more" in e ? /* @__PURE__ */ n(z, { id: e.id, textValue: l.showNMore(e.more), className: "alea-option alea-command-item alea-command-more", children: /* @__PURE__ */ n("span", { className: "alea-option-text", children: /* @__PURE__ */ n("span", { slot: "label", children: l.showNMore(e.more) }) }) }) : /* @__PURE__ */ m(z, { id: e.id, textValue: [e.label, ...e.keywords || []].join(" "), className: "alea-option alea-command-item", children: [
77
79
  e.icon && /* @__PURE__ */ n("span", { className: "alea-option-icon", "aria-hidden": "true", children: e.icon }),
78
80
  /* @__PURE__ */ m("span", { className: "alea-option-text", children: [
79
81
  /* @__PURE__ */ n("span", { slot: "label", children: e.label }),
80
82
  e.description && /* @__PURE__ */ n("span", { className: "alea-option-desc", slot: "description", children: e.description })
81
83
  ] }),
82
- e.shortcut && /* @__PURE__ */ n(ne, { className: "alea-menu-shortcut", children: e.shortcut })
84
+ e.shortcut && /* @__PURE__ */ n(ie, { className: "alea-menu-shortcut", children: e.shortcut })
83
85
  ] }) })
84
86
  ] }) }),
85
- p && A.length > 0 && /* @__PURE__ */ n("p", { className: "alea-command-loading", role: "status", children: a.loading })
87
+ /* @__PURE__ */ n("div", { role: "status", children: y.length === 0 ? /* @__PURE__ */ n("p", { className: "alea-command-empty", children: v ? l.loading : k }) : v ? /* @__PURE__ */ n("p", { className: "alea-command-loading", children: l.loading }) : r ? /* @__PURE__ */ n("span", { className: "alea-visually-hidden", children: l.resultsCount(X) }) : null })
86
88
  ] })
87
89
  ] }) }) });
88
90
  });
89
91
  export {
90
- we as CommandPalette
92
+ ve as CommandPalette
91
93
  };
@@ -7,8 +7,10 @@ export interface DescriptionsProps extends Omit<HTMLAttributes<HTMLElement>, 'ti
7
7
  span?: 1 | 2 | 3 | 4; /** Spans the whole row. */
8
8
  wide?: boolean;
9
9
  }>;
10
- /** Columns on wide screens: 1 to 4. Default 2. Three and four columns drop to two below 1024 px; everything is one column on phones. */
11
- columns?: 1 | 2 | 3 | 4;
10
+ /** Columns on wide screens: 1 to 4. Default 2. Three and four columns drop to two below 1024 px; everything is one column on phones. 'auto' fits as many columns of at least 14 rem as the width allows (item spans count as one). */
11
+ columns?: 1 | 2 | 3 | 4 | 'auto';
12
+ /** Leaves out the items whose value is empty (null, undefined, false or an empty string), so a record with optional facts shows no blank rows. */
13
+ hideEmpty?: boolean;
12
14
  /** stacked (label above the value, default) or inline (label and value side by side). */
13
15
  layout?: 'stacked' | 'inline';
14
16
  /** Draws lines between items. */
@@ -23,7 +25,7 @@ export interface DescriptionsProps extends Omit<HTMLAttributes<HTMLElement>, 'ti
23
25
  labelWidth?: string;
24
26
  }
25
27
  /** Key and value pairs: order details, profile facts, settings summaries. A title with an action, one to four columns, item spans, stacked or inline, two sizes. */
26
- export declare function Descriptions({ items, columns, layout, bordered, size, title, extra, labelWidth, className, style, ...props }: DescriptionsProps): import("react").JSX.Element;
28
+ export declare function Descriptions({ items, columns, hideEmpty, layout, bordered, size, title, extra, labelWidth, className, style, ...props }: DescriptionsProps): import("react").JSX.Element;
27
29
  export interface StatisticProps extends Omit<HTMLAttributes<HTMLDivElement>, 'prefix'> {
28
30
  /** What the number is. */
29
31
  label: ReactNode;
@@ -1,57 +1,57 @@
1
1
  "use client";
2
2
  import { jsx as e, jsxs as r, Fragment as L } from "react/jsx-runtime";
3
- import { createElement as U, useState as G, useRef as z, useEffect as O } from "react";
4
- import { Inbox as D, ServerCrash as X, Lock as _, SearchX as B, CircleAlert as H, CircleCheck as J, TrendingUp as K, TrendingDown as P } from "lucide-react";
5
- import { cx as N } from "../../utils/cx.js";
3
+ import { createElement as U, useState as G, useRef as D, useEffect as O } from "react";
4
+ import { Inbox as E, ServerCrash as X, Lock as _, SearchX as B, CircleAlert as H, CircleCheck as J, TrendingUp as K, TrendingDown as P } from "lucide-react";
5
+ import { cx as v } from "../../utils/cx.js";
6
6
  import { isDecimalString as Q } from "../../utils/decimal.js";
7
7
  import { useReducedMotion as V, TextSwap as Y } from "@alea-design/motion";
8
- function ie({ items: c, columns: a = 2, layout: d = "stacked", bordered: l, size: n, title: o, extra: s, labelWidth: m, className: h, style: p, ...u }) {
9
- const i = /* @__PURE__ */ e("dl", { className: "alea-descriptions", "data-columns": a, "data-layout": d, "data-bordered": l || void 0, "data-size": n, style: m ? { "--alea-desc-label": m } : void 0, children: c.map((t, v) => /* @__PURE__ */ r("div", { className: "alea-desc-item", "data-wide": t.wide || void 0, "data-span": t.span && t.span > 1 ? t.span : void 0, children: [
8
+ function ie({ items: c, columns: a = 2, hideEmpty: d, layout: m = "stacked", bordered: n, size: u, title: s, extra: l, labelWidth: h, className: p, style: f, ...i }) {
9
+ const o = d ? c.filter((t) => t.value != null && t.value !== !1 && t.value !== "") : c, N = /* @__PURE__ */ e("dl", { className: "alea-descriptions", "data-columns": a, "data-layout": m, "data-bordered": n || void 0, "data-size": u, style: h ? { "--alea-desc-label": h } : void 0, children: o.map((t, S) => /* @__PURE__ */ r("div", { className: "alea-desc-item", "data-wide": t.wide || void 0, "data-span": t.span && t.span > 1 ? t.span : void 0, children: [
10
10
  /* @__PURE__ */ e("dt", { children: t.label }),
11
11
  /* @__PURE__ */ e("dd", { children: t.value })
12
- ] }, v)) });
13
- return !o && !s ? /* @__PURE__ */ e("div", { ...u, style: p, className: N("alea-descriptions-wrap", h), children: i }) : /* @__PURE__ */ r("section", { ...u, style: p, className: N("alea-descriptions-wrap", h), children: [
12
+ ] }, S)) });
13
+ return !s && !l ? /* @__PURE__ */ e("div", { ...i, style: f, className: v("alea-descriptions-wrap", p), children: N }) : /* @__PURE__ */ r("section", { ...i, style: f, className: v("alea-descriptions-wrap", p), children: [
14
14
  /* @__PURE__ */ r("header", { className: "alea-descriptions-head", children: [
15
- o && /* @__PURE__ */ e("h3", { className: "alea-descriptions-title", children: o }),
16
- s && /* @__PURE__ */ e("div", { className: "alea-descriptions-extra", children: s })
15
+ s && /* @__PURE__ */ e("h3", { className: "alea-descriptions-title", children: s }),
16
+ l && /* @__PURE__ */ e("div", { className: "alea-descriptions-extra", children: l })
17
17
  ] }),
18
- i
18
+ N
19
19
  ] });
20
20
  }
21
- function ce({ label: c, value: a, isDecimal: d, formatOptions: l, delta: n, higherIsBetter: o = !0, animate: s, prefix: m, suffix: h, className: p, ...u }) {
22
- var C;
23
- const i = !!d && Q(a), t = typeof a == "string" && !i, v = V(), f = t ? 0 : i ? Number(a) : a, E = i ? ((C = a.trim().split(".")[1]) == null ? void 0 : C.length) ?? 0 : 0, [w, I] = G(s && !t ? 0 : f), x = z(w), S = z(0);
21
+ function ce({ label: c, value: a, isDecimal: d, formatOptions: m, delta: n, higherIsBetter: u = !0, animate: s, prefix: l, suffix: h, className: p, ...f }) {
22
+ var R;
23
+ const i = !!d && Q(a), o = typeof a == "string" && !i, N = V(), t = o ? 0 : i ? Number(a) : a, S = i ? ((R = a.trim().split(".")[1]) == null ? void 0 : R.length) ?? 0 : 0, [w, I] = G(s && !o ? 0 : t), F = D(w), b = D(0);
24
24
  O(() => {
25
- if (t) return;
25
+ if (o) return;
26
26
  const y = (g) => {
27
- x.current = g, I(g);
27
+ F.current = g, I(g);
28
28
  };
29
- if (!s || v || typeof window > "u") {
30
- y(f);
29
+ if (!s || N || typeof window > "u") {
30
+ y(t);
31
31
  return;
32
32
  }
33
- const R = x.current, j = performance.now(), q = 900, k = (g) => {
34
- const b = Math.min(1, (g - j) / q);
35
- y(b < 1 ? R + (f - R) * (1 - Math.pow(1 - b, 3)) : f), b < 1 && (S.current = requestAnimationFrame(k));
33
+ const k = F.current, j = performance.now(), q = 900, z = (g) => {
34
+ const x = Math.min(1, (g - j) / q);
35
+ y(x < 1 ? k + (t - k) * (1 - Math.pow(1 - x, 3)) : t), x < 1 && (b.current = requestAnimationFrame(z));
36
36
  };
37
- return S.current = requestAnimationFrame(k), () => cancelAnimationFrame(S.current);
38
- }, [f, s, v, t]);
39
- const M = new Intl.NumberFormat(void 0, l), F = (y) => M.format(y), T = t || w === f || !s ? a : i ? w.toFixed(E) : Math.round(w * 100) / 100, A = n === void 0 ? null : n >= 0 === o;
40
- return /* @__PURE__ */ r("div", { ...u, className: N("alea-stat", p), children: [
37
+ return b.current = requestAnimationFrame(z), () => cancelAnimationFrame(b.current);
38
+ }, [t, s, N, o]);
39
+ const M = new Intl.NumberFormat(void 0, m), A = (y) => M.format(y), T = o || w === t || !s ? a : i ? w.toFixed(S) : Math.round(w * 100) / 100, C = n === void 0 ? null : n >= 0 === u;
40
+ return /* @__PURE__ */ r("div", { ...f, className: v("alea-stat", p), children: [
41
41
  /* @__PURE__ */ e("div", { className: "alea-stat-label", children: c }),
42
- /* @__PURE__ */ e("div", { className: "alea-stat-value", children: t ? /* @__PURE__ */ r("span", { children: [
43
- m,
42
+ /* @__PURE__ */ e("div", { className: "alea-stat-value", children: o ? /* @__PURE__ */ r("span", { children: [
43
+ l,
44
44
  s ? /* @__PURE__ */ e(Y, { children: String(a) }) : a,
45
45
  h
46
46
  ] }) : /* @__PURE__ */ r(L, { children: [
47
47
  /* @__PURE__ */ r("span", { "aria-hidden": "true", children: [
48
- m,
49
- F(T),
48
+ l,
49
+ A(T),
50
50
  h
51
51
  ] }),
52
- /* @__PURE__ */ e("span", { className: "alea-visually-hidden", children: F(a) })
52
+ /* @__PURE__ */ e("span", { className: "alea-visually-hidden", children: A(a) })
53
53
  ] }) }),
54
- n !== void 0 && /* @__PURE__ */ r("div", { className: "alea-stat-delta", "data-good": A ? !0 : void 0, "data-bad": A === !1 ? !0 : void 0, children: [
54
+ n !== void 0 && /* @__PURE__ */ r("div", { className: "alea-stat-delta", "data-good": C ? !0 : void 0, "data-bad": C === !1 ? !0 : void 0, children: [
55
55
  n >= 0 ? /* @__PURE__ */ e(K, { size: 14, "aria-hidden": "true" }) : /* @__PURE__ */ e(P, { size: 14, "aria-hidden": "true" }),
56
56
  /* @__PURE__ */ r("span", { children: [
57
57
  n >= 0 ? "+" : "",
@@ -64,22 +64,22 @@ function ce({ label: c, value: a, isDecimal: d, formatOptions: l, delta: n, high
64
64
  ] })
65
65
  ] });
66
66
  }
67
- function Z({ title: c, description: a, icon: d, illustration: l, action: n, secondaryAction: o, footer: s, size: m, variant: h, headingAs: p = "h3", className: u, ...i }) {
68
- return /* @__PURE__ */ r("div", { ...i, className: N("alea-empty", u), "data-size": m, "data-variant": h, children: [
69
- /* @__PURE__ */ e("span", { className: l ? "alea-empty-art" : "alea-empty-icon", "aria-hidden": "true", children: d ?? /* @__PURE__ */ e(D, {}) }),
67
+ function Z({ title: c, description: a, icon: d, illustration: m, action: n, secondaryAction: u, footer: s, size: l, variant: h, headingAs: p = "h3", className: f, ...i }) {
68
+ return /* @__PURE__ */ r("div", { ...i, className: v("alea-empty", f), "data-size": l, "data-variant": h, children: [
69
+ /* @__PURE__ */ e("span", { className: m ? "alea-empty-art" : "alea-empty-icon", "aria-hidden": "true", children: d ?? /* @__PURE__ */ e(E, {}) }),
70
70
  U(p, { className: "alea-empty-title" }, c),
71
71
  a && /* @__PURE__ */ e("p", { className: "alea-empty-text", children: a }),
72
- (n || o) && /* @__PURE__ */ r("div", { className: "alea-empty-action", children: [
72
+ (n || u) && /* @__PURE__ */ r("div", { className: "alea-empty-action", children: [
73
73
  n,
74
- o
74
+ u
75
75
  ] }),
76
76
  s && /* @__PURE__ */ e("p", { className: "alea-empty-footer", children: s })
77
77
  ] });
78
78
  }
79
- const $ = { success: J, error: H, 404: B, 403: _, 500: X, info: D };
79
+ const $ = { success: J, error: H, 404: B, 403: _, 500: X, info: E };
80
80
  function de({ status: c, className: a, ...d }) {
81
- const l = $[c];
82
- return /* @__PURE__ */ e(Z, { ...d, headingAs: d.headingAs ?? "h2", icon: /* @__PURE__ */ e(l, {}), className: N("alea-result", a), "data-status": c });
81
+ const m = $[c];
82
+ return /* @__PURE__ */ e(Z, { ...d, headingAs: d.headingAs ?? "h2", icon: /* @__PURE__ */ e(m, {}), className: v("alea-result", a), "data-status": c });
83
83
  }
84
84
  export {
85
85
  ie as Descriptions,
@@ -27,11 +27,15 @@ export interface TimelineProps {
27
27
  reverse?: boolean;
28
28
  /** sm (tighter, for side panels) or md (default). */
29
29
  size?: 'sm' | 'md';
30
+ /** Where the time sits: above the title (default) or right under it. */
31
+ timePlacement?: 'above' | 'below';
32
+ /** Name of the list for screen readers ("Order history"). */
33
+ 'aria-label'?: string;
30
34
  /** Extra class names for the root element. */
31
35
  className?: string;
32
36
  }
33
37
  /** Events in order: a changelog, an order's progress, an activity feed. Content on one side, the other, or alternating; reversed; two sizes. */
34
- export declare function Timeline({ items, pending, mode, reverse, size, className }: TimelineProps): import("react").JSX.Element;
38
+ export declare function Timeline({ items, pending, mode, reverse, size, timePlacement, className, 'aria-label': label }: TimelineProps): import("react").JSX.Element;
35
39
  export interface CarouselProps {
36
40
  /** The slides. */
37
41
  children: ReactNode[];