@wealthx/shadcn 1.5.38 → 1.5.40

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 (39) hide show
  1. package/.turbo/turbo-build.log +98 -95
  2. package/CHANGELOG.md +12 -0
  3. package/dist/{chunk-LSSIWLYU.mjs → chunk-6XNEHTII.mjs} +1 -1
  4. package/dist/{chunk-ULQ53FRJ.mjs → chunk-7NQKFPXE.mjs} +1 -1
  5. package/dist/{chunk-DSVKEVX6.mjs → chunk-CZOGJC76.mjs} +1 -1
  6. package/dist/{chunk-JPGL36WQ.mjs → chunk-FL7DEYUA.mjs} +6 -7
  7. package/dist/{chunk-2CHH5QOA.mjs → chunk-FQUT5XD6.mjs} +1 -1
  8. package/dist/chunk-MGIDYXOP.mjs +814 -0
  9. package/dist/{chunk-OG2VM34K.mjs → chunk-MHBQJVHE.mjs} +1 -1
  10. package/dist/{chunk-R7M657QL.mjs → chunk-STN5QIWN.mjs} +36 -1
  11. package/dist/components/ui/file-preview-dialog.js +6 -7
  12. package/dist/components/ui/file-preview-dialog.mjs +2 -2
  13. package/dist/components/ui/kanban-column.js +6 -7
  14. package/dist/components/ui/kanban-column.mjs +3 -3
  15. package/dist/components/ui/opportunity-card.js +6 -7
  16. package/dist/components/ui/opportunity-card.mjs +2 -2
  17. package/dist/components/ui/pipeline-board.js +6 -7
  18. package/dist/components/ui/pipeline-board.mjs +4 -4
  19. package/dist/components/ui/policy-ai/index.js +1636 -0
  20. package/dist/components/ui/policy-ai/index.mjs +36 -0
  21. package/dist/components/ui/progress.js +6 -7
  22. package/dist/components/ui/progress.mjs +1 -1
  23. package/dist/components/ui/stage-timeline.js +6 -7
  24. package/dist/components/ui/stage-timeline.mjs +2 -2
  25. package/dist/components/ui/support-agent/index.js +31 -1
  26. package/dist/components/ui/support-agent/index.mjs +1 -1
  27. package/dist/index.js +4105 -3299
  28. package/dist/index.mjs +25 -7
  29. package/dist/styles.css +1 -1
  30. package/package.json +10 -5
  31. package/src/components/index.tsx +30 -0
  32. package/src/components/ui/policy-ai/index.tsx +41 -0
  33. package/src/components/ui/policy-ai/policy-ai-panel.tsx +526 -0
  34. package/src/components/ui/policy-ai/policy-ai-primitives.tsx +332 -0
  35. package/src/components/ui/policy-ai/policy-ai-responses.tsx +543 -0
  36. package/src/components/ui/progress.tsx +15 -12
  37. package/src/components/ui/support-agent/support-agent-panel.tsx +46 -2
  38. package/src/styles/styles-css.ts +1 -1
  39. package/tsup.config.ts +2 -1
@@ -1,7 +1,7 @@
1
1
  import {
2
2
  LeadCard,
3
3
  OpportunityCard
4
- } from "./chunk-DSVKEVX6.mjs";
4
+ } from "./chunk-CZOGJC76.mjs";
5
5
  import {
6
6
  Tooltip,
7
7
  TooltipContent,
@@ -17,6 +17,11 @@ import {
17
17
  import {
18
18
  cn
19
19
  } from "./chunk-AFML43VJ.mjs";
20
+ import {
21
+ __objRest,
22
+ __spreadProps,
23
+ __spreadValues
24
+ } from "./chunk-WNQUEZJF.mjs";
20
25
 
21
26
  // src/components/ui/support-agent/support-agent-primitives.tsx
22
27
  import * as React from "react";
@@ -285,6 +290,9 @@ function SupportAgentFAB({
285
290
 
286
291
  // src/components/ui/support-agent/support-agent-panel.tsx
287
292
  import * as React2 from "react";
293
+ import ReactMarkdown from "react-markdown";
294
+ import rehypeRaw from "rehype-raw";
295
+ import rehypeSanitize, { defaultSchema } from "rehype-sanitize";
288
296
  import { Bot, ChevronLeft, ChevronRight, SquarePen, X as X2 } from "lucide-react";
289
297
  import { jsx as jsx3, jsxs as jsxs3 } from "react/jsx-runtime";
290
298
  function SupportTypingIndicator() {
@@ -306,6 +314,21 @@ function SupportTypingIndicator() {
306
314
  }
307
315
  );
308
316
  }
317
+ function StreamingStatus({ label }) {
318
+ if (!label) return /* @__PURE__ */ jsx3(SupportTypingIndicator, {});
319
+ return /* @__PURE__ */ jsxs3(
320
+ "span",
321
+ {
322
+ className: "flex items-center gap-1.5 text-sm text-muted-foreground",
323
+ role: "status",
324
+ "aria-label": `${label}\u2026`,
325
+ children: [
326
+ /* @__PURE__ */ jsx3("span", { children: label }),
327
+ /* @__PURE__ */ jsx3(SupportTypingIndicator, {})
328
+ ]
329
+ }
330
+ );
331
+ }
309
332
  function MessageBubble({ message }) {
310
333
  const isUser = message.role === "user";
311
334
  const isEmpty = !message.content.trim();
@@ -328,7 +351,19 @@ function MessageBubble({ message }) {
328
351
  "data-slot": "support-message-bubble",
329
352
  "data-role": message.role,
330
353
  children: [
331
- isEmpty && message.isStreaming ? /* @__PURE__ */ jsx3(SupportTypingIndicator, {}) : /* @__PURE__ */ jsx3("span", { className: "whitespace-pre-wrap break-words leading-relaxed", children: message.content }),
354
+ isEmpty && message.isStreaming ? /* @__PURE__ */ jsx3(StreamingStatus, { label: message.streamingLabel }) : isUser ? /* @__PURE__ */ jsx3("span", { className: "whitespace-pre-wrap break-words leading-relaxed", children: message.content }) : /* @__PURE__ */ jsx3("div", { className: "break-words text-sm leading-relaxed [&_a]:text-primary [&_a]:underline [&_p]:m-0 [&_p:not(:last-child)]:mb-2 [&_ul]:my-1 [&_ul]:list-disc [&_ul]:pl-4 [&_ol]:my-1 [&_ol]:list-decimal [&_ol]:pl-4 [&_li]:mb-0.5", children: /* @__PURE__ */ jsx3(
355
+ ReactMarkdown,
356
+ {
357
+ rehypePlugins: [rehypeRaw, [rehypeSanitize, defaultSchema]],
358
+ components: {
359
+ a: (_a) => {
360
+ var _b = _a, { node } = _b, props = __objRest(_b, ["node"]);
361
+ return /* @__PURE__ */ jsx3("a", __spreadProps(__spreadValues({}, props), { target: "_blank", rel: "noopener noreferrer" }));
362
+ }
363
+ },
364
+ children: message.content
365
+ }
366
+ ) }),
332
367
  message.isErrored && /* @__PURE__ */ jsx3("p", { className: "mt-1 text-xs opacity-70", children: "Failed to send. Please try again." })
333
368
  ]
334
369
  }
@@ -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-ULQ53FRJ.mjs";
4
- import "../../chunk-JPGL36WQ.mjs";
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-OG2VM34K.mjs";
4
- import "../../chunk-DSVKEVX6.mjs";
3
+ } from "../../chunk-MHBQJVHE.mjs";
4
+ import "../../chunk-CZOGJC76.mjs";
5
5
  import "../../chunk-L6LE4OIM.mjs";
6
- import "../../chunk-JPGL36WQ.mjs";
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-DSVKEVX6.mjs";
4
+ } from "../../chunk-CZOGJC76.mjs";
5
5
  import "../../chunk-L6LE4OIM.mjs";
6
- import "../../chunk-JPGL36WQ.mjs";
6
+ import "../../chunk-FL7DEYUA.mjs";
7
7
  import "../../chunk-PNSYFE3K.mjs";
8
8
  import "../../chunk-IKXYTCSB.mjs";
9
9
  import "../../chunk-H5DTKPJ2.mjs";
@@ -827,25 +827,24 @@ var import_jsx_runtime14 = require("react/jsx-runtime");
827
827
  function Progress(_a) {
828
828
  var _b = _a, {
829
829
  className,
830
- value
830
+ value,
831
+ indicatorClassName
831
832
  } = _b, props = __objRest(_b, [
832
833
  "className",
833
- "value"
834
+ "value",
835
+ "indicatorClassName"
834
836
  ]);
835
837
  return /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(
836
838
  import_progress.Progress.Root,
837
839
  __spreadProps(__spreadValues({
838
- className: cn(
839
- "relative h-2 w-full overflow-hidden bg-muted",
840
- className
841
- ),
840
+ className: cn("relative h-2 w-full overflow-hidden bg-muted", className),
842
841
  "data-slot": "progress",
843
842
  value
844
843
  }, props), {
845
844
  children: /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(import_progress.Progress.Track, { className: "h-full", children: /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(
846
845
  import_progress.Progress.Indicator,
847
846
  {
848
- className: "h-full bg-primary transition-all",
847
+ className: cn("h-full bg-primary transition-all", indicatorClassName),
849
848
  "data-slot": "progress-indicator"
850
849
  }
851
850
  ) })
@@ -1,10 +1,10 @@
1
1
  import {
2
2
  PipelineBoard
3
- } from "../../chunk-2CHH5QOA.mjs";
4
- import "../../chunk-OG2VM34K.mjs";
5
- import "../../chunk-DSVKEVX6.mjs";
3
+ } from "../../chunk-FQUT5XD6.mjs";
4
+ import "../../chunk-MHBQJVHE.mjs";
5
+ import "../../chunk-CZOGJC76.mjs";
6
6
  import "../../chunk-L6LE4OIM.mjs";
7
- import "../../chunk-JPGL36WQ.mjs";
7
+ import "../../chunk-FL7DEYUA.mjs";
8
8
  import "../../chunk-3S6KVFF5.mjs";
9
9
  import "../../chunk-PNSYFE3K.mjs";
10
10
  import "../../chunk-IKXYTCSB.mjs";