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

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