@botonic/webchat-react 2.31.1-alpha.9 → 2.33.0

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.
@@ -1,7 +1,7 @@
1
1
  import { jsx as t, jsxs as f, Fragment as B } from "react/jsx-runtime";
2
2
  import { Button as en, DropdownMenuItem as tt, DropdownMenuItemCheckbox as tn, PopoverTrigger as nn, DropdownMenu as on } from "@lilara/ui-web-react";
3
- import St, { createContext as Re, useContext as Be, useState as N, useRef as S, useCallback as b, useMemo as ce, useEffect as E, forwardRef as G, useLayoutEffect as an } from "react";
4
- import { cva as j, cx as R } from "class-variance-authority";
3
+ import St, { createContext as Pe, useContext as Be, useState as N, useRef as S, useCallback as b, useMemo as ce, useEffect as I, forwardRef as G, useLayoutEffect as an } from "react";
4
+ import { cva as j, cx as P } from "class-variance-authority";
5
5
  import { WebchatController as sn, setupGlobalWebchatAPI as rn, publicWebchatController as ct, isCloseWebviewMessage as ln, isWebviewPostMessage as cn, WEBVIEW_MESSAGE_TYPES as ge, WebchatMessageFactory as nt } from "@botonic/webchat-core";
6
6
  import { useDialog as dn, FocusScope as un, useButton as Nt, useFocusRing as ot, mergeProps as Mt, useObjectRef as mn } from "react-aria";
7
7
  import { useSelector as z } from "@xstate/react";
@@ -10,14 +10,14 @@ import fn from "react-markdown";
10
10
  import pn from "rehype-external-links";
11
11
  import Cn from "remark-breaks";
12
12
  import vn from "remark-gfm";
13
- const It = Re(null);
13
+ const Tt = Pe(null);
14
14
  function q() {
15
- const e = Be(It);
15
+ const e = Be(Tt);
16
16
  if (!e)
17
17
  throw new Error("useWebchatContext must be used within a WebchatProvider");
18
18
  return e;
19
19
  }
20
- const Et = Re(
20
+ const Et = Pe(
21
21
  null
22
22
  );
23
23
  function bn({
@@ -107,7 +107,7 @@ function yn(e) {
107
107
  c,
108
108
  (g) => g.context.overlayState
109
109
  );
110
- return E(() => (rn(o), () => {
110
+ return I(() => (rn(o), () => {
111
111
  o.destroy();
112
112
  }), [o]), {
113
113
  // Framework-agnostic controller - all webchat functionality
@@ -141,7 +141,7 @@ const Sn = G(({ children: e, ...n }, a) => {
141
141
  controller: o.controller,
142
142
  previewUtils: n.previewUtils
143
143
  };
144
- return /* @__PURE__ */ t(It.Provider, { value: s, children: /* @__PURE__ */ t(bn, { children: e }) });
144
+ return /* @__PURE__ */ t(Tt.Provider, { value: s, children: /* @__PURE__ */ t(bn, { children: e }) });
145
145
  }), Nn = {
146
146
  collapsedByDefaultWhenConversationHasMessages: !0,
147
147
  collapseOnUserEngagement: !0,
@@ -172,7 +172,7 @@ const An = {
172
172
  },
173
173
  onUserEngagement: Ae
174
174
  };
175
- function In({
175
+ function Tn({
176
176
  controller: e,
177
177
  isOpen: n,
178
178
  layout: a,
@@ -191,7 +191,7 @@ function In({
191
191
  (A) => Ze(A),
192
192
  (A, M) => A === M
193
193
  );
194
- E(() => {
194
+ I(() => {
195
195
  if (!o) return;
196
196
  if (p === 0) {
197
197
  m(!1), u(!1), h.current = !1, _.current = !1, l.current = 0;
@@ -203,7 +203,7 @@ function In({
203
203
  o,
204
204
  p,
205
205
  s.collapsedByDefaultWhenConversationHasMessages
206
- ]), E(() => {
206
+ ]), I(() => {
207
207
  if (!o || !n || !s.collapsedByDefaultWhenConversationHasMessages) return;
208
208
  Ze(e.machine.getSnapshot()) > 0 && (m(!0), u(!0), h.current = !0);
209
209
  }, [
@@ -214,7 +214,7 @@ function In({
214
214
  ]);
215
215
  const v = b(() => {
216
216
  o && (h.current = !0, u(!0), s.collapseOnUserEngagement && m(!0));
217
- }, [o, s.collapseOnUserEngagement]), w = b(
217
+ }, [o, s.collapseOnUserEngagement]), L = b(
218
218
  (A) => {
219
219
  if (o && h.current) {
220
220
  if (!A) {
@@ -225,7 +225,7 @@ function In({
225
225
  }
226
226
  },
227
227
  [o, s.expandHeroWhenReturningToScrollTop]
228
- ), I = b(
228
+ ), T = b(
229
229
  (A) => {
230
230
  o && C(A);
231
231
  },
@@ -239,27 +239,27 @@ function In({
239
239
  },
240
240
  messages: {
241
241
  hasUserInteracted: d,
242
- onScrollDepthChange: I,
243
- onMessagesScrollAtTopChange: w,
242
+ onScrollDepthChange: T,
243
+ onMessagesScrollAtTopChange: L,
244
244
  onUserInteraction: v
245
245
  },
246
246
  onUserEngagement: v
247
247
  } : An;
248
248
  }
249
- const En = "backdrop-module__base___2047X", Tn = {
249
+ const En = "backdrop-module__base___2047X", In = {
250
250
  base: En
251
251
  };
252
252
  function xn({ isClosing: e = !1 }) {
253
253
  return /* @__PURE__ */ t(
254
254
  "div",
255
255
  {
256
- className: Tn.base,
256
+ className: In.base,
257
257
  "aria-hidden": !0,
258
258
  "data-closing": e || void 0
259
259
  }
260
260
  );
261
261
  }
262
- function Pn() {
262
+ function Rn() {
263
263
  return /* @__PURE__ */ t(
264
264
  "svg",
265
265
  {
@@ -272,7 +272,7 @@ function Pn() {
272
272
  }
273
273
  );
274
274
  }
275
- function Rn() {
275
+ function Pn() {
276
276
  return /* @__PURE__ */ t(
277
277
  "svg",
278
278
  {
@@ -285,13 +285,13 @@ function Rn() {
285
285
  }
286
286
  );
287
287
  }
288
- const Bn = "dialog-module__base___K18e8", kn = "dialog-module__success___z5NAQ", On = "dialog-module__error___Q46VR", Dn = "dialog-module__loading___21312", Wn = "dialog-module__actions___xFizf", Vn = "dialog-module__closing___qgRFX", zn = "dialog-module__iconContainer___8lOJ3", Fn = "dialog-module__spinner___jL0bN", Hn = "dialog-module__textContent___t6Tqt", Un = "dialog-module__title___jr3if", $n = "dialog-module__subtitle___K1uUB", Z = {
288
+ const Bn = "dialog-module__base___K18e8", kn = "dialog-module__success___z5NAQ", On = "dialog-module__error___Q46VR", Dn = "dialog-module__loading___21312", Vn = "dialog-module__actions___xFizf", Wn = "dialog-module__closing___qgRFX", zn = "dialog-module__iconContainer___8lOJ3", Fn = "dialog-module__spinner___jL0bN", Hn = "dialog-module__textContent___t6Tqt", Un = "dialog-module__title___jr3if", $n = "dialog-module__subtitle___K1uUB", Z = {
289
289
  base: Bn,
290
290
  success: kn,
291
291
  error: On,
292
292
  loading: Dn,
293
- actions: Wn,
294
- closing: Vn,
293
+ actions: Vn,
294
+ closing: Wn,
295
295
  iconContainer: zn,
296
296
  spinner: Fn,
297
297
  textContent: Hn,
@@ -325,7 +325,7 @@ function qn({
325
325
  const m = (g) => (g ?? "solid") === "solid";
326
326
  return Number(m(u.appearance)) - Number(m(c.appearance));
327
327
  }), h = S(null), { dialogProps: _, titleProps: d } = dn({ role: "dialog" }, h);
328
- return E(() => {
328
+ return I(() => {
329
329
  h.current && h.current.focus();
330
330
  }, [e]), /* @__PURE__ */ t(un, { contain: !0, restoreFocus: !0, autoFocus: !0, children: /* @__PURE__ */ f(
331
331
  "div",
@@ -344,8 +344,8 @@ function qn({
344
344
  "aria-hidden": !0,
345
345
  children: [
346
346
  e === "loading" && /* @__PURE__ */ t("div", { className: Z.spinner }, "loading"),
347
- e === "success" && /* @__PURE__ */ t(Pn, {}, "success"),
348
- e === "error" && /* @__PURE__ */ t(Rn, {}, "error")
347
+ e === "success" && /* @__PURE__ */ t(Rn, {}, "success"),
348
+ e === "error" && /* @__PURE__ */ t(Pn, {}, "error")
349
349
  ]
350
350
  }
351
351
  ),
@@ -358,9 +358,9 @@ function qn({
358
358
  }
359
359
  ) });
360
360
  }
361
- const Tt = Re(null);
361
+ const It = Pe(null);
362
362
  function xt() {
363
- const e = Be(Tt);
363
+ const e = Be(It);
364
364
  if (!e)
365
365
  throw new Error("useDialog must be used within a DialogProvider");
366
366
  return e;
@@ -406,7 +406,7 @@ function jn({
406
406
  }
407
407
  r(!0);
408
408
  }, []);
409
- a && (a.current = { open: d, update: u, close: c }), E(() => {
409
+ a && (a.current = { open: d, update: u, close: c }), I(() => {
410
410
  if (process.env.NODE_ENV !== "production") {
411
411
  const C = document.querySelector(
412
412
  "[data-webchat-container], [data-webview-frame]"
@@ -417,7 +417,7 @@ function jn({
417
417
  }
418
418
  }, []);
419
419
  const m = o.isOpen || i, g = { open: d, update: u, close: c, dialogState: o };
420
- return /* @__PURE__ */ f(Tt.Provider, { value: g, children: [
420
+ return /* @__PURE__ */ f(It.Provider, { value: g, children: [
421
421
  e,
422
422
  m && /* @__PURE__ */ t(xn, { isClosing: i }),
423
423
  m && /* @__PURE__ */ t(
@@ -441,7 +441,7 @@ function Qn({
441
441
  const o = S(null), s = () => {
442
442
  a.current();
443
443
  };
444
- return E(() => (ct.setDialogController({
444
+ return I(() => (ct.setDialogController({
445
445
  open: (i) => o.current?.open(i),
446
446
  update: (i) => o.current?.update(i),
447
447
  close: () => o.current?.close()
@@ -449,21 +449,21 @@ function Qn({
449
449
  ct.setDialogController(void 0);
450
450
  }), []), /* @__PURE__ */ t(jn, { onOpen: s, controlsRef: o, children: e });
451
451
  }
452
- const Pt = Re(null);
452
+ const Rt = Pe(null);
453
453
  function Oe() {
454
- const e = Be(Pt);
454
+ const e = Be(Rt);
455
455
  if (!e)
456
456
  throw new Error("useOverlayContext must be used within an Overlay");
457
457
  return e;
458
458
  }
459
- const Zn = "cover-frame-module__base___e38vU", Xn = "cover-frame-module__errorContainer___o19mQ", Yn = "cover-frame-module__errorText___ltF9m", Je = {
459
+ const Zn = "cover-frame-module__base___e38vU", Yn = "cover-frame-module__errorContainer___o19mQ", Xn = "cover-frame-module__errorText___ltF9m", Je = {
460
460
  base: Zn,
461
- errorContainer: Xn,
462
- errorText: Yn
461
+ errorContainer: Yn,
462
+ errorText: Xn
463
463
  }, dt = j(Je.base);
464
464
  function Jn({ className: e }) {
465
465
  const { overlayState: n, coverRegistry: a, setIsLoading: o } = Oe();
466
- if (E(() => {
466
+ if (I(() => {
467
467
  n?.type === "cover" && o(!1);
468
468
  }, [n?.type, o]), !n || n.type !== "cover")
469
469
  return null;
@@ -616,11 +616,11 @@ function bo(e, n) {
616
616
  l,
617
617
  h
618
618
  ]);
619
- return E(() => {
619
+ return I(() => {
620
620
  e?.isOpen && e?.type === "webview" && o(!0);
621
- }, [e?.isOpen, e?.type]), E(() => {
621
+ }, [e?.isOpen, e?.type]), I(() => {
622
622
  e?.type === "webview" && o(!0);
623
- }, [e?.type === "webview" ? e.url : null]), E(() => {
623
+ }, [e?.type === "webview" ? e.url : null]), I(() => {
624
624
  if (e?.type !== "webview")
625
625
  return;
626
626
  const d = (u) => {
@@ -655,7 +655,7 @@ function bo(e, n) {
655
655
  return window.addEventListener("message", d), () => {
656
656
  window.removeEventListener("message", d);
657
657
  };
658
- }, [n, _, e?.type]), E(() => {
658
+ }, [n, _, e?.type]), I(() => {
659
659
  const d = (u) => {
660
660
  if (u.key === "Escape") {
661
661
  if (r.isOpen) {
@@ -723,7 +723,7 @@ function yo({
723
723
  attemptClose: m,
724
724
  coverRegistry: h
725
725
  };
726
- return /* @__PURE__ */ t(Pt.Provider, { value: C, children: /* @__PURE__ */ t("div", { className: Lo(g), "data-overlay": !0, children: _ || /* @__PURE__ */ f(B, { children: [
726
+ return /* @__PURE__ */ t(Rt.Provider, { value: C, children: /* @__PURE__ */ t("div", { className: Lo(g), "data-overlay": !0, children: _ || /* @__PURE__ */ f(B, { children: [
727
727
  /* @__PURE__ */ t(fo, {}),
728
728
  /* @__PURE__ */ t(ro, {})
729
729
  ] }) }) });
@@ -744,7 +744,7 @@ function So(e, n, a) {
744
744
  },
745
745
  [u]
746
746
  );
747
- return E(() => {
747
+ return I(() => {
748
748
  const v = C.current;
749
749
  C.current = d, v === !1 && d ? (g(!0), c("opening")) : v === !0 && !d && c("closing");
750
750
  }, [d]), {
@@ -838,10 +838,10 @@ function Ao(e) {
838
838
  ), v = b(
839
839
  (y) => a.overlay.setConfirmClose(y),
840
840
  [a]
841
- ), w = b(
841
+ ), L = b(
842
842
  (y) => a.overlay.sendPayload(y),
843
843
  [a]
844
- ), I = b(
844
+ ), T = b(
845
845
  (y) => a.overlay.navigate(y),
846
846
  [a]
847
847
  );
@@ -864,8 +864,8 @@ function Ao(e) {
864
864
  onSetIcon: C,
865
865
  onSetAllowClose: p,
866
866
  onSetConfirmClose: v,
867
- onSendPayload: w,
868
- onNavigate: I,
867
+ onSendPayload: L,
868
+ onNavigate: T,
869
869
  coverRegistry: h
870
870
  }
871
871
  )
@@ -873,7 +873,7 @@ function Ao(e) {
873
873
  }
874
874
  ) : null;
875
875
  }
876
- function Io() {
876
+ function To() {
877
877
  return /* @__PURE__ */ f(
878
878
  "svg",
879
879
  {
@@ -909,7 +909,7 @@ function Eo() {
909
909
  }
910
910
  );
911
911
  }
912
- function To(e) {
912
+ function Io(e) {
913
913
  return Math.min(1, Math.max(0, e));
914
914
  }
915
915
  function xo(e, n, a) {
@@ -928,7 +928,7 @@ function xo(e, n, a) {
928
928
  className: g,
929
929
  style: C,
930
930
  ...p
931
- } = e, v = s ?? n.avatarConfig?.bot?.src, w = n.avatarConfig?.bot?.svg, I = i ?? n.avatarConfig?.bot?.alt, y = z(
931
+ } = e, v = s ?? n.avatarConfig?.bot?.src, L = n.avatarConfig?.bot?.svg, T = i ?? n.avatarConfig?.bot?.alt, y = z(
932
932
  n.controller.machine,
933
933
  (F) => F.context.connectionStatus || "disconnected"
934
934
  ), A = b(() => {
@@ -948,11 +948,11 @@ function xo(e, n, a) {
948
948
  default:
949
949
  return "Offline";
950
950
  }
951
- }, []), k = r ? M(y) : void 0, W = _ !== "expanded", V = c ?? n.enableResponsiveHeroHeader ?? !0, X = To(
952
- d ?? Number(W)
953
- ), Y = {
951
+ }, []), k = r ? M(y) : void 0, V = _ !== "expanded", W = c ?? n.enableResponsiveHeroHeader ?? !0, Y = Io(
952
+ d ?? Number(V)
953
+ ), X = {
954
954
  ...C,
955
- "--webchat-header-collapse-progress": String(X)
955
+ "--webchat-header-collapse-progress": String(Y)
956
956
  };
957
957
  return {
958
958
  // Header element props
@@ -960,14 +960,14 @@ function xo(e, n, a) {
960
960
  ...p,
961
961
  ref: a,
962
962
  "aria-label": m || `${o} header`,
963
- style: Y,
964
- "data-webchat-responsive-hero": V ? "on" : "off"
963
+ style: X,
964
+ "data-webchat-responsive-hero": W ? "on" : "off"
965
965
  },
966
966
  // Header content
967
967
  title: o,
968
968
  avatarSrc: v,
969
- avatarSvg: w,
970
- avatarAlt: I,
969
+ avatarSvg: L,
970
+ avatarAlt: T,
971
971
  showStatus: r,
972
972
  statusText: k,
973
973
  showClose: l,
@@ -981,10 +981,10 @@ function xo(e, n, a) {
981
981
  }
982
982
  };
983
983
  }
984
- const Po = "webchat-header-module__base___VbIWd", Ro = "webchat-header-module__profile___NsohW", Bo = "webchat-header-module__avatar___klWPr", ko = "webchat-header-module__collapsed___Xwj3m", Oo = "webchat-header-module__expanded___9RKFH", D = {
985
- base: Po,
984
+ const Ro = "webchat-header-module__base___VbIWd", Po = "webchat-header-module__profile___NsohW", Bo = "webchat-header-module__avatar___klWPr", ko = "webchat-header-module__collapsed___Xwj3m", Oo = "webchat-header-module__expanded___9RKFH", D = {
985
+ base: Ro,
986
986
  "header-content": "webchat-header-module__header-content___bPP9l",
987
- profile: Ro,
987
+ profile: Po,
988
988
  avatar: Bo,
989
989
  "header-text": "webchat-header-module__header-text___64Yj9",
990
990
  "header-title": "webchat-header-module__header-title___QHcHi",
@@ -998,7 +998,7 @@ const Po = "webchat-header-module__base___VbIWd", Ro = "webchat-header-module__p
998
998
  "has-shadow": "webchat-header-module__has-shadow___uQ7mG",
999
999
  collapsed: ko,
1000
1000
  expanded: Oo
1001
- }, Rt = G((e, n) => {
1001
+ }, Pt = G((e, n) => {
1002
1002
  const a = mn(n), { buttonProps: o } = Nt(e, a), { focusProps: s, isFocusVisible: i } = ot();
1003
1003
  return /* @__PURE__ */ t(
1004
1004
  "button",
@@ -1022,12 +1022,12 @@ function Do(e) {
1022
1022
  className: D["header-button"],
1023
1023
  "aria-label": e["aria-label"] ?? "Close chat",
1024
1024
  "data-focus-visible": s || void 0,
1025
- children: /* @__PURE__ */ t(Io, {})
1025
+ children: /* @__PURE__ */ t(To, {})
1026
1026
  }
1027
1027
  );
1028
1028
  }
1029
- Rt.displayName = "MenuTriggerButton";
1030
- const Wo = j(D.base, {
1029
+ Pt.displayName = "MenuTriggerButton";
1030
+ const Vo = j(D.base, {
1031
1031
  variants: {
1032
1032
  variant: {
1033
1033
  default: D.collapsed,
@@ -1042,7 +1042,7 @@ const Wo = j(D.base, {
1042
1042
  variant: "collapsed"
1043
1043
  }
1044
1044
  });
1045
- function Vo({
1045
+ function Wo({
1046
1046
  children: e,
1047
1047
  ...n
1048
1048
  }) {
@@ -1063,7 +1063,7 @@ function Vo({
1063
1063
  "header",
1064
1064
  {
1065
1065
  ...s,
1066
- className: Wo(g),
1066
+ className: Vo(g),
1067
1067
  "data-webchat-header": !0,
1068
1068
  children: /* @__PURE__ */ f("div", { className: D["header-content"], children: [
1069
1069
  /* @__PURE__ */ f("div", { className: D.profile, children: [
@@ -1194,7 +1194,7 @@ function Zo({
1194
1194
  const { menuItemProps: a } = Qo({ onClose: e });
1195
1195
  return /* @__PURE__ */ t(tt, { icon: /* @__PURE__ */ t($o, {}), onPress: a.onPress, children: n ?? "Reset session" });
1196
1196
  }
1197
- function Xo() {
1197
+ function Yo() {
1198
1198
  return /* @__PURE__ */ t(
1199
1199
  "svg",
1200
1200
  {
@@ -1207,7 +1207,7 @@ function Xo() {
1207
1207
  }
1208
1208
  );
1209
1209
  }
1210
- function Yo({
1210
+ function Xo({
1211
1211
  onClose: e,
1212
1212
  children: n
1213
1213
  }) {
@@ -1215,7 +1215,7 @@ function Yo({
1215
1215
  return /* @__PURE__ */ t(
1216
1216
  tn,
1217
1217
  {
1218
- icon: /* @__PURE__ */ t(Xo, {}),
1218
+ icon: /* @__PURE__ */ t(Yo, {}),
1219
1219
  isSelected: s,
1220
1220
  onChange: (i) => o.toggleSounds(i),
1221
1221
  children: n ?? "Sounds"
@@ -1404,7 +1404,7 @@ function va(e) {
1404
1404
  }
1405
1405
  function ba() {
1406
1406
  const { controller: e } = q(), [n, a] = N([]), [o, s] = N(), i = S(null), r = S(/* @__PURE__ */ new Map());
1407
- E(() => {
1407
+ I(() => {
1408
1408
  const c = r.current;
1409
1409
  return () => {
1410
1410
  c.forEach((m) => URL.revokeObjectURL(m));
@@ -1463,12 +1463,12 @@ function ba() {
1463
1463
  }
1464
1464
  };
1465
1465
  }
1466
- const wa = "audio-waveform-module__waveform___xs7iO", Wt = {
1466
+ const wa = "audio-waveform-module__waveform___xs7iO", Vt = {
1467
1467
  waveform: wa
1468
1468
  }, La = 30, ya = 1e3 / La, Sa = 24, mt = 2, _t = 3;
1469
1469
  function Na({ analyserNode: e }) {
1470
1470
  const n = S(null), a = S(void 0), o = S(0);
1471
- return E(() => {
1471
+ return I(() => {
1472
1472
  const s = n.current;
1473
1473
  if (!s) return;
1474
1474
  const i = () => {
@@ -1498,19 +1498,19 @@ function Na({ analyserNode: e }) {
1498
1498
  const m = window.devicePixelRatio ?? 1, g = s.width, C = s.height, p = mt * m, v = Math.max(
1499
1499
  1,
1500
1500
  Math.floor(g / m / (mt + _t))
1501
- ), w = _t * m;
1501
+ ), L = _t * m;
1502
1502
  l.clearRect(0, 0, g, C), l.fillStyle = "currentColor";
1503
- const I = Math.floor(h * 0.5);
1503
+ const T = Math.floor(h * 0.5);
1504
1504
  for (let y = 0; y < v; y++) {
1505
- const A = Math.floor(y / v * I), M = _[A], k = Math.max(p, M / 255 * C * 1.1), W = y * (p + w), V = (C - k) / 2;
1506
- d(W, V, p, k);
1505
+ const A = Math.floor(y / v * T), M = _[A], k = Math.max(p, M / 255 * C * 1.1), V = y * (p + L), W = (C - k) / 2;
1506
+ d(V, W, p, k);
1507
1507
  }
1508
1508
  a.current = requestAnimationFrame(u);
1509
1509
  }
1510
1510
  return a.current = requestAnimationFrame(u), () => {
1511
1511
  a.current !== void 0 && cancelAnimationFrame(a.current), r.disconnect();
1512
1512
  };
1513
- }, [e]), /* @__PURE__ */ t("canvas", { ref: n, className: Wt.waveform, "aria-hidden": !0 });
1513
+ }, [e]), /* @__PURE__ */ t("canvas", { ref: n, className: Vt.waveform, "aria-hidden": !0 });
1514
1514
  }
1515
1515
  const Ma = 24, ht = 2, gt = 3;
1516
1516
  function Aa(e, n, a, o, s) {
@@ -1521,7 +1521,7 @@ function Aa(e, n, a, o, s) {
1521
1521
  }
1522
1522
  e.beginPath(), e.moveTo(n + i, a), e.arcTo(n + o, a, n + o, a + i, i), e.lineTo(n + o, a + s - i), e.arcTo(n + o, a + s, n + i, a + s, i), e.lineTo(n + i, a + s), e.arcTo(n, a + s, n, a + s - i, i), e.lineTo(n, a + i), e.arcTo(n, a, n + i, a, i), e.closePath(), e.fill();
1523
1523
  }
1524
- function Ia(e, n, a, o, s) {
1524
+ function Ta(e, n, a, o, s) {
1525
1525
  const i = window.devicePixelRatio ?? 1;
1526
1526
  e.clearRect(0, 0, n, a), e.fillStyle = "currentColor";
1527
1527
  const r = ht * i, l = gt * i, h = Math.max(
@@ -1535,7 +1535,7 @@ function Ia(e, n, a, o, s) {
1535
1535
  Math.floor((g + 1) / h * o.length)
1536
1536
  );
1537
1537
  let v = 0;
1538
- for (let w = C; w < p; w++) v += Math.abs(o[w]);
1538
+ for (let L = C; L < p; L++) v += Math.abs(o[L]);
1539
1539
  u[g] = v / (p - C);
1540
1540
  } else
1541
1541
  u[g] = 0.1 + 0.1 * Math.abs(Math.sin(g * 0.9)) + 0.07 * Math.abs(Math.sin(g * 1.7));
@@ -1549,11 +1549,11 @@ function Ia(e, n, a, o, s) {
1549
1549
  }
1550
1550
  e.globalAlpha = 1;
1551
1551
  }
1552
- function Ie(e, n, a) {
1552
+ function Te(e, n, a) {
1553
1553
  const o = window.devicePixelRatio ?? 1, s = Math.max(e.clientWidth, 60), i = Math.round(s * o), r = Ma * o;
1554
1554
  e.width !== i && (e.width = i), e.height !== r && (e.height = r);
1555
1555
  const l = e.getContext("2d");
1556
- l && Ia(l, e.width, e.height, n, a);
1556
+ l && Ta(l, e.width, e.height, n, a);
1557
1557
  }
1558
1558
  function Ea(e) {
1559
1559
  return Math.min(1, Math.max(0, e));
@@ -1562,31 +1562,31 @@ function ft(e, n) {
1562
1562
  const a = e.getBoundingClientRect();
1563
1563
  return Ea((n - a.left) / a.width);
1564
1564
  }
1565
- function Vt({
1565
+ function Wt({
1566
1566
  audioBlob: e,
1567
1567
  progress: n,
1568
1568
  onSeek: a
1569
1569
  }) {
1570
1570
  const o = S(null), s = S(null), i = S(n), r = S(a);
1571
- i.current = n, r.current = a, E(() => {
1571
+ i.current = n, r.current = a, I(() => {
1572
1572
  const _ = o.current;
1573
1573
  if (!_) return;
1574
1574
  let d = !1;
1575
- s.current = null, Ie(_, null, i.current);
1575
+ s.current = null, Te(_, null, i.current);
1576
1576
  const u = new ResizeObserver(() => {
1577
- d || Ie(_, s.current, i.current);
1577
+ d || Te(_, s.current, i.current);
1578
1578
  });
1579
1579
  u.observe(_);
1580
1580
  const c = new AudioContext();
1581
1581
  return e.arrayBuffer().then((m) => c.decodeAudioData(m)).then((m) => {
1582
- d || (s.current = m.getChannelData(0), Ie(_, s.current, i.current));
1582
+ d || (s.current = m.getChannelData(0), Te(_, s.current, i.current));
1583
1583
  }).catch(() => {
1584
1584
  }).finally(() => c.close()), () => {
1585
1585
  d = !0, u.disconnect();
1586
1586
  };
1587
- }, [e]), E(() => {
1587
+ }, [e]), I(() => {
1588
1588
  const _ = o.current;
1589
- _ && Ie(_, s.current, n);
1589
+ _ && Te(_, s.current, n);
1590
1590
  }, [n]);
1591
1591
  const l = b(
1592
1592
  (_) => {
@@ -1607,7 +1607,7 @@ function Vt({
1607
1607
  "canvas",
1608
1608
  {
1609
1609
  ref: o,
1610
- className: Wt.waveform,
1610
+ className: Vt.waveform,
1611
1611
  "data-seekable": !!a,
1612
1612
  "aria-hidden": !0,
1613
1613
  onPointerDown: a ? l : void 0,
@@ -1615,7 +1615,7 @@ function Vt({
1615
1615
  }
1616
1616
  );
1617
1617
  }
1618
- function Ta() {
1618
+ function Ia() {
1619
1619
  return /* @__PURE__ */ t(
1620
1620
  "svg",
1621
1621
  {
@@ -1690,14 +1690,14 @@ function xa({
1690
1690
  handleAudioPlay: C,
1691
1691
  handleAudioPause: p,
1692
1692
  handleAudioEnded: v,
1693
- handleAudioLoadedMetadata: w,
1694
- handleAudioTimeUpdate: I
1693
+ handleAudioLoadedMetadata: L,
1694
+ handleAudioTimeUpdate: T
1695
1695
  }) {
1696
1696
  return /* @__PURE__ */ f(B, { children: [
1697
1697
  e && /* @__PURE__ */ f(
1698
1698
  "div",
1699
1699
  {
1700
- className: R(
1700
+ className: P(
1701
1701
  re["recording-controls"],
1702
1702
  n
1703
1703
  ),
@@ -1709,13 +1709,13 @@ function xa({
1709
1709
  className: re["recording-side-btn"],
1710
1710
  "aria-label": h ? "Discard recording" : "Cancel recording",
1711
1711
  onClick: u,
1712
- children: /* @__PURE__ */ t(Ta, {})
1712
+ children: /* @__PURE__ */ t(Ia, {})
1713
1713
  }
1714
1714
  ),
1715
1715
  /* @__PURE__ */ f(
1716
1716
  "div",
1717
1717
  {
1718
- className: R(
1718
+ className: P(
1719
1719
  re["recording-pill"],
1720
1720
  a ? re["recording-pill--recording"] : re["recording-pill--preview"]
1721
1721
  ),
@@ -1731,7 +1731,7 @@ function xa({
1731
1731
  }
1732
1732
  ),
1733
1733
  a && s ? /* @__PURE__ */ t(Na, { analyserNode: s }) : o && i ? /* @__PURE__ */ t(
1734
- Vt,
1734
+ Wt,
1735
1735
  {
1736
1736
  audioBlob: i,
1737
1737
  progress: r,
@@ -1753,20 +1753,20 @@ function xa({
1753
1753
  onPlay: C,
1754
1754
  onPause: p,
1755
1755
  onEnded: v,
1756
- onLoadedMetadata: w,
1757
- onTimeUpdate: I,
1756
+ onLoadedMetadata: L,
1757
+ onTimeUpdate: T,
1758
1758
  style: { display: "none" }
1759
1759
  }
1760
1760
  )
1761
1761
  ] });
1762
1762
  }
1763
- function Pa() {
1763
+ function Ra() {
1764
1764
  return typeof window < "u" && typeof navigator.mediaDevices?.getUserMedia == "function" && typeof MediaRecorder < "u";
1765
1765
  }
1766
- function Ra() {
1766
+ function Pa() {
1767
1767
  const [e, n] = N("idle"), [a, o] = N(void 0), [s, i] = N(
1768
1768
  void 0
1769
- ), [r, l] = N(!1), h = Pa(), _ = S(void 0), d = S(void 0), u = S(void 0), c = S([]), m = b(() => {
1769
+ ), [r, l] = N(!1), h = Ra(), _ = S(void 0), d = S(void 0), u = S(void 0), c = S([]), m = b(() => {
1770
1770
  d.current?.getTracks().forEach((v) => v.stop()), d.current = void 0, u.current?.close(), u.current = void 0, i(void 0);
1771
1771
  }, []), g = b(async () => {
1772
1772
  if (!h || e !== "idle") return;
@@ -1779,10 +1779,10 @@ function Ra() {
1779
1779
  return;
1780
1780
  }
1781
1781
  d.current = v;
1782
- const w = new AudioContext();
1783
- u.current = w;
1784
- const I = w.createMediaStreamSource(v), y = w.createAnalyser();
1785
- y.fftSize = 256, I.connect(y), i(y), c.current = [];
1782
+ const L = new AudioContext();
1783
+ u.current = L;
1784
+ const T = L.createMediaStreamSource(v), y = L.createAnalyser();
1785
+ y.fftSize = 256, T.connect(y), i(y), c.current = [];
1786
1786
  const A = new MediaRecorder(v);
1787
1787
  _.current = A, A.ondataavailable = (M) => {
1788
1788
  M.data.size > 0 && c.current.push(M.data);
@@ -1790,16 +1790,16 @@ function Ra() {
1790
1790
  }, [h, e]), C = b(() => {
1791
1791
  const v = _.current;
1792
1792
  !v || e !== "recording" || (v.onstop = () => {
1793
- const w = new Blob(c.current, {
1793
+ const L = new Blob(c.current, {
1794
1794
  type: v.mimeType || "audio/webm"
1795
1795
  });
1796
- o(w), n("preview");
1796
+ o(L), n("preview");
1797
1797
  }, v.stop(), m());
1798
1798
  }, [e, m]), p = b(() => {
1799
1799
  const v = _.current;
1800
1800
  v && v.state !== "inactive" && (v.onstop = null, v.stop()), m(), c.current = [], o(void 0), n("idle");
1801
1801
  }, [m]);
1802
- return E(() => () => {
1802
+ return I(() => () => {
1803
1803
  const v = _.current;
1804
1804
  v && v.state !== "inactive" && (v.onstop = null, v.stop()), m();
1805
1805
  }, [m]), {
@@ -1813,11 +1813,11 @@ function Ra() {
1813
1813
  cancelRecording: p
1814
1814
  };
1815
1815
  }
1816
- function Pe(e) {
1816
+ function Re(e) {
1817
1817
  const n = String(Math.floor(e / 60)).padStart(2, "0"), a = String(Math.floor(e % 60)).padStart(2, "0");
1818
1818
  return `${n}:${a}`;
1819
1819
  }
1820
- const Xe = "audio-recording", fe = "audio-preview", Ba = 120;
1820
+ const Ye = "audio-recording", fe = "audio-preview", Ba = 120;
1821
1821
  function ka(e) {
1822
1822
  return new Promise((n, a) => {
1823
1823
  const o = new FileReader();
@@ -1826,7 +1826,7 @@ function ka(e) {
1826
1826
  }
1827
1827
  function Oa(e) {
1828
1828
  const [n, a] = N(e), [o, s] = N(!1), i = S();
1829
- return E(() => (e ? (clearTimeout(i.current), a(!0), s(!1)) : (s(!0), i.current = setTimeout(() => {
1829
+ return I(() => (e ? (clearTimeout(i.current), a(!0), s(!1)) : (s(!0), i.current = setTimeout(() => {
1830
1830
  a(!1), s(!1);
1831
1831
  }, Ba)), () => {
1832
1832
  clearTimeout(i.current);
@@ -1841,21 +1841,21 @@ function Da(e, n) {
1841
1841
  startRecording: d,
1842
1842
  confirmRecording: u,
1843
1843
  cancelRecording: c
1844
- } = Ra(), m = e.webchatClientSettingsBehaviors.input.isAudioRecordingVisible && _, [g, C] = N(0), p = S(
1844
+ } = Pa(), m = e.webchatClientSettingsBehaviors.input.isAudioRecordingVisible && _, [g, C] = N(0), p = S(
1845
1845
  void 0
1846
- ), v = S(null), [w, I] = N(""), [y, A] = N(!1), [M, k] = N(0), [W, V] = N(0);
1847
- E(() => (r === "recording" ? (C(0), p.current = setInterval(() => {
1846
+ ), v = S(null), [L, T] = N(""), [y, A] = N(!1), [M, k] = N(0), [V, W] = N(0);
1847
+ I(() => (r === "recording" ? (C(0), p.current = setInterval(() => {
1848
1848
  C((O) => O + 1);
1849
- }, 1e3)) : (clearInterval(p.current), r === "idle" && (C(0), k(0), V(0), A(!1))), () => clearInterval(p.current)), [r]), E(() => {
1849
+ }, 1e3)) : (clearInterval(p.current), r === "idle" && (C(0), k(0), W(0), A(!1))), () => clearInterval(p.current)), [r]), I(() => {
1850
1850
  if (!l) {
1851
- I("");
1851
+ T("");
1852
1852
  return;
1853
1853
  }
1854
1854
  const O = URL.createObjectURL(l);
1855
- return I(O), () => URL.revokeObjectURL(O);
1855
+ return T(O), () => URL.revokeObjectURL(O);
1856
1856
  }, [l]);
1857
- const X = Pe(r === "recording" ? g : y ? W : M), Y = M > 0 ? W / M : 0;
1858
- E(() => {
1857
+ const Y = Re(r === "recording" ? g : y ? V : M), X = M > 0 ? V / M : 0;
1858
+ I(() => {
1859
1859
  o !== fe && y && v.current?.pause();
1860
1860
  }, [o, y]);
1861
1861
  const F = b(() => {
@@ -1871,21 +1871,21 @@ function Da(e, n) {
1871
1871
  []
1872
1872
  ), Ne = b(
1873
1873
  (O) => {
1874
- V(Math.round(O.currentTarget.currentTime));
1874
+ W(Math.round(O.currentTarget.currentTime));
1875
1875
  },
1876
1876
  []
1877
- ), Ve = b(() => {
1877
+ ), We = b(() => {
1878
1878
  const O = v.current;
1879
1879
  O && (y ? O.pause() : O.play().catch(() => A(!1)));
1880
1880
  }, [y]), ze = b(() => {
1881
- m && (s(Xe), d());
1881
+ m && (s(Ye), d());
1882
1882
  }, [m, s, d]), Fe = b(() => {
1883
- i(Xe), u();
1883
+ i(Ye), u();
1884
1884
  }, [i, u]), He = b(() => {
1885
- i(Xe), i(fe), c();
1885
+ i(Ye), i(fe), c();
1886
1886
  }, [i, c]), he = b(
1887
1887
  (O) => {
1888
- !v.current || M === 0 || (v.current.currentTime = O * M, V(Math.round(v.current.currentTime)));
1888
+ !v.current || M === 0 || (v.current.currentTime = O * M, W(Math.round(v.current.currentTime)));
1889
1889
  },
1890
1890
  [M]
1891
1891
  ), Ue = b(() => {
@@ -1917,14 +1917,14 @@ function Da(e, n) {
1917
1917
  frozenIsPreview: ue,
1918
1918
  analyserNode: h,
1919
1919
  audioBlob: l,
1920
- audioProgress: Y,
1920
+ audioProgress: X,
1921
1921
  isPlaying: y,
1922
1922
  isPreview: ee,
1923
- handlePlayPause: Ve,
1923
+ handlePlayPause: We,
1924
1924
  handleSeekPreview: he,
1925
1925
  handleCancelRecording: He,
1926
- timerDisplay: X,
1927
- objectUrl: w,
1926
+ timerDisplay: Y,
1927
+ objectUrl: L,
1928
1928
  audioRef: v,
1929
1929
  handleAudioPlay: F,
1930
1930
  handleAudioPause: J,
@@ -1934,10 +1934,10 @@ function Da(e, n) {
1934
1934
  }
1935
1935
  };
1936
1936
  }
1937
- function Wa() {
1937
+ function Va() {
1938
1938
  return /* @__PURE__ */ t("svg", { ..._e, viewBox: "0 0 448 512", children: /* @__PURE__ */ t("path", { d: "M364.2 83.8c-24.4-24.4-64-24.4-88.4 0l-184 184c-42.1 42.1-42.1 110.3 0 152.4s110.3 42.1 152.4 0l152-152c10.9-10.9 28.7-10.9 39.6 0s10.9 28.7 0 39.6l-152 152c-64 64-167.6 64-231.6 0s-64-167.6 0-231.6l184-184c46.3-46.3 121.3-46.3 167.6 0s46.3 121.3 0 167.6l-176 176c-28.6 28.6-75 28.6-103.6 0s-28.6-75 0-103.6l144-144c10.9-10.9 28.7-10.9 39.6 0s10.9 28.7 0 39.6l-144 144c-6.7 6.7-6.7 17.7 0 24.4s17.7 6.7 24.4 0l176-176c24.4-24.4 24.4-64 0-88.4z" }) });
1939
1939
  }
1940
- function Va() {
1940
+ function Wa() {
1941
1941
  return /* @__PURE__ */ t(
1942
1942
  "svg",
1943
1943
  {
@@ -1977,7 +1977,7 @@ function Fa() {
1977
1977
  function pt() {
1978
1978
  return /* @__PURE__ */ t("svg", { ..._e, children: /* @__PURE__ */ t("path", { d: "M57.6 35.8C23.1 20.6-11.3 57.4 6.1 90.9l63 121.2c4.4 8.4 12.6 14.1 22 15.3L266 249.3c3.4 .4 6 3.3 6 6.7s-2.6 6.3-6 6.7L91.1 284.6c-9.4 1.2-17.6 6.9-22 15.3L6.1 421.1c-17.4 33.5 17 70.2 51.6 55.1L492.9 285.3c25.5-11.2 25.5-47.4 0-58.6L57.6 35.8z" }) });
1979
1979
  }
1980
- const Ha = "webchat-input-module__base___TZXU7", Ua = "webchat-input-module__branding___ReLzJ", P = {
1980
+ const Ha = "webchat-input-module__base___TZXU7", Ua = "webchat-input-module__branding___ReLzJ", R = {
1981
1981
  default: "webchat-input-module__default___tHS5e",
1982
1982
  base: Ha,
1983
1983
  "input-form": "webchat-input-module__input-form___GnKc7",
@@ -2026,28 +2026,28 @@ function Ga(e, n, a) {
2026
2026
  onMicrophoneClick: c,
2027
2027
  onUserMessageSent: m,
2028
2028
  ...g
2029
- } = e, [C, p] = N(""), v = S(""), w = n.webchatClientSettingsBehaviors.input, I = w.isTextInputEnabled && !i, y = $a(
2029
+ } = e, [C, p] = N(""), v = S(""), L = n.webchatClientSettingsBehaviors.input, T = L.isTextInputEnabled && !i, y = $a(
2030
2030
  C,
2031
- w.blockInputs
2031
+ L.blockInputs
2032
2032
  ), A = C.trim().length > 0, {
2033
2033
  hasAttachments: M,
2034
2034
  attachmentError: k,
2035
- fileInputRef: W,
2036
- handleFileInputChange: V,
2037
- handleOpenFilePicker: X,
2038
- sendAttachments: Y,
2035
+ fileInputRef: V,
2036
+ handleFileInputChange: W,
2037
+ handleOpenFilePicker: Y,
2038
+ sendAttachments: X,
2039
2039
  attachmentListProps: F
2040
2040
  } = ba(), {
2041
2041
  audioRecordingAvailable: J,
2042
2042
  hideBaseContent: ie,
2043
2043
  isPreview: ae,
2044
2044
  isRecording: Ne,
2045
- handleMicrophoneClick: Ve,
2045
+ handleMicrophoneClick: We,
2046
2046
  handleConfirmRecording: ze,
2047
2047
  handleSendRecording: Fe,
2048
2048
  overlayProps: He
2049
2049
  } = Da(n), he = b(() => {
2050
- if (!I || y) return;
2050
+ if (!T || y) return;
2051
2051
  const te = v.current.trim();
2052
2052
  if (te) {
2053
2053
  const Me = nt.createText({
@@ -2058,11 +2058,11 @@ function Ga(e, n, a) {
2058
2058
  });
2059
2059
  m?.(), o.sendMessage(Me), v.current = "", p("");
2060
2060
  }
2061
- }, [o, I, y, m]), Ue = b(
2061
+ }, [o, T, y, m]), Ue = b(
2062
2062
  (te) => {
2063
- te.preventDefault(), M && Y(), he();
2063
+ te.preventDefault(), M && X(), he();
2064
2064
  },
2065
- [M, Y, he]
2065
+ [M, X, he]
2066
2066
  ), ve = b(
2067
2067
  (te) => {
2068
2068
  const Me = te.target.value;
@@ -2074,9 +2074,9 @@ function Ga(e, n, a) {
2074
2074
  te.key === "Enter" && !te.shiftKey && (te.preventDefault(), he());
2075
2075
  },
2076
2076
  [he]
2077
- ), be = A || M, we = J ? !!i || !I || A && y : !!i || !I || !be || A && y, Ge = J ? be ? "submit" : "button" : "submit", ue = !Ne && !ae && J && !be, ee = Ne, qe = !ue && !ee, Ke = ue ? P["primary-action-mic"] : ee ? P["primary-action-confirm"] : P["primary-action-send"], je = ee || ae ? "button" : Ge, lt = ee ? !1 : we, O = ee ? ze : ae ? Fe : ue ? Ve : void 0, Qe = ue ? "Record voice message" : ee ? "Confirm recording" : "Send message", Jt = b(() => {
2078
- X(), u?.();
2079
- }, [X, u]);
2077
+ ), be = A || M, we = J ? !!i || !T || A && y : !!i || !T || !be || A && y, Ge = J ? be ? "submit" : "button" : "submit", ue = !Ne && !ae && J && !be, ee = Ne, qe = !ue && !ee, Ke = ue ? R["primary-action-mic"] : ee ? R["primary-action-confirm"] : R["primary-action-send"], je = ee || ae ? "button" : Ge, lt = ee ? !1 : we, O = ee ? ze : ae ? Fe : ue ? We : void 0, Qe = ue ? "Record voice message" : ee ? "Confirm recording" : "Send message", Jt = b(() => {
2078
+ Y(), u?.();
2079
+ }, [Y, u]);
2080
2080
  return {
2081
2081
  // Input wrapper props
2082
2082
  inputProps: {
@@ -2094,8 +2094,8 @@ function Ga(e, n, a) {
2094
2094
  // Attachment preview
2095
2095
  hasAttachments: M,
2096
2096
  attachmentError: k,
2097
- fileInputRef: W,
2098
- handleFileInputChange: V,
2097
+ fileInputRef: V,
2098
+ handleFileInputChange: W,
2099
2099
  attachmentListProps: F,
2100
2100
  // Input field props
2101
2101
  fieldProps: {
@@ -2103,7 +2103,7 @@ function Ga(e, n, a) {
2103
2103
  onChange: ve,
2104
2104
  onKeyDown: $e,
2105
2105
  placeholder: s,
2106
- disabled: !I,
2106
+ disabled: !T,
2107
2107
  rows: 1
2108
2108
  // minimum rows; CSS field-sizing: content allows growth up to --webchat-input-max-rows
2109
2109
  },
@@ -2112,9 +2112,9 @@ function Ga(e, n, a) {
2112
2112
  variant: r,
2113
2113
  className: _
2114
2114
  },
2115
- isInputEnabled: I,
2115
+ isInputEnabled: T,
2116
2116
  isInputDisabled: i,
2117
- inputBehavior: w,
2117
+ inputBehavior: L,
2118
2118
  showBranding: l,
2119
2119
  // Audio overlay (passed to AudioInput)
2120
2120
  overlayProps: He,
@@ -2132,10 +2132,10 @@ function Ga(e, n, a) {
2132
2132
  showSend: qe
2133
2133
  };
2134
2134
  }
2135
- const qa = j(P.base, {
2135
+ const qa = j(R.base, {
2136
2136
  variants: {
2137
2137
  variant: {
2138
- default: P.default
2138
+ default: R.default
2139
2139
  }
2140
2140
  },
2141
2141
  defaultVariants: {
@@ -2159,20 +2159,20 @@ function Ka(e) {
2159
2159
  primaryBgClass: C,
2160
2160
  primaryType: p,
2161
2161
  isPrimaryDisabled: v,
2162
- primaryHandler: w,
2163
- primaryLabel: I,
2162
+ primaryHandler: L,
2163
+ primaryLabel: T,
2164
2164
  showMic: y,
2165
2165
  showConfirm: A,
2166
2166
  showSend: M,
2167
2167
  hasAttachments: k,
2168
- attachmentError: W,
2169
- fileInputRef: V,
2170
- handleFileInputChange: X,
2171
- attachmentListProps: Y
2168
+ attachmentError: V,
2169
+ fileInputRef: W,
2170
+ handleFileInputChange: Y,
2171
+ attachmentListProps: X
2172
2172
  } = Ga(e, n, a), { icons: F } = e;
2173
2173
  if (!u.isComposerVisible)
2174
2174
  return null;
2175
- const J = l ? /* @__PURE__ */ t("p", { className: P.branding, children: "Powered by Hubtype" }) : void 0;
2175
+ const J = l ? /* @__PURE__ */ t("p", { className: R.branding, children: "Powered by Hubtype" }) : void 0;
2176
2176
  return /* @__PURE__ */ f(
2177
2177
  "div",
2178
2178
  {
@@ -2182,26 +2182,26 @@ function Ka(e) {
2182
2182
  "data-attachments-enabled": String(u.areAttachmentsVisible),
2183
2183
  "data-emoji-picker-enabled": String(u.isEmojiPickerVisible),
2184
2184
  children: [
2185
- /* @__PURE__ */ t("div", { className: P["input-container"], children: /* @__PURE__ */ f(
2185
+ /* @__PURE__ */ t("div", { className: R["input-container"], children: /* @__PURE__ */ f(
2186
2186
  "form",
2187
2187
  {
2188
2188
  onSubmit: s,
2189
- className: R(
2190
- P["input-form"],
2191
- m && P["input-form--active"]
2189
+ className: P(
2190
+ R["input-form"],
2191
+ m && R["input-form--active"]
2192
2192
  ),
2193
2193
  children: [
2194
- k && /* @__PURE__ */ t(_a, { ...Y }),
2195
- W && /* @__PURE__ */ t("p", { className: P["attachment-error"], role: "alert", children: W }),
2196
- /* @__PURE__ */ f("div", { className: P["input-row"], children: [
2194
+ k && /* @__PURE__ */ t(_a, { ...X }),
2195
+ V && /* @__PURE__ */ t("p", { className: R["attachment-error"], role: "alert", children: V }),
2196
+ /* @__PURE__ */ f("div", { className: R["input-row"], children: [
2197
2197
  g && /* @__PURE__ */ t(xa, { ...c }),
2198
2198
  /* @__PURE__ */ t(
2199
2199
  "textarea",
2200
2200
  {
2201
2201
  ...i,
2202
- className: R(
2203
- P["input-field"],
2204
- m && P["content-hidden"]
2202
+ className: P(
2203
+ R["input-field"],
2204
+ m && R["content-hidden"]
2205
2205
  ),
2206
2206
  inert: m ? "" : void 0
2207
2207
  }
@@ -2209,9 +2209,9 @@ function Ka(e) {
2209
2209
  /* @__PURE__ */ f(
2210
2210
  "div",
2211
2211
  {
2212
- className: R(
2213
- P["action-bar"],
2214
- m && P["content-hidden"]
2212
+ className: P(
2213
+ R["action-bar"],
2214
+ m && R["content-hidden"]
2215
2215
  ),
2216
2216
  role: "group",
2217
2217
  "aria-label": "Message actions",
@@ -2221,7 +2221,7 @@ function Ka(e) {
2221
2221
  "button",
2222
2222
  {
2223
2223
  type: "button",
2224
- className: P["action-button"],
2224
+ className: R["action-button"],
2225
2225
  "aria-label": "Emoji",
2226
2226
  disabled: d,
2227
2227
  onClick: h,
@@ -2232,11 +2232,11 @@ function Ka(e) {
2232
2232
  "button",
2233
2233
  {
2234
2234
  type: "button",
2235
- className: P["action-button"],
2235
+ className: R["action-button"],
2236
2236
  "aria-label": "Attach file",
2237
2237
  disabled: d,
2238
2238
  onClick: _,
2239
- children: F?.attachment ?? /* @__PURE__ */ t(Wa, {})
2239
+ children: F?.attachment ?? /* @__PURE__ */ t(Va, {})
2240
2240
  }
2241
2241
  )
2242
2242
  ]
@@ -2246,16 +2246,16 @@ function Ka(e) {
2246
2246
  "button",
2247
2247
  {
2248
2248
  type: p,
2249
- className: R(P["primary-action-base"], C),
2249
+ className: P(R["primary-action-base"], C),
2250
2250
  disabled: v,
2251
- "aria-label": I,
2252
- onClick: w,
2253
- children: /* @__PURE__ */ t("span", { className: P["icon-slot"], children: g ? /* @__PURE__ */ f(B, { children: [
2251
+ "aria-label": T,
2252
+ onClick: L,
2253
+ children: /* @__PURE__ */ t("span", { className: R["icon-slot"], children: g ? /* @__PURE__ */ f(B, { children: [
2254
2254
  /* @__PURE__ */ t(
2255
2255
  "span",
2256
2256
  {
2257
2257
  "aria-hidden": !0,
2258
- className: R(P["icon-face"], P["icon-mic"]),
2258
+ className: P(R["icon-face"], R["icon-mic"]),
2259
2259
  "data-visible": y ? "true" : "false",
2260
2260
  children: F?.microphone ?? /* @__PURE__ */ t(Fa, {})
2261
2261
  }
@@ -2264,19 +2264,19 @@ function Ka(e) {
2264
2264
  "span",
2265
2265
  {
2266
2266
  "aria-hidden": !0,
2267
- className: R(
2268
- P["icon-face"],
2269
- P["icon-confirm"]
2267
+ className: P(
2268
+ R["icon-face"],
2269
+ R["icon-confirm"]
2270
2270
  ),
2271
2271
  "data-visible": A ? "true" : "false",
2272
- children: /* @__PURE__ */ t(Va, {})
2272
+ children: /* @__PURE__ */ t(Wa, {})
2273
2273
  }
2274
2274
  ),
2275
2275
  /* @__PURE__ */ t(
2276
2276
  "span",
2277
2277
  {
2278
2278
  "aria-hidden": !0,
2279
- className: R(P["icon-face"], P["icon-send"]),
2279
+ className: P(R["icon-face"], R["icon-send"]),
2280
2280
  "data-visible": M ? "true" : "false",
2281
2281
  children: F?.send ?? /* @__PURE__ */ t(pt, {})
2282
2282
  }
@@ -2285,7 +2285,7 @@ function Ka(e) {
2285
2285
  "span",
2286
2286
  {
2287
2287
  "aria-hidden": !0,
2288
- className: R(P["icon-face"], P["icon-send"]),
2288
+ className: P(R["icon-face"], R["icon-send"]),
2289
2289
  "data-visible": "true",
2290
2290
  children: F?.send ?? /* @__PURE__ */ t(pt, {})
2291
2291
  }
@@ -2296,10 +2296,10 @@ function Ka(e) {
2296
2296
  /* @__PURE__ */ t(
2297
2297
  "input",
2298
2298
  {
2299
- ref: V,
2299
+ ref: W,
2300
2300
  type: "file",
2301
2301
  accept: pa,
2302
- onChange: X,
2302
+ onChange: Y,
2303
2303
  style: { display: "none" },
2304
2304
  "aria-hidden": !0,
2305
2305
  tabIndex: -1
@@ -2321,14 +2321,14 @@ function et(e) {
2321
2321
  if (!(!Number.isFinite(o) || o <= 0))
2322
2322
  return new Date(o);
2323
2323
  }
2324
- const ja = "message-bubble-module__base___WzTAP", Qa = "message-bubble-module__bot___PcXmL", Za = "message-bubble-module__agent___WGfzX", Xa = "message-bubble-module__user___lFMMm", Ya = "message-bubble-module__system___e8-FD", Ja = "message-bubble-module__sending___P9nK-", es = "message-bubble-module__error___mine7", ne = {
2324
+ const ja = "message-bubble-module__base___WzTAP", Qa = "message-bubble-module__bot___PcXmL", Za = "message-bubble-module__agent___WGfzX", Ya = "message-bubble-module__user___lFMMm", Xa = "message-bubble-module__system___e8-FD", Ja = "message-bubble-module__sending___P9nK-", es = "message-bubble-module__error___mine7", ne = {
2325
2325
  base: ja,
2326
2326
  bot: Qa,
2327
2327
  agent: Za,
2328
- user: Xa,
2328
+ user: Ya,
2329
2329
  "flat-top-corner": "message-bubble-module__flat-top-corner___CLxP2",
2330
2330
  "flat-bottom-corner": "message-bubble-module__flat-bottom-corner___DrB7C",
2331
- system: Ya,
2331
+ system: Xa,
2332
2332
  sending: Ja,
2333
2333
  error: es
2334
2334
  }, ts = j(ne.base, {
@@ -2468,7 +2468,7 @@ const ja = "message-bubble-module__base___WzTAP", Qa = "message-bubble-module__b
2468
2468
  ]
2469
2469
  }
2470
2470
  )
2471
- ), vs = "message-info-module__base___yO0Cd", bs = "message-info-module__senderName___fP58-", ws = "message-info-module__timestamp___xwDsF", Ls = "message-info-module__status___jPwtz", ys = "message-info-module__top___NK5CY", Ss = "message-info-module__bottom___NE4Rs", Ns = "message-info-module__bot___xlQbg", Ms = "message-info-module__agent___ckeYQ", As = "message-info-module__user___bgEi-", Is = "message-info-module__system___MF1CS", oe = {
2471
+ ), vs = "message-info-module__base___yO0Cd", bs = "message-info-module__senderName___fP58-", ws = "message-info-module__timestamp___xwDsF", Ls = "message-info-module__status___jPwtz", ys = "message-info-module__top___NK5CY", Ss = "message-info-module__bottom___NE4Rs", Ns = "message-info-module__bot___xlQbg", Ms = "message-info-module__agent___ckeYQ", As = "message-info-module__user___bgEi-", Ts = "message-info-module__system___MF1CS", oe = {
2472
2472
  base: vs,
2473
2473
  senderName: bs,
2474
2474
  timestamp: ws,
@@ -2478,7 +2478,7 @@ const ja = "message-bubble-module__base___WzTAP", Qa = "message-bubble-module__b
2478
2478
  bot: Ns,
2479
2479
  agent: Ms,
2480
2480
  user: As,
2481
- system: Is
2481
+ system: Ts
2482
2482
  }, Es = j(oe.base, {
2483
2483
  variants: {
2484
2484
  variant: {
@@ -2493,7 +2493,7 @@ const ja = "message-bubble-module__base___WzTAP", Qa = "message-bubble-module__b
2493
2493
  }
2494
2494
  },
2495
2495
  defaultVariants: { variant: "bot", position: "bottom" }
2496
- }), Ts = (e) => {
2496
+ }), Is = (e) => {
2497
2497
  if (e)
2498
2498
  return typeof e == "string" ? e : e.toLocaleTimeString([], { hour: "2-digit", minute: "2-digit" });
2499
2499
  }, Ft = G(
@@ -2520,7 +2520,7 @@ const ja = "message-bubble-module__base___WzTAP", Qa = "message-bubble-module__b
2520
2520
  default:
2521
2521
  return "";
2522
2522
  }
2523
- }, c = Ts(o);
2523
+ }, c = Is(o);
2524
2524
  return a && c || s || _ || r || l ? /* @__PURE__ */ f(
2525
2525
  "div",
2526
2526
  {
@@ -2541,14 +2541,14 @@ const ja = "message-bubble-module__base___WzTAP", Qa = "message-bubble-module__b
2541
2541
  }
2542
2542
  ) : null;
2543
2543
  }
2544
- ), xs = "message-module__base___Ki7QB", Ps = "message-module__bot___vw-E6", Rs = "message-module__agent___2wXra", Bs = "message-module__user___BSpcY", ks = "message-module__system___-jvsr", Q = {
2544
+ ), xs = "message-module__base___Ki7QB", Rs = "message-module__bot___vw-E6", Ps = "message-module__agent___2wXra", Bs = "message-module__user___BSpcY", ks = "message-module__system___-jvsr", Q = {
2545
2545
  base: xs,
2546
2546
  "hide-footer": "message-module__hide-footer___hIyVr",
2547
- bot: Ps,
2547
+ bot: Rs,
2548
2548
  "is-full-width": "message-module__is-full-width___TbepW",
2549
2549
  "has-actions": "message-module__has-actions___oKqN8",
2550
2550
  "is-continuation": "message-module__is-continuation___0ir98",
2551
- agent: Rs,
2551
+ agent: Ps,
2552
2552
  user: Bs,
2553
2553
  system: ks
2554
2554
  }, Os = j(Q.base, {
@@ -2616,7 +2616,7 @@ function rt(e) {
2616
2616
  timestamp: i,
2617
2617
  status: a,
2618
2618
  senderName: l
2619
- }, w = {
2619
+ }, L = {
2620
2620
  variant: n,
2621
2621
  status: a,
2622
2622
  ..._ ? { className: _ } : {},
@@ -2626,31 +2626,31 @@ function rt(e) {
2626
2626
  if (!r)
2627
2627
  return {
2628
2628
  messageClasses: p,
2629
- bubbleProps: w,
2629
+ bubbleProps: L,
2630
2630
  infoProps: v,
2631
2631
  standaloneAvatarProps: null
2632
2632
  };
2633
- const { placement: I, avatarProps: y } = r;
2634
- switch (I) {
2633
+ const { placement: T, avatarProps: y } = r;
2634
+ switch (T) {
2635
2635
  case "bubble":
2636
2636
  case "info":
2637
2637
  return {
2638
2638
  messageClasses: p,
2639
- bubbleProps: w,
2639
+ bubbleProps: L,
2640
2640
  infoProps: { ...v, avatarProps: y },
2641
2641
  standaloneAvatarProps: null
2642
2642
  };
2643
2643
  case "standalone":
2644
2644
  return {
2645
2645
  messageClasses: p,
2646
- bubbleProps: w,
2646
+ bubbleProps: L,
2647
2647
  infoProps: v,
2648
2648
  standaloneAvatarProps: y
2649
2649
  };
2650
2650
  default:
2651
2651
  return {
2652
2652
  messageClasses: p,
2653
- bubbleProps: w,
2653
+ bubbleProps: L,
2654
2654
  infoProps: v,
2655
2655
  standaloneAvatarProps: null
2656
2656
  };
@@ -2689,10 +2689,10 @@ const de = G(
2689
2689
  }
2690
2690
  );
2691
2691
  }
2692
- ), Ds = "audio-message-module__audioMessageBase___Xye8T", Ws = "audio-message-module__audioControls___bPgRS", Vs = "audio-message-module__playButton___zFi0C", zs = "audio-message-module__waveformPlaceholder___I9e-v", Fs = "audio-message-module__timer___6vQtQ", Le = {
2692
+ ), Ds = "audio-message-module__audioMessageBase___Xye8T", Vs = "audio-message-module__audioControls___bPgRS", Ws = "audio-message-module__playButton___zFi0C", zs = "audio-message-module__waveformPlaceholder___I9e-v", Fs = "audio-message-module__timer___6vQtQ", Le = {
2693
2693
  audioMessageBase: Ds,
2694
- audioControls: Ws,
2695
- playButton: Vs,
2694
+ audioControls: Vs,
2695
+ playButton: Ws,
2696
2696
  waveformPlaceholder: zs,
2697
2697
  timer: Fs
2698
2698
  };
@@ -2704,10 +2704,10 @@ function Hs({
2704
2704
  onPause: s,
2705
2705
  onEnded: i
2706
2706
  }) {
2707
- const r = S(null), [l, h] = N(!1), [_, d] = N(), [u, c] = N(0), [m, g] = N(), C = S(!1), { activeId: p, setActive: v, clearActive: w } = ke(), { isFocusVisible: I, focusProps: y } = ot();
2708
- E(() => {
2707
+ const r = S(null), [l, h] = N(!1), [_, d] = N(), [u, c] = N(0), [m, g] = N(), C = S(!1), { activeId: p, setActive: v, clearActive: L } = ke(), { isFocusVisible: T, focusProps: y } = ot();
2708
+ I(() => {
2709
2709
  n && p !== n && l && r.current?.pause();
2710
- }, [p, n, l]), E(() => {
2710
+ }, [p, n, l]), I(() => {
2711
2711
  if (C.current) return;
2712
2712
  let ie = !1;
2713
2713
  return fetch(e).then((ae) => ae.blob()).then((ae) => {
@@ -2723,36 +2723,36 @@ function Hs({
2723
2723
  r.current && c(r.current.currentTime);
2724
2724
  }, []), k = b(() => {
2725
2725
  h(!0), n && v(n), o?.();
2726
- }, [n, o, v]), W = b(() => {
2727
- h(!1), n && w(n), s?.();
2728
- }, [n, s, w]), V = b(() => {
2729
- h(!1), c(0), n && w(n), i?.();
2730
- }, [n, i, w]), X = b(() => {
2726
+ }, [n, o, v]), V = b(() => {
2727
+ h(!1), n && L(n), s?.();
2728
+ }, [n, s, L]), W = b(() => {
2729
+ h(!1), c(0), n && L(n), i?.();
2730
+ }, [n, i, L]), Y = b(() => {
2731
2731
  r.current && (l ? r.current.pause() : r.current.play());
2732
- }, [l]), Y = b(
2732
+ }, [l]), X = b(
2733
2733
  (ie) => {
2734
2734
  !r.current || _ === void 0 || (r.current.currentTime = ie * _, c(r.current.currentTime));
2735
2735
  },
2736
2736
  [_]
2737
- ), F = _ ? u / _ : 0, J = l ? Pe(u) : _ !== void 0 ? Pe(_) : "--:--";
2737
+ ), F = _ ? u / _ : 0, J = l ? Re(u) : _ !== void 0 ? Re(_) : "--:--";
2738
2738
  return {
2739
2739
  audioRef: r,
2740
2740
  audioBlob: m,
2741
2741
  isPlaying: l,
2742
2742
  audioProgress: F,
2743
2743
  timerLabel: J,
2744
- handlePlayPause: X,
2745
- handleSeek: Y,
2744
+ handlePlayPause: Y,
2745
+ handleSeek: X,
2746
2746
  audioProps: {
2747
2747
  onLoadedMetadata: A,
2748
2748
  onTimeUpdate: M,
2749
2749
  onPlay: k,
2750
- onPause: W,
2751
- onEnded: V
2750
+ onPause: V,
2751
+ onEnded: W
2752
2752
  },
2753
2753
  playButtonProps: {
2754
2754
  ...y,
2755
- "data-focus-visible": I
2755
+ "data-focus-visible": T
2756
2756
  }
2757
2757
  };
2758
2758
  }
@@ -2777,7 +2777,7 @@ const Ht = G(
2777
2777
  handlePlayPause: C,
2778
2778
  handleSeek: p,
2779
2779
  audioProps: v,
2780
- playButtonProps: w
2780
+ playButtonProps: L
2781
2781
  } = Hs({
2782
2782
  src: e,
2783
2783
  messageId: n,
@@ -2790,7 +2790,7 @@ const Ht = G(
2790
2790
  de,
2791
2791
  {
2792
2792
  ref: _,
2793
- className: R(Le.audioMessageBase, l),
2793
+ className: P(Le.audioMessageBase, l),
2794
2794
  ...h,
2795
2795
  children: [
2796
2796
  /* @__PURE__ */ t(
@@ -2811,12 +2811,12 @@ const Ht = G(
2811
2811
  className: Le.playButton,
2812
2812
  onClick: C,
2813
2813
  "aria-label": c ? "Pause audio" : "Play audio",
2814
- ...w,
2814
+ ...L,
2815
2815
  children: c ? /* @__PURE__ */ t(zt, {}) : /* @__PURE__ */ t(at, {})
2816
2816
  }
2817
2817
  ),
2818
2818
  u ? /* @__PURE__ */ t(
2819
- Vt,
2819
+ Wt,
2820
2820
  {
2821
2821
  audioBlob: u,
2822
2822
  progress: m,
@@ -2836,7 +2836,7 @@ const Us = "markdown-text-module__markdownText___UbIHM", $s = {
2836
2836
  }, it = ({
2837
2837
  text: e,
2838
2838
  className: n
2839
- }) => /* @__PURE__ */ t("div", { className: R($s.markdownText, n), children: /* @__PURE__ */ t(
2839
+ }) => /* @__PURE__ */ t("div", { className: P($s.markdownText, n), children: /* @__PURE__ */ t(
2840
2840
  fn,
2841
2841
  {
2842
2842
  remarkPlugins: [Cn, vn],
@@ -2917,7 +2917,7 @@ const Ut = G(
2917
2917
  onClick: (_) => {
2918
2918
  _.preventDefault(), _.stopPropagation(), a?.(o);
2919
2919
  },
2920
- className: R(
2920
+ className: P(
2921
2921
  ye.quickReply,
2922
2922
  i === "primary" && ye.primary,
2923
2923
  i === "secondary" && ye.secondary,
@@ -2932,9 +2932,9 @@ const Ut = G(
2932
2932
  }
2933
2933
  );
2934
2934
  }
2935
- ), Xs = "button-message-module__actions___3CAVo", Ys = "button-message-module__floatingButton___OK9AF", Ct = {
2936
- actions: Xs,
2937
- floatingButton: Ys
2935
+ ), Ys = "button-message-module__actions___3CAVo", Xs = "button-message-module__floatingButton___OK9AF", Ct = {
2936
+ actions: Ys,
2937
+ floatingButton: Xs
2938
2938
  }, Js = G(
2939
2939
  ({ text: e, buttons: n, buttonsPerRow: a = 1, className: o, hideFooter: s, ...i }, r) => {
2940
2940
  const l = Math.min(a, n.length), { messageClasses: h, bubbleProps: _, infoProps: d, standaloneAvatarProps: u } = rt({ ...i, children: null, hasActions: !0, hideFooter: s });
@@ -2942,7 +2942,7 @@ const Ut = G(
2942
2942
  "div",
2943
2943
  {
2944
2944
  ref: r,
2945
- className: R(h, o),
2945
+ className: P(h, o),
2946
2946
  "data-testid": `webchat-message-${i.variant || "bot"}`,
2947
2947
  children: [
2948
2948
  u && /* @__PURE__ */ t(De, { ...u }),
@@ -3118,7 +3118,7 @@ const $t = G(
3118
3118
  de,
3119
3119
  {
3120
3120
  ref: i,
3121
- className: R(H.carouselMessageBase, o),
3121
+ className: P(H.carouselMessageBase, o),
3122
3122
  isFullWidth: !0,
3123
3123
  ...s,
3124
3124
  children: /* @__PURE__ */ f("div", { ...r, className: H.carouselWrapper, children: [
@@ -3167,7 +3167,7 @@ const $t = G(
3167
3167
  {
3168
3168
  ...d,
3169
3169
  type: "button",
3170
- className: R(H.arrowButton, H.prevArrow),
3170
+ className: P(H.arrowButton, H.prevArrow),
3171
3171
  children: /* @__PURE__ */ t(hr, {})
3172
3172
  }
3173
3173
  ),
@@ -3176,7 +3176,7 @@ const $t = G(
3176
3176
  {
3177
3177
  ...u,
3178
3178
  type: "button",
3179
- className: R(H.arrowButton, H.nextArrow),
3179
+ className: P(H.arrowButton, H.nextArrow),
3180
3180
  children: /* @__PURE__ */ t(gr, {})
3181
3181
  }
3182
3182
  )
@@ -3187,7 +3187,7 @@ const $t = G(
3187
3187
  }
3188
3188
  );
3189
3189
  $t.displayName = "CarouselMessage";
3190
- const pr = "document-message-module__documentMessageBase___hqh5-", Cr = "document-message-module__fileRow___-dzrn", vr = "document-message-module__fileIcon___OwdXn", br = "document-message-module__fileName___2d5yP", Te = {
3190
+ const pr = "document-message-module__documentMessageBase___hqh5-", Cr = "document-message-module__fileRow___-dzrn", vr = "document-message-module__fileIcon___OwdXn", br = "document-message-module__fileName___2d5yP", Ie = {
3191
3191
  documentMessageBase: pr,
3192
3192
  fileRow: Cr,
3193
3193
  fileIcon: vr,
@@ -3217,18 +3217,18 @@ const Gt = G(
3217
3217
  de,
3218
3218
  {
3219
3219
  ref: r,
3220
- className: R(Te.documentMessageBase, s),
3220
+ className: P(Ie.documentMessageBase, s),
3221
3221
  ...i,
3222
3222
  children: /* @__PURE__ */ f(
3223
3223
  "button",
3224
3224
  {
3225
3225
  type: "button",
3226
- className: Te.fileRow,
3226
+ className: Ie.fileRow,
3227
3227
  "aria-label": `Download ${n || "document"}`,
3228
3228
  ...l,
3229
3229
  children: [
3230
- /* @__PURE__ */ t("span", { className: Te.fileIcon, "aria-hidden": !0, children: Lr(a) }),
3231
- /* @__PURE__ */ t("span", { className: Te.fileName, children: n || "Document" })
3230
+ /* @__PURE__ */ t("span", { className: Ie.fileIcon, "aria-hidden": !0, children: Lr(a) }),
3231
+ /* @__PURE__ */ t("span", { className: Ie.fileName, children: n || "Document" })
3232
3232
  ]
3233
3233
  }
3234
3234
  )
@@ -3261,7 +3261,7 @@ const qt = G(
3261
3261
  de,
3262
3262
  {
3263
3263
  ref: i,
3264
- className: R(bt.imageMessageBase, o),
3264
+ className: P(bt.imageMessageBase, o),
3265
3265
  ...s,
3266
3266
  children: /* @__PURE__ */ t(
3267
3267
  "img",
@@ -3277,15 +3277,15 @@ const qt = G(
3277
3277
  }
3278
3278
  );
3279
3279
  qt.displayName = "ImageMessage";
3280
- const Mr = "location-message-module__locationMessageBase___rY3d-", Ar = "location-message-module__locationContainer___9Rukw", Ir = "location-message-module__locationContent___2BRdV", Er = "location-message-module__locationIcon___rjObu", Tr = "location-message-module__locationInfo___NqVsR", xr = "location-message-module__locationTitle___RpUjH", Pr = "location-message-module__locationCoordinates___lLfuf", Rr = "location-message-module__locationLink___Zq2I2", le = {
3280
+ const Mr = "location-message-module__locationMessageBase___rY3d-", Ar = "location-message-module__locationContainer___9Rukw", Tr = "location-message-module__locationContent___2BRdV", Er = "location-message-module__locationIcon___rjObu", Ir = "location-message-module__locationInfo___NqVsR", xr = "location-message-module__locationTitle___RpUjH", Rr = "location-message-module__locationCoordinates___lLfuf", Pr = "location-message-module__locationLink___Zq2I2", le = {
3281
3281
  locationMessageBase: Mr,
3282
3282
  locationContainer: Ar,
3283
- locationContent: Ir,
3283
+ locationContent: Tr,
3284
3284
  locationIcon: Er,
3285
- locationInfo: Tr,
3285
+ locationInfo: Ir,
3286
3286
  locationTitle: xr,
3287
- locationCoordinates: Pr,
3288
- locationLink: Rr
3287
+ locationCoordinates: Rr,
3288
+ locationLink: Pr
3289
3289
  }, Br = G(
3290
3290
  ({
3291
3291
  latitude: e,
@@ -3302,7 +3302,7 @@ const Mr = "location-message-module__locationMessageBase___rY3d-", Ar = "locatio
3302
3302
  de,
3303
3303
  {
3304
3304
  ref: r,
3305
- className: R(le.locationMessageBase, s),
3305
+ className: P(le.locationMessageBase, s),
3306
3306
  ...i,
3307
3307
  children: /* @__PURE__ */ f("div", { className: le.locationContainer, children: [
3308
3308
  /* @__PURE__ */ f("div", { className: le.locationContent, children: [
@@ -3408,7 +3408,7 @@ const Mr = "location-message-module__locationMessageBase___rY3d-", Ar = "locatio
3408
3408
  d: "M464 256A208 208 0 1 0 48 256a208 208 0 1 0 416 0zM0 256a256 256 0 1 1 512 0A256 256 0 1 1 0 256zm349.5 52.4c18.7-4.4 35.9 12 25.5 28.1C350.4 374.6 306.3 400 255.9 400s-94.5-25.4-119.1-63.5c-10.4-16.1 6.8-32.5 25.5-28.1c28.9 6.8 60.5 10.5 93.6 10.5s64.7-3.7 93.6-10.5zM217.6 228.8s0 0 0 0c0 0 0 0 0 0l-.2-.2c-.2-.2-.4-.5-.7-.9c-.6-.8-1.6-2-2.8-3.4c-2.5-2.8-6-6.6-10.2-10.3c-8.8-7.8-18.8-14-27.7-14s-18.9 6.2-27.7 14c-4.2 3.7-7.7 7.5-10.2 10.3c-1.2 1.4-2.2 2.6-2.8 3.4c-.3 .4-.6 .7-.7 .9l-.2 .2c0 0 0 0 0 0c0 0 0 0 0 0s0 0 0 0c-2.1 2.8-5.7 3.9-8.9 2.8s-5.5-4.1-5.5-7.6c0-17.9 6.7-35.6 16.6-48.8c9.8-13 23.9-23.2 39.4-23.2s29.6 10.2 39.4 23.2c9.9 13.2 16.6 30.9 16.6 48.8c0 3.4-2.2 6.5-5.5 7.6s-6.9 0-8.9-2.8c0 0 0 0 0 0s0 0 0 0zm160 0c0 0 0 0 0 0l-.2-.2c-.2-.2-.4-.5-.7-.9c-.6-.8-1.6-2-2.8-3.4c-2.5-2.8-6-6.6-10.2-10.3c-8.8-7.8-18.8-14-27.7-14s-18.9 6.2-27.7 14c-4.2 3.7-7.7 7.5-10.2 10.3c-1.2 1.4-2.2 2.6-2.8 3.4c-.3 .4-.6 .7-.7 .9l-.2 .2c0 0 0 0 0 0c0 0 0 0 0 0s0 0 0 0c-2.1 2.8-5.7 3.9-8.9 2.8s-5.5-4.1-5.5-7.6c0-17.9 6.7-35.6 16.6-48.8c9.8-13 23.9-23.2 39.4-23.2s29.6 10.2 39.4 23.2c9.9 13.2 16.6 30.9 16.6 48.8c0 3.4-2.2 6.5-5.5 7.6s-6.9 0-8.9-2.8c0 0 0 0 0 0s0 0 0 0s0 0 0 0z",
3409
3409
  fill: "currentColor"
3410
3410
  }
3411
- ) }), Wr = ({ color: e, selected: n }) => n ? /* @__PURE__ */ t("svg", { xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 512 512", color: e, children: /* @__PURE__ */ t(
3411
+ ) }), Vr = ({ color: e, selected: n }) => n ? /* @__PURE__ */ t("svg", { xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 512 512", color: e, children: /* @__PURE__ */ t(
3412
3412
  "path",
3413
3413
  {
3414
3414
  d: "M256 512A256 256 0 1 0 256 0a256 256 0 1 0 0 512zM176.4 176a32 32 0 1 1 0 64 32 32 0 1 1 0-64zm128 32a32 32 0 1 1 64 0 32 32 0 1 1 -64 0zM160 336l192 0c8.8 0 16 7.2 16 16s-7.2 16-16 16l-192 0c-8.8 0-16-7.2-16-16s7.2-16 16-16z",
@@ -3420,7 +3420,7 @@ const Mr = "location-message-module__locationMessageBase___rY3d-", Ar = "locatio
3420
3420
  d: "M464 256A208 208 0 1 1 48 256a208 208 0 1 1 416 0zM256 0a256 256 0 1 0 0 512A256 256 0 1 0 256 0zM176.4 240a32 32 0 1 0 0-64 32 32 0 1 0 0 64zm192-32a32 32 0 1 0 -64 0 32 32 0 1 0 64 0zM184 328c-13.3 0-24 10.7-24 24s10.7 24 24 24l144 0c13.3 0 24-10.7 24-24s-10.7-24-24-24l-144 0z",
3421
3421
  fill: "currentColor"
3422
3422
  }
3423
- ) }), Vr = ({ color: e, selected: n }) => n ? /* @__PURE__ */ t("svg", { xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 512 512", color: e, children: /* @__PURE__ */ t(
3423
+ ) }), Wr = ({ color: e, selected: n }) => n ? /* @__PURE__ */ t("svg", { xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 512 512", color: e, children: /* @__PURE__ */ t(
3424
3424
  "path",
3425
3425
  {
3426
3426
  d: "M256 512A256 256 0 1 0 256 0a256 256 0 1 0 0 512zM164.1 325.5C182 346.2 212.6 368 256 368s74-21.8 91.9-42.5c5.8-6.7 15.9-7.4 22.6-1.6s7.4 15.9 1.6 22.6C349.8 372.1 311.1 400 256 400s-93.8-27.9-116.1-53.5c-5.8-6.7-5.1-16.8 1.6-22.6s16.8-5.1 22.6 1.6zM144.4 208a32 32 0 1 1 64 0 32 32 0 1 1 -64 0zm192-32a32 32 0 1 1 0 64 32 32 0 1 1 0-64z",
@@ -3444,7 +3444,7 @@ const Mr = "location-message-module__locationMessageBase___rY3d-", Ar = "locatio
3444
3444
  d: "M287.9 0c9.2 0 17.6 5.2 21.6 13.5l68.6 141.3 153.2 22.6c9 1.3 16.5 7.6 19.3 16.3s.5 18.1-5.9 24.5L433.6 328.4l26.2 155.6c1.5 9-2.2 18.1-9.7 23.5s-17.3 6-25.3 1.7l-137-73.2L151 509.1c-8.1 4.3-17.9 3.7-25.3-1.7s-11.2-14.5-9.7-23.5l26.2-155.6L31.1 218.2c-6.5-6.4-8.7-15.9-5.9-24.5s10.3-14.9 19.3-16.3l153.2-22.6L266.3 13.5C270.4 5.2 278.7 0 287.9 0zm0 79L235.4 187.2c-3.5 7.1-10.2 12.1-18.1 13.3L99 217.9 184.9 303c5.5 5.5 8.1 13.3 6.8 21L171.4 443.7l105.2-56.2c7.1-3.8 15.6-3.8 22.6 0l105.2 56.2L384.2 324.1c-1.3-7.7 1.2-15.5 6.8-21l85.9-85.1L358.6 200.5c-7.8-1.2-14.6-6.1-18.1-13.3L287.9 79z",
3445
3445
  fill: "currentColor"
3446
3446
  }
3447
- ) }), Fr = "rating-message-module__ratingBubble___7wyHy", Hr = "rating-message-module__container___dtkEH", Ur = "rating-message-module__titleBlock___V-gUi", $r = "rating-message-module__title___nox04", Gr = "rating-message-module__subtitle___HvR5A", qr = "rating-message-module__starsBlock___p7KFf", Kr = "rating-message-module__starsRow___0okuD", jr = "rating-message-module__ratingIconWrap___c8yQW", Qr = "rating-message-module__starButton___jEIj0", Zr = "rating-message-module__smileyButton___W-mdc", Xr = "rating-message-module__submitButton___fzRTp", U = {
3447
+ ) }), Fr = "rating-message-module__ratingBubble___7wyHy", Hr = "rating-message-module__container___dtkEH", Ur = "rating-message-module__titleBlock___V-gUi", $r = "rating-message-module__title___nox04", Gr = "rating-message-module__subtitle___HvR5A", qr = "rating-message-module__starsBlock___p7KFf", Kr = "rating-message-module__starsRow___0okuD", jr = "rating-message-module__ratingIconWrap___c8yQW", Qr = "rating-message-module__starButton___jEIj0", Zr = "rating-message-module__smileyButton___W-mdc", Yr = "rating-message-module__submitButton___fzRTp", U = {
3448
3448
  ratingBubble: Fr,
3449
3449
  container: Hr,
3450
3450
  titleBlock: Ur,
@@ -3456,10 +3456,10 @@ const Mr = "location-message-module__locationMessageBase___rY3d-", Ar = "locatio
3456
3456
  starButton: Qr,
3457
3457
  smileyButton: Zr,
3458
3458
  "is-submitted": "rating-message-module__is-submitted___fCaIp",
3459
- submitButton: Xr,
3459
+ submitButton: Yr,
3460
3460
  "is-active": "rating-message-module__is-active___iZqMO"
3461
3461
  };
3462
- function Yr(e) {
3462
+ function Xr(e) {
3463
3463
  const { controller: n } = q();
3464
3464
  return b(
3465
3465
  (a) => {
@@ -3474,19 +3474,19 @@ function Jr(e) {
3474
3474
  return n === -1 ? [e, void 0] : [e.slice(0, n).trim(), e.slice(n + 1).trim()];
3475
3475
  }
3476
3476
  function ei(e) {
3477
- const n = e.text ?? "", [a, o] = Jr(n), s = e.sendButtonText ?? "", i = e.buttons ?? [], r = e.messageProps ?? {}, l = e.type ?? At.Stars, { controller: h } = q(), _ = Yr(e.messageId), [d, u] = N(e.selected), [c, m] = N(void 0), [g, C] = N(e.submitted ?? !1), [p, v] = N(!1);
3478
- E(() => {
3477
+ const n = e.text ?? "", [a, o] = Jr(n), s = e.sendButtonText ?? "", i = e.buttons ?? [], r = e.messageProps ?? {}, l = e.type ?? At.Stars, { controller: h } = q(), _ = Xr(e.messageId), [d, u] = N(e.selected), [c, m] = N(void 0), [g, C] = N(e.submitted ?? !1), [p, v] = N(!1);
3478
+ I(() => {
3479
3479
  _({ selected: d, submitted: g });
3480
3480
  }, [d, g, _]);
3481
- const w = S(g);
3482
- w.current = g;
3483
- const I = b((M) => {
3484
- w.current || u(M);
3481
+ const L = S(g);
3482
+ L.current = g;
3483
+ const T = b((M) => {
3484
+ L.current || u(M);
3485
3485
  }, []), y = b((M) => {
3486
- w.current || m(M);
3486
+ L.current || m(M);
3487
3487
  }, []), A = b(async () => {
3488
- if (d === void 0 || p || w.current) return;
3489
- const M = i.find((W) => W.value === d)?.payload;
3488
+ if (d === void 0 || p || L.current) return;
3489
+ const M = i.find((V) => V.value === d)?.payload;
3490
3490
  if (!M) return;
3491
3491
  const k = h.getContext();
3492
3492
  if (!(!k.webchatService || !k.user)) {
@@ -3500,7 +3500,7 @@ function ei(e) {
3500
3500
  }, [d, p, i, h]);
3501
3501
  return {
3502
3502
  state: { selected: d, hovered: c, submitted: g, isSubmitting: p },
3503
- handlers: { handleSelect: I, handleHover: y, handleSubmit: A },
3503
+ handlers: { handleSelect: T, handleHover: y, handleSubmit: A },
3504
3504
  resolved: {
3505
3505
  titleText: a,
3506
3506
  text: o,
@@ -3514,8 +3514,8 @@ function ei(e) {
3514
3514
  const ti = [
3515
3515
  kr,
3516
3516
  Or,
3517
- Wr,
3518
3517
  Vr,
3518
+ Wr,
3519
3519
  Dr
3520
3520
  ], ni = "var(--webchat-rating-message-star-inactive)", oi = "var(--webchat-rating-message-star-active)", ai = (e) => {
3521
3521
  const { state: n, handlers: a, resolved: o } = ei(e), { selected: s, hovered: i, submitted: r, isSubmitting: l } = n, { handleSelect: h, handleHover: _, handleSubmit: d } = a, { titleText: u, text: c, sendButtonText: m, messageProps: g, type: C } = o, p = C === At.Smileys, v = [1, 2, 3, 4, 5];
@@ -3530,38 +3530,38 @@ const ti = [
3530
3530
  /* @__PURE__ */ t("p", { className: U.title, children: u }),
3531
3531
  c && /* @__PURE__ */ t(it, { text: c, className: U.subtitle })
3532
3532
  ] }),
3533
- /* @__PURE__ */ t("div", { className: U.starsBlock, children: /* @__PURE__ */ t("div", { className: U.starsRow, "data-rating-type": C, children: v.map((w) => {
3534
- const I = s !== void 0 && w <= s || s === void 0 && i !== void 0 && w <= i, y = I ? oi : ni, A = ti[w - 1];
3533
+ /* @__PURE__ */ t("div", { className: U.starsBlock, children: /* @__PURE__ */ t("div", { className: U.starsRow, "data-rating-type": C, children: v.map((L) => {
3534
+ const T = s !== void 0 && L <= s || s === void 0 && i !== void 0 && L <= i, y = T ? oi : ni, A = ti[L - 1];
3535
3535
  return p ? /* @__PURE__ */ t(
3536
3536
  "button",
3537
3537
  {
3538
3538
  type: "button",
3539
- "aria-label": `Rate ${w} out of 5`,
3540
- className: R(
3539
+ "aria-label": `Rate ${L} out of 5`,
3540
+ className: P(
3541
3541
  U.smileyButton,
3542
3542
  r && U["is-submitted"]
3543
3543
  ),
3544
- onClick: () => h(w),
3545
- onMouseEnter: () => _(w),
3544
+ onClick: () => h(L),
3545
+ onMouseEnter: () => _(L),
3546
3546
  onMouseLeave: () => _(void 0),
3547
- children: /* @__PURE__ */ t("span", { className: U.ratingIconWrap, "aria-hidden": !0, children: /* @__PURE__ */ t(A, { color: y, selected: I }) })
3547
+ children: /* @__PURE__ */ t("span", { className: U.ratingIconWrap, "aria-hidden": !0, children: /* @__PURE__ */ t(A, { color: y, selected: T }) })
3548
3548
  },
3549
- w
3549
+ L
3550
3550
  ) : /* @__PURE__ */ t(
3551
3551
  "button",
3552
3552
  {
3553
3553
  type: "button",
3554
- "aria-label": `Rate ${w} out of 5`,
3555
- className: R(
3554
+ "aria-label": `Rate ${L} out of 5`,
3555
+ className: P(
3556
3556
  U.starButton,
3557
3557
  r && U["is-submitted"]
3558
3558
  ),
3559
- onClick: () => h(w),
3560
- onMouseEnter: () => _(w),
3559
+ onClick: () => h(L),
3560
+ onMouseEnter: () => _(L),
3561
3561
  onMouseLeave: () => _(void 0),
3562
- children: /* @__PURE__ */ t("span", { className: U.ratingIconWrap, "aria-hidden": !0, children: /* @__PURE__ */ t(zr, { color: y, selected: I }) })
3562
+ children: /* @__PURE__ */ t("span", { className: U.ratingIconWrap, "aria-hidden": !0, children: /* @__PURE__ */ t(zr, { color: y, selected: T }) })
3563
3563
  },
3564
- w
3564
+ L
3565
3565
  );
3566
3566
  }) }) }),
3567
3567
  !r && /* @__PURE__ */ t(
@@ -3571,7 +3571,7 @@ const ti = [
3571
3571
  onClick: d,
3572
3572
  disabled: s === void 0 || l,
3573
3573
  "aria-label": m,
3574
- className: R(
3574
+ className: P(
3575
3575
  U.submitButton,
3576
3576
  s !== void 0 && !l && U["is-active"]
3577
3577
  ),
@@ -3581,7 +3581,7 @@ const ti = [
3581
3581
  ] })
3582
3582
  }
3583
3583
  );
3584
- }, si = "text-message-module__textMessageBase___p4r-t", ri = "text-message-module__textContent___yRb8d", Ye = {
3584
+ }, si = "text-message-module__textMessageBase___p4r-t", ri = "text-message-module__textContent___yRb8d", Xe = {
3585
3585
  textMessageBase: si,
3586
3586
  textContent: ri
3587
3587
  }, ii = G(
@@ -3591,9 +3591,9 @@ const ti = [
3591
3591
  de,
3592
3592
  {
3593
3593
  ref: o,
3594
- className: R(Ye.textMessageBase, n),
3594
+ className: P(Xe.textMessageBase, n),
3595
3595
  ...a,
3596
- children: s ? /* @__PURE__ */ t(it, { text: e, className: Ye.textContent }) : /* @__PURE__ */ t("div", { className: Ye.textContent, children: e })
3596
+ children: s ? /* @__PURE__ */ t(it, { text: e, className: Xe.textContent }) : /* @__PURE__ */ t("div", { className: Xe.textContent, children: e })
3597
3597
  }
3598
3598
  );
3599
3599
  }
@@ -3606,7 +3606,7 @@ function li({
3606
3606
  onEnded: s
3607
3607
  }) {
3608
3608
  const i = S(null), [r, l] = N(!1), { activeId: h, setActive: _, clearActive: d } = ke();
3609
- E(() => {
3609
+ I(() => {
3610
3610
  e && h !== e && r && i.current?.pause();
3611
3611
  }, [h, e, r]);
3612
3612
  const u = b(() => {
@@ -3663,7 +3663,7 @@ const ci = "video-message-module__videoMessageBase___RX3Qk", di = "video-message
3663
3663
  de,
3664
3664
  {
3665
3665
  ref: _,
3666
- className: R(Se.videoMessageBase, l),
3666
+ className: P(Se.videoMessageBase, l),
3667
3667
  ...h,
3668
3668
  children: /* @__PURE__ */ f("div", { className: Se.videoContainer, children: [
3669
3669
  /* @__PURE__ */ t(
@@ -3720,7 +3720,7 @@ function gi() {
3720
3720
  }
3721
3721
  );
3722
3722
  }
3723
- const fi = "preview-events-module__debugContainer___P9sMZ", pi = "preview-events-module__isCollapsible___Wioh1", Ci = "preview-events-module__debugHeader___5JQ-z", vi = "preview-events-module__debugArrow___bZ2MW", bi = "preview-events-module__debugIcon___U7Cd-", wi = "preview-events-module__debugTitle___2woRJ", Li = "preview-events-module__debugContent___gjEW1", yi = "preview-events-module__debugDetail___T8Mtr", Si = "preview-events-module__debugLabel___ZoZkq", Ni = "preview-events-module__debugValue___U-Sy5", Mi = "preview-events-module__debugItemWithIcon___hA1rE", Ai = "preview-events-module__debugContentWrapper___KPaYl", Ii = "preview-events-module__seeInfoButton___tEdQN", Ei = "preview-events-module__guardrailItem___-SEcp", Ti = "preview-events-module__isLastItem___s0M7V", xi = "preview-events-module__guardrailLabel___Vsipd", Pi = "preview-events-module__guardrailValue___YlnOM", Ri = "preview-events-module__fileSourceValue___kHKp-", Bi = "preview-events-module__urlSourceValue___qCosj", L = {
3723
+ const fi = "preview-events-module__debugContainer___P9sMZ", pi = "preview-events-module__isCollapsible___Wioh1", Ci = "preview-events-module__debugHeader___5JQ-z", vi = "preview-events-module__debugArrow___bZ2MW", bi = "preview-events-module__debugIcon___U7Cd-", wi = "preview-events-module__debugTitle___2woRJ", Li = "preview-events-module__debugContent___gjEW1", yi = "preview-events-module__debugDetail___T8Mtr", Si = "preview-events-module__debugLabel___ZoZkq", Ni = "preview-events-module__debugValue___U-Sy5", Mi = "preview-events-module__debugItemWithIcon___hA1rE", Ai = "preview-events-module__debugContentWrapper___KPaYl", Ti = "preview-events-module__seeInfoButton___tEdQN", Ei = "preview-events-module__guardrailItem___-SEcp", Ii = "preview-events-module__isLastItem___s0M7V", xi = "preview-events-module__guardrailLabel___Vsipd", Ri = "preview-events-module__guardrailValue___YlnOM", Pi = "preview-events-module__fileSourceValue___kHKp-", Bi = "preview-events-module__urlSourceValue___qCosj", w = {
3724
3724
  debugContainer: fi,
3725
3725
  isCollapsible: pi,
3726
3726
  debugHeader: Ci,
@@ -3733,12 +3733,12 @@ const fi = "preview-events-module__debugContainer___P9sMZ", pi = "preview-events
3733
3733
  debugValue: Ni,
3734
3734
  debugItemWithIcon: Mi,
3735
3735
  debugContentWrapper: Ai,
3736
- seeInfoButton: Ii,
3736
+ seeInfoButton: Ti,
3737
3737
  guardrailItem: Ei,
3738
- isLastItem: Ti,
3738
+ isLastItem: Ii,
3739
3739
  guardrailLabel: xi,
3740
- guardrailValue: Pi,
3741
- fileSourceValue: Ri,
3740
+ guardrailValue: Ri,
3741
+ fileSourceValue: Pi,
3742
3742
  urlSourceValue: Bi
3743
3743
  };
3744
3744
  function ki() {
@@ -3796,8 +3796,8 @@ function jt({
3796
3796
  default:
3797
3797
  return null;
3798
3798
  }
3799
- }, { hasKnowledge: w, isFaithful: I } = ce(() => o === "no_knowledge" ? { hasKnowledge: !1, isFaithful: !1 } : o === "hallucination" ? { hasKnowledge: !0, isFaithful: !1 } : { hasKnowledge: !0, isFaithful: !0 }, [o]);
3800
- return E(() => {
3799
+ }, { hasKnowledge: L, isFaithful: T } = ce(() => o === "no_knowledge" ? { hasKnowledge: !1, isFaithful: !1 } : o === "hallucination" ? { hasKnowledge: !0, isFaithful: !1 } : { hasKnowledge: !0, isFaithful: !0 }, [o]);
3800
+ return I(() => {
3801
3801
  if (i || !s || n.length === 0)
3802
3802
  return;
3803
3803
  let y = !1;
@@ -3806,10 +3806,10 @@ function jt({
3806
3806
  try {
3807
3807
  const M = await s.getChunkIdsGroupedBySource(n);
3808
3808
  if (y) return;
3809
- const k = M.map((V) => V.source), W = M.flatMap(
3810
- (V) => V.chunks
3809
+ const k = M.map((W) => W.source), V = M.flatMap(
3810
+ (W) => W.chunks
3811
3811
  );
3812
- d(M), c(k), g(W);
3812
+ d(M), c(k), g(V);
3813
3813
  } catch (M) {
3814
3814
  y || console.error("Error fetching chunks with sources:", M);
3815
3815
  } finally {
@@ -3824,8 +3824,8 @@ function jt({
3824
3824
  chunksWithSources: _,
3825
3825
  isLoading: C,
3826
3826
  getIconForSourceType: v,
3827
- hasKnowledge: w,
3828
- isFaithful: I
3827
+ hasKnowledge: L,
3828
+ isFaithful: T
3829
3829
  };
3830
3830
  }
3831
3831
  function Qt() {
@@ -3906,7 +3906,7 @@ function Zt() {
3906
3906
  }
3907
3907
  );
3908
3908
  }
3909
- const T = {
3909
+ const E = {
3910
3910
  GUARDRAIL_TRIGGERED: "Guardrail triggered",
3911
3911
  KNOWLEDGE_FOUND: "Knowledge found",
3912
3912
  FAITHFUL_ANSWER: "Faithful answer",
@@ -3933,19 +3933,22 @@ const T = {
3933
3933
  AGENTS_AVAILABLE: "Agents available",
3934
3934
  SPECIALISTS_AVAILABLE: "Specialists available",
3935
3935
  NO_TRANSFER: "No transfer",
3936
- TRANSFERRED_TO: "Transferred to"
3937
- }, Xt = ({
3936
+ TRANSFERRED_TO: "Transferred to",
3937
+ TYPE: "Type",
3938
+ OPERATOR: "Operator",
3939
+ TARGET: "Target"
3940
+ }, Yt = ({
3938
3941
  guardrail: e,
3939
3942
  keyPrefix: n,
3940
3943
  isLastItem: a
3941
3944
  }) => /* @__PURE__ */ f(
3942
3945
  "div",
3943
3946
  {
3944
- className: R(L.guardrailItem, { [L.isLastItem]: a }),
3947
+ className: P(w.guardrailItem, { [w.isLastItem]: a }),
3945
3948
  children: [
3946
3949
  /* @__PURE__ */ t(Zt, {}),
3947
- /* @__PURE__ */ t("span", { className: L.guardrailLabel, children: T.GUARDRAIL_TRIGGERED }),
3948
- /* @__PURE__ */ f("span", { className: L.guardrailValue, children: [
3950
+ /* @__PURE__ */ t("span", { className: w.guardrailLabel, children: E.GUARDRAIL_TRIGGERED }),
3951
+ /* @__PURE__ */ f("span", { className: w.guardrailValue, children: [
3949
3952
  "- ",
3950
3953
  e
3951
3954
  ] })
@@ -3957,24 +3960,24 @@ const T = {
3957
3960
  keyPrefix: n,
3958
3961
  isLastItem: a
3959
3962
  }) => /* @__PURE__ */ t(B, { children: e.map((o) => /* @__PURE__ */ t(
3960
- Xt,
3963
+ Yt,
3961
3964
  {
3962
3965
  guardrail: o,
3963
3966
  keyPrefix: n,
3964
3967
  isLastItem: a
3965
3968
  },
3966
3969
  `${n}-${o}`
3967
- )) }), Yt = ({
3970
+ )) }), Xt = ({
3968
3971
  sources: e,
3969
3972
  chunks: n,
3970
3973
  getIconForSourceType: a,
3971
3974
  onSeeChunks: o,
3972
- label: s = T.SOURCES
3973
- }) => e.length === 0 ? null : /* @__PURE__ */ f("div", { className: L.debugDetail, children: [
3974
- /* @__PURE__ */ t("strong", { className: L.debugLabel, children: s }),
3975
+ label: s = E.SOURCES
3976
+ }) => e.length === 0 ? null : /* @__PURE__ */ f("div", { className: w.debugDetail, children: [
3977
+ /* @__PURE__ */ t("strong", { className: w.debugLabel, children: s }),
3975
3978
  e.map((i) => {
3976
3979
  const r = a(i), l = i.type === "url", h = l ? i.activeExtractionJob?.url : i.activeExtractionJob?.fileName;
3977
- return /* @__PURE__ */ f("div", { className: L.debugItemWithIcon, children: [
3980
+ return /* @__PURE__ */ f("div", { className: w.debugItemWithIcon, children: [
3978
3981
  r,
3979
3982
  l ? /* @__PURE__ */ t(
3980
3983
  "a",
@@ -3983,23 +3986,23 @@ const T = {
3983
3986
  target: "_blank",
3984
3987
  rel: "noopener noreferrer",
3985
3988
  title: h ?? "Not detected",
3986
- className: L.urlSourceValue,
3989
+ className: w.urlSourceValue,
3987
3990
  children: h
3988
3991
  }
3989
- ) : /* @__PURE__ */ t("span", { className: L.fileSourceValue, children: h })
3992
+ ) : /* @__PURE__ */ t("span", { className: w.fileSourceValue, children: h })
3990
3993
  ] }, i.id);
3991
3994
  }),
3992
3995
  n.length > 0 && /* @__PURE__ */ t(
3993
3996
  "button",
3994
3997
  {
3995
3998
  type: "button",
3996
- className: L.seeInfoButton,
3999
+ className: w.seeInfoButton,
3997
4000
  onClick: o,
3998
- children: T.SEE_CHUNKS_BUTTON
4001
+ children: E.SEE_CHUNKS_BUTTON
3999
4002
  }
4000
4003
  )
4001
4004
  ] });
4002
- function Wi() {
4005
+ function Vi() {
4003
4006
  return /* @__PURE__ */ t(
4004
4007
  "svg",
4005
4008
  {
@@ -4012,23 +4015,23 @@ function Wi() {
4012
4015
  }
4013
4016
  );
4014
4017
  }
4015
- const Vi = ({ tools: e, onSeeToolDetails: n }) => e.length ? /* @__PURE__ */ f("div", { className: L.debugDetail, children: [
4016
- /* @__PURE__ */ t("strong", { className: L.debugLabel, children: T.EXECUTED_TOOLS }),
4018
+ const Wi = ({ tools: e, onSeeToolDetails: n }) => e.length ? /* @__PURE__ */ f("div", { className: w.debugDetail, children: [
4019
+ /* @__PURE__ */ t("strong", { className: w.debugLabel, children: E.EXECUTED_TOOLS }),
4017
4020
  e.map((a, o) => /* @__PURE__ */ f(
4018
4021
  "div",
4019
4022
  {
4020
- className: L.debugItemWithIcon,
4023
+ className: w.debugItemWithIcon,
4021
4024
  children: [
4022
- /* @__PURE__ */ t(Wi, {}),
4025
+ /* @__PURE__ */ t(Vi, {}),
4023
4026
  a.tool_name,
4024
4027
  /* @__PURE__ */ t(
4025
4028
  "button",
4026
4029
  {
4027
4030
  type: "button",
4028
- className: L.seeInfoButton,
4031
+ className: w.seeInfoButton,
4029
4032
  style: { border: "none", flexShrink: 0 },
4030
4033
  onClick: () => n(a),
4031
- children: T.SEE_TOOL_DETAILS
4034
+ children: E.SEE_TOOL_DETAILS
4032
4035
  }
4033
4036
  )
4034
4037
  ]
@@ -4078,41 +4081,41 @@ const Ui = ({
4078
4081
  }), C = () => {
4079
4082
  r?.onClickOpenChunks?.(m);
4080
4083
  }, p = (v) => {
4081
- const w = {
4084
+ const L = {
4082
4085
  toolName: v.tool_name,
4083
4086
  toolArguments: v.tool_arguments ?? {},
4084
4087
  knowledgebaseSourcesIds: v.knowledgebase_sources_ids,
4085
4088
  knowledgebaseChunksIds: v.knowledgebase_chunks_ids
4086
4089
  };
4087
- r?.onClickOpenToolResults?.(w);
4090
+ r?.onClickOpenToolResults?.(L);
4088
4091
  };
4089
4092
  return /* @__PURE__ */ f(B, { children: [
4090
- d && /* @__PURE__ */ f("div", { className: L.debugDetail, children: [
4091
- /* @__PURE__ */ t("strong", { className: L.debugLabel, children: T.QUERY }),
4092
- /* @__PURE__ */ f("div", { className: L.debugValue, children: [
4093
+ d && /* @__PURE__ */ f("div", { className: w.debugDetail, children: [
4094
+ /* @__PURE__ */ t("strong", { className: w.debugLabel, children: E.QUERY }),
4095
+ /* @__PURE__ */ f("div", { className: w.debugValue, children: [
4093
4096
  '"',
4094
4097
  d,
4095
4098
  '"'
4096
4099
  ] })
4097
4100
  ] }),
4098
4101
  /* @__PURE__ */ t(
4099
- Yt,
4102
+ Xt,
4100
4103
  {
4101
4104
  sources: u,
4102
4105
  chunks: c,
4103
4106
  getIconForSourceType: g,
4104
4107
  onSeeChunks: C,
4105
- label: T.KNOWLEDGE_SOURCES
4108
+ label: E.KNOWLEDGE_SOURCES
4106
4109
  }
4107
4110
  ),
4108
4111
  /* @__PURE__ */ t(
4109
- Vi,
4112
+ Wi,
4110
4113
  {
4111
4114
  tools: l,
4112
4115
  onSeeToolDetails: p
4113
4116
  }
4114
4117
  ),
4115
- !e.length && /* @__PURE__ */ t("div", { className: L.debugDetail, children: /* @__PURE__ */ t("strong", { className: L.debugLabel, children: T.NO_TOOLS_EXECUTED }) }),
4118
+ !e.length && /* @__PURE__ */ t("div", { className: w.debugDetail, children: /* @__PURE__ */ t("strong", { className: w.debugLabel, children: E.NO_TOOLS_EXECUTED }) }),
4116
4119
  /* @__PURE__ */ t(
4117
4120
  wt,
4118
4121
  {
@@ -4128,8 +4131,8 @@ const Ui = ({
4128
4131
  isLastItem: !o && !s
4129
4132
  }
4130
4133
  ),
4131
- o && /* @__PURE__ */ t("div", { className: L.debugDetail, children: /* @__PURE__ */ t("strong", { className: L.debugLabel, children: T.EXIT }) }),
4132
- s && /* @__PURE__ */ t("div", { className: L.debugDetail, children: /* @__PURE__ */ t("strong", { className: L.debugLabel, children: T.ERROR }) })
4134
+ o && /* @__PURE__ */ t("div", { className: w.debugDetail, children: /* @__PURE__ */ t("strong", { className: w.debugLabel, children: E.EXIT }) }),
4135
+ s && /* @__PURE__ */ t("div", { className: w.debugDetail, children: /* @__PURE__ */ t("strong", { className: w.debugLabel, children: E.ERROR }) })
4133
4136
  ] });
4134
4137
  }, $i = (e) => ({
4135
4138
  action: x.AiAgent,
@@ -4212,15 +4215,15 @@ const qi = ({
4212
4215
  is_transferred_to_specialist: a,
4213
4216
  last_agent_name: o
4214
4217
  }) => /* @__PURE__ */ f(B, { children: [
4215
- n.length > 0 && /* @__PURE__ */ f("div", { className: L.debugDetail, "data-line-end": !0, children: [
4216
- /* @__PURE__ */ t("strong", { className: L.debugLabel, children: T.SPECIALISTS_AVAILABLE }),
4217
- n.map((s) => /* @__PURE__ */ f("div", { className: L.debugItemWithIcon, children: [
4218
+ n.length > 0 && /* @__PURE__ */ f("div", { className: w.debugDetail, "data-line-end": !0, children: [
4219
+ /* @__PURE__ */ t("strong", { className: w.debugLabel, children: E.SPECIALISTS_AVAILABLE }),
4220
+ n.map((s) => /* @__PURE__ */ f("div", { className: w.debugItemWithIcon, children: [
4218
4221
  /* @__PURE__ */ t(Qt, {}),
4219
4222
  s.name
4220
4223
  ] }, s.name))
4221
4224
  ] }),
4222
- /* @__PURE__ */ t("div", { className: L.debugDetail, children: a ? /* @__PURE__ */ f("div", { className: L.debugValue, children: [
4223
- T.TRANSFERRED_TO,
4225
+ /* @__PURE__ */ t("div", { className: w.debugDetail, children: a ? /* @__PURE__ */ f("div", { className: w.debugValue, children: [
4226
+ E.TRANSFERRED_TO,
4224
4227
  " ",
4225
4228
  /* @__PURE__ */ f("span", { style: { fontWeight: 400 }, children: [
4226
4229
  "- ",
@@ -4229,18 +4232,18 @@ const qi = ({
4229
4232
  ] }) : e.length > 0 ? /* @__PURE__ */ t(B, { children: e.map((s) => /* @__PURE__ */ f(
4230
4233
  "div",
4231
4234
  {
4232
- className: L.debugItemWithIcon,
4235
+ className: w.debugItemWithIcon,
4233
4236
  children: [
4234
4237
  /* @__PURE__ */ t(Zt, {}),
4235
- /* @__PURE__ */ t("span", { className: L.guardrailLabel, children: T.GUARDRAIL_TRIGGERED }),
4236
- /* @__PURE__ */ f("span", { className: L.guardrailValue, children: [
4238
+ /* @__PURE__ */ t("span", { className: w.guardrailLabel, children: E.GUARDRAIL_TRIGGERED }),
4239
+ /* @__PURE__ */ f("span", { className: w.guardrailValue, children: [
4237
4240
  "- ",
4238
4241
  s
4239
4242
  ] })
4240
4243
  ]
4241
4244
  },
4242
4245
  `input-guardrail-${s}`
4243
- )) }) : /* @__PURE__ */ t("div", { className: L.debugValue, children: T.NO_TRANSFER }) })
4246
+ )) }) : /* @__PURE__ */ t("div", { className: w.debugValue, children: E.NO_TRANSFER }) })
4244
4247
  ] }), Ki = (e) => ({
4245
4248
  action: x.AiAgentRouter,
4246
4249
  title: /* @__PURE__ */ f(B, { children: [
@@ -4280,7 +4283,7 @@ const Qi = (e) => ({
4280
4283
  icon: /* @__PURE__ */ t(ji, {}),
4281
4284
  collapsible: !1
4282
4285
  });
4283
- function We() {
4286
+ function Ve() {
4284
4287
  return /* @__PURE__ */ t(
4285
4288
  "svg",
4286
4289
  {
@@ -4303,9 +4306,9 @@ const Zi = (e) => ({
4303
4306
  ] })
4304
4307
  ] }),
4305
4308
  component: null,
4306
- icon: /* @__PURE__ */ t(We, {}),
4309
+ icon: /* @__PURE__ */ t(Ve, {}),
4307
4310
  collapsible: !1
4308
- }), Xi = (e) => ({
4311
+ }), Yi = (e) => ({
4309
4312
  action: x.ConditionalCountry,
4310
4313
  title: /* @__PURE__ */ f(B, { children: [
4311
4314
  "Country checked ",
@@ -4315,37 +4318,44 @@ const Zi = (e) => ({
4315
4318
  ] })
4316
4319
  ] }),
4317
4320
  component: null,
4318
- icon: /* @__PURE__ */ t(We, {}),
4321
+ icon: /* @__PURE__ */ t(Ve, {}),
4319
4322
  collapsible: !1
4320
- }), Yi = (e) => ({
4321
- action: x.ConditionalCustom,
4322
- title: /* @__PURE__ */ f(B, { children: [
4323
- "Custom condition checked ",
4324
- /* @__PURE__ */ f("span", { children: [
4325
- "- ",
4326
- e.conditional_variable
4327
- ] })
4323
+ }), Xi = (e) => /* @__PURE__ */ f(B, { children: [
4324
+ /* @__PURE__ */ f("div", { className: w.debugDetail, children: [
4325
+ /* @__PURE__ */ t("strong", { className: w.debugLabel, children: E.TYPE }),
4326
+ /* @__PURE__ */ t("div", { className: w.debugValue, children: e.variable_format })
4328
4327
  ] }),
4329
- component: null,
4330
- icon: /* @__PURE__ */ t(We, {}),
4331
- collapsible: !1
4332
- }), Ji = (e) => {
4333
- const n = e.is_queue_open ? T.OPEN : T.CLOSED, a = e.is_available_agent ? T.YES : T.NO;
4328
+ /* @__PURE__ */ f("div", { className: w.debugDetail, children: [
4329
+ /* @__PURE__ */ t("strong", { className: w.debugLabel, children: E.OPERATOR }),
4330
+ /* @__PURE__ */ t("div", { className: w.debugValue, children: e.operator })
4331
+ ] }),
4332
+ /* @__PURE__ */ f("div", { className: w.debugDetail, children: [
4333
+ /* @__PURE__ */ t("strong", { className: w.debugLabel, children: E.TARGET }),
4334
+ /* @__PURE__ */ t("div", { className: w.debugValue, children: e.conditional_variable })
4335
+ ] })
4336
+ ] }), Ji = (e) => ({
4337
+ action: x.ConditionalCustom,
4338
+ title: /* @__PURE__ */ t(B, { children: "Custom condition" }),
4339
+ component: Xi,
4340
+ icon: /* @__PURE__ */ t(Ve, {}),
4341
+ collapsible: !0
4342
+ }), el = (e) => {
4343
+ const n = e.is_queue_open ? E.OPEN : E.CLOSED, a = e.is_available_agent ? E.YES : E.NO;
4334
4344
  return /* @__PURE__ */ f(B, { children: [
4335
- /* @__PURE__ */ f("div", { className: L.debugDetail, children: [
4336
- /* @__PURE__ */ t("strong", { className: L.debugLabel, children: T.QUEUE }),
4337
- /* @__PURE__ */ t("div", { className: L.debugValue, children: e.queue_name })
4345
+ /* @__PURE__ */ f("div", { className: w.debugDetail, children: [
4346
+ /* @__PURE__ */ t("strong", { className: w.debugLabel, children: E.QUEUE }),
4347
+ /* @__PURE__ */ t("div", { className: w.debugValue, children: e.queue_name })
4338
4348
  ] }),
4339
- /* @__PURE__ */ f("div", { className: L.debugDetail, children: [
4340
- /* @__PURE__ */ t("strong", { className: L.debugLabel, children: T.STATUS }),
4341
- /* @__PURE__ */ t("div", { className: L.debugValue, children: n })
4349
+ /* @__PURE__ */ f("div", { className: w.debugDetail, children: [
4350
+ /* @__PURE__ */ t("strong", { className: w.debugLabel, children: E.STATUS }),
4351
+ /* @__PURE__ */ t("div", { className: w.debugValue, children: n })
4342
4352
  ] }),
4343
- /* @__PURE__ */ f("div", { className: L.debugDetail, children: [
4344
- /* @__PURE__ */ t("strong", { className: L.debugLabel, children: T.AGENTS_AVAILABLE }),
4345
- /* @__PURE__ */ t("div", { className: L.debugValue, children: a })
4353
+ /* @__PURE__ */ f("div", { className: w.debugDetail, children: [
4354
+ /* @__PURE__ */ t("strong", { className: w.debugLabel, children: E.AGENTS_AVAILABLE }),
4355
+ /* @__PURE__ */ t("div", { className: w.debugValue, children: a })
4346
4356
  ] })
4347
4357
  ] });
4348
- }, el = (e) => ({
4358
+ }, tl = (e) => ({
4349
4359
  action: x.ConditionalQueueStatus,
4350
4360
  title: /* @__PURE__ */ f(B, { children: [
4351
4361
  "Queue status checked ",
@@ -4354,11 +4364,11 @@ const Zi = (e) => ({
4354
4364
  e.queue_name
4355
4365
  ] })
4356
4366
  ] }),
4357
- component: Ji,
4358
- icon: /* @__PURE__ */ t(We, {}),
4367
+ component: el,
4368
+ icon: /* @__PURE__ */ t(Ve, {}),
4359
4369
  collapsible: !0
4360
4370
  });
4361
- function tl() {
4371
+ function nl() {
4362
4372
  return /* @__PURE__ */ t(
4363
4373
  "svg",
4364
4374
  {
@@ -4371,7 +4381,7 @@ function tl() {
4371
4381
  }
4372
4382
  );
4373
4383
  }
4374
- const nl = (e) => {
4384
+ const ol = (e) => {
4375
4385
  const n = e.fallback_out === 1 ? "1st" : "2nd";
4376
4386
  return {
4377
4387
  action: x.Fallback,
@@ -4384,11 +4394,11 @@ const nl = (e) => {
4384
4394
  ] })
4385
4395
  ] }),
4386
4396
  component: null,
4387
- icon: /* @__PURE__ */ t(tl, {}),
4397
+ icon: /* @__PURE__ */ t(nl, {}),
4388
4398
  collapsible: !1
4389
4399
  };
4390
4400
  };
4391
- function ol() {
4401
+ function al() {
4392
4402
  return /* @__PURE__ */ t(
4393
4403
  "svg",
4394
4404
  {
@@ -4401,9 +4411,9 @@ function ol() {
4401
4411
  }
4402
4412
  );
4403
4413
  }
4404
- const al = (e) => {
4414
+ const sl = (e) => {
4405
4415
  const [n, a] = N();
4406
- return E(() => {
4416
+ return I(() => {
4407
4417
  if (!e.previewUtils || !e.handoff_note_id)
4408
4418
  return;
4409
4419
  let o = !1;
@@ -4418,20 +4428,20 @@ const al = (e) => {
4418
4428
  o = !0;
4419
4429
  };
4420
4430
  }, [e.previewUtils, e.handoff_note_id]), /* @__PURE__ */ f(B, { children: [
4421
- /* @__PURE__ */ f("div", { className: L.debugDetail, children: [
4422
- /* @__PURE__ */ t("strong", { className: L.debugLabel, children: T.QUEUE }),
4423
- /* @__PURE__ */ t("div", { className: L.debugValue, children: e.handoff_queue_name })
4431
+ /* @__PURE__ */ f("div", { className: w.debugDetail, children: [
4432
+ /* @__PURE__ */ t("strong", { className: w.debugLabel, children: E.QUEUE }),
4433
+ /* @__PURE__ */ t("div", { className: w.debugValue, children: e.handoff_queue_name })
4424
4434
  ] }),
4425
- /* @__PURE__ */ f("div", { className: L.debugDetail, children: [
4426
- /* @__PURE__ */ t("strong", { className: L.debugLabel, children: T.AUTO_ASSIGN }),
4427
- /* @__PURE__ */ t("div", { className: L.debugValue, children: e.handoff_has_auto_assign ? T.AUTO_ASSIGN_ON : T.AUTO_ASSIGN_OFF })
4435
+ /* @__PURE__ */ f("div", { className: w.debugDetail, children: [
4436
+ /* @__PURE__ */ t("strong", { className: w.debugLabel, children: E.AUTO_ASSIGN }),
4437
+ /* @__PURE__ */ t("div", { className: w.debugValue, children: e.handoff_has_auto_assign ? E.AUTO_ASSIGN_ON : E.AUTO_ASSIGN_OFF })
4428
4438
  ] }),
4429
- !!n && /* @__PURE__ */ f("div", { className: L.debugDetail, children: [
4430
- /* @__PURE__ */ t("strong", { className: L.debugLabel, children: T.NOTE }),
4431
- /* @__PURE__ */ t("div", { className: L.debugValue, children: n })
4439
+ !!n && /* @__PURE__ */ f("div", { className: w.debugDetail, children: [
4440
+ /* @__PURE__ */ t("strong", { className: w.debugLabel, children: E.NOTE }),
4441
+ /* @__PURE__ */ t("div", { className: w.debugValue, children: n })
4432
4442
  ] })
4433
4443
  ] });
4434
- }, sl = (e) => ({
4444
+ }, rl = (e) => ({
4435
4445
  action: x.HandoffSuccess,
4436
4446
  title: /* @__PURE__ */ f(B, { children: [
4437
4447
  "Handoff to agent ",
@@ -4440,11 +4450,11 @@ const al = (e) => {
4440
4450
  e.handoff_queue_name
4441
4451
  ] })
4442
4452
  ] }),
4443
- icon: /* @__PURE__ */ t(ol, {}),
4444
- component: al,
4453
+ icon: /* @__PURE__ */ t(al, {}),
4454
+ component: sl,
4445
4455
  collapsible: !0
4446
4456
  });
4447
- function rl() {
4457
+ function il() {
4448
4458
  return /* @__PURE__ */ t(
4449
4459
  "svg",
4450
4460
  {
@@ -4457,7 +4467,7 @@ function rl() {
4457
4467
  }
4458
4468
  );
4459
4469
  }
4460
- const il = (e) => ({
4470
+ const ll = (e) => ({
4461
4471
  action: x.Keyword,
4462
4472
  title: /* @__PURE__ */ f(B, { children: [
4463
4473
  "Keyword matched ",
@@ -4468,10 +4478,10 @@ const il = (e) => ({
4468
4478
  ] })
4469
4479
  ] }),
4470
4480
  component: null,
4471
- icon: /* @__PURE__ */ t(rl, {}),
4481
+ icon: /* @__PURE__ */ t(il, {}),
4472
4482
  collapsible: !1
4473
4483
  });
4474
- function ll() {
4484
+ function cl() {
4475
4485
  return /* @__PURE__ */ t(
4476
4486
  "svg",
4477
4487
  {
@@ -4484,7 +4494,7 @@ function ll() {
4484
4494
  }
4485
4495
  );
4486
4496
  }
4487
- function cl() {
4497
+ function dl() {
4488
4498
  return /* @__PURE__ */ t(
4489
4499
  "svg",
4490
4500
  {
@@ -4497,7 +4507,7 @@ function cl() {
4497
4507
  }
4498
4508
  );
4499
4509
  }
4500
- const dl = (e) => {
4510
+ const ul = (e) => {
4501
4511
  const {
4502
4512
  sources: n,
4503
4513
  chunks: a,
@@ -4515,20 +4525,20 @@ const dl = (e) => {
4515
4525
  e.previewUtils?.onClickOpenChunks?.(o);
4516
4526
  };
4517
4527
  return /* @__PURE__ */ f(B, { children: [
4518
- /* @__PURE__ */ f("div", { className: L.debugDetail, children: [
4519
- /* @__PURE__ */ t("strong", { className: L.debugLabel, children: T.QUERY }),
4520
- /* @__PURE__ */ f("div", { className: L.debugValue, children: [
4528
+ /* @__PURE__ */ f("div", { className: w.debugDetail, children: [
4529
+ /* @__PURE__ */ t("strong", { className: w.debugLabel, children: E.QUERY }),
4530
+ /* @__PURE__ */ f("div", { className: w.debugValue, children: [
4521
4531
  '"',
4522
4532
  e.user_input,
4523
4533
  '"'
4524
4534
  ] })
4525
4535
  ] }),
4526
- l ? /* @__PURE__ */ f("div", { className: L.debugDetail, children: [
4527
- /* @__PURE__ */ t("strong", { className: L.debugLabel, children: T.KNOWLEDGE_BASE_FAIL_REASON }),
4528
- /* @__PURE__ */ t("div", { className: L.debugValue, children: e.knowledgebase_fail_reason })
4536
+ l ? /* @__PURE__ */ f("div", { className: w.debugDetail, children: [
4537
+ /* @__PURE__ */ t("strong", { className: w.debugLabel, children: E.KNOWLEDGE_BASE_FAIL_REASON }),
4538
+ /* @__PURE__ */ t("div", { className: w.debugValue, children: e.knowledgebase_fail_reason })
4529
4539
  ] }) : /* @__PURE__ */ f(B, { children: [
4530
4540
  /* @__PURE__ */ t(
4531
- Yt,
4541
+ Xt,
4532
4542
  {
4533
4543
  sources: n,
4534
4544
  chunks: a,
@@ -4537,33 +4547,33 @@ const dl = (e) => {
4537
4547
  }
4538
4548
  ),
4539
4549
  i && /* @__PURE__ */ t(
4540
- Xt,
4550
+ Yt,
4541
4551
  {
4542
- guardrail: T.KNOWLEDGE_FOUND,
4552
+ guardrail: E.KNOWLEDGE_FOUND,
4543
4553
  keyPrefix: "kb-knowledge"
4544
4554
  }
4545
4555
  ),
4546
4556
  r && /* @__PURE__ */ f(
4547
4557
  "div",
4548
4558
  {
4549
- className: `${L.guardrailItem} ${L.isLastItem}`,
4559
+ className: `${w.guardrailItem} ${w.isLastItem}`,
4550
4560
  "data-line-end": !0,
4551
4561
  children: [
4552
- /* @__PURE__ */ t(ll, {}),
4553
- /* @__PURE__ */ t("span", { className: L.guardrailLabel, children: T.FAITHFUL_ANSWER })
4562
+ /* @__PURE__ */ t(cl, {}),
4563
+ /* @__PURE__ */ t("span", { className: w.guardrailLabel, children: E.FAITHFUL_ANSWER })
4554
4564
  ]
4555
4565
  }
4556
4566
  )
4557
4567
  ] })
4558
4568
  ] });
4559
- }, ul = (e) => ({
4569
+ }, ml = (e) => ({
4560
4570
  action: x.Knowledgebase,
4561
4571
  title: /* @__PURE__ */ t(B, { children: "Knowledge Base triggered" }),
4562
- component: dl,
4563
- icon: /* @__PURE__ */ t(cl, {}),
4572
+ component: ul,
4573
+ icon: /* @__PURE__ */ t(dl, {}),
4564
4574
  collapsible: !0
4565
4575
  });
4566
- function ml() {
4576
+ function _l() {
4567
4577
  return /* @__PURE__ */ t(
4568
4578
  "svg",
4569
4579
  {
@@ -4576,7 +4586,7 @@ function ml() {
4576
4586
  }
4577
4587
  );
4578
4588
  }
4579
- const _l = (e) => ({
4589
+ const hl = (e) => ({
4580
4590
  action: x.RedirectFlow,
4581
4591
  title: /* @__PURE__ */ f(B, { children: [
4582
4592
  "Redirected to flow ",
@@ -4586,10 +4596,10 @@ const _l = (e) => ({
4586
4596
  ] })
4587
4597
  ] }),
4588
4598
  component: null,
4589
- icon: /* @__PURE__ */ t(ml, {}),
4599
+ icon: /* @__PURE__ */ t(_l, {}),
4590
4600
  collapsible: !1
4591
4601
  });
4592
- function hl() {
4602
+ function gl() {
4593
4603
  return /* @__PURE__ */ t(
4594
4604
  "svg",
4595
4605
  {
@@ -4602,7 +4612,7 @@ function hl() {
4602
4612
  }
4603
4613
  );
4604
4614
  }
4605
- const gl = (e) => ({
4615
+ const fl = (e) => ({
4606
4616
  action: x.IntentSmart,
4607
4617
  title: /* @__PURE__ */ f(B, { children: [
4608
4618
  "Smart intent triggered",
@@ -4614,9 +4624,9 @@ const gl = (e) => ({
4614
4624
  ] })
4615
4625
  ] }),
4616
4626
  component: null,
4617
- icon: /* @__PURE__ */ t(hl, {})
4627
+ icon: /* @__PURE__ */ t(gl, {})
4618
4628
  });
4619
- function fl() {
4629
+ function pl() {
4620
4630
  return /* @__PURE__ */ t(
4621
4631
  "svg",
4622
4632
  {
@@ -4629,7 +4639,7 @@ function fl() {
4629
4639
  }
4630
4640
  );
4631
4641
  }
4632
- const pl = (e) => ({
4642
+ const Cl = (e) => ({
4633
4643
  action: x.WebviewActionTriggered,
4634
4644
  title: /* @__PURE__ */ f(B, { children: [
4635
4645
  "Webview action triggered ",
@@ -4639,16 +4649,16 @@ const pl = (e) => ({
4639
4649
  ] })
4640
4650
  ] }),
4641
4651
  component: null,
4642
- icon: /* @__PURE__ */ t(fl, {}),
4652
+ icon: /* @__PURE__ */ t(pl, {}),
4643
4653
  collapsible: !1
4644
4654
  });
4645
- function Cl({
4655
+ function vl({
4646
4656
  wrapperRef: e,
4647
4657
  isExpanded: n,
4648
4658
  debugEvent: a,
4649
4659
  isCollapsible: o
4650
4660
  }) {
4651
- E(() => {
4661
+ I(() => {
4652
4662
  if (!o)
4653
4663
  return;
4654
4664
  if (!n || !e.current) {
@@ -4693,52 +4703,52 @@ function Cl({
4693
4703
  };
4694
4704
  }, [n, a, e, o]);
4695
4705
  }
4696
- function vl(e) {
4706
+ function bl(e) {
4697
4707
  switch (e.action) {
4698
4708
  case x.Keyword:
4699
- return il(e);
4709
+ return ll(e);
4700
4710
  case x.IntentSmart:
4701
- return gl(e);
4711
+ return fl(e);
4702
4712
  case x.HandoffSuccess:
4703
- return sl(e);
4713
+ return rl(e);
4704
4714
  case x.AiAgent:
4705
4715
  return $i(e);
4706
4716
  case x.AiAgentRouter:
4707
4717
  return Ki(e);
4708
4718
  case x.Knowledgebase:
4709
- return ul();
4719
+ return ml();
4710
4720
  case x.Fallback:
4711
- return nl(e);
4721
+ return ol(e);
4712
4722
  case x.BotAction:
4713
4723
  return Qi(e);
4714
4724
  case x.ConditionalChannel:
4715
4725
  return Zi(e);
4716
4726
  case x.ConditionalCountry:
4717
- return Xi(e);
4718
- case x.ConditionalCustom:
4719
4727
  return Yi(e);
4728
+ case x.ConditionalCustom:
4729
+ return Ji();
4720
4730
  case x.ConditionalQueueStatus:
4721
- return el(e);
4731
+ return tl(e);
4722
4732
  case x.RedirectFlow:
4723
- return _l(e);
4733
+ return hl(e);
4724
4734
  case x.WebviewActionTriggered:
4725
- return pl(e);
4735
+ return Cl(e);
4726
4736
  default:
4727
4737
  return;
4728
4738
  }
4729
4739
  }
4730
- function bl({
4740
+ function wl({
4731
4741
  debugEvent: e,
4732
4742
  messageId: n,
4733
4743
  previewUtils: a
4734
4744
  }) {
4735
- const [o, s] = N(!1), i = S(null), r = vl(e);
4736
- Cl({
4745
+ const [o, s] = N(!1), i = S(null), r = bl(e);
4746
+ vl({
4737
4747
  wrapperRef: i,
4738
4748
  isExpanded: o,
4739
4749
  debugEvent: e,
4740
4750
  isCollapsible: r?.collapsible ?? !1
4741
- }), E(() => {
4751
+ }), I(() => {
4742
4752
  o && a?.trackPreviewEventOpened?.({ action: e.action });
4743
4753
  }, [a, o, e]);
4744
4754
  const l = b(
@@ -4757,12 +4767,12 @@ function bl({
4757
4767
  handleContainerClick: l
4758
4768
  };
4759
4769
  }
4760
- const wl = "system-message", Ll = ({
4770
+ const Ll = "system-message", yl = ({
4761
4771
  debugEvent: e,
4762
4772
  messageId: n,
4763
4773
  previewUtils: a
4764
4774
  }) => {
4765
- const { isExpanded: o, eventConfig: s, wrapperRef: i, handleContainerClick: r } = bl({ debugEvent: e, messageId: n, previewUtils: a }), { messageClasses: l, standaloneAvatarProps: h } = rt({
4775
+ const { isExpanded: o, eventConfig: s, wrapperRef: i, handleContainerClick: r } = wl({ debugEvent: e, messageId: n, previewUtils: a }), { messageClasses: l, standaloneAvatarProps: h } = rt({
4766
4776
  variant: "bot",
4767
4777
  children: null,
4768
4778
  hideFooter: !0
@@ -4770,28 +4780,28 @@ const wl = "system-message", Ll = ({
4770
4780
  if (!s)
4771
4781
  return null;
4772
4782
  const { title: _, icon: d, component: u, collapsible: c } = s, m = u;
4773
- return /* @__PURE__ */ f("div", { className: l, role: wl, children: [
4783
+ return /* @__PURE__ */ f("div", { className: l, role: Ll, children: [
4774
4784
  h && /* @__PURE__ */ t(De, { ...h }),
4775
4785
  /* @__PURE__ */ f(
4776
4786
  "div",
4777
4787
  {
4778
- className: R(L.debugContainer, {
4779
- [L.isCollapsible]: c
4788
+ className: P(w.debugContainer, {
4789
+ [w.isCollapsible]: c
4780
4790
  }),
4781
4791
  "data-webchat-message-bubble": !0,
4782
4792
  onClick: c ? r : void 0,
4783
4793
  children: [
4784
- /* @__PURE__ */ f("div", { className: L.debugHeader, children: [
4785
- /* @__PURE__ */ t("span", { className: L.debugIcon, children: d }),
4786
- /* @__PURE__ */ t("span", { className: L.debugTitle, children: _ }),
4787
- c && /* @__PURE__ */ t("span", { className: L.debugArrow, children: o ? /* @__PURE__ */ t(gi, {}) : /* @__PURE__ */ t(hi, {}) })
4794
+ /* @__PURE__ */ f("div", { className: w.debugHeader, children: [
4795
+ /* @__PURE__ */ t("span", { className: w.debugIcon, children: d }),
4796
+ /* @__PURE__ */ t("span", { className: w.debugTitle, children: _ }),
4797
+ c && /* @__PURE__ */ t("span", { className: w.debugArrow, children: o ? /* @__PURE__ */ t(gi, {}) : /* @__PURE__ */ t(hi, {}) })
4788
4798
  ] }),
4789
4799
  m && /* @__PURE__ */ t(
4790
4800
  "div",
4791
4801
  {
4792
- className: L.debugContent,
4802
+ className: w.debugContent,
4793
4803
  style: { display: o ? "block" : "none" },
4794
- children: /* @__PURE__ */ t("div", { className: L.debugContentWrapper, ref: i, children: /* @__PURE__ */ t(
4804
+ children: /* @__PURE__ */ t("div", { className: w.debugContentWrapper, ref: i, children: /* @__PURE__ */ t(
4795
4805
  m,
4796
4806
  {
4797
4807
  ...e,
@@ -4806,7 +4816,7 @@ const wl = "system-message", Ll = ({
4806
4816
  )
4807
4817
  ] });
4808
4818
  };
4809
- function yl({
4819
+ function Sl({
4810
4820
  messageActor: e,
4811
4821
  baseProps: n = {}
4812
4822
  }) {
@@ -4875,7 +4885,7 @@ function yl({
4875
4885
  handleButtonClick: r
4876
4886
  };
4877
4887
  }
4878
- const Sl = ({
4888
+ const Nl = ({
4879
4889
  messageActor: e,
4880
4890
  customMessageRenderer: n,
4881
4891
  baseProps: a = {
@@ -4885,11 +4895,11 @@ const Sl = ({
4885
4895
  onImageLoadStart: s,
4886
4896
  onImageLoadComplete: i
4887
4897
  }) => {
4888
- const { message: r, messageProps: l, handleButtonClick: h } = yl({
4898
+ const { message: r, messageProps: l, handleButtonClick: h } = Sl({
4889
4899
  messageActor: e,
4890
4900
  baseProps: a
4891
4901
  });
4892
- return E(() => {
4902
+ return I(() => {
4893
4903
  if (r && r.type === "image") {
4894
4904
  const d = `img-${r.id}-${r.data}`;
4895
4905
  s?.(d);
@@ -5022,7 +5032,7 @@ const Sl = ({
5022
5032
  );
5023
5033
  }
5024
5034
  return r.isSystemDebugTrace() ? /* @__PURE__ */ t(
5025
- Ll,
5035
+ yl,
5026
5036
  {
5027
5037
  debugEvent: r.data.event_data,
5028
5038
  messageId: d,
@@ -5039,7 +5049,7 @@ const Sl = ({
5039
5049
  ), null) : (console.warn(`Unknown message type: ${r.type}`), null);
5040
5050
  })() }) : null;
5041
5051
  };
5042
- function Nl(e) {
5052
+ function Ml(e) {
5043
5053
  return ce(() => {
5044
5054
  if (!e)
5045
5055
  return { bot: null, agent: null };
@@ -5064,7 +5074,7 @@ function Nl(e) {
5064
5074
  };
5065
5075
  }, [e]);
5066
5076
  }
5067
- function Ml(e, n, a) {
5077
+ function Al(e, n, a) {
5068
5078
  const {
5069
5079
  variant: o = "default",
5070
5080
  hasUserInteracted: s = !1,
@@ -5081,7 +5091,7 @@ function Ml(e, n, a) {
5081
5091
  return C ? Array.from(C.values()) : [];
5082
5092
  },
5083
5093
  (g, C) => g.length === C.length
5084
- ), c = Nl(n.avatarConfig), m = z(
5094
+ ), c = Ml(n.avatarConfig), m = z(
5085
5095
  n.controller.machine,
5086
5096
  (g) => g.context.isTypingOn,
5087
5097
  (g, C) => g === C
@@ -5118,8 +5128,8 @@ function Ml(e, n, a) {
5118
5128
  }
5119
5129
  };
5120
5130
  }
5121
- const Al = 8, Il = 1, El = 350, Tl = 2;
5122
- function xl({
5131
+ const Tl = 8, El = 1, Il = 350, xl = 2;
5132
+ function Rl({
5123
5133
  scrollRef: e,
5124
5134
  hasUserInteracted: n,
5125
5135
  messageActorsLength: a,
@@ -5131,12 +5141,12 @@ function xl({
5131
5141
  if (!n) return;
5132
5142
  const c = e.current;
5133
5143
  if (!c) return;
5134
- const m = c.scrollTop <= Tl;
5144
+ const m = c.scrollTop <= xl;
5135
5145
  i?.(m);
5136
5146
  }, [n, i]), d = b(() => {
5137
5147
  const c = e.current;
5138
5148
  if (!c) return;
5139
- const m = r.current ? c.scrollTop > Il : c.scrollTop > Al;
5149
+ const m = r.current ? c.scrollTop > El : c.scrollTop > Tl;
5140
5150
  r.current !== m && (r.current = m, s?.(m));
5141
5151
  }, [s]), u = b(() => {
5142
5152
  d(), !l.current && _();
@@ -5150,7 +5160,7 @@ function xl({
5150
5160
  behavior: "smooth"
5151
5161
  }), h.current = window.setTimeout(() => {
5152
5162
  l.current = !1, u();
5153
- }, El), requestAnimationFrame(u);
5163
+ }, Il), requestAnimationFrame(u);
5154
5164
  });
5155
5165
  }, [a, o, u]), { handleScrollState: u };
5156
5166
  }
@@ -5160,7 +5170,7 @@ const Pl = "webchat-messages-module__base___V7acY", pe = {
5160
5170
  "scroll-fade-bottom": "webchat-messages-module__scroll-fade-bottom___WoP9u",
5161
5171
  "typing-indicator-container": "webchat-messages-module__typing-indicator-container___v3bpq",
5162
5172
  default: "webchat-messages-module__default___3C2qm"
5163
- }, Rl = j(pe.base, {
5173
+ }, Bl = j(pe.base, {
5164
5174
  variants: {
5165
5175
  variant: {
5166
5176
  default: pe.default
@@ -5169,20 +5179,20 @@ const Pl = "webchat-messages-module__base___V7acY", pe = {
5169
5179
  defaultVariants: {
5170
5180
  variant: "default"
5171
5181
  }
5172
- }), Bl = 1, kl = /* @__PURE__ */ new Set([gn.Text]);
5182
+ }), kl = 1, Ol = /* @__PURE__ */ new Set([gn.Text]);
5173
5183
  function Lt(e) {
5174
- return kl.has(e.type);
5184
+ return Ol.has(e.type);
5175
5185
  }
5176
- function Ol(e, n) {
5177
- return !e || !n ? !1 : Math.abs(n.getTime() - e.getTime()) <= Bl * 6e4;
5186
+ function Dl(e, n) {
5187
+ return !e || !n ? !1 : Math.abs(n.getTime() - e.getTime()) <= kl * 6e4;
5178
5188
  }
5179
5189
  function yt(e, n) {
5180
- return !e || !n || !Lt(e) || !Lt(n) || e.sent_by !== n.sent_by ? !1 : Ol(
5190
+ return !e || !n || !Lt(e) || !Lt(n) || e.sent_by !== n.sent_by ? !1 : Dl(
5181
5191
  et(e.id),
5182
5192
  et(n.id)
5183
5193
  );
5184
5194
  }
5185
- function Dl({
5195
+ function Vl({
5186
5196
  messageActors: e,
5187
5197
  isTyping: n,
5188
5198
  hasUserInteracted: a = !1,
@@ -5195,7 +5205,7 @@ function Dl({
5195
5205
  onUserInteraction: _,
5196
5206
  previewUtils: d
5197
5207
  }) {
5198
- const { handleScrollState: u } = xl({
5208
+ const { handleScrollState: u } = Rl({
5199
5209
  scrollRef: r,
5200
5210
  hasUserInteracted: a ?? !1,
5201
5211
  messageActorsLength: e.length,
@@ -5206,9 +5216,9 @@ function Dl({
5206
5216
  (m, g, C, p) => {
5207
5217
  const v = m;
5208
5218
  if (v.type === "custom" && v.data && o) {
5209
- const w = o[v.data.name];
5210
- if (w && typeof w == "function")
5211
- return w({
5219
+ const L = o[v.data.name];
5220
+ if (L && typeof L == "function")
5221
+ return L({
5212
5222
  ...v.data.props,
5213
5223
  onButtonClick: C,
5214
5224
  messageProps: p,
@@ -5228,9 +5238,9 @@ function Dl({
5228
5238
  onScroll: u,
5229
5239
  children: [
5230
5240
  e && e.length > 0 && e.map((m, g) => {
5231
- const C = e[g - 1]?.getSnapshot().context?.message, p = m.getSnapshot().context?.message, v = e[g + 1]?.getSnapshot().context?.message, w = yt(p, v), I = yt(C, p);
5241
+ const C = e[g - 1]?.getSnapshot().context?.message, p = m.getSnapshot().context?.message, v = e[g + 1]?.getSnapshot().context?.message, L = yt(p, v), T = yt(C, p);
5232
5242
  return /* @__PURE__ */ t(
5233
- Sl,
5243
+ Nl,
5234
5244
  {
5235
5245
  messageActor: m,
5236
5246
  customMessageRenderer: c,
@@ -5240,8 +5250,8 @@ function Dl({
5240
5250
  botAvatarConfig: s,
5241
5251
  agentAvatarConfig: i,
5242
5252
  onUserInteraction: _,
5243
- hideFooter: w,
5244
- isContinuation: I,
5253
+ hideFooter: L,
5254
+ isContinuation: T,
5245
5255
  botInteractionId: p?.bot_interaction_id,
5246
5256
  previewUtils: d
5247
5257
  }
@@ -5256,7 +5266,7 @@ function Dl({
5256
5266
  );
5257
5267
  }
5258
5268
  function Wl(e) {
5259
- const { state: n, previewUtils: a } = q(), o = S(null), s = S(null), { messagesProps: i, messageListProps: r, variants: l } = Ml(
5269
+ const { state: n, previewUtils: a } = q(), o = S(null), s = S(null), { messagesProps: i, messageListProps: r, variants: l } = Al(
5260
5270
  e,
5261
5271
  n,
5262
5272
  o
@@ -5265,10 +5275,10 @@ function Wl(e) {
5265
5275
  "div",
5266
5276
  {
5267
5277
  ...i,
5268
- className: Rl(l),
5278
+ className: Bl(l),
5269
5279
  "data-webchat-messages": !0,
5270
5280
  children: /* @__PURE__ */ t(
5271
- Dl,
5281
+ Vl,
5272
5282
  {
5273
5283
  ...r,
5274
5284
  customMessages: n.customMessages,
@@ -5279,7 +5289,7 @@ function Wl(e) {
5279
5289
  }
5280
5290
  );
5281
5291
  }
5282
- function Vl({
5292
+ function zl({
5283
5293
  isOpen: e,
5284
5294
  onClose: n,
5285
5295
  onControllerReady: a,
@@ -5290,21 +5300,21 @@ function Vl({
5290
5300
  icons: l,
5291
5301
  heroHeaderLayout: h
5292
5302
  }) {
5293
- const { controller: _, state: d } = q(), u = S(!1), c = In({
5303
+ const { controller: _, state: d } = q(), u = S(!1), c = Tn({
5294
5304
  controller: _,
5295
5305
  isOpen: e,
5296
5306
  layout: h,
5297
5307
  enableResponsiveHeroHeader: d.enableResponsiveHeroHeader
5298
5308
  }), { header: m, messages: g, onUserEngagement: C } = c;
5299
- return E(() => {
5309
+ return I(() => {
5300
5310
  _ && !u.current && (u.current = !0, a?.(_));
5301
- }, [_, a]), E(() => {
5311
+ }, [_, a]), I(() => {
5302
5312
  if (!_) return;
5303
- const w = _.machine.getSnapshot().context.isOpen ?? !1;
5304
- e && !w ? _.open() : !e && w && _.close();
5313
+ const L = _.machine.getSnapshot().context.isOpen ?? !1;
5314
+ e && !L ? _.open() : !e && L && _.close();
5305
5315
  }, [e, _]), /* @__PURE__ */ f(Ao, { layout: "default", coverRegistry: r, children: [
5306
5316
  /* @__PURE__ */ t(
5307
- Vo,
5317
+ Wo,
5308
5318
  {
5309
5319
  title: o,
5310
5320
  onClose: () => {
@@ -5317,12 +5327,12 @@ function Vl({
5317
5327
  children: /* @__PURE__ */ t(
5318
5328
  nn,
5319
5329
  {
5320
- trigger: /* @__PURE__ */ t(Rt, { "aria-label": "Open menu" }),
5330
+ trigger: /* @__PURE__ */ t(Pt, { "aria-label": "Open menu" }),
5321
5331
  placement: "bottom right",
5322
5332
  children: ({ close: v }) => /* @__PURE__ */ f(on, { children: [
5323
5333
  /* @__PURE__ */ t(Uo, { onClose: v }),
5324
5334
  /* @__PURE__ */ t(Fo, { onClose: v }),
5325
- /* @__PURE__ */ t(Yo, {}),
5335
+ /* @__PURE__ */ t(Xo, {}),
5326
5336
  /* @__PURE__ */ t(Zo, { onClose: v })
5327
5337
  ] })
5328
5338
  }
@@ -5342,7 +5352,7 @@ function Vl({
5342
5352
  )
5343
5353
  ] });
5344
5354
  }
5345
- function zl({
5355
+ function Fl({
5346
5356
  appId: e,
5347
5357
  isOpen: n,
5348
5358
  onClose: a,
@@ -5366,7 +5376,7 @@ function zl({
5366
5376
  avatarConfig: h,
5367
5377
  ...c,
5368
5378
  children: /* @__PURE__ */ t(
5369
- Vl,
5379
+ zl,
5370
5380
  {
5371
5381
  isOpen: n,
5372
5382
  onClose: a,
@@ -5382,50 +5392,50 @@ function zl({
5382
5392
  }
5383
5393
  );
5384
5394
  }
5385
- const Jl = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
5395
+ const ec = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
5386
5396
  __proto__: null,
5387
- WebchatApp: zl
5397
+ WebchatApp: Fl
5388
5398
  }, Symbol.toStringTag, { value: "Module" }));
5389
5399
  export {
5390
5400
  ho as A,
5391
5401
  xn as B,
5392
5402
  Do as C,
5393
5403
  Nn as D,
5394
- Yr as E,
5404
+ Xr as E,
5395
5405
  So as F,
5396
5406
  q as G,
5397
5407
  xo as H,
5398
- In as I,
5408
+ Tn as I,
5399
5409
  Ga as J,
5400
- Ml as K,
5410
+ Al as K,
5401
5411
  yn as L,
5402
5412
  it as M,
5403
- Jl as N,
5413
+ ec as N,
5404
5414
  yo as O,
5405
- Ll as P,
5415
+ yl as P,
5406
5416
  Ut as Q,
5407
5417
  ai as R,
5408
- wl as S,
5418
+ Ll as S,
5409
5419
  as as T,
5410
- zl as W,
5420
+ Fl as W,
5411
5421
  qn as a,
5412
- Tt as b,
5422
+ It as b,
5413
5423
  jn as c,
5414
5424
  Fo as d,
5415
5425
  Uo as e,
5416
5426
  Zo as f,
5417
- Yo as g,
5418
- Rt as h,
5427
+ Xo as g,
5428
+ Pt as h,
5419
5429
  de as i,
5420
5430
  st as j,
5421
- Sl as k,
5431
+ Nl as k,
5422
5432
  ro as l,
5423
- Pt as m,
5433
+ Rt as m,
5424
5434
  Jn as n,
5425
5435
  fo as o,
5426
5436
  so as p,
5427
5437
  Ao as q,
5428
- Vo as r,
5438
+ Wo as r,
5429
5439
  Ka as s,
5430
5440
  Wl as t,
5431
5441
  Sn as u,