@anam-ai/agent-widget 0.1.0-alpha.11 → 0.1.0-alpha.13

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.js CHANGED
@@ -1,4 +1,4 @@
1
- var Fe, D, fi, pi, Ee, Ht, _i, Ei, mi, It, _t, Et, Me = {}, gi = [], ln = /acit|ex(?:s|g|n|p|$)|rph|grid|ows|mnc|ntw|ine[ch]|zoo|^ord|itera/i, rt = Array.isArray;
1
+ var Fe, k, fi, pi, Ee, Ht, _i, Ei, mi, It, _t, Et, Me = {}, gi = [], ln = /acit|ex(?:s|g|n|p|$)|rph|grid|ows|mnc|ntw|ine[ch]|zoo|^ord|itera/i, rt = Array.isArray;
2
2
  function ie(t, e) {
3
3
  for (var n in e) t[n] = e[n];
4
4
  return t;
@@ -6,17 +6,17 @@ function ie(t, e) {
6
6
  function bt(t) {
7
7
  t && t.parentNode && t.parentNode.removeChild(t);
8
8
  }
9
- function Ie(t, e, n) {
10
- var o, u, a, c = {};
11
- for (a in e) a == "key" ? o = e[a] : a == "ref" ? u = e[a] : c[a] = e[a];
12
- if (arguments.length > 2 && (c.children = arguments.length > 3 ? Fe.call(arguments, 2) : n), typeof t == "function" && t.defaultProps != null) for (a in t.defaultProps) c[a] === void 0 && (c[a] = t.defaultProps[a]);
13
- return xe(t, c, o, u, null);
9
+ function Ce(t, e, n) {
10
+ var o, c, a, u = {};
11
+ for (a in e) a == "key" ? o = e[a] : a == "ref" ? c = e[a] : u[a] = e[a];
12
+ if (arguments.length > 2 && (u.children = arguments.length > 3 ? Fe.call(arguments, 2) : n), typeof t == "function" && t.defaultProps != null) for (a in t.defaultProps) u[a] === void 0 && (u[a] = t.defaultProps[a]);
13
+ return xe(t, u, o, c, null);
14
14
  }
15
- function xe(t, e, n, o, u) {
16
- var a = { type: t, props: e, key: n, ref: o, __k: null, __: null, __b: 0, __e: null, __c: null, constructor: void 0, __v: u ?? ++fi, __i: -1, __u: 0 };
17
- return u == null && D.vnode != null && D.vnode(a), a;
15
+ function xe(t, e, n, o, c) {
16
+ var a = { type: t, props: e, key: n, ref: o, __k: null, __: null, __b: 0, __e: null, __c: null, constructor: void 0, __v: c ?? ++fi, __i: -1, __u: 0 };
17
+ return c == null && k.vnode != null && k.vnode(a), a;
18
18
  }
19
- function oe(t) {
19
+ function _e(t) {
20
20
  return t.children;
21
21
  }
22
22
  function Oe(t, e) {
@@ -38,27 +38,27 @@ function vi(t) {
38
38
  }
39
39
  }
40
40
  function Wt(t) {
41
- (!t.__d && (t.__d = !0) && Ee.push(t) && !Je.__r++ || Ht != D.debounceRendering) && ((Ht = D.debounceRendering) || _i)(Je);
41
+ (!t.__d && (t.__d = !0) && Ee.push(t) && !Je.__r++ || Ht != k.debounceRendering) && ((Ht = k.debounceRendering) || _i)(Je);
42
42
  }
43
43
  function Je() {
44
- for (var t, e, n, o, u, a, c, l = 1; Ee.length; ) Ee.length > l && Ee.sort(Ei), t = Ee.shift(), l = Ee.length, t.__d && (n = void 0, o = void 0, u = (o = (e = t).__v).__e, a = [], c = [], e.__P && ((n = ie({}, o)).__v = o.__v + 1, D.vnode && D.vnode(n), At(e.__P, n, o, e.__n, e.__P.namespaceURI, 32 & o.__u ? [u] : null, a, u ?? be(o), !!(32 & o.__u), c), n.__v = o.__v, n.__.__k[n.__i] = n, wi(a, n, c), o.__e = o.__ = null, n.__e != u && vi(n)));
44
+ for (var t, e, n, o, c, a, u, l = 1; Ee.length; ) Ee.length > l && Ee.sort(Ei), t = Ee.shift(), l = Ee.length, t.__d && (n = void 0, o = void 0, c = (o = (e = t).__v).__e, a = [], u = [], e.__P && ((n = ie({}, o)).__v = o.__v + 1, k.vnode && k.vnode(n), At(e.__P, n, o, e.__n, e.__P.namespaceURI, 32 & o.__u ? [c] : null, a, c ?? be(o), !!(32 & o.__u), u), n.__v = o.__v, n.__.__k[n.__i] = n, wi(a, n, u), o.__e = o.__ = null, n.__e != c && vi(n)));
45
45
  Je.__r = 0;
46
46
  }
47
- function yi(t, e, n, o, u, a, c, l, m, p, _) {
48
- var d, S, g, y, b, A, C, I = o && o.__k || gi, x = e.length;
49
- for (m = cn(n, e, I, m, x), d = 0; d < x; d++) (g = n.__k[d]) != null && (S = g.__i == -1 ? Me : I[g.__i] || Me, g.__i = d, A = At(t, g, S, u, a, c, l, m, p, _), y = g.__e, g.ref && S.ref != g.ref && (S.ref && Tt(S.ref, null, g), _.push(g.ref, g.__c || y, g)), b == null && y != null && (b = y), (C = !!(4 & g.__u)) || S.__k === g.__k ? m = Si(g, m, t, C) : typeof g.type == "function" && A !== void 0 ? m = A : y && (m = y.nextSibling), g.__u &= -7);
50
- return n.__e = b, m;
47
+ function yi(t, e, n, o, c, a, u, l, m, p, _) {
48
+ var d, y, g, S, C, A, I, b = o && o.__k || gi, T = e.length;
49
+ for (m = cn(n, e, b, m, T), d = 0; d < T; d++) (g = n.__k[d]) != null && (y = g.__i == -1 ? Me : b[g.__i] || Me, g.__i = d, A = At(t, g, y, c, a, u, l, m, p, _), S = g.__e, g.ref && y.ref != g.ref && (y.ref && Tt(y.ref, null, g), _.push(g.ref, g.__c || S, g)), C == null && S != null && (C = S), (I = !!(4 & g.__u)) || y.__k === g.__k ? m = Si(g, m, t, I) : typeof g.type == "function" && A !== void 0 ? m = A : S && (m = S.nextSibling), g.__u &= -7);
50
+ return n.__e = C, m;
51
51
  }
52
- function cn(t, e, n, o, u) {
53
- var a, c, l, m, p, _ = n.length, d = _, S = 0;
54
- for (t.__k = new Array(u), a = 0; a < u; a++) (c = e[a]) != null && typeof c != "boolean" && typeof c != "function" ? (typeof c == "string" || typeof c == "number" || typeof c == "bigint" || c.constructor == String ? c = t.__k[a] = xe(null, c, null, null, null) : rt(c) ? c = t.__k[a] = xe(oe, { children: c }, null, null, null) : c.constructor === void 0 && c.__b > 0 ? c = t.__k[a] = xe(c.type, c.props, c.key, c.ref ? c.ref : null, c.__v) : t.__k[a] = c, m = a + S, c.__ = t, c.__b = t.__b + 1, l = null, (p = c.__i = un(c, n, m, d)) != -1 && (d--, (l = n[p]) && (l.__u |= 2)), l == null || l.__v == null ? (p == -1 && (u > _ ? S-- : u < _ && S++), typeof c.type != "function" && (c.__u |= 4)) : p != m && (p == m - 1 ? S-- : p == m + 1 ? S++ : (p > m ? S-- : S++, c.__u |= 4))) : t.__k[a] = null;
52
+ function cn(t, e, n, o, c) {
53
+ var a, u, l, m, p, _ = n.length, d = _, y = 0;
54
+ for (t.__k = new Array(c), a = 0; a < c; a++) (u = e[a]) != null && typeof u != "boolean" && typeof u != "function" ? (typeof u == "string" || typeof u == "number" || typeof u == "bigint" || u.constructor == String ? u = t.__k[a] = xe(null, u, null, null, null) : rt(u) ? u = t.__k[a] = xe(_e, { children: u }, null, null, null) : u.constructor === void 0 && u.__b > 0 ? u = t.__k[a] = xe(u.type, u.props, u.key, u.ref ? u.ref : null, u.__v) : t.__k[a] = u, m = a + y, u.__ = t, u.__b = t.__b + 1, l = null, (p = u.__i = un(u, n, m, d)) != -1 && (d--, (l = n[p]) && (l.__u |= 2)), l == null || l.__v == null ? (p == -1 && (c > _ ? y-- : c < _ && y++), typeof u.type != "function" && (u.__u |= 4)) : p != m && (p == m - 1 ? y-- : p == m + 1 ? y++ : (p > m ? y-- : y++, u.__u |= 4))) : t.__k[a] = null;
55
55
  if (d) for (a = 0; a < _; a++) (l = n[a]) != null && (2 & l.__u) == 0 && (l.__e == o && (o = be(l)), Ii(l, l));
56
56
  return o;
57
57
  }
58
58
  function Si(t, e, n, o) {
59
- var u, a;
59
+ var c, a;
60
60
  if (typeof t.type == "function") {
61
- for (u = t.__k, a = 0; u && a < u.length; a++) u[a] && (u[a].__ = t, e = Si(u[a], e, n, o));
61
+ for (c = t.__k, a = 0; c && a < c.length; a++) c[a] && (c[a].__ = t, e = Si(c[a], e, n, o));
62
62
  return e;
63
63
  }
64
64
  t.__e != e && (o && (e && t.type && !e.parentNode && (e = be(t)), n.insertBefore(t.__e, e || null)), e = t.__e);
@@ -68,26 +68,26 @@ function Si(t, e, n, o) {
68
68
  return e;
69
69
  }
70
70
  function un(t, e, n, o) {
71
- var u, a, c, l = t.key, m = t.type, p = e[n], _ = p != null && (2 & p.__u) == 0;
71
+ var c, a, u, l = t.key, m = t.type, p = e[n], _ = p != null && (2 & p.__u) == 0;
72
72
  if (p === null && l == null || _ && l == p.key && m == p.type) return n;
73
73
  if (o > (_ ? 1 : 0)) {
74
- for (u = n - 1, a = n + 1; u >= 0 || a < e.length; ) if ((p = e[c = u >= 0 ? u-- : a++]) != null && (2 & p.__u) == 0 && l == p.key && m == p.type) return c;
74
+ for (c = n - 1, a = n + 1; c >= 0 || a < e.length; ) if ((p = e[u = c >= 0 ? c-- : a++]) != null && (2 & p.__u) == 0 && l == p.key && m == p.type) return u;
75
75
  }
76
76
  return -1;
77
77
  }
78
78
  function zt(t, e, n) {
79
79
  e[0] == "-" ? t.setProperty(e, n ?? "") : t[e] = n == null ? "" : typeof n != "number" || ln.test(e) ? n : n + "px";
80
80
  }
81
- function Ve(t, e, n, o, u) {
82
- var a, c;
81
+ function Ge(t, e, n, o, c) {
82
+ var a, u;
83
83
  e: if (e == "style") if (typeof n == "string") t.style.cssText = n;
84
84
  else {
85
85
  if (typeof o == "string" && (t.style.cssText = o = ""), o) for (e in o) n && e in n || zt(t.style, e, "");
86
86
  if (n) for (e in n) o && n[e] == o[e] || zt(t.style, e, n[e]);
87
87
  }
88
- else if (e[0] == "o" && e[1] == "n") a = e != (e = e.replace(mi, "$1")), c = e.toLowerCase(), e = c in t || e == "onFocusOut" || e == "onFocusIn" ? c.slice(2) : e.slice(2), t.l || (t.l = {}), t.l[e + a] = n, n ? o ? n.u = o.u : (n.u = It, t.addEventListener(e, a ? Et : _t, a)) : t.removeEventListener(e, a ? Et : _t, a);
88
+ else if (e[0] == "o" && e[1] == "n") a = e != (e = e.replace(mi, "$1")), u = e.toLowerCase(), e = u in t || e == "onFocusOut" || e == "onFocusIn" ? u.slice(2) : e.slice(2), t.l || (t.l = {}), t.l[e + a] = n, n ? o ? n.u = o.u : (n.u = It, t.addEventListener(e, a ? Et : _t, a)) : t.removeEventListener(e, a ? Et : _t, a);
89
89
  else {
90
- if (u == "http://www.w3.org/2000/svg") e = e.replace(/xlink(H|:h)/, "h").replace(/sName$/, "s");
90
+ if (c == "http://www.w3.org/2000/svg") e = e.replace(/xlink(H|:h)/, "h").replace(/sName$/, "s");
91
91
  else if (e != "width" && e != "height" && e != "href" && e != "list" && e != "form" && e != "tabIndex" && e != "download" && e != "rowSpan" && e != "colSpan" && e != "role" && e != "popover" && e in t) try {
92
92
  t[e] = n ?? "";
93
93
  break e;
@@ -102,93 +102,93 @@ function qt(t) {
102
102
  var n = this.l[e.type + t];
103
103
  if (e.t == null) e.t = It++;
104
104
  else if (e.t < n.u) return;
105
- return n(D.event ? D.event(e) : e);
105
+ return n(k.event ? k.event(e) : e);
106
106
  }
107
107
  };
108
108
  }
109
- function At(t, e, n, o, u, a, c, l, m, p) {
110
- var _, d, S, g, y, b, A, C, I, x, O, T, q, H, ae, ne, re, Q = e.type;
109
+ function At(t, e, n, o, c, a, u, l, m, p) {
110
+ var _, d, y, g, S, C, A, I, b, T, D, x, Z, H, se, ne, re, Q = e.type;
111
111
  if (e.constructor !== void 0) return null;
112
- 128 & n.__u && (m = !!(32 & n.__u), a = [l = e.__e = n.__e]), (_ = D.__b) && _(e);
112
+ 128 & n.__u && (m = !!(32 & n.__u), a = [l = e.__e = n.__e]), (_ = k.__b) && _(e);
113
113
  e: if (typeof Q == "function") try {
114
- if (C = e.props, I = "prototype" in Q && Q.prototype.render, x = (_ = Q.contextType) && o[_.__c], O = _ ? x ? x.props.value : _.__ : o, n.__c ? A = (d = e.__c = n.__c).__ = d.__E : (I ? e.__c = d = new Q(C, O) : (e.__c = d = new Oe(C, O), d.constructor = Q, d.render = hn), x && x.sub(d), d.state || (d.state = {}), d.__n = o, S = d.__d = !0, d.__h = [], d._sb = []), I && d.__s == null && (d.__s = d.state), I && Q.getDerivedStateFromProps != null && (d.__s == d.state && (d.__s = ie({}, d.__s)), ie(d.__s, Q.getDerivedStateFromProps(C, d.__s))), g = d.props, y = d.state, d.__v = e, S) I && Q.getDerivedStateFromProps == null && d.componentWillMount != null && d.componentWillMount(), I && d.componentDidMount != null && d.__h.push(d.componentDidMount);
114
+ if (I = e.props, b = "prototype" in Q && Q.prototype.render, T = (_ = Q.contextType) && o[_.__c], D = _ ? T ? T.props.value : _.__ : o, n.__c ? A = (d = e.__c = n.__c).__ = d.__E : (b ? e.__c = d = new Q(I, D) : (e.__c = d = new Oe(I, D), d.constructor = Q, d.render = hn), T && T.sub(d), d.state || (d.state = {}), d.__n = o, y = d.__d = !0, d.__h = [], d._sb = []), b && d.__s == null && (d.__s = d.state), b && Q.getDerivedStateFromProps != null && (d.__s == d.state && (d.__s = ie({}, d.__s)), ie(d.__s, Q.getDerivedStateFromProps(I, d.__s))), g = d.props, S = d.state, d.__v = e, y) b && Q.getDerivedStateFromProps == null && d.componentWillMount != null && d.componentWillMount(), b && d.componentDidMount != null && d.__h.push(d.componentDidMount);
115
115
  else {
116
- if (I && Q.getDerivedStateFromProps == null && C !== g && d.componentWillReceiveProps != null && d.componentWillReceiveProps(C, O), e.__v == n.__v || !d.__e && d.shouldComponentUpdate != null && d.shouldComponentUpdate(C, d.__s, O) === !1) {
117
- for (e.__v != n.__v && (d.props = C, d.state = d.__s, d.__d = !1), e.__e = n.__e, e.__k = n.__k, e.__k.some(function(le) {
118
- le && (le.__ = e);
119
- }), T = 0; T < d._sb.length; T++) d.__h.push(d._sb[T]);
120
- d._sb = [], d.__h.length && c.push(d);
116
+ if (b && Q.getDerivedStateFromProps == null && I !== g && d.componentWillReceiveProps != null && d.componentWillReceiveProps(I, D), e.__v == n.__v || !d.__e && d.shouldComponentUpdate != null && d.shouldComponentUpdate(I, d.__s, D) === !1) {
117
+ for (e.__v != n.__v && (d.props = I, d.state = d.__s, d.__d = !1), e.__e = n.__e, e.__k = n.__k, e.__k.some(function(ae) {
118
+ ae && (ae.__ = e);
119
+ }), x = 0; x < d._sb.length; x++) d.__h.push(d._sb[x]);
120
+ d._sb = [], d.__h.length && u.push(d);
121
121
  break e;
122
122
  }
123
- d.componentWillUpdate != null && d.componentWillUpdate(C, d.__s, O), I && d.componentDidUpdate != null && d.__h.push(function() {
124
- d.componentDidUpdate(g, y, b);
123
+ d.componentWillUpdate != null && d.componentWillUpdate(I, d.__s, D), b && d.componentDidUpdate != null && d.__h.push(function() {
124
+ d.componentDidUpdate(g, S, C);
125
125
  });
126
126
  }
127
- if (d.context = O, d.props = C, d.__P = t, d.__e = !1, q = D.__r, H = 0, I) {
128
- for (d.state = d.__s, d.__d = !1, q && q(e), _ = d.render(d.props, d.state, d.context), ae = 0; ae < d._sb.length; ae++) d.__h.push(d._sb[ae]);
127
+ if (d.context = D, d.props = I, d.__P = t, d.__e = !1, Z = k.__r, H = 0, b) {
128
+ for (d.state = d.__s, d.__d = !1, Z && Z(e), _ = d.render(d.props, d.state, d.context), se = 0; se < d._sb.length; se++) d.__h.push(d._sb[se]);
129
129
  d._sb = [];
130
130
  } else do
131
- d.__d = !1, q && q(e), _ = d.render(d.props, d.state, d.context), d.state = d.__s;
131
+ d.__d = !1, Z && Z(e), _ = d.render(d.props, d.state, d.context), d.state = d.__s;
132
132
  while (d.__d && ++H < 25);
133
- d.state = d.__s, d.getChildContext != null && (o = ie(ie({}, o), d.getChildContext())), I && !S && d.getSnapshotBeforeUpdate != null && (b = d.getSnapshotBeforeUpdate(g, y)), ne = _, _ != null && _.type === oe && _.key == null && (ne = Ci(_.props.children)), l = yi(t, rt(ne) ? ne : [ne], e, n, o, u, a, c, l, m, p), d.base = e.__e, e.__u &= -161, d.__h.length && c.push(d), A && (d.__E = d.__ = null);
134
- } catch (le) {
135
- if (e.__v = null, m || a != null) if (le.then) {
133
+ d.state = d.__s, d.getChildContext != null && (o = ie(ie({}, o), d.getChildContext())), b && !y && d.getSnapshotBeforeUpdate != null && (C = d.getSnapshotBeforeUpdate(g, S)), ne = _, _ != null && _.type === _e && _.key == null && (ne = Ci(_.props.children)), l = yi(t, rt(ne) ? ne : [ne], e, n, o, c, a, u, l, m, p), d.base = e.__e, e.__u &= -161, d.__h.length && u.push(d), A && (d.__E = d.__ = null);
134
+ } catch (ae) {
135
+ if (e.__v = null, m || a != null) if (ae.then) {
136
136
  for (e.__u |= m ? 160 : 128; l && l.nodeType == 8 && l.nextSibling; ) l = l.nextSibling;
137
137
  a[a.indexOf(l)] = null, e.__e = l;
138
138
  } else {
139
139
  for (re = a.length; re--; ) bt(a[re]);
140
140
  mt(e);
141
141
  }
142
- else e.__e = n.__e, e.__k = n.__k, le.then || mt(e);
143
- D.__e(le, e, n);
142
+ else e.__e = n.__e, e.__k = n.__k, ae.then || mt(e);
143
+ k.__e(ae, e, n);
144
144
  }
145
- else a == null && e.__v == n.__v ? (e.__k = n.__k, e.__e = n.__e) : l = e.__e = dn(n.__e, e, n, o, u, a, c, m, p);
146
- return (_ = D.diffed) && _(e), 128 & e.__u ? void 0 : l;
145
+ else a == null && e.__v == n.__v ? (e.__k = n.__k, e.__e = n.__e) : l = e.__e = dn(n.__e, e, n, o, c, a, u, m, p);
146
+ return (_ = k.diffed) && _(e), 128 & e.__u ? void 0 : l;
147
147
  }
148
148
  function mt(t) {
149
149
  t && t.__c && (t.__c.__e = !0), t && t.__k && t.__k.forEach(mt);
150
150
  }
151
151
  function wi(t, e, n) {
152
152
  for (var o = 0; o < n.length; o++) Tt(n[o], n[++o], n[++o]);
153
- D.__c && D.__c(e, t), t.some(function(u) {
153
+ k.__c && k.__c(e, t), t.some(function(c) {
154
154
  try {
155
- t = u.__h, u.__h = [], t.some(function(a) {
156
- a.call(u);
155
+ t = c.__h, c.__h = [], t.some(function(a) {
156
+ a.call(c);
157
157
  });
158
158
  } catch (a) {
159
- D.__e(a, u.__v);
159
+ k.__e(a, c.__v);
160
160
  }
161
161
  });
162
162
  }
163
163
  function Ci(t) {
164
164
  return typeof t != "object" || t == null || t.__b && t.__b > 0 ? t : rt(t) ? t.map(Ci) : ie({}, t);
165
165
  }
166
- function dn(t, e, n, o, u, a, c, l, m) {
167
- var p, _, d, S, g, y, b, A = n.props || Me, C = e.props, I = e.type;
168
- if (I == "svg" ? u = "http://www.w3.org/2000/svg" : I == "math" ? u = "http://www.w3.org/1998/Math/MathML" : u || (u = "http://www.w3.org/1999/xhtml"), a != null) {
169
- for (p = 0; p < a.length; p++) if ((g = a[p]) && "setAttribute" in g == !!I && (I ? g.localName == I : g.nodeType == 3)) {
166
+ function dn(t, e, n, o, c, a, u, l, m) {
167
+ var p, _, d, y, g, S, C, A = n.props || Me, I = e.props, b = e.type;
168
+ if (b == "svg" ? c = "http://www.w3.org/2000/svg" : b == "math" ? c = "http://www.w3.org/1998/Math/MathML" : c || (c = "http://www.w3.org/1999/xhtml"), a != null) {
169
+ for (p = 0; p < a.length; p++) if ((g = a[p]) && "setAttribute" in g == !!b && (b ? g.localName == b : g.nodeType == 3)) {
170
170
  t = g, a[p] = null;
171
171
  break;
172
172
  }
173
173
  }
174
174
  if (t == null) {
175
- if (I == null) return document.createTextNode(C);
176
- t = document.createElementNS(u, I, C.is && C), l && (D.__m && D.__m(e, a), l = !1), a = null;
175
+ if (b == null) return document.createTextNode(I);
176
+ t = document.createElementNS(c, b, I.is && I), l && (k.__m && k.__m(e, a), l = !1), a = null;
177
177
  }
178
- if (I == null) A === C || l && t.data == C || (t.data = C);
178
+ if (b == null) A === I || l && t.data == I || (t.data = I);
179
179
  else {
180
180
  if (a = a && Fe.call(t.childNodes), !l && a != null) for (A = {}, p = 0; p < t.attributes.length; p++) A[(g = t.attributes[p]).name] = g.value;
181
181
  for (p in A) if (g = A[p], p != "children") {
182
182
  if (p == "dangerouslySetInnerHTML") d = g;
183
- else if (!(p in C)) {
184
- if (p == "value" && "defaultValue" in C || p == "checked" && "defaultChecked" in C) continue;
185
- Ve(t, p, null, g, u);
183
+ else if (!(p in I)) {
184
+ if (p == "value" && "defaultValue" in I || p == "checked" && "defaultChecked" in I) continue;
185
+ Ge(t, p, null, g, c);
186
186
  }
187
187
  }
188
- for (p in C) g = C[p], p == "children" ? S = g : p == "dangerouslySetInnerHTML" ? _ = g : p == "value" ? y = g : p == "checked" ? b = g : l && typeof g != "function" || A[p] === g || Ve(t, p, g, A[p], u);
188
+ for (p in I) g = I[p], p == "children" ? y = g : p == "dangerouslySetInnerHTML" ? _ = g : p == "value" ? S = g : p == "checked" ? C = g : l && typeof g != "function" || A[p] === g || Ge(t, p, g, A[p], c);
189
189
  if (_) l || d && (_.__html == d.__html || _.__html == t.innerHTML) || (t.innerHTML = _.__html), e.__k = [];
190
- else if (d && (t.innerHTML = ""), yi(e.type == "template" ? t.content : t, rt(S) ? S : [S], e, n, o, I == "foreignObject" ? "http://www.w3.org/1999/xhtml" : u, a, c, a ? a[0] : n.__k && be(n, 0), l, m), a != null) for (p = a.length; p--; ) bt(a[p]);
191
- l || (p = "value", I == "progress" && y == null ? t.removeAttribute("value") : y != null && (y !== t[p] || I == "progress" && !y || I == "option" && y != A[p]) && Ve(t, p, y, A[p], u), p = "checked", b != null && b != t[p] && Ve(t, p, b, A[p], u));
190
+ else if (d && (t.innerHTML = ""), yi(e.type == "template" ? t.content : t, rt(y) ? y : [y], e, n, o, b == "foreignObject" ? "http://www.w3.org/1999/xhtml" : c, a, u, a ? a[0] : n.__k && be(n, 0), l, m), a != null) for (p = a.length; p--; ) bt(a[p]);
191
+ l || (p = "value", b == "progress" && S == null ? t.removeAttribute("value") : S != null && (S !== t[p] || b == "progress" && !S || b == "option" && S != A[p]) && Ge(t, p, S, A[p], c), p = "checked", C != null && C != t[p] && Ge(t, p, C, A[p], c));
192
192
  }
193
193
  return t;
194
194
  }
@@ -198,41 +198,41 @@ function Tt(t, e, n) {
198
198
  var o = typeof t.__u == "function";
199
199
  o && t.__u(), o && e == null || (t.__u = t(e));
200
200
  } else t.current = e;
201
- } catch (u) {
202
- D.__e(u, n);
201
+ } catch (c) {
202
+ k.__e(c, n);
203
203
  }
204
204
  }
205
205
  function Ii(t, e, n) {
206
- var o, u;
207
- if (D.unmount && D.unmount(t), (o = t.ref) && (o.current && o.current != t.__e || Tt(o, null, e)), (o = t.__c) != null) {
206
+ var o, c;
207
+ if (k.unmount && k.unmount(t), (o = t.ref) && (o.current && o.current != t.__e || Tt(o, null, e)), (o = t.__c) != null) {
208
208
  if (o.componentWillUnmount) try {
209
209
  o.componentWillUnmount();
210
210
  } catch (a) {
211
- D.__e(a, e);
211
+ k.__e(a, e);
212
212
  }
213
213
  o.base = o.__P = null;
214
214
  }
215
- if (o = t.__k) for (u = 0; u < o.length; u++) o[u] && Ii(o[u], e, n || typeof t.type != "function");
215
+ if (o = t.__k) for (c = 0; c < o.length; c++) o[c] && Ii(o[c], e, n || typeof t.type != "function");
216
216
  n || bt(t.__e), t.__c = t.__ = t.__e = void 0;
217
217
  }
218
218
  function hn(t, e, n) {
219
219
  return this.constructor(t, n);
220
220
  }
221
221
  function ot(t, e, n) {
222
- var o, u, a, c;
223
- e == document && (e = document.documentElement), D.__ && D.__(t, e), u = (o = typeof n == "function") ? null : n && n.__k || e.__k, a = [], c = [], At(e, t = (!o && n || e).__k = Ie(oe, null, [t]), u || Me, Me, e.namespaceURI, !o && n ? [n] : u ? null : e.firstChild ? Fe.call(e.childNodes) : null, a, !o && n ? n : u ? u.__e : e.firstChild, o, c), wi(a, t, c);
222
+ var o, c, a, u;
223
+ e == document && (e = document.documentElement), k.__ && k.__(t, e), c = (o = typeof n == "function") ? null : n && n.__k || e.__k, a = [], u = [], At(e, t = (!o && n || e).__k = Ce(_e, null, [t]), c || Me, Me, e.namespaceURI, !o && n ? [n] : c ? null : e.firstChild ? Fe.call(e.childNodes) : null, a, !o && n ? n : c ? c.__e : e.firstChild, o, u), wi(a, t, u);
224
224
  }
225
225
  function bi(t, e) {
226
226
  ot(t, e, bi);
227
227
  }
228
228
  function Ai(t, e, n) {
229
- var o, u, a, c, l = ie({}, t.props);
230
- for (a in t.type && t.type.defaultProps && (c = t.type.defaultProps), e) a == "key" ? o = e[a] : a == "ref" ? u = e[a] : l[a] = e[a] === void 0 && c != null ? c[a] : e[a];
231
- return arguments.length > 2 && (l.children = arguments.length > 3 ? Fe.call(arguments, 2) : n), xe(t.type, l, o || t.key, u || t.ref, null);
229
+ var o, c, a, u, l = ie({}, t.props);
230
+ for (a in t.type && t.type.defaultProps && (u = t.type.defaultProps), e) a == "key" ? o = e[a] : a == "ref" ? c = e[a] : l[a] = e[a] === void 0 && u != null ? u[a] : e[a];
231
+ return arguments.length > 2 && (l.children = arguments.length > 3 ? Fe.call(arguments, 2) : n), xe(t.type, l, o || t.key, c || t.ref, null);
232
232
  }
233
- Fe = gi.slice, D = { __e: function(t, e, n, o) {
234
- for (var u, a, c; e = e.__; ) if ((u = e.__c) && !u.__) try {
235
- if ((a = u.constructor) && a.getDerivedStateFromError != null && (u.setState(a.getDerivedStateFromError(t)), c = u.__d), u.componentDidCatch != null && (u.componentDidCatch(t, o || {}), c = u.__d), c) return u.__E = u;
233
+ Fe = gi.slice, k = { __e: function(t, e, n, o) {
234
+ for (var c, a, u; e = e.__; ) if ((c = e.__c) && !c.__) try {
235
+ if ((a = c.constructor) && a.getDerivedStateFromError != null && (c.setState(a.getDerivedStateFromError(t)), u = c.__d), c.componentDidCatch != null && (c.componentDidCatch(t, o || {}), u = c.__d), u) return c.__E = c;
236
236
  } catch (l) {
237
237
  t = l;
238
238
  }
@@ -244,7 +244,7 @@ Fe = gi.slice, D = { __e: function(t, e, n, o) {
244
244
  n = this.__s != null && this.__s != this.state ? this.__s : this.__s = ie({}, this.state), typeof t == "function" && (t = t(ie({}, n), this.props)), t && ie(n, t), t != null && this.__v && (e && this._sb.push(e), Wt(this));
245
245
  }, Oe.prototype.forceUpdate = function(t) {
246
246
  this.__v && (this.__e = !0, t && this.__h.push(t), Wt(this));
247
- }, Oe.prototype.render = oe, Ee = [], _i = typeof Promise == "function" ? Promise.prototype.then.bind(Promise.resolve()) : setTimeout, Ei = function(t, e) {
247
+ }, Oe.prototype.render = _e, Ee = [], _i = typeof Promise == "function" ? Promise.prototype.then.bind(Promise.resolve()) : setTimeout, Ei = function(t, e) {
248
248
  return t.__v.__b - e.__v.__b;
249
249
  }, Je.__r = 0, mi = /(PointerCapture)$|Capture$/i, It = 0, _t = qt(!1), Et = qt(!0);
250
250
  function Xe() {
@@ -258,27 +258,27 @@ function Xe() {
258
258
  }
259
259
  function Ti(t, e) {
260
260
  if (t == null) return {};
261
- var n, o, u = {}, a = Object.keys(t);
262
- for (o = 0; o < a.length; o++) e.indexOf(n = a[o]) >= 0 || (u[n] = t[n]);
263
- return u;
261
+ var n, o, c = {}, a = Object.keys(t);
262
+ for (o = 0; o < a.length; o++) e.indexOf(n = a[o]) >= 0 || (c[n] = t[n]);
263
+ return c;
264
264
  }
265
265
  var fn = ["context", "children"], pn = ["useFragment"];
266
266
  function _n(t, e, n, o) {
267
- function u() {
268
- var a, c = Reflect.construct(HTMLElement, [], u);
269
- return c._vdomComponent = t, o && o.shadow ? (c._root = c.attachShadow({ mode: o.mode || "open", serializable: (a = o.serializable) != null && a }), o.adoptedStyleSheets && (c._root.adoptedStyleSheets = o.adoptedStyleSheets)) : c._root = c, c;
267
+ function c() {
268
+ var a, u = Reflect.construct(HTMLElement, [], c);
269
+ return u._vdomComponent = t, o && o.shadow ? (u._root = u.attachShadow({ mode: o.mode || "open", serializable: (a = o.serializable) != null && a }), o.adoptedStyleSheets && (u._root.adoptedStyleSheets = o.adoptedStyleSheets)) : u._root = u, u;
270
270
  }
271
- return (u.prototype = Object.create(HTMLElement.prototype)).constructor = u, u.prototype.connectedCallback = function() {
271
+ return (c.prototype = Object.create(HTMLElement.prototype)).constructor = c, c.prototype.connectedCallback = function() {
272
272
  mn.call(this, o);
273
- }, u.prototype.attributeChangedCallback = gn, u.prototype.disconnectedCallback = vn, n = n || t.observedAttributes || Object.keys(t.propTypes || {}), u.observedAttributes = n, t.formAssociated && (u.formAssociated = !0), n.forEach(function(a) {
274
- Object.defineProperty(u.prototype, a, { get: function() {
273
+ }, c.prototype.attributeChangedCallback = gn, c.prototype.disconnectedCallback = vn, n = n || t.observedAttributes || Object.keys(t.propTypes || {}), c.observedAttributes = n, t.formAssociated && (c.formAssociated = !0), n.forEach(function(a) {
274
+ Object.defineProperty(c.prototype, a, { get: function() {
275
275
  return this._vdom ? this._vdom.props[a] : this._props[a];
276
- }, set: function(c) {
277
- this._vdom ? this.attributeChangedCallback(a, null, c) : (this._props || (this._props = {}), this._props[a] = c);
278
- var l = typeof c;
279
- c != null && l !== "string" && l !== "boolean" && l !== "number" || this.setAttribute(a, c);
276
+ }, set: function(u) {
277
+ this._vdom ? this.attributeChangedCallback(a, null, u) : (this._props || (this._props = {}), this._props[a] = u);
278
+ var l = typeof u;
279
+ u != null && l !== "string" && l !== "boolean" && l !== "number" || this.setAttribute(a, u);
280
280
  } });
281
- }), customElements.define(e || t.tagName || t.displayName || t.name, u), u;
281
+ }), customElements.define(e || t.tagName || t.displayName || t.name, c), c;
282
282
  }
283
283
  function En(t) {
284
284
  this.getChildContext = function() {
@@ -289,7 +289,7 @@ function En(t) {
289
289
  }
290
290
  function mn(t) {
291
291
  var e = new CustomEvent("_preact", { detail: {}, bubbles: !0, cancelable: !0 });
292
- this.dispatchEvent(e), this._vdom = Ie(En, Xe({}, this._props, { context: e.detail.context }), Ni(this, this._vdomComponent, t)), (this.hasAttribute("hydrate") ? bi : ot)(this._vdom, this._root);
292
+ this.dispatchEvent(e), this._vdom = Ce(En, Xe({}, this._props, { context: e.detail.context }), Ni(this, this._vdomComponent, t)), (this.hasAttribute("hydrate") ? bi : ot)(this._vdom, this._root);
293
293
  }
294
294
  function Ri(t) {
295
295
  return t.replace(/-(\w)/g, function(e, n) {
@@ -306,42 +306,42 @@ function vn() {
306
306
  ot(this._vdom = null, this._root);
307
307
  }
308
308
  function Yt(t, e) {
309
- var n = this, o = t.useFragment, u = Ti(t, pn);
310
- return Ie(o ? oe : "slot", Xe({}, u, { ref: function(a) {
311
- a ? (n.ref = a, n._listener || (n._listener = function(c) {
312
- c.stopPropagation(), c.detail.context = e;
309
+ var n = this, o = t.useFragment, c = Ti(t, pn);
310
+ return Ce(o ? _e : "slot", Xe({}, c, { ref: function(a) {
311
+ a ? (n.ref = a, n._listener || (n._listener = function(u) {
312
+ u.stopPropagation(), u.detail.context = e;
313
313
  }, a.addEventListener("_preact", n._listener))) : n.ref.removeEventListener("_preact", n._listener);
314
314
  } }));
315
315
  }
316
316
  function Ni(t, e, n) {
317
317
  if (t.nodeType === 3) return t.data;
318
318
  if (t.nodeType !== 1) return null;
319
- var o = [], u = {}, a = 0, c = t.attributes, l = t.childNodes;
320
- for (a = c.length; a--; ) c[a].name !== "slot" && (u[c[a].name] = c[a].value, u[Ri(c[a].name)] = c[a].value);
319
+ var o = [], c = {}, a = 0, u = t.attributes, l = t.childNodes;
320
+ for (a = u.length; a--; ) u[a].name !== "slot" && (c[u[a].name] = u[a].value, c[Ri(u[a].name)] = u[a].value);
321
321
  for (a = l.length; a--; ) {
322
322
  var m = Ni(l[a], null, n), p = l[a].slot;
323
- p ? u[p] = Ie(Yt, { name: p }, m) : o[a] = m;
323
+ p ? c[p] = Ce(Yt, { name: p }, m) : o[a] = m;
324
324
  }
325
- var _ = !(!n || !n.shadow), d = e ? Ie(Yt, { useFragment: !_ }, o) : o;
326
- return !_ && e && (t.innerHTML = ""), Ie(e || t.nodeName.toLowerCase(), u, d);
325
+ var _ = !(!n || !n.shadow), d = e ? Ce(Yt, { useFragment: !_ }, o) : o;
326
+ return !_ && e && (t.innerHTML = ""), Ce(e || t.nodeName.toLowerCase(), c, d);
327
327
  }
328
328
  var yn = 0;
329
- function w(t, e, n, o, u, a) {
329
+ function w(t, e, n, o, c, a) {
330
330
  e || (e = {});
331
- var c, l, m = e;
332
- if ("ref" in m) for (l in m = {}, e) l == "ref" ? c = e[l] : m[l] = e[l];
333
- var p = { type: t, props: m, key: n, ref: c, __k: null, __: null, __b: 0, __e: null, __c: null, constructor: void 0, __v: --yn, __i: -1, __u: 0, __source: u, __self: a };
334
- if (typeof t == "function" && (c = t.defaultProps)) for (l in c) m[l] === void 0 && (m[l] = c[l]);
335
- return D.vnode && D.vnode(p), p;
331
+ var u, l, m = e;
332
+ if ("ref" in m) for (l in m = {}, e) l == "ref" ? u = e[l] : m[l] = e[l];
333
+ var p = { type: t, props: m, key: n, ref: u, __k: null, __: null, __b: 0, __e: null, __c: null, constructor: void 0, __v: --yn, __i: -1, __u: 0, __source: c, __self: a };
334
+ if (typeof t == "function" && (u = t.defaultProps)) for (l in u) m[l] === void 0 && (m[l] = u[l]);
335
+ return k.vnode && k.vnode(p), p;
336
336
  }
337
- var Ue, P, dt, Kt, Be = 0, xi = [], F = D, Jt = F.__b, Xt = F.__r, Zt = F.diffed, Qt = F.__c, ei = F.unmount, ti = F.__;
337
+ var Ue, P, dt, Kt, Le = 0, xi = [], F = k, Jt = F.__b, Xt = F.__r, Zt = F.diffed, Qt = F.__c, ei = F.unmount, ti = F.__;
338
338
  function Rt(t, e) {
339
- F.__h && F.__h(P, t, Be || e), Be = 0;
339
+ F.__h && F.__h(P, t, Le || e), Le = 0;
340
340
  var n = P.__H || (P.__H = { __: [], __h: [] });
341
341
  return t >= n.__.length && n.__.push({}), n.__[t];
342
342
  }
343
343
  function qe(t) {
344
- return Be = 1, Sn(ki, t);
344
+ return Le = 1, Sn(ki, t);
345
345
  }
346
346
  function Sn(t, e, n) {
347
347
  var o = Rt(Ue++, 2);
@@ -349,31 +349,31 @@ function Sn(t, e, n) {
349
349
  var m = o.__N ? o.__N[0] : o.__[0], p = o.t(m, l);
350
350
  m !== p && (o.__N = [p, o.__[1]], o.__c.setState({}));
351
351
  }], o.__c = P, !P.__f)) {
352
- var u = function(l, m, p) {
352
+ var c = function(l, m, p) {
353
353
  if (!o.__c.__H) return !0;
354
- var _ = o.__c.__H.__.filter(function(S) {
355
- return !!S.__c;
354
+ var _ = o.__c.__H.__.filter(function(y) {
355
+ return !!y.__c;
356
356
  });
357
- if (_.every(function(S) {
358
- return !S.__N;
357
+ if (_.every(function(y) {
358
+ return !y.__N;
359
359
  })) return !a || a.call(this, l, m, p);
360
360
  var d = o.__c.props !== l;
361
- return _.forEach(function(S) {
362
- if (S.__N) {
363
- var g = S.__[0];
364
- S.__ = S.__N, S.__N = void 0, g !== S.__[0] && (d = !0);
361
+ return _.forEach(function(y) {
362
+ if (y.__N) {
363
+ var g = y.__[0];
364
+ y.__ = y.__N, y.__N = void 0, g !== y.__[0] && (d = !0);
365
365
  }
366
366
  }), a && a.call(this, l, m, p) || d;
367
367
  };
368
368
  P.__f = !0;
369
- var a = P.shouldComponentUpdate, c = P.componentWillUpdate;
369
+ var a = P.shouldComponentUpdate, u = P.componentWillUpdate;
370
370
  P.componentWillUpdate = function(l, m, p) {
371
371
  if (this.__e) {
372
372
  var _ = a;
373
- a = void 0, u(l, m, p), a = _;
373
+ a = void 0, c(l, m, p), a = _;
374
374
  }
375
- c && c.call(this, l, m, p);
376
- }, P.shouldComponentUpdate = u;
375
+ u && u.call(this, l, m, p);
376
+ }, P.shouldComponentUpdate = c;
377
377
  }
378
378
  return o.__N || o.__;
379
379
  }
@@ -382,16 +382,16 @@ function gt(t, e) {
382
382
  !F.__s && Oi(n.__H, e) && (n.__ = t, n.u = e, P.__H.__h.push(n));
383
383
  }
384
384
  function Ze(t) {
385
- return Be = 5, me(function() {
385
+ return Le = 5, Ie(function() {
386
386
  return { current: t };
387
387
  }, []);
388
388
  }
389
- function me(t, e) {
389
+ function Ie(t, e) {
390
390
  var n = Rt(Ue++, 7);
391
391
  return Oi(n.__H, e) && (n.__ = t(), n.__H = e, n.__h = t), n.__;
392
392
  }
393
393
  function je(t, e) {
394
- return Be = 8, me(function() {
394
+ return Le = 8, Ie(function() {
395
395
  return t;
396
396
  }, e);
397
397
  }
@@ -425,8 +425,8 @@ F.__b = function(t) {
425
425
  return !o.__ || vt(o);
426
426
  });
427
427
  } catch (o) {
428
- e.some(function(u) {
429
- u.__h && (u.__h = []);
428
+ e.some(function(c) {
429
+ c.__h && (c.__h = []);
430
430
  }), e = [], F.__e(o, n.__v);
431
431
  }
432
432
  }), Qt && Qt(t, e);
@@ -436,8 +436,8 @@ F.__b = function(t) {
436
436
  n && n.__H && (n.__H.__.forEach(function(o) {
437
437
  try {
438
438
  Ye(o);
439
- } catch (u) {
440
- e = u;
439
+ } catch (c) {
440
+ e = c;
441
441
  }
442
442
  }), n.__H = void 0, e && F.__e(e, n.__v));
443
443
  };
@@ -466,8 +466,8 @@ function ki(t, e) {
466
466
  }
467
467
  var In = /* @__PURE__ */ Symbol.for("preact-signals");
468
468
  function st() {
469
- if (pe > 1)
470
- pe--;
469
+ if (fe > 1)
470
+ fe--;
471
471
  else {
472
472
  for (var t, e = !1; ke !== void 0; ) {
473
473
  var n = ke;
@@ -475,42 +475,42 @@ function st() {
475
475
  var o = n.o;
476
476
  if (n.o = void 0, n.f &= -3, !(8 & n.f) && Ui(n)) try {
477
477
  n.c();
478
- } catch (u) {
479
- e || (t = u, e = !0);
478
+ } catch (c) {
479
+ e || (t = c, e = !0);
480
480
  }
481
481
  n = o;
482
482
  }
483
483
  }
484
- if (yt = 0, pe--, e) throw t;
484
+ if (yt = 0, fe--, e) throw t;
485
485
  }
486
486
  }
487
487
  function bn(t) {
488
- if (pe > 0) return t();
489
- pe++;
488
+ if (fe > 0) return t();
489
+ fe++;
490
490
  try {
491
491
  return t();
492
492
  } finally {
493
493
  st();
494
494
  }
495
495
  }
496
- var k = void 0;
496
+ var O = void 0;
497
497
  function Di(t) {
498
- var e = k;
499
- k = void 0;
498
+ var e = O;
499
+ O = void 0;
500
500
  try {
501
501
  return t();
502
502
  } finally {
503
- k = e;
503
+ O = e;
504
504
  }
505
505
  }
506
- var ke = void 0, pe = 0, yt = 0, Qe = 0;
506
+ var ke = void 0, fe = 0, yt = 0, Qe = 0;
507
507
  function Mi(t) {
508
- if (k !== void 0) {
508
+ if (O !== void 0) {
509
509
  var e = t.n;
510
- if (e === void 0 || e.t !== k)
511
- return e = { i: 0, S: t, p: k.s, n: void 0, t: k, e: void 0, x: void 0, r: e }, k.s !== void 0 && (k.s.n = e), k.s = e, t.n = e, 32 & k.f && t.S(e), e;
510
+ if (e === void 0 || e.t !== O)
511
+ return e = { i: 0, S: t, p: O.s, n: void 0, t: O, e: void 0, x: void 0, r: e }, O.s !== void 0 && (O.s.n = e), O.s = e, t.n = e, 32 & O.f && t.S(e), e;
512
512
  if (e.i === -1)
513
- return e.i = 0, e.n !== void 0 && (e.n.p = e.p, e.p !== void 0 && (e.p.n = e.n), e.p = k.s, e.n = void 0, k.s.n = e, k.s = e), e;
513
+ return e.i = 0, e.n !== void 0 && (e.n.p = e.p, e.p !== void 0 && (e.p.n = e.n), e.p = O.s, e.n = void 0, O.s.n = e, O.s = e), e;
514
514
  }
515
515
  }
516
516
  function j(t, e) {
@@ -532,20 +532,20 @@ j.prototype.U = function(t) {
532
532
  if (this.t !== void 0) {
533
533
  var n = t.e, o = t.x;
534
534
  n !== void 0 && (n.x = o, t.e = void 0), o !== void 0 && (o.e = n, t.x = void 0), t === this.t && (this.t = o, o === void 0 && Di(function() {
535
- var u;
536
- (u = e.Z) == null || u.call(e);
535
+ var c;
536
+ (c = e.Z) == null || c.call(e);
537
537
  }));
538
538
  }
539
539
  };
540
540
  j.prototype.subscribe = function(t) {
541
541
  var e = this;
542
542
  return $e(function() {
543
- var n = e.value, o = k;
544
- k = void 0;
543
+ var n = e.value, o = O;
544
+ O = void 0;
545
545
  try {
546
546
  t(n);
547
547
  } finally {
548
- k = o;
548
+ O = o;
549
549
  }
550
550
  }, { name: "sub" });
551
551
  };
@@ -559,12 +559,12 @@ j.prototype.toJSON = function() {
559
559
  return this.value;
560
560
  };
561
561
  j.prototype.peek = function() {
562
- var t = k;
563
- k = void 0;
562
+ var t = O;
563
+ O = void 0;
564
564
  try {
565
565
  return this.value;
566
566
  } finally {
567
- k = t;
567
+ O = t;
568
568
  }
569
569
  };
570
570
  Object.defineProperty(j.prototype, "value", { get: function() {
@@ -573,7 +573,7 @@ Object.defineProperty(j.prototype, "value", { get: function() {
573
573
  }, set: function(t) {
574
574
  if (t !== this.v) {
575
575
  if (yt > 100) throw new Error("Cycle detected");
576
- this.v = t, this.i++, Qe++, pe++;
576
+ this.v = t, this.i++, Qe++, fe++;
577
577
  try {
578
578
  for (var e = this.t; e !== void 0; e = e.x) e.t.N();
579
579
  } finally {
@@ -581,14 +581,14 @@ Object.defineProperty(j.prototype, "value", { get: function() {
581
581
  }
582
582
  }
583
583
  } });
584
- function K(t, e) {
584
+ function Y(t, e) {
585
585
  return new j(t, e);
586
586
  }
587
587
  function Ui(t) {
588
588
  for (var e = t.s; e !== void 0; e = e.n) if (e.S.i !== e.i || !e.S.h() || e.S.i !== e.i) return !0;
589
589
  return !1;
590
590
  }
591
- function Bi(t) {
591
+ function Li(t) {
592
592
  for (var e = t.s; e !== void 0; e = e.n) {
593
593
  var n = e.S.n;
594
594
  if (n !== void 0 && (e.r = n), e.S.n = e, e.i = -1, e.n === void 0) {
@@ -597,72 +597,72 @@ function Bi(t) {
597
597
  }
598
598
  }
599
599
  }
600
- function Li(t) {
600
+ function Bi(t) {
601
601
  for (var e = t.s, n = void 0; e !== void 0; ) {
602
602
  var o = e.p;
603
603
  e.i === -1 ? (e.S.U(e), o !== void 0 && (o.n = e.n), e.n !== void 0 && (e.n.p = o)) : n = e, e.S.n = e.r, e.r !== void 0 && (e.r = void 0), e = o;
604
604
  }
605
605
  t.s = n;
606
606
  }
607
- function ve(t, e) {
607
+ function ge(t, e) {
608
608
  j.call(this, void 0), this.x = t, this.s = void 0, this.g = Qe - 1, this.f = 4, this.W = e?.watched, this.Z = e?.unwatched, this.name = e?.name;
609
609
  }
610
- ve.prototype = new j();
611
- ve.prototype.h = function() {
610
+ ge.prototype = new j();
611
+ ge.prototype.h = function() {
612
612
  if (this.f &= -3, 1 & this.f) return !1;
613
613
  if ((36 & this.f) == 32 || (this.f &= -5, this.g === Qe)) return !0;
614
614
  if (this.g = Qe, this.f |= 1, this.i > 0 && !Ui(this))
615
615
  return this.f &= -2, !0;
616
- var t = k;
616
+ var t = O;
617
617
  try {
618
- Bi(this), k = this;
618
+ Li(this), O = this;
619
619
  var e = this.x();
620
620
  (16 & this.f || this.v !== e || this.i === 0) && (this.v = e, this.f &= -17, this.i++);
621
621
  } catch (n) {
622
622
  this.v = n, this.f |= 16, this.i++;
623
623
  }
624
- return k = t, Li(this), this.f &= -2, !0;
624
+ return O = t, Bi(this), this.f &= -2, !0;
625
625
  };
626
- ve.prototype.S = function(t) {
626
+ ge.prototype.S = function(t) {
627
627
  if (this.t === void 0) {
628
628
  this.f |= 36;
629
629
  for (var e = this.s; e !== void 0; e = e.n) e.S.S(e);
630
630
  }
631
631
  j.prototype.S.call(this, t);
632
632
  };
633
- ve.prototype.U = function(t) {
633
+ ge.prototype.U = function(t) {
634
634
  if (this.t !== void 0 && (j.prototype.U.call(this, t), this.t === void 0)) {
635
635
  this.f &= -33;
636
636
  for (var e = this.s; e !== void 0; e = e.n) e.S.U(e);
637
637
  }
638
638
  };
639
- ve.prototype.N = function() {
639
+ ge.prototype.N = function() {
640
640
  if (!(2 & this.f)) {
641
641
  this.f |= 6;
642
642
  for (var t = this.t; t !== void 0; t = t.x) t.t.N();
643
643
  }
644
644
  };
645
- Object.defineProperty(ve.prototype, "value", { get: function() {
645
+ Object.defineProperty(ge.prototype, "value", { get: function() {
646
646
  if (1 & this.f) throw new Error("Cycle detected");
647
647
  var t = Mi(this);
648
648
  if (this.h(), t !== void 0 && (t.i = this.i), 16 & this.f) throw this.v;
649
649
  return this.v;
650
650
  } });
651
651
  function ni(t, e) {
652
- return new ve(t, e);
652
+ return new ge(t, e);
653
653
  }
654
654
  function Pi(t) {
655
655
  var e = t.u;
656
656
  if (t.u = void 0, typeof e == "function") {
657
- pe++;
658
- var n = k;
659
- k = void 0;
657
+ fe++;
658
+ var n = O;
659
+ O = void 0;
660
660
  try {
661
661
  e();
662
662
  } catch (o) {
663
663
  throw t.f &= -2, t.f |= 8, Nt(t), o;
664
664
  } finally {
665
- k = n, st();
665
+ O = n, st();
666
666
  }
667
667
  }
668
668
  }
@@ -671,8 +671,8 @@ function Nt(t) {
671
671
  t.x = void 0, t.s = void 0, Pi(t);
672
672
  }
673
673
  function An(t) {
674
- if (k !== this) throw new Error("Out-of-order effect");
675
- Li(this), k = t, this.f &= -2, 8 & this.f && Nt(this), st();
674
+ if (O !== this) throw new Error("Out-of-order effect");
675
+ Bi(this), O = t, this.f &= -2, 8 & this.f && Nt(this), st();
676
676
  }
677
677
  function Ae(t, e) {
678
678
  this.x = t, this.u = void 0, this.s = void 0, this.o = void 0, this.f = 32, this.name = e?.name;
@@ -689,9 +689,9 @@ Ae.prototype.c = function() {
689
689
  };
690
690
  Ae.prototype.S = function() {
691
691
  if (1 & this.f) throw new Error("Cycle detected");
692
- this.f |= 1, this.f &= -9, Pi(this), Bi(this), pe++;
693
- var t = k;
694
- return k = this, An.bind(this, t);
692
+ this.f |= 1, this.f &= -9, Pi(this), Li(this), fe++;
693
+ var t = O;
694
+ return O = this, An.bind(this, t);
695
695
  };
696
696
  Ae.prototype.N = function() {
697
697
  2 & this.f || (this.f |= 2, this.o = ke, ke = this);
@@ -706,8 +706,8 @@ function $e(t, e) {
706
706
  var n = new Ae(t, e);
707
707
  try {
708
708
  n.c();
709
- } catch (u) {
710
- throw n.d(), u;
709
+ } catch (c) {
710
+ throw n.d(), c;
711
711
  }
712
712
  var o = n.d.bind(n);
713
713
  return o[Symbol.dispose] = o, o;
@@ -717,16 +717,16 @@ $e(function() {
717
717
  Fi = this.N;
718
718
  })();
719
719
  function Te(t, e) {
720
- D[t] = e.bind(null, D[t] || function() {
720
+ k[t] = e.bind(null, k[t] || function() {
721
721
  });
722
722
  }
723
723
  function et(t) {
724
724
  ht && ht(), ht = t && t.S();
725
725
  }
726
- function Gi(t) {
727
- var e = this, n = t.data, o = Vi(n);
726
+ function Vi(t) {
727
+ var e = this, n = t.data, o = Gi(n);
728
728
  o.value = n;
729
- var u = me(function() {
729
+ var c = Ie(function() {
730
730
  for (var l = e, m = e.__v; m = m.__; ) if (m.__c) {
731
731
  m.__c.__$f |= 4;
732
732
  break;
@@ -741,39 +741,39 @@ function Gi(t) {
741
741
  var g = p.value;
742
742
  l.__v && l.__v.__e && l.__v.__e.nodeType === 3 && (l.__v.__e.data = g);
743
743
  }
744
- }), S = e.__$u.d;
744
+ }), y = e.__$u.d;
745
745
  return e.__$u.d = function() {
746
- d(), S.call(this);
746
+ d(), y.call(this);
747
747
  }, [_, p];
748
- }, []), a = u[0], c = u[1];
749
- return a.value ? c.peek() : c.value;
748
+ }, []), a = c[0], u = c[1];
749
+ return a.value ? u.peek() : u.value;
750
750
  }
751
- Gi.displayName = "ReactiveTextNode";
752
- Object.defineProperties(j.prototype, { constructor: { configurable: !0, value: void 0 }, type: { configurable: !0, value: Gi }, props: { configurable: !0, get: function() {
751
+ Vi.displayName = "ReactiveTextNode";
752
+ Object.defineProperties(j.prototype, { constructor: { configurable: !0, value: void 0 }, type: { configurable: !0, value: Vi }, props: { configurable: !0, get: function() {
753
753
  return { data: this };
754
754
  } }, __b: { configurable: !0, value: 1 } });
755
755
  Te("__b", function(t, e) {
756
756
  if (typeof e.type == "string") {
757
757
  var n, o = e.props;
758
- for (var u in o) if (u !== "children") {
759
- var a = o[u];
760
- a instanceof j && (n || (e.__np = n = {}), n[u] = a, o[u] = a.peek());
758
+ for (var c in o) if (c !== "children") {
759
+ var a = o[c];
760
+ a instanceof j && (n || (e.__np = n = {}), n[c] = a, o[c] = a.peek());
761
761
  }
762
762
  }
763
763
  t(e);
764
764
  });
765
765
  Te("__r", function(t, e) {
766
- if (e.type !== oe) {
766
+ if (e.type !== _e) {
767
767
  et();
768
768
  var n, o = e.__c;
769
- o && (o.__$f &= -2, (n = o.__$u) === void 0 && (o.__$u = n = (function(u, a) {
770
- var c;
769
+ o && (o.__$f &= -2, (n = o.__$u) === void 0 && (o.__$u = n = (function(c, a) {
770
+ var u;
771
771
  return $e(function() {
772
- c = this;
773
- }, { name: a }), c.c = u, c;
772
+ u = this;
773
+ }, { name: a }), u.c = c, u;
774
774
  })(function() {
775
- var u;
776
- Tn && ((u = n.y) == null || u.call(n)), o.__$f |= 1, o.setState({});
775
+ var c;
776
+ Tn && ((c = n.y) == null || c.call(n)), o.__$f |= 1, o.setState({});
777
777
  }, typeof e.type == "function" ? e.type.displayName || e.type.name : ""))), et(n);
778
778
  }
779
779
  t(e);
@@ -785,31 +785,31 @@ Te("diffed", function(t, e) {
785
785
  et();
786
786
  var n;
787
787
  if (typeof e.type == "string" && (n = e.__e)) {
788
- var o = e.__np, u = e.props;
788
+ var o = e.__np, c = e.props;
789
789
  if (o) {
790
790
  var a = n.U;
791
- if (a) for (var c in a) {
792
- var l = a[c];
793
- l !== void 0 && !(c in o) && (l.d(), a[c] = void 0);
791
+ if (a) for (var u in a) {
792
+ var l = a[u];
793
+ l !== void 0 && !(u in o) && (l.d(), a[u] = void 0);
794
794
  }
795
795
  else
796
796
  a = {}, n.U = a;
797
797
  for (var m in o) {
798
798
  var p = a[m], _ = o[m];
799
- p === void 0 ? (p = Rn(n, m, _, u), a[m] = p) : p.o(_, u);
799
+ p === void 0 ? (p = Rn(n, m, _, c), a[m] = p) : p.o(_, c);
800
800
  }
801
801
  }
802
802
  }
803
803
  t(e);
804
804
  });
805
805
  function Rn(t, e, n, o) {
806
- var u = e in t && t.ownerSVGElement === void 0, a = K(n);
807
- return { o: function(c, l) {
808
- a.value = c, o = l;
806
+ var c = e in t && t.ownerSVGElement === void 0, a = Y(n);
807
+ return { o: function(u, l) {
808
+ a.value = u, o = l;
809
809
  }, d: $e(function() {
810
810
  this.N = ji;
811
- var c = a.value.value;
812
- o[e] !== c && (o[e] = c, u ? t[e] = c : c != null && (c !== !1 || e[4] === "-") ? t.setAttribute(e, c) : t.removeAttribute(e));
811
+ var u = a.value.value;
812
+ o[e] !== u && (o[e] = u, c ? t[e] = u : u != null && (u !== !1 || e[4] === "-") ? t.setAttribute(e, u) : t.removeAttribute(e));
813
813
  }) };
814
814
  }
815
815
  Te("unmount", function(t, e) {
@@ -819,17 +819,17 @@ Te("unmount", function(t, e) {
819
819
  var o = n.U;
820
820
  if (o) {
821
821
  n.U = void 0;
822
- for (var u in o) {
823
- var a = o[u];
822
+ for (var c in o) {
823
+ var a = o[c];
824
824
  a && a.d();
825
825
  }
826
826
  }
827
827
  }
828
828
  } else {
829
- var c = e.__c;
830
- if (c) {
831
- var l = c.__$u;
832
- l && (c.__$u = void 0, l.d());
829
+ var u = e.__c;
830
+ if (u) {
831
+ var l = u.__$u;
832
+ l && (u.__$u = void 0, l.d());
833
833
  }
834
834
  }
835
835
  t(e);
@@ -840,18 +840,18 @@ Te("__h", function(t, e, n, o) {
840
840
  Oe.prototype.shouldComponentUpdate = function(t, e) {
841
841
  if (this.__R) return !0;
842
842
  var n = this.__$u, o = n && n.s !== void 0;
843
- for (var u in e) return !0;
843
+ for (var c in e) return !0;
844
844
  if (this.__f || typeof this.u == "boolean" && this.u === !0) {
845
845
  var a = 2 & this.__$f;
846
846
  if (!(o || a || 4 & this.__$f) || 1 & this.__$f) return !0;
847
847
  } else if (!(o || 4 & this.__$f) || 3 & this.__$f) return !0;
848
- for (var c in t) if (c !== "__source" && t[c] !== this.props[c]) return !0;
848
+ for (var u in t) if (u !== "__source" && t[u] !== this.props[u]) return !0;
849
849
  for (var l in this.props) if (!(l in t)) return !0;
850
850
  return !1;
851
851
  };
852
- function Vi(t, e) {
852
+ function Gi(t, e) {
853
853
  return qe(function() {
854
- return K(t, e);
854
+ return Y(t, e);
855
855
  })[0];
856
856
  }
857
857
  var Nn = function(t) {
@@ -865,30 +865,16 @@ function xn() {
865
865
  });
866
866
  }
867
867
  function ji() {
868
- $i.push(this) === 1 && (D.requestAnimationFrame || Nn)(xn);
868
+ $i.push(this) === 1 && (k.requestAnimationFrame || Nn)(xn);
869
869
  }
870
870
  const ri = {
871
871
  inline: !1,
872
872
  layout: "expanded",
873
873
  position: "bottom-right",
874
- styles: {
875
- backgroundColor: "#ffffff",
876
- textColor: "#1f2937"
877
- },
878
874
  showCaptions: !1,
879
875
  showTextInput: !1,
880
876
  showMuteButton: !0,
881
- interactionMode: "both",
882
- startExpanded: !1,
883
- textContents: {
884
- callToAction: "Talk to our assistant",
885
- connecting: "Connecting...",
886
- listening: "Listening...",
887
- speaking: "Speaking...",
888
- endCall: "End",
889
- sendMessage: "Send",
890
- placeholder: "Type a message..."
891
- }
877
+ callToAction: "Talk to our assistant"
892
878
  }, He = {
893
879
  "bottom-right": { bottom: "24px", right: "24px" },
894
880
  "bottom-left": { bottom: "24px", left: "24px" },
@@ -902,94 +888,94 @@ function On(t) {
902
888
  if (!e) return He["bottom-right"];
903
889
  const n = {};
904
890
  for (const o of e[1].split(",")) {
905
- const u = o.trim(), a = u.lastIndexOf("-");
891
+ const c = o.trim(), a = c.lastIndexOf("-");
906
892
  if (a <= 0) continue;
907
- const c = u.slice(0, a), l = u.slice(a + 1);
908
- n[c] = /^\d+$/.test(l) ? `${l}px` : l;
893
+ const u = c.slice(0, a), l = c.slice(a + 1);
894
+ n[u] = /^\d+$/.test(l) ? `${l}px` : l;
909
895
  }
910
896
  return Object.keys(n).length > 0 ? n : He["bottom-right"];
911
897
  }
912
898
  var ft = {}, Ne = {}, oi;
913
899
  function kn() {
914
900
  if (oi) return Ne;
915
- oi = 1, Ne.byteLength = l, Ne.toByteArray = p, Ne.fromByteArray = S;
916
- for (var t = [], e = [], n = typeof Uint8Array < "u" ? Uint8Array : Array, o = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/", u = 0, a = o.length; u < a; ++u)
917
- t[u] = o[u], e[o.charCodeAt(u)] = u;
901
+ oi = 1, Ne.byteLength = l, Ne.toByteArray = p, Ne.fromByteArray = y;
902
+ for (var t = [], e = [], n = typeof Uint8Array < "u" ? Uint8Array : Array, o = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/", c = 0, a = o.length; c < a; ++c)
903
+ t[c] = o[c], e[o.charCodeAt(c)] = c;
918
904
  e[45] = 62, e[95] = 63;
919
- function c(g) {
920
- var y = g.length;
921
- if (y % 4 > 0)
905
+ function u(g) {
906
+ var S = g.length;
907
+ if (S % 4 > 0)
922
908
  throw new Error("Invalid string. Length must be a multiple of 4");
923
- var b = g.indexOf("=");
924
- b === -1 && (b = y);
925
- var A = b === y ? 0 : 4 - b % 4;
926
- return [b, A];
909
+ var C = g.indexOf("=");
910
+ C === -1 && (C = S);
911
+ var A = C === S ? 0 : 4 - C % 4;
912
+ return [C, A];
927
913
  }
928
914
  function l(g) {
929
- var y = c(g), b = y[0], A = y[1];
930
- return (b + A) * 3 / 4 - A;
915
+ var S = u(g), C = S[0], A = S[1];
916
+ return (C + A) * 3 / 4 - A;
931
917
  }
932
- function m(g, y, b) {
933
- return (y + b) * 3 / 4 - b;
918
+ function m(g, S, C) {
919
+ return (S + C) * 3 / 4 - C;
934
920
  }
935
921
  function p(g) {
936
- var y, b = c(g), A = b[0], C = b[1], I = new n(m(g, A, C)), x = 0, O = C > 0 ? A - 4 : A, T;
937
- for (T = 0; T < O; T += 4)
938
- y = e[g.charCodeAt(T)] << 18 | e[g.charCodeAt(T + 1)] << 12 | e[g.charCodeAt(T + 2)] << 6 | e[g.charCodeAt(T + 3)], I[x++] = y >> 16 & 255, I[x++] = y >> 8 & 255, I[x++] = y & 255;
939
- return C === 2 && (y = e[g.charCodeAt(T)] << 2 | e[g.charCodeAt(T + 1)] >> 4, I[x++] = y & 255), C === 1 && (y = e[g.charCodeAt(T)] << 10 | e[g.charCodeAt(T + 1)] << 4 | e[g.charCodeAt(T + 2)] >> 2, I[x++] = y >> 8 & 255, I[x++] = y & 255), I;
922
+ var S, C = u(g), A = C[0], I = C[1], b = new n(m(g, A, I)), T = 0, D = I > 0 ? A - 4 : A, x;
923
+ for (x = 0; x < D; x += 4)
924
+ S = e[g.charCodeAt(x)] << 18 | e[g.charCodeAt(x + 1)] << 12 | e[g.charCodeAt(x + 2)] << 6 | e[g.charCodeAt(x + 3)], b[T++] = S >> 16 & 255, b[T++] = S >> 8 & 255, b[T++] = S & 255;
925
+ return I === 2 && (S = e[g.charCodeAt(x)] << 2 | e[g.charCodeAt(x + 1)] >> 4, b[T++] = S & 255), I === 1 && (S = e[g.charCodeAt(x)] << 10 | e[g.charCodeAt(x + 1)] << 4 | e[g.charCodeAt(x + 2)] >> 2, b[T++] = S >> 8 & 255, b[T++] = S & 255), b;
940
926
  }
941
927
  function _(g) {
942
928
  return t[g >> 18 & 63] + t[g >> 12 & 63] + t[g >> 6 & 63] + t[g & 63];
943
929
  }
944
- function d(g, y, b) {
945
- for (var A, C = [], I = y; I < b; I += 3)
946
- A = (g[I] << 16 & 16711680) + (g[I + 1] << 8 & 65280) + (g[I + 2] & 255), C.push(_(A));
947
- return C.join("");
930
+ function d(g, S, C) {
931
+ for (var A, I = [], b = S; b < C; b += 3)
932
+ A = (g[b] << 16 & 16711680) + (g[b + 1] << 8 & 65280) + (g[b + 2] & 255), I.push(_(A));
933
+ return I.join("");
948
934
  }
949
- function S(g) {
950
- for (var y, b = g.length, A = b % 3, C = [], I = 16383, x = 0, O = b - A; x < O; x += I)
951
- C.push(d(g, x, x + I > O ? O : x + I));
952
- return A === 1 ? (y = g[b - 1], C.push(
953
- t[y >> 2] + t[y << 4 & 63] + "=="
954
- )) : A === 2 && (y = (g[b - 2] << 8) + g[b - 1], C.push(
955
- t[y >> 10] + t[y >> 4 & 63] + t[y << 2 & 63] + "="
956
- )), C.join("");
935
+ function y(g) {
936
+ for (var S, C = g.length, A = C % 3, I = [], b = 16383, T = 0, D = C - A; T < D; T += b)
937
+ I.push(d(g, T, T + b > D ? D : T + b));
938
+ return A === 1 ? (S = g[C - 1], I.push(
939
+ t[S >> 2] + t[S << 4 & 63] + "=="
940
+ )) : A === 2 && (S = (g[C - 2] << 8) + g[C - 1], I.push(
941
+ t[S >> 10] + t[S >> 4 & 63] + t[S << 2 & 63] + "="
942
+ )), I.join("");
957
943
  }
958
944
  return Ne;
959
945
  }
960
946
  var We = {};
961
947
  var si;
962
948
  function Dn() {
963
- return si || (si = 1, We.read = function(t, e, n, o, u) {
964
- var a, c, l = u * 8 - o - 1, m = (1 << l) - 1, p = m >> 1, _ = -7, d = n ? u - 1 : 0, S = n ? -1 : 1, g = t[e + d];
965
- for (d += S, a = g & (1 << -_) - 1, g >>= -_, _ += l; _ > 0; a = a * 256 + t[e + d], d += S, _ -= 8)
949
+ return si || (si = 1, We.read = function(t, e, n, o, c) {
950
+ var a, u, l = c * 8 - o - 1, m = (1 << l) - 1, p = m >> 1, _ = -7, d = n ? c - 1 : 0, y = n ? -1 : 1, g = t[e + d];
951
+ for (d += y, a = g & (1 << -_) - 1, g >>= -_, _ += l; _ > 0; a = a * 256 + t[e + d], d += y, _ -= 8)
966
952
  ;
967
- for (c = a & (1 << -_) - 1, a >>= -_, _ += o; _ > 0; c = c * 256 + t[e + d], d += S, _ -= 8)
953
+ for (u = a & (1 << -_) - 1, a >>= -_, _ += o; _ > 0; u = u * 256 + t[e + d], d += y, _ -= 8)
968
954
  ;
969
955
  if (a === 0)
970
956
  a = 1 - p;
971
957
  else {
972
958
  if (a === m)
973
- return c ? NaN : (g ? -1 : 1) * (1 / 0);
974
- c = c + Math.pow(2, o), a = a - p;
959
+ return u ? NaN : (g ? -1 : 1) * (1 / 0);
960
+ u = u + Math.pow(2, o), a = a - p;
975
961
  }
976
- return (g ? -1 : 1) * c * Math.pow(2, a - o);
977
- }, We.write = function(t, e, n, o, u, a) {
978
- var c, l, m, p = a * 8 - u - 1, _ = (1 << p) - 1, d = _ >> 1, S = u === 23 ? Math.pow(2, -24) - Math.pow(2, -77) : 0, g = o ? 0 : a - 1, y = o ? 1 : -1, b = e < 0 || e === 0 && 1 / e < 0 ? 1 : 0;
979
- for (e = Math.abs(e), isNaN(e) || e === 1 / 0 ? (l = isNaN(e) ? 1 : 0, c = _) : (c = Math.floor(Math.log(e) / Math.LN2), e * (m = Math.pow(2, -c)) < 1 && (c--, m *= 2), c + d >= 1 ? e += S / m : e += S * Math.pow(2, 1 - d), e * m >= 2 && (c++, m /= 2), c + d >= _ ? (l = 0, c = _) : c + d >= 1 ? (l = (e * m - 1) * Math.pow(2, u), c = c + d) : (l = e * Math.pow(2, d - 1) * Math.pow(2, u), c = 0)); u >= 8; t[n + g] = l & 255, g += y, l /= 256, u -= 8)
962
+ return (g ? -1 : 1) * u * Math.pow(2, a - o);
963
+ }, We.write = function(t, e, n, o, c, a) {
964
+ var u, l, m, p = a * 8 - c - 1, _ = (1 << p) - 1, d = _ >> 1, y = c === 23 ? Math.pow(2, -24) - Math.pow(2, -77) : 0, g = o ? 0 : a - 1, S = o ? 1 : -1, C = e < 0 || e === 0 && 1 / e < 0 ? 1 : 0;
965
+ for (e = Math.abs(e), isNaN(e) || e === 1 / 0 ? (l = isNaN(e) ? 1 : 0, u = _) : (u = Math.floor(Math.log(e) / Math.LN2), e * (m = Math.pow(2, -u)) < 1 && (u--, m *= 2), u + d >= 1 ? e += y / m : e += y * Math.pow(2, 1 - d), e * m >= 2 && (u++, m /= 2), u + d >= _ ? (l = 0, u = _) : u + d >= 1 ? (l = (e * m - 1) * Math.pow(2, c), u = u + d) : (l = e * Math.pow(2, d - 1) * Math.pow(2, c), u = 0)); c >= 8; t[n + g] = l & 255, g += S, l /= 256, c -= 8)
980
966
  ;
981
- for (c = c << u | l, p += u; p > 0; t[n + g] = c & 255, g += y, c /= 256, p -= 8)
967
+ for (u = u << c | l, p += c; p > 0; t[n + g] = u & 255, g += S, u /= 256, p -= 8)
982
968
  ;
983
- t[n + g - y] |= b * 128;
969
+ t[n + g - S] |= C * 128;
984
970
  }), We;
985
971
  }
986
972
  var ai;
987
973
  function Mn() {
988
974
  return ai || (ai = 1, (function(t) {
989
975
  const e = kn(), n = Dn(), o = typeof Symbol == "function" && typeof Symbol.for == "function" ? /* @__PURE__ */ Symbol.for("nodejs.util.inspect.custom") : null;
990
- t.Buffer = l, t.SlowBuffer = I, t.INSPECT_MAX_BYTES = 50;
991
- const u = 2147483647;
992
- t.kMaxLength = u, l.TYPED_ARRAY_SUPPORT = a(), !l.TYPED_ARRAY_SUPPORT && typeof console < "u" && typeof console.error == "function" && console.error(
976
+ t.Buffer = l, t.SlowBuffer = b, t.INSPECT_MAX_BYTES = 50;
977
+ const c = 2147483647;
978
+ t.kMaxLength = c, l.TYPED_ARRAY_SUPPORT = a(), !l.TYPED_ARRAY_SUPPORT && typeof console < "u" && typeof console.error == "function" && console.error(
993
979
  "This browser lacks typed array (Uint8Array) support which is required by `buffer` v5.x. Use `buffer` v4.x if you require old browser support."
994
980
  );
995
981
  function a() {
@@ -1015,8 +1001,8 @@ function Mn() {
1015
1001
  return this.byteOffset;
1016
1002
  }
1017
1003
  });
1018
- function c(s) {
1019
- if (s > u)
1004
+ function u(s) {
1005
+ if (s > c)
1020
1006
  throw new RangeError('The value "' + s + '" is invalid for option "size"');
1021
1007
  const i = new Uint8Array(s);
1022
1008
  return Object.setPrototypeOf(i, l.prototype), i;
@@ -1034,15 +1020,15 @@ function Mn() {
1034
1020
  l.poolSize = 8192;
1035
1021
  function m(s, i, r) {
1036
1022
  if (typeof s == "string")
1037
- return S(s, i);
1023
+ return y(s, i);
1038
1024
  if (ArrayBuffer.isView(s))
1039
- return y(s);
1025
+ return S(s);
1040
1026
  if (s == null)
1041
1027
  throw new TypeError(
1042
1028
  "The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type " + typeof s
1043
1029
  );
1044
1030
  if (ee(s, ArrayBuffer) || s && ee(s.buffer, ArrayBuffer) || typeof SharedArrayBuffer < "u" && (ee(s, SharedArrayBuffer) || s && ee(s.buffer, SharedArrayBuffer)))
1045
- return b(s, i, r);
1031
+ return C(s, i, r);
1046
1032
  if (typeof s == "number")
1047
1033
  throw new TypeError(
1048
1034
  'The "value" argument must not be of type number. Received type number'
@@ -1068,41 +1054,41 @@ function Mn() {
1068
1054
  throw new RangeError('The value "' + s + '" is invalid for option "size"');
1069
1055
  }
1070
1056
  function _(s, i, r) {
1071
- return p(s), s <= 0 ? c(s) : i !== void 0 ? typeof r == "string" ? c(s).fill(i, r) : c(s).fill(i) : c(s);
1057
+ return p(s), s <= 0 ? u(s) : i !== void 0 ? typeof r == "string" ? u(s).fill(i, r) : u(s).fill(i) : u(s);
1072
1058
  }
1073
1059
  l.alloc = function(s, i, r) {
1074
1060
  return _(s, i, r);
1075
1061
  };
1076
1062
  function d(s) {
1077
- return p(s), c(s < 0 ? 0 : C(s) | 0);
1063
+ return p(s), u(s < 0 ? 0 : I(s) | 0);
1078
1064
  }
1079
1065
  l.allocUnsafe = function(s) {
1080
1066
  return d(s);
1081
1067
  }, l.allocUnsafeSlow = function(s) {
1082
1068
  return d(s);
1083
1069
  };
1084
- function S(s, i) {
1070
+ function y(s, i) {
1085
1071
  if ((typeof i != "string" || i === "") && (i = "utf8"), !l.isEncoding(i))
1086
1072
  throw new TypeError("Unknown encoding: " + i);
1087
- const r = x(s, i) | 0;
1088
- let h = c(r);
1073
+ const r = T(s, i) | 0;
1074
+ let h = u(r);
1089
1075
  const f = h.write(s, i);
1090
1076
  return f !== r && (h = h.slice(0, f)), h;
1091
1077
  }
1092
1078
  function g(s) {
1093
- const i = s.length < 0 ? 0 : C(s.length) | 0, r = c(i);
1079
+ const i = s.length < 0 ? 0 : I(s.length) | 0, r = u(i);
1094
1080
  for (let h = 0; h < i; h += 1)
1095
1081
  r[h] = s[h] & 255;
1096
1082
  return r;
1097
1083
  }
1098
- function y(s) {
1084
+ function S(s) {
1099
1085
  if (ee(s, Uint8Array)) {
1100
1086
  const i = new Uint8Array(s);
1101
- return b(i.buffer, i.byteOffset, i.byteLength);
1087
+ return C(i.buffer, i.byteOffset, i.byteLength);
1102
1088
  }
1103
1089
  return g(s);
1104
1090
  }
1105
- function b(s, i, r) {
1091
+ function C(s, i, r) {
1106
1092
  if (i < 0 || s.byteLength < i)
1107
1093
  throw new RangeError('"offset" is outside of buffer bounds');
1108
1094
  if (s.byteLength < i + (r || 0))
@@ -1112,20 +1098,20 @@ function Mn() {
1112
1098
  }
1113
1099
  function A(s) {
1114
1100
  if (l.isBuffer(s)) {
1115
- const i = C(s.length) | 0, r = c(i);
1101
+ const i = I(s.length) | 0, r = u(i);
1116
1102
  return r.length === 0 || s.copy(r, 0, 0, i), r;
1117
1103
  }
1118
1104
  if (s.length !== void 0)
1119
- return typeof s.length != "number" || ut(s.length) ? c(0) : g(s);
1105
+ return typeof s.length != "number" || ut(s.length) ? u(0) : g(s);
1120
1106
  if (s.type === "Buffer" && Array.isArray(s.data))
1121
1107
  return g(s.data);
1122
1108
  }
1123
- function C(s) {
1124
- if (s >= u)
1125
- throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x" + u.toString(16) + " bytes");
1109
+ function I(s) {
1110
+ if (s >= c)
1111
+ throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x" + c.toString(16) + " bytes");
1126
1112
  return s | 0;
1127
1113
  }
1128
- function I(s) {
1114
+ function b(s) {
1129
1115
  return +s != s && (s = 0), l.alloc(+s);
1130
1116
  }
1131
1117
  l.isBuffer = function(i) {
@@ -1187,7 +1173,7 @@ function Mn() {
1187
1173
  }
1188
1174
  return f;
1189
1175
  };
1190
- function x(s, i) {
1176
+ function T(s, i) {
1191
1177
  if (l.isBuffer(s))
1192
1178
  return s.length;
1193
1179
  if (ArrayBuffer.isView(s) || ee(s, ArrayBuffer))
@@ -1223,8 +1209,8 @@ function Mn() {
1223
1209
  i = ("" + i).toLowerCase(), f = !0;
1224
1210
  }
1225
1211
  }
1226
- l.byteLength = x;
1227
- function O(s, i, r) {
1212
+ l.byteLength = T;
1213
+ function D(s, i, r) {
1228
1214
  let h = !1;
1229
1215
  if ((i === void 0 || i < 0) && (i = 0), i > this.length || ((r === void 0 || r > this.length) && (r = this.length), r <= 0) || (r >>>= 0, i >>>= 0, r <= i))
1230
1216
  return "";
@@ -1253,7 +1239,7 @@ function Mn() {
1253
1239
  }
1254
1240
  }
1255
1241
  l.prototype._isBuffer = !0;
1256
- function T(s, i, r) {
1242
+ function x(s, i, r) {
1257
1243
  const h = s[i];
1258
1244
  s[i] = s[r], s[r] = h;
1259
1245
  }
@@ -1262,25 +1248,25 @@ function Mn() {
1262
1248
  if (i % 2 !== 0)
1263
1249
  throw new RangeError("Buffer size must be a multiple of 16-bits");
1264
1250
  for (let r = 0; r < i; r += 2)
1265
- T(this, r, r + 1);
1251
+ x(this, r, r + 1);
1266
1252
  return this;
1267
1253
  }, l.prototype.swap32 = function() {
1268
1254
  const i = this.length;
1269
1255
  if (i % 4 !== 0)
1270
1256
  throw new RangeError("Buffer size must be a multiple of 32-bits");
1271
1257
  for (let r = 0; r < i; r += 4)
1272
- T(this, r, r + 3), T(this, r + 1, r + 2);
1258
+ x(this, r, r + 3), x(this, r + 1, r + 2);
1273
1259
  return this;
1274
1260
  }, l.prototype.swap64 = function() {
1275
1261
  const i = this.length;
1276
1262
  if (i % 8 !== 0)
1277
1263
  throw new RangeError("Buffer size must be a multiple of 64-bits");
1278
1264
  for (let r = 0; r < i; r += 8)
1279
- T(this, r, r + 7), T(this, r + 1, r + 6), T(this, r + 2, r + 5), T(this, r + 3, r + 4);
1265
+ x(this, r, r + 7), x(this, r + 1, r + 6), x(this, r + 2, r + 5), x(this, r + 3, r + 4);
1280
1266
  return this;
1281
1267
  }, l.prototype.toString = function() {
1282
1268
  const i = this.length;
1283
- return i === 0 ? "" : arguments.length === 0 ? Mt(this, 0, i) : O.apply(this, arguments);
1269
+ return i === 0 ? "" : arguments.length === 0 ? Mt(this, 0, i) : D.apply(this, arguments);
1284
1270
  }, l.prototype.toLocaleString = l.prototype.toString, l.prototype.equals = function(i) {
1285
1271
  if (!l.isBuffer(i)) throw new TypeError("Argument must be a Buffer");
1286
1272
  return this === i ? !0 : l.compare(this, i) === 0;
@@ -1303,15 +1289,15 @@ function Mn() {
1303
1289
  return 1;
1304
1290
  if (r >>>= 0, h >>>= 0, f >>>= 0, E >>>= 0, this === i) return 0;
1305
1291
  let v = E - f, R = h - r;
1306
- const B = Math.min(v, R), U = this.slice(f, E), L = i.slice(r, h);
1307
- for (let M = 0; M < B; ++M)
1308
- if (U[M] !== L[M]) {
1309
- v = U[M], R = L[M];
1292
+ const L = Math.min(v, R), U = this.slice(f, E), B = i.slice(r, h);
1293
+ for (let M = 0; M < L; ++M)
1294
+ if (U[M] !== B[M]) {
1295
+ v = U[M], R = B[M];
1310
1296
  break;
1311
1297
  }
1312
1298
  return v < R ? -1 : R < v ? 1 : 0;
1313
1299
  };
1314
- function q(s, i, r, h, f) {
1300
+ function Z(s, i, r, h, f) {
1315
1301
  if (s.length === 0) return -1;
1316
1302
  if (typeof r == "string" ? (h = r, r = 0) : r > 2147483647 ? r = 2147483647 : r < -2147483648 && (r = -2147483648), r = +r, ut(r) && (r = f ? 0 : s.length - 1), r < 0 && (r = s.length + r), r >= s.length) {
1317
1303
  if (f) return -1;
@@ -1332,37 +1318,37 @@ function Mn() {
1332
1318
  return -1;
1333
1319
  E = 2, v /= 2, R /= 2, r /= 2;
1334
1320
  }
1335
- function B(L, M) {
1336
- return E === 1 ? L[M] : L.readUInt16BE(M * E);
1321
+ function L(B, M) {
1322
+ return E === 1 ? B[M] : B.readUInt16BE(M * E);
1337
1323
  }
1338
1324
  let U;
1339
1325
  if (f) {
1340
- let L = -1;
1326
+ let B = -1;
1341
1327
  for (U = r; U < v; U++)
1342
- if (B(s, U) === B(i, L === -1 ? 0 : U - L)) {
1343
- if (L === -1 && (L = U), U - L + 1 === R) return L * E;
1328
+ if (L(s, U) === L(i, B === -1 ? 0 : U - B)) {
1329
+ if (B === -1 && (B = U), U - B + 1 === R) return B * E;
1344
1330
  } else
1345
- L !== -1 && (U -= U - L), L = -1;
1331
+ B !== -1 && (U -= U - B), B = -1;
1346
1332
  } else
1347
1333
  for (r + R > v && (r = v - R), U = r; U >= 0; U--) {
1348
- let L = !0;
1334
+ let B = !0;
1349
1335
  for (let M = 0; M < R; M++)
1350
- if (B(s, U + M) !== B(i, M)) {
1351
- L = !1;
1336
+ if (L(s, U + M) !== L(i, M)) {
1337
+ B = !1;
1352
1338
  break;
1353
1339
  }
1354
- if (L) return U;
1340
+ if (B) return U;
1355
1341
  }
1356
1342
  return -1;
1357
1343
  }
1358
1344
  l.prototype.includes = function(i, r, h) {
1359
1345
  return this.indexOf(i, r, h) !== -1;
1360
1346
  }, l.prototype.indexOf = function(i, r, h) {
1361
- return q(this, i, r, h, !0);
1347
+ return Z(this, i, r, h, !0);
1362
1348
  }, l.prototype.lastIndexOf = function(i, r, h) {
1363
- return q(this, i, r, h, !1);
1349
+ return Z(this, i, r, h, !1);
1364
1350
  };
1365
- function ae(s, i, r, h) {
1351
+ function se(s, i, r, h) {
1366
1352
  r = Number(r) || 0;
1367
1353
  const f = s.length - r;
1368
1354
  h ? (h = Number(h), h > f && (h = f)) : h = f;
@@ -1377,16 +1363,16 @@ function Mn() {
1377
1363
  return v;
1378
1364
  }
1379
1365
  function ne(s, i, r, h) {
1380
- return Ge(ct(i, s.length - r), s, r, h);
1366
+ return Ve(ct(i, s.length - r), s, r, h);
1381
1367
  }
1382
1368
  function re(s, i, r, h) {
1383
- return Ge(rn(i), s, r, h);
1369
+ return Ve(rn(i), s, r, h);
1384
1370
  }
1385
1371
  function Q(s, i, r, h) {
1386
- return Ge(jt(i), s, r, h);
1372
+ return Ve(jt(i), s, r, h);
1387
1373
  }
1388
- function le(s, i, r, h) {
1389
- return Ge(on(i, s.length - r), s, r, h);
1374
+ function ae(s, i, r, h) {
1375
+ return Ve(on(i, s.length - r), s, r, h);
1390
1376
  }
1391
1377
  l.prototype.write = function(i, r, h, f) {
1392
1378
  if (r === void 0)
@@ -1407,7 +1393,7 @@ function Mn() {
1407
1393
  for (; ; )
1408
1394
  switch (f) {
1409
1395
  case "hex":
1410
- return ae(this, i, r, h);
1396
+ return se(this, i, r, h);
1411
1397
  case "utf8":
1412
1398
  case "utf-8":
1413
1399
  return ne(this, i, r, h);
@@ -1421,7 +1407,7 @@ function Mn() {
1421
1407
  case "ucs-2":
1422
1408
  case "utf16le":
1423
1409
  case "utf-16le":
1424
- return le(this, i, r, h);
1410
+ return ae(this, i, r, h);
1425
1411
  default:
1426
1412
  if (v) throw new TypeError("Unknown encoding: " + f);
1427
1413
  f = ("" + f).toLowerCase(), v = !0;
@@ -1443,19 +1429,19 @@ function Mn() {
1443
1429
  const E = s[f];
1444
1430
  let v = null, R = E > 239 ? 4 : E > 223 ? 3 : E > 191 ? 2 : 1;
1445
1431
  if (f + R <= r) {
1446
- let B, U, L, M;
1432
+ let L, U, B, M;
1447
1433
  switch (R) {
1448
1434
  case 1:
1449
1435
  E < 128 && (v = E);
1450
1436
  break;
1451
1437
  case 2:
1452
- B = s[f + 1], (B & 192) === 128 && (M = (E & 31) << 6 | B & 63, M > 127 && (v = M));
1438
+ L = s[f + 1], (L & 192) === 128 && (M = (E & 31) << 6 | L & 63, M > 127 && (v = M));
1453
1439
  break;
1454
1440
  case 3:
1455
- B = s[f + 1], U = s[f + 2], (B & 192) === 128 && (U & 192) === 128 && (M = (E & 15) << 12 | (B & 63) << 6 | U & 63, M > 2047 && (M < 55296 || M > 57343) && (v = M));
1441
+ L = s[f + 1], U = s[f + 2], (L & 192) === 128 && (U & 192) === 128 && (M = (E & 15) << 12 | (L & 63) << 6 | U & 63, M > 2047 && (M < 55296 || M > 57343) && (v = M));
1456
1442
  break;
1457
1443
  case 4:
1458
- B = s[f + 1], U = s[f + 2], L = s[f + 3], (B & 192) === 128 && (U & 192) === 128 && (L & 192) === 128 && (M = (E & 15) << 18 | (B & 63) << 12 | (U & 63) << 6 | L & 63, M > 65535 && M < 1114112 && (v = M));
1444
+ L = s[f + 1], U = s[f + 2], B = s[f + 3], (L & 192) === 128 && (U & 192) === 128 && (B & 192) === 128 && (M = (E & 15) << 18 | (L & 63) << 12 | (U & 63) << 6 | B & 63, M > 65535 && M < 1114112 && (v = M));
1459
1445
  }
1460
1446
  }
1461
1447
  v === null ? (v = 65533, R = 1) : v > 65535 && (v -= 65536, h.push(v >>> 10 & 1023 | 55296), v = 56320 | v & 1023), h.push(v), f += R;
@@ -1510,93 +1496,93 @@ function Mn() {
1510
1496
  const f = this.subarray(i, r);
1511
1497
  return Object.setPrototypeOf(f, l.prototype), f;
1512
1498
  };
1513
- function G(s, i, r) {
1499
+ function V(s, i, r) {
1514
1500
  if (s % 1 !== 0 || s < 0) throw new RangeError("offset is not uint");
1515
1501
  if (s + i > r) throw new RangeError("Trying to access beyond buffer length");
1516
1502
  }
1517
1503
  l.prototype.readUintLE = l.prototype.readUIntLE = function(i, r, h) {
1518
- i = i >>> 0, r = r >>> 0, h || G(i, r, this.length);
1504
+ i = i >>> 0, r = r >>> 0, h || V(i, r, this.length);
1519
1505
  let f = this[i], E = 1, v = 0;
1520
1506
  for (; ++v < r && (E *= 256); )
1521
1507
  f += this[i + v] * E;
1522
1508
  return f;
1523
1509
  }, l.prototype.readUintBE = l.prototype.readUIntBE = function(i, r, h) {
1524
- i = i >>> 0, r = r >>> 0, h || G(i, r, this.length);
1510
+ i = i >>> 0, r = r >>> 0, h || V(i, r, this.length);
1525
1511
  let f = this[i + --r], E = 1;
1526
1512
  for (; r > 0 && (E *= 256); )
1527
1513
  f += this[i + --r] * E;
1528
1514
  return f;
1529
1515
  }, l.prototype.readUint8 = l.prototype.readUInt8 = function(i, r) {
1530
- return i = i >>> 0, r || G(i, 1, this.length), this[i];
1516
+ return i = i >>> 0, r || V(i, 1, this.length), this[i];
1531
1517
  }, l.prototype.readUint16LE = l.prototype.readUInt16LE = function(i, r) {
1532
- return i = i >>> 0, r || G(i, 2, this.length), this[i] | this[i + 1] << 8;
1518
+ return i = i >>> 0, r || V(i, 2, this.length), this[i] | this[i + 1] << 8;
1533
1519
  }, l.prototype.readUint16BE = l.prototype.readUInt16BE = function(i, r) {
1534
- return i = i >>> 0, r || G(i, 2, this.length), this[i] << 8 | this[i + 1];
1520
+ return i = i >>> 0, r || V(i, 2, this.length), this[i] << 8 | this[i + 1];
1535
1521
  }, l.prototype.readUint32LE = l.prototype.readUInt32LE = function(i, r) {
1536
- return i = i >>> 0, r || G(i, 4, this.length), (this[i] | this[i + 1] << 8 | this[i + 2] << 16) + this[i + 3] * 16777216;
1522
+ return i = i >>> 0, r || V(i, 4, this.length), (this[i] | this[i + 1] << 8 | this[i + 2] << 16) + this[i + 3] * 16777216;
1537
1523
  }, l.prototype.readUint32BE = l.prototype.readUInt32BE = function(i, r) {
1538
- return i = i >>> 0, r || G(i, 4, this.length), this[i] * 16777216 + (this[i + 1] << 16 | this[i + 2] << 8 | this[i + 3]);
1539
- }, l.prototype.readBigUInt64LE = ce(function(i) {
1540
- i = i >>> 0, Se(i, "offset");
1524
+ return i = i >>> 0, r || V(i, 4, this.length), this[i] * 16777216 + (this[i + 1] << 16 | this[i + 2] << 8 | this[i + 3]);
1525
+ }, l.prototype.readBigUInt64LE = le(function(i) {
1526
+ i = i >>> 0, ye(i, "offset");
1541
1527
  const r = this[i], h = this[i + 7];
1542
1528
  (r === void 0 || h === void 0) && Re(i, this.length - 8);
1543
1529
  const f = r + this[++i] * 2 ** 8 + this[++i] * 2 ** 16 + this[++i] * 2 ** 24, E = this[++i] + this[++i] * 2 ** 8 + this[++i] * 2 ** 16 + h * 2 ** 24;
1544
1530
  return BigInt(f) + (BigInt(E) << BigInt(32));
1545
- }), l.prototype.readBigUInt64BE = ce(function(i) {
1546
- i = i >>> 0, Se(i, "offset");
1531
+ }), l.prototype.readBigUInt64BE = le(function(i) {
1532
+ i = i >>> 0, ye(i, "offset");
1547
1533
  const r = this[i], h = this[i + 7];
1548
1534
  (r === void 0 || h === void 0) && Re(i, this.length - 8);
1549
1535
  const f = r * 2 ** 24 + this[++i] * 2 ** 16 + this[++i] * 2 ** 8 + this[++i], E = this[++i] * 2 ** 24 + this[++i] * 2 ** 16 + this[++i] * 2 ** 8 + h;
1550
1536
  return (BigInt(f) << BigInt(32)) + BigInt(E);
1551
1537
  }), l.prototype.readIntLE = function(i, r, h) {
1552
- i = i >>> 0, r = r >>> 0, h || G(i, r, this.length);
1538
+ i = i >>> 0, r = r >>> 0, h || V(i, r, this.length);
1553
1539
  let f = this[i], E = 1, v = 0;
1554
1540
  for (; ++v < r && (E *= 256); )
1555
1541
  f += this[i + v] * E;
1556
1542
  return E *= 128, f >= E && (f -= Math.pow(2, 8 * r)), f;
1557
1543
  }, l.prototype.readIntBE = function(i, r, h) {
1558
- i = i >>> 0, r = r >>> 0, h || G(i, r, this.length);
1544
+ i = i >>> 0, r = r >>> 0, h || V(i, r, this.length);
1559
1545
  let f = r, E = 1, v = this[i + --f];
1560
1546
  for (; f > 0 && (E *= 256); )
1561
1547
  v += this[i + --f] * E;
1562
1548
  return E *= 128, v >= E && (v -= Math.pow(2, 8 * r)), v;
1563
1549
  }, l.prototype.readInt8 = function(i, r) {
1564
- return i = i >>> 0, r || G(i, 1, this.length), this[i] & 128 ? (255 - this[i] + 1) * -1 : this[i];
1550
+ return i = i >>> 0, r || V(i, 1, this.length), this[i] & 128 ? (255 - this[i] + 1) * -1 : this[i];
1565
1551
  }, l.prototype.readInt16LE = function(i, r) {
1566
- i = i >>> 0, r || G(i, 2, this.length);
1552
+ i = i >>> 0, r || V(i, 2, this.length);
1567
1553
  const h = this[i] | this[i + 1] << 8;
1568
1554
  return h & 32768 ? h | 4294901760 : h;
1569
1555
  }, l.prototype.readInt16BE = function(i, r) {
1570
- i = i >>> 0, r || G(i, 2, this.length);
1556
+ i = i >>> 0, r || V(i, 2, this.length);
1571
1557
  const h = this[i + 1] | this[i] << 8;
1572
1558
  return h & 32768 ? h | 4294901760 : h;
1573
1559
  }, l.prototype.readInt32LE = function(i, r) {
1574
- return i = i >>> 0, r || G(i, 4, this.length), this[i] | this[i + 1] << 8 | this[i + 2] << 16 | this[i + 3] << 24;
1560
+ return i = i >>> 0, r || V(i, 4, this.length), this[i] | this[i + 1] << 8 | this[i + 2] << 16 | this[i + 3] << 24;
1575
1561
  }, l.prototype.readInt32BE = function(i, r) {
1576
- return i = i >>> 0, r || G(i, 4, this.length), this[i] << 24 | this[i + 1] << 16 | this[i + 2] << 8 | this[i + 3];
1577
- }, l.prototype.readBigInt64LE = ce(function(i) {
1578
- i = i >>> 0, Se(i, "offset");
1562
+ return i = i >>> 0, r || V(i, 4, this.length), this[i] << 24 | this[i + 1] << 16 | this[i + 2] << 8 | this[i + 3];
1563
+ }, l.prototype.readBigInt64LE = le(function(i) {
1564
+ i = i >>> 0, ye(i, "offset");
1579
1565
  const r = this[i], h = this[i + 7];
1580
1566
  (r === void 0 || h === void 0) && Re(i, this.length - 8);
1581
1567
  const f = this[i + 4] + this[i + 5] * 2 ** 8 + this[i + 6] * 2 ** 16 + (h << 24);
1582
1568
  return (BigInt(f) << BigInt(32)) + BigInt(r + this[++i] * 2 ** 8 + this[++i] * 2 ** 16 + this[++i] * 2 ** 24);
1583
- }), l.prototype.readBigInt64BE = ce(function(i) {
1584
- i = i >>> 0, Se(i, "offset");
1569
+ }), l.prototype.readBigInt64BE = le(function(i) {
1570
+ i = i >>> 0, ye(i, "offset");
1585
1571
  const r = this[i], h = this[i + 7];
1586
1572
  (r === void 0 || h === void 0) && Re(i, this.length - 8);
1587
1573
  const f = (r << 24) + // Overflow
1588
1574
  this[++i] * 2 ** 16 + this[++i] * 2 ** 8 + this[++i];
1589
1575
  return (BigInt(f) << BigInt(32)) + BigInt(this[++i] * 2 ** 24 + this[++i] * 2 ** 16 + this[++i] * 2 ** 8 + h);
1590
1576
  }), l.prototype.readFloatLE = function(i, r) {
1591
- return i = i >>> 0, r || G(i, 4, this.length), n.read(this, i, !0, 23, 4);
1577
+ return i = i >>> 0, r || V(i, 4, this.length), n.read(this, i, !0, 23, 4);
1592
1578
  }, l.prototype.readFloatBE = function(i, r) {
1593
- return i = i >>> 0, r || G(i, 4, this.length), n.read(this, i, !1, 23, 4);
1579
+ return i = i >>> 0, r || V(i, 4, this.length), n.read(this, i, !1, 23, 4);
1594
1580
  }, l.prototype.readDoubleLE = function(i, r) {
1595
- return i = i >>> 0, r || G(i, 8, this.length), n.read(this, i, !0, 52, 8);
1581
+ return i = i >>> 0, r || V(i, 8, this.length), n.read(this, i, !0, 52, 8);
1596
1582
  }, l.prototype.readDoubleBE = function(i, r) {
1597
- return i = i >>> 0, r || G(i, 8, this.length), n.read(this, i, !1, 52, 8);
1583
+ return i = i >>> 0, r || V(i, 8, this.length), n.read(this, i, !1, 52, 8);
1598
1584
  };
1599
- function Y(s, i, r, h, f, E) {
1585
+ function q(s, i, r, h, f, E) {
1600
1586
  if (!l.isBuffer(s)) throw new TypeError('"buffer" argument must be a Buffer instance');
1601
1587
  if (i > f || i < E) throw new RangeError('"value" argument is out of bounds');
1602
1588
  if (r + h > s.length) throw new RangeError("Index out of range");
@@ -1604,7 +1590,7 @@ function Mn() {
1604
1590
  l.prototype.writeUintLE = l.prototype.writeUIntLE = function(i, r, h, f) {
1605
1591
  if (i = +i, r = r >>> 0, h = h >>> 0, !f) {
1606
1592
  const R = Math.pow(2, 8 * h) - 1;
1607
- Y(this, i, r, h, R, 0);
1593
+ q(this, i, r, h, R, 0);
1608
1594
  }
1609
1595
  let E = 1, v = 0;
1610
1596
  for (this[r] = i & 255; ++v < h && (E *= 256); )
@@ -1613,45 +1599,45 @@ function Mn() {
1613
1599
  }, l.prototype.writeUintBE = l.prototype.writeUIntBE = function(i, r, h, f) {
1614
1600
  if (i = +i, r = r >>> 0, h = h >>> 0, !f) {
1615
1601
  const R = Math.pow(2, 8 * h) - 1;
1616
- Y(this, i, r, h, R, 0);
1602
+ q(this, i, r, h, R, 0);
1617
1603
  }
1618
1604
  let E = h - 1, v = 1;
1619
1605
  for (this[r + E] = i & 255; --E >= 0 && (v *= 256); )
1620
1606
  this[r + E] = i / v & 255;
1621
1607
  return r + h;
1622
1608
  }, l.prototype.writeUint8 = l.prototype.writeUInt8 = function(i, r, h) {
1623
- return i = +i, r = r >>> 0, h || Y(this, i, r, 1, 255, 0), this[r] = i & 255, r + 1;
1609
+ return i = +i, r = r >>> 0, h || q(this, i, r, 1, 255, 0), this[r] = i & 255, r + 1;
1624
1610
  }, l.prototype.writeUint16LE = l.prototype.writeUInt16LE = function(i, r, h) {
1625
- return i = +i, r = r >>> 0, h || Y(this, i, r, 2, 65535, 0), this[r] = i & 255, this[r + 1] = i >>> 8, r + 2;
1611
+ return i = +i, r = r >>> 0, h || q(this, i, r, 2, 65535, 0), this[r] = i & 255, this[r + 1] = i >>> 8, r + 2;
1626
1612
  }, l.prototype.writeUint16BE = l.prototype.writeUInt16BE = function(i, r, h) {
1627
- return i = +i, r = r >>> 0, h || Y(this, i, r, 2, 65535, 0), this[r] = i >>> 8, this[r + 1] = i & 255, r + 2;
1613
+ return i = +i, r = r >>> 0, h || q(this, i, r, 2, 65535, 0), this[r] = i >>> 8, this[r + 1] = i & 255, r + 2;
1628
1614
  }, l.prototype.writeUint32LE = l.prototype.writeUInt32LE = function(i, r, h) {
1629
- return i = +i, r = r >>> 0, h || Y(this, i, r, 4, 4294967295, 0), this[r + 3] = i >>> 24, this[r + 2] = i >>> 16, this[r + 1] = i >>> 8, this[r] = i & 255, r + 4;
1615
+ return i = +i, r = r >>> 0, h || q(this, i, r, 4, 4294967295, 0), this[r + 3] = i >>> 24, this[r + 2] = i >>> 16, this[r + 1] = i >>> 8, this[r] = i & 255, r + 4;
1630
1616
  }, l.prototype.writeUint32BE = l.prototype.writeUInt32BE = function(i, r, h) {
1631
- return i = +i, r = r >>> 0, h || Y(this, i, r, 4, 4294967295, 0), this[r] = i >>> 24, this[r + 1] = i >>> 16, this[r + 2] = i >>> 8, this[r + 3] = i & 255, r + 4;
1617
+ return i = +i, r = r >>> 0, h || q(this, i, r, 4, 4294967295, 0), this[r] = i >>> 24, this[r + 1] = i >>> 16, this[r + 2] = i >>> 8, this[r + 3] = i & 255, r + 4;
1632
1618
  };
1633
- function Bt(s, i, r, h, f) {
1634
- Vt(i, h, f, s, r, 7);
1619
+ function Lt(s, i, r, h, f) {
1620
+ Gt(i, h, f, s, r, 7);
1635
1621
  let E = Number(i & BigInt(4294967295));
1636
1622
  s[r++] = E, E = E >> 8, s[r++] = E, E = E >> 8, s[r++] = E, E = E >> 8, s[r++] = E;
1637
1623
  let v = Number(i >> BigInt(32) & BigInt(4294967295));
1638
1624
  return s[r++] = v, v = v >> 8, s[r++] = v, v = v >> 8, s[r++] = v, v = v >> 8, s[r++] = v, r;
1639
1625
  }
1640
- function Lt(s, i, r, h, f) {
1641
- Vt(i, h, f, s, r, 7);
1626
+ function Bt(s, i, r, h, f) {
1627
+ Gt(i, h, f, s, r, 7);
1642
1628
  let E = Number(i & BigInt(4294967295));
1643
1629
  s[r + 7] = E, E = E >> 8, s[r + 6] = E, E = E >> 8, s[r + 5] = E, E = E >> 8, s[r + 4] = E;
1644
1630
  let v = Number(i >> BigInt(32) & BigInt(4294967295));
1645
1631
  return s[r + 3] = v, v = v >> 8, s[r + 2] = v, v = v >> 8, s[r + 1] = v, v = v >> 8, s[r] = v, r + 8;
1646
1632
  }
1647
- l.prototype.writeBigUInt64LE = ce(function(i, r = 0) {
1648
- return Bt(this, i, r, BigInt(0), BigInt("0xffffffffffffffff"));
1649
- }), l.prototype.writeBigUInt64BE = ce(function(i, r = 0) {
1633
+ l.prototype.writeBigUInt64LE = le(function(i, r = 0) {
1650
1634
  return Lt(this, i, r, BigInt(0), BigInt("0xffffffffffffffff"));
1635
+ }), l.prototype.writeBigUInt64BE = le(function(i, r = 0) {
1636
+ return Bt(this, i, r, BigInt(0), BigInt("0xffffffffffffffff"));
1651
1637
  }), l.prototype.writeIntLE = function(i, r, h, f) {
1652
1638
  if (i = +i, r = r >>> 0, !f) {
1653
- const B = Math.pow(2, 8 * h - 1);
1654
- Y(this, i, r, h, B - 1, -B);
1639
+ const L = Math.pow(2, 8 * h - 1);
1640
+ q(this, i, r, h, L - 1, -L);
1655
1641
  }
1656
1642
  let E = 0, v = 1, R = 0;
1657
1643
  for (this[r] = i & 255; ++E < h && (v *= 256); )
@@ -1659,27 +1645,27 @@ function Mn() {
1659
1645
  return r + h;
1660
1646
  }, l.prototype.writeIntBE = function(i, r, h, f) {
1661
1647
  if (i = +i, r = r >>> 0, !f) {
1662
- const B = Math.pow(2, 8 * h - 1);
1663
- Y(this, i, r, h, B - 1, -B);
1648
+ const L = Math.pow(2, 8 * h - 1);
1649
+ q(this, i, r, h, L - 1, -L);
1664
1650
  }
1665
1651
  let E = h - 1, v = 1, R = 0;
1666
1652
  for (this[r + E] = i & 255; --E >= 0 && (v *= 256); )
1667
1653
  i < 0 && R === 0 && this[r + E + 1] !== 0 && (R = 1), this[r + E] = (i / v >> 0) - R & 255;
1668
1654
  return r + h;
1669
1655
  }, l.prototype.writeInt8 = function(i, r, h) {
1670
- return i = +i, r = r >>> 0, h || Y(this, i, r, 1, 127, -128), i < 0 && (i = 255 + i + 1), this[r] = i & 255, r + 1;
1656
+ return i = +i, r = r >>> 0, h || q(this, i, r, 1, 127, -128), i < 0 && (i = 255 + i + 1), this[r] = i & 255, r + 1;
1671
1657
  }, l.prototype.writeInt16LE = function(i, r, h) {
1672
- return i = +i, r = r >>> 0, h || Y(this, i, r, 2, 32767, -32768), this[r] = i & 255, this[r + 1] = i >>> 8, r + 2;
1658
+ return i = +i, r = r >>> 0, h || q(this, i, r, 2, 32767, -32768), this[r] = i & 255, this[r + 1] = i >>> 8, r + 2;
1673
1659
  }, l.prototype.writeInt16BE = function(i, r, h) {
1674
- return i = +i, r = r >>> 0, h || Y(this, i, r, 2, 32767, -32768), this[r] = i >>> 8, this[r + 1] = i & 255, r + 2;
1660
+ return i = +i, r = r >>> 0, h || q(this, i, r, 2, 32767, -32768), this[r] = i >>> 8, this[r + 1] = i & 255, r + 2;
1675
1661
  }, l.prototype.writeInt32LE = function(i, r, h) {
1676
- return i = +i, r = r >>> 0, h || Y(this, i, r, 4, 2147483647, -2147483648), this[r] = i & 255, this[r + 1] = i >>> 8, this[r + 2] = i >>> 16, this[r + 3] = i >>> 24, r + 4;
1662
+ return i = +i, r = r >>> 0, h || q(this, i, r, 4, 2147483647, -2147483648), this[r] = i & 255, this[r + 1] = i >>> 8, this[r + 2] = i >>> 16, this[r + 3] = i >>> 24, r + 4;
1677
1663
  }, l.prototype.writeInt32BE = function(i, r, h) {
1678
- return i = +i, r = r >>> 0, h || Y(this, i, r, 4, 2147483647, -2147483648), i < 0 && (i = 4294967295 + i + 1), this[r] = i >>> 24, this[r + 1] = i >>> 16, this[r + 2] = i >>> 8, this[r + 3] = i & 255, r + 4;
1679
- }, l.prototype.writeBigInt64LE = ce(function(i, r = 0) {
1680
- return Bt(this, i, r, -BigInt("0x8000000000000000"), BigInt("0x7fffffffffffffff"));
1681
- }), l.prototype.writeBigInt64BE = ce(function(i, r = 0) {
1664
+ return i = +i, r = r >>> 0, h || q(this, i, r, 4, 2147483647, -2147483648), i < 0 && (i = 4294967295 + i + 1), this[r] = i >>> 24, this[r + 1] = i >>> 16, this[r + 2] = i >>> 8, this[r + 3] = i & 255, r + 4;
1665
+ }, l.prototype.writeBigInt64LE = le(function(i, r = 0) {
1682
1666
  return Lt(this, i, r, -BigInt("0x8000000000000000"), BigInt("0x7fffffffffffffff"));
1667
+ }), l.prototype.writeBigInt64BE = le(function(i, r = 0) {
1668
+ return Bt(this, i, r, -BigInt("0x8000000000000000"), BigInt("0x7fffffffffffffff"));
1683
1669
  });
1684
1670
  function Pt(s, i, r, h, f, E) {
1685
1671
  if (r + h > s.length) throw new RangeError("Index out of range");
@@ -1743,9 +1729,9 @@ function Mn() {
1743
1729
  }
1744
1730
  return this;
1745
1731
  };
1746
- const ye = {};
1732
+ const ve = {};
1747
1733
  function lt(s, i, r) {
1748
- ye[s] = class extends r {
1734
+ ve[s] = class extends r {
1749
1735
  constructor() {
1750
1736
  super(), Object.defineProperty(this, "message", {
1751
1737
  value: i.apply(this, arguments),
@@ -1785,11 +1771,11 @@ function Mn() {
1785
1771
  "ERR_OUT_OF_RANGE",
1786
1772
  function(s, i, r) {
1787
1773
  let h = `The value of "${s}" is out of range.`, f = r;
1788
- return Number.isInteger(r) && Math.abs(r) > 2 ** 32 ? f = Gt(String(r)) : typeof r == "bigint" && (f = String(r), (r > BigInt(2) ** BigInt(32) || r < -(BigInt(2) ** BigInt(32))) && (f = Gt(f)), f += "n"), h += ` It must be ${i}. Received ${f}`, h;
1774
+ return Number.isInteger(r) && Math.abs(r) > 2 ** 32 ? f = Vt(String(r)) : typeof r == "bigint" && (f = String(r), (r > BigInt(2) ** BigInt(32) || r < -(BigInt(2) ** BigInt(32))) && (f = Vt(f)), f += "n"), h += ` It must be ${i}. Received ${f}`, h;
1789
1775
  },
1790
1776
  RangeError
1791
1777
  );
1792
- function Gt(s) {
1778
+ function Vt(s) {
1793
1779
  let i = "", r = s.length;
1794
1780
  const h = s[0] === "-" ? 1 : 0;
1795
1781
  for (; r >= h + 4; r -= 3)
@@ -1797,22 +1783,22 @@ function Mn() {
1797
1783
  return `${s.slice(0, r)}${i}`;
1798
1784
  }
1799
1785
  function en(s, i, r) {
1800
- Se(i, "offset"), (s[i] === void 0 || s[i + r] === void 0) && Re(i, s.length - (r + 1));
1786
+ ye(i, "offset"), (s[i] === void 0 || s[i + r] === void 0) && Re(i, s.length - (r + 1));
1801
1787
  }
1802
- function Vt(s, i, r, h, f, E) {
1788
+ function Gt(s, i, r, h, f, E) {
1803
1789
  if (s > r || s < i) {
1804
1790
  const v = typeof i == "bigint" ? "n" : "";
1805
1791
  let R;
1806
- throw i === 0 || i === BigInt(0) ? R = `>= 0${v} and < 2${v} ** ${(E + 1) * 8}${v}` : R = `>= -(2${v} ** ${(E + 1) * 8 - 1}${v}) and < 2 ** ${(E + 1) * 8 - 1}${v}`, new ye.ERR_OUT_OF_RANGE("value", R, s);
1792
+ throw i === 0 || i === BigInt(0) ? R = `>= 0${v} and < 2${v} ** ${(E + 1) * 8}${v}` : R = `>= -(2${v} ** ${(E + 1) * 8 - 1}${v}) and < 2 ** ${(E + 1) * 8 - 1}${v}`, new ve.ERR_OUT_OF_RANGE("value", R, s);
1807
1793
  }
1808
1794
  en(h, f, E);
1809
1795
  }
1810
- function Se(s, i) {
1796
+ function ye(s, i) {
1811
1797
  if (typeof s != "number")
1812
- throw new ye.ERR_INVALID_ARG_TYPE(i, "number", s);
1798
+ throw new ve.ERR_INVALID_ARG_TYPE(i, "number", s);
1813
1799
  }
1814
1800
  function Re(s, i, r) {
1815
- throw Math.floor(s) !== s ? (Se(s, r), new ye.ERR_OUT_OF_RANGE("offset", "an integer", s)) : i < 0 ? new ye.ERR_BUFFER_OUT_OF_BOUNDS() : new ye.ERR_OUT_OF_RANGE(
1801
+ throw Math.floor(s) !== s ? (ye(s, r), new ve.ERR_OUT_OF_RANGE("offset", "an integer", s)) : i < 0 ? new ve.ERR_BUFFER_OUT_OF_BOUNDS() : new ve.ERR_OUT_OF_RANGE(
1816
1802
  "offset",
1817
1803
  `>= 0 and <= ${i}`,
1818
1804
  s
@@ -1895,7 +1881,7 @@ function Mn() {
1895
1881
  function jt(s) {
1896
1882
  return e.toByteArray(nn(s));
1897
1883
  }
1898
- function Ge(s, i, r, h) {
1884
+ function Ve(s, i, r, h) {
1899
1885
  let f;
1900
1886
  for (f = 0; f < h && !(f + r >= i.length || f >= s.length); ++f)
1901
1887
  i[f + r] = s[f];
@@ -1916,7 +1902,7 @@ function Mn() {
1916
1902
  }
1917
1903
  return i;
1918
1904
  })();
1919
- function ce(s) {
1905
+ function le(s) {
1920
1906
  return typeof BigInt > "u" ? an : s;
1921
1907
  }
1922
1908
  function an() {
@@ -1925,69 +1911,69 @@ function Mn() {
1925
1911
  })(ft)), ft;
1926
1912
  }
1927
1913
  var Un = Mn();
1928
- const Bn = "https://api.anam.ai", Ln = "/v1", Hi = {
1914
+ const Ln = "https://api.anam.ai", Bn = "/v1", Hi = {
1929
1915
  client: "js-sdk",
1930
1916
  version: "4.8.0"
1931
1917
  };
1932
1918
  var Pn = function(t, e, n, o) {
1933
- function u(a) {
1934
- return a instanceof n ? a : new n(function(c) {
1935
- c(a);
1919
+ function c(a) {
1920
+ return a instanceof n ? a : new n(function(u) {
1921
+ u(a);
1936
1922
  });
1937
1923
  }
1938
- return new (n || (n = Promise))(function(a, c) {
1924
+ return new (n || (n = Promise))(function(a, u) {
1939
1925
  function l(_) {
1940
1926
  try {
1941
1927
  p(o.next(_));
1942
1928
  } catch (d) {
1943
- c(d);
1929
+ u(d);
1944
1930
  }
1945
1931
  }
1946
1932
  function m(_) {
1947
1933
  try {
1948
1934
  p(o.throw(_));
1949
1935
  } catch (d) {
1950
- c(d);
1936
+ u(d);
1951
1937
  }
1952
1938
  }
1953
1939
  function p(_) {
1954
- _.done ? a(_.value) : u(_.value).then(l, m);
1940
+ _.done ? a(_.value) : c(_.value).then(l, m);
1955
1941
  }
1956
1942
  p((o = o.apply(t, e || [])).next());
1957
1943
  });
1958
1944
  };
1959
1945
  const Wi = "https://api.anam.ai", xt = "/v1";
1960
- var se;
1946
+ var oe;
1961
1947
  (function(t) {
1962
1948
  t.CLIENT_METRIC_MEASUREMENT_ERROR = "client_error", t.CLIENT_METRIC_MEASUREMENT_CONNECTION_CLOSED = "client_connection_closed", t.CLIENT_METRIC_MEASUREMENT_CONNECTION_ESTABLISHED = "client_connection_established", t.CLIENT_METRIC_MEASUREMENT_SESSION_ATTEMPT = "client_session_attempt", t.CLIENT_METRIC_MEASUREMENT_SESSION_SUCCESS = "client_session_success";
1963
- })(se || (se = {}));
1964
- let St = Wi, zi = xt, de, qi = !1;
1949
+ })(oe || (oe = {}));
1950
+ let St = Wi, zi = xt, ue, qi = !1;
1965
1951
  const Fn = (t, e = xt) => {
1966
1952
  St = t, zi = e;
1967
1953
  }, $n = (t) => {
1968
- de = t;
1969
- }, Gn = (t) => {
1954
+ ue = t;
1955
+ }, Vn = (t) => {
1970
1956
  qi = t;
1971
1957
  };
1972
- let he = {
1958
+ let de = {
1973
1959
  sessionId: null,
1974
1960
  organizationId: null,
1975
1961
  attemptCorrelationId: null
1976
1962
  };
1977
- const we = (t) => {
1978
- he = Object.assign(Object.assign({}, he), t);
1979
- }, ge = (t, e, n) => Pn(void 0, void 0, void 0, function* () {
1963
+ const Se = (t) => {
1964
+ de = Object.assign(Object.assign({}, de), t);
1965
+ }, me = (t, e, n) => Pn(void 0, void 0, void 0, function* () {
1980
1966
  if (!qi)
1981
1967
  try {
1982
1968
  const o = Object.assign(Object.assign({}, Hi), n);
1983
- he.sessionId && (o.sessionId = he.sessionId), he.organizationId && (o.organizationId = he.organizationId), he.attemptCorrelationId && (o.attemptCorrelationId = he.attemptCorrelationId);
1984
- const u = `${zi}/metrics/client`;
1985
- let a, c = {
1969
+ de.sessionId && (o.sessionId = de.sessionId), de.organizationId && (o.organizationId = de.organizationId), de.attemptCorrelationId && (o.attemptCorrelationId = de.attemptCorrelationId);
1970
+ const c = `${zi}/metrics/client`;
1971
+ let a, u = {
1986
1972
  "Content-Type": "application/json"
1987
1973
  };
1988
- de?.enabled && de?.baseUrl ? (a = `${de.baseUrl}${u}`, c["X-Anam-Target-Url"] = `${St}${u}`) : a = `${St}${u}`, yield fetch(a, {
1974
+ ue?.enabled && ue?.baseUrl ? (a = `${ue.baseUrl}${c}`, u["X-Anam-Target-Url"] = `${St}${c}`) : a = `${St}${c}`, yield fetch(a, {
1989
1975
  method: "POST",
1990
- headers: c,
1976
+ headers: u,
1991
1977
  body: JSON.stringify({
1992
1978
  name: t,
1993
1979
  value: e,
@@ -1997,94 +1983,94 @@ const we = (t) => {
1997
1983
  } catch (o) {
1998
1984
  console.error("Failed to send error metric:", o);
1999
1985
  }
2000
- }), Vn = (t, e = "console") => {
2001
- var n, o, u;
1986
+ }), Gn = (t, e = "console") => {
1987
+ var n, o, c;
2002
1988
  const a = {};
2003
1989
  t.forEach((d) => {
2004
1990
  a[d.type] || (a[d.type] = []), a[d.type].push(d);
2005
1991
  });
2006
- const c = {
1992
+ const u = {
2007
1993
  issues: []
2008
1994
  }, l = ((n = a["inbound-rtp"]) === null || n === void 0 ? void 0 : n.filter((d) => d.kind === "video")) || [];
2009
- l.length > 0 && (c.personaVideoStream = [], l.forEach((d) => {
2010
- var S, g, y, b, A;
2011
- const C = {
2012
- framesReceived: (S = d.framesReceived) !== null && S !== void 0 ? S : "unknown",
1995
+ l.length > 0 && (u.personaVideoStream = [], l.forEach((d) => {
1996
+ var y, g, S, C, A;
1997
+ const I = {
1998
+ framesReceived: (y = d.framesReceived) !== null && y !== void 0 ? y : "unknown",
2013
1999
  framesDropped: (g = d.framesDropped) !== null && g !== void 0 ? g : "unknown",
2014
- framesPerSecond: (y = d.framesPerSecond) !== null && y !== void 0 ? y : "unknown",
2015
- packetsReceived: (b = d.packetsReceived) !== null && b !== void 0 ? b : "unknown",
2000
+ framesPerSecond: (S = d.framesPerSecond) !== null && S !== void 0 ? S : "unknown",
2001
+ packetsReceived: (C = d.packetsReceived) !== null && C !== void 0 ? C : "unknown",
2016
2002
  packetsLost: (A = d.packetsLost) !== null && A !== void 0 ? A : "unknown",
2017
2003
  resolution: d.frameWidth && d.frameHeight ? `${d.frameWidth}x${d.frameHeight}` : void 0,
2018
2004
  jitter: d.jitter !== void 0 ? d.jitter : void 0
2019
2005
  };
2020
- c.personaVideoStream.push(C);
2006
+ u.personaVideoStream.push(I);
2021
2007
  }));
2022
2008
  const m = ((o = a["inbound-rtp"]) === null || o === void 0 ? void 0 : o.filter((d) => d.kind === "audio")) || [];
2023
- m.length > 0 && (c.personaAudioStream = [], m.forEach((d) => {
2024
- var S, g, y;
2025
- const b = {
2026
- packetsReceived: (S = d.packetsReceived) !== null && S !== void 0 ? S : "unknown",
2009
+ m.length > 0 && (u.personaAudioStream = [], m.forEach((d) => {
2010
+ var y, g, S;
2011
+ const C = {
2012
+ packetsReceived: (y = d.packetsReceived) !== null && y !== void 0 ? y : "unknown",
2027
2013
  packetsLost: (g = d.packetsLost) !== null && g !== void 0 ? g : "unknown",
2028
- audioLevel: (y = d.audioLevel) !== null && y !== void 0 ? y : "unknown",
2014
+ audioLevel: (S = d.audioLevel) !== null && S !== void 0 ? S : "unknown",
2029
2015
  jitter: d.jitter !== void 0 ? d.jitter : void 0,
2030
2016
  totalAudioEnergy: d.totalAudioEnergy !== void 0 ? d.totalAudioEnergy : void 0
2031
2017
  };
2032
- c.personaAudioStream.push(b);
2018
+ u.personaAudioStream.push(C);
2033
2019
  }));
2034
- const p = ((u = a["outbound-rtp"]) === null || u === void 0 ? void 0 : u.filter((d) => d.kind === "audio")) || [];
2035
- p.length > 0 && (c.userAudioInput = [], p.forEach((d) => {
2036
- var S, g;
2037
- const y = {
2038
- packetsSent: (S = d.packetsSent) !== null && S !== void 0 ? S : "unknown",
2020
+ const p = ((c = a["outbound-rtp"]) === null || c === void 0 ? void 0 : c.filter((d) => d.kind === "audio")) || [];
2021
+ p.length > 0 && (u.userAudioInput = [], p.forEach((d) => {
2022
+ var y, g;
2023
+ const S = {
2024
+ packetsSent: (y = d.packetsSent) !== null && y !== void 0 ? y : "unknown",
2039
2025
  retransmittedPackets: (g = d.retransmittedPacketsSent) !== null && g !== void 0 ? g : void 0,
2040
2026
  avgPacketSendDelay: d.totalPacketSendDelay !== void 0 ? d.totalPacketSendDelay / (d.packetsSent || 1) * 1e3 : void 0
2041
2027
  };
2042
- c.userAudioInput.push(y);
2043
- })), a.codec && (c.codecs = [], a.codec.forEach((d) => {
2044
- const S = {
2028
+ u.userAudioInput.push(S);
2029
+ })), a.codec && (u.codecs = [], a.codec.forEach((d) => {
2030
+ const y = {
2045
2031
  status: d.payloadType ? "Active" : "Available",
2046
2032
  mimeType: d.mimeType || "Unknown",
2047
2033
  payloadType: d.payloadType || "N/A",
2048
2034
  clockRate: d.clockRate || void 0,
2049
2035
  channels: d.channels || void 0
2050
2036
  };
2051
- c.codecs.push(S);
2052
- })), a.transport && (c.transportLayer = [], a.transport.forEach((d) => {
2053
- const S = {
2037
+ u.codecs.push(y);
2038
+ })), a.transport && (u.transportLayer = [], a.transport.forEach((d) => {
2039
+ const y = {
2054
2040
  dtlsState: d.dtlsState || "unknown",
2055
2041
  iceState: d.iceState || "unknown",
2056
2042
  bytesSent: d.bytesSent || void 0,
2057
2043
  bytesReceived: d.bytesReceived || void 0
2058
2044
  };
2059
- c.transportLayer.push(S);
2045
+ u.transportLayer.push(y);
2060
2046
  }));
2061
2047
  const _ = [];
2062
2048
  if (l.forEach((d) => {
2063
2049
  typeof d.framesDropped == "number" && d.framesDropped > 0 && _.push(`Video: ${d.framesDropped} frames dropped`), typeof d.packetsLost == "number" && d.packetsLost > 0 && _.push(`Video: ${d.packetsLost} packets lost`), typeof d.framesPerSecond == "number" && d.framesPerSecond < 23 && _.push(`Video: Low frame rate (${d.framesPerSecond} fps)`);
2064
2050
  }), m.forEach((d) => {
2065
2051
  typeof d.packetsLost == "number" && d.packetsLost > 0 && _.push(`Audio: ${d.packetsLost} packets lost`), typeof d.jitter == "number" && d.jitter > 0.1 && _.push(`Audio: High jitter (${(d.jitter * 1e3).toFixed(1)}ms)`);
2066
- }), c.issues = _, e === "json")
2067
- return c;
2068
- console.group("📊 WebRTC Session Statistics Report"), c.personaVideoStream && c.personaVideoStream.length > 0 && (console.group("📹 Persona Video Stream (Inbound)"), c.personaVideoStream.forEach((d) => {
2052
+ }), u.issues = _, e === "json")
2053
+ return u;
2054
+ console.group("📊 WebRTC Session Statistics Report"), u.personaVideoStream && u.personaVideoStream.length > 0 && (console.group("📹 Persona Video Stream (Inbound)"), u.personaVideoStream.forEach((d) => {
2069
2055
  console.log(`Frames Received: ${d.framesReceived}`), console.log(`Frames Dropped: ${d.framesDropped}`), console.log(`Frames Per Second: ${d.framesPerSecond}`), console.log(`Packets Received: ${typeof d.packetsReceived == "number" ? d.packetsReceived.toLocaleString() : d.packetsReceived}`), console.log(`Packets Lost: ${d.packetsLost}`), d.resolution && console.log(`Resolution: ${d.resolution}`), d.jitter !== void 0 && console.log(`Jitter: ${d.jitter.toFixed(5)}ms`);
2070
- }), console.groupEnd()), c.personaAudioStream && c.personaAudioStream.length > 0 && (console.group("🔊 Persona Audio Stream (Inbound)"), c.personaAudioStream.forEach((d) => {
2056
+ }), console.groupEnd()), u.personaAudioStream && u.personaAudioStream.length > 0 && (console.group("🔊 Persona Audio Stream (Inbound)"), u.personaAudioStream.forEach((d) => {
2071
2057
  console.log(`Packets Received: ${typeof d.packetsReceived == "number" ? d.packetsReceived.toLocaleString() : d.packetsReceived}`), console.log(`Packets Lost: ${d.packetsLost}`), console.log(`Audio Level: ${d.audioLevel}`), d.jitter !== void 0 && console.log(`Jitter: ${d.jitter.toFixed(5)}ms`), d.totalAudioEnergy !== void 0 && console.log(`Total Audio Energy: ${d.totalAudioEnergy.toFixed(6)}`);
2072
- }), console.groupEnd()), c.userAudioInput && c.userAudioInput.length > 0 && (console.group("🎤 User Audio Input (Outbound)"), c.userAudioInput.forEach((d) => {
2058
+ }), console.groupEnd()), u.userAudioInput && u.userAudioInput.length > 0 && (console.group("🎤 User Audio Input (Outbound)"), u.userAudioInput.forEach((d) => {
2073
2059
  console.log(`Packets Sent: ${typeof d.packetsSent == "number" ? d.packetsSent.toLocaleString() : d.packetsSent}`), d.retransmittedPackets && console.log(`Retransmitted Packets: ${d.retransmittedPackets}`), d.avgPacketSendDelay !== void 0 && console.log(`Avg Packet Send Delay: ${d.avgPacketSendDelay.toFixed(5)}ms`);
2074
- }), console.groupEnd()), c.codecs && c.codecs.length > 0 && (console.group("🔧 Codecs Used"), c.codecs.forEach((d) => {
2060
+ }), console.groupEnd()), u.codecs && u.codecs.length > 0 && (console.group("🔧 Codecs Used"), u.codecs.forEach((d) => {
2075
2061
  console.log(`${d.status} ${d.mimeType} - Payload Type: ${d.payloadType}`), d.clockRate && console.log(` Clock Rate: ${d.clockRate}Hz`), d.channels && console.log(` Channels: ${d.channels}`);
2076
- }), console.groupEnd()), c.transportLayer && c.transportLayer.length > 0 && (console.group("🚚 Transport Layer"), c.transportLayer.forEach((d) => {
2062
+ }), console.groupEnd()), u.transportLayer && u.transportLayer.length > 0 && (console.group("🚚 Transport Layer"), u.transportLayer.forEach((d) => {
2077
2063
  console.log(`DTLS State: ${d.dtlsState}`), console.log(`ICE State: ${d.iceState}`), (d.bytesReceived || d.bytesSent) && console.log(`Data Transfer (bytes) - Sent: ${(d.bytesSent || 0).toLocaleString()}, Received: ${(d.bytesReceived || 0).toLocaleString()}`);
2078
- }), console.groupEnd()), c.issues.length > 0 ? (console.group("⚠️ Potential Issues Detected"), c.issues.forEach((d) => console.warn(d)), console.groupEnd()) : console.log("✅ No significant issues detected"), console.groupEnd();
2064
+ }), console.groupEnd()), u.issues.length > 0 ? (console.group("⚠️ Potential Issues Detected"), u.issues.forEach((d) => console.warn(d)), console.groupEnd()) : console.log("✅ No significant issues detected"), console.groupEnd();
2079
2065
  };
2080
- var V;
2066
+ var G;
2081
2067
  (function(t) {
2082
2068
  t.CLIENT_ERROR_CODE_USAGE_LIMIT_REACHED = "CLIENT_ERROR_CODE_USAGE_LIMIT_REACHED", t.CLIENT_ERROR_CODE_SPEND_CAP_REACHED = "CLIENT_ERROR_CODE_SPEND_CAP_REACHED", t.CLIENT_ERROR_CODE_VALIDATION_ERROR = "CLIENT_ERROR_CODE_VALIDATION_ERROR", t.CLIENT_ERROR_CODE_AUTHENTICATION_ERROR = "CLIENT_ERROR_CODE_AUTHENTICATION_ERROR", t.CLIENT_ERROR_CODE_SERVER_ERROR = "CLIENT_ERROR_CODE_SERVER_ERROR", t.CLIENT_ERROR_CODE_MAX_CONCURRENT_SESSIONS_REACHED = "CLIENT_ERROR_CODE_MAX_CONCURRENT_SESSIONS_REACHED", t.CLIENT_ERROR_CODE_SERVICE_BUSY = "CLIENT_ERROR_CODE_SERVICE_BUSY", t.CLIENT_ERROR_CODE_NO_PLAN_FOUND = "CLIENT_ERROR_CODE_NO_PLAN_FOUND", t.CLIENT_ERROR_CODE_UNKNOWN_ERROR = "CLIENT_ERROR_CODE_UNKNOWN_ERROR", t.CLIENT_ERROR_CODE_CONFIGURATION_ERROR = "CLIENT_ERROR_CODE_CONFIGURATION_ERROR";
2083
- })(V || (V = {}));
2069
+ })(G || (G = {}));
2084
2070
  class $ extends Error {
2085
- constructor(e, n, o = 500, u) {
2086
- super(e), this.name = "ClientError", this.code = n, this.statusCode = o, this.details = u, Object.setPrototypeOf(this, $.prototype), ge(se.CLIENT_METRIC_MEASUREMENT_ERROR, n, {
2087
- details: u,
2071
+ constructor(e, n, o = 500, c) {
2072
+ super(e), this.name = "ClientError", this.code = n, this.statusCode = o, this.details = c, Object.setPrototypeOf(this, $.prototype), me(oe.CLIENT_METRIC_MEASUREMENT_ERROR, n, {
2073
+ details: c,
2088
2074
  statusCode: o
2089
2075
  });
2090
2076
  }
@@ -2115,10 +2101,10 @@ var De;
2115
2101
  (function(t) {
2116
2102
  t.SPEECH_TEXT = "speechText", t.CLIENT_TOOL_EVENT = "clientToolEvent", t.REASONING_TEXT = "reasoningText";
2117
2103
  })(De || (De = {}));
2118
- var fe;
2104
+ var he;
2119
2105
  (function(t) {
2120
2106
  t.PENDING = "pending", t.GRANTED = "granted", t.DENIED = "denied", t.NOT_REQUESTED = "not_requested";
2121
- })(fe || (fe = {}));
2107
+ })(he || (he = {}));
2122
2108
  var tt;
2123
2109
  (function(t) {
2124
2110
  t.USER = "user", t.PERSONA = "persona";
@@ -2127,14 +2113,14 @@ var N;
2127
2113
  (function(t) {
2128
2114
  t.MESSAGE_HISTORY_UPDATED = "MESSAGE_HISTORY_UPDATED", t.MESSAGE_STREAM_EVENT_RECEIVED = "MESSAGE_STREAM_EVENT_RECEIVED", t.CONNECTION_ESTABLISHED = "CONNECTION_ESTABLISHED", t.CONNECTION_CLOSED = "CONNECTION_CLOSED", t.INPUT_AUDIO_STREAM_STARTED = "INPUT_AUDIO_STREAM_STARTED", t.VIDEO_STREAM_STARTED = "VIDEO_STREAM_STARTED", t.VIDEO_PLAY_STARTED = "VIDEO_PLAY_STARTED", t.AUDIO_STREAM_STARTED = "AUDIO_STREAM_STARTED", t.TALK_STREAM_INTERRUPTED = "TALK_STREAM_INTERRUPTED", t.SESSION_READY = "SESSION_READY", t.SERVER_WARNING = "SERVER_WARNING", t.MIC_PERMISSION_PENDING = "MIC_PERMISSION_PENDING", t.MIC_PERMISSION_GRANTED = "MIC_PERMISSION_GRANTED", t.MIC_PERMISSION_DENIED = "MIC_PERMISSION_DENIED", t.INPUT_AUDIO_DEVICE_CHANGED = "INPUT_AUDIO_DEVICE_CHANGED", t.CLIENT_TOOL_EVENT_RECEIVED = "CLIENT_TOOL_EVENT_RECEIVED", t.REASONING_HISTORY_UPDATED = "REASONING_HISTORY_UPDATED", t.REASONING_STREAM_EVENT_RECEIVED = "REASONING_STREAM_EVENT_RECEIVED";
2129
2115
  })(N || (N = {}));
2130
- var X;
2116
+ var J;
2131
2117
  (function(t) {
2132
2118
  t.WEB_SOCKET_OPEN = "WEB_SOCKET_OPEN", t.SIGNAL_MESSAGE_RECEIVED = "SIGNAL_MESSAGE_RECEIVED", t.WEBRTC_CHAT_MESSAGE_RECEIVED = "WEBRTC_CHAT_MESSAGE_RECEIVED", t.WEBRTC_CLIENT_TOOL_EVENT_RECEIVED = "WEBRTC_CLIENT_TOOL_EVENT_RECEIVED", t.WEBRTC_REASONING_TEXT_MESSAGE_RECEIVED = "WEBRTC_REASONING_TEXT_MESSAGE_RECEIVED";
2133
- })(X || (X = {}));
2134
- var _e;
2119
+ })(J || (J = {}));
2120
+ var pe;
2135
2121
  (function(t) {
2136
2122
  t.NORMAL = "CONNECTION_CLOSED_CODE_NORMAL", t.MICROPHONE_PERMISSION_DENIED = "CONNECTION_CLOSED_CODE_MICROPHONE_PERMISSION_DENIED", t.SIGNALLING_CLIENT_CONNECTION_FAILURE = "CONNECTION_CLOSED_CODE_SIGNALLING_CLIENT_CONNECTION_FAILURE", t.WEBRTC_FAILURE = "CONNECTION_CLOSED_CODE_WEBRTC_FAILURE", t.SERVER_CLOSED_CONNECTION = "CONNECTION_CLOSED_CODE_SERVER_CLOSED_CONNECTION";
2137
- })(_e || (_e = {}));
2123
+ })(pe || (pe = {}));
2138
2124
  class Hn {
2139
2125
  constructor(e, n) {
2140
2126
  this.sequenceNumber = 0, this.config = e, this.signallingClient = n;
@@ -2173,55 +2159,55 @@ class Hn {
2173
2159
  return this.config;
2174
2160
  }
2175
2161
  arrayBufferToBase64(e) {
2176
- const n = e instanceof Uint8Array ? e : new Uint8Array(e), o = Array.from(n, (u) => String.fromCharCode(u)).join("");
2162
+ const n = e instanceof Uint8Array ? e : new Uint8Array(e), o = Array.from(n, (c) => String.fromCharCode(c)).join("");
2177
2163
  return btoa(o);
2178
2164
  }
2179
2165
  }
2180
- var Ce = function(t, e, n, o) {
2181
- function u(a) {
2182
- return a instanceof n ? a : new n(function(c) {
2183
- c(a);
2166
+ var we = function(t, e, n, o) {
2167
+ function c(a) {
2168
+ return a instanceof n ? a : new n(function(u) {
2169
+ u(a);
2184
2170
  });
2185
2171
  }
2186
- return new (n || (n = Promise))(function(a, c) {
2172
+ return new (n || (n = Promise))(function(a, u) {
2187
2173
  function l(_) {
2188
2174
  try {
2189
2175
  p(o.next(_));
2190
2176
  } catch (d) {
2191
- c(d);
2177
+ u(d);
2192
2178
  }
2193
2179
  }
2194
2180
  function m(_) {
2195
2181
  try {
2196
2182
  p(o.throw(_));
2197
2183
  } catch (d) {
2198
- c(d);
2184
+ u(d);
2199
2185
  }
2200
2186
  }
2201
2187
  function p(_) {
2202
- _.done ? a(_.value) : u(_.value).then(l, m);
2188
+ _.done ? a(_.value) : c(_.value).then(l, m);
2203
2189
  }
2204
2190
  p((o = o.apply(t, e || [])).next());
2205
2191
  });
2206
2192
  };
2207
2193
  const Wn = 5, zn = 5;
2208
2194
  class qn {
2209
- constructor(e, n, o, u, a) {
2210
- var c, l, m, p, _;
2211
- if (this.stopSignal = !1, this.sendingBuffer = [], this.wsConnectionAttempts = 0, this.socket = null, this.heartBeatIntervalRef = null, this.publicEventEmitter = o, this.internalEventEmitter = u, this.apiGatewayConfig = a, !e)
2195
+ constructor(e, n, o, c, a) {
2196
+ var u, l, m, p, _;
2197
+ if (this.stopSignal = !1, this.sendingBuffer = [], this.wsConnectionAttempts = 0, this.socket = null, this.heartBeatIntervalRef = null, this.publicEventEmitter = o, this.internalEventEmitter = c, this.apiGatewayConfig = a, !e)
2212
2198
  throw new Error("Signalling Client: sessionId is required");
2213
2199
  this.sessionId = e;
2214
- const { heartbeatIntervalSeconds: d, maxWsReconnectionAttempts: S, url: g } = n;
2215
- if (this.heartbeatIntervalSeconds = d || Wn, this.maxWsReconnectionAttempts = S || zn, !g.baseUrl)
2200
+ const { heartbeatIntervalSeconds: d, maxWsReconnectionAttempts: y, url: g } = n;
2201
+ if (this.heartbeatIntervalSeconds = d || Wn, this.maxWsReconnectionAttempts = y || zn, !g.baseUrl)
2216
2202
  throw new Error("Signalling Client: baseUrl is required");
2217
- if (!((c = this.apiGatewayConfig) === null || c === void 0) && c.enabled && (!((l = this.apiGatewayConfig) === null || l === void 0) && l.baseUrl)) {
2218
- const y = new URL(this.apiGatewayConfig.baseUrl), b = (m = this.apiGatewayConfig.wsPath) !== null && m !== void 0 ? m : "/ws";
2219
- y.protocol = y.protocol.replace("http", "ws"), y.pathname = b, this.url = y;
2220
- const A = g.protocol || "https", C = A === "http" ? "ws" : "wss", I = `${A}://${g.baseUrl}`, x = (p = g.signallingPath) !== null && p !== void 0 ? p : "/ws", O = new URL(I);
2221
- O.protocol = C === "ws" ? "ws:" : "wss:", g.port && (O.port = g.port), O.pathname = x, O.searchParams.append("session_id", e), this.url.searchParams.append("target_url", O.href);
2203
+ if (!((u = this.apiGatewayConfig) === null || u === void 0) && u.enabled && (!((l = this.apiGatewayConfig) === null || l === void 0) && l.baseUrl)) {
2204
+ const S = new URL(this.apiGatewayConfig.baseUrl), C = (m = this.apiGatewayConfig.wsPath) !== null && m !== void 0 ? m : "/ws";
2205
+ S.protocol = S.protocol.replace("http", "ws"), S.pathname = C, this.url = S;
2206
+ const A = g.protocol || "https", I = A === "http" ? "ws" : "wss", b = `${A}://${g.baseUrl}`, T = (p = g.signallingPath) !== null && p !== void 0 ? p : "/ws", D = new URL(b);
2207
+ D.protocol = I === "ws" ? "ws:" : "wss:", g.port && (D.port = g.port), D.pathname = T, D.searchParams.append("session_id", e), this.url.searchParams.append("target_url", D.href);
2222
2208
  } else {
2223
- const b = `${g.protocol || "https"}://${g.baseUrl}`;
2224
- this.url = new URL(b), this.url.protocol = g.protocol === "http" ? "ws:" : "wss:", g.port && (this.url.port = g.port), this.url.pathname = (_ = g.signallingPath) !== null && _ !== void 0 ? _ : "/ws", this.url.searchParams.append("session_id", e);
2209
+ const C = `${g.protocol || "https"}://${g.baseUrl}`;
2210
+ this.url = new URL(C), this.url.protocol = g.protocol === "http" ? "ws:" : "wss:", g.port && (this.url.port = g.port), this.url.pathname = (_ = g.signallingPath) !== null && _ !== void 0 ? _ : "/ws", this.url.searchParams.append("session_id", e);
2225
2211
  }
2226
2212
  }
2227
2213
  stop() {
@@ -2231,7 +2217,7 @@ class qn {
2231
2217
  return this.socket = new WebSocket(this.url.href), this.socket.onopen = this.onOpen.bind(this), this.socket.onclose = this.onClose.bind(this), this.socket.onerror = this.onError.bind(this), this.socket;
2232
2218
  }
2233
2219
  sendOffer(e) {
2234
- return Ce(this, void 0, void 0, function* () {
2220
+ return we(this, void 0, void 0, function* () {
2235
2221
  const n = {
2236
2222
  connectionDescription: e,
2237
2223
  userUid: this.sessionId
@@ -2245,7 +2231,7 @@ class qn {
2245
2231
  });
2246
2232
  }
2247
2233
  sendIceCandidate(e) {
2248
- return Ce(this, void 0, void 0, function* () {
2234
+ return we(this, void 0, void 0, function* () {
2249
2235
  const n = {
2250
2236
  actionType: W.ICE_CANDIDATE,
2251
2237
  sessionId: this.sessionId,
@@ -2266,7 +2252,7 @@ class qn {
2266
2252
  this.sendingBuffer.push(e);
2267
2253
  }
2268
2254
  sendTalkMessage(e) {
2269
- return Ce(this, void 0, void 0, function* () {
2255
+ return we(this, void 0, void 0, function* () {
2270
2256
  const n = {
2271
2257
  actionType: W.TALK_STREAM_INPUT,
2272
2258
  sessionId: this.sessionId,
@@ -2295,21 +2281,21 @@ class qn {
2295
2281
  this.socket && (this.socket.close(), this.socket = null), this.heartBeatIntervalRef && (clearInterval(this.heartBeatIntervalRef), this.heartBeatIntervalRef = null);
2296
2282
  }
2297
2283
  onOpen() {
2298
- return Ce(this, void 0, void 0, function* () {
2284
+ return we(this, void 0, void 0, function* () {
2299
2285
  if (!this.socket)
2300
2286
  throw new Error("SignallingClient - onOpen: socket is null");
2301
2287
  try {
2302
- this.wsConnectionAttempts = 0, this.flushSendingBuffer(), this.socket.onmessage = this.onMessage.bind(this), this.startSendingHeartBeats(), this.internalEventEmitter.emit(X.WEB_SOCKET_OPEN);
2288
+ this.wsConnectionAttempts = 0, this.flushSendingBuffer(), this.socket.onmessage = this.onMessage.bind(this), this.startSendingHeartBeats(), this.internalEventEmitter.emit(J.WEB_SOCKET_OPEN);
2303
2289
  } catch (e) {
2304
- console.error("SignallingClient - onOpen: error in onOpen", e), this.publicEventEmitter.emit(N.CONNECTION_CLOSED, _e.SIGNALLING_CLIENT_CONNECTION_FAILURE);
2290
+ console.error("SignallingClient - onOpen: error in onOpen", e), this.publicEventEmitter.emit(N.CONNECTION_CLOSED, pe.SIGNALLING_CLIENT_CONNECTION_FAILURE);
2305
2291
  }
2306
2292
  });
2307
2293
  }
2308
2294
  onClose() {
2309
- return Ce(this, void 0, void 0, function* () {
2295
+ return we(this, void 0, void 0, function* () {
2310
2296
  this.wsConnectionAttempts += 1, !this.stopSignal && (this.wsConnectionAttempts <= this.maxWsReconnectionAttempts ? (this.socket = null, setTimeout(() => {
2311
2297
  this.connect();
2312
- }, 100 * this.wsConnectionAttempts)) : (this.heartBeatIntervalRef && (clearInterval(this.heartBeatIntervalRef), this.heartBeatIntervalRef = null), this.publicEventEmitter.emit(N.CONNECTION_CLOSED, _e.SIGNALLING_CLIENT_CONNECTION_FAILURE)));
2298
+ }, 100 * this.wsConnectionAttempts)) : (this.heartBeatIntervalRef && (clearInterval(this.heartBeatIntervalRef), this.heartBeatIntervalRef = null), this.publicEventEmitter.emit(N.CONNECTION_CLOSED, pe.SIGNALLING_CLIENT_CONNECTION_FAILURE)));
2313
2299
  });
2314
2300
  }
2315
2301
  onError(e) {
@@ -2323,9 +2309,9 @@ class qn {
2323
2309
  }), this.sendingBuffer = e;
2324
2310
  }
2325
2311
  onMessage(e) {
2326
- return Ce(this, void 0, void 0, function* () {
2312
+ return we(this, void 0, void 0, function* () {
2327
2313
  const n = JSON.parse(e.data);
2328
- this.internalEventEmitter.emit(X.SIGNAL_MESSAGE_RECEIVED, n);
2314
+ this.internalEventEmitter.emit(J.SIGNAL_MESSAGE_RECEIVED, n);
2329
2315
  });
2330
2316
  }
2331
2317
  startSendingHeartBeats() {
@@ -2338,8 +2324,8 @@ class qn {
2338
2324
  payload: ""
2339
2325
  }, o = JSON.stringify(n);
2340
2326
  this.heartBeatIntervalRef = setInterval(() => {
2341
- var u;
2342
- this.stopSignal || ((u = this.socket) === null || u === void 0 ? void 0 : u.readyState) === WebSocket.OPEN && this.socket.send(o);
2327
+ var c;
2328
+ this.stopSignal || ((c = this.socket) === null || c === void 0 ? void 0 : c.readyState) === WebSocket.OPEN && this.socket.send(o);
2343
2329
  }, e);
2344
2330
  }
2345
2331
  }
@@ -2347,28 +2333,28 @@ function Yn(t) {
2347
2333
  return "brainType" in t || "llmId" in t;
2348
2334
  }
2349
2335
  var ci = function(t, e, n, o) {
2350
- function u(a) {
2351
- return a instanceof n ? a : new n(function(c) {
2352
- c(a);
2336
+ function c(a) {
2337
+ return a instanceof n ? a : new n(function(u) {
2338
+ u(a);
2353
2339
  });
2354
2340
  }
2355
- return new (n || (n = Promise))(function(a, c) {
2341
+ return new (n || (n = Promise))(function(a, u) {
2356
2342
  function l(_) {
2357
2343
  try {
2358
2344
  p(o.next(_));
2359
2345
  } catch (d) {
2360
- c(d);
2346
+ u(d);
2361
2347
  }
2362
2348
  }
2363
2349
  function m(_) {
2364
2350
  try {
2365
2351
  p(o.throw(_));
2366
2352
  } catch (d) {
2367
- c(d);
2353
+ u(d);
2368
2354
  }
2369
2355
  }
2370
2356
  function p(_) {
2371
- _.done ? a(_.value) : u(_.value).then(l, m);
2357
+ _.done ? a(_.value) : c(_.value).then(l, m);
2372
2358
  }
2373
2359
  p((o = o.apply(t, e || [])).next());
2374
2360
  });
@@ -2377,15 +2363,15 @@ class Kn {
2377
2363
  constructor(e, n, o) {
2378
2364
  if (!e && !n)
2379
2365
  throw new Error("Either sessionToken or apiKey must be provided");
2380
- this.sessionToken = e || null, this.apiKey = n || null, this.baseUrl = o?.baseUrl || Bn, this.apiVersion = o?.apiVersion || Ln, this.apiGatewayConfig = o?.apiGateway || void 0;
2366
+ this.sessionToken = e || null, this.apiKey = n || null, this.baseUrl = o?.baseUrl || Ln, this.apiVersion = o?.apiVersion || Bn, this.apiGatewayConfig = o?.apiGateway || void 0;
2381
2367
  }
2382
2368
  /**
2383
2369
  * Builds URL and headers for a request, applying API Gateway configuration if enabled
2384
2370
  */
2385
2371
  buildGatewayUrlAndHeaders(e, n) {
2386
- var o, u;
2387
- if (!((o = this.apiGatewayConfig) === null || o === void 0) && o.enabled && (!((u = this.apiGatewayConfig) === null || u === void 0) && u.baseUrl)) {
2388
- const a = `${this.apiGatewayConfig.baseUrl}${e}`, c = new URL(`${this.baseUrl}${e}`), l = Object.assign(Object.assign({}, n), { "X-Anam-Target-Url": c.href });
2372
+ var o, c;
2373
+ if (!((o = this.apiGatewayConfig) === null || o === void 0) && o.enabled && (!((c = this.apiGatewayConfig) === null || c === void 0) && c.baseUrl)) {
2374
+ const a = `${this.apiGatewayConfig.baseUrl}${e}`, u = new URL(`${this.baseUrl}${e}`), l = Object.assign(Object.assign({}, n), { "X-Anam-Target-Url": u.href });
2389
2375
  return { url: a, headers: l };
2390
2376
  } else
2391
2377
  return {
@@ -2397,15 +2383,15 @@ class Kn {
2397
2383
  return ci(this, void 0, void 0, function* () {
2398
2384
  if (!this.sessionToken) {
2399
2385
  if (!e)
2400
- throw new $("Persona configuration must be provided when using apiKey", V.CLIENT_ERROR_CODE_VALIDATION_ERROR, 400);
2386
+ throw new $("Persona configuration must be provided when using apiKey", G.CLIENT_ERROR_CODE_VALIDATION_ERROR, 400);
2401
2387
  this.sessionToken = yield this.unsafe_getSessionToken(e);
2402
2388
  }
2403
2389
  e && "brainType" in e && console.warn("Warning: brainType is deprecated and will be removed in a future version. Please use llmId instead.");
2404
2390
  try {
2405
- const o = `${this.apiVersion}/engine/session`, { url: u, headers: a } = this.buildGatewayUrlAndHeaders(o, {
2391
+ const o = `${this.apiVersion}/engine/session`, { url: c, headers: a } = this.buildGatewayUrlAndHeaders(o, {
2406
2392
  "Content-Type": "application/json",
2407
2393
  Authorization: `Bearer ${this.sessionToken}`
2408
- }), c = yield fetch(u, {
2394
+ }), u = yield fetch(c, {
2409
2395
  method: "POST",
2410
2396
  headers: a,
2411
2397
  body: JSON.stringify({
@@ -2413,28 +2399,28 @@ class Kn {
2413
2399
  sessionOptions: n,
2414
2400
  clientMetadata: Hi
2415
2401
  })
2416
- }), l = yield c.json(), m = l.error;
2417
- switch (c.status) {
2402
+ }), l = yield u.json(), m = l.error;
2403
+ switch (u.status) {
2418
2404
  case 200:
2419
2405
  case 201:
2420
2406
  return l;
2421
2407
  case 400:
2422
- throw new $("Invalid request to start session", V.CLIENT_ERROR_CODE_VALIDATION_ERROR, 400, { cause: l.message });
2408
+ throw new $("Invalid request to start session", G.CLIENT_ERROR_CODE_VALIDATION_ERROR, 400, { cause: l.message });
2423
2409
  case 401:
2424
- throw new $("Authentication failed when starting session", V.CLIENT_ERROR_CODE_AUTHENTICATION_ERROR, 401, { cause: l.message });
2410
+ throw new $("Authentication failed when starting session", G.CLIENT_ERROR_CODE_AUTHENTICATION_ERROR, 401, { cause: l.message });
2425
2411
  case 402:
2426
- throw new $("Please sign up for a plan to start a session", V.CLIENT_ERROR_CODE_NO_PLAN_FOUND, 402, { cause: l.message });
2412
+ throw new $("Please sign up for a plan to start a session", G.CLIENT_ERROR_CODE_NO_PLAN_FOUND, 402, { cause: l.message });
2427
2413
  case 403:
2428
- throw new $("Authentication failed when starting session", V.CLIENT_ERROR_CODE_AUTHENTICATION_ERROR, 403, { cause: l.message });
2414
+ throw new $("Authentication failed when starting session", G.CLIENT_ERROR_CODE_AUTHENTICATION_ERROR, 403, { cause: l.message });
2429
2415
  case 429:
2430
- throw m === "Concurrent session limit reached" ? new $("Concurrency limit reached, please upgrade your plan", V.CLIENT_ERROR_CODE_MAX_CONCURRENT_SESSIONS_REACHED, 429, { cause: l.message }) : m === "Spend cap reached" ? new $("Spend cap reached, please upgrade your plan", V.CLIENT_ERROR_CODE_SPEND_CAP_REACHED, 429, { cause: l.message }) : new $("Usage limit reached, please upgrade your plan", V.CLIENT_ERROR_CODE_USAGE_LIMIT_REACHED, 429, { cause: l.message });
2416
+ throw m === "Concurrent session limit reached" ? new $("Concurrency limit reached, please upgrade your plan", G.CLIENT_ERROR_CODE_MAX_CONCURRENT_SESSIONS_REACHED, 429, { cause: l.message }) : m === "Spend cap reached" ? new $("Spend cap reached, please upgrade your plan", G.CLIENT_ERROR_CODE_SPEND_CAP_REACHED, 429, { cause: l.message }) : new $("Usage limit reached, please upgrade your plan", G.CLIENT_ERROR_CODE_USAGE_LIMIT_REACHED, 429, { cause: l.message });
2431
2417
  case 503:
2432
- throw new $("There are no available personas, please try again later", V.CLIENT_ERROR_CODE_SERVICE_BUSY, 503, { cause: l.message });
2418
+ throw new $("There are no available personas, please try again later", G.CLIENT_ERROR_CODE_SERVICE_BUSY, 503, { cause: l.message });
2433
2419
  default:
2434
- throw new $("Unknown error when starting session", V.CLIENT_ERROR_CODE_SERVER_ERROR, 500, { cause: l.message });
2420
+ throw new $("Unknown error when starting session", G.CLIENT_ERROR_CODE_SERVER_ERROR, 500, { cause: l.message });
2435
2421
  }
2436
2422
  } catch (o) {
2437
- throw o instanceof $ ? o : new $("Failed to start session", V.CLIENT_ERROR_CODE_SERVER_ERROR, 500, { cause: o instanceof Error ? o.message : String(o) });
2423
+ throw o instanceof $ ? o : new $("Failed to start session", G.CLIENT_ERROR_CODE_SERVER_ERROR, 500, { cause: o instanceof Error ? o.message : String(o) });
2438
2424
  }
2439
2425
  });
2440
2426
  }
@@ -2448,11 +2434,11 @@ class Kn {
2448
2434
  };
2449
2435
  Yn(e) && (n = Object.assign(Object.assign({}, n), { personaConfig: e }));
2450
2436
  try {
2451
- const o = `${this.apiVersion}/auth/session-token`, { url: u, headers: a } = this.buildGatewayUrlAndHeaders(o, {
2437
+ const o = `${this.apiVersion}/auth/session-token`, { url: c, headers: a } = this.buildGatewayUrlAndHeaders(o, {
2452
2438
  "Content-Type": "application/json",
2453
2439
  Authorization: `Bearer ${this.apiKey}`
2454
2440
  });
2455
- return (yield (yield fetch(u, {
2441
+ return (yield (yield fetch(c, {
2456
2442
  method: "POST",
2457
2443
  headers: a,
2458
2444
  body: JSON.stringify(n)
@@ -2467,28 +2453,28 @@ class Kn {
2467
2453
  }
2468
2454
  }
2469
2455
  var Jn = function(t, e, n, o) {
2470
- function u(a) {
2471
- return a instanceof n ? a : new n(function(c) {
2472
- c(a);
2456
+ function c(a) {
2457
+ return a instanceof n ? a : new n(function(u) {
2458
+ u(a);
2473
2459
  });
2474
2460
  }
2475
- return new (n || (n = Promise))(function(a, c) {
2461
+ return new (n || (n = Promise))(function(a, u) {
2476
2462
  function l(_) {
2477
2463
  try {
2478
2464
  p(o.next(_));
2479
2465
  } catch (d) {
2480
- c(d);
2466
+ u(d);
2481
2467
  }
2482
2468
  }
2483
2469
  function m(_) {
2484
2470
  try {
2485
2471
  p(o.throw(_));
2486
2472
  } catch (d) {
2487
- c(d);
2473
+ u(d);
2488
2474
  }
2489
2475
  }
2490
2476
  function p(_) {
2491
- _.done ? a(_.value) : u(_.value).then(l, m);
2477
+ _.done ? a(_.value) : c(_.value).then(l, m);
2492
2478
  }
2493
2479
  p((o = o.apply(t, e || [])).next());
2494
2480
  });
@@ -2501,17 +2487,17 @@ class Xn {
2501
2487
  return Jn(this, void 0, void 0, function* () {
2502
2488
  var n, o;
2503
2489
  try {
2504
- let u, a = {
2490
+ let c, a = {
2505
2491
  "Content-Type": "application/json"
2506
2492
  };
2507
- const c = "/talk", l = `?session_id=${this.sessionId}`;
2493
+ const u = "/talk", l = `?session_id=${this.sessionId}`;
2508
2494
  if (!((n = this.apiGatewayConfig) === null || n === void 0) && n.enabled && (!((o = this.apiGatewayConfig) === null || o === void 0) && o.baseUrl)) {
2509
- u = `${this.apiGatewayConfig.baseUrl}${c}${l}`;
2510
- const p = new URL(`${this.baseUrl}${c}${l}`);
2495
+ c = `${this.apiGatewayConfig.baseUrl}${u}${l}`;
2496
+ const p = new URL(`${this.baseUrl}${u}${l}`);
2511
2497
  a["X-Anam-Target-Url"] = p.href;
2512
2498
  } else
2513
- u = `${this.baseUrl}${c}${l}`;
2514
- const m = yield fetch(u, {
2499
+ c = `${this.baseUrl}${u}${l}`;
2500
+ const m = yield fetch(c, {
2515
2501
  method: "POST",
2516
2502
  headers: a,
2517
2503
  body: JSON.stringify({
@@ -2520,8 +2506,8 @@ class Xn {
2520
2506
  });
2521
2507
  if (!m.ok)
2522
2508
  throw new Error(`Failed to send talk command: ${m.status} ${m.statusText}`);
2523
- } catch (u) {
2524
- throw console.error(u), new Error("EngineApiRestClient - sendTalkCommand: Failed to send talk command");
2509
+ } catch (c) {
2510
+ throw console.error(c), new Error("EngineApiRestClient - sendTalkCommand: Failed to send talk command");
2525
2511
  }
2526
2512
  });
2527
2513
  }
@@ -2544,7 +2530,7 @@ class Zn {
2544
2530
  }
2545
2531
  class Qn {
2546
2532
  constructor(e, n) {
2547
- this.messages = [], this.publicEventEmitter = e, this.internalEventEmitter = n, this.internalEventEmitter.addListener(X.WEBRTC_CHAT_MESSAGE_RECEIVED, this.processWebRtcTextMessageEvent.bind(this));
2533
+ this.messages = [], this.publicEventEmitter = e, this.internalEventEmitter = n, this.internalEventEmitter.addListener(J.WEBRTC_CHAT_MESSAGE_RECEIVED, this.processWebRtcTextMessageEvent.bind(this));
2548
2534
  }
2549
2535
  webRtcTextMessageEventToMessageStreamEvent(e) {
2550
2536
  return {
@@ -2570,10 +2556,10 @@ class Qn {
2570
2556
  content: e.content,
2571
2557
  role: e.role,
2572
2558
  interrupted: e.interrupted
2573
- }, o = this.messages.findIndex((u) => u.id === n.id);
2559
+ }, o = this.messages.findIndex((c) => c.id === n.id);
2574
2560
  if (o !== -1) {
2575
- const u = this.messages[o];
2576
- this.messages[o] = Object.assign(Object.assign({}, u), { content: u.content + n.content, interrupted: u.interrupted || n.interrupted });
2561
+ const c = this.messages[o];
2562
+ this.messages[o] = Object.assign(Object.assign({}, c), { content: c.content + n.content, interrupted: c.interrupted || n.interrupted });
2577
2563
  } else
2578
2564
  this.messages.push(n);
2579
2565
  }
@@ -2601,9 +2587,9 @@ class er {
2601
2587
  this.listeners[e] && this.listeners[e].delete(n);
2602
2588
  }
2603
2589
  emit(e, ...n) {
2604
- if (e === N.CONNECTION_ESTABLISHED && ge(se.CLIENT_METRIC_MEASUREMENT_CONNECTION_ESTABLISHED, "1"), e === N.CONNECTION_CLOSED) {
2605
- const [o, u] = n;
2606
- ge(se.CLIENT_METRIC_MEASUREMENT_CONNECTION_CLOSED, o, u ? { details: u } : void 0);
2590
+ if (e === N.CONNECTION_ESTABLISHED && me(oe.CLIENT_METRIC_MEASUREMENT_CONNECTION_ESTABLISHED, "1"), e === N.CONNECTION_CLOSED) {
2591
+ const [o, c] = n;
2592
+ me(oe.CLIENT_METRIC_MEASUREMENT_CONNECTION_CLOSED, o, c ? { details: c } : void 0);
2607
2593
  }
2608
2594
  this.listeners[e] && this.listeners[e].forEach((o) => {
2609
2595
  o(...n);
@@ -2615,38 +2601,38 @@ var z;
2615
2601
  t[t.UNSTARTED = 0] = "UNSTARTED", t[t.STREAMING = 1] = "STREAMING", t[t.INTERRUPTED = 2] = "INTERRUPTED", t[t.ENDED = 3] = "ENDED";
2616
2602
  })(z || (z = {}));
2617
2603
  var pt = function(t, e, n, o) {
2618
- function u(a) {
2619
- return a instanceof n ? a : new n(function(c) {
2620
- c(a);
2604
+ function c(a) {
2605
+ return a instanceof n ? a : new n(function(u) {
2606
+ u(a);
2621
2607
  });
2622
2608
  }
2623
- return new (n || (n = Promise))(function(a, c) {
2609
+ return new (n || (n = Promise))(function(a, u) {
2624
2610
  function l(_) {
2625
2611
  try {
2626
2612
  p(o.next(_));
2627
2613
  } catch (d) {
2628
- c(d);
2614
+ u(d);
2629
2615
  }
2630
2616
  }
2631
2617
  function m(_) {
2632
2618
  try {
2633
2619
  p(o.throw(_));
2634
2620
  } catch (d) {
2635
- c(d);
2621
+ u(d);
2636
2622
  }
2637
2623
  }
2638
2624
  function p(_) {
2639
- _.done ? a(_.value) : u(_.value).then(l, m);
2625
+ _.done ? a(_.value) : c(_.value).then(l, m);
2640
2626
  }
2641
2627
  p((o = o.apply(t, e || [])).next());
2642
2628
  });
2643
2629
  };
2644
2630
  class tr {
2645
2631
  constructor(e, n, o) {
2646
- this.state = z.UNSTARTED, this.correlationId = e, this.internalEventEmitter = n, this.signallingClient = o, this.internalEventEmitter.addListener(X.SIGNAL_MESSAGE_RECEIVED, this.onSignalMessage.bind(this));
2632
+ this.state = z.UNSTARTED, this.correlationId = e, this.internalEventEmitter = n, this.signallingClient = o, this.internalEventEmitter.addListener(J.SIGNAL_MESSAGE_RECEIVED, this.onSignalMessage.bind(this));
2647
2633
  }
2648
2634
  onDeactivate() {
2649
- this.internalEventEmitter.removeListener(X.SIGNAL_MESSAGE_RECEIVED, this.onSignalMessage.bind(this));
2635
+ this.internalEventEmitter.removeListener(J.SIGNAL_MESSAGE_RECEIVED, this.onSignalMessage.bind(this));
2650
2636
  }
2651
2637
  onSignalMessage(e) {
2652
2638
  return pt(this, void 0, void 0, function* () {
@@ -2695,43 +2681,43 @@ class tr {
2695
2681
  return this.state;
2696
2682
  }
2697
2683
  }
2698
- var J = function(t, e, n, o) {
2699
- function u(a) {
2700
- return a instanceof n ? a : new n(function(c) {
2701
- c(a);
2684
+ var K = function(t, e, n, o) {
2685
+ function c(a) {
2686
+ return a instanceof n ? a : new n(function(u) {
2687
+ u(a);
2702
2688
  });
2703
2689
  }
2704
- return new (n || (n = Promise))(function(a, c) {
2690
+ return new (n || (n = Promise))(function(a, u) {
2705
2691
  function l(_) {
2706
2692
  try {
2707
2693
  p(o.next(_));
2708
2694
  } catch (d) {
2709
- c(d);
2695
+ u(d);
2710
2696
  }
2711
2697
  }
2712
2698
  function m(_) {
2713
2699
  try {
2714
2700
  p(o.throw(_));
2715
2701
  } catch (d) {
2716
- c(d);
2702
+ u(d);
2717
2703
  }
2718
2704
  }
2719
2705
  function p(_) {
2720
- _.done ? a(_.value) : u(_.value).then(l, m);
2706
+ _.done ? a(_.value) : c(_.value).then(l, m);
2721
2707
  }
2722
2708
  p((o = o.apply(t, e || [])).next());
2723
2709
  });
2724
2710
  };
2725
2711
  const ir = 15e3, nr = 5e3, rr = 2;
2726
2712
  class or {
2727
- constructor(e, n, o, u) {
2728
- var a, c, l, m;
2713
+ constructor(e, n, o, c) {
2714
+ var a, u, l, m;
2729
2715
  this.peerConnection = null, this.connectionReceivedAnswer = !1, this.remoteIceCandidateBuffer = [], this.inputAudioStream = null, this.dataChannel = null, this.videoElement = null, this.videoStream = null, this.audioStream = null, this.inputAudioState = {
2730
2716
  isMuted: !1,
2731
- permissionState: fe.NOT_REQUESTED
2732
- }, this.successMetricPoller = null, this.successMetricFired = !1, this.showPeerConnectionStatsReport = !1, this.peerConnectionStatsReportOutputFormat = "console", this.statsCollectionInterval = null, this.agentAudioInputStream = null, this.publicEventEmitter = o, this.internalEventEmitter = u, this.apiGatewayConfig = n.apiGateway;
2717
+ permissionState: he.NOT_REQUESTED
2718
+ }, this.successMetricPoller = null, this.successMetricFired = !1, this.showPeerConnectionStatsReport = !1, this.peerConnectionStatsReportOutputFormat = "console", this.statsCollectionInterval = null, this.agentAudioInputStream = null, this.publicEventEmitter = o, this.internalEventEmitter = c, this.apiGatewayConfig = n.apiGateway;
2733
2719
  const { inputAudio: p } = n;
2734
- this.inputAudioState = p.inputAudioState, n.inputAudio.userProvidedMediaStream && (this.inputAudioStream = n.inputAudio.userProvidedMediaStream), this.disableInputAudio = n.inputAudio.disableInputAudio === !0, this.internalEventEmitter.addListener(X.WEB_SOCKET_OPEN, this.onSignallingClientConnected.bind(this)), this.internalEventEmitter.addListener(X.SIGNAL_MESSAGE_RECEIVED, this.onSignalMessage.bind(this)), this.iceServers = n.iceServers, this.signallingClient = new qn(e, n.signalling, this.publicEventEmitter, this.internalEventEmitter, this.apiGatewayConfig), this.engineApiRestClient = new Xn(n.engine.baseUrl, e, this.apiGatewayConfig), this.audioDeviceId = n.inputAudio.audioDeviceId, this.showPeerConnectionStatsReport = (c = (a = n.metrics) === null || a === void 0 ? void 0 : a.showPeerConnectionStatsReport) !== null && c !== void 0 ? c : !1, this.peerConnectionStatsReportOutputFormat = (m = (l = n.metrics) === null || l === void 0 ? void 0 : l.peerConnectionStatsReportOutputFormat) !== null && m !== void 0 ? m : "console";
2720
+ this.inputAudioState = p.inputAudioState, n.inputAudio.userProvidedMediaStream && (this.inputAudioStream = n.inputAudio.userProvidedMediaStream), this.disableInputAudio = n.inputAudio.disableInputAudio === !0, this.internalEventEmitter.addListener(J.WEB_SOCKET_OPEN, this.onSignallingClientConnected.bind(this)), this.internalEventEmitter.addListener(J.SIGNAL_MESSAGE_RECEIVED, this.onSignalMessage.bind(this)), this.iceServers = n.iceServers, this.signallingClient = new qn(e, n.signalling, this.publicEventEmitter, this.internalEventEmitter, this.apiGatewayConfig), this.engineApiRestClient = new Xn(n.engine.baseUrl, e, this.apiGatewayConfig), this.audioDeviceId = n.inputAudio.audioDeviceId, this.showPeerConnectionStatsReport = (u = (a = n.metrics) === null || a === void 0 ? void 0 : a.showPeerConnectionStatsReport) !== null && u !== void 0 ? u : !1, this.peerConnectionStatsReportOutputFormat = (m = (l = n.metrics) === null || l === void 0 ? void 0 : l.peerConnectionStatsReportOutputFormat) !== null && m !== void 0 ? m : "console";
2735
2721
  }
2736
2722
  onInputAudioStateChange(e, n) {
2737
2723
  e.isMuted !== n.isMuted && (n.isMuted ? this.muteAllAudioTracks() : this.unmuteAllAudioTracks());
@@ -2749,7 +2735,7 @@ class or {
2749
2735
  });
2750
2736
  }
2751
2737
  startStatsCollection() {
2752
- this.statsCollectionInterval || (this.statsCollectionInterval = setInterval(() => J(this, void 0, void 0, function* () {
2738
+ this.statsCollectionInterval || (this.statsCollectionInterval = setInterval(() => K(this, void 0, void 0, function* () {
2753
2739
  if (!(!this.peerConnection || !this.dataChannel || this.dataChannel.readyState !== "open"))
2754
2740
  try {
2755
2741
  const e = yield this.peerConnection.getStats();
@@ -2776,18 +2762,18 @@ class or {
2776
2762
  const e = setTimeout(() => {
2777
2763
  this.successMetricPoller && (console.warn("No video frames received, there is a problem with the connection."), clearInterval(this.successMetricPoller), this.successMetricPoller = null);
2778
2764
  }, ir);
2779
- this.successMetricPoller = setInterval(() => J(this, void 0, void 0, function* () {
2765
+ this.successMetricPoller = setInterval(() => K(this, void 0, void 0, function* () {
2780
2766
  if (!this.peerConnection || this.successMetricFired) {
2781
2767
  this.successMetricPoller && clearInterval(this.successMetricPoller), clearTimeout(e);
2782
2768
  return;
2783
2769
  }
2784
2770
  try {
2785
2771
  const n = yield this.peerConnection.getStats();
2786
- let o = !1, u = null;
2772
+ let o = !1, c = null;
2787
2773
  n.forEach((a) => {
2788
- a.type === "inbound-rtp" && a.kind === "video" && (a.framesDecoded !== void 0 && a.framesDecoded > 0 ? (o = !0, u = "framesDecoded") : a.framesReceived !== void 0 && a.framesReceived > 0 ? (o = !0, u = "framesReceived") : a.bytesReceived > 0 && a.packetsReceived > 0 && // Additional check: ensure we've received enough data for actual video
2789
- a.bytesReceived > 1e5 && (o = !0, u = "bytesReceived"));
2790
- }), o && !this.successMetricFired && (this.successMetricFired = !0, ge(se.CLIENT_METRIC_MEASUREMENT_SESSION_SUCCESS, "1", u ? { detectionMethod: u } : void 0), this.successMetricPoller && clearInterval(this.successMetricPoller), clearTimeout(e), this.successMetricPoller = null);
2774
+ a.type === "inbound-rtp" && a.kind === "video" && (a.framesDecoded !== void 0 && a.framesDecoded > 0 ? (o = !0, c = "framesDecoded") : a.framesReceived !== void 0 && a.framesReceived > 0 ? (o = !0, c = "framesReceived") : a.bytesReceived > 0 && a.packetsReceived > 0 && // Additional check: ensure we've received enough data for actual video
2775
+ a.bytesReceived > 1e5 && (o = !0, c = "bytesReceived"));
2776
+ }), o && !this.successMetricFired && (this.successMetricFired = !0, me(oe.CLIENT_METRIC_MEASUREMENT_SESSION_SUCCESS, "1", c ? { detectionMethod: c } : void 0), this.successMetricPoller && clearInterval(this.successMetricPoller), clearTimeout(e), this.successMetricPoller = null);
2791
2777
  } catch {
2792
2778
  }
2793
2779
  }), 500);
@@ -2807,15 +2793,15 @@ class or {
2807
2793
  return this.peerConnection;
2808
2794
  }
2809
2795
  changeAudioInputDevice(e) {
2810
- return J(this, void 0, void 0, function* () {
2796
+ return K(this, void 0, void 0, function* () {
2811
2797
  if (!this.peerConnection)
2812
2798
  throw new Error("StreamingClient - changeAudioInputDevice: peer connection is not initialized. Start streaming first.");
2813
2799
  if (e == null)
2814
2800
  throw new Error("StreamingClient - changeAudioInputDevice: deviceId is required");
2815
2801
  const n = this.inputAudioState.isMuted;
2816
2802
  try {
2817
- this.inputAudioStream && this.inputAudioStream.getAudioTracks().forEach((u) => {
2818
- u.stop();
2803
+ this.inputAudioStream && this.inputAudioStream.getAudioTracks().forEach((c) => {
2804
+ c.stop();
2819
2805
  });
2820
2806
  const o = {
2821
2807
  echoCancellation: !0,
@@ -2863,12 +2849,12 @@ class or {
2863
2849
  }
2864
2850
  }
2865
2851
  stopConnection() {
2866
- return J(this, void 0, void 0, function* () {
2852
+ return K(this, void 0, void 0, function* () {
2867
2853
  yield this.shutdown();
2868
2854
  });
2869
2855
  }
2870
2856
  sendTalkCommand(e) {
2871
- return J(this, void 0, void 0, function* () {
2857
+ return K(this, void 0, void 0, function* () {
2872
2858
  if (!this.peerConnection)
2873
2859
  throw new Error("StreamingClient - sendTalkCommand: peer connection is null");
2874
2860
  yield this.engineApiRestClient.sendTalkCommand(e);
@@ -2884,7 +2870,7 @@ class or {
2884
2870
  return this.agentAudioInputStream;
2885
2871
  }
2886
2872
  initPeerConnection() {
2887
- return J(this, void 0, void 0, function* () {
2873
+ return K(this, void 0, void 0, function* () {
2888
2874
  this.peerConnection = new RTCPeerConnection({
2889
2875
  iceServers: this.iceServers,
2890
2876
  iceCandidatePoolSize: rr
@@ -2894,7 +2880,7 @@ class or {
2894
2880
  });
2895
2881
  }
2896
2882
  onSignalMessage(e) {
2897
- return J(this, void 0, void 0, function* () {
2883
+ return K(this, void 0, void 0, function* () {
2898
2884
  if (!this.peerConnection) {
2899
2885
  console.error("StreamingClient - onSignalMessage: peerConnection is not initialized");
2900
2886
  return;
@@ -2905,16 +2891,16 @@ class or {
2905
2891
  yield this.peerConnection.setRemoteDescription(n), this.connectionReceivedAnswer = !0, this.flushRemoteIceCandidateBuffer();
2906
2892
  break;
2907
2893
  case W.ICE_CANDIDATE:
2908
- const o = e.payload, u = new RTCIceCandidate(o);
2909
- this.connectionReceivedAnswer ? yield this.peerConnection.addIceCandidate(u) : this.remoteIceCandidateBuffer.push(u);
2894
+ const o = e.payload, c = new RTCIceCandidate(o);
2895
+ this.connectionReceivedAnswer ? yield this.peerConnection.addIceCandidate(c) : this.remoteIceCandidateBuffer.push(c);
2910
2896
  break;
2911
2897
  case W.END_SESSION:
2912
2898
  const a = e.payload;
2913
- this.publicEventEmitter.emit(N.CONNECTION_CLOSED, _e.SERVER_CLOSED_CONNECTION, a), this.shutdown();
2899
+ this.publicEventEmitter.emit(N.CONNECTION_CLOSED, pe.SERVER_CLOSED_CONNECTION, a), this.shutdown();
2914
2900
  break;
2915
2901
  case W.WARNING:
2916
- const c = e.payload;
2917
- console.warn("Warning received from server: " + c), this.publicEventEmitter.emit(N.SERVER_WARNING, c);
2902
+ const u = e.payload;
2903
+ console.warn("Warning received from server: " + u), this.publicEventEmitter.emit(N.SERVER_WARNING, u);
2918
2904
  break;
2919
2905
  case W.TALK_STREAM_INTERRUPTED:
2920
2906
  const l = e.payload;
@@ -2932,7 +2918,7 @@ class or {
2932
2918
  });
2933
2919
  }
2934
2920
  onSignallingClientConnected() {
2935
- return J(this, void 0, void 0, function* () {
2921
+ return K(this, void 0, void 0, function* () {
2936
2922
  if (!this.peerConnection)
2937
2923
  try {
2938
2924
  yield this.initPeerConnectionAndSendOffer();
@@ -2964,7 +2950,7 @@ class or {
2964
2950
  ((e = this.peerConnection) === null || e === void 0 ? void 0 : e.connectionState) === "closed" && (console.error("StreamingClient - onConnectionStateChange: Connection closed"), this.handleWebrtcFailure("The connection to our servers was lost. Please try again."));
2965
2951
  }
2966
2952
  handleWebrtcFailure(e) {
2967
- console.error({ message: "StreamingClient - handleWebrtcFailure: ", err: e }), e.name === "NotAllowedError" && e.message === "Permission denied" ? this.publicEventEmitter.emit(N.CONNECTION_CLOSED, _e.MICROPHONE_PERMISSION_DENIED) : this.publicEventEmitter.emit(N.CONNECTION_CLOSED, _e.WEBRTC_FAILURE);
2953
+ console.error({ message: "StreamingClient - handleWebrtcFailure: ", err: e }), e.name === "NotAllowedError" && e.message === "Permission denied" ? this.publicEventEmitter.emit(N.CONNECTION_CLOSED, pe.MICROPHONE_PERMISSION_DENIED) : this.publicEventEmitter.emit(N.CONNECTION_CLOSED, pe.WEBRTC_FAILURE);
2968
2954
  try {
2969
2955
  this.stopConnection();
2970
2956
  } catch (n) {
@@ -2977,7 +2963,7 @@ class or {
2977
2963
  this.videoElement.srcObject = this.videoStream;
2978
2964
  const n = this.videoElement.requestVideoFrameCallback(() => {
2979
2965
  var o;
2980
- (o = this.videoElement) === null || o === void 0 || o.cancelVideoFrameCallback(n), this.publicEventEmitter.emit(N.VIDEO_PLAY_STARTED), this.successMetricFired || (this.successMetricFired = !0, ge(se.CLIENT_METRIC_MEASUREMENT_SESSION_SUCCESS, "1", { detectionMethod: "videoElement" }));
2966
+ (o = this.videoElement) === null || o === void 0 || o.cancelVideoFrameCallback(n), this.publicEventEmitter.emit(N.VIDEO_PLAY_STARTED), this.successMetricFired || (this.successMetricFired = !0, me(oe.CLIENT_METRIC_MEASUREMENT_SESSION_SUCCESS, "1", { detectionMethod: "videoElement" }));
2981
2967
  });
2982
2968
  }
2983
2969
  } else e.track.kind === "audio" && (this.audioStream = e.streams[0], this.publicEventEmitter.emit(N.AUDIO_STREAM_STARTED, this.audioStream));
@@ -2986,7 +2972,7 @@ class or {
2986
2972
  * Set up the data channels for sending and receiving messages
2987
2973
  */
2988
2974
  setupDataChannels() {
2989
- return J(this, void 0, void 0, function* () {
2975
+ return K(this, void 0, void 0, function* () {
2990
2976
  if (!this.peerConnection) {
2991
2977
  console.error("StreamingClient - setupDataChannels: peer connection is not initialized");
2992
2978
  return;
@@ -3004,16 +2990,16 @@ class or {
3004
2990
  const o = JSON.parse(n.data);
3005
2991
  switch (o.messageType) {
3006
2992
  case De.SPEECH_TEXT:
3007
- this.internalEventEmitter.emit(X.WEBRTC_CHAT_MESSAGE_RECEIVED, o.data);
2993
+ this.internalEventEmitter.emit(J.WEBRTC_CHAT_MESSAGE_RECEIVED, o.data);
3008
2994
  break;
3009
2995
  case De.CLIENT_TOOL_EVENT:
3010
- const u = o.data;
3011
- this.internalEventEmitter.emit(X.WEBRTC_CLIENT_TOOL_EVENT_RECEIVED, u);
3012
- const a = sr.WebRTCClientToolEventToClientToolEvent(u);
2996
+ const c = o.data;
2997
+ this.internalEventEmitter.emit(J.WEBRTC_CLIENT_TOOL_EVENT_RECEIVED, c);
2998
+ const a = sr.WebRTCClientToolEventToClientToolEvent(c);
3013
2999
  this.publicEventEmitter.emit(N.CLIENT_TOOL_EVENT_RECEIVED, a);
3014
3000
  break;
3015
3001
  case De.REASONING_TEXT:
3016
- this.internalEventEmitter.emit(X.WEBRTC_REASONING_TEXT_MESSAGE_RECEIVED, o.data);
3002
+ this.internalEventEmitter.emit(J.WEBRTC_REASONING_TEXT_MESSAGE_RECEIVED, o.data);
3017
3003
  break;
3018
3004
  // Unknown message types are silently ignored to maintain forward compatibility
3019
3005
  default:
@@ -3029,9 +3015,9 @@ class or {
3029
3015
  * Request microphone permission asynchronously without blocking connection
3030
3016
  */
3031
3017
  requestMicrophonePermissionAsync() {
3032
- return J(this, void 0, void 0, function* () {
3033
- if (this.inputAudioState.permissionState !== fe.PENDING) {
3034
- this.inputAudioState = Object.assign(Object.assign({}, this.inputAudioState), { permissionState: fe.PENDING }), this.publicEventEmitter.emit(N.MIC_PERMISSION_PENDING);
3018
+ return K(this, void 0, void 0, function* () {
3019
+ if (this.inputAudioState.permissionState !== he.PENDING) {
3020
+ this.inputAudioState = Object.assign(Object.assign({}, this.inputAudioState), { permissionState: he.PENDING }), this.publicEventEmitter.emit(N.MIC_PERMISSION_PENDING);
3035
3021
  try {
3036
3022
  const e = {
3037
3023
  echoCancellation: !0
@@ -3040,9 +3026,9 @@ class or {
3040
3026
  exact: this.audioDeviceId
3041
3027
  }), this.inputAudioStream = yield navigator.mediaDevices.getUserMedia({
3042
3028
  audio: e
3043
- }), this.inputAudioState = Object.assign(Object.assign({}, this.inputAudioState), { permissionState: fe.GRANTED }), this.publicEventEmitter.emit(N.MIC_PERMISSION_GRANTED), yield this.setupAudioTrack();
3029
+ }), this.inputAudioState = Object.assign(Object.assign({}, this.inputAudioState), { permissionState: he.GRANTED }), this.publicEventEmitter.emit(N.MIC_PERMISSION_GRANTED), yield this.setupAudioTrack();
3044
3030
  } catch (e) {
3045
- console.error("Failed to get microphone permission:", e), this.inputAudioState = Object.assign(Object.assign({}, this.inputAudioState), { permissionState: fe.DENIED });
3031
+ console.error("Failed to get microphone permission:", e), this.inputAudioState = Object.assign(Object.assign({}, this.inputAudioState), { permissionState: he.DENIED });
3046
3032
  const n = e instanceof Error ? e.message : String(e);
3047
3033
  this.publicEventEmitter.emit(N.MIC_PERMISSION_DENIED, n);
3048
3034
  }
@@ -3053,7 +3039,7 @@ class or {
3053
3039
  * Set up audio track and add it to the peer connection using replaceTrack
3054
3040
  */
3055
3041
  setupAudioTrack() {
3056
- return J(this, void 0, void 0, function* () {
3042
+ return K(this, void 0, void 0, function* () {
3057
3043
  if (!this.peerConnection || !this.inputAudioStream)
3058
3044
  return;
3059
3045
  if (!this.inputAudioStream.getAudioTracks().length) {
@@ -3061,15 +3047,15 @@ class or {
3061
3047
  return;
3062
3048
  }
3063
3049
  this.inputAudioState.isMuted && this.muteAllAudioTracks();
3064
- const e = this.inputAudioStream.getAudioTracks()[0], o = this.peerConnection.getSenders().find((u) => {
3050
+ const e = this.inputAudioStream.getAudioTracks()[0], o = this.peerConnection.getSenders().find((c) => {
3065
3051
  var a;
3066
- return ((a = u.track) === null || a === void 0 ? void 0 : a.kind) === "audio" || u.track === null && u.dtmf !== null;
3052
+ return ((a = c.track) === null || a === void 0 ? void 0 : a.kind) === "audio" || c.track === null && c.dtmf !== null;
3067
3053
  });
3068
3054
  if (o)
3069
3055
  try {
3070
3056
  yield o.replaceTrack(e);
3071
- } catch (u) {
3072
- console.error("Failed to replace audio track:", u), this.peerConnection.addTrack(e, this.inputAudioStream);
3057
+ } catch (c) {
3058
+ console.error("Failed to replace audio track:", c), this.peerConnection.addTrack(e, this.inputAudioStream);
3073
3059
  }
3074
3060
  else
3075
3061
  this.peerConnection.addTrack(e, this.inputAudioStream);
@@ -3077,7 +3063,7 @@ class or {
3077
3063
  });
3078
3064
  }
3079
3065
  initPeerConnectionAndSendOffer() {
3080
- return J(this, void 0, void 0, function* () {
3066
+ return K(this, void 0, void 0, function* () {
3081
3067
  if (yield this.initPeerConnection(), !this.peerConnection) {
3082
3068
  console.error("StreamingClient - initPeerConnectionAndSendOffer: peer connection is not initialized");
3083
3069
  return;
@@ -3094,12 +3080,12 @@ class or {
3094
3080
  });
3095
3081
  }
3096
3082
  shutdown() {
3097
- return J(this, void 0, void 0, function* () {
3083
+ return K(this, void 0, void 0, function* () {
3098
3084
  var e;
3099
3085
  if (this.showPeerConnectionStatsReport) {
3100
3086
  const n = yield (e = this.peerConnection) === null || e === void 0 ? void 0 : e.getStats();
3101
3087
  if (n) {
3102
- const o = Vn(n, this.peerConnectionStatsReportOutputFormat);
3088
+ const o = Gn(n, this.peerConnectionStatsReportOutputFormat);
3103
3089
  o && console.log(o, void 0, 2);
3104
3090
  }
3105
3091
  }
@@ -3142,7 +3128,7 @@ class sr {
3142
3128
  }
3143
3129
  class ar {
3144
3130
  constructor(e, n) {
3145
- this.reasoning_messages = [], this.publicEventEmitter = e, this.internalEventEmitter = n, this.internalEventEmitter.addListener(X.WEBRTC_REASONING_TEXT_MESSAGE_RECEIVED, this.processWebRtcReasoningTextMessageEvent.bind(this));
3131
+ this.reasoning_messages = [], this.publicEventEmitter = e, this.internalEventEmitter = n, this.internalEventEmitter.addListener(J.WEBRTC_REASONING_TEXT_MESSAGE_RECEIVED, this.processWebRtcReasoningTextMessageEvent.bind(this));
3146
3132
  }
3147
3133
  webRtcTextMessageEventToReasoningStreamEvent(e) {
3148
3134
  return {
@@ -3159,53 +3145,53 @@ class ar {
3159
3145
  id: n.id,
3160
3146
  content: n.content,
3161
3147
  role: n.role
3162
- }, u = this.reasoning_messages.findIndex((a) => a.id === o.id);
3163
- if (u !== -1) {
3164
- const a = this.reasoning_messages[u];
3165
- a.content += o.content, this.reasoning_messages[u] = a;
3148
+ }, c = this.reasoning_messages.findIndex((a) => a.id === o.id);
3149
+ if (c !== -1) {
3150
+ const a = this.reasoning_messages[c];
3151
+ a.content += o.content, this.reasoning_messages[c] = a;
3166
3152
  } else
3167
3153
  this.reasoning_messages.push(o);
3168
3154
  n.endOfThought && this.publicEventEmitter.emit(N.REASONING_HISTORY_UPDATED, this.reasoning_messages);
3169
3155
  }
3170
3156
  }
3171
- var ue = function(t, e, n, o) {
3172
- function u(a) {
3173
- return a instanceof n ? a : new n(function(c) {
3174
- c(a);
3157
+ var ce = function(t, e, n, o) {
3158
+ function c(a) {
3159
+ return a instanceof n ? a : new n(function(u) {
3160
+ u(a);
3175
3161
  });
3176
3162
  }
3177
- return new (n || (n = Promise))(function(a, c) {
3163
+ return new (n || (n = Promise))(function(a, u) {
3178
3164
  function l(_) {
3179
3165
  try {
3180
3166
  p(o.next(_));
3181
3167
  } catch (d) {
3182
- c(d);
3168
+ u(d);
3183
3169
  }
3184
3170
  }
3185
3171
  function m(_) {
3186
3172
  try {
3187
3173
  p(o.throw(_));
3188
3174
  } catch (d) {
3189
- c(d);
3175
+ u(d);
3190
3176
  }
3191
3177
  }
3192
3178
  function p(_) {
3193
- _.done ? a(_.value) : u(_.value).then(l, m);
3179
+ _.done ? a(_.value) : c(_.value).then(l, m);
3194
3180
  }
3195
3181
  p((o = o.apply(t, e || [])).next());
3196
3182
  });
3197
3183
  };
3198
3184
  class lr {
3199
3185
  constructor(e, n, o) {
3200
- var u, a, c, l, m;
3186
+ var c, a, u, l, m;
3201
3187
  this.inputAudioState = {
3202
3188
  isMuted: !1,
3203
- permissionState: fe.NOT_REQUESTED
3189
+ permissionState: he.NOT_REQUESTED
3204
3190
  }, this.sessionId = null, this.organizationId = null, this.streamingClient = null, this._isStreaming = !1;
3205
3191
  const p = this.validateClientConfig(e, n, o);
3206
3192
  if (p)
3207
- throw new $(p, V.CLIENT_ERROR_CODE_CONFIGURATION_ERROR, 400);
3208
- this.personaConfig = n, this.clientOptions = o, (!((u = o?.api) === null || u === void 0) && u.baseUrl || !((a = o?.api) === null || a === void 0) && a.apiVersion) && Fn(o.api.baseUrl || Wi, o.api.apiVersion || xt), !((l = (c = o?.api) === null || c === void 0 ? void 0 : c.apiGateway) === null || l === void 0) && l.enabled && $n(o.api.apiGateway), !((m = o?.metrics) === null || m === void 0) && m.disableClientMetrics && Gn(!0), this.publicEventEmitter = new er(), this.internalEventEmitter = new Zn(), this.apiClient = new Kn(e, o?.apiKey, o?.api), this.messageHistoryClient = new Qn(this.publicEventEmitter, this.internalEventEmitter), this.reasoningHistoryClient = new ar(this.publicEventEmitter, this.internalEventEmitter);
3193
+ throw new $(p, G.CLIENT_ERROR_CODE_CONFIGURATION_ERROR, 400);
3194
+ this.personaConfig = n, this.clientOptions = o, (!((c = o?.api) === null || c === void 0) && c.baseUrl || !((a = o?.api) === null || a === void 0) && a.apiVersion) && Fn(o.api.baseUrl || Wi, o.api.apiVersion || xt), !((l = (u = o?.api) === null || u === void 0 ? void 0 : u.apiGateway) === null || l === void 0) && l.enabled && $n(o.api.apiGateway), !((m = o?.metrics) === null || m === void 0) && m.disableClientMetrics && Vn(!0), this.publicEventEmitter = new er(), this.internalEventEmitter = new Zn(), this.apiClient = new Kn(e, o?.apiKey, o?.api), this.messageHistoryClient = new Qn(this.publicEventEmitter, this.internalEventEmitter), this.reasoningHistoryClient = new ar(this.publicEventEmitter, this.internalEventEmitter);
3209
3195
  }
3210
3196
  decodeJwt(e) {
3211
3197
  try {
@@ -3216,17 +3202,17 @@ class lr {
3216
3202
  }
3217
3203
  }
3218
3204
  validateClientConfig(e, n, o) {
3219
- var u, a;
3205
+ var c, a;
3220
3206
  if (!e && !o?.apiKey)
3221
3207
  return "Either sessionToken or apiKey must be provided";
3222
3208
  if (o?.apiKey && e)
3223
3209
  return "Only one of sessionToken or apiKey should be used";
3224
- const c = jn((u = o?.api) === null || u === void 0 ? void 0 : u.apiGateway);
3225
- if (c)
3226
- return c;
3210
+ const u = jn((c = o?.api) === null || c === void 0 ? void 0 : c.apiGateway);
3211
+ if (u)
3212
+ return u;
3227
3213
  if (e) {
3228
3214
  const l = this.decodeJwt(e);
3229
- this.organizationId = l.accountId, we({
3215
+ this.organizationId = l.accountId, Se({
3230
3216
  organizationId: this.organizationId
3231
3217
  });
3232
3218
  const m = (a = l.type) === null || a === void 0 ? void 0 : a.toLowerCase();
@@ -3254,77 +3240,77 @@ class lr {
3254
3240
  return n;
3255
3241
  }
3256
3242
  startSession(e) {
3257
- return ue(this, void 0, void 0, function* () {
3258
- var n, o, u, a, c, l, m, p, _, d, S, g;
3259
- const y = this.personaConfig, b = this.buildStartSessionOptionsForClient(), A = yield this.apiClient.startSession(y, b), { sessionId: C, clientConfig: I, engineHost: x, engineProtocol: O, signallingEndpoint: T } = A, { heartbeatIntervalSeconds: q, maxWsReconnectionAttempts: H, iceServers: ae } = I;
3260
- this.sessionId = C, we({
3243
+ return ce(this, void 0, void 0, function* () {
3244
+ var n, o, c, a, u, l, m, p, _, d, y, g;
3245
+ const S = this.personaConfig, C = this.buildStartSessionOptionsForClient(), A = yield this.apiClient.startSession(S, C), { sessionId: I, clientConfig: b, engineHost: T, engineProtocol: D, signallingEndpoint: x } = A, { heartbeatIntervalSeconds: Z, maxWsReconnectionAttempts: H, iceServers: se } = b;
3246
+ this.sessionId = I, Se({
3261
3247
  sessionId: this.sessionId
3262
3248
  });
3263
- const ne = !((n = this.clientOptions) === null || n === void 0) && n.iceServers ? this.clientOptions.iceServers : ae;
3249
+ const ne = !((n = this.clientOptions) === null || n === void 0) && n.iceServers ? this.clientOptions.iceServers : se;
3264
3250
  try {
3265
- this.streamingClient = new or(C, {
3251
+ this.streamingClient = new or(I, {
3266
3252
  engine: {
3267
- baseUrl: `${O}://${x}`
3253
+ baseUrl: `${D}://${T}`
3268
3254
  },
3269
3255
  signalling: {
3270
- heartbeatIntervalSeconds: q,
3256
+ heartbeatIntervalSeconds: Z,
3271
3257
  maxWsReconnectionAttempts: H,
3272
3258
  url: {
3273
- baseUrl: x,
3274
- protocol: O,
3275
- signallingPath: T
3259
+ baseUrl: T,
3260
+ protocol: D,
3261
+ signallingPath: x
3276
3262
  }
3277
3263
  },
3278
3264
  iceServers: ne,
3279
3265
  inputAudio: {
3280
3266
  inputAudioState: this.inputAudioState,
3281
3267
  userProvidedMediaStream: !((o = this.clientOptions) === null || o === void 0) && o.disableInputAudio ? void 0 : e,
3282
- audioDeviceId: (u = this.clientOptions) === null || u === void 0 ? void 0 : u.audioDeviceId,
3268
+ audioDeviceId: (c = this.clientOptions) === null || c === void 0 ? void 0 : c.audioDeviceId,
3283
3269
  disableInputAudio: (a = this.clientOptions) === null || a === void 0 ? void 0 : a.disableInputAudio
3284
3270
  },
3285
- apiGateway: (l = (c = this.clientOptions) === null || c === void 0 ? void 0 : c.api) === null || l === void 0 ? void 0 : l.apiGateway,
3271
+ apiGateway: (l = (u = this.clientOptions) === null || u === void 0 ? void 0 : u.api) === null || l === void 0 ? void 0 : l.apiGateway,
3286
3272
  metrics: {
3287
3273
  showPeerConnectionStatsReport: (_ = (p = (m = this.clientOptions) === null || m === void 0 ? void 0 : m.metrics) === null || p === void 0 ? void 0 : p.showPeerConnectionStatsReport) !== null && _ !== void 0 ? _ : !1,
3288
- peerConnectionStatsReportOutputFormat: (g = (S = (d = this.clientOptions) === null || d === void 0 ? void 0 : d.metrics) === null || S === void 0 ? void 0 : S.peerConnectionStatsReportOutputFormat) !== null && g !== void 0 ? g : "console"
3274
+ peerConnectionStatsReportOutputFormat: (g = (y = (d = this.clientOptions) === null || d === void 0 ? void 0 : d.metrics) === null || y === void 0 ? void 0 : y.peerConnectionStatsReportOutputFormat) !== null && g !== void 0 ? g : "console"
3289
3275
  }
3290
3276
  }, this.publicEventEmitter, this.internalEventEmitter);
3291
3277
  } catch (re) {
3292
- throw we({
3278
+ throw Se({
3293
3279
  sessionId: null
3294
- }), new $("Failed to initialize streaming client", V.CLIENT_ERROR_CODE_SERVER_ERROR, 500, {
3280
+ }), new $("Failed to initialize streaming client", G.CLIENT_ERROR_CODE_SERVER_ERROR, 500, {
3295
3281
  cause: re instanceof Error ? re.message : String(re),
3296
- sessionId: C
3282
+ sessionId: I
3297
3283
  });
3298
3284
  }
3299
- return C;
3285
+ return I;
3300
3286
  });
3301
3287
  }
3302
3288
  startSessionIfNeeded(e) {
3303
- return ue(this, void 0, void 0, function* () {
3289
+ return ce(this, void 0, void 0, function* () {
3304
3290
  if ((!this.sessionId || !this.streamingClient) && (yield this.startSession(e), !this.sessionId || !this.streamingClient))
3305
- throw new $("Session ID or streaming client is not available after starting session", V.CLIENT_ERROR_CODE_SERVER_ERROR, 500, {
3291
+ throw new $("Session ID or streaming client is not available after starting session", G.CLIENT_ERROR_CODE_SERVER_ERROR, 500, {
3306
3292
  cause: "Failed to initialize session properly"
3307
3293
  });
3308
3294
  });
3309
3295
  }
3310
3296
  stream(e) {
3311
- return ue(this, void 0, void 0, function* () {
3297
+ return ce(this, void 0, void 0, function* () {
3312
3298
  var n;
3313
3299
  if (this._isStreaming)
3314
3300
  throw new Error("Already streaming");
3315
3301
  const o = li();
3316
- return we({
3302
+ return Se({
3317
3303
  attemptCorrelationId: o,
3318
3304
  sessionId: null
3319
3305
  // reset sessionId
3320
- }), ge(se.CLIENT_METRIC_MEASUREMENT_SESSION_ATTEMPT, "1"), !((n = this.clientOptions) === null || n === void 0) && n.disableInputAudio && e && console.warn("AnamClient:Input audio is disabled. User provided audio stream will be ignored."), yield this.startSessionIfNeeded(e), this._isStreaming = !0, new Promise((u) => {
3306
+ }), me(oe.CLIENT_METRIC_MEASUREMENT_SESSION_ATTEMPT, "1"), !((n = this.clientOptions) === null || n === void 0) && n.disableInputAudio && e && console.warn("AnamClient:Input audio is disabled. User provided audio stream will be ignored."), yield this.startSessionIfNeeded(e), this._isStreaming = !0, new Promise((c) => {
3321
3307
  var a;
3322
- const c = [];
3308
+ const u = [];
3323
3309
  let l = !1, m = !1;
3324
3310
  this.publicEventEmitter.addListener(N.VIDEO_STREAM_STARTED, (p) => {
3325
- c.push(p), l = !0, m && u(c);
3311
+ u.push(p), l = !0, m && c(u);
3326
3312
  }), this.publicEventEmitter.addListener(N.AUDIO_STREAM_STARTED, (p) => {
3327
- c.push(p), m = !0, l && u(c);
3313
+ u.push(p), m = !0, l && c(u);
3328
3314
  }), (a = this.streamingClient) === null || a === void 0 || a.startConnection();
3329
3315
  });
3330
3316
  });
@@ -3333,23 +3319,23 @@ class lr {
3333
3319
  * @deprecated This method is deprecated. Please use streamToVideoElement instead.
3334
3320
  */
3335
3321
  streamToVideoAndAudioElements(e, n, o) {
3336
- return ue(this, void 0, void 0, function* () {
3322
+ return ce(this, void 0, void 0, function* () {
3337
3323
  console.warn("AnamClient: streamToVideoAndAudioElements is deprecated. To avoid possible audio issues, please use streamToVideoElement instead."), yield this.streamToVideoElement(e, o);
3338
3324
  });
3339
3325
  }
3340
3326
  streamToVideoElement(e, n) {
3341
- return ue(this, void 0, void 0, function* () {
3327
+ return ce(this, void 0, void 0, function* () {
3342
3328
  var o;
3343
- const u = li();
3344
- we({
3345
- attemptCorrelationId: u,
3329
+ const c = li();
3330
+ Se({
3331
+ attemptCorrelationId: c,
3346
3332
  sessionId: null
3347
3333
  // reset sessionId
3348
- }), ge(se.CLIENT_METRIC_MEASUREMENT_SESSION_ATTEMPT, "1"), !((o = this.clientOptions) === null || o === void 0) && o.disableInputAudio && n && console.warn("AnamClient:Input audio is disabled. User provided audio stream will be ignored.");
3334
+ }), me(oe.CLIENT_METRIC_MEASUREMENT_SESSION_ATTEMPT, "1"), !((o = this.clientOptions) === null || o === void 0) && o.disableInputAudio && n && console.warn("AnamClient:Input audio is disabled. User provided audio stream will be ignored.");
3349
3335
  try {
3350
3336
  yield this.startSessionIfNeeded(n);
3351
3337
  } catch (a) {
3352
- throw a instanceof $ ? a : new $("Failed to start session", V.CLIENT_ERROR_CODE_SERVER_ERROR, 500, {
3338
+ throw a instanceof $ ? a : new $("Failed to start session", G.CLIENT_ERROR_CODE_SERVER_ERROR, 500, {
3353
3339
  cause: a instanceof Error ? a.message : String(a),
3354
3340
  sessionId: this.sessionId
3355
3341
  });
@@ -3367,7 +3353,7 @@ class lr {
3367
3353
  * @throws Error if session is not started or not currently streaming
3368
3354
  */
3369
3355
  talk(e) {
3370
- return ue(this, void 0, void 0, function* () {
3356
+ return ce(this, void 0, void 0, function* () {
3371
3357
  if (!this.streamingClient)
3372
3358
  throw new Error("Failed to send talk command: session is not started. Have you called startSession?");
3373
3359
  if (!this._isStreaming)
@@ -3397,13 +3383,13 @@ class lr {
3397
3383
  const n = this.getActiveSessionId();
3398
3384
  if (!n)
3399
3385
  throw new Error("Failed to send user message: no active session");
3400
- const o = (/* @__PURE__ */ new Date()).toISOString().replace("Z", ""), u = JSON.stringify({
3386
+ const o = (/* @__PURE__ */ new Date()).toISOString().replace("Z", ""), c = JSON.stringify({
3401
3387
  content: e,
3402
3388
  timestamp: o,
3403
3389
  session_id: n,
3404
3390
  message_type: "speech"
3405
3391
  });
3406
- this.sendDataMessage(u);
3392
+ this.sendDataMessage(c);
3407
3393
  }
3408
3394
  interruptPersona() {
3409
3395
  if (!this._isStreaming)
@@ -3420,8 +3406,8 @@ class lr {
3420
3406
  this.sendDataMessage(n);
3421
3407
  }
3422
3408
  stopStreaming() {
3423
- return ue(this, void 0, void 0, function* () {
3424
- this.streamingClient && (this.publicEventEmitter.emit(N.CONNECTION_CLOSED, _e.NORMAL), yield this.streamingClient.stopConnection(), this.streamingClient = null, this.sessionId = null, we({
3409
+ return ce(this, void 0, void 0, function* () {
3410
+ this.streamingClient && (this.publicEventEmitter.emit(N.CONNECTION_CLOSED, pe.NORMAL), yield this.streamingClient.stopConnection(), this.streamingClient = null, this.sessionId = null, Se({
3425
3411
  attemptCorrelationId: null,
3426
3412
  sessionId: null,
3427
3413
  organizationId: this.organizationId
@@ -3450,7 +3436,7 @@ class lr {
3450
3436
  return !((e = this.clientOptions) === null || e === void 0) && e.disableInputAudio && console.warn("AnamClient: Input audio is disabled. Unmuting input audio will have no effect."), this.streamingClient && !(!((n = this.clientOptions) === null || n === void 0) && n.disableInputAudio) ? this.inputAudioState = this.streamingClient.unmuteInputAudio() : this.inputAudioState = Object.assign(Object.assign({}, this.inputAudioState), { isMuted: !1 }), this.inputAudioState;
3451
3437
  }
3452
3438
  changeAudioInputDevice(e) {
3453
- return ue(this, void 0, void 0, function* () {
3439
+ return ce(this, void 0, void 0, function* () {
3454
3440
  var n;
3455
3441
  if (!((n = this.clientOptions) === null || n === void 0) && n.disableInputAudio)
3456
3442
  throw new Error("AnamClient: Cannot change audio input device because input audio is disabled.");
@@ -3495,7 +3481,7 @@ function dr(t) {
3495
3481
  return {};
3496
3482
  }
3497
3483
  }
3498
- const Z = K(null), te = K("idle"), Le = K(!1), Ke = K(!1), at = K([]), Pe = K(null), it = K(null), Ot = K(null), kt = K(null), Dt = K(null), ui = K(!1), nt = K(!1);
3484
+ const X = Y(null), te = Y("idle"), Be = Y(!1), Ke = Y(!1), at = Y([]), Pe = Y(null), it = Y(null), Ot = Y(null), kt = Y(null), Dt = Y(null), ui = Y(!1), nt = Y(!1);
3499
3485
  function hr(t, e) {
3500
3486
  return e === 401 || e === 403 ? "This agent is not authorized. Check your agent ID." : e === 404 ? "Agent not found. Check your agent ID." : e === 429 ? "Too many requests. Please wait a moment." : e && e >= 500 ? "Server error. Please try again later." : t instanceof TypeError && t.message === "Failed to fetch" ? "Unable to connect. Check your network connection." : t instanceof Error && t.message.length < 80 ? t.message : "Something went wrong. Please try again.";
3501
3487
  }
@@ -3515,7 +3501,7 @@ async function pr(t, e, n, o) {
3515
3501
  if (te.value === "connecting" || te.value === "connected")
3516
3502
  return;
3517
3503
  te.value = "connecting", Pe.value = null;
3518
- let u;
3504
+ let c;
3519
3505
  try {
3520
3506
  let a;
3521
3507
  if (o)
@@ -3527,7 +3513,7 @@ async function pr(t, e, n, o) {
3527
3513
  headers: { "Content-Type": "application/json" },
3528
3514
  body: JSON.stringify({ agentId: t })
3529
3515
  });
3530
- if (u = m.status, !m.ok) {
3516
+ if (c = m.status, !m.ok) {
3531
3517
  const _ = await m.json().catch(() => ({}));
3532
3518
  throw new Error(_.error || `HTTP ${m.status}`);
3533
3519
  }
@@ -3536,57 +3522,57 @@ async function pr(t, e, n, o) {
3536
3522
  hasToken: !!p.sessionToken
3537
3523
  }), a = p.sessionToken;
3538
3524
  }
3539
- const c = cr(a, {
3525
+ const u = cr(a, {
3540
3526
  api: e ? { baseUrl: e } : void 0,
3541
3527
  metrics: { disableClientMetrics: !0 }
3542
3528
  });
3543
- c.addListener(N.CONNECTION_ESTABLISHED, () => {
3529
+ u.addListener(N.CONNECTION_ESTABLISHED, () => {
3544
3530
  console.log("[AnamWidget] Connection established"), te.value = "connected";
3545
- }), c.addListener(N.VIDEO_STREAM_STARTED, () => {
3546
- console.log("[AnamWidget] Video stream started"), Le.value = !0;
3547
- }), c.addListener(N.AUDIO_STREAM_STARTED, () => {
3531
+ }), u.addListener(N.VIDEO_STREAM_STARTED, () => {
3532
+ console.log("[AnamWidget] Video stream started"), Be.value = !0;
3533
+ }), u.addListener(N.AUDIO_STREAM_STARTED, () => {
3548
3534
  console.log("[AnamWidget] Audio stream started");
3549
- }), c.addListener(N.MESSAGE_HISTORY_UPDATED, (m) => {
3535
+ }), u.addListener(N.MESSAGE_HISTORY_UPDATED, (m) => {
3550
3536
  at.value = [...m];
3551
- }), c.addListener(N.CONNECTION_CLOSED, (m, p) => {
3552
- console.log("[AnamWidget] Connection closed:", m, p), te.value = "idle", Le.value = !1, it.value = null;
3553
- }), c.addListener(N.SESSION_READY, (m) => {
3537
+ }), u.addListener(N.CONNECTION_CLOSED, (m, p) => {
3538
+ console.log("[AnamWidget] Connection closed:", m, p), te.value = "idle", Be.value = !1, it.value = null;
3539
+ }), u.addListener(N.SESSION_READY, (m) => {
3554
3540
  console.log("[AnamWidget] Session ready:", m), it.value = m;
3555
- }), Z.value = c;
3556
- const l = await c.stream();
3541
+ }), X.value = u;
3542
+ const l = await u.stream();
3557
3543
  if (n && l.length > 0) {
3558
3544
  const m = l.find((p) => p.getVideoTracks().length > 0);
3559
3545
  m && (n.srcObject = m);
3560
3546
  }
3561
3547
  } catch (a) {
3562
- console.error("[AnamWidget] Failed to start session:", a), Pe.value = hr(a, u), te.value = "error", Z.value = null;
3548
+ console.error("[AnamWidget] Failed to start session:", a), Pe.value = hr(a, c), te.value = "error", X.value = null;
3563
3549
  }
3564
3550
  }
3565
3551
  async function _r() {
3566
- if (Z.value)
3552
+ if (X.value)
3567
3553
  try {
3568
- await Z.value.stopStreaming();
3554
+ await X.value.stopStreaming();
3569
3555
  } catch (t) {
3570
3556
  console.error("[AnamWidget] Failed to stop session:", t);
3571
3557
  }
3572
- Z.value = null, te.value = "idle", Le.value = !1, at.value = [];
3558
+ X.value = null, te.value = "idle", Be.value = !1, at.value = [];
3573
3559
  }
3574
3560
  function Er(t) {
3575
- !Z.value || te.value !== "connected" || Z.value.sendUserMessage(t);
3561
+ !X.value || te.value !== "connected" || X.value.sendUserMessage(t);
3576
3562
  }
3577
3563
  function mr() {
3578
- Z.value && (Ke.value ? (Z.value.unmuteInputAudio(), Ke.value = !1) : (Z.value.muteInputAudio(), Ke.value = !0));
3564
+ X.value && (Ke.value ? (X.value.unmuteInputAudio(), Ke.value = !1) : (X.value.muteInputAudio(), Ke.value = !0));
3579
3565
  }
3580
3566
  function gr() {
3581
- Z.value?.isStreaming() && Z.value.stopStreaming(), Z.value = null, te.value = "idle", Le.value = !1, at.value = [], Pe.value = null, it.value = null, Ot.value = null, kt.value = null, Dt.value = null;
3567
+ X.value?.isStreaming() && X.value.stopStreaming(), X.value = null, te.value = "idle", Be.value = !1, at.value = [], Pe.value = null, it.value = null, Ot.value = null, kt.value = null, Dt.value = null;
3582
3568
  }
3583
3569
  function vr(t, e, n) {
3584
3570
  const o = t || (n ? dr(n).personaId : void 0);
3585
3571
  ui.value = !!o || !!n;
3586
- const u = e || ur;
3572
+ const c = e || ur;
3587
3573
  return {
3588
3574
  connectionStatus: te,
3589
- isStreaming: Le,
3575
+ isStreaming: Be,
3590
3576
  isMuted: Ke,
3591
3577
  messages: at,
3592
3578
  error: Pe,
@@ -3601,21 +3587,21 @@ function vr(t, e, n) {
3601
3587
  nt.value = !0;
3602
3588
  return;
3603
3589
  }
3604
- fr(o, u);
3590
+ fr(o, c);
3605
3591
  },
3606
- startSession: (l) => !o && !n ? (Pe.value = "No agent ID or session token configured", Promise.resolve()) : pr(o || "", u, l, n),
3592
+ startSession: (l) => !o && !n ? (Pe.value = "No agent ID or session token configured", Promise.resolve()) : pr(o || "", c, l, n),
3607
3593
  stopSession: _r,
3608
3594
  sendMessage: Er,
3609
3595
  toggleMute: mr,
3610
3596
  cleanup: gr
3611
3597
  };
3612
3598
  }
3613
- const di = '@layer properties{@supports (((-webkit-hyphens:none)) and (not (margin-trim:inline))) or ((-moz-orient:inline) and (not (color:rgb(from red r g b)))){*,:before,:after,::backdrop{--tw-rotate-x:initial;--tw-rotate-y:initial;--tw-rotate-z:initial;--tw-skew-x:initial;--tw-skew-y:initial;--tw-border-style:solid;--tw-outline-style:solid}}}@layer theme{:root,:host{--font-sans:ui-sans-serif,system-ui,sans-serif,"Apple Color Emoji","Segoe UI Emoji","Segoe UI Symbol","Noto Color Emoji";--font-mono:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,"Liberation Mono","Courier New",monospace;--default-transition-duration:.15s;--default-transition-timing-function:cubic-bezier(.4,0,.2,1);--default-font-family:var(--font-sans);--default-mono-font-family:var(--font-mono)}}@layer base{*,:after,:before,::backdrop{box-sizing:border-box;border:0 solid;margin:0;padding:0}::file-selector-button{box-sizing:border-box;border:0 solid;margin:0;padding:0}html,:host{-webkit-text-size-adjust:100%;tab-size:4;line-height:1.5;font-family:var(--default-font-family,ui-sans-serif,system-ui,sans-serif,"Apple Color Emoji","Segoe UI Emoji","Segoe UI Symbol","Noto Color Emoji");font-feature-settings:var(--default-font-feature-settings,normal);font-variation-settings:var(--default-font-variation-settings,normal);-webkit-tap-highlight-color:transparent}hr{height:0;color:inherit;border-top-width:1px}abbr:where([title]){-webkit-text-decoration:underline dotted;text-decoration:underline dotted}h1,h2,h3,h4,h5,h6{font-size:inherit;font-weight:inherit}a{color:inherit;-webkit-text-decoration:inherit;text-decoration:inherit}b,strong{font-weight:bolder}code,kbd,samp,pre{font-family:var(--default-mono-font-family,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,"Liberation Mono","Courier New",monospace);font-feature-settings:var(--default-mono-font-feature-settings,normal);font-variation-settings:var(--default-mono-font-variation-settings,normal);font-size:1em}small{font-size:80%}sub,sup{vertical-align:baseline;font-size:75%;line-height:0;position:relative}sub{bottom:-.25em}sup{top:-.5em}table{text-indent:0;border-color:inherit;border-collapse:collapse}:-moz-focusring{outline:auto}progress{vertical-align:baseline}summary{display:list-item}ol,ul,menu{list-style:none}img,svg,video,canvas,audio,iframe,embed,object{vertical-align:middle;display:block}img,video{max-width:100%;height:auto}button,input,select,optgroup,textarea{font:inherit;font-feature-settings:inherit;font-variation-settings:inherit;letter-spacing:inherit;color:inherit;opacity:1;background-color:#0000;border-radius:0}::file-selector-button{font:inherit;font-feature-settings:inherit;font-variation-settings:inherit;letter-spacing:inherit;color:inherit;opacity:1;background-color:#0000;border-radius:0}:where(select:is([multiple],[size])) optgroup{font-weight:bolder}:where(select:is([multiple],[size])) optgroup option{padding-inline-start:20px}::file-selector-button{margin-inline-end:4px}::placeholder{opacity:1}@supports (not ((-webkit-appearance:-apple-pay-button))) or (contain-intrinsic-size:1px){::placeholder{color:currentColor}@supports (color:color-mix(in lab,red,red)){::placeholder{color:color-mix(in oklab,currentcolor 50%,transparent)}}}textarea{resize:vertical}::-webkit-search-decoration{-webkit-appearance:none}::-webkit-date-and-time-value{min-height:1lh;text-align:inherit}::-webkit-datetime-edit{display:inline-flex}::-webkit-datetime-edit-fields-wrapper{padding:0}::-webkit-datetime-edit{padding-block:0}::-webkit-datetime-edit-year-field{padding-block:0}::-webkit-datetime-edit-month-field{padding-block:0}::-webkit-datetime-edit-day-field{padding-block:0}::-webkit-datetime-edit-hour-field{padding-block:0}::-webkit-datetime-edit-minute-field{padding-block:0}::-webkit-datetime-edit-second-field{padding-block:0}::-webkit-datetime-edit-millisecond-field{padding-block:0}::-webkit-datetime-edit-meridiem-field{padding-block:0}::-webkit-calendar-picker-indicator{line-height:1}:-moz-ui-invalid{box-shadow:none}button,input:where([type=button],[type=reset],[type=submit]){appearance:button}::file-selector-button{appearance:button}::-webkit-inner-spin-button{height:auto}::-webkit-outer-spin-button{height:auto}[hidden]:where(:not([hidden=until-found])){display:none!important}}@layer components;@layer utilities{.visible{visibility:visible}.fixed{position:fixed}.block{display:block}.flex{display:flex}.inline{display:inline}.flex-shrink{flex-shrink:1}.transform{transform:var(--tw-rotate-x,)var(--tw-rotate-y,)var(--tw-rotate-z,)var(--tw-skew-x,)var(--tw-skew-y,)}.border{border-style:var(--tw-border-style);border-width:1px}.outline{outline-style:var(--tw-outline-style);outline-width:1px}.transition{transition-property:color,background-color,border-color,outline-color,text-decoration-color,fill,stroke,--tw-gradient-from,--tw-gradient-via,--tw-gradient-to,opacity,box-shadow,transform,translate,scale,rotate,filter,-webkit-backdrop-filter,backdrop-filter,display,content-visibility,overlay,pointer-events;transition-timing-function:var(--tw-ease,var(--default-transition-timing-function));transition-duration:var(--tw-duration,var(--default-transition-duration))}}:host{--anam-background:#fff;--anam-text:#18181b;--anam-trigger-size:80px;--anam-sheet-width:400px;--anam-sheet-height:640px;all:initial;color:var(--anam-text);-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;font-family:DM Sans,system-ui,-apple-system,sans-serif;font-size:15px;line-height:1.5}@media(max-width:640px){:host{--anam-trigger-size:72px;--anam-sheet-width: calc(100vw - 24px) ;--anam-sheet-height: calc(100dvh - 100px) }}.anam-widget{z-index:9999;font-family:inherit}.anam-widget[data-inline=false]{position:fixed}.anam-widget[data-inline=true]{position:relative}.anam-trigger{width:var(--anam-trigger-size);height:var(--anam-trigger-size);cursor:pointer;background:0 0;border:none;border-radius:50%;justify-content:center;align-items:center;padding:0;transition:all .25s cubic-bezier(.4,0,.2,1);display:flex;overflow:hidden;box-shadow:0 2px 8px #00000014,0 8px 24px -4px #0000002e}.anam-trigger:hover{transform:scale(1.06);box-shadow:0 4px 12px #0000001a,0 12px 32px -4px #00000040}.anam-trigger:active{transform:scale(.97)}.anam-trigger img{object-fit:cover;width:100%;height:100%;display:block}.anam-sheet{width:var(--anam-sheet-width);aspect-ratio:16/10;max-height:var(--anam-sheet-height);border-radius:8px;animation:.25s cubic-bezier(.16,1,.3,1) sheetIn;position:relative;overflow:hidden;box-shadow:0 32px 64px -16px #00000040,0 0 0 1px #00000014}.anam-widget[data-inline=true][data-layout=expanded] .anam-sheet{aspect-ratio:3/2;border-radius:8px;width:100%;max-height:none;animation:none}@keyframes sheetIn{0%{opacity:0;transform:translateY(8px)scale(.97)}to{opacity:1;transform:translateY(0)scale(1)}}.anam-video{object-fit:cover;background:#000;width:100%;height:100%;display:block;position:absolute;inset:0}.anam-video[data-hidden=true]{visibility:hidden}.anam-overlay-idle{z-index:2;position:absolute;inset:0}.anam-overlay-idle img{object-fit:cover;width:100%;height:100%;display:block}.anam-cta-pill{-webkit-backdrop-filter:blur(16px);color:#fff;letter-spacing:-.01em;cursor:pointer;white-space:nowrap;background:#00000080;border:1px solid #ffffff1a;border-radius:999px;align-items:center;gap:10px;padding:12px 28px;font-family:inherit;font-size:15px;font-weight:500;transition:all .2s;display:flex;position:absolute;bottom:40px;left:50%;transform:translate(-50%)}.anam-cta-pill:hover{background:#000000a6;transform:translate(-50%)scale(1.03)}.anam-cta-pill:active{transform:translate(-50%)scale(.98)}.anam-cta-pill svg{flex-shrink:0}.anam-overlay-unconfigured{z-index:2;background:#111;flex-direction:column;justify-content:center;align-items:center;gap:16px;display:flex;position:absolute;inset:0}.anam-overlay-unconfigured span{color:#ffffff59;letter-spacing:-.01em;font-size:14px;font-weight:400}.anam-overlay-loading{z-index:3;background:#000;flex-direction:column;justify-content:center;align-items:center;gap:20px;display:flex;position:absolute;inset:0}.anam-overlay-loading span{color:#fffc;letter-spacing:-.01em;font-size:15px;font-weight:400}.anam-overlay-error{z-index:3;background:#000;flex-direction:column;justify-content:center;align-items:center;gap:16px;display:flex;position:absolute;inset:0}.anam-overlay-error-text{color:#fff9;text-align:center;max-width:260px;font-size:14px;line-height:1.5}.anam-overlay-error .anam-retry-btn{-webkit-backdrop-filter:blur(8px);color:#fff;cursor:pointer;background:#ffffff1f;border:1px solid #ffffff1a;border-radius:999px;padding:10px 24px;font-family:inherit;font-size:14px;font-weight:500;transition:background .15s}.anam-overlay-error .anam-retry-btn:hover{background:#fff3}.anam-spinner{border:2.5px solid #ffffff1f;border-top-color:#fff;border-radius:50%;width:32px;height:32px;animation:.75s linear infinite spin}@keyframes spin{to{transform:rotate(360deg)}}.anam-close-btn{z-index:10;-webkit-backdrop-filter:blur(8px);color:#fff;cursor:pointer;background:#00000073;border:1px solid #ffffff14;border-radius:50%;justify-content:center;align-items:center;width:32px;height:32px;padding:0;transition:background .15s;display:flex;position:absolute;top:12px;right:12px}.anam-close-btn:hover{background:#0009}.anam-toast{z-index:10;-webkit-backdrop-filter:blur(16px);color:#fff;letter-spacing:-.01em;white-space:nowrap;text-overflow:ellipsis;pointer-events:none;background:#0009;border:1px solid #ffffff0f;border-radius:999px;max-width:85%;padding:10px 22px;font-size:14px;font-weight:400;animation:.25s cubic-bezier(.16,1,.3,1) toastIn;position:absolute;bottom:80px;left:50%;overflow:hidden;transform:translate(-50%)}.anam-toast-out{animation:.4s forwards toastOut}@keyframes toastIn{0%{opacity:0;transform:translate(-50%)translateY(6px)}to{opacity:1;transform:translate(-50%)translateY(0)}}@keyframes toastOut{0%{opacity:1}to{opacity:0}}.anam-control-bar{z-index:10;background:linear-gradient(#0000,#00000040 40%,#0000008c);align-items:center;gap:8px;padding:48px 16px 16px;display:flex;position:absolute;bottom:0;left:0;right:0}.anam-ctl-btn{-webkit-backdrop-filter:blur(8px);color:#fff;cursor:pointer;background:#ffffff24;border:1px solid #ffffff0f;border-radius:50%;flex-shrink:0;justify-content:center;align-items:center;width:44px;height:44px;padding:0;transition:background .15s;display:flex}.anam-ctl-btn:hover{background:#ffffff38}.anam-ctl-btn:disabled{opacity:.35;cursor:not-allowed}.anam-ctl-btn-muted{background:#dc26268c;border-color:#dc262633}.anam-ctl-btn-muted:hover{background:#dc2626b3}.anam-ctl-end{background:#dc262699;border-color:#dc262626}.anam-ctl-end:hover{background:#dc2626cc}.anam-ctl-input{-webkit-backdrop-filter:blur(8px);color:#fff;background:#ffffff1a;border:1px solid #ffffff14;border-radius:999px;outline:none;flex:1;min-width:0;padding:11px 18px;font-family:inherit;font-size:14px;transition:background .15s,border-color .15s}.anam-ctl-input::placeholder{color:#fff6}.anam-ctl-input:focus{background:#ffffff26;border-color:#ffffff2e}.anam-ctl-input:disabled{opacity:.35;cursor:not-allowed}@property --tw-rotate-x{syntax:"*";inherits:false}@property --tw-rotate-y{syntax:"*";inherits:false}@property --tw-rotate-z{syntax:"*";inherits:false}@property --tw-skew-x{syntax:"*";inherits:false}@property --tw-skew-y{syntax:"*";inherits:false}@property --tw-border-style{syntax:"*";inherits:false;initial-value:solid}@property --tw-outline-style{syntax:"*";inherits:false;initial-value:solid}';
3599
+ const di = '@layer properties{@supports (((-webkit-hyphens:none)) and (not (margin-trim:inline))) or ((-moz-orient:inline) and (not (color:rgb(from red r g b)))){*,:before,:after,::backdrop{--tw-rotate-x:initial;--tw-rotate-y:initial;--tw-rotate-z:initial;--tw-skew-x:initial;--tw-skew-y:initial;--tw-border-style:solid;--tw-outline-style:solid}}}@layer theme{:root,:host{--font-sans:ui-sans-serif,system-ui,sans-serif,"Apple Color Emoji","Segoe UI Emoji","Segoe UI Symbol","Noto Color Emoji";--font-mono:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,"Liberation Mono","Courier New",monospace;--default-transition-duration:.15s;--default-transition-timing-function:cubic-bezier(.4,0,.2,1);--default-font-family:var(--font-sans);--default-mono-font-family:var(--font-mono)}}@layer base{*,:after,:before,::backdrop{box-sizing:border-box;border:0 solid;margin:0;padding:0}::file-selector-button{box-sizing:border-box;border:0 solid;margin:0;padding:0}html,:host{-webkit-text-size-adjust:100%;tab-size:4;line-height:1.5;font-family:var(--default-font-family,ui-sans-serif,system-ui,sans-serif,"Apple Color Emoji","Segoe UI Emoji","Segoe UI Symbol","Noto Color Emoji");font-feature-settings:var(--default-font-feature-settings,normal);font-variation-settings:var(--default-font-variation-settings,normal);-webkit-tap-highlight-color:transparent}hr{height:0;color:inherit;border-top-width:1px}abbr:where([title]){-webkit-text-decoration:underline dotted;text-decoration:underline dotted}h1,h2,h3,h4,h5,h6{font-size:inherit;font-weight:inherit}a{color:inherit;-webkit-text-decoration:inherit;text-decoration:inherit}b,strong{font-weight:bolder}code,kbd,samp,pre{font-family:var(--default-mono-font-family,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,"Liberation Mono","Courier New",monospace);font-feature-settings:var(--default-mono-font-feature-settings,normal);font-variation-settings:var(--default-mono-font-variation-settings,normal);font-size:1em}small{font-size:80%}sub,sup{vertical-align:baseline;font-size:75%;line-height:0;position:relative}sub{bottom:-.25em}sup{top:-.5em}table{text-indent:0;border-color:inherit;border-collapse:collapse}:-moz-focusring{outline:auto}progress{vertical-align:baseline}summary{display:list-item}ol,ul,menu{list-style:none}img,svg,video,canvas,audio,iframe,embed,object{vertical-align:middle;display:block}img,video{max-width:100%;height:auto}button,input,select,optgroup,textarea{font:inherit;font-feature-settings:inherit;font-variation-settings:inherit;letter-spacing:inherit;color:inherit;opacity:1;background-color:#0000;border-radius:0}::file-selector-button{font:inherit;font-feature-settings:inherit;font-variation-settings:inherit;letter-spacing:inherit;color:inherit;opacity:1;background-color:#0000;border-radius:0}:where(select:is([multiple],[size])) optgroup{font-weight:bolder}:where(select:is([multiple],[size])) optgroup option{padding-inline-start:20px}::file-selector-button{margin-inline-end:4px}::placeholder{opacity:1}@supports (not ((-webkit-appearance:-apple-pay-button))) or (contain-intrinsic-size:1px){::placeholder{color:currentColor}@supports (color:color-mix(in lab,red,red)){::placeholder{color:color-mix(in oklab,currentcolor 50%,transparent)}}}textarea{resize:vertical}::-webkit-search-decoration{-webkit-appearance:none}::-webkit-date-and-time-value{min-height:1lh;text-align:inherit}::-webkit-datetime-edit{display:inline-flex}::-webkit-datetime-edit-fields-wrapper{padding:0}::-webkit-datetime-edit{padding-block:0}::-webkit-datetime-edit-year-field{padding-block:0}::-webkit-datetime-edit-month-field{padding-block:0}::-webkit-datetime-edit-day-field{padding-block:0}::-webkit-datetime-edit-hour-field{padding-block:0}::-webkit-datetime-edit-minute-field{padding-block:0}::-webkit-datetime-edit-second-field{padding-block:0}::-webkit-datetime-edit-millisecond-field{padding-block:0}::-webkit-datetime-edit-meridiem-field{padding-block:0}::-webkit-calendar-picker-indicator{line-height:1}:-moz-ui-invalid{box-shadow:none}button,input:where([type=button],[type=reset],[type=submit]){appearance:button}::file-selector-button{appearance:button}::-webkit-inner-spin-button{height:auto}::-webkit-outer-spin-button{height:auto}[hidden]:where(:not([hidden=until-found])){display:none!important}}@layer components;@layer utilities{.visible{visibility:visible}.fixed{position:fixed}.block{display:block}.flex{display:flex}.inline{display:inline}.flex-shrink{flex-shrink:1}.transform{transform:var(--tw-rotate-x,)var(--tw-rotate-y,)var(--tw-rotate-z,)var(--tw-skew-x,)var(--tw-skew-y,)}.border{border-style:var(--tw-border-style);border-width:1px}.outline{outline-style:var(--tw-outline-style);outline-width:1px}.transition{transition-property:color,background-color,border-color,outline-color,text-decoration-color,fill,stroke,--tw-gradient-from,--tw-gradient-via,--tw-gradient-to,opacity,box-shadow,transform,translate,scale,rotate,filter,-webkit-backdrop-filter,backdrop-filter,display,content-visibility,overlay,pointer-events;transition-timing-function:var(--tw-ease,var(--default-transition-timing-function));transition-duration:var(--tw-duration,var(--default-transition-duration))}}:host{--anam-trigger-size:80px;--anam-sheet-width:400px;--anam-sheet-height:640px;all:initial;color:#18181b;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;font-family:DM Sans,system-ui,-apple-system,sans-serif;font-size:15px;line-height:1.5}@media(max-width:640px){:host{--anam-trigger-size:72px;--anam-sheet-width: calc(100vw - 24px) ;--anam-sheet-height: calc(100dvh - 100px) }}.anam-widget{z-index:9999;font-family:inherit}.anam-widget[data-inline=false]{position:fixed}.anam-widget[data-inline=true]{position:relative}.anam-trigger{width:var(--anam-trigger-size);height:var(--anam-trigger-size);cursor:pointer;background:0 0;border:none;border-radius:50%;justify-content:center;align-items:center;padding:0;transition:all .25s cubic-bezier(.4,0,.2,1);display:flex;overflow:hidden;box-shadow:0 2px 8px #00000014,0 8px 24px -4px #0000002e}.anam-trigger:hover{transform:scale(1.06);box-shadow:0 4px 12px #0000001a,0 12px 32px -4px #00000040}.anam-trigger:active{transform:scale(.97)}.anam-trigger img{object-fit:cover;width:100%;height:100%;display:block}.anam-sheet{width:var(--anam-sheet-width);aspect-ratio:16/10;max-height:var(--anam-sheet-height);border-radius:8px;animation:.25s cubic-bezier(.16,1,.3,1) sheetIn;position:relative;overflow:hidden;box-shadow:0 32px 64px -16px #00000040,0 0 0 1px #00000014}.anam-widget[data-inline=true][data-layout=expanded] .anam-sheet{aspect-ratio:3/2;border-radius:8px;width:100%;max-height:none;animation:none}@keyframes sheetIn{0%{opacity:0;transform:translateY(8px)scale(.97)}to{opacity:1;transform:translateY(0)scale(1)}}.anam-video{object-fit:cover;background:#000;width:100%;height:100%;display:block;position:absolute;inset:0}.anam-video[data-hidden=true]{visibility:hidden}.anam-overlay-idle{z-index:2;position:absolute;inset:0}.anam-overlay-idle img{object-fit:cover;width:100%;height:100%;display:block}.anam-cta-pill{-webkit-backdrop-filter:blur(8px);color:#fff;letter-spacing:-.01em;cursor:pointer;white-space:nowrap;background:#ffffff24;border:1px solid #ffffff38;border-radius:999px;align-items:center;gap:12px;min-width:200px;padding:12px 26px;font-family:inherit;font-size:16px;font-weight:600;transition:all .2s;display:flex;position:absolute;bottom:20px;left:50%;transform:translate(-50%)}.anam-cta-pill:hover{background:#ffffff38;transform:translate(-50%)scale(1.03)}.anam-cta-pill:active{transform:translate(-50%)scale(.98)}.anam-cta-pill svg{flex-shrink:0}.anam-overlay-unconfigured{z-index:2;background:#111;flex-direction:column;justify-content:center;align-items:center;gap:16px;display:flex;position:absolute;inset:0}.anam-overlay-unconfigured span{color:#ffffff59;letter-spacing:-.01em;font-size:14px;font-weight:400}.anam-overlay-loading{z-index:3;background:#000;flex-direction:column;justify-content:center;align-items:center;gap:20px;display:flex;position:absolute;inset:0}.anam-overlay-loading span{color:#fffc;letter-spacing:-.01em;font-size:15px;font-weight:400}.anam-overlay-error{z-index:3;background:#000;flex-direction:column;justify-content:center;align-items:center;gap:16px;display:flex;position:absolute;inset:0}.anam-overlay-error-text{color:#fff9;text-align:center;max-width:260px;font-size:14px;line-height:1.5}.anam-overlay-error .anam-retry-btn{-webkit-backdrop-filter:blur(8px);color:#fff;cursor:pointer;background:#ffffff1f;border:1px solid #ffffff1a;border-radius:999px;padding:10px 24px;font-family:inherit;font-size:14px;font-weight:500;transition:background .15s}.anam-overlay-error .anam-retry-btn:hover{background:#fff3}.anam-spinner{border:2.5px solid #ffffff1f;border-top-color:#fff;border-radius:50%;width:32px;height:32px;animation:.75s linear infinite spin}@keyframes spin{to{transform:rotate(360deg)}}.anam-close-btn{z-index:10;-webkit-backdrop-filter:blur(8px);color:#fff;cursor:pointer;background:#00000073;border:1px solid #ffffff38;border-radius:50%;justify-content:center;align-items:center;width:44px;height:44px;padding:0;transition:background .15s;display:flex;position:absolute;top:12px;right:12px}.anam-close-btn:hover{background:#0009}.anam-toast{z-index:10;-webkit-backdrop-filter:blur(16px);color:#fff;letter-spacing:-.01em;white-space:nowrap;text-overflow:ellipsis;pointer-events:none;background:#0009;border:1px solid #ffffff0f;border-radius:999px;max-width:85%;padding:10px 22px;font-size:14px;font-weight:400;animation:.25s cubic-bezier(.16,1,.3,1) toastIn;position:absolute;bottom:80px;left:50%;overflow:hidden;transform:translate(-50%)}.anam-toast-out{animation:.4s forwards toastOut}@keyframes toastIn{0%{opacity:0;transform:translate(-50%)translateY(6px)}to{opacity:1;transform:translate(-50%)translateY(0)}}@keyframes toastOut{0%{opacity:1}to{opacity:0}}.anam-control-bar{z-index:10;background:linear-gradient(#0000,#00000040 40%,#0000008c);justify-content:center;align-items:center;gap:8px;padding:48px 16px 16px;display:flex;position:absolute;bottom:0;left:0;right:0}.anam-ctl-btn{-webkit-backdrop-filter:blur(8px);color:#fff;cursor:pointer;background:#ffffff24;border:1px solid #ffffff38;border-radius:50%;flex-shrink:0;justify-content:center;align-items:center;width:44px;height:44px;padding:0;transition:background .15s;display:flex}.anam-ctl-btn:hover{background:#ffffff38}.anam-ctl-btn:disabled{opacity:.35;cursor:not-allowed}.anam-ctl-input-wrap{flex:1;align-items:center;min-width:0;margin-right:56px;display:flex;position:relative}.anam-ctl-input{-webkit-backdrop-filter:blur(8px);color:#fff;background:#ffffff1a;border:1px solid #ffffff38;border-radius:999px;outline:none;width:100%;padding:11px 44px 11px 18px;font-family:inherit;font-size:14px;transition:background .15s,border-color .15s}.anam-ctl-input::placeholder{color:#fff6}.anam-ctl-input:focus{background:#ffffff26;border-color:#ffffff2e}.anam-ctl-input:disabled{opacity:.35;cursor:not-allowed}.anam-ctl-send{color:#ffffff80;cursor:pointer;background:0 0;border:none;border-radius:50%;justify-content:center;align-items:center;width:32px;height:32px;padding:0;transition:color .15s;display:flex;position:absolute;right:6px}.anam-ctl-send:hover{color:#fff}.anam-ctl-send:disabled{opacity:.35;cursor:not-allowed}.anam-watermark{z-index:11;opacity:.5;line-height:0;text-decoration:none;transition:opacity .15s;position:absolute;top:16px;left:16px}.anam-watermark:hover{opacity:.8}@property --tw-rotate-x{syntax:"*";inherits:false}@property --tw-rotate-y{syntax:"*";inherits:false}@property --tw-rotate-z{syntax:"*";inherits:false}@property --tw-skew-x{syntax:"*";inherits:false}@property --tw-skew-y{syntax:"*";inherits:false}@property --tw-border-style{syntax:"*";inherits:false;initial-value:solid}@property --tw-outline-style{syntax:"*";inherits:false;initial-value:solid}';
3614
3600
  function wt(t, e) {
3615
3601
  const n = { ...t };
3616
3602
  for (const o of Object.keys(e)) {
3617
- const u = e[o];
3618
- u !== void 0 && (u !== null && typeof u == "object" && !Array.isArray(u) && typeof n[o] == "object" && n[o] !== null && !Array.isArray(n[o]) ? n[o] = wt(n[o], u) : n[o] = u);
3603
+ const c = e[o];
3604
+ c !== void 0 && (c !== null && typeof c == "object" && !Array.isArray(c) && typeof n[o] == "object" && n[o] !== null && !Array.isArray(n[o]) ? n[o] = wt(n[o], c) : n[o] = c);
3619
3605
  }
3620
3606
  return n;
3621
3607
  }
@@ -3628,12 +3614,12 @@ function yr(t) {
3628
3614
  n !== void 0 && (e.inline = n), t.layout && (e.layout = t.layout), t.position && (e.position = t.position);
3629
3615
  const o = ze(t["ui-mute-button"]);
3630
3616
  o !== void 0 && (e.showMuteButton = o);
3631
- const u = ze(t["ui-text-input"]);
3632
- u !== void 0 && (e.showTextInput = u);
3617
+ const c = ze(t["ui-text-input"]);
3618
+ c !== void 0 && (e.showTextInput = c);
3633
3619
  const a = ze(t["ui-captions"]);
3634
- return a !== void 0 && (e.showCaptions = a), e;
3620
+ return a !== void 0 && (e.showCaptions = a), t["call-to-action"] && (e.callToAction = t["call-to-action"]), e;
3635
3621
  }
3636
- const Sr = () => /* @__PURE__ */ w("svg", { width: "16", height: "16", viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", "stroke-width": "2.5", "stroke-linecap": "round", children: /* @__PURE__ */ w("path", { d: "M18 6L6 18M6 6l12 12" }) }), wr = () => /* @__PURE__ */ w("svg", { width: "16", height: "16", viewBox: "0 0 24 24", fill: "currentColor", children: /* @__PURE__ */ w("path", { d: "M8 5.14v13.72a1 1 0 0 0 1.5.86l11.04-6.86a1 1 0 0 0 0-1.72L9.5 4.28A1 1 0 0 0 8 5.14Z" }) }), Cr = () => /* @__PURE__ */ w("svg", { width: "20", height: "20", viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", "stroke-width": "2", "stroke-linecap": "round", children: [
3622
+ const Sr = () => /* @__PURE__ */ w("svg", { width: "20", height: "20", viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", "stroke-width": "2.5", "stroke-linecap": "round", children: /* @__PURE__ */ w("path", { d: "M18 6L6 18M6 6l12 12" }) }), wr = () => /* @__PURE__ */ w("svg", { width: "24", height: "24", viewBox: "0 0 24 24", fill: "currentColor", children: /* @__PURE__ */ w("path", { d: "M8 5.14v13.72a1 1 0 0 0 1.5.86l11.04-6.86a1 1 0 0 0 0-1.72L9.5 4.28A1 1 0 0 0 8 5.14Z" }) }), Cr = () => /* @__PURE__ */ w("svg", { width: "20", height: "20", viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", "stroke-width": "2", "stroke-linecap": "round", children: [
3637
3623
  /* @__PURE__ */ w("path", { d: "M12 2a3 3 0 0 0-3 3v7a3 3 0 0 0 6 0V5a3 3 0 0 0-3-3Z" }),
3638
3624
  /* @__PURE__ */ w("path", { d: "M19 10v2a7 7 0 0 1-14 0v-2" }),
3639
3625
  /* @__PURE__ */ w("line", { x1: "12", y1: "19", x2: "12", y2: "22" })
@@ -3645,36 +3631,33 @@ const Sr = () => /* @__PURE__ */ w("svg", { width: "16", height: "16", viewBox:
3645
3631
  ] }), br = () => /* @__PURE__ */ w("svg", { width: "18", height: "18", viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", "stroke-width": "2", "stroke-linecap": "round", children: [
3646
3632
  /* @__PURE__ */ w("line", { x1: "22", y1: "2", x2: "11", y2: "13" }),
3647
3633
  /* @__PURE__ */ w("polygon", { points: "22 2 15 22 11 13 2 9 22 2" })
3648
- ] }), Ar = () => /* @__PURE__ */ w("svg", { width: "18", height: "18", viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", "stroke-width": "2", "stroke-linecap": "round", children: [
3649
- /* @__PURE__ */ w("path", { d: "M10.68 13.31a16 16 0 0 0 3.41 2.6l1.27-1.27a2 2 0 0 1 2.11-.45 12.84 12.84 0 0 0 2.81.7 2 2 0 0 1 1.72 2v3a2 2 0 0 1-2.18 2 19.79 19.79 0 0 1-8.63-3.07 19.5 19.5 0 0 1-6-6 19.79 19.79 0 0 1-3.07-8.67A2 2 0 0 1 4.11 2h3a2 2 0 0 1 2 1.72 12.84 12.84 0 0 0 .7 2.81 2 2 0 0 1-.45 2.11L8.09 9.91a16 16 0 0 0 2.59 3.4z" }),
3650
- /* @__PURE__ */ w("line", { x1: "1", y1: "1", x2: "23", y2: "23" })
3651
3634
  ] }), Ct = () => /* @__PURE__ */ w("svg", { width: "48", height: "48", viewBox: "0 0 48 48", fill: "none", style: { opacity: 0.3 }, children: [
3652
3635
  /* @__PURE__ */ w("circle", { cx: "24", cy: "18", r: "8", stroke: "white", "stroke-width": "2", fill: "none" }),
3653
3636
  /* @__PURE__ */ w("path", { d: "M8 42c0-8.837 7.163-16 16-16s16 7.163 16 16", stroke: "white", "stroke-width": "2", fill: "none" })
3654
3637
  ] });
3655
- function Tr({
3638
+ function Ar({
3656
3639
  config: t,
3657
3640
  session: e,
3658
3641
  videoRef: n,
3659
3642
  avatarSrc: o,
3660
- displayCta: u,
3643
+ displayCta: c,
3661
3644
  onCollapse: a
3662
3645
  }) {
3663
- const c = Ze(null), [l, m] = qe(""), [p, _] = qe(null), [d, S] = qe(!1), g = Ze(null), y = e.connectionStatus.value === "connected", b = e.connectionStatus.value === "connecting", A = e.connectionStatus.value === "error", C = e.isStreaming.value, I = !b && !y && !A, x = je(async () => {
3646
+ const u = Ze(null), [l, m] = qe(""), [p, _] = qe(null), [d, y] = qe(!1), g = Ze(null), S = e.connectionStatus.value === "connected", C = e.connectionStatus.value === "connecting", A = e.connectionStatus.value === "error", I = e.isStreaming.value, b = !C && !S && !A, T = je(async () => {
3664
3647
  n.current && await e.startSession(n.current);
3665
- }, [e.startSession]), O = je(async () => {
3648
+ }, [e.startSession]), D = je(async () => {
3666
3649
  await e.stopSession();
3667
- }, [e.stopSession]), T = je(() => {
3650
+ }, [e.stopSession]), x = je(() => {
3668
3651
  if (!l.trim()) return;
3669
3652
  const H = l.trim();
3670
- e.sendMessage(H), m(""), c.current?.focus(), g.current && clearTimeout(g.current), S(!1), _(H), g.current = window.setTimeout(() => {
3671
- S(!0), g.current = window.setTimeout(() => {
3672
- _(null), S(!1);
3653
+ e.sendMessage(H), m(""), u.current?.focus(), g.current && clearTimeout(g.current), y(!1), _(H), g.current = window.setTimeout(() => {
3654
+ y(!0), g.current = window.setTimeout(() => {
3655
+ _(null), y(!1);
3673
3656
  }, 400);
3674
3657
  }, 2600);
3675
- }, [l]), q = je((H) => {
3676
- H.key === "Enter" && !H.shiftKey && (H.preventDefault(), T());
3677
- }, [T]);
3658
+ }, [l]), Z = je((H) => {
3659
+ H.key === "Enter" && !H.shiftKey && (H.preventDefault(), x());
3660
+ }, [x]);
3678
3661
  return gt(() => () => {
3679
3662
  g.current && clearTimeout(g.current);
3680
3663
  }, []), /* @__PURE__ */ w("div", { class: "anam-sheet", children: [
@@ -3685,16 +3668,16 @@ function Tr({
3685
3668
  class: "anam-video",
3686
3669
  autoplay: !0,
3687
3670
  playsinline: !0,
3688
- "data-hidden": C ? void 0 : "true"
3671
+ "data-hidden": I ? void 0 : "true"
3689
3672
  }
3690
3673
  ),
3691
- I && (e.isConfigured.value ? (
3674
+ b && (e.isConfigured.value ? (
3692
3675
  /* Has agent-id: show avatar or placeholder + CTA pill */
3693
3676
  /* @__PURE__ */ w("div", { class: "anam-overlay-idle", children: [
3694
3677
  o ? /* @__PURE__ */ w("img", { src: o, alt: "Avatar" }) : /* @__PURE__ */ w(Ct, {}),
3695
- /* @__PURE__ */ w("button", { class: "anam-cta-pill", onClick: x, children: [
3678
+ /* @__PURE__ */ w("button", { class: "anam-cta-pill", onClick: T, children: [
3696
3679
  /* @__PURE__ */ w(wr, {}),
3697
- u
3680
+ c
3698
3681
  ] })
3699
3682
  ] })
3700
3683
  ) : (
@@ -3704,16 +3687,24 @@ function Tr({
3704
3687
  /* @__PURE__ */ w("span", { children: "Agent not configured" })
3705
3688
  ] })
3706
3689
  )),
3707
- b && /* @__PURE__ */ w("div", { class: "anam-overlay-loading", children: [
3690
+ C && /* @__PURE__ */ w("div", { class: "anam-overlay-loading", children: [
3708
3691
  /* @__PURE__ */ w("span", { class: "anam-spinner" }),
3709
3692
  /* @__PURE__ */ w("span", { children: "Starting your conversation..." })
3710
3693
  ] }),
3711
3694
  A && /* @__PURE__ */ w("div", { class: "anam-overlay-error", children: [
3712
3695
  /* @__PURE__ */ w("div", { class: "anam-overlay-error-text", children: e.error.value || "Something went wrong" }),
3713
- /* @__PURE__ */ w("button", { class: "anam-retry-btn", onClick: x, children: "Try Again" })
3696
+ /* @__PURE__ */ w("button", { class: "anam-retry-btn", onClick: T, children: "Try Again" })
3714
3697
  ] }),
3715
- (y || C) && /* @__PURE__ */ w(oe, { children: [
3716
- a && /* @__PURE__ */ w("button", { class: "anam-close-btn", onClick: a, "aria-label": "Close", children: /* @__PURE__ */ w(Sr, {}) }),
3698
+ (S || I) && /* @__PURE__ */ w(_e, { children: [
3699
+ /* @__PURE__ */ w(
3700
+ "button",
3701
+ {
3702
+ class: "anam-close-btn",
3703
+ onClick: a ?? D,
3704
+ "aria-label": "End call",
3705
+ children: /* @__PURE__ */ w(Sr, {})
3706
+ }
3707
+ ),
3717
3708
  p && /* @__PURE__ */ w("div", { class: `anam-toast ${d ? "anam-toast-out" : ""}`, children: p }),
3718
3709
  /* @__PURE__ */ w("div", { class: "anam-control-bar", children: [
3719
3710
  t.showMuteButton && /* @__PURE__ */ w(
@@ -3725,103 +3716,106 @@ function Tr({
3725
3716
  children: e.isMuted.value ? /* @__PURE__ */ w(Ir, {}) : /* @__PURE__ */ w(Cr, {})
3726
3717
  }
3727
3718
  ),
3728
- t.showTextInput && /* @__PURE__ */ w(oe, { children: [
3719
+ t.showTextInput && /* @__PURE__ */ w("div", { class: "anam-ctl-input-wrap", children: [
3729
3720
  /* @__PURE__ */ w(
3730
3721
  "input",
3731
3722
  {
3732
- ref: c,
3723
+ ref: u,
3733
3724
  type: "text",
3734
3725
  class: "anam-ctl-input",
3735
- placeholder: t.textContents.placeholder,
3726
+ placeholder: "Type a message...",
3736
3727
  value: l,
3737
3728
  onInput: (H) => m(H.target.value),
3738
- onKeyDown: q,
3739
- disabled: !y
3729
+ onKeyDown: Z,
3730
+ disabled: !S
3740
3731
  }
3741
3732
  ),
3742
3733
  /* @__PURE__ */ w(
3743
3734
  "button",
3744
3735
  {
3745
- class: "anam-ctl-btn",
3746
- onClick: T,
3747
- disabled: !y || !l.trim(),
3736
+ class: "anam-ctl-send",
3737
+ onClick: x,
3738
+ disabled: !S || !l.trim(),
3748
3739
  "aria-label": "Send message",
3749
3740
  children: /* @__PURE__ */ w(br, {})
3750
3741
  }
3751
3742
  )
3752
- ] }),
3753
- /* @__PURE__ */ w(
3754
- "button",
3755
- {
3756
- class: "anam-ctl-btn anam-ctl-end",
3757
- onClick: O,
3758
- "aria-label": "End call",
3759
- children: /* @__PURE__ */ w(Ar, {})
3760
- }
3761
- )
3743
+ ] })
3762
3744
  ] })
3763
- ] })
3745
+ ] }),
3746
+ /* @__PURE__ */ w(
3747
+ "a",
3748
+ {
3749
+ class: "anam-watermark",
3750
+ href: "https://anam.ai",
3751
+ target: "_blank",
3752
+ rel: "noopener noreferrer",
3753
+ children: /* @__PURE__ */ w("svg", { width: "48", height: "16", viewBox: "0 0 86 29", fill: "white", xmlns: "http://www.w3.org/2000/svg", children: [
3754
+ /* @__PURE__ */ w("path", { d: "M18.1491 28.1986L16.2127 21.63L6.3408 21.63L4.40439 28.1986H0L9.03659 -1.79687L13.4789 -1.79687L22.5535 28.1986H18.1491ZM7.47986 17.8331L15.0736 17.8331L11.2767 4.96161L7.47986 17.8331Z" }),
3755
+ /* @__PURE__ */ w("path", { d: "M24.7666 28.1984L24.7666 7.69518L39.5745 7.69518V28.1984L35.3979 28.1984V11.4921L28.9432 11.4921L28.9432 28.1984H24.7666Z" }),
3756
+ /* @__PURE__ */ w("path", { d: "M61.0239 28.1984V7.69518L85.7037 7.69518V28.1984H81.5271V11.4921L75.4521 11.4921V28.1984L71.2755 28.1984V11.4921L65.2005 11.4921V28.1984H61.0239Z" }),
3757
+ /* @__PURE__ */ w("path", { d: "M42.8948 7.69518L57.7026 7.69518V28.1984L53.5261 28.1984V27.1353C52.4629 28.0466 51.0201 28.5781 49.3495 28.5781C45.4007 28.5781 42.8948 25.7305 42.8948 21.2501C42.8948 16.8457 45.4007 14.074 49.3495 14.074C51.0201 14.074 52.4629 14.5676 53.5261 15.4788V11.3022L42.8948 11.3022V7.69518ZM50.4885 24.7812C52.6148 24.7812 53.9437 23.4143 53.9057 21.2501C53.8678 19.0859 52.5389 17.681 50.4885 17.681C48.4003 17.681 47.0713 19.0859 47.0713 21.2501C47.0713 23.4143 48.4003 24.7812 50.4885 24.7812Z" })
3758
+ ] })
3759
+ }
3760
+ )
3764
3761
  ] });
3765
3762
  }
3766
- function Rr(t) {
3767
- const e = Ze(null), n = Vi(!1);
3763
+ function Tr(t) {
3764
+ const e = Ze(null), n = Gi(!1);
3768
3765
  t["agent-id"] && t["session-token"] && console.warn("[AnamWidget] Both agent-id and session-token are set. Use one or the other. Ignoring agent-id.");
3769
- const o = t["session-token"] ? void 0 : t["agent-id"], u = vr(o, t["api-base-url"], t["session-token"]), a = me(
3766
+ const o = t["session-token"] ? void 0 : t["agent-id"], c = vr(o, t["api-base-url"], t["session-token"]), a = Ie(
3770
3767
  () => yr(t),
3771
- [t.inline, t.layout, t.position, t["ui-mute-button"], t["ui-text-input"], t["ui-captions"]]
3772
- ), c = me(() => {
3773
- const O = u.serverConfig.value, T = wt(wt({ ...ri }, O ?? {}), a);
3768
+ [t.inline, t.layout, t.position, t["ui-mute-button"], t["ui-text-input"], t["ui-captions"], t["call-to-action"]]
3769
+ ), u = Ie(() => {
3770
+ const b = c.serverConfig.value, T = wt(wt({ ...ri }, b ?? {}), a);
3774
3771
  return T.layout === "orb" && (T.inline = !1), T;
3775
- }, [u.serverConfig.value, a]);
3772
+ }, [c.serverConfig.value, a]);
3776
3773
  gt(() => {
3777
- u.fetchWidgetConfig();
3774
+ c.fetchWidgetConfig();
3778
3775
  }, [o, t["api-base-url"], t["session-token"]]);
3779
- const l = t["avatar-url"] || u.avatarThumbnailUrl.value || null, p = t["agent-name"] || u.personaName.value, _ = c.textContents.callToAction === ri.textContents.callToAction && p ? `Talk to ${p}` : c.textContents.callToAction, d = me(
3780
- () => `--anam-background: ${c.styles.backgroundColor}; --anam-text: ${c.styles.textColor};`,
3781
- [c.styles.backgroundColor, c.styles.textColor]
3782
- ), S = me(() => {
3783
- if (c.inline) return "";
3784
- const O = On(c.position);
3785
- return Object.entries(O).map(([T, q]) => `${T}: ${q}`).join("; ");
3786
- }, [c.inline, c.position]), g = [d, S].filter(Boolean).join("; "), y = Ze(!1), b = () => {
3776
+ const l = t["avatar-url"] || c.avatarThumbnailUrl.value || null, p = t["agent-name"] || c.personaName.value, _ = u.callToAction === ri.callToAction && p ? `Talk to ${p}` : u.callToAction, d = Ie(() => {
3777
+ if (u.inline) return "";
3778
+ const b = On(u.position);
3779
+ return Object.entries(b).map(([T, D]) => `${T}: ${D}`).join("; ");
3780
+ }, [u.inline, u.position]), y = Ze(!1), g = () => {
3787
3781
  n.value = !0, y.current = !1, setTimeout(() => {
3788
- e.current && u.startSession(e.current);
3782
+ e.current && c.startSession(e.current);
3789
3783
  }, 50);
3790
- }, A = async () => {
3791
- u.connectionStatus.value !== "idle" && await u.stopSession(), y.current = !1, n.value = !1;
3792
- }, C = c.layout === "orb", I = u.connectionStatus.value;
3793
- (I === "connecting" || I === "connected") && (y.current = !0), gt(() => {
3794
- C && n.value && I === "idle" && y.current && (y.current = !1, n.value = !1);
3795
- }, [I]);
3796
- const x = C ? n.value : !0;
3797
- return u.isReady.value ? /* @__PURE__ */ w(oe, { children: [
3784
+ }, S = async () => {
3785
+ c.connectionStatus.value !== "idle" && await c.stopSession(), y.current = !1, n.value = !1;
3786
+ }, C = u.layout === "orb", A = c.connectionStatus.value;
3787
+ (A === "connecting" || A === "connected") && (y.current = !0), gt(() => {
3788
+ C && n.value && A === "idle" && y.current && (y.current = !1, n.value = !1);
3789
+ }, [A]);
3790
+ const I = C ? n.value : !0;
3791
+ return c.isReady.value ? /* @__PURE__ */ w(_e, { children: [
3798
3792
  /* @__PURE__ */ w("style", { children: di }),
3799
3793
  /* @__PURE__ */ w(
3800
3794
  "div",
3801
3795
  {
3802
3796
  class: "anam-widget",
3803
- "data-inline": c.inline ? "true" : "false",
3804
- "data-layout": c.layout,
3805
- style: g,
3797
+ "data-inline": u.inline ? "true" : "false",
3798
+ "data-layout": u.layout,
3799
+ style: d,
3806
3800
  children: [
3807
3801
  C && !n.value && /* @__PURE__ */ w(
3808
3802
  "button",
3809
3803
  {
3810
3804
  class: "anam-trigger",
3811
- onClick: b,
3805
+ onClick: g,
3812
3806
  "aria-label": _,
3813
3807
  children: l ? /* @__PURE__ */ w("img", { src: l, alt: "Avatar" }) : /* @__PURE__ */ w(Ct, {})
3814
3808
  }
3815
3809
  ),
3816
- x && /* @__PURE__ */ w(
3817
- Tr,
3810
+ I && /* @__PURE__ */ w(
3811
+ Ar,
3818
3812
  {
3819
- config: c,
3820
- session: u,
3813
+ config: u,
3814
+ session: c,
3821
3815
  videoRef: e,
3822
3816
  avatarSrc: l,
3823
3817
  displayCta: _,
3824
- onCollapse: C ? A : null
3818
+ onCollapse: C ? S : null
3825
3819
  }
3826
3820
  )
3827
3821
  ]
@@ -3829,7 +3823,7 @@ function Rr(t) {
3829
3823
  )
3830
3824
  ] }) : /* @__PURE__ */ w("style", { children: di });
3831
3825
  }
3832
- const Nr = [
3826
+ const Rr = [
3833
3827
  "agent-id",
3834
3828
  // Persona ID -- required for session streaming + server config fetch
3835
3829
  "api-base-url",
@@ -3848,11 +3842,13 @@ const Nr = [
3848
3842
  // "true" | "false" -- show text input
3849
3843
  "ui-captions",
3850
3844
  // "true" | "false" -- show captions
3845
+ "call-to-action",
3846
+ // Custom CTA text for the start button
3851
3847
  "avatar-url",
3852
3848
  // Override avatar thumbnail (Lab preview)
3853
3849
  "agent-name"
3854
3850
  // Override persona name for CTA (Lab preview)
3855
- ], Or = {
3851
+ ], xr = {
3856
3852
  SESSION_STARTED: "anam-agent:session-started",
3857
3853
  SESSION_ENDED: "anam-agent:session-ended",
3858
3854
  MESSAGE_RECEIVED: "anam-agent:message-received",
@@ -3864,13 +3860,13 @@ const Nr = [
3864
3860
  MIC_UNMUTED: "anam-agent:mic-unmuted"
3865
3861
  };
3866
3862
  function hi(t = "anam-agent") {
3867
- _n(Rr, t, [...Nr], {
3863
+ _n(Tr, t, [...Rr], {
3868
3864
  shadow: !0
3869
3865
  });
3870
3866
  }
3871
3867
  typeof window < "u" && typeof document < "u" && (document.readyState === "loading" ? document.addEventListener("DOMContentLoaded", () => hi()) : hi());
3872
3868
  export {
3873
3869
  ri as DefaultConfig,
3874
- Or as WidgetEventNames,
3870
+ xr as WidgetEventNames,
3875
3871
  hi as registerWidget
3876
3872
  };