@actioneer/ads 0.1.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 (231) hide show
  1. package/LICENSE +21 -0
  2. package/bin/ads-init.mjs +314 -0
  3. package/components/accordion.d.ts +13 -0
  4. package/components/accordion.js +91 -0
  5. package/components/agents-ui/agent-audio-visualizer-aura.d.ts +11 -0
  6. package/components/agents-ui/agent-audio-visualizer-aura.js +277 -0
  7. package/components/agents-ui/agent-audio-visualizer-wave.d.ts +12 -0
  8. package/components/agents-ui/agent-audio-visualizer-wave.js +203 -0
  9. package/components/agents-ui/react-shader-toy.d.ts +87 -0
  10. package/components/agents-ui/react-shader-toy.js +531 -0
  11. package/components/ai-elements/chain-of-thought.d.ts +30 -0
  12. package/components/ai-elements/chain-of-thought.js +182 -0
  13. package/components/ai-elements/index.d.ts +11 -0
  14. package/components/ai-elements/inline-citation.d.ts +44 -0
  15. package/components/ai-elements/inline-citation.js +314 -0
  16. package/components/ai-elements/message.d.ts +96 -0
  17. package/components/ai-elements/message.js +308 -0
  18. package/components/ai-elements/queue.d.ts +60 -0
  19. package/components/ai-elements/queue.js +193 -0
  20. package/components/ai-elements/reasoning.d.ts +26 -0
  21. package/components/ai-elements/reasoning.js +131 -0
  22. package/components/ai-elements/shimmer.d.ts +25 -0
  23. package/components/ai-elements/shimmer.js +44 -0
  24. package/components/ai-elements/speech-input.d.ts +16 -0
  25. package/components/ai-elements/speech-input.js +151 -0
  26. package/components/ai-elements/task-progress.d.ts +41 -0
  27. package/components/ai-elements/task-progress.js +211 -0
  28. package/components/ai-elements/task.d.ts +35 -0
  29. package/components/ai-elements/task.js +73 -0
  30. package/components/ai-elements/tool.d.ts +53 -0
  31. package/components/ai-elements/tool.js +116 -0
  32. package/components/ai-elements/voice.d.ts +74 -0
  33. package/components/ai-elements/voice.js +875 -0
  34. package/components/alert.d.ts +21 -0
  35. package/components/alert.js +76 -0
  36. package/components/answer.d.ts +984 -0
  37. package/components/answer.js +543 -0
  38. package/components/assistant-ui/action-bar.d.ts +3 -0
  39. package/components/assistant-ui/action-bar.js +57 -0
  40. package/components/assistant-ui/answer-tool-ui.d.ts +5 -0
  41. package/components/assistant-ui/answer-tool-ui.js +42 -0
  42. package/components/assistant-ui/attachment.d.ts +50 -0
  43. package/components/assistant-ui/attachment.js +353 -0
  44. package/components/assistant-ui/badge.d.ts +11 -0
  45. package/components/assistant-ui/badge.js +54 -0
  46. package/components/assistant-ui/branch-picker.d.ts +3 -0
  47. package/components/assistant-ui/branch-picker.js +36 -0
  48. package/components/assistant-ui/chain-of-thought.d.ts +46 -0
  49. package/components/assistant-ui/composer-add-context.d.ts +50 -0
  50. package/components/assistant-ui/composer-add-context.js +209 -0
  51. package/components/assistant-ui/composer-deep-research.d.ts +16 -0
  52. package/components/assistant-ui/composer-deep-research.js +38 -0
  53. package/components/assistant-ui/composer-harness.d.ts +18 -0
  54. package/components/assistant-ui/composer-harness.js +186 -0
  55. package/components/assistant-ui/composer-trigger-popover.d.ts +47 -0
  56. package/components/assistant-ui/composer-trigger-popover.js +147 -0
  57. package/components/assistant-ui/composer.d.ts +8 -0
  58. package/components/assistant-ui/composer.js +276 -0
  59. package/components/assistant-ui/directive-text.d.ts +16 -0
  60. package/components/assistant-ui/directive-text.js +40 -0
  61. package/components/assistant-ui/error.d.ts +6 -0
  62. package/components/assistant-ui/error.js +39 -0
  63. package/components/assistant-ui/file.d.ts +37 -0
  64. package/components/assistant-ui/file.js +159 -0
  65. package/components/assistant-ui/follow-up-suggestions.d.ts +7 -0
  66. package/components/assistant-ui/follow-up-suggestions.js +44 -0
  67. package/components/assistant-ui/image.d.ts +46 -0
  68. package/components/assistant-ui/image.js +351 -0
  69. package/components/assistant-ui/index.d.ts +28 -0
  70. package/components/assistant-ui/markdown-text.d.ts +1 -0
  71. package/components/assistant-ui/markdown-text.js +242 -0
  72. package/components/assistant-ui/message-timing.d.ts +25 -0
  73. package/components/assistant-ui/message-timing.js +56 -0
  74. package/components/assistant-ui/message.d.ts +4 -0
  75. package/components/assistant-ui/message.js +159 -0
  76. package/components/assistant-ui/primitives.d.ts +2 -0
  77. package/components/assistant-ui/quote.d.ts +37 -0
  78. package/components/assistant-ui/quote.js +150 -0
  79. package/components/assistant-ui/reasoning.d.ts +44 -0
  80. package/components/assistant-ui/reasoning.js +261 -0
  81. package/components/assistant-ui/selection-toolbar.d.ts +29 -0
  82. package/components/assistant-ui/selection-toolbar.js +91 -0
  83. package/components/assistant-ui/smart-message-text.d.ts +15 -0
  84. package/components/assistant-ui/smart-message-text.js +29 -0
  85. package/components/assistant-ui/sources.d.ts +17 -0
  86. package/components/assistant-ui/sources.js +121 -0
  87. package/components/assistant-ui/suggestions.d.ts +7 -0
  88. package/components/assistant-ui/suggestions.js +19 -0
  89. package/components/assistant-ui/thread-context.d.ts +37 -0
  90. package/components/assistant-ui/thread-context.js +8 -0
  91. package/components/assistant-ui/thread.d.ts +5 -0
  92. package/components/assistant-ui/thread.js +77 -0
  93. package/components/assistant-ui/tool-fallback.d.ts +36 -0
  94. package/components/assistant-ui/tool-fallback.js +428 -0
  95. package/components/assistant-ui/tool-group.d.ts +33 -0
  96. package/components/assistant-ui/tool-group.js +173 -0
  97. package/components/assistant-ui/tooltip-icon-button.d.ts +7 -0
  98. package/components/assistant-ui/tooltip-icon-button.js +31 -0
  99. package/components/assistant-ui/voice.d.ts +18 -0
  100. package/components/autocomplete.d.ts +18 -0
  101. package/components/autocomplete.js +162 -0
  102. package/components/avatar.d.ts +26 -0
  103. package/components/avatar.js +92 -0
  104. package/components/badge.d.ts +10 -0
  105. package/components/badge.js +83 -0
  106. package/components/brand-loader.d.ts +16 -0
  107. package/components/brand-loader.js +64 -0
  108. package/components/breadcrumbs.d.ts +8 -0
  109. package/components/breadcrumbs.js +58 -0
  110. package/components/button.d.ts +13 -0
  111. package/components/button.js +100 -0
  112. package/components/card.d.ts +19 -0
  113. package/components/card.js +82 -0
  114. package/components/carousel.d.ts +31 -0
  115. package/components/carousel.js +351 -0
  116. package/components/chart.d.ts +165 -0
  117. package/components/chart.js +841 -0
  118. package/components/checkbox.d.ts +13 -0
  119. package/components/checkbox.js +84 -0
  120. package/components/chip.d.ts +13 -0
  121. package/components/chip.js +112 -0
  122. package/components/collapsible.d.ts +5 -0
  123. package/components/collapsible.js +31 -0
  124. package/components/connector-card.d.ts +62 -0
  125. package/components/connector-card.js +154 -0
  126. package/components/divider.d.ts +23 -0
  127. package/components/divider.js +69 -0
  128. package/components/drawer.d.ts +45 -0
  129. package/components/drawer.js +234 -0
  130. package/components/dropdown.d.ts +33 -0
  131. package/components/dropdown.js +198 -0
  132. package/components/empty-state.d.ts +8 -0
  133. package/components/empty-state.js +30 -0
  134. package/components/field.d.ts +20 -0
  135. package/components/field.js +74 -0
  136. package/components/index.d.ts +56 -0
  137. package/components/index.js +444 -0
  138. package/components/input-field.d.ts +22 -0
  139. package/components/input-field.js +91 -0
  140. package/components/input.d.ts +8 -0
  141. package/components/input.js +61 -0
  142. package/components/kbd.d.ts +6 -0
  143. package/components/kbd.js +26 -0
  144. package/components/link.d.ts +14 -0
  145. package/components/link.js +72 -0
  146. package/components/modal.d.ts +18 -0
  147. package/components/modal.js +156 -0
  148. package/components/navbar.d.ts +15 -0
  149. package/components/navbar.js +68 -0
  150. package/components/number-field.d.ts +11 -0
  151. package/components/number-field.js +89 -0
  152. package/components/pagination.d.ts +28 -0
  153. package/components/pagination.js +179 -0
  154. package/components/panel.d.ts +14 -0
  155. package/components/panel.js +71 -0
  156. package/components/pixel-blast-svg.d.ts +22 -0
  157. package/components/pixel-blast-svg.js +154 -0
  158. package/components/popover.d.ts +20 -0
  159. package/components/popover.js +101 -0
  160. package/components/progress-circle.d.ts +11 -0
  161. package/components/progress-circle.js +75 -0
  162. package/components/progress.d.ts +22 -0
  163. package/components/progress.js +66 -0
  164. package/components/radio.d.ts +16 -0
  165. package/components/radio.js +101 -0
  166. package/components/segmented.d.ts +16 -0
  167. package/components/segmented.js +103 -0
  168. package/components/select.d.ts +28 -0
  169. package/components/select.js +180 -0
  170. package/components/selection-action-bar.d.ts +11 -0
  171. package/components/selection-action-bar.js +59 -0
  172. package/components/sidebar.d.ts +118 -0
  173. package/components/sidebar.js +375 -0
  174. package/components/skeleton.d.ts +6 -0
  175. package/components/skeleton.js +26 -0
  176. package/components/slider.d.ts +11 -0
  177. package/components/slider.js +62 -0
  178. package/components/spinner.d.ts +11 -0
  179. package/components/spinner.js +62 -0
  180. package/components/switch.d.ts +7 -0
  181. package/components/switch.js +61 -0
  182. package/components/table.d.ts +59 -0
  183. package/components/table.js +254 -0
  184. package/components/tabs.d.ts +29 -0
  185. package/components/tabs.js +371 -0
  186. package/components/textarea.d.ts +5 -0
  187. package/components/textarea.js +24 -0
  188. package/components/timeline.d.ts +7 -0
  189. package/components/timeline.js +47 -0
  190. package/components/toast.d.ts +74 -0
  191. package/components/toast.js +211 -0
  192. package/components/tooltip.d.ts +11 -0
  193. package/components/tooltip.js +143 -0
  194. package/components/tree.d.ts +42 -0
  195. package/components/tree.js +86 -0
  196. package/components/typography.d.ts +33 -0
  197. package/components/typography.js +65 -0
  198. package/components/ui/avatar.d.ts +11 -0
  199. package/components/ui/avatar.js +56 -0
  200. package/components/ui/button.d.ts +10 -0
  201. package/components/ui/button.js +57 -0
  202. package/components/ui/collapsible.d.ts +5 -0
  203. package/components/ui/collapsible.js +35 -0
  204. package/components/ui/dialog.d.ts +17 -0
  205. package/components/ui/dialog.js +93 -0
  206. package/components/ui/tabs.d.ts +22 -0
  207. package/components/ui/tooltip.d.ts +7 -0
  208. package/components/ui/tooltip.js +56 -0
  209. package/fonts/aribau-grotesk-400.otf +0 -0
  210. package/fonts/aribau-grotesk-700.otf +0 -0
  211. package/fonts.css +21 -0
  212. package/hooks/agents-ui/use-agent-audio-visualizer-aura.d.ts +8 -0
  213. package/hooks/agents-ui/use-agent-audio-visualizer-aura.js +62 -0
  214. package/hooks/agents-ui/use-agent-audio-visualizer-wave.d.ts +7 -0
  215. package/hooks/agents-ui/use-agent-audio-visualizer-wave.js +60 -0
  216. package/hooks/agents-ui/voice-visualizer-types.d.ts +9 -0
  217. package/lib/cn.d.ts +3 -0
  218. package/lib/cn.js +9 -0
  219. package/lib/icons.d.ts +378 -0
  220. package/lib/icons.js +119 -0
  221. package/lib/interactive.d.ts +24 -0
  222. package/lib/interactive.js +36 -0
  223. package/lib/motion.d.ts +58 -0
  224. package/lib/motion.js +70 -0
  225. package/lib/router.d.ts +3 -0
  226. package/lib/utils.d.ts +6 -0
  227. package/llms.txt +537 -0
  228. package/manifest.json +5085 -0
  229. package/package.json +60 -0
  230. package/styles.css +653 -0
  231. package/theme.css +273 -0
@@ -0,0 +1,103 @@
1
+ "use client";
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";
6
+ import { cn as c } from "../lib/cn.js";
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",
13
+ {
14
+ variants: {
15
+ size: {
16
+ sm: "text-xs",
17
+ md: "text-xs",
18
+ lg: "text-base"
19
+ }
20
+ },
21
+ defaultVariants: { size: "md" }
22
+ }
23
+ ), k = l(
24
+ c(
25
+ // The active pill is a shared motion thumb that SLIDES between options
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",
28
+ "transition-colors duration-(--duration-fast) cursor-pointer",
29
+ "outline-none focus-visible:ring-3 focus-visible:ring-ring",
30
+ "disabled:pointer-events-none disabled:opacity-50"
31
+ ),
32
+ {
33
+ variants: {
34
+ size: {
35
+ sm: "h-6 px-2.5",
36
+ md: "h-8 px-3",
37
+ lg: "h-9 px-4"
38
+ },
39
+ selected: {
40
+ true: "text-foreground",
41
+ false: "text-muted-foreground hover:text-foreground"
42
+ }
43
+ },
44
+ defaultVariants: { size: "md", selected: !1 }
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);
50
+ };
51
+ return /* @__PURE__ */ n(
52
+ "div",
53
+ {
54
+ ref: f,
55
+ role: "radiogroup",
56
+ onKeyDown: (e) => {
57
+ switch (e.key) {
58
+ case "ArrowRight":
59
+ case "ArrowDown":
60
+ e.preventDefault(), i(1);
61
+ break;
62
+ case "ArrowLeft":
63
+ case "ArrowUp":
64
+ e.preventDefault(), i(-1);
65
+ break;
66
+ }
67
+ },
68
+ className: c(y({ size: o }), u),
69
+ ...m,
70
+ children: /* @__PURE__ */ n(v, { reducedMotion: "user", children: r.map((e) => {
71
+ const t = e.value === a;
72
+ return /* @__PURE__ */ b(
73
+ "button",
74
+ {
75
+ type: "button",
76
+ role: "radio",
77
+ "aria-checked": t,
78
+ tabIndex: t ? 0 : -1,
79
+ onClick: () => s(e.value),
80
+ className: k({ size: o, selected: t }),
81
+ children: [
82
+ t && /* @__PURE__ */ n(
83
+ h.span,
84
+ {
85
+ layoutId: g,
86
+ "aria-hidden": !0,
87
+ transition: { duration: 0.2, ease: w },
88
+ className: "absolute inset-0 rounded-md bg-elevated shadow-elevation"
89
+ }
90
+ ),
91
+ /* @__PURE__ */ n("span", { className: "relative", children: e.label })
92
+ ]
93
+ },
94
+ e.value
95
+ );
96
+ }) })
97
+ }
98
+ );
99
+ });
100
+ A.displayName = "SegmentedControl";
101
+ export {
102
+ A as SegmentedControl
103
+ };
@@ -0,0 +1,28 @@
1
+ import { VariantProps } from 'class-variance-authority';
2
+ import * as React from "react";
3
+ declare const selectTriggerVariants: (props?: ({
4
+ size?: "sm" | "md" | "lg" | null | undefined;
5
+ } & import('class-variance-authority/types').ClassProp) | undefined) => string;
6
+ export interface SelectItem {
7
+ label: string;
8
+ value: string;
9
+ disabled?: boolean;
10
+ }
11
+ export interface SelectProps extends VariantProps<typeof selectTriggerVariants> {
12
+ items: SelectItem[];
13
+ value?: string;
14
+ onChange?: (value: string) => void;
15
+ placeholder?: string;
16
+ disabled?: boolean;
17
+ isInvalid?: boolean;
18
+ className?: string;
19
+ id?: string;
20
+ /**
21
+ * Which side the listbox opens toward. Use `"top"` when the trigger sits
22
+ * at the bottom of a clipped container (e.g. a table footer inside an
23
+ * `overflow-clip` shell) so the menu isn't cut off. Defaults to `"bottom"`.
24
+ */
25
+ placement?: "top" | "bottom";
26
+ }
27
+ export declare const Select: React.ForwardRefExoticComponent<SelectProps & React.RefAttributes<HTMLButtonElement>>;
28
+ export {};
@@ -0,0 +1,180 @@
1
+ "use client";
2
+ import { jsxs as x, jsx as i } from "react/jsx-runtime";
3
+ import * as s from "react";
4
+ import { cva as j } from "class-variance-authority";
5
+ import { MotionConfig as M, AnimatePresence as V, motion as $ } from "motion/react";
6
+ import { ChevronDown as C, Check as K } from "../lib/icons.js";
7
+ import { cn as d } from "../lib/cn.js";
8
+ import { inputBaseClass as L } from "./field.js";
9
+ import { floatVariants as O } from "../lib/motion.js";
10
+ const P = j(
11
+ d(
12
+ L,
13
+ "items-center justify-between gap-2 text-left cursor-pointer",
14
+ "[&_svg]:pointer-events-none [&_svg]:shrink-0"
15
+ ),
16
+ {
17
+ variants: {
18
+ size: {
19
+ sm: "h-8 text-xs",
20
+ md: "h-10 text-xs",
21
+ lg: "h-11 text-base"
22
+ }
23
+ },
24
+ defaultVariants: { size: "md" }
25
+ }
26
+ ), T = s.forwardRef(
27
+ ({
28
+ items: o,
29
+ value: c,
30
+ onChange: m,
31
+ placeholder: I = "Select…",
32
+ size: N,
33
+ disabled: h,
34
+ isInvalid: E,
35
+ className: A,
36
+ id: R,
37
+ placement: w = "bottom"
38
+ }, 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]);
43
+ s.useEffect(() => {
44
+ if (!r) return;
45
+ const e = (t) => {
46
+ var n;
47
+ (n = g.current) != null && n.contains(t.target) || l(!1);
48
+ };
49
+ return document.addEventListener("mousedown", e), () => document.removeEventListener("mousedown", e);
50
+ }, [r]), s.useEffect(() => {
51
+ var t;
52
+ if (!r || a < 0) return;
53
+ const e = (t = k.current) == null ? void 0 : t.children[a];
54
+ e == null || e.scrollIntoView({ block: "nearest" });
55
+ }, [r, a]);
56
+ const f = () => {
57
+ h || (b(z()), l(!0));
58
+ }, y = (e) => {
59
+ b((t) => {
60
+ 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;
63
+ return t;
64
+ });
65
+ }, D = (e) => {
66
+ const t = o[e];
67
+ !t || t.disabled || (m == null || m(t.value), l(!1));
68
+ };
69
+ return /* @__PURE__ */ x("div", { ref: g, className: "relative", children: [
70
+ /* @__PURE__ */ x(
71
+ "button",
72
+ {
73
+ ref: S,
74
+ id: R,
75
+ type: "button",
76
+ role: "combobox",
77
+ "aria-haspopup": "listbox",
78
+ "aria-expanded": r,
79
+ "aria-controls": u,
80
+ "aria-invalid": E || void 0,
81
+ disabled: h,
82
+ onClick: () => r ? l(!1) : f(),
83
+ onKeyDown: (e) => {
84
+ switch (e.key) {
85
+ case "ArrowDown":
86
+ e.preventDefault(), r ? y(1) : f();
87
+ break;
88
+ case "ArrowUp":
89
+ e.preventDefault(), r ? y(-1) : f();
90
+ break;
91
+ case "Enter":
92
+ case " ":
93
+ e.preventDefault(), r ? D(a) : f();
94
+ break;
95
+ case "Escape":
96
+ r && (e.preventDefault(), l(!1));
97
+ break;
98
+ case "Tab":
99
+ l(!1);
100
+ break;
101
+ }
102
+ },
103
+ className: d(P({ size: N }), A),
104
+ children: [
105
+ /* @__PURE__ */ i(
106
+ "span",
107
+ {
108
+ className: d(
109
+ "truncate",
110
+ !v && "text-muted-foreground"
111
+ ),
112
+ children: v ? v.label : I
113
+ }
114
+ ),
115
+ /* @__PURE__ */ i(
116
+ C,
117
+ {
118
+ className: d(
119
+ "size-4 text-muted-foreground transition-transform duration-(--duration-fast) ease-out motion-reduce:transition-none",
120
+ r && "rotate-180"
121
+ ),
122
+ "aria-hidden": !0
123
+ }
124
+ )
125
+ ]
126
+ }
127
+ ),
128
+ /* @__PURE__ */ i(M, { reducedMotion: "user", children: /* @__PURE__ */ i(V, { children: r && /* @__PURE__ */ i(
129
+ $.ul,
130
+ {
131
+ ref: k,
132
+ id: u,
133
+ role: "listbox",
134
+ "aria-activedescendant": a >= 0 ? `${u}-opt-${a}` : void 0,
135
+ variants: O,
136
+ initial: "hidden",
137
+ animate: "visible",
138
+ exit: "hidden",
139
+ style: {
140
+ transformOrigin: w === "top" ? "bottom" : "top"
141
+ },
142
+ className: d(
143
+ "absolute z-50 max-h-60 w-full overflow-auto p-1",
144
+ "rounded-md border border-border bg-elevated shadow-elevation",
145
+ w === "top" ? "bottom-full mb-1.5" : "top-full mt-1.5"
146
+ ),
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
+ })
172
+ }
173
+ ) }) })
174
+ ] });
175
+ }
176
+ );
177
+ T.displayName = "Select";
178
+ export {
179
+ T as Select
180
+ };
@@ -0,0 +1,11 @@
1
+ import { ButtonProps } from './button';
2
+ import * as React from "react";
3
+ export interface SelectionActionBarProps extends React.HTMLAttributes<HTMLDivElement> {
4
+ selectedCount: number;
5
+ selectedLabel?: React.ReactNode;
6
+ actions?: React.ReactNode;
7
+ onClear?: () => void;
8
+ clearLabel?: string;
9
+ }
10
+ export declare const SelectionActionBar: React.ForwardRefExoticComponent<SelectionActionBarProps & React.RefAttributes<HTMLDivElement>>;
11
+ export declare const SelectionActionBarAction: React.ForwardRefExoticComponent<ButtonProps & React.RefAttributes<HTMLButtonElement>>;
@@ -0,0 +1,59 @@
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(
7
+ ({
8
+ className: r,
9
+ selectedCount: o,
10
+ selectedLabel: t,
11
+ actions: n,
12
+ onClear: e,
13
+ clearLabel: l = "Clear",
14
+ ...m
15
+ }, f) => /* @__PURE__ */ i(
16
+ "div",
17
+ {
18
+ ref: f,
19
+ className: d(
20
+ "flex items-center gap-3 rounded-lg bg-brand px-3 py-2 text-xs text-brand-foreground",
21
+ r
22
+ ),
23
+ ...m,
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,
28
+ e && /* @__PURE__ */ a(
29
+ s,
30
+ {
31
+ onClick: e,
32
+ className: "text-brand-foreground/70 hover:text-brand-foreground",
33
+ children: l
34
+ }
35
+ )
36
+ ] })
37
+ ]
38
+ }
39
+ )
40
+ );
41
+ g.displayName = "SelectionActionBar";
42
+ const s = c.forwardRef(({ className: r, variant: o = "ghost", size: t = "xs", ...n }, e) => /* @__PURE__ */ a(
43
+ u,
44
+ {
45
+ ref: e,
46
+ variant: o,
47
+ size: t,
48
+ className: d(
49
+ "text-brand-foreground hover:bg-brand-foreground/10 hover:text-brand-foreground focus-visible:ring-brand-foreground",
50
+ r
51
+ ),
52
+ ...n
53
+ }
54
+ ));
55
+ s.displayName = "SelectionActionBarAction";
56
+ export {
57
+ g as SelectionActionBar,
58
+ s as SelectionActionBarAction
59
+ };
@@ -0,0 +1,118 @@
1
+ import * as React from "react";
2
+ /**
3
+ * Sidebar — a vertical navigation rail (the left region of an app frame).
4
+ *
5
+ * Supports a **collapsed** icon-rail mode: the rail animates between the
6
+ * `--sidebar-width` (expanded) and `--sidebar-width-sm` (56px icon rail) tokens.
7
+ * Collapse is opt-in and works controlled (`collapsed` + `onCollapsedChange`) or
8
+ * uncontrolled (`defaultCollapsed`). Press ⌘B / Ctrl-B to toggle.
9
+ *
10
+ * Sub-parts read the collapsed state through a `group/sidebar` data attribute, so
11
+ * labels hide and icons center automatically — no prop threading. Consumers that
12
+ * render richer collapse-sensitive content (a "Recents" list, an account block)
13
+ * can read `useSidebar()`.
14
+ *
15
+ * Compose: Sidebar > SidebarHeader (+ SidebarTrigger) + SidebarNav
16
+ * (SidebarSection > SidebarItem…) + SidebarFooter.
17
+ */
18
+ interface SidebarContextValue {
19
+ collapsed: boolean;
20
+ toggle: () => void;
21
+ setCollapsed: (collapsed: boolean) => void;
22
+ }
23
+ /** Read the sidebar's collapsed state (and toggle) from any descendant. */
24
+ export declare function useSidebar(): SidebarContextValue;
25
+ export interface SidebarProps extends React.HTMLAttributes<HTMLElement> {
26
+ /** Controlled collapsed state. */
27
+ collapsed?: boolean;
28
+ /** Uncontrolled initial collapsed state. */
29
+ defaultCollapsed?: boolean;
30
+ onCollapsedChange?: (collapsed: boolean) => void;
31
+ /** Bind ⌘B / Ctrl-B to toggle collapse. Default true. */
32
+ keyboardToggle?: boolean;
33
+ }
34
+ export declare const Sidebar: React.ForwardRefExoticComponent<SidebarProps & React.RefAttributes<HTMLElement>>;
35
+ /**
36
+ * Collapse toggle. Place inside SidebarHeader. Shows a tooltip with the ⌘B
37
+ * shortcut, and lifts to a white chip on hover.
38
+ */
39
+ export declare function SidebarTrigger({ className, onClick, ...props }: React.ButtonHTMLAttributes<HTMLButtonElement>): React.JSX.Element;
40
+ export interface SidebarBrandProps extends React.HTMLAttributes<HTMLDivElement> {
41
+ /** The brand mark (img/svg) — `--sidebar-logo` (20px) centered in a `--sidebar-item` (32px) square, same box as every other rail icon. */
42
+ logo: React.ReactNode;
43
+ /** Wrap the logo in a link. */
44
+ href?: string;
45
+ /** Accessible label for the logo link. */
46
+ label?: string;
47
+ /** Reveal the collapse trigger in place of the logo on hover. Default true. */
48
+ showTrigger?: boolean;
49
+ }
50
+ /**
51
+ * Brand header — the logo sits in the top slot and, when `showTrigger`, swaps to
52
+ * the collapse toggle while the rail is hovered (the trigger takes the logo's
53
+ * place). Self-contained: use it as the first child of `Sidebar` instead of a
54
+ * `SidebarHeader`.
55
+ */
56
+ export declare function SidebarBrand({ logo, href, label, showTrigger, className, ...props }: SidebarBrandProps): React.JSX.Element;
57
+ export declare const SidebarHeader: React.ForwardRefExoticComponent<React.HTMLAttributes<HTMLDivElement> & React.RefAttributes<HTMLDivElement>>;
58
+ export declare const SidebarNav: React.ForwardRefExoticComponent<React.HTMLAttributes<HTMLElement> & React.RefAttributes<HTMLElement>>;
59
+ export interface SidebarSectionProps extends React.HTMLAttributes<HTMLDivElement> {
60
+ label?: React.ReactNode;
61
+ }
62
+ export declare const SidebarSection: React.ForwardRefExoticComponent<SidebarSectionProps & React.RefAttributes<HTMLDivElement>>;
63
+ export interface SidebarItemProps extends React.AnchorHTMLAttributes<HTMLAnchorElement> {
64
+ icon?: React.ReactNode;
65
+ isActive?: boolean;
66
+ /** Trailing content (e.g. a badge). Hidden when collapsed. */
67
+ endContent?: React.ReactNode;
68
+ }
69
+ export declare const SidebarItem: React.ForwardRefExoticComponent<SidebarItemProps & React.RefAttributes<HTMLAnchorElement>>;
70
+ export declare const SidebarFooter: React.ForwardRefExoticComponent<React.HTMLAttributes<HTMLDivElement> & React.RefAttributes<HTMLDivElement>>;
71
+ export interface SidebarActionProps extends React.ButtonHTMLAttributes<HTMLButtonElement> {
72
+ icon?: React.ReactNode;
73
+ }
74
+ /**
75
+ * Primary action for the rail (e.g. "Ask …"). An elevated, subtly-stroked pill
76
+ * that collapses to a centered square icon button.
77
+ */
78
+ export declare const SidebarAction: React.ForwardRefExoticComponent<SidebarActionProps & React.RefAttributes<HTMLButtonElement>>;
79
+ export interface SidebarHistoryProps extends React.HTMLAttributes<HTMLDivElement> {
80
+ label?: React.ReactNode;
81
+ }
82
+ /** A labelled list (e.g. "Recents"). Hidden entirely in the collapsed rail. */
83
+ export declare const SidebarHistory: React.ForwardRefExoticComponent<SidebarHistoryProps & React.RefAttributes<HTMLDivElement>>;
84
+ export interface SidebarHistoryItemProps extends React.AnchorHTMLAttributes<HTMLAnchorElement> {
85
+ /**
86
+ * Hover-revealed trailing action (e.g. a kebab menu). Sits over the right
87
+ * edge with a gradient backdrop, so the scrolling title disappears cleanly
88
+ * behind it.
89
+ */
90
+ action?: React.ReactNode;
91
+ /** Persistent active/selected state (e.g. the open conversation). */
92
+ isActive?: boolean;
93
+ /**
94
+ * Optional leading icon (e.g. a spinner while the conversation is
95
+ * generating). Sits in the text indent, so the title doesn't shift.
96
+ */
97
+ icon?: React.ReactNode;
98
+ }
99
+ /**
100
+ * A recents/history row. Instead of a hard `…` truncation, a long title fades
101
+ * out at the right edge (mask). On hover the title strip scrolls left at a
102
+ * constant speed to reveal the full name (measured in JS, animated in CSS), and
103
+ * the `action` slot fades in. Respects reduced-motion (no scroll, fade only).
104
+ */
105
+ export declare const SidebarHistoryItem: React.ForwardRefExoticComponent<SidebarHistoryItemProps & React.RefAttributes<HTMLAnchorElement>>;
106
+ export interface SidebarAccountProps extends Omit<React.AnchorHTMLAttributes<HTMLAnchorElement>, "role"> {
107
+ name: string;
108
+ /** Secondary line (role, org…). */
109
+ role?: React.ReactNode;
110
+ /** Avatar image; falls back to initials from `name`. */
111
+ src?: string;
112
+ }
113
+ /**
114
+ * Account block for the rail footer — avatar + name/role. Collapses to just the
115
+ * avatar, centered. Wrap in a `SidebarFooter`.
116
+ */
117
+ export declare const SidebarAccount: React.ForwardRefExoticComponent<SidebarAccountProps & React.RefAttributes<HTMLAnchorElement>>;
118
+ export {};