@actioneer/ads 0.5.4 → 0.5.6

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 (93) hide show
  1. package/components/accordion.js +15 -15
  2. package/components/agent-icon.d.ts +64 -0
  3. package/components/agent-icon.js +251 -0
  4. package/components/ai-elements/agent-trace.d.ts +8 -1
  5. package/components/ai-elements/agent-trace.js +164 -129
  6. package/components/ai-elements/chain-of-thought-icon.d.ts +42 -0
  7. package/components/ai-elements/chain-of-thought-icon.js +283 -0
  8. package/components/ai-elements/chain-of-thought.js +7 -7
  9. package/components/ai-elements/chart.js +38 -35
  10. package/components/ai-elements/index.d.ts +1 -0
  11. package/components/ai-elements/inline-citation.js +40 -40
  12. package/components/ai-elements/message.js +5 -5
  13. package/components/ai-elements/queue.js +1 -1
  14. package/components/ai-elements/research-activity.d.ts +2 -0
  15. package/components/ai-elements/research-activity.js +79 -81
  16. package/components/ai-elements/task-progress.js +2 -2
  17. package/components/ai-elements/tool.d.ts +4 -2
  18. package/components/ai-elements/tool.js +74 -54
  19. package/components/ai-elements/transcript.js +1 -1
  20. package/components/alert.js +1 -1
  21. package/components/answer.d.ts +2644 -311
  22. package/components/answer.js +1776 -371
  23. package/components/assistant-ui/answer-tool-ui.js +27 -28
  24. package/components/assistant-ui/chain-of-thought.d.ts +7 -2
  25. package/components/assistant-ui/composer-harness.js +20 -16
  26. package/components/assistant-ui/follow-up-suggestions.d.ts +5 -1
  27. package/components/assistant-ui/follow-up-suggestions.js +47 -19
  28. package/components/assistant-ui/reasoning.js +35 -31
  29. package/components/assistant-ui/tool-fallback.js +125 -122
  30. package/components/assistant-ui/tool-group.d.ts +3 -1
  31. package/components/assistant-ui/tool-group.js +48 -43
  32. package/components/audio-waveform.js +14 -14
  33. package/components/autocomplete.js +52 -48
  34. package/components/avatar.js +58 -44
  35. package/components/badge.js +3 -3
  36. package/components/brand-texture.js +1 -1
  37. package/components/breadcrumbs.d.ts +27 -1
  38. package/components/breadcrumbs.js +94 -42
  39. package/components/button.js +15 -15
  40. package/components/carousel.js +10 -10
  41. package/components/chart.js +77 -77
  42. package/components/chip.js +3 -3
  43. package/components/code-block.d.ts +39 -17
  44. package/components/code-block.js +153 -104
  45. package/components/command-palette.js +27 -25
  46. package/components/connector-card.js +2 -2
  47. package/components/dropdown.js +65 -61
  48. package/components/empty-state.js +15 -15
  49. package/components/field.js +16 -16
  50. package/components/index.d.ts +4 -0
  51. package/components/index.js +525 -478
  52. package/components/infinite-canvas.js +60 -60
  53. package/components/kbd.js +6 -6
  54. package/components/link.js +6 -6
  55. package/components/modal.js +22 -20
  56. package/components/page-header.js +1 -1
  57. package/components/pagination.js +22 -22
  58. package/components/pixel-blast-svg.js +1 -1
  59. package/components/pixel-icon.d.ts +31 -0
  60. package/components/pixel-icon.js +733 -0
  61. package/components/popover.js +46 -42
  62. package/components/ripple.d.ts +29 -0
  63. package/components/ripple.js +17 -0
  64. package/components/segmented.js +24 -23
  65. package/components/select.js +71 -67
  66. package/components/selection-action-bar.js +22 -22
  67. package/components/sidebar.d.ts +11 -3
  68. package/components/sidebar.js +161 -148
  69. package/components/stepper.d.ts +2 -0
  70. package/components/stepper.js +80 -43
  71. package/components/table.d.ts +7 -0
  72. package/components/table.js +223 -155
  73. package/components/tabs.d.ts +3 -1
  74. package/components/tabs.js +165 -144
  75. package/components/textarea.js +10 -8
  76. package/components/toast.js +48 -46
  77. package/components/tooltip.js +61 -59
  78. package/components/tree.js +44 -41
  79. package/components/typography.d.ts +1 -1
  80. package/components/typography.js +25 -25
  81. package/components/viz-charts.js +133 -133
  82. package/fonts/aribau-grotesk-500.otf +0 -0
  83. package/fonts/aribau-grotesk-600.woff2 +0 -0
  84. package/fonts.css +6 -4
  85. package/lib/icons.d.ts +411 -402
  86. package/lib/icons.js +109 -107
  87. package/llms.txt +98 -8
  88. package/manifest.json +1012 -96
  89. package/package.json +5 -5
  90. package/styles.css +206 -81
  91. package/theme.css +200 -77
  92. package/fonts/aribau-grotesk-400.otf +0 -0
  93. package/fonts/aribau-grotesk-700.otf +0 -0
@@ -1,29 +1,30 @@
1
1
  "use client";
2
- import { jsx as g } from "react/jsx-runtime";
2
+ import { jsx as g, jsxs as b } from "react/jsx-runtime";
3
3
  import * as n from "react";
4
- import { createPortal as P } from "react-dom";
5
- import { MotionConfig as b, AnimatePresence as C, motion as y } from "motion/react";
6
- import { cn as L } from "../lib/cn.js";
7
- import { floatVariants as R } from "../lib/motion.js";
8
- const k = {
4
+ import { createPortal as C } from "react-dom";
5
+ import { MotionConfig as y, AnimatePresence as L, motion as R } from "motion/react";
6
+ import { cn as k } from "../lib/cn.js";
7
+ import { floatVariants as z } from "../lib/motion.js";
8
+ import { Ripple as O } from "./ripple.js";
9
+ const h = {
9
10
  start: "top left",
10
11
  center: "top",
11
12
  end: "top right"
12
- }, h = n.createContext(null);
13
- function x(r) {
14
- const e = n.useContext(h);
13
+ }, x = n.createContext(null);
14
+ function E(o) {
15
+ const e = n.useContext(x);
15
16
  if (!e)
16
- throw new Error(`${r} must be used within a <Popover>.`);
17
+ throw new Error(`${o} must be used within a <Popover>.`);
17
18
  return e;
18
19
  }
19
- function M({ children: r, defaultOpen: e = !1 }) {
20
- const [d, l] = n.useState(e), u = n.useRef(null);
21
- return /* @__PURE__ */ g(h.Provider, { value: { open: d, setOpen: l, triggerRef: u }, children: r });
20
+ function T({ children: o, defaultOpen: e = !1 }) {
21
+ const [d, a] = n.useState(e), u = n.useRef(null);
22
+ return /* @__PURE__ */ g(x.Provider, { value: { open: d, setOpen: a, triggerRef: u }, children: o });
22
23
  }
23
- function S({ children: r }) {
24
- const { open: e, setOpen: d, triggerRef: l } = x("PopoverTrigger"), u = r;
24
+ function W({ children: o }) {
25
+ const { open: e, setOpen: d, triggerRef: a } = E("PopoverTrigger"), u = o;
25
26
  return n.cloneElement(u, {
26
- ref: l,
27
+ ref: a,
27
28
  "aria-expanded": e,
28
29
  "aria-haspopup": !0,
29
30
  onClick: (i) => {
@@ -32,46 +33,46 @@ function S({ children: r }) {
32
33
  }
33
34
  });
34
35
  }
35
- function T({
36
- className: r,
36
+ function K({
37
+ className: o,
37
38
  align: e = "start",
38
39
  sideOffset: d = 8,
39
- children: l,
40
+ children: a,
40
41
  ...u
41
42
  }) {
42
- const { open: i, setOpen: f, triggerRef: s } = x("PopoverContent"), w = n.useRef(null), [c, E] = n.useState(null);
43
+ const { open: i, setOpen: f, triggerRef: s } = E("PopoverContent"), w = n.useRef(null), [c, P] = n.useState(null);
43
44
  return n.useLayoutEffect(() => {
44
45
  if (!i) return;
45
46
  const p = s.current;
46
47
  if (!p) return;
47
- const o = () => {
48
+ const r = () => {
48
49
  var v;
49
50
  const t = p.getBoundingClientRect(), m = ((v = w.current) == null ? void 0 : v.offsetWidth) ?? 0;
50
- let a = t.left;
51
- e === "center" ? a = t.left + t.width / 2 - m / 2 : e === "end" && (a = t.right - m), E({ top: t.bottom + d, left: a });
51
+ let l = t.left;
52
+ e === "center" ? l = t.left + t.width / 2 - m / 2 : e === "end" && (l = t.right - m), P({ top: t.bottom + d, left: l });
52
53
  };
53
- return o(), window.addEventListener("resize", o), window.addEventListener("scroll", o, !0), () => {
54
- window.removeEventListener("resize", o), window.removeEventListener("scroll", o, !0);
54
+ return r(), window.addEventListener("resize", r), window.addEventListener("scroll", r, !0), () => {
55
+ window.removeEventListener("resize", r), window.removeEventListener("scroll", r, !0);
55
56
  };
56
57
  }, [i, e, d, s]), n.useEffect(() => {
57
58
  if (!i) return;
58
59
  const p = (t) => {
59
60
  t.key === "Escape" && f(!1);
60
- }, o = (t) => {
61
- var a, v;
61
+ }, r = (t) => {
62
+ var l, v;
62
63
  const m = t.target;
63
- (a = w.current) != null && a.contains(m) || (v = s.current) != null && v.contains(m) || f(!1);
64
+ (l = w.current) != null && l.contains(m) || (v = s.current) != null && v.contains(m) || f(!1);
64
65
  };
65
- return document.addEventListener("keydown", p), document.addEventListener("pointerdown", o), () => {
66
- document.removeEventListener("keydown", p), document.removeEventListener("pointerdown", o);
66
+ return document.addEventListener("keydown", p), document.addEventListener("pointerdown", r), () => {
67
+ document.removeEventListener("keydown", p), document.removeEventListener("pointerdown", r);
67
68
  };
68
- }, [i, f, s]), P(
69
- /* @__PURE__ */ g(b, { reducedMotion: "user", children: /* @__PURE__ */ g(C, { children: i && /* @__PURE__ */ g(
70
- y.div,
69
+ }, [i, f, s]), C(
70
+ /* @__PURE__ */ g(y, { reducedMotion: "user", children: /* @__PURE__ */ g(L, { children: i && /* @__PURE__ */ b(
71
+ R.div,
71
72
  {
72
73
  ref: w,
73
74
  role: "dialog",
74
- variants: R,
75
+ variants: z,
75
76
  initial: "hidden",
76
77
  animate: "visible",
77
78
  exit: "hidden",
@@ -80,22 +81,25 @@ function T({
80
81
  top: (c == null ? void 0 : c.top) ?? 0,
81
82
  left: (c == null ? void 0 : c.left) ?? 0,
82
83
  visibility: c ? "visible" : "hidden",
83
- transformOrigin: k[e]
84
+ transformOrigin: h[e]
84
85
  },
85
- className: L(
86
- "z-50 min-w-44 rounded-lg border border-border bg-elevated p-3",
86
+ className: k(
87
+ "relative z-50 min-w-44 rounded-lg border border-border bg-elevated p-3",
87
88
  "text-xs text-foreground shadow-elevation",
88
- r
89
+ o
89
90
  ),
90
91
  ...u,
91
- children: l
92
+ children: [
93
+ /* @__PURE__ */ g(O, { origin: h[e] }),
94
+ a
95
+ ]
92
96
  }
93
97
  ) }) }),
94
98
  document.body
95
99
  );
96
100
  }
97
101
  export {
98
- M as Popover,
99
- T as PopoverContent,
100
- S as PopoverTrigger
102
+ T as Popover,
103
+ K as PopoverContent,
104
+ W as PopoverTrigger
101
105
  };
@@ -0,0 +1,29 @@
1
+ /**
2
+ * Ripple — the appearance wash for floating surfaces (principle 3). Drop it as
3
+ * the FIRST child of a `relative` panel and a soft brand tint radiates from the
4
+ * panel's origin corner and fades, once, as the surface mounts — the same
5
+ * origin the panel scales from, so the ripple reads as the surface arriving.
6
+ *
7
+ * <motion.div className="relative …" style={{ transformOrigin: origin }}>
8
+ * <Ripple origin={origin} />
9
+ * {children}
10
+ * </motion.div>
11
+ *
12
+ * It is an absolute, `pointer-events-none`, `z-0` layer clipped to the panel
13
+ * radius (`rounded-[inherit]`), so it sits under the content and never
14
+ * intercepts input. All timing/curve/tint come from tokens (`--ripple-*`,
15
+ * `--ease-out`); reduced-motion drops it entirely. Remount it (via `key`) to
16
+ * replay on each open.
17
+ */
18
+ export interface RippleProps {
19
+ /**
20
+ * CSS position keywords the wash emanates from — pass the panel's own
21
+ * `transformOrigin` (e.g. "top left", "bottom right", "center").
22
+ */
23
+ origin?: string;
24
+ className?: string;
25
+ }
26
+ export declare function Ripple({ origin, className }: RippleProps): import("react").JSX.Element;
27
+ export declare namespace Ripple {
28
+ var displayName: string;
29
+ }
@@ -0,0 +1,17 @@
1
+ "use client";
2
+ import { jsx as p } from "react/jsx-runtime";
3
+ import { cn as r } from "../lib/cn.js";
4
+ function n({ origin: e = "center", className: i }) {
5
+ return /* @__PURE__ */ p(
6
+ "span",
7
+ {
8
+ "aria-hidden": "true",
9
+ className: r("ads-ripple", i),
10
+ style: { "--ripple-origin": e }
11
+ }
12
+ );
13
+ }
14
+ n.displayName = "Ripple";
15
+ export {
16
+ n as Ripple
17
+ };
@@ -1,15 +1,15 @@
1
1
  "use client";
2
2
  import { jsx as n, jsxs as b } from "react/jsx-runtime";
3
- import * as d from "react";
4
- import { MotionConfig as v, motion as h } from "motion/react";
5
- import { cva as l } from "class-variance-authority";
3
+ import * as l from "react";
4
+ import { MotionConfig as h, motion as v } from "motion/react";
5
+ import { cva as d } from "class-variance-authority";
6
6
  import { cn as c } from "../lib/cn.js";
7
7
  import { EASE_OUT as w } from "../lib/motion.js";
8
- const y = l(
9
- // Borderless muted track — matches the demo's tab switcher (the pill
10
- // provides the definition; a stroke around the track read as a second,
11
- // heavier control).
12
- "inline-flex items-center gap-1 rounded-lg bg-muted p-1",
8
+ const y = d(
9
+ // Borderless recessed track on ink-200 (bg-surface) — matches the Tabs
10
+ // primary track (the pill provides the definition; a stroke around the
11
+ // track read as a second, heavier control).
12
+ "inline-flex items-center gap-1 rounded-full bg-surface p-1",
13
13
  {
14
14
  variants: {
15
15
  size: {
@@ -20,11 +20,11 @@ const y = l(
20
20
  },
21
21
  defaultVariants: { size: "md" }
22
22
  }
23
- ), k = l(
23
+ ), D = d(
24
24
  c(
25
25
  // The active pill is a shared motion thumb that SLIDES between options
26
26
  // (layoutId), so the option itself only carries text color.
27
- "relative inline-flex items-center justify-center whitespace-nowrap rounded-md font-medium select-none",
27
+ "relative inline-flex items-center justify-center whitespace-nowrap rounded-full font-normal select-none",
28
28
  "transition-colors duration-(--duration-fast) cursor-pointer",
29
29
  "outline-none focus-visible:ring-3 focus-visible:ring-ring",
30
30
  "disabled:pointer-events-none disabled:opacity-50"
@@ -43,10 +43,10 @@ const y = l(
43
43
  },
44
44
  defaultVariants: { size: "md", selected: !1 }
45
45
  }
46
- ), A = d.forwardRef(({ options: r, value: a, onChange: s, size: o, className: u, ...m }, f) => {
47
- const g = d.useId(), i = (e) => {
48
- const t = r.findIndex((x) => x.value === a), p = ((t < 0 ? 0 : t) + e + r.length) % r.length;
49
- s(r[p].value);
46
+ ), k = l.forwardRef(({ options: r, value: a, onChange: o, size: s, className: u, ...m }, f) => {
47
+ const p = l.useId(), i = (e) => {
48
+ const t = r.findIndex((x) => x.value === a), g = ((t < 0 ? 0 : t) + e + r.length) % r.length;
49
+ o(r[g].value);
50
50
  };
51
51
  return /* @__PURE__ */ n(
52
52
  "div",
@@ -65,9 +65,9 @@ const y = l(
65
65
  break;
66
66
  }
67
67
  },
68
- className: c(y({ size: o }), u),
68
+ className: c(y({ size: s }), u),
69
69
  ...m,
70
- children: /* @__PURE__ */ n(v, { reducedMotion: "user", children: r.map((e) => {
70
+ children: /* @__PURE__ */ n(h, { reducedMotion: "user", children: r.map((e) => {
71
71
  const t = e.value === a;
72
72
  return /* @__PURE__ */ b(
73
73
  "button",
@@ -76,16 +76,17 @@ const y = l(
76
76
  role: "radio",
77
77
  "aria-checked": t,
78
78
  tabIndex: t ? 0 : -1,
79
- onClick: () => s(e.value),
80
- className: k({ size: o, selected: t }),
79
+ onClick: () => o(e.value),
80
+ className: D({ size: s, selected: t }),
81
81
  children: [
82
82
  t && /* @__PURE__ */ n(
83
- h.span,
83
+ v.span,
84
84
  {
85
- layoutId: g,
85
+ layoutId: p,
86
86
  "aria-hidden": !0,
87
+ layoutDependency: a,
87
88
  transition: { duration: 0.2, ease: w },
88
- className: "absolute inset-0 rounded-md bg-elevated shadow-elevation"
89
+ className: "absolute inset-0 rounded-full bg-elevated shadow-elevation"
89
90
  }
90
91
  ),
91
92
  /* @__PURE__ */ n("span", { className: "relative", children: e.label })
@@ -97,7 +98,7 @@ const y = l(
97
98
  }
98
99
  );
99
100
  });
100
- A.displayName = "SegmentedControl";
101
+ k.displayName = "SegmentedControl";
101
102
  export {
102
- A as SegmentedControl
103
+ k as SegmentedControl
103
104
  };
@@ -1,5 +1,5 @@
1
1
  "use client";
2
- import { jsxs as x, jsx as i } from "react/jsx-runtime";
2
+ import { jsxs as m, jsx as i } from "react/jsx-runtime";
3
3
  import * as s from "react";
4
4
  import { cva as j } from "class-variance-authority";
5
5
  import { MotionConfig as M, AnimatePresence as V, motion as $ } from "motion/react";
@@ -7,7 +7,8 @@ import { ChevronDown as C, Check as K } from "../lib/icons.js";
7
7
  import { cn as d } from "../lib/cn.js";
8
8
  import { inputBaseClass as L } from "./field.js";
9
9
  import { floatVariants as O } from "../lib/motion.js";
10
- const P = j(
10
+ import { Ripple as P } from "./ripple.js";
11
+ const T = j(
11
12
  d(
12
13
  L,
13
14
  "items-center justify-between gap-2 text-left cursor-pointer",
@@ -23,93 +24,93 @@ const P = j(
23
24
  },
24
25
  defaultVariants: { size: "md" }
25
26
  }
26
- ), T = s.forwardRef(
27
+ ), _ = s.forwardRef(
27
28
  ({
28
- items: o,
29
+ items: r,
29
30
  value: c,
30
- onChange: m,
31
+ onChange: b,
31
32
  placeholder: I = "Select…",
32
33
  size: N,
33
- disabled: h,
34
+ disabled: w,
34
35
  isInvalid: E,
35
- className: A,
36
- id: R,
37
- placement: w = "bottom"
36
+ className: R,
37
+ id: A,
38
+ placement: v = "bottom"
38
39
  }, S) => {
39
- const [r, l] = s.useState(!1), [a, b] = s.useState(-1), g = s.useRef(null), k = s.useRef(null), u = s.useId(), v = o.find((e) => e.value === c), z = s.useCallback(() => {
40
- const e = o.findIndex((t) => t.value === c);
41
- return e >= 0 && !o[e].disabled ? e : o.findIndex((t) => !t.disabled);
42
- }, [o, c]);
40
+ const [o, l] = s.useState(!1), [a, x] = s.useState(-1), g = s.useRef(null), k = s.useRef(null), u = s.useId(), h = r.find((e) => e.value === c), z = s.useCallback(() => {
41
+ const e = r.findIndex((t) => t.value === c);
42
+ return e >= 0 && !r[e].disabled ? e : r.findIndex((t) => !t.disabled);
43
+ }, [r, c]);
43
44
  s.useEffect(() => {
44
- if (!r) return;
45
+ if (!o) return;
45
46
  const e = (t) => {
46
47
  var n;
47
48
  (n = g.current) != null && n.contains(t.target) || l(!1);
48
49
  };
49
50
  return document.addEventListener("mousedown", e), () => document.removeEventListener("mousedown", e);
50
- }, [r]), s.useEffect(() => {
51
+ }, [o]), s.useEffect(() => {
51
52
  var t;
52
- if (!r || a < 0) return;
53
+ if (!o || a < 0) return;
53
54
  const e = (t = k.current) == null ? void 0 : t.children[a];
54
55
  e == null || e.scrollIntoView({ block: "nearest" });
55
- }, [r, a]);
56
+ }, [o, a]);
56
57
  const f = () => {
57
- h || (b(z()), l(!0));
58
+ w || (x(z()), l(!0));
58
59
  }, y = (e) => {
59
- b((t) => {
60
+ x((t) => {
60
61
  let n = t;
61
- for (let p = 0; p < o.length; p++)
62
- if (n = (n + e + o.length) % o.length, !o[n].disabled) return n;
62
+ for (let p = 0; p < r.length; p++)
63
+ if (n = (n + e + r.length) % r.length, !r[n].disabled) return n;
63
64
  return t;
64
65
  });
65
66
  }, D = (e) => {
66
- const t = o[e];
67
- !t || t.disabled || (m == null || m(t.value), l(!1));
67
+ const t = r[e];
68
+ !t || t.disabled || (b == null || b(t.value), l(!1));
68
69
  };
69
- return /* @__PURE__ */ x("div", { ref: g, className: "relative", children: [
70
- /* @__PURE__ */ x(
70
+ return /* @__PURE__ */ m("div", { ref: g, className: "relative", children: [
71
+ /* @__PURE__ */ m(
71
72
  "button",
72
73
  {
73
74
  ref: S,
74
- id: R,
75
+ id: A,
75
76
  type: "button",
76
77
  role: "combobox",
77
78
  "aria-haspopup": "listbox",
78
- "aria-expanded": r,
79
+ "aria-expanded": o,
79
80
  "aria-controls": u,
80
81
  "aria-invalid": E || void 0,
81
- disabled: h,
82
- onClick: () => r ? l(!1) : f(),
82
+ disabled: w,
83
+ onClick: () => o ? l(!1) : f(),
83
84
  onKeyDown: (e) => {
84
85
  switch (e.key) {
85
86
  case "ArrowDown":
86
- e.preventDefault(), r ? y(1) : f();
87
+ e.preventDefault(), o ? y(1) : f();
87
88
  break;
88
89
  case "ArrowUp":
89
- e.preventDefault(), r ? y(-1) : f();
90
+ e.preventDefault(), o ? y(-1) : f();
90
91
  break;
91
92
  case "Enter":
92
93
  case " ":
93
- e.preventDefault(), r ? D(a) : f();
94
+ e.preventDefault(), o ? D(a) : f();
94
95
  break;
95
96
  case "Escape":
96
- r && (e.preventDefault(), l(!1));
97
+ o && (e.preventDefault(), l(!1));
97
98
  break;
98
99
  case "Tab":
99
100
  l(!1);
100
101
  break;
101
102
  }
102
103
  },
103
- className: d(P({ size: N }), A),
104
+ className: d(T({ size: N }), R),
104
105
  children: [
105
106
  /* @__PURE__ */ i(
106
107
  "span",
107
108
  {
108
109
  className: d(
109
110
  "truncate",
110
- !v && "text-muted-foreground"
111
+ !h && "text-muted-foreground"
111
112
  ),
112
- children: v ? v.label : I
113
+ children: h ? h.label : I
113
114
  }
114
115
  ),
115
116
  /* @__PURE__ */ i(
@@ -117,7 +118,7 @@ const P = j(
117
118
  {
118
119
  className: d(
119
120
  "size-4 text-muted-foreground transition-transform duration-(--duration-fast) ease-out motion-reduce:transition-none",
120
- r && "rotate-180"
121
+ o && "rotate-180"
121
122
  ),
122
123
  "aria-hidden": !0
123
124
  }
@@ -125,7 +126,7 @@ const P = j(
125
126
  ]
126
127
  }
127
128
  ),
128
- /* @__PURE__ */ i(M, { reducedMotion: "user", children: /* @__PURE__ */ i(V, { children: r && /* @__PURE__ */ i(
129
+ /* @__PURE__ */ i(M, { reducedMotion: "user", children: /* @__PURE__ */ i(V, { children: o && /* @__PURE__ */ m(
129
130
  $.ul,
130
131
  {
131
132
  ref: k,
@@ -137,44 +138,47 @@ const P = j(
137
138
  animate: "visible",
138
139
  exit: "hidden",
139
140
  style: {
140
- transformOrigin: w === "top" ? "bottom" : "top"
141
+ transformOrigin: v === "top" ? "bottom" : "top"
141
142
  },
142
143
  className: d(
143
144
  "absolute z-50 max-h-60 w-full overflow-auto p-1",
144
145
  "rounded-md border border-border bg-elevated shadow-elevation",
145
- w === "top" ? "bottom-full mb-1.5" : "top-full mt-1.5"
146
+ v === "top" ? "bottom-full mb-1.5" : "top-full mt-1.5"
146
147
  ),
147
- children: o.map((e, t) => {
148
- const n = e.value === c, p = t === a;
149
- return /* @__PURE__ */ x(
150
- "li",
151
- {
152
- id: `${u}-opt-${t}`,
153
- role: "option",
154
- "aria-selected": n,
155
- "aria-disabled": e.disabled || void 0,
156
- onMouseEnter: () => !e.disabled && b(t),
157
- onClick: () => D(t),
158
- className: d(
159
- "flex cursor-pointer items-center justify-between gap-2",
160
- "rounded-sm px-2 py-1.5 text-xs text-foreground select-none",
161
- p && !e.disabled && "bg-muted",
162
- e.disabled && "pointer-events-none opacity-50"
163
- ),
164
- children: [
165
- /* @__PURE__ */ i("span", { className: "truncate", children: e.label }),
166
- n && /* @__PURE__ */ i(K, { className: "size-4 shrink-0", "aria-hidden": !0 })
167
- ]
168
- },
169
- e.value
170
- );
171
- })
148
+ children: [
149
+ /* @__PURE__ */ i(P, { origin: v === "top" ? "bottom" : "top" }),
150
+ r.map((e, t) => {
151
+ const n = e.value === c, p = t === a;
152
+ return /* @__PURE__ */ m(
153
+ "li",
154
+ {
155
+ id: `${u}-opt-${t}`,
156
+ role: "option",
157
+ "aria-selected": n,
158
+ "aria-disabled": e.disabled || void 0,
159
+ onMouseEnter: () => !e.disabled && x(t),
160
+ onClick: () => D(t),
161
+ className: d(
162
+ "flex cursor-pointer items-center justify-between gap-2",
163
+ "rounded-sm px-2 py-1.5 text-xs text-foreground select-none",
164
+ p && !e.disabled && "bg-muted",
165
+ e.disabled && "pointer-events-none opacity-50"
166
+ ),
167
+ children: [
168
+ /* @__PURE__ */ i("span", { className: "truncate", children: e.label }),
169
+ n && /* @__PURE__ */ i(K, { className: "size-4 shrink-0", "aria-hidden": !0 })
170
+ ]
171
+ },
172
+ e.value
173
+ );
174
+ })
175
+ ]
172
176
  }
173
177
  ) }) })
174
178
  ] });
175
179
  }
176
180
  );
177
- T.displayName = "Select";
181
+ _.displayName = "Select";
178
182
  export {
179
- T as Select
183
+ _ as Select
180
184
  };
@@ -1,32 +1,32 @@
1
1
  "use client";
2
- import { jsxs as i, jsx as a } from "react/jsx-runtime";
3
- import * as c from "react";
4
- import { cn as d } from "../lib/cn.js";
5
- import { Button as u } from "./button.js";
6
- const g = c.forwardRef(
2
+ import { jsxs as c, jsx as a } from "react/jsx-runtime";
3
+ import * as i from "react";
4
+ import { cn as s } from "../lib/cn.js";
5
+ import { Button as g } from "./button.js";
6
+ const u = i.forwardRef(
7
7
  ({
8
8
  className: r,
9
9
  selectedCount: o,
10
- selectedLabel: t,
11
- actions: n,
10
+ selectedLabel: n,
11
+ actions: t,
12
12
  onClear: e,
13
13
  clearLabel: l = "Clear",
14
14
  ...m
15
- }, f) => /* @__PURE__ */ i(
15
+ }, f) => /* @__PURE__ */ c(
16
16
  "div",
17
17
  {
18
18
  ref: f,
19
- className: d(
19
+ className: s(
20
20
  "flex items-center gap-3 rounded-lg bg-brand px-3 py-2 text-xs text-brand-foreground",
21
21
  r
22
22
  ),
23
23
  ...m,
24
24
  children: [
25
- /* @__PURE__ */ a("span", { className: "font-medium tabular-nums", children: t ?? `${o} selected` }),
26
- /* @__PURE__ */ i("div", { className: "ml-auto flex items-center gap-1", children: [
27
- n,
25
+ /* @__PURE__ */ a("span", { className: "font-normal tabular-nums", children: n ?? `${o} selected` }),
26
+ /* @__PURE__ */ c("div", { className: "ml-auto flex items-center gap-1", children: [
27
+ t,
28
28
  e && /* @__PURE__ */ a(
29
- s,
29
+ d,
30
30
  {
31
31
  onClick: e,
32
32
  className: "text-brand-foreground/70 hover:text-brand-foreground",
@@ -38,22 +38,22 @@ const g = c.forwardRef(
38
38
  }
39
39
  )
40
40
  );
41
- g.displayName = "SelectionActionBar";
42
- const s = c.forwardRef(({ className: r, variant: o = "ghost", size: t = "xs", ...n }, e) => /* @__PURE__ */ a(
43
- u,
41
+ u.displayName = "SelectionActionBar";
42
+ const d = i.forwardRef(({ className: r, variant: o = "ghost", size: n = "xs", ...t }, e) => /* @__PURE__ */ a(
43
+ g,
44
44
  {
45
45
  ref: e,
46
46
  variant: o,
47
- size: t,
48
- className: d(
47
+ size: n,
48
+ className: s(
49
49
  "text-brand-foreground hover:bg-brand-foreground/10 hover:text-brand-foreground focus-visible:ring-brand-foreground",
50
50
  r
51
51
  ),
52
- ...n
52
+ ...t
53
53
  }
54
54
  ));
55
- s.displayName = "SelectionActionBarAction";
55
+ d.displayName = "SelectionActionBarAction";
56
56
  export {
57
- g as SelectionActionBar,
58
- s as SelectionActionBarAction
57
+ u as SelectionActionBar,
58
+ d as SelectionActionBarAction
59
59
  };
@@ -36,7 +36,10 @@ export declare const Sidebar: React.ForwardRefExoticComponent<SidebarProps & Rea
36
36
  * Collapse toggle. Place inside SidebarHeader. Shows a tooltip with the ⌘B
37
37
  * shortcut, and lifts to a white chip on hover.
38
38
  */
39
- export declare function SidebarTrigger({ className, onClick, ...props }: React.ButtonHTMLAttributes<HTMLButtonElement>): React.JSX.Element;
39
+ export declare function SidebarTrigger({ className, onClick, tooltipSide, ...props }: React.ButtonHTMLAttributes<HTMLButtonElement> & {
40
+ /** Which side the Collapse/Expand tooltip opens on. Default `right`. */
41
+ tooltipSide?: "top" | "right" | "bottom" | "left";
42
+ }): React.JSX.Element;
40
43
  export interface SidebarBrandProps extends React.HTMLAttributes<HTMLDivElement> {
41
44
  /** The brand mark (img/svg) — `--sidebar-logo` (20px) centered in a `--sidebar-item` (32px) square, same box as every other rail icon. */
42
45
  logo: React.ReactNode;
@@ -44,10 +47,11 @@ export interface SidebarBrandProps extends React.HTMLAttributes<HTMLDivElement>
44
47
  href?: string;
45
48
  /** Accessible label for the logo link. */
46
49
  label?: string;
47
- /** Reveal the collapse trigger in place of the logo on hover. Default true. */
50
+ /** Render the collapse/expand trigger: next to the actions when expanded, in
51
+ * the logo slot when collapsed. Default true. */
48
52
  showTrigger?: boolean;
49
53
  /** Persistent header actions (e.g. a global-search button), right-aligned
50
- * next to the hover-revealed collapse trigger. Hidden while collapsed. */
54
+ * next to the collapse trigger. Hidden while collapsed. */
51
55
  children?: React.ReactNode;
52
56
  }
53
57
  /**
@@ -112,6 +116,10 @@ export interface SidebarAccountProps extends Omit<React.AnchorHTMLAttributes<HTM
112
116
  role?: React.ReactNode;
113
117
  /** Avatar image; falls back to initials from `name`. */
114
118
  src?: string;
119
+ /** Hide the leading avatar, showing the name/role only. The collapsed rail
120
+ * still shows a person glyph so the account entry never becomes an empty
121
+ * square. */
122
+ hideAvatar?: boolean;
115
123
  }
116
124
  /**
117
125
  * Account block for the rail footer — avatar + name/role. Collapses to just the