@chatsystem/client 1.1.25 → 1.1.26
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.cjs +19 -19
- package/dist/index.cjs.map +1 -1
- package/dist/index.mjs +128 -128
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
package/dist/index.mjs
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { jsx as
|
|
1
|
+
import { jsx as B, Fragment as rn, jsxs as De } from "react/jsx-runtime";
|
|
2
2
|
import * as Qe from "react";
|
|
3
3
|
import ke, { useState as ge, useEffect as Pe, useRef as we, forwardRef as os, useMemo as xn, useImperativeHandle as Dl, useContext as lt, useCallback as Ut, createContext as kl, useLayoutEffect as wl } from "react";
|
|
4
4
|
import Ml from "lottie-react";
|
|
@@ -176,7 +176,7 @@ function Hl() {
|
|
|
176
176
|
function p(U) {
|
|
177
177
|
return D(U) === c;
|
|
178
178
|
}
|
|
179
|
-
function
|
|
179
|
+
function F(U) {
|
|
180
180
|
return D(U) === o;
|
|
181
181
|
}
|
|
182
182
|
function X(U) {
|
|
@@ -209,7 +209,7 @@ function Hl() {
|
|
|
209
209
|
function _e(U) {
|
|
210
210
|
return D(U) === d;
|
|
211
211
|
}
|
|
212
|
-
Te.AsyncMode = x, Te.ConcurrentMode = I, Te.ContextConsumer = q, Te.ContextProvider = ue, Te.Element = te, Te.ForwardRef = Y, Te.Fragment = M, Te.Lazy = w, Te.Memo = G, Te.Portal = $, Te.Profiler = W, Te.StrictMode = se, Te.Suspense = me, Te.isAsyncMode = Le, Te.isConcurrentMode = p, Te.isContextConsumer =
|
|
212
|
+
Te.AsyncMode = x, Te.ConcurrentMode = I, Te.ContextConsumer = q, Te.ContextProvider = ue, Te.Element = te, Te.ForwardRef = Y, Te.Fragment = M, Te.Lazy = w, Te.Memo = G, Te.Portal = $, Te.Profiler = W, Te.StrictMode = se, Te.Suspense = me, Te.isAsyncMode = Le, Te.isConcurrentMode = p, Te.isContextConsumer = F, Te.isContextProvider = X, Te.isElement = T, Te.isForwardRef = V, Te.isFragment = K, Te.isLazy = z, Te.isMemo = Q, Te.isPortal = ee, Te.isProfiler = ae, Te.isStrictMode = Z, Te.isSuspense = _e, Te.isValidElementType = N, Te.typeOf = D;
|
|
213
213
|
})()), Te;
|
|
214
214
|
}
|
|
215
215
|
var yi;
|
|
@@ -4298,12 +4298,12 @@ const Pf = ({
|
|
|
4298
4298
|
), console.log(
|
|
4299
4299
|
"hasDIsplayedCss",
|
|
4300
4300
|
l.appInternalContext.hasDisplayedCSS
|
|
4301
|
-
), /* @__PURE__ */
|
|
4301
|
+
), /* @__PURE__ */ B(rn, { children: /* @__PURE__ */ B(
|
|
4302
4302
|
of,
|
|
4303
4303
|
{
|
|
4304
4304
|
locale: i?.locale,
|
|
4305
4305
|
messages: i?.translatedText,
|
|
4306
|
-
children: /* @__PURE__ */
|
|
4306
|
+
children: /* @__PURE__ */ B(Bs.Provider, { value: o, children: /* @__PURE__ */ B(Us.Provider, { value: l, children: /* @__PURE__ */ B(Sr.Provider, { value: c, children: /* @__PURE__ */ B(
|
|
4307
4307
|
Fs.Provider,
|
|
4308
4308
|
{
|
|
4309
4309
|
value: f,
|
|
@@ -4323,7 +4323,7 @@ const Pf = ({
|
|
|
4323
4323
|
}).catch(() => n(null)), () => {
|
|
4324
4324
|
t && !r && (URL.revokeObjectURL(t), r = !0);
|
|
4325
4325
|
};
|
|
4326
|
-
}, [e]), /* @__PURE__ */
|
|
4326
|
+
}, [e]), /* @__PURE__ */ B("img", { src: t ?? e, decoding: "async", loading: "eager" });
|
|
4327
4327
|
};
|
|
4328
4328
|
function Bf(e) {
|
|
4329
4329
|
return !!e && typeof e == "object" && "blob" in e && e.blob instanceof Blob;
|
|
@@ -4354,21 +4354,21 @@ function Ff({
|
|
|
4354
4354
|
), () => {
|
|
4355
4355
|
m = !0, d && URL.revokeObjectURL(d);
|
|
4356
4356
|
};
|
|
4357
|
-
}, [e]), c.kind === "loading" ? /* @__PURE__ */
|
|
4357
|
+
}, [e]), c.kind === "loading" ? /* @__PURE__ */ B(
|
|
4358
4358
|
"div",
|
|
4359
4359
|
{
|
|
4360
4360
|
className: "flex items-center justify-center rounded-xl border border-dashed p-6 text-sm opacity-70 " + (r ?? ""),
|
|
4361
4361
|
style: { minHeight: 96, ...a },
|
|
4362
4362
|
children: i ?? "Loading animation…"
|
|
4363
4363
|
}
|
|
4364
|
-
) : c.kind === "error" ? /* @__PURE__ */
|
|
4364
|
+
) : c.kind === "error" ? /* @__PURE__ */ B(
|
|
4365
4365
|
"div",
|
|
4366
4366
|
{
|
|
4367
4367
|
className: "flex items-center justify-center rounded-xl border p-6 text-sm text-red-600 " + (r ?? ""),
|
|
4368
4368
|
style: { minHeight: 96, ...a },
|
|
4369
4369
|
children: u ?? "Failed to load animation"
|
|
4370
4370
|
}
|
|
4371
|
-
) : c.kind === "json" ? /* @__PURE__ */
|
|
4371
|
+
) : c.kind === "json" ? /* @__PURE__ */ B(
|
|
4372
4372
|
Ml,
|
|
4373
4373
|
{
|
|
4374
4374
|
animationData: c.data,
|
|
@@ -4378,7 +4378,7 @@ function Ff({
|
|
|
4378
4378
|
style: a,
|
|
4379
4379
|
rendererSettings: { preserveAspectRatio: "xMidYMid meet" }
|
|
4380
4380
|
}
|
|
4381
|
-
) : /* @__PURE__ */
|
|
4381
|
+
) : /* @__PURE__ */ B(
|
|
4382
4382
|
Bl,
|
|
4383
4383
|
{
|
|
4384
4384
|
src: c.blobUrl,
|
|
@@ -4565,7 +4565,7 @@ const $f = os(function({
|
|
|
4565
4565
|
onEnd: x,
|
|
4566
4566
|
onFrame: I
|
|
4567
4567
|
}, q) {
|
|
4568
|
-
const ue = we(null), te = we(null), [Y, M] = ge(null), [w, G] = ge(null), [$, W] = ge(null), [se, me] = ge(!1), [ve, Le] = ge(!!d), [p,
|
|
4568
|
+
const ue = we(null), te = we(null), [Y, M] = ge(null), [w, G] = ge(null), [$, W] = ge(null), [se, me] = ge(!1), [ve, Le] = ge(!!d), [p, F] = ge(h), X = we(1), [T, V] = ge(null), K = Math.max(
|
|
4569
4569
|
1,
|
|
4570
4570
|
Math.floor(typeof window < "u" && window.devicePixelRatio || 1)
|
|
4571
4571
|
);
|
|
@@ -4700,7 +4700,7 @@ const $f = os(function({
|
|
|
4700
4700
|
xe(p);
|
|
4701
4701
|
return;
|
|
4702
4702
|
}
|
|
4703
|
-
le = Ee - Ne % Ie,
|
|
4703
|
+
le = Ee - Ne % Ie, F((Ye) => {
|
|
4704
4704
|
const He = Ce.length - 1;
|
|
4705
4705
|
let Ke = Ye;
|
|
4706
4706
|
return y === "forward" ? Ke = Ye + 1 : y === "backward" ? Ke = Ye - 1 : ((Ye >= He && X.current === 1 || Ye <= 0 && X.current === -1) && (X.current *= -1), Ke = Ye + X.current), (Ke > He || Ke < 0) && (m ? Ke = y === "backward" ? He : 0 : (Ke = Math.max(0, Math.min(Ke, He)), Le(!1), x?.())), Ke;
|
|
@@ -4723,7 +4723,7 @@ const $f = os(function({
|
|
|
4723
4723
|
play: () => Le(!0),
|
|
4724
4724
|
pause: () => Le(!1),
|
|
4725
4725
|
toggle: () => Le((le) => !le),
|
|
4726
|
-
gotoFrame: (le) =>
|
|
4726
|
+
gotoFrame: (le) => F(() => Math.max(
|
|
4727
4727
|
0,
|
|
4728
4728
|
Math.min(le, Math.max(0, Ce.length - 1))
|
|
4729
4729
|
)),
|
|
@@ -4731,7 +4731,7 @@ const $f = os(function({
|
|
|
4731
4731
|
currentFrame: () => p
|
|
4732
4732
|
}),
|
|
4733
4733
|
[ve, p, Ce.length]
|
|
4734
|
-
), /* @__PURE__ */
|
|
4734
|
+
), /* @__PURE__ */ B("div", { className: S, style: R, children: /* @__PURE__ */ B("canvas", { ref: ue, "aria-label": "spritesheet animation" }) });
|
|
4735
4735
|
});
|
|
4736
4736
|
function Yf({
|
|
4737
4737
|
url: e,
|
|
@@ -4748,12 +4748,12 @@ function Yf({
|
|
|
4748
4748
|
}, [e]), a ? /* @__PURE__ */ De("div", { className: t, role: "alert", children: [
|
|
4749
4749
|
"Couldn’t load SVG: ",
|
|
4750
4750
|
a
|
|
4751
|
-
] }) : n ? /* @__PURE__ */
|
|
4751
|
+
] }) : n ? /* @__PURE__ */ B("div", { className: t, dangerouslySetInnerHTML: { __html: n } }) : /* @__PURE__ */ B("div", { className: t });
|
|
4752
4752
|
}
|
|
4753
4753
|
const Qa = ({ facet: e }) => {
|
|
4754
4754
|
const { mode: t, assetUrl: n } = e;
|
|
4755
4755
|
return /* @__PURE__ */ De("div", { className: "assetContainer", children: [
|
|
4756
|
-
t === We.AgentDisplayFacetModeType.LOTTIE && /* @__PURE__ */
|
|
4756
|
+
t === We.AgentDisplayFacetModeType.LOTTIE && /* @__PURE__ */ B(
|
|
4757
4757
|
Ff,
|
|
4758
4758
|
{
|
|
4759
4759
|
src: n,
|
|
@@ -4761,9 +4761,9 @@ const Qa = ({ facet: e }) => {
|
|
|
4761
4761
|
onError: (r) => console.error(r)
|
|
4762
4762
|
}
|
|
4763
4763
|
),
|
|
4764
|
-
t === We.AgentDisplayFacetModeType.SVG && /* @__PURE__ */
|
|
4765
|
-
t === We.AgentDisplayFacetModeType.IMAGE && /* @__PURE__ */
|
|
4766
|
-
t === We.AgentDisplayFacetModeType.SPRITESHEET && /* @__PURE__ */
|
|
4764
|
+
t === We.AgentDisplayFacetModeType.SVG && /* @__PURE__ */ B("div", { children: /* @__PURE__ */ B(Yf, { url: n }) }),
|
|
4765
|
+
t === We.AgentDisplayFacetModeType.IMAGE && /* @__PURE__ */ B(Mf, { src: n }),
|
|
4766
|
+
t === We.AgentDisplayFacetModeType.SPRITESHEET && /* @__PURE__ */ B($f, { src: n })
|
|
4767
4767
|
] });
|
|
4768
4768
|
}, Gf = ({
|
|
4769
4769
|
isWidgetOpen: e,
|
|
@@ -4787,13 +4787,13 @@ const Qa = ({ facet: e }) => {
|
|
|
4787
4787
|
`,
|
|
4788
4788
|
onClick: () => t(!e),
|
|
4789
4789
|
children: [
|
|
4790
|
-
!e && /* @__PURE__ */
|
|
4790
|
+
!e && /* @__PURE__ */ B(
|
|
4791
4791
|
Qa,
|
|
4792
4792
|
{
|
|
4793
4793
|
facet: n.agent.display[We.AgentDisplayFacetRoleType.LAUNCHER]
|
|
4794
4794
|
}
|
|
4795
4795
|
),
|
|
4796
|
-
e && /* @__PURE__ */
|
|
4796
|
+
e && /* @__PURE__ */ B(wf, { className: "w-6 h-6", fill: "white" })
|
|
4797
4797
|
]
|
|
4798
4798
|
}
|
|
4799
4799
|
);
|
|
@@ -7734,7 +7734,7 @@ function Pd(e, t, n) {
|
|
|
7734
7734
|
return T === null || J(T) ? w(T) : he(T) ? (e.consume(T), M) : n(T);
|
|
7735
7735
|
}
|
|
7736
7736
|
function w(T) {
|
|
7737
|
-
return T === 45 && a === 2 ? (e.consume(T), se) : T === 60 && a === 1 ? (e.consume(T), me) : T === 62 && a === 4 ? (e.consume(T),
|
|
7737
|
+
return T === 45 && a === 2 ? (e.consume(T), se) : T === 60 && a === 1 ? (e.consume(T), me) : T === 62 && a === 4 ? (e.consume(T), F) : T === 63 && a === 3 ? (e.consume(T), p) : T === 93 && a === 5 ? (e.consume(T), Le) : J(T) && (a === 6 || a === 7) ? (e.exit("htmlFlowData"), e.check(
|
|
7738
7738
|
Ld,
|
|
7739
7739
|
X,
|
|
7740
7740
|
G
|
|
@@ -7762,7 +7762,7 @@ function Pd(e, t, n) {
|
|
|
7762
7762
|
function ve(T) {
|
|
7763
7763
|
if (T === 62) {
|
|
7764
7764
|
const V = u.toLowerCase();
|
|
7765
|
-
return su.includes(V) ? (e.consume(T),
|
|
7765
|
+
return su.includes(V) ? (e.consume(T), F) : w(T);
|
|
7766
7766
|
}
|
|
7767
7767
|
return Et(T) && u.length < 8 ? (e.consume(T), u += String.fromCharCode(T), ve) : w(T);
|
|
7768
7768
|
}
|
|
@@ -7770,10 +7770,10 @@ function Pd(e, t, n) {
|
|
|
7770
7770
|
return T === 93 ? (e.consume(T), p) : w(T);
|
|
7771
7771
|
}
|
|
7772
7772
|
function p(T) {
|
|
7773
|
-
return T === 62 ? (e.consume(T),
|
|
7773
|
+
return T === 62 ? (e.consume(T), F) : T === 45 && a === 2 ? (e.consume(T), p) : w(T);
|
|
7774
7774
|
}
|
|
7775
|
-
function
|
|
7776
|
-
return T === null || J(T) ? (e.exit("htmlFlowData"), X(T)) : (e.consume(T),
|
|
7775
|
+
function F(T) {
|
|
7776
|
+
return T === null || J(T) ? (e.exit("htmlFlowData"), X(T)) : (e.consume(T), F);
|
|
7777
7777
|
}
|
|
7778
7778
|
function X(T) {
|
|
7779
7779
|
return e.exit("htmlFlow"), t(T);
|
|
@@ -7825,8 +7825,8 @@ function Md(e, t, n) {
|
|
|
7825
7825
|
return p === 62 ? se(p) : p === 45 ? m(p) : d(p);
|
|
7826
7826
|
}
|
|
7827
7827
|
function y(p) {
|
|
7828
|
-
const
|
|
7829
|
-
return p ===
|
|
7828
|
+
const F = "CDATA[";
|
|
7829
|
+
return p === F.charCodeAt(i++) ? (e.consume(p), i === F.length ? A : y) : n(p);
|
|
7830
7830
|
}
|
|
7831
7831
|
function A(p) {
|
|
7832
7832
|
return p === null ? n(p) : p === 93 ? (e.consume(p), L) : J(p) ? (u = A, me(p)) : (e.consume(p), A);
|
|
@@ -8527,8 +8527,8 @@ function hh(e, t, n) {
|
|
|
8527
8527
|
return Array.isArray($) ? X($) : "tokenize" in $ ? (
|
|
8528
8528
|
// @ts-expect-error Looks like a construct.
|
|
8529
8529
|
X([$])
|
|
8530
|
-
) :
|
|
8531
|
-
function
|
|
8530
|
+
) : F($);
|
|
8531
|
+
function F(z) {
|
|
8532
8532
|
return Q;
|
|
8533
8533
|
function Q(ee) {
|
|
8534
8534
|
const ae = ee !== null && z[ee], Z = ee !== null && z.null, _e = [
|
|
@@ -8879,7 +8879,7 @@ function Dh(e) {
|
|
|
8879
8879
|
paragraph: l(),
|
|
8880
8880
|
referenceString: V,
|
|
8881
8881
|
resourceDestinationString: p,
|
|
8882
|
-
resourceTitleString:
|
|
8882
|
+
resourceTitleString: F,
|
|
8883
8883
|
resource: X,
|
|
8884
8884
|
setextHeading: l(ue),
|
|
8885
8885
|
setextHeadingLineSequence: q,
|
|
@@ -9173,7 +9173,7 @@ function Dh(e) {
|
|
|
9173
9173
|
const O = this.resume(), H = this.stack[this.stack.length - 1];
|
|
9174
9174
|
H.url = O;
|
|
9175
9175
|
}
|
|
9176
|
-
function
|
|
9176
|
+
function F() {
|
|
9177
9177
|
const O = this.resume(), H = this.stack[this.stack.length - 1];
|
|
9178
9178
|
H.title = O;
|
|
9179
9179
|
}
|
|
@@ -11484,7 +11484,7 @@ function Ro(e) {
|
|
|
11484
11484
|
Fragment: rn,
|
|
11485
11485
|
components: i,
|
|
11486
11486
|
ignoreInvalidStyle: !0,
|
|
11487
|
-
jsx:
|
|
11487
|
+
jsx: B,
|
|
11488
11488
|
jsxs: De,
|
|
11489
11489
|
passKeys: !0,
|
|
11490
11490
|
passNode: !0
|
|
@@ -17865,21 +17865,21 @@ const hb = (e) => /* @__PURE__ */ Qe.createElement("svg", { xmlns: "http://www.w
|
|
|
17865
17865
|
}) => {
|
|
17866
17866
|
const { chatlineLabelUserTranslation: n } = Ka();
|
|
17867
17867
|
return /* @__PURE__ */ De("div", { className: "flex px-3 justify-between mt-8 bg-gray-200 rounded-lg", children: [
|
|
17868
|
-
/* @__PURE__ */
|
|
17868
|
+
/* @__PURE__ */ B("div", { className: "w-10 mr-3 flex-col content-center", children: /* @__PURE__ */ B("div", { children: /* @__PURE__ */ B(hb, { fill: "#4564d6" }) }) }),
|
|
17869
17869
|
/* @__PURE__ */ De(
|
|
17870
17870
|
"div",
|
|
17871
17871
|
{
|
|
17872
17872
|
className: `w-full p-4 rounded-lg transition-all duration-300 ${t?.isErrorMessage ? "bg-red-100 border-l-4 border-red-400 text-red-800 shadow-md animate-fade-in" : " text-gray-800"}`,
|
|
17873
17873
|
children: [
|
|
17874
|
-
/* @__PURE__ */
|
|
17875
|
-
/* @__PURE__ */
|
|
17874
|
+
/* @__PURE__ */ B("p", { className: "font-bold", children: n }),
|
|
17875
|
+
/* @__PURE__ */ B("div", { children: /* @__PURE__ */ B(Ro, { rehypePlugins: [El], children: e && e }) })
|
|
17876
17876
|
]
|
|
17877
17877
|
}
|
|
17878
17878
|
)
|
|
17879
17879
|
] });
|
|
17880
17880
|
}, pb = ({}) => {
|
|
17881
17881
|
const { companySettings: e } = lt(Sr);
|
|
17882
|
-
return /* @__PURE__ */
|
|
17882
|
+
return /* @__PURE__ */ B(
|
|
17883
17883
|
"div",
|
|
17884
17884
|
{
|
|
17885
17885
|
className: `assistant
|
|
@@ -17891,7 +17891,7 @@ const hb = (e) => /* @__PURE__ */ Qe.createElement("svg", { xmlns: "http://www.w
|
|
|
17891
17891
|
justify-center
|
|
17892
17892
|
items-center
|
|
17893
17893
|
`,
|
|
17894
|
-
children: /* @__PURE__ */
|
|
17894
|
+
children: /* @__PURE__ */ B(
|
|
17895
17895
|
Qa,
|
|
17896
17896
|
{
|
|
17897
17897
|
facet: e.agent.display[We.AgentDisplayFacetRoleType.ASSISTANT]
|
|
@@ -17902,14 +17902,14 @@ const hb = (e) => /* @__PURE__ */ Qe.createElement("svg", { xmlns: "http://www.w
|
|
|
17902
17902
|
}, Eb = ({ content: e, metaData: t }) => {
|
|
17903
17903
|
const { chatlineLabelAssistantTranslation: n } = Ka();
|
|
17904
17904
|
return /* @__PURE__ */ De("div", { className: "flex justify-between mt-8 px-3", children: [
|
|
17905
|
-
/* @__PURE__ */
|
|
17905
|
+
/* @__PURE__ */ B("div", { className: "w-10 mr-3 mt-6", children: /* @__PURE__ */ B("div", { children: /* @__PURE__ */ B(pb, {}) }) }),
|
|
17906
17906
|
/* @__PURE__ */ De(
|
|
17907
17907
|
"div",
|
|
17908
17908
|
{
|
|
17909
17909
|
className: `w-full p-4 rounded-lg transition-all duration-300 ${t?.isErrorMessage ? "bg-red-100 border-l-4 border-red-400 text-red-800 shadow-md animate-fade-in" : "bg-white text-gray-800"}`,
|
|
17910
17910
|
children: [
|
|
17911
|
-
/* @__PURE__ */
|
|
17912
|
-
/* @__PURE__ */
|
|
17911
|
+
/* @__PURE__ */ B("p", { className: "font-bold", children: n }),
|
|
17912
|
+
/* @__PURE__ */ B("div", { children: /* @__PURE__ */ B(Ro, { rehypePlugins: [El], children: e && e }) })
|
|
17913
17913
|
]
|
|
17914
17914
|
}
|
|
17915
17915
|
)
|
|
@@ -17919,8 +17919,8 @@ const hb = (e) => /* @__PURE__ */ Qe.createElement("svg", { xmlns: "http://www.w
|
|
|
17919
17919
|
content: t,
|
|
17920
17920
|
metaData: n
|
|
17921
17921
|
}) => /* @__PURE__ */ De(rn, { children: [
|
|
17922
|
-
e === "user" && /* @__PURE__ */
|
|
17923
|
-
e === "assistant" && /* @__PURE__ */
|
|
17922
|
+
e === "user" && /* @__PURE__ */ B(mb, { content: t, metaData: n }),
|
|
17923
|
+
e === "assistant" && /* @__PURE__ */ B(Eb, { content: t, metaData: n })
|
|
17924
17924
|
] });
|
|
17925
17925
|
function Tb(e, t, n) {
|
|
17926
17926
|
let [r, a] = ge(e || t), i = we(e !== void 0), u = e !== void 0;
|
|
@@ -18839,8 +18839,8 @@ const ST = (e) => e.charCodeAt(e.length - 1) === 10, CT = (e) => {
|
|
|
18839
18839
|
className: `${e.classNameContainer} w-fu`,
|
|
18840
18840
|
children: [
|
|
18841
18841
|
/* @__PURE__ */ De("div", { style: { display: "flex", flexDirection: "column" }, children: [
|
|
18842
|
-
/* @__PURE__ */
|
|
18843
|
-
/* @__PURE__ */
|
|
18842
|
+
/* @__PURE__ */ B("label", { ...h, className: e.classNameLabel, children: u }),
|
|
18843
|
+
/* @__PURE__ */ B(
|
|
18844
18844
|
"textarea",
|
|
18845
18845
|
{
|
|
18846
18846
|
...y,
|
|
@@ -18861,21 +18861,21 @@ const ST = (e) => e.charCodeAt(e.length - 1) === 10, CT = (e) => {
|
|
|
18861
18861
|
}
|
|
18862
18862
|
)
|
|
18863
18863
|
] }),
|
|
18864
|
-
!c && o && /* @__PURE__ */
|
|
18864
|
+
!c && o && /* @__PURE__ */ B("div", { className: "relative", children: /* @__PURE__ */ B(
|
|
18865
18865
|
o,
|
|
18866
18866
|
{
|
|
18867
18867
|
onSubmitButton: R,
|
|
18868
18868
|
isDisabled: S
|
|
18869
18869
|
}
|
|
18870
18870
|
) }),
|
|
18871
|
-
c && f && /* @__PURE__ */
|
|
18871
|
+
c && f && /* @__PURE__ */ B("div", { className: "relative", children: /* @__PURE__ */ B(f, { onPressLoadingButton: N }) })
|
|
18872
18872
|
]
|
|
18873
18873
|
}
|
|
18874
18874
|
);
|
|
18875
18875
|
}, xT = ({
|
|
18876
18876
|
onSubmitButton: e,
|
|
18877
18877
|
isDisabled: t
|
|
18878
|
-
}) => /* @__PURE__ */
|
|
18878
|
+
}) => /* @__PURE__ */ B("div", { children: /* @__PURE__ */ B(
|
|
18879
18879
|
"button",
|
|
18880
18880
|
{
|
|
18881
18881
|
className: `absolute
|
|
@@ -18898,7 +18898,7 @@ const ST = (e) => e.charCodeAt(e.length - 1) === 10, CT = (e) => {
|
|
|
18898
18898
|
"data-testid": "send-button",
|
|
18899
18899
|
onClick: e,
|
|
18900
18900
|
disabled: t,
|
|
18901
|
-
children: /* @__PURE__ */
|
|
18901
|
+
children: /* @__PURE__ */ B("span", { className: "", "data-state": "closed", children: /* @__PURE__ */ B(
|
|
18902
18902
|
"svg",
|
|
18903
18903
|
{
|
|
18904
18904
|
width: "24",
|
|
@@ -18906,7 +18906,7 @@ const ST = (e) => e.charCodeAt(e.length - 1) === 10, CT = (e) => {
|
|
|
18906
18906
|
viewBox: "0 0 24 24",
|
|
18907
18907
|
fill: "none",
|
|
18908
18908
|
className: "text-white dark:text-black",
|
|
18909
|
-
children: /* @__PURE__ */
|
|
18909
|
+
children: /* @__PURE__ */ B(
|
|
18910
18910
|
"path",
|
|
18911
18911
|
{
|
|
18912
18912
|
d: "M7 11L12 6L17 11M12 18V7",
|
|
@@ -18991,7 +18991,7 @@ const Il = () => {
|
|
|
18991
18991
|
};
|
|
18992
18992
|
}, RT = ({}) => {
|
|
18993
18993
|
const { companySettings: e } = lt(Sr);
|
|
18994
|
-
return /* @__PURE__ */
|
|
18994
|
+
return /* @__PURE__ */ B(
|
|
18995
18995
|
"div",
|
|
18996
18996
|
{
|
|
18997
18997
|
className: `search
|
|
@@ -19002,7 +19002,7 @@ const Il = () => {
|
|
|
19002
19002
|
justify-center
|
|
19003
19003
|
items-center
|
|
19004
19004
|
`,
|
|
19005
|
-
children: /* @__PURE__ */
|
|
19005
|
+
children: /* @__PURE__ */ B(
|
|
19006
19006
|
Qa,
|
|
19007
19007
|
{
|
|
19008
19008
|
facet: e.agent.display[We.AgentDisplayFacetRoleType.SEARCH]
|
|
@@ -19021,32 +19021,32 @@ const Il = () => {
|
|
|
19021
19021
|
stepTranslation: i,
|
|
19022
19022
|
lookingForProductTranslation: u
|
|
19023
19023
|
} = Il();
|
|
19024
|
-
return /* @__PURE__ */
|
|
19024
|
+
return /* @__PURE__ */ B(rn, { children: e === "loadingIntermediaryStates" && /* @__PURE__ */ De("div", { children: [
|
|
19025
19025
|
/* @__PURE__ */ De("div", { children: [
|
|
19026
19026
|
/* @__PURE__ */ De("p", { className: "text-center my-2 text-lg", children: [
|
|
19027
19027
|
u,
|
|
19028
19028
|
"..."
|
|
19029
19029
|
] }),
|
|
19030
|
-
/* @__PURE__ */
|
|
19030
|
+
/* @__PURE__ */ B("p", { className: "text-center my-1 text-md", children: t && `${a(t)}` }),
|
|
19031
19031
|
n && /* @__PURE__ */ De("p", { className: "text-center my-2", children: [
|
|
19032
19032
|
i,
|
|
19033
|
-
/* @__PURE__ */
|
|
19033
|
+
/* @__PURE__ */ B("span", { children: " " }),
|
|
19034
19034
|
n,
|
|
19035
19035
|
"/",
|
|
19036
19036
|
r
|
|
19037
19037
|
] })
|
|
19038
19038
|
] }),
|
|
19039
|
-
/* @__PURE__ */
|
|
19039
|
+
/* @__PURE__ */ B("div", { className: "flex justify-center", children: /* @__PURE__ */ B(RT, {}) })
|
|
19040
19040
|
] }) });
|
|
19041
19041
|
}, PT = ({
|
|
19042
19042
|
onPressLoadingButton: e
|
|
19043
|
-
}) => /* @__PURE__ */
|
|
19043
|
+
}) => /* @__PURE__ */ B("div", { children: /* @__PURE__ */ B(
|
|
19044
19044
|
"button",
|
|
19045
19045
|
{
|
|
19046
19046
|
className: "absolute bg-white md:bottom-2 md:right-3 dark:hover:bg-white right-2 bottom-1.5 disabled:opacity-10 disabled:text-gray-400 enabled:bg-white text-white p-0.5 border border-white rounded-lg dark:border-white dark:bg-white transition-colors",
|
|
19047
19047
|
"data-testid": "send-button",
|
|
19048
19048
|
onClick: e,
|
|
19049
|
-
children: /* @__PURE__ */
|
|
19049
|
+
children: /* @__PURE__ */ B("span", { className: "", "data-state": "closed", children: /* @__PURE__ */ De(
|
|
19050
19050
|
"svg",
|
|
19051
19051
|
{
|
|
19052
19052
|
fill: "#000000",
|
|
@@ -19057,8 +19057,8 @@ const Il = () => {
|
|
|
19057
19057
|
xmlns: "http://www.w3.org/2000/svg",
|
|
19058
19058
|
viewBox: "0 0 297 297",
|
|
19059
19059
|
children: [
|
|
19060
|
-
/* @__PURE__ */
|
|
19061
|
-
/* @__PURE__ */
|
|
19060
|
+
/* @__PURE__ */ B("g", { id: "SVGRepo_bgCarrier", "stroke-width": "0" }),
|
|
19061
|
+
/* @__PURE__ */ B(
|
|
19062
19062
|
"g",
|
|
19063
19063
|
{
|
|
19064
19064
|
id: "SVGRepo_tracerCarrier",
|
|
@@ -19068,7 +19068,7 @@ const Il = () => {
|
|
|
19068
19068
|
),
|
|
19069
19069
|
/* @__PURE__ */ De("g", { id: "SVGRepo_iconCarrier", children: [
|
|
19070
19070
|
" ",
|
|
19071
|
-
/* @__PURE__ */
|
|
19071
|
+
/* @__PURE__ */ B("path", { d: "M148.5,0C66.486,0,0,66.486,0,148.5S66.486,297,148.5,297S297,230.514,297,148.5S230.514,0,148.5,0z M213.292,190.121 c0,12.912-10.467,23.379-23.378,23.379H106.67c-12.911,0-23.378-10.467-23.378-23.379v-83.242c0-12.912,10.467-23.379,23.378-23.379 h83.244c12.911,0,23.378,10.467,23.378,23.379V190.121z" }),
|
|
19072
19072
|
" "
|
|
19073
19073
|
] })
|
|
19074
19074
|
]
|
|
@@ -19178,7 +19178,7 @@ const Nl = ({
|
|
|
19178
19178
|
});
|
|
19179
19179
|
fetch(`${w}/ai/prompt/${e}`, W).then(async (se) => {
|
|
19180
19180
|
const me = se?.body?.getReader(), ve = new TextDecoder();
|
|
19181
|
-
let Le = "", p = "",
|
|
19181
|
+
let Le = "", p = "", F = !1, X = !1, T = null;
|
|
19182
19182
|
await new ReadableStream({
|
|
19183
19183
|
start(z) {
|
|
19184
19184
|
return Q();
|
|
@@ -19196,7 +19196,7 @@ const Nl = ({
|
|
|
19196
19196
|
streamSourceUuid: Ie,
|
|
19197
19197
|
shouldStopStream: pe
|
|
19198
19198
|
} = Fe;
|
|
19199
|
-
T && T !== Ie && (Le += '<span style="display:block;height:1rem;"></span>'), T = Ie, (le || pe) && (X = !0), z.enqueue(xe), NT(xe) ? (p += xe, Le += p, p = "",
|
|
19199
|
+
T && T !== Ie && (Le += '<span style="display:block;height:1rem;"></span>'), T = Ie, (le || pe) && (X = !0), z.enqueue(xe), NT(xe) ? (p += xe, Le += p, p = "", F = !1) : F || IT(xe) ? (p += xe, F = !0) : Le += xe, i((Ee) => {
|
|
19200
19200
|
const Ne = [...Ee], Ye = Ne.length - 1, He = Ne[Ye];
|
|
19201
19201
|
return Ne[Ye] = {
|
|
19202
19202
|
...He,
|
|
@@ -19258,7 +19258,7 @@ const Nl = ({
|
|
|
19258
19258
|
className: "flex-1 overflow-y-auto min-h-0 messagesContainer",
|
|
19259
19259
|
ref: I,
|
|
19260
19260
|
children: [
|
|
19261
|
-
a.map((M, w) => /* @__PURE__ */
|
|
19261
|
+
a.map((M, w) => /* @__PURE__ */ B(
|
|
19262
19262
|
bb,
|
|
19263
19263
|
{
|
|
19264
19264
|
content: M.content,
|
|
@@ -19267,7 +19267,7 @@ const Nl = ({
|
|
|
19267
19267
|
},
|
|
19268
19268
|
w
|
|
19269
19269
|
)),
|
|
19270
|
-
/* @__PURE__ */
|
|
19270
|
+
/* @__PURE__ */ B(
|
|
19271
19271
|
vT,
|
|
19272
19272
|
{
|
|
19273
19273
|
currentStepName: h,
|
|
@@ -19279,7 +19279,7 @@ const Nl = ({
|
|
|
19279
19279
|
]
|
|
19280
19280
|
}
|
|
19281
19281
|
),
|
|
19282
|
-
x && /* @__PURE__ */
|
|
19282
|
+
x && /* @__PURE__ */ B(
|
|
19283
19283
|
"button",
|
|
19284
19284
|
{
|
|
19285
19285
|
onClick: () => D({
|
|
@@ -19288,7 +19288,7 @@ const Nl = ({
|
|
|
19288
19288
|
}),
|
|
19289
19289
|
className: "absolute bottom-[120px] right-4 bg-blue-500 hover:bg-blue-600 text-white p-3 rounded-full shadow-lg transition-all duration-300 z-10",
|
|
19290
19290
|
"aria-label": "Scroll to bottom",
|
|
19291
|
-
children: /* @__PURE__ */
|
|
19291
|
+
children: /* @__PURE__ */ B(
|
|
19292
19292
|
"svg",
|
|
19293
19293
|
{
|
|
19294
19294
|
width: "20",
|
|
@@ -19296,7 +19296,7 @@ const Nl = ({
|
|
|
19296
19296
|
viewBox: "0 0 24 24",
|
|
19297
19297
|
fill: "none",
|
|
19298
19298
|
xmlns: "http://www.w3.org/2000/svg",
|
|
19299
|
-
children: /* @__PURE__ */
|
|
19299
|
+
children: /* @__PURE__ */ B(
|
|
19300
19300
|
"path",
|
|
19301
19301
|
{
|
|
19302
19302
|
d: "M12 16L6 10L7.4 8.6L12 13.2L16.6 8.6L18 10L12 16Z",
|
|
@@ -19307,7 +19307,7 @@ const Nl = ({
|
|
|
19307
19307
|
)
|
|
19308
19308
|
}
|
|
19309
19309
|
),
|
|
19310
|
-
/* @__PURE__ */
|
|
19310
|
+
/* @__PURE__ */ B("div", { className: "flex-shrink-0", children: /* @__PURE__ */ B(
|
|
19311
19311
|
CT,
|
|
19312
19312
|
{
|
|
19313
19313
|
classNameTextarea: "",
|
|
@@ -19500,9 +19500,9 @@ function MT() {
|
|
|
19500
19500
|
return da = function(o, l) {
|
|
19501
19501
|
var c = typeof Symbol == "function" && Symbol.iterator, f = "@@iterator";
|
|
19502
19502
|
function d(p) {
|
|
19503
|
-
var
|
|
19504
|
-
if (typeof
|
|
19505
|
-
return
|
|
19503
|
+
var F = p && (c && p[c] || p[f]);
|
|
19504
|
+
if (typeof F == "function")
|
|
19505
|
+
return F;
|
|
19506
19506
|
}
|
|
19507
19507
|
var m = "<<anonymous>>", h = {
|
|
19508
19508
|
array: S("array"),
|
|
@@ -19525,16 +19525,16 @@ function MT() {
|
|
|
19525
19525
|
shape: w,
|
|
19526
19526
|
exact: G
|
|
19527
19527
|
};
|
|
19528
|
-
function y(p,
|
|
19529
|
-
return p ===
|
|
19528
|
+
function y(p, F) {
|
|
19529
|
+
return p === F ? p !== 0 || 1 / p === 1 / F : p !== p && F !== F;
|
|
19530
19530
|
}
|
|
19531
|
-
function A(p,
|
|
19532
|
-
this.message = p, this.data =
|
|
19531
|
+
function A(p, F) {
|
|
19532
|
+
this.message = p, this.data = F && typeof F == "object" ? F : {}, this.stack = "";
|
|
19533
19533
|
}
|
|
19534
19534
|
A.prototype = Error.prototype;
|
|
19535
19535
|
function L(p) {
|
|
19536
19536
|
if (process.env.NODE_ENV !== "production")
|
|
19537
|
-
var
|
|
19537
|
+
var F = {}, X = 0;
|
|
19538
19538
|
function T(K, z, Q, ee, ae, Z, _e) {
|
|
19539
19539
|
if (ee = ee || m, Z = Z || Q, _e !== n) {
|
|
19540
19540
|
if (l) {
|
|
@@ -19544,10 +19544,10 @@ function MT() {
|
|
|
19544
19544
|
throw U.name = "Invariant Violation", U;
|
|
19545
19545
|
} else if (process.env.NODE_ENV !== "production" && typeof console < "u") {
|
|
19546
19546
|
var Ce = ee + ":" + Q;
|
|
19547
|
-
!
|
|
19547
|
+
!F[Ce] && // Avoid spamming the console because they are often not actionable except for lib authors
|
|
19548
19548
|
X < 3 && (i(
|
|
19549
19549
|
"You are manually calling a React.PropTypes validation function for the `" + Z + "` prop on `" + ee + "`. This is deprecated and will throw in the standalone `prop-types` package. You may be seeing this warning due to a third-party PropTypes library. See https://fb.me/react-warning-dont-call-proptypes for details."
|
|
19550
|
-
),
|
|
19550
|
+
), F[Ce] = !0, X++);
|
|
19551
19551
|
}
|
|
19552
19552
|
}
|
|
19553
19553
|
return z[Q] == null ? K ? z[Q] === null ? new A("The " + ae + " `" + Z + "` is marked as required " + ("in `" + ee + "`, but its value is `null`.")) : new A("The " + ae + " `" + Z + "` is marked as required in " + ("`" + ee + "`, but its value is `undefined`.")) : null : p(z, Q, ee, ae, Z);
|
|
@@ -19556,7 +19556,7 @@ function MT() {
|
|
|
19556
19556
|
return V.isRequired = T.bind(null, !0), V;
|
|
19557
19557
|
}
|
|
19558
19558
|
function S(p) {
|
|
19559
|
-
function
|
|
19559
|
+
function F(X, T, V, K, z, Q) {
|
|
19560
19560
|
var ee = X[T], ae = se(ee);
|
|
19561
19561
|
if (ae !== p) {
|
|
19562
19562
|
var Z = me(ee);
|
|
@@ -19567,13 +19567,13 @@ function MT() {
|
|
|
19567
19567
|
}
|
|
19568
19568
|
return null;
|
|
19569
19569
|
}
|
|
19570
|
-
return L(
|
|
19570
|
+
return L(F);
|
|
19571
19571
|
}
|
|
19572
19572
|
function R() {
|
|
19573
19573
|
return L(u);
|
|
19574
19574
|
}
|
|
19575
19575
|
function N(p) {
|
|
19576
|
-
function
|
|
19576
|
+
function F(X, T, V, K, z) {
|
|
19577
19577
|
if (typeof p != "function")
|
|
19578
19578
|
return new A("Property `" + z + "` of component `" + V + "` has invalid PropType notation inside arrayOf.");
|
|
19579
19579
|
var Q = X[T];
|
|
@@ -19588,11 +19588,11 @@ function MT() {
|
|
|
19588
19588
|
}
|
|
19589
19589
|
return null;
|
|
19590
19590
|
}
|
|
19591
|
-
return L(
|
|
19591
|
+
return L(F);
|
|
19592
19592
|
}
|
|
19593
19593
|
function D() {
|
|
19594
|
-
function p(
|
|
19595
|
-
var z =
|
|
19594
|
+
function p(F, X, T, V, K) {
|
|
19595
|
+
var z = F[X];
|
|
19596
19596
|
if (!o(z)) {
|
|
19597
19597
|
var Q = se(z);
|
|
19598
19598
|
return new A("Invalid " + V + " `" + K + "` of type " + ("`" + Q + "` supplied to `" + T + "`, expected a single ReactElement."));
|
|
@@ -19602,8 +19602,8 @@ function MT() {
|
|
|
19602
19602
|
return L(p);
|
|
19603
19603
|
}
|
|
19604
19604
|
function x() {
|
|
19605
|
-
function p(
|
|
19606
|
-
var z =
|
|
19605
|
+
function p(F, X, T, V, K) {
|
|
19606
|
+
var z = F[X];
|
|
19607
19607
|
if (!e.isValidElementType(z)) {
|
|
19608
19608
|
var Q = se(z);
|
|
19609
19609
|
return new A("Invalid " + V + " `" + K + "` of type " + ("`" + Q + "` supplied to `" + T + "`, expected a single ReactElement type."));
|
|
@@ -19613,21 +19613,21 @@ function MT() {
|
|
|
19613
19613
|
return L(p);
|
|
19614
19614
|
}
|
|
19615
19615
|
function I(p) {
|
|
19616
|
-
function
|
|
19616
|
+
function F(X, T, V, K, z) {
|
|
19617
19617
|
if (!(X[T] instanceof p)) {
|
|
19618
19618
|
var Q = p.name || m, ee = Le(X[T]);
|
|
19619
19619
|
return new A("Invalid " + K + " `" + z + "` of type " + ("`" + ee + "` supplied to `" + V + "`, expected ") + ("instance of `" + Q + "`."));
|
|
19620
19620
|
}
|
|
19621
19621
|
return null;
|
|
19622
19622
|
}
|
|
19623
|
-
return L(
|
|
19623
|
+
return L(F);
|
|
19624
19624
|
}
|
|
19625
19625
|
function q(p) {
|
|
19626
19626
|
if (!Array.isArray(p))
|
|
19627
19627
|
return process.env.NODE_ENV !== "production" && (arguments.length > 1 ? i(
|
|
19628
19628
|
"Invalid arguments supplied to oneOf, expected an array, got " + arguments.length + " arguments. A common mistake is to write oneOf(x, y, z) instead of oneOf([x, y, z])."
|
|
19629
19629
|
) : i("Invalid argument supplied to oneOf, expected an array.")), u;
|
|
19630
|
-
function
|
|
19630
|
+
function F(X, T, V, K, z) {
|
|
19631
19631
|
for (var Q = X[T], ee = 0; ee < p.length; ee++)
|
|
19632
19632
|
if (y(Q, p[ee]))
|
|
19633
19633
|
return null;
|
|
@@ -19637,10 +19637,10 @@ function MT() {
|
|
|
19637
19637
|
});
|
|
19638
19638
|
return new A("Invalid " + K + " `" + z + "` of value `" + String(Q) + "` " + ("supplied to `" + V + "`, expected one of " + ae + "."));
|
|
19639
19639
|
}
|
|
19640
|
-
return L(
|
|
19640
|
+
return L(F);
|
|
19641
19641
|
}
|
|
19642
19642
|
function ue(p) {
|
|
19643
|
-
function
|
|
19643
|
+
function F(X, T, V, K, z) {
|
|
19644
19644
|
if (typeof p != "function")
|
|
19645
19645
|
return new A("Property `" + z + "` of component `" + V + "` has invalid PropType notation inside objectOf.");
|
|
19646
19646
|
var Q = X[T], ee = se(Q);
|
|
@@ -19654,16 +19654,16 @@ function MT() {
|
|
|
19654
19654
|
}
|
|
19655
19655
|
return null;
|
|
19656
19656
|
}
|
|
19657
|
-
return L(
|
|
19657
|
+
return L(F);
|
|
19658
19658
|
}
|
|
19659
19659
|
function te(p) {
|
|
19660
19660
|
if (!Array.isArray(p))
|
|
19661
19661
|
return process.env.NODE_ENV !== "production" && i("Invalid argument supplied to oneOfType, expected an instance of array."), u;
|
|
19662
|
-
for (var
|
|
19663
|
-
var X = p[
|
|
19662
|
+
for (var F = 0; F < p.length; F++) {
|
|
19663
|
+
var X = p[F];
|
|
19664
19664
|
if (typeof X != "function")
|
|
19665
19665
|
return i(
|
|
19666
|
-
"Invalid argument supplied to oneOfType. Expected an array of check functions, but received " + ve(X) + " at index " +
|
|
19666
|
+
"Invalid argument supplied to oneOfType. Expected an array of check functions, but received " + ve(X) + " at index " + F + "."
|
|
19667
19667
|
), u;
|
|
19668
19668
|
}
|
|
19669
19669
|
function T(V, K, z, Q, ee) {
|
|
@@ -19679,18 +19679,18 @@ function MT() {
|
|
|
19679
19679
|
return L(T);
|
|
19680
19680
|
}
|
|
19681
19681
|
function Y() {
|
|
19682
|
-
function p(
|
|
19683
|
-
return $(
|
|
19682
|
+
function p(F, X, T, V, K) {
|
|
19683
|
+
return $(F[X]) ? null : new A("Invalid " + V + " `" + K + "` supplied to " + ("`" + T + "`, expected a ReactNode."));
|
|
19684
19684
|
}
|
|
19685
19685
|
return L(p);
|
|
19686
19686
|
}
|
|
19687
|
-
function M(p,
|
|
19687
|
+
function M(p, F, X, T, V) {
|
|
19688
19688
|
return new A(
|
|
19689
|
-
(p || "React class") + ": " +
|
|
19689
|
+
(p || "React class") + ": " + F + " type `" + X + "." + T + "` is invalid; it must be a function, usually from the `prop-types` package, but received `" + V + "`."
|
|
19690
19690
|
);
|
|
19691
19691
|
}
|
|
19692
19692
|
function w(p) {
|
|
19693
|
-
function
|
|
19693
|
+
function F(X, T, V, K, z) {
|
|
19694
19694
|
var Q = X[T], ee = se(Q);
|
|
19695
19695
|
if (ee !== "object")
|
|
19696
19696
|
return new A("Invalid " + K + " `" + z + "` of type `" + ee + "` " + ("supplied to `" + V + "`, expected `object`."));
|
|
@@ -19704,10 +19704,10 @@ function MT() {
|
|
|
19704
19704
|
}
|
|
19705
19705
|
return null;
|
|
19706
19706
|
}
|
|
19707
|
-
return L(
|
|
19707
|
+
return L(F);
|
|
19708
19708
|
}
|
|
19709
19709
|
function G(p) {
|
|
19710
|
-
function
|
|
19710
|
+
function F(X, T, V, K, z) {
|
|
19711
19711
|
var Q = X[T], ee = se(Q);
|
|
19712
19712
|
if (ee !== "object")
|
|
19713
19713
|
return new A("Invalid " + K + " `" + z + "` of type `" + ee + "` " + ("supplied to `" + V + "`, expected `object`."));
|
|
@@ -19727,7 +19727,7 @@ Valid keys: ` + JSON.stringify(Object.keys(p), null, " ")
|
|
|
19727
19727
|
}
|
|
19728
19728
|
return null;
|
|
19729
19729
|
}
|
|
19730
|
-
return L(
|
|
19730
|
+
return L(F);
|
|
19731
19731
|
}
|
|
19732
19732
|
function $(p) {
|
|
19733
19733
|
switch (typeof p) {
|
|
@@ -19742,10 +19742,10 @@ Valid keys: ` + JSON.stringify(Object.keys(p), null, " ")
|
|
|
19742
19742
|
return p.every($);
|
|
19743
19743
|
if (p === null || o(p))
|
|
19744
19744
|
return !0;
|
|
19745
|
-
var
|
|
19746
|
-
if (
|
|
19747
|
-
var X =
|
|
19748
|
-
if (
|
|
19745
|
+
var F = d(p);
|
|
19746
|
+
if (F) {
|
|
19747
|
+
var X = F.call(p), T;
|
|
19748
|
+
if (F !== p.entries) {
|
|
19749
19749
|
for (; !(T = X.next()).done; )
|
|
19750
19750
|
if (!$(T.value))
|
|
19751
19751
|
return !1;
|
|
@@ -19762,37 +19762,37 @@ Valid keys: ` + JSON.stringify(Object.keys(p), null, " ")
|
|
|
19762
19762
|
return !1;
|
|
19763
19763
|
}
|
|
19764
19764
|
}
|
|
19765
|
-
function W(p,
|
|
19766
|
-
return p === "symbol" ? !0 :
|
|
19765
|
+
function W(p, F) {
|
|
19766
|
+
return p === "symbol" ? !0 : F ? F["@@toStringTag"] === "Symbol" || typeof Symbol == "function" && F instanceof Symbol : !1;
|
|
19767
19767
|
}
|
|
19768
19768
|
function se(p) {
|
|
19769
|
-
var
|
|
19770
|
-
return Array.isArray(p) ? "array" : p instanceof RegExp ? "object" : W(
|
|
19769
|
+
var F = typeof p;
|
|
19770
|
+
return Array.isArray(p) ? "array" : p instanceof RegExp ? "object" : W(F, p) ? "symbol" : F;
|
|
19771
19771
|
}
|
|
19772
19772
|
function me(p) {
|
|
19773
19773
|
if (typeof p > "u" || p === null)
|
|
19774
19774
|
return "" + p;
|
|
19775
|
-
var
|
|
19776
|
-
if (
|
|
19775
|
+
var F = se(p);
|
|
19776
|
+
if (F === "object") {
|
|
19777
19777
|
if (p instanceof Date)
|
|
19778
19778
|
return "date";
|
|
19779
19779
|
if (p instanceof RegExp)
|
|
19780
19780
|
return "regexp";
|
|
19781
19781
|
}
|
|
19782
|
-
return
|
|
19782
|
+
return F;
|
|
19783
19783
|
}
|
|
19784
19784
|
function ve(p) {
|
|
19785
|
-
var
|
|
19786
|
-
switch (
|
|
19785
|
+
var F = me(p);
|
|
19786
|
+
switch (F) {
|
|
19787
19787
|
case "array":
|
|
19788
19788
|
case "object":
|
|
19789
|
-
return "an " +
|
|
19789
|
+
return "an " + F;
|
|
19790
19790
|
case "boolean":
|
|
19791
19791
|
case "date":
|
|
19792
19792
|
case "regexp":
|
|
19793
|
-
return "a " +
|
|
19793
|
+
return "a " + F;
|
|
19794
19794
|
default:
|
|
19795
|
-
return
|
|
19795
|
+
return F;
|
|
19796
19796
|
}
|
|
19797
19797
|
}
|
|
19798
19798
|
function Le(p) {
|
|
@@ -20435,20 +20435,20 @@ const VT = os(
|
|
|
20435
20435
|
bg-white
|
|
20436
20436
|
`,
|
|
20437
20437
|
children: [
|
|
20438
|
-
/* @__PURE__ */
|
|
20438
|
+
/* @__PURE__ */ B(
|
|
20439
20439
|
"div",
|
|
20440
20440
|
{
|
|
20441
20441
|
className: "bg-violet-700 py-2 text-white text-center flex justify-center items-center",
|
|
20442
20442
|
children: "Assistant"
|
|
20443
20443
|
}
|
|
20444
20444
|
),
|
|
20445
|
-
/* @__PURE__ */
|
|
20445
|
+
/* @__PURE__ */ B(Nl, { appToken: e.appToken })
|
|
20446
20446
|
]
|
|
20447
20447
|
}
|
|
20448
20448
|
)
|
|
20449
20449
|
), qT = ({ isWidgetOpen: e, appToken: t }) => {
|
|
20450
20450
|
const n = we(null);
|
|
20451
|
-
return /* @__PURE__ */
|
|
20451
|
+
return /* @__PURE__ */ B("div", { children: /* @__PURE__ */ B(
|
|
20452
20452
|
gi,
|
|
20453
20453
|
{
|
|
20454
20454
|
nodeRef: n,
|
|
@@ -20456,23 +20456,23 @@ const VT = os(
|
|
|
20456
20456
|
timeout: 200,
|
|
20457
20457
|
classNames: "menuTransition",
|
|
20458
20458
|
unmountOnExit: !0,
|
|
20459
|
-
children: /* @__PURE__ */
|
|
20459
|
+
children: /* @__PURE__ */ B(VT, { ref: n, props: { appToken: t } })
|
|
20460
20460
|
}
|
|
20461
20461
|
) });
|
|
20462
20462
|
}, WT = ({ displayMode: e, appToken: t }) => {
|
|
20463
20463
|
const [n, r] = ge(!1), { appInternalContext: a } = lt(Us);
|
|
20464
20464
|
return /* @__PURE__ */ De(rn, { children: [
|
|
20465
20465
|
e === ln.LAUNCHER && a.hasFetchedSettings && /* @__PURE__ */ De(rn, { children: [
|
|
20466
|
-
/* @__PURE__ */
|
|
20466
|
+
/* @__PURE__ */ B(
|
|
20467
20467
|
Gf,
|
|
20468
20468
|
{
|
|
20469
20469
|
isWidgetOpen: n,
|
|
20470
20470
|
setIsWidgetOpen: r
|
|
20471
20471
|
}
|
|
20472
20472
|
),
|
|
20473
|
-
/* @__PURE__ */
|
|
20473
|
+
/* @__PURE__ */ B(qT, { isWidgetOpen: n, appToken: t })
|
|
20474
20474
|
] }),
|
|
20475
|
-
e === ln.CHATBOX && a.hasFetchedSettings && /* @__PURE__ */
|
|
20475
|
+
e === ln.CHATBOX && a.hasFetchedSettings && /* @__PURE__ */ B("div", { className: "chatBox", children: /* @__PURE__ */ B(Nl, { appToken: t }) })
|
|
20476
20476
|
] });
|
|
20477
20477
|
};
|
|
20478
20478
|
var ln = /* @__PURE__ */ ((e) => (e.LAUNCHER = "launcher", e.CHATBOX = "chatbox", e))(ln || {});
|
|
@@ -20485,7 +20485,7 @@ function eg({
|
|
|
20485
20485
|
"appToken not defined in ai-client. Please see the documentation at URL_ERROR_IN_DOC"
|
|
20486
20486
|
);
|
|
20487
20487
|
const r = kf(t);
|
|
20488
|
-
return /* @__PURE__ */
|
|
20488
|
+
return /* @__PURE__ */ B("div", { className: "chatSystemWidget", children: /* @__PURE__ */ B(Pf, { appToken: e, agentId: n, children: /* @__PURE__ */ B(WT, { displayMode: r, appToken: e }) }) });
|
|
20489
20489
|
}
|
|
20490
20490
|
export {
|
|
20491
20491
|
eg as App
|