@linktr.ee/messaging-react 3.15.2-rc-1784885341 → 3.15.2

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.
@@ -3,7 +3,7 @@ import j, { createContext as st, useContext as ye, useCallback as W, useState as
3
3
  import { StreamChatService as Gs } from "@linktr.ee/messaging-core";
4
4
  import { StreamChat as Hs, LinkPreviewsManager as Ot } from "stream-chat";
5
5
  import { Chat as Ys, useChannelStateContext as ue, useChatContext as ke, DateSeparator as qs, MessageStatus as Ws, useMessageContext as pe, MessageErrorIcon as Ze, MessageText as Le, areMessageUIPropsEqual as Xs, useMessageReminder as Ks, useComponentContext as es, Attachment as Zs, EditMessageModal as Js, MessageBlocked as Qs, MessageBouncePrompt as en, MessageDeleted as tn, MessageIsThreadReplyInChannelButtonIndicator as sn, MessageRepliesCountButton as nn, ReminderNotification as an, StreamedMessageText as rn, messageHasAttachments as on, messageHasReactions as ln, isDateSeparatorMessage as cn, isMessageBlocked as dn, isMessageBounced as un, MessageBounceModal as mn, Poll as hn, useMessageComposer as fn, useStateStore as gn, MessageInput as Ft, useMessageInputContext as pn, useMessageComposerHasSendableData as bn, AttachmentPreviewList as vn, QuotedMessagePreview as xn, TextareaComposer as wn, MessageTimestamp as Ve, AIStates as Ge, useTypingContext as _n, useAIState as Nn, Channel as yn, WithComponents as kn, Window as Cn, MessageList as Bt, ChannelList as Sn, InfiniteScroll as En } from "stream-chat-react";
6
- import y from "classnames";
6
+ import N from "classnames";
7
7
  import { StarIcon as Je, DotsThreeIcon as In, SpinnerGapIcon as Ae, SignOutIcon as Tn, ProhibitInsetIcon as $t, FlagIcon as ts, CurrencyDollarIcon as Mn, CaretRightIcon as ss, ArrowLeftIcon as An, FileIcon as ns, ImageIcon as Rn, SpeakerHighIcon as Ln, VideoCameraIcon as as, FileMdIcon as Dn, FileTextIcon as Pn, FileZipIcon as zn, FilePptIcon as On, FileCsvIcon as Fn, FileXlsIcon as Bn, FileDocIcon as $n, FilePdfIcon as Un, CircleNotchIcon as _e, PlayIcon as Qe, PauseIcon as jn, LinkIcon as Vn, DownloadSimpleIcon as Ne, XIcon as Be, CaretLeftIcon as Gn, GiftIcon as Hn, ThumbsUpIcon as Yn, ThumbsDownIcon as qn, ChecksIcon as Wn, PencilSimpleIcon as Xn, TrashSimpleIcon as Kn, ArrowUpIcon as Zn, SparkleIcon as Jn, ProhibitIcon as Qn } from "@phosphor-icons/react";
8
8
  import { MessageActions as ea, DefaultDropdownActionButton as rs } from "stream-chat-react/experimental";
9
9
  const is = st({
@@ -25,10 +25,10 @@ const is = st({
25
25
  debug: i = !1,
26
26
  client: l
27
27
  }) => {
28
- var N, M;
28
+ var S, I;
29
29
  const o = W(
30
- (E, ...D) => {
31
- i && console.log(`🔥 [MessagingProvider] ${E}`, ...D);
30
+ (y, ...D) => {
31
+ i && console.log(`🔥 [MessagingProvider] ${y}`, ...D);
32
32
  },
33
33
  [i]
34
34
  );
@@ -38,7 +38,7 @@ const is = st({
38
38
  serviceConfig: !!n,
39
39
  capabilities: Object.keys(r)
40
40
  });
41
- const [d, u] = F(null), [g, m] = F(null), [f, c] = F(!1), [v, w] = F(!1), [p, b] = F(null), x = G(!1), S = G(null), k = G(n);
41
+ const [d, u] = F(null), [g, m] = F(null), [f, c] = F(!1), [v, x] = F(!1), [p, b] = F(null), w = G(!1), E = G(null), k = G(n);
42
42
  k.current = n;
43
43
  const R = G(i);
44
44
  R.current = i;
@@ -47,9 +47,9 @@ const is = st({
47
47
  apiKey: a,
48
48
  serviceConfig: n,
49
49
  capabilities: r
50
- }), O = G(0);
51
- O.current++, o("📊 RENDER INFO", {
52
- renderCount: O.current,
50
+ }), z = G(0);
51
+ z.current++, o("📊 RENDER INFO", {
52
+ renderCount: z.current,
53
53
  currentProps: { userId: t == null ? void 0 : t.id, apiKey: (a == null ? void 0 : a.substring(0, 8)) + "..." },
54
54
  propChanges: {
55
55
  userChanged: A.current.userId !== (t == null ? void 0 : t.id),
@@ -64,36 +64,36 @@ const is = st({
64
64
  capabilities: r
65
65
  };
66
66
  const B = G(null);
67
- !l && a && ((N = B.current) == null ? void 0 : N.apiKey) !== a && (B.current = { apiKey: a, client: new Hs(a) });
68
- const z = l || (a ? ((M = B.current) == null ? void 0 : M.client) ?? null : null);
67
+ !l && a && ((S = B.current) == null ? void 0 : S.apiKey) !== a && (B.current = { apiKey: a, client: new Hs(a) });
68
+ const O = l || (a ? ((I = B.current) == null ? void 0 : I.client) ?? null : null);
69
69
  Y(() => {
70
- const E = O.current, D = k.current;
70
+ const y = z.current, D = k.current;
71
71
  if (l) {
72
- S.current = null, u(null), m(null), c(!1), b(null), w(!1);
72
+ E.current = null, u(null), m(null), c(!1), b(null), x(!1);
73
73
  return;
74
74
  }
75
- if (!a || !z || !D) {
75
+ if (!a || !O || !D) {
76
76
  o("⚠️ SERVICE INIT SKIPPED", {
77
- renderCount: E,
77
+ renderCount: y,
78
78
  reason: "Missing apiKey, client, or serviceConfig"
79
79
  });
80
80
  return;
81
81
  }
82
82
  o("🚀 CREATING SERVICE", {
83
- renderCount: E,
83
+ renderCount: y,
84
84
  apiKey: (a == null ? void 0 : a.substring(0, 8)) + "..."
85
85
  });
86
86
  const H = new Gs({
87
87
  ...D,
88
88
  apiKey: a,
89
89
  debug: R.current,
90
- client: z
90
+ client: O
91
91
  });
92
- S.current = H, u(H), o("✅ SERVICE SET", {
93
- renderCount: E,
92
+ E.current = H, u(H), o("✅ SERVICE SET", {
93
+ renderCount: y,
94
94
  serviceInstance: !!H
95
95
  });
96
- }, [a, z, l]);
96
+ }, [a, O, l]);
97
97
  const L = G(null);
98
98
  Y(() => {
99
99
  var D, H;
@@ -101,7 +101,7 @@ const is = st({
101
101
  hasService: !!d,
102
102
  hasUser: !!t,
103
103
  userId: t == null ? void 0 : t.id,
104
- isConnecting: x.current,
104
+ isConnecting: w.current,
105
105
  isConnected: f,
106
106
  dependencies: { service: !!d, userId: t == null ? void 0 : t.id }
107
107
  }), l)
@@ -110,7 +110,7 @@ const is = st({
110
110
  o("⚠️ USER CONNECTION SKIPPED", "Missing service or user");
111
111
  return;
112
112
  }
113
- if (x.current) {
113
+ if (w.current) {
114
114
  o("⚠️ USER CONNECTION SKIPPED", "Already connecting");
115
115
  return;
116
116
  }
@@ -122,7 +122,7 @@ const is = st({
122
122
  return;
123
123
  }
124
124
  (async () => {
125
- o("🚀 STARTING USER CONNECTION", { userId: t.id }), x.current = !0, w(!0), b(null);
125
+ o("🚀 STARTING USER CONNECTION", { userId: t.id }), w.current = !0, x(!0), b(null);
126
126
  try {
127
127
  o("📞 CALLING SERVICE.CONNECTUSER", { userId: t.id });
128
128
  const q = await d.connectUser(t);
@@ -137,19 +137,19 @@ const is = st({
137
137
  error: K
138
138
  });
139
139
  } finally {
140
- w(!1), x.current = !1, o("🔄 USER CONNECTION FINISHED", {
140
+ x(!1), w.current = !1, o("🔄 USER CONNECTION FINISHED", {
141
141
  userId: t.id,
142
142
  isConnected: f
143
143
  });
144
144
  }
145
145
  })();
146
146
  }, [d, t, o, f, l]), Y(() => {
147
- const E = z;
147
+ const y = O;
148
148
  return () => {
149
149
  var D;
150
- E && (L.current = null, (D = S.current) == null || D.disconnectUser().catch(console.error));
150
+ y && (L.current = null, (D = E.current) == null || D.disconnectUser().catch(console.error));
151
151
  };
152
- }, [z]);
152
+ }, [O]);
153
153
  const C = W(async () => {
154
154
  if (o("🔄 REFRESH CONNECTION CALLED", {
155
155
  hasService: !!d,
@@ -159,22 +159,22 @@ const is = st({
159
159
  o("⚠️ REFRESH CONNECTION SKIPPED", "Missing service or user");
160
160
  return;
161
161
  }
162
- o("🚀 STARTING CONNECTION REFRESH", { userId: t.id }), w(!0);
162
+ o("🚀 STARTING CONNECTION REFRESH", { userId: t.id }), x(!0);
163
163
  try {
164
164
  o("🔌 DISCONNECTING FOR REFRESH"), await d.disconnectUser(), o("📞 RECONNECTING FOR REFRESH");
165
- const E = await d.connectUser(t);
166
- m(E), c(!0), b(null), o("✅ CONNECTION REFRESH SUCCESS", { userId: t.id });
167
- } catch (E) {
168
- const D = E instanceof Error ? E.message : "Refresh failed";
165
+ const y = await d.connectUser(t);
166
+ m(y), c(!0), b(null), o("✅ CONNECTION REFRESH SUCCESS", { userId: t.id });
167
+ } catch (y) {
168
+ const D = y instanceof Error ? y.message : "Refresh failed";
169
169
  b(D), o("❌ CONNECTION REFRESH ERROR", {
170
170
  userId: t.id,
171
171
  error: D
172
172
  });
173
173
  } finally {
174
- w(!1), o("🔄 CONNECTION REFRESH FINISHED", { userId: t.id });
174
+ x(!1), o("🔄 CONNECTION REFRESH FINISHED", { userId: t.id });
175
175
  }
176
176
  }
177
- }, [d, t, o, l]), I = j.useMemo(() => (o("💫 CONTEXT VALUE MEMOIZATION", {
177
+ }, [d, t, o, l]), T = j.useMemo(() => (o("💫 CONTEXT VALUE MEMOIZATION", {
178
178
  hasService: !!d,
179
179
  hasClient: !!g,
180
180
  isConnected: f,
@@ -211,13 +211,13 @@ const is = st({
211
211
  o
212
212
  ]);
213
213
  return o("🔄 RENDER END", {
214
- renderCount: O.current,
215
- willRenderChat: !!z,
216
- contextValueReady: !!I
217
- }), /* @__PURE__ */ s(is.Provider, { value: I, children: z ? /* @__PURE__ */ s(
214
+ renderCount: z.current,
215
+ willRenderChat: !!O,
216
+ contextValueReady: !!T
217
+ }), /* @__PURE__ */ s(is.Provider, { value: T, children: O ? /* @__PURE__ */ s(
218
218
  Ys,
219
219
  {
220
- client: z,
220
+ client: O,
221
221
  customClasses: {
222
222
  channelList: "str-chat__channel-list str-chat__channel-list-react bg-transparent lg:border-r-2 border-r-0 border-[#0000000A]"
223
223
  },
@@ -341,7 +341,7 @@ const be = ({
341
341
  "div",
342
342
  {
343
343
  "aria-hidden": "true",
344
- className: y(
344
+ className: N(
345
345
  "avatar-fallback flex h-full w-full items-center justify-center font-semibold select-none transition-colors"
346
346
  ),
347
347
  style: { fontSize: m, lineHeight: 1 },
@@ -351,7 +351,7 @@ const be = ({
351
351
  return /* @__PURE__ */ h(
352
352
  "div",
353
353
  {
354
- className: y(
354
+ className: N(
355
355
  "relative flex-shrink-0",
356
356
  a
357
357
  ),
@@ -375,7 +375,7 @@ const be = ({
375
375
  "div",
376
376
  {
377
377
  "data-testid": "avatar-ring",
378
- className: y(
378
+ className: N(
379
379
  "h-full w-full",
380
380
  "bg-transparent"
381
381
  ),
@@ -407,56 +407,56 @@ const be = ({
407
407
  onActionComplete: u,
408
408
  logLabel: g = "useChannelModerationActions"
409
409
  }) => {
410
- var I;
411
- const { service: m, debug: f } = nt(), c = (I = t == null ? void 0 : t.user) == null ? void 0 : I.id, v = !!(a && n && m && c), [w, p] = F(!1), [b, x] = F(null), [S, k] = F(!1), [R, A] = F(!1), O = v && ((b == null ? void 0 : b.participantId) !== c || (b == null ? void 0 : b.service) !== m);
410
+ var T;
411
+ const { service: m, debug: f } = nt(), c = (T = t == null ? void 0 : t.user) == null ? void 0 : T.id, v = !!(a && n && m && c), [x, p] = F(!1), [b, w] = F(null), [E, k] = F(!1), [R, A] = F(!1), z = v && ((b == null ? void 0 : b.participantId) !== c || (b == null ? void 0 : b.service) !== m);
412
412
  return Y(() => {
413
413
  if (!v || !m || !c) {
414
- p(!1), x(null);
414
+ p(!1), w(null);
415
415
  return;
416
416
  }
417
- let N = !1;
417
+ let S = !1;
418
418
  return (async () => {
419
419
  try {
420
- const M = await m.getBlockedUsers();
421
- if (N) return;
420
+ const I = await m.getBlockedUsers();
421
+ if (S) return;
422
422
  p(
423
- M.some(
424
- (E) => E.blocked_user_id === c
423
+ I.some(
424
+ (y) => y.blocked_user_id === c
425
425
  )
426
426
  );
427
- } catch (M) {
428
- N || console.error(`[${g}] Failed to check blocked status:`, M);
427
+ } catch (I) {
428
+ S || console.error(`[${g}] Failed to check blocked status:`, I);
429
429
  } finally {
430
- N || x({ participantId: c, service: m });
430
+ S || w({ participantId: c, service: m });
431
431
  }
432
432
  })(), () => {
433
- N = !0;
433
+ S = !0;
434
434
  };
435
435
  }, [v, m, c, g]), {
436
- isParticipantBlocked: w,
437
- isCheckingBlockedStatus: O,
438
- isLeaving: S,
436
+ isParticipantBlocked: x,
437
+ isCheckingBlockedStatus: z,
438
+ isLeaving: E,
439
439
  isUpdatingBlockStatus: R,
440
440
  handleLeaveConversation: async () => {
441
- var N;
442
- if (!S) {
441
+ var S;
442
+ if (!E) {
443
443
  l == null || l(), f && console.log(`[${g}] Leave conversation`, e.cid), k(!0);
444
444
  try {
445
- const M = ((N = e._client) == null ? void 0 : N.userID) ?? null;
446
- await e.hide(M, !1), r && await r(e), u == null || u();
447
- } catch (M) {
448
- console.error(`[${g}] Failed to leave conversation`, M);
445
+ const I = ((S = e._client) == null ? void 0 : S.userID) ?? null;
446
+ await e.hide(I, !1), r && await r(e), u == null || u();
447
+ } catch (I) {
448
+ console.error(`[${g}] Failed to leave conversation`, I);
449
449
  } finally {
450
450
  k(!1);
451
451
  }
452
452
  }
453
453
  },
454
454
  handleBlockUser: async () => {
455
- var N, M, E;
455
+ var S, I, y;
456
456
  if (!(R || !m)) {
457
- o == null || o(), f && console.log(`[${g}] Block member`, (N = t == null ? void 0 : t.user) == null ? void 0 : N.id), A(!0);
457
+ o == null || o(), f && console.log(`[${g}] Block member`, (S = t == null ? void 0 : t.user) == null ? void 0 : S.id), A(!0);
458
458
  try {
459
- await m.blockUser((M = t == null ? void 0 : t.user) == null ? void 0 : M.id), i && await i((E = t == null ? void 0 : t.user) == null ? void 0 : E.id), u == null || u();
459
+ await m.blockUser((I = t == null ? void 0 : t.user) == null ? void 0 : I.id), i && await i((y = t == null ? void 0 : t.user) == null ? void 0 : y.id), u == null || u();
460
460
  } catch (D) {
461
461
  console.error(`[${g}] Failed to block member`, D);
462
462
  } finally {
@@ -465,11 +465,11 @@ const be = ({
465
465
  }
466
466
  },
467
467
  handleUnblockUser: async () => {
468
- var N, M, E;
468
+ var S, I, y;
469
469
  if (!(R || !m)) {
470
- o == null || o(), f && console.log(`[${g}] Unblock member`, (N = t == null ? void 0 : t.user) == null ? void 0 : N.id), A(!0);
470
+ o == null || o(), f && console.log(`[${g}] Unblock member`, (S = t == null ? void 0 : t.user) == null ? void 0 : S.id), A(!0);
471
471
  try {
472
- await m.unBlockUser((M = t == null ? void 0 : t.user) == null ? void 0 : M.id), i && await i((E = t == null ? void 0 : t.user) == null ? void 0 : E.id), u == null || u();
472
+ await m.unBlockUser((I = t == null ? void 0 : t.user) == null ? void 0 : I.id), i && await i((y = t == null ? void 0 : t.user) == null ? void 0 : y.id), u == null || u();
473
473
  } catch (D) {
474
474
  console.error(`[${g}] Failed to unblock member`, D);
475
475
  } finally {
@@ -490,7 +490,7 @@ const be = ({
490
490
  "button",
491
491
  {
492
492
  type: "button",
493
- className: y(
493
+ className: N(
494
494
  "flex w-full items-center gap-3 rounded-lg px-4 py-3 text-left text-sm transition-colors focus-ring disabled:cursor-not-allowed disabled:opacity-60",
495
495
  e === "danger" ? "text-danger hover:bg-danger/50" : "text-charcoal hover:bg-sand",
496
496
  t
@@ -512,14 +512,14 @@ const be = ({
512
512
  customChannelActions: g,
513
513
  triggerClassName: m
514
514
  }) => {
515
- const [f, c] = F(!1), v = G(null), w = js(), p = W(() => c(!1), []), {
515
+ const [f, c] = F(!1), v = G(null), x = js(), p = W(() => c(!1), []), {
516
516
  isParticipantBlocked: b,
517
- isCheckingBlockedStatus: x,
518
- isLeaving: S,
517
+ isCheckingBlockedStatus: w,
518
+ isLeaving: E,
519
519
  isUpdatingBlockStatus: k,
520
520
  handleLeaveConversation: R,
521
521
  handleBlockUser: A,
522
- handleUnblockUser: O,
522
+ handleUnblockUser: z,
523
523
  handleReportUser: B
524
524
  } = da({
525
525
  channel: e,
@@ -536,10 +536,10 @@ const be = ({
536
536
  });
537
537
  return Y(() => {
538
538
  if (!f) return;
539
- const L = (I) => {
540
- v.current && !v.current.contains(I.target) && c(!1);
541
- }, C = (I) => {
542
- I.key === "Escape" && c(!1);
539
+ const L = (T) => {
540
+ v.current && !v.current.contains(T.target) && c(!1);
541
+ }, C = (T) => {
542
+ T.key === "Escape" && c(!1);
543
543
  };
544
544
  return document.addEventListener("mousedown", L), document.addEventListener("keydown", C), () => {
545
545
  document.removeEventListener("mousedown", L), document.removeEventListener("keydown", C);
@@ -552,7 +552,7 @@ const be = ({
552
552
  type: "button",
553
553
  "aria-haspopup": "true",
554
554
  "aria-expanded": f,
555
- "aria-controls": f ? w : void 0,
555
+ "aria-controls": f ? x : void 0,
556
556
  onClick: () => c((L) => !L),
557
557
  children: [
558
558
  /* @__PURE__ */ s(In, { className: "size-5 text-black/90" }),
@@ -563,9 +563,9 @@ const be = ({
563
563
  f && /* @__PURE__ */ s(
564
564
  "div",
565
565
  {
566
- id: w,
566
+ id: x,
567
567
  "aria-label": "Conversation options",
568
- className: y(
568
+ className: N(
569
569
  "absolute right-0 top-full z-50 mt-2 w-56 overflow-hidden",
570
570
  "rounded-lg border border-sand bg-white p-1 shadow-max-elevation-light"
571
571
  ),
@@ -574,15 +574,15 @@ const be = ({
574
574
  ve,
575
575
  {
576
576
  onClick: R,
577
- disabled: S,
578
- "aria-busy": S,
577
+ disabled: E,
578
+ "aria-busy": E,
579
579
  children: [
580
- S ? /* @__PURE__ */ s(Ae, { className: "h-5 w-5 animate-spin" }) : /* @__PURE__ */ s(Tn, { className: "h-5 w-5" }),
580
+ E ? /* @__PURE__ */ s(Ae, { className: "h-5 w-5 animate-spin" }) : /* @__PURE__ */ s(Tn, { className: "h-5 w-5" }),
581
581
  /* @__PURE__ */ s("span", { children: "Delete Conversation" })
582
582
  ]
583
583
  }
584
584
  ) }),
585
- a && /* @__PURE__ */ s("li", { children: x ? (
585
+ a && /* @__PURE__ */ s("li", { children: w ? (
586
586
  // Block status not yet resolved — show a disabled placeholder
587
587
  // so a premature click can't act on a stale block state.
588
588
  /* @__PURE__ */ h(ve, { disabled: !0, "aria-busy": !0, children: [
@@ -592,7 +592,7 @@ const be = ({
592
592
  ) : b ? /* @__PURE__ */ h(
593
593
  ve,
594
594
  {
595
- onClick: O,
595
+ onClick: z,
596
596
  disabled: k,
597
597
  "aria-busy": k,
598
598
  children: [
@@ -637,74 +637,83 @@ const be = ({
637
637
  customChannelActions: f,
638
638
  renderChannelActions: c,
639
639
  showChannelInfo: v = !0,
640
- onParticipantNameClick: w
640
+ onParticipantNameClick: x
641
641
  }) => {
642
- var z, L, C, I;
643
- const { channel: p } = ue(), { client: b } = ke(), x = j.useMemo(
642
+ var C, T, S, I;
643
+ const { channel: p } = ue(), { client: b } = ke(), w = j.useMemo(
644
644
  () => {
645
- var N;
645
+ var y;
646
646
  return ls(
647
- (N = p.state) == null ? void 0 : N.members,
647
+ (y = p.state) == null ? void 0 : y.members,
648
648
  b == null ? void 0 : b.userID,
649
649
  p.type
650
650
  );
651
651
  },
652
- [(z = p.state) == null ? void 0 : z.members, b == null ? void 0 : b.userID, p.type]
653
- ), S = cs(x == null ? void 0 : x.user), k = (L = x == null ? void 0 : x.user) == null ? void 0 : L.image, R = os(p), A = ha((C = p.data) == null ? void 0 : C.customer_tag) && (x == null ? void 0 : x.is_follower) === !0, O = async () => {
652
+ [(C = p.state) == null ? void 0 : C.members, b == null ? void 0 : b.userID, p.type]
653
+ ), E = cs(w == null ? void 0 : w.user), k = (T = w == null ? void 0 : w.user) == null ? void 0 : T.image, R = os(p), A = ha((S = p.data) == null ? void 0 : S.customer_tag) && (w == null ? void 0 : w.is_follower) === !0, z = a && R, B = A || z || !!x, O = async () => {
654
654
  try {
655
655
  R ? await p.unpin() : await p.pin();
656
- } catch (N) {
656
+ } catch (y) {
657
657
  console.error(
658
658
  "[ChannelHeaderRedesign] Failed to update pinned status:",
659
- N
659
+ y
660
660
  );
661
661
  }
662
- }, B = /* @__PURE__ */ h(ee, { children: [
662
+ }, L = /* @__PURE__ */ h(ee, { children: [
663
663
  /* @__PURE__ */ s(
664
664
  be,
665
665
  {
666
- id: ((I = x == null ? void 0 : x.user) == null ? void 0 : I.id) || p.id || "unknown",
667
- name: S,
666
+ id: ((I = w == null ? void 0 : w.user) == null ? void 0 : I.id) || p.id || "unknown",
667
+ name: E,
668
668
  image: k,
669
669
  shape: "circle",
670
670
  size: 48,
671
671
  className: "-mb-2"
672
672
  }
673
673
  ),
674
- /* @__PURE__ */ s("span", { className: "relative z-10 flex max-w-full flex-col items-center justify-center rounded-full border border-white/10 bg-white/65 py-1.5 pl-3 pr-2 shadow-[0px_0px_0px_0px_rgba(0,0,0,0.04),0px_1px_2px_0px_rgba(0,0,0,0.04),0px_8px_32px_0px_rgba(0,0,0,0.1)] backdrop-blur-[2px] transition-filter duration-150 group-hover:brightness-95", children: /* @__PURE__ */ h("span", { className: "flex max-w-full items-center justify-center", children: [
675
- /* @__PURE__ */ s("span", { className: "min-w-0 truncate text-sm font-bold leading-[1.43] tracking-[0.28px] text-black/90", children: S }),
676
- /* @__PURE__ */ h("span", { className: "ml-2 flex gap-1", children: [
677
- A && /* @__PURE__ */ s(
678
- "span",
679
- {
680
- "aria-label": "Paid customer",
681
- className: "flex size-4 shrink-0 items-center justify-center rounded-full bg-[#34C759] text-white",
682
- children: /* @__PURE__ */ s(Mn, { className: "size-2.5", weight: "bold" })
683
- }
684
- ),
685
- a && R && /* @__PURE__ */ s(
686
- "span",
687
- {
688
- "aria-label": "Starred conversation",
689
- className: "flex size-4 shrink-0 items-center justify-center rounded-full bg-[#FFD60A] text-white",
690
- children: /* @__PURE__ */ s(Je, { className: "size-2.5", weight: "fill" })
691
- }
674
+ /* @__PURE__ */ s(
675
+ "span",
676
+ {
677
+ className: N(
678
+ "relative z-10 flex max-w-full flex-col items-center justify-center rounded-full border border-white/10 bg-white/65 py-1.5 shadow-[0px_0px_0px_0px_rgba(0,0,0,0.04),0px_1px_2px_0px_rgba(0,0,0,0.04),0px_8px_32px_0px_rgba(0,0,0,0.1)] backdrop-blur-[2px] transition-filter duration-150 group-hover:brightness-95",
679
+ B ? "pl-3 pr-2" : "px-3"
692
680
  ),
693
- w && /* @__PURE__ */ s(
694
- ss,
695
- {
696
- "aria-hidden": "true",
697
- className: "size-4 shrink-0 text-black/65",
698
- weight: "bold"
699
- }
700
- )
701
- ] })
702
- ] }) })
681
+ children: /* @__PURE__ */ h("span", { className: "flex max-w-full items-center justify-center", children: [
682
+ /* @__PURE__ */ s("span", { className: "min-w-0 truncate text-sm font-bold leading-[1.43] tracking-[0.28px] text-black/90", children: E }),
683
+ B && /* @__PURE__ */ h("span", { className: "ml-2 flex gap-1", children: [
684
+ A && /* @__PURE__ */ s(
685
+ "span",
686
+ {
687
+ "aria-label": "Paid customer",
688
+ className: "flex size-4 shrink-0 items-center justify-center rounded-full bg-[#34C759] text-white",
689
+ children: /* @__PURE__ */ s(Mn, { className: "size-2.5", weight: "bold" })
690
+ }
691
+ ),
692
+ z && /* @__PURE__ */ s(
693
+ "span",
694
+ {
695
+ "aria-label": "Starred conversation",
696
+ className: "flex size-4 shrink-0 items-center justify-center rounded-full bg-[#FFD60A] text-white",
697
+ children: /* @__PURE__ */ s(Je, { className: "size-2.5", weight: "fill" })
698
+ }
699
+ ),
700
+ x && /* @__PURE__ */ s(
701
+ ss,
702
+ {
703
+ "aria-hidden": "true",
704
+ className: "size-4 shrink-0 text-black/65",
705
+ weight: "bold"
706
+ }
707
+ )
708
+ ] })
709
+ ] })
710
+ }
711
+ )
703
712
  ] });
704
713
  return /* @__PURE__ */ s(
705
714
  "div",
706
715
  {
707
- className: y(
716
+ className: N(
708
717
  "@container bg-[linear-gradient(180deg,#FBFAF9_0%,rgba(251,250,249,0.92)_58%,rgba(251,250,249,0)_100%)]",
709
718
  e
710
719
  ),
@@ -712,7 +721,7 @@ const be = ({
712
721
  /* @__PURE__ */ s("div", { className: "flex items-start", children: n && /* @__PURE__ */ s(
713
722
  "button",
714
723
  {
715
- className: y(
724
+ className: N(
716
725
  He,
717
726
  "messaging-channel-view-back-button-mobile messaging-channel-view-back-button-desktop"
718
727
  ),
@@ -723,16 +732,16 @@ const be = ({
723
732
  children: /* @__PURE__ */ s(An, { className: "size-5 text-black/90" })
724
733
  }
725
734
  ) }),
726
- /* @__PURE__ */ s("div", { className: "flex min-w-0 justify-center", "data-dd-privacy": "mask", children: w ? /* @__PURE__ */ s(
735
+ /* @__PURE__ */ s("div", { className: "flex min-w-0 justify-center", "data-dd-privacy": "mask", children: x ? /* @__PURE__ */ s(
727
736
  "button",
728
737
  {
729
738
  type: "button",
730
- onClick: w,
731
- "aria-label": `View details for ${S}`,
739
+ onClick: x,
740
+ "aria-label": `View details for ${E}`,
732
741
  className: "group flex min-w-0 max-w-full appearance-none flex-col items-center border-0 bg-transparent px-2 focus-ring focus-visible:outline-none",
733
- children: B
742
+ children: L
734
743
  }
735
- ) : /* @__PURE__ */ s("div", { className: "flex min-w-0 max-w-full flex-col items-center px-2", children: B }) }),
744
+ ) : /* @__PURE__ */ s("div", { className: "flex min-w-0 max-w-full flex-col items-center px-2", children: L }) }),
736
745
  /* @__PURE__ */ h("div", { className: "flex items-start justify-end gap-2", children: [
737
746
  a && /* @__PURE__ */ s(
738
747
  "button",
@@ -745,7 +754,7 @@ const be = ({
745
754
  children: /* @__PURE__ */ s(
746
755
  Je,
747
756
  {
748
- className: y("size-5", {
757
+ className: N("size-5", {
749
758
  "text-[#FFD60A]": R,
750
759
  "text-black/90": !R
751
760
  }),
@@ -758,7 +767,7 @@ const be = ({
758
767
  ua,
759
768
  {
760
769
  channel: p,
761
- participant: x,
770
+ participant: w,
762
771
  showDeleteConversation: l,
763
772
  showBlockParticipant: o,
764
773
  showReportParticipant: d,
@@ -895,53 +904,53 @@ const Sa = (e) => {
895
904
  muted: d = !1,
896
905
  onContainerClick: u
897
906
  }) => {
898
- const g = oe(t), m = G(null), f = G(null), c = G(null), v = G(r), [w, p] = F(a), [b, x] = F(0), [S, k] = F(!1), [R, A] = F(!1), [O, B] = F(!1), [z, L] = F(!1), [C, I] = F(!0), [N, M] = F(null), E = W(() => {
907
+ const g = oe(t), m = G(null), f = G(null), c = G(null), v = G(r), [x, p] = F(a), [b, w] = F(0), [E, k] = F(!1), [R, A] = F(!1), [z, B] = F(!1), [O, L] = F(!1), [C, T] = F(!0), [S, I] = F(null), y = W(() => {
899
908
  B(!1), p(!0);
900
909
  }, []), D = W((_) => {
901
- const T = f.current;
902
- if (!T) return 0;
903
- const $ = T.getBoundingClientRect();
910
+ const M = f.current;
911
+ if (!M) return 0;
912
+ const $ = M.getBoundingClientRect();
904
913
  return Math.max(
905
914
  0,
906
915
  Math.min(1, (Sa(_) - $.left) / $.width)
907
916
  );
908
917
  }, []), H = W((_) => {
909
- const T = m.current;
910
- T && T.duration && (T.currentTime = _ * T.duration);
918
+ const M = m.current;
919
+ M && M.duration && (M.currentTime = _ * M.duration);
911
920
  }, []), q = (_) => {
912
921
  _.stopPropagation(), k(!0);
913
- const T = D(_);
914
- x(T), H(T);
922
+ const M = D(_);
923
+ w(M), H(M);
915
924
  };
916
925
  Y(() => {
917
926
  r !== void 0 && r !== v.current && (v.current = r, p(r));
918
927
  }, [r]), Y(() => {
919
- if (!w) {
928
+ if (!x) {
920
929
  c.current !== null && (cancelAnimationFrame(c.current), c.current = null);
921
930
  return;
922
931
  }
923
932
  const _ = () => {
924
- const T = m.current;
925
- T && T.duration && !S && x(T.currentTime / T.duration), c.current = requestAnimationFrame(_);
933
+ const M = m.current;
934
+ M && M.duration && !E && w(M.currentTime / M.duration), c.current = requestAnimationFrame(_);
926
935
  };
927
936
  return c.current = requestAnimationFrame(_), () => {
928
937
  c.current !== null && cancelAnimationFrame(c.current);
929
938
  };
930
- }, [w, S]), Y(() => {
939
+ }, [x, E]), Y(() => {
931
940
  const _ = m.current;
932
- _ && (w ? _.play().catch((T) => {
941
+ _ && (x ? _.play().catch((M) => {
933
942
  p(!1), B(!0);
934
943
  }) : _.pause());
935
- }, [w]), Y(() => {
936
- if (!S) return;
937
- const _ = ($) => x(D($)), T = ($) => {
944
+ }, [x]), Y(() => {
945
+ if (!E) return;
946
+ const _ = ($) => w(D($)), M = ($) => {
938
947
  k(!1), H(D($));
939
948
  };
940
- return window.addEventListener("mousemove", _), window.addEventListener("mouseup", T), window.addEventListener("touchmove", _, { passive: !0 }), window.addEventListener("touchend", T), () => {
941
- window.removeEventListener("mousemove", _), window.removeEventListener("mouseup", T), window.removeEventListener("touchmove", _), window.removeEventListener("touchend", T);
949
+ return window.addEventListener("mousemove", _), window.addEventListener("mouseup", M), window.addEventListener("touchmove", _, { passive: !0 }), window.addEventListener("touchend", M), () => {
950
+ window.removeEventListener("mousemove", _), window.removeEventListener("mouseup", M), window.removeEventListener("touchmove", _), window.removeEventListener("touchend", M);
942
951
  };
943
- }, [S, D, H]);
944
- const K = N ? { aspectRatio: String(N) } : void 0, Z = N ? "" : " aspect-video", V = Math.round(b * 100);
952
+ }, [E, D, H]);
953
+ const K = S ? { aspectRatio: String(S) } : void 0, Z = S ? "" : " aspect-video", V = Math.round(b * 100);
945
954
  return /* @__PURE__ */ h(
946
955
  "div",
947
956
  {
@@ -954,7 +963,7 @@ const Sa = (e) => {
954
963
  u(_);
955
964
  return;
956
965
  }
957
- O || l && p((T) => !T);
966
+ z || l && p((M) => !M);
958
967
  },
959
968
  onKeyDown: (_) => {
960
969
  if (!(_.key !== "Enter" && _.key !== " ")) {
@@ -962,7 +971,7 @@ const Sa = (e) => {
962
971
  u(_);
963
972
  return;
964
973
  }
965
- O || l && p((T) => !T);
974
+ z || l && p((M) => !M);
966
975
  }
967
976
  },
968
977
  children: [
@@ -988,12 +997,12 @@ const Sa = (e) => {
988
997
  style: { width: "100%", height: "100%" },
989
998
  onLoadStart: () => L(!0),
990
999
  onCanPlay: () => {
991
- L(!1), I(!1);
1000
+ L(!1), T(!1);
992
1001
  },
993
1002
  onWaiting: () => L(!0),
994
1003
  onPlay: () => B(!1),
995
1004
  onEnded: () => {
996
- i || (p(!1), x(0));
1005
+ i || (p(!1), w(0));
997
1006
  },
998
1007
  children: /* @__PURE__ */ s("track", { kind: "captions" })
999
1008
  }
@@ -1008,28 +1017,28 @@ const Sa = (e) => {
1008
1017
  style: { width: "100%", height: "100%" },
1009
1018
  onLoadStart: () => L(!0),
1010
1019
  onCanPlay: () => {
1011
- L(!1), I(!1);
1020
+ L(!1), T(!1);
1012
1021
  },
1013
1022
  onWaiting: () => L(!0),
1014
1023
  onPlay: () => B(!1),
1015
1024
  onLoadedMetadata: () => {
1016
1025
  const _ = m.current;
1017
- _ instanceof HTMLVideoElement && _.videoWidth && _.videoHeight && M(_.videoWidth / _.videoHeight);
1026
+ _ instanceof HTMLVideoElement && _.videoWidth && _.videoHeight && I(_.videoWidth / _.videoHeight);
1018
1027
  },
1019
1028
  onEnded: () => {
1020
- i || (p(!1), x(0));
1029
+ i || (p(!1), w(0));
1021
1030
  },
1022
1031
  children: /* @__PURE__ */ s("track", { kind: "captions" })
1023
1032
  }
1024
1033
  ) }),
1025
- z && !O && /* @__PURE__ */ s("div", { className: "absolute inset-0 z-10 flex items-center justify-center", children: /* @__PURE__ */ s(
1034
+ O && !z && /* @__PURE__ */ s("div", { className: "absolute inset-0 z-10 flex items-center justify-center", children: /* @__PURE__ */ s(
1026
1035
  _e,
1027
1036
  {
1028
1037
  className: "size-8 animate-spin text-white/80",
1029
1038
  weight: "bold"
1030
1039
  }
1031
1040
  ) }),
1032
- O && !l && /* @__PURE__ */ s(
1041
+ z && !l && /* @__PURE__ */ s(
1033
1042
  "div",
1034
1043
  {
1035
1044
  className: "absolute inset-0 z-30 flex cursor-pointer items-center justify-center bg-black/35",
@@ -1037,10 +1046,10 @@ const Sa = (e) => {
1037
1046
  tabIndex: 0,
1038
1047
  "aria-label": "Play preview",
1039
1048
  onClick: (_) => {
1040
- _.stopPropagation(), E();
1049
+ _.stopPropagation(), y();
1041
1050
  },
1042
1051
  onKeyDown: (_) => {
1043
- _.key !== "Enter" && _.key !== " " || (_.preventDefault(), _.stopPropagation(), E());
1052
+ _.key !== "Enter" && _.key !== " " || (_.preventDefault(), _.stopPropagation(), y());
1044
1053
  },
1045
1054
  children: /* @__PURE__ */ s("span", { className: "flex size-16 items-center justify-center rounded-full bg-white/20 text-white backdrop-blur-sm", children: /* @__PURE__ */ s(Qe, { className: "size-9 translate-x-0.5", weight: "fill" }) })
1046
1055
  }
@@ -1077,11 +1086,11 @@ const Sa = (e) => {
1077
1086
  {
1078
1087
  type: "button",
1079
1088
  onClick: (_) => {
1080
- _.stopPropagation(), p((T) => !T);
1089
+ _.stopPropagation(), p((M) => !M);
1081
1090
  },
1082
1091
  className: "shrink-0 text-white",
1083
- "aria-label": w ? "Pause" : "Play",
1084
- children: w ? /* @__PURE__ */ s(jn, { className: "size-5", weight: "fill" }) : /* @__PURE__ */ s(Qe, { className: "size-5 translate-x-px", weight: "fill" })
1092
+ "aria-label": x ? "Pause" : "Play",
1093
+ children: x ? /* @__PURE__ */ s(jn, { className: "size-5", weight: "fill" }) : /* @__PURE__ */ s(Qe, { className: "size-5 translate-x-px", weight: "fill" })
1085
1094
  }
1086
1095
  ),
1087
1096
  /* @__PURE__ */ h(
@@ -1107,7 +1116,7 @@ const Sa = (e) => {
1107
1116
  /* @__PURE__ */ s(
1108
1117
  "div",
1109
1118
  {
1110
- className: `w-full overflow-hidden rounded-full bg-white/30 transition-all duration-200 ${R || S ? "h-1.5" : "h-1"}`,
1119
+ className: `w-full overflow-hidden rounded-full bg-white/30 transition-all duration-200 ${R || E ? "h-1.5" : "h-1"}`,
1111
1120
  children: /* @__PURE__ */ s(
1112
1121
  "div",
1113
1122
  {
@@ -1120,7 +1129,7 @@ const Sa = (e) => {
1120
1129
  /* @__PURE__ */ s(
1121
1130
  "div",
1122
1131
  {
1123
- className: `absolute size-3 -translate-x-1/2 rounded-full bg-white shadow transition-[opacity,transform] duration-200 ${R || S ? "scale-100 opacity-100" : "scale-0 opacity-0"}`,
1132
+ className: `absolute size-3 -translate-x-1/2 rounded-full bg-white shadow transition-[opacity,transform] duration-200 ${R || E ? "scale-100 opacity-100" : "scale-0 opacity-0"}`,
1124
1133
  style: { left: `${V}%` }
1125
1134
  }
1126
1135
  )
@@ -1231,7 +1240,7 @@ const Sa = (e) => {
1231
1240
  {
1232
1241
  ref: g,
1233
1242
  "data-testid": m,
1234
- className: y(
1243
+ className: N(
1235
1244
  "relative w-[280px] select-none overflow-hidden rounded-[24px] shadow-[0_0_0_1px_rgba(0,0,0,0.04),0_4px_8px_rgba(0,0,0,0.06)]",
1236
1245
  f ? "bg-[#1e2330]" : "bg-white"
1237
1246
  ),
@@ -1243,7 +1252,7 @@ const Sa = (e) => {
1243
1252
  c.trim() !== "" && /* @__PURE__ */ s(
1244
1253
  "p",
1245
1254
  {
1246
- className: y("mb-0.5 truncate text-base font-medium", {
1255
+ className: N("mb-0.5 truncate text-base font-medium", {
1247
1256
  "text-black": !f,
1248
1257
  "text-white/30": f && v,
1249
1258
  "text-white": f && !v
@@ -1253,7 +1262,7 @@ const Sa = (e) => {
1253
1262
  ),
1254
1263
  /* @__PURE__ */ h("div", { className: "flex flex-wrap items-center gap-1", children: [
1255
1264
  ge(r, {
1256
- className: y(
1265
+ className: N(
1257
1266
  "size-5 shrink-0",
1258
1267
  f ? "text-white/55" : "text-black/55"
1259
1268
  ),
@@ -1262,7 +1271,7 @@ const Sa = (e) => {
1262
1271
  i != null && i !== "" && /* @__PURE__ */ s(
1263
1272
  "span",
1264
1273
  {
1265
- className: y(
1274
+ className: N(
1266
1275
  "text-xs font-medium",
1267
1276
  f ? "text-white/55" : "text-black/55"
1268
1277
  ),
@@ -1371,13 +1380,13 @@ const Pa = ({
1371
1380
  function ot(e) {
1372
1381
  var m, f, c, v;
1373
1382
  const t = (m = e.attachments) == null ? void 0 : m.find(
1374
- (w) => w.type === "video" && w.asset_url
1383
+ (x) => x.type === "video" && x.asset_url
1375
1384
  ), n = (f = e.attachments) == null ? void 0 : f.find(
1376
- (w) => w.type === "image" && w.image_url
1385
+ (x) => x.type === "image" && x.image_url
1377
1386
  ), a = (c = e.attachments) == null ? void 0 : c.find(
1378
- (w) => w.type === "audio" && w.asset_url
1387
+ (x) => x.type === "audio" && x.asset_url
1379
1388
  ), r = (v = e.attachments) == null ? void 0 : v.find(
1380
- (w) => w.type === "file" && w.asset_url
1389
+ (x) => x.type === "file" && x.asset_url
1381
1390
  ), i = t ?? n ?? a ?? r, l = (t == null ? void 0 : t.asset_url) ?? (n == null ? void 0 : n.image_url) ?? (a == null ? void 0 : a.asset_url) ?? (r == null ? void 0 : r.asset_url);
1382
1391
  if (!l) return null;
1383
1392
  const o = (i == null ? void 0 : i.mime_type) ?? ((i == null ? void 0 : i.type) === "image" ? "image/jpeg" : (i == null ? void 0 : i.type) === "video" ? "video/mp4" : (i == null ? void 0 : i.type) === "audio" ? "audio/mpeg" : "application/octet-stream"), d = i == null ? void 0 : i.title, u = i == null ? void 0 : i.file_size, g = t == null ? void 0 : t.thumb_url;
@@ -1534,7 +1543,7 @@ const bs = ({
1534
1543
  {
1535
1544
  "data-testid": l,
1536
1545
  "data-group-position": a,
1537
- className: y(
1546
+ className: N(
1538
1547
  // 280px-wide bubble — matches the mobile chat attachment width
1539
1548
  // and keeps the document / image / audio bubbles visually
1540
1549
  // consistent inside the conversation timeline. The 8px / 16px
@@ -1554,7 +1563,7 @@ const bs = ({
1554
1563
  o ? /* @__PURE__ */ s(
1555
1564
  "p",
1556
1565
  {
1557
- className: y(
1566
+ className: N(
1558
1567
  // No `text-*` / `font-*` overrides here — caption inherits
1559
1568
  // the same font family + size as `.str-chat__message-text`
1560
1569
  // so it matches the surrounding `CustomMessage` bubbles.
@@ -1583,7 +1592,7 @@ const bs = ({
1583
1592
  a.stopPropagation(), e();
1584
1593
  },
1585
1594
  "aria-label": n,
1586
- className: y(
1595
+ className: N(
1587
1596
  "flex size-6 items-center justify-center rounded-full text-white",
1588
1597
  t === "overlay" ? "bg-[#121110]/85 backdrop-blur" : "bg-white/15 hover:bg-white/25"
1589
1598
  ),
@@ -1717,13 +1726,13 @@ const tr = {
1717
1726
  const d = n ?? t ?? "File", u = er(a, t, r), g = /* @__PURE__ */ s(
1718
1727
  "div",
1719
1728
  {
1720
- className: y(
1729
+ className: N(
1721
1730
  "flex size-10 shrink-0 items-center justify-center rounded-sm",
1722
1731
  sr[e]
1723
1732
  ),
1724
1733
  "aria-hidden": !0,
1725
1734
  children: ge(a, {
1726
- className: y("size-6", nr[e]),
1735
+ className: N("size-6", nr[e]),
1727
1736
  weight: "regular"
1728
1737
  })
1729
1738
  }
@@ -1732,7 +1741,7 @@ const tr = {
1732
1741
  u ? /* @__PURE__ */ s(
1733
1742
  "p",
1734
1743
  {
1735
- className: y(
1744
+ className: N(
1736
1745
  "truncate text-xs leading-4",
1737
1746
  tr[e]
1738
1747
  ),
@@ -1745,7 +1754,7 @@ const tr = {
1745
1754
  type: "button",
1746
1755
  onClick: i,
1747
1756
  "aria-label": l,
1748
- className: y(
1757
+ className: N(
1749
1758
  "flex min-w-0 flex-1 items-center gap-3 rounded-sm text-left transition-colors",
1750
1759
  e === "dark" ? "hover:bg-white/[0.04]" : "hover:bg-black/[0.04]"
1751
1760
  ),
@@ -1829,15 +1838,15 @@ const ar = ({
1829
1838
  if ((u == null ? void 0 : u(p)) === !1) return;
1830
1839
  const b = c[p];
1831
1840
  if (!b) return;
1832
- const x = b.filename ?? ne(b.src);
1833
- ws(b.src, x);
1841
+ const w = b.filename ?? ne(b.src);
1842
+ ws(b.src, w);
1834
1843
  };
1835
1844
  if (c.length === 0)
1836
1845
  return null;
1837
- const w = /* @__PURE__ */ s(
1846
+ const x = /* @__PURE__ */ s(
1838
1847
  "span",
1839
1848
  {
1840
- className: y(
1849
+ className: N(
1841
1850
  "flex size-8 items-center justify-center rounded-full",
1842
1851
  m === "dark" ? "text-white/70" : "text-black/70"
1843
1852
  ),
@@ -1859,7 +1868,7 @@ const ar = ({
1859
1868
  item: p,
1860
1869
  index: b,
1861
1870
  onActivate: v,
1862
- trailingAction: f && b === 0 ? /* @__PURE__ */ s(Se, { onClick: g, variant: "inline" }) : w
1871
+ trailingAction: f && b === 0 ? /* @__PURE__ */ s(Se, { onClick: g, variant: "inline" }) : x
1863
1872
  },
1864
1873
  `${p.src}-${b}`
1865
1874
  )) })
@@ -1912,7 +1921,7 @@ const ar = ({
1912
1921
  }));
1913
1922
  },
1914
1923
  [o, e, t, l]
1915
- ), g = r ?? n !== "pill", f = { className: y(
1924
+ ), g = r ?? n !== "pill", f = { className: N(
1916
1925
  n === "pill" ? "size-4" : "size-5",
1917
1926
  "shrink-0"
1918
1927
  ), weight: "bold" };
@@ -1923,7 +1932,7 @@ const ar = ({
1923
1932
  onClick: u,
1924
1933
  disabled: o,
1925
1934
  "aria-label": a,
1926
- className: y(
1935
+ className: N(
1927
1936
  "flex size-8 shrink-0 items-center justify-center rounded-full transition-colors disabled:opacity-70",
1928
1937
  {
1929
1938
  dark: "text-white/70 hover:bg-white/[0.08] hover:text-white",
@@ -1963,7 +1972,7 @@ const ar = ({
1963
1972
  onClick: u,
1964
1973
  disabled: o,
1965
1974
  "aria-label": g ? a : void 0,
1966
- className: y(
1975
+ className: N(
1967
1976
  "mt-3 inline-flex h-10 w-full items-center justify-center gap-2 rounded-full px-4 text-sm font-medium leading-none transition-colors disabled:opacity-70",
1968
1977
  i === "dark" ? "bg-[#121110] text-white hover:bg-[#2a2928]" : "bg-white text-[#121110] hover:bg-white/90"
1969
1978
  ),
@@ -2160,14 +2169,14 @@ const ar = ({
2160
2169
  const r = e.length;
2161
2170
  if (r === 0) return null;
2162
2171
  const i = e.slice(0, Math.min(r, n)), l = r - i.length, o = (d, u, g) => {
2163
- const m = y(dr, "h-full w-full");
2172
+ const m = N(dr, "h-full w-full");
2164
2173
  return t ? /* @__PURE__ */ h(
2165
2174
  "button",
2166
2175
  {
2167
2176
  type: "button",
2168
2177
  onClick: () => t(u),
2169
2178
  "aria-label": d.ariaLabel ?? `Open media ${u + 1}`,
2170
- className: y(m, "cursor-zoom-in"),
2179
+ className: N(m, "cursor-zoom-in"),
2171
2180
  children: [
2172
2181
  d.content,
2173
2182
  g
@@ -2179,10 +2188,10 @@ const ar = ({
2179
2188
  g
2180
2189
  ] }, u);
2181
2190
  };
2182
- return i.length === 1 ? /* @__PURE__ */ s("div", { className: y("aspect-square w-full", a), children: o(i[0], 0) }) : i.length === 2 ? /* @__PURE__ */ s(
2191
+ return i.length === 1 ? /* @__PURE__ */ s("div", { className: N("aspect-square w-full", a), children: o(i[0], 0) }) : i.length === 2 ? /* @__PURE__ */ s(
2183
2192
  "div",
2184
2193
  {
2185
- className: y(
2194
+ className: N(
2186
2195
  "grid aspect-[16/9] w-full grid-cols-2 gap-0.5",
2187
2196
  a
2188
2197
  ),
@@ -2191,7 +2200,7 @@ const ar = ({
2191
2200
  ) : i.length === 3 ? /* @__PURE__ */ h(
2192
2201
  "div",
2193
2202
  {
2194
- className: y(
2203
+ className: N(
2195
2204
  "grid aspect-[4/3] w-full grid-cols-2 grid-rows-2 gap-0.5",
2196
2205
  a
2197
2206
  ),
@@ -2204,7 +2213,7 @@ const ar = ({
2204
2213
  ) : /* @__PURE__ */ s(
2205
2214
  "div",
2206
2215
  {
2207
- className: y(
2216
+ className: N(
2208
2217
  "grid aspect-[4/3] w-full grid-cols-2 grid-rows-2 gap-0.5",
2209
2218
  a
2210
2219
  ),
@@ -2304,7 +2313,7 @@ const ar = ({
2304
2313
  );
2305
2314
  if (u.length === 0)
2306
2315
  return null;
2307
- const w = u.map(
2316
+ const x = u.map(
2308
2317
  (p, b) => ur(p, b, u.length, o)
2309
2318
  );
2310
2319
  return /* @__PURE__ */ h(
@@ -2315,7 +2324,7 @@ const ar = ({
2315
2324
  groupPosition: l,
2316
2325
  "data-testid": "image-attachment",
2317
2326
  children: [
2318
- /* @__PURE__ */ s("div", { className: "relative", children: /* @__PURE__ */ s(ys, { tiles: w, onTileActivate: c }) }),
2327
+ /* @__PURE__ */ s("div", { className: "relative", children: /* @__PURE__ */ s(ys, { tiles: x, onTileActivate: c }) }),
2319
2328
  /* @__PURE__ */ s(
2320
2329
  Ns,
2321
2330
  {
@@ -2422,14 +2431,14 @@ const ar = ({
2422
2431
  onClick: d,
2423
2432
  onDismiss: u
2424
2433
  }) => {
2425
- const g = Ee(e), m = wr({ src: t, filename: n, fileSize: a, title: r, items: i }), { viewerOpen: f, viewerIndex: c, handleActivate: v, closeViewer: w } = Ie(
2434
+ const g = Ee(e), m = wr({ src: t, filename: n, fileSize: a, title: r, items: i }), { viewerOpen: f, viewerIndex: c, handleActivate: v, closeViewer: x } = Ie(
2426
2435
  d
2427
2436
  ), p = e === "composer" && !!u;
2428
2437
  if (m.length === 0)
2429
2438
  return null;
2430
- const b = m.map((x) => ({
2431
- src: x.src,
2432
- filename: x.filename ?? ne(x.src)
2439
+ const b = m.map((w) => ({
2440
+ src: w.src,
2441
+ filename: w.filename ?? ne(w.src)
2433
2442
  }));
2434
2443
  return /* @__PURE__ */ h(
2435
2444
  Ce,
@@ -2439,11 +2448,11 @@ const ar = ({
2439
2448
  groupPosition: o,
2440
2449
  "data-testid": "pdf-attachment",
2441
2450
  children: [
2442
- /* @__PURE__ */ s("div", { className: "flex flex-col gap-2", children: m.map((x, S) => {
2443
- const k = x.filename ?? ne(x.src), R = p && S === 0 ? /* @__PURE__ */ s(Se, { onClick: u, variant: "inline" }) : e === "composer" ? void 0 : /* @__PURE__ */ s(
2451
+ /* @__PURE__ */ s("div", { className: "flex flex-col gap-2", children: m.map((w, E) => {
2452
+ const k = w.filename ?? ne(w.src), R = p && E === 0 ? /* @__PURE__ */ s(Se, { onClick: u, variant: "inline" }) : e === "composer" ? void 0 : /* @__PURE__ */ s(
2444
2453
  _s,
2445
2454
  {
2446
- url: x.src,
2455
+ url: w.src,
2447
2456
  filename: k,
2448
2457
  variant: "inline",
2449
2458
  label: `Download ${k}`,
@@ -2454,12 +2463,12 @@ const ar = ({
2454
2463
  _r,
2455
2464
  {
2456
2465
  variant: g,
2457
- item: x,
2458
- index: S,
2466
+ item: w,
2467
+ index: E,
2459
2468
  onActivate: v,
2460
2469
  trailingAction: R
2461
2470
  },
2462
- `${x.src}-${S}`
2471
+ `${w.src}-${E}`
2463
2472
  );
2464
2473
  }) }),
2465
2474
  /* @__PURE__ */ s(
@@ -2468,7 +2477,7 @@ const ar = ({
2468
2477
  open: f,
2469
2478
  items: b,
2470
2479
  initialIndex: c,
2471
- onClose: w
2480
+ onClose: x
2472
2481
  }
2473
2482
  )
2474
2483
  ]
@@ -2607,13 +2616,13 @@ const ar = ({
2607
2616
  preload: d,
2608
2617
  onClick: u
2609
2618
  }) => {
2610
- const g = Ir({ src: t, poster: n, mimeType: a, preload: d, items: i }), m = Ee(e), { viewerOpen: f, viewerIndex: c, handleActivate: v, closeViewer: w } = Ie(
2619
+ const g = Ir({ src: t, poster: n, mimeType: a, preload: d, items: i }), m = Ee(e), { viewerOpen: f, viewerIndex: c, handleActivate: v, closeViewer: x } = Ie(
2611
2620
  u
2612
2621
  );
2613
2622
  if (g.length === 0)
2614
2623
  return null;
2615
2624
  const p = g.map(
2616
- (b, x) => Er(b, x, g.length)
2625
+ (b, w) => Er(b, w, g.length)
2617
2626
  );
2618
2627
  return /* @__PURE__ */ h(
2619
2628
  Ce,
@@ -2637,7 +2646,7 @@ const ar = ({
2637
2646
  open: f,
2638
2647
  items: Is(g, r),
2639
2648
  initialIndex: c,
2640
- onClose: w
2649
+ onClose: x
2641
2650
  }
2642
2651
  )
2643
2652
  ]
@@ -2661,7 +2670,7 @@ const ar = ({
2661
2670
  function zr(e) {
2662
2671
  return ye(Ms)[e] ?? Pr[e];
2663
2672
  }
2664
- const Or = j.lazy(() => import("./Card-qS17qnN0.js")), Fr = j.lazy(() => import("./Card-opmIFszT.js")), Br = () => /* @__PURE__ */ s(
2673
+ const Or = j.lazy(() => import("./Card-qS17qnN0.js")), Fr = j.lazy(() => import("./Card-CL8BkAA9.js")), Br = () => /* @__PURE__ */ s(
2665
2674
  "div",
2666
2675
  {
2667
2676
  className: "w-[280px] min-h-[200px] animate-pulse rounded-md bg-black/[0.06] shadow-[0_0_0_1px_rgba(0,0,0,0.04),0_1px_2px_rgba(0,0,0,0.04),0_8px_32px_rgba(0,0,0,0.1)]",
@@ -2745,7 +2754,7 @@ const Or = j.lazy(() => import("./Card-qS17qnN0.js")), Fr = j.lazy(() => import(
2745
2754
  "button",
2746
2755
  {
2747
2756
  type: "button",
2748
- className: y("message-vote-button focus-ring", {
2757
+ className: N("message-vote-button focus-ring", {
2749
2758
  "message-vote-button--selected": e === "up"
2750
2759
  }),
2751
2760
  onClick: t,
@@ -2759,7 +2768,7 @@ const Or = j.lazy(() => import("./Card-qS17qnN0.js")), Fr = j.lazy(() => import(
2759
2768
  "button",
2760
2769
  {
2761
2770
  type: "button",
2762
- className: y("message-vote-button focus-ring", {
2771
+ className: N("message-vote-button focus-ring", {
2763
2772
  "message-vote-button--selected": e === "down"
2764
2773
  }),
2765
2774
  onClick: n,
@@ -2806,7 +2815,7 @@ const Zr = {
2806
2815
  dark: "bg-white text-[#121110] hover:bg-white/90",
2807
2816
  light: "bg-[#121110] text-white hover:bg-[#2a2928]"
2808
2817
  }, Jr = ({ variant: e, cta: t }) => {
2809
- const n = y(
2818
+ const n = N(
2810
2819
  "mt-2 inline-flex h-10 w-full items-center justify-center rounded-full px-4 text-sm font-medium leading-none transition-colors",
2811
2820
  Zr[e]
2812
2821
  ), a = gt(t.href);
@@ -2853,10 +2862,10 @@ const Zr = {
2853
2862
  }) => {
2854
2863
  const d = e === "dark", u = t ?? (d ? n : void 0) ?? "", g = u.trim() !== "", m = a != null && a.trim() !== "", f = typeof r == "string" ? r.trim() : "", c = f !== "", v = l != null;
2855
2864
  if (!g && !m && !c && !v) return null;
2856
- const p = y(
2865
+ const p = N(
2857
2866
  "truncate text-base font-medium leading-6",
2858
2867
  d && !t ? ei : Qr[e]
2859
- ), b = y(
2868
+ ), b = N(
2860
2869
  "truncate text-xs leading-4",
2861
2870
  ti[e]
2862
2871
  );
@@ -2866,7 +2875,7 @@ const Zr = {
2866
2875
  /* @__PURE__ */ h("div", { className: "flex min-w-0 flex-col gap-1", children: [
2867
2876
  g && /* @__PURE__ */ h("div", { className: "flex min-w-0 items-center gap-2", children: [
2868
2877
  i ? /* @__PURE__ */ s("span", { className: "shrink-0", children: i }) : null,
2869
- /* @__PURE__ */ s("p", { className: y("min-w-0", p), children: u })
2878
+ /* @__PURE__ */ s("p", { className: N("min-w-0", p), children: u })
2870
2879
  ] }),
2871
2880
  m && /* @__PURE__ */ s("p", { className: b, children: a })
2872
2881
  ] }),
@@ -2876,7 +2885,7 @@ const Zr = {
2876
2885
  ] }),
2877
2886
  l && /* @__PURE__ */ s(Jr, { variant: e, cta: l })
2878
2887
  ] });
2879
- }, si = y(
2888
+ }, si = N(
2880
2889
  "relative block w-[280px] select-none overflow-hidden rounded-md",
2881
2890
  // 1px hairline border that sits flush with the card chrome — matches
2882
2891
  // the messaging design system's "small border around link attachments"
@@ -2894,7 +2903,7 @@ const Zr = {
2894
2903
  bgClassName: o,
2895
2904
  "data-testid": d
2896
2905
  }) => {
2897
- const u = n != null || a != null, g = y(
2906
+ const u = n != null || a != null, g = N(
2898
2907
  si,
2899
2908
  o ?? (e === "dark" ? "bg-[#1e2330]" : "bg-white"),
2900
2909
  // `focus-ring` is a design-system utility from the component-library
@@ -2925,7 +2934,7 @@ const Zr = {
2925
2934
  onClick: a,
2926
2935
  "aria-label": r,
2927
2936
  "data-testid": d,
2928
- className: y(g, "text-left"),
2937
+ className: N(g, "text-left"),
2929
2938
  children: [
2930
2939
  t,
2931
2940
  m
@@ -2975,7 +2984,7 @@ const Zr = {
2975
2984
  ) }) : /* @__PURE__ */ h(
2976
2985
  "div",
2977
2986
  {
2978
- className: y(
2987
+ className: N(
2979
2988
  "relative h-[180px] w-full overflow-hidden",
2980
2989
  d && "bg-black"
2981
2990
  ),
@@ -3002,7 +3011,7 @@ const Zr = {
3002
3011
  ) : /* @__PURE__ */ s(
3003
3012
  "div",
3004
3013
  {
3005
- className: y(
3014
+ className: N(
3006
3015
  "flex h-full w-full items-center justify-center",
3007
3016
  ni[e]
3008
3017
  ),
@@ -3040,7 +3049,7 @@ const Zr = {
3040
3049
  className: "flex size-6 items-center justify-center rounded-full bg-[#121110] text-white",
3041
3050
  children: /* @__PURE__ */ s(Be, { className: "size-3", weight: "bold" })
3042
3051
  }
3043
- ) : void 0, w = m ? /* @__PURE__ */ s(
3052
+ ) : void 0, x = m ? /* @__PURE__ */ s(
3044
3053
  "button",
3045
3054
  {
3046
3055
  type: "button",
@@ -3088,7 +3097,7 @@ const Zr = {
3088
3097
  url: a,
3089
3098
  appIcon: d,
3090
3099
  cta: u,
3091
- trailingAction: w
3100
+ trailingAction: x
3092
3101
  }
3093
3102
  )
3094
3103
  ]
@@ -3106,7 +3115,7 @@ const Zr = {
3106
3115
  cta: d,
3107
3116
  onClick: u
3108
3117
  }) => {
3109
- const g = bt(a, i), m = gt(n), f = d == null && m != null && !g ? m : void 0, c = d == null && !g ? u : void 0, v = $e(a, i) ? vt : void 0, w = d && u ? {
3118
+ const g = bt(a, i), m = gt(n), f = d == null && m != null && !g ? m : void 0, c = d == null && !g ? u : void 0, v = $e(a, i) ? vt : void 0, x = d && u ? {
3110
3119
  ...d,
3111
3120
  onClick: () => {
3112
3121
  var p;
@@ -3141,7 +3150,7 @@ const Zr = {
3141
3150
  description: t,
3142
3151
  url: n,
3143
3152
  appIcon: o,
3144
- cta: w
3153
+ cta: x
3145
3154
  }
3146
3155
  )
3147
3156
  ]
@@ -3396,14 +3405,14 @@ const gi = ({
3396
3405
  var v;
3397
3406
  const r = Ls(n.attachments);
3398
3407
  if (r.length === 0) return null;
3399
- const i = di(r), l = (v = n.text) == null ? void 0 : v.trim(), o = r.find((w) => w.type === "link"), d = (o == null ? void 0 : o.type) === "link" ? qt(o.attachments[0] ?? {}).url : void 0, u = l && li(l, d) ? void 0 : l;
3408
+ const i = di(r), l = (v = n.text) == null ? void 0 : v.trim(), o = r.find((x) => x.type === "link"), d = (o == null ? void 0 : o.type) === "link" ? qt(o.attachments[0] ?? {}).url : void 0, u = l && li(l, d) ? void 0 : l;
3400
3409
  let g = 0;
3401
- const m = [], f = (w, p) => {
3410
+ const m = [], f = (x, p) => {
3402
3411
  const b = t ? Ht.Sent : Ht.Received;
3403
3412
  m.push(
3404
- /* @__PURE__ */ s(b, { ...qt(w) }, p)
3413
+ /* @__PURE__ */ s(b, { ...qt(x) }, p)
3405
3414
  );
3406
- }, c = (w, p) => {
3415
+ }, c = (x, p) => {
3407
3416
  const b = ui(
3408
3417
  g,
3409
3418
  i,
@@ -3415,20 +3424,20 @@ const gi = ({
3415
3424
  {
3416
3425
  groupPosition: b,
3417
3426
  isMyMessage: t,
3418
- segment: w
3427
+ segment: x
3419
3428
  },
3420
3429
  p
3421
3430
  )
3422
3431
  );
3423
3432
  };
3424
- return r.forEach((w, p) => {
3425
- if (w.type === "link") {
3426
- w.attachments.forEach((b, x) => {
3427
- f(b, `link-${p}-${x}`);
3433
+ return r.forEach((x, p) => {
3434
+ if (x.type === "link") {
3435
+ x.attachments.forEach((b, w) => {
3436
+ f(b, `link-${p}-${w}`);
3428
3437
  });
3429
3438
  return;
3430
3439
  }
3431
- c(w, `media-${p}`);
3440
+ c(x, `media-${p}`);
3432
3441
  }), /* @__PURE__ */ h("div", { className: "str-chat__message-bubble-wrapper", children: [
3433
3442
  /* @__PURE__ */ h(
3434
3443
  "div",
@@ -3475,12 +3484,12 @@ const gi = ({
3475
3484
  isMyMessage: f,
3476
3485
  message: c,
3477
3486
  renderText: v,
3478
- threadList: w,
3487
+ threadList: x,
3479
3488
  viewerLanguage: p
3480
- } = e, { client: b } = ke("CustomMessage"), { channel: x } = ue("CustomMessage"), { isUnlocking: S, onUnlockClick: k, onFetchSource: R, onDownloadClick: A } = zr("LockedAttachment"), [O, B] = F(!1), z = Ks(c.id), { selected: L, voteUp: C, voteDown: I } = ba(c), {
3481
- Attachment: N = Zs,
3482
- EditMessageModal: M = Js,
3483
- MessageActions: E,
3489
+ } = e, { client: b } = ke("CustomMessage"), { channel: w } = ue("CustomMessage"), { isUnlocking: E, onUnlockClick: k, onFetchSource: R, onDownloadClick: A } = zr("LockedAttachment"), [z, B] = F(!1), O = Ks(c.id), { selected: L, voteUp: C, voteDown: T } = ba(c), {
3490
+ Attachment: S = Zs,
3491
+ EditMessageModal: I = Js,
3492
+ MessageActions: y,
3484
3493
  MessageBlocked: D = Qs,
3485
3494
  MessageBouncePrompt: H = en,
3486
3495
  MessageDeleted: q = tn,
@@ -3488,7 +3497,7 @@ const gi = ({
3488
3497
  MessageRepliesCountButton: Z = nn,
3489
3498
  ReminderNotification: V = an,
3490
3499
  StreamedMessageText: _ = rn,
3491
- PinIndicator: T
3500
+ PinIndicator: M
3492
3501
  } = es("CustomMessage"), $ = on(c), te = ln(c), X = se(
3493
3502
  () => m == null ? void 0 : m(c),
3494
3503
  [m, c]
@@ -3517,10 +3526,10 @@ const gi = ({
3517
3526
  return /* @__PURE__ */ s(q, { message: c });
3518
3527
  if (dn(c))
3519
3528
  return /* @__PURE__ */ s(D, {});
3520
- const le = !w && !!c.reply_count, ie = !w && c.show_in_channel && c.parent_id, xt = c.status === "failed" && ((Ct = c.error) == null ? void 0 : Ct.status) !== 403, wt = un(c);
3529
+ const le = !x && !!c.reply_count, ie = !x && c.show_in_channel && c.parent_id, xt = c.status === "failed" && ((Ct = c.error) == null ? void 0 : Ct.status) !== 403, wt = un(c);
3521
3530
  let me;
3522
3531
  xt ? me = () => u(c) : wt && (me = () => B(!0));
3523
- const Q = f(), Bs = y(
3532
+ const Q = f(), Bs = N(
3524
3533
  "str-chat__message str-chat__message-simple",
3525
3534
  `str-chat__message--${c.type}`,
3526
3535
  `str-chat__message--${c.status}`,
@@ -3550,21 +3559,21 @@ const gi = ({
3550
3559
  amountText: (Rt = c.metadata) == null ? void 0 : Rt.amount_text,
3551
3560
  detail: (Lt = c.metadata) == null ? void 0 : Lt.attachment_detail,
3552
3561
  paymentStatus: (Dt = c.metadata) == null ? void 0 : Dt.payment_status,
3553
- onFetchSource: R ? () => R(c, x) : void 0
3562
+ onFetchSource: R ? () => R(c, w) : void 0
3554
3563
  };
3555
3564
  return /* @__PURE__ */ h(ee, { children: [
3556
3565
  a && /* @__PURE__ */ s(
3557
- M,
3566
+ I,
3558
3567
  {
3559
3568
  additionalMessageInputProps: t
3560
3569
  }
3561
3570
  ),
3562
- O && /* @__PURE__ */ s(
3571
+ z && /* @__PURE__ */ s(
3563
3572
  mn,
3564
3573
  {
3565
3574
  MessageBouncePrompt: H,
3566
3575
  onClose: () => B(!1),
3567
- open: O
3576
+ open: z
3568
3577
  }
3569
3578
  ),
3570
3579
  /* @__PURE__ */ h(
@@ -3574,8 +3583,8 @@ const gi = ({
3574
3583
  "data-message-id": c.id,
3575
3584
  "data-dd-privacy": "mask",
3576
3585
  children: [
3577
- T && /* @__PURE__ */ s(T, {}),
3578
- !!z && /* @__PURE__ */ s(V, { reminder: z }),
3586
+ M && /* @__PURE__ */ s(M, {}),
3587
+ !!O && /* @__PURE__ */ s(V, { reminder: O }),
3579
3588
  c.user && /* @__PURE__ */ s(
3580
3589
  be,
3581
3590
  {
@@ -3591,7 +3600,7 @@ const gi = ({
3591
3600
  /* @__PURE__ */ s(
3592
3601
  "div",
3593
3602
  {
3594
- className: y("str-chat__message-inner", {
3603
+ className: N("str-chat__message-inner", {
3595
3604
  "str-chat__simple-message--error-failed": xt || wt
3596
3605
  }),
3597
3606
  "data-testid": "message-inner",
@@ -3606,7 +3615,7 @@ const gi = ({
3606
3615
  marginInlineStart: 0
3607
3616
  },
3608
3617
  children: _t ? /* @__PURE__ */ s(qe, { message: c, standalone: !0 }) : Vr(c) ? /* @__PURE__ */ s("div", { className: "str-chat__message-bubble-wrapper", children: /* @__PURE__ */ h("div", { className: "flex items-center gap-2", children: [
3609
- Q && E && /* @__PURE__ */ s(E, {}),
3618
+ Q && y && /* @__PURE__ */ s(y, {}),
3610
3619
  Q ? /* @__PURE__ */ s(
3611
3620
  Re,
3612
3621
  {
@@ -3618,32 +3627,32 @@ const gi = ({
3618
3627
  {
3619
3628
  ...yt,
3620
3629
  isMine: !1,
3621
- isUnlocking: S(c.id),
3622
- onUnlockClick: () => k == null ? void 0 : k(c, x)
3630
+ isUnlocking: E(c.id),
3631
+ onUnlockClick: () => k == null ? void 0 : k(c, w)
3623
3632
  }
3624
3633
  ),
3625
- !Q && E && /* @__PURE__ */ s(E, {})
3634
+ !Q && y && /* @__PURE__ */ s(y, {})
3626
3635
  ] }) }) : Gr(c) ? /* @__PURE__ */ h("div", { className: "str-chat__message-bubble-wrapper", children: [
3627
3636
  /* @__PURE__ */ h("div", { className: "flex items-center gap-2", children: [
3628
- Q && E && /* @__PURE__ */ s(E, {}),
3637
+ Q && y && /* @__PURE__ */ s(y, {}),
3629
3638
  Q ? /* @__PURE__ */ s(
3630
3639
  Re,
3631
3640
  {
3632
3641
  ...kt,
3633
3642
  isMine: !0,
3634
- onPreviewClick: () => k ? k(c, x) : void 0
3643
+ onPreviewClick: () => k ? k(c, w) : void 0
3635
3644
  }
3636
3645
  ) : /* @__PURE__ */ s(
3637
3646
  Re,
3638
3647
  {
3639
3648
  ...kt,
3640
3649
  isMine: !1,
3641
- isUnlocking: S(c.id),
3642
- onUnlockClick: () => k ? k(c, x) : void 0,
3643
- onDownloadClick: () => A ? A(c, x) : void 0
3650
+ isUnlocking: E(c.id),
3651
+ onUnlockClick: () => k ? k(c, w) : void 0,
3652
+ onDownloadClick: () => A ? A(c, w) : void 0
3644
3653
  }
3645
3654
  ),
3646
- !Q && E && /* @__PURE__ */ s(E, {})
3655
+ !Q && y && /* @__PURE__ */ s(y, {})
3647
3656
  ] }),
3648
3657
  c.text && /* @__PURE__ */ s("div", { className: "str-chat__message-bubble", children: /* @__PURE__ */ s(
3649
3658
  Le,
@@ -3678,7 +3687,7 @@ const gi = ({
3678
3687
  ),
3679
3688
  Ue && /* @__PURE__ */ s(hn, { poll: Ue }),
3680
3689
  U != null && U.length && !c.quoted_message ? /* @__PURE__ */ s(
3681
- N,
3690
+ S,
3682
3691
  {
3683
3692
  actionHandler: o,
3684
3693
  attachments: U
@@ -3715,7 +3724,7 @@ const gi = ({
3715
3724
  {
3716
3725
  selected: L,
3717
3726
  onVoteUp: C,
3718
- onVoteDown: I
3727
+ onVoteDown: T
3719
3728
  }
3720
3729
  )
3721
3730
  ] }),
@@ -3937,19 +3946,19 @@ const gi = ({
3937
3946
  const v = () => {
3938
3947
  const p = m.offsetHeight, b = p > c;
3939
3948
  c = p;
3940
- const x = Array.from(
3949
+ const w = Array.from(
3941
3950
  f.querySelectorAll(".str-chat__list")
3942
- ).find((k) => k.scrollHeight > k.clientHeight) ?? null, S = x ? x.scrollHeight - x.scrollTop - x.clientHeight < Ci : !1;
3951
+ ).find((k) => k.scrollHeight > k.clientHeight) ?? null, E = w ? w.scrollHeight - w.scrollTop - w.clientHeight < Ci : !1;
3943
3952
  f.style.setProperty(
3944
3953
  "--messaging-composer-height",
3945
3954
  `${p}px`
3946
- ), b && S && x && (x.scrollTop = x.scrollHeight);
3955
+ ), b && E && w && (w.scrollTop = w.scrollHeight);
3947
3956
  };
3948
3957
  if (v(), typeof ResizeObserver > "u")
3949
3958
  return;
3950
- const w = new ResizeObserver(v);
3951
- return w.observe(m), () => {
3952
- w.disconnect(), f.style.removeProperty("--messaging-composer-height");
3959
+ const x = new ResizeObserver(v);
3960
+ return x.observe(m), () => {
3961
+ x.disconnect(), f.style.removeProperty("--messaging-composer-height");
3953
3962
  };
3954
3963
  }, [d]), a ? d ? /* @__PURE__ */ h(
3955
3964
  "div",
@@ -4160,7 +4169,7 @@ const gi = ({
4160
4169
  Ge.Generating,
4161
4170
  Ge.ExternalSources
4162
4171
  ]), $i = ({ threadList: e }) => {
4163
- var v, w;
4172
+ var v, x;
4164
4173
  const { channel: t, channelConfig: n, thread: a } = ue(), { client: r } = ke(), { typing: i = {} } = _n(), { aiState: l } = Nn(t), o = ye(Ds);
4165
4174
  if (!e && o && Bi.has(l)) {
4166
4175
  const p = Ui(t, (v = r.user) == null ? void 0 : v.id);
@@ -4178,18 +4187,18 @@ const gi = ({
4178
4187
  return null;
4179
4188
  const u = e ? [] : Object.values(i).filter(
4180
4189
  ({ parent_id: p, user: b }) => {
4181
- var x;
4182
- return (b == null ? void 0 : b.id) !== ((x = r.user) == null ? void 0 : x.id) && !p;
4190
+ var w;
4191
+ return (b == null ? void 0 : b.id) !== ((w = r.user) == null ? void 0 : w.id) && !p;
4183
4192
  }
4184
4193
  ), g = e ? Object.values(i).filter(
4185
4194
  ({ parent_id: p, user: b }) => {
4186
- var x;
4187
- return (b == null ? void 0 : b.id) !== ((x = r.user) == null ? void 0 : x.id) && p === (a == null ? void 0 : a.id);
4195
+ var w;
4196
+ return (b == null ? void 0 : b.id) !== ((w = r.user) == null ? void 0 : w.id) && p === (a == null ? void 0 : a.id);
4188
4197
  }
4189
4198
  ) : [], m = e ? g : u;
4190
4199
  if (!m.length)
4191
4200
  return null;
4192
- const f = (w = m[0]) == null ? void 0 : w.user, c = f != null && f.id && t.state.members[f.id] ? t.state.members[f.id].user : void 0;
4201
+ const f = (x = m[0]) == null ? void 0 : x.user, c = f != null && f.id && t.state.members[f.id] ? t.state.members[f.id].user : void 0;
4193
4202
  return /* @__PURE__ */ s(
4194
4203
  Jt,
4195
4204
  {
@@ -4255,7 +4264,7 @@ function Ui(e, t) {
4255
4264
  const ji = () => null, Vi = ({ className: e, message: t }) => /* @__PURE__ */ h(
4256
4265
  "div",
4257
4266
  {
4258
- className: y("flex items-center justify-center h-full", e),
4267
+ className: N("flex items-center justify-center h-full", e),
4259
4268
  children: [
4260
4269
  /* @__PURE__ */ h("svg", { viewBox: "0 0 100 100", className: "size-8 fill-pebble", stroke: "none", children: [
4261
4270
  /* @__PURE__ */ s("circle", { cx: "6", cy: "50", r: "6", children: /* @__PURE__ */ s(
@@ -4316,27 +4325,27 @@ const Gi = ({
4316
4325
  showReportParticipant: f = !0,
4317
4326
  composerDisabled: c = !1,
4318
4327
  composerDisabledReason: v,
4319
- showStarButton: w = !1,
4328
+ showStarButton: x = !1,
4320
4329
  chatbotVotingEnabled: p = !1,
4321
4330
  renderChannelBanner: b,
4322
- customChannelActions: x,
4323
- renderChannelActions: S,
4331
+ customChannelActions: w,
4332
+ renderChannelActions: E,
4324
4333
  renderMessage: k,
4325
4334
  viewerLanguage: R,
4326
4335
  showChannelInfo: A = !0,
4327
- onParticipantNameClick: O,
4336
+ onParticipantNameClick: z,
4328
4337
  composerInput: B
4329
4338
  }) => {
4330
- const { channel: z } = ue(), L = z.state.messages.some(
4331
- (M) => M.type !== "deleted"
4332
- ), C = b ? /* @__PURE__ */ s(j.Fragment, { children: b() }, "lt-channel-banner") : null, I = /* @__PURE__ */ s(
4339
+ const { channel: O } = ue(), L = O.state.messages.some(
4340
+ (I) => I.type !== "deleted"
4341
+ ), C = b ? /* @__PURE__ */ s(j.Fragment, { children: b() }, "lt-channel-banner") : null, T = /* @__PURE__ */ s(
4333
4342
  fa,
4334
4343
  {
4335
4344
  className: "-mx-[var(--str-chat\\_\\_spacing-2)] px-[var(--str-chat\\_\\_spacing-2)] md:-mx-[min(var(--str-chat\\_\\_spacing-10),4%)] md:px-[min(var(--str-chat\\_\\_spacing-10),4%)]",
4336
4345
  onBack: e,
4337
4346
  showBackButton: t,
4338
4347
  showChannelInfo: A,
4339
- showStarButton: w,
4348
+ showStarButton: x,
4340
4349
  onLeaveConversation: i,
4341
4350
  onBlockParticipant: l,
4342
4351
  showDeleteConversation: o,
@@ -4345,21 +4354,21 @@ const Gi = ({
4345
4354
  onDeleteConversationClick: d,
4346
4355
  onBlockParticipantClick: u,
4347
4356
  onReportParticipantClick: g,
4348
- customChannelActions: x,
4349
- renderChannelActions: S,
4350
- onParticipantNameClick: O
4357
+ customChannelActions: w,
4358
+ renderChannelActions: E,
4359
+ onParticipantNameClick: z
4351
4360
  }
4352
- ), N = W(
4353
- (M) => {
4354
- const { message: E } = pe("ChannelView"), D = /* @__PURE__ */ s(
4361
+ ), S = W(
4362
+ (I) => {
4363
+ const { message: y } = pe("ChannelView"), D = /* @__PURE__ */ s(
4355
4364
  vi,
4356
4365
  {
4357
- ...M,
4366
+ ...I,
4358
4367
  chatbotVotingEnabled: p,
4359
4368
  viewerLanguage: R
4360
4369
  }
4361
4370
  );
4362
- return !k || !E ? D : k(D, E);
4371
+ return !k || !y ? D : k(D, y);
4363
4372
  },
4364
4373
  [p, k, R]
4365
4374
  );
@@ -4367,7 +4376,7 @@ const Gi = ({
4367
4376
  kn,
4368
4377
  {
4369
4378
  overrides: {
4370
- Message: N,
4379
+ Message: S,
4371
4380
  MessageActions: _i,
4372
4381
  UnreadMessagesNotification: () => null,
4373
4382
  UnreadMessagesSeparator: () => null
@@ -4379,14 +4388,14 @@ const Gi = ({
4379
4388
  className: "messaging-channel-message-list messaging-channel-message-list--floating relative min-h-0 flex-1 overflow-hidden",
4380
4389
  children: [
4381
4390
  !L && /* @__PURE__ */ s("div", { className: "str-chat__list", children: /* @__PURE__ */ h("div", { className: "str-chat__message-list-scroll", children: [
4382
- I,
4391
+ T,
4383
4392
  C
4384
4393
  ] }) }),
4385
4394
  /* @__PURE__ */ s(
4386
4395
  Bt,
4387
4396
  {
4388
4397
  head: L ? /* @__PURE__ */ h("div", { className: "sticky top-0 z-10", children: [
4389
- I,
4398
+ T,
4390
4399
  C
4391
4400
  ] }) : void 0,
4392
4401
  hideDeletedMessages: !0,
@@ -4401,12 +4410,12 @@ const Gi = ({
4401
4410
  Kt,
4402
4411
  {
4403
4412
  ...n && {
4404
- renderActions: () => n == null ? void 0 : n(z)
4413
+ renderActions: () => n == null ? void 0 : n(O)
4405
4414
  },
4406
4415
  ...r && {
4407
- renderHeader: () => r(z)
4416
+ renderHeader: () => r(O)
4408
4417
  },
4409
- renderFooter: () => a == null ? void 0 : a(z),
4418
+ renderFooter: () => a == null ? void 0 : a(O),
4410
4419
  disabled: c,
4411
4420
  disabledReason: v,
4412
4421
  composerInput: B
@@ -4420,14 +4429,14 @@ const Gi = ({
4420
4429
  className: "flex-1 overflow-hidden relative",
4421
4430
  children: [
4422
4431
  !L && /* @__PURE__ */ s("div", { className: "str-chat__list", children: /* @__PURE__ */ h("div", { className: "str-chat__message-list-scroll", children: [
4423
- I,
4432
+ T,
4424
4433
  C
4425
4434
  ] }) }),
4426
4435
  /* @__PURE__ */ s(
4427
4436
  Bt,
4428
4437
  {
4429
4438
  head: L ? /* @__PURE__ */ h("div", { className: "sticky top-0 z-10", children: [
4430
- I,
4439
+ T,
4431
4440
  C
4432
4441
  ] }) : void 0,
4433
4442
  hideDeletedMessages: !0,
@@ -4438,14 +4447,14 @@ const Gi = ({
4438
4447
  },
4439
4448
  "lt-channel-message-list"
4440
4449
  ),
4441
- r ? /* @__PURE__ */ s(j.Fragment, { children: r(z) }, "lt-channel-conversation-footer") : null,
4450
+ r ? /* @__PURE__ */ s(j.Fragment, { children: r(O) }, "lt-channel-conversation-footer") : null,
4442
4451
  /* @__PURE__ */ s(
4443
4452
  Kt,
4444
4453
  {
4445
4454
  ...n && {
4446
- renderActions: () => n == null ? void 0 : n(z)
4455
+ renderActions: () => n == null ? void 0 : n(O)
4447
4456
  },
4448
- renderFooter: () => a == null ? void 0 : a(z),
4457
+ renderFooter: () => a == null ? void 0 : a(O),
4449
4458
  disabled: c,
4450
4459
  disabledReason: v,
4451
4460
  composerInput: B
@@ -4472,36 +4481,36 @@ const Gi = ({
4472
4481
  onBlockParticipantClick: f,
4473
4482
  onReportParticipantClick: c,
4474
4483
  showBlockParticipant: v = !0,
4475
- showReportParticipant: w = !0,
4484
+ showReportParticipant: x = !0,
4476
4485
  composerDisabled: p = !1,
4477
4486
  composerDisabledReason: b,
4478
- dmAgentEnabled: x,
4479
- messageMetadata: S,
4487
+ dmAgentEnabled: w,
4488
+ messageMetadata: E,
4480
4489
  onMessageSent: k,
4481
4490
  showStarButton: R = !1,
4482
4491
  chatbotVotingEnabled: A = !1,
4483
- renderChannelBanner: O,
4492
+ renderChannelBanner: z,
4484
4493
  customChannelActions: B,
4485
- renderChannelActions: z,
4494
+ renderChannelActions: O,
4486
4495
  renderMessage: L,
4487
4496
  onMessageLinkClick: C,
4488
- sendButton: I,
4489
- attachmentPreviewList: N,
4490
- viewerLanguage: M,
4491
- showChannelInfo: E = !0,
4497
+ sendButton: T,
4498
+ attachmentPreviewList: S,
4499
+ viewerLanguage: I,
4500
+ showChannelInfo: y = !0,
4492
4501
  onParticipantNameClick: D,
4493
4502
  composerInput: H
4494
4503
  }) => {
4495
4504
  const q = W(
4496
4505
  async (Z, V, _) => {
4497
4506
  var J;
4498
- const T = ((J = e.data) == null ? void 0 : J.chatbot_paused) === !0, $ = x && !T, te = {
4507
+ const M = ((J = e.data) == null ? void 0 : J.chatbot_paused) === !0, $ = w && !M, te = {
4499
4508
  ...V,
4500
4509
  ...$ && { silent: !0 },
4501
- ...S && {
4510
+ ...E && {
4502
4511
  metadata: {
4503
4512
  ...V.metadata ?? {},
4504
- ...S
4513
+ ...E
4505
4514
  }
4506
4515
  }
4507
4516
  }, X = {
@@ -4510,14 +4519,14 @@ const Gi = ({
4510
4519
  }, U = await e.sendMessage(te, X);
4511
4520
  return k == null || k(U), U;
4512
4521
  },
4513
- [e, x, S, k]
4522
+ [e, w, E, k]
4514
4523
  ), K = G(null);
4515
4524
  return Y(() => {
4516
4525
  if (!C) return;
4517
4526
  const Z = K.current;
4518
4527
  if (!Z) return;
4519
4528
  const V = (_) => {
4520
- const T = _.target, $ = T == null ? void 0 : T.closest("a[href]"), te = $ == null ? void 0 : $.getAttribute("href");
4529
+ const M = _.target, $ = M == null ? void 0 : M.closest("a[href]"), te = $ == null ? void 0 : $.getAttribute("href");
4521
4530
  if (!te) return;
4522
4531
  const X = $ == null ? void 0 : $.closest("[data-message-id]"), U = X == null ? void 0 : X.getAttribute("data-message-id"), J = U ? e.state.messages.find((ae) => ae.id === U) : void 0;
4523
4532
  C(te, J);
@@ -4527,11 +4536,11 @@ const Gi = ({
4527
4536
  "div",
4528
4537
  {
4529
4538
  ref: K,
4530
- className: y(
4539
+ className: N(
4531
4540
  "messaging-channel-view h-full flex flex-col",
4532
4541
  d
4533
4542
  ),
4534
- children: /* @__PURE__ */ s(Ds.Provider, { value: x ?? !1, children: /* @__PURE__ */ s(
4543
+ children: /* @__PURE__ */ s(Ds.Provider, { value: w ?? !1, children: /* @__PURE__ */ s(
4535
4544
  yn,
4536
4545
  {
4537
4546
  channel: e,
@@ -4541,8 +4550,8 @@ const Gi = ({
4541
4550
  DateSeparator: ga,
4542
4551
  TypingIndicator: $i,
4543
4552
  doSendMessageRequest: q,
4544
- ...I ? { SendButton: I } : {},
4545
- ...N ? { AttachmentPreviewList: N } : {},
4553
+ ...T ? { SendButton: T } : {},
4554
+ ...S ? { AttachmentPreviewList: S } : {},
4546
4555
  children: /* @__PURE__ */ s(
4547
4556
  Gi,
4548
4557
  {
@@ -4559,17 +4568,17 @@ const Gi = ({
4559
4568
  onBlockParticipantClick: f,
4560
4569
  onReportParticipantClick: c,
4561
4570
  showBlockParticipant: v,
4562
- showReportParticipant: w,
4571
+ showReportParticipant: x,
4563
4572
  composerDisabled: p,
4564
4573
  composerDisabledReason: b,
4565
4574
  showStarButton: R,
4566
4575
  chatbotVotingEnabled: A,
4567
- renderChannelBanner: O,
4576
+ renderChannelBanner: z,
4568
4577
  customChannelActions: B,
4569
- renderChannelActions: z,
4578
+ renderChannelActions: O,
4570
4579
  renderMessage: L,
4571
- viewerLanguage: M,
4572
- showChannelInfo: E,
4580
+ viewerLanguage: I,
4581
+ showChannelInfo: y,
4573
4582
  onParticipantNameClick: D,
4574
4583
  composerInput: H
4575
4584
  }
@@ -4612,31 +4621,31 @@ const bo = ({
4612
4621
  chatbotVotingEnabled: f = !1,
4613
4622
  viewerLanguage: c,
4614
4623
  renderChannelBanner: v,
4615
- customChannelActions: w,
4624
+ customChannelActions: x,
4616
4625
  renderChannelActions: p,
4617
4626
  onParticipantNameClick: b,
4618
- renderMessage: x,
4619
- onMessageLinkClick: S,
4627
+ renderMessage: w,
4628
+ onMessageLinkClick: E,
4620
4629
  showChannelInfo: k,
4621
4630
  composerInput: R
4622
4631
  }) => {
4623
4632
  const {
4624
4633
  client: A,
4625
- isConnected: O,
4634
+ isConnected: z,
4626
4635
  isLoading: B,
4627
- error: z,
4636
+ error: O,
4628
4637
  refreshConnection: L,
4629
4638
  service: C,
4630
- debug: I
4631
- } = ta(), [N, M] = F(null), [E, D] = F(null), [H, q] = F(!1), { showDeleteConversation: K = !0 } = e, Z = G(l);
4639
+ debug: T
4640
+ } = ta(), [S, I] = F(null), [y, D] = F(null), [H, q] = F(!1), { showDeleteConversation: K = !0 } = e, Z = G(l);
4632
4641
  Z.current = l;
4633
4642
  const V = G(a);
4634
4643
  V.current = a;
4635
- const _ = G(null), T = G(null);
4644
+ const _ = G(null), M = G(null);
4636
4645
  Y(() => {
4637
- T.current = N;
4638
- }, [N]), Y(() => {
4639
- if (!A || !O) return;
4646
+ M.current = S;
4647
+ }, [S]), Y(() => {
4648
+ if (!A || !z) return;
4640
4649
  const X = A.userID;
4641
4650
  if (!X) return;
4642
4651
  const U = `${X}::${i}`;
@@ -4648,7 +4657,7 @@ const bo = ({
4648
4657
  (async () => {
4649
4658
  var Te, Me;
4650
4659
  try {
4651
- I && console.log(
4660
+ T && console.log(
4652
4661
  "[MessagingShell] Loading initial conversation with:",
4653
4662
  i
4654
4663
  );
@@ -4661,7 +4670,7 @@ const bo = ({
4661
4670
  { limit: 1 }
4662
4671
  );
4663
4672
  if (re.length > 0) {
4664
- M(re[0]), D(null), (Te = V.current) == null || Te.call(V, re[0]), I && console.log(
4673
+ I(re[0]), D(null), (Te = V.current) == null || Te.call(V, re[0]), T && console.log(
4665
4674
  "[MessagingShell] Initial conversation loaded:",
4666
4675
  re[0].id
4667
4676
  );
@@ -4669,7 +4678,7 @@ const bo = ({
4669
4678
  }
4670
4679
  const le = Z.current;
4671
4680
  if (!le || !C) {
4672
- J(), D("No conversation found with this account"), I && console.log(
4681
+ J(), D("No conversation found with this account"), T && console.log(
4673
4682
  "[MessagingShell] No conversation found for:",
4674
4683
  i
4675
4684
  );
@@ -4681,7 +4690,7 @@ const bo = ({
4681
4690
  name: le.name,
4682
4691
  phone: le.phone
4683
4692
  });
4684
- M(ie), D(null), (Me = V.current) == null || Me.call(V, ie), I && console.log(
4693
+ I(ie), D(null), (Me = V.current) == null || Me.call(V, ie), T && console.log(
4685
4694
  "[MessagingShell] Channel created and loaded:",
4686
4695
  ie.id
4687
4696
  );
@@ -4695,26 +4704,26 @@ const bo = ({
4695
4704
  console.error(
4696
4705
  "[MessagingShell] Failed to load initial conversation:",
4697
4706
  re
4698
- ), J(), T.current || D("Failed to load conversation");
4707
+ ), J(), M.current || D("Failed to load conversation");
4699
4708
  }
4700
4709
  })();
4701
- }, [i, A, O, C, I]);
4710
+ }, [i, A, z, C, T]);
4702
4711
  const $ = G(r);
4703
4712
  $.current = r;
4704
4713
  const te = W(() => {
4705
4714
  var X;
4706
- M(null), q(!0), (X = $.current) == null || X.call($);
4715
+ I(null), q(!0), (X = $.current) == null || X.call($);
4707
4716
  }, []);
4708
- return B ? /* @__PURE__ */ s(Fe, {}) : z ? /* @__PURE__ */ s(we, { message: z, onBack: L }) : !O || !A ? /* @__PURE__ */ s(
4717
+ return B ? /* @__PURE__ */ s(Fe, {}) : O ? /* @__PURE__ */ s(we, { message: O, onBack: L }) : !z || !A ? /* @__PURE__ */ s(
4709
4718
  we,
4710
4719
  {
4711
4720
  message: "Not connected to messaging service",
4712
4721
  onBack: L
4713
4722
  }
4714
- ) : E ? /* @__PURE__ */ s(we, { message: E }) : H && !N ? /* @__PURE__ */ s(we, { message: "Conversation ended" }) : N ? /* @__PURE__ */ s("div", { className: "messaging-shell h-full bg-background-primary overflow-hidden", children: /* @__PURE__ */ s("div", { className: "flex h-full min-h-0 flex-col", children: /* @__PURE__ */ s(
4723
+ ) : y ? /* @__PURE__ */ s(we, { message: y }) : H && !S ? /* @__PURE__ */ s(we, { message: "Conversation ended" }) : S ? /* @__PURE__ */ s("div", { className: "messaging-shell h-full bg-background-primary overflow-hidden", children: /* @__PURE__ */ s("div", { className: "flex h-full min-h-0 flex-col", children: /* @__PURE__ */ s(
4715
4724
  Ps,
4716
4725
  {
4717
- channel: N,
4726
+ channel: S,
4718
4727
  renderMessageInputActions: t,
4719
4728
  renderConversationFooter: n,
4720
4729
  renderChannelBanner: v,
@@ -4728,15 +4737,15 @@ const bo = ({
4728
4737
  onMessageSent: m,
4729
4738
  chatbotVotingEnabled: f,
4730
4739
  viewerLanguage: c,
4731
- customChannelActions: w,
4740
+ customChannelActions: x,
4732
4741
  renderChannelActions: p,
4733
4742
  onParticipantNameClick: b,
4734
- renderMessage: x,
4735
- onMessageLinkClick: S,
4743
+ renderMessage: w,
4744
+ onMessageLinkClick: E,
4736
4745
  showChannelInfo: k,
4737
4746
  composerInput: R
4738
4747
  },
4739
- N.id
4748
+ S.id
4740
4749
  ) }) }) : /* @__PURE__ */ s(Fe, {});
4741
4750
  };
4742
4751
  function Hi(e) {
@@ -4776,7 +4785,7 @@ const zs = j.createContext({
4776
4785
  });
4777
4786
  }, Os = j.memo(
4778
4787
  (e) => {
4779
- var B, z, L;
4788
+ var B, O, L;
4780
4789
  const { channel: t, unread: n } = e, {
4781
4790
  selectedChannel: a,
4782
4791
  onChannelSelect: r,
@@ -4799,44 +4808,44 @@ const zs = j.createContext({
4799
4808
  const f = () => {
4800
4809
  t && r(t);
4801
4810
  }, c = (C) => {
4802
- const I = C.key === "Enter" || C.key === " ", N = C.repeat;
4803
- !I || N || (C.preventDefault(), f());
4811
+ const T = C.key === "Enter" || C.key === " ", S = C.repeat;
4812
+ !T || S || (C.preventDefault(), f());
4804
4813
  }, v = ls(
4805
4814
  (B = t == null ? void 0 : t.state) == null ? void 0 : B.members,
4806
4815
  u == null ? void 0 : u.userID,
4807
4816
  t == null ? void 0 : t.type
4808
- ), w = cs(v == null ? void 0 : v.user), p = (z = v == null ? void 0 : v.user) == null ? void 0 : z.image, b = (() => {
4809
- var I;
4810
- const C = (I = t == null ? void 0 : t.state) == null ? void 0 : I.messages;
4817
+ ), x = cs(v == null ? void 0 : v.user), p = (O = v == null ? void 0 : v.user) == null ? void 0 : O.image, b = (() => {
4818
+ var T;
4819
+ const C = (T = t == null ? void 0 : t.state) == null ? void 0 : T.messages;
4811
4820
  if (C != null && C.length) {
4812
- for (let N = C.length - 1; N >= 0; N--)
4813
- if (C[N].type !== "system") return C[N];
4821
+ for (let S = C.length - 1; S >= 0; S--)
4822
+ if (C[S].type !== "system") return C[S];
4814
4823
  }
4815
- })(), S = (() => {
4816
- var E;
4824
+ })(), E = (() => {
4825
+ var y;
4817
4826
  const C = us({
4818
4827
  message: b,
4819
4828
  viewerLanguage: d
4820
- }), { custom_type: I, attachment_content_type: N } = (b == null ? void 0 : b.metadata) || {};
4821
- if (I === "MESSAGE_TIP")
4829
+ }), { custom_type: T, attachment_content_type: S } = (b == null ? void 0 : b.metadata) || {};
4830
+ if (T === "MESSAGE_TIP")
4822
4831
  return C || "Sent a tip";
4823
- if (I === "MESSAGE_PAID")
4832
+ if (T === "MESSAGE_PAID")
4824
4833
  return C || "Sent a message";
4825
- if (I === "MESSAGE_ATTACHMENT") {
4826
- if (N === "text")
4834
+ if (T === "MESSAGE_ATTACHMENT") {
4835
+ if (S === "text")
4827
4836
  return "🔒 Sent a locked message";
4828
- if (N === "media")
4837
+ if (S === "media")
4829
4838
  return "🔒 Sent a locked attachment";
4830
4839
  }
4831
4840
  if (C) return C;
4832
- const M = (E = b == null ? void 0 : b.attachments) == null ? void 0 : E[0];
4833
- return M ? M.og_scrape_url ? M.og_scrape_url : M.type === "image" ? "📷 Sent an image" : M.type === "video" ? "🎥 Sent a video" : M.type === "audio" ? "🎵 Sent audio" : M.type === "file" ? "📎 Sent a file" : "📎 Sent an attachment" : "No messages yet";
4834
- })(), k = b != null && b.created_at ? Xi(new Date(b.created_at)) : "", R = b ? De(b) : !1, A = o ? o(b, S) : `${R ? "✨ " : ""}${S}`, O = n ?? 0;
4841
+ const I = (y = b == null ? void 0 : b.attachments) == null ? void 0 : y[0];
4842
+ return I ? I.og_scrape_url ? I.og_scrape_url : I.type === "image" ? "📷 Sent an image" : I.type === "video" ? "🎥 Sent a video" : I.type === "audio" ? "🎵 Sent audio" : I.type === "file" ? "📎 Sent a file" : "📎 Sent an attachment" : "No messages yet";
4843
+ })(), k = b != null && b.created_at ? Xi(new Date(b.created_at)) : "", R = b ? De(b) : !1, A = o ? o(b, E) : `${R ? "✨ " : ""}${E}`, z = n ?? 0;
4835
4844
  return i && console.log("📺 [ChannelList] 📋 CHANNEL PREVIEW RENDER", {
4836
4845
  channelId: t == null ? void 0 : t.id,
4837
4846
  isSelected: g,
4838
- participantName: w,
4839
- unreadCount: O,
4847
+ participantName: x,
4848
+ unreadCount: z,
4840
4849
  hasTimestamp: !!k
4841
4850
  }), /* @__PURE__ */ s(
4842
4851
  "div",
@@ -4845,7 +4854,7 @@ const zs = j.createContext({
4845
4854
  tabIndex: 0,
4846
4855
  onClick: f,
4847
4856
  onKeyDown: c,
4848
- className: y(
4857
+ className: N(
4849
4858
  "group w-full px-4 py-3 transition-colors text-left max-w-full overflow-hidden focus-ring rounded-[12px] [&+&]:mt-2",
4850
4859
  {
4851
4860
  "bg-black/[0.04]": g,
@@ -4858,7 +4867,7 @@ const zs = j.createContext({
4858
4867
  be,
4859
4868
  {
4860
4869
  id: ((L = v == null ? void 0 : v.user) == null ? void 0 : L.id) || t.id || "unknown",
4861
- name: w,
4870
+ name: x,
4862
4871
  image: p,
4863
4872
  size: 48,
4864
4873
  starred: m
@@ -4869,12 +4878,12 @@ const zs = j.createContext({
4869
4878
  /* @__PURE__ */ h(
4870
4879
  "h3",
4871
4880
  {
4872
- className: y(
4881
+ className: N(
4873
4882
  "text-sm font-medium truncate text-[#191918]"
4874
4883
  ),
4875
4884
  children: [
4876
4885
  m && /* @__PURE__ */ s("span", { className: "sr-only", children: "Starred conversation. " }),
4877
- w
4886
+ x
4878
4887
  ]
4879
4888
  }
4880
4889
  ),
@@ -4882,7 +4891,7 @@ const zs = j.createContext({
4882
4891
  ] }),
4883
4892
  /* @__PURE__ */ h("div", { className: "flex items-center justify-between gap-2 min-w-0", children: [
4884
4893
  /* @__PURE__ */ s("p", { className: "text-sm text-[#717070] flex-1 line-clamp-1", children: A }),
4885
- O > 0 && /* @__PURE__ */ s("span", { className: "bg-[#7f22fe] text-white text-[10px] rounded-full h-4 flex items-center justify-center p-1 min-w-4 text-center flex-shrink-0", children: O > 99 ? "99+" : O })
4894
+ z > 0 && /* @__PURE__ */ s("span", { className: "bg-[#7f22fe] text-white text-[10px] rounded-full h-4 flex items-center justify-center p-1 min-w-4 text-center flex-shrink-0", children: z > 99 ? "99+" : z })
4886
4895
  ] })
4887
4896
  ] })
4888
4897
  ] })
@@ -4908,22 +4917,22 @@ const Ki = { last_message_at: -1 }, Zi = j.memo(
4908
4917
  lockChannelOrder: f,
4909
4918
  onMessageNewHandler: c,
4910
4919
  onMessageNew: v,
4911
- onChannelVisible: w,
4920
+ onChannelVisible: x,
4912
4921
  onAddedToChannel: p,
4913
4922
  onChannelUpdated: b
4914
4923
  }) => {
4915
- const x = j.useRef(0);
4916
- x.current++;
4917
- const { debug: S = !1 } = nt(), k = j.useCallback(
4924
+ const w = j.useRef(0);
4925
+ w.current++;
4926
+ const { debug: E = !1 } = nt(), k = j.useCallback(
4918
4927
  (A) => {
4919
- for (const O of A)
4920
- Hi(O);
4928
+ for (const z of A)
4929
+ Hi(z);
4921
4930
  return r ? r(A) : A;
4922
4931
  },
4923
4932
  [r]
4924
4933
  );
4925
- S && console.log("📺 [ChannelList] 🔄 RENDER START", {
4926
- renderCount: x.current,
4934
+ E && console.log("📺 [ChannelList] 🔄 RENDER START", {
4935
+ renderCount: w.current,
4927
4936
  selectedChannelId: t == null ? void 0 : t.id,
4928
4937
  filters: n
4929
4938
  });
@@ -4931,7 +4940,7 @@ const Ki = { last_message_at: -1 }, Zi = j.memo(
4931
4940
  () => ({
4932
4941
  selectedChannel: t,
4933
4942
  onChannelSelect: e,
4934
- debug: S,
4943
+ debug: E,
4935
4944
  channelPreview: u,
4936
4945
  renderMessagePreview: g,
4937
4946
  viewerLanguage: m
@@ -4939,7 +4948,7 @@ const Ki = { last_message_at: -1 }, Zi = j.memo(
4939
4948
  [
4940
4949
  t,
4941
4950
  e,
4942
- S,
4951
+ E,
4943
4952
  u,
4944
4953
  g,
4945
4954
  m
@@ -4948,7 +4957,7 @@ const Ki = { last_message_at: -1 }, Zi = j.memo(
4948
4957
  return /* @__PURE__ */ s(
4949
4958
  "div",
4950
4959
  {
4951
- className: y(
4960
+ className: N(
4952
4961
  "messaging-channel-list h-full flex flex-col min-w-0 overflow-hidden",
4953
4962
  l
4954
4963
  ),
@@ -4963,7 +4972,7 @@ const Ki = { last_message_at: -1 }, Zi = j.memo(
4963
4972
  lockChannelOrder: f,
4964
4973
  onMessageNewHandler: c,
4965
4974
  onMessageNew: v,
4966
- onChannelVisible: w,
4975
+ onChannelVisible: x,
4967
4976
  onAddedToChannel: p,
4968
4977
  onChannelUpdated: b,
4969
4978
  Paginator: d,
@@ -5014,7 +5023,7 @@ const Qt = `url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' wi
5014
5023
  "div",
5015
5024
  {
5016
5025
  "data-dd-privacy": "mask",
5017
- className: y(
5026
+ className: N(
5018
5027
  "relative px-4 py-3",
5019
5028
  "text-[0.875rem] leading-[1.3125rem] tracking-[0.14px]",
5020
5029
  r
@@ -5059,7 +5068,7 @@ const Qt = `url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' wi
5059
5068
  onClick: t,
5060
5069
  disabled: n,
5061
5070
  style: { backgroundColor: "#E6E5E3" },
5062
- className: y(
5071
+ className: N(
5063
5072
  "w-full text-center p-4 rounded-xl text-charcoal font-medium transition-colors focus-ring",
5064
5073
  {
5065
5074
  "hover:brightness-95 active:brightness-90": !n,
@@ -5150,4 +5159,4 @@ export {
5150
5159
  ls as y,
5151
5160
  it as z
5152
5161
  };
5153
- //# sourceMappingURL=index-BdRJRNr3.js.map
5162
+ //# sourceMappingURL=index-CGWNR062.js.map