@smarttalks.ai/widget 0.9.9 → 0.9.10

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.
package/lib/index.js CHANGED
@@ -230,7 +230,7 @@ function xa(e, ...t) {
230
230
  const X = (e) => {
231
231
  const t = (n) => n[e] || [];
232
232
  return t.isThemeGetter = !0, t;
233
- }, Si = /^\[(?:([a-z-]+):)?(.+)\]$/i, Sa = /^\d+\/\d+$/, ka = /* @__PURE__ */ new Set(["px", "full", "screen"]), Ea = /^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/, Ca = /\d+(%|px|r?em|[sdl]?v([hwib]|min|max)|pt|pc|in|cm|mm|cap|ch|ex|r?lh|cq(w|h|i|b|min|max))|\b(calc|min|max|clamp)\(.+\)|^0$/, Oa = /^(rgba?|hsla?|hwb|(ok)?(lab|lch))\(.+\)$/, _a = /^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/, Pa = /^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/, Ke = (e) => gt(e) || ka.has(e) || Sa.test(e), We = (e) => vt(e, "length", Fa), gt = (e) => !!e && !Number.isNaN(Number(e)), jn = (e) => vt(e, "number", gt), Tt = (e) => !!e && Number.isInteger(Number(e)), Aa = (e) => e.endsWith("%") && gt(e.slice(0, -1)), N = (e) => Si.test(e), Ge = (e) => Ea.test(e), Ta = /* @__PURE__ */ new Set(["length", "size", "percentage"]), La = (e) => vt(e, Ta, ki), Ma = (e) => vt(e, "position", ki), Da = /* @__PURE__ */ new Set(["image", "url"]), Ia = (e) => vt(e, Da, Na), Ra = (e) => vt(e, "", $a), Lt = () => !0, vt = (e, t, n) => {
233
+ }, Si = /^\[(?:([a-z-]+):)?(.+)\]$/i, Sa = /^\d+\/\d+$/, ka = /* @__PURE__ */ new Set(["px", "full", "screen"]), Ea = /^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/, Ca = /\d+(%|px|r?em|[sdl]?v([hwib]|min|max)|pt|pc|in|cm|mm|cap|ch|ex|r?lh|cq(w|h|i|b|min|max))|\b(calc|min|max|clamp)\(.+\)|^0$/, Oa = /^(rgba?|hsla?|hwb|(ok)?(lab|lch))\(.+\)$/, _a = /^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/, Pa = /^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/, Ne = (e) => gt(e) || ka.has(e) || Sa.test(e), He = (e) => vt(e, "length", Fa), gt = (e) => !!e && !Number.isNaN(Number(e)), jn = (e) => vt(e, "number", gt), Tt = (e) => !!e && Number.isInteger(Number(e)), Aa = (e) => e.endsWith("%") && gt(e.slice(0, -1)), N = (e) => Si.test(e), We = (e) => Ea.test(e), Ta = /* @__PURE__ */ new Set(["length", "size", "percentage"]), La = (e) => vt(e, Ta, ki), Ma = (e) => vt(e, "position", ki), Da = /* @__PURE__ */ new Set(["image", "url"]), Ia = (e) => vt(e, Da, Na), Ra = (e) => vt(e, "", $a), Lt = () => !0, vt = (e, t, n) => {
234
234
  const r = Si.exec(e);
235
235
  return r ? r[1] ? typeof t == "string" ? r[1] === t : t.has(r[1]) : n(r[2]) : !1;
236
236
  }, Fa = (e) => (
@@ -239,17 +239,17 @@ const X = (e) => {
239
239
  // I could also use lookbehind assertion in `lengthUnitRegex` but that isn't supported widely enough.
240
240
  Ca.test(e) && !Oa.test(e)
241
241
  ), ki = () => !1, $a = (e) => _a.test(e), Na = (e) => Pa.test(e), Ka = () => {
242
- const e = X("colors"), t = X("spacing"), n = X("blur"), r = X("brightness"), o = X("borderColor"), i = X("borderRadius"), s = X("borderSpacing"), a = X("borderWidth"), l = X("contrast"), c = X("grayscale"), d = X("hueRotate"), u = X("invert"), f = X("gap"), g = X("gradientColorStops"), h = X("gradientColorStopPositions"), p = X("inset"), m = X("margin"), b = X("opacity"), w = X("padding"), v = X("saturate"), x = X("scale"), _ = X("sepia"), E = X("skew"), k = X("space"), F = X("translate"), P = () => ["auto", "contain", "none"], R = () => ["auto", "hidden", "clip", "visible", "scroll"], M = () => ["auto", N, t], D = () => [N, t], ne = () => ["", Ke, We], W = () => ["auto", gt, N], ce = () => ["bottom", "center", "left", "left-bottom", "left-top", "right", "right-bottom", "right-top", "top"], $ = () => ["solid", "dashed", "dotted", "double", "none"], z = () => ["normal", "multiply", "screen", "overlay", "darken", "lighten", "color-dodge", "color-burn", "hard-light", "soft-light", "difference", "exclusion", "hue", "saturation", "color", "luminosity"], Q = () => ["start", "end", "center", "between", "around", "evenly", "stretch"], oe = () => ["", "0", N], ut = () => ["auto", "avoid", "all", "avoid-page", "page", "left", "right", "column"], ke = () => [gt, N];
242
+ const e = X("colors"), t = X("spacing"), n = X("blur"), r = X("brightness"), o = X("borderColor"), i = X("borderRadius"), s = X("borderSpacing"), a = X("borderWidth"), l = X("contrast"), c = X("grayscale"), d = X("hueRotate"), u = X("invert"), f = X("gap"), g = X("gradientColorStops"), h = X("gradientColorStopPositions"), p = X("inset"), m = X("margin"), b = X("opacity"), w = X("padding"), v = X("saturate"), x = X("scale"), _ = X("sepia"), E = X("skew"), k = X("space"), F = X("translate"), P = () => ["auto", "contain", "none"], R = () => ["auto", "hidden", "clip", "visible", "scroll"], M = () => ["auto", N, t], D = () => [N, t], ne = () => ["", Ne, He], W = () => ["auto", gt, N], ce = () => ["bottom", "center", "left", "left-bottom", "left-top", "right", "right-bottom", "right-top", "top"], $ = () => ["solid", "dashed", "dotted", "double", "none"], z = () => ["normal", "multiply", "screen", "overlay", "darken", "lighten", "color-dodge", "color-burn", "hard-light", "soft-light", "difference", "exclusion", "hue", "saturation", "color", "luminosity"], Q = () => ["start", "end", "center", "between", "around", "evenly", "stretch"], oe = () => ["", "0", N], ut = () => ["auto", "avoid", "all", "avoid-page", "page", "left", "right", "column"], ke = () => [gt, N];
243
243
  return {
244
244
  cacheSize: 500,
245
245
  separator: ":",
246
246
  theme: {
247
247
  colors: [Lt],
248
- spacing: [Ke, We],
249
- blur: ["none", "", Ge, N],
248
+ spacing: [Ne, He],
249
+ blur: ["none", "", We, N],
250
250
  brightness: ke(),
251
251
  borderColor: [e],
252
- borderRadius: ["none", "", "full", Ge, N],
252
+ borderRadius: ["none", "", "full", We, N],
253
253
  borderSpacing: D(),
254
254
  borderWidth: ne(),
255
255
  contrast: ke(),
@@ -258,7 +258,7 @@ const X = (e) => {
258
258
  invert: oe(),
259
259
  gap: D(),
260
260
  gradientColorStops: [e],
261
- gradientColorStopPositions: [Aa, We],
261
+ gradientColorStopPositions: [Aa, He],
262
262
  inset: M(),
263
263
  margin: M(),
264
264
  opacity: ke(),
@@ -289,7 +289,7 @@ const X = (e) => {
289
289
  * @see https://tailwindcss.com/docs/columns
290
290
  */
291
291
  columns: [{
292
- columns: [Ge]
292
+ columns: [We]
293
293
  }],
294
294
  /**
295
295
  * Break After
@@ -873,8 +873,8 @@ const X = (e) => {
873
873
  */
874
874
  "max-w": [{
875
875
  "max-w": [N, t, "none", "full", "min", "max", "fit", "prose", {
876
- screen: [Ge]
877
- }, Ge]
876
+ screen: [We]
877
+ }, We]
878
878
  }],
879
879
  /**
880
880
  * Height
@@ -910,7 +910,7 @@ const X = (e) => {
910
910
  * @see https://tailwindcss.com/docs/font-size
911
911
  */
912
912
  "font-size": [{
913
- text: ["base", Ge, We]
913
+ text: ["base", We, He]
914
914
  }],
915
915
  /**
916
916
  * Font Smoothing
@@ -985,7 +985,7 @@ const X = (e) => {
985
985
  * @see https://tailwindcss.com/docs/line-height
986
986
  */
987
987
  leading: [{
988
- leading: ["none", "tight", "snug", "normal", "relaxed", "loose", Ke, N]
988
+ leading: ["none", "tight", "snug", "normal", "relaxed", "loose", Ne, N]
989
989
  }],
990
990
  /**
991
991
  * List Style Image
@@ -1061,14 +1061,14 @@ const X = (e) => {
1061
1061
  * @see https://tailwindcss.com/docs/text-decoration-thickness
1062
1062
  */
1063
1063
  "text-decoration-thickness": [{
1064
- decoration: ["auto", "from-font", Ke, We]
1064
+ decoration: ["auto", "from-font", Ne, He]
1065
1065
  }],
1066
1066
  /**
1067
1067
  * Text Underline Offset
1068
1068
  * @see https://tailwindcss.com/docs/text-underline-offset
1069
1069
  */
1070
1070
  "underline-offset": [{
1071
- "underline-offset": ["auto", Ke, N]
1071
+ "underline-offset": ["auto", Ne, N]
1072
1072
  }],
1073
1073
  /**
1074
1074
  * Text Decoration Color
@@ -1550,14 +1550,14 @@ const X = (e) => {
1550
1550
  * @see https://tailwindcss.com/docs/outline-offset
1551
1551
  */
1552
1552
  "outline-offset": [{
1553
- "outline-offset": [Ke, N]
1553
+ "outline-offset": [Ne, N]
1554
1554
  }],
1555
1555
  /**
1556
1556
  * Outline Width
1557
1557
  * @see https://tailwindcss.com/docs/outline-width
1558
1558
  */
1559
1559
  "outline-w": [{
1560
- outline: [Ke, We]
1560
+ outline: [Ne, He]
1561
1561
  }],
1562
1562
  /**
1563
1563
  * Outline Color
@@ -1597,7 +1597,7 @@ const X = (e) => {
1597
1597
  * @see https://tailwindcss.com/docs/ring-offset-width
1598
1598
  */
1599
1599
  "ring-offset-w": [{
1600
- "ring-offset": [Ke, We]
1600
+ "ring-offset": [Ne, He]
1601
1601
  }],
1602
1602
  /**
1603
1603
  * Ring Offset Color
@@ -1612,7 +1612,7 @@ const X = (e) => {
1612
1612
  * @see https://tailwindcss.com/docs/box-shadow
1613
1613
  */
1614
1614
  shadow: [{
1615
- shadow: ["", "inner", "none", Ge, Ra]
1615
+ shadow: ["", "inner", "none", We, Ra]
1616
1616
  }],
1617
1617
  /**
1618
1618
  * Box Shadow Color
@@ -1677,7 +1677,7 @@ const X = (e) => {
1677
1677
  * @see https://tailwindcss.com/docs/drop-shadow
1678
1678
  */
1679
1679
  "drop-shadow": [{
1680
- "drop-shadow": ["", "none", Ge, N]
1680
+ "drop-shadow": ["", "none", We, N]
1681
1681
  }],
1682
1682
  /**
1683
1683
  * Grayscale
@@ -2192,7 +2192,7 @@ const X = (e) => {
2192
2192
  * @see https://tailwindcss.com/docs/stroke-width
2193
2193
  */
2194
2194
  "stroke-w": [{
2195
- stroke: [Ke, We, jn]
2195
+ stroke: [Ne, He, jn]
2196
2196
  }],
2197
2197
  /**
2198
2198
  * Stroke
@@ -2570,15 +2570,15 @@ const rl = !1, ol = (e, t) => e === t, xe = Symbol("solid-proxy"), Ai = typeof P
2570
2570
  equals: ol
2571
2571
  };
2572
2572
  let Ti = Ri;
2573
- const He = 1, wn = 2, Li = {
2573
+ const qe = 1, wn = 2, Li = {
2574
2574
  owned: null,
2575
2575
  cleanups: null,
2576
2576
  context: null,
2577
2577
  owner: null
2578
2578
  }, Hn = {};
2579
2579
  var q = null;
2580
- let Wn = null, il = null, Y = null, le = null, Be = null, Ln = 0;
2581
- function Ve(e, t) {
2580
+ let Wn = null, il = null, Y = null, le = null, ze = null, Ln = 0;
2581
+ function Be(e, t) {
2582
2582
  const n = Y, r = q, o = e.length === 0, i = t === void 0 ? r : t, s = o ? Li : {
2583
2583
  owned: null,
2584
2584
  cleanups: null,
@@ -2587,7 +2587,7 @@ function Ve(e, t) {
2587
2587
  }, a = o ? e : () => e(() => H(() => zt(s)));
2588
2588
  q = s, Y = null;
2589
2589
  try {
2590
- return Ue(a, !0);
2590
+ return Ve(a, !0);
2591
2591
  } finally {
2592
2592
  Y = n, q = r;
2593
2593
  }
@@ -2603,17 +2603,17 @@ function O(e, t) {
2603
2603
  return [Di.bind(n), r];
2604
2604
  }
2605
2605
  function Mi(e, t, n) {
2606
- const r = Mn(e, t, !0, He);
2606
+ const r = Mn(e, t, !0, qe);
2607
2607
  St(r);
2608
2608
  }
2609
2609
  function ie(e, t, n) {
2610
- const r = Mn(e, t, !1, He);
2610
+ const r = Mn(e, t, !1, qe);
2611
2611
  St(r);
2612
2612
  }
2613
2613
  function L(e, t, n) {
2614
2614
  Ti = fl;
2615
- const r = Mn(e, t, !1, He);
2616
- (!n || !n.render) && (r.user = !0), Be ? Be.push(r) : St(r);
2615
+ const r = Mn(e, t, !1, qe);
2616
+ (!n || !n.render) && (r.user = !0), ze ? ze.push(r) : St(r);
2617
2617
  }
2618
2618
  function C(e, t, n) {
2619
2619
  n = n ? Object.assign({}, bn, n) : bn;
@@ -2639,7 +2639,7 @@ function al(e, t, n) {
2639
2639
  ), a = Hn, E(R, M)), R;
2640
2640
  }
2641
2641
  function E(P, R) {
2642
- Ue(() => {
2642
+ Ve(() => {
2643
2643
  R === void 0 && h(() => P), x(R !== void 0 ? "errored" : d ? "ready" : "unresolved"), m(R);
2644
2644
  for (const M of f.keys()) M.decrement();
2645
2645
  f.clear();
@@ -2664,7 +2664,7 @@ function al(e, t, n) {
2664
2664
  refetching: P
2665
2665
  })
2666
2666
  );
2667
- return sl(M) ? (s = M, "value" in M ? (M.status === "success" ? _(s, M.value, void 0, R) : _(s, void 0, fr(M.value), R), M) : (c = !0, queueMicrotask(() => c = !1), Ue(() => {
2667
+ return sl(M) ? (s = M, "value" in M ? (M.status === "success" ? _(s, M.value, void 0, R) : _(s, void 0, fr(M.value), R), M) : (c = !0, queueMicrotask(() => c = !1), Ve(() => {
2668
2668
  x(d ? "refreshing" : "pending"), w();
2669
2669
  }, !1), M.then(
2670
2670
  (D) => _(M, D, void 0, R),
@@ -2701,7 +2701,7 @@ function al(e, t, n) {
2701
2701
  ];
2702
2702
  }
2703
2703
  function Oe(e) {
2704
- return Ue(e, !1);
2704
+ return Ve(e, !1);
2705
2705
  }
2706
2706
  function H(e) {
2707
2707
  if (Y === null) return e();
@@ -2744,7 +2744,7 @@ function ll(e, t) {
2744
2744
  const n = q, r = Y;
2745
2745
  q = e, Y = null;
2746
2746
  try {
2747
- return Ue(t, !0);
2747
+ return Ve(t, !0);
2748
2748
  } catch (o) {
2749
2749
  Kr(o);
2750
2750
  } finally {
@@ -2773,10 +2773,10 @@ function Nr(e) {
2773
2773
  let cl;
2774
2774
  function Di() {
2775
2775
  if (this.sources && this.state)
2776
- if (this.state === He) St(this);
2776
+ if (this.state === qe) St(this);
2777
2777
  else {
2778
2778
  const e = le;
2779
- le = null, Ue(() => xn(this), !1), le = e;
2779
+ le = null, Ve(() => xn(this), !1), le = e;
2780
2780
  }
2781
2781
  if (Y) {
2782
2782
  const e = this.observers ? this.observers.length : 0;
@@ -2786,10 +2786,10 @@ function Di() {
2786
2786
  }
2787
2787
  function Ii(e, t, n) {
2788
2788
  let r = e.value;
2789
- return (!e.comparator || !e.comparator(r, t)) && (e.value = t, e.observers && e.observers.length && Ue(() => {
2789
+ return (!e.comparator || !e.comparator(r, t)) && (e.value = t, e.observers && e.observers.length && Ve(() => {
2790
2790
  for (let o = 0; o < e.observers.length; o += 1) {
2791
2791
  const i = e.observers[o], s = Wn && Wn.running;
2792
- s && Wn.disposed.has(i), (s ? !i.tState : !i.state) && (i.pure ? le.push(i) : Be.push(i), i.observers && Fi(i)), s || (i.state = He);
2792
+ s && Wn.disposed.has(i), (s ? !i.tState : !i.state) && (i.pure ? le.push(i) : ze.push(i), i.observers && Fi(i)), s || (i.state = qe);
2793
2793
  }
2794
2794
  if (le.length > 1e6)
2795
2795
  throw le = [], new Error();
@@ -2812,13 +2812,13 @@ function ul(e, t, n) {
2812
2812
  try {
2813
2813
  r = e.fn(t);
2814
2814
  } catch (s) {
2815
- return e.pure && (e.state = He, e.owned && e.owned.forEach(zt), e.owned = null), e.updatedAt = n + 1, Kr(s);
2815
+ return e.pure && (e.state = qe, e.owned && e.owned.forEach(zt), e.owned = null), e.updatedAt = n + 1, Kr(s);
2816
2816
  } finally {
2817
2817
  Y = i, q = o;
2818
2818
  }
2819
2819
  (!e.updatedAt || e.updatedAt <= n) && (e.updatedAt != null && "observers" in e ? Ii(e, r) : e.value = r, e.updatedAt = n);
2820
2820
  }
2821
- function Mn(e, t, n, r = He, o) {
2821
+ function Mn(e, t, n, r = qe, o) {
2822
2822
  const i = {
2823
2823
  fn: e,
2824
2824
  state: r,
@@ -2842,28 +2842,28 @@ function vn(e) {
2842
2842
  for (; (e = e.owner) && (!e.updatedAt || e.updatedAt < Ln); )
2843
2843
  e.state && t.push(e);
2844
2844
  for (let n = t.length - 1; n >= 0; n--)
2845
- if (e = t[n], e.state === He)
2845
+ if (e = t[n], e.state === qe)
2846
2846
  St(e);
2847
2847
  else if (e.state === wn) {
2848
2848
  const r = le;
2849
- le = null, Ue(() => xn(e, t[0]), !1), le = r;
2849
+ le = null, Ve(() => xn(e, t[0]), !1), le = r;
2850
2850
  }
2851
2851
  }
2852
- function Ue(e, t) {
2852
+ function Ve(e, t) {
2853
2853
  if (le) return e();
2854
2854
  let n = !1;
2855
- t || (le = []), Be ? n = !0 : Be = [], Ln++;
2855
+ t || (le = []), ze ? n = !0 : ze = [], Ln++;
2856
2856
  try {
2857
2857
  const r = e();
2858
2858
  return dl(n), r;
2859
2859
  } catch (r) {
2860
- n || (Be = null), le = null, Kr(r);
2860
+ n || (ze = null), le = null, Kr(r);
2861
2861
  }
2862
2862
  }
2863
2863
  function dl(e) {
2864
2864
  if (le && (Ri(le), le = null), e) return;
2865
- const t = Be;
2866
- Be = null, t.length && Ue(() => Ti(t), !1);
2865
+ const t = ze;
2866
+ ze = null, t.length && Ve(() => Ti(t), !1);
2867
2867
  }
2868
2868
  function Ri(e) {
2869
2869
  for (let t = 0; t < e.length; t++) vn(e[t]);
@@ -2889,14 +2889,14 @@ function xn(e, t) {
2889
2889
  const r = e.sources[n];
2890
2890
  if (r.sources) {
2891
2891
  const o = r.state;
2892
- o === He ? r !== t && (!r.updatedAt || r.updatedAt < Ln) && vn(r) : o === wn && xn(r, t);
2892
+ o === qe ? r !== t && (!r.updatedAt || r.updatedAt < Ln) && vn(r) : o === wn && xn(r, t);
2893
2893
  }
2894
2894
  }
2895
2895
  }
2896
2896
  function Fi(e) {
2897
2897
  for (let t = 0; t < e.observers.length; t += 1) {
2898
2898
  const n = e.observers[t];
2899
- n.state || (n.state = wn, n.pure ? le.push(n) : Be.push(n), n.observers && Fi(n));
2899
+ n.state || (n.state = wn, n.pure ? le.push(n) : ze.push(n), n.observers && Fi(n));
2900
2900
  }
2901
2901
  }
2902
2902
  function zt(e) {
@@ -2966,10 +2966,10 @@ function pl(e, t, n = {}) {
2966
2966
  return l[ur], H(() => {
2967
2967
  let g, h, p, m, b, w, v, x, _;
2968
2968
  if (c === 0)
2969
- s !== 0 && (wo(i), i = [], r = [], o = [], s = 0, a && (a = [])), n.fallback && (r = [gl], o[0] = Ve((E) => (i[0] = E, n.fallback())), s = 1);
2969
+ s !== 0 && (wo(i), i = [], r = [], o = [], s = 0, a && (a = [])), n.fallback && (r = [gl], o[0] = Be((E) => (i[0] = E, n.fallback())), s = 1);
2970
2970
  else if (s === 0) {
2971
2971
  for (o = new Array(c), u = 0; u < c; u++)
2972
- r[u] = l[u], o[u] = Ve(f);
2972
+ r[u] = l[u], o[u] = Be(f);
2973
2973
  s = c;
2974
2974
  } else {
2975
2975
  for (p = new Array(c), m = new Array(c), a && (b = new Array(c)), w = 0, v = Math.min(s, c); w < v && r[w] === l[w]; w++) ;
@@ -2980,7 +2980,7 @@ function pl(e, t, n = {}) {
2980
2980
  for (d = w; d <= v; d++)
2981
2981
  _ = r[d], u = g.get(_), u !== void 0 && u !== -1 ? (p[u] = o[d], m[u] = i[d], a && (b[u] = a[d]), u = h[u], g.set(_, u)) : i[d]();
2982
2982
  for (u = w; u < c; u++)
2983
- u in p ? (o[u] = p[u], i[u] = m[u], a && (a[u] = b[u], a[u](u))) : o[u] = Ve(f);
2983
+ u in p ? (o[u] = p[u], i[u] = m[u], a && (a[u] = b[u], a[u](u))) : o[u] = Be(f);
2984
2984
  o = o.slice(0, s = c), r = l.slice(0);
2985
2985
  }
2986
2986
  return o;
@@ -3134,7 +3134,7 @@ function j(e, ...t) {
3134
3134
  return [...r, n];
3135
3135
  }
3136
3136
  let yl = 0;
3137
- function Me() {
3137
+ function Le() {
3138
3138
  return V.context ? V.getNextContextId() : `cl-${yl++}`;
3139
3139
  }
3140
3140
  const $i = (e) => `Stale read from <${e}>.`;
@@ -3715,7 +3715,7 @@ function zi(e) {
3715
3715
  const a = r();
3716
3716
  if (a instanceof HTMLHeadElement) {
3717
3717
  const [l, c] = O(!1), d = () => c(!0);
3718
- Ve((u) => A(a, () => l() ? u() : i(), null)), K(d);
3718
+ Be((u) => A(a, () => l() ? u() : i(), null)), K(d);
3719
3719
  } else {
3720
3720
  const l = Ki(e.isSVG ? "g" : "div", e.isSVG), c = t && l.attachShadow ? l.attachShadow({
3721
3721
  mode: "open"
@@ -3774,7 +3774,7 @@ function Vl(e) {
3774
3774
  function Ul(e) {
3775
3775
  return (t, n) => {
3776
3776
  const { element: r } = n;
3777
- return Ve((o) => {
3777
+ return Be((o) => {
3778
3778
  const i = Bl(t);
3779
3779
  r.addPropertyChangedCallback((a, l) => i[a] = l), r.addReleaseCallback(() => {
3780
3780
  r.renderRoot.textContent = "", o();
@@ -3802,7 +3802,7 @@ const ql = '*,:before,:after{--tw-border-spacing-x: 0;--tw-border-spacing-y: 0;-
3802
3802
  hide: Gl,
3803
3803
  toggle: Wl,
3804
3804
  onOpen: Hl
3805
- }), mr = Symbol("store-raw"), mt = Symbol("store-node"), ze = Symbol("store-has"), qi = Symbol("store-self");
3805
+ }), mr = Symbol("store-raw"), mt = Symbol("store-node"), Ke = Symbol("store-has"), qi = Symbol("store-self");
3806
3806
  function Hi(e) {
3807
3807
  let t = e[xe];
3808
3808
  if (!t && (Object.defineProperty(e, xe, {
@@ -3871,7 +3871,7 @@ const Zl = {
3871
3871
  return Wi(e), n;
3872
3872
  const r = kn(e, mt), o = r[t];
3873
3873
  let i = o ? o() : e[t];
3874
- if (t === mt || t === ze || t === "__proto__") return i;
3874
+ if (t === mt || t === Ke || t === "__proto__") return i;
3875
3875
  if (!o) {
3876
3876
  const s = Object.getOwnPropertyDescriptor(e, t);
3877
3877
  dr() && (typeof i != "function" || e.hasOwnProperty(t)) && !(s && s.get) && (i = Ut(r, t, i)());
@@ -3879,7 +3879,7 @@ const Zl = {
3879
3879
  return Sn(i) ? Hi(i) : i;
3880
3880
  },
3881
3881
  has(e, t) {
3882
- return t === mr || t === xe || t === ur || t === mt || t === ze || t === "__proto__" ? !0 : (dr() && Ut(kn(e, ze), t)(), t in e);
3882
+ return t === mr || t === xe || t === ur || t === mt || t === Ke || t === "__proto__" ? !0 : (dr() && Ut(kn(e, Ke), t)(), t in e);
3883
3883
  },
3884
3884
  set() {
3885
3885
  return !0;
@@ -3893,7 +3893,7 @@ const Zl = {
3893
3893
  function En(e, t, n, r = !1) {
3894
3894
  if (!r && e[t] === n) return;
3895
3895
  const o = e[t], i = e.length;
3896
- n === void 0 ? (delete e[t], e[ze] && e[ze][t] && o !== void 0 && e[ze][t].$()) : (e[t] = n, e[ze] && e[ze][t] && o === void 0 && e[ze][t].$());
3896
+ n === void 0 ? (delete e[t], e[Ke] && e[Ke][t] && o !== void 0 && e[Ke][t].$()) : (e[t] = n, e[Ke] && e[Ke][t] && o === void 0 && e[Ke][t].$());
3897
3897
  let s = kn(e, mt), a;
3898
3898
  if ((a = Ut(s, t, o)) && a.$(() => n), Array.isArray(e) && e.length !== i) {
3899
3899
  for (let l = e.length; l < i; l++) (a = s[l]) && a.$();
@@ -3956,7 +3956,7 @@ function ec(...[e, t]) {
3956
3956
  return [o, i];
3957
3957
  }
3958
3958
  function Yi(e, t, n) {
3959
- return Ve(() => {
3959
+ return Be(() => {
3960
3960
  const r = Oi(e), [o, i] = ec(
3961
3961
  r ? JSON.parse(r) : t
3962
3962
  );
@@ -3964,7 +3964,7 @@ function Yi(e, t, n) {
3964
3964
  });
3965
3965
  }
3966
3966
  function tc(e, t, n) {
3967
- return Ve(() => {
3967
+ return Be(() => {
3968
3968
  const r = Oi(e), [o, i] = O(
3969
3969
  r ? JSON.parse(r) : t
3970
3970
  );
@@ -4059,7 +4059,7 @@ const oc = async (e) => {
4059
4059
  }).catch(console.error);
4060
4060
  }
4061
4061
  ), i._id = n, i;
4062
- }, [Xi, ic] = O(""), [rt] = Ve(() => al(Xi, oc)), sc = () => {
4062
+ }, [Xi, ic] = O(""), [rt] = Be(() => al(Xi, oc)), sc = () => {
4063
4063
  if (rt()?.type === "chat") return rt();
4064
4064
  }, ac = () => {
4065
4065
  if (rt()?.type === "form") return rt();
@@ -4069,7 +4069,7 @@ const oc = async (e) => {
4069
4069
  if (typeof window < "u")
4070
4070
  return localStorage.getItem("chat_session_id");
4071
4071
  };
4072
- Ve(
4072
+ Be(
4073
4073
  () => L(() => {
4074
4074
  const e = rt();
4075
4075
  Ba(e), e && (ee("onLoad"), e.sessionId && (console.log("currentWidget.sessionId", e.sessionId), localStorage.setItem("chat_session_id", e.sessionId)));
@@ -4389,11 +4389,11 @@ function Lc(e) {
4389
4389
  function Qi(e) {
4390
4390
  return (t) => `${e()}-${t}`;
4391
4391
  }
4392
- function Le(e, t) {
4392
+ function Te(e, t) {
4393
4393
  return e ? e === t || e.contains(t) : !1;
4394
4394
  }
4395
4395
  function Ft(e, t = !1) {
4396
- const { activeElement: n } = je(e);
4396
+ const { activeElement: n } = Ue(e);
4397
4397
  if (!n?.nodeName)
4398
4398
  return null;
4399
4399
  if (es(n) && n.contentDocument)
@@ -4404,14 +4404,14 @@ function Ft(e, t = !1) {
4404
4404
  if (t) {
4405
4405
  const r = n.getAttribute("aria-activedescendant");
4406
4406
  if (r) {
4407
- const o = je(n).getElementById(r);
4407
+ const o = Ue(n).getElementById(r);
4408
4408
  if (o)
4409
4409
  return o;
4410
4410
  }
4411
4411
  }
4412
4412
  return n;
4413
4413
  }
4414
- function je(e) {
4414
+ function Ue(e) {
4415
4415
  return e ? e.ownerDocument || e : document;
4416
4416
  }
4417
4417
  function es(e) {
@@ -4601,7 +4601,7 @@ function Gc(e, t) {
4601
4601
  }
4602
4602
  return o;
4603
4603
  }
4604
- function $e(e, t) {
4604
+ function Fe(e, t) {
4605
4605
  return T(e, t);
4606
4606
  }
4607
4607
  var Mt = /* @__PURE__ */ new Map(), To = /* @__PURE__ */ new Set();
@@ -4830,7 +4830,7 @@ function eu(e) {
4830
4830
  L(() => {
4831
4831
  if (S(e.isDisabled))
4832
4832
  return;
4833
- const n = e.ownerDocument?.() ?? je();
4833
+ const n = e.ownerDocument?.() ?? Ue();
4834
4834
  n.addEventListener("keydown", t), K(() => {
4835
4835
  n.removeEventListener("keydown", t);
4836
4836
  });
@@ -4851,18 +4851,18 @@ function eu(e) {
4851
4851
  */
4852
4852
  const Cn = "data-kb-top-layer";
4853
4853
  let ss, xr = !1;
4854
- const qe = [];
4854
+ const je = [];
4855
4855
  function jt(e) {
4856
- return qe.findIndex((t) => t.node === e);
4856
+ return je.findIndex((t) => t.node === e);
4857
4857
  }
4858
4858
  function tu(e) {
4859
- return qe[jt(e)];
4859
+ return je[jt(e)];
4860
4860
  }
4861
4861
  function nu(e) {
4862
- return qe[qe.length - 1].node === e;
4862
+ return je[je.length - 1].node === e;
4863
4863
  }
4864
4864
  function as() {
4865
- return qe.filter((e) => e.isPointerBlocking);
4865
+ return je.filter((e) => e.isPointerBlocking);
4866
4866
  }
4867
4867
  function ru() {
4868
4868
  return [...as()].slice(-1)[0];
@@ -4875,32 +4875,32 @@ function ls(e) {
4875
4875
  return jt(e) < t;
4876
4876
  }
4877
4877
  function ou(e) {
4878
- qe.push(e);
4878
+ je.push(e);
4879
4879
  }
4880
4880
  function iu(e) {
4881
4881
  const t = jt(e);
4882
- t < 0 || qe.splice(t, 1);
4882
+ t < 0 || je.splice(t, 1);
4883
4883
  }
4884
4884
  function su() {
4885
4885
  for (const {
4886
4886
  node: e
4887
- } of qe)
4887
+ } of je)
4888
4888
  e.style.pointerEvents = ls(e) ? "none" : "auto";
4889
4889
  }
4890
4890
  function au(e) {
4891
4891
  if (Wr() && !xr) {
4892
- const t = je(e);
4892
+ const t = Ue(e);
4893
4893
  ss = document.body.style.pointerEvents, t.body.style.pointerEvents = "none", xr = !0;
4894
4894
  }
4895
4895
  }
4896
4896
  function lu(e) {
4897
4897
  if (Wr())
4898
4898
  return;
4899
- const t = je(e);
4899
+ const t = Ue(e);
4900
4900
  t.body.style.pointerEvents = ss, t.body.style.length === 0 && t.body.removeAttribute("style"), xr = !1;
4901
4901
  }
4902
4902
  const he = {
4903
- layers: qe,
4903
+ layers: je,
4904
4904
  isTopMostLayer: nu,
4905
4905
  hasPointerBlockingLayer: Wr,
4906
4906
  isBelowPointerBlockingLayer: ls,
@@ -4952,7 +4952,7 @@ function cu(e, t) {
4952
4952
  }
4953
4953
  };
4954
4954
  let i = null;
4955
- const s = (h) => e.onMountAutoFocus?.(h), a = (h) => e.onUnmountAutoFocus?.(h), l = () => je(t()), c = () => {
4955
+ const s = (h) => e.onMountAutoFocus?.(h), a = (h) => e.onUnmountAutoFocus?.(h), l = () => Ue(t()), c = () => {
4956
4956
  const h = l().createElement("span");
4957
4957
  return h.setAttribute("data-focus-trap", ""), h.tabIndex = 0, Object.assign(h.style, Xc), h;
4958
4958
  }, d = () => {
@@ -4969,7 +4969,7 @@ function cu(e, t) {
4969
4969
  if (!h)
4970
4970
  return !1;
4971
4971
  const p = Ft(h);
4972
- return !p || Le(h, p) ? !1 : os(p);
4972
+ return !p || Te(h, p) ? !1 : os(p);
4973
4973
  };
4974
4974
  L(() => {
4975
4975
  const h = t();
@@ -4977,7 +4977,7 @@ function cu(e, t) {
4977
4977
  return;
4978
4978
  Io.add(o);
4979
4979
  const p = Ft(h);
4980
- if (!Le(h, p)) {
4980
+ if (!Te(h, p)) {
4981
4981
  const b = new CustomEvent(Xn, Do);
4982
4982
  h.addEventListener(Xn, s), h.dispatchEvent(b), b.defaultPrevented || setTimeout(() => {
4983
4983
  ue(u()), Ft(h) === p && ue(h);
@@ -4995,10 +4995,10 @@ function cu(e, t) {
4995
4995
  return;
4996
4996
  const p = (b) => {
4997
4997
  const w = b.target;
4998
- w?.closest(`[${Cn}]`) || (Le(h, w) ? i = w : ue(i));
4998
+ w?.closest(`[${Cn}]`) || (Te(h, w) ? i = w : ue(i));
4999
4999
  }, m = (b) => {
5000
5000
  const v = b.relatedTarget ?? Ft(h);
5001
- v?.closest(`[${Cn}]`) || Le(h, v) || ue(i);
5001
+ v?.closest(`[${Cn}]`) || Te(h, v) || ue(i);
5002
5002
  };
5003
5003
  l().addEventListener("focusin", p), l().addEventListener("focusout", m), K(() => {
5004
5004
  l().removeEventListener("focusin", p), l().removeEventListener("focusout", m);
@@ -5118,9 +5118,9 @@ function fu(e, t = document.body) {
5118
5118
  const Ro = "interactOutside.pointerDownOutside", Fo = "interactOutside.focusOutside";
5119
5119
  function hu(e, t) {
5120
5120
  let n, r = Wc;
5121
- const o = () => je(t()), i = (u) => e.onPointerDownOutside?.(u), s = (u) => e.onFocusOutside?.(u), a = (u) => e.onInteractOutside?.(u), l = (u) => {
5121
+ const o = () => Ue(t()), i = (u) => e.onPointerDownOutside?.(u), s = (u) => e.onFocusOutside?.(u), a = (u) => e.onInteractOutside?.(u), l = (u) => {
5122
5122
  const f = u.target;
5123
- return !(f instanceof HTMLElement) || f.closest(`[${Cn}]`) || !Le(o(), f) || Le(t(), f) ? !1 : !e.shouldExcludeElement?.(f);
5123
+ return !(f instanceof HTMLElement) || f.closest(`[${Cn}]`) || !Te(o(), f) || Te(t(), f) ? !1 : !e.shouldExcludeElement?.(f);
5124
5124
  }, c = (u) => {
5125
5125
  function f() {
5126
5126
  const g = t(), h = u.target;
@@ -5462,7 +5462,7 @@ function Ou(e, t) {
5462
5462
  * https://github.com/adobe/react-spectrum/blob/bfce84fee12a027d9cbc38b43e1747e3e4b4b169/packages/@react-stately/selection/src/useMultipleSelectionState.ts
5463
5463
  */
5464
5464
  function _u(e) {
5465
- const t = $e({
5465
+ const t = Fe({
5466
5466
  selectionMode: "none",
5467
5467
  selectionBehavior: "toggle"
5468
5468
  }, e), [n, r] = O(!1), [o, i] = O(), s = C(() => {
@@ -6191,7 +6191,7 @@ function Nu(e) {
6191
6191
  }
6192
6192
  function Ku(e) {
6193
6193
  let t;
6194
- const n = $e({
6194
+ const n = Fe({
6195
6195
  type: "button"
6196
6196
  }, e), [r, o] = j(n, ["ref", "type", "disabled"]), i = mu(() => t, () => "button"), s = C(() => {
6197
6197
  const c = i();
@@ -6280,7 +6280,7 @@ function Uu(e) {
6280
6280
  return r;
6281
6281
  r = r.parentElement;
6282
6282
  }
6283
- return je(r).body;
6283
+ return Ue(r).body;
6284
6284
  }
6285
6285
  function ju(e, t) {
6286
6286
  L(() => {
@@ -6340,7 +6340,7 @@ function Hu(e = {}) {
6340
6340
  }) };
6341
6341
  }
6342
6342
  function Wu(e) {
6343
- const t = zu(), n = $e({ shouldRegisterItem: !0 }, e);
6343
+ const t = zu(), n = Fe({ shouldRegisterItem: !0 }, e);
6344
6344
  L(() => {
6345
6345
  if (!n.shouldRegisterItem)
6346
6346
  return;
@@ -6413,7 +6413,7 @@ var J = (e) => typeof e == "function" ? e() : e, Qn = (e) => requestAnimationFra
6413
6413
  preventScrollbarShiftMode: "padding",
6414
6414
  restoreScrollPosition: !0,
6415
6415
  allowPinchZoom: !1
6416
- }, e), n = Me();
6416
+ }, e), n = Le();
6417
6417
  let r = [0, 0], o = null, i = null;
6418
6418
  L(() => {
6419
6419
  J(t.enabled) && (qo((c) => [...c, n]), K(() => {
@@ -6504,7 +6504,7 @@ function rd(e) {
6504
6504
  };
6505
6505
  };
6506
6506
  hu({
6507
- shouldExcludeElement: (u) => t ? r.excludedElements?.some((f) => Le(f(), u)) || [...i].some((f) => Le(f, u)) : !1,
6507
+ shouldExcludeElement: (u) => t ? r.excludedElements?.some((f) => Te(f(), u)) || [...i].some((f) => Te(f, u)) : !1,
6508
6508
  onPointerDownOutside: (u) => {
6509
6509
  !t || he.isBelowPointerBlockingLayer(t) || !r.bypassTopMostLayerCheck && !he.isTopMostLayer(t) || (r.onPointerDownOutside?.(u), r.onInteractOutside?.(u), u.defaultPrevented || r.onDismiss?.());
6510
6510
  },
@@ -6512,7 +6512,7 @@ function rd(e) {
6512
6512
  r.onFocusOutside?.(u), r.onInteractOutside?.(u), u.defaultPrevented || r.onDismiss?.();
6513
6513
  }
6514
6514
  }, () => t), eu({
6515
- ownerDocument: () => je(t),
6515
+ ownerDocument: () => Ue(t),
6516
6516
  onEscapeKeyDown: (u) => {
6517
6517
  !t || !he.isTopMostLayer(t) || (r.onEscapeKeyDown?.(u), !u.defaultPrevented && r.onDismiss && (u.preventDefault(), r.onDismiss()));
6518
6518
  }
@@ -6581,7 +6581,7 @@ function id(e) {
6581
6581
  }
6582
6582
  }, r));
6583
6583
  }
6584
- const sd = ["top", "right", "bottom", "left"], Xe = Math.min, ge = Math.max, _n = Math.round, nn = Math.floor, De = (e) => ({
6584
+ const sd = ["top", "right", "bottom", "left"], Xe = Math.min, ge = Math.max, _n = Math.round, nn = Math.floor, Me = (e) => ({
6585
6585
  x: e,
6586
6586
  y: e
6587
6587
  }), ad = {
@@ -7166,7 +7166,7 @@ function me(e) {
7166
7166
  var t;
7167
7167
  return (e == null || (t = e.ownerDocument) == null ? void 0 : t.defaultView) || window;
7168
7168
  }
7169
- function Ne(e) {
7169
+ function $e(e) {
7170
7170
  var t;
7171
7171
  return (t = (vs(e) ? e.ownerDocument : e.document) || window.document) == null ? void 0 : t.documentElement;
7172
7172
  }
@@ -7176,7 +7176,7 @@ function vs(e) {
7176
7176
  function Pe(e) {
7177
7177
  return Fn() ? e instanceof Element || e instanceof me(e).Element : !1;
7178
7178
  }
7179
- function Re(e) {
7179
+ function Ie(e) {
7180
7180
  return Fn() ? e instanceof HTMLElement || e instanceof me(e).HTMLElement : !1;
7181
7181
  }
7182
7182
  function Jo(e) {
@@ -7209,7 +7209,7 @@ function Jr(e) {
7209
7209
  }
7210
7210
  function kd(e) {
7211
7211
  let t = Ze(e);
7212
- for (; Re(t) && !wt(t); ) {
7212
+ for (; Ie(t) && !wt(t); ) {
7213
7213
  if (Jr(t))
7214
7214
  return t;
7215
7215
  if ($n(t))
@@ -7244,13 +7244,13 @@ function Ze(e) {
7244
7244
  e.assignedSlot || // DOM Element detected.
7245
7245
  e.parentNode || // ShadowRoot detected.
7246
7246
  Jo(e) && e.host || // Fallback.
7247
- Ne(e)
7247
+ $e(e)
7248
7248
  );
7249
7249
  return Jo(t) ? t.host : t;
7250
7250
  }
7251
7251
  function xs(e) {
7252
7252
  const t = Ze(e);
7253
- return wt(t) ? e.ownerDocument ? e.ownerDocument.body : e.body : Re(t) && Wt(t) ? t : xs(t);
7253
+ return wt(t) ? e.ownerDocument ? e.ownerDocument.body : e.body : Ie(t) && Wt(t) ? t : xs(t);
7254
7254
  }
7255
7255
  function Ht(e, t, n) {
7256
7256
  var r;
@@ -7268,7 +7268,7 @@ function Or(e) {
7268
7268
  function Ss(e) {
7269
7269
  const t = Ae(e);
7270
7270
  let n = parseFloat(t.width) || 0, r = parseFloat(t.height) || 0;
7271
- const o = Re(e), i = o ? e.offsetWidth : n, s = o ? e.offsetHeight : r, a = _n(n) !== i || _n(r) !== s;
7271
+ const o = Ie(e), i = o ? e.offsetWidth : n, s = o ? e.offsetHeight : r, a = _n(n) !== i || _n(r) !== s;
7272
7272
  return a && (n = i, r = s), {
7273
7273
  width: n,
7274
7274
  height: r,
@@ -7280,8 +7280,8 @@ function Qr(e) {
7280
7280
  }
7281
7281
  function yt(e) {
7282
7282
  const t = Qr(e);
7283
- if (!Re(t))
7284
- return De(1);
7283
+ if (!Ie(t))
7284
+ return Me(1);
7285
7285
  const n = t.getBoundingClientRect(), {
7286
7286
  width: r,
7287
7287
  height: o,
@@ -7293,7 +7293,7 @@ function yt(e) {
7293
7293
  y: a
7294
7294
  };
7295
7295
  }
7296
- const Ed = /* @__PURE__ */ De(0);
7296
+ const Ed = /* @__PURE__ */ Me(0);
7297
7297
  function ks(e) {
7298
7298
  const t = me(e);
7299
7299
  return !Zr() || !t.visualViewport ? Ed : {
@@ -7307,9 +7307,9 @@ function Cd(e, t, n) {
7307
7307
  function it(e, t, n, r) {
7308
7308
  t === void 0 && (t = !1), n === void 0 && (n = !1);
7309
7309
  const o = e.getBoundingClientRect(), i = Qr(e);
7310
- let s = De(1);
7310
+ let s = Me(1);
7311
7311
  t && (r ? Pe(r) && (s = yt(r)) : s = yt(e));
7312
- const a = Cd(i, n, r) ? ks(i) : De(0);
7312
+ const a = Cd(i, n, r) ? ks(i) : Me(0);
7313
7313
  let l = (o.left + a.x) / s.x, c = (o.top + a.y) / s.y, d = o.width / s.x, u = o.height / s.y;
7314
7314
  if (i) {
7315
7315
  const f = me(i), g = r && Pe(r) ? me(r) : r;
@@ -7328,7 +7328,7 @@ function it(e, t, n, r) {
7328
7328
  }
7329
7329
  function eo(e, t) {
7330
7330
  const n = Nn(e).scrollLeft;
7331
- return t ? t.left + n : it(Ne(e)).left + n;
7331
+ return t ? t.left + n : it($e(e)).left + n;
7332
7332
  }
7333
7333
  function Es(e, t, n) {
7334
7334
  n === void 0 && (n = !1);
@@ -7348,19 +7348,19 @@ function Od(e) {
7348
7348
  offsetParent: r,
7349
7349
  strategy: o
7350
7350
  } = e;
7351
- const i = o === "fixed", s = Ne(r), a = t ? $n(t.floating) : !1;
7351
+ const i = o === "fixed", s = $e(r), a = t ? $n(t.floating) : !1;
7352
7352
  if (r === s || a && i)
7353
7353
  return n;
7354
7354
  let l = {
7355
7355
  scrollLeft: 0,
7356
7356
  scrollTop: 0
7357
- }, c = De(1);
7358
- const d = De(0), u = Re(r);
7359
- if ((u || !u && !i) && ((Et(r) !== "body" || Wt(s)) && (l = Nn(r)), Re(r))) {
7357
+ }, c = Me(1);
7358
+ const d = Me(0), u = Ie(r);
7359
+ if ((u || !u && !i) && ((Et(r) !== "body" || Wt(s)) && (l = Nn(r)), Ie(r))) {
7360
7360
  const g = it(r);
7361
7361
  c = yt(r), d.x = g.x + r.clientLeft, d.y = g.y + r.clientTop;
7362
7362
  }
7363
- const f = s && !u && !i ? Es(s, l, !0) : De(0);
7363
+ const f = s && !u && !i ? Es(s, l, !0) : Me(0);
7364
7364
  return {
7365
7365
  width: n.width * c.x,
7366
7366
  height: n.height * c.y,
@@ -7372,7 +7372,7 @@ function _d(e) {
7372
7372
  return Array.from(e.getClientRects());
7373
7373
  }
7374
7374
  function Pd(e) {
7375
- const t = Ne(e), n = Nn(e), r = e.ownerDocument.body, o = ge(t.scrollWidth, t.clientWidth, r.scrollWidth, r.clientWidth), i = ge(t.scrollHeight, t.clientHeight, r.scrollHeight, r.clientHeight);
7375
+ const t = $e(e), n = Nn(e), r = e.ownerDocument.body, o = ge(t.scrollWidth, t.clientWidth, r.scrollWidth, r.clientWidth), i = ge(t.scrollHeight, t.clientHeight, r.scrollHeight, r.clientHeight);
7376
7376
  let s = -n.scrollLeft + eo(e);
7377
7377
  const a = -n.scrollTop;
7378
7378
  return Ae(r).direction === "rtl" && (s += ge(t.clientWidth, r.clientWidth) - o), {
@@ -7383,7 +7383,7 @@ function Pd(e) {
7383
7383
  };
7384
7384
  }
7385
7385
  function Ad(e, t) {
7386
- const n = me(e), r = Ne(e), o = n.visualViewport;
7386
+ const n = me(e), r = $e(e), o = n.visualViewport;
7387
7387
  let i = r.clientWidth, s = r.clientHeight, a = 0, l = 0;
7388
7388
  if (o) {
7389
7389
  i = o.width, s = o.height;
@@ -7398,7 +7398,7 @@ function Ad(e, t) {
7398
7398
  };
7399
7399
  }
7400
7400
  function Td(e, t) {
7401
- const n = it(e, !0, t === "fixed"), r = n.top + e.clientTop, o = n.left + e.clientLeft, i = Re(e) ? yt(e) : De(1), s = e.clientWidth * i.x, a = e.clientHeight * i.y, l = o * i.x, c = r * i.y;
7401
+ const n = it(e, !0, t === "fixed"), r = n.top + e.clientTop, o = n.left + e.clientLeft, i = Ie(e) ? yt(e) : Me(1), s = e.clientWidth * i.x, a = e.clientHeight * i.y, l = o * i.x, c = r * i.y;
7402
7402
  return {
7403
7403
  width: s,
7404
7404
  height: a,
@@ -7411,7 +7411,7 @@ function Zo(e, t, n) {
7411
7411
  if (t === "viewport")
7412
7412
  r = Ad(e, n);
7413
7413
  else if (t === "document")
7414
- r = Pd(Ne(e));
7414
+ r = Pd($e(e));
7415
7415
  else if (Pe(t))
7416
7416
  r = Td(t, n);
7417
7417
  else {
@@ -7471,18 +7471,18 @@ function Dd(e) {
7471
7471
  };
7472
7472
  }
7473
7473
  function Id(e, t, n) {
7474
- const r = Re(t), o = Ne(t), i = n === "fixed", s = it(e, !0, i, t);
7474
+ const r = Ie(t), o = $e(t), i = n === "fixed", s = it(e, !0, i, t);
7475
7475
  let a = {
7476
7476
  scrollLeft: 0,
7477
7477
  scrollTop: 0
7478
7478
  };
7479
- const l = De(0);
7479
+ const l = Me(0);
7480
7480
  if (r || !r && !i)
7481
7481
  if ((Et(t) !== "body" || Wt(o)) && (a = Nn(t)), r) {
7482
7482
  const f = it(t, !0, i, t);
7483
7483
  l.x = f.x + t.clientLeft, l.y = f.y + t.clientTop;
7484
7484
  } else o && (l.x = eo(o));
7485
- const c = o && !r && !i ? Es(o, a) : De(0), d = s.left + a.scrollLeft - l.x - c.x, u = s.top + a.scrollTop - l.y - c.y;
7485
+ const c = o && !r && !i ? Es(o, a) : Me(0), d = s.left + a.scrollLeft - l.x - c.x, u = s.top + a.scrollTop - l.y - c.y;
7486
7486
  return {
7487
7487
  x: d,
7488
7488
  y: u,
@@ -7494,18 +7494,18 @@ function er(e) {
7494
7494
  return Ae(e).position === "static";
7495
7495
  }
7496
7496
  function Qo(e, t) {
7497
- if (!Re(e) || Ae(e).position === "fixed")
7497
+ if (!Ie(e) || Ae(e).position === "fixed")
7498
7498
  return null;
7499
7499
  if (t)
7500
7500
  return t(e);
7501
7501
  let n = e.offsetParent;
7502
- return Ne(e) === n && (n = n.ownerDocument.body), n;
7502
+ return $e(e) === n && (n = n.ownerDocument.body), n;
7503
7503
  }
7504
7504
  function Os(e, t) {
7505
7505
  const n = me(e);
7506
7506
  if ($n(e))
7507
7507
  return n;
7508
- if (!Re(e)) {
7508
+ if (!Ie(e)) {
7509
7509
  let o = Ze(e);
7510
7510
  for (; o && !wt(o); ) {
7511
7511
  if (Pe(o) && !er(o))
@@ -7536,7 +7536,7 @@ function Fd(e) {
7536
7536
  }
7537
7537
  const _s = {
7538
7538
  convertOffsetParentRelativeRectToViewportRelativeRect: Od,
7539
- getDocumentElement: Ne,
7539
+ getDocumentElement: $e,
7540
7540
  getClippingRect: Md,
7541
7541
  getOffsetParent: Os,
7542
7542
  getElementRects: Rd,
@@ -7551,7 +7551,7 @@ function Ps(e, t) {
7551
7551
  }
7552
7552
  function $d(e, t) {
7553
7553
  let n = null, r;
7554
- const o = Ne(e);
7554
+ const o = $e(e);
7555
7555
  function i() {
7556
7556
  var a;
7557
7557
  clearTimeout(r), (a = n) == null || a.disconnect(), n = null;
@@ -7683,7 +7683,7 @@ function Yd(e, t) {
7683
7683
  return r ? n === "left" || n === "right" ? `${o} ${r === "start" ? "top" : "bottom"}` : r === "start" ? `${o} ${t === "rtl" ? "right" : "left"}` : `${o} ${t === "rtl" ? "left" : "right"}` : `${o} center`;
7684
7684
  }
7685
7685
  function Xd(e) {
7686
- const t = $e({
7686
+ const t = Fe({
7687
7687
  getAnchorRect: (f) => f?.getBoundingClientRect(),
7688
7688
  placement: "bottom",
7689
7689
  gutter: 0,
@@ -7835,7 +7835,7 @@ function Jd(e, t) {
7835
7835
  return t ? Gc([e.clientX, e.clientY], t) : !1;
7836
7836
  }
7837
7837
  function Zd(e) {
7838
- const t = Ot(), n = fs(), r = Ts(), o = $e({
7838
+ const t = Ot(), n = fs(), r = Ts(), o = Fe({
7839
7839
  placement: "bottom-start"
7840
7840
  }, e), [i, s] = j(o, ["open", "defaultOpen", "onOpenChange"]);
7841
7841
  let a = 0, l = null, c = "right";
@@ -7937,8 +7937,8 @@ function Zd(e) {
7937
7937
  const Qd = fe();
7938
7938
  function ef(e) {
7939
7939
  let t;
7940
- const n = Ot(), r = Ct(), o = $e({
7941
- id: n.generateId(`item-${Me()}`)
7940
+ const n = Ot(), r = Ct(), o = Fe({
7941
+ id: n.generateId(`item-${Le()}`)
7942
7942
  }, e), [i, s] = j(o, ["ref", "textValue", "disabled", "closeOnSelect", "checked", "indeterminate", "onSelect", "onPointerMove", "onPointerLeave", "onPointerDown", "onPointerUp", "onClick", "onKeyDown", "onMouseDown", "onFocus"]), [a, l] = O(), [c, d] = O(), [u, f] = O(), g = () => r.listState().selectionManager(), h = () => s.id, p = () => g().focusedKey() === h(), m = () => {
7943
7943
  i.onSelect?.(), i.closeOnSelect && r.close(!0);
7944
7944
  };
@@ -8046,8 +8046,8 @@ function Ms() {
8046
8046
  }
8047
8047
  function nf(e) {
8048
8048
  let t;
8049
- const n = Ot(), r = Ct(), o = Ms(), i = $e({
8050
- id: n.generateId(`content-${Me()}`)
8049
+ const n = Ot(), r = Ct(), o = Ms(), i = Fe({
8050
+ id: n.generateId(`content-${Le()}`)
8051
8051
  }, e), [s, a] = j(i, ["ref", "id", "style", "onOpenAutoFocus", "onCloseAutoFocus", "onEscapeKeyDown", "onFocusOutside", "onPointerEnter", "onPointerMove", "onKeyDown", "onMouseDown", "onFocusIn", "onFocusOut"]);
8052
8052
  let l = 0;
8053
8053
  const c = () => r.parentMenuContext() == null && o === void 0 && n.isModal(), d = Fu({
@@ -8066,7 +8066,7 @@ function nf(e) {
8066
8066
  onUnmountAutoFocus: s.onCloseAutoFocus
8067
8067
  }, () => t);
8068
8068
  const u = (m) => {
8069
- if (Le(m.currentTarget, m.target) && (m.key === "Tab" && r.isOpen() && m.preventDefault(), o !== void 0 && m.currentTarget.getAttribute("aria-haspopup") !== "true"))
8069
+ if (Te(m.currentTarget, m.target) && (m.key === "Tab" && r.isOpen() && m.preventDefault(), o !== void 0 && m.currentTarget.getAttribute("aria-haspopup") !== "true"))
8070
8070
  switch (m.key) {
8071
8071
  case "ArrowRight":
8072
8072
  m.stopPropagation(), m.preventDefault(), r.close(!0), o.setAutoFocusMenu(!0), o.nextMenu();
@@ -8086,7 +8086,7 @@ function nf(e) {
8086
8086
  if (pe(m, s.onPointerMove), m.pointerType !== "mouse")
8087
8087
  return;
8088
8088
  const b = m.target, w = l !== m.clientX;
8089
- Le(m.currentTarget, b) && w && (r.setPointerDir(m.clientX > l ? "right" : "left"), l = m.clientX);
8089
+ Te(m.currentTarget, b) && w && (r.setPointerDir(m.clientX > l ? "right" : "left"), l = m.clientX);
8090
8090
  };
8091
8091
  return L(() => K(r.registerContentId(s.id))), y(Z, {
8092
8092
  get when() {
@@ -8184,7 +8184,7 @@ function sf(e) {
8184
8184
  });
8185
8185
  }
8186
8186
  function af(e) {
8187
- const t = `menu-${Me()}`, n = $e({
8187
+ const t = `menu-${Le()}`, n = Fe({
8188
8188
  id: t,
8189
8189
  modal: !0
8190
8190
  }, e), [r, o] = j(n, ["id", "modal", "preventScroll", "forceMount", "open", "defaultOpen", "onOpenChange", "value"]), i = is({
@@ -8213,7 +8213,7 @@ function af(e) {
8213
8213
  });
8214
8214
  }
8215
8215
  function lf(e) {
8216
- const t = Ot(), n = Ct(), r = Ms(), o = $e({
8216
+ const t = Ot(), n = Ct(), r = Ms(), o = Fe({
8217
8217
  id: t.generateId("trigger")
8218
8218
  }, e), [i, s] = j(o, ["ref", "id", "disabled", "onPointerDown", "onClick", "onKeyDown", "onMouseOver", "onFocus"]);
8219
8219
  let a;
@@ -8302,7 +8302,7 @@ function cf(e) {
8302
8302
  }, o));
8303
8303
  }
8304
8304
  function uf(e) {
8305
- const t = `dropdownmenu-${Me()}`, n = $e({
8305
+ const t = `dropdownmenu-${Le()}`, n = Fe({
8306
8306
  id: t
8307
8307
  }, e);
8308
8308
  return y(af, n);
@@ -8404,19 +8404,19 @@ async function xf(e, t, n) {
8404
8404
  };
8405
8405
  await fetch(r, o);
8406
8406
  }
8407
- const Fe = /* @__PURE__ */ Object.create(null);
8408
- Fe.open = "0";
8409
- Fe.close = "1";
8410
- Fe.ping = "2";
8411
- Fe.pong = "3";
8412
- Fe.message = "4";
8413
- Fe.upgrade = "5";
8414
- Fe.noop = "6";
8407
+ const Re = /* @__PURE__ */ Object.create(null);
8408
+ Re.open = "0";
8409
+ Re.close = "1";
8410
+ Re.ping = "2";
8411
+ Re.pong = "3";
8412
+ Re.message = "4";
8413
+ Re.upgrade = "5";
8414
+ Re.noop = "6";
8415
8415
  const dn = /* @__PURE__ */ Object.create(null);
8416
- Object.keys(Fe).forEach((e) => {
8417
- dn[Fe[e]] = e;
8416
+ Object.keys(Re).forEach((e) => {
8417
+ dn[Re[e]] = e;
8418
8418
  });
8419
- const _r = { type: "error", data: "parser error" }, Ds = typeof Blob == "function" || typeof Blob < "u" && Object.prototype.toString.call(Blob) === "[object BlobConstructor]", Is = typeof ArrayBuffer == "function", Rs = (e) => typeof ArrayBuffer.isView == "function" ? ArrayBuffer.isView(e) : e && e.buffer instanceof ArrayBuffer, to = ({ type: e, data: t }, n, r) => Ds && t instanceof Blob ? n ? r(t) : ti(t, r) : Is && (t instanceof ArrayBuffer || Rs(t)) ? n ? r(t) : ti(new Blob([t]), r) : r(Fe[e] + (t || "")), ti = (e, t) => {
8419
+ const _r = { type: "error", data: "parser error" }, Ds = typeof Blob == "function" || typeof Blob < "u" && Object.prototype.toString.call(Blob) === "[object BlobConstructor]", Is = typeof ArrayBuffer == "function", Rs = (e) => typeof ArrayBuffer.isView == "function" ? ArrayBuffer.isView(e) : e && e.buffer instanceof ArrayBuffer, to = ({ type: e, data: t }, n, r) => Ds && t instanceof Blob ? n ? r(t) : ti(t, r) : Is && (t instanceof ArrayBuffer || Rs(t)) ? n ? r(t) : ti(new Blob([t]), r) : r(Re[e] + (t || "")), ti = (e, t) => {
8420
8420
  const n = new FileReader();
8421
8421
  return n.onload = function() {
8422
8422
  const r = n.result.split(",")[1];
@@ -8898,7 +8898,7 @@ class Uf extends zf {
8898
8898
  }), this.pollXhr = t;
8899
8899
  }
8900
8900
  }
8901
- class Ie extends te {
8901
+ class De extends te {
8902
8902
  /**
8903
8903
  * Request constructor
8904
8904
  *
@@ -8952,7 +8952,7 @@ class Ie extends te {
8952
8952
  }, 0);
8953
8953
  return;
8954
8954
  }
8955
- typeof document < "u" && (this._index = Ie.requestsCount++, Ie.requests[this._index] = this);
8955
+ typeof document < "u" && (this._index = De.requestsCount++, De.requests[this._index] = this);
8956
8956
  }
8957
8957
  /**
8958
8958
  * Called upon error.
@@ -8974,7 +8974,7 @@ class Ie extends te {
8974
8974
  this._xhr.abort();
8975
8975
  } catch {
8976
8976
  }
8977
- typeof document < "u" && delete Ie.requests[this._index], this._xhr = null;
8977
+ typeof document < "u" && delete De.requests[this._index], this._xhr = null;
8978
8978
  }
8979
8979
  }
8980
8980
  /**
@@ -8995,8 +8995,8 @@ class Ie extends te {
8995
8995
  this._cleanup();
8996
8996
  }
8997
8997
  }
8998
- Ie.requestsCount = 0;
8999
- Ie.requests = {};
8998
+ De.requestsCount = 0;
8999
+ De.requests = {};
9000
9000
  if (typeof document < "u") {
9001
9001
  if (typeof attachEvent == "function")
9002
9002
  attachEvent("onunload", oi);
@@ -9006,8 +9006,8 @@ if (typeof document < "u") {
9006
9006
  }
9007
9007
  }
9008
9008
  function oi() {
9009
- for (let e in Ie.requests)
9010
- Ie.requests.hasOwnProperty(e) && Ie.requests[e].abort();
9009
+ for (let e in De.requests)
9010
+ De.requests.hasOwnProperty(e) && De.requests[e].abort();
9011
9011
  }
9012
9012
  const jf = function() {
9013
9013
  const e = Vs({
@@ -9022,7 +9022,7 @@ class qf extends Uf {
9022
9022
  this.supportsBinary = jf && !n;
9023
9023
  }
9024
9024
  request(t = {}) {
9025
- return Object.assign(t, { xd: this.xd }, this.opts), new Ie(Vs, this.uri(), t);
9025
+ return Object.assign(t, { xd: this.xd }, this.opts), new De(Vs, this.uri(), t);
9026
9026
  }
9027
9027
  }
9028
9028
  function Vs(e) {
@@ -10695,14 +10695,14 @@ Object.assign(gn, {
10695
10695
  io: gn,
10696
10696
  connect: gn
10697
10697
  });
10698
- class Te {
10698
+ class Ge {
10699
10699
  static instance;
10700
10700
  constructor() {
10701
10701
  }
10702
10702
  static init(t) {
10703
- if (!Te.instance) {
10703
+ if (!Ge.instance) {
10704
10704
  const n = Vr();
10705
- Te.instance = gn(qa, {
10705
+ Ge.instance = gn(qa, {
10706
10706
  path: "/ws",
10707
10707
  withCredentials: !0,
10708
10708
  extraHeaders: {
@@ -10715,16 +10715,15 @@ class Te {
10715
10715
  query: {
10716
10716
  sessionId: n || ""
10717
10717
  }
10718
- }), Te.instance.on("connect", () => {
10719
- console.info("SmartTalks.ai widget connected!", Te.instance.id);
10720
- }), Te.instance.on("connect_error", (r) => {
10721
- console.error("Socket Connection Error:", r.message);
10718
+ }), Ge.instance.on("connect", () => {
10719
+ console.info("SmartTalks.ai widget connected!", Ge.instance.id);
10722
10720
  });
10723
10721
  }
10724
- return Te.instance;
10722
+ return Ge.instance;
10725
10723
  }
10726
10724
  static on(t, n, r) {
10727
- Te.instance ? Te.instance.on(t, r) : this.init(n).on(t, r);
10725
+ const o = Ge.instance || this.init(n);
10726
+ o.off(t), o.on(t, r);
10728
10727
  }
10729
10728
  }
10730
10729
  const Hs = 1e3 * 60 * 60 * 24, [Tn, Ws] = Yi(
@@ -10775,7 +10774,7 @@ const Hs = 1e3 * 60 * 60 * 24, [Tn, Ws] = Yi(
10775
10774
  type: "text",
10776
10775
  origin: "user",
10777
10776
  createdAt: (/* @__PURE__ */ new Date()).toString()
10778
- }), ee("onInput", e), Te.on("message", r(), (i) => {
10777
+ }), ee("onInput", e), Ge.on("message", r(), (i) => {
10779
10778
  (i.contactId !== o.contactId || i.interactionId !== o.interactionId) && Js({
10780
10779
  contactId: i.contactId,
10781
10780
  interactionId: i.interactionId
@@ -11233,7 +11232,7 @@ var Ir = qh, pn = /* @__PURE__ */ new Map(), Bn = (e, t) => {
11233
11232
  }, tg = eg, Rr = fe(), ng = (e) => C(() => {
11234
11233
  if (ye(Rr))
11235
11234
  return y(ui, e);
11236
- const r = Me(), [o, i] = O([r]), s = (l) => {
11235
+ const r = Le(), [o, i] = O([r]), s = (l) => {
11237
11236
  i((c) => [...c, l]);
11238
11237
  }, a = (l) => {
11239
11238
  i((c) => c.filter((d) => d !== l));
@@ -11255,7 +11254,7 @@ var Ir = qh, pn = /* @__PURE__ */ new Map(), Bn = (e, t) => {
11255
11254
  dismissOnOutsidePointer: !0,
11256
11255
  dismissOnOutsidePointerStrategy: "pointerup",
11257
11256
  noOutsidePointerEvents: !0
11258
- }, e), [n, r] = j(t, ["enabled", "children", "dismissOnEscapeKeyDown", "dismissOnOutsidePointer", "dismissOnOutsidePointerStrategy", "dismissOnOutsidePointerIgnore", "noOutsidePointerEvents", "onDismiss"]), o = ye(Rr), i = Me();
11257
+ }, e), [n, r] = j(t, ["enabled", "children", "dismissOnEscapeKeyDown", "dismissOnOutsidePointer", "dismissOnOutsidePointerStrategy", "dismissOnOutsidePointerIgnore", "noOutsidePointerEvents", "onDismiss"]), o = ye(Rr), i = Le();
11259
11258
  L(() => {
11260
11259
  n.enabled ? o.onLayerShow(i) : o.onLayerDismiss(i);
11261
11260
  });
@@ -11646,15 +11645,15 @@ var Ir = qh, pn = /* @__PURE__ */ new Map(), Bn = (e, t) => {
11646
11645
  allowPinchZoom: !0,
11647
11646
  trapFocus: !0,
11648
11647
  restoreFocus: !0,
11649
- dialogId: Me()
11648
+ dialogId: Le()
11650
11649
  }, e), [n, r] = Ir({
11651
11650
  value: () => t.open,
11652
11651
  initialValue: t.initialOpen,
11653
11652
  onChange: t.onOpenChange
11654
11653
  }), [o, i, s] = ci({
11655
- value: () => t.labelId ?? Me()
11654
+ value: () => t.labelId ?? Le()
11656
11655
  }), [a, l, c] = ci({
11657
- value: () => t.descriptionId ?? Me()
11656
+ value: () => t.descriptionId ?? Le()
11658
11657
  }), [d, u] = O(null), [f, g] = O(null), [h, p] = O(null), {
11659
11658
  present: m
11660
11659
  } = hi({