@forbespro/lead-agent
Version:
Lead Chat Agent React Component
73 lines (72 loc) • 2.06 kB
JavaScript
import { f as m, m as d, S as E, d as p, a as R, i as S, s as C, b as D, c as h, e as w } from "./index38.js";
import { I as q, r as z, O as B, U as P, k as j, z as G, q as H, o as M, y as J, h as X, n as Y, w as K, x as Q, B as Z, j as $, A as ee, p as te, t as se, v as ne, l as oe, u as ae } from "./index38.js";
import { INFINITE_PREFIX as I } from "./index48.js";
import O, { useContext as A } from "react";
const l = S && window.__SWR_DEVTOOLS_USE__, L = l ? window.__SWR_DEVTOOLS_USE__ : [], T = () => {
l && (window.__SWR_DEVTOOLS_REACT__ = O);
}, W = (e) => R(e[1]) ? [
e[0],
e[1],
e[2] || {}
] : [
e[0],
null,
(e[1] === null ? e[2] : e[1]) || {}
], g = () => d(p, A(E)), x = (e) => (n, s, t) => e(n, s && ((...c) => {
const [r] = C(n), [, , , o] = D.get(h);
if (r.startsWith(I))
return s(...c);
const a = o[r];
return w(a) ? s(...c) : (delete o[r], a);
}), t), b = L.concat(x), v = (e) => function(...s) {
const t = g(), [i, c, r] = W(s), o = m(t, r);
let a = e;
const { use: _ } = o, u = (_ || []).concat(b);
for (let f = u.length; f--; )
a = u[f](a);
return a(i, c || o.fetcher || null, o);
}, y = (e, n, s) => {
const t = n[e] || (n[e] = []);
return t.push(s), () => {
const i = t.indexOf(s);
i >= 0 && (t[i] = t[t.length - 1], t.pop());
};
};
T();
export {
I as INFINITE_PREFIX,
q as IS_REACT_LEGACY,
z as IS_SERVER,
B as OBJECT,
D as SWRGlobalState,
P as UNDEFINED,
h as cache,
j as compare,
G as createCacheHelper,
p as defaultConfig,
H as defaultConfigOptions,
M as getTimestamp,
J as hasRequestAnimationFrame,
X as initCache,
Y as internalMutate,
K as isDocumentDefined,
R as isFunction,
Q as isLegacyDeno,
Z as isPromiseLike,
w as isUndefined,
S as isWindowDefined,
m as mergeConfigs,
d as mergeObjects,
$ as mutate,
ee as noop,
W as normalize,
te as preset,
se as rAF,
C as serialize,
ne as slowConnection,
oe as stableHash,
y as subscribeCallback,
ae as useIsomorphicLayoutEffect,
g as useSWRConfig,
v as withArgs
};