@actioneer/ads 0.5.7 → 0.5.9

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 (147) hide show
  1. package/bin/ads-init.mjs +6 -0
  2. package/components/accordion.js +50 -48
  3. package/components/agent-icon.d.ts +12 -0
  4. package/components/agent-icon.js +133 -120
  5. package/components/ai-elements/chain-of-thought.d.ts +1 -1
  6. package/components/ai-elements/chain-of-thought.js +108 -108
  7. package/components/ai-elements/chart.js +16 -14
  8. package/components/ai-elements/inline-citation.js +41 -41
  9. package/components/ai-elements/message.js +4 -4
  10. package/components/ai-elements/queue.js +7 -7
  11. package/components/ai-elements/research-activity.js +114 -114
  12. package/components/ai-elements/shimmer.d.ts +2 -2
  13. package/components/ai-elements/speech-input.js +28 -28
  14. package/components/ai-elements/task-progress.js +26 -16
  15. package/components/ai-elements/task.js +17 -17
  16. package/components/ai-elements/tool.js +6 -6
  17. package/components/ai-elements/transcript.js +6 -5
  18. package/components/ai-elements/voice.js +1 -1
  19. package/components/alert.js +10 -10
  20. package/components/answer-sources.js +1 -1
  21. package/components/answer.js +115 -114
  22. package/components/assistant-ui/action-bar.js +94 -48
  23. package/components/assistant-ui/attachment.js +103 -75
  24. package/components/assistant-ui/badge.d.ts +1 -1
  25. package/components/assistant-ui/badge.js +17 -17
  26. package/components/assistant-ui/chain-of-thought.d.ts +1 -1
  27. package/components/assistant-ui/composer-add-context.js +9 -9
  28. package/components/assistant-ui/composer-deep-research.js +5 -5
  29. package/components/assistant-ui/composer-harness.js +11 -9
  30. package/components/assistant-ui/composer-trigger-popover.js +45 -34
  31. package/components/assistant-ui/composer.js +59 -59
  32. package/components/assistant-ui/error.js +14 -14
  33. package/components/assistant-ui/file.d.ts +1 -1
  34. package/components/assistant-ui/image.d.ts +1 -1
  35. package/components/assistant-ui/image.js +113 -103
  36. package/components/assistant-ui/markdown-text.js +18 -18
  37. package/components/assistant-ui/message.js +46 -45
  38. package/components/assistant-ui/quote.js +1 -1
  39. package/components/assistant-ui/reasoning.d.ts +1 -1
  40. package/components/assistant-ui/reasoning.js +66 -77
  41. package/components/assistant-ui/suggestions.js +4 -4
  42. package/components/assistant-ui/thread.js +22 -22
  43. package/components/assistant-ui/tool-fallback.js +60 -63
  44. package/components/assistant-ui/tool-group.d.ts +1 -1
  45. package/components/assistant-ui/tool-group.js +36 -42
  46. package/components/audio-waveform.js +25 -24
  47. package/components/autocomplete.d.ts +1 -0
  48. package/components/autocomplete.js +45 -43
  49. package/components/avatar.d.ts +1 -0
  50. package/components/avatar.js +27 -26
  51. package/components/badge.d.ts +1 -1
  52. package/components/breadcrumbs.d.ts +2 -0
  53. package/components/breadcrumbs.js +52 -50
  54. package/components/button.d.ts +2 -2
  55. package/components/button.js +22 -20
  56. package/components/card.js +8 -8
  57. package/components/carousel.js +105 -104
  58. package/components/chart.d.ts +6 -0
  59. package/components/chart.js +743 -672
  60. package/components/checkbox.js +74 -38
  61. package/components/chip.d.ts +1 -1
  62. package/components/code-block.js +3 -3
  63. package/components/collapsible.js +67 -23
  64. package/components/connector-card.js +6 -6
  65. package/components/drawer.d.ts +18 -11
  66. package/components/drawer.js +81 -78
  67. package/components/dropdown.d.ts +2 -0
  68. package/components/dropdown.js +88 -79
  69. package/components/empty-state.d.ts +1 -1
  70. package/components/empty-state.js +7 -7
  71. package/components/field.d.ts +4 -0
  72. package/components/field.js +45 -34
  73. package/components/file-dropzone.js +12 -12
  74. package/components/index.d.ts +3 -0
  75. package/components/index.js +584 -558
  76. package/components/input-field.js +51 -46
  77. package/components/input.js +20 -20
  78. package/components/link.js +9 -9
  79. package/components/modal.d.ts +5 -1
  80. package/components/modal.js +121 -76
  81. package/components/navbar.d.ts +1 -1
  82. package/components/navbar.js +1 -1
  83. package/components/number-field.js +38 -29
  84. package/components/page-header.js +12 -12
  85. package/components/pagination.js +19 -19
  86. package/components/panel.js +2 -2
  87. package/components/pixel-blast-svg.js +3 -3
  88. package/components/pixel-icon.d.ts +4 -0
  89. package/components/pixel-icon.js +210 -164
  90. package/components/popover.d.ts +1 -1
  91. package/components/popover.js +66 -64
  92. package/components/progress-circle.js +36 -32
  93. package/components/progress.js +28 -24
  94. package/components/radio.js +59 -49
  95. package/components/resizable-panel.js +1 -1
  96. package/components/reveal.d.ts +2 -2
  97. package/components/ripple.d.ts +3 -3
  98. package/components/scroll-area.js +17 -16
  99. package/components/segmented.d.ts +1 -0
  100. package/components/segmented.js +39 -36
  101. package/components/select.d.ts +7 -0
  102. package/components/select.js +186 -137
  103. package/components/setting-row.js +45 -42
  104. package/components/sidebar.js +131 -127
  105. package/components/skeleton.js +5 -5
  106. package/components/spinner.d.ts +13 -4
  107. package/components/spinner.js +42 -42
  108. package/components/stepper.js +21 -21
  109. package/components/switch.js +41 -39
  110. package/components/table.d.ts +16 -0
  111. package/components/table.js +393 -260
  112. package/components/tabs.js +149 -137
  113. package/components/toast.js +66 -66
  114. package/components/tooltip.js +2 -2
  115. package/components/tree.js +62 -51
  116. package/components/typography.d.ts +2 -1
  117. package/components/typography.js +33 -32
  118. package/components/ui/button.d.ts +2 -2
  119. package/components/ui/button.js +19 -19
  120. package/components/ui/collapsible.d.ts +1 -5
  121. package/components/ui/dialog.d.ts +3 -3
  122. package/components/ui/dialog.js +95 -58
  123. package/components/ui/tooltip.d.ts +2 -2
  124. package/components/ui/tooltip.js +67 -33
  125. package/components/viz-charts.js +95 -95
  126. package/demo/components/add-to-artifact.js +363 -0
  127. package/demo/lib/artifact-library.js +142 -0
  128. package/demo/lib/artifact-pin-guard.js +12 -0
  129. package/fonts/aribau-grotesk-medium.woff2 +0 -0
  130. package/fonts/aribau-grotesk-regular.woff2 +0 -0
  131. package/fonts.css +11 -11
  132. package/hooks/agents-ui/use-agent-audio-visualizer-aura.js +17 -16
  133. package/hooks/agents-ui/use-agent-audio-visualizer-wave.js +21 -20
  134. package/lib/icons.d.ts +24 -0
  135. package/lib/icons.js +114 -108
  136. package/lib/motion.d.ts +42 -39
  137. package/lib/motion.js +112 -52
  138. package/lib/spinner-mark.d.ts +9 -0
  139. package/lib/spinner-mark.js +98 -0
  140. package/llms.txt +53 -19
  141. package/manifest.json +258 -36
  142. package/package.json +1 -1
  143. package/styles.css +143 -124
  144. package/theme.css +90 -93
  145. package/components/ui/collapsible.js +0 -35
  146. package/fonts/aribau-grotesk-500.otf +0 -0
  147. package/fonts/aribau-grotesk-600.woff2 +0 -0
@@ -1,65 +1,65 @@
1
1
  "use client";
2
- import { jsxs as T, jsx as a } from "react/jsx-runtime";
2
+ import { jsxs as P, jsx as c } from "react/jsx-runtime";
3
3
  import * as o from "react";
4
- import { createPortal as A } from "react-dom";
5
- import { MotionConfig as O, AnimatePresence as W, motion as F } from "motion/react";
6
- import { WarningCircle as B, Warning as D, Info as N, CheckCircle as U, Close as V } from "../lib/icons.js";
4
+ import { createPortal as W } from "react-dom";
5
+ import { MotionConfig as A, AnimatePresence as F, motion as B } from "motion/react";
6
+ import { WarningCircle as D, Warning as V, Info as E, CheckCircle as q, Close as G } from "../lib/icons.js";
7
7
  import { cn as g } from "../lib/cn.js";
8
- import { toastSpring as q, EASE_OUT as G } from "../lib/motion.js";
8
+ import { springOverlay as z } from "../lib/motion.js";
9
9
  import { Ripple as J } from "./ripple.js";
10
10
  import { Button as K } from "./button.js";
11
11
  import { Spinner as Q } from "./spinner.js";
12
- const z = o.createContext(null);
13
- function lt() {
14
- const b = o.useContext(z);
12
+ const S = o.createContext(null);
13
+ function at() {
14
+ const b = o.useContext(S);
15
15
  if (!b)
16
16
  throw new Error("useToast must be used within a <ToastProvider>.");
17
- const { push: c, close: p, clear: f } = b;
17
+ const { push: a, close: p, clear: d } = b;
18
18
  return { toast: o.useMemo(() => {
19
19
  const s = ((r, i) => {
20
20
  if (r !== null && typeof r == "object" && !o.isValidElement(r)) {
21
- const { title: d, ...m } = r;
22
- return c(d, { ...m, ...i });
21
+ const { title: f, ...m } = r;
22
+ return a(f, { ...m, ...i });
23
23
  }
24
- return c(r, i);
25
- }), l = (r) => (i, d) => c(i, { ...d, variant: r });
26
- return s.success = l("success"), s.info = l("info"), s.warning = l("warning"), s.danger = l("danger"), s.close = p, s.clear = f, s.promise = (r, i) => {
27
- const d = c(i.loading, { isLoading: !0, timeout: 0 });
24
+ return a(r, i);
25
+ }), l = (r) => (i, f) => a(i, { ...f, variant: r });
26
+ return s.success = l("success"), s.info = l("info"), s.warning = l("warning"), s.danger = l("danger"), s.close = p, s.clear = d, s.promise = (r, i) => {
27
+ const f = a(i.loading, { isLoading: !0, timeout: 0 });
28
28
  return r.then((m) => {
29
- p(d), c(
29
+ p(f), a(
30
30
  typeof i.success == "function" ? i.success(m) : i.success,
31
31
  { variant: "success" }
32
32
  );
33
33
  }).catch((m) => {
34
- p(d), c(
34
+ p(f), a(
35
35
  typeof i.error == "function" ? i.error(m) : i.error,
36
36
  { variant: "danger" }
37
37
  );
38
38
  }), r;
39
39
  }, s;
40
- }, [c, p, f]) };
40
+ }, [a, p, d]) };
41
41
  }
42
- const X = {
43
- default: { icon: N, accent: "text-foreground" },
44
- success: { icon: U, accent: "text-success-700" },
45
- info: { icon: N, accent: "text-info-700" },
46
- warning: { icon: D, accent: "text-warning-700" },
47
- danger: { icon: B, accent: "text-danger-700" }
48
- }, Y = {
42
+ const U = {
43
+ default: { icon: E, accent: "text-foreground" },
44
+ success: { icon: q, accent: "text-success-700" },
45
+ info: { icon: E, accent: "text-info-700" },
46
+ warning: { icon: V, accent: "text-warning-700" },
47
+ danger: { icon: D, accent: "text-danger-700" }
48
+ }, X = {
49
49
  "bottom-end": "bottom-4 right-4",
50
50
  bottom: "bottom-4 left-1/2 -translate-x-1/2",
51
51
  "bottom-start": "bottom-4 left-4",
52
52
  "top-end": "top-4 right-4",
53
53
  top: "top-4 left-1/2 -translate-x-1/2",
54
54
  "top-start": "top-4 left-4"
55
- }, S = 12, Z = 0.05;
56
- function ut({
55
+ }, R = 12, Y = 0.05;
56
+ function lt({
57
57
  children: b,
58
- placement: c = "bottom-end",
58
+ placement: a = "bottom-end",
59
59
  maxVisible: p = 3
60
60
  }) {
61
- var k;
62
- const [f, y] = o.useState([]), s = o.useRef(/* @__PURE__ */ new Map()), l = o.useRef(/* @__PURE__ */ new Map()), r = o.useCallback((t) => {
61
+ var M;
62
+ const [d, y] = o.useState([]), s = o.useRef(/* @__PURE__ */ new Map()), l = o.useRef(/* @__PURE__ */ new Map()), r = o.useCallback((t) => {
63
63
  y((u) => u.filter((h) => h.id !== t));
64
64
  const n = s.current.get(t);
65
65
  n && (clearTimeout(n), s.current.delete(t));
@@ -71,7 +71,7 @@ function ut({
71
71
  const e = s.current.get(n.id);
72
72
  e && clearTimeout(e), s.current.delete(n.id), (u = l.current.get(n.id)) == null || u(), l.current.delete(n.id);
73
73
  }), []));
74
- }, []), d = o.useCallback(
74
+ }, []), f = o.useCallback(
75
75
  (t, n = {}) => {
76
76
  const e = Math.random().toString(36).slice(2), u = { variant: "default", ...n, id: e, title: t };
77
77
  y((x) => [...x, u]), l.current.set(e, n.onClose);
@@ -86,40 +86,40 @@ function ut({
86
86
  t.forEach((n) => clearTimeout(n)), t.clear();
87
87
  };
88
88
  }, []);
89
- const m = o.useMemo(() => ({ push: d, close: r, clear: i }), [d, r, i]), [R, L] = o.useState(!1);
90
- o.useEffect(() => L(!0), []);
91
- const [w, P] = o.useState(null), E = o.useRef(null), j = (k = f[f.length - 1]) == null ? void 0 : k.id;
89
+ const m = o.useMemo(() => ({ push: f, close: r, clear: i }), [f, r, i]), [j, H] = o.useState(!1);
90
+ o.useEffect(() => H(!0), []);
91
+ const [w, T] = o.useState(null), k = o.useRef(null), L = (M = d[d.length - 1]) == null ? void 0 : M.id;
92
92
  o.useLayoutEffect(() => {
93
- const t = E.current;
93
+ const t = k.current;
94
94
  if (!t) {
95
- P(null);
95
+ T(null);
96
96
  return;
97
97
  }
98
- const n = () => P(t.offsetHeight);
98
+ const n = () => T(t.offsetHeight);
99
99
  n();
100
100
  const e = new ResizeObserver(n);
101
101
  return e.observe(t), () => e.disconnect();
102
- }, [j]);
103
- const v = c.startsWith("top"), H = v ? 1 : -1, _ = Math.min(p, Math.max(f.length, 1)), I = w != null ? w + S * (_ - 1) : void 0;
104
- return /* @__PURE__ */ T(z.Provider, { value: m, children: [
102
+ }, [L]);
103
+ const v = a.startsWith("top"), I = v ? 1 : -1, _ = Math.min(p, Math.max(d.length, 1)), $ = w != null ? w + R * (_ - 1) : void 0;
104
+ return /* @__PURE__ */ P(S.Provider, { value: m, children: [
105
105
  b,
106
- R && A(
107
- /* @__PURE__ */ a(
106
+ j && d.length > 0 && W(
107
+ /* @__PURE__ */ c(
108
108
  "div",
109
109
  {
110
110
  className: g(
111
111
  "pointer-events-none fixed z-50 w-full max-w-sm",
112
- Y[c]
112
+ X[a]
113
113
  ),
114
- style: { height: I },
114
+ style: { height: $ },
115
115
  role: "region",
116
116
  "aria-label": "Notifications",
117
- children: /* @__PURE__ */ a(O, { reducedMotion: "user", children: /* @__PURE__ */ a(W, { children: f.map((t, n) => {
118
- const e = f.length - 1 - n, u = e === 0, h = e >= p, x = X[t.variant ?? "default"], $ = x.icon;
119
- return /* @__PURE__ */ T(
120
- F.div,
117
+ children: /* @__PURE__ */ c(A, { reducedMotion: "user", children: /* @__PURE__ */ c(F, { children: d.map((t, n) => {
118
+ const e = d.length - 1 - n, u = e === 0, h = e >= p, x = U[t.variant ?? "default"], O = x.icon;
119
+ return /* @__PURE__ */ P(
120
+ B.div,
121
121
  {
122
- ref: u ? E : void 0,
122
+ ref: u ? k : void 0,
123
123
  layout: !1,
124
124
  role: "status",
125
125
  "aria-live": "polite",
@@ -129,14 +129,14 @@ function ut({
129
129
  },
130
130
  animate: {
131
131
  opacity: h ? 0 : 1,
132
- transform: `translate3d(0, ${H * e * S}px, 0) scale(${1 - e * Z})`
132
+ transform: `translate3d(0, ${I * e * R}px, 0) scale(${1 - e * Y})`
133
133
  },
134
134
  exit: {
135
135
  opacity: 0,
136
136
  transform: `translate3d(0, ${v ? -16 : 16}px, 0) scale(0.98)`,
137
- transition: { duration: 0.14, ease: G }
137
+ transition: z
138
138
  },
139
- transition: q,
139
+ transition: z,
140
140
  className: g(
141
141
  "group/toast absolute inset-x-0 flex items-start gap-1.5",
142
142
  v ? "top-0" : "bottom-0",
@@ -150,35 +150,35 @@ function ut({
150
150
  height: !u && w != null ? w : void 0
151
151
  },
152
152
  children: [
153
- /* @__PURE__ */ a(J, { origin: v ? "top" : "bottom" }),
154
- /* @__PURE__ */ a(
153
+ /* @__PURE__ */ c(J, { origin: v ? "top" : "bottom" }),
154
+ /* @__PURE__ */ c(
155
155
  "span",
156
156
  {
157
157
  className: g(
158
158
  "flex shrink-0 select-none items-center justify-center p-1 [&_svg]:size-4",
159
159
  x.accent
160
160
  ),
161
- children: t.isLoading ? /* @__PURE__ */ a(Q, { size: "sm", "aria-label": "Loading" }) : t.indicator ?? /* @__PURE__ */ a($, { "aria-hidden": !0 })
161
+ children: t.isLoading ? /* @__PURE__ */ c(Q, { variant: "action", size: "sm", "aria-hidden": !0 }) : t.indicator ?? /* @__PURE__ */ c(O, { "aria-hidden": !0 })
162
162
  }
163
163
  ),
164
- /* @__PURE__ */ T("div", { className: "flex min-w-0 grow flex-col items-start self-center", children: [
165
- /* @__PURE__ */ a("p", { className: g("text-xs font-normal leading-5", x.accent), children: t.title }),
166
- t.description && /* @__PURE__ */ a("p", { className: "text-xs text-muted-foreground", children: t.description })
164
+ /* @__PURE__ */ P("div", { className: "flex min-w-0 grow flex-col items-start self-center", children: [
165
+ /* @__PURE__ */ c("p", { className: g("text-xs font-normal leading-5", x.accent), children: t.title }),
166
+ t.description && /* @__PURE__ */ c("p", { className: "text-xs text-muted-foreground", children: t.description })
167
167
  ] }),
168
- t.actionProps && /* @__PURE__ */ a(
168
+ t.actionProps && /* @__PURE__ */ c(
169
169
  K,
170
170
  {
171
171
  size: "sm",
172
172
  variant: t.actionProps.variant ?? "soft",
173
173
  className: g("ml-2 shrink-0 self-center rounded-full", t.actionProps.className),
174
174
  onClick: () => {
175
- var C, M;
176
- return (M = (C = t.actionProps) == null ? void 0 : C.onClick) == null ? void 0 : M.call(C);
175
+ var C, N;
176
+ return (N = (C = t.actionProps) == null ? void 0 : C.onClick) == null ? void 0 : N.call(C);
177
177
  },
178
178
  children: t.actionProps.children
179
179
  }
180
180
  ),
181
- /* @__PURE__ */ a(
181
+ /* @__PURE__ */ c(
182
182
  "button",
183
183
  {
184
184
  type: "button",
@@ -187,13 +187,13 @@ function ut({
187
187
  className: g(
188
188
  "absolute -right-1 -top-1 inline-flex size-5 items-center justify-center",
189
189
  "rounded-full border border-border bg-elevated text-muted-foreground shadow-elevation",
190
- "opacity-0 transition-opacity duration-(--duration-fast) ease-out",
190
+ "opacity-0 transition-opacity duration-150 ease-out",
191
191
  "group-hover/toast:opacity-100 focus-visible:opacity-100",
192
192
  "hover:bg-muted hover:text-foreground",
193
193
  "outline-none focus-visible:ring-2 focus-visible:ring-ring",
194
194
  "[&_svg]:size-3 [&_svg]:shrink-0"
195
195
  ),
196
- children: /* @__PURE__ */ a(V, { "aria-hidden": !0 })
196
+ children: /* @__PURE__ */ c(G, { "aria-hidden": !0 })
197
197
  }
198
198
  )
199
199
  ]
@@ -208,6 +208,6 @@ function ut({
208
208
  ] });
209
209
  }
210
210
  export {
211
- ut as ToastProvider,
212
- lt as useToast
211
+ lt as ToastProvider,
212
+ at as useToast
213
213
  };
@@ -115,7 +115,7 @@ function Y({
115
115
  transformOrigin: W[a]
116
116
  },
117
117
  className: S(
118
- "relative z-50 max-w-xs rounded-md bg-foreground px-2 py-1",
118
+ "relative z-50 max-w-xs rounded-sm bg-foreground px-2 py-1",
119
119
  "text-xs text-background",
120
120
  "pointer-events-none select-none",
121
121
  A
@@ -127,7 +127,7 @@ function Y({
127
127
  {
128
128
  "aria-hidden": !0,
129
129
  className: S(
130
- "absolute size-2 rotate-45 rounded-sm bg-foreground",
130
+ "absolute size-2 rotate-45 rounded-xs bg-foreground",
131
131
  V[a]
132
132
  )
133
133
  }
@@ -1,89 +1,100 @@
1
1
  "use client";
2
- import { jsx as e, jsxs as x, Fragment as N } from "react/jsx-runtime";
2
+ import { jsx as e, jsxs as h, Fragment as y } from "react/jsx-runtime";
3
3
  import * as t from "react";
4
- import { cn as s } from "../lib/cn.js";
5
- import { ChevronRight as _, FileText as z } from "../lib/icons.js";
6
- const S = t.forwardRef(({ className: i, ...d }, f) => /* @__PURE__ */ e(
4
+ import { MotionConfig as M, AnimatePresence as _, motion as z } from "motion/react";
5
+ import { cn as a } from "../lib/cn.js";
6
+ import { ChevronRight as D, FileText as S } from "../lib/icons.js";
7
+ import { springDisclosure as V } from "../lib/motion.js";
8
+ const W = t.forwardRef(({ className: s, ...c }, d) => /* @__PURE__ */ e(
7
9
  "div",
8
10
  {
9
- ref: f,
11
+ ref: d,
10
12
  role: "tree",
11
- className: s("flex flex-col gap-0.5 text-xs", i),
12
- ...d
13
+ className: a("flex flex-col gap-0.5 text-xs", s),
14
+ ...c
13
15
  }
14
16
  ));
15
- S.displayName = "Tree";
16
- const V = t.forwardRef(
17
+ W.displayName = "Tree";
18
+ const q = t.forwardRef(
17
19
  ({
18
- className: i,
19
- label: d,
20
- icon: f,
20
+ className: s,
21
+ label: c,
22
+ icon: d,
21
23
  count: p,
22
- endContent: w,
23
- defaultExpanded: y = !1,
24
- expanded: h,
25
- onExpandedChange: c,
24
+ endContent: N,
25
+ defaultExpanded: w = !1,
26
+ expanded: x,
27
+ onExpandedChange: f,
26
28
  href: g,
27
29
  isActive: o,
28
30
  onSelect: C,
29
31
  children: n,
30
32
  ...I
31
33
  }, k) => {
32
- const r = t.Children.count(n) > 0, v = h !== void 0, [T, R] = t.useState(y), l = v ? h : T, j = (a) => {
33
- v || R(a), c == null || c(a);
34
- }, m = s(
34
+ const r = t.Children.count(n) > 0, v = x !== void 0, [T, R] = t.useState(w), i = v ? x : T, j = (l) => {
35
+ v || R(l), f == null || f(l);
36
+ }, m = a(
35
37
  "flex h-9 w-full items-center gap-2 rounded-md px-2 text-left",
36
38
  "outline-none transition-colors focus-visible:ring-3 focus-visible:ring-ring",
37
39
  "[&_svg]:size-4 [&_svg]:shrink-0",
38
40
  o ? "bg-fill font-normal text-foreground" : "text-muted-foreground hover:bg-fill/60 hover:text-foreground"
39
- ), u = f ?? (r ? null : /* @__PURE__ */ e(z, { className: "text-tertiary" })), F = o && t.isValidElement(u) ? t.cloneElement(
41
+ ), u = d ?? (r ? null : /* @__PURE__ */ e(S, { className: "text-tertiary" })), F = o && t.isValidElement(u) ? t.cloneElement(
40
42
  u,
41
43
  { weight: "fill" }
42
- ) : u, b = /* @__PURE__ */ x(N, { children: [
44
+ ) : u, b = /* @__PURE__ */ h(y, { children: [
43
45
  F,
44
- /* @__PURE__ */ e("span", { className: "min-w-0 flex-1 truncate", children: d }),
45
- w,
46
- r && /* @__PURE__ */ x(N, { children: [
46
+ /* @__PURE__ */ e("span", { className: "min-w-0 flex-1 truncate", children: c }),
47
+ N,
48
+ r && /* @__PURE__ */ h(y, { children: [
47
49
  (p ?? t.Children.count(n)) > 0 && /* @__PURE__ */ e("span", { className: "shrink-0 tabular-nums text-xs text-tertiary", children: p ?? t.Children.count(n) }),
48
50
  /* @__PURE__ */ e(
49
- _,
51
+ D,
50
52
  {
51
- className: s(
52
- "text-muted-foreground transition-transform duration-(--duration-fast) motion-reduce:transition-none",
53
- l && "rotate-90"
53
+ className: a(
54
+ "text-muted-foreground transition-transform duration-150 motion-reduce:transition-none",
55
+ i && "rotate-90"
54
56
  ),
55
57
  strokeWidth: 2
56
58
  }
57
59
  )
58
60
  ] })
59
61
  ] });
60
- return /* @__PURE__ */ x("div", { ref: k, role: "treeitem", "aria-expanded": r ? l : void 0, "aria-selected": o, className: i, ...I, children: [
61
- r ? /* @__PURE__ */ e("button", { type: "button", className: m, onClick: () => j(!l), children: b }) : g ? /* @__PURE__ */ e("a", { href: g, className: m, "aria-current": o ? "page" : void 0, children: b }) : /* @__PURE__ */ e("button", { type: "button", className: m, onClick: C, children: b }),
62
- r && l && // ml-4 aligns the rail under the parent icon; each child carries the
63
- // elbow (before) + rail continuation (after), hidden on the last.
64
- /* @__PURE__ */ e("div", { role: "group", className: "ml-4 flex flex-col gap-0.5", children: t.Children.map(n, (a) => /* @__PURE__ */ e(
65
- "div",
62
+ return /* @__PURE__ */ h("div", { ref: k, role: "treeitem", "aria-expanded": r ? i : void 0, "aria-selected": o, className: s, ...I, children: [
63
+ r ? /* @__PURE__ */ e("button", { type: "button", className: m, onClick: () => j(!i), children: b }) : g ? /* @__PURE__ */ e("a", { href: g, className: m, "aria-current": o ? "page" : void 0, children: b }) : /* @__PURE__ */ e("button", { type: "button", className: m, onClick: C, children: b }),
64
+ /* @__PURE__ */ e(M, { reducedMotion: "user", children: /* @__PURE__ */ e(_, { initial: !1, children: r && i && /* @__PURE__ */ e(
65
+ z.div,
66
66
  {
67
- className: s(
68
- "relative ps-5",
69
- // Continuous vertical rail — a straight line (no radius) so it
70
- // never breaks between children. The LAST child needs no rail
71
- // at all: the elbow's own left border draws its final vertical
72
- // segment, so a rail there would poke through the curve.
73
- "before:absolute before:left-0 before:top-0 before:bottom-0 before:border-l before:border-border before:content-['']",
74
- "last:before:hidden",
75
- // Rounded elbow branching off the rail to this child. Its own
76
- // left border overlaps the rail, so the curve reads cleanly.
77
- "after:absolute after:left-0 after:top-0 after:h-4 after:w-4 after:rounded-bl-[9px] after:border-b after:border-l after:border-border after:content-['']"
78
- ),
79
- children: a
67
+ role: "group",
68
+ initial: { height: 0, opacity: 0, y: -4 },
69
+ animate: { height: "auto", opacity: 1, y: 0 },
70
+ exit: { height: 0, opacity: 0, y: -4 },
71
+ transition: V,
72
+ className: "ml-4 flex flex-col gap-0.5 overflow-hidden",
73
+ children: t.Children.map(n, (l) => /* @__PURE__ */ e(
74
+ "div",
75
+ {
76
+ className: a(
77
+ "relative ps-5",
78
+ // Continuous vertical rail — a straight line (no radius) so it
79
+ // never breaks between children. The LAST child needs no rail
80
+ // at all: the elbow's own left border draws its final vertical
81
+ // segment, so a rail there would poke through the curve.
82
+ "before:absolute before:left-0 before:top-0 before:bottom-0 before:border-l before:border-border before:content-['']",
83
+ "last:before:hidden",
84
+ // Rounded elbow branching off the rail to this child. Its own
85
+ // left border overlaps the rail, so the curve reads cleanly.
86
+ "after:absolute after:left-0 after:top-0 after:h-4 after:w-4 after:rounded-bl-[9px] after:border-b after:border-l after:border-border after:content-['']"
87
+ ),
88
+ children: l
89
+ }
90
+ ))
80
91
  }
81
- )) })
92
+ ) }) })
82
93
  ] });
83
94
  }
84
95
  );
85
- V.displayName = "TreeItem";
96
+ q.displayName = "TreeItem";
86
97
  export {
87
- S as Tree,
88
- V as TreeItem
98
+ W as Tree,
99
+ q as TreeItem
89
100
  };
@@ -11,7 +11,8 @@ declare const textSizes: {
11
11
  };
12
12
  declare const textWeights: {
13
13
  readonly regular: "font-normal";
14
- readonly bold: "font-semibold";
14
+ readonly medium: "font-medium";
15
+ readonly bold: "font-medium";
15
16
  };
16
17
  declare const textColors: {
17
18
  readonly primary: "text-primary";
@@ -1,52 +1,53 @@
1
1
  "use client";
2
- import { jsx as n } from "react/jsx-runtime";
3
- import * as i from "react";
2
+ import { jsx as i } from "react/jsx-runtime";
3
+ import * as d from "react";
4
4
  import { cn as c } from "../lib/cn.js";
5
- const p = {
6
- 1: { tag: "h1", className: "text-2xl font-semibold tracking-tight" },
7
- 2: { tag: "h2", className: "text-xl font-semibold tracking-tight" },
8
- 3: { tag: "h3", className: "text-lg font-semibold" },
9
- 4: { tag: "h4", className: "text-base font-semibold" }
10
- }, y = i.forwardRef(
11
- ({ className: e, level: s = 1, children: t, ...o }, a) => {
12
- const { tag: r, className: l } = p[s];
13
- return /* @__PURE__ */ n(r, { ref: a, className: c(l, e), ...o, children: t });
5
+ const u = {
6
+ 1: { tag: "h1", className: "text-2xl font-medium tracking-tight" },
7
+ 2: { tag: "h2", className: "text-xl font-medium tracking-tight" },
8
+ 3: { tag: "h3", className: "text-lg font-medium" },
9
+ 4: { tag: "h4", className: "text-base font-medium" }
10
+ }, p = d.forwardRef(
11
+ ({ className: e, level: a = 1, children: t, ...m }, s) => {
12
+ const { tag: r, className: o } = u[a];
13
+ return /* @__PURE__ */ i(r, { ref: s, className: c(o, e), ...m, children: t });
14
14
  }
15
15
  );
16
- y.displayName = "Heading";
17
- const N = {
16
+ p.displayName = "Heading";
17
+ const y = {
18
18
  xs: "text-xs",
19
19
  sm: "text-xs",
20
20
  md: "text-base",
21
21
  lg: "text-lg"
22
- }, b = {
22
+ }, N = {
23
23
  regular: "font-normal",
24
- bold: "font-semibold"
25
- }, m = {
24
+ medium: "font-medium",
25
+ bold: "font-medium"
26
+ }, n = {
26
27
  primary: "text-primary",
27
28
  secondary: "text-secondary",
28
29
  tertiary: "text-tertiary"
29
- }, u = i.forwardRef(
30
- ({ className: e, size: s = "md", color: t, muted: o = !1, weight: a, as: r = "p", children: l, ...x }, d) => {
31
- const g = r, f = t ? m[t] : o ? m.tertiary : m.primary;
32
- return /* @__PURE__ */ n(
30
+ }, h = d.forwardRef(
31
+ ({ className: e, size: a = "md", color: t, muted: m = !1, weight: s, as: r = "p", children: o, ...l }, x) => {
32
+ const g = r, f = t ? n[t] : m ? n.tertiary : n.primary;
33
+ return /* @__PURE__ */ i(
33
34
  g,
34
35
  {
35
- ref: d,
36
+ ref: x,
36
37
  className: c(
37
- N[s],
38
- a && b[a],
38
+ y[a],
39
+ s && N[s],
39
40
  f,
40
41
  e
41
42
  ),
42
- ...x,
43
- children: l
43
+ ...l,
44
+ children: o
44
45
  }
45
46
  );
46
47
  }
47
48
  );
48
- u.displayName = "Text";
49
- const h = i.forwardRef(({ className: e, ...s }, t) => /* @__PURE__ */ n(
49
+ h.displayName = "Text";
50
+ const b = d.forwardRef(({ className: e, ...a }, t) => /* @__PURE__ */ i(
50
51
  "code",
51
52
  {
52
53
  ref: t,
@@ -54,12 +55,12 @@ const h = i.forwardRef(({ className: e, ...s }, t) => /* @__PURE__ */ n(
54
55
  "rounded bg-muted px-1.5 py-0.5 tabular-nums text-xs",
55
56
  e
56
57
  ),
57
- ...s
58
+ ...a
58
59
  }
59
60
  ));
60
- h.displayName = "Code";
61
+ b.displayName = "Code";
61
62
  export {
62
- h as Code,
63
- y as Heading,
64
- u as Text
63
+ b as Code,
64
+ p as Heading,
65
+ h as Text
65
66
  };
@@ -1,8 +1,8 @@
1
1
  import { VariantProps } from 'class-variance-authority';
2
2
  import * as React from "react";
3
3
  declare const buttonVariants: (props?: ({
4
- variant?: "default" | "link" | "secondary" | "outline" | "ghost" | "destructive" | null | undefined;
5
- size?: "default" | "sm" | "lg" | "xs" | "icon" | "icon-sm" | "icon-xs" | "icon-lg" | null | undefined;
4
+ variant?: "default" | "outline" | "link" | "secondary" | "ghost" | "destructive" | null | undefined;
5
+ size?: "default" | "xs" | "sm" | "lg" | "icon" | "icon-sm" | "icon-xs" | "icon-lg" | null | undefined;
6
6
  } & import('class-variance-authority/types').ClassProp) | undefined) => string;
7
7
  declare function Button({ className, variant, size, asChild, ...props }: React.ComponentProps<"button"> & VariantProps<typeof buttonVariants> & {
8
8
  asChild?: boolean;
@@ -1,28 +1,28 @@
1
1
  "use client";
2
- import { jsx as s } from "react/jsx-runtime";
2
+ import { jsx as i } from "react/jsx-runtime";
3
3
  import { cva as a } from "class-variance-authority";
4
4
  import { Slot as d } from "radix-ui";
5
5
  import { cn as c } from "../../lib/cn.js";
6
6
  const u = a(
7
- "inline-flex shrink-0 items-center justify-center gap-2 rounded-md text-xs font-medium whitespace-nowrap transition-[background-color,border-color,color,box-shadow,transform] duration-(--duration-fast) ease-out outline-none motion-reduce:transition-none focus-visible:border-ring focus-visible:ring-[3px] focus-visible:ring-ring/50 disabled:pointer-events-none disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",
7
+ "inline-flex shrink-0 items-center justify-center gap-2 rounded-md text-xs font-medium whitespace-nowrap transition-[background-color,border-color,color,box-shadow,transform] duration-150 ease-out outline-none motion-reduce:transition-none focus-visible:border-ring focus-visible:ring-[3px] focus-visible:ring-ring/50 disabled:pointer-events-none disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-destructive/20 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",
8
8
  {
9
9
  variants: {
10
10
  variant: {
11
11
  default: "bg-primary text-primary-foreground hover:bg-primary/90",
12
- destructive: "bg-destructive text-white hover:bg-destructive/90 focus-visible:ring-destructive/20 dark:bg-destructive/60 dark:focus-visible:ring-destructive/40",
13
- outline: "border bg-background shadow-xs hover:bg-accent hover:text-accent-foreground dark:border-input dark:bg-input/30 dark:hover:bg-input/50",
12
+ destructive: "bg-destructive text-white hover:bg-destructive/90 focus-visible:ring-destructive/20",
13
+ outline: "border bg-background shadow-xs hover:bg-accent hover:text-accent-foreground",
14
14
  secondary: "bg-secondary text-secondary-foreground hover:bg-secondary/80",
15
- ghost: "hover:bg-accent hover:text-accent-foreground dark:hover:bg-accent/50",
15
+ ghost: "hover:bg-accent hover:text-accent-foreground",
16
16
  link: "text-primary underline-offset-4 hover:underline"
17
17
  },
18
18
  size: {
19
19
  default: "h-9 px-4 py-2 has-[>svg]:px-3",
20
- xs: "h-6 gap-1 rounded-md px-2 text-xs has-[>svg]:px-1.5 [&_svg:not([class*='size-'])]:size-3",
20
+ xs: "h-6 gap-1 rounded-sm px-2 text-xs has-[>svg]:px-1.5 [&_svg:not([class*='size-'])]:size-3",
21
21
  sm: "h-8 gap-1.5 rounded-md px-3 has-[>svg]:px-2.5",
22
22
  lg: "h-10 rounded-md px-6 has-[>svg]:px-4",
23
23
  icon: "size-9",
24
- "icon-xs": "size-6 rounded-md [&_svg:not([class*='size-'])]:size-3",
25
- "icon-sm": "size-8",
24
+ "icon-xs": "size-6 rounded-sm [&_svg:not([class*='size-'])]:size-3",
25
+ "icon-sm": "size-8 rounded-sm",
26
26
  "icon-lg": "size-10"
27
27
  }
28
28
  },
@@ -32,26 +32,26 @@ const u = a(
32
32
  }
33
33
  }
34
34
  );
35
- function p({
36
- className: t,
35
+ function f({
36
+ className: o,
37
37
  variant: e = "default",
38
- size: r = "default",
39
- asChild: o = !1,
40
- ...i
38
+ size: t = "default",
39
+ asChild: r = !1,
40
+ ...s
41
41
  }) {
42
- const n = o ? d.Root : "button";
43
- return /* @__PURE__ */ s(
42
+ const n = r ? d.Root : "button";
43
+ return /* @__PURE__ */ i(
44
44
  n,
45
45
  {
46
46
  "data-slot": "button",
47
47
  "data-variant": e,
48
- "data-size": r,
49
- className: c(u({ variant: e, size: r, className: t })),
50
- ...i
48
+ "data-size": t,
49
+ className: c(u({ variant: e, size: t, className: o })),
50
+ ...s
51
51
  }
52
52
  );
53
53
  }
54
54
  export {
55
- p as Button,
55
+ f as Button,
56
56
  u as buttonVariants
57
57
  };
@@ -1,5 +1 @@
1
- import { Collapsible as CollapsiblePrimitive } from 'radix-ui';
2
- declare function Collapsible({ ...props }: React.ComponentProps<typeof CollapsiblePrimitive.Root>): import("react").JSX.Element;
3
- declare function CollapsibleTrigger({ ...props }: React.ComponentProps<typeof CollapsiblePrimitive.CollapsibleTrigger>): import("react").JSX.Element;
4
- declare function CollapsibleContent({ ...props }: React.ComponentProps<typeof CollapsiblePrimitive.CollapsibleContent>): import("react").JSX.Element;
5
- export { Collapsible, CollapsibleTrigger, CollapsibleContent };
1
+ export { Collapsible, CollapsibleTrigger, CollapsibleContent, } from '../collapsible';