@wealthx/shadcn 1.5.37 → 1.5.39
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.
- package/.turbo/turbo-build.log +142 -133
- package/CHANGELOG.md +12 -0
- package/dist/{chunk-LSSIWLYU.mjs → chunk-6XNEHTII.mjs} +1 -1
- package/dist/{chunk-ULQ53FRJ.mjs → chunk-7NQKFPXE.mjs} +1 -1
- package/dist/{chunk-734FOOJC.mjs → chunk-B5PSUONN.mjs} +25 -58
- package/dist/{chunk-DSVKEVX6.mjs → chunk-CZOGJC76.mjs} +1 -1
- package/dist/chunk-EFHPSKVF.mjs +192 -0
- package/dist/{chunk-JPGL36WQ.mjs → chunk-FL7DEYUA.mjs} +6 -7
- package/dist/{chunk-2CHH5QOA.mjs → chunk-FQUT5XD6.mjs} +1 -1
- package/dist/chunk-MGIDYXOP.mjs +814 -0
- package/dist/{chunk-OG2VM34K.mjs → chunk-MHBQJVHE.mjs} +1 -1
- package/dist/{chunk-NB3ZL36B.mjs → chunk-MZI77ZMX.mjs} +17 -2
- package/dist/chunk-R7M657QL.mjs +587 -0
- package/dist/{chunk-DIH2NZZ3.mjs → chunk-RRROLESJ.mjs} +33 -23
- package/dist/components/ui/ai-assistant-drawer.js +269 -121
- package/dist/components/ui/ai-assistant-drawer.mjs +2 -1
- package/dist/components/ui/ai-conversations/index.js +474 -286
- package/dist/components/ui/ai-conversations/index.mjs +2 -1
- package/dist/components/ui/chat-input-area.js +429 -0
- package/dist/components/ui/chat-input-area.mjs +11 -0
- package/dist/components/ui/file-preview-dialog.js +6 -7
- package/dist/components/ui/file-preview-dialog.mjs +2 -2
- package/dist/components/ui/kanban-column.js +6 -7
- package/dist/components/ui/kanban-column.mjs +3 -3
- package/dist/components/ui/opportunity-card.js +6 -7
- package/dist/components/ui/opportunity-card.mjs +2 -2
- package/dist/components/ui/page-top-bar.js +182 -5
- package/dist/components/ui/page-top-bar.mjs +3 -1
- package/dist/components/ui/pipeline-board.js +6 -7
- package/dist/components/ui/pipeline-board.mjs +4 -4
- package/dist/components/ui/policy-ai/index.js +1636 -0
- package/dist/components/ui/policy-ai/index.mjs +36 -0
- package/dist/components/ui/progress.js +6 -7
- package/dist/components/ui/progress.mjs +1 -1
- package/dist/components/ui/stage-timeline.js +6 -7
- package/dist/components/ui/stage-timeline.mjs +2 -2
- package/dist/components/ui/support-agent/index.js +1131 -0
- package/dist/components/ui/support-agent/index.mjs +27 -0
- package/dist/index.js +5609 -4100
- package/dist/index.mjs +77 -41
- package/dist/styles.css +1 -1
- package/package.json +16 -1
- package/src/components/index.tsx +54 -0
- package/src/components/ui/ai-assistant-drawer.tsx +24 -51
- package/src/components/ui/ai-conversations/index.tsx +16 -8
- package/src/components/ui/ai-conversations/thread.tsx +38 -27
- package/src/components/ui/chat-input-area.tsx +244 -0
- package/src/components/ui/page-top-bar.tsx +31 -5
- package/src/components/ui/policy-ai/index.tsx +41 -0
- package/src/components/ui/policy-ai/policy-ai-panel.tsx +526 -0
- package/src/components/ui/policy-ai/policy-ai-primitives.tsx +332 -0
- package/src/components/ui/policy-ai/policy-ai-responses.tsx +543 -0
- package/src/components/ui/progress.tsx +15 -12
- package/src/components/ui/support-agent/index.tsx +25 -0
- package/src/components/ui/support-agent/support-agent-fab.tsx +116 -0
- package/src/components/ui/support-agent/support-agent-panel.tsx +498 -0
- package/src/components/ui/support-agent/support-agent-primitives.tsx +354 -0
- package/src/styles/globals.css +1 -0
- package/src/styles/styles-css.ts +1 -1
- package/tsup.config.ts +3 -0
|
@@ -9,13 +9,14 @@ import {
|
|
|
9
9
|
ConversationStatusChip,
|
|
10
10
|
ConversationsPage,
|
|
11
11
|
LeadInfoPanel
|
|
12
|
-
} from "../../../chunk-
|
|
12
|
+
} from "../../../chunk-RRROLESJ.mjs";
|
|
13
13
|
import "../../../chunk-3S6KVFF5.mjs";
|
|
14
14
|
import "../../../chunk-WE4YKBDE.mjs";
|
|
15
15
|
import "../../../chunk-T5FRVEJQ.mjs";
|
|
16
16
|
import "../../../chunk-H5DTKPJ2.mjs";
|
|
17
17
|
import "../../../chunk-H6NQTIF4.mjs";
|
|
18
18
|
import "../../../chunk-2GIYVERS.mjs";
|
|
19
|
+
import "../../../chunk-EFHPSKVF.mjs";
|
|
19
20
|
import "../../../chunk-BS75ICOO.mjs";
|
|
20
21
|
import "../../../chunk-X6RC5UWB.mjs";
|
|
21
22
|
import "../../../chunk-F3CU6KEI.mjs";
|
|
@@ -0,0 +1,429 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __create = Object.create;
|
|
3
|
+
var __defProp = Object.defineProperty;
|
|
4
|
+
var __defProps = Object.defineProperties;
|
|
5
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
6
|
+
var __getOwnPropDescs = Object.getOwnPropertyDescriptors;
|
|
7
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
8
|
+
var __getOwnPropSymbols = Object.getOwnPropertySymbols;
|
|
9
|
+
var __getProtoOf = Object.getPrototypeOf;
|
|
10
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
11
|
+
var __propIsEnum = Object.prototype.propertyIsEnumerable;
|
|
12
|
+
var __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
13
|
+
var __spreadValues = (a, b) => {
|
|
14
|
+
for (var prop in b || (b = {}))
|
|
15
|
+
if (__hasOwnProp.call(b, prop))
|
|
16
|
+
__defNormalProp(a, prop, b[prop]);
|
|
17
|
+
if (__getOwnPropSymbols)
|
|
18
|
+
for (var prop of __getOwnPropSymbols(b)) {
|
|
19
|
+
if (__propIsEnum.call(b, prop))
|
|
20
|
+
__defNormalProp(a, prop, b[prop]);
|
|
21
|
+
}
|
|
22
|
+
return a;
|
|
23
|
+
};
|
|
24
|
+
var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
25
|
+
var __objRest = (source, exclude) => {
|
|
26
|
+
var target = {};
|
|
27
|
+
for (var prop in source)
|
|
28
|
+
if (__hasOwnProp.call(source, prop) && exclude.indexOf(prop) < 0)
|
|
29
|
+
target[prop] = source[prop];
|
|
30
|
+
if (source != null && __getOwnPropSymbols)
|
|
31
|
+
for (var prop of __getOwnPropSymbols(source)) {
|
|
32
|
+
if (exclude.indexOf(prop) < 0 && __propIsEnum.call(source, prop))
|
|
33
|
+
target[prop] = source[prop];
|
|
34
|
+
}
|
|
35
|
+
return target;
|
|
36
|
+
};
|
|
37
|
+
var __export = (target, all) => {
|
|
38
|
+
for (var name in all)
|
|
39
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
|
40
|
+
};
|
|
41
|
+
var __copyProps = (to, from, except, desc) => {
|
|
42
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
43
|
+
for (let key of __getOwnPropNames(from))
|
|
44
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
45
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
46
|
+
}
|
|
47
|
+
return to;
|
|
48
|
+
};
|
|
49
|
+
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
|
|
50
|
+
// If the importer is in node compatibility mode or this is not an ESM
|
|
51
|
+
// file that has been converted to a CommonJS file using a Babel-
|
|
52
|
+
// compatible transform (i.e. "__esModule" has not been set), then set
|
|
53
|
+
// "default" to the CommonJS "module.exports" for node compatibility.
|
|
54
|
+
isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
|
|
55
|
+
mod
|
|
56
|
+
));
|
|
57
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
58
|
+
|
|
59
|
+
// src/components/ui/chat-input-area.tsx
|
|
60
|
+
var chat_input_area_exports = {};
|
|
61
|
+
__export(chat_input_area_exports, {
|
|
62
|
+
ChatInputArea: () => ChatInputArea
|
|
63
|
+
});
|
|
64
|
+
module.exports = __toCommonJS(chat_input_area_exports);
|
|
65
|
+
var React2 = __toESM(require("react"));
|
|
66
|
+
var import_lucide_react2 = require("lucide-react");
|
|
67
|
+
|
|
68
|
+
// src/lib/utils.ts
|
|
69
|
+
var import_clsx = require("clsx");
|
|
70
|
+
var import_tailwind_merge = require("tailwind-merge");
|
|
71
|
+
var twMerge = (0, import_tailwind_merge.extendTailwindMerge)({
|
|
72
|
+
extend: {
|
|
73
|
+
classGroups: {
|
|
74
|
+
"font-size": [
|
|
75
|
+
{
|
|
76
|
+
text: [
|
|
77
|
+
"display-large",
|
|
78
|
+
"display-medium",
|
|
79
|
+
"display-small",
|
|
80
|
+
"h1",
|
|
81
|
+
"h2",
|
|
82
|
+
"h3",
|
|
83
|
+
"h4",
|
|
84
|
+
"h5",
|
|
85
|
+
"h6",
|
|
86
|
+
"body-large",
|
|
87
|
+
"body-medium",
|
|
88
|
+
"body-small",
|
|
89
|
+
"label-large",
|
|
90
|
+
"label-medium",
|
|
91
|
+
"label-small",
|
|
92
|
+
"button",
|
|
93
|
+
"button-xs",
|
|
94
|
+
"caption",
|
|
95
|
+
"overline",
|
|
96
|
+
"code"
|
|
97
|
+
]
|
|
98
|
+
}
|
|
99
|
+
]
|
|
100
|
+
}
|
|
101
|
+
}
|
|
102
|
+
});
|
|
103
|
+
function cn(...inputs) {
|
|
104
|
+
return twMerge((0, import_clsx.clsx)(inputs));
|
|
105
|
+
}
|
|
106
|
+
|
|
107
|
+
// src/components/ui/button.tsx
|
|
108
|
+
var import_react = require("react");
|
|
109
|
+
var import_class_variance_authority = require("class-variance-authority");
|
|
110
|
+
var import_lucide_react = require("lucide-react");
|
|
111
|
+
|
|
112
|
+
// src/lib/slot.tsx
|
|
113
|
+
var React = __toESM(require("react"));
|
|
114
|
+
function mergeRefs(...refs) {
|
|
115
|
+
return (value) => {
|
|
116
|
+
for (const ref of refs) {
|
|
117
|
+
if (typeof ref === "function") ref(value);
|
|
118
|
+
else if (ref !== null)
|
|
119
|
+
ref.current = value;
|
|
120
|
+
}
|
|
121
|
+
};
|
|
122
|
+
}
|
|
123
|
+
var Slot = React.forwardRef(
|
|
124
|
+
(_a, forwardedRef) => {
|
|
125
|
+
var _b = _a, { children } = _b, props = __objRest(_b, ["children"]);
|
|
126
|
+
const child = React.Children.only(children);
|
|
127
|
+
if (!React.isValidElement(child)) return null;
|
|
128
|
+
const childProps = child.props;
|
|
129
|
+
const merged = __spreadValues({}, props);
|
|
130
|
+
for (const key of Object.keys(childProps)) {
|
|
131
|
+
if (key === "className") {
|
|
132
|
+
merged.className = [props.className, childProps.className].filter(Boolean).join(" ");
|
|
133
|
+
} else if (key === "style") {
|
|
134
|
+
merged.style = __spreadValues(__spreadValues({}, props.style), childProps.style);
|
|
135
|
+
} else if (key.startsWith("on") && typeof childProps[key] === "function") {
|
|
136
|
+
const parentHandler = props[key];
|
|
137
|
+
if (typeof parentHandler === "function") {
|
|
138
|
+
merged[key] = (...args) => {
|
|
139
|
+
childProps[key](...args);
|
|
140
|
+
parentHandler(...args);
|
|
141
|
+
};
|
|
142
|
+
} else {
|
|
143
|
+
merged[key] = childProps[key];
|
|
144
|
+
}
|
|
145
|
+
} else {
|
|
146
|
+
merged[key] = childProps[key];
|
|
147
|
+
}
|
|
148
|
+
}
|
|
149
|
+
const childRef = child.ref;
|
|
150
|
+
merged.ref = forwardedRef ? mergeRefs(forwardedRef, childRef) : childRef;
|
|
151
|
+
return React.cloneElement(
|
|
152
|
+
child,
|
|
153
|
+
merged
|
|
154
|
+
);
|
|
155
|
+
}
|
|
156
|
+
);
|
|
157
|
+
Slot.displayName = "Slot";
|
|
158
|
+
|
|
159
|
+
// src/components/ui/button.tsx
|
|
160
|
+
var import_jsx_runtime = require("react/jsx-runtime");
|
|
161
|
+
var buttonVariants = (0, import_class_variance_authority.cva)(
|
|
162
|
+
"inline-flex shrink-0 cursor-pointer items-center justify-center gap-2 font-sans text-button whitespace-nowrap transition-all active:scale-[0.98] outline-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",
|
|
163
|
+
{
|
|
164
|
+
variants: {
|
|
165
|
+
variant: {
|
|
166
|
+
default: "bg-primary text-primary-foreground shadow-xs hover:bg-primary/90",
|
|
167
|
+
secondary: "bg-brand-secondary text-brand-secondary-foreground shadow-xs hover:bg-brand-secondary/80 focus-visible:ring-brand-secondary/30",
|
|
168
|
+
destructive: "bg-destructive text-destructive-foreground shadow-xs hover:bg-destructive/90 focus-visible:ring-destructive/20 dark:bg-destructive/60 dark:focus-visible:ring-destructive/40",
|
|
169
|
+
outline: "border border-input bg-background shadow-xs hover:bg-accent hover:text-accent-foreground focus-visible:border-border focus-visible:ring-border/50 dark:bg-input/30 dark:border-input dark:hover:bg-input/50",
|
|
170
|
+
"outline-primary": "border border-primary text-foreground bg-transparent shadow-xs hover:bg-primary/5 focus-visible:ring-primary/50",
|
|
171
|
+
"outline-secondary": "border border-brand-secondary text-brand-secondary bg-transparent shadow-xs hover:bg-brand-secondary/10 focus-visible:border-brand-secondary focus-visible:ring-brand-secondary/30",
|
|
172
|
+
ghost: "hover:bg-accent hover:text-accent-foreground hover:shadow-xs focus-visible:ring-border/50 dark:hover:bg-accent/50",
|
|
173
|
+
link: "text-primary underline-offset-4 hover:underline"
|
|
174
|
+
},
|
|
175
|
+
size: {
|
|
176
|
+
default: "h-9 px-4 py-2 has-[>svg]:px-3",
|
|
177
|
+
xs: "h-6 gap-1 px-2 text-button-xs has-[>svg]:px-1.5 [&_svg:not([class*='size-'])]:size-3",
|
|
178
|
+
sm: "h-8 gap-1.5 px-3 has-[>svg]:px-2.5",
|
|
179
|
+
lg: "h-10 px-6 has-[>svg]:px-4",
|
|
180
|
+
icon: "size-9",
|
|
181
|
+
"icon-xs": "size-6 [&_svg:not([class*='size-'])]:size-3",
|
|
182
|
+
"icon-sm": "size-8",
|
|
183
|
+
"icon-lg": "size-10"
|
|
184
|
+
}
|
|
185
|
+
},
|
|
186
|
+
defaultVariants: {
|
|
187
|
+
variant: "default",
|
|
188
|
+
size: "default"
|
|
189
|
+
}
|
|
190
|
+
}
|
|
191
|
+
);
|
|
192
|
+
var Button = (0, import_react.forwardRef)(function Button2(_a, ref) {
|
|
193
|
+
var _b = _a, {
|
|
194
|
+
className,
|
|
195
|
+
variant,
|
|
196
|
+
size,
|
|
197
|
+
asChild = false,
|
|
198
|
+
loading = false,
|
|
199
|
+
disabled,
|
|
200
|
+
type = "button",
|
|
201
|
+
children
|
|
202
|
+
} = _b, props = __objRest(_b, [
|
|
203
|
+
"className",
|
|
204
|
+
"variant",
|
|
205
|
+
"size",
|
|
206
|
+
"asChild",
|
|
207
|
+
"loading",
|
|
208
|
+
"disabled",
|
|
209
|
+
"type",
|
|
210
|
+
"children"
|
|
211
|
+
]);
|
|
212
|
+
const Comp = asChild ? Slot : "button";
|
|
213
|
+
const isIconOnly = size === "icon" || size === "icon-xs" || size === "icon-sm" || size === "icon-lg";
|
|
214
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
|
|
215
|
+
Comp,
|
|
216
|
+
__spreadProps(__spreadValues({
|
|
217
|
+
className: cn(buttonVariants({ variant, size, className })),
|
|
218
|
+
"data-size": size,
|
|
219
|
+
"data-slot": "button",
|
|
220
|
+
"data-variant": variant,
|
|
221
|
+
disabled: loading || disabled,
|
|
222
|
+
ref,
|
|
223
|
+
type
|
|
224
|
+
}, props), {
|
|
225
|
+
children: loading ? /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(import_jsx_runtime.Fragment, { children: [
|
|
226
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_lucide_react.Loader2, { "aria-hidden": "true", className: "animate-spin" }),
|
|
227
|
+
!isIconOnly && children
|
|
228
|
+
] }) : children
|
|
229
|
+
})
|
|
230
|
+
);
|
|
231
|
+
});
|
|
232
|
+
|
|
233
|
+
// src/components/ui/textarea.tsx
|
|
234
|
+
var import_jsx_runtime2 = require("react/jsx-runtime");
|
|
235
|
+
function Textarea(_a) {
|
|
236
|
+
var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
|
|
237
|
+
return /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(
|
|
238
|
+
"textarea",
|
|
239
|
+
__spreadValues({
|
|
240
|
+
className: cn(
|
|
241
|
+
// WealthX: removed shadow-xs (flat panels), added font-sans
|
|
242
|
+
"flex field-sizing-content min-h-16 w-full border border-input bg-transparent px-3 py-2 text-body-medium font-sans transition-[color,box-shadow] outline-none placeholder:font-normal placeholder:text-muted-foreground focus-visible:border-primary focus-visible:ring-[3px] focus-visible:ring-primary/20 disabled:cursor-not-allowed disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-destructive/20 dark:bg-input/30 dark:aria-invalid:ring-destructive/40",
|
|
243
|
+
className
|
|
244
|
+
),
|
|
245
|
+
"data-slot": "textarea"
|
|
246
|
+
}, props)
|
|
247
|
+
);
|
|
248
|
+
}
|
|
249
|
+
|
|
250
|
+
// src/components/ui/chat-input-area.tsx
|
|
251
|
+
var import_jsx_runtime3 = require("react/jsx-runtime");
|
|
252
|
+
var DEFAULT_HINT = "Enter to send \xB7 Shift+Enter for new line";
|
|
253
|
+
function ChatInputArea({
|
|
254
|
+
value,
|
|
255
|
+
onChange,
|
|
256
|
+
onSend,
|
|
257
|
+
onAttachFile,
|
|
258
|
+
onAttachImage,
|
|
259
|
+
disabled = false,
|
|
260
|
+
placeholder = "Type your message\u2026",
|
|
261
|
+
hint = DEFAULT_HINT,
|
|
262
|
+
maxHeight = 160,
|
|
263
|
+
autoFocus = false,
|
|
264
|
+
className
|
|
265
|
+
}) {
|
|
266
|
+
const textareaRef = React2.useRef(null);
|
|
267
|
+
const fileInputRef = React2.useRef(null);
|
|
268
|
+
const imageInputRef = React2.useRef(null);
|
|
269
|
+
React2.useEffect(() => {
|
|
270
|
+
if (autoFocus) {
|
|
271
|
+
setTimeout(() => {
|
|
272
|
+
var _a;
|
|
273
|
+
return (_a = textareaRef.current) == null ? void 0 : _a.focus();
|
|
274
|
+
}, 50);
|
|
275
|
+
}
|
|
276
|
+
}, [autoFocus]);
|
|
277
|
+
const handleSend = React2.useCallback(() => {
|
|
278
|
+
const text = value.trim();
|
|
279
|
+
if (!text || disabled) return;
|
|
280
|
+
onSend(text);
|
|
281
|
+
if (textareaRef.current) {
|
|
282
|
+
textareaRef.current.style.height = "auto";
|
|
283
|
+
}
|
|
284
|
+
}, [value, disabled, onSend]);
|
|
285
|
+
const handleKeyDown = React2.useCallback(
|
|
286
|
+
(e) => {
|
|
287
|
+
if (e.key === "Enter" && !e.shiftKey) {
|
|
288
|
+
e.preventDefault();
|
|
289
|
+
handleSend();
|
|
290
|
+
}
|
|
291
|
+
},
|
|
292
|
+
[handleSend]
|
|
293
|
+
);
|
|
294
|
+
const handleTextareaChange = React2.useCallback(
|
|
295
|
+
(e) => {
|
|
296
|
+
onChange(e.target.value);
|
|
297
|
+
const el = e.target;
|
|
298
|
+
el.style.height = "auto";
|
|
299
|
+
el.style.height = `${Math.min(el.scrollHeight, maxHeight)}px`;
|
|
300
|
+
},
|
|
301
|
+
[onChange, maxHeight]
|
|
302
|
+
);
|
|
303
|
+
const handleFileChange = React2.useCallback(
|
|
304
|
+
(e) => {
|
|
305
|
+
var _a;
|
|
306
|
+
if ((_a = e.target.files) == null ? void 0 : _a.length) {
|
|
307
|
+
onAttachFile == null ? void 0 : onAttachFile(e.target.files);
|
|
308
|
+
e.target.value = "";
|
|
309
|
+
}
|
|
310
|
+
},
|
|
311
|
+
[onAttachFile]
|
|
312
|
+
);
|
|
313
|
+
const handleImageChange = React2.useCallback(
|
|
314
|
+
(e) => {
|
|
315
|
+
var _a;
|
|
316
|
+
if ((_a = e.target.files) == null ? void 0 : _a.length) {
|
|
317
|
+
onAttachImage == null ? void 0 : onAttachImage(e.target.files);
|
|
318
|
+
e.target.value = "";
|
|
319
|
+
}
|
|
320
|
+
},
|
|
321
|
+
[onAttachImage]
|
|
322
|
+
);
|
|
323
|
+
const showFileButton = typeof onAttachFile === "function";
|
|
324
|
+
const showImageButton = typeof onAttachImage === "function";
|
|
325
|
+
return /* @__PURE__ */ (0, import_jsx_runtime3.jsxs)(
|
|
326
|
+
"div",
|
|
327
|
+
{
|
|
328
|
+
"data-slot": "chat-input-area",
|
|
329
|
+
className: cn("flex flex-col gap-1.5", className),
|
|
330
|
+
children: [
|
|
331
|
+
/* @__PURE__ */ (0, import_jsx_runtime3.jsxs)("div", { className: "border border-border bg-background flex flex-col focus-within:ring-1 focus-within:ring-ring", children: [
|
|
332
|
+
/* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
|
|
333
|
+
Textarea,
|
|
334
|
+
{
|
|
335
|
+
ref: textareaRef,
|
|
336
|
+
value,
|
|
337
|
+
onChange: handleTextareaChange,
|
|
338
|
+
onKeyDown: handleKeyDown,
|
|
339
|
+
placeholder,
|
|
340
|
+
disabled,
|
|
341
|
+
rows: 3,
|
|
342
|
+
className: "resize-none text-sm border-0 shadow-none focus-visible:ring-0 px-3 pt-3 pb-1 min-h-[72px]",
|
|
343
|
+
"aria-label": placeholder
|
|
344
|
+
}
|
|
345
|
+
),
|
|
346
|
+
/* @__PURE__ */ (0, import_jsx_runtime3.jsxs)("div", { className: "flex items-center justify-between px-2 pb-2", children: [
|
|
347
|
+
/* @__PURE__ */ (0, import_jsx_runtime3.jsxs)("div", { className: "flex items-center gap-0.5", children: [
|
|
348
|
+
showFileButton && /* @__PURE__ */ (0, import_jsx_runtime3.jsxs)(import_jsx_runtime3.Fragment, { children: [
|
|
349
|
+
/* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
|
|
350
|
+
Button,
|
|
351
|
+
{
|
|
352
|
+
variant: "ghost",
|
|
353
|
+
size: "icon-sm",
|
|
354
|
+
type: "button",
|
|
355
|
+
title: "Attach file",
|
|
356
|
+
"aria-label": "Attach file",
|
|
357
|
+
disabled,
|
|
358
|
+
onClick: () => {
|
|
359
|
+
var _a;
|
|
360
|
+
return (_a = fileInputRef.current) == null ? void 0 : _a.click();
|
|
361
|
+
},
|
|
362
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(import_lucide_react2.Paperclip, { className: "size-3.5", "aria-hidden": "true" })
|
|
363
|
+
}
|
|
364
|
+
),
|
|
365
|
+
/* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
|
|
366
|
+
"input",
|
|
367
|
+
{
|
|
368
|
+
ref: fileInputRef,
|
|
369
|
+
type: "file",
|
|
370
|
+
multiple: true,
|
|
371
|
+
className: "sr-only",
|
|
372
|
+
tabIndex: -1,
|
|
373
|
+
onChange: handleFileChange
|
|
374
|
+
}
|
|
375
|
+
)
|
|
376
|
+
] }),
|
|
377
|
+
showImageButton && /* @__PURE__ */ (0, import_jsx_runtime3.jsxs)(import_jsx_runtime3.Fragment, { children: [
|
|
378
|
+
/* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
|
|
379
|
+
Button,
|
|
380
|
+
{
|
|
381
|
+
variant: "ghost",
|
|
382
|
+
size: "icon-sm",
|
|
383
|
+
type: "button",
|
|
384
|
+
title: "Upload image",
|
|
385
|
+
"aria-label": "Upload image",
|
|
386
|
+
disabled,
|
|
387
|
+
onClick: () => {
|
|
388
|
+
var _a;
|
|
389
|
+
return (_a = imageInputRef.current) == null ? void 0 : _a.click();
|
|
390
|
+
},
|
|
391
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(import_lucide_react2.ImagePlus, { className: "size-3.5", "aria-hidden": "true" })
|
|
392
|
+
}
|
|
393
|
+
),
|
|
394
|
+
/* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
|
|
395
|
+
"input",
|
|
396
|
+
{
|
|
397
|
+
ref: imageInputRef,
|
|
398
|
+
type: "file",
|
|
399
|
+
multiple: true,
|
|
400
|
+
accept: "image/*",
|
|
401
|
+
className: "sr-only",
|
|
402
|
+
tabIndex: -1,
|
|
403
|
+
onChange: handleImageChange
|
|
404
|
+
}
|
|
405
|
+
)
|
|
406
|
+
] })
|
|
407
|
+
] }),
|
|
408
|
+
/* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
|
|
409
|
+
Button,
|
|
410
|
+
{
|
|
411
|
+
size: "icon-sm",
|
|
412
|
+
type: "button",
|
|
413
|
+
"aria-label": "Send message",
|
|
414
|
+
disabled: !value.trim() || disabled,
|
|
415
|
+
onClick: handleSend,
|
|
416
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(import_lucide_react2.Send, { className: "size-3.5", "aria-hidden": "true" })
|
|
417
|
+
}
|
|
418
|
+
)
|
|
419
|
+
] })
|
|
420
|
+
] }),
|
|
421
|
+
hint !== false && /* @__PURE__ */ (0, import_jsx_runtime3.jsx)("p", { className: "text-xs text-muted-foreground", children: hint })
|
|
422
|
+
]
|
|
423
|
+
}
|
|
424
|
+
);
|
|
425
|
+
}
|
|
426
|
+
// Annotate the CommonJS export names for ESM import in node:
|
|
427
|
+
0 && (module.exports = {
|
|
428
|
+
ChatInputArea
|
|
429
|
+
});
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import {
|
|
2
|
+
ChatInputArea
|
|
3
|
+
} from "../../chunk-EFHPSKVF.mjs";
|
|
4
|
+
import "../../chunk-BS75ICOO.mjs";
|
|
5
|
+
import "../../chunk-NOOEKOWY.mjs";
|
|
6
|
+
import "../../chunk-R4HCRDU5.mjs";
|
|
7
|
+
import "../../chunk-AFML43VJ.mjs";
|
|
8
|
+
import "../../chunk-WNQUEZJF.mjs";
|
|
9
|
+
export {
|
|
10
|
+
ChatInputArea
|
|
11
|
+
};
|
|
@@ -408,25 +408,24 @@ var import_jsx_runtime4 = require("react/jsx-runtime");
|
|
|
408
408
|
function Progress(_a) {
|
|
409
409
|
var _b = _a, {
|
|
410
410
|
className,
|
|
411
|
-
value
|
|
411
|
+
value,
|
|
412
|
+
indicatorClassName
|
|
412
413
|
} = _b, props = __objRest(_b, [
|
|
413
414
|
"className",
|
|
414
|
-
"value"
|
|
415
|
+
"value",
|
|
416
|
+
"indicatorClassName"
|
|
415
417
|
]);
|
|
416
418
|
return /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
|
|
417
419
|
import_progress.Progress.Root,
|
|
418
420
|
__spreadProps(__spreadValues({
|
|
419
|
-
className: cn(
|
|
420
|
-
"relative h-2 w-full overflow-hidden bg-muted",
|
|
421
|
-
className
|
|
422
|
-
),
|
|
421
|
+
className: cn("relative h-2 w-full overflow-hidden bg-muted", className),
|
|
423
422
|
"data-slot": "progress",
|
|
424
423
|
value
|
|
425
424
|
}, props), {
|
|
426
425
|
children: /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(import_progress.Progress.Track, { className: "h-full", children: /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
|
|
427
426
|
import_progress.Progress.Indicator,
|
|
428
427
|
{
|
|
429
|
-
className: "h-full bg-primary transition-all",
|
|
428
|
+
className: cn("h-full bg-primary transition-all", indicatorClassName),
|
|
430
429
|
"data-slot": "progress-indicator"
|
|
431
430
|
}
|
|
432
431
|
) })
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import {
|
|
2
2
|
FilePreviewDialog
|
|
3
|
-
} from "../../chunk-
|
|
4
|
-
import "../../chunk-
|
|
3
|
+
} from "../../chunk-7NQKFPXE.mjs";
|
|
4
|
+
import "../../chunk-FL7DEYUA.mjs";
|
|
5
5
|
import "../../chunk-GTAVSBDO.mjs";
|
|
6
6
|
import "../../chunk-3S6KVFF5.mjs";
|
|
7
7
|
import "../../chunk-GT3RU6GA.mjs";
|
|
@@ -697,25 +697,24 @@ var import_jsx_runtime11 = require("react/jsx-runtime");
|
|
|
697
697
|
function Progress(_a) {
|
|
698
698
|
var _b = _a, {
|
|
699
699
|
className,
|
|
700
|
-
value
|
|
700
|
+
value,
|
|
701
|
+
indicatorClassName
|
|
701
702
|
} = _b, props = __objRest(_b, [
|
|
702
703
|
"className",
|
|
703
|
-
"value"
|
|
704
|
+
"value",
|
|
705
|
+
"indicatorClassName"
|
|
704
706
|
]);
|
|
705
707
|
return /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(
|
|
706
708
|
import_progress.Progress.Root,
|
|
707
709
|
__spreadProps(__spreadValues({
|
|
708
|
-
className: cn(
|
|
709
|
-
"relative h-2 w-full overflow-hidden bg-muted",
|
|
710
|
-
className
|
|
711
|
-
),
|
|
710
|
+
className: cn("relative h-2 w-full overflow-hidden bg-muted", className),
|
|
712
711
|
"data-slot": "progress",
|
|
713
712
|
value
|
|
714
713
|
}, props), {
|
|
715
714
|
children: /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(import_progress.Progress.Track, { className: "h-full", children: /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(
|
|
716
715
|
import_progress.Progress.Indicator,
|
|
717
716
|
{
|
|
718
|
-
className: "h-full bg-primary transition-all",
|
|
717
|
+
className: cn("h-full bg-primary transition-all", indicatorClassName),
|
|
719
718
|
"data-slot": "progress-indicator"
|
|
720
719
|
}
|
|
721
720
|
) })
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import {
|
|
2
2
|
KanbanColumn
|
|
3
|
-
} from "../../chunk-
|
|
4
|
-
import "../../chunk-
|
|
3
|
+
} from "../../chunk-MHBQJVHE.mjs";
|
|
4
|
+
import "../../chunk-CZOGJC76.mjs";
|
|
5
5
|
import "../../chunk-L6LE4OIM.mjs";
|
|
6
|
-
import "../../chunk-
|
|
6
|
+
import "../../chunk-FL7DEYUA.mjs";
|
|
7
7
|
import "../../chunk-3S6KVFF5.mjs";
|
|
8
8
|
import "../../chunk-PNSYFE3K.mjs";
|
|
9
9
|
import "../../chunk-IKXYTCSB.mjs";
|
|
@@ -667,25 +667,24 @@ var import_jsx_runtime10 = require("react/jsx-runtime");
|
|
|
667
667
|
function Progress(_a) {
|
|
668
668
|
var _b = _a, {
|
|
669
669
|
className,
|
|
670
|
-
value
|
|
670
|
+
value,
|
|
671
|
+
indicatorClassName
|
|
671
672
|
} = _b, props = __objRest(_b, [
|
|
672
673
|
"className",
|
|
673
|
-
"value"
|
|
674
|
+
"value",
|
|
675
|
+
"indicatorClassName"
|
|
674
676
|
]);
|
|
675
677
|
return /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(
|
|
676
678
|
import_progress.Progress.Root,
|
|
677
679
|
__spreadProps(__spreadValues({
|
|
678
|
-
className: cn(
|
|
679
|
-
"relative h-2 w-full overflow-hidden bg-muted",
|
|
680
|
-
className
|
|
681
|
-
),
|
|
680
|
+
className: cn("relative h-2 w-full overflow-hidden bg-muted", className),
|
|
682
681
|
"data-slot": "progress",
|
|
683
682
|
value
|
|
684
683
|
}, props), {
|
|
685
684
|
children: /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(import_progress.Progress.Track, { className: "h-full", children: /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(
|
|
686
685
|
import_progress.Progress.Indicator,
|
|
687
686
|
{
|
|
688
|
-
className: "h-full bg-primary transition-all",
|
|
687
|
+
className: cn("h-full bg-primary transition-all", indicatorClassName),
|
|
689
688
|
"data-slot": "progress-indicator"
|
|
690
689
|
}
|
|
691
690
|
) })
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import {
|
|
2
2
|
LeadCard,
|
|
3
3
|
OpportunityCard
|
|
4
|
-
} from "../../chunk-
|
|
4
|
+
} from "../../chunk-CZOGJC76.mjs";
|
|
5
5
|
import "../../chunk-L6LE4OIM.mjs";
|
|
6
|
-
import "../../chunk-
|
|
6
|
+
import "../../chunk-FL7DEYUA.mjs";
|
|
7
7
|
import "../../chunk-PNSYFE3K.mjs";
|
|
8
8
|
import "../../chunk-IKXYTCSB.mjs";
|
|
9
9
|
import "../../chunk-H5DTKPJ2.mjs";
|