@2uinc/frontend-component-xpert-chatbot 1.30.0 → 1.31.1-beta.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/dist/lib/index.min.js +842 -827
  2. package/package.json +1 -1
@@ -1,4 +1,4 @@
1
- import Ge, { createContext as In, useState as ee, useCallback as Ct, useEffect as ke, useContext as Q, useRef as ze, forwardRef as io, createElement as kr, useMemo as Es, Fragment as Ts } from "react";
1
+ import Ge, { createContext as Pn, useState as ee, useCallback as Ct, useEffect as ke, useContext as Q, useRef as ze, forwardRef as io, createElement as kr, useMemo as Es, Fragment as Ts } from "react";
2
2
  import Os from "react-dom";
3
3
  var cn = typeof globalThis < "u" ? globalThis : typeof window < "u" ? window : typeof global < "u" ? global : typeof self < "u" ? self : {};
4
4
  function nt(e) {
@@ -29,10 +29,10 @@ object-assign
29
29
  (c) Sindre Sorhus
30
30
  @license MIT
31
31
  */
32
- var Xn, Pi;
33
- function Is() {
34
- if (Pi) return Xn;
35
- Pi = 1;
32
+ var Xn, Ii;
33
+ function Ps() {
34
+ if (Ii) return Xn;
35
+ Ii = 1;
36
36
  var e = Object.getOwnPropertySymbols, t = Object.prototype.hasOwnProperty, n = Object.prototype.propertyIsEnumerable;
37
37
  function r(a) {
38
38
  if (a == null)
@@ -84,9 +84,9 @@ function Is() {
84
84
  * LICENSE file in the root directory of this source tree.
85
85
  */
86
86
  var Ai;
87
- function Ps() {
87
+ function Is() {
88
88
  if (Ai) return Nt;
89
- Ai = 1, Is();
89
+ Ai = 1, Ps();
90
90
  var e = Ge, t = 60103;
91
91
  if (Nt.Fragment = 60107, typeof Symbol == "function" && Symbol.for) {
92
92
  var n = Symbol.for;
@@ -104,7 +104,7 @@ function Ps() {
104
104
  }
105
105
  var Fi;
106
106
  function As() {
107
- return Fi || (Fi = 1, Gn.exports = Ps()), Gn.exports;
107
+ return Fi || (Fi = 1, Gn.exports = Is()), Gn.exports;
108
108
  }
109
109
  var k = As();
110
110
  /*! js-cookie v3.0.5 | MIT */
@@ -243,9 +243,9 @@ Zt.exports;
243
243
  var Mi;
244
244
  function Ms() {
245
245
  return Mi || (Mi = 1, function(e, t) {
246
- var n = 200, r = "__lodash_hash_undefined__", i = 800, a = 16, o = 9007199254740991, l = "[object Arguments]", s = "[object Array]", u = "[object AsyncFunction]", c = "[object Boolean]", d = "[object Date]", p = "[object Error]", f = "[object Function]", y = "[object GeneratorFunction]", h = "[object Map]", v = "[object Number]", g = "[object Null]", P = "[object Object]", A = "[object Proxy]", q = "[object RegExp]", I = "[object Set]", b = "[object String]", E = "[object Undefined]", z = "[object WeakMap]", F = "[object ArrayBuffer]", U = "[object DataView]", j = "[object Float32Array]", H = "[object Float64Array]", T = "[object Int8Array]", S = "[object Int16Array]", O = "[object Int32Array]", N = "[object Uint8Array]", M = "[object Uint8ClampedArray]", D = "[object Uint16Array]", B = "[object Uint32Array]", m = /[\\^$.*+?()[\]{}|]/g, W = /^\[object .+?Constructor\]$/, K = /^(?:0|[1-9]\d*)$/, w = {};
247
- w[j] = w[H] = w[T] = w[S] = w[O] = w[N] = w[M] = w[D] = w[B] = !0, w[l] = w[s] = w[F] = w[c] = w[U] = w[d] = w[p] = w[f] = w[h] = w[v] = w[P] = w[q] = w[I] = w[b] = w[z] = !1;
248
- var Y = typeof cn == "object" && cn && cn.Object === Object && cn, oe = typeof self == "object" && self && self.Object === Object && self, ne = Y || oe || Function("return this")(), de = t && !t.nodeType && t, pe = de && !0 && e && !e.nodeType && e, xe = pe && pe.exports === de, he = xe && Y.process, Te = function() {
246
+ var n = 200, r = "__lodash_hash_undefined__", i = 800, a = 16, o = 9007199254740991, l = "[object Arguments]", s = "[object Array]", u = "[object AsyncFunction]", c = "[object Boolean]", d = "[object Date]", p = "[object Error]", f = "[object Function]", y = "[object GeneratorFunction]", h = "[object Map]", v = "[object Number]", g = "[object Null]", I = "[object Object]", A = "[object Proxy]", q = "[object RegExp]", P = "[object Set]", b = "[object String]", E = "[object Undefined]", z = "[object WeakMap]", F = "[object ArrayBuffer]", U = "[object DataView]", M = "[object Float32Array]", B = "[object Float64Array]", T = "[object Int8Array]", S = "[object Int16Array]", O = "[object Int32Array]", N = "[object Uint8Array]", H = "[object Uint8ClampedArray]", j = "[object Uint16Array]", D = "[object Uint32Array]", m = /[\\^$.*+?()[\]{}|]/g, W = /^\[object .+?Constructor\]$/, Y = /^(?:0|[1-9]\d*)$/, w = {};
247
+ w[M] = w[B] = w[T] = w[S] = w[O] = w[N] = w[H] = w[j] = w[D] = !0, w[l] = w[s] = w[F] = w[c] = w[U] = w[d] = w[p] = w[f] = w[h] = w[v] = w[I] = w[q] = w[P] = w[b] = w[z] = !1;
248
+ var K = typeof cn == "object" && cn && cn.Object === Object && cn, oe = typeof self == "object" && self && self.Object === Object && self, ne = K || oe || Function("return this")(), de = t && !t.nodeType && t, pe = de && !0 && e && !e.nodeType && e, xe = pe && pe.exports === de, he = xe && K.process, Te = function() {
249
249
  try {
250
250
  var x = pe && pe.require && pe.require("util").types;
251
251
  return x || he && he.binding && he.binding("util");
@@ -283,10 +283,10 @@ function Ms() {
283
283
  return x(_(L));
284
284
  };
285
285
  }
286
- var mt = Array.prototype, It = Function.prototype, Ze = Object.prototype, X = ne["__core-js_shared__"], re = It.toString, ce = Ze.hasOwnProperty, Ee = function() {
286
+ var mt = Array.prototype, Pt = Function.prototype, Ze = Object.prototype, X = ne["__core-js_shared__"], re = Pt.toString, ce = Ze.hasOwnProperty, Ee = function() {
287
287
  var x = /[^.]+$/.exec(X && X.keys && X.keys.IE_PROTO || "");
288
288
  return x ? "Symbol(src)_1." + x : "";
289
- }(), Ne = Ze.toString, ut = re.call(Object), R = RegExp(
289
+ }(), Ne = Ze.toString, ct = re.call(Object), R = RegExp(
290
290
  "^" + re.call(ce).replace(m, "\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g, "$1.*?") + "$"
291
291
  ), V = xe ? ne.Buffer : void 0, Z = ne.Symbol, ae = ne.Uint8Array;
292
292
  V && V.allocUnsafe;
@@ -296,7 +296,7 @@ function Ms() {
296
296
  return x({}, "", {}), x;
297
297
  } catch {
298
298
  }
299
- }(), Ce = V ? V.isBuffer : void 0, Pt = Math.max, Ve = Date.now, vi = Bn(ne, "Map"), Ht = Bn(Object, "create"), El = /* @__PURE__ */ function() {
299
+ }(), Ce = V ? V.isBuffer : void 0, It = Math.max, Ve = Date.now, vi = Bn(ne, "Map"), Ht = Bn(Object, "create"), El = /* @__PURE__ */ function() {
300
300
  function x() {
301
301
  }
302
302
  return function(_) {
@@ -323,7 +323,7 @@ function Ms() {
323
323
  var _ = this.has(x) && delete this.__data__[x];
324
324
  return this.size -= _ ? 1 : 0, _;
325
325
  }
326
- function Il(x) {
326
+ function Pl(x) {
327
327
  var _ = this.__data__;
328
328
  if (Ht) {
329
329
  var L = _[x];
@@ -331,7 +331,7 @@ function Ms() {
331
331
  }
332
332
  return ce.call(_, x) ? _[x] : void 0;
333
333
  }
334
- function Pl(x) {
334
+ function Il(x) {
335
335
  var _ = this.__data__;
336
336
  return Ht ? _[x] !== void 0 : ce.call(_, x);
337
337
  }
@@ -339,7 +339,7 @@ function Ms() {
339
339
  var L = this.__data__;
340
340
  return this.size += this.has(x) ? 0 : 1, L[x] = Ht && _ === void 0 ? r : _, this;
341
341
  }
342
- gt.prototype.clear = Tl, gt.prototype.delete = Ol, gt.prototype.get = Il, gt.prototype.has = Pl, gt.prototype.set = Al;
342
+ gt.prototype.clear = Tl, gt.prototype.delete = Ol, gt.prototype.get = Pl, gt.prototype.has = Il, gt.prototype.set = Al;
343
343
  function it(x) {
344
344
  var _ = -1, L = x == null ? 0 : x.length;
345
345
  for (this.clear(); ++_ < L; ) {
@@ -499,8 +499,8 @@ function Ms() {
499
499
  }
500
500
  var je = me ? me(se, ve, L + "", x, _, be) : void 0, qt = je === void 0;
501
501
  if (qt) {
502
- var Vn = qn(ve), Wn = !Vn && Si(ve), Ii = !Vn && !Wn && Ei(ve);
503
- je = ve, Vn || Wn || Ii ? qn(se) ? je = se : xs(se) ? je = as(se) : Wn ? (qt = !1, je = ns(ve)) : Ii ? (qt = !1, je = is(ve)) : je = [] : ws(ve) || zn(ve) ? (je = se, zn(se) ? je = Cs(se) : (!yt(se) || $n(se)) && (je = cs(ve))) : qt = !1;
502
+ var Vn = qn(ve), Wn = !Vn && Si(ve), Pi = !Vn && !Wn && Ei(ve);
503
+ je = ve, Vn || Wn || Pi ? qn(se) ? je = se : xs(se) ? je = as(se) : Wn ? (qt = !1, je = ns(ve)) : Pi ? (qt = !1, je = is(ve)) : je = [] : ws(ve) || zn(ve) ? (je = se, zn(se) ? je = Cs(se) : (!yt(se) || $n(se)) && (je = cs(ve))) : qt = !1;
504
504
  }
505
505
  qt && (be.set(ve, je), ie(je, ve, G, me, be), be.delete(ve)), Dn(x, L, je);
506
506
  }
@@ -584,7 +584,7 @@ function Ms() {
584
584
  }
585
585
  function Ci(x, _) {
586
586
  var L = typeof x;
587
- return _ = _ ?? o, !!_ && (L == "number" || L != "symbol" && K.test(x)) && x > -1 && x % 1 == 0 && x < _;
587
+ return _ = _ ?? o, !!_ && (L == "number" || L != "symbol" && Y.test(x)) && x > -1 && x % 1 == 0 && x < _;
588
588
  }
589
589
  function fs(x, _, L) {
590
590
  if (!yt(L))
@@ -614,8 +614,8 @@ function Ms() {
614
614
  return Ne.call(x);
615
615
  }
616
616
  function gs(x, _, L) {
617
- return _ = Pt(_ === void 0 ? x.length - 1 : _, 0), function() {
618
- for (var G = arguments, ie = -1, me = Pt(G.length - _, 0), be = Array(me); ++ie < me; )
617
+ return _ = It(_ === void 0 ? x.length - 1 : _, 0), function() {
618
+ for (var G = arguments, ie = -1, me = It(G.length - _, 0), be = Array(me); ++ie < me; )
619
619
  be[ie] = G[_ + ie];
620
620
  ie = -1;
621
621
  for (var se = Array(_ + 1); ++ie < _; )
@@ -685,13 +685,13 @@ function Ms() {
685
685
  return x != null && typeof x == "object";
686
686
  }
687
687
  function ws(x) {
688
- if (!zt(x) || ln(x) != P)
688
+ if (!zt(x) || ln(x) != I)
689
689
  return !1;
690
690
  var _ = le(x);
691
691
  if (_ === null)
692
692
  return !0;
693
693
  var L = ce.call(_, "constructor") && _.constructor;
694
- return typeof L == "function" && L instanceof L && re.call(L) == ut;
694
+ return typeof L == "function" && L instanceof L && re.call(L) == ct;
695
695
  }
696
696
  var Ei = Fe ? Tt(Fe) : Kl;
697
697
  function Cs(x) {
@@ -1407,7 +1407,7 @@ const zr = /* @__PURE__ */ nt(Ds), Rs = {
1407
1407
  throw new Error("id or configurations is required");
1408
1408
  const n = Vs[e] || {};
1409
1409
  return zr(n, t);
1410
- }, Se = In({}), lo = ({
1410
+ }, Se = Pn({}), lo = ({
1411
1411
  children: e,
1412
1412
  clientId: t = null,
1413
1413
  configurations: n = null,
@@ -1555,7 +1555,7 @@ lo.propTypes = {
1555
1555
  xpertKey: C.string,
1556
1556
  widgetMode: C.bool
1557
1557
  };
1558
- const St = In({}), so = C.shape({
1558
+ const St = Pn({}), so = C.shape({
1559
1559
  content: C.string.isRequired,
1560
1560
  feedbackThumbType: C.oneOf(["DOWN", "UP"]),
1561
1561
  liveAgent: C.bool,
@@ -1575,7 +1575,7 @@ const St = In({}), so = C.shape({
1575
1575
  })
1576
1576
  })
1577
1577
  )
1578
- }), Pn = C.arrayOf(so), uo = ({
1578
+ }), In = C.arrayOf(so), uo = ({
1579
1579
  children: e,
1580
1580
  conversation: t,
1581
1581
  onFeedbackSelection: n,
@@ -1599,7 +1599,7 @@ const St = In({}), so = C.shape({
1599
1599
  };
1600
1600
  uo.propTypes = {
1601
1601
  children: C.element.isRequired,
1602
- conversation: Pn,
1602
+ conversation: In,
1603
1603
  onFeedbackSelection: C.func,
1604
1604
  onMessageSent: C.func
1605
1605
  };
@@ -1613,11 +1613,11 @@ const Di = 991, Gs = () => {
1613
1613
  };
1614
1614
  return window.addEventListener("resize", n), () => window.removeEventListener("resize", n);
1615
1615
  }, []), e;
1616
- }, dt = {
1616
+ }, ut = {
1617
1617
  LIVECHAT: "LIVECHAT",
1618
1618
  XPERT: "XPERT"
1619
- }, Ie = In({}), co = ({ children: e }) => {
1620
- const [t, n] = ee(!1), [r, i] = ee(!1), [a, o] = ee(!1), [l, s] = ee(!0), [u, c] = ee(!1), [d, p] = ee(dt.XPERT), f = Gs(), y = {
1619
+ }, Pe = Pn({}), co = ({ children: e }) => {
1620
+ const [t, n] = ee(!1), [r, i] = ee(!1), [a, o] = ee(!1), [l, s] = ee(!0), [u, c] = ee(!1), [d, p] = ee(ut.XPERT), f = Gs(), y = {
1621
1621
  disabledScroll: t,
1622
1622
  hasError: r,
1623
1623
  hasNewMessage: a,
@@ -1632,7 +1632,7 @@ const Di = 991, Gs = () => {
1632
1632
  setLoading: c,
1633
1633
  setMode: p
1634
1634
  };
1635
- return /* @__PURE__ */ k.jsx(Ie.Provider, { value: y, children: e });
1635
+ return /* @__PURE__ */ k.jsx(Pe.Provider, { value: y, children: e });
1636
1636
  };
1637
1637
  co.propTypes = {
1638
1638
  children: C.element.isRequired
@@ -1686,7 +1686,7 @@ function An({
1686
1686
  children: i,
1687
1687
  ...a
1688
1688
  }) {
1689
- const { isMobile: o } = Q(Ie);
1689
+ const { isMobile: o } = Q(Pe);
1690
1690
  return /* @__PURE__ */ k.jsx(
1691
1691
  "button",
1692
1692
  {
@@ -1724,31 +1724,31 @@ eyes follow your mouse when you hover near it.`, qr = ({
1724
1724
  handleFloatingActionButtonClick: e
1725
1725
  }) => {
1726
1726
  var f, y, h, v;
1727
- const { id: t, launchButton: n } = Q(Se), { isMobile: r } = Q(Ie), i = !Re.get(
1727
+ const { id: t, launchButton: n } = Q(Se), { isMobile: r } = Q(Pe), i = !Re.get(
1728
1728
  `${t}-proactive-message-xpert-chatbot`
1729
1729
  ), a = ze(null), o = ze(!1), l = i ? (f = n == null ? void 0 : n.animatedGraduate) == null ? void 0 : f.delayMs : ((y = n == null ? void 0 : n.animatedGraduate) == null ? void 0 : y.delayMs) * 2, [s, u] = ee(!1), c = window.matchMedia(
1730
1730
  `(max-width: ${Ys}px)`
1731
1731
  ).matches;
1732
1732
  ke(() => {
1733
- const P = setTimeout(
1733
+ const I = setTimeout(
1734
1734
  () => {
1735
1735
  u(!0);
1736
1736
  },
1737
1737
  l
1738
1738
  );
1739
1739
  return () => {
1740
- clearTimeout(P);
1740
+ clearTimeout(I);
1741
1741
  };
1742
1742
  }, [l]), ke(() => {
1743
- const g = (P) => {
1743
+ const g = (I) => {
1744
1744
  const A = window.devicePixelRatio > 1.5;
1745
1745
  if (!(o != null && o.current) || c || A)
1746
1746
  return;
1747
1747
  a.current.querySelectorAll(
1748
1748
  ".xpert_chatbot__animated_graduate__pupil"
1749
- ).forEach((I) => {
1750
- const b = I.getBoundingClientRect(), E = (P.pageX - window.scrollX - b.left) / 30 / 16 + "rem", z = (P.pageY - window.scrollY - b.top) / 30 / 16 + "rem";
1751
- I.style.transform = "translate3d(" + E + "," + z + ", 0rem)";
1749
+ ).forEach((P) => {
1750
+ const b = P.getBoundingClientRect(), E = (I.pageX - window.scrollX - b.left) / 30 / 16 + "rem", z = (I.pageY - window.scrollY - b.top) / 30 / 16 + "rem";
1751
+ P.style.transform = "translate3d(" + E + "," + z + ", 0rem)";
1752
1752
  });
1753
1753
  };
1754
1754
  return window.addEventListener("mousemove", g), () => {
@@ -1934,7 +1934,7 @@ const Js = "data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20hei
1934
1934
  default: Js
1935
1935
  }, Ur = ({ handleFloatingActionButtonClick: e }) => {
1936
1936
  var r, i;
1937
- const { launchButton: t } = Q(Se), { isMobile: n } = Q(Ie);
1937
+ const { launchButton: t } = Q(Se), { isMobile: n } = Q(Pe);
1938
1938
  return /* @__PURE__ */ k.jsx(
1939
1939
  An,
1940
1940
  {
@@ -2015,12 +2015,12 @@ var ho = ["input:not([inert])", "select:not([inert])", "textarea:not([inert])",
2015
2015
  return i;
2016
2016
  }, bo = function(t) {
2017
2017
  return !isNaN(parseInt(t.getAttribute("tabindex"), 10));
2018
- }, ft = function(t) {
2018
+ }, dt = function(t) {
2019
2019
  if (!t)
2020
2020
  throw new Error("No node provided");
2021
2021
  return t.tabIndex < 0 && (/^(AUDIO|VIDEO|DETAILS)$/.test(t.tagName) || eu(t)) && !bo(t) ? 0 : t.tabIndex;
2022
2022
  }, tu = function(t, n) {
2023
- var r = ft(t);
2023
+ var r = dt(t);
2024
2024
  return r < 0 && n && !bo(t) ? 0 : r;
2025
2025
  }, nu = function(t, n) {
2026
2026
  return t.tabIndex === n.tabIndex ? t.documentOrder - n.documentOrder : t.tabIndex - n.tabIndex;
@@ -2115,7 +2115,7 @@ var ho = ["input:not([inert])", "select:not([inert])", "textarea:not([inert])",
2115
2115
  Sn(n) || ru(n) || cu(n, t) || // For a details element with a summary, the summary element gets the focus
2116
2116
  iu(n) || fu(n));
2117
2117
  }, _r = function(t, n) {
2118
- return !(su(n) || ft(n) < 0 || !_n(t, n));
2118
+ return !(su(n) || dt(n) < 0 || !_n(t, n));
2119
2119
  }, du = function(t) {
2120
2120
  var n = parseInt(t.getAttribute("tabindex"), 10);
2121
2121
  return !!(isNaN(n) || n >= 0);
@@ -2162,7 +2162,7 @@ var ho = ["input:not([inert])", "select:not([inert])", "textarea:not([inert])",
2162
2162
  const mu = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
2163
2163
  __proto__: null,
2164
2164
  focusable: wo,
2165
- getTabIndex: ft,
2165
+ getTabIndex: dt,
2166
2166
  isFocusable: yn,
2167
2167
  isTabbable: wt,
2168
2168
  tabbable: xo
@@ -2270,7 +2270,7 @@ var qi = {
2270
2270
  return typeof t == "function" ? t.apply(void 0, r) : t;
2271
2271
  }, dn = function(t) {
2272
2272
  return t.target.shadowRoot && typeof t.composedPath == "function" ? t.composedPath()[0] : t.target;
2273
- }, Ou = [], Iu = function(t, n) {
2273
+ }, Ou = [], Pu = function(t, n) {
2274
2274
  var r = (n == null ? void 0 : n.document) || document, i = (n == null ? void 0 : n.trapStack) || Ou, a = zi({
2275
2275
  returnFocusOnDeactivate: !0,
2276
2276
  escapeDeactivates: !0,
@@ -2319,26 +2319,26 @@ var qi = {
2319
2319
  }, u = function(T, S) {
2320
2320
  var O = typeof (S == null ? void 0 : S.composedPath) == "function" ? S.composedPath() : void 0;
2321
2321
  return o.containerGroups.findIndex(function(N) {
2322
- var M = N.container, D = N.tabbableNodes;
2323
- return M.contains(T) || // fall back to explicit tabbable search which will take into consideration any
2322
+ var H = N.container, j = N.tabbableNodes;
2323
+ return H.contains(T) || // fall back to explicit tabbable search which will take into consideration any
2324
2324
  // web components if the `tabbableOptions.getShadowRoot` option was used for
2325
2325
  // the trap, enabling shadow DOM support in tabbable (`Node.contains()` doesn't
2326
2326
  // look inside web components even if open)
2327
- (O == null ? void 0 : O.includes(M)) || D.find(function(B) {
2328
- return B === T;
2327
+ (O == null ? void 0 : O.includes(H)) || j.find(function(D) {
2328
+ return D === T;
2329
2329
  });
2330
2330
  });
2331
2331
  }, c = function(T) {
2332
- var S = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : {}, O = S.hasFallback, N = O === void 0 ? !1 : O, M = S.params, D = M === void 0 ? [] : M, B = a[T];
2333
- if (typeof B == "function" && (B = B.apply(void 0, xu(D))), B === !0 && (B = void 0), !B) {
2334
- if (B === void 0 || B === !1)
2335
- return B;
2332
+ var S = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : {}, O = S.hasFallback, N = O === void 0 ? !1 : O, H = S.params, j = H === void 0 ? [] : H, D = a[T];
2333
+ if (typeof D == "function" && (D = D.apply(void 0, xu(j))), D === !0 && (D = void 0), !D) {
2334
+ if (D === void 0 || D === !1)
2335
+ return D;
2336
2336
  throw new Error("`".concat(T, "` was specified but was not a node, or did not return a node"));
2337
2337
  }
2338
- var m = B;
2339
- if (typeof B == "string") {
2338
+ var m = D;
2339
+ if (typeof D == "string") {
2340
2340
  try {
2341
- m = r.querySelector(B);
2341
+ m = r.querySelector(D);
2342
2342
  } catch (W) {
2343
2343
  throw new Error("`".concat(T, '` appears to be an invalid selector; error="').concat(W.message, '"'));
2344
2344
  }
@@ -2365,12 +2365,12 @@ var qi = {
2365
2365
  return T;
2366
2366
  }, p = function() {
2367
2367
  if (o.containerGroups = o.containers.map(function(T) {
2368
- var S = xo(T, a.tabbableOptions), O = wo(T, a.tabbableOptions), N = S.length > 0 ? S[0] : void 0, M = S.length > 0 ? S[S.length - 1] : void 0, D = O.find(function(W) {
2368
+ var S = xo(T, a.tabbableOptions), O = wo(T, a.tabbableOptions), N = S.length > 0 ? S[0] : void 0, H = S.length > 0 ? S[S.length - 1] : void 0, j = O.find(function(W) {
2369
2369
  return wt(W);
2370
- }), B = O.slice().reverse().find(function(W) {
2370
+ }), D = O.slice().reverse().find(function(W) {
2371
2371
  return wt(W);
2372
2372
  }), m = !!S.find(function(W) {
2373
- return ft(W) > 0;
2373
+ return dt(W) > 0;
2374
2374
  });
2375
2375
  return {
2376
2376
  container: T,
@@ -2381,7 +2381,7 @@ var qi = {
2381
2381
  /** First tabbable node in container, __tabindex__ order; `undefined` if none. */
2382
2382
  firstTabbableNode: N,
2383
2383
  /** Last tabbable node in container, __tabindex__ order; `undefined` if none. */
2384
- lastTabbableNode: M,
2384
+ lastTabbableNode: H,
2385
2385
  // NOTE: DOM order is NOT NECESSARILY "document position" order, but figuring that out
2386
2386
  // would require more than just https://developer.mozilla.org/en-US/docs/Web/API/Node/compareDocumentPosition
2387
2387
  // because that API doesn't work with Shadow DOM as well as it should (@see
@@ -2390,9 +2390,9 @@ var qi = {
2390
2390
  // "close enough most of the time" alternative for positive tabindexes which should generally
2391
2391
  // be avoided anyway...
2392
2392
  /** First tabbable node in container, __DOM__ order; `undefined` if none. */
2393
- firstDomTabbableNode: D,
2393
+ firstDomTabbableNode: j,
2394
2394
  /** Last tabbable node in container, __DOM__ order; `undefined` if none. */
2395
- lastDomTabbableNode: B,
2395
+ lastDomTabbableNode: D,
2396
2396
  /**
2397
2397
  * Finds the __tabbable__ node that follows the given node in the specified direction,
2398
2398
  * in this container, if any.
@@ -2401,13 +2401,13 @@ var qi = {
2401
2401
  * in reverse.
2402
2402
  * @returns {HTMLElement|undefined} The next tabbable node, if any.
2403
2403
  */
2404
- nextTabbableNode: function(K) {
2405
- var w = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : !0, Y = S.indexOf(K);
2406
- return Y < 0 ? w ? O.slice(O.indexOf(K) + 1).find(function(oe) {
2404
+ nextTabbableNode: function(Y) {
2405
+ var w = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : !0, K = S.indexOf(Y);
2406
+ return K < 0 ? w ? O.slice(O.indexOf(Y) + 1).find(function(oe) {
2407
2407
  return wt(oe);
2408
- }) : O.slice(0, O.indexOf(K)).reverse().find(function(oe) {
2408
+ }) : O.slice(0, O.indexOf(Y)).reverse().find(function(oe) {
2409
2409
  return wt(oe);
2410
- }) : S[Y + (w ? 1 : -1)];
2410
+ }) : S[K + (w ? 1 : -1)];
2411
2411
  }
2412
2412
  };
2413
2413
  }), o.tabbableGroups = o.containerGroups.filter(function(T) {
@@ -2438,35 +2438,35 @@ var qi = {
2438
2438
  });
2439
2439
  return S || (S === !1 ? !1 : T);
2440
2440
  }, v = function(T) {
2441
- var S = T.target, O = T.event, N = T.isBackward, M = N === void 0 ? !1 : N;
2441
+ var S = T.target, O = T.event, N = T.isBackward, H = N === void 0 ? !1 : N;
2442
2442
  S = S || dn(O), p();
2443
- var D = null;
2443
+ var j = null;
2444
2444
  if (o.tabbableGroups.length > 0) {
2445
- var B = u(S, O), m = B >= 0 ? o.containerGroups[B] : void 0;
2446
- if (B < 0)
2447
- M ? D = o.tabbableGroups[o.tabbableGroups.length - 1].lastTabbableNode : D = o.tabbableGroups[0].firstTabbableNode;
2448
- else if (M) {
2445
+ var D = u(S, O), m = D >= 0 ? o.containerGroups[D] : void 0;
2446
+ if (D < 0)
2447
+ H ? j = o.tabbableGroups[o.tabbableGroups.length - 1].lastTabbableNode : j = o.tabbableGroups[0].firstTabbableNode;
2448
+ else if (H) {
2449
2449
  var W = o.tabbableGroups.findIndex(function(de) {
2450
2450
  var pe = de.firstTabbableNode;
2451
2451
  return S === pe;
2452
2452
  });
2453
- if (W < 0 && (m.container === S || yn(S, a.tabbableOptions) && !wt(S, a.tabbableOptions) && !m.nextTabbableNode(S, !1)) && (W = B), W >= 0) {
2454
- var K = W === 0 ? o.tabbableGroups.length - 1 : W - 1, w = o.tabbableGroups[K];
2455
- D = ft(S) >= 0 ? w.lastTabbableNode : w.lastDomTabbableNode;
2456
- } else Yt(O) || (D = m.nextTabbableNode(S, !1));
2453
+ if (W < 0 && (m.container === S || yn(S, a.tabbableOptions) && !wt(S, a.tabbableOptions) && !m.nextTabbableNode(S, !1)) && (W = D), W >= 0) {
2454
+ var Y = W === 0 ? o.tabbableGroups.length - 1 : W - 1, w = o.tabbableGroups[Y];
2455
+ j = dt(S) >= 0 ? w.lastTabbableNode : w.lastDomTabbableNode;
2456
+ } else Yt(O) || (j = m.nextTabbableNode(S, !1));
2457
2457
  } else {
2458
- var Y = o.tabbableGroups.findIndex(function(de) {
2458
+ var K = o.tabbableGroups.findIndex(function(de) {
2459
2459
  var pe = de.lastTabbableNode;
2460
2460
  return S === pe;
2461
2461
  });
2462
- if (Y < 0 && (m.container === S || yn(S, a.tabbableOptions) && !wt(S, a.tabbableOptions) && !m.nextTabbableNode(S)) && (Y = B), Y >= 0) {
2463
- var oe = Y === o.tabbableGroups.length - 1 ? 0 : Y + 1, ne = o.tabbableGroups[oe];
2464
- D = ft(S) >= 0 ? ne.firstTabbableNode : ne.firstDomTabbableNode;
2465
- } else Yt(O) || (D = m.nextTabbableNode(S));
2462
+ if (K < 0 && (m.container === S || yn(S, a.tabbableOptions) && !wt(S, a.tabbableOptions) && !m.nextTabbableNode(S)) && (K = D), K >= 0) {
2463
+ var oe = K === o.tabbableGroups.length - 1 ? 0 : K + 1, ne = o.tabbableGroups[oe];
2464
+ j = dt(S) >= 0 ? ne.firstTabbableNode : ne.firstDomTabbableNode;
2465
+ } else Yt(O) || (j = m.nextTabbableNode(S));
2466
2466
  }
2467
2467
  } else
2468
- D = c("fallbackFocus");
2469
- return D;
2468
+ j = c("fallbackFocus");
2469
+ return j;
2470
2470
  }, g = function(T) {
2471
2471
  var S = dn(T);
2472
2472
  if (!(u(S, T) >= 0)) {
@@ -2484,31 +2484,31 @@ var qi = {
2484
2484
  }
2485
2485
  Ut(a.allowOutsideClick, T) || T.preventDefault();
2486
2486
  }
2487
- }, P = function(T) {
2487
+ }, I = function(T) {
2488
2488
  var S = dn(T), O = u(S, T) >= 0;
2489
2489
  if (O || S instanceof Document)
2490
2490
  O && (o.mostRecentlyFocusedNode = S);
2491
2491
  else {
2492
2492
  T.stopImmediatePropagation();
2493
- var N, M = !0;
2493
+ var N, H = !0;
2494
2494
  if (o.mostRecentlyFocusedNode)
2495
- if (ft(o.mostRecentlyFocusedNode) > 0) {
2496
- var D = u(o.mostRecentlyFocusedNode), B = o.containerGroups[D].tabbableNodes;
2497
- if (B.length > 0) {
2498
- var m = B.findIndex(function(W) {
2495
+ if (dt(o.mostRecentlyFocusedNode) > 0) {
2496
+ var j = u(o.mostRecentlyFocusedNode), D = o.containerGroups[j].tabbableNodes;
2497
+ if (D.length > 0) {
2498
+ var m = D.findIndex(function(W) {
2499
2499
  return W === o.mostRecentlyFocusedNode;
2500
2500
  });
2501
- m >= 0 && (a.isKeyForward(o.recentNavEvent) ? m + 1 < B.length && (N = B[m + 1], M = !1) : m - 1 >= 0 && (N = B[m - 1], M = !1));
2501
+ m >= 0 && (a.isKeyForward(o.recentNavEvent) ? m + 1 < D.length && (N = D[m + 1], H = !1) : m - 1 >= 0 && (N = D[m - 1], H = !1));
2502
2502
  }
2503
2503
  } else
2504
2504
  o.containerGroups.some(function(W) {
2505
- return W.tabbableNodes.some(function(K) {
2506
- return ft(K) > 0;
2505
+ return W.tabbableNodes.some(function(Y) {
2506
+ return dt(Y) > 0;
2507
2507
  });
2508
- }) || (M = !1);
2508
+ }) || (H = !1);
2509
2509
  else
2510
- M = !1;
2511
- M && (N = v({
2510
+ H = !1;
2511
+ H && (N = v({
2512
2512
  // move FROM the MRU node, not event-related node (which will be the node that is
2513
2513
  // outside the trap causing the focus escape we're trying to fix)
2514
2514
  target: o.mostRecentlyFocusedNode,
@@ -2526,7 +2526,7 @@ var qi = {
2526
2526
  O && (Yt(T) && T.preventDefault(), y(O));
2527
2527
  }, q = function(T) {
2528
2528
  (a.isKeyForward(T) || a.isKeyBackward(T)) && A(T, a.isKeyBackward(T));
2529
- }, I = function(T) {
2529
+ }, P = function(T) {
2530
2530
  _u(T) && Ut(a.escapeDeactivates, T) !== !1 && (T.preventDefault(), l.deactivate());
2531
2531
  }, b = function(T) {
2532
2532
  var S = dn(T);
@@ -2535,7 +2535,7 @@ var qi = {
2535
2535
  if (o.active)
2536
2536
  return qi.activateTrap(i, l), o.delayInitialFocusTimer = a.delayInitialFocus ? Ui(function() {
2537
2537
  y(d());
2538
- }) : y(d()), r.addEventListener("focusin", P, !0), r.addEventListener("mousedown", g, {
2538
+ }) : y(d()), r.addEventListener("focusin", I, !0), r.addEventListener("mousedown", g, {
2539
2539
  capture: !0,
2540
2540
  passive: !1
2541
2541
  }), r.addEventListener("touchstart", g, {
@@ -2547,19 +2547,19 @@ var qi = {
2547
2547
  }), r.addEventListener("keydown", q, {
2548
2548
  capture: !0,
2549
2549
  passive: !1
2550
- }), r.addEventListener("keydown", I), l;
2550
+ }), r.addEventListener("keydown", P), l;
2551
2551
  }, z = function() {
2552
2552
  if (o.active)
2553
- return r.removeEventListener("focusin", P, !0), r.removeEventListener("mousedown", g, !0), r.removeEventListener("touchstart", g, !0), r.removeEventListener("click", b, !0), r.removeEventListener("keydown", q, !0), r.removeEventListener("keydown", I), l;
2553
+ return r.removeEventListener("focusin", I, !0), r.removeEventListener("mousedown", g, !0), r.removeEventListener("touchstart", g, !0), r.removeEventListener("click", b, !0), r.removeEventListener("keydown", q, !0), r.removeEventListener("keydown", P), l;
2554
2554
  }, F = function(T) {
2555
2555
  var S = T.some(function(O) {
2556
2556
  var N = Array.from(O.removedNodes);
2557
- return N.some(function(M) {
2558
- return M === o.mostRecentlyFocusedNode;
2557
+ return N.some(function(H) {
2558
+ return H === o.mostRecentlyFocusedNode;
2559
2559
  });
2560
2560
  });
2561
2561
  S && y(d());
2562
- }, U = typeof window < "u" && "MutationObserver" in window ? new MutationObserver(F) : void 0, j = function() {
2562
+ }, U = typeof window < "u" && "MutationObserver" in window ? new MutationObserver(F) : void 0, M = function() {
2563
2563
  U && (U.disconnect(), o.active && !o.paused && o.containers.map(function(T) {
2564
2564
  U.observe(T, {
2565
2565
  subtree: !0,
@@ -2579,10 +2579,10 @@ var qi = {
2579
2579
  return this;
2580
2580
  var S = s(T, "onActivate"), O = s(T, "onPostActivate"), N = s(T, "checkCanFocusTrap");
2581
2581
  N || p(), o.active = !0, o.paused = !1, o.nodeFocusedBeforeActivation = r.activeElement, S == null || S();
2582
- var M = function() {
2583
- N && p(), E(), j(), O == null || O();
2582
+ var H = function() {
2583
+ N && p(), E(), M(), O == null || O();
2584
2584
  };
2585
- return N ? (N(o.containers.concat()).then(M, M), this) : (M(), this);
2585
+ return N ? (N(o.containers.concat()).then(H, H), this) : (H(), this);
2586
2586
  },
2587
2587
  deactivate: function(T) {
2588
2588
  if (!o.active)
@@ -2592,15 +2592,15 @@ var qi = {
2592
2592
  onPostDeactivate: a.onPostDeactivate,
2593
2593
  checkCanReturnFocus: a.checkCanReturnFocus
2594
2594
  }, T);
2595
- clearTimeout(o.delayInitialFocusTimer), o.delayInitialFocusTimer = void 0, z(), o.active = !1, o.paused = !1, j(), qi.deactivateTrap(i, l);
2596
- var O = s(S, "onDeactivate"), N = s(S, "onPostDeactivate"), M = s(S, "checkCanReturnFocus"), D = s(S, "returnFocus", "returnFocusOnDeactivate");
2595
+ clearTimeout(o.delayInitialFocusTimer), o.delayInitialFocusTimer = void 0, z(), o.active = !1, o.paused = !1, M(), qi.deactivateTrap(i, l);
2596
+ var O = s(S, "onDeactivate"), N = s(S, "onPostDeactivate"), H = s(S, "checkCanReturnFocus"), j = s(S, "returnFocus", "returnFocusOnDeactivate");
2597
2597
  O == null || O();
2598
- var B = function() {
2598
+ var D = function() {
2599
2599
  Ui(function() {
2600
- D && y(h(o.nodeFocusedBeforeActivation)), N == null || N();
2600
+ j && y(h(o.nodeFocusedBeforeActivation)), N == null || N();
2601
2601
  });
2602
2602
  };
2603
- return D && M ? (M(h(o.nodeFocusedBeforeActivation)).then(B, B), this) : (B(), this);
2603
+ return j && H ? (H(h(o.nodeFocusedBeforeActivation)).then(D, D), this) : (D(), this);
2604
2604
  },
2605
2605
  pause: function(T) {
2606
2606
  return o.active ? (o.manuallyPaused = !0, this._setPausedState(!0, T)) : this;
@@ -2612,7 +2612,7 @@ var qi = {
2612
2612
  var S = [].concat(T).filter(Boolean);
2613
2613
  return o.containers = S.map(function(O) {
2614
2614
  return typeof O == "string" ? r.querySelector(O) : O;
2615
- }), o.active && p(), j(), this;
2615
+ }), o.active && p(), M(), this;
2616
2616
  }
2617
2617
  }, Object.defineProperties(l, {
2618
2618
  _isManuallyPaused: {
@@ -2626,20 +2626,20 @@ var qi = {
2626
2626
  return this;
2627
2627
  if (o.paused = T, T) {
2628
2628
  var O = s(S, "onPause"), N = s(S, "onPostPause");
2629
- O == null || O(), z(), j(), N == null || N();
2629
+ O == null || O(), z(), M(), N == null || N();
2630
2630
  } else {
2631
- var M = s(S, "onUnpause"), D = s(S, "onPostUnpause");
2632
- M == null || M(), p(), E(), j(), D == null || D();
2631
+ var H = s(S, "onUnpause"), j = s(S, "onPostUnpause");
2632
+ H == null || H(), p(), E(), M(), j == null || j();
2633
2633
  }
2634
2634
  return this;
2635
2635
  }
2636
2636
  }
2637
2637
  }), l.updateContainerElements(t), l;
2638
2638
  };
2639
- const Pu = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
2639
+ const Iu = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
2640
2640
  __proto__: null,
2641
- createFocusTrap: Iu
2642
- }, Symbol.toStringTag, { value: "Module" })), Au = /* @__PURE__ */ ao(Pu), Fu = /* @__PURE__ */ ao(mu);
2641
+ createFocusTrap: Pu
2642
+ }, Symbol.toStringTag, { value: "Module" })), Au = /* @__PURE__ */ ao(Iu), Fu = /* @__PURE__ */ ao(mu);
2643
2643
  var Qn, $i;
2644
2644
  function Nu() {
2645
2645
  if ($i) return Qn;
@@ -2717,28 +2717,28 @@ function Nu() {
2717
2717
  }
2718
2718
  return (E === "string" ? String : Number)(b);
2719
2719
  }
2720
- var y = Ge, h = /* @__PURE__ */ oo(), v = Au, g = v.createFocusTrap, P = Fu, A = P.isFocusable, q = /* @__PURE__ */ function(b) {
2720
+ var y = Ge, h = /* @__PURE__ */ oo(), v = Au, g = v.createFocusTrap, I = Fu, A = I.isFocusable, q = /* @__PURE__ */ function(b) {
2721
2721
  function E(z) {
2722
2722
  var F;
2723
- t(this, E), F = i(this, E, [z]), d(F, "getNodeForOption", function(H) {
2724
- var T, S = (T = this.internalOptions[H]) !== null && T !== void 0 ? T : this.originalOptions[H];
2723
+ t(this, E), F = i(this, E, [z]), d(F, "getNodeForOption", function(B) {
2724
+ var T, S = (T = this.internalOptions[B]) !== null && T !== void 0 ? T : this.originalOptions[B];
2725
2725
  if (typeof S == "function") {
2726
- for (var O = arguments.length, N = new Array(O > 1 ? O - 1 : 0), M = 1; M < O; M++)
2727
- N[M - 1] = arguments[M];
2726
+ for (var O = arguments.length, N = new Array(O > 1 ? O - 1 : 0), H = 1; H < O; H++)
2727
+ N[H - 1] = arguments[H];
2728
2728
  S = S.apply(void 0, N);
2729
2729
  }
2730
2730
  if (S === !0 && (S = void 0), !S) {
2731
2731
  if (S === void 0 || S === !1)
2732
2732
  return S;
2733
- throw new Error("`".concat(H, "` was specified but was not a node, or did not return a node"));
2733
+ throw new Error("`".concat(B, "` was specified but was not a node, or did not return a node"));
2734
2734
  }
2735
- var D = S;
2735
+ var j = S;
2736
2736
  if (typeof S == "string") {
2737
- var B;
2738
- if (D = (B = this.getDocument()) === null || B === void 0 ? void 0 : B.querySelector(S), !D)
2739
- throw new Error("`".concat(H, "` as selector refers to no known node"));
2737
+ var D;
2738
+ if (j = (D = this.getDocument()) === null || D === void 0 ? void 0 : D.querySelector(S), !j)
2739
+ throw new Error("`".concat(B, "` as selector refers to no known node"));
2740
2740
  }
2741
- return D;
2741
+ return j;
2742
2742
  }), F.handleDeactivate = F.handleDeactivate.bind(F), F.handlePostDeactivate = F.handlePostDeactivate.bind(F), F.handleClickOutsideDeactivates = F.handleClickOutsideDeactivates.bind(F), F.internalOptions = {
2743
2743
  // We need to hijack the returnFocusOnDeactivate option,
2744
2744
  // because React can move focus into the element before we arrived at
@@ -2770,13 +2770,13 @@ function Nu() {
2770
2770
  clickOutsideDeactivates: !1
2771
2771
  };
2772
2772
  var U = z.focusTrapOptions;
2773
- for (var j in U)
2774
- if (Object.prototype.hasOwnProperty.call(U, j)) {
2775
- if (j === "returnFocusOnDeactivate" || j === "onDeactivate" || j === "onPostDeactivate" || j === "checkCanReturnFocus" || j === "clickOutsideDeactivates") {
2776
- F.originalOptions[j] = U[j];
2773
+ for (var M in U)
2774
+ if (Object.prototype.hasOwnProperty.call(U, M)) {
2775
+ if (M === "returnFocusOnDeactivate" || M === "onDeactivate" || M === "onPostDeactivate" || M === "checkCanReturnFocus" || M === "clickOutsideDeactivates") {
2776
+ F.originalOptions[M] = U[M];
2777
2777
  continue;
2778
2778
  }
2779
- F.internalOptions[j] = U[j];
2779
+ F.internalOptions[M] = U[M];
2780
2780
  }
2781
2781
  return F.outsideClick = null, F.focusTrapElements = z.containerElements || [], F.updatePreviousElement(), F;
2782
2782
  }
@@ -2836,15 +2836,15 @@ function Nu() {
2836
2836
  key: "handlePostDeactivate",
2837
2837
  value: function() {
2838
2838
  var F = this, U = function() {
2839
- var H = F.getReturnFocusNode(), T = !!// did the consumer allow it?
2839
+ var B = F.getReturnFocusNode(), T = !!// did the consumer allow it?
2840
2840
  (F.originalOptions.returnFocusOnDeactivate && // can we actually focus the node?
2841
- H !== null && H !== void 0 && H.focus && // was there an outside click that allowed deactivation?
2841
+ B !== null && B !== void 0 && B.focus && // was there an outside click that allowed deactivation?
2842
2842
  (!F.outsideClick || // did the consumer allow deactivation when the outside node was clicked?
2843
2843
  F.outsideClick.allowDeactivation && // is the outside node NOT focusable (implying that it did NOT receive focus
2844
2844
  // as a result of the click-through) -- in which case do NOT restore focus
2845
2845
  // to `returnFocusNode` because focus should remain on the outside node
2846
2846
  !A(F.outsideClick.target, F.internalOptions.tabbableOptions))), S = F.internalOptions.preventScroll, O = S === void 0 ? !1 : S;
2847
- T && H.focus({
2847
+ T && B.focus({
2848
2848
  preventScroll: O
2849
2849
  }), F.originalOptions.onPostDeactivate && F.originalOptions.onPostDeactivate.call(null), F.outsideClick = null;
2850
2850
  };
@@ -2870,12 +2870,12 @@ function Nu() {
2870
2870
  value: function(F) {
2871
2871
  if (this.focusTrap) {
2872
2872
  F.containerElements !== this.props.containerElements && this.focusTrap.updateContainerElements(this.props.containerElements);
2873
- var U = !F.active && this.props.active, j = F.active && !this.props.active, H = !F.paused && this.props.paused, T = F.paused && !this.props.paused;
2874
- if (U && (this.updatePreviousElement(), this.focusTrap.activate()), j) {
2873
+ var U = !F.active && this.props.active, M = F.active && !this.props.active, B = !F.paused && this.props.paused, T = F.paused && !this.props.paused;
2874
+ if (U && (this.updatePreviousElement(), this.focusTrap.activate()), M) {
2875
2875
  this.deactivateTrap();
2876
2876
  return;
2877
2877
  }
2878
- H && this.focusTrap.pause(), T && this.focusTrap.unpause();
2878
+ B && this.focusTrap.pause(), T && this.focusTrap.unpause();
2879
2879
  } else
2880
2880
  F.containerElements !== this.props.containerElements && (this.focusTrapElements = this.props.containerElements), this.props.active && (this.updatePreviousElement(), this.setupFocusTrap());
2881
2881
  }
@@ -2891,18 +2891,18 @@ function Nu() {
2891
2891
  if (U) {
2892
2892
  if (U.type && U.type === y.Fragment)
2893
2893
  throw new Error("A focus-trap cannot use a Fragment as its child container. Try replacing it with a <div> element.");
2894
- var j = function(S) {
2894
+ var M = function(S) {
2895
2895
  var O = F.props.containerElements;
2896
2896
  U && (typeof U.ref == "function" ? U.ref(S) : U.ref && (U.ref.current = S)), F.focusTrapElements = O || [S];
2897
- }, H = y.cloneElement(U, {
2898
- ref: j
2897
+ }, B = y.cloneElement(U, {
2898
+ ref: M
2899
2899
  });
2900
- return H;
2900
+ return B;
2901
2901
  }
2902
2902
  return null;
2903
2903
  }
2904
2904
  }]);
2905
- }(y.Component), I = typeof Element > "u" ? Function : Element;
2905
+ }(y.Component), P = typeof Element > "u" ? Function : Element;
2906
2906
  return q.propTypes = {
2907
2907
  active: h.bool,
2908
2908
  paused: h.bool,
@@ -2918,9 +2918,9 @@ function Nu() {
2918
2918
  onDeactivate: h.func,
2919
2919
  onPostDeactivate: h.func,
2920
2920
  checkCanReturnFocus: h.func,
2921
- initialFocus: h.oneOfType([h.instanceOf(I), h.string, h.bool, h.func]),
2921
+ initialFocus: h.oneOfType([h.instanceOf(P), h.string, h.bool, h.func]),
2922
2922
  fallbackFocus: h.oneOfType([
2923
- h.instanceOf(I),
2923
+ h.instanceOf(P),
2924
2924
  h.string,
2925
2925
  // NOTE: does not support `false` as value (or return value from function)
2926
2926
  h.func
@@ -2928,7 +2928,7 @@ function Nu() {
2928
2928
  escapeDeactivates: h.oneOfType([h.bool, h.func]),
2929
2929
  clickOutsideDeactivates: h.oneOfType([h.bool, h.func]),
2930
2930
  returnFocusOnDeactivate: h.bool,
2931
- setReturnFocus: h.oneOfType([h.instanceOf(I), h.string, h.bool, h.func]),
2931
+ setReturnFocus: h.oneOfType([h.instanceOf(P), h.string, h.bool, h.func]),
2932
2932
  allowOutsideClick: h.oneOfType([h.bool, h.func]),
2933
2933
  preventScroll: h.bool,
2934
2934
  tabbableOptions: h.shape({
@@ -2939,12 +2939,12 @@ function Nu() {
2939
2939
  isKeyForward: h.func,
2940
2940
  isKeyBackward: h.func
2941
2941
  }),
2942
- containerElements: h.arrayOf(h.instanceOf(I)),
2942
+ containerElements: h.arrayOf(h.instanceOf(P)),
2943
2943
  // DOM element ONLY
2944
2944
  children: h.oneOfType([
2945
2945
  h.element,
2946
2946
  // React element
2947
- h.instanceOf(I)
2947
+ h.instanceOf(P)
2948
2948
  // DOM element
2949
2949
  ])
2950
2950
  // NOTE: _createFocusTrap is internal, for testing purposes only, so we don't
@@ -2960,7 +2960,7 @@ function Nu() {
2960
2960
  var Lu = Nu();
2961
2961
  const ju = /* @__PURE__ */ nt(Lu);
2962
2962
  function $r({ style: e, className: t, children: n, isMounted: r }) {
2963
- const { isMobile: i, isNormalSize: a } = Q(Ie), o = ze(null);
2963
+ const { isMobile: i, isNormalSize: a } = Q(Pe), o = ze(null);
2964
2964
  return /* @__PURE__ */ k.jsx(
2965
2965
  ju,
2966
2966
  {
@@ -3229,7 +3229,7 @@ function zu(e, t, n) {
3229
3229
  return !1;
3230
3230
  }
3231
3231
  let en = !1;
3232
- function Io(e) {
3232
+ function Po(e) {
3233
3233
  return typeof e == "boolean" && (en = e), en;
3234
3234
  }
3235
3235
  function Gi(e) {
@@ -3264,12 +3264,12 @@ function Uu(e, t) {
3264
3264
  const r = Mt(t, n);
3265
3265
  return !!Oo(r, e);
3266
3266
  }
3267
- const Po = Object.freeze({
3267
+ const Io = Object.freeze({
3268
3268
  width: null,
3269
3269
  height: null
3270
3270
  }), Ao = Object.freeze({
3271
3271
  // Dimensions
3272
- ...Po,
3272
+ ...Io,
3273
3273
  // Transformations
3274
3274
  ...En
3275
3275
  }), $u = /(-?[0-9.]*[0-9]+[0-9.]*)/g, Vu = /^-?[0-9.]*[0-9]+[0-9.]*$/g;
@@ -3336,11 +3336,11 @@ function Yu(e, t) {
3336
3336
  };
3337
3337
  let a = n.body;
3338
3338
  [n, r].forEach((h) => {
3339
- const v = [], g = h.hFlip, P = h.vFlip;
3339
+ const v = [], g = h.hFlip, I = h.vFlip;
3340
3340
  let A = h.rotate;
3341
- g ? P ? A += 2 : (v.push(
3341
+ g ? I ? A += 2 : (v.push(
3342
3342
  "translate(" + (i.width + i.left).toString() + " " + (0 - i.top).toString() + ")"
3343
- ), v.push("scale(-1 1)"), i.top = i.left = 0) : P && (v.push(
3343
+ ), v.push("scale(-1 1)"), i.top = i.left = 0) : I && (v.push(
3344
3344
  "translate(" + (0 - i.left).toString() + " " + (i.height + i.top).toString() + ")"
3345
3345
  ), v.push("scale(1 -1)"), i.top = i.left = 0);
3346
3346
  let q;
@@ -3405,7 +3405,7 @@ const Or = /* @__PURE__ */ Object.create(null);
3405
3405
  function tc(e, t) {
3406
3406
  Or[e] = t;
3407
3407
  }
3408
- function Ir(e) {
3408
+ function Pr(e) {
3409
3409
  return Or[e] || Or[""];
3410
3410
  }
3411
3411
  function Wr(e) {
@@ -3691,7 +3691,7 @@ function gc(e, t, n, r) {
3691
3691
  abort: h
3692
3692
  };
3693
3693
  }
3694
- function P() {
3694
+ function I() {
3695
3695
  s = "failed", f.forEach((b) => {
3696
3696
  b(void 0, c);
3697
3697
  });
@@ -3714,11 +3714,11 @@ function gc(e, t, n, r) {
3714
3714
  return;
3715
3715
  }
3716
3716
  if (E === "abort") {
3717
- c = z, P();
3717
+ c = z, I();
3718
3718
  return;
3719
3719
  }
3720
3720
  if (F) {
3721
- c = z, p.length || (o.length ? I() : P());
3721
+ c = z, p.length || (o.length ? P() : I());
3722
3722
  return;
3723
3723
  }
3724
3724
  if (y(), A(), !e.random) {
@@ -3729,7 +3729,7 @@ function gc(e, t, n, r) {
3729
3729
  U(z);
3730
3730
  });
3731
3731
  }
3732
- function I() {
3732
+ function P() {
3733
3733
  if (s !== "pending")
3734
3734
  return;
3735
3735
  y();
@@ -3737,11 +3737,11 @@ function gc(e, t, n, r) {
3737
3737
  if (b === void 0) {
3738
3738
  if (p.length) {
3739
3739
  d = setTimeout(() => {
3740
- y(), s === "pending" && (A(), P());
3740
+ y(), s === "pending" && (A(), I());
3741
3741
  }, e.timeout);
3742
3742
  return;
3743
3743
  }
3744
- P();
3744
+ I();
3745
3745
  return;
3746
3746
  }
3747
3747
  const E = {
@@ -3751,9 +3751,9 @@ function gc(e, t, n, r) {
3751
3751
  q(E, z, F);
3752
3752
  }
3753
3753
  };
3754
- p.push(E), u++, d = setTimeout(I, e.rotate), n(b, t, E.callback);
3754
+ p.push(E), u++, d = setTimeout(P, e.rotate), n(b, t, E.callback);
3755
3755
  }
3756
- return setTimeout(I), g;
3756
+ return setTimeout(P), g;
3757
3757
  }
3758
3758
  function No(e) {
3759
3759
  const t = {
@@ -3807,7 +3807,7 @@ function yc(e) {
3807
3807
  function bc(e, t, n) {
3808
3808
  let r, i;
3809
3809
  if (typeof e == "string") {
3810
- const a = Ir(e);
3810
+ const a = Pr(e);
3811
3811
  if (!a)
3812
3812
  return n(void 0, 424), Yi;
3813
3813
  i = a.send;
@@ -3817,7 +3817,7 @@ function bc(e, t, n) {
3817
3817
  const a = Wr(e);
3818
3818
  if (a) {
3819
3819
  r = No(a);
3820
- const o = e.resources ? e.resources[0] : "", l = Ir(o);
3820
+ const o = e.resources ? e.resources[0] : "", l = Pr(o);
3821
3821
  l && (i = l.send);
3822
3822
  }
3823
3823
  }
@@ -3898,7 +3898,7 @@ function wc(e, t) {
3898
3898
  const { valid: o, invalid: l } = xc(i);
3899
3899
  if (l.length && Vt(e, l, null), !o.length)
3900
3900
  return;
3901
- const s = r.match(To) ? Ir(n) : null;
3901
+ const s = r.match(To) ? Pr(n) : null;
3902
3902
  if (!s) {
3903
3903
  Vt(e, o, null);
3904
3904
  return;
@@ -3911,7 +3911,7 @@ function wc(e, t) {
3911
3911
  }));
3912
3912
  }
3913
3913
  const Cc = (e, t) => {
3914
- const n = hc(e, !0, Io()), r = cc(n);
3914
+ const n = hc(e, !0, Po()), r = cc(n);
3915
3915
  if (!r.pending.length) {
3916
3916
  let s = !0;
3917
3917
  return t && setTimeout(() => {
@@ -3948,7 +3948,7 @@ function kc(e, t) {
3948
3948
  };
3949
3949
  for (const r in t) {
3950
3950
  const i = t[r], a = typeof i;
3951
- r in Po ? (i === null || i && (a === "string" || a === "number")) && (n[r] = i) : a === typeof n[r] && (n[r] = r === "rotate" ? i % 4 : i);
3951
+ r in Io ? (i === null || i && (a === "string" || a === "number")) && (n[r] = i) : a === typeof n[r] && (n[r] = r === "rotate" ? i % 4 : i);
3952
3952
  }
3953
3953
  return n;
3954
3954
  }
@@ -4000,11 +4000,11 @@ function Tc(e, t) {
4000
4000
  function Oc(e) {
4001
4001
  return e.replace(/"/g, "'").replace(/%/g, "%25").replace(/#/g, "%23").replace(/</g, "%3C").replace(/>/g, "%3E").replace(/\s+/g, " ");
4002
4002
  }
4003
- function Ic(e) {
4003
+ function Pc(e) {
4004
4004
  return "data:image/svg+xml," + Oc(e);
4005
4005
  }
4006
- function Pc(e) {
4007
- return 'url("' + Ic(e) + '")';
4006
+ function Ic(e) {
4007
+ return 'url("' + Pc(e) + '")';
4008
4008
  }
4009
4009
  let Kt;
4010
4010
  function Ac() {
@@ -4030,7 +4030,7 @@ const Lo = {
4030
4030
  role: "img"
4031
4031
  }, Lc = {
4032
4032
  display: "inline-block"
4033
- }, Pr = {
4033
+ }, Ir = {
4034
4034
  backgroundColor: "currentColor"
4035
4035
  }, jo = {
4036
4036
  backgroundColor: "transparent"
@@ -4039,8 +4039,8 @@ const Lo = {
4039
4039
  Repeat: "no-repeat",
4040
4040
  Size: "100% 100%"
4041
4041
  }, ea = {
4042
- WebkitMask: Pr,
4043
- mask: Pr,
4042
+ WebkitMask: Ir,
4043
+ mask: Ir,
4044
4044
  background: jo
4045
4045
  };
4046
4046
  for (const e in ea) {
@@ -4062,11 +4062,11 @@ const Mc = (e, t, n) => {
4062
4062
  if (n) {
4063
4063
  const v = Fn(n, !1, !0);
4064
4064
  if (v) {
4065
- const g = ["iconify"], P = [
4065
+ const g = ["iconify"], I = [
4066
4066
  "provider",
4067
4067
  "prefix"
4068
4068
  ];
4069
- for (const A of P)
4069
+ for (const A of I)
4070
4070
  v[A] && g.push("iconify--" + v[A]);
4071
4071
  s.className = g.join(" ");
4072
4072
  }
@@ -4137,15 +4137,15 @@ const Mc = (e, t, n) => {
4137
4137
  });
4138
4138
  return s.style = {
4139
4139
  ...o,
4140
- "--svg": Pc(h),
4140
+ "--svg": Ic(h),
4141
4141
  width: ta(c.width),
4142
4142
  height: ta(c.height),
4143
4143
  ...Lc,
4144
- ...y ? Pr : jo,
4144
+ ...y ? Ir : jo,
4145
4145
  ...l
4146
4146
  }, kr("span", s);
4147
4147
  };
4148
- Io(!0);
4148
+ Po(!0);
4149
4149
  tc("", uc);
4150
4150
  if (typeof document < "u" && typeof window < "u") {
4151
4151
  const e = window;
@@ -4256,7 +4256,7 @@ function Nn({
4256
4256
  inputRef: i,
4257
4257
  value: a
4258
4258
  }) {
4259
- const { primaryColor: o } = Q(Se), { hasError: l, hasNewMessage: s } = Q(Ie);
4259
+ const { primaryColor: o } = Q(Se), { hasError: l, hasNewMessage: s } = Q(Pe);
4260
4260
  ke(() => {
4261
4261
  var d;
4262
4262
  (l || s) && ((d = i.current) == null || d.focus());
@@ -4447,47 +4447,47 @@ function Ln({
4447
4447
  text: o,
4448
4448
  userTrackingName: l
4449
4449
  }) {
4450
- var g, P, A, q;
4450
+ var g, I, A, q;
4451
4451
  const [s, u] = ee(!0), { primaryColor: c, id: d, userTracking: p, conversationScreen: f } = Q(Se), y = Ct(
4452
- (I) => {
4452
+ (P) => {
4453
4453
  var b, E, z, F;
4454
- ((b = I == null ? void 0 : I.data) == null ? void 0 : b.who) === "customer" && (!(window != null && window.OnetrustActiveGroups) || (E = window == null ? void 0 : window.OnetrustActiveGroups) != null && E.includes("C0003")) && Re.set(`${d}-live-chat-open`, 1, {
4454
+ ((b = P == null ? void 0 : P.data) == null ? void 0 : b.who) === "customer" && (!(window != null && window.OnetrustActiveGroups) || (E = window == null ? void 0 : window.OnetrustActiveGroups) != null && E.includes("C0003")) && Re.set(`${d}-live-chat-open`, 1, {
4455
4455
  expires: 1,
4456
4456
  path: "/"
4457
- }), ((z = I == null ? void 0 : I.data) == null ? void 0 : z.type) === "connection" && ((F = I == null ? void 0 : I.data) == null ? void 0 : F.state) === "disconnected" && Re.remove(`${d}-live-chat-open`);
4457
+ }), ((z = P == null ? void 0 : P.data) == null ? void 0 : z.type) === "connection" && ((F = P == null ? void 0 : P.data) == null ? void 0 : F.state) === "disconnected" && Re.remove(`${d}-live-chat-open`);
4458
4458
  },
4459
4459
  [d]
4460
4460
  ), h = Ct(
4461
- (I) => {
4461
+ (P) => {
4462
4462
  var b, E, z, F;
4463
- ((b = I == null ? void 0 : I.data) == null ? void 0 : b.type) === "unhide" && ((E = I == null ? void 0 : I.data) == null ? void 0 : E.reason) === "pop-out" && t(!0), ((z = I == null ? void 0 : I.data) == null ? void 0 : z.type) === "open" && ((F = I == null ? void 0 : I.data) == null ? void 0 : F.chatState) === !0 && t(!0);
4463
+ ((b = P == null ? void 0 : P.data) == null ? void 0 : b.type) === "unhide" && ((E = P == null ? void 0 : P.data) == null ? void 0 : E.reason) === "pop-out" && t(!0), ((z = P == null ? void 0 : P.data) == null ? void 0 : z.type) === "open" && ((F = P == null ? void 0 : P.data) == null ? void 0 : F.chatState) === !0 && t(!0);
4464
4464
  },
4465
4465
  [t]
4466
4466
  );
4467
4467
  ke(() => {
4468
4468
  var E, z, F, U;
4469
- let I, b;
4469
+ let P, b;
4470
4470
  return (E = f == null ? void 0 : f.liveChat) != null && E.useOwnChat && (b = setTimeout(() => {
4471
4471
  u(!1);
4472
- }, 3e3)), (z = f == null ? void 0 : f.liveChat) != null && z.enabled && !((F = f == null ? void 0 : f.liveChat) != null && F.useOwnChat) && (window.Five9ChatPlugin || (I = document.createElement("script"), I.type = "text/javascript", I.src = (U = f == null ? void 0 : f.liveChat) == null ? void 0 : U.sourceCode, I.async = !0, I.onload = () => {
4473
- var j;
4474
- window.Five9ChatPlugin((j = f == null ? void 0 : f.liveChat) == null ? void 0 : j.options);
4475
- }, document.body.appendChild(I)), window.addEventListener("message", y), window.addEventListener("message", h), b = setTimeout(() => {
4472
+ }, 3e3)), (z = f == null ? void 0 : f.liveChat) != null && z.enabled && !((F = f == null ? void 0 : f.liveChat) != null && F.useOwnChat) && (window.Five9ChatPlugin || (P = document.createElement("script"), P.type = "text/javascript", P.src = (U = f == null ? void 0 : f.liveChat) == null ? void 0 : U.sourceCode, P.async = !0, P.onload = () => {
4473
+ var M;
4474
+ window.Five9ChatPlugin((M = f == null ? void 0 : f.liveChat) == null ? void 0 : M.options);
4475
+ }, document.body.appendChild(P)), window.addEventListener("message", y), window.addEventListener("message", h), b = setTimeout(() => {
4476
4476
  u(!1);
4477
4477
  }, 3e3)), () => {
4478
- var j;
4479
- (j = f == null ? void 0 : f.liveChat) != null && j.enabled && (window.removeEventListener("message", y), window.removeEventListener("message", h), clearTimeout(b));
4478
+ var M;
4479
+ (M = f == null ? void 0 : f.liveChat) != null && M.enabled && (window.removeEventListener("message", y), window.removeEventListener("message", h), clearTimeout(b));
4480
4480
  };
4481
4481
  }, [
4482
4482
  (g = f == null ? void 0 : f.liveChat) == null ? void 0 : g.enabled,
4483
- (P = f == null ? void 0 : f.liveChat) == null ? void 0 : P.options,
4483
+ (I = f == null ? void 0 : f.liveChat) == null ? void 0 : I.options,
4484
4484
  (A = f == null ? void 0 : f.liveChat) == null ? void 0 : A.sourceCode,
4485
4485
  (q = f == null ? void 0 : f.liveChat) == null ? void 0 : q.useOwnChat,
4486
4486
  y,
4487
4487
  h
4488
4488
  ]);
4489
4489
  const v = () => {
4490
- var I;
4490
+ var P;
4491
4491
  e({
4492
4492
  name: `${p == null ? void 0 : p.prefix}.bi.xpert.chatbot.popup.live.chat.${l}`,
4493
4493
  payload: {
@@ -4495,7 +4495,7 @@ function Ln({
4495
4495
  label: "xpert-chatbot",
4496
4496
  isTestUser: n
4497
4497
  }
4498
- }), t(!0), (I = f == null ? void 0 : f.liveChat) != null && I.useOwnChat || window.f9_postMessage({ type: "toggle" });
4498
+ }), t(!0), (P = f == null ? void 0 : f.liveChat) != null && P.useOwnChat || window.f9_postMessage({ type: "toggle" });
4499
4499
  };
4500
4500
  return /* @__PURE__ */ k.jsxs("div", { title: "Talk to a live agent at anytime.", style: i, children: [
4501
4501
  s && r && /* @__PURE__ */ k.jsxs("div", { className: "xpert-chatbot-popup__live-chat--message", children: [
@@ -5047,11 +5047,11 @@ function Jc() {
5047
5047
  return u[c];
5048
5048
  };
5049
5049
  return or = function s() {
5050
- var u, c, d, p, f, y, h = arguments[0], v = 1, g = arguments.length, P = !1;
5051
- for (typeof h == "boolean" && (P = h, h = arguments[1] || {}, v = 2), (h == null || typeof h != "object" && typeof h != "function") && (h = {}); v < g; ++v)
5050
+ var u, c, d, p, f, y, h = arguments[0], v = 1, g = arguments.length, I = !1;
5051
+ for (typeof h == "boolean" && (I = h, h = arguments[1] || {}, v = 2), (h == null || typeof h != "object" && typeof h != "function") && (h = {}); v < g; ++v)
5052
5052
  if (u = arguments[v], u != null)
5053
5053
  for (c in u)
5054
- d = l(h, c), p = l(u, c), h !== p && (P && p && (a(p) || (f = i(p))) ? (f ? (f = !1, y = d && i(d) ? d : []) : y = d && a(d) ? d : {}, o(h, { name: c, newValue: s(P, y, p) })) : typeof p < "u" && o(h, { name: c, newValue: p }));
5054
+ d = l(h, c), p = l(u, c), h !== p && (I && p && (a(p) || (f = i(p))) ? (f ? (f = !1, y = d && i(d) ? d : []) : y = d && a(d) ? d : {}, o(h, { name: c, newValue: s(I, y, p) })) : typeof p < "u" && o(h, { name: c, newValue: p }));
5055
5055
  return h;
5056
5056
  }, or;
5057
5057
  }
@@ -5150,19 +5150,19 @@ function zo() {
5150
5150
  function s(h, ...v) {
5151
5151
  let g;
5152
5152
  if (ur("use", r), h != null) if (typeof h == "function")
5153
- I(h, ...v);
5153
+ P(h, ...v);
5154
5154
  else if (typeof h == "object")
5155
5155
  Array.isArray(h) ? q(h) : A(h);
5156
5156
  else
5157
5157
  throw new TypeError("Expected usable value, not `" + h + "`");
5158
5158
  return g && (n.settings = Object.assign(n.settings || {}, g)), a;
5159
- function P(b) {
5159
+ function I(b) {
5160
5160
  if (typeof b == "function")
5161
- I(b);
5161
+ P(b);
5162
5162
  else if (typeof b == "object")
5163
5163
  if (Array.isArray(b)) {
5164
5164
  const [E, ...z] = b;
5165
- I(E, ...z);
5165
+ P(E, ...z);
5166
5166
  } else
5167
5167
  A(b);
5168
5168
  else
@@ -5176,12 +5176,12 @@ function zo() {
5176
5176
  if (b != null) if (Array.isArray(b))
5177
5177
  for (; ++E < b.length; ) {
5178
5178
  const z = b[E];
5179
- P(z);
5179
+ I(z);
5180
5180
  }
5181
5181
  else
5182
5182
  throw new TypeError("Expected a list of plugins, not `" + b + "`");
5183
5183
  }
5184
- function I(b, E) {
5184
+ function P(b, E) {
5185
5185
  let z = -1, F;
5186
5186
  for (; ++z < t.length; )
5187
5187
  if (t[z][0] === b) {
@@ -5198,43 +5198,43 @@ function zo() {
5198
5198
  }
5199
5199
  function c(h, v) {
5200
5200
  a.freeze();
5201
- const g = Wt(v), P = a.Compiler;
5202
- return sr("stringify", P), fa(h), ca(P, "compile") ? new P(h, g).compile() : P(h, g);
5201
+ const g = Wt(v), I = a.Compiler;
5202
+ return sr("stringify", I), fa(h), ca(I, "compile") ? new I(h, g).compile() : I(h, g);
5203
5203
  }
5204
5204
  function d(h, v, g) {
5205
5205
  if (fa(h), a.freeze(), !g && typeof v == "function" && (g = v, v = void 0), !g)
5206
- return new Promise(P);
5207
- P(null, g);
5208
- function P(A, q) {
5209
- e.run(h, Wt(v), I);
5210
- function I(b, E, z) {
5206
+ return new Promise(I);
5207
+ I(null, g);
5208
+ function I(A, q) {
5209
+ e.run(h, Wt(v), P);
5210
+ function P(b, E, z) {
5211
5211
  E = E || h, b ? q(b) : A ? A(E) : g(null, E, z);
5212
5212
  }
5213
5213
  }
5214
5214
  }
5215
5215
  function p(h, v) {
5216
- let g, P;
5217
- return a.run(h, v, A), da("runSync", "run", P), g;
5218
- function A(q, I) {
5219
- la(q), g = I, P = !0;
5216
+ let g, I;
5217
+ return a.run(h, v, A), da("runSync", "run", I), g;
5218
+ function A(q, P) {
5219
+ la(q), g = P, I = !0;
5220
5220
  }
5221
5221
  }
5222
5222
  function f(h, v) {
5223
5223
  if (a.freeze(), lr("process", a.Parser), sr("process", a.Compiler), !v)
5224
5224
  return new Promise(g);
5225
5225
  g(null, v);
5226
- function g(P, A) {
5226
+ function g(I, A) {
5227
5227
  const q = Wt(h);
5228
5228
  a.run(a.parse(q), q, (b, E, z) => {
5229
5229
  if (b || !E || !z)
5230
- I(b);
5230
+ P(b);
5231
5231
  else {
5232
5232
  const F = a.stringify(E, z);
5233
- F == null || (of(F) ? z.value = F : z.result = F), I(b, z);
5233
+ F == null || (of(F) ? z.value = F : z.result = F), P(b, z);
5234
5234
  }
5235
5235
  });
5236
- function I(b, E) {
5237
- b || !E ? A(b) : P ? P(E) : v(null, E);
5236
+ function P(b, E) {
5237
+ b || !E ? A(b) : I ? I(E) : v(null, E);
5238
5238
  }
5239
5239
  }
5240
5240
  }
@@ -5242,8 +5242,8 @@ function zo() {
5242
5242
  let v;
5243
5243
  a.freeze(), lr("processSync", a.Parser), sr("processSync", a.Compiler);
5244
5244
  const g = Wt(h);
5245
- return a.process(g, P), da("processSync", "process", v), g;
5246
- function P(A) {
5245
+ return a.process(g, I), da("processSync", "process", v), g;
5246
+ function I(A) {
5247
5247
  v = !0, la(A);
5248
5248
  }
5249
5249
  }
@@ -5461,12 +5461,12 @@ function Cf(e) {
5461
5461
  }
5462
5462
  function s(A) {
5463
5463
  if (r++, t.containerState._closeFlow) {
5464
- t.containerState._closeFlow = void 0, i && P();
5464
+ t.containerState._closeFlow = void 0, i && I();
5465
5465
  const q = t.events.length;
5466
- let I = q, b;
5467
- for (; I--; )
5468
- if (t.events[I][0] === "exit" && t.events[I][1].type === "chunkFlow") {
5469
- b = t.events[I][1].end;
5466
+ let P = q, b;
5467
+ for (; P--; )
5468
+ if (t.events[P][0] === "exit" && t.events[P][1].type === "chunkFlow") {
5469
+ b = t.events[P][1].end;
5470
5470
  break;
5471
5471
  }
5472
5472
  g(r);
@@ -5475,7 +5475,7 @@ function Cf(e) {
5475
5475
  t.events[E][1].end = Object.assign({}, b), E++;
5476
5476
  return tt(
5477
5477
  t.events,
5478
- I + 1,
5478
+ P + 1,
5479
5479
  0,
5480
5480
  t.events.slice(q)
5481
5481
  ), t.events.length = E, u(A);
@@ -5497,7 +5497,7 @@ function Cf(e) {
5497
5497
  )(A);
5498
5498
  }
5499
5499
  function c(A) {
5500
- return i && P(), g(r), p(A);
5500
+ return i && I(), g(r), p(A);
5501
5501
  }
5502
5502
  function d(A) {
5503
5503
  return t.parser.lazy[t.now().line] = r !== n.length, o = t.now().offset, y(A);
@@ -5514,7 +5514,7 @@ function Cf(e) {
5514
5514
  }
5515
5515
  function y(A) {
5516
5516
  if (A === null) {
5517
- i && P(), g(0), e.consume(A);
5517
+ i && I(), g(0), e.consume(A);
5518
5518
  return;
5519
5519
  }
5520
5520
  return i = i || t.parser.flow(t.now()), e.enter("chunkFlow", {
@@ -5531,8 +5531,8 @@ function Cf(e) {
5531
5531
  return J(A) ? (e.consume(A), v(e.exit("chunkFlow")), r = 0, t.interrupt = void 0, l) : (e.consume(A), h);
5532
5532
  }
5533
5533
  function v(A, q) {
5534
- const I = t.sliceStream(A);
5535
- if (q && I.push(null), A.previous = a, a && (a.next = A), a = A, i.defineSkip(A.start), i.write(I), t.parser.lazy[A.start.line]) {
5534
+ const P = t.sliceStream(A);
5535
+ if (q && P.push(null), A.previous = a, a && (a.next = A), a = A, i.defineSkip(A.start), i.write(P), t.parser.lazy[A.start.line]) {
5536
5536
  let b = i.events.length;
5537
5537
  for (; b--; )
5538
5538
  if (
@@ -5565,12 +5565,12 @@ function Cf(e) {
5565
5565
  function g(A) {
5566
5566
  let q = n.length;
5567
5567
  for (; q-- > A; ) {
5568
- const I = n[q];
5569
- t.containerState = I[1], I[0].exit.call(t, e);
5568
+ const P = n[q];
5569
+ t.containerState = P[1], P[0].exit.call(t, e);
5570
5570
  }
5571
5571
  n.length = A;
5572
5572
  }
5573
- function P() {
5573
+ function I() {
5574
5574
  i.write([null]), a = void 0, i = void 0, t.containerState._closeFlow = void 0;
5575
5575
  }
5576
5576
  }
@@ -5731,13 +5731,13 @@ function Of(e, t, n) {
5731
5731
  }
5732
5732
  const Uo = {
5733
5733
  name: "blockQuote",
5734
- tokenize: If,
5734
+ tokenize: Pf,
5735
5735
  continuation: {
5736
- tokenize: Pf
5736
+ tokenize: If
5737
5737
  },
5738
5738
  exit: Af
5739
5739
  };
5740
- function If(e, t, n) {
5740
+ function Pf(e, t, n) {
5741
5741
  const r = this;
5742
5742
  return i;
5743
5743
  function i(o) {
@@ -5753,7 +5753,7 @@ function If(e, t, n) {
5753
5753
  return ue(o) ? (e.enter("blockQuotePrefixWhitespace"), e.consume(o), e.exit("blockQuotePrefixWhitespace"), e.exit("blockQuotePrefix"), t) : (e.exit("blockQuotePrefix"), t(o));
5754
5754
  }
5755
5755
  }
5756
- function Pf(e, t, n) {
5756
+ function If(e, t, n) {
5757
5757
  const r = this;
5758
5758
  return i;
5759
5759
  function i(o) {
@@ -5830,7 +5830,7 @@ const va = {
5830
5830
  };
5831
5831
  function Lf(e, t, n) {
5832
5832
  const r = this, i = {
5833
- tokenize: I,
5833
+ tokenize: P,
5834
5834
  partial: !0
5835
5835
  };
5836
5836
  let a = 0, o = 0, l;
@@ -5870,35 +5870,35 @@ function Lf(e, t, n) {
5870
5870
  function g(b) {
5871
5871
  return a > 0 && ue(b) ? ye(
5872
5872
  e,
5873
- P,
5873
+ I,
5874
5874
  "linePrefix",
5875
5875
  a + 1
5876
- )(b) : P(b);
5876
+ )(b) : I(b);
5877
5877
  }
5878
- function P(b) {
5878
+ function I(b) {
5879
5879
  return b === null || J(b) ? e.check(va, h, q)(b) : (e.enter("codeFlowValue"), A(b));
5880
5880
  }
5881
5881
  function A(b) {
5882
- return b === null || J(b) ? (e.exit("codeFlowValue"), P(b)) : (e.consume(b), A);
5882
+ return b === null || J(b) ? (e.exit("codeFlowValue"), I(b)) : (e.consume(b), A);
5883
5883
  }
5884
5884
  function q(b) {
5885
5885
  return e.exit("codeFenced"), t(b);
5886
5886
  }
5887
- function I(b, E, z) {
5887
+ function P(b, E, z) {
5888
5888
  let F = 0;
5889
5889
  return U;
5890
5890
  function U(O) {
5891
- return b.enter("lineEnding"), b.consume(O), b.exit("lineEnding"), j;
5891
+ return b.enter("lineEnding"), b.consume(O), b.exit("lineEnding"), M;
5892
5892
  }
5893
- function j(O) {
5893
+ function M(O) {
5894
5894
  return b.enter("codeFencedFence"), ue(O) ? ye(
5895
5895
  b,
5896
- H,
5896
+ B,
5897
5897
  "linePrefix",
5898
5898
  r.parser.constructs.disable.null.includes("codeIndented") ? void 0 : 4
5899
- )(O) : H(O);
5899
+ )(O) : B(O);
5900
5900
  }
5901
- function H(O) {
5901
+ function B(O) {
5902
5902
  return O === l ? (b.enter("codeFencedFenceSequence"), T(O)) : z(O);
5903
5903
  }
5904
5904
  function T(O) {
@@ -6032,8 +6032,8 @@ function Uf(e, t) {
6032
6032
  // Find a void token that includes a break.
6033
6033
  l[p][0] === "exit" && l[p - 1][0] === "enter" && l[p][1].type === l[p - 1][1].type && l[p][1].start.line !== l[p][1].end.line && (h = p + 1, v.push(h), f._tokenizer = void 0, f.previous = void 0, f = f.next);
6034
6034
  for (o.events = [], f ? (f._tokenizer = void 0, f.previous = void 0) : v.pop(), p = v.length; p--; ) {
6035
- const g = l.slice(v[p], v[p + 1]), P = a.pop();
6036
- s.unshift([P, P + g.length - 1]), tt(e, P, 2, g);
6035
+ const g = l.slice(v[p], v[p + 1]), I = a.pop();
6036
+ s.unshift([I, I + g.length - 1]), tt(e, I, 2, g);
6037
6037
  }
6038
6038
  for (p = -1; ++p < s.length; )
6039
6039
  u[y + s[p][0]] = y + s[p][1], y += s[p][1] - s[p][0] - 1;
@@ -6411,33 +6411,33 @@ function ud(e, t, n) {
6411
6411
  return w === 45 ? (e.consume(w), r.interrupt ? t : m) : n(w);
6412
6412
  }
6413
6413
  function y(w) {
6414
- const Y = "CDATA[";
6415
- return w === Y.charCodeAt(l++) ? (e.consume(w), l === Y.length ? r.interrupt ? t : H : y) : n(w);
6414
+ const K = "CDATA[";
6415
+ return w === K.charCodeAt(l++) ? (e.consume(w), l === K.length ? r.interrupt ? t : B : y) : n(w);
6416
6416
  }
6417
6417
  function h(w) {
6418
6418
  return Qe(w) ? (e.consume(w), o = String.fromCharCode(w), v) : n(w);
6419
6419
  }
6420
6420
  function v(w) {
6421
6421
  if (w === null || w === 47 || w === 62 || Ae(w)) {
6422
- const Y = w === 47, oe = o.toLowerCase();
6423
- return !Y && !a && wa.includes(oe) ? (i = 1, r.interrupt ? t(w) : H(w)) : id.includes(o.toLowerCase()) ? (i = 6, Y ? (e.consume(w), g) : r.interrupt ? t(w) : H(w)) : (i = 7, r.interrupt && !r.parser.lazy[r.now().line] ? n(w) : a ? P(w) : A(w));
6422
+ const K = w === 47, oe = o.toLowerCase();
6423
+ return !K && !a && wa.includes(oe) ? (i = 1, r.interrupt ? t(w) : B(w)) : id.includes(o.toLowerCase()) ? (i = 6, K ? (e.consume(w), g) : r.interrupt ? t(w) : B(w)) : (i = 7, r.interrupt && !r.parser.lazy[r.now().line] ? n(w) : a ? I(w) : A(w));
6424
6424
  }
6425
6425
  return w === 45 || Be(w) ? (e.consume(w), o += String.fromCharCode(w), v) : n(w);
6426
6426
  }
6427
6427
  function g(w) {
6428
- return w === 62 ? (e.consume(w), r.interrupt ? t : H) : n(w);
6428
+ return w === 62 ? (e.consume(w), r.interrupt ? t : B) : n(w);
6429
6429
  }
6430
- function P(w) {
6431
- return ue(w) ? (e.consume(w), P) : U(w);
6430
+ function I(w) {
6431
+ return ue(w) ? (e.consume(w), I) : U(w);
6432
6432
  }
6433
6433
  function A(w) {
6434
6434
  return w === 47 ? (e.consume(w), U) : w === 58 || w === 95 || Qe(w) ? (e.consume(w), q) : ue(w) ? (e.consume(w), A) : U(w);
6435
6435
  }
6436
6436
  function q(w) {
6437
- return w === 45 || w === 46 || w === 58 || w === 95 || Be(w) ? (e.consume(w), q) : I(w);
6437
+ return w === 45 || w === 46 || w === 58 || w === 95 || Be(w) ? (e.consume(w), q) : P(w);
6438
6438
  }
6439
- function I(w) {
6440
- return w === 61 ? (e.consume(w), b) : ue(w) ? (e.consume(w), I) : A(w);
6439
+ function P(w) {
6440
+ return w === 61 ? (e.consume(w), b) : ue(w) ? (e.consume(w), P) : A(w);
6441
6441
  }
6442
6442
  function b(w) {
6443
6443
  return w === null || w === 60 || w === 61 || w === 62 || w === 96 ? n(w) : w === 34 || w === 39 ? (e.consume(w), s = w, E) : ue(w) ? (e.consume(w), b) : z(w);
@@ -6446,60 +6446,60 @@ function ud(e, t, n) {
6446
6446
  return w === s ? (e.consume(w), s = null, F) : w === null || J(w) ? n(w) : (e.consume(w), E);
6447
6447
  }
6448
6448
  function z(w) {
6449
- return w === null || w === 34 || w === 39 || w === 47 || w === 60 || w === 61 || w === 62 || w === 96 || Ae(w) ? I(w) : (e.consume(w), z);
6449
+ return w === null || w === 34 || w === 39 || w === 47 || w === 60 || w === 61 || w === 62 || w === 96 || Ae(w) ? P(w) : (e.consume(w), z);
6450
6450
  }
6451
6451
  function F(w) {
6452
6452
  return w === 47 || w === 62 || ue(w) ? A(w) : n(w);
6453
6453
  }
6454
6454
  function U(w) {
6455
- return w === 62 ? (e.consume(w), j) : n(w);
6455
+ return w === 62 ? (e.consume(w), M) : n(w);
6456
6456
  }
6457
- function j(w) {
6458
- return w === null || J(w) ? H(w) : ue(w) ? (e.consume(w), j) : n(w);
6457
+ function M(w) {
6458
+ return w === null || J(w) ? B(w) : ue(w) ? (e.consume(w), M) : n(w);
6459
6459
  }
6460
- function H(w) {
6461
- return w === 45 && i === 2 ? (e.consume(w), N) : w === 60 && i === 1 ? (e.consume(w), M) : w === 62 && i === 4 ? (e.consume(w), W) : w === 63 && i === 3 ? (e.consume(w), m) : w === 93 && i === 5 ? (e.consume(w), B) : J(w) && (i === 6 || i === 7) ? (e.exit("htmlFlowData"), e.check(
6460
+ function B(w) {
6461
+ return w === 45 && i === 2 ? (e.consume(w), N) : w === 60 && i === 1 ? (e.consume(w), H) : w === 62 && i === 4 ? (e.consume(w), W) : w === 63 && i === 3 ? (e.consume(w), m) : w === 93 && i === 5 ? (e.consume(w), D) : J(w) && (i === 6 || i === 7) ? (e.exit("htmlFlowData"), e.check(
6462
6462
  od,
6463
- K,
6463
+ Y,
6464
6464
  T
6465
- )(w)) : w === null || J(w) ? (e.exit("htmlFlowData"), T(w)) : (e.consume(w), H);
6465
+ )(w)) : w === null || J(w) ? (e.exit("htmlFlowData"), T(w)) : (e.consume(w), B);
6466
6466
  }
6467
6467
  function T(w) {
6468
6468
  return e.check(
6469
6469
  ld,
6470
6470
  S,
6471
- K
6471
+ Y
6472
6472
  )(w);
6473
6473
  }
6474
6474
  function S(w) {
6475
6475
  return e.enter("lineEnding"), e.consume(w), e.exit("lineEnding"), O;
6476
6476
  }
6477
6477
  function O(w) {
6478
- return w === null || J(w) ? T(w) : (e.enter("htmlFlowData"), H(w));
6478
+ return w === null || J(w) ? T(w) : (e.enter("htmlFlowData"), B(w));
6479
6479
  }
6480
6480
  function N(w) {
6481
- return w === 45 ? (e.consume(w), m) : H(w);
6481
+ return w === 45 ? (e.consume(w), m) : B(w);
6482
6482
  }
6483
- function M(w) {
6484
- return w === 47 ? (e.consume(w), o = "", D) : H(w);
6483
+ function H(w) {
6484
+ return w === 47 ? (e.consume(w), o = "", j) : B(w);
6485
6485
  }
6486
- function D(w) {
6486
+ function j(w) {
6487
6487
  if (w === 62) {
6488
- const Y = o.toLowerCase();
6489
- return wa.includes(Y) ? (e.consume(w), W) : H(w);
6488
+ const K = o.toLowerCase();
6489
+ return wa.includes(K) ? (e.consume(w), W) : B(w);
6490
6490
  }
6491
- return Qe(w) && o.length < 8 ? (e.consume(w), o += String.fromCharCode(w), D) : H(w);
6491
+ return Qe(w) && o.length < 8 ? (e.consume(w), o += String.fromCharCode(w), j) : B(w);
6492
6492
  }
6493
- function B(w) {
6494
- return w === 93 ? (e.consume(w), m) : H(w);
6493
+ function D(w) {
6494
+ return w === 93 ? (e.consume(w), m) : B(w);
6495
6495
  }
6496
6496
  function m(w) {
6497
- return w === 62 ? (e.consume(w), W) : w === 45 && i === 2 ? (e.consume(w), m) : H(w);
6497
+ return w === 62 ? (e.consume(w), W) : w === 45 && i === 2 ? (e.consume(w), m) : B(w);
6498
6498
  }
6499
6499
  function W(w) {
6500
- return w === null || J(w) ? (e.exit("htmlFlowData"), K(w)) : (e.consume(w), W);
6500
+ return w === null || J(w) ? (e.exit("htmlFlowData"), Y(w)) : (e.consume(w), W);
6501
6501
  }
6502
- function K(w) {
6502
+ function Y(w) {
6503
6503
  return e.exit("htmlFlow"), t(w);
6504
6504
  }
6505
6505
  }
@@ -6531,16 +6531,16 @@ function pd(e, t, n) {
6531
6531
  return e.enter("htmlText"), e.enter("htmlTextData"), e.consume(m), s;
6532
6532
  }
6533
6533
  function s(m) {
6534
- return m === 33 ? (e.consume(m), u) : m === 47 ? (e.consume(m), I) : m === 63 ? (e.consume(m), A) : Qe(m) ? (e.consume(m), z) : n(m);
6534
+ return m === 33 ? (e.consume(m), u) : m === 47 ? (e.consume(m), P) : m === 63 ? (e.consume(m), A) : Qe(m) ? (e.consume(m), z) : n(m);
6535
6535
  }
6536
6536
  function u(m) {
6537
- return m === 45 ? (e.consume(m), c) : m === 91 ? (e.consume(m), a = 0, y) : Qe(m) ? (e.consume(m), P) : n(m);
6537
+ return m === 45 ? (e.consume(m), c) : m === 91 ? (e.consume(m), a = 0, y) : Qe(m) ? (e.consume(m), I) : n(m);
6538
6538
  }
6539
6539
  function c(m) {
6540
6540
  return m === 45 ? (e.consume(m), f) : n(m);
6541
6541
  }
6542
6542
  function d(m) {
6543
- return m === null ? n(m) : m === 45 ? (e.consume(m), p) : J(m) ? (o = d, M(m)) : (e.consume(m), d);
6543
+ return m === null ? n(m) : m === 45 ? (e.consume(m), p) : J(m) ? (o = d, H(m)) : (e.consume(m), d);
6544
6544
  }
6545
6545
  function p(m) {
6546
6546
  return m === 45 ? (e.consume(m), f) : d(m);
@@ -6553,7 +6553,7 @@ function pd(e, t, n) {
6553
6553
  return m === W.charCodeAt(a++) ? (e.consume(m), a === W.length ? h : y) : n(m);
6554
6554
  }
6555
6555
  function h(m) {
6556
- return m === null ? n(m) : m === 93 ? (e.consume(m), v) : J(m) ? (o = h, M(m)) : (e.consume(m), h);
6556
+ return m === null ? n(m) : m === 93 ? (e.consume(m), v) : J(m) ? (o = h, H(m)) : (e.consume(m), h);
6557
6557
  }
6558
6558
  function v(m) {
6559
6559
  return m === 93 ? (e.consume(m), g) : h(m);
@@ -6561,41 +6561,41 @@ function pd(e, t, n) {
6561
6561
  function g(m) {
6562
6562
  return m === 62 ? N(m) : m === 93 ? (e.consume(m), g) : h(m);
6563
6563
  }
6564
- function P(m) {
6565
- return m === null || m === 62 ? N(m) : J(m) ? (o = P, M(m)) : (e.consume(m), P);
6564
+ function I(m) {
6565
+ return m === null || m === 62 ? N(m) : J(m) ? (o = I, H(m)) : (e.consume(m), I);
6566
6566
  }
6567
6567
  function A(m) {
6568
- return m === null ? n(m) : m === 63 ? (e.consume(m), q) : J(m) ? (o = A, M(m)) : (e.consume(m), A);
6568
+ return m === null ? n(m) : m === 63 ? (e.consume(m), q) : J(m) ? (o = A, H(m)) : (e.consume(m), A);
6569
6569
  }
6570
6570
  function q(m) {
6571
6571
  return m === 62 ? N(m) : A(m);
6572
6572
  }
6573
- function I(m) {
6573
+ function P(m) {
6574
6574
  return Qe(m) ? (e.consume(m), b) : n(m);
6575
6575
  }
6576
6576
  function b(m) {
6577
6577
  return m === 45 || Be(m) ? (e.consume(m), b) : E(m);
6578
6578
  }
6579
6579
  function E(m) {
6580
- return J(m) ? (o = E, M(m)) : ue(m) ? (e.consume(m), E) : N(m);
6580
+ return J(m) ? (o = E, H(m)) : ue(m) ? (e.consume(m), E) : N(m);
6581
6581
  }
6582
6582
  function z(m) {
6583
6583
  return m === 45 || Be(m) ? (e.consume(m), z) : m === 47 || m === 62 || Ae(m) ? F(m) : n(m);
6584
6584
  }
6585
6585
  function F(m) {
6586
- return m === 47 ? (e.consume(m), N) : m === 58 || m === 95 || Qe(m) ? (e.consume(m), U) : J(m) ? (o = F, M(m)) : ue(m) ? (e.consume(m), F) : N(m);
6586
+ return m === 47 ? (e.consume(m), N) : m === 58 || m === 95 || Qe(m) ? (e.consume(m), U) : J(m) ? (o = F, H(m)) : ue(m) ? (e.consume(m), F) : N(m);
6587
6587
  }
6588
6588
  function U(m) {
6589
- return m === 45 || m === 46 || m === 58 || m === 95 || Be(m) ? (e.consume(m), U) : j(m);
6589
+ return m === 45 || m === 46 || m === 58 || m === 95 || Be(m) ? (e.consume(m), U) : M(m);
6590
6590
  }
6591
- function j(m) {
6592
- return m === 61 ? (e.consume(m), H) : J(m) ? (o = j, M(m)) : ue(m) ? (e.consume(m), j) : F(m);
6591
+ function M(m) {
6592
+ return m === 61 ? (e.consume(m), B) : J(m) ? (o = M, H(m)) : ue(m) ? (e.consume(m), M) : F(m);
6593
6593
  }
6594
- function H(m) {
6595
- return m === null || m === 60 || m === 61 || m === 62 || m === 96 ? n(m) : m === 34 || m === 39 ? (e.consume(m), i = m, T) : J(m) ? (o = H, M(m)) : ue(m) ? (e.consume(m), H) : (e.consume(m), S);
6594
+ function B(m) {
6595
+ return m === null || m === 60 || m === 61 || m === 62 || m === 96 ? n(m) : m === 34 || m === 39 ? (e.consume(m), i = m, T) : J(m) ? (o = B, H(m)) : ue(m) ? (e.consume(m), B) : (e.consume(m), S);
6596
6596
  }
6597
6597
  function T(m) {
6598
- return m === i ? (e.consume(m), i = void 0, O) : m === null ? n(m) : J(m) ? (o = T, M(m)) : (e.consume(m), T);
6598
+ return m === i ? (e.consume(m), i = void 0, O) : m === null ? n(m) : J(m) ? (o = T, H(m)) : (e.consume(m), T);
6599
6599
  }
6600
6600
  function S(m) {
6601
6601
  return m === null || m === 34 || m === 39 || m === 60 || m === 61 || m === 96 ? n(m) : m === 47 || m === 62 || Ae(m) ? F(m) : (e.consume(m), S);
@@ -6606,18 +6606,18 @@ function pd(e, t, n) {
6606
6606
  function N(m) {
6607
6607
  return m === 62 ? (e.consume(m), e.exit("htmlTextData"), e.exit("htmlText"), t) : n(m);
6608
6608
  }
6609
- function M(m) {
6610
- return e.exit("htmlTextData"), e.enter("lineEnding"), e.consume(m), e.exit("lineEnding"), D;
6609
+ function H(m) {
6610
+ return e.exit("htmlTextData"), e.enter("lineEnding"), e.consume(m), e.exit("lineEnding"), j;
6611
6611
  }
6612
- function D(m) {
6612
+ function j(m) {
6613
6613
  return ue(m) ? ye(
6614
6614
  e,
6615
- B,
6615
+ D,
6616
6616
  "linePrefix",
6617
6617
  r.parser.constructs.disable.null.includes("codeIndented") ? void 0 : 4
6618
- )(m) : B(m);
6618
+ )(m) : D(m);
6619
6619
  }
6620
- function B(m) {
6620
+ function D(m) {
6621
6621
  return e.enter("htmlTextData"), o(m);
6622
6622
  }
6623
6623
  }
@@ -6869,17 +6869,17 @@ function Od(e, t, n) {
6869
6869
  return u === i ? (e.consume(u), r++, s) : (e.exit("thematicBreakSequence"), ue(u) ? ye(e, l, "whitespace")(u) : l(u));
6870
6870
  }
6871
6871
  }
6872
- const Pe = {
6872
+ const Ie = {
6873
6873
  name: "list",
6874
6874
  tokenize: Ad,
6875
6875
  continuation: {
6876
6876
  tokenize: Fd
6877
6877
  },
6878
6878
  exit: Ld
6879
- }, Id = {
6879
+ }, Pd = {
6880
6880
  tokenize: jd,
6881
6881
  partial: !0
6882
- }, Pd = {
6882
+ }, Id = {
6883
6883
  tokenize: Nd,
6884
6884
  partial: !0
6885
6885
  };
@@ -6908,7 +6908,7 @@ function Ad(e, t, n) {
6908
6908
  // Can’t be empty when interrupting.
6909
6909
  r.interrupt ? n : c,
6910
6910
  e.attempt(
6911
- Id,
6911
+ Pd,
6912
6912
  p,
6913
6913
  d
6914
6914
  )
@@ -6936,12 +6936,12 @@ function Fd(e, t, n) {
6936
6936
  )(l);
6937
6937
  }
6938
6938
  function a(l) {
6939
- return r.containerState.furtherBlankLines || !ue(l) ? (r.containerState.furtherBlankLines = void 0, r.containerState.initialBlankLine = void 0, o(l)) : (r.containerState.furtherBlankLines = void 0, r.containerState.initialBlankLine = void 0, e.attempt(Pd, t, o)(l));
6939
+ return r.containerState.furtherBlankLines || !ue(l) ? (r.containerState.furtherBlankLines = void 0, r.containerState.initialBlankLine = void 0, o(l)) : (r.containerState.furtherBlankLines = void 0, r.containerState.initialBlankLine = void 0, e.attempt(Id, t, o)(l));
6940
6940
  }
6941
6941
  function o(l) {
6942
6942
  return r.containerState._closeFlow = !0, r.interrupt = void 0, ye(
6943
6943
  e,
6944
- e.attempt(Pe, t, n),
6944
+ e.attempt(Ie, t, n),
6945
6945
  "linePrefix",
6946
6946
  r.parser.constructs.disable.null.includes("codeIndented") ? void 0 : 4
6947
6947
  )(l);
@@ -7169,10 +7169,10 @@ function $d(e, t, n) {
7169
7169
  const i = {}, a = [];
7170
7170
  let o = [], l = [];
7171
7171
  const s = {
7172
- consume: P,
7172
+ consume: I,
7173
7173
  enter: A,
7174
7174
  exit: q,
7175
- attempt: E(I),
7175
+ attempt: E(P),
7176
7176
  check: E(b),
7177
7177
  interrupt: E(b, {
7178
7178
  interrupt: !0
@@ -7191,66 +7191,66 @@ function $d(e, t, n) {
7191
7191
  };
7192
7192
  let c = t.tokenize.call(u, s);
7193
7193
  return t.resolveAll && a.push(t), u;
7194
- function d(j) {
7195
- return o = He(o, j), v(), o[o.length - 1] !== null ? [] : (z(t, 0), u.events = Zr(a, u.events, u), u.events);
7194
+ function d(M) {
7195
+ return o = He(o, M), v(), o[o.length - 1] !== null ? [] : (z(t, 0), u.events = Zr(a, u.events, u), u.events);
7196
7196
  }
7197
- function p(j, H) {
7198
- return Wd(f(j), H);
7197
+ function p(M, B) {
7198
+ return Wd(f(M), B);
7199
7199
  }
7200
- function f(j) {
7201
- return Vd(o, j);
7200
+ function f(M) {
7201
+ return Vd(o, M);
7202
7202
  }
7203
7203
  function y() {
7204
- const { line: j, column: H, offset: T, _index: S, _bufferIndex: O } = r;
7204
+ const { line: M, column: B, offset: T, _index: S, _bufferIndex: O } = r;
7205
7205
  return {
7206
- line: j,
7207
- column: H,
7206
+ line: M,
7207
+ column: B,
7208
7208
  offset: T,
7209
7209
  _index: S,
7210
7210
  _bufferIndex: O
7211
7211
  };
7212
7212
  }
7213
- function h(j) {
7214
- i[j.line] = j.column, U();
7213
+ function h(M) {
7214
+ i[M.line] = M.column, U();
7215
7215
  }
7216
7216
  function v() {
7217
- let j;
7217
+ let M;
7218
7218
  for (; r._index < o.length; ) {
7219
- const H = o[r._index];
7220
- if (typeof H == "string")
7221
- for (j = r._index, r._bufferIndex < 0 && (r._bufferIndex = 0); r._index === j && r._bufferIndex < H.length; )
7222
- g(H.charCodeAt(r._bufferIndex));
7219
+ const B = o[r._index];
7220
+ if (typeof B == "string")
7221
+ for (M = r._index, r._bufferIndex < 0 && (r._bufferIndex = 0); r._index === M && r._bufferIndex < B.length; )
7222
+ g(B.charCodeAt(r._bufferIndex));
7223
7223
  else
7224
- g(H);
7224
+ g(B);
7225
7225
  }
7226
7226
  }
7227
- function g(j) {
7228
- c = c(j);
7227
+ function g(M) {
7228
+ c = c(M);
7229
7229
  }
7230
- function P(j) {
7231
- J(j) ? (r.line++, r.column = 1, r.offset += j === -3 ? 2 : 1, U()) : j !== -1 && (r.column++, r.offset++), r._bufferIndex < 0 ? r._index++ : (r._bufferIndex++, r._bufferIndex === o[r._index].length && (r._bufferIndex = -1, r._index++)), u.previous = j;
7230
+ function I(M) {
7231
+ J(M) ? (r.line++, r.column = 1, r.offset += M === -3 ? 2 : 1, U()) : M !== -1 && (r.column++, r.offset++), r._bufferIndex < 0 ? r._index++ : (r._bufferIndex++, r._bufferIndex === o[r._index].length && (r._bufferIndex = -1, r._index++)), u.previous = M;
7232
7232
  }
7233
- function A(j, H) {
7234
- const T = H || {};
7235
- return T.type = j, T.start = y(), u.events.push(["enter", T, u]), l.push(T), T;
7233
+ function A(M, B) {
7234
+ const T = B || {};
7235
+ return T.type = M, T.start = y(), u.events.push(["enter", T, u]), l.push(T), T;
7236
7236
  }
7237
- function q(j) {
7238
- const H = l.pop();
7239
- return H.end = y(), u.events.push(["exit", H, u]), H;
7237
+ function q(M) {
7238
+ const B = l.pop();
7239
+ return B.end = y(), u.events.push(["exit", B, u]), B;
7240
7240
  }
7241
- function I(j, H) {
7242
- z(j, H.from);
7241
+ function P(M, B) {
7242
+ z(M, B.from);
7243
7243
  }
7244
- function b(j, H) {
7245
- H.restore();
7244
+ function b(M, B) {
7245
+ B.restore();
7246
7246
  }
7247
- function E(j, H) {
7247
+ function E(M, B) {
7248
7248
  return T;
7249
7249
  function T(S, O, N) {
7250
- let M, D, B, m;
7251
- return Array.isArray(S) ? K(S) : "tokenize" in S ? (
7250
+ let H, j, D, m;
7251
+ return Array.isArray(S) ? Y(S) : "tokenize" in S ? (
7252
7252
  // @ts-expect-error Looks like a construct.
7253
- K([S])
7253
+ Y([S])
7254
7254
  ) : W(S);
7255
7255
  function W(ne) {
7256
7256
  return de;
@@ -7261,50 +7261,50 @@ function $d(e, t, n) {
7261
7261
  ...Array.isArray(xe) ? xe : xe ? [xe] : [],
7262
7262
  ...Array.isArray(he) ? he : he ? [he] : []
7263
7263
  ];
7264
- return K(Te)(pe);
7264
+ return Y(Te)(pe);
7265
7265
  }
7266
7266
  }
7267
- function K(ne) {
7268
- return M = ne, D = 0, ne.length === 0 ? N : w(ne[D]);
7267
+ function Y(ne) {
7268
+ return H = ne, j = 0, ne.length === 0 ? N : w(ne[j]);
7269
7269
  }
7270
7270
  function w(ne) {
7271
7271
  return de;
7272
7272
  function de(pe) {
7273
- return m = F(), B = ne, ne.partial || (u.currentConstruct = ne), ne.name && u.parser.constructs.disable.null.includes(ne.name) ? oe() : ne.tokenize.call(
7273
+ return m = F(), D = ne, ne.partial || (u.currentConstruct = ne), ne.name && u.parser.constructs.disable.null.includes(ne.name) ? oe() : ne.tokenize.call(
7274
7274
  // If we do have fields, create an object w/ `context` as its
7275
7275
  // prototype.
7276
7276
  // This allows a “live binding”, which is needed for `interrupt`.
7277
- H ? Object.assign(Object.create(u), H) : u,
7277
+ B ? Object.assign(Object.create(u), B) : u,
7278
7278
  s,
7279
- Y,
7279
+ K,
7280
7280
  oe
7281
7281
  )(pe);
7282
7282
  }
7283
7283
  }
7284
- function Y(ne) {
7285
- return j(B, m), O;
7284
+ function K(ne) {
7285
+ return M(D, m), O;
7286
7286
  }
7287
7287
  function oe(ne) {
7288
- return m.restore(), ++D < M.length ? w(M[D]) : N;
7288
+ return m.restore(), ++j < H.length ? w(H[j]) : N;
7289
7289
  }
7290
7290
  }
7291
7291
  }
7292
- function z(j, H) {
7293
- j.resolveAll && !a.includes(j) && a.push(j), j.resolve && tt(
7292
+ function z(M, B) {
7293
+ M.resolveAll && !a.includes(M) && a.push(M), M.resolve && tt(
7294
7294
  u.events,
7295
- H,
7296
- u.events.length - H,
7297
- j.resolve(u.events.slice(H), u)
7298
- ), j.resolveTo && (u.events = j.resolveTo(u.events, u));
7295
+ B,
7296
+ u.events.length - B,
7297
+ M.resolve(u.events.slice(B), u)
7298
+ ), M.resolveTo && (u.events = M.resolveTo(u.events, u));
7299
7299
  }
7300
7300
  function F() {
7301
- const j = y(), H = u.previous, T = u.currentConstruct, S = u.events.length, O = Array.from(l);
7301
+ const M = y(), B = u.previous, T = u.currentConstruct, S = u.events.length, O = Array.from(l);
7302
7302
  return {
7303
7303
  restore: N,
7304
7304
  from: S
7305
7305
  };
7306
7306
  function N() {
7307
- r = j, u.previous = H, u.currentConstruct = T, u.events.length = S, l = O, U();
7307
+ r = M, u.previous = B, u.currentConstruct = T, u.events.length = S, l = O, U();
7308
7308
  }
7309
7309
  }
7310
7310
  function U() {
@@ -7367,19 +7367,19 @@ function Wd(e, t) {
7367
7367
  return r.join("");
7368
7368
  }
7369
7369
  const Gd = {
7370
- 42: Pe,
7371
- 43: Pe,
7372
- 45: Pe,
7373
- 48: Pe,
7374
- 49: Pe,
7375
- 50: Pe,
7376
- 51: Pe,
7377
- 52: Pe,
7378
- 53: Pe,
7379
- 54: Pe,
7380
- 55: Pe,
7381
- 56: Pe,
7382
- 57: Pe,
7370
+ 42: Ie,
7371
+ 43: Ie,
7372
+ 45: Ie,
7373
+ 48: Ie,
7374
+ 49: Ie,
7375
+ 50: Ie,
7376
+ 51: Ie,
7377
+ 52: Ie,
7378
+ 53: Ie,
7379
+ 54: Ie,
7380
+ 55: Ie,
7381
+ 56: Ie,
7382
+ 57: Ie,
7383
7383
  62: Uo
7384
7384
  }, Xd = {
7385
7385
  91: Zf
@@ -7544,20 +7544,20 @@ function cp(e) {
7544
7544
  canContainEols: ["emphasis", "fragment", "heading", "paragraph", "strong"],
7545
7545
  enter: {
7546
7546
  autolink: l(Ze),
7547
- autolinkProtocol: j,
7548
- autolinkEmail: j,
7547
+ autolinkProtocol: M,
7548
+ autolinkEmail: M,
7549
7549
  atxHeading: l(Ot),
7550
7550
  blockQuote: l(Te),
7551
- characterEscape: j,
7552
- characterReference: j,
7551
+ characterEscape: M,
7552
+ characterReference: M,
7553
7553
  codeFenced: l(Fe),
7554
7554
  codeFencedFenceInfo: s,
7555
7555
  codeFencedFenceMeta: s,
7556
7556
  codeIndented: l(Fe, s),
7557
7557
  codeText: l(Xe, s),
7558
- codeTextData: j,
7559
- data: j,
7560
- codeFlowValue: j,
7558
+ codeTextData: M,
7559
+ data: M,
7560
+ codeFlowValue: M,
7561
7561
  definition: l(Bt),
7562
7562
  definitionDestinationString: s,
7563
7563
  definitionLabelString: s,
@@ -7566,10 +7566,10 @@ function cp(e) {
7566
7566
  hardBreakEscape: l(ht),
7567
7567
  hardBreakTrailing: l(ht),
7568
7568
  htmlFlow: l(mt, s),
7569
- htmlFlowData: j,
7569
+ htmlFlowData: M,
7570
7570
  htmlText: l(mt, s),
7571
- htmlTextData: j,
7572
- image: l(It),
7571
+ htmlTextData: M,
7572
+ image: l(Pt),
7573
7573
  label: s,
7574
7574
  link: l(Ze),
7575
7575
  listItem: l(re),
@@ -7583,7 +7583,7 @@ function cp(e) {
7583
7583
  resourceTitleString: s,
7584
7584
  setextHeading: l(Ot),
7585
7585
  strong: l(Ee),
7586
- thematicBreak: l(ut)
7586
+ thematicBreak: l(ct)
7587
7587
  },
7588
7588
  exit: {
7589
7589
  atxHeading: c(),
@@ -7592,43 +7592,43 @@ function cp(e) {
7592
7592
  autolinkEmail: he,
7593
7593
  autolinkProtocol: xe,
7594
7594
  blockQuote: c(),
7595
- characterEscapeValue: H,
7595
+ characterEscapeValue: B,
7596
7596
  characterReferenceMarkerHexadecimal: de,
7597
7597
  characterReferenceMarkerNumeric: de,
7598
7598
  characterReferenceValue: pe,
7599
- codeFenced: c(P),
7599
+ codeFenced: c(I),
7600
7600
  codeFencedFence: g,
7601
7601
  codeFencedFenceInfo: h,
7602
7602
  codeFencedFenceMeta: v,
7603
- codeFlowValue: H,
7603
+ codeFlowValue: B,
7604
7604
  codeIndented: c(A),
7605
- codeText: c(M),
7606
- codeTextData: H,
7607
- data: H,
7605
+ codeText: c(H),
7606
+ codeTextData: B,
7607
+ data: B,
7608
7608
  definition: c(),
7609
7609
  definitionDestinationString: b,
7610
7610
  definitionLabelString: q,
7611
- definitionTitleString: I,
7611
+ definitionTitleString: P,
7612
7612
  emphasis: c(),
7613
7613
  hardBreakEscape: c(S),
7614
7614
  hardBreakTrailing: c(S),
7615
7615
  htmlFlow: c(O),
7616
- htmlFlowData: H,
7616
+ htmlFlowData: B,
7617
7617
  htmlText: c(N),
7618
- htmlTextData: H,
7619
- image: c(B),
7618
+ htmlTextData: B,
7619
+ image: c(D),
7620
7620
  label: W,
7621
7621
  labelText: m,
7622
7622
  lineEnding: T,
7623
- link: c(D),
7623
+ link: c(j),
7624
7624
  listItem: c(),
7625
7625
  listOrdered: c(),
7626
7626
  listUnordered: c(),
7627
7627
  paragraph: c(),
7628
7628
  referenceString: ne,
7629
- resourceDestinationString: K,
7629
+ resourceDestinationString: Y,
7630
7630
  resourceTitleString: w,
7631
- resource: Y,
7631
+ resource: K,
7632
7632
  setextHeading: c(U),
7633
7633
  setextHeadingLineSequence: F,
7634
7634
  setextHeadingText: z,
@@ -7681,14 +7681,14 @@ function cp(e) {
7681
7681
  (we[1] || Sa).call(Z, void 0, we[0]);
7682
7682
  }
7683
7683
  for (V.position = {
7684
- start: ct(
7684
+ start: ft(
7685
7685
  R.length > 0 ? R[0][1].start : {
7686
7686
  line: 1,
7687
7687
  column: 1,
7688
7688
  offset: 0
7689
7689
  }
7690
7690
  ),
7691
- end: ct(
7691
+ end: ft(
7692
7692
  R.length > 0 ? R[R.length - 2][1].end : {
7693
7693
  line: 1,
7694
7694
  column: 1,
@@ -7705,12 +7705,12 @@ function cp(e) {
7705
7705
  const Ce = R[ae];
7706
7706
  if (Ce[1].type === "listUnordered" || Ce[1].type === "listOrdered" || Ce[1].type === "blockQuote" ? (Ce[0] === "enter" ? le++ : le--, Ke = void 0) : Ce[1].type === "lineEndingBlank" ? Ce[0] === "enter" && (Ye && !Ke && !le && !Le && (Le = ae), Ke = void 0) : Ce[1].type === "linePrefix" || Ce[1].type === "listItemValue" || Ce[1].type === "listItemMarker" || Ce[1].type === "listItemPrefix" || Ce[1].type === "listItemPrefixWhitespace" || (Ke = void 0), !le && Ce[0] === "enter" && Ce[1].type === "listItemPrefix" || le === -1 && Ce[0] === "exit" && (Ce[1].type === "listUnordered" || Ce[1].type === "listOrdered")) {
7707
7707
  if (Ye) {
7708
- let Pt = ae;
7709
- for ($e = void 0; Pt--; ) {
7710
- const Ve = R[Pt];
7708
+ let It = ae;
7709
+ for ($e = void 0; It--; ) {
7710
+ const Ve = R[It];
7711
7711
  if (Ve[1].type === "lineEnding" || Ve[1].type === "lineEndingBlank") {
7712
7712
  if (Ve[0] === "exit") continue;
7713
- $e && (R[$e][1].type = "lineEndingBlank", we = !0), Ve[1].type = "lineEnding", $e = Pt;
7713
+ $e && (R[$e][1].type = "lineEndingBlank", we = !0), Ve[1].type = "lineEnding", $e = It;
7714
7714
  } else if (!(Ve[1].type === "linePrefix" || Ve[1].type === "blockQuotePrefix" || Ve[1].type === "blockQuotePrefixWhitespace" || Ve[1].type === "blockQuoteMarker" || Ve[1].type === "listItemIndent")) break;
7715
7715
  }
7716
7716
  Le && (!$e || Le < $e) && (Ye._spread = !0), Ye.end = Object.assign(
@@ -7749,7 +7749,7 @@ function cp(e) {
7749
7749
  }
7750
7750
  function u(R, V, Z) {
7751
7751
  return this.stack[this.stack.length - 1].children.push(R), this.stack.push(R), this.tokenStack.push([V, Z]), R.position = {
7752
- start: ct(V.start)
7752
+ start: ft(V.start)
7753
7753
  }, R;
7754
7754
  }
7755
7755
  function c(R) {
@@ -7768,7 +7768,7 @@ function cp(e) {
7768
7768
  end: R.end
7769
7769
  }) + "): it’s not open"
7770
7770
  );
7771
- return Z.position.end = ct(R.end), Z;
7771
+ return Z.position.end = ft(R.end), Z;
7772
7772
  }
7773
7773
  function p() {
7774
7774
  return sf(this.stack.pop());
@@ -7793,7 +7793,7 @@ function cp(e) {
7793
7793
  function g() {
7794
7794
  o("flowCodeInside") || (this.buffer(), a("flowCodeInside", !0));
7795
7795
  }
7796
- function P() {
7796
+ function I() {
7797
7797
  const R = this.resume(), V = this.stack[this.stack.length - 1];
7798
7798
  V.value = R.replace(/^(\r?\n|\r)|(\r?\n|\r)$/g, ""), a("flowCodeInside");
7799
7799
  }
@@ -7807,7 +7807,7 @@ function cp(e) {
7807
7807
  this.sliceSerialize(R)
7808
7808
  ).toLowerCase();
7809
7809
  }
7810
- function I() {
7810
+ function P() {
7811
7811
  const R = this.resume(), V = this.stack[this.stack.length - 1];
7812
7812
  V.title = R;
7813
7813
  }
@@ -7832,25 +7832,25 @@ function cp(e) {
7832
7832
  function U() {
7833
7833
  a("setextHeadingSlurpLineEnding");
7834
7834
  }
7835
- function j(R) {
7835
+ function M(R) {
7836
7836
  const V = this.stack[this.stack.length - 1];
7837
7837
  let Z = V.children[V.children.length - 1];
7838
7838
  (!Z || Z.type !== "text") && (Z = Ne(), Z.position = {
7839
- start: ct(R.start)
7839
+ start: ft(R.start)
7840
7840
  }, V.children.push(Z)), this.stack.push(Z);
7841
7841
  }
7842
- function H(R) {
7842
+ function B(R) {
7843
7843
  const V = this.stack.pop();
7844
- V.value += this.sliceSerialize(R), V.position.end = ct(R.end);
7844
+ V.value += this.sliceSerialize(R), V.position.end = ft(R.end);
7845
7845
  }
7846
7846
  function T(R) {
7847
7847
  const V = this.stack[this.stack.length - 1];
7848
7848
  if (o("atHardBreak")) {
7849
7849
  const Z = V.children[V.children.length - 1];
7850
- Z.position.end = ct(R.end), a("atHardBreak");
7850
+ Z.position.end = ft(R.end), a("atHardBreak");
7851
7851
  return;
7852
7852
  }
7853
- !o("setextHeadingSlurpLineEnding") && t.canContainEols.includes(V.type) && (j.call(this, R), H.call(this, R));
7853
+ !o("setextHeadingSlurpLineEnding") && t.canContainEols.includes(V.type) && (M.call(this, R), B.call(this, R));
7854
7854
  }
7855
7855
  function S() {
7856
7856
  a("atHardBreak", !0);
@@ -7863,11 +7863,11 @@ function cp(e) {
7863
7863
  const R = this.resume(), V = this.stack[this.stack.length - 1];
7864
7864
  V.value = R;
7865
7865
  }
7866
- function M() {
7866
+ function H() {
7867
7867
  const R = this.resume(), V = this.stack[this.stack.length - 1];
7868
7868
  V.value = R;
7869
7869
  }
7870
- function D() {
7870
+ function j() {
7871
7871
  const R = this.stack[this.stack.length - 1];
7872
7872
  if (o("inReference")) {
7873
7873
  const V = o("referenceType") || "shortcut";
@@ -7876,7 +7876,7 @@ function cp(e) {
7876
7876
  delete R.identifier, delete R.label;
7877
7877
  a("referenceType");
7878
7878
  }
7879
- function B() {
7879
+ function D() {
7880
7880
  const R = this.stack[this.stack.length - 1];
7881
7881
  if (o("inReference")) {
7882
7882
  const V = o("referenceType") || "shortcut";
@@ -7897,7 +7897,7 @@ function cp(e) {
7897
7897
  } else
7898
7898
  Z.alt = V;
7899
7899
  }
7900
- function K() {
7900
+ function Y() {
7901
7901
  const R = this.resume(), V = this.stack[this.stack.length - 1];
7902
7902
  V.url = R;
7903
7903
  }
@@ -7905,7 +7905,7 @@ function cp(e) {
7905
7905
  const R = this.resume(), V = this.stack[this.stack.length - 1];
7906
7906
  V.title = R;
7907
7907
  }
7908
- function Y() {
7908
+ function K() {
7909
7909
  a("inReference");
7910
7910
  }
7911
7911
  function oe() {
@@ -7928,15 +7928,15 @@ function cp(e) {
7928
7928
  Z === "characterReferenceMarkerNumeric" ? 10 : 16
7929
7929
  ), a("characterReferenceType")) : ae = Yr(V);
7930
7930
  const le = this.stack.pop();
7931
- le.value += ae, le.position.end = ct(R.end);
7931
+ le.value += ae, le.position.end = ft(R.end);
7932
7932
  }
7933
7933
  function xe(R) {
7934
- H.call(this, R);
7934
+ B.call(this, R);
7935
7935
  const V = this.stack[this.stack.length - 1];
7936
7936
  V.url = this.sliceSerialize(R);
7937
7937
  }
7938
7938
  function he(R) {
7939
- H.call(this, R);
7939
+ B.call(this, R);
7940
7940
  const V = this.stack[this.stack.length - 1];
7941
7941
  V.url = "mailto:" + this.sliceSerialize(R);
7942
7942
  }
@@ -7993,7 +7993,7 @@ function cp(e) {
7993
7993
  value: ""
7994
7994
  };
7995
7995
  }
7996
- function It() {
7996
+ function Pt() {
7997
7997
  return {
7998
7998
  type: "image",
7999
7999
  title: null,
@@ -8044,13 +8044,13 @@ function cp(e) {
8044
8044
  value: ""
8045
8045
  };
8046
8046
  }
8047
- function ut() {
8047
+ function ct() {
8048
8048
  return {
8049
8049
  type: "thematicBreak"
8050
8050
  };
8051
8051
  }
8052
8052
  }
8053
- function ct(e) {
8053
+ function ft(e) {
8054
8054
  return {
8055
8055
  line: e.line,
8056
8056
  column: e.column,
@@ -8351,7 +8351,7 @@ function Op(e, t) {
8351
8351
  };
8352
8352
  return e.patch(t, a), e.applyData(t, a);
8353
8353
  }
8354
- function Ip(e, t) {
8354
+ function Pp(e, t) {
8355
8355
  const n = {
8356
8356
  type: "element",
8357
8357
  tagName: "p",
@@ -8360,7 +8360,7 @@ function Ip(e, t) {
8360
8360
  };
8361
8361
  return e.patch(t, n), e.applyData(t, n);
8362
8362
  }
8363
- function Pp(e, t) {
8363
+ function Ip(e, t) {
8364
8364
  const n = { type: "root", children: e.wrap(e.all(t)) };
8365
8365
  return e.patch(t, n), e.applyData(t, n);
8366
8366
  }
@@ -8503,8 +8503,8 @@ const Bp = {
8503
8503
  link: _p,
8504
8504
  listItem: Ep,
8505
8505
  list: Op,
8506
- paragraph: Ip,
8507
- root: Pp,
8506
+ paragraph: Pp,
8507
+ root: Ip,
8508
8508
  strong: Ap,
8509
8509
  table: Np,
8510
8510
  tableCell: jp,
@@ -8659,21 +8659,21 @@ const ei = (
8659
8659
  function Xp(e) {
8660
8660
  return !e || !e.position || !e.position.start || !e.position.start.line || !e.position.start.column || !e.position.end || !e.position.end.line || !e.position.end.column;
8661
8661
  }
8662
- const Ia = {}.hasOwnProperty;
8662
+ const Pa = {}.hasOwnProperty;
8663
8663
  function Zp(e) {
8664
8664
  const t = /* @__PURE__ */ Object.create(null);
8665
8665
  if (!e || !e.type)
8666
8666
  throw new Error("mdast-util-definitions expected node");
8667
8667
  return ei(e, "definition", (r) => {
8668
- const i = Pa(r.identifier);
8669
- i && !Ia.call(t, i) && (t[i] = r);
8668
+ const i = Ia(r.identifier);
8669
+ i && !Pa.call(t, i) && (t[i] = r);
8670
8670
  }), n;
8671
8671
  function n(r) {
8672
- const i = Pa(r);
8673
- return i && Ia.call(t, i) ? t[i] : null;
8672
+ const i = Ia(r);
8673
+ return i && Pa.call(t, i) ? t[i] : null;
8674
8674
  }
8675
8675
  }
8676
- function Pa(e) {
8676
+ function Ia(e) {
8677
8677
  return String(e || "").toUpperCase();
8678
8678
  }
8679
8679
  const Tn = {}.hasOwnProperty;
@@ -10148,28 +10148,28 @@ function Sh() {
10148
10148
  throw new TypeError("First argument must be a string");
10149
10149
  if (!h) return [];
10150
10150
  v = v || {};
10151
- var g = 1, P = 1;
10151
+ var g = 1, I = 1;
10152
10152
  function A(T) {
10153
10153
  var S = T.match(t);
10154
10154
  S && (g += S.length);
10155
10155
  var O = T.lastIndexOf(s);
10156
- P = ~O ? T.length - O : P + T.length;
10156
+ I = ~O ? T.length - O : I + T.length;
10157
10157
  }
10158
10158
  function q() {
10159
- var T = { line: g, column: P };
10159
+ var T = { line: g, column: I };
10160
10160
  return function(S) {
10161
- return S.position = new I(T), z(), S;
10161
+ return S.position = new P(T), z(), S;
10162
10162
  };
10163
10163
  }
10164
- function I(T) {
10165
- this.start = T, this.end = { line: g, column: P }, this.source = v.source;
10164
+ function P(T) {
10165
+ this.start = T, this.end = { line: g, column: I }, this.source = v.source;
10166
10166
  }
10167
- I.prototype.content = h;
10167
+ P.prototype.content = h;
10168
10168
  function b(T) {
10169
10169
  var S = new Error(
10170
- v.source + ":" + g + ":" + P + ": " + T
10170
+ v.source + ":" + g + ":" + I + ": " + T
10171
10171
  );
10172
- if (S.reason = T, S.filename = v.source, S.line = g, S.column = P, S.source = h, !v.silent) throw S;
10172
+ if (S.reason = T, S.filename = v.source, S.line = g, S.column = I, S.source = h, !v.silent) throw S;
10173
10173
  }
10174
10174
  function E(T) {
10175
10175
  var S = T.exec(h);
@@ -10195,13 +10195,13 @@ function Sh() {
10195
10195
  if (S += 2, d === h.charAt(S - 1))
10196
10196
  return b("End of comment missing");
10197
10197
  var O = h.slice(2, S - 2);
10198
- return P += 2, A(O), h = h.slice(S), P += 2, T({
10198
+ return I += 2, A(O), h = h.slice(S), I += 2, T({
10199
10199
  type: p,
10200
10200
  comment: O
10201
10201
  });
10202
10202
  }
10203
10203
  }
10204
- function j() {
10204
+ function M() {
10205
10205
  var T = q(), S = E(r);
10206
10206
  if (S) {
10207
10207
  if (U(), !E(i)) return b("property missing ':'");
@@ -10213,14 +10213,14 @@ function Sh() {
10213
10213
  return E(o), N;
10214
10214
  }
10215
10215
  }
10216
- function H() {
10216
+ function B() {
10217
10217
  var T = [];
10218
10218
  F(T);
10219
- for (var S; S = j(); )
10219
+ for (var S; S = M(); )
10220
10220
  S !== !1 && (T.push(S), F(T));
10221
10221
  return T;
10222
10222
  }
10223
- return z(), H();
10223
+ return z(), B();
10224
10224
  };
10225
10225
  function y(h) {
10226
10226
  return h ? h.replace(l, d) : d;
@@ -10248,10 +10248,10 @@ function gl(e, t) {
10248
10248
  const n = [];
10249
10249
  let r = -1, i;
10250
10250
  for (; ++r < t.children.length; )
10251
- i = t.children[r], i.type === "element" ? n.push(Ih(e, i, r, t)) : i.type === "text" ? (t.type !== "element" || !Oh.has(t.tagName) || !wh(i)) && n.push(i.value) : i.type === "raw" && !e.options.skipHtml && n.push(i.value);
10251
+ i = t.children[r], i.type === "element" ? n.push(Ph(e, i, r, t)) : i.type === "text" ? (t.type !== "element" || !Oh.has(t.tagName) || !wh(i)) && n.push(i.value) : i.type === "raw" && !e.options.skipHtml && n.push(i.value);
10252
10252
  return n;
10253
10253
  }
10254
- function Ih(e, t, n, r) {
10254
+ function Ph(e, t, n, r) {
10255
10255
  const i = e.options, a = i.transformLinkUri === void 0 ? Rc : i.transformLinkUri, o = e.schema, l = t.tagName, s = {};
10256
10256
  let u = o, c;
10257
10257
  if (o.space === "html" && l === "svg" && (u = mh, e.schema = u), t.properties)
@@ -10281,12 +10281,12 @@ function Ih(e, t, n, r) {
10281
10281
  String(s.alt || ""),
10282
10282
  typeof s.title == "string" ? s.title : null
10283
10283
  )), !y && l === "li" && r.type === "element") {
10284
- const h = Ph(t);
10284
+ const h = Ih(t);
10285
10285
  s.checked = h && h.properties ? !!h.properties.checked : null, s.index = mr(r, t), s.ordered = r.tagName === "ol";
10286
10286
  }
10287
10287
  return !y && (l === "ol" || l === "ul") && (s.ordered = l === "ol", s.depth = e.listDepth), (l === "td" || l === "th") && (s.align && (s.style || (s.style = {}), s.style.textAlign = s.align, delete s.align), y || (s.isHeader = l === "th")), !y && l === "tr" && r.type === "element" && (s.isHeader = r.tagName === "thead"), i.sourcePos && (s["data-sourcepos"] = Lh(p)), !y && i.rawSourcePos && (s.sourcePosition = t.position), !y && i.includeElementIndex && (s.index = mr(r, t), s.siblingCount = mr(r)), y || (s.node = t), d.length > 0 ? Ge.createElement(f, s, d) : Ge.createElement(f, s);
10288
10288
  }
10289
- function Ph(e) {
10289
+ function Ih(e) {
10290
10290
  let t = -1;
10291
10291
  for (; ++t < e.children.length; ) {
10292
10292
  const n = e.children[t];
@@ -10480,205 +10480,205 @@ function Rh() {
10480
10480
  (function(n, r) {
10481
10481
  e.exports = r();
10482
10482
  })(Dh, function() {
10483
- var n = 1e3, r = 6e4, i = 36e5, a = "millisecond", o = "second", l = "minute", s = "hour", u = "day", c = "week", d = "month", p = "quarter", f = "year", y = "date", h = "Invalid Date", v = /^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/, g = /\[([^\]]+)]|Y{1,4}|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g, P = { name: "en", weekdays: "Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"), months: "January_February_March_April_May_June_July_August_September_October_November_December".split("_"), ordinal: function(S) {
10483
+ var n = 1e3, r = 6e4, i = 36e5, a = "millisecond", o = "second", l = "minute", s = "hour", u = "day", c = "week", d = "month", p = "quarter", f = "year", y = "date", h = "Invalid Date", v = /^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/, g = /\[([^\]]+)]|Y{1,4}|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g, I = { name: "en", weekdays: "Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"), months: "January_February_March_April_May_June_July_August_September_October_November_December".split("_"), ordinal: function(S) {
10484
10484
  var O = ["th", "st", "nd", "rd"], N = S % 100;
10485
10485
  return "[" + S + (O[(N - 20) % 10] || O[N] || O[0]) + "]";
10486
10486
  } }, A = function(S, O, N) {
10487
- var M = String(S);
10488
- return !M || M.length >= O ? S : "" + Array(O + 1 - M.length).join(N) + S;
10487
+ var H = String(S);
10488
+ return !H || H.length >= O ? S : "" + Array(O + 1 - H.length).join(N) + S;
10489
10489
  }, q = { s: A, z: function(S) {
10490
- var O = -S.utcOffset(), N = Math.abs(O), M = Math.floor(N / 60), D = N % 60;
10491
- return (O <= 0 ? "+" : "-") + A(M, 2, "0") + ":" + A(D, 2, "0");
10490
+ var O = -S.utcOffset(), N = Math.abs(O), H = Math.floor(N / 60), j = N % 60;
10491
+ return (O <= 0 ? "+" : "-") + A(H, 2, "0") + ":" + A(j, 2, "0");
10492
10492
  }, m: function S(O, N) {
10493
10493
  if (O.date() < N.date()) return -S(N, O);
10494
- var M = 12 * (N.year() - O.year()) + (N.month() - O.month()), D = O.clone().add(M, d), B = N - D < 0, m = O.clone().add(M + (B ? -1 : 1), d);
10495
- return +(-(M + (N - D) / (B ? D - m : m - D)) || 0);
10494
+ var H = 12 * (N.year() - O.year()) + (N.month() - O.month()), j = O.clone().add(H, d), D = N - j < 0, m = O.clone().add(H + (D ? -1 : 1), d);
10495
+ return +(-(H + (N - j) / (D ? j - m : m - j)) || 0);
10496
10496
  }, a: function(S) {
10497
10497
  return S < 0 ? Math.ceil(S) || 0 : Math.floor(S);
10498
10498
  }, p: function(S) {
10499
10499
  return { M: d, y: f, w: c, d: u, D: y, h: s, m: l, s: o, ms: a, Q: p }[S] || String(S || "").toLowerCase().replace(/s$/, "");
10500
10500
  }, u: function(S) {
10501
10501
  return S === void 0;
10502
- } }, I = "en", b = {};
10503
- b[I] = P;
10502
+ } }, P = "en", b = {};
10503
+ b[P] = I;
10504
10504
  var E = "$isDayjsObject", z = function(S) {
10505
- return S instanceof H || !(!S || !S[E]);
10506
- }, F = function S(O, N, M) {
10507
- var D;
10508
- if (!O) return I;
10505
+ return S instanceof B || !(!S || !S[E]);
10506
+ }, F = function S(O, N, H) {
10507
+ var j;
10508
+ if (!O) return P;
10509
10509
  if (typeof O == "string") {
10510
- var B = O.toLowerCase();
10511
- b[B] && (D = B), N && (b[B] = N, D = B);
10510
+ var D = O.toLowerCase();
10511
+ b[D] && (j = D), N && (b[D] = N, j = D);
10512
10512
  var m = O.split("-");
10513
- if (!D && m.length > 1) return S(m[0]);
10513
+ if (!j && m.length > 1) return S(m[0]);
10514
10514
  } else {
10515
10515
  var W = O.name;
10516
- b[W] = O, D = W;
10516
+ b[W] = O, j = W;
10517
10517
  }
10518
- return !M && D && (I = D), D || !M && I;
10518
+ return !H && j && (P = j), j || !H && P;
10519
10519
  }, U = function(S, O) {
10520
10520
  if (z(S)) return S.clone();
10521
10521
  var N = typeof O == "object" ? O : {};
10522
- return N.date = S, N.args = arguments, new H(N);
10523
- }, j = q;
10524
- j.l = F, j.i = z, j.w = function(S, O) {
10522
+ return N.date = S, N.args = arguments, new B(N);
10523
+ }, M = q;
10524
+ M.l = F, M.i = z, M.w = function(S, O) {
10525
10525
  return U(S, { locale: O.$L, utc: O.$u, x: O.$x, $offset: O.$offset });
10526
10526
  };
10527
- var H = function() {
10527
+ var B = function() {
10528
10528
  function S(N) {
10529
10529
  this.$L = F(N.locale, null, !0), this.parse(N), this.$x = this.$x || N.x || {}, this[E] = !0;
10530
10530
  }
10531
10531
  var O = S.prototype;
10532
10532
  return O.parse = function(N) {
10533
- this.$d = function(M) {
10534
- var D = M.date, B = M.utc;
10535
- if (D === null) return /* @__PURE__ */ new Date(NaN);
10536
- if (j.u(D)) return /* @__PURE__ */ new Date();
10537
- if (D instanceof Date) return new Date(D);
10538
- if (typeof D == "string" && !/Z$/i.test(D)) {
10539
- var m = D.match(v);
10533
+ this.$d = function(H) {
10534
+ var j = H.date, D = H.utc;
10535
+ if (j === null) return /* @__PURE__ */ new Date(NaN);
10536
+ if (M.u(j)) return /* @__PURE__ */ new Date();
10537
+ if (j instanceof Date) return new Date(j);
10538
+ if (typeof j == "string" && !/Z$/i.test(j)) {
10539
+ var m = j.match(v);
10540
10540
  if (m) {
10541
- var W = m[2] - 1 || 0, K = (m[7] || "0").substring(0, 3);
10542
- return B ? new Date(Date.UTC(m[1], W, m[3] || 1, m[4] || 0, m[5] || 0, m[6] || 0, K)) : new Date(m[1], W, m[3] || 1, m[4] || 0, m[5] || 0, m[6] || 0, K);
10541
+ var W = m[2] - 1 || 0, Y = (m[7] || "0").substring(0, 3);
10542
+ return D ? new Date(Date.UTC(m[1], W, m[3] || 1, m[4] || 0, m[5] || 0, m[6] || 0, Y)) : new Date(m[1], W, m[3] || 1, m[4] || 0, m[5] || 0, m[6] || 0, Y);
10543
10543
  }
10544
10544
  }
10545
- return new Date(D);
10545
+ return new Date(j);
10546
10546
  }(N), this.init();
10547
10547
  }, O.init = function() {
10548
10548
  var N = this.$d;
10549
10549
  this.$y = N.getFullYear(), this.$M = N.getMonth(), this.$D = N.getDate(), this.$W = N.getDay(), this.$H = N.getHours(), this.$m = N.getMinutes(), this.$s = N.getSeconds(), this.$ms = N.getMilliseconds();
10550
10550
  }, O.$utils = function() {
10551
- return j;
10551
+ return M;
10552
10552
  }, O.isValid = function() {
10553
10553
  return this.$d.toString() !== h;
10554
- }, O.isSame = function(N, M) {
10555
- var D = U(N);
10556
- return this.startOf(M) <= D && D <= this.endOf(M);
10557
- }, O.isAfter = function(N, M) {
10558
- return U(N) < this.startOf(M);
10559
- }, O.isBefore = function(N, M) {
10560
- return this.endOf(M) < U(N);
10561
- }, O.$g = function(N, M, D) {
10562
- return j.u(N) ? this[M] : this.set(D, N);
10554
+ }, O.isSame = function(N, H) {
10555
+ var j = U(N);
10556
+ return this.startOf(H) <= j && j <= this.endOf(H);
10557
+ }, O.isAfter = function(N, H) {
10558
+ return U(N) < this.startOf(H);
10559
+ }, O.isBefore = function(N, H) {
10560
+ return this.endOf(H) < U(N);
10561
+ }, O.$g = function(N, H, j) {
10562
+ return M.u(N) ? this[H] : this.set(j, N);
10563
10563
  }, O.unix = function() {
10564
10564
  return Math.floor(this.valueOf() / 1e3);
10565
10565
  }, O.valueOf = function() {
10566
10566
  return this.$d.getTime();
10567
- }, O.startOf = function(N, M) {
10568
- var D = this, B = !!j.u(M) || M, m = j.p(N), W = function(xe, he) {
10569
- var Te = j.w(D.$u ? Date.UTC(D.$y, he, xe) : new Date(D.$y, he, xe), D);
10570
- return B ? Te : Te.endOf(u);
10571
- }, K = function(xe, he) {
10572
- return j.w(D.toDate()[xe].apply(D.toDate("s"), (B ? [0, 0, 0, 0] : [23, 59, 59, 999]).slice(he)), D);
10573
- }, w = this.$W, Y = this.$M, oe = this.$D, ne = "set" + (this.$u ? "UTC" : "");
10567
+ }, O.startOf = function(N, H) {
10568
+ var j = this, D = !!M.u(H) || H, m = M.p(N), W = function(xe, he) {
10569
+ var Te = M.w(j.$u ? Date.UTC(j.$y, he, xe) : new Date(j.$y, he, xe), j);
10570
+ return D ? Te : Te.endOf(u);
10571
+ }, Y = function(xe, he) {
10572
+ return M.w(j.toDate()[xe].apply(j.toDate("s"), (D ? [0, 0, 0, 0] : [23, 59, 59, 999]).slice(he)), j);
10573
+ }, w = this.$W, K = this.$M, oe = this.$D, ne = "set" + (this.$u ? "UTC" : "");
10574
10574
  switch (m) {
10575
10575
  case f:
10576
- return B ? W(1, 0) : W(31, 11);
10576
+ return D ? W(1, 0) : W(31, 11);
10577
10577
  case d:
10578
- return B ? W(1, Y) : W(0, Y + 1);
10578
+ return D ? W(1, K) : W(0, K + 1);
10579
10579
  case c:
10580
10580
  var de = this.$locale().weekStart || 0, pe = (w < de ? w + 7 : w) - de;
10581
- return W(B ? oe - pe : oe + (6 - pe), Y);
10581
+ return W(D ? oe - pe : oe + (6 - pe), K);
10582
10582
  case u:
10583
10583
  case y:
10584
- return K(ne + "Hours", 0);
10584
+ return Y(ne + "Hours", 0);
10585
10585
  case s:
10586
- return K(ne + "Minutes", 1);
10586
+ return Y(ne + "Minutes", 1);
10587
10587
  case l:
10588
- return K(ne + "Seconds", 2);
10588
+ return Y(ne + "Seconds", 2);
10589
10589
  case o:
10590
- return K(ne + "Milliseconds", 3);
10590
+ return Y(ne + "Milliseconds", 3);
10591
10591
  default:
10592
10592
  return this.clone();
10593
10593
  }
10594
10594
  }, O.endOf = function(N) {
10595
10595
  return this.startOf(N, !1);
10596
- }, O.$set = function(N, M) {
10597
- var D, B = j.p(N), m = "set" + (this.$u ? "UTC" : ""), W = (D = {}, D[u] = m + "Date", D[y] = m + "Date", D[d] = m + "Month", D[f] = m + "FullYear", D[s] = m + "Hours", D[l] = m + "Minutes", D[o] = m + "Seconds", D[a] = m + "Milliseconds", D)[B], K = B === u ? this.$D + (M - this.$W) : M;
10598
- if (B === d || B === f) {
10596
+ }, O.$set = function(N, H) {
10597
+ var j, D = M.p(N), m = "set" + (this.$u ? "UTC" : ""), W = (j = {}, j[u] = m + "Date", j[y] = m + "Date", j[d] = m + "Month", j[f] = m + "FullYear", j[s] = m + "Hours", j[l] = m + "Minutes", j[o] = m + "Seconds", j[a] = m + "Milliseconds", j)[D], Y = D === u ? this.$D + (H - this.$W) : H;
10598
+ if (D === d || D === f) {
10599
10599
  var w = this.clone().set(y, 1);
10600
- w.$d[W](K), w.init(), this.$d = w.set(y, Math.min(this.$D, w.daysInMonth())).$d;
10601
- } else W && this.$d[W](K);
10600
+ w.$d[W](Y), w.init(), this.$d = w.set(y, Math.min(this.$D, w.daysInMonth())).$d;
10601
+ } else W && this.$d[W](Y);
10602
10602
  return this.init(), this;
10603
- }, O.set = function(N, M) {
10604
- return this.clone().$set(N, M);
10603
+ }, O.set = function(N, H) {
10604
+ return this.clone().$set(N, H);
10605
10605
  }, O.get = function(N) {
10606
- return this[j.p(N)]();
10607
- }, O.add = function(N, M) {
10608
- var D, B = this;
10606
+ return this[M.p(N)]();
10607
+ }, O.add = function(N, H) {
10608
+ var j, D = this;
10609
10609
  N = Number(N);
10610
- var m = j.p(M), W = function(Y) {
10611
- var oe = U(B);
10612
- return j.w(oe.date(oe.date() + Math.round(Y * N)), B);
10610
+ var m = M.p(H), W = function(K) {
10611
+ var oe = U(D);
10612
+ return M.w(oe.date(oe.date() + Math.round(K * N)), D);
10613
10613
  };
10614
10614
  if (m === d) return this.set(d, this.$M + N);
10615
10615
  if (m === f) return this.set(f, this.$y + N);
10616
10616
  if (m === u) return W(1);
10617
10617
  if (m === c) return W(7);
10618
- var K = (D = {}, D[l] = r, D[s] = i, D[o] = n, D)[m] || 1, w = this.$d.getTime() + N * K;
10619
- return j.w(w, this);
10620
- }, O.subtract = function(N, M) {
10621
- return this.add(-1 * N, M);
10618
+ var Y = (j = {}, j[l] = r, j[s] = i, j[o] = n, j)[m] || 1, w = this.$d.getTime() + N * Y;
10619
+ return M.w(w, this);
10620
+ }, O.subtract = function(N, H) {
10621
+ return this.add(-1 * N, H);
10622
10622
  }, O.format = function(N) {
10623
- var M = this, D = this.$locale();
10624
- if (!this.isValid()) return D.invalidDate || h;
10625
- var B = N || "YYYY-MM-DDTHH:mm:ssZ", m = j.z(this), W = this.$H, K = this.$m, w = this.$M, Y = D.weekdays, oe = D.months, ne = D.meridiem, de = function(he, Te, Fe, Xe) {
10626
- return he && (he[Te] || he(M, B)) || Fe[Te].slice(0, Xe);
10623
+ var H = this, j = this.$locale();
10624
+ if (!this.isValid()) return j.invalidDate || h;
10625
+ var D = N || "YYYY-MM-DDTHH:mm:ssZ", m = M.z(this), W = this.$H, Y = this.$m, w = this.$M, K = j.weekdays, oe = j.months, ne = j.meridiem, de = function(he, Te, Fe, Xe) {
10626
+ return he && (he[Te] || he(H, D)) || Fe[Te].slice(0, Xe);
10627
10627
  }, pe = function(he) {
10628
- return j.s(W % 12 || 12, he, "0");
10628
+ return M.s(W % 12 || 12, he, "0");
10629
10629
  }, xe = ne || function(he, Te, Fe) {
10630
10630
  var Xe = he < 12 ? "AM" : "PM";
10631
10631
  return Fe ? Xe.toLowerCase() : Xe;
10632
10632
  };
10633
- return B.replace(g, function(he, Te) {
10633
+ return D.replace(g, function(he, Te) {
10634
10634
  return Te || function(Fe) {
10635
10635
  switch (Fe) {
10636
10636
  case "YY":
10637
- return String(M.$y).slice(-2);
10637
+ return String(H.$y).slice(-2);
10638
10638
  case "YYYY":
10639
- return j.s(M.$y, 4, "0");
10639
+ return M.s(H.$y, 4, "0");
10640
10640
  case "M":
10641
10641
  return w + 1;
10642
10642
  case "MM":
10643
- return j.s(w + 1, 2, "0");
10643
+ return M.s(w + 1, 2, "0");
10644
10644
  case "MMM":
10645
- return de(D.monthsShort, w, oe, 3);
10645
+ return de(j.monthsShort, w, oe, 3);
10646
10646
  case "MMMM":
10647
10647
  return de(oe, w);
10648
10648
  case "D":
10649
- return M.$D;
10649
+ return H.$D;
10650
10650
  case "DD":
10651
- return j.s(M.$D, 2, "0");
10651
+ return M.s(H.$D, 2, "0");
10652
10652
  case "d":
10653
- return String(M.$W);
10653
+ return String(H.$W);
10654
10654
  case "dd":
10655
- return de(D.weekdaysMin, M.$W, Y, 2);
10655
+ return de(j.weekdaysMin, H.$W, K, 2);
10656
10656
  case "ddd":
10657
- return de(D.weekdaysShort, M.$W, Y, 3);
10657
+ return de(j.weekdaysShort, H.$W, K, 3);
10658
10658
  case "dddd":
10659
- return Y[M.$W];
10659
+ return K[H.$W];
10660
10660
  case "H":
10661
10661
  return String(W);
10662
10662
  case "HH":
10663
- return j.s(W, 2, "0");
10663
+ return M.s(W, 2, "0");
10664
10664
  case "h":
10665
10665
  return pe(1);
10666
10666
  case "hh":
10667
10667
  return pe(2);
10668
10668
  case "a":
10669
- return xe(W, K, !0);
10669
+ return xe(W, Y, !0);
10670
10670
  case "A":
10671
- return xe(W, K, !1);
10671
+ return xe(W, Y, !1);
10672
10672
  case "m":
10673
- return String(K);
10673
+ return String(Y);
10674
10674
  case "mm":
10675
- return j.s(K, 2, "0");
10675
+ return M.s(Y, 2, "0");
10676
10676
  case "s":
10677
- return String(M.$s);
10677
+ return String(H.$s);
10678
10678
  case "ss":
10679
- return j.s(M.$s, 2, "0");
10679
+ return M.s(H.$s, 2, "0");
10680
10680
  case "SSS":
10681
- return j.s(M.$ms, 3, "0");
10681
+ return M.s(H.$ms, 3, "0");
10682
10682
  case "Z":
10683
10683
  return m;
10684
10684
  }
@@ -10687,49 +10687,49 @@ function Rh() {
10687
10687
  });
10688
10688
  }, O.utcOffset = function() {
10689
10689
  return 15 * -Math.round(this.$d.getTimezoneOffset() / 15);
10690
- }, O.diff = function(N, M, D) {
10691
- var B, m = this, W = j.p(M), K = U(N), w = (K.utcOffset() - this.utcOffset()) * r, Y = this - K, oe = function() {
10692
- return j.m(m, K);
10690
+ }, O.diff = function(N, H, j) {
10691
+ var D, m = this, W = M.p(H), Y = U(N), w = (Y.utcOffset() - this.utcOffset()) * r, K = this - Y, oe = function() {
10692
+ return M.m(m, Y);
10693
10693
  };
10694
10694
  switch (W) {
10695
10695
  case f:
10696
- B = oe() / 12;
10696
+ D = oe() / 12;
10697
10697
  break;
10698
10698
  case d:
10699
- B = oe();
10699
+ D = oe();
10700
10700
  break;
10701
10701
  case p:
10702
- B = oe() / 3;
10702
+ D = oe() / 3;
10703
10703
  break;
10704
10704
  case c:
10705
- B = (Y - w) / 6048e5;
10705
+ D = (K - w) / 6048e5;
10706
10706
  break;
10707
10707
  case u:
10708
- B = (Y - w) / 864e5;
10708
+ D = (K - w) / 864e5;
10709
10709
  break;
10710
10710
  case s:
10711
- B = Y / i;
10711
+ D = K / i;
10712
10712
  break;
10713
10713
  case l:
10714
- B = Y / r;
10714
+ D = K / r;
10715
10715
  break;
10716
10716
  case o:
10717
- B = Y / n;
10717
+ D = K / n;
10718
10718
  break;
10719
10719
  default:
10720
- B = Y;
10720
+ D = K;
10721
10721
  }
10722
- return D ? B : j.a(B);
10722
+ return j ? D : M.a(D);
10723
10723
  }, O.daysInMonth = function() {
10724
10724
  return this.endOf(d).$D;
10725
10725
  }, O.$locale = function() {
10726
10726
  return b[this.$L];
10727
- }, O.locale = function(N, M) {
10727
+ }, O.locale = function(N, H) {
10728
10728
  if (!N) return this.$L;
10729
- var D = this.clone(), B = F(N, M, !0);
10730
- return B && (D.$L = B), D;
10729
+ var j = this.clone(), D = F(N, H, !0);
10730
+ return D && (j.$L = D), j;
10731
10731
  }, O.clone = function() {
10732
- return j.w(this.$d, this);
10732
+ return M.w(this.$d, this);
10733
10733
  }, O.toDate = function() {
10734
10734
  return new Date(this.valueOf());
10735
10735
  }, O.toJSON = function() {
@@ -10739,16 +10739,16 @@ function Rh() {
10739
10739
  }, O.toString = function() {
10740
10740
  return this.$d.toUTCString();
10741
10741
  }, S;
10742
- }(), T = H.prototype;
10742
+ }(), T = B.prototype;
10743
10743
  return U.prototype = T, [["$ms", a], ["$s", o], ["$m", l], ["$H", s], ["$W", u], ["$M", d], ["$y", f], ["$D", y]].forEach(function(S) {
10744
10744
  T[S[1]] = function(O) {
10745
10745
  return this.$g(O, S[0], S[1]);
10746
10746
  };
10747
10747
  }), U.extend = function(S, O) {
10748
- return S.$i || (S(O, H, U), S.$i = !0), U;
10748
+ return S.$i || (S(O, B, U), S.$i = !0), U;
10749
10749
  }, U.locale = F, U.isDayjs = z, U.unix = function(S) {
10750
10750
  return U(1e3 * S);
10751
- }, U.en = b[I], U.Ls = b, U.p = {}, U;
10751
+ }, U.en = b[P], U.Ls = b, U.p = {}, U;
10752
10752
  });
10753
10753
  }(wn)), wn.exports;
10754
10754
  }
@@ -10786,7 +10786,7 @@ const Vh = "Sure, I can get you to someone who can help.", rn = ({
10786
10786
  submitEvent: l
10787
10787
  }) => {
10788
10788
  var A;
10789
- const { primaryColor: s, conversationScreen: u } = Q(Se), { content: c, disableFeedback: d, liveAgent: p, role: f, timestamp: y, toolCalls: h } = n ?? {}, v = p || $h(h).includes("escalate_to_an_agent"), g = !v && !!c, P = {
10789
+ const { primaryColor: s, conversationScreen: u } = Q(Se), { content: c, disableFeedback: d, liveAgent: p, role: f, timestamp: y, toolCalls: h } = n ?? {}, v = p || $h(h).includes("escalate_to_an_agent"), g = !v && !!c, I = {
10790
10790
  agent: {
10791
10791
  bubbleClassName: "xpert-chatbot-popup__bubble--assistant",
10792
10792
  bubbleStyle: {},
@@ -10818,7 +10818,7 @@ const Vh = "Sure, I can get you to someone who can help.", rn = ({
10818
10818
  return /* @__PURE__ */ k.jsxs(
10819
10819
  "section",
10820
10820
  {
10821
- "aria-label": P[f].sectionAriaLabel,
10821
+ "aria-label": I[f].sectionAriaLabel,
10822
10822
  className: "xpert-chatbot-popup__bubble--group",
10823
10823
  ref: r,
10824
10824
  children: [
@@ -10826,7 +10826,7 @@ const Vh = "Sure, I can get you to someone who can help.", rn = ({
10826
10826
  "div",
10827
10827
  {
10828
10828
  className: "xpert-chatbot-popup__bubble--group-inner",
10829
- style: P[f].innerStyle,
10829
+ style: I[f].innerStyle,
10830
10830
  children: [
10831
10831
  f === "agent" && /* @__PURE__ */ k.jsx(
10832
10832
  On,
@@ -10840,8 +10840,8 @@ const Vh = "Sure, I can get you to someone who can help.", rn = ({
10840
10840
  "div",
10841
10841
  {
10842
10842
  "data-testid": "message-container",
10843
- className: P[f].bubbleClassName,
10844
- style: P[f].bubbleStyle,
10843
+ className: I[f].bubbleClassName,
10844
+ style: I[f].bubbleStyle,
10845
10845
  children: [
10846
10846
  g && /* @__PURE__ */ k.jsx(
10847
10847
  ri,
@@ -10862,7 +10862,7 @@ const Vh = "Sure, I can get you to someone who can help.", rn = ({
10862
10862
  children: q.children
10863
10863
  }
10864
10864
  ),
10865
- p: (q) => /* @__PURE__ */ k.jsx("p", { ...q, style: P[f].bubbleStyle, children: q.children })
10865
+ p: (q) => /* @__PURE__ */ k.jsx("p", { ...q, style: I[f].bubbleStyle, children: q.children })
10866
10866
  },
10867
10867
  linkTarget: "_blank",
10868
10868
  transformLinkUri: Uh,
@@ -10986,7 +10986,7 @@ const an = ({
10986
10986
  setLiveChatOpen: a,
10987
10987
  submitEvent: o
10988
10988
  }) => {
10989
- const { disableScroll: l, hasError: s } = Q(Ie), u = ze(null);
10989
+ const { disableScroll: l, hasError: s } = Q(Pe), u = ze(null);
10990
10990
  return ke(() => {
10991
10991
  var c;
10992
10992
  (c = u.current) == null || c.scrollIntoView({
@@ -11030,7 +11030,7 @@ const an = ({
11030
11030
  an.propTypes = {
11031
11031
  isTestUser: C.bool,
11032
11032
  loading: C.bool.isRequired,
11033
- messages: Pn,
11033
+ messages: In,
11034
11034
  onFeedbackThumbSelection: C.func.isRequired,
11035
11035
  onMessageLinkClicked: C.func,
11036
11036
  setLiveChatOpen: C.func,
@@ -11140,8 +11140,8 @@ function oi({
11140
11140
  userInput: s
11141
11141
  }) {
11142
11142
  var v, g;
11143
- const { conversationScreen: u, disclaimer: c } = Q(Se), { deleteConversationModal: d, xpertMessages: p } = Q(St), { loading: f, setMode: y } = Q(Ie), h = (P) => {
11144
- u.liveChat.useOwnChat ? y(dt.LIVECHAT) : o(P);
11143
+ const { conversationScreen: u, disclaimer: c } = Q(Se), { deleteConversationModal: d, xpertMessages: p } = Q(St), { loading: f, setMode: y } = Q(Pe), h = (I) => {
11144
+ u.liveChat.useOwnChat ? y(ut.LIVECHAT) : o(I);
11145
11145
  };
11146
11146
  return /* @__PURE__ */ k.jsxs(k.Fragment, { children: [
11147
11147
  /* @__PURE__ */ k.jsxs(
@@ -11330,8 +11330,8 @@ function vl() {
11330
11330
  else if (g + s <= v && y + s <= v)
11331
11331
  try {
11332
11332
  typeof p == "function" ? r.send(p()) : r.send(p), y = v;
11333
- } catch (P) {
11334
- console.error("Heartbeat failed, closing connection", P instanceof Error ? P.message : P), r.close();
11333
+ } catch (I) {
11334
+ console.error("Heartbeat failed, closing connection", I instanceof Error ? I.message : I), r.close();
11335
11335
  }
11336
11336
  }, f);
11337
11337
  return r.addEventListener("close", function() {
@@ -11421,14 +11421,14 @@ function Wh() {
11421
11421
  return c.onclose = function(v) {
11422
11422
  var g;
11423
11423
  if (d.current.onClose && d.current.onClose(v), p(r.ReadyState.CLOSED), d.current.shouldReconnect && d.current.shouldReconnect(v)) {
11424
- var P = (g = d.current.reconnectAttempts) !== null && g !== void 0 ? g : r.DEFAULT_RECONNECT_LIMIT;
11425
- if (y.current < P) {
11424
+ var I = (g = d.current.reconnectAttempts) !== null && g !== void 0 ? g : r.DEFAULT_RECONNECT_LIMIT;
11425
+ if (y.current < I) {
11426
11426
  var A = typeof d.current.reconnectInterval == "function" ? d.current.reconnectInterval(y.current) : d.current.reconnectInterval;
11427
11427
  h = window.setTimeout(function() {
11428
11428
  y.current++, f();
11429
11429
  }, A ?? r.DEFAULT_RECONNECT_INTERVAL_MS);
11430
11430
  } else
11431
- d.current.onReconnectStop && d.current.onReconnectStop(P), console.warn("Max reconnect attempts of ".concat(P, " exceeded"));
11431
+ d.current.onReconnectStop && d.current.onReconnectStop(I), console.warn("Max reconnect attempts of ".concat(I, " exceeded"));
11432
11432
  }
11433
11433
  }, function() {
11434
11434
  return h && window.clearTimeout(h);
@@ -11439,19 +11439,19 @@ function Wh() {
11439
11439
  var g;
11440
11440
  if (d.current.onError && d.current.onError(v), r.isEventSourceSupported && c instanceof EventSource && (d.current.onClose && d.current.onClose(e(e({}, v), { code: 1006, reason: "An error occurred with the EventSource: ".concat(v), wasClean: !1 })), p(r.ReadyState.CLOSED), c.close()), d.current.retryOnError)
11441
11441
  if (y.current < ((g = d.current.reconnectAttempts) !== null && g !== void 0 ? g : r.DEFAULT_RECONNECT_LIMIT)) {
11442
- var P = typeof d.current.reconnectInterval == "function" ? d.current.reconnectInterval(y.current) : d.current.reconnectInterval;
11442
+ var I = typeof d.current.reconnectInterval == "function" ? d.current.reconnectInterval(y.current) : d.current.reconnectInterval;
11443
11443
  h = window.setTimeout(function() {
11444
11444
  y.current++, f();
11445
- }, P ?? r.DEFAULT_RECONNECT_INTERVAL_MS);
11445
+ }, I ?? r.DEFAULT_RECONNECT_INTERVAL_MS);
11446
11446
  } else
11447
11447
  d.current.onReconnectStop && d.current.onReconnectStop(d.current.reconnectAttempts), console.warn("Max reconnect attempts of ".concat(d.current.reconnectAttempts, " exceeded"));
11448
11448
  }, function() {
11449
11449
  return h && window.clearTimeout(h);
11450
11450
  };
11451
11451
  }, u = function(c, d, p, f, y, h, v) {
11452
- var g = d.setLastMessage, P = d.setReadyState, A, q, I;
11453
- return p.current.fromSocketIO && (A = (0, t.setUpSocketIOPing)(v)), a(c, p, g, h), o(c, p, P, y, h), q = l(c, p, P, f, y), I = s(c, p, P, f, y), function() {
11454
- P(r.ReadyState.CLOSING), q(), I(), c.close(), A && clearInterval(A);
11452
+ var g = d.setLastMessage, I = d.setReadyState, A, q, P;
11453
+ return p.current.fromSocketIO && (A = (0, t.setUpSocketIOPing)(v)), a(c, p, g, h), o(c, p, I, y, h), q = l(c, p, I, f, y), P = s(c, p, I, f, y), function() {
11454
+ I(r.ReadyState.CLOSING), q(), P(), c.close(), A && clearInterval(A);
11455
11455
  };
11456
11456
  };
11457
11457
  return bt.attachListeners = u, bt;
@@ -11571,22 +11571,22 @@ function Zh() {
11571
11571
  });
11572
11572
  }
11573
11573
  return new (c || (c = Promise))(function(f, y) {
11574
- function h(P) {
11574
+ function h(I) {
11575
11575
  try {
11576
- g(d.next(P));
11576
+ g(d.next(I));
11577
11577
  } catch (A) {
11578
11578
  y(A);
11579
11579
  }
11580
11580
  }
11581
- function v(P) {
11581
+ function v(I) {
11582
11582
  try {
11583
- g(d.throw(P));
11583
+ g(d.throw(I));
11584
11584
  } catch (A) {
11585
11585
  y(A);
11586
11586
  }
11587
11587
  }
11588
- function g(P) {
11589
- P.done ? f(P.value) : p(P.value).then(h, v);
11588
+ function g(I) {
11589
+ I.done ? f(I.value) : p(I.value).then(h, v);
11590
11590
  }
11591
11591
  g((d = d.apply(s, u || [])).next());
11592
11592
  });
@@ -11599,8 +11599,8 @@ function Zh() {
11599
11599
  return this;
11600
11600
  }), y;
11601
11601
  function h(g) {
11602
- return function(P) {
11603
- return v([g, P]);
11602
+ return function(I) {
11603
+ return v([g, I]);
11604
11604
  };
11605
11605
  }
11606
11606
  function v(g) {
@@ -11641,8 +11641,8 @@ function Zh() {
11641
11641
  continue;
11642
11642
  }
11643
11643
  g = u.call(s, c);
11644
- } catch (P) {
11645
- g = [6, P], p = 0;
11644
+ } catch (I) {
11645
+ g = [6, I], p = 0;
11646
11646
  } finally {
11647
11647
  d = f = 0;
11648
11648
  }
@@ -11663,7 +11663,7 @@ function Zh() {
11663
11663
  for (var c = [], d = 2; d < arguments.length; d++)
11664
11664
  c[d - 2] = arguments[d];
11665
11665
  return t(void 0, r([s, u], c, !0), void 0, function(p, f, y) {
11666
- var h, v, g, P, A, q, I, b;
11666
+ var h, v, g, I, A, q, P, b;
11667
11667
  return y === void 0 && (y = 0), n(this, function(E) {
11668
11668
  switch (E.label) {
11669
11669
  case 0:
@@ -11678,7 +11678,7 @@ function Zh() {
11678
11678
  case 4:
11679
11679
  return E.sent(), [2, (0, e.getUrl)(p, f, y + 1)];
11680
11680
  case 5:
11681
- return (b = (I = f.current).onReconnectStop) === null || b === void 0 || b.call(I, y), [2, null];
11681
+ return (b = (P = f.current).onReconnectStop) === null || b === void 0 || b.call(P, y), [2, null];
11682
11682
  case 6:
11683
11683
  return [3, 8];
11684
11684
  case 7:
@@ -11690,7 +11690,7 @@ function Zh() {
11690
11690
  case 10:
11691
11691
  h = p, E.label = 11;
11692
11692
  case 11:
11693
- return P = f.current.fromSocketIO ? (0, i.parseSocketIOUrl)(h) : h, A = f.current.queryParams ? (0, i.appendQueryParams)(P, f.current.queryParams) : P, [2, A];
11693
+ return I = f.current.fromSocketIO ? (0, i.parseSocketIOUrl)(h) : h, A = f.current.queryParams ? (0, i.appendQueryParams)(I, f.current.queryParams) : I, [2, A];
11694
11694
  }
11695
11695
  });
11696
11696
  });
@@ -11731,88 +11731,88 @@ function fi() {
11731
11731
  }, e.apply(this, arguments);
11732
11732
  }, t = Me && Me.__awaiter || function(p, f, y, h) {
11733
11733
  function v(g) {
11734
- return g instanceof y ? g : new y(function(P) {
11735
- P(g);
11734
+ return g instanceof y ? g : new y(function(I) {
11735
+ I(g);
11736
11736
  });
11737
11737
  }
11738
- return new (y || (y = Promise))(function(g, P) {
11738
+ return new (y || (y = Promise))(function(g, I) {
11739
11739
  function A(b) {
11740
11740
  try {
11741
- I(h.next(b));
11741
+ P(h.next(b));
11742
11742
  } catch (E) {
11743
- P(E);
11743
+ I(E);
11744
11744
  }
11745
11745
  }
11746
11746
  function q(b) {
11747
11747
  try {
11748
- I(h.throw(b));
11748
+ P(h.throw(b));
11749
11749
  } catch (E) {
11750
- P(E);
11750
+ I(E);
11751
11751
  }
11752
11752
  }
11753
- function I(b) {
11753
+ function P(b) {
11754
11754
  b.done ? g(b.value) : v(b.value).then(A, q);
11755
11755
  }
11756
- I((h = h.apply(p, f || [])).next());
11756
+ P((h = h.apply(p, f || [])).next());
11757
11757
  });
11758
11758
  }, n = Me && Me.__generator || function(p, f) {
11759
11759
  var y = { label: 0, sent: function() {
11760
11760
  if (g[0] & 1) throw g[1];
11761
11761
  return g[1];
11762
- }, trys: [], ops: [] }, h, v, g, P = Object.create((typeof Iterator == "function" ? Iterator : Object).prototype);
11763
- return P.next = A(0), P.throw = A(1), P.return = A(2), typeof Symbol == "function" && (P[Symbol.iterator] = function() {
11762
+ }, trys: [], ops: [] }, h, v, g, I = Object.create((typeof Iterator == "function" ? Iterator : Object).prototype);
11763
+ return I.next = A(0), I.throw = A(1), I.return = A(2), typeof Symbol == "function" && (I[Symbol.iterator] = function() {
11764
11764
  return this;
11765
- }), P;
11766
- function A(I) {
11765
+ }), I;
11766
+ function A(P) {
11767
11767
  return function(b) {
11768
- return q([I, b]);
11768
+ return q([P, b]);
11769
11769
  };
11770
11770
  }
11771
- function q(I) {
11771
+ function q(P) {
11772
11772
  if (h) throw new TypeError("Generator is already executing.");
11773
- for (; P && (P = 0, I[0] && (y = 0)), y; ) try {
11774
- if (h = 1, v && (g = I[0] & 2 ? v.return : I[0] ? v.throw || ((g = v.return) && g.call(v), 0) : v.next) && !(g = g.call(v, I[1])).done) return g;
11775
- switch (v = 0, g && (I = [I[0] & 2, g.value]), I[0]) {
11773
+ for (; I && (I = 0, P[0] && (y = 0)), y; ) try {
11774
+ if (h = 1, v && (g = P[0] & 2 ? v.return : P[0] ? v.throw || ((g = v.return) && g.call(v), 0) : v.next) && !(g = g.call(v, P[1])).done) return g;
11775
+ switch (v = 0, g && (P = [P[0] & 2, g.value]), P[0]) {
11776
11776
  case 0:
11777
11777
  case 1:
11778
- g = I;
11778
+ g = P;
11779
11779
  break;
11780
11780
  case 4:
11781
- return y.label++, { value: I[1], done: !1 };
11781
+ return y.label++, { value: P[1], done: !1 };
11782
11782
  case 5:
11783
- y.label++, v = I[1], I = [0];
11783
+ y.label++, v = P[1], P = [0];
11784
11784
  continue;
11785
11785
  case 7:
11786
- I = y.ops.pop(), y.trys.pop();
11786
+ P = y.ops.pop(), y.trys.pop();
11787
11787
  continue;
11788
11788
  default:
11789
- if (g = y.trys, !(g = g.length > 0 && g[g.length - 1]) && (I[0] === 6 || I[0] === 2)) {
11789
+ if (g = y.trys, !(g = g.length > 0 && g[g.length - 1]) && (P[0] === 6 || P[0] === 2)) {
11790
11790
  y = 0;
11791
11791
  continue;
11792
11792
  }
11793
- if (I[0] === 3 && (!g || I[1] > g[0] && I[1] < g[3])) {
11794
- y.label = I[1];
11793
+ if (P[0] === 3 && (!g || P[1] > g[0] && P[1] < g[3])) {
11794
+ y.label = P[1];
11795
11795
  break;
11796
11796
  }
11797
- if (I[0] === 6 && y.label < g[1]) {
11798
- y.label = g[1], g = I;
11797
+ if (P[0] === 6 && y.label < g[1]) {
11798
+ y.label = g[1], g = P;
11799
11799
  break;
11800
11800
  }
11801
11801
  if (g && y.label < g[2]) {
11802
- y.label = g[2], y.ops.push(I);
11802
+ y.label = g[2], y.ops.push(P);
11803
11803
  break;
11804
11804
  }
11805
11805
  g[2] && y.ops.pop(), y.trys.pop();
11806
11806
  continue;
11807
11807
  }
11808
- I = f.call(p, y);
11808
+ P = f.call(p, y);
11809
11809
  } catch (b) {
11810
- I = [6, b], v = 0;
11810
+ P = [6, b], v = 0;
11811
11811
  } finally {
11812
11812
  h = g = 0;
11813
11813
  }
11814
- if (I[0] & 5) throw I[1];
11815
- return { value: I[0] ? I[1] : void 0, done: !0 };
11814
+ if (P[0] & 5) throw P[1];
11815
+ return { value: P[0] ? P[1] : void 0, done: !0 };
11816
11816
  }
11817
11817
  }, r = Me && Me.__importDefault || function(p) {
11818
11818
  return p && p.__esModule ? p : { default: p };
@@ -11820,7 +11820,7 @@ function fi() {
11820
11820
  Object.defineProperty(Me, "__esModule", { value: !0 }), Me.useWebSocket = void 0;
11821
11821
  var i = Ge, a = Os, o = rt(), l = Xh(), s = Zh(), u = r(Yh()), c = ci(), d = function(p, f, y) {
11822
11822
  f === void 0 && (f = o.DEFAULT_OPTIONS), y === void 0 && (y = !0);
11823
- var h = (0, i.useState)(null), v = h[0], g = h[1], P = (0, i.useState)({}), A = P[0], q = P[1], I = (0, i.useMemo)(function() {
11823
+ var h = (0, i.useState)(null), v = h[0], g = h[1], I = (0, i.useState)({}), A = I[0], q = I[1], P = (0, i.useMemo)(function() {
11824
11824
  if (!f.disableJson && v)
11825
11825
  try {
11826
11826
  return JSON.parse(v.data);
@@ -11829,25 +11829,25 @@ function fi() {
11829
11829
  }
11830
11830
  return null;
11831
11831
  }, [v, f.disableJson]), b = (0, i.useRef)(null), E = (0, i.useRef)(null), z = (0, i.useRef)(function() {
11832
- }), F = (0, i.useRef)(0), U = (0, i.useRef)(Date.now()), j = (0, i.useRef)([]), H = (0, i.useRef)(null), T = (0, i.useRef)(f);
11832
+ }), F = (0, i.useRef)(0), U = (0, i.useRef)(Date.now()), M = (0, i.useRef)([]), B = (0, i.useRef)(null), T = (0, i.useRef)(f);
11833
11833
  T.current = f;
11834
- var S = b.current && A[b.current] !== void 0 ? A[b.current] : p !== null && y === !0 ? o.ReadyState.CONNECTING : o.ReadyState.UNINSTANTIATED, O = f.queryParams ? JSON.stringify(f.queryParams) : null, N = (0, i.useCallback)(function(B, m) {
11834
+ var S = b.current && A[b.current] !== void 0 ? A[b.current] : p !== null && y === !0 ? o.ReadyState.CONNECTING : o.ReadyState.UNINSTANTIATED, O = f.queryParams ? JSON.stringify(f.queryParams) : null, N = (0, i.useCallback)(function(D, m) {
11835
11835
  var W;
11836
11836
  if (m === void 0 && (m = !0), o.isEventSourceSupported && E.current instanceof EventSource) {
11837
11837
  console.warn("Unable to send a message from an eventSource");
11838
11838
  return;
11839
11839
  }
11840
- ((W = E.current) === null || W === void 0 ? void 0 : W.readyState) === o.ReadyState.OPEN ? ((0, c.assertIsWebSocket)(E.current, T.current.skipAssert), E.current.send(B)) : m && j.current.push(B);
11841
- }, []), M = (0, i.useCallback)(function(B, m) {
11842
- m === void 0 && (m = !0), N(JSON.stringify(B), m);
11843
- }, [N]), D = (0, i.useCallback)(function() {
11844
- return T.current.share !== !0 || o.isEventSourceSupported && E.current instanceof EventSource ? E.current : (H.current === null && E.current && ((0, c.assertIsWebSocket)(E.current, T.current.skipAssert), H.current = (0, u.default)(E.current, z)), H.current);
11840
+ ((W = E.current) === null || W === void 0 ? void 0 : W.readyState) === o.ReadyState.OPEN ? ((0, c.assertIsWebSocket)(E.current, T.current.skipAssert), E.current.send(D)) : m && M.current.push(D);
11841
+ }, []), H = (0, i.useCallback)(function(D, m) {
11842
+ m === void 0 && (m = !0), N(JSON.stringify(D), m);
11843
+ }, [N]), j = (0, i.useCallback)(function() {
11844
+ return T.current.share !== !0 || o.isEventSourceSupported && E.current instanceof EventSource ? E.current : (B.current === null && E.current && ((0, c.assertIsWebSocket)(E.current, T.current.skipAssert), B.current = (0, u.default)(E.current, z)), B.current);
11845
11845
  }, []);
11846
11846
  return (0, i.useEffect)(function() {
11847
11847
  if (p !== null && y === !0) {
11848
- var B, m = !1, W = !0, K = function() {
11848
+ var D, m = !1, W = !0, Y = function() {
11849
11849
  return t(void 0, void 0, void 0, function() {
11850
- var w, Y, oe;
11850
+ var w, K, oe;
11851
11851
  return n(this, function(ne) {
11852
11852
  switch (ne.label) {
11853
11853
  case 0:
@@ -11860,7 +11860,7 @@ function fi() {
11860
11860
  }), [
11861
11861
  2
11862
11862
  /*return*/
11863
- ]) : (Y = function(de) {
11863
+ ]) : (K = function(de) {
11864
11864
  m || (0, a.flushSync)(function() {
11865
11865
  return g(de);
11866
11866
  });
@@ -11871,7 +11871,7 @@ function fi() {
11871
11871
  return e(e({}, pe), b.current && (xe = {}, xe[b.current] = de, xe));
11872
11872
  });
11873
11873
  });
11874
- }, W && (B = (0, l.createOrJoinSocket)(E, b.current, oe, T, Y, z, F, U, N)), [
11874
+ }, W && (D = (0, l.createOrJoinSocket)(E, b.current, oe, T, K, z, F, U, N)), [
11875
11875
  2
11876
11876
  /*return*/
11877
11877
  ]);
@@ -11880,25 +11880,25 @@ function fi() {
11880
11880
  });
11881
11881
  };
11882
11882
  return z.current = function() {
11883
- m || (H.current && (H.current = null), B == null || B(), K());
11884
- }, K(), function() {
11885
- m = !0, W = !1, H.current && (H.current = null), B == null || B(), g(null);
11883
+ m || (B.current && (B.current = null), D == null || D(), Y());
11884
+ }, Y(), function() {
11885
+ m = !0, W = !1, B.current && (B.current = null), D == null || D(), g(null);
11886
11886
  };
11887
11887
  } else (p === null || y === !1) && (F.current = 0, q(function(w) {
11888
- var Y;
11889
- return e(e({}, w), b.current && (Y = {}, Y[b.current] = o.ReadyState.CLOSED, Y));
11888
+ var K;
11889
+ return e(e({}, w), b.current && (K = {}, K[b.current] = o.ReadyState.CLOSED, K));
11890
11890
  }));
11891
11891
  }, [p, y, O, N]), (0, i.useEffect)(function() {
11892
- S === o.ReadyState.OPEN && j.current.splice(0).forEach(function(B) {
11893
- N(B);
11892
+ S === o.ReadyState.OPEN && M.current.splice(0).forEach(function(D) {
11893
+ N(D);
11894
11894
  });
11895
11895
  }, [S]), {
11896
11896
  sendMessage: N,
11897
- sendJsonMessage: M,
11897
+ sendJsonMessage: H,
11898
11898
  lastMessage: v,
11899
- lastJsonMessage: I,
11899
+ lastJsonMessage: P,
11900
11900
  readyState: S,
11901
- getWebSocket: D
11901
+ getWebSocket: j
11902
11902
  };
11903
11903
  };
11904
11904
  return Me.useWebSocket = d, Me;
@@ -11980,8 +11980,8 @@ function Jh() {
11980
11980
  c && (f.current = c);
11981
11981
  var y = (0, r.useWebSocket)(o, p, s), h = y.lastMessage, v = y.readyState, g = y.getWebSocket;
11982
11982
  return (0, n.useEffect)(function() {
11983
- h != null && h.type && Object.entries(f.current).forEach(function(P) {
11984
- var A = P[0], q = P[1];
11983
+ h != null && h.type && Object.entries(f.current).forEach(function(I) {
11984
+ var A = I[0], q = I[1];
11985
11985
  A === h.type && q(h);
11986
11986
  });
11987
11987
  }, [h]), {
@@ -12038,26 +12038,26 @@ const r0 = "This conversation with a live agent has ended. Please note that a tr
12038
12038
  CONNECTING: "CONNECTING",
12039
12039
  CONVERSATION: "CONVERSATION",
12040
12040
  FORM: "FORM"
12041
- }, Et = In({}), xl = ({ children: e }) => {
12042
- const { conversationScreen: t } = Q(Se), { pushXpertMessage: n } = Q(St), { setHasError: r, setMode: i } = Q(Ie), [a, o] = ee(""), [l, s] = ee(!1), [, u] = ee(""), [c, d] = ee([]), [p, f] = ee(null), [y, h] = ee(st.FORM), [v, g] = ee(null), P = (M) => d((D) => [...D, M]), A = async (M) => {
12043
- const D = await n0(M.data), { conversation_id: B, event_type: m, body: W } = D;
12044
- switch (m) {
12041
+ }, Et = Pn({}), xl = ({ children: e, liveChatPayload: t }) => {
12042
+ const { conversationScreen: n } = Q(Se), { pushXpertMessage: r } = Q(St), { setHasError: i, setMode: a } = Q(Pe), [o, l] = ee(""), [s, u] = ee(!1), [, c] = ee(""), [d, p] = ee([]), [f, y] = ee(null), [h, v] = ee(st.FORM), [g, I] = ee(null), A = (j) => p((D) => [...D, j]), q = async (j) => {
12043
+ const D = await n0(j.data), { conversation_id: m, event_type: W, body: Y } = D;
12044
+ switch (W) {
12045
12045
  case "AGENT_TYPING":
12046
- return F();
12046
+ return U();
12047
12047
  case "CONVERSATION_ACCEPTED":
12048
- return U(W);
12048
+ return M(Y);
12049
12049
  case "CONVERSATION_CREATED":
12050
- return u(B);
12050
+ return c(m);
12051
12051
  case "CONVERSATION_ERROR":
12052
12052
  return;
12053
12053
  case "CONVERSATION_TERMINATED":
12054
- return E();
12054
+ return z();
12055
12055
  case "CONVERSATION_TRANSFERRED_TO_GROUP":
12056
12056
  return;
12057
12057
  case "CONVERSATION_TRANSFERRED_TO_AGENT":
12058
12058
  return;
12059
12059
  case "MESSAGE_ADDED":
12060
- return j(W);
12060
+ return B(Y);
12061
12061
  case "PARTICIPANT_JOINED":
12062
12062
  return;
12063
12063
  case "PARTICIPANT_LEFT":
@@ -12065,39 +12065,42 @@ const r0 = "This conversation with a live agent has ended. Please note that a tr
12065
12065
  default:
12066
12066
  return;
12067
12067
  }
12068
- }, { sendJsonMessage: q } = t0(p, {
12069
- onMessage: A
12070
- }), I = () => {
12071
- h(st.FORM);
12072
- }, b = () => {
12073
- q({
12068
+ }, { sendJsonMessage: P } = t0(f, {
12069
+ onMessage: q
12070
+ }), b = () => {
12071
+ var D;
12072
+ v(st.FORM);
12073
+ const j = (D = n == null ? void 0 : n.liveChat) == null ? void 0 : D.form;
12074
+ (!j || j.length === 0) && a(ut.XPERT);
12075
+ }, E = () => {
12076
+ P({
12074
12077
  action: "sendmessage",
12075
12078
  event: "TERMINATE_CONVERSATION"
12076
12079
  });
12077
- }, E = () => {
12078
- n({
12080
+ }, z = () => {
12081
+ r({
12079
12082
  content: r0,
12080
12083
  role: "info"
12081
- }), z();
12082
- }, z = () => {
12083
- u(""), f(null), h(st.FORM), i(dt.XPERT);
12084
+ }), F();
12084
12085
  }, F = () => {
12085
- v && clearTimeout(v), s(!0);
12086
- const M = setTimeout(() => {
12087
- s(!1);
12086
+ c(""), y(null), v(st.FORM), a(ut.XPERT);
12087
+ }, U = () => {
12088
+ g && clearTimeout(g), u(!0);
12089
+ const j = setTimeout(() => {
12090
+ u(!1);
12088
12091
  }, 5e3);
12089
- g(M);
12090
- }, U = (M) => {
12091
- const { displayName: D } = M;
12092
- d([]), o(D ?? "An agent"), h(st.CONVERSATION);
12093
- }, j = (M) => {
12094
- const { messageId: D, text: B, timestamp: m } = M;
12095
- P({
12096
- content: B ?? "",
12092
+ I(j);
12093
+ }, M = (j) => {
12094
+ const { displayName: D } = j;
12095
+ p([]), l(D ?? "An agent"), v(st.CONVERSATION);
12096
+ }, B = (j) => {
12097
+ const { messageId: D, text: m, timestamp: W } = j;
12098
+ A({
12099
+ content: m ?? "",
12097
12100
  id: D ?? "",
12098
12101
  role: "agent",
12099
- timestamp: m ? new Date(m) : void 0
12100
- }), q({
12102
+ timestamp: W ? new Date(W) : void 0
12103
+ }), P({
12101
12104
  action: "sendmessage",
12102
12105
  messages: [
12103
12106
  {
@@ -12106,65 +12109,66 @@ const r0 = "This conversation with a live agent has ended. Please note that a tr
12106
12109
  }
12107
12110
  ],
12108
12111
  event: "ACKNOWLEDGE_MESSAGE"
12109
- }), s(!1);
12110
- }, N = {
12111
- agentName: a,
12112
- agentTyping: l,
12113
- cancelLiveChatConnection: I,
12114
- endLiveChat: E,
12115
- liveChatMessages: c,
12116
- pushLiveChatMessage: P,
12117
- sendMessage: (M) => {
12118
- P({
12119
- content: M,
12112
+ }), u(!1);
12113
+ }, H = {
12114
+ agentName: o,
12115
+ agentTyping: s,
12116
+ cancelLiveChatConnection: b,
12117
+ endLiveChat: z,
12118
+ liveChatMessages: d,
12119
+ pushLiveChatMessage: A,
12120
+ sendMessage: (j) => {
12121
+ A({
12122
+ content: j,
12120
12123
  id: "",
12121
12124
  role: "user",
12122
12125
  timestamp: /* @__PURE__ */ new Date()
12123
- }), q({
12126
+ }), P({
12124
12127
  action: "sendmessage",
12125
12128
  event: "OUTGOING_MESSAGE",
12126
- message: M
12129
+ message: j
12127
12130
  });
12128
12131
  },
12129
12132
  sendTypingEvent: async () => {
12130
- q({
12133
+ P({
12131
12134
  action: "sendmessage",
12132
12135
  event: "TYPING"
12133
12136
  });
12134
12137
  },
12135
- setLiveChatMessages: d,
12136
- step: y,
12137
- setStep: h,
12138
- startLiveChat: (M) => {
12138
+ setLiveChatMessages: p,
12139
+ step: h,
12140
+ setStep: v,
12141
+ startLiveChat: (j) => {
12139
12142
  var D;
12140
12143
  try {
12141
- h(st.CONNECTING);
12142
- const B = new URLSearchParams(M);
12143
- B.append("url", window.location.href), f(
12144
- `${(D = t == null ? void 0 : t.liveChat) == null ? void 0 : D.socketUrl}?${B.toString()}`
12144
+ v(st.CONNECTING);
12145
+ const m = new URLSearchParams({ ...t, ...j });
12146
+ m.append("url", window.location.href), y(
12147
+ `${(D = n == null ? void 0 : n.liveChat) == null ? void 0 : D.socketUrl}?${m.toString()}`
12145
12148
  );
12146
- } catch (B) {
12147
- console.error(B.message), r(!0), z();
12149
+ } catch (m) {
12150
+ console.error(m.message), i(!0), F();
12148
12151
  }
12149
12152
  },
12150
12153
  submitSurvey: () => {
12151
- n({
12154
+ r({
12152
12155
  content: "Feedback submitted",
12153
12156
  icon: "check",
12154
12157
  iconColor: "#30A171",
12155
12158
  role: "notification"
12156
- }), E();
12159
+ }), z();
12157
12160
  },
12158
- terminateConversation: b
12161
+ terminateConversation: E
12159
12162
  };
12160
- return /* @__PURE__ */ k.jsx(Et.Provider, { value: N, children: e });
12163
+ return /* @__PURE__ */ k.jsx(Et.Provider, { value: H, children: e });
12161
12164
  };
12162
12165
  xl.propTypes = {
12163
- children: C.element.isRequired
12166
+ children: C.element.isRequired,
12167
+ liveChatPayload: C.object
12164
12168
  };
12165
12169
  const i0 = "data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20fill='%23ffffff'%20height='48'%20viewBox='0%20-960%20960%20960'%20width='48'%3e%3cpath%20d='M120-120v-300h60v198l558-558H540v-60h300v300h-60v-198L222-180h198v60H120Z'/%3e%3c/svg%3e", a0 = "data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20fill='%23ffffff'%20height='48'%20viewBox='0%20-960%20960%20960'%20width='48'%3e%3cpath%20d='M370-287h360v-90H370v90ZM180-120q-24%200-42-18t-18-42v-600q0-24%2018-42t42-18h600q24%200%2042%2018t18%2042v600q0%2024-18%2042t-42%2018H180Zm0-60h600v-600H180v600Zm0-600v600-600Z'/%3e%3c/svg%3e";
12166
12170
  function wl({ handleResizeButtonClick: e, setIsMounted: t }) {
12167
- const { isMobile: n, isNormalSize: r } = Q(Ie);
12171
+ const { isMobile: n, isNormalSize: r } = Q(Pe);
12168
12172
  return n ? null : r ? /* @__PURE__ */ k.jsx(
12169
12173
  "button",
12170
12174
  {
@@ -12221,7 +12225,7 @@ function Cl({
12221
12225
  isMounted: r
12222
12226
  }) {
12223
12227
  var u;
12224
- const { conversationScreen: i } = Q(Se), { mode: a } = Q(Ie), { setDeleteConversationModal: o, xpertMessages: l } = Q(St), s = a === dt.XPERT && ((u = i == null ? void 0 : i.conversationHistory) == null ? void 0 : u.allowDeletion) && !!(l != null && l.length);
12228
+ const { conversationScreen: i } = Q(Se), { mode: a } = Q(Pe), { setDeleteConversationModal: o, xpertMessages: l } = Q(St), s = a === ut.XPERT && ((u = i == null ? void 0 : i.conversationHistory) == null ? void 0 : u.allowDeletion) && !!(l != null && l.length);
12225
12229
  return /* @__PURE__ */ k.jsxs(k.Fragment, { children: [
12226
12230
  s && /* @__PURE__ */ k.jsx(
12227
12231
  "button",
@@ -12327,9 +12331,9 @@ function kl({
12327
12331
  setIsMounted: n,
12328
12332
  onClose: r
12329
12333
  }) {
12330
- var u, c, d, p, f, y, h, v, g, P, A, q, I, b, E;
12331
- const { primaryColor: i, conversationScreen: a } = Q(Se), { isMobile: o, mode: l } = Q(Ie), { step: s } = Q(Et);
12332
- return s === st.CONNECTING && l === dt.LIVECHAT ? null : /* @__PURE__ */ k.jsxs(
12334
+ var u, c, d, p, f, y, h, v, g, I, A, q, P, b, E;
12335
+ const { primaryColor: i, conversationScreen: a } = Q(Se), { isMobile: o, mode: l } = Q(Pe), { step: s } = Q(Et);
12336
+ return s === st.CONNECTING && l === ut.LIVECHAT ? null : /* @__PURE__ */ k.jsxs(
12333
12337
  "div",
12334
12338
  {
12335
12339
  "data-testid": "xpert-conversations-header",
@@ -12365,7 +12369,7 @@ function kl({
12365
12369
  di,
12366
12370
  {
12367
12371
  backgroundColor: (g = a == null ? void 0 : a.header.logo.style) == null ? void 0 : g.backgroundColor,
12368
- textColor: ((q = (A = (P = a == null ? void 0 : a.header) == null ? void 0 : P.logo) == null ? void 0 : A.style) == null ? void 0 : q.color) || "#FFFFFF"
12372
+ textColor: ((q = (A = (I = a == null ? void 0 : a.header) == null ? void 0 : I.logo) == null ? void 0 : A.style) == null ? void 0 : q.color) || "#FFFFFF"
12369
12373
  }
12370
12374
  ),
12371
12375
  /* @__PURE__ */ k.jsx(
@@ -12383,7 +12387,7 @@ function kl({
12383
12387
  className: "xpert-chatbot-popup__header_container",
12384
12388
  style: {
12385
12389
  right: 0,
12386
- background: ((E = (b = (I = a == null ? void 0 : a.header) == null ? void 0 : I.container) == null ? void 0 : b.style) == null ? void 0 : E.background) || i
12390
+ background: ((E = (b = (P = a == null ? void 0 : a.header) == null ? void 0 : P.container) == null ? void 0 : b.style) == null ? void 0 : E.background) || i
12387
12391
  }
12388
12392
  }
12389
12393
  )
@@ -12431,7 +12435,7 @@ function o0() {
12431
12435
  }
12432
12436
  const l0 = () => {
12433
12437
  var n, r, i, a, o;
12434
- const { isMobile: e } = Q(Ie), { launchButton: t } = Q(Se);
12438
+ const { isMobile: e } = Q(Pe), { launchButton: t } = Q(Se);
12435
12439
  return (n = t == null ? void 0 : t.message) != null && n.enabled ? /* @__PURE__ */ k.jsx(
12436
12440
  "div",
12437
12441
  {
@@ -12448,20 +12452,20 @@ function s0() {
12448
12452
  return /* @__PURE__ */ k.jsx("div", { className: "spinner" });
12449
12453
  }
12450
12454
  function pi() {
12451
- var i;
12452
- const { conversationScreen: e, primaryColor: t } = Q(Se), { cancelLiveChatConnection: n } = Q(Et), r = ((i = e == null ? void 0 : e.liveChat) == null ? void 0 : i.queueMessages) ?? [];
12453
- return /* @__PURE__ */ k.jsxs(
12454
- "div",
12455
- {
12456
- className: "live-chat-connecting",
12457
- style: { backgroundColor: t },
12458
- children: [
12459
- /* @__PURE__ */ k.jsx(s0, {}),
12460
- /* @__PURE__ */ k.jsx("div", { className: "live-chat-connecting-messages", children: r.length === 0 ? /* @__PURE__ */ k.jsx("p", { children: "Connecting to live agent" }) : r.map((a, o) => /* @__PURE__ */ k.jsx("p", { children: a }, `queue-message-${o}`)) }),
12461
- /* @__PURE__ */ k.jsx("button", { onClick: n, children: "Cancel" })
12462
- ]
12463
- }
12464
- );
12455
+ var l;
12456
+ const { conversationScreen: e, primaryColor: t, widgetMode: n } = Q(Se), { cancelLiveChatConnection: r } = Q(Et), i = ((l = e == null ? void 0 : e.liveChat) == null ? void 0 : l.queueMessages) ?? [], a = n ? t : "#FFFFFF", o = n ? "#FFFFFF" : t;
12457
+ return /* @__PURE__ */ k.jsxs("div", { className: "live-chat-connecting", style: { backgroundColor: a }, children: [
12458
+ /* @__PURE__ */ k.jsx(s0, {}),
12459
+ /* @__PURE__ */ k.jsx("div", { className: "live-chat-connecting-messages", style: { color: o }, children: i.length === 0 ? /* @__PURE__ */ k.jsx("p", { children: "Connecting to live agent" }) : i.map((s, u) => /* @__PURE__ */ k.jsx("p", { children: s }, `queue-message-${u}`)) }),
12460
+ /* @__PURE__ */ k.jsx(
12461
+ "button",
12462
+ {
12463
+ onClick: r,
12464
+ style: { color: o, outlineColor: o },
12465
+ children: "Cancel"
12466
+ }
12467
+ )
12468
+ ] });
12465
12469
  }
12466
12470
  pi.propTypes = {};
12467
12471
  pi.defaultProps = {};
@@ -12505,14 +12509,14 @@ function hi({ onDismiss: e }) {
12505
12509
  r && /* @__PURE__ */ k.jsxs(k.Fragment, { children: [
12506
12510
  /* @__PURE__ */ k.jsx("p", { children: "Before you go, let me know how I did:" }),
12507
12511
  /* @__PURE__ */ k.jsx("div", { className: "livechat-end-confirmation-container__icon-button-container", children: u0.map(({ key: y, icon: h, text: v }) => {
12508
- const g = y === a, P = g ? { backgroundColor: "#E7E4DB", borderColor: "#767676" } : {};
12512
+ const g = y === a, I = g ? { backgroundColor: "#E7E4DB", borderColor: "#767676" } : {};
12509
12513
  return /* @__PURE__ */ k.jsxs(
12510
12514
  "button",
12511
12515
  {
12512
12516
  "aria-checked": g,
12513
12517
  "aria-label": v,
12514
12518
  role: "radio",
12515
- style: P,
12519
+ style: I,
12516
12520
  onClick: () => o(y),
12517
12521
  children: [
12518
12522
  /* @__PURE__ */ k.jsx("span", { children: h }),
@@ -12675,25 +12679,29 @@ const d0 = "data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20wid
12675
12679
  }];
12676
12680
  }, wr = "privacy policy";
12677
12681
  function gi() {
12678
- const { conversationScreen: e, primaryColor: t } = Q(Se), { startLiveChat: n } = Q(Et), { setMode: r } = Q(Ie), { form: i, formHeader: a, privacyPolicyLink: o, privacyPolicyText: l } = e.liveChat, [s, , u] = h0({}), [c, d] = ee(!1), { clearError: p, errors: f, setErrors: y } = p0(), h = Es(
12682
+ const { conversationScreen: e, primaryColor: t } = Q(Se), { startLiveChat: n } = Q(Et), { setMode: r } = Q(Pe), { form: i, formHeader: a, privacyPolicyLink: o, privacyPolicyText: l } = e.liveChat, [s, , u] = h0({}), [c, d] = ee(!1), { clearError: p, errors: f, setErrors: y } = p0(), h = Es(
12679
12683
  () => (l ?? "").split(wr, 2),
12680
12684
  [l]
12681
12685
  ), v = () => {
12682
- r(dt.XPERT);
12686
+ r(ut.XPERT);
12683
12687
  }, g = () => {
12684
- p("privacyCheck"), d((I) => !I);
12685
- }, P = (I, b) => {
12686
- const E = I.target.value;
12688
+ p("privacyCheck"), d((P) => !P);
12689
+ }, I = (P, b) => {
12690
+ const E = P.target.value;
12687
12691
  p(b), u(b, E);
12688
12692
  }, A = () => {
12689
12693
  q() && n(s);
12690
- }, q = () => {
12691
- const I = i.reduce((b, E) => {
12694
+ };
12695
+ ke(() => {
12696
+ (!i || i.length === 0) && n();
12697
+ }, [i, n]);
12698
+ const q = () => {
12699
+ const P = i.reduce((b, E) => {
12692
12700
  const { key: z, validations: F = [] } = E, U = s[z];
12693
12701
  if (!U) return { ...b, [z]: "Required" };
12694
12702
  if ((F == null ? void 0 : F.length) > 0)
12695
- for (const j of F)
12696
- switch (j) {
12703
+ for (const M of F)
12704
+ switch (M) {
12697
12705
  case "email": {
12698
12706
  if (!f0(U))
12699
12707
  return { ...b, [z]: "Should be email" };
@@ -12702,22 +12710,22 @@ function gi() {
12702
12710
  }
12703
12711
  return b;
12704
12712
  }, {});
12705
- return !c && l && (I.privacyCheck = "Required"), y(I), Object.keys(I).length === 0;
12713
+ return !c && l && (P.privacyCheck = "Required"), y(P), Object.keys(P).length === 0;
12706
12714
  };
12707
12715
  return /* @__PURE__ */ k.jsxs("div", { className: "live-chat-form", children: [
12708
12716
  a && /* @__PURE__ */ k.jsx("p", { children: a }),
12709
- (i ?? []).map(({ key: I, name: b }) => /* @__PURE__ */ k.jsxs(Ts, { children: [
12717
+ (i ?? []).map(({ key: P, name: b }) => /* @__PURE__ */ k.jsxs(Ts, { children: [
12710
12718
  /* @__PURE__ */ k.jsx(
12711
12719
  "input",
12712
12720
  {
12713
- className: `live-chat-form-input ${f[I] ? "error" : ""}`,
12721
+ className: `live-chat-form-input ${f[P] ? "error" : ""}`,
12714
12722
  name: b,
12715
12723
  placeholder: b,
12716
- onChange: (E) => P(E, I)
12724
+ onChange: (E) => I(E, P)
12717
12725
  }
12718
12726
  ),
12719
- f[I] && /* @__PURE__ */ k.jsx("p", { className: "live-chat-form-error", children: f[I] })
12720
- ] }, I)),
12727
+ f[P] && /* @__PURE__ */ k.jsx("p", { className: "live-chat-form-error", children: f[P] })
12728
+ ] }, P)),
12721
12729
  l && /* @__PURE__ */ k.jsxs(k.Fragment, { children: [
12722
12730
  /* @__PURE__ */ k.jsx(
12723
12731
  "div",
@@ -12762,7 +12770,7 @@ function gi() {
12762
12770
  },
12763
12771
  type: "checkbox",
12764
12772
  onChange: g,
12765
- onKeyDown: (I) => I.key === "Enter" && g()
12773
+ onKeyDown: (P) => P.key === "Enter" && g()
12766
12774
  }
12767
12775
  ),
12768
12776
  /* @__PURE__ */ k.jsx("label", { htmlFor: "privacy-check", children: "Yes, I accept" })
@@ -12827,11 +12835,11 @@ function Sl({
12827
12835
  var h;
12828
12836
  s(!1), (!(window != null && window.OnetrustActiveGroups) || (h = window == null ? void 0 : window.OnetrustActiveGroups) != null && h.includes("C0003")) && f(t, 1, 1), r();
12829
12837
  }, f = (h, v, g) => {
12830
- const P = {
12838
+ const I = {
12831
12839
  expires: g,
12832
12840
  path: "/"
12833
12841
  };
12834
- Re.set(h, v, P);
12842
+ Re.set(h, v, I);
12835
12843
  };
12836
12844
  return !u || !d || !i ? null : /* @__PURE__ */ k.jsx("div", { children: /* @__PURE__ */ k.jsxs(
12837
12845
  "div",
@@ -12996,7 +13004,7 @@ const ro = (e) => {
12996
13004
  })), t;
12997
13005
  };
12998
13006
  function bi({ submitEventExternal: e }) {
12999
- var ht, mt, It, Ze;
13007
+ var ht, mt, Pt, Ze;
13000
13008
  const {
13001
13009
  chatApi: t,
13002
13010
  configurationLoaded: n,
@@ -13017,21 +13025,21 @@ function bi({ submitEventExternal: e }) {
13017
13025
  isMobile: h,
13018
13026
  mode: v,
13019
13027
  setDisableScroll: g,
13020
- setHasError: P,
13028
+ setHasError: I,
13021
13029
  setHasNewMessage: A,
13022
13030
  setIsNormalSize: q,
13023
- setLoading: I
13024
- } = Q(Ie), [, b] = ee(!1), [, E] = ee(!1), [z, F] = ee(!1), [U, j] = ee(!1), [H, T] = ee(""), [S, O] = ee(!1), N = z || !u, M = ze(null), D = ze(null), B = ze(null), m = Re.get(`${i}-test`) === "1";
13031
+ setLoading: P
13032
+ } = Q(Pe), [, b] = ee(!1), [, E] = ee(!1), [z, F] = ee(!1), [U, M] = ee(!1), [B, T] = ee(""), [S, O] = ee(!1), N = z || !u, H = ze(null), j = ze(null), D = ze(null), m = Re.get(`${i}-test`) === "1";
13025
13033
  m0(
13026
13034
  (ht = r == null ? void 0 : r.liveChat) == null ? void 0 : ht.enabled,
13027
13035
  U,
13028
- j
13036
+ M
13029
13037
  );
13030
13038
  const W = Ct(
13031
13039
  ({ name: X, payload: re }) => {
13032
13040
  if (!n || !(l != null && l.enabled)) return;
13033
13041
  const ce = zr(l == null ? void 0 : l.payloadParams, re);
13034
- e ? e({ name: X, payload: ce }) : B.current.track(
13042
+ e ? e({ name: X, payload: ce }) : D.current.track(
13035
13043
  // TODO: this is untestable - create a custom hook to get submit event function.
13036
13044
  X,
13037
13045
  ce
@@ -13043,7 +13051,7 @@ function bi({ submitEventExternal: e }) {
13043
13051
  l == null ? void 0 : l.enabled,
13044
13052
  l == null ? void 0 : l.payloadParams
13045
13053
  ]
13046
- ), K = async () => {
13054
+ ), Y = async () => {
13047
13055
  var X;
13048
13056
  if (window != null && window.OnetrustActiveGroups && window.OnetrustActiveGroups.split(",").includes("C0003") && (X = r == null ? void 0 : r.conversationHistory) != null && X.enabled)
13049
13057
  try {
@@ -13069,20 +13077,20 @@ function bi({ submitEventExternal: e }) {
13069
13077
  } catch (re) {
13070
13078
  console.error(re);
13071
13079
  } finally {
13072
- I(!1);
13080
+ P(!1);
13073
13081
  }
13074
13082
  };
13075
13083
  y0(
13076
13084
  () => {
13077
13085
  var X;
13078
- return ((X = r == null ? void 0 : r.conversationHistory) == null ? void 0 : X.enabled) && N && !U && K();
13086
+ return ((X = r == null ? void 0 : r.conversationHistory) == null ? void 0 : X.enabled) && N && !U && Y();
13079
13087
  }
13080
13088
  ), ke(() => {
13081
13089
  let X, re;
13082
13090
  if (n)
13083
13091
  return l != null && l.enabled && (X = setInterval(() => {
13084
13092
  var Ee;
13085
- ((Ee = window.analytics) != null && Ee.track || e) && (B.current = window.analytics, clearInterval(X), clearTimeout(re), b(!0));
13093
+ ((Ee = window.analytics) != null && Ee.track || e) && (D.current = window.analytics, clearInterval(X), clearTimeout(re), b(!0));
13086
13094
  }, 1e3), re = setTimeout(() => {
13087
13095
  clearInterval(X);
13088
13096
  }, 6e4)), () => {
@@ -13121,10 +13129,10 @@ function bi({ submitEventExternal: e }) {
13121
13129
  }
13122
13130
  });
13123
13131
  };
13124
- if (g0(s == null ? void 0 : s.experimentName), !n || s != null && s.enabled && !(s != null && s.experimentName) && !m || l != null && l.enabled && (l != null && l.prefix) && !((mt = B == null ? void 0 : B.current) != null && mt.track) && !e)
13132
+ if (g0(s == null ? void 0 : s.experimentName), !n || s != null && s.enabled && !(s != null && s.experimentName) && !m || l != null && l.enabled && (l != null && l.prefix) && !((mt = D == null ? void 0 : D.current) != null && mt.track) && !e)
13125
13133
  return null;
13126
- const Y = () => {
13127
- T(""), D.current.value = "", D.current.style.height = "auto";
13134
+ const K = () => {
13135
+ T(""), j.current.value = "", j.current.style.height = "auto";
13128
13136
  }, oe = (X, re) => {
13129
13137
  W({
13130
13138
  name: `${l.prefix}.bi.xpert.chatbot.popup.chat.message.response`,
@@ -13162,7 +13170,7 @@ function bi({ submitEventExternal: e }) {
13162
13170
  if (X.trim().length === 0)
13163
13171
  return;
13164
13172
  const re = /* @__PURE__ */ new Date();
13165
- A(!1), P(!1);
13173
+ A(!1), I(!1);
13166
13174
  const ce = y.filter((we) => we.role === "user").length + 1;
13167
13175
  if (W({
13168
13176
  name: `${l.prefix}.bi.xpert.chatbot.popup.chat.message.sent`,
@@ -13173,8 +13181,8 @@ function bi({ submitEventExternal: e }) {
13173
13181
  userInputMessage: X,
13174
13182
  isTestUser: m
13175
13183
  }
13176
- }), Y(), I(!0), d) {
13177
- await d(X), I(!1);
13184
+ }), K(), P(!0), d) {
13185
+ await d(X), P(!1);
13178
13186
  return;
13179
13187
  }
13180
13188
  let Ee = null;
@@ -13192,7 +13200,7 @@ function bi({ submitEventExternal: e }) {
13192
13200
  role: we.role,
13193
13201
  content: we.content,
13194
13202
  ...we.toolCalls && { tool_calls: we.toolCalls }
13195
- })).filter(({ role: we }) => ["assistant", "user"].includes(we)), ut = await fetch(t.endpoint, {
13203
+ })).filter(({ role: we }) => ["assistant", "user"].includes(we)), ct = await fetch(t.endpoint, {
13196
13204
  method: "POST",
13197
13205
  headers: {
13198
13206
  "Content-Type": "application/json"
@@ -13205,13 +13213,13 @@ function bi({ submitEventExternal: e }) {
13205
13213
  }
13206
13214
  })
13207
13215
  });
13208
- if (!ut.ok)
13209
- throw new Error(`HTTPError: ${ut.status} ${ut.statusText}`);
13216
+ if (!ct.ok)
13217
+ throw new Error(`HTTPError: ${ct.status} ${ct.statusText}`);
13210
13218
  const {
13211
13219
  content: R,
13212
13220
  live_agent: V,
13213
13221
  tool_calls: Z
13214
- } = await ut.json();
13222
+ } = await ct.json();
13215
13223
  oe(R, Ee);
13216
13224
  const ae = /* @__PURE__ */ new Date();
13217
13225
  ne({
@@ -13226,12 +13234,12 @@ function bi({ submitEventExternal: e }) {
13226
13234
  liveAgent: V,
13227
13235
  role: "assistant",
13228
13236
  toolCalls: Z
13229
- }), g(!1), I(!1), Y(), A(!0);
13237
+ }), g(!1), P(!1), K(), A(!0);
13230
13238
  } catch (re) {
13231
- I(!1), Y(), P(!0), console.error(re);
13239
+ P(!1), K(), I(!0), console.error(re);
13232
13240
  }
13233
13241
  }, pe = () => {
13234
- j(!1), F(!0), K(), W({
13242
+ M(!1), F(!0), Y(), W({
13235
13243
  name: `${l.prefix}.bi.xpert.chatbot.action.button.clicked`,
13236
13244
  payload: {
13237
13245
  category: "2u",
@@ -13249,7 +13257,7 @@ function bi({ submitEventExternal: e }) {
13249
13257
  }
13250
13258
  }), q(X);
13251
13259
  }, he = () => {
13252
- F(!0), K(), W({
13260
+ F(!0), Y(), W({
13253
13261
  name: `${l.prefix}.bi.xpert.chatbot.proactive.message.clicked`,
13254
13262
  payload: {
13255
13263
  category: "2u",
@@ -13297,7 +13305,7 @@ function bi({ submitEventExternal: e }) {
13297
13305
  feedbackThumbType: re
13298
13306
  }) : Ee);
13299
13307
  f(ce), g(!1);
13300
- }, Tt = (It = a == null ? void 0 : a.animatedGraduate) == null ? void 0 : It.enabled, Ot = o != null && o.enabled ? h ? (Ze = o == null ? void 0 : o.style) == null ? void 0 : Ze.mobile : o == null ? void 0 : o.style : null;
13308
+ }, Tt = (Pt = a == null ? void 0 : a.animatedGraduate) == null ? void 0 : Pt.enabled, Ot = o != null && o.enabled ? h ? (Ze = o == null ? void 0 : o.style) == null ? void 0 : Ze.mobile : o == null ? void 0 : o.style : null;
13301
13309
  return (
13302
13310
  // do not remove this class as it's needed to turn off chatbot
13303
13311
  /* @__PURE__ */ k.jsxs("div", { className: `xpert-chatbot${u ? "" : "--inline"}`, children: [
@@ -13351,7 +13359,7 @@ function bi({ submitEventExternal: e }) {
13351
13359
  N && !U && /* @__PURE__ */ k.jsx(Co, { isMounted: S, children: /* @__PURE__ */ k.jsx(
13352
13360
  "div",
13353
13361
  {
13354
- ref: M,
13362
+ ref: H,
13355
13363
  style: { display: "flex", flexDirection: "column", height: "100%" },
13356
13364
  children: /* @__PURE__ */ k.jsxs(k.Fragment, { children: [
13357
13365
  u && /* @__PURE__ */ k.jsx(
@@ -13364,21 +13372,21 @@ function bi({ submitEventExternal: e }) {
13364
13372
  }
13365
13373
  ),
13366
13374
  /* @__PURE__ */ k.jsx(o0, {}),
13367
- v === dt.XPERT && /* @__PURE__ */ k.jsx(
13375
+ v === ut.XPERT && /* @__PURE__ */ k.jsx(
13368
13376
  oi,
13369
13377
  {
13370
13378
  handleChange: Xe,
13371
13379
  handleFeedbackThumbSelection: Bt,
13372
13380
  handleMessageLinkClicked: w,
13373
13381
  handleSend: de,
13374
- inputRef: D,
13382
+ inputRef: j,
13375
13383
  isTestUser: m,
13376
- setLiveChatOpen: j,
13384
+ setLiveChatOpen: M,
13377
13385
  submitEvent: W,
13378
- userInput: H
13386
+ userInput: B
13379
13387
  }
13380
13388
  ),
13381
- v === dt.LIVECHAT && /* @__PURE__ */ k.jsx(yi, {})
13389
+ v === ut.LIVECHAT && /* @__PURE__ */ k.jsx(yi, {})
13382
13390
  ] })
13383
13391
  }
13384
13392
  ) })
@@ -13396,29 +13404,33 @@ const _l = ({
13396
13404
  clientId: t = null,
13397
13405
  configurations: n = {},
13398
13406
  conversation: r,
13399
- onFeedbackSelection: i,
13400
- onMessageSent: a,
13401
- xpertKey: o,
13402
- widgetMode: l = !0
13407
+ liveChatPayload: i,
13408
+ onFeedbackSelection: a,
13409
+ onMessageSent: o,
13410
+ xpertKey: l,
13411
+ widgetMode: s = !0
13403
13412
  }) => {
13404
- const s = {
13413
+ const u = {
13405
13414
  clientId: t,
13406
13415
  configurations: n,
13407
- xpertKey: o,
13408
- widgetMode: l
13409
- }, u = {
13416
+ xpertKey: l,
13417
+ widgetMode: s
13418
+ }, c = {
13410
13419
  conversation: r,
13411
- onFeedbackSelection: i,
13412
- onMessageSent: a
13420
+ onFeedbackSelection: a,
13421
+ onMessageSent: o
13422
+ }, d = {
13423
+ liveChatPayload: i
13413
13424
  };
13414
- return /* @__PURE__ */ k.jsx(lo, { ...s, children: /* @__PURE__ */ k.jsx(co, { children: /* @__PURE__ */ k.jsx(uo, { ...u, children: /* @__PURE__ */ k.jsx(xl, { children: e }) }) }) });
13425
+ return /* @__PURE__ */ k.jsx(lo, { ...u, children: /* @__PURE__ */ k.jsx(co, { children: /* @__PURE__ */ k.jsx(uo, { ...c, children: /* @__PURE__ */ k.jsx(xl, { ...d, children: e }) }) }) });
13415
13426
  };
13416
13427
  _l.propTypes = {
13417
13428
  children: C.element,
13418
13429
  clientId: C.string,
13419
13430
  configurations: C.object,
13420
- conversation: Pn,
13431
+ conversation: In,
13421
13432
  id: C.string,
13433
+ liveChatPayload: C.object,
13422
13434
  onFeedbackSelection: C.func,
13423
13435
  onMessageSent: C.func,
13424
13436
  xpertKey: C.string,
@@ -13428,11 +13440,12 @@ function E0({
13428
13440
  clientId: e,
13429
13441
  configurations: t = {},
13430
13442
  conversation: n,
13431
- onFeedbackSelection: r,
13432
- onMessageSent: i,
13433
- submitEventExternal: a,
13434
- xpertKey: o,
13435
- widgetMode: l = !0
13443
+ liveChatPayload: r,
13444
+ onFeedbackSelection: i,
13445
+ onMessageSent: a,
13446
+ submitEventExternal: o,
13447
+ xpertKey: l,
13448
+ widgetMode: s = !0
13436
13449
  }) {
13437
13450
  return /* @__PURE__ */ k.jsx(
13438
13451
  _l,
@@ -13440,18 +13453,20 @@ function E0({
13440
13453
  clientId: e,
13441
13454
  configurations: t,
13442
13455
  conversation: n,
13443
- onFeedbackSelection: r,
13444
- onMessageSent: i,
13445
- xpertKey: o,
13446
- widgetMode: l,
13447
- children: /* @__PURE__ */ k.jsx(bi, { submitEventExternal: a })
13456
+ onFeedbackSelection: i,
13457
+ onMessageSent: a,
13458
+ liveChatPayload: r,
13459
+ xpertKey: l,
13460
+ widgetMode: s,
13461
+ children: /* @__PURE__ */ k.jsx(bi, { submitEventExternal: o })
13448
13462
  }
13449
13463
  );
13450
13464
  }
13451
13465
  E0.propTypes = {
13452
13466
  clientId: C.string,
13453
13467
  configurations: C.object,
13454
- conversation: Pn,
13468
+ conversation: In,
13469
+ liveChatPayload: C.object,
13455
13470
  onFeedbackSelection: C.func,
13456
13471
  onMessageSent: C.func,
13457
13472
  submitEventExternal: C.func,