@wow-two-beta/ui 0.0.24 → 0.0.25

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 (96) hide show
  1. package/dist/actions/index.js +2 -2
  2. package/dist/{chunk-O6UUYPTB.js → chunk-2AUDMNHI.js} +3 -3
  3. package/dist/{chunk-O6UUYPTB.js.map → chunk-2AUDMNHI.js.map} +1 -1
  4. package/dist/{chunk-45SFQEMP.js → chunk-3PUV6PGJ.js} +302 -5
  5. package/dist/chunk-3PUV6PGJ.js.map +1 -0
  6. package/dist/{chunk-4P2TFUVW.js → chunk-76ZIAFWD.js} +9 -3
  7. package/dist/chunk-76ZIAFWD.js.map +1 -0
  8. package/dist/{chunk-25CGSOXZ.js → chunk-A5JQGP5F.js} +3 -3
  9. package/dist/{chunk-25CGSOXZ.js.map → chunk-A5JQGP5F.js.map} +1 -1
  10. package/dist/{chunk-3KPILWVX.js → chunk-IERJ5D7R.js} +4 -4
  11. package/dist/{chunk-3KPILWVX.js.map → chunk-IERJ5D7R.js.map} +1 -1
  12. package/dist/{chunk-XRTXK5Y4.js → chunk-MCUDIBTG.js} +4 -4
  13. package/dist/{chunk-XRTXK5Y4.js.map → chunk-MCUDIBTG.js.map} +1 -1
  14. package/dist/{chunk-I4WUBNR6.js → chunk-NLUTV5BP.js} +179 -5
  15. package/dist/chunk-NLUTV5BP.js.map +1 -0
  16. package/dist/{chunk-GRJBIGUD.js → chunk-S6QNKXKP.js} +3 -3
  17. package/dist/{chunk-GRJBIGUD.js.map → chunk-S6QNKXKP.js.map} +1 -1
  18. package/dist/{chunk-DSA7L7PD.js → chunk-TSTJCUXX.js} +5 -5
  19. package/dist/{chunk-DSA7L7PD.js.map → chunk-TSTJCUXX.js.map} +1 -1
  20. package/dist/{chunk-TK3SXTTF.js → chunk-U5SWHGKO.js} +566 -6
  21. package/dist/chunk-U5SWHGKO.js.map +1 -0
  22. package/dist/display/activityFeed/ActivityFeed.d.ts +29 -0
  23. package/dist/display/activityFeed/ActivityFeed.d.ts.map +1 -0
  24. package/dist/display/activityFeed/index.d.ts +2 -0
  25. package/dist/display/activityFeed/index.d.ts.map +1 -0
  26. package/dist/display/annotationMarker/AnnotationMarker.d.ts +24 -0
  27. package/dist/display/annotationMarker/AnnotationMarker.d.ts.map +1 -0
  28. package/dist/display/annotationMarker/index.d.ts +2 -0
  29. package/dist/display/annotationMarker/index.d.ts.map +1 -0
  30. package/dist/display/chatBubble/ChatBubble.d.ts +34 -0
  31. package/dist/display/chatBubble/ChatBubble.d.ts.map +1 -0
  32. package/dist/display/chatBubble/index.d.ts +2 -0
  33. package/dist/display/chatBubble/index.d.ts.map +1 -0
  34. package/dist/display/commentThread/CommentThread.d.ts +32 -0
  35. package/dist/display/commentThread/CommentThread.d.ts.map +1 -0
  36. package/dist/display/commentThread/index.d.ts +2 -0
  37. package/dist/display/commentThread/index.d.ts.map +1 -0
  38. package/dist/display/index.d.ts +7 -0
  39. package/dist/display/index.d.ts.map +1 -1
  40. package/dist/display/index.js +2 -2
  41. package/dist/display/messageList/MessageList.d.ts +33 -0
  42. package/dist/display/messageList/MessageList.d.ts.map +1 -0
  43. package/dist/display/messageList/index.d.ts +2 -0
  44. package/dist/display/messageList/index.d.ts.map +1 -0
  45. package/dist/display/reactionBar/ReactionBar.d.ts +33 -0
  46. package/dist/display/reactionBar/ReactionBar.d.ts.map +1 -0
  47. package/dist/display/reactionBar/index.d.ts +2 -0
  48. package/dist/display/reactionBar/index.d.ts.map +1 -0
  49. package/dist/display/threadView/ThreadView.d.ts +26 -0
  50. package/dist/display/threadView/ThreadView.d.ts.map +1 -0
  51. package/dist/display/threadView/index.d.ts +2 -0
  52. package/dist/display/threadView/index.d.ts.map +1 -0
  53. package/dist/feedback/index.d.ts +4 -0
  54. package/dist/feedback/index.d.ts.map +1 -1
  55. package/dist/feedback/index.js +2 -2
  56. package/dist/feedback/liveCursor/LiveCursor.d.ts +27 -0
  57. package/dist/feedback/liveCursor/LiveCursor.d.ts.map +1 -0
  58. package/dist/feedback/liveCursor/index.d.ts +2 -0
  59. package/dist/feedback/liveCursor/index.d.ts.map +1 -0
  60. package/dist/feedback/notificationCenter/NotificationCenter.d.ts +40 -0
  61. package/dist/feedback/notificationCenter/NotificationCenter.d.ts.map +1 -0
  62. package/dist/feedback/notificationCenter/index.d.ts +2 -0
  63. package/dist/feedback/notificationCenter/index.d.ts.map +1 -0
  64. package/dist/feedback/presenceIndicator/PresenceIndicator.d.ts +19 -0
  65. package/dist/feedback/presenceIndicator/PresenceIndicator.d.ts.map +1 -0
  66. package/dist/feedback/presenceIndicator/index.d.ts +2 -0
  67. package/dist/feedback/presenceIndicator/index.d.ts.map +1 -0
  68. package/dist/feedback/typingIndicator/TypingIndicator.d.ts +18 -0
  69. package/dist/feedback/typingIndicator/TypingIndicator.d.ts.map +1 -0
  70. package/dist/feedback/typingIndicator/index.d.ts +2 -0
  71. package/dist/feedback/typingIndicator/index.d.ts.map +1 -0
  72. package/dist/forms/chatComposer/ChatComposer.d.ts +37 -0
  73. package/dist/forms/chatComposer/ChatComposer.d.ts.map +1 -0
  74. package/dist/forms/chatComposer/index.d.ts +2 -0
  75. package/dist/forms/chatComposer/index.d.ts.map +1 -0
  76. package/dist/forms/index.d.ts +2 -0
  77. package/dist/forms/index.d.ts.map +1 -1
  78. package/dist/forms/index.js +5 -5
  79. package/dist/forms/reactionPicker/ReactionPicker.d.ts +22 -0
  80. package/dist/forms/reactionPicker/ReactionPicker.d.ts.map +1 -0
  81. package/dist/forms/reactionPicker/index.d.ts +2 -0
  82. package/dist/forms/reactionPicker/index.d.ts.map +1 -0
  83. package/dist/hooks/index.d.ts +1 -0
  84. package/dist/hooks/index.d.ts.map +1 -1
  85. package/dist/hooks/index.js +1 -1
  86. package/dist/hooks/useReducedMotion.d.ts +7 -0
  87. package/dist/hooks/useReducedMotion.d.ts.map +1 -0
  88. package/dist/index.js +10 -10
  89. package/dist/layout/index.js +3 -3
  90. package/dist/nav/index.js +3 -3
  91. package/dist/overlays/index.js +4 -4
  92. package/package.json +1 -1
  93. package/dist/chunk-45SFQEMP.js.map +0 -1
  94. package/dist/chunk-4P2TFUVW.js.map +0 -1
  95. package/dist/chunk-I4WUBNR6.js.map +0 -1
  96. package/dist/chunk-TK3SXTTF.js.map +0 -1
@@ -1,13 +1,13 @@
1
1
  import { Kbd, addDays, MONTHS_LONG, startOfDay, buildMonthGrid, WEEKDAYS_SHORT, isToday, addMonths, isSameDay } from './chunk-6RFXTWLM.js';
2
2
  import { tv, dataAttr } from './chunk-BMBIZLO4.js';
3
- import { useClipboard, useControlled } from './chunk-4P2TFUVW.js';
3
+ import { useClipboard, useControlled } from './chunk-76ZIAFWD.js';
4
4
  import { Icon } from './chunk-TDX22OWF.js';
5
5
  import { Slot, RovingFocusGroup, useRovingFocusItem, Portal, AnchoredPositioner } from './chunk-NC2CBGX2.js';
6
6
  import { composeRefs } from './chunk-DN7WBRIV.js';
7
7
  import { cn } from './chunk-KZ4VFY2T.js';
8
- import { forwardRef, useState, Children, isValidElement, Fragment as Fragment$1, createContext, useId, useMemo, useCallback, useContext, useEffect, useRef, useImperativeHandle, cloneElement } from 'react';
8
+ import { forwardRef, useState, Children, isValidElement, Fragment as Fragment$1, createContext, useId, useMemo, useCallback, useContext, useEffect, useRef, useImperativeHandle, useLayoutEffect, cloneElement } from 'react';
9
9
  import { jsx, Fragment, jsxs } from 'react/jsx-runtime';
10
- import { TrendingUp, TrendingDown, Check, Copy, ChevronDown, ChevronLeft, ChevronRight, Plus, Minus, Maximize, Pause, Play, VolumeX, Volume2, Captions, CaptionsOff, PictureInPicture2, Minimize, ZoomOut, ZoomIn, Download, ArrowUp, ArrowDown, ArrowUpDown } from 'lucide-react';
10
+ import { TrendingUp, TrendingDown, Check, Copy, ChevronDown, ChevronLeft, ChevronRight, Plus, Minus, Maximize, Pause, Play, VolumeX, Volume2, Captions, CaptionsOff, PictureInPicture2, Minimize, ZoomOut, ZoomIn, Download, SmilePlus, X, AlertTriangle, CheckCheck, Clock, ArrowUp, ArrowDown, ArrowUpDown } from 'lucide-react';
11
11
 
12
12
  // src/display/heading/Heading.variants.ts
13
13
  var headingVariants = tv({
@@ -4895,7 +4895,567 @@ var Confetti = forwardRef(function Confetti2({
4895
4895
  }
4896
4896
  ) });
4897
4897
  });
4898
+ var TONE_HIGHLIGHT = {
4899
+ note: "bg-info-soft/60 decoration-info",
4900
+ comment: "bg-primary-soft/60 decoration-primary",
4901
+ suggestion: "bg-success-soft/60 decoration-success",
4902
+ issue: "bg-destructive-soft/60 decoration-destructive",
4903
+ resolved: "bg-muted decoration-muted-foreground"
4904
+ };
4905
+ var TONE_PIN = {
4906
+ note: "bg-info text-info-foreground",
4907
+ comment: "bg-primary text-primary-foreground",
4908
+ suggestion: "bg-success text-success-foreground",
4909
+ issue: "bg-destructive text-destructive-foreground",
4910
+ resolved: "bg-muted-foreground text-background"
4911
+ };
4912
+ var AnnotationMarker = forwardRef(
4913
+ ({ children, index, tone = "comment", pinOnly, resolved, active, className, ...props }, ref) => {
4914
+ const effectiveTone = resolved ? "resolved" : tone;
4915
+ const pin = /* @__PURE__ */ jsx(
4916
+ "span",
4917
+ {
4918
+ "aria-hidden": "true",
4919
+ className: cn(
4920
+ "inline-flex h-4 min-w-4 shrink-0 items-center justify-center rounded-full px-1 text-[10px] font-semibold leading-none",
4921
+ TONE_PIN[effectiveTone]
4922
+ ),
4923
+ children: index ?? ""
4924
+ }
4925
+ );
4926
+ if (pinOnly || children == null) {
4927
+ return /* @__PURE__ */ jsx(
4928
+ "button",
4929
+ {
4930
+ ref,
4931
+ type: "button",
4932
+ "data-tone": effectiveTone,
4933
+ "data-active": active ? "" : void 0,
4934
+ className: cn(
4935
+ "inline-flex items-center gap-1 align-middle rounded-full ring-1 ring-transparent transition-shadow",
4936
+ active && "ring-ring",
4937
+ "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring",
4938
+ className
4939
+ ),
4940
+ ...props,
4941
+ children: pin
4942
+ }
4943
+ );
4944
+ }
4945
+ return /* @__PURE__ */ jsxs(
4946
+ "button",
4947
+ {
4948
+ ref,
4949
+ type: "button",
4950
+ "data-tone": effectiveTone,
4951
+ "data-active": active ? "" : void 0,
4952
+ className: cn(
4953
+ "group inline-flex items-baseline gap-1 align-baseline rounded-sm px-0.5 transition-colors",
4954
+ "underline decoration-2 underline-offset-4",
4955
+ "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring",
4956
+ TONE_HIGHLIGHT[effectiveTone],
4957
+ resolved && "line-through opacity-70",
4958
+ active && "ring-1 ring-ring",
4959
+ className
4960
+ ),
4961
+ ...props,
4962
+ children: [
4963
+ /* @__PURE__ */ jsx("span", { children }),
4964
+ pin
4965
+ ]
4966
+ }
4967
+ );
4968
+ }
4969
+ );
4970
+ AnnotationMarker.displayName = "AnnotationMarker";
4971
+ function ReactionChip({ reactedByMe, className, ...rest }) {
4972
+ return /* @__PURE__ */ jsx(
4973
+ "button",
4974
+ {
4975
+ type: "button",
4976
+ "data-active": reactedByMe ? "" : void 0,
4977
+ className: cn(
4978
+ "inline-flex items-center gap-1 rounded-full border px-2 py-0.5 text-xs leading-none transition-colors",
4979
+ "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring",
4980
+ reactedByMe ? "border-primary bg-primary-soft text-primary-soft-foreground" : "border-border bg-background hover:bg-muted",
4981
+ className
4982
+ ),
4983
+ ...rest
4984
+ }
4985
+ );
4986
+ }
4987
+ var ReactionBar = forwardRef(
4988
+ ({
4989
+ reactions,
4990
+ onReact,
4991
+ onAdd,
4992
+ hideAddButton,
4993
+ compact,
4994
+ hideEmpty = true,
4995
+ className,
4996
+ ...props
4997
+ }, ref) => {
4998
+ const visible = hideEmpty ? reactions.filter((r) => r.count > 0) : reactions;
4999
+ return /* @__PURE__ */ jsxs(
5000
+ "div",
5001
+ {
5002
+ ref,
5003
+ role: "group",
5004
+ "aria-label": "Reactions",
5005
+ className: cn("inline-flex flex-wrap items-center gap-1", className),
5006
+ ...props,
5007
+ children: [
5008
+ visible.map((r) => /* @__PURE__ */ jsxs(
5009
+ ReactionChip,
5010
+ {
5011
+ reactedByMe: r.reactedByMe,
5012
+ title: r.users?.length ? r.users.join(", ") : void 0,
5013
+ onClick: () => onReact?.(r.key),
5014
+ children: [
5015
+ /* @__PURE__ */ jsx("span", { className: "text-sm leading-none", children: r.emoji }),
5016
+ !compact && /* @__PURE__ */ jsx("span", { className: "font-medium tabular-nums", children: r.count })
5017
+ ]
5018
+ },
5019
+ r.key
5020
+ )),
5021
+ !hideAddButton && onAdd && /* @__PURE__ */ jsx(
5022
+ "button",
5023
+ {
5024
+ type: "button",
5025
+ onClick: onAdd,
5026
+ "aria-label": "Add reaction",
5027
+ className: cn(
5028
+ "inline-flex items-center justify-center rounded-full border border-dashed border-border px-2 py-0.5 text-muted-foreground transition-colors",
5029
+ "hover:bg-muted hover:text-foreground",
5030
+ "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring"
5031
+ ),
5032
+ children: /* @__PURE__ */ jsx(SmilePlus, { className: "h-3.5 w-3.5" })
5033
+ }
5034
+ )
5035
+ ]
5036
+ }
5037
+ );
5038
+ }
5039
+ );
5040
+ ReactionBar.displayName = "ReactionBar";
5041
+ var TONE_BASE = {
5042
+ default: "bg-muted text-foreground",
5043
+ primary: "bg-primary text-primary-foreground",
5044
+ system: "bg-transparent text-muted-foreground italic",
5045
+ subtle: "bg-card text-card-foreground border border-border"
5046
+ };
5047
+ var STATUS_ICON = {
5048
+ sending: /* @__PURE__ */ jsx(Clock, { className: "h-3 w-3" }),
5049
+ sent: /* @__PURE__ */ jsx(Check, { className: "h-3 w-3" }),
5050
+ delivered: /* @__PURE__ */ jsx(CheckCheck, { className: "h-3 w-3" }),
5051
+ read: /* @__PURE__ */ jsx(CheckCheck, { className: "h-3 w-3 text-info" }),
5052
+ failed: /* @__PURE__ */ jsx(AlertTriangle, { className: "h-3 w-3 text-destructive" })
5053
+ };
5054
+ var ChatBubble = forwardRef(
5055
+ ({
5056
+ side = "start",
5057
+ tone,
5058
+ avatar,
5059
+ author,
5060
+ timestamp,
5061
+ status,
5062
+ showStatusOnStart,
5063
+ tailless,
5064
+ footer,
5065
+ children,
5066
+ className,
5067
+ ...props
5068
+ }, ref) => {
5069
+ const isEnd = side === "end";
5070
+ const effectiveTone = tone ?? (isEnd ? "primary" : "default");
5071
+ const isSystem = effectiveTone === "system";
5072
+ const showStatus = !!status && (isEnd || showStatusOnStart);
5073
+ if (isSystem) {
5074
+ return /* @__PURE__ */ jsx(
5075
+ "div",
5076
+ {
5077
+ ref,
5078
+ "data-side": side,
5079
+ className: cn("flex w-full justify-center", className),
5080
+ ...props,
5081
+ children: /* @__PURE__ */ jsx("div", { className: cn("text-center text-xs", TONE_BASE.system), children })
5082
+ }
5083
+ );
5084
+ }
5085
+ return /* @__PURE__ */ jsxs(
5086
+ "div",
5087
+ {
5088
+ ref,
5089
+ "data-side": side,
5090
+ className: cn(
5091
+ "flex w-full gap-2",
5092
+ isEnd ? "flex-row-reverse" : "flex-row",
5093
+ className
5094
+ ),
5095
+ ...props,
5096
+ children: [
5097
+ avatar && /* @__PURE__ */ jsx("div", { className: "shrink-0 self-end", children: avatar }),
5098
+ /* @__PURE__ */ jsxs(
5099
+ "div",
5100
+ {
5101
+ className: cn(
5102
+ "flex max-w-[75%] flex-col gap-1",
5103
+ isEnd ? "items-end" : "items-start"
5104
+ ),
5105
+ children: [
5106
+ author && /* @__PURE__ */ jsx("div", { className: "text-xs font-medium text-muted-foreground", children: author }),
5107
+ /* @__PURE__ */ jsx(
5108
+ "div",
5109
+ {
5110
+ className: cn(
5111
+ "relative inline-block px-3 py-2 text-sm break-words",
5112
+ TONE_BASE[effectiveTone],
5113
+ tailless ? "rounded-2xl" : isEnd ? "rounded-2xl rounded-br-sm" : "rounded-2xl rounded-bl-sm"
5114
+ ),
5115
+ children
5116
+ }
5117
+ ),
5118
+ (timestamp || showStatus) && /* @__PURE__ */ jsxs(
5119
+ "div",
5120
+ {
5121
+ className: cn(
5122
+ "flex items-center gap-1 text-[11px] text-muted-foreground",
5123
+ isEnd ? "flex-row-reverse" : "flex-row"
5124
+ ),
5125
+ children: [
5126
+ timestamp && /* @__PURE__ */ jsx("span", { children: timestamp }),
5127
+ showStatus && status && /* @__PURE__ */ jsx("span", { "aria-label": `Status: ${status}`, children: STATUS_ICON[status] })
5128
+ ]
5129
+ }
5130
+ ),
5131
+ footer && /* @__PURE__ */ jsx("div", { className: cn(isEnd && "self-end"), children: footer })
5132
+ ]
5133
+ }
5134
+ )
5135
+ ]
5136
+ }
5137
+ );
5138
+ }
5139
+ );
5140
+ ChatBubble.displayName = "ChatBubble";
5141
+ var DaySeparator = forwardRef(
5142
+ ({ label, className, ...props }, ref) => /* @__PURE__ */ jsxs(
5143
+ "div",
5144
+ {
5145
+ ref,
5146
+ role: "separator",
5147
+ className: cn("flex items-center gap-3 py-2", className),
5148
+ ...props,
5149
+ children: [
5150
+ /* @__PURE__ */ jsx("span", { className: "h-px flex-1 bg-border", "aria-hidden": "true" }),
5151
+ /* @__PURE__ */ jsx("span", { className: "text-[11px] font-medium uppercase tracking-wide text-muted-foreground", children: label }),
5152
+ /* @__PURE__ */ jsx("span", { className: "h-px flex-1 bg-border", "aria-hidden": "true" })
5153
+ ]
5154
+ }
5155
+ )
5156
+ );
5157
+ DaySeparator.displayName = "MessageList.DaySeparator";
5158
+ var MessageListInner = forwardRef(
5159
+ ({
5160
+ header,
5161
+ footer,
5162
+ stickToBottom = true,
5163
+ bottomThreshold = 32,
5164
+ showJumpToBottom = true,
5165
+ reverse: _reverse,
5166
+ children,
5167
+ className,
5168
+ ...props
5169
+ }, ref) => {
5170
+ const scrollerRef = useRef(null);
5171
+ const [atBottom, setAtBottom] = useState(true);
5172
+ const isNearBottom = useCallback(() => {
5173
+ const el = scrollerRef.current;
5174
+ if (!el) return true;
5175
+ return el.scrollHeight - el.clientHeight - el.scrollTop <= bottomThreshold;
5176
+ }, [bottomThreshold]);
5177
+ const scrollToBottom = useCallback((behavior = "smooth") => {
5178
+ const el = scrollerRef.current;
5179
+ if (!el) return;
5180
+ el.scrollTo({ top: el.scrollHeight, behavior });
5181
+ }, []);
5182
+ useImperativeHandle(
5183
+ ref,
5184
+ () => ({ scrollToBottom, isAtBottom: isNearBottom }),
5185
+ [scrollToBottom, isNearBottom]
5186
+ );
5187
+ useLayoutEffect(() => {
5188
+ if (stickToBottom && isNearBottom()) scrollToBottom("auto");
5189
+ }, [children, stickToBottom, isNearBottom, scrollToBottom]);
5190
+ useEffect(() => {
5191
+ const el = scrollerRef.current;
5192
+ if (!el) return;
5193
+ const onScroll = () => setAtBottom(isNearBottom());
5194
+ el.addEventListener("scroll", onScroll, { passive: true });
5195
+ onScroll();
5196
+ return () => el.removeEventListener("scroll", onScroll);
5197
+ }, [isNearBottom]);
5198
+ return /* @__PURE__ */ jsxs("div", { className: cn("relative flex h-full min-h-0 flex-col", className), ...props, children: [
5199
+ header && /* @__PURE__ */ jsx("div", { className: "shrink-0", children: header }),
5200
+ /* @__PURE__ */ jsx(
5201
+ "div",
5202
+ {
5203
+ ref: scrollerRef,
5204
+ className: "flex-1 min-h-0 overflow-y-auto px-3 py-3",
5205
+ role: "log",
5206
+ "aria-live": "polite",
5207
+ "aria-relevant": "additions",
5208
+ children: /* @__PURE__ */ jsx("div", { className: "flex flex-col gap-2", children })
5209
+ }
5210
+ ),
5211
+ footer && /* @__PURE__ */ jsx("div", { className: "shrink-0 border-t border-border px-3 py-2", children: footer }),
5212
+ showJumpToBottom && !atBottom && /* @__PURE__ */ jsx(
5213
+ "button",
5214
+ {
5215
+ type: "button",
5216
+ onClick: () => scrollToBottom("smooth"),
5217
+ "aria-label": "Jump to latest",
5218
+ className: cn(
5219
+ "absolute bottom-3 right-3 inline-flex h-9 w-9 items-center justify-center rounded-full",
5220
+ "border border-border bg-background text-foreground shadow-md",
5221
+ "hover:bg-muted focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring"
5222
+ ),
5223
+ children: /* @__PURE__ */ jsx(ChevronDown, { className: "h-4 w-4" })
5224
+ }
5225
+ )
5226
+ ] });
5227
+ }
5228
+ );
5229
+ MessageListInner.displayName = "MessageList";
5230
+ var MessageList = MessageListInner;
5231
+ MessageList.DaySeparator = DaySeparator;
5232
+ var ThreadView = forwardRef(
5233
+ ({
5234
+ title = "Thread",
5235
+ subtitle,
5236
+ parent,
5237
+ replyCount,
5238
+ children,
5239
+ composer,
5240
+ onClose,
5241
+ hideCloseButton,
5242
+ className,
5243
+ ...props
5244
+ }, ref) => {
5245
+ const replies = Array.isArray(children) ? children : children == null ? [] : [children];
5246
+ const count = replies.length;
5247
+ return /* @__PURE__ */ jsxs(
5248
+ "div",
5249
+ {
5250
+ ref,
5251
+ role: "complementary",
5252
+ "aria-label": "Thread",
5253
+ className: cn(
5254
+ "flex h-full min-h-0 flex-col rounded-md border border-border bg-card",
5255
+ className
5256
+ ),
5257
+ ...props,
5258
+ children: [
5259
+ /* @__PURE__ */ jsxs("header", { className: "flex items-start justify-between gap-2 border-b border-border px-4 py-3", children: [
5260
+ /* @__PURE__ */ jsxs("div", { className: "min-w-0", children: [
5261
+ /* @__PURE__ */ jsx("div", { className: "text-sm font-semibold text-foreground", children: title }),
5262
+ subtitle && /* @__PURE__ */ jsx("div", { className: "text-xs text-muted-foreground", children: subtitle })
5263
+ ] }),
5264
+ !hideCloseButton && onClose && /* @__PURE__ */ jsx(
5265
+ "button",
5266
+ {
5267
+ type: "button",
5268
+ onClick: onClose,
5269
+ "aria-label": "Close thread",
5270
+ className: "inline-flex h-7 w-7 shrink-0 items-center justify-center rounded-md text-muted-foreground hover:bg-muted hover:text-foreground focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring",
5271
+ children: /* @__PURE__ */ jsx(X, { className: "h-4 w-4" })
5272
+ }
5273
+ )
5274
+ ] }),
5275
+ /* @__PURE__ */ jsxs("div", { className: "flex-1 min-h-0 overflow-y-auto px-4 py-3", children: [
5276
+ /* @__PURE__ */ jsx("div", { children: parent }),
5277
+ replyCount !== null && /* @__PURE__ */ jsxs("div", { className: "my-3 flex items-center gap-3", children: [
5278
+ /* @__PURE__ */ jsx("span", { className: "text-xs text-muted-foreground", children: replyCount ?? (count === 0 ? "No replies yet" : count === 1 ? "1 reply" : `${count} replies`) }),
5279
+ /* @__PURE__ */ jsx("span", { "aria-hidden": "true", className: "h-px flex-1 bg-border" })
5280
+ ] }),
5281
+ /* @__PURE__ */ jsx("div", { className: "flex flex-col gap-2", children })
5282
+ ] }),
5283
+ composer && /* @__PURE__ */ jsx("div", { className: "border-t border-border px-3 py-2", children: composer })
5284
+ ]
5285
+ }
5286
+ );
5287
+ }
5288
+ );
5289
+ ThreadView.displayName = "ThreadView";
5290
+ var CommentThreadInner = forwardRef(
5291
+ ({ children, className, ...props }, ref) => /* @__PURE__ */ jsx(
5292
+ "div",
5293
+ {
5294
+ ref,
5295
+ role: "tree",
5296
+ "aria-label": "Comments",
5297
+ className: cn("flex flex-col gap-3", className),
5298
+ ...props,
5299
+ children
5300
+ }
5301
+ )
5302
+ );
5303
+ CommentThreadInner.displayName = "CommentThread";
5304
+ var Comment = forwardRef(
5305
+ ({
5306
+ avatar,
5307
+ author,
5308
+ timestamp,
5309
+ badge,
5310
+ children,
5311
+ actions,
5312
+ replies,
5313
+ defaultCollapsed = false,
5314
+ highlighted,
5315
+ className,
5316
+ ...props
5317
+ }, ref) => {
5318
+ const [collapsed, setCollapsed] = useState(defaultCollapsed);
5319
+ const replyCount = Children.toArray(replies).filter(isValidElement).length;
5320
+ const hasReplies = replyCount > 0;
5321
+ return /* @__PURE__ */ jsxs(
5322
+ "div",
5323
+ {
5324
+ ref,
5325
+ role: "treeitem",
5326
+ "aria-expanded": hasReplies ? !collapsed : void 0,
5327
+ "data-highlighted": highlighted ? "" : void 0,
5328
+ className: cn(
5329
+ "flex gap-2 rounded-md",
5330
+ highlighted && "bg-primary-soft/30 ring-1 ring-primary/20 p-2",
5331
+ className
5332
+ ),
5333
+ ...props,
5334
+ children: [
5335
+ /* @__PURE__ */ jsxs("div", { className: "flex flex-col items-center gap-1", children: [
5336
+ /* @__PURE__ */ jsx("div", { className: "shrink-0", children: avatar }),
5337
+ hasReplies && /* @__PURE__ */ jsx(
5338
+ "button",
5339
+ {
5340
+ type: "button",
5341
+ onClick: () => setCollapsed((c) => !c),
5342
+ "aria-label": collapsed ? "Expand replies" : "Collapse replies",
5343
+ className: cn(
5344
+ "flex flex-1 items-stretch -my-1 group/rail",
5345
+ "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring rounded-full"
5346
+ ),
5347
+ children: /* @__PURE__ */ jsx(
5348
+ "span",
5349
+ {
5350
+ "aria-hidden": "true",
5351
+ className: cn(
5352
+ "mx-auto w-px flex-1 bg-border transition-colors group-hover/rail:bg-foreground/30",
5353
+ collapsed && "opacity-40"
5354
+ )
5355
+ }
5356
+ )
5357
+ }
5358
+ )
5359
+ ] }),
5360
+ /* @__PURE__ */ jsxs("div", { className: "flex-1 min-w-0", children: [
5361
+ /* @__PURE__ */ jsxs("div", { className: "flex flex-wrap items-baseline gap-x-2 text-sm", children: [
5362
+ /* @__PURE__ */ jsx("span", { className: "font-medium text-foreground", children: author }),
5363
+ badge,
5364
+ timestamp && /* @__PURE__ */ jsx("span", { className: "text-xs text-muted-foreground", children: timestamp })
5365
+ ] }),
5366
+ /* @__PURE__ */ jsx("div", { className: "mt-1 text-sm text-foreground", children }),
5367
+ actions && /* @__PURE__ */ jsx("div", { className: "mt-1 flex items-center gap-2 text-xs text-muted-foreground", children: actions }),
5368
+ hasReplies && /* @__PURE__ */ jsx("div", { className: cn("mt-2", collapsed && "hidden"), children: /* @__PURE__ */ jsx("div", { className: "flex flex-col gap-3 border-l border-border pl-3", children: replies }) }),
5369
+ hasReplies && collapsed && /* @__PURE__ */ jsxs(
5370
+ "button",
5371
+ {
5372
+ type: "button",
5373
+ onClick: () => setCollapsed(false),
5374
+ className: cn(
5375
+ "mt-1 inline-flex items-center gap-1 text-xs text-primary hover:underline",
5376
+ "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring rounded"
5377
+ ),
5378
+ children: [
5379
+ /* @__PURE__ */ jsx(ChevronRight, { className: "h-3 w-3" }),
5380
+ "Show ",
5381
+ replyCount,
5382
+ " ",
5383
+ replyCount === 1 ? "reply" : "replies"
5384
+ ]
5385
+ }
5386
+ ),
5387
+ hasReplies && !collapsed && /* @__PURE__ */ jsxs(
5388
+ "button",
5389
+ {
5390
+ type: "button",
5391
+ onClick: () => setCollapsed(true),
5392
+ className: cn(
5393
+ "mt-1 inline-flex items-center gap-1 text-xs text-muted-foreground hover:text-foreground",
5394
+ "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring rounded"
5395
+ ),
5396
+ children: [
5397
+ /* @__PURE__ */ jsx(ChevronDown, { className: "h-3 w-3" }),
5398
+ "Collapse"
5399
+ ]
5400
+ }
5401
+ )
5402
+ ] })
5403
+ ]
5404
+ }
5405
+ );
5406
+ }
5407
+ );
5408
+ Comment.displayName = "CommentThread.Comment";
5409
+ var CommentThread = CommentThreadInner;
5410
+ CommentThread.Comment = Comment;
5411
+ var ActivityFeedInner = forwardRef(
5412
+ ({ dense, children, className, ...props }, ref) => /* @__PURE__ */ jsx(
5413
+ "ol",
5414
+ {
5415
+ ref,
5416
+ className: cn("flex list-none flex-col", dense ? "gap-3" : "gap-5", className),
5417
+ "data-dense": dense ? "" : void 0,
5418
+ ...props,
5419
+ children
5420
+ }
5421
+ )
5422
+ );
5423
+ ActivityFeedInner.displayName = "ActivityFeed";
5424
+ var ActivityItem = forwardRef(
5425
+ ({ avatar, children, timestamp, preview, actions, last, className, ...props }, ref) => /* @__PURE__ */ jsxs(
5426
+ "li",
5427
+ {
5428
+ ref,
5429
+ className: cn("relative flex gap-3", className),
5430
+ "data-last": last ? "" : void 0,
5431
+ ...props,
5432
+ children: [
5433
+ /* @__PURE__ */ jsxs("div", { className: "relative flex flex-col items-center", children: [
5434
+ /* @__PURE__ */ jsx("div", { className: "z-10 shrink-0", children: avatar }),
5435
+ !last && /* @__PURE__ */ jsx(
5436
+ "span",
5437
+ {
5438
+ "aria-hidden": "true",
5439
+ className: "mt-1 w-px flex-1 bg-border"
5440
+ }
5441
+ )
5442
+ ] }),
5443
+ /* @__PURE__ */ jsxs("div", { className: "min-w-0 flex-1 pb-1", children: [
5444
+ /* @__PURE__ */ jsxs("div", { className: "text-sm leading-relaxed text-foreground", children: [
5445
+ children,
5446
+ timestamp && /* @__PURE__ */ jsx("span", { className: "ml-2 text-xs text-muted-foreground", children: timestamp })
5447
+ ] }),
5448
+ preview && /* @__PURE__ */ jsx("div", { className: "mt-1.5 rounded-md border border-border bg-muted/40 px-3 py-2 text-sm text-muted-foreground", children: preview }),
5449
+ actions && /* @__PURE__ */ jsx("div", { className: "mt-1 flex items-center gap-3 text-xs text-muted-foreground", children: actions })
5450
+ ] })
5451
+ ]
5452
+ }
5453
+ )
5454
+ );
5455
+ ActivityItem.displayName = "ActivityFeed.Item";
5456
+ var ActivityFeed = ActivityFeedInner;
5457
+ ActivityFeed.Item = ActivityItem;
4898
5458
 
4899
- export { Accordion, AccordionContent, AccordionItem, AccordionTrigger, AnimatedNumber, AudioPlayer, AudioWaveform, Avatar, AvatarGroup, Badge, BadgeOverlay, Card, Carousel, CarouselDot, CarouselDots, CarouselNext, CarouselPrev, CarouselSlide, CarouselSlides, CarouselViewport, Code, Collapsible, CollapsibleContent, CollapsibleTrigger, Confetti, CountBadge, CountUp, DataGrid, DataTable, DescriptionList, DiffViewer, EmptyState, EventCalendar, Gantt, GradientText, Heading, HeatmapCalendar, Highlight, Image, InfoRow, KeyboardShortcut, List, ListItem, Mark, Marquee, NodeEditor, NotificationDot, PDFViewer, Quote, ScheduleView, ScrollReveal, SectionHeader, Separator, Snippet, Sparkline, Stat, Status, SwipeActions, Table, TableBody, TableCaption, TableCell, TableFooter, TableHead, TableHeaderCell, TableRow, Tabs, TabsList, TabsPanel, TabsTab, Text, Tilt, Timeline, TimelineDescription, TimelineItem, TimelineTitle, Tooltip, Tree, TreeGroup, TreeItem, Typewriter, VideoPlayer, avatarVariants, badgeVariants, codeVariants, headingVariants, textVariants };
4900
- //# sourceMappingURL=chunk-TK3SXTTF.js.map
4901
- //# sourceMappingURL=chunk-TK3SXTTF.js.map
5459
+ export { Accordion, AccordionContent, AccordionItem, AccordionTrigger, ActivityFeed, ActivityItem, AnimatedNumber, AnnotationMarker, AudioPlayer, AudioWaveform, Avatar, AvatarGroup, Badge, BadgeOverlay, Card, Carousel, CarouselDot, CarouselDots, CarouselNext, CarouselPrev, CarouselSlide, CarouselSlides, CarouselViewport, ChatBubble, Code, Collapsible, CollapsibleContent, CollapsibleTrigger, Comment, CommentThread, Confetti, CountBadge, CountUp, DataGrid, DataTable, DaySeparator, DescriptionList, DiffViewer, EmptyState, EventCalendar, Gantt, GradientText, Heading, HeatmapCalendar, Highlight, Image, InfoRow, KeyboardShortcut, List, ListItem, Mark, Marquee, MessageList, NodeEditor, NotificationDot, PDFViewer, Quote, ReactionBar, ScheduleView, ScrollReveal, SectionHeader, Separator, Snippet, Sparkline, Stat, Status, SwipeActions, Table, TableBody, TableCaption, TableCell, TableFooter, TableHead, TableHeaderCell, TableRow, Tabs, TabsList, TabsPanel, TabsTab, Text, ThreadView, Tilt, Timeline, TimelineDescription, TimelineItem, TimelineTitle, Tooltip, Tree, TreeGroup, TreeItem, Typewriter, VideoPlayer, avatarVariants, badgeVariants, codeVariants, headingVariants, textVariants };
5460
+ //# sourceMappingURL=chunk-U5SWHGKO.js.map
5461
+ //# sourceMappingURL=chunk-U5SWHGKO.js.map