@eka-care/medassist-widget 0.1.87 → 0.1.88-0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,4 +1,4 @@
1
- var kn, W, Si, Et, Uo, wi, Ci, gr, Yn, wn, Ti, Qr, Vr, $r, Ni, Jn = {}, Qn = [], yl = /acit|ex(?:s|g|n|p|$)|rph|grid|ows|mnc|ntw|ine[ch]|zoo|^ord|itera/i, Rn = Array.isArray;
1
+ var kn, q, Si, Et, Uo, wi, Ci, gr, Yn, wn, Ti, Qr, Vr, $r, Ni, Jn = {}, Qn = [], yl = /acit|ex(?:s|g|n|p|$)|rph|grid|ows|mnc|ntw|ine[ch]|zoo|^ord|itera/i, Rn = Array.isArray;
2
2
  function Je(e, t) {
3
3
  for (var n in t) e[n] = t[n];
4
4
  return e;
@@ -14,7 +14,7 @@ function De(e, t, n) {
14
14
  }
15
15
  function Cn(e, t, n, r, o) {
16
16
  var s = { type: e, props: t, key: n, ref: r, __k: null, __: null, __b: 0, __e: null, __c: null, constructor: void 0, __v: o ?? ++Si, __i: -1, __u: 0 };
17
- return o == null && W.vnode != null && W.vnode(s), s;
17
+ return o == null && q.vnode != null && q.vnode(s), s;
18
18
  }
19
19
  function xi() {
20
20
  return { current: null };
@@ -33,7 +33,7 @@ function Vt(e, t) {
33
33
  function vl(e) {
34
34
  if (e.__P && e.__d) {
35
35
  var t = e.__v, n = t.__e, r = [], o = [], s = Je({}, t);
36
- s.__v = t.__v + 1, W.vnode && W.vnode(s), to(e.__P, s, t, e.__n, e.__P.namespaceURI, 32 & t.__u ? [n] : null, r, n ?? Vt(t), !!(32 & t.__u), o), s.__v = t.__v, s.__.__k[s.__i] = s, Ai(r, s, o), t.__e = t.__ = null, s.__e != n && ki(s);
36
+ s.__v = t.__v + 1, q.vnode && q.vnode(s), to(e.__P, s, t, e.__n, e.__P.namespaceURI, 32 & t.__u ? [n] : null, r, n ?? Vt(t), !!(32 & t.__u), o), s.__v = t.__v, s.__.__k[s.__i] = s, Ai(r, s, o), t.__e = t.__ = null, s.__e != n && ki(s);
37
37
  }
38
38
  }
39
39
  function ki(e) {
@@ -42,7 +42,7 @@ function ki(e) {
42
42
  }), ki(e);
43
43
  }
44
44
  function zr(e) {
45
- (!e.__d && (e.__d = !0) && Et.push(e) && !er.__r++ || Uo != W.debounceRendering) && ((Uo = W.debounceRendering) || wi)(er);
45
+ (!e.__d && (e.__d = !0) && Et.push(e) && !er.__r++ || Uo != q.debounceRendering) && ((Uo = q.debounceRendering) || wi)(er);
46
46
  }
47
47
  function er() {
48
48
  try {
@@ -114,14 +114,14 @@ function $o(e) {
114
114
  var n = this.l[t.type + e];
115
115
  if (t[Yn] == null) t[Yn] = Qr++;
116
116
  else if (t[Yn] < n[wn]) return;
117
- return n(W.event ? W.event(t) : t);
117
+ return n(q.event ? q.event(t) : t);
118
118
  }
119
119
  };
120
120
  }
121
121
  function to(e, t, n, r, o, s, a, i, c, d) {
122
122
  var m, u, p, h, _, b, y, f, g, E, N, w, C, T, S, v = t.type;
123
123
  if (t.constructor !== void 0) return null;
124
- 128 & n.__u && (c = !!(32 & n.__u), s = [i = t.__e = n.__e]), (m = W.__b) && m(t);
124
+ 128 & n.__u && (c = !!(32 & n.__u), s = [i = t.__e = n.__e]), (m = q.__b) && m(t);
125
125
  e: if (typeof v == "function") try {
126
126
  if (f = t.props, g = v.prototype && v.prototype.render, E = (m = v.contextType) && r[m.__c], N = m ? E ? E.props.value : m.__ : r, n.__c ? y = (u = t.__c = n.__c).__ = u.__E : (g ? t.__c = u = new v(f, N) : (t.__c = u = new Ge(f, N), u.constructor = v, u.render = Tl), E && E.sub(u), u.state || (u.state = {}), u.__n = r, p = u.__d = !0, u.__h = [], u._sb = []), g && u.__s == null && (u.__s = u.state), g && v.getDerivedStateFromProps != null && (u.__s == u.state && (u.__s = Je({}, u.__s)), Je(u.__s, v.getDerivedStateFromProps(f, u.__s))), h = u.props, _ = u.state, u.__v = t, p) g && v.getDerivedStateFromProps == null && u.componentWillMount != null && u.componentWillMount(), g && u.componentDidMount != null && u.__h.push(u.componentDidMount);
127
127
  else {
@@ -135,7 +135,7 @@ function to(e, t, n, r, o, s, a, i, c, d) {
135
135
  u.componentDidUpdate(h, _, b);
136
136
  });
137
137
  }
138
- if (u.context = N, u.props = f, u.__P = e, u.__e = !1, w = W.__r, C = 0, g) u.state = u.__s, u.__d = !1, w && w(t), m = u.render(u.props, u.state, u.context), Qn.push.apply(u.__h, u._sb), u._sb = [];
138
+ if (u.context = N, u.props = f, u.__P = e, u.__e = !1, w = q.__r, C = 0, g) u.state = u.__s, u.__d = !1, w && w(t), m = u.render(u.props, u.state, u.context), Qn.push.apply(u.__h, u._sb), u._sb = [];
139
139
  else do
140
140
  u.__d = !1, w && w(t), m = u.render(u.props, u.state, u.context), u.state = u.__s;
141
141
  while (u.__d && ++C < 25);
@@ -149,23 +149,23 @@ function to(e, t, n, r, o, s, a, i, c, d) {
149
149
  Br(t);
150
150
  }
151
151
  else t.__e = n.__e, t.__k = n.__k, x.then || Br(t);
152
- W.__e(x, t, n);
152
+ q.__e(x, t, n);
153
153
  }
154
154
  else s == null && t.__v == n.__v ? (t.__k = n.__k, t.__e = n.__e) : i = t.__e = Cl(n.__e, t, n, r, o, s, a, c, d);
155
- return (m = W.diffed) && m(t), 128 & t.__u ? void 0 : i;
155
+ return (m = q.diffed) && m(t), 128 & t.__u ? void 0 : i;
156
156
  }
157
157
  function Br(e) {
158
158
  e && (e.__c && (e.__c.__e = !0), e.__k && e.__k.some(Br));
159
159
  }
160
160
  function Ai(e, t, n) {
161
161
  for (var r = 0; r < n.length; r++) no(n[r], n[++r], n[++r]);
162
- W.__c && W.__c(t, e), e.some(function(o) {
162
+ q.__c && q.__c(t, e), e.some(function(o) {
163
163
  try {
164
164
  e = o.__h, o.__h = [], e.some(function(s) {
165
165
  s.call(o);
166
166
  });
167
167
  } catch (s) {
168
- W.__e(s, o.__v);
168
+ q.__e(s, o.__v);
169
169
  }
170
170
  });
171
171
  }
@@ -182,7 +182,7 @@ function Cl(e, t, n, r, o, s, a, i, c) {
182
182
  }
183
183
  if (e == null) {
184
184
  if (g == null) return document.createTextNode(f);
185
- e = document.createElementNS(o, g, f.is && f), i && (W.__m && W.__m(t, s), i = !1), s = null;
185
+ e = document.createElementNS(o, g, f.is && f), i && (q.__m && q.__m(t, s), i = !1), s = null;
186
186
  }
187
187
  if (g == null) y === f || i && e.data == f || (e.data = f);
188
188
  else {
@@ -202,16 +202,16 @@ function no(e, t, n) {
202
202
  r && e.__u(), r && t == null || (e.__u = e(t));
203
203
  } else e.current = t;
204
204
  } catch (o) {
205
- W.__e(o, n);
205
+ q.__e(o, n);
206
206
  }
207
207
  }
208
208
  function Mi(e, t, n) {
209
209
  var r, o;
210
- if (W.unmount && W.unmount(e), (r = e.ref) && (r.current && r.current != e.__e || no(r, null, t)), (r = e.__c) != null) {
210
+ if (q.unmount && q.unmount(e), (r = e.ref) && (r.current && r.current != e.__e || no(r, null, t)), (r = e.__c) != null) {
211
211
  if (r.componentWillUnmount) try {
212
212
  r.componentWillUnmount();
213
213
  } catch (s) {
214
- W.__e(s, t);
214
+ q.__e(s, t);
215
215
  }
216
216
  r.base = r.__P = null;
217
217
  }
@@ -223,7 +223,7 @@ function Tl(e, t, n) {
223
223
  }
224
224
  function Nn(e, t, n) {
225
225
  var r, o, s, a;
226
- t == document && (t = document.documentElement), W.__ && W.__(e, t), o = (r = typeof n == "function") ? null : n && n.__k || t.__k, s = [], a = [], to(t, e = (!r && n || t).__k = De(be, null, [e]), o || Jn, Jn, t.namespaceURI, !r && n ? [n] : o ? null : t.firstChild ? kn.call(t.childNodes) : null, s, !r && n ? n : o ? o.__e : t.firstChild, r, a), Ai(s, e, a);
226
+ t == document && (t = document.documentElement), q.__ && q.__(e, t), o = (r = typeof n == "function") ? null : n && n.__k || t.__k, s = [], a = [], to(t, e = (!r && n || t).__k = De(be, null, [e]), o || Jn, Jn, t.namespaceURI, !r && n ? [n] : o ? null : t.firstChild ? kn.call(t.childNodes) : null, s, !r && n ? n : o ? o.__e : t.firstChild, r, a), Ai(s, e, a);
227
227
  }
228
228
  function Pi(e, t) {
229
229
  Nn(e, t, Pi);
@@ -256,7 +256,7 @@ function it(e) {
256
256
  return n.children(r);
257
257
  }).contextType = t, t;
258
258
  }
259
- kn = Qn.slice, W = { __e: function(e, t, n, r) {
259
+ kn = Qn.slice, q = { __e: function(e, t, n, r) {
260
260
  for (var o, s, a; t = t.__; ) if ((o = t.__c) && !o.__) try {
261
261
  if ((s = o.constructor) && s.getDerivedStateFromError != null && (o.setState(s.getDerivedStateFromError(e)), a = o.__d), o.componentDidCatch != null && (o.componentDidCatch(e, r || {}), a = o.__d), a) return o.__E = o;
262
262
  } catch (i) {
@@ -278,9 +278,9 @@ function l(e, t, n, r, o, s) {
278
278
  if ("ref" in c) for (i in c = {}, t) i == "ref" ? a = t[i] : c[i] = t[i];
279
279
  var d = { type: e, props: c, key: n, ref: a, __k: null, __: null, __b: 0, __e: null, __c: null, constructor: void 0, __v: --xl, __i: -1, __u: 0, __source: o, __self: s };
280
280
  if (typeof e == "function" && (a = e.defaultProps)) for (i in a) c[i] === void 0 && (c[i] = a[i]);
281
- return W.vnode && W.vnode(d), d;
281
+ return q.vnode && q.vnode(d), d;
282
282
  }
283
- var at, fe, _r, zo, $t = 0, Li = [], ye = W, Bo = ye.__b, jo = ye.__r, Ho = ye.diffed, Go = ye.__c, Wo = ye.unmount, qo = ye.__;
283
+ var at, fe, _r, zo, $t = 0, Li = [], ye = q, Bo = ye.__b, jo = ye.__r, Ho = ye.diffed, Go = ye.__c, Wo = ye.unmount, qo = ye.__;
284
284
  function It(e, t) {
285
285
  ye.__h && ye.__h(fe, e, $t || t), $t = 0;
286
286
  var n = fe.__H || (fe.__H = { __: [], __h: [] });
@@ -331,7 +331,7 @@ function lt(e, t) {
331
331
  var n = It(at++, 4);
332
332
  !ye.__s && io(n.__H, t) && (n.__ = e, n.u = t, fe.__h.push(n));
333
333
  }
334
- function G(e) {
334
+ function W(e) {
335
335
  return $t = 5, de(function() {
336
336
  return { current: e };
337
337
  }, []);
@@ -507,8 +507,8 @@ function fo(e, t) {
507
507
  (tr.prototype = new Ge()).isPureReactComponent = !0, tr.prototype.shouldComponentUpdate = function(e, t) {
508
508
  return Hr(this.props, e) || Hr(this.state, t);
509
509
  };
510
- var Ko = W.__b;
511
- W.__b = function(e) {
510
+ var Ko = q.__b;
511
+ q.__b = function(e) {
512
512
  e.type && e.type.__f && e.ref && (e.props.ref = e.ref, e.ref = null), Ko && Ko(e);
513
513
  };
514
514
  var Al = typeof Symbol < "u" && Symbol.for && Symbol.for("react.forward_ref") || 3911;
@@ -527,14 +527,14 @@ var Zo = function(e, t) {
527
527
  var t = st(e);
528
528
  if (t.length !== 1) throw "Children.only";
529
529
  return t[0];
530
- }, toArray: st }, Ol = W.__e;
531
- W.__e = function(e, t, n, r) {
530
+ }, toArray: st }, Ol = q.__e;
531
+ q.__e = function(e, t, n, r) {
532
532
  if (e.then) {
533
533
  for (var o, s = t; s = s.__; ) if ((o = s.__c) && o.__c) return t.__e == null && (t.__e = n.__e, t.__k = n.__k), o.__c(e, t);
534
534
  }
535
535
  Ol(e, t, n, r);
536
536
  };
537
- var Xo = W.unmount;
537
+ var Xo = q.unmount;
538
538
  function Ui(e, t, n) {
539
539
  return e && (e.__c && e.__c.__H && (e.__c.__H.__.forEach(function(r) {
540
540
  typeof r.__c == "function" && r.__c();
@@ -547,7 +547,7 @@ function Vi(e, t, n) {
547
547
  return Vi(r, t, n);
548
548
  }), e.__c && e.__c.__P === t && (e.__e && n.appendChild(e.__e), e.__c.__e = !0, e.__c.__P = n)), e;
549
549
  }
550
- function Re() {
550
+ function Me() {
551
551
  this.__u = 0, this.o = null, this.__b = null;
552
552
  }
553
553
  function $i(e) {
@@ -570,10 +570,10 @@ function dt(e) {
570
570
  function Ut() {
571
571
  this.i = null, this.l = null;
572
572
  }
573
- W.unmount = function(e) {
573
+ q.unmount = function(e) {
574
574
  var t = e.__c;
575
575
  t && (t.__z = !0), t && t.__R && t.__R(), t && 32 & e.__u && (e.type = null), Xo && Xo(e);
576
- }, (Re.prototype = new Ge()).__c = function(e, t) {
576
+ }, (Me.prototype = new Ge()).__c = function(e, t) {
577
577
  var n = t.__c, r = this;
578
578
  r.o == null && (r.o = []), r.o.push(n);
579
579
  var o = $i(r.__v), s = !1, a = function() {
@@ -593,9 +593,9 @@ W.unmount = function(e) {
593
593
  }
594
594
  };
595
595
  r.__u++ || 32 & t.__u || r.setState({ __a: r.__b = r.__v.__k[0] }), e.then(a, a);
596
- }, Re.prototype.componentWillUnmount = function() {
596
+ }, Me.prototype.componentWillUnmount = function() {
597
597
  this.o = [];
598
- }, Re.prototype.render = function(e, t) {
598
+ }, Me.prototype.render = function(e, t) {
599
599
  if (this.__b) {
600
600
  if (this.__v.__k) {
601
601
  var n = document.createElement("div"), r = this.__v.__k[0].__c;
@@ -674,8 +674,8 @@ Ge.prototype.isReactComponent = !0, ["componentWillMount", "componentWillReceive
674
674
  Object.defineProperty(this, e, { configurable: !0, writable: !0, value: t });
675
675
  } });
676
676
  });
677
- var Qo = W.event;
678
- W.event = function(e) {
677
+ var Qo = q.event;
678
+ q.event = function(e) {
679
679
  return Qo && (e = Qo(e)), e.persist = function() {
680
680
  }, e.isPropagationStopped = function() {
681
681
  return this.cancelBubble;
@@ -685,8 +685,8 @@ W.event = function(e) {
685
685
  };
686
686
  var po, $l = { configurable: !0, get: function() {
687
687
  return this.class;
688
- } }, es = W.vnode;
689
- W.vnode = function(e) {
688
+ } }, es = q.vnode;
689
+ q.vnode = function(e) {
690
690
  typeof e.type == "string" && (function(t) {
691
691
  var n = t.props, r = t.type, o = {}, s = r.indexOf("-") == -1;
692
692
  for (var a in n) {
@@ -703,19 +703,19 @@ W.vnode = function(e) {
703
703
  }))), n.class && !n.className ? (o.class = n.class, Object.defineProperty(o, "className", $l)) : n.className && (o.class = o.className = n.className), t.props = o;
704
704
  })(e), e.$$typeof = Bi, es && es(e);
705
705
  };
706
- var ts = W.__r;
707
- W.__r = function(e) {
706
+ var ts = q.__r;
707
+ q.__r = function(e) {
708
708
  ts && ts(e), po = e.__c;
709
709
  };
710
- var ns = W.diffed;
711
- W.diffed = function(e) {
710
+ var ns = q.diffed;
711
+ q.diffed = function(e) {
712
712
  ns && ns(e);
713
713
  var t = e.props, n = e.__e;
714
714
  n != null && e.type === "textarea" && "value" in t && t.value !== n.value && (n.value = t.value == null ? "" : t.value), po = null;
715
715
  };
716
716
  var Hi = { ReactCurrentDispatcher: { current: { readContext: function(e) {
717
717
  return po.__n[e.__c].props.value;
718
- }, useCallback: ae, useContext: ct, useDebugValue: oo, useDeferredValue: co, useEffect: $, useId: so, useImperativeHandle: ro, useInsertionEffect: ho, useLayoutEffect: lt, useMemo: de, useReducer: Gt, useRef: G, useState: V, useSyncExternalStore: ao, useTransition: uo } } }, zl = "18.3.1";
718
+ }, useCallback: ae, useContext: ct, useDebugValue: oo, useDeferredValue: co, useEffect: $, useId: so, useImperativeHandle: ro, useInsertionEffect: ho, useLayoutEffect: lt, useMemo: de, useReducer: Gt, useRef: W, useState: V, useSyncExternalStore: ao, useTransition: uo } } }, zl = "18.3.1";
719
719
  function Gi(e) {
720
720
  return De.bind(null, e);
721
721
  }
@@ -740,14 +740,14 @@ function Yi(e) {
740
740
  var Ki = function(e, t) {
741
741
  return e(t);
742
742
  }, Zi = function(e, t) {
743
- var n = W.debounceRendering;
744
- W.debounceRendering = function(o) {
743
+ var n = q.debounceRendering;
744
+ q.debounceRendering = function(o) {
745
745
  return o();
746
746
  };
747
747
  var r = e(t);
748
- return W.debounceRendering = n, r;
749
- }, Xi = $e, Sn = { useState: V, useId: so, useReducer: Gt, useEffect: $, useLayoutEffect: lt, useInsertionEffect: ho, useTransition: uo, useDeferredValue: co, useSyncExternalStore: ao, startTransition: lo, useRef: G, useImperativeHandle: ro, useMemo: de, useCallback: ae, useContext: ct, useDebugValue: oo, version: "18.3.1", Children: Ve, render: mo, hydrate: ji, unmountComponentAtNode: go, createPortal: zi, createElement: De, createContext: it, createFactory: Gi, cloneElement: yt, createRef: xi, Fragment: be, isValidElement: $e, isElement: Xi, isFragment: Wi, isMemo: qi, findDOMNode: Yi, Component: Ge, PureComponent: tr, memo: fo, forwardRef: K, flushSync: Zi, unstable_batchedUpdates: Ki, StrictMode: be, Suspense: Re, SuspenseList: Ut, lazy: dt, __SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED: Hi };
750
- const Ji = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({ __proto__: null, Children: Ve, Component: Ge, Fragment: be, PureComponent: tr, StrictMode: be, Suspense: Re, SuspenseList: Ut, __SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED: Hi, cloneElement: yt, createContext: it, createElement: De, createFactory: Gi, createPortal: zi, createRef: xi, default: Sn, findDOMNode: Yi, flushSync: Zi, forwardRef: K, hydrate: ji, isElement: Xi, isFragment: Wi, isMemo: qi, isValidElement: $e, lazy: dt, memo: fo, render: mo, startTransition: lo, unmountComponentAtNode: go, unstable_batchedUpdates: Ki, useCallback: ae, useContext: ct, useDebugValue: oo, useDeferredValue: co, useEffect: $, useErrorBoundary: kl, useId: so, useImperativeHandle: ro, useInsertionEffect: ho, useLayoutEffect: lt, useMemo: de, useReducer: Gt, useRef: G, useState: V, useSyncExternalStore: ao, useTransition: uo, version: zl }, Symbol.toStringTag, { value: "Module" }));
748
+ return q.debounceRendering = n, r;
749
+ }, Xi = $e, Sn = { useState: V, useId: so, useReducer: Gt, useEffect: $, useLayoutEffect: lt, useInsertionEffect: ho, useTransition: uo, useDeferredValue: co, useSyncExternalStore: ao, startTransition: lo, useRef: W, useImperativeHandle: ro, useMemo: de, useCallback: ae, useContext: ct, useDebugValue: oo, version: "18.3.1", Children: Ve, render: mo, hydrate: ji, unmountComponentAtNode: go, createPortal: zi, createElement: De, createContext: it, createFactory: Gi, cloneElement: yt, createRef: xi, Fragment: be, isValidElement: $e, isElement: Xi, isFragment: Wi, isMemo: qi, findDOMNode: Yi, Component: Ge, PureComponent: tr, memo: fo, forwardRef: K, flushSync: Zi, unstable_batchedUpdates: Ki, StrictMode: be, Suspense: Me, SuspenseList: Ut, lazy: dt, __SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED: Hi };
750
+ const Ji = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({ __proto__: null, Children: Ve, Component: Ge, Fragment: be, PureComponent: tr, StrictMode: be, Suspense: Me, SuspenseList: Ut, __SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED: Hi, cloneElement: yt, createContext: it, createElement: De, createFactory: Gi, createPortal: zi, createRef: xi, default: Sn, findDOMNode: Yi, flushSync: Zi, forwardRef: K, hydrate: ji, isElement: Xi, isFragment: Wi, isMemo: qi, isValidElement: $e, lazy: dt, memo: fo, render: mo, startTransition: lo, unmountComponentAtNode: go, unstable_batchedUpdates: Ki, useCallback: ae, useContext: ct, useDebugValue: oo, useDeferredValue: co, useEffect: $, useErrorBoundary: kl, useId: so, useImperativeHandle: ro, useInsertionEffect: ho, useLayoutEffect: lt, useMemo: de, useReducer: Gt, useRef: W, useState: V, useSyncExternalStore: ao, useTransition: uo, version: zl }, Symbol.toStringTag, { value: "Module" }));
751
751
  function Bl(e) {
752
752
  return {
753
753
  // eslint-disable-next-line
@@ -862,7 +862,7 @@ var An = (e) => {
862
862
  };
863
863
  An.displayName = "Presence";
864
864
  function Xl(e) {
865
- const [t, n] = V(), r = G(null), o = G(e), s = G("none"), a = e ? "mounted" : "unmounted", [i, c] = Zl(a, {
865
+ const [t, n] = V(), r = W(null), o = W(e), s = W("none"), a = e ? "mounted" : "unmounted", [i, c] = Zl(a, {
866
866
  mounted: {
867
867
  UNMOUNT: "unmounted",
868
868
  ANIMATION_OUT: "unmountSuspended"
@@ -966,7 +966,7 @@ function ec(...e) {
966
966
  return n.scopeName = t.scopeName, n;
967
967
  }
968
968
  function bt(e) {
969
- const t = G(e);
969
+ const t = W(e);
970
970
  return $(() => {
971
971
  t.current = e;
972
972
  }), de(() => (...n) => t.current?.(...n), []);
@@ -1041,7 +1041,7 @@ var Eo = "ScrollArea", [Qi] = Ql(Eo), [sc, We] = Qi(Eo), ea = K(
1041
1041
  ea.displayName = Eo;
1042
1042
  var ta = "ScrollAreaViewport", na = K(
1043
1043
  (e, t) => {
1044
- const { __scopeScrollArea: n, children: r, nonce: o, ...s } = e, a = We(ta, n), i = G(null), c = At(t, i, a.onViewportChange);
1044
+ const { __scopeScrollArea: n, children: r, nonce: o, ...s } = e, a = We(ta, n), i = W(null), c = At(t, i, a.onViewportChange);
1045
1045
  return /* @__PURE__ */ l(be, { children: [
1046
1046
  /* @__PURE__ */ l(
1047
1047
  "style",
@@ -1173,7 +1173,7 @@ var ic = K((e, t) => {
1173
1173
  }
1174
1174
  ) });
1175
1175
  }), yo = K((e, t) => {
1176
- const { orientation: n = "vertical", ...r } = e, o = We(Qe, e.__scopeScrollArea), s = G(null), a = G(0), [i, c] = V({
1176
+ const { orientation: n = "vertical", ...r } = e, o = We(Qe, e.__scopeScrollArea), s = W(null), a = W(0), [i, c] = V({
1177
1177
  content: 0,
1178
1178
  viewport: 0,
1179
1179
  scrollbar: { size: 0, paddingStart: 0, paddingEnd: 0 }
@@ -1227,7 +1227,7 @@ var ic = K((e, t) => {
1227
1227
  }
1228
1228
  ) : null;
1229
1229
  }), lc = K((e, t) => {
1230
- const { sizes: n, onSizesChange: r, ...o } = e, s = We(Qe, e.__scopeScrollArea), [a, i] = V(), c = G(null), d = At(t, c, s.onScrollbarXChange);
1230
+ const { sizes: n, onSizesChange: r, ...o } = e, s = We(Qe, e.__scopeScrollArea), [a, i] = V(), c = W(null), d = At(t, c, s.onScrollbarXChange);
1231
1231
  return $(() => {
1232
1232
  c.current && i(getComputedStyle(c.current));
1233
1233
  }, [c]), /* @__PURE__ */ l(
@@ -1266,7 +1266,7 @@ var ic = K((e, t) => {
1266
1266
  }
1267
1267
  );
1268
1268
  }), cc = K((e, t) => {
1269
- const { sizes: n, onSizesChange: r, ...o } = e, s = We(Qe, e.__scopeScrollArea), [a, i] = V(), c = G(null), d = At(t, c, s.onScrollbarYChange);
1269
+ const { sizes: n, onSizesChange: r, ...o } = e, s = We(Qe, e.__scopeScrollArea), [a, i] = V(), c = W(null), d = At(t, c, s.onScrollbarYChange);
1270
1270
  return $(() => {
1271
1271
  c.current && i(getComputedStyle(c.current));
1272
1272
  }, [c]), /* @__PURE__ */ l(
@@ -1318,7 +1318,7 @@ var ic = K((e, t) => {
1318
1318
  onWheelScroll: m,
1319
1319
  onResize: u,
1320
1320
  ...p
1321
- } = e, h = We(Qe, n), [_, b] = V(null), y = At(t, (v) => b(v)), f = G(null), g = G(""), E = h.viewport, N = r.content - r.viewport, w = bt(m), C = bt(c), T = cr(u, 10);
1321
+ } = e, h = We(Qe, n), [_, b] = V(null), y = At(t, (v) => b(v)), f = W(null), g = W(""), E = h.viewport, N = r.content - r.viewport, w = bt(m), C = bt(c), T = cr(u, 10);
1322
1322
  function S(v) {
1323
1323
  if (f.current) {
1324
1324
  const x = v.clientX - f.current.left, O = v.clientY - f.current.top;
@@ -1369,7 +1369,7 @@ var ic = K((e, t) => {
1369
1369
  const { __scopeScrollArea: n, style: r, ...o } = e, s = We(nr, n), a = oa(nr, n), { onThumbPositionChange: i } = a, c = At(
1370
1370
  t,
1371
1371
  (u) => a.onThumbChange(u)
1372
- ), d = G(void 0), m = cr(() => {
1372
+ ), d = W(void 0), m = cr(() => {
1373
1373
  d.current && (d.current(), d.current = void 0);
1374
1374
  }, 100);
1375
1375
  return $(() => {
@@ -1474,7 +1474,7 @@ var mc = (e, t = () => {
1474
1474
  })(), () => window.cancelAnimationFrame(r);
1475
1475
  };
1476
1476
  function cr(e, t) {
1477
- const n = bt(e), r = G(0);
1477
+ const n = bt(e), r = W(0);
1478
1478
  return $(() => () => window.clearTimeout(r.current), []), ae(() => {
1479
1479
  window.clearTimeout(r.current), r.current = window.setTimeout(n, t);
1480
1480
  }, [n, t]);
@@ -4719,7 +4719,7 @@ const Dc = (e, t) => {
4719
4719
  _,
4720
4720
  U,
4721
4721
  F
4722
- ], Ie = () => ["none", Z, U, F], Se = () => ["none", Z, U, F], he = () => [Z, U, F], Pe = () => [Lt, "full", ...S()];
4722
+ ], xe = () => ["none", Z, U, F], Se = () => ["none", Z, U, F], he = () => [Z, U, F], Pe = () => [Lt, "full", ...S()];
4723
4723
  return {
4724
4724
  cacheSize: 500,
4725
4725
  theme: {
@@ -6666,28 +6666,28 @@ const Dc = (e, t) => {
6666
6666
  * @see https://tailwindcss.com/docs/rotate
6667
6667
  */
6668
6668
  rotate: [{
6669
- rotate: Ie()
6669
+ rotate: xe()
6670
6670
  }],
6671
6671
  /**
6672
6672
  * Rotate X
6673
6673
  * @see https://tailwindcss.com/docs/rotate
6674
6674
  */
6675
6675
  "rotate-x": [{
6676
- "rotate-x": Ie()
6676
+ "rotate-x": xe()
6677
6677
  }],
6678
6678
  /**
6679
6679
  * Rotate Y
6680
6680
  * @see https://tailwindcss.com/docs/rotate
6681
6681
  */
6682
6682
  "rotate-y": [{
6683
- "rotate-y": Ie()
6683
+ "rotate-y": xe()
6684
6684
  }],
6685
6685
  /**
6686
6686
  * Rotate Z
6687
6687
  * @see https://tailwindcss.com/docs/rotate
6688
6688
  */
6689
6689
  "rotate-z": [{
6690
- "rotate-z": Ie()
6690
+ "rotate-z": xe()
6691
6691
  }],
6692
6692
  /**
6693
6693
  * Scale
@@ -7900,7 +7900,7 @@ function Nu({ defaultPosition: e, enabled: t = !0, onDragStart: n, onDragEnd: r
7900
7900
  const o = ae(() => typeof window > "u" ? { x: 0, y: 0 } : {
7901
7901
  x: window.innerWidth - jn.width - Hn,
7902
7902
  y: window.innerHeight - jn.height - Hn
7903
- }, []), [s, a] = V(() => e ?? o()), [i, c] = V(!1), d = G({ x: 0, y: 0 }), m = G(null), u = G(!1);
7903
+ }, []), [s, a] = V(() => e ?? o()), [i, c] = V(!1), d = W({ x: 0, y: 0 }), m = W(null), u = W(!1);
7904
7904
  $(() => {
7905
7905
  t || (u.current = !1);
7906
7906
  }, [t]), lt(() => {
@@ -8393,7 +8393,7 @@ function ti(e, t) {
8393
8393
  return e ? t ? (e.src !== t && (e.src = t), e.complete && e.naturalWidth > 0 ? "loaded" : "loading") : "error" : "idle";
8394
8394
  }
8395
8395
  function Xu(e, { referrerPolicy: t, crossOrigin: n }) {
8396
- const r = qu(), o = G(null), s = r ? (o.current || (o.current = new window.Image()), o.current) : null, [a, i] = V(
8396
+ const r = qu(), o = W(null), s = r ? (o.current || (o.current = new window.Image()), o.current) : null, [a, i] = V(
8397
8397
  () => ti(s, e)
8398
8398
  );
8399
8399
  return zt(() => {
@@ -8476,7 +8476,7 @@ function nh({
8476
8476
  headerTinted: c = !1,
8477
8477
  onToggleDisplayMode: d
8478
8478
  }) {
8479
- const m = ol(), p = eh() && !m, h = ne((v) => v.displayMode) === "full", _ = ne((v) => v.initialDisplayMode) === "full", y = (h ? !1 : c) ? "text-primary-foreground" : "text-foreground", f = ne((v) => v.connectionStatus), [g, E] = V(!1), N = G(null), w = de(() => i === "connected" || i === "connecting" || i === "listening" || i === "speaking" || i === "thinking", [i]), C = ae(() => {
8479
+ const m = ol(), p = eh() && !m, h = ne((v) => v.displayMode) === "full", _ = ne((v) => v.initialDisplayMode) === "full", y = (h ? !1 : c) ? "text-primary-foreground" : "text-foreground", f = ne((v) => v.connectionStatus), [g, E] = V(!1), N = W(null), w = de(() => i === "connected" || i === "connecting" || i === "listening" || i === "speaking" || i === "thinking", [i]), C = ae(() => {
8480
8480
  g || (E(!0), N.current && clearTimeout(N.current), N.current = setTimeout(() => {
8481
8481
  N.current = null, E(!1);
8482
8482
  }, 6e3), a());
@@ -9214,7 +9214,7 @@ function dh({
9214
9214
  onResendOtp: o,
9215
9215
  serverMessage: s
9216
9216
  }) {
9217
- const a = G([]), [i, c] = V(0), [d, m] = V(!1), u = G(!1), p = G(r), h = G(o), _ = n?.maxLength ?? ah, b = de(
9217
+ const a = W([]), [i, c] = V(0), [d, m] = V(!1), u = W(!1), p = W(r), h = W(o), _ = n?.maxLength ?? ah, b = de(
9218
9218
  () => new RegExp(n?.pattern ?? `^\\d{${_}}$`),
9219
9219
  [n?.pattern, _]
9220
9220
  );
@@ -9543,7 +9543,7 @@ function _h({
9543
9543
  activeElicitationState: N,
9544
9544
  isFullScreen: w
9545
9545
  }) {
9546
- const C = G(null), T = G(null), S = e.trim().length > 0 || i, v = _ === void 0 || _.includes(M.SYNAPSE_CONVERSATION.AUDIO), x = _ === void 0 || _.includes(M.SYNAPSE_CONVERSATION.VOICE), O = S || !v, I = S, z = _ === void 0 || _.includes(M.SYNAPSE_CONVERSATION.FILE), oe = (d || p !== me.IDLE) && !a, P = D(
9546
+ const C = W(null), T = W(null), S = e.trim().length > 0 || i, v = _ === void 0 || _.includes(M.SYNAPSE_CONVERSATION.AUDIO), x = _ === void 0 || _.includes(M.SYNAPSE_CONVERSATION.VOICE), O = S || !v, I = S, z = _ === void 0 || _.includes(M.SYNAPSE_CONVERSATION.FILE), oe = (d || p !== me.IDLE) && !a, P = D(
9547
9547
  "rounded-full transition-all duration-200 ",
9548
9548
  a ? "bg-gradient-to-r from-rose-400 via-primary to-indigo-500 text-white ring-2 ring-white/60 animate-pulse shadow-[0_0_20px_rgba(139,92,246,0.45)]" : oe ? "text-primary/50 cursor-not-allowed shadow-none" : "text-foreground hover:bg-primary hover:text-primary-foreground"
9549
9549
  ), H = (ee) => {
@@ -9911,6 +9911,70 @@ function _h({
9911
9911
  )
9912
9912
  ] }) });
9913
9913
  }
9914
+ function Eh({ message: e, onDismiss: t }) {
9915
+ return /* @__PURE__ */ l(be, { children: [
9916
+ /* @__PURE__ */ l(
9917
+ "div",
9918
+ {
9919
+ className: "pointer-events-none absolute inset-0 z-[55] bg-black-600",
9920
+ "aria-hidden": !0
9921
+ }
9922
+ ),
9923
+ /* @__PURE__ */ l(
9924
+ "div",
9925
+ {
9926
+ className: "pointer-events-none absolute inset-x-3 top-3 z-[60]",
9927
+ role: "presentation",
9928
+ children: /* @__PURE__ */ l(
9929
+ "div",
9930
+ {
9931
+ role: "alertdialog",
9932
+ "aria-modal": "true",
9933
+ "aria-labelledby": "synapse-disp-toast-msg",
9934
+ className: "pointer-events-auto flex w-full flex-row items-center gap-3 rounded-lg border border-border bg-surface p-3 text-left text-foreground opacity-100",
9935
+ onClick: (n) => n.stopPropagation(),
9936
+ children: [
9937
+ /* @__PURE__ */ l(
9938
+ "p",
9939
+ {
9940
+ id: "synapse-disp-toast-msg",
9941
+ className: "min-w-0 flex-1 text-sm font-medium whitespace-pre-wrap",
9942
+ children: e
9943
+ }
9944
+ ),
9945
+ /* @__PURE__ */ l(
9946
+ "button",
9947
+ {
9948
+ type: "button",
9949
+ onClick: t,
9950
+ className: "flex h-8 w-8 shrink-0 items-center justify-center rounded-full text-muted-foreground hover:bg-muted hover:text-foreground",
9951
+ "aria-label": "Close",
9952
+ children: /* @__PURE__ */ l(ar, { className: "h-4 w-4", strokeWidth: 2.5 })
9953
+ }
9954
+ )
9955
+ ]
9956
+ }
9957
+ )
9958
+ }
9959
+ )
9960
+ ] });
9961
+ }
9962
+ function bh() {
9963
+ const e = ne((r) => r.toastMessage), t = ne((r) => r.setToastMessage), n = ae(() => {
9964
+ t(null);
9965
+ }, [t]);
9966
+ return $(() => {
9967
+ if (!e) return;
9968
+ const r = window.setTimeout(n, 3e3);
9969
+ return () => window.clearTimeout(r);
9970
+ }, [e, n]), e ? /* @__PURE__ */ l(
9971
+ Eh,
9972
+ {
9973
+ message: e,
9974
+ onDismiss: n
9975
+ }
9976
+ ) : null;
9977
+ }
9914
9978
  function sl({
9915
9979
  isOpen: e,
9916
9980
  onClose: t,
@@ -9935,7 +9999,7 @@ function sl({
9935
9999
  theme: E,
9936
10000
  hideWatermark: N = !1
9937
10001
  }) {
9938
- const [w, C] = V(!1), [T, S] = V(!1), v = G(null), x = _, O = x === "full", I = G(null), [z, oe] = V("");
10002
+ const [w, C] = V(!1), [T, S] = V(!1), v = W(null), x = _, O = x === "full", I = W(null), [z, oe] = V("");
9939
10003
  $(() => {
9940
10004
  I.current !== null && I.current !== x && oe(
9941
10005
  x === "full" ? "Switched to fullscreen mode" : x === "widget" ? "Switched to widget mode" : "Switched to mobile layout"
@@ -9967,13 +10031,13 @@ function sl({
9967
10031
  if (!e || !w || !v.current) return;
9968
10032
  const A = v.current;
9969
10033
  let Y = null, ue = null, ge = null, X = window.visualViewport?.offsetTop ?? 0, Ue = 0;
9970
- const Ie = 2, Se = 80;
10034
+ const xe = 2, Se = 80;
9971
10035
  if (window.visualViewport) {
9972
10036
  const he = () => {
9973
10037
  if (A && window.visualViewport) {
9974
- const Le = window.visualViewport.height, Ae = window.visualViewport.offsetTop;
10038
+ const Le = window.visualViewport.height, Ie = window.visualViewport.offsetTop;
9975
10039
  Y = requestAnimationFrame(() => {
9976
- A.style.transition = "none", A.style.top = `${Ae}px`, A.style.left = "0", A.style.right = "0", A.style.bottom = "auto", A.style.width = "100vw", A.style.height = `${Le}px`, A.style.maxHeight = `${Le}px`, A.style.minHeight = `${Le}px`, ue && clearTimeout(ue), ue = setTimeout(() => {
10040
+ A.style.transition = "none", A.style.top = `${Ie}px`, A.style.left = "0", A.style.right = "0", A.style.bottom = "auto", A.style.width = "100vw", A.style.height = `${Le}px`, A.style.maxHeight = `${Le}px`, A.style.minHeight = `${Le}px`, ue && clearTimeout(ue), ue = setTimeout(() => {
9977
10041
  A.style.transition = "";
9978
10042
  }, 100);
9979
10043
  });
@@ -9982,8 +10046,8 @@ function sl({
9982
10046
  he();
9983
10047
  }, we = () => {
9984
10048
  if (!A || !window.visualViewport) return;
9985
- const Le = window.visualViewport.offsetTop, Ae = Date.now();
9986
- Math.abs(Le - X) < Ie || Ae - Ue < Se || (Ue = Ae, X = Le, Y = requestAnimationFrame(() => {
10049
+ const Le = window.visualViewport.offsetTop, Ie = Date.now();
10050
+ Math.abs(Le - X) < xe || Ie - Ue < Se || (Ue = Ie, X = Le, Y = requestAnimationFrame(() => {
9987
10051
  A.style.transition = "none", A.style.top = `${Le}px`, ge && clearTimeout(ge), ge = setTimeout(() => {
9988
10052
  A.style.transition = "";
9989
10053
  }, 150);
@@ -10007,7 +10071,7 @@ function sl({
10007
10071
  const A = v.current, Y = window.scrollY, ue = document.body.style.cssText, ge = document.documentElement.style.overflow, X = window.innerWidth - document.documentElement.clientWidth;
10008
10072
  document.body.style.position = "fixed", document.body.style.top = `-${Y}px`, document.body.style.left = "0", document.body.style.right = "0", document.body.style.width = "100%", document.body.style.overflow = "hidden", document.documentElement.style.overflow = "hidden", X > 0 && !w && (document.body.style.paddingRight = `${X}px`);
10009
10073
  let Ue = 0;
10010
- const Ie = (he) => {
10074
+ const xe = (he) => {
10011
10075
  Ue = he.touches[0].clientY;
10012
10076
  }, Se = (he) => {
10013
10077
  if (he.touches.length !== 1) return;
@@ -10017,7 +10081,7 @@ function sl({
10017
10081
  for (; we && we !== A; ) {
10018
10082
  const { overflowY: Le } = window.getComputedStyle(we);
10019
10083
  if ((Le === "auto" || Le === "scroll") && we.scrollHeight > we.clientHeight) {
10020
- const { scrollTop: Ae, scrollHeight: Ot, clientHeight: et } = we, Yt = Ae <= 0 && Pe < 0, Mt = Ae + et >= Ot - 1 && Pe > 0;
10084
+ const { scrollTop: Ie, scrollHeight: Ot, clientHeight: et } = we, Yt = Ie <= 0 && Pe < 0, Mt = Ie + et >= Ot - 1 && Pe > 0;
10021
10085
  if (!Yt && !Mt) return;
10022
10086
  break;
10023
10087
  }
@@ -10025,8 +10089,8 @@ function sl({
10025
10089
  }
10026
10090
  he.preventDefault();
10027
10091
  };
10028
- return A && (A.addEventListener("touchstart", Ie, { passive: !0 }), A.addEventListener("touchmove", Se, { passive: !1 })), () => {
10029
- A && (A.removeEventListener("touchstart", Ie), A.removeEventListener("touchmove", Se)), document.body.style.cssText = ue, document.documentElement.style.overflow = ge, window.scrollTo(0, Y);
10092
+ return A && (A.addEventListener("touchstart", xe, { passive: !0 }), A.addEventListener("touchmove", Se, { passive: !1 })), () => {
10093
+ A && (A.removeEventListener("touchstart", xe), A.removeEventListener("touchmove", Se)), document.body.style.cssText = ue, document.documentElement.style.overflow = ge, window.scrollTo(0, Y);
10030
10094
  };
10031
10095
  }
10032
10096
  }, [e, w]);
@@ -10225,7 +10289,7 @@ function sl({
10225
10289
  ...!w && !O && {
10226
10290
  cursor: e ? "grab" : "default"
10227
10291
  }
10228
- }, children: /* @__PURE__ */ l(Re, { fallback: /* @__PURE__ */ l(Fu, {}), children: /* @__PURE__ */ l(
10292
+ }, children: /* @__PURE__ */ l(Me, { fallback: /* @__PURE__ */ l(Fu, {}), children: /* @__PURE__ */ l(
10229
10293
  nh,
10230
10294
  {
10231
10295
  onClose: t,
@@ -10241,7 +10305,7 @@ function sl({
10241
10305
  }
10242
10306
  ) }) }),
10243
10307
  (() => {
10244
- const A = O && !!i, Y = p && g === M.VOICE_AGENT_STATE.IDLE ? /* @__PURE__ */ l(Re, { fallback: /* @__PURE__ */ l(Uu, {}), children: /* @__PURE__ */ l(
10308
+ const A = O && !!i, Y = p && g === M.VOICE_AGENT_STATE.IDLE ? /* @__PURE__ */ l(Me, { fallback: /* @__PURE__ */ l(Uu, {}), children: /* @__PURE__ */ l(
10245
10309
  _h,
10246
10310
  {
10247
10311
  value: p.value,
@@ -10305,7 +10369,10 @@ function sl({
10305
10369
  composerFooter: A ? ue : null
10306
10370
  }) : null;
10307
10371
  return /* @__PURE__ */ l(be, { children: [
10308
- /* @__PURE__ */ l("div", { className: "flex-1 min-h-0 overflow-hidden flex flex-col relative", children: ge ?? a }),
10372
+ /* @__PURE__ */ l("div", { className: "flex-1 min-h-0 overflow-hidden flex flex-col relative", children: [
10373
+ ge ?? a,
10374
+ /* @__PURE__ */ l(bh, {})
10375
+ ] }),
10309
10376
  p && !A && /* @__PURE__ */ l(
10310
10377
  "div",
10311
10378
  {
@@ -10342,12 +10409,12 @@ function sl({
10342
10409
  }
10343
10410
  );
10344
10411
  }
10345
- function Eh() {
10412
+ function yh() {
10346
10413
  const e = (/* @__PURE__ */ new Date()).getHours();
10347
10414
  return e >= 5 && e < 12 ? "Good morning. How are you feeling today?" : e >= 12 && e < 17 ? "Good afternoon. How are you feeling right now?" : e >= 17 && e < 21 ? "Good evening. How are you doing this evening?" : "Up late? I'm here whenever you need me.";
10348
10415
  }
10349
- const bh = 180;
10350
- function yh({
10416
+ const vh = 180;
10417
+ function Sh({
10351
10418
  description: e,
10352
10419
  suggestions: t,
10353
10420
  onSendMessage: n,
@@ -10365,7 +10432,7 @@ function yh({
10365
10432
  };
10366
10433
  return /* @__PURE__ */ l("div", { className: "flex-1 flex flex-col overflow-y-auto", children: /* @__PURE__ */ l("div", { className: "flex flex-col items-stretch gap-6 w-full max-w-2xl mx-auto my-auto px-4 py-6", children: [
10367
10434
  /* @__PURE__ */ l("div", { className: "flex flex-col px-3 gap-2 items-start", children: [
10368
- e && e?.trim?.()?.length <= bh && /* @__PURE__ */ l(
10435
+ e && e?.trim?.()?.length <= vh && /* @__PURE__ */ l(
10369
10436
  "h2",
10370
10437
  {
10371
10438
  className: "text-text-primary",
@@ -10377,7 +10444,7 @@ function yh({
10377
10444
  letterSpacing: "-0.025em",
10378
10445
  margin: 0
10379
10446
  },
10380
- children: Eh()
10447
+ children: yh()
10381
10448
  }
10382
10449
  ),
10383
10450
  e && /* @__PURE__ */ l(
@@ -10446,7 +10513,7 @@ const al = (e) => Object.fromEntries(
10446
10513
  ), Em = (e) => e ? e.split(" ").map((t) => t[0]).slice(0, 2).join("").toUpperCase() : "DR", bm = (e) => {
10447
10514
  const t = new Date(e), n = t.toLocaleDateString(void 0, { weekday: "short" }), r = t.toLocaleDateString(void 0, { day: "2-digit" });
10448
10515
  return { weekday: n, dayNum: r };
10449
- }, vh = (e = [], t = []) => {
10516
+ }, wh = (e = [], t = []) => {
10450
10517
  if (!e.length) return t;
10451
10518
  if (!t.length) return e;
10452
10519
  const n = e.map((r) => ({ ...r }));
@@ -10464,7 +10531,7 @@ const al = (e) => Object.fromEntries(
10464
10531
  }
10465
10532
  }
10466
10533
  return n;
10467
- }, Sh = (e = [], t = []) => {
10534
+ }, Ch = (e = [], t = []) => {
10468
10535
  if (!e.length) return t;
10469
10536
  if (!t.length) return e;
10470
10537
  const n = e.map((r) => ({ ...r }));
@@ -10477,14 +10544,14 @@ const al = (e) => Object.fromEntries(
10477
10544
  n[o] = {
10478
10545
  ...s,
10479
10546
  ...al(r),
10480
- availability: vh(s.availability, r.availability)
10547
+ availability: wh(s.availability, r.availability)
10481
10548
  };
10482
10549
  }
10483
10550
  }
10484
10551
  return n;
10485
- }, si = (e) => !!e && Array.isArray(e.doctors), wh = (e, t, n) => e ? t ? n !== M.SYNAPSE_COMPONENTS.DOCTOR_CARD ? t : !si(e) || !si(t) ? e : {
10552
+ }, si = (e) => !!e && Array.isArray(e.doctors), Th = (e, t, n) => e ? t ? n !== M.SYNAPSE_COMPONENTS.DOCTOR_CARD ? t : !si(e) || !si(t) ? e : {
10486
10553
  ...t,
10487
- doctors: Sh(e.doctors, t.doctors),
10554
+ doctors: Ch(e.doctors, t.doctors),
10488
10555
  doctor_details: {
10489
10556
  ...e.doctor_details || {},
10490
10557
  ...t.doctor_details || {}
@@ -10492,7 +10559,7 @@ const al = (e) => Object.fromEntries(
10492
10559
  } : e : t, pt = (e) => {
10493
10560
  const t = e;
10494
10561
  return t?.message ? t.error?.msg || t.message : e instanceof Error ? e.message : "An unexpected error occurred";
10495
- }, Ch = ({
10562
+ }, Nh = ({
10496
10563
  environment: e,
10497
10564
  connectionType: t,
10498
10565
  baseUrl: n,
@@ -10501,7 +10568,7 @@ const al = (e) => Object.fromEntries(
10501
10568
  authToken: s
10502
10569
  // onInlineText,
10503
10570
  }) => {
10504
- const [a, i] = V([]), c = G([]), [d, m] = V(!1), u = G(0), [p, h] = V(!1), [_, b] = V([]), y = G(null), f = _u(), g = G(null), { isOnline: E } = il(), N = G(!1), w = ne((R) => R.agentId), C = ne((R) => R.sessionId), T = ne((R) => R.sessionToken), S = ne((R) => R.isStreaming), v = ne((R) => R.isWaitingForResponse), x = ne((R) => R.initialMessage), O = ne((R) => R.userId), I = ne((R) => R.fileUploadPerSession), {
10571
+ const [a, i] = V([]), c = W([]), [d, m] = V(!1), u = W(0), [p, h] = V(!1), [_, b] = V([]), y = W(null), f = _u(), g = W(null), { isOnline: E } = il(), N = W(!1), w = ne((R) => R.agentId), C = ne((R) => R.sessionId), T = ne((R) => R.sessionToken), S = ne((R) => R.isStreaming), v = ne((R) => R.isWaitingForResponse), x = ne((R) => R.initialMessage), O = ne((R) => R.userId), I = ne((R) => R.fileUploadPerSession), {
10505
10572
  setSessionId: z,
10506
10573
  setSessionToken: oe,
10507
10574
  setError: P,
@@ -10518,11 +10585,11 @@ const al = (e) => Object.fromEntries(
10518
10585
  updateMessageInSession: ge,
10519
10586
  setUserId: X,
10520
10587
  setFileUploadPerSession: Ue,
10521
- setToastMessage: Ie,
10588
+ setToastMessage: xe,
10522
10589
  upsertElicitationState: Se
10523
10590
  } = ne.getState();
10524
10591
  $(() => {
10525
- E ? p ? we() && (H(Ne.CONNECTED), Ae()) : H(Ne.CONNECTING) : H(Ne.NOT_CONNECTED);
10592
+ E ? p ? we() && (H(Ne.CONNECTED), Ie()) : H(Ne.CONNECTING) : H(Ne.NOT_CONNECTED);
10526
10593
  }, [E, p]), $(() => {
10527
10594
  C && (i((R) => [...R, ...ue(C) || []]), b([]));
10528
10595
  }, [C]), $(() => {
@@ -10603,16 +10670,17 @@ const al = (e) => Object.fromEntries(
10603
10670
  }), [v, S, le]);
10604
10671
  const he = async (R, k, B = !1) => {
10605
10672
  try {
10606
- const q = await y.current?.startSession({
10673
+ const G = await y.current?.startSession({
10607
10674
  session_id: R || "",
10608
10675
  session_token: k || ""
10609
10676
  });
10610
- q?.session_id && q?.session_token && (z(q.session_id), oe(q.session_token)), q?.user_id && X(q.user_id);
10611
- } catch (q) {
10612
- const te = q, re = te.context?.stage === "handleSessionExpiry" || te.context?.stage === "refreshSession" || te.status === 404, Oe = te.status === 403;
10613
- re ? (P(null), H(Ne.NOT_CONNECTED), L(!0)) : Oe && !B ? (A(), Ae(), await he(void 0, void 0, !0)) : (P({
10677
+ G?.session_id && G?.session_token && (z(G.session_id), oe(G.session_token)), G?.user_id && X(G.user_id), G?.warnings?.length && xe(G.warnings.join(`
10678
+ `));
10679
+ } catch (G) {
10680
+ const te = G, re = te.context?.stage === "handleSessionExpiry" || te.context?.stage === "refreshSession" || te.status === 404, Ae = te.status === 403;
10681
+ re ? (P(null), H(Ne.NOT_CONNECTED), L(!0)) : Ae && !B ? (A(), Ie(), await he(void 0, void 0, !0)) : (P({
10614
10682
  title: "Connection Lost!",
10615
- description: pt(q)
10683
+ description: pt(G)
10616
10684
  }), j(!0));
10617
10685
  }
10618
10686
  }, Pe = async (R = !1) => {
@@ -10625,7 +10693,7 @@ const al = (e) => Object.fromEntries(
10625
10693
  return;
10626
10694
  }
10627
10695
  if (m(!0), R) {
10628
- H(Ne.CONNECTING), i([]), await A(), await y?.current?.endSession(), Ae(), await he(), Ot();
10696
+ H(Ne.CONNECTING), i([]), await A(), await y?.current?.endSession(), Ie(), await he(), Ot();
10629
10697
  return;
10630
10698
  }
10631
10699
  const { sessionId: k, sessionToken: B } = ne.getState();
@@ -10636,29 +10704,29 @@ const al = (e) => Object.fromEntries(
10636
10704
  }
10637
10705
  }, we = () => y.current?.isConnected() ?? !1, Le = () => {
10638
10706
  y.current?.endSession();
10639
- }, Ae = () => {
10707
+ }, Ie = () => {
10640
10708
  u.current = 0, j(!1), L(!1), P(null);
10641
10709
  }, Ot = () => {
10642
10710
  y.current?.on(M.SYNAPSE_REALTIME_EVENTS.MESSAGE_CHUNK, (R) => {
10643
10711
  const k = R;
10644
10712
  if (k.data?.text && k.messageId) {
10645
- S || (le(!1), pe(!0)), we() && H(Ne.CONNECTED), Ae();
10646
- const B = k.data.text, q = k.messageId, te = N.current;
10713
+ S || (le(!1), pe(!0)), we() && H(Ne.CONNECTED), Ie();
10714
+ const B = k.data.text, G = k.messageId, te = N.current;
10647
10715
  N.current = !1, i((re) => {
10648
- const Oe = re[re.length - 1];
10649
- if (Oe && Oe.id === q && Oe.role === je.ASSISTANT) {
10650
- const Me = [...re], ze = te && Oe.content.length > 0 && !/\s$/.test(Oe.content) && !/^\s/.test(B) ? `
10716
+ const Ae = re[re.length - 1];
10717
+ if (Ae && Ae.id === G && Ae.role === je.ASSISTANT) {
10718
+ const Oe = [...re], ze = te && Ae.content.length > 0 && !/\s$/.test(Ae.content) && !/^\s/.test(B) ? `
10651
10719
 
10652
10720
  ` : "";
10653
- return Me[Me.length - 1] = {
10654
- ...Oe,
10655
- content: Oe.content + ze + B
10656
- }, Me;
10721
+ return Oe[Oe.length - 1] = {
10722
+ ...Ae,
10723
+ content: Ae.content + ze + B
10724
+ }, Oe;
10657
10725
  } else
10658
10726
  return [
10659
10727
  ...re,
10660
10728
  {
10661
- id: q,
10729
+ id: G,
10662
10730
  content: B,
10663
10731
  role: je.ASSISTANT,
10664
10732
  timestamp: Dt(Date.now()),
@@ -10670,7 +10738,7 @@ const al = (e) => Object.fromEntries(
10670
10738
  }), y.current?.on(M.SYNAPSE_REALTIME_EVENTS.END_OF_STREAM, () => {
10671
10739
  N.current = !1, pe(!1), ee(null), le(!1);
10672
10740
  }), y.current?.on(M.SYNAPSE_REALTIME_EVENTS.CONNECTED, () => {
10673
- Ae(), H(Ne.CONNECTED);
10741
+ Ie(), H(Ne.CONNECTED);
10674
10742
  }), y.current?.on(
10675
10743
  M.SYNAPSE_REALTIME_EVENTS.TOOL_CALL,
10676
10744
  (R) => {
@@ -10679,12 +10747,12 @@ const al = (e) => Object.fromEntries(
10679
10747
  if (!k?.messageId || !k?.data || !k?.data?.details?.component || !k?.data?.tool_id)
10680
10748
  return;
10681
10749
  v && le(!1);
10682
- const { messageId: B, data: q } = k, te = q.tool_id, re = `${B}::${te}`, Me = ne.getState().elicitationState[re], ze = q.details?.component, Ze = k?.data?.details?._meta?.tool_result, se = q.details?.input, Q = wh(Me?.ui_input, se, ze);
10750
+ const { messageId: B, data: G } = k, te = G.tool_id, re = `${B}::${te}`, Oe = ne.getState().elicitationState[re], ze = G.details?.component, Ze = k?.data?.details?._meta?.tool_result, se = G.details?.input, Q = Th(Oe?.ui_input, se, ze);
10683
10751
  let Ce = k.data.details?._meta?.disp_toast_msg;
10684
- const tt = q?.details?._meta?.schema?.required || [];
10685
- switch (q?.details?.status) {
10752
+ const tt = G?.details?._meta?.schema?.required || [];
10753
+ switch (G?.details?.status) {
10686
10754
  case M.SYNAPSE_EICITATION_STATUS.PROGRESS: {
10687
- const _e = k?.data?.details?.input || {}, ie = tt.reduce((vt, Pt) => (_e[Pt] !== void 0 && (vt[Pt] = _e[Pt]), vt), {}), ft = { ...Me?.server_input || {}, ...ie }, Be = tt.filter((vt) => !ft[vt]), Zt = k.data.details?._meta?.mcp_meta_fields || [];
10755
+ const _e = k?.data?.details?.input || {}, ie = tt.reduce((vt, Pt) => (_e[Pt] !== void 0 && (vt[Pt] = _e[Pt]), vt), {}), ft = { ...Oe?.server_input || {}, ...ie }, Be = tt.filter((vt) => !ft[vt]), Zt = k.data.details?._meta?.mcp_meta_fields || [];
10688
10756
  Se(re, {
10689
10757
  tool_id: te,
10690
10758
  active: !0,
@@ -10709,7 +10777,7 @@ const al = (e) => Object.fromEntries(
10709
10777
  }
10710
10778
  case M.SYNAPSE_EICITATION_STATUS.SUCCESS: {
10711
10779
  Se(re, {
10712
- ...Me || {},
10780
+ ...Oe || {},
10713
10781
  tool_id: te,
10714
10782
  // disabled: !isActiveComponent(component),
10715
10783
  disabled: !0,
@@ -10727,11 +10795,11 @@ const al = (e) => Object.fromEntries(
10727
10795
  }
10728
10796
  case M.SYNAPSE_EICITATION_STATUS.FAILURE: {
10729
10797
  Se(re, {
10730
- ...Me || {},
10798
+ ...Oe || {},
10731
10799
  tool_id: te,
10732
10800
  active: !1,
10733
10801
  messageId: B,
10734
- response_value: { label: q?.details?._meta?.disp_message || "Tool call failed" },
10802
+ response_value: { label: G?.details?._meta?.disp_message || "Tool call failed" },
10735
10803
  tool_result: Ze,
10736
10804
  disabled: !0
10737
10805
  });
@@ -10749,7 +10817,7 @@ const al = (e) => Object.fromEntries(
10749
10817
  component: ze
10750
10818
  });
10751
10819
  }
10752
- Ce && Ie(Ce);
10820
+ Ce && xe(Ce);
10753
10821
  const ht = k?.data?.details?._meta?.user_hint;
10754
10822
  i((_e) => {
10755
10823
  let ft = _e[_e.length - 1]?.id === B ? _e.length - 1 : _e.findIndex?.((Be) => Be.id === B);
@@ -10868,10 +10936,10 @@ const al = (e) => Object.fromEntries(
10868
10936
  const k = R;
10869
10937
  if (k.data?.name && k.messageId) {
10870
10938
  const B = k.messageId;
10871
- i((q) => {
10872
- const te = q[q.length - 1];
10939
+ i((G) => {
10940
+ const te = G[G.length - 1];
10873
10941
  if (te && te.id === B && te.role === je.ASSISTANT) {
10874
- const re = [...q];
10942
+ const re = [...G];
10875
10943
  return re[re.length - 1] = {
10876
10944
  ...te,
10877
10945
  toolCallStatus: `Calling tool: ${k.data.name}...`
@@ -10879,7 +10947,7 @@ const al = (e) => Object.fromEntries(
10879
10947
  toolCallStatus: `Calling tool: ${k.data.name}...`
10880
10948
  }), re;
10881
10949
  }
10882
- return q;
10950
+ return G;
10883
10951
  });
10884
10952
  }
10885
10953
  }), y.current?.on(M.SYNAPSE_REALTIME_EVENTS.TOOL_END, (R) => {
@@ -10887,10 +10955,10 @@ const al = (e) => Object.fromEntries(
10887
10955
  const k = R;
10888
10956
  if (k.data?.name && k.messageId) {
10889
10957
  const B = k.messageId;
10890
- i((q) => {
10891
- const te = q[q.length - 1];
10958
+ i((G) => {
10959
+ const te = G[G.length - 1];
10892
10960
  if (te && te.id === B && te.role === je.ASSISTANT) {
10893
- const re = [...q];
10961
+ const re = [...G];
10894
10962
  return re[re.length - 1] = {
10895
10963
  ...te,
10896
10964
  toolCallStatus: "Tool call completed."
@@ -10898,7 +10966,7 @@ const al = (e) => Object.fromEntries(
10898
10966
  toolCallStatus: "Tool call completed."
10899
10967
  }), re;
10900
10968
  }
10901
- return q;
10969
+ return G;
10902
10970
  });
10903
10971
  }
10904
10972
  });
@@ -10906,15 +10974,15 @@ const al = (e) => Object.fromEntries(
10906
10974
  message: R,
10907
10975
  files: k,
10908
10976
  audio: B,
10909
- toolCalled: q,
10977
+ toolCalled: G,
10910
10978
  selectedComponent: te,
10911
10979
  resend: re,
10912
- tool_declined: Oe,
10913
- tool_result: Me,
10980
+ tool_declined: Ae,
10981
+ tool_result: Oe,
10914
10982
  tool_key: ze
10915
10983
  }) => {
10916
10984
  const Ze = ne.getState().elicitationState, se = Object.values(Ze).some((Q) => Q.active);
10917
- if (!(!q && k && k.length === 0 && R?.trim() === "" && !B?.audio && !te && !se && !Me && !Object.keys(Me || {}).length)) {
10985
+ if (!(!G && k && k.length === 0 && R?.trim() === "" && !B?.audio && !te && !se && !Oe && !Object.keys(Oe || {}).length)) {
10918
10986
  if (k && k.length > 3) {
10919
10987
  P({
10920
10988
  title: "Maximum 3 files are allowed to be sent at a time",
@@ -10941,18 +11009,18 @@ const al = (e) => Object.fromEntries(
10941
11009
  try {
10942
11010
  const Q = a.length == 2 && _.length == 2 ? _ : null;
10943
11011
  let Ce = null;
10944
- const tt = a.length - 1, ht = tt >= 0 ? a[tt] : null, Pn = ne.getState().elicitationState, _e = ze || null, ie = _e ? Pn[_e] : void 0, Be = ie?.component === M.SYNAPSE_COMPONENTS.DOCTOR_CARD || ie?.component === M.SYNAPSE_COMPONENTS.CARD ? !!ie && !Me && !!ie.active : !!ie?.active, Zt = !!(k || []).length || !!B?.audio || !!Oe || !Be || !q, vt = te ? te.label : void 0, Pt = ie?.component === M.SYNAPSE_COMPONENTS.PILL && typeof vt == "string" ? vt : null;
11012
+ const tt = a.length - 1, ht = tt >= 0 ? a[tt] : null, Pn = ne.getState().elicitationState, _e = ze || null, ie = _e ? Pn[_e] : void 0, Be = ie?.component === M.SYNAPSE_COMPONENTS.DOCTOR_CARD || ie?.component === M.SYNAPSE_COMPONENTS.CARD ? !!ie && !Oe && !!ie.active : !!ie?.active, Zt = !!(k || []).length || !!B?.audio || !!Ae || !Be || !G, vt = te ? te.label : void 0, Pt = ie?.component === M.SYNAPSE_COMPONENTS.PILL && typeof vt == "string" ? vt : null;
10945
11013
  if (!Zt && Be && _e && ie?.messageId) {
10946
- const xe = ie.toolSelectionNames?.length ? ie.toolSelectionNames : ie.required?.filter((ve) => !ie.server_input?.[ve]) ?? [], nt = xe.reduce((ve, Ee) => {
11014
+ const ke = ie.toolSelectionNames?.length ? ie.toolSelectionNames : ie.required?.filter((ve) => !ie.server_input?.[ve]) ?? [], nt = ke.reduce((ve, Ee) => {
10947
11015
  if (te) {
10948
11016
  const Xt = te[Ee];
10949
11017
  Xt !== void 0 && (ve[Ee] = Xt);
10950
- } else xe.length === 1 && (ve[Ee] = R);
11018
+ } else ke.length === 1 && (ve[Ee] = R);
10951
11019
  return ve;
10952
- }, {}), Dn = ie.mcp_meta_fields?.reduce((ve, Ee) => (xe.includes(Ee) ? ve[Ee] = nt[Ee] : ie.server_input?.[Ee] && (ve[Ee] = ie.server_input[Ee]), re && !ve.is_resend && (ve.is_resend = re), ve), {}), El = Object.keys(ie.server_input || {})?.reduce((ve, Ee) => {
11020
+ }, {}), Dn = ie.mcp_meta_fields?.reduce((ve, Ee) => (ke.includes(Ee) ? ve[Ee] = nt[Ee] : ie.server_input?.[Ee] && (ve[Ee] = ie.server_input[Ee]), re && !ve.is_resend && (ve.is_resend = re), ve), {}), El = Object.keys(ie.server_input || {})?.reduce((ve, Ee) => {
10953
11021
  const Xt = !Object.keys(Dn || {})?.includes(Ee), Fo = !!ie.server_input?.[Ee];
10954
11022
  return (re ? Xt && Fo : Xt && ie.required?.includes(Ee) && Fo) && (ve[Ee] = ie.server_input?.[Ee]), ve;
10955
- }, {}), bl = re ? {} : (ie.required || xe).reduce((ve, Ee) => (Object.keys(Dn || {}).includes(Ee) || (nt[Ee] !== void 0 ? ve[Ee] = nt[Ee] : te && te[Ee] !== void 0 && (ve[Ee] = te[Ee])), ve), {}), pr = {
11023
+ }, {}), bl = re ? {} : (ie.required || ke).reduce((ve, Ee) => (Object.keys(Dn || {}).includes(Ee) || (nt[Ee] !== void 0 ? ve[Ee] = nt[Ee] : te && te[Ee] !== void 0 && (ve[Ee] = te[Ee])), ve), {}), pr = {
10956
11024
  ...El || {},
10957
11025
  //existing inputs
10958
11026
  ...bl,
@@ -10977,22 +11045,22 @@ const al = (e) => Object.fromEntries(
10977
11045
  });
10978
11046
  }
10979
11047
  } else {
10980
- const xe = Me ?? ie?.tool_result;
11048
+ const ke = Oe ?? ie?.tool_result;
10981
11049
  await y.current?.sendMessage({
10982
11050
  message: R,
10983
11051
  files: k,
10984
11052
  audio: B,
10985
11053
  ...Q && { initial_prompts: Q },
10986
- ...Oe ? {
11054
+ ...Ae ? {
10987
11055
  tool_declined: !0,
10988
11056
  tool_id: ie?.tool_id || ""
10989
11057
  } : {},
10990
- ...xe && { tool_result: xe }
11058
+ ...ke && { tool_result: ke }
10991
11059
  });
10992
11060
  }
10993
- (R || k && k.length > 0 || B?.audio) && (i((xe) => {
10994
- if (Ce) return xe;
10995
- const nt = xe.length === 0 && x?.text ? [{
11061
+ (R || k && k.length > 0 || B?.audio) && (i((ke) => {
11062
+ if (Ce) return ke;
11063
+ const nt = ke.length === 0 && x?.text ? [{
10996
11064
  id: "initial-bot-message",
10997
11065
  content: x.text,
10998
11066
  role: je.ASSISTANT,
@@ -11000,7 +11068,7 @@ const al = (e) => Object.fromEntries(
11000
11068
  isStored: !1
11001
11069
  }] : [];
11002
11070
  return [
11003
- ...xe,
11071
+ ...ke,
11004
11072
  ...nt,
11005
11073
  {
11006
11074
  id: Date.now().toString(),
@@ -11014,12 +11082,12 @@ const al = (e) => Object.fromEntries(
11014
11082
  ];
11015
11083
  }), Ce || le(!0), Ce = null);
11016
11084
  const _l = ne.getState().elicitationState, Ln = /* @__PURE__ */ new Set();
11017
- _e && Ln.add(_e), _e && Ln.add(_e), ht?.tool_keys?.forEach((xe) => Ln.add(xe)), Ln.forEach((xe) => {
11018
- const nt = _l[xe];
11019
- nt && Se(xe, {
11085
+ _e && Ln.add(_e), _e && Ln.add(_e), ht?.tool_keys?.forEach((ke) => Ln.add(ke)), Ln.forEach((ke) => {
11086
+ const nt = _l[ke];
11087
+ nt && Se(ke, {
11020
11088
  ...nt,
11021
11089
  ...Zt && { active: !1, disabled: !0 },
11022
- ...xe === _e ? {
11090
+ ...ke === _e ? {
11023
11091
  response_value: {
11024
11092
  ...nt?.response_value || {},
11025
11093
  label: Pt || R || ""
@@ -11065,11 +11133,11 @@ const al = (e) => Object.fromEntries(
11065
11133
  k,
11066
11134
  B
11067
11135
  );
11068
- } catch (q) {
11069
- throw q;
11136
+ } catch (G) {
11137
+ throw G;
11070
11138
  }
11071
11139
  }, fr = async () => {
11072
- Ae(), await A(), await Pe(!0);
11140
+ Ie(), await A(), await Pe(!0);
11073
11141
  }, Mn = async () => {
11074
11142
  if (we()) {
11075
11143
  H(Ne.CONNECTED);
@@ -11148,34 +11216,34 @@ const al = (e) => Object.fromEntries(
11148
11216
  }
11149
11217
  },
11150
11218
  clearElicitationState: async (R, k) => {
11151
- const B = ne.getState().elicitationState, q = R ? B[R] : void 0;
11219
+ const B = ne.getState().elicitationState, G = R ? B[R] : void 0;
11152
11220
  try {
11153
11221
  await et({
11154
11222
  message: k || "User aborted elicitation",
11155
11223
  tool_declined: !0,
11156
- tool_result: q?.tool_result,
11224
+ tool_result: G?.tool_result,
11157
11225
  tool_key: R
11158
11226
  });
11159
11227
  } catch {
11160
11228
  } finally {
11161
- R && q && Se(R, { ...q, active: !1, disabled: !0 });
11229
+ R && G && Se(R, { ...G, active: !1, disabled: !0 });
11162
11230
  }
11163
11231
  }
11164
11232
  };
11165
- }, Th = 32, Nh = 100, xh = 320;
11166
- function kh() {
11233
+ }, xh = 32, kh = 100, Rh = 320;
11234
+ function Ih() {
11167
11235
  return typeof window > "u" || !window.matchMedia ? !1 : window.matchMedia("(prefers-reduced-motion: reduce)").matches;
11168
11236
  }
11169
- function Rh({
11237
+ function Ah({
11170
11238
  messageCount: e,
11171
11239
  isStreaming: t,
11172
11240
  isFirstMessage: n,
11173
11241
  resolvedMode: r
11174
11242
  }) {
11175
- const o = G(null), s = G(null), [a, i] = V(!1), c = G(null), d = G(!1), m = G("auto"), u = G(!0), p = ae(() => o.current?.querySelector(
11243
+ const o = W(null), s = W(null), [a, i] = V(!1), c = W(null), d = W(!1), m = W("auto"), u = W(!0), p = ae(() => o.current?.querySelector(
11176
11244
  "[data-radix-scroll-area-viewport]"
11177
11245
  ) || null, []), h = ae(
11178
- (y) => kh() ? "auto" : y,
11246
+ (y) => Ih() ? "auto" : y,
11179
11247
  []
11180
11248
  ), _ = ae(
11181
11249
  (y) => {
@@ -11203,7 +11271,7 @@ function Rh({
11203
11271
  if (!e || !u.current) return;
11204
11272
  const y = setTimeout(
11205
11273
  () => b("auto"),
11206
- xh
11274
+ Rh
11207
11275
  );
11208
11276
  return () => clearTimeout(y);
11209
11277
  }, [r, e, b]), $(() => {
@@ -11217,7 +11285,7 @@ function Rh({
11217
11285
  }
11218
11286
  const S = () => {
11219
11287
  const { scrollTop: O, scrollHeight: I, clientHeight: z } = w;
11220
- return I - O - z <= Th;
11288
+ return I - O - z <= xh;
11221
11289
  };
11222
11290
  u.current = !0;
11223
11291
  let v = 0;
@@ -11231,7 +11299,7 @@ function Rh({
11231
11299
  w.addEventListener("scroll", x, { passive: !0 }), g = () => w.removeEventListener("scroll", x), f = new ResizeObserver(() => {
11232
11300
  if (!u.current) return;
11233
11301
  const O = Date.now();
11234
- O - E < Nh || (E = O, v++, b("auto"));
11302
+ O - E < kh || (E = O, v++, b("auto"));
11235
11303
  }), f.observe(T);
11236
11304
  };
11237
11305
  return N(), () => {
@@ -11245,7 +11313,7 @@ function Rh({
11245
11313
  scheduleScrollToBottom: b
11246
11314
  };
11247
11315
  }
11248
- function Ih({ isOpen: e, agentId: t, config: n }) {
11316
+ function Oh({ isOpen: e, agentId: t, config: n }) {
11249
11317
  const {
11250
11318
  state: r,
11251
11319
  isMuted: o,
@@ -11257,7 +11325,7 @@ function Ih({ isOpen: e, agentId: t, config: n }) {
11257
11325
  r === M.VOICE_AGENT_STATE.IDLE && s();
11258
11326
  }, m = r !== M.VOICE_AGENT_STATE.IDLE, [u, p] = V(""), [h, _] = V(!1), b = ne((se) => se.setDisplayMode), [y, f] = V(
11259
11327
  n.displayMode === "full" ? "full" : "widget"
11260
- ), g = () => f((se) => se === "full" ? "widget" : "full"), N = ol() ? "mobile" : y, [w, C] = V([]), T = G(!1), [S, v] = V(!1), x = G(null), {
11328
+ ), g = () => f((se) => se === "full" ? "widget" : "full"), N = ol() ? "mobile" : y, [w, C] = V([]), T = W(!1), [S, v] = V(!1), x = W(null), {
11261
11329
  setAgentId: O,
11262
11330
  startNewConnection: I,
11263
11331
  showRetryButton: z,
@@ -11276,16 +11344,16 @@ function Ih({ isOpen: e, agentId: t, config: n }) {
11276
11344
  } = ne(), ge = ne((se) => se.elicitationState), {
11277
11345
  incomingMessages: X,
11278
11346
  loading: Ue,
11279
- sendMessage: Ie,
11347
+ sendMessage: xe,
11280
11348
  startSession: Se,
11281
11349
  isReady: he,
11282
11350
  startRecording: Pe,
11283
11351
  stopRecording: we,
11284
11352
  handleRetry: Le,
11285
- isValidFile: Ae,
11353
+ isValidFile: Ie,
11286
11354
  handleToggleFeedback: Ot,
11287
11355
  clearElicitationState: et
11288
- } = Ch({
11356
+ } = Nh({
11289
11357
  environment: n.environment,
11290
11358
  connectionType: n.connectionType,
11291
11359
  baseUrl: n.baseUrl ? n.baseUrl : void 0,
@@ -11311,22 +11379,22 @@ function Ih({ isOpen: e, agentId: t, config: n }) {
11311
11379
  messagesEndRef: Lo,
11312
11380
  showScrollButton: Do,
11313
11381
  scrollToBottom: R
11314
- } = Rh({
11382
+ } = Ah({
11315
11383
  messageCount: X.length,
11316
11384
  isStreaming: pe,
11317
11385
  isFirstMessage: Mt,
11318
11386
  resolvedMode: N
11319
- }), k = H === M.ConnectionStatus.CONNECTED, B = L || pe, q = de(() => j === me.IDLE ? null : j === me.LISTENING ? "Listening..." : j === me.PROCESSING ? "Processing..." : j === me.TRANSCRIBING ? "Transcribing..." : null, [j]), te = q && j !== me.IDLE ? q : L || pe ? "Please wait for the response..." : "Type a reply…", re = async (se) => {
11387
+ }), k = H === M.ConnectionStatus.CONNECTED, B = L || pe, G = de(() => j === me.IDLE ? null : j === me.LISTENING ? "Listening..." : j === me.PROCESSING ? "Processing..." : j === me.TRANSCRIBING ? "Transcribing..." : null, [j]), te = G && j !== me.IDLE ? G : L || pe ? "Please wait for the response..." : "Type a reply…", re = async (se) => {
11320
11388
  if (B)
11321
11389
  return;
11322
11390
  const Q = se?.message ?? u;
11323
- (Q.trim() || h || S || se?.resend) && (w.length > 0 ? (await Ie({
11391
+ (Q.trim() || h || S || se?.resend) && (w.length > 0 ? (await xe({
11324
11392
  files: w,
11325
11393
  message: Q.trim()
11326
- }), C([]), v(!1)) : Q.trim() ? await Ie({ ...se, message: Q.trim() }) : se?.resend && await Ie(se), p(""), _(!1), v(!1));
11327
- }, Oe = (se) => {
11394
+ }), C([]), v(!1)) : Q.trim() ? await xe({ ...se, message: Q.trim() }) : se?.resend && await xe(se), p(""), _(!1), v(!1));
11395
+ }, Ae = (se) => {
11328
11396
  if (se && se.length > 0) {
11329
- const Q = se.filter((Ce) => !!Ae(Ce));
11397
+ const Q = se.filter((Ce) => !!Ie(Ce));
11330
11398
  if (Q?.length + w.length > 3) {
11331
11399
  le({
11332
11400
  title: "You can only upload up to 3 files at a time",
@@ -11347,7 +11415,7 @@ function Ih({ isOpen: e, agentId: t, config: n }) {
11347
11415
  return;
11348
11416
  }
11349
11417
  C((Q) => (v((Q?.length ?? 0) + (se?.length ?? 0) > 0), [...Q, ...se]));
11350
- }, Me = (se) => {
11418
+ }, Oe = (se) => {
11351
11419
  C((Q) => {
11352
11420
  const Ce = Q.filter((tt, ht) => ht !== se);
11353
11421
  return v(Ce.length > 0), Ce;
@@ -11366,8 +11434,8 @@ function Ih({ isOpen: e, agentId: t, config: n }) {
11366
11434
  value: u,
11367
11435
  onChange: p,
11368
11436
  onSend: re,
11369
- onFileChange: Oe,
11370
- onRemoveFile: Me,
11437
+ onFileChange: Ae,
11438
+ onRemoveFile: Oe,
11371
11439
  onRecording: ze,
11372
11440
  isRecording: h,
11373
11441
  hasAttachment: S,
@@ -11420,15 +11488,15 @@ function Ih({ isOpen: e, agentId: t, config: n }) {
11420
11488
  initialMessage: A,
11421
11489
  // Chat hook values
11422
11490
  incomingMessages: X,
11423
- sendMessage: Ie,
11491
+ sendMessage: xe,
11424
11492
  startSession: Se,
11425
11493
  handleToggleFeedback: Ot,
11426
11494
  clearElicitationState: et,
11427
11495
  handleRetry: Le,
11428
11496
  // Handlers
11429
11497
  handleSendMessage: re,
11430
- handleFileChange: Oe,
11431
- handleRemoveFile: Me,
11498
+ handleFileChange: Ae,
11499
+ handleRemoveFile: Oe,
11432
11500
  handleRecording: ze,
11433
11501
  scrollToBottom: R,
11434
11502
  // Composer props (pre-built)
@@ -11453,7 +11521,7 @@ function kt() {
11453
11521
  return e;
11454
11522
  }, kt.apply(this, arguments);
11455
11523
  }
11456
- const Ah = ["children", "options"], ii = ["allowFullScreen", "allowTransparency", "autoComplete", "autoFocus", "autoPlay", "cellPadding", "cellSpacing", "charSet", "classId", "colSpan", "contentEditable", "contextMenu", "crossOrigin", "encType", "formAction", "formEncType", "formMethod", "formNoValidate", "formTarget", "frameBorder", "hrefLang", "inputMode", "keyParams", "keyType", "marginHeight", "marginWidth", "maxLength", "mediaGroup", "minLength", "noValidate", "radioGroup", "readOnly", "rowSpan", "spellCheck", "srcDoc", "srcLang", "srcSet", "tabIndex", "useMap"].reduce((e, t) => (e[t.toLowerCase()] = t, e), { class: "className", for: "htmlFor" }), ai = { amp: "&", apos: "'", gt: ">", lt: "<", nbsp: " ", quot: "“" }, Oh = ["style", "script", "pre"], Mh = ["src", "href", "data", "formAction", "srcDoc", "action"], Ph = /([-A-Z0-9_:]+)(?:\s*=\s*(?:(?:"((?:\\.|[^"])*)")|(?:'((?:\\.|[^'])*)')|(?:\{((?:\\.|{[^}]*?}|[^}])*)\})))?/gi, Lh = /\n{2,}$/, li = /^(\s*>[\s\S]*?)(?=\n\n|$)/, Dh = /^ *> ?/gm, Fh = /^(?:\[!([^\]]*)\]\n)?([\s\S]*)/, Uh = /^ {2,}\n/, Vh = /^(?:([-*_])( *\1){2,}) *(?:\n *)+\n/, ci = /^(?: {1,3})?(`{3,}|~{3,}) *(\S+)? *([^\n]*?)?\n([\s\S]*?)(?:\1\n?|$)/, di = /^(?: {4}[^\n]+\n*)+(?:\n *)+\n?/, $h = /^(`+)((?:\\`|(?!\1)`|[^`])+)\1/, zh = /^(?:\n *)*\n/, Bh = /\r\n?/g, jh = /^\[\^([^\]]+)](:(.*)((\n+ {4,}.*)|(\n(?!\[\^).+))*)/, Hh = /^\[\^([^\]]+)]/, Gh = /\f/g, Wh = /^---[ \t]*\n(.|\n)*\n---[ \t]*\n/, qh = /^\s*?\[(x|\s)\]/, ui = /^ *(#{1,6}) *([^\n]+?)(?: +#*)?(?:\n *)*(?:\n|$)/, hi = /^ *(#{1,6}) +([^\n]+?)(?: +#*)?(?:\n *)*(?:\n|$)/, fi = /^([^\n]+)\n *(=|-)\2{2,} *\n/, Mr = /^ *(?!<[a-z][^ >/]* ?\/>)<([a-z][^ >/]*) ?((?:[^>]*[^/])?)>\n?(\s*(?:<\1[^>]*?>[\s\S]*?<\/\1>|(?!<\1\b)[\s\S])*?)<\/\1>(?!<\/\1>)\n*/i, Yh = /&([a-z0-9]+|#[0-9]{1,6}|#x[0-9a-fA-F]{1,6});/gi, mi = /^<!--[\s\S]*?(?:-->)/, Kh = /^(data|aria|x)-[a-z_][a-z\d_.-]*$/, Pr = /^ *<([a-z][a-z0-9:]*)(?:\s+((?:<.*?>|[^>])*))?\/?>(?!<\/\1>)(\s*\n)?/i, Zh = /^\{.*\}$/, Xh = /^(https?:\/\/[^\s<]+[^<.,:;"')\]\s])/, Jh = /^<([^ >]+[:@\/][^ >]+)>/, Qh = /-([a-z])?/gi, pi = /^(\|.*)\n(?: *(\|? *[-:]+ *\|[-| :]*)\n((?:.*\|.*\n)*))?\n?/, ef = /^[^\n]+(?: \n|\n{2,})/, tf = /^\[([^\]]*)\]:\s+<?([^\s>]+)>?\s*("([^"]*)")?/, nf = /^!\[([^\]]*)\] ?\[([^\]]*)\]/, rf = /^\[([^\]]*)\] ?\[([^\]]*)\]/, of = /(\n|^[-*]\s|^#|^ {2,}|^-{2,}|^>\s)/, sf = /\t/g, af = /(^ *\||\| *$)/g, lf = /^ *:-+: *$/, cf = /^ *:-+ *$/, df = /^ *-+: *$/, ur = (e) => `(?=[\\s\\S]+?\\1${e ? "\\1" : ""})`, hr = "((?:\\[.*?\\][([].*?[)\\]]|<.*?>(?:.*?<.*?>)?|`.*?`|\\\\\\1|[\\s\\S])+?)", uf = RegExp(`^([*_])\\1${ur(1)}${hr}\\1\\1(?!\\1)`), hf = RegExp(`^([*_])${ur(0)}${hr}\\1(?!\\1)`), ff = RegExp(`^(==)${ur(0)}${hr}\\1`), mf = RegExp(`^(~~)${ur(0)}${hr}\\1`), pf = /^(:[a-zA-Z0-9-_]+:)/, gf = /^\\([^0-9A-Za-z\s])/, _f = /\\([^0-9A-Za-z\s])/g, Ef = /^[\s\S](?:(?! \n|[0-9]\.|http)[^=*_~\-\n:<`\\\[!])*/, bf = /^\n+/, yf = /^([ \t]*)/, vf = /(?:^|\n)( *)$/, Oo = "(?:\\d+\\.)", Mo = "(?:[*+-])";
11524
+ const Mh = ["children", "options"], ii = ["allowFullScreen", "allowTransparency", "autoComplete", "autoFocus", "autoPlay", "cellPadding", "cellSpacing", "charSet", "classId", "colSpan", "contentEditable", "contextMenu", "crossOrigin", "encType", "formAction", "formEncType", "formMethod", "formNoValidate", "formTarget", "frameBorder", "hrefLang", "inputMode", "keyParams", "keyType", "marginHeight", "marginWidth", "maxLength", "mediaGroup", "minLength", "noValidate", "radioGroup", "readOnly", "rowSpan", "spellCheck", "srcDoc", "srcLang", "srcSet", "tabIndex", "useMap"].reduce((e, t) => (e[t.toLowerCase()] = t, e), { class: "className", for: "htmlFor" }), ai = { amp: "&", apos: "'", gt: ">", lt: "<", nbsp: " ", quot: "“" }, Ph = ["style", "script", "pre"], Lh = ["src", "href", "data", "formAction", "srcDoc", "action"], Dh = /([-A-Z0-9_:]+)(?:\s*=\s*(?:(?:"((?:\\.|[^"])*)")|(?:'((?:\\.|[^'])*)')|(?:\{((?:\\.|{[^}]*?}|[^}])*)\})))?/gi, Fh = /\n{2,}$/, li = /^(\s*>[\s\S]*?)(?=\n\n|$)/, Uh = /^ *> ?/gm, Vh = /^(?:\[!([^\]]*)\]\n)?([\s\S]*)/, $h = /^ {2,}\n/, zh = /^(?:([-*_])( *\1){2,}) *(?:\n *)+\n/, ci = /^(?: {1,3})?(`{3,}|~{3,}) *(\S+)? *([^\n]*?)?\n([\s\S]*?)(?:\1\n?|$)/, di = /^(?: {4}[^\n]+\n*)+(?:\n *)+\n?/, Bh = /^(`+)((?:\\`|(?!\1)`|[^`])+)\1/, jh = /^(?:\n *)*\n/, Hh = /\r\n?/g, Gh = /^\[\^([^\]]+)](:(.*)((\n+ {4,}.*)|(\n(?!\[\^).+))*)/, Wh = /^\[\^([^\]]+)]/, qh = /\f/g, Yh = /^---[ \t]*\n(.|\n)*\n---[ \t]*\n/, Kh = /^\s*?\[(x|\s)\]/, ui = /^ *(#{1,6}) *([^\n]+?)(?: +#*)?(?:\n *)*(?:\n|$)/, hi = /^ *(#{1,6}) +([^\n]+?)(?: +#*)?(?:\n *)*(?:\n|$)/, fi = /^([^\n]+)\n *(=|-)\2{2,} *\n/, Mr = /^ *(?!<[a-z][^ >/]* ?\/>)<([a-z][^ >/]*) ?((?:[^>]*[^/])?)>\n?(\s*(?:<\1[^>]*?>[\s\S]*?<\/\1>|(?!<\1\b)[\s\S])*?)<\/\1>(?!<\/\1>)\n*/i, Zh = /&([a-z0-9]+|#[0-9]{1,6}|#x[0-9a-fA-F]{1,6});/gi, mi = /^<!--[\s\S]*?(?:-->)/, Xh = /^(data|aria|x)-[a-z_][a-z\d_.-]*$/, Pr = /^ *<([a-z][a-z0-9:]*)(?:\s+((?:<.*?>|[^>])*))?\/?>(?!<\/\1>)(\s*\n)?/i, Jh = /^\{.*\}$/, Qh = /^(https?:\/\/[^\s<]+[^<.,:;"')\]\s])/, ef = /^<([^ >]+[:@\/][^ >]+)>/, tf = /-([a-z])?/gi, pi = /^(\|.*)\n(?: *(\|? *[-:]+ *\|[-| :]*)\n((?:.*\|.*\n)*))?\n?/, nf = /^[^\n]+(?: \n|\n{2,})/, rf = /^\[([^\]]*)\]:\s+<?([^\s>]+)>?\s*("([^"]*)")?/, of = /^!\[([^\]]*)\] ?\[([^\]]*)\]/, sf = /^\[([^\]]*)\] ?\[([^\]]*)\]/, af = /(\n|^[-*]\s|^#|^ {2,}|^-{2,}|^>\s)/, lf = /\t/g, cf = /(^ *\||\| *$)/g, df = /^ *:-+: *$/, uf = /^ *:-+ *$/, hf = /^ *-+: *$/, ur = (e) => `(?=[\\s\\S]+?\\1${e ? "\\1" : ""})`, hr = "((?:\\[.*?\\][([].*?[)\\]]|<.*?>(?:.*?<.*?>)?|`.*?`|\\\\\\1|[\\s\\S])+?)", ff = RegExp(`^([*_])\\1${ur(1)}${hr}\\1\\1(?!\\1)`), mf = RegExp(`^([*_])${ur(0)}${hr}\\1(?!\\1)`), pf = RegExp(`^(==)${ur(0)}${hr}\\1`), gf = RegExp(`^(~~)${ur(0)}${hr}\\1`), _f = /^(:[a-zA-Z0-9-_]+:)/, Ef = /^\\([^0-9A-Za-z\s])/, bf = /\\([^0-9A-Za-z\s])/g, yf = /^[\s\S](?:(?! \n|[0-9]\.|http)[^=*_~\-\n:<`\\\[!])*/, vf = /^\n+/, Sf = /^([ \t]*)/, wf = /(?:^|\n)( *)$/, Oo = "(?:\\d+\\.)", Mo = "(?:[*+-])";
11457
11525
  function ll(e) {
11458
11526
  return "( *)(" + (e === 1 ? Oo : Mo) + ") +";
11459
11527
  }
@@ -11461,23 +11529,23 @@ const cl = ll(1), dl = ll(2);
11461
11529
  function ul(e) {
11462
11530
  return RegExp("^" + (e === 1 ? cl : dl));
11463
11531
  }
11464
- const Sf = ul(1), wf = ul(2);
11532
+ const Cf = ul(1), Tf = ul(2);
11465
11533
  function hl(e) {
11466
11534
  return RegExp("^" + (e === 1 ? cl : dl) + "[^\\n]*(?:\\n(?!\\1" + (e === 1 ? Oo : Mo) + " )[^\\n]*)*(\\n|$)", "gm");
11467
11535
  }
11468
- const Cf = hl(1), Tf = hl(2);
11536
+ const Nf = hl(1), xf = hl(2);
11469
11537
  function fl(e) {
11470
11538
  const t = e === 1 ? Oo : Mo;
11471
11539
  return RegExp("^( *)(" + t + ") [\\s\\S]+?(?:\\n{2,}(?! )(?!\\1" + t + " (?!" + t + " ))\\n*|\\s*\\n*$)");
11472
11540
  }
11473
11541
  const ml = fl(1), pl = fl(2);
11474
11542
  function gi(e, t) {
11475
- const n = t === 1, r = n ? ml : pl, o = n ? Cf : Tf, s = n ? Sf : wf;
11543
+ const n = t === 1, r = n ? ml : pl, o = n ? Nf : xf, s = n ? Cf : Tf;
11476
11544
  return { t: (a) => s.test(a), o: Ht(function(a, i) {
11477
- const c = vf.exec(i.prevCapture);
11545
+ const c = wf.exec(i.prevCapture);
11478
11546
  return c && (i.list || !i.inline && !i.simple) ? r.exec(a = c[1] + a) : null;
11479
11547
  }), i: 1, u(a, i, c) {
11480
- const d = n ? +a[2] : void 0, m = a[0].replace(Lh, `
11548
+ const d = n ? +a[2] : void 0, m = a[0].replace(Fh, `
11481
11549
  `).match(o);
11482
11550
  let u = !1;
11483
11551
  return { items: m.map(function(p, h) {
@@ -11497,7 +11565,7 @@ function gi(e, t) {
11497
11565
  return e("li", { key: m }, i(d, c));
11498
11566
  })) };
11499
11567
  }
11500
- const Nf = RegExp(`^\\[((?:\\[[^\\[\\]]*(?:\\[[^\\[\\]]*\\][^\\[\\]]*)*\\]|[^\\[\\]])*)\\]\\(\\s*<?((?:\\([^)]*\\)|[^\\s\\\\]|\\\\.)*?)>?(?:\\s+['"]([\\s\\S]*?)['"])?\\s*\\)`), xf = /^!\[(.*?)\]\( *((?:\([^)]*\)|[^() ])*) *"?([^)"]*)?"?\)/;
11568
+ const kf = RegExp(`^\\[((?:\\[[^\\[\\]]*(?:\\[[^\\[\\]]*\\][^\\[\\]]*)*\\]|[^\\[\\]])*)\\]\\(\\s*<?((?:\\([^)]*\\)|[^\\s\\\\]|\\\\.)*?)>?(?:\\s+['"]([\\s\\S]*?)['"])?\\s*\\)`), Rf = /^!\[(.*?)\]\( *((?:\([^)]*\)|[^() ])*) *"?([^)"]*)?"?\)/;
11501
11569
  function _i(e) {
11502
11570
  return typeof e == "string";
11503
11571
  }
@@ -11509,7 +11577,7 @@ function Tn(e) {
11509
11577
  function Zn(e, t) {
11510
11578
  return e.startsWith(t);
11511
11579
  }
11512
- function kf(e, t, n) {
11580
+ function If(e, t, n) {
11513
11581
  if (Array.isArray(n)) {
11514
11582
  for (let r = 0; r < n.length; r++) if (Zn(e, n[r])) return !0;
11515
11583
  return !1;
@@ -11519,8 +11587,8 @@ function kf(e, t, n) {
11519
11587
  function vn(e) {
11520
11588
  return e.replace(/[ÀÁÂÃÄÅàáâãä忯]/g, "a").replace(/[çÇ]/g, "c").replace(/[ðÐ]/g, "d").replace(/[ÈÉÊËéèêë]/g, "e").replace(/[ÏïÎîÍíÌì]/g, "i").replace(/[Ññ]/g, "n").replace(/[øØœŒÕõÔôÓóÒò]/g, "o").replace(/[ÜüÛûÚúÙù]/g, "u").replace(/[ŸÿÝý]/g, "y").replace(/[^a-z0-9- ]/gi, "").replace(/ /gi, "-").toLowerCase();
11521
11589
  }
11522
- function Rf(e) {
11523
- return df.test(e) ? "right" : lf.test(e) ? "center" : cf.test(e) ? "left" : null;
11590
+ function Af(e) {
11591
+ return hf.test(e) ? "right" : df.test(e) ? "center" : uf.test(e) ? "left" : null;
11524
11592
  }
11525
11593
  function Ei(e, t, n, r) {
11526
11594
  const o = n.inTable;
@@ -11535,9 +11603,9 @@ function Ei(e, t, n, r) {
11535
11603
  c.trim() === "|" && (i(), r) ? d !== 0 && d !== m.length - 1 && s.push([]) : a += c;
11536
11604
  }), i(), n.inTable = o, s;
11537
11605
  }
11538
- function If(e, t, n) {
11606
+ function Of(e, t, n) {
11539
11607
  n.inline = !0;
11540
- const r = e[2] ? e[2].replace(af, "").split("|").map(Rf) : [], o = e[3] ? (function(a, i, c) {
11608
+ const r = e[2] ? e[2].replace(cf, "").split("|").map(Af) : [], o = e[3] ? (function(a, i, c) {
11541
11609
  return a.trim().split(`
11542
11610
  `).map(function(d) {
11543
11611
  return Ei(d, i, c, !0);
@@ -11571,18 +11639,18 @@ function Wn(e) {
11571
11639
  return e.exec(t);
11572
11640
  });
11573
11641
  }
11574
- const Af = /(javascript|vbscript|data(?!:image)):/i;
11575
- function Of(e) {
11642
+ const Mf = /(javascript|vbscript|data(?!:image)):/i;
11643
+ function Pf(e) {
11576
11644
  try {
11577
11645
  const t = decodeURIComponent(e).replace(/[^A-Za-z0-9/:]/g, "");
11578
- if (Af.test(t)) return null;
11646
+ if (Mf.test(t)) return null;
11579
11647
  } catch {
11580
11648
  return null;
11581
11649
  }
11582
11650
  return e;
11583
11651
  }
11584
11652
  function Xe(e) {
11585
- return e && e.replace(_f, "$1");
11653
+ return e && e.replace(bf, "$1");
11586
11654
  }
11587
11655
  function Xn(e, t, n) {
11588
11656
  const r = n.inline || !1, o = n.simple || !1;
@@ -11590,13 +11658,13 @@ function Xn(e, t, n) {
11590
11658
  const s = e(t, n);
11591
11659
  return n.inline = r, n.simple = o, s;
11592
11660
  }
11593
- function Mf(e, t, n) {
11661
+ function Lf(e, t, n) {
11594
11662
  const r = n.inline || !1, o = n.simple || !1;
11595
11663
  n.inline = !1, n.simple = !0;
11596
11664
  const s = e(t, n);
11597
11665
  return n.inline = r, n.simple = o, s;
11598
11666
  }
11599
- function Pf(e, t, n) {
11667
+ function Df(e, t, n) {
11600
11668
  const r = n.inline || !1;
11601
11669
  n.inline = !1;
11602
11670
  const o = e(t, n);
@@ -11609,7 +11677,7 @@ function Dr() {
11609
11677
  function Fr() {
11610
11678
  return null;
11611
11679
  }
11612
- function Lf(...e) {
11680
+ function Ff(...e) {
11613
11681
  return e.filter(Boolean).join(" ");
11614
11682
  }
11615
11683
  function Ur(e, t, n) {
@@ -11618,9 +11686,9 @@ function Ur(e, t, n) {
11618
11686
  for (; o.length && (r = r[o[0]], r !== void 0); ) o.shift();
11619
11687
  return r || n;
11620
11688
  }
11621
- function Df(e = "", t = {}) {
11689
+ function Uf(e = "", t = {}) {
11622
11690
  t.overrides = t.overrides || {}, t.namedCodesToUnicode = t.namedCodesToUnicode ? kt({}, ai, t.namedCodesToUnicode) : ai;
11623
- const n = t.slugify || vn, r = t.sanitizer || Of, o = t.createElement || De, s = [li, ci, di, t.enforceAtxHeadings ? hi : ui, fi, pi, ml, pl], a = [...s, ef, Mr, mi, Pr];
11691
+ const n = t.slugify || vn, r = t.sanitizer || Pf, o = t.createElement || De, s = [li, ci, di, t.enforceAtxHeadings ? hi : ui, fi, pi, ml, pl], a = [...s, nf, Mr, mi, Pr];
11624
11692
  function i(f, g) {
11625
11693
  for (let E = 0; E < f.length; E++) if (f[E].test(g)) return !0;
11626
11694
  return !1;
@@ -11630,13 +11698,13 @@ function Df(e = "", t = {}) {
11630
11698
  return o((function(w, C) {
11631
11699
  const T = Ur(C, w);
11632
11700
  return T ? typeof T == "function" || typeof T == "object" && "render" in T ? T : Ur(C, w + ".component", w) : w;
11633
- })(f, t.overrides), kt({}, g, N, { className: Lf(g?.className, N.className) || void 0 }), ...E);
11701
+ })(f, t.overrides), kt({}, g, N, { className: Ff(g?.className, N.className) || void 0 }), ...E);
11634
11702
  }
11635
11703
  function d(f) {
11636
- f = f.replace(Wh, "");
11704
+ f = f.replace(Yh, "");
11637
11705
  let g = !1;
11638
- t.forceInline ? g = !0 : t.forceBlock || (g = of.test(f) === !1);
11639
- const E = b(_(g ? f : Tn(f).replace(bf, "") + `
11706
+ t.forceInline ? g = !0 : t.forceBlock || (g = af.test(f) === !1);
11707
+ const E = b(_(g ? f : Tn(f).replace(vf, "") + `
11640
11708
 
11641
11709
  `, { inline: g }));
11642
11710
  for (; _i(E[E.length - 1]) && !E[E.length - 1].trim(); ) E.pop();
@@ -11652,12 +11720,12 @@ function Df(e = "", t = {}) {
11652
11720
  }
11653
11721
  function m(f, g) {
11654
11722
  if (!g || !g.trim()) return null;
11655
- const E = g.match(Ph);
11723
+ const E = g.match(Dh);
11656
11724
  return E ? E.reduce(function(N, w) {
11657
11725
  const C = w.indexOf("=");
11658
11726
  if (C !== -1) {
11659
11727
  const T = (function(O) {
11660
- return O.indexOf("-") !== -1 && O.match(Kh) === null && (O = O.replace(Qh, function(I, z) {
11728
+ return O.indexOf("-") !== -1 && O.match(Xh) === null && (O = O.replace(tf, function(I, z) {
11661
11729
  return z.toUpperCase();
11662
11730
  })), O;
11663
11731
  })(w.slice(0, C)).trim(), S = (function(O) {
@@ -11696,7 +11764,7 @@ function Df(e = "", t = {}) {
11696
11764
  return H;
11697
11765
  })(z).reduce(function(P, [H, j]) {
11698
11766
  return P[H.replace(/(-[a-z])/g, (L) => L[1].toUpperCase())] = oe(j, O, H), P;
11699
- }, {}) : Mh.indexOf(I) !== -1 ? oe(Xe(z), O, I) : (z.match(Zh) && (z = Xe(z.slice(1, z.length - 1))), z === "true" || z !== "false" && z);
11767
+ }, {}) : Lh.indexOf(I) !== -1 ? oe(Xe(z), O, I) : (z.match(Jh) && (z = Xe(z.slice(1, z.length - 1))), z === "true" || z !== "false" && z);
11700
11768
  })(f, T, S, r);
11701
11769
  typeof x == "string" && (Mr.test(x) || Pr.test(x)) && (N[v] = d(x.trim()));
11702
11770
  } else w !== "style" && (N[ii[w] || w] = !0);
@@ -11704,17 +11772,17 @@ function Df(e = "", t = {}) {
11704
11772
  }, {}) : null;
11705
11773
  }
11706
11774
  const u = [], p = {}, h = { 0: { t: [">"], o: ot(li), i: 1, u(f, g, E) {
11707
- const [, N, w] = f[0].replace(Dh, "").match(Fh);
11775
+ const [, N, w] = f[0].replace(Uh, "").match(Vh);
11708
11776
  return { alert: N, children: g(w, E) };
11709
11777
  }, l(f, g, E) {
11710
11778
  const N = { key: E.key };
11711
11779
  return f.alert && (N.className = "markdown-alert-" + n(f.alert.toLowerCase(), vn), f.children.unshift({ attrs: {}, children: [{ type: "27", text: f.alert }], noInnerParse: !0, type: "11", tag: "header" })), c("blockquote", N, g(f.children, E));
11712
- } }, 1: { t: [" "], o: Wn(Uh), i: 1, u: Dr, l: (f, g, E) => c("br", { key: E.key }) }, 2: { t: ["--", "__", "**", "- ", "* ", "_ "], o: ot(Vh), i: 1, u: Dr, l: (f, g, E) => c("hr", { key: E.key }) }, 3: { t: [" "], o: ot(di), i: 0, u: (f) => ({ lang: void 0, text: Xe(Tn(f[0].replace(/^ {4}/gm, ""))) }), l: (f, g, E) => c("pre", { key: E.key }, c("code", kt({}, f.attrs, { className: f.lang ? "lang-" + f.lang : "" }), f.text)) }, 4: { t: ["```", "~~~"], o: ot(ci), i: 0, u: (f) => ({ attrs: m("code", f[3] || ""), lang: f[2] || void 0, text: f[4], type: "3" }) }, 5: { t: ["`"], o: gt($h), i: 3, u: (f) => ({ text: Xe(f[2]) }), l: (f, g, E) => c("code", { key: E.key }, f.text) }, 6: { t: ["[^"], o: ot(jh), i: 0, u: (f) => (u.push({ footnote: f[2], identifier: f[1] }), {}), l: Fr }, 7: { t: ["[^"], o: xt(Hh), i: 1, u: (f) => ({ target: "#" + n(f[1], vn), text: f[1] }), l: (f, g, E) => c("a", { key: E.key, href: r(f.target, "a", "href") }, c("sup", { key: E.key }, f.text)) }, 8: { t: ["[ ]", "[x]"], o: xt(qh), i: 1, u: (f) => ({ completed: f[1].toLowerCase() === "x" }), l: (f, g, E) => c("input", { checked: f.completed, key: E.key, readOnly: !0, type: "checkbox" }) }, 9: { t: ["#"], o: ot(t.enforceAtxHeadings ? hi : ui), i: 1, u: (f, g, E) => ({ children: Xn(g, f[2], E), id: n(f[2], vn), level: f[1].length }), l: (f, g, E) => c("h" + f.level, { id: f.id, key: E.key }, g(f.children, E)) }, 10: { t: (f) => {
11780
+ } }, 1: { t: [" "], o: Wn($h), i: 1, u: Dr, l: (f, g, E) => c("br", { key: E.key }) }, 2: { t: ["--", "__", "**", "- ", "* ", "_ "], o: ot(zh), i: 1, u: Dr, l: (f, g, E) => c("hr", { key: E.key }) }, 3: { t: [" "], o: ot(di), i: 0, u: (f) => ({ lang: void 0, text: Xe(Tn(f[0].replace(/^ {4}/gm, ""))) }), l: (f, g, E) => c("pre", { key: E.key }, c("code", kt({}, f.attrs, { className: f.lang ? "lang-" + f.lang : "" }), f.text)) }, 4: { t: ["```", "~~~"], o: ot(ci), i: 0, u: (f) => ({ attrs: m("code", f[3] || ""), lang: f[2] || void 0, text: f[4], type: "3" }) }, 5: { t: ["`"], o: gt(Bh), i: 3, u: (f) => ({ text: Xe(f[2]) }), l: (f, g, E) => c("code", { key: E.key }, f.text) }, 6: { t: ["[^"], o: ot(Gh), i: 0, u: (f) => (u.push({ footnote: f[2], identifier: f[1] }), {}), l: Fr }, 7: { t: ["[^"], o: xt(Wh), i: 1, u: (f) => ({ target: "#" + n(f[1], vn), text: f[1] }), l: (f, g, E) => c("a", { key: E.key, href: r(f.target, "a", "href") }, c("sup", { key: E.key }, f.text)) }, 8: { t: ["[ ]", "[x]"], o: xt(Kh), i: 1, u: (f) => ({ completed: f[1].toLowerCase() === "x" }), l: (f, g, E) => c("input", { checked: f.completed, key: E.key, readOnly: !0, type: "checkbox" }) }, 9: { t: ["#"], o: ot(t.enforceAtxHeadings ? hi : ui), i: 1, u: (f, g, E) => ({ children: Xn(g, f[2], E), id: n(f[2], vn), level: f[1].length }), l: (f, g, E) => c("h" + f.level, { id: f.id, key: E.key }, g(f.children, E)) }, 10: { t: (f) => {
11713
11781
  const g = f.indexOf(`
11714
11782
  `);
11715
11783
  return g > 0 && g < f.length - 1 && (f[g + 1] === "=" || f[g + 1] === "-");
11716
11784
  }, o: ot(fi), i: 1, u: (f, g, E) => ({ children: Xn(g, f[1], E), level: f[2] === "=" ? 1 : 2, type: "9" }) }, 11: { t: ["<"], o: Wn(Mr), i: 1, u(f, g, E) {
11717
- const [, N] = f[3].match(yf), w = RegExp("^" + N, "gm"), C = f[3].replace(w, ""), T = i(a, C) ? Pf : Xn, S = f[1].toLowerCase(), v = Oh.indexOf(S) !== -1, x = (v ? S : f[1]).trim(), O = { attrs: m(x, f[2]), noInnerParse: v, tag: x };
11785
+ const [, N] = f[3].match(Sf), w = RegExp("^" + N, "gm"), C = f[3].replace(w, ""), T = i(a, C) ? Df : Xn, S = f[1].toLowerCase(), v = Ph.indexOf(S) !== -1, x = (v ? S : f[1]).trim(), O = { attrs: m(x, f[2]), noInnerParse: v, tag: x };
11718
11786
  if (E.inAnchor = E.inAnchor || S === "a", v) O.text = f[3];
11719
11787
  else {
11720
11788
  const I = E.inHTML;
@@ -11724,11 +11792,11 @@ function Df(e = "", t = {}) {
11724
11792
  }, l: (f, g, E) => c(f.tag, kt({ key: E.key }, f.attrs), f.text || (f.children ? g(f.children, E) : "")) }, 13: { t: ["<"], o: Wn(Pr), i: 1, u(f) {
11725
11793
  const g = f[1].trim();
11726
11794
  return { attrs: m(g, f[2] || ""), tag: g };
11727
- }, l: (f, g, E) => c(f.tag, kt({}, f.attrs, { key: E.key })) }, 12: { t: ["<!--"], o: Wn(mi), i: 1, u: () => ({}), l: Fr }, 14: { t: ["!["], o: gt(xf), i: 1, u: (f) => ({ alt: Xe(f[1]), target: Xe(f[2]), title: Xe(f[3]) }), l: (f, g, E) => c("img", { key: E.key, alt: f.alt || void 0, title: f.title || void 0, src: r(f.target, "img", "src") }) }, 15: { t: ["["], o: xt(Nf), i: 3, u: (f, g, E) => ({ children: Mf(g, f[1], E), target: Xe(f[2]), title: Xe(f[3]) }), l: (f, g, E) => c("a", { key: E.key, href: r(f.target, "a", "href"), title: f.title }, g(f.children, E)) }, 16: { t: ["<"], o: xt(Jh), i: 0, u(f) {
11795
+ }, l: (f, g, E) => c(f.tag, kt({}, f.attrs, { key: E.key })) }, 12: { t: ["<!--"], o: Wn(mi), i: 1, u: () => ({}), l: Fr }, 14: { t: ["!["], o: gt(Rf), i: 1, u: (f) => ({ alt: Xe(f[1]), target: Xe(f[2]), title: Xe(f[3]) }), l: (f, g, E) => c("img", { key: E.key, alt: f.alt || void 0, title: f.title || void 0, src: r(f.target, "img", "src") }) }, 15: { t: ["["], o: xt(kf), i: 3, u: (f, g, E) => ({ children: Lf(g, f[1], E), target: Xe(f[2]), title: Xe(f[3]) }), l: (f, g, E) => c("a", { key: E.key, href: r(f.target, "a", "href"), title: f.title }, g(f.children, E)) }, 16: { t: ["<"], o: xt(ef), i: 0, u(f) {
11728
11796
  let g = f[1], E = !1;
11729
11797
  return g.indexOf("@") !== -1 && g.indexOf("//") === -1 && (E = !0, g = g.replace("mailto:", "")), { children: [{ text: g, type: "27" }], target: E ? "mailto:" + g : g, type: "15" };
11730
- } }, 17: { t: (f, g) => !g.inAnchor && !t.disableAutoLink && (Zn(f, "http://") || Zn(f, "https://")), o: xt(Xh), i: 0, u: (f) => ({ children: [{ text: f[1], type: "27" }], target: f[1], title: void 0, type: "15" }) }, 20: gi(c, 1), 33: gi(c, 2), 19: { t: [`
11731
- `], o: ot(zh), i: 3, u: Dr, l: () => `
11798
+ } }, 17: { t: (f, g) => !g.inAnchor && !t.disableAutoLink && (Zn(f, "http://") || Zn(f, "https://")), o: xt(Qh), i: 0, u: (f) => ({ children: [{ text: f[1], type: "27" }], target: f[1], title: void 0, type: "15" }) }, 20: gi(c, 1), 33: gi(c, 2), 19: { t: [`
11799
+ `], o: ot(jh), i: 3, u: Dr, l: () => `
11732
11800
  ` }, 21: { o: Ht(function(f, g) {
11733
11801
  if (g.inline || g.simple || g.inHTML && f.indexOf(`
11734
11802
 
@@ -11744,7 +11812,7 @@ function Df(e = "", t = {}) {
11744
11812
  }
11745
11813
  const w = Tn(E);
11746
11814
  return w === "" ? null : [E, , w];
11747
- }), i: 3, u: Lr, l: (f, g, E) => c("p", { key: E.key }, g(f.children, E)) }, 22: { t: ["["], o: xt(tf), i: 0, u: (f) => (p[f[1]] = { target: f[2], title: f[4] }, {}), l: Fr }, 23: { t: ["!["], o: gt(nf), i: 0, u: (f) => ({ alt: f[1] ? Xe(f[1]) : void 0, ref: f[2] }), l: (f, g, E) => p[f.ref] ? c("img", { key: E.key, alt: f.alt, src: r(p[f.ref].target, "img", "src"), title: p[f.ref].title }) : null }, 24: { t: (f) => f[0] === "[" && f.indexOf("](") === -1, o: xt(rf), i: 0, u: (f, g, E) => ({ children: g(f[1], E), fallbackChildren: f[0], ref: f[2] }), l: (f, g, E) => p[f.ref] ? c("a", { key: E.key, href: r(p[f.ref].target, "a", "href"), title: p[f.ref].title }, g(f.children, E)) : c("span", { key: E.key }, f.fallbackChildren) }, 25: { t: ["|"], o: ot(pi), i: 1, u: If, l(f, g, E) {
11815
+ }), i: 3, u: Lr, l: (f, g, E) => c("p", { key: E.key }, g(f.children, E)) }, 22: { t: ["["], o: xt(rf), i: 0, u: (f) => (p[f[1]] = { target: f[2], title: f[4] }, {}), l: Fr }, 23: { t: ["!["], o: gt(of), i: 0, u: (f) => ({ alt: f[1] ? Xe(f[1]) : void 0, ref: f[2] }), l: (f, g, E) => p[f.ref] ? c("img", { key: E.key, alt: f.alt, src: r(p[f.ref].target, "img", "src"), title: p[f.ref].title }) : null }, 24: { t: (f) => f[0] === "[" && f.indexOf("](") === -1, o: xt(sf), i: 0, u: (f, g, E) => ({ children: g(f[1], E), fallbackChildren: f[0], ref: f[2] }), l: (f, g, E) => p[f.ref] ? c("a", { key: E.key, href: r(p[f.ref].target, "a", "href"), title: p[f.ref].title }, g(f.children, E)) : c("span", { key: E.key }, f.fallbackChildren) }, 25: { t: ["|"], o: ot(pi), i: 1, u: Of, l(f, g, E) {
11748
11816
  const N = f;
11749
11817
  return c("table", { key: E.key }, c("thead", null, c("tr", null, N.header.map(function(w, C) {
11750
11818
  return c("th", { key: C, style: bi(N, C) }, g(w, E));
@@ -11755,14 +11823,14 @@ function Df(e = "", t = {}) {
11755
11823
  })));
11756
11824
  } }, 27: { o: Ht(function(f, g) {
11757
11825
  let E;
11758
- return Zn(f, ":") && (E = pf.exec(f)), E || Ef.exec(f);
11826
+ return Zn(f, ":") && (E = _f.exec(f)), E || yf.exec(f);
11759
11827
  }), i: 4, u(f) {
11760
11828
  const g = f[0];
11761
- return { text: g.indexOf("&") === -1 ? g : g.replace(Yh, (E, N) => t.namedCodesToUnicode[N] || E) };
11762
- }, l: (f) => f.text }, 28: { t: ["**", "__"], o: gt(uf), i: 2, u: (f, g, E) => ({ children: g(f[2], E) }), l: (f, g, E) => c("strong", { key: E.key }, g(f.children, E)) }, 29: { t: (f) => {
11829
+ return { text: g.indexOf("&") === -1 ? g : g.replace(Zh, (E, N) => t.namedCodesToUnicode[N] || E) };
11830
+ }, l: (f) => f.text }, 28: { t: ["**", "__"], o: gt(ff), i: 2, u: (f, g, E) => ({ children: g(f[2], E) }), l: (f, g, E) => c("strong", { key: E.key }, g(f.children, E)) }, 29: { t: (f) => {
11763
11831
  const g = f[0];
11764
11832
  return (g === "*" || g === "_") && f[1] !== g;
11765
- }, o: gt(hf), i: 3, u: (f, g, E) => ({ children: g(f[2], E) }), l: (f, g, E) => c("em", { key: E.key }, g(f.children, E)) }, 30: { t: ["\\"], o: gt(gf), i: 1, u: (f) => ({ text: f[1], type: "27" }) }, 31: { t: ["=="], o: gt(ff), i: 3, u: Lr, l: (f, g, E) => c("mark", { key: E.key }, g(f.children, E)) }, 32: { t: ["~~"], o: gt(mf), i: 3, u: Lr, l: (f, g, E) => c("del", { key: E.key }, g(f.children, E)) } };
11833
+ }, o: gt(mf), i: 3, u: (f, g, E) => ({ children: g(f[2], E) }), l: (f, g, E) => c("em", { key: E.key }, g(f.children, E)) }, 30: { t: ["\\"], o: gt(Ef), i: 1, u: (f) => ({ text: f[1], type: "27" }) }, 31: { t: ["=="], o: gt(pf), i: 3, u: Lr, l: (f, g, E) => c("mark", { key: E.key }, g(f.children, E)) }, 32: { t: ["~~"], o: gt(gf), i: 3, u: Lr, l: (f, g, E) => c("del", { key: E.key }, g(f.children, E)) } };
11766
11834
  t.disableParsingRawHTML === !0 && (delete h[11], delete h[13]);
11767
11835
  const _ = (function(f) {
11768
11836
  var g = Object.keys(f);
@@ -11770,7 +11838,7 @@ function Df(e = "", t = {}) {
11770
11838
  var C = [];
11771
11839
  if (w.prevCapture = w.prevCapture || "", N.trim()) for (; N; ) for (var T = 0; T < g.length; ) {
11772
11840
  var S = g[T], v = f[S];
11773
- if (!v.t || kf(N, w, v.t)) {
11841
+ if (!v.t || If(N, w, v.t)) {
11774
11842
  var x = v.o(N, w);
11775
11843
  if (x && x[0]) {
11776
11844
  N = N.substring(x[0].length);
@@ -11787,8 +11855,8 @@ function Df(e = "", t = {}) {
11787
11855
  return f[N].i - f[w].i || (N < w ? -1 : 1);
11788
11856
  }), function(N, w) {
11789
11857
  return E((function(C) {
11790
- return C.replace(Bh, `
11791
- `).replace(Gh, "").replace(sf, " ");
11858
+ return C.replace(Hh, `
11859
+ `).replace(qh, "").replace(lf, " ");
11792
11860
  })(N), w);
11793
11861
  };
11794
11862
  })(h), b = /* @__PURE__ */ (function(f, g) {
@@ -11813,35 +11881,35 @@ function Df(e = "", t = {}) {
11813
11881
  return c("div", { id: n(f.identifier, vn), key: f.identifier }, f.identifier, b(_(f.footnote, { inline: !0 })));
11814
11882
  }))) : y;
11815
11883
  }
11816
- const Ff = (e) => {
11884
+ const Vf = (e) => {
11817
11885
  let { children: t, options: n } = e, r = (function(o, s) {
11818
11886
  if (o == null) return {};
11819
11887
  var a, i, c = {}, d = Object.keys(o);
11820
11888
  for (i = 0; i < d.length; i++) s.indexOf(a = d[i]) >= 0 || (c[a] = o[a]);
11821
11889
  return c;
11822
- })(e, Ah);
11823
- return yt(Df(t ?? "", n), r);
11824
- }, Uf = {
11890
+ })(e, Mh);
11891
+ return yt(Uf(t ?? "", n), r);
11892
+ }, $f = {
11825
11893
  disableParsingRawHTML: !0,
11826
11894
  forceBlock: !0
11827
11895
  };
11828
11896
  function Xr({ children: e }) {
11829
- return /* @__PURE__ */ l(Ff, { options: Uf, children: e });
11897
+ return /* @__PURE__ */ l(Vf, { options: $f, children: e });
11830
11898
  }
11831
- const Vf = dt(
11832
- () => Promise.resolve().then(() => qf).then((e) => ({ default: e.Pills }))
11833
- ), $f = dt(
11899
+ const zf = dt(
11900
+ () => Promise.resolve().then(() => Kf).then((e) => ({ default: e.Pills }))
11901
+ ), Bf = dt(
11834
11902
  () => import("./medassist-widget-MultiSelect-BnExX-Ty.js").then((e) => ({ default: e.MultiSelectGroup }))
11835
- ), zf = dt(
11903
+ ), jf = dt(
11836
11904
  () => import("./medassist-widget-FocusCarousel-BsLIZftX.js").then((e) => ({ default: e.FocusCarousel }))
11837
- ), Bf = dt(
11905
+ ), Hf = dt(
11838
11906
  () => import("./medassist-widget-DoctorCard-BdLitZW0.js").then((e) => ({ default: e.DoctorCard }))
11839
- ), jf = dt(
11907
+ ), Gf = dt(
11840
11908
  () => import("./medassist-widget-CardList-BR2hjo_A.js").then((e) => ({ default: e.CardList }))
11841
- ), Hf = dt(
11909
+ ), Wf = dt(
11842
11910
  () => import("./medassist-widget-MediaCard-DRUToQV3.js").then((e) => ({ default: e.MediaCard }))
11843
11911
  );
11844
- function ke({ className: e }) {
11912
+ function Re({ className: e }) {
11845
11913
  return /* @__PURE__ */ l(
11846
11914
  "div",
11847
11915
  {
@@ -11858,9 +11926,9 @@ function ke({ className: e }) {
11858
11926
  function Ft({ variant: e }) {
11859
11927
  return e === "pill" ? /* @__PURE__ */ l("div", { className: "flex flex-wrap gap-2 mt-3", "aria-busy": !0, "aria-label": "Loading options", children: [
11860
11928
  /* @__PURE__ */ l(qn, {}),
11861
- /* @__PURE__ */ l(ke, { className: "h-8 w-20 rounded-full" }),
11862
- /* @__PURE__ */ l(ke, { className: "h-8 w-24 rounded-full" }),
11863
- /* @__PURE__ */ l(ke, { className: "h-8 w-16 rounded-full" })
11929
+ /* @__PURE__ */ l(Re, { className: "h-8 w-20 rounded-full" }),
11930
+ /* @__PURE__ */ l(Re, { className: "h-8 w-24 rounded-full" }),
11931
+ /* @__PURE__ */ l(Re, { className: "h-8 w-16 rounded-full" })
11864
11932
  ] }) : e === "media" ? /* @__PURE__ */ l(
11865
11933
  "div",
11866
11934
  {
@@ -11869,10 +11937,10 @@ function Ft({ variant: e }) {
11869
11937
  "aria-label": "Loading media",
11870
11938
  children: [
11871
11939
  /* @__PURE__ */ l(qn, {}),
11872
- /* @__PURE__ */ l(ke, { className: "h-24 w-full rounded-lg" }),
11940
+ /* @__PURE__ */ l(Re, { className: "h-24 w-full rounded-lg" }),
11873
11941
  /* @__PURE__ */ l("div", { className: "mt-3 space-y-2", children: [
11874
- /* @__PURE__ */ l(ke, { className: "h-3 w-3/4 rounded" }),
11875
- /* @__PURE__ */ l(ke, { className: "h-3 w-1/2 rounded" })
11942
+ /* @__PURE__ */ l(Re, { className: "h-3 w-3/4 rounded" }),
11943
+ /* @__PURE__ */ l(Re, { className: "h-3 w-1/2 rounded" })
11876
11944
  ] })
11877
11945
  ]
11878
11946
  }
@@ -11884,13 +11952,13 @@ function Ft({ variant: e }) {
11884
11952
  "aria-label": "Loading input",
11885
11953
  children: [
11886
11954
  /* @__PURE__ */ l(qn, {}),
11887
- /* @__PURE__ */ l(ke, { className: "h-3 w-32 rounded mb-3" }),
11955
+ /* @__PURE__ */ l(Re, { className: "h-3 w-32 rounded mb-3" }),
11888
11956
  /* @__PURE__ */ l("div", { className: "space-y-2", children: [
11889
- /* @__PURE__ */ l(ke, { className: "h-9 w-full rounded-lg" }),
11890
- /* @__PURE__ */ l(ke, { className: "h-9 w-full rounded-lg" }),
11891
- /* @__PURE__ */ l(ke, { className: "h-9 w-full rounded-lg" })
11957
+ /* @__PURE__ */ l(Re, { className: "h-9 w-full rounded-lg" }),
11958
+ /* @__PURE__ */ l(Re, { className: "h-9 w-full rounded-lg" }),
11959
+ /* @__PURE__ */ l(Re, { className: "h-9 w-full rounded-lg" })
11892
11960
  ] }),
11893
- /* @__PURE__ */ l(ke, { className: "mt-4 h-9 w-full rounded-lg" })
11961
+ /* @__PURE__ */ l(Re, { className: "mt-4 h-9 w-full rounded-lg" })
11894
11962
  ]
11895
11963
  }
11896
11964
  ) : /* @__PURE__ */ l(
@@ -11902,17 +11970,17 @@ function Ft({ variant: e }) {
11902
11970
  children: [
11903
11971
  /* @__PURE__ */ l(qn, {}),
11904
11972
  /* @__PURE__ */ l("div", { className: "flex items-center gap-3", children: [
11905
- /* @__PURE__ */ l(ke, { className: "h-10 w-10 rounded-full" }),
11973
+ /* @__PURE__ */ l(Re, { className: "h-10 w-10 rounded-full" }),
11906
11974
  /* @__PURE__ */ l("div", { className: "flex-1 space-y-2", children: [
11907
- /* @__PURE__ */ l(ke, { className: "h-3 w-3/4 rounded" }),
11908
- /* @__PURE__ */ l(ke, { className: "h-3 w-1/2 rounded" })
11975
+ /* @__PURE__ */ l(Re, { className: "h-3 w-3/4 rounded" }),
11976
+ /* @__PURE__ */ l(Re, { className: "h-3 w-1/2 rounded" })
11909
11977
  ] })
11910
11978
  ] }),
11911
11979
  /* @__PURE__ */ l("div", { className: "mt-4 space-y-2", children: [
11912
- /* @__PURE__ */ l(ke, { className: "h-3 w-full rounded" }),
11913
- /* @__PURE__ */ l(ke, { className: "h-3 w-5/6 rounded" })
11980
+ /* @__PURE__ */ l(Re, { className: "h-3 w-full rounded" }),
11981
+ /* @__PURE__ */ l(Re, { className: "h-3 w-5/6 rounded" })
11914
11982
  ] }),
11915
- /* @__PURE__ */ l(ke, { className: "mt-4 h-9 w-28 rounded-lg" })
11983
+ /* @__PURE__ */ l(Re, { className: "mt-4 h-9 w-28 rounded-lg" })
11916
11984
  ]
11917
11985
  }
11918
11986
  );
@@ -11920,7 +11988,7 @@ function Ft({ variant: e }) {
11920
11988
  function qn() {
11921
11989
  return /* @__PURE__ */ l("style", { children: "@keyframes shimmer { 100% { transform: translateX(100%); } }" });
11922
11990
  }
11923
- function Gf({
11991
+ function qf({
11924
11992
  messageId: e,
11925
11993
  tool_key: t,
11926
11994
  entry: n,
@@ -11979,9 +12047,9 @@ function Gf({
11979
12047
  if (!h) return null;
11980
12048
  const C = h === M.SYNAPSE_COMPONENTS.PILL ? b?.options : void 0, T = h === M.SYNAPSE_COMPONENTS.CARD ? b?.cards : void 0, S = h === M.SYNAPSE_COMPONENTS.MEDIA_CARD ? b?.media_card : void 0;
11981
12049
  return /* @__PURE__ */ l("div", { className: "flex justify-end", children: [
11982
- C && /* @__PURE__ */ l(Re, { fallback: /* @__PURE__ */ l(Ft, { variant: "pill" }), children: /* @__PURE__ */ l("div", { className: `flex ${C.length > 3 ? "flex-col" : "flex-wrap"} gap-2 mt-3`, children: [
12050
+ C && /* @__PURE__ */ l(Me, { fallback: /* @__PURE__ */ l(Ft, { variant: "pill" }), children: /* @__PURE__ */ l("div", { className: `flex ${C.length > 3 ? "flex-col" : "flex-wrap"} gap-2 mt-3`, children: [
11983
12051
  C.slice(0, u).map((v, x) => /* @__PURE__ */ l(
11984
- Vf,
12052
+ zf,
11985
12053
  {
11986
12054
  disabled: _ || o || d,
11987
12055
  text: v?.label || "",
@@ -12011,10 +12079,10 @@ function Gf({
12011
12079
  }
12012
12080
  )
12013
12081
  ] }) }),
12014
- h === M.SYNAPSE_COMPONENTS.MULTI && b?.options && /* @__PURE__ */ l(Re, { fallback: /* @__PURE__ */ l(Ft, { variant: "input" }), children: /* @__PURE__ */ l("div", { className: "mt-3 space-y-3 break-words overflow-wrap-anywhere whitespace-pre-wrap bg-elicitationBg border border-primary/40 rounded-xl p-4", children: [
12082
+ h === M.SYNAPSE_COMPONENTS.MULTI && b?.options && /* @__PURE__ */ l(Me, { fallback: /* @__PURE__ */ l(Ft, { variant: "input" }), children: /* @__PURE__ */ l("div", { className: "mt-3 space-y-3 break-words overflow-wrap-anywhere whitespace-pre-wrap bg-elicitationBg border border-primary/40 rounded-xl p-4", children: [
12015
12083
  /* @__PURE__ */ l("h3", { className: "text-xs font-medium text-muted-foreground mb-2", children: "Select multiple options:" }),
12016
12084
  /* @__PURE__ */ l(
12017
- $f,
12085
+ Bf,
12018
12086
  {
12019
12087
  options: N(),
12020
12088
  selectedValues: s,
@@ -12037,8 +12105,8 @@ function Gf({
12037
12105
  }
12038
12106
  )
12039
12107
  ] }) }),
12040
- w && w.length > 0 ? /* @__PURE__ */ l(Re, { fallback: /* @__PURE__ */ l(Ft, { variant: "card" }), children: /* @__PURE__ */ l(
12041
- zf,
12108
+ w && w.length > 0 ? /* @__PURE__ */ l(Me, { fallback: /* @__PURE__ */ l(Ft, { variant: "card" }), children: /* @__PURE__ */ l(
12109
+ jf,
12042
12110
  {
12043
12111
  count: w.length > 1 ? w.length + 1 : w.length,
12044
12112
  renderItem: (v, x) => {
@@ -12070,8 +12138,8 @@ function Gf({
12070
12138
  }
12071
12139
  );
12072
12140
  const O = w[v];
12073
- return /* @__PURE__ */ l(Re, { fallback: /* @__PURE__ */ l(Ft, { variant: "card" }), children: /* @__PURE__ */ l(
12074
- Bf,
12141
+ return /* @__PURE__ */ l(Me, { fallback: /* @__PURE__ */ l(Ft, { variant: "card" }), children: /* @__PURE__ */ l(
12142
+ Hf,
12075
12143
  {
12076
12144
  doctor: O,
12077
12145
  doctorDetails: i?.[O.doctor_id],
@@ -12083,8 +12151,8 @@ function Gf({
12083
12151
  }
12084
12152
  }
12085
12153
  ) }) : null,
12086
- T && /* @__PURE__ */ l(Re, { fallback: /* @__PURE__ */ l(Ft, { variant: "card" }), children: /* @__PURE__ */ l(
12087
- jf,
12154
+ T && /* @__PURE__ */ l(Me, { fallback: /* @__PURE__ */ l(Ft, { variant: "card" }), children: /* @__PURE__ */ l(
12155
+ Gf,
12088
12156
  {
12089
12157
  cards: T,
12090
12158
  onSelect: async (v) => {
@@ -12099,10 +12167,10 @@ function Gf({
12099
12167
  disabled: _ || o
12100
12168
  }
12101
12169
  ) }),
12102
- S && /* @__PURE__ */ l(Re, { fallback: /* @__PURE__ */ l(Ft, { variant: "media" }), children: /* @__PURE__ */ l("div", { className: "mt-3", children: /* @__PURE__ */ l(Hf, { card: S }) }) })
12170
+ S && /* @__PURE__ */ l(Me, { fallback: /* @__PURE__ */ l(Ft, { variant: "media" }), children: /* @__PURE__ */ l("div", { className: "mt-3", children: /* @__PURE__ */ l(Wf, { card: S }) }) })
12103
12171
  ] });
12104
12172
  }
12105
- function Wf({
12173
+ function Yf({
12106
12174
  id: e,
12107
12175
  role: t,
12108
12176
  content: n,
@@ -12223,7 +12291,7 @@ function Wf({
12223
12291
  a?.map((C) => {
12224
12292
  const T = c[C];
12225
12293
  return T ? /* @__PURE__ */ l(
12226
- Gf,
12294
+ qf,
12227
12295
  {
12228
12296
  messageId: e,
12229
12297
  tool_key: C,
@@ -12317,7 +12385,7 @@ function gl({
12317
12385
  onClick: o,
12318
12386
  disabled: s = !1
12319
12387
  }) {
12320
- const [a, i] = V(!1), c = G(null), d = G(null);
12388
+ const [a, i] = V(!1), c = W(null), d = W(null);
12321
12389
  return $(() => {
12322
12390
  const m = () => {
12323
12391
  if (c.current && d.current) {
@@ -12359,8 +12427,8 @@ function gl({
12359
12427
  }
12360
12428
  ) : null;
12361
12429
  }
12362
- const qf = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({ __proto__: null, Pills: gl }, Symbol.toStringTag, { value: "Module" }));
12363
- function Yf({
12430
+ const Kf = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({ __proto__: null, Pills: gl }, Symbol.toStringTag, { value: "Module" }));
12431
+ function Zf({
12364
12432
  text: e,
12365
12433
  suggestions: t,
12366
12434
  onSendMessage: n,
@@ -12422,7 +12490,7 @@ function Yf({
12422
12490
  ) })
12423
12491
  ] });
12424
12492
  }
12425
- function Kf({
12493
+ function Xf({
12426
12494
  messages: e,
12427
12495
  onSendMessage: t,
12428
12496
  onToggleFeedback: n,
@@ -12434,7 +12502,7 @@ function Kf({
12434
12502
  }) {
12435
12503
  const c = ne((h) => h.isWaitingForResponse), d = ne((h) => h.connectionStatus), m = ne((h) => h.elicitationState), u = d === Ne.CONNECTED, p = ne((h) => h.progressMessage);
12436
12504
  return e.length === 0 && !p ? /* @__PURE__ */ l(
12437
- Yf,
12505
+ Zf,
12438
12506
  {
12439
12507
  text: a?.text,
12440
12508
  suggestions: a?.suggestions,
@@ -12451,7 +12519,7 @@ function Kf({
12451
12519
  "data-message-id": h.id,
12452
12520
  id: _ === e.length - 1 ? "last-message" : void 0,
12453
12521
  children: /* @__PURE__ */ l(
12454
- Wf,
12522
+ Yf,
12455
12523
  {
12456
12524
  id: h.id,
12457
12525
  role: h.role,
@@ -12475,10 +12543,10 @@ function Kf({
12475
12543
  },
12476
12544
  h.id
12477
12545
  )) }),
12478
- c && /* @__PURE__ */ l(Zf, {})
12546
+ c && /* @__PURE__ */ l(Jf, {})
12479
12547
  ] });
12480
12548
  }
12481
- function Zf() {
12549
+ function Jf() {
12482
12550
  return /* @__PURE__ */ l("div", { className: "animate-slideUp", children: /* @__PURE__ */ l("div", { className: "flex justify-start", children: /* @__PURE__ */ l("div", { className: "flex gap-3", children: /* @__PURE__ */ l(jt, { className: "px-4 py-2 rounded-lg shadow-none bg-botMessage backdrop-blur-sm text-text-primary shadow-sm", children: /* @__PURE__ */ l(
12483
12551
  "div",
12484
12552
  {
@@ -12495,70 +12563,6 @@ function Zf() {
12495
12563
  }
12496
12564
  ) }) }) }) });
12497
12565
  }
12498
- function Xf({ message: e, onDismiss: t }) {
12499
- return /* @__PURE__ */ l(be, { children: [
12500
- /* @__PURE__ */ l(
12501
- "div",
12502
- {
12503
- className: "pointer-events-none absolute inset-0 z-[55] bg-black-600",
12504
- "aria-hidden": !0
12505
- }
12506
- ),
12507
- /* @__PURE__ */ l(
12508
- "div",
12509
- {
12510
- className: "pointer-events-none absolute inset-x-3 top-3 z-[60]",
12511
- role: "presentation",
12512
- children: /* @__PURE__ */ l(
12513
- "div",
12514
- {
12515
- role: "alertdialog",
12516
- "aria-modal": "true",
12517
- "aria-labelledby": "synapse-disp-toast-msg",
12518
- className: "pointer-events-auto flex w-full flex-row items-center gap-3 rounded-lg border border-border bg-surface p-3 text-left text-foreground opacity-100",
12519
- onClick: (n) => n.stopPropagation(),
12520
- children: [
12521
- /* @__PURE__ */ l(
12522
- "p",
12523
- {
12524
- id: "synapse-disp-toast-msg",
12525
- className: "min-w-0 flex-1 text-sm font-medium whitespace-pre-wrap",
12526
- children: e
12527
- }
12528
- ),
12529
- /* @__PURE__ */ l(
12530
- "button",
12531
- {
12532
- type: "button",
12533
- onClick: t,
12534
- className: "flex h-8 w-8 shrink-0 items-center justify-center rounded-full text-muted-foreground hover:bg-muted hover:text-foreground",
12535
- "aria-label": "Close",
12536
- children: /* @__PURE__ */ l(ar, { className: "h-4 w-4", strokeWidth: 2.5 })
12537
- }
12538
- )
12539
- ]
12540
- }
12541
- )
12542
- }
12543
- )
12544
- ] });
12545
- }
12546
- function Jf() {
12547
- const e = ne((r) => r.toastMessage), t = ne((r) => r.setToastMessage), n = ae(() => {
12548
- t(null);
12549
- }, [t]);
12550
- return $(() => {
12551
- if (!e) return;
12552
- const r = window.setTimeout(n, 3e3);
12553
- return () => window.clearTimeout(r);
12554
- }, [e, n]), e ? /* @__PURE__ */ l(
12555
- Xf,
12556
- {
12557
- message: e,
12558
- onDismiss: n
12559
- }
12560
- ) : null;
12561
- }
12562
12566
  function yi({
12563
12567
  className: e = "",
12564
12568
  onRetry: t,
@@ -12678,7 +12682,7 @@ function em({
12678
12682
  disconnectVoiceAgent: H,
12679
12683
  resetVoiceAgent: j,
12680
12684
  toggleMute: L
12681
- } = Ih({ isOpen: e, agentId: t, config: n });
12685
+ } = Oh({ isOpen: e, agentId: t, config: n });
12682
12686
  $(() => {
12683
12687
  N.length || x("auto");
12684
12688
  }, [N.length, x]);
@@ -12714,7 +12718,7 @@ function em({
12714
12718
  voiceAgentState: z,
12715
12719
  chatComposer: O,
12716
12720
  fullScreenEmptyState: E ? (le) => /* @__PURE__ */ l(
12717
- yh,
12721
+ Sh,
12718
12722
  {
12719
12723
  title: n.title,
12720
12724
  description: n?.initialMessage?.text,
@@ -12736,7 +12740,7 @@ function em({
12736
12740
  )
12737
12741
  }
12738
12742
  ) : void 0,
12739
- children: P ? /* @__PURE__ */ l(Re, { fallback: /* @__PURE__ */ l(vi, {}), children: /* @__PURE__ */ l(
12743
+ children: P ? /* @__PURE__ */ l(Me, { fallback: /* @__PURE__ */ l(vi, {}), children: /* @__PURE__ */ l(
12740
12744
  Qf,
12741
12745
  {
12742
12746
  state: z,
@@ -12748,51 +12752,48 @@ function em({
12748
12752
  iconUrl: n.iconUrl,
12749
12753
  textColor: n.theme?.textColor
12750
12754
  }
12751
- ) }) : /* @__PURE__ */ l(Re, { fallback: /* @__PURE__ */ l(vi, {}), children: /* @__PURE__ */ l("div", { className: D("flex-1 flex flex-col min-h-0 overflow-hidden relative synapse-chat-window"), children: [
12752
- /* @__PURE__ */ l("div", { className: "relative flex min-h-0 flex-1 flex-col overflow-hidden", children: [
12753
- /* @__PURE__ */ l(
12754
- La,
12755
- {
12756
- ref: s,
12757
- className: "flex-1 min-h-0 [&>[data-radix-scroll-area-viewport]>div]:!flex [&>[data-radix-scroll-area-viewport]>div]:flex-col [&>[data-radix-scroll-area-viewport]>div]:min-h-full",
12758
- children: [
12759
- /* @__PURE__ */ l("div", { className: "flex-1" }),
12760
- /* @__PURE__ */ l(
12761
- "div",
12762
- {
12763
- className: D(
12764
- "transition-all duration-300 min-w-0 overflow-x-hidden",
12765
- f ? "pt-4 px-4 space-y-3" : "pt-4 px-4 space-y-4",
12766
- // Center the chat content in fullscreen so messages don't
12767
- // sprawl across the whole viewport — mirrors the Figma layout.
12768
- o === "full" && "max-w-2xl mx-auto w-full"
12769
- ),
12770
- children: [
12771
- g && /* @__PURE__ */ l("div", { className: "text-xs text-[var(--color-muted-foreground)] text-center mb-2", children: "Just now" }),
12772
- !g && /* @__PURE__ */ l("div", { className: "text-xs text-[var(--color-muted-foreground)] text-center", children: pe }),
12773
- /* @__PURE__ */ l(Re, { fallback: /* @__PURE__ */ l(Vu, {}), children: /* @__PURE__ */ l(
12774
- Kf,
12775
- {
12776
- messages: N,
12777
- onSendMessage: w,
12778
- iconUrl: n.iconUrl,
12779
- onToggleFeedback: T,
12780
- onClearElicitationState: S,
12781
- isAuthComponent: _,
12782
- isFullScreen: o === "full",
12783
- initialMessage: n.initialMessage,
12784
- disabled: !b || y
12785
- }
12786
- ) }),
12787
- /* @__PURE__ */ l("div", { ref: a })
12788
- ]
12789
- }
12790
- )
12791
- ]
12792
- }
12793
- ),
12794
- /* @__PURE__ */ l(Re, { fallback: null, children: /* @__PURE__ */ l(Jf, {}) })
12795
- ] }),
12755
+ ) }) : /* @__PURE__ */ l(Me, { fallback: /* @__PURE__ */ l(vi, {}), children: /* @__PURE__ */ l("div", { className: D("flex-1 flex flex-col min-h-0 overflow-hidden relative synapse-chat-window"), children: [
12756
+ /* @__PURE__ */ l("div", { className: "relative flex min-h-0 flex-1 flex-col overflow-hidden", children: /* @__PURE__ */ l(
12757
+ La,
12758
+ {
12759
+ ref: s,
12760
+ className: "flex-1 min-h-0 [&>[data-radix-scroll-area-viewport]>div]:!flex [&>[data-radix-scroll-area-viewport]>div]:flex-col [&>[data-radix-scroll-area-viewport]>div]:min-h-full",
12761
+ children: [
12762
+ /* @__PURE__ */ l("div", { className: "flex-1" }),
12763
+ /* @__PURE__ */ l(
12764
+ "div",
12765
+ {
12766
+ className: D(
12767
+ "transition-all duration-300 min-w-0 overflow-x-hidden",
12768
+ f ? "pt-4 px-4 space-y-3" : "pt-4 px-4 space-y-4",
12769
+ // Center the chat content in fullscreen so messages don't
12770
+ // sprawl across the whole viewport mirrors the Figma layout.
12771
+ o === "full" && "max-w-2xl mx-auto w-full"
12772
+ ),
12773
+ children: [
12774
+ g && /* @__PURE__ */ l("div", { className: "text-xs text-[var(--color-muted-foreground)] text-center mb-2", children: "Just now" }),
12775
+ !g && /* @__PURE__ */ l("div", { className: "text-xs text-[var(--color-muted-foreground)] text-center", children: pe }),
12776
+ /* @__PURE__ */ l(Me, { fallback: /* @__PURE__ */ l(Vu, {}), children: /* @__PURE__ */ l(
12777
+ Xf,
12778
+ {
12779
+ messages: N,
12780
+ onSendMessage: w,
12781
+ iconUrl: n.iconUrl,
12782
+ onToggleFeedback: T,
12783
+ onClearElicitationState: S,
12784
+ isAuthComponent: _,
12785
+ isFullScreen: o === "full",
12786
+ initialMessage: n.initialMessage,
12787
+ disabled: !b || y
12788
+ }
12789
+ ) }),
12790
+ /* @__PURE__ */ l("div", { ref: a })
12791
+ ]
12792
+ }
12793
+ )
12794
+ ]
12795
+ }
12796
+ ) }),
12796
12797
  i && /* @__PURE__ */ l("div", { className: "absolute bottom-[10px] left-1/2 transform -translate-x-1/2 z-10", children: /* @__PURE__ */ l(
12797
12798
  ce,
12798
12799
  {
@@ -12993,7 +12994,7 @@ const im = (e, t, n) => {
12993
12994
  };
12994
12995
  typeof window < "u" && (window.renderMedAssist = im);
12995
12996
  export {
12996
- G as A,
12997
+ W as A,
12997
12998
  ce as B,
12998
12999
  No as C,
12999
13000
  K as D,