@eloquentai/chat-sdk 0.26.0-dev → 0.26.1-dev
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-DfHp-nmR.js → index-C0lXr3_t.js} +2 -2
- package/dist/{index-DfHp-nmR.js.map → index-C0lXr3_t.js.map} +1 -1
- package/dist/{index-Bh7o228L.js → index-Dqos2v0b.js} +777 -774
- package/dist/{index-Bh7o228L.js.map → index-Dqos2v0b.js.map} +1 -1
- package/dist/index.mjs +1 -1
- package/dist/lib/eloquent-ai-api-client.d.ts +1 -0
- package/package.json +1 -1
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { jsx as
|
|
1
|
+
import { jsx as y, jsxs as B, Fragment as We } from "react/jsx-runtime";
|
|
2
2
|
import { ChevronDown as jo, X as gr, Copy as al, ThumbsUp as sl, ThumbsDown as ll, FileSearch as cl, CheckCircle as ul, Info as fl, XCircle as dl, AlertTriangle as pl, Hourglass as hl, ArrowUp as ml, RefreshCcw as gl } from "lucide-react";
|
|
3
3
|
import { clsx as bl } from "clsx";
|
|
4
4
|
import { twMerge as yl } from "tailwind-merge";
|
|
@@ -15,16 +15,16 @@ import { z as Q } from "zod";
|
|
|
15
15
|
import Cl from "react-dom/client";
|
|
16
16
|
try {
|
|
17
17
|
let e = typeof window < "u" ? window : typeof global < "u" ? global : typeof globalThis < "u" ? globalThis : typeof self < "u" ? self : {}, t = new e.Error().stack;
|
|
18
|
-
t && (e._sentryDebugIds = e._sentryDebugIds || {}, e._sentryDebugIds[t] = "
|
|
18
|
+
t && (e._sentryDebugIds = e._sentryDebugIds || {}, e._sentryDebugIds[t] = "115c8c74-b43b-41cd-979f-d361dfcc248e", e._sentryDebugIdIdentifier = "sentry-dbid-115c8c74-b43b-41cd-979f-d361dfcc248e");
|
|
19
19
|
} catch {
|
|
20
20
|
}
|
|
21
21
|
{
|
|
22
22
|
let e = typeof window < "u" ? window : typeof global < "u" ? global : typeof globalThis < "u" ? globalThis : typeof self < "u" ? self : {};
|
|
23
|
-
e.SENTRY_RELEASE = { id: "
|
|
23
|
+
e.SENTRY_RELEASE = { id: "75c5948fee4525f723d37592f66a83645d90df69" };
|
|
24
24
|
}
|
|
25
25
|
if (typeof window < "u") {
|
|
26
26
|
const e = "development";
|
|
27
|
-
import("./index-
|
|
27
|
+
import("./index-C0lXr3_t.js").then((t) => {
|
|
28
28
|
t.init({
|
|
29
29
|
dsn: void 0,
|
|
30
30
|
environment: e,
|
|
@@ -55,7 +55,7 @@ function hn(e) {
|
|
|
55
55
|
s(!1);
|
|
56
56
|
}, [i]);
|
|
57
57
|
const l = !i || a;
|
|
58
|
-
return /* @__PURE__ */
|
|
58
|
+
return /* @__PURE__ */ y(
|
|
59
59
|
"div",
|
|
60
60
|
{
|
|
61
61
|
className: j(
|
|
@@ -64,8 +64,8 @@ function hn(e) {
|
|
|
64
64
|
),
|
|
65
65
|
...o,
|
|
66
66
|
children: l ? /* @__PURE__ */ B("svg", { viewBox: "0 0 80 80", fill: "none", xmlns: "http://www.w3.org/2000/svg", children: [
|
|
67
|
-
/* @__PURE__ */
|
|
68
|
-
/* @__PURE__ */
|
|
67
|
+
/* @__PURE__ */ y("circle", { cx: "40", cy: "40", r: "40", fill: n || "#6F33B7" }),
|
|
68
|
+
/* @__PURE__ */ y(
|
|
69
69
|
"path",
|
|
70
70
|
{
|
|
71
71
|
fillRule: "evenodd",
|
|
@@ -74,7 +74,7 @@ function hn(e) {
|
|
|
74
74
|
fill: r || "#000000"
|
|
75
75
|
}
|
|
76
76
|
)
|
|
77
|
-
] }) : /* @__PURE__ */
|
|
77
|
+
] }) : /* @__PURE__ */ y(
|
|
78
78
|
"img",
|
|
79
79
|
{
|
|
80
80
|
src: i,
|
|
@@ -90,37 +90,37 @@ function Al({
|
|
|
90
90
|
isOpen: e,
|
|
91
91
|
toggleBubble: t
|
|
92
92
|
}) {
|
|
93
|
-
return /* @__PURE__ */
|
|
93
|
+
return /* @__PURE__ */ y("div", { className: "absolute inset-0 m-auto flex items-center justify-center overflow-hidden", children: /* @__PURE__ */ B(
|
|
94
94
|
"div",
|
|
95
95
|
{
|
|
96
96
|
className: "chat-bubble relative flex items-center justify-center w-12 h-12 rounded-full bg-[#000] text-[#fff] cursor-pointer",
|
|
97
97
|
onClick: t,
|
|
98
98
|
children: [
|
|
99
|
-
/* @__PURE__ */
|
|
99
|
+
/* @__PURE__ */ y(
|
|
100
100
|
"div",
|
|
101
101
|
{
|
|
102
102
|
className: j(
|
|
103
103
|
"absolute inset-0 flex justify-center items-center m-auto transition duration-200 ease-linear",
|
|
104
104
|
e ? "rotate-180 opacity-0 scale-0" : "rotate-0 opacity-100 scale-100"
|
|
105
105
|
),
|
|
106
|
-
children: /* @__PURE__ */
|
|
106
|
+
children: /* @__PURE__ */ y(hn, { bgColor: "#000", fgColor: "#ffffff" })
|
|
107
107
|
}
|
|
108
108
|
),
|
|
109
|
-
/* @__PURE__ */
|
|
109
|
+
/* @__PURE__ */ y(
|
|
110
110
|
"div",
|
|
111
111
|
{
|
|
112
112
|
className: j(
|
|
113
113
|
"absolute inset-0 flex justify-center items-center m-auto transition duration-200 ease-linear",
|
|
114
114
|
e ? "rotate-0 opacity-100 scale-100" : "-rotate-180 opacity-0 scale-0"
|
|
115
115
|
),
|
|
116
|
-
children: /* @__PURE__ */
|
|
116
|
+
children: /* @__PURE__ */ y(jo, {})
|
|
117
117
|
}
|
|
118
118
|
)
|
|
119
119
|
]
|
|
120
120
|
}
|
|
121
121
|
) });
|
|
122
122
|
}
|
|
123
|
-
const yr = pe.forwardRef(({ className: e, ...t }, n) => /* @__PURE__ */
|
|
123
|
+
const yr = pe.forwardRef(({ className: e, ...t }, n) => /* @__PURE__ */ y(
|
|
124
124
|
"div",
|
|
125
125
|
{
|
|
126
126
|
ref: n,
|
|
@@ -132,7 +132,7 @@ const yr = pe.forwardRef(({ className: e, ...t }, n) => /* @__PURE__ */ w(
|
|
|
132
132
|
}
|
|
133
133
|
));
|
|
134
134
|
yr.displayName = "Card";
|
|
135
|
-
const wr = pe.forwardRef(({ className: e, ...t }, n) => /* @__PURE__ */
|
|
135
|
+
const wr = pe.forwardRef(({ className: e, ...t }, n) => /* @__PURE__ */ y(
|
|
136
136
|
"div",
|
|
137
137
|
{
|
|
138
138
|
ref: n,
|
|
@@ -141,7 +141,7 @@ const wr = pe.forwardRef(({ className: e, ...t }, n) => /* @__PURE__ */ w(
|
|
|
141
141
|
}
|
|
142
142
|
));
|
|
143
143
|
wr.displayName = "CardHeader";
|
|
144
|
-
const Il = pe.forwardRef(({ className: e, ...t }, n) => /* @__PURE__ */
|
|
144
|
+
const Il = pe.forwardRef(({ className: e, ...t }, n) => /* @__PURE__ */ y(
|
|
145
145
|
"div",
|
|
146
146
|
{
|
|
147
147
|
ref: n,
|
|
@@ -153,7 +153,7 @@ const Il = pe.forwardRef(({ className: e, ...t }, n) => /* @__PURE__ */ w(
|
|
|
153
153
|
}
|
|
154
154
|
));
|
|
155
155
|
Il.displayName = "CardTitle";
|
|
156
|
-
const Tl = pe.forwardRef(({ className: e, ...t }, n) => /* @__PURE__ */
|
|
156
|
+
const Tl = pe.forwardRef(({ className: e, ...t }, n) => /* @__PURE__ */ y(
|
|
157
157
|
"div",
|
|
158
158
|
{
|
|
159
159
|
ref: n,
|
|
@@ -162,9 +162,9 @@ const Tl = pe.forwardRef(({ className: e, ...t }, n) => /* @__PURE__ */ w(
|
|
|
162
162
|
}
|
|
163
163
|
));
|
|
164
164
|
Tl.displayName = "CardDescription";
|
|
165
|
-
const xr = pe.forwardRef(({ className: e, ...t }, n) => /* @__PURE__ */
|
|
165
|
+
const xr = pe.forwardRef(({ className: e, ...t }, n) => /* @__PURE__ */ y("div", { ref: n, className: j("p-6 pt-0", e), ...t }));
|
|
166
166
|
xr.displayName = "CardContent";
|
|
167
|
-
const vr = pe.forwardRef(({ className: e, ...t }, n) => /* @__PURE__ */
|
|
167
|
+
const vr = pe.forwardRef(({ className: e, ...t }, n) => /* @__PURE__ */ y(
|
|
168
168
|
"div",
|
|
169
169
|
{
|
|
170
170
|
ref: n,
|
|
@@ -175,7 +175,7 @@ const vr = pe.forwardRef(({ className: e, ...t }, n) => /* @__PURE__ */ w(
|
|
|
175
175
|
vr.displayName = "CardFooter";
|
|
176
176
|
const Ho = dn(void 0);
|
|
177
177
|
function Vo(e) {
|
|
178
|
-
return /* @__PURE__ */
|
|
178
|
+
return /* @__PURE__ */ y(
|
|
179
179
|
Ho.Provider,
|
|
180
180
|
{
|
|
181
181
|
value: {
|
|
@@ -200,7 +200,7 @@ const kr = () => {
|
|
|
200
200
|
className: j("relative overflow-hidden", e),
|
|
201
201
|
...r,
|
|
202
202
|
children: [
|
|
203
|
-
/* @__PURE__ */
|
|
203
|
+
/* @__PURE__ */ y(
|
|
204
204
|
Ze.Viewport,
|
|
205
205
|
{
|
|
206
206
|
className: "h-full w-full rounded-[inherit]",
|
|
@@ -208,13 +208,13 @@ const kr = () => {
|
|
|
208
208
|
children: t
|
|
209
209
|
}
|
|
210
210
|
),
|
|
211
|
-
/* @__PURE__ */
|
|
212
|
-
/* @__PURE__ */
|
|
211
|
+
/* @__PURE__ */ y(Wo, {}),
|
|
212
|
+
/* @__PURE__ */ y(Ze.Corner, {})
|
|
213
213
|
]
|
|
214
214
|
}
|
|
215
215
|
));
|
|
216
216
|
$o.displayName = Ze.Root.displayName;
|
|
217
|
-
const Wo = pe.forwardRef(({ className: e, orientation: t = "vertical", ...n }, r) => /* @__PURE__ */
|
|
217
|
+
const Wo = pe.forwardRef(({ className: e, orientation: t = "vertical", ...n }, r) => /* @__PURE__ */ y(
|
|
218
218
|
Ze.ScrollAreaScrollbar,
|
|
219
219
|
{
|
|
220
220
|
ref: r,
|
|
@@ -226,11 +226,11 @@ const Wo = pe.forwardRef(({ className: e, orientation: t = "vertical", ...n }, r
|
|
|
226
226
|
e
|
|
227
227
|
),
|
|
228
228
|
...n,
|
|
229
|
-
children: /* @__PURE__ */
|
|
229
|
+
children: /* @__PURE__ */ y(Ze.ScrollAreaThumb, { className: "relative flex-1 rounded-full bg-border" })
|
|
230
230
|
}
|
|
231
231
|
));
|
|
232
232
|
Wo.displayName = Ze.ScrollAreaScrollbar.displayName;
|
|
233
|
-
const Nl = Pe.Root, Rl = Pe.Portal, Go = pe.forwardRef(({ className: e, ...t }, n) => /* @__PURE__ */
|
|
233
|
+
const Nl = Pe.Root, Rl = Pe.Portal, Go = pe.forwardRef(({ className: e, ...t }, n) => /* @__PURE__ */ y(
|
|
234
234
|
Pe.Overlay,
|
|
235
235
|
{
|
|
236
236
|
ref: n,
|
|
@@ -243,7 +243,7 @@ const Nl = Pe.Root, Rl = Pe.Portal, Go = pe.forwardRef(({ className: e, ...t },
|
|
|
243
243
|
));
|
|
244
244
|
Go.displayName = Pe.Overlay.displayName;
|
|
245
245
|
const Ko = pe.forwardRef(({ className: e, children: t, ...n }, r) => /* @__PURE__ */ B(Rl, { children: [
|
|
246
|
-
/* @__PURE__ */
|
|
246
|
+
/* @__PURE__ */ y(Go, {}),
|
|
247
247
|
/* @__PURE__ */ B(
|
|
248
248
|
Pe.Content,
|
|
249
249
|
{
|
|
@@ -256,15 +256,15 @@ const Ko = pe.forwardRef(({ className: e, children: t, ...n }, r) => /* @__PURE_
|
|
|
256
256
|
children: [
|
|
257
257
|
t,
|
|
258
258
|
/* @__PURE__ */ B(Pe.Close, { className: "absolute right-4 top-4 rounded-sm opacity-70 ring-offset-background transition-opacity hover:opacity-100 focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2 disabled:pointer-events-none data-[state=open]:bg-accent data-[state=open]:text-muted-foreground bg-white/90", children: [
|
|
259
|
-
/* @__PURE__ */
|
|
260
|
-
/* @__PURE__ */
|
|
259
|
+
/* @__PURE__ */ y(gr, { className: "h-4 w-4" }),
|
|
260
|
+
/* @__PURE__ */ y("span", { className: "sr-only", children: "Close" })
|
|
261
261
|
] })
|
|
262
262
|
]
|
|
263
263
|
}
|
|
264
264
|
)
|
|
265
265
|
] }));
|
|
266
266
|
Ko.displayName = Pe.Content.displayName;
|
|
267
|
-
const Yo = pe.forwardRef(({ className: e, ...t }, n) => /* @__PURE__ */
|
|
267
|
+
const Yo = pe.forwardRef(({ className: e, ...t }, n) => /* @__PURE__ */ y(
|
|
268
268
|
Pe.Title,
|
|
269
269
|
{
|
|
270
270
|
ref: n,
|
|
@@ -276,7 +276,7 @@ const Yo = pe.forwardRef(({ className: e, ...t }, n) => /* @__PURE__ */ w(
|
|
|
276
276
|
}
|
|
277
277
|
));
|
|
278
278
|
Yo.displayName = Pe.Title.displayName;
|
|
279
|
-
const Jo = pe.forwardRef(({ className: e, ...t }, n) => /* @__PURE__ */
|
|
279
|
+
const Jo = pe.forwardRef(({ className: e, ...t }, n) => /* @__PURE__ */ y(
|
|
280
280
|
Pe.Description,
|
|
281
281
|
{
|
|
282
282
|
ref: n,
|
|
@@ -290,7 +290,7 @@ function Ol({
|
|
|
290
290
|
children: e,
|
|
291
291
|
...t
|
|
292
292
|
}) {
|
|
293
|
-
return /* @__PURE__ */
|
|
293
|
+
return /* @__PURE__ */ y(Qo.Provider, { value: t, children: e });
|
|
294
294
|
}
|
|
295
295
|
function mn() {
|
|
296
296
|
const e = pn(Qo);
|
|
@@ -341,7 +341,7 @@ function Xo({ isWaiting: e = !1, ...t }) {
|
|
|
341
341
|
}
|
|
342
342
|
}, [a, s, e]), re(() => {
|
|
343
343
|
a && r?.();
|
|
344
|
-
}, [a]), /* @__PURE__ */
|
|
344
|
+
}, [a]), /* @__PURE__ */ y(
|
|
345
345
|
"div",
|
|
346
346
|
{
|
|
347
347
|
className: j(
|
|
@@ -349,7 +349,7 @@ function Xo({ isWaiting: e = !1, ...t }) {
|
|
|
349
349
|
n
|
|
350
350
|
),
|
|
351
351
|
...i,
|
|
352
|
-
children: /* @__PURE__ */
|
|
352
|
+
children: /* @__PURE__ */ y(o, {})
|
|
353
353
|
}
|
|
354
354
|
);
|
|
355
355
|
}
|
|
@@ -1561,59 +1561,59 @@ function ac() {
|
|
|
1561
1561
|
di = 1;
|
|
1562
1562
|
var e = /\/\*[^*]*\*+([^/*][^*]*\*+)*\//g, t = /\n/g, n = /^\s*/, r = /^(\*?[-#/*\\\w]+(\[[0-9a-z_-]+\])?)\s*/, i = /^:\s*/, o = /^((?:'(?:\\'|.)*?'|"(?:\\"|.)*?"|\([^)]*?\)|[^};])+)/, a = /^[;\s]*/, s = /^\s+|\s+$/g, l = `
|
|
1563
1563
|
`, c = "/", u = "*", f = "", p = "comment", d = "declaration";
|
|
1564
|
-
function h(v,
|
|
1564
|
+
function h(v, w) {
|
|
1565
1565
|
if (typeof v != "string")
|
|
1566
1566
|
throw new TypeError("First argument must be a string");
|
|
1567
1567
|
if (!v) return [];
|
|
1568
|
-
|
|
1569
|
-
var _ = 1,
|
|
1570
|
-
function
|
|
1568
|
+
w = w || {};
|
|
1569
|
+
var _ = 1, S = 1;
|
|
1570
|
+
function O(R) {
|
|
1571
1571
|
var A = R.match(t);
|
|
1572
1572
|
A && (_ += A.length);
|
|
1573
1573
|
var U = R.lastIndexOf(l);
|
|
1574
|
-
|
|
1574
|
+
S = ~U ? R.length - U : S + R.length;
|
|
1575
1575
|
}
|
|
1576
1576
|
function N() {
|
|
1577
|
-
var R = { line: _, column:
|
|
1577
|
+
var R = { line: _, column: S };
|
|
1578
1578
|
return function(A) {
|
|
1579
|
-
return A.position = new
|
|
1579
|
+
return A.position = new k(R), M(), A;
|
|
1580
1580
|
};
|
|
1581
1581
|
}
|
|
1582
|
-
function
|
|
1583
|
-
this.start = R, this.end = { line: _, column:
|
|
1582
|
+
function k(R) {
|
|
1583
|
+
this.start = R, this.end = { line: _, column: S }, this.source = w.source;
|
|
1584
1584
|
}
|
|
1585
|
-
|
|
1586
|
-
function
|
|
1585
|
+
k.prototype.content = v;
|
|
1586
|
+
function z(R) {
|
|
1587
1587
|
var A = new Error(
|
|
1588
|
-
|
|
1588
|
+
w.source + ":" + _ + ":" + S + ": " + R
|
|
1589
1589
|
);
|
|
1590
|
-
if (A.reason = R, A.filename =
|
|
1590
|
+
if (A.reason = R, A.filename = w.source, A.line = _, A.column = S, A.source = v, !w.silent) throw A;
|
|
1591
1591
|
}
|
|
1592
1592
|
function P(R) {
|
|
1593
1593
|
var A = R.exec(v);
|
|
1594
1594
|
if (A) {
|
|
1595
1595
|
var U = A[0];
|
|
1596
|
-
return
|
|
1596
|
+
return O(U), v = v.slice(U.length), A;
|
|
1597
1597
|
}
|
|
1598
1598
|
}
|
|
1599
|
-
function
|
|
1599
|
+
function M() {
|
|
1600
1600
|
P(n);
|
|
1601
1601
|
}
|
|
1602
1602
|
function x(R) {
|
|
1603
1603
|
var A;
|
|
1604
|
-
for (R = R || []; A =
|
|
1604
|
+
for (R = R || []; A = E(); )
|
|
1605
1605
|
A !== !1 && R.push(A);
|
|
1606
1606
|
return R;
|
|
1607
1607
|
}
|
|
1608
|
-
function
|
|
1608
|
+
function E() {
|
|
1609
1609
|
var R = N();
|
|
1610
1610
|
if (!(c != v.charAt(0) || u != v.charAt(1))) {
|
|
1611
1611
|
for (var A = 2; f != v.charAt(A) && (u != v.charAt(A) || c != v.charAt(A + 1)); )
|
|
1612
1612
|
++A;
|
|
1613
1613
|
if (A += 2, f === v.charAt(A - 1))
|
|
1614
|
-
return
|
|
1614
|
+
return z("End of comment missing");
|
|
1615
1615
|
var U = v.slice(2, A - 2);
|
|
1616
|
-
return
|
|
1616
|
+
return S += 2, O(U), v = v.slice(A), S += 2, R({
|
|
1617
1617
|
type: p,
|
|
1618
1618
|
comment: U
|
|
1619
1619
|
});
|
|
@@ -1622,7 +1622,7 @@ function ac() {
|
|
|
1622
1622
|
function I() {
|
|
1623
1623
|
var R = N(), A = P(r);
|
|
1624
1624
|
if (A) {
|
|
1625
|
-
if (
|
|
1625
|
+
if (E(), !P(i)) return z("property missing ':'");
|
|
1626
1626
|
var U = P(o), q = R({
|
|
1627
1627
|
type: d,
|
|
1628
1628
|
property: b(A[0].replace(e, f)),
|
|
@@ -1638,7 +1638,7 @@ function ac() {
|
|
|
1638
1638
|
A !== !1 && (R.push(A), x(R));
|
|
1639
1639
|
return R;
|
|
1640
1640
|
}
|
|
1641
|
-
return
|
|
1641
|
+
return M(), D();
|
|
1642
1642
|
}
|
|
1643
1643
|
function b(v) {
|
|
1644
1644
|
return v ? v.replace(s, f) : f;
|
|
@@ -4439,109 +4439,109 @@ function Hc(e) {
|
|
|
4439
4439
|
const t = this, n = [];
|
|
4440
4440
|
let r = 0, i, o, a;
|
|
4441
4441
|
return s;
|
|
4442
|
-
function s(
|
|
4442
|
+
function s(S) {
|
|
4443
4443
|
if (r < n.length) {
|
|
4444
|
-
const
|
|
4445
|
-
return t.containerState =
|
|
4444
|
+
const O = n[r];
|
|
4445
|
+
return t.containerState = O[1], e.attempt(O[0].continuation, l, c)(S);
|
|
4446
4446
|
}
|
|
4447
|
-
return c(
|
|
4447
|
+
return c(S);
|
|
4448
4448
|
}
|
|
4449
|
-
function l(
|
|
4449
|
+
function l(S) {
|
|
4450
4450
|
if (r++, t.containerState._closeFlow) {
|
|
4451
4451
|
t.containerState._closeFlow = void 0, i && _();
|
|
4452
|
-
const
|
|
4453
|
-
let N =
|
|
4452
|
+
const O = t.events.length;
|
|
4453
|
+
let N = O, k;
|
|
4454
4454
|
for (; N--; )
|
|
4455
4455
|
if (t.events[N][0] === "exit" && t.events[N][1].type === "chunkFlow") {
|
|
4456
|
-
|
|
4456
|
+
k = t.events[N][1].end;
|
|
4457
4457
|
break;
|
|
4458
4458
|
}
|
|
4459
|
-
|
|
4460
|
-
let
|
|
4461
|
-
for (;
|
|
4462
|
-
t.events[
|
|
4463
|
-
...
|
|
4464
|
-
},
|
|
4465
|
-
return Ee(t.events, N + 1, 0, t.events.slice(
|
|
4459
|
+
w(r);
|
|
4460
|
+
let z = O;
|
|
4461
|
+
for (; z < t.events.length; )
|
|
4462
|
+
t.events[z][1].end = {
|
|
4463
|
+
...k
|
|
4464
|
+
}, z++;
|
|
4465
|
+
return Ee(t.events, N + 1, 0, t.events.slice(O)), t.events.length = z, c(S);
|
|
4466
4466
|
}
|
|
4467
|
-
return s(
|
|
4467
|
+
return s(S);
|
|
4468
4468
|
}
|
|
4469
|
-
function c(
|
|
4469
|
+
function c(S) {
|
|
4470
4470
|
if (r === n.length) {
|
|
4471
4471
|
if (!i)
|
|
4472
|
-
return p(
|
|
4472
|
+
return p(S);
|
|
4473
4473
|
if (i.currentConstruct && i.currentConstruct.concrete)
|
|
4474
|
-
return h(
|
|
4474
|
+
return h(S);
|
|
4475
4475
|
t.interrupt = !!(i.currentConstruct && !i._gfmTableDynamicInterruptHack);
|
|
4476
4476
|
}
|
|
4477
|
-
return t.containerState = {}, e.check(vi, u, f)(
|
|
4477
|
+
return t.containerState = {}, e.check(vi, u, f)(S);
|
|
4478
4478
|
}
|
|
4479
|
-
function u(
|
|
4480
|
-
return i && _(),
|
|
4479
|
+
function u(S) {
|
|
4480
|
+
return i && _(), w(r), p(S);
|
|
4481
4481
|
}
|
|
4482
|
-
function f(
|
|
4483
|
-
return t.parser.lazy[t.now().line] = r !== n.length, a = t.now().offset, h(
|
|
4482
|
+
function f(S) {
|
|
4483
|
+
return t.parser.lazy[t.now().line] = r !== n.length, a = t.now().offset, h(S);
|
|
4484
4484
|
}
|
|
4485
|
-
function p(
|
|
4486
|
-
return t.containerState = {}, e.attempt(vi, d, h)(
|
|
4485
|
+
function p(S) {
|
|
4486
|
+
return t.containerState = {}, e.attempt(vi, d, h)(S);
|
|
4487
4487
|
}
|
|
4488
|
-
function d(
|
|
4489
|
-
return r++, n.push([t.currentConstruct, t.containerState]), p(
|
|
4488
|
+
function d(S) {
|
|
4489
|
+
return r++, n.push([t.currentConstruct, t.containerState]), p(S);
|
|
4490
4490
|
}
|
|
4491
|
-
function h(
|
|
4492
|
-
if (
|
|
4493
|
-
i && _(),
|
|
4491
|
+
function h(S) {
|
|
4492
|
+
if (S === null) {
|
|
4493
|
+
i && _(), w(0), e.consume(S);
|
|
4494
4494
|
return;
|
|
4495
4495
|
}
|
|
4496
4496
|
return i = i || t.parser.flow(t.now()), e.enter("chunkFlow", {
|
|
4497
4497
|
_tokenizer: i,
|
|
4498
4498
|
contentType: "flow",
|
|
4499
4499
|
previous: o
|
|
4500
|
-
}), b(
|
|
4500
|
+
}), b(S);
|
|
4501
4501
|
}
|
|
4502
|
-
function b(
|
|
4503
|
-
if (
|
|
4504
|
-
v(e.exit("chunkFlow"), !0),
|
|
4502
|
+
function b(S) {
|
|
4503
|
+
if (S === null) {
|
|
4504
|
+
v(e.exit("chunkFlow"), !0), w(0), e.consume(S);
|
|
4505
4505
|
return;
|
|
4506
4506
|
}
|
|
4507
|
-
return F(
|
|
4507
|
+
return F(S) ? (e.consume(S), v(e.exit("chunkFlow")), r = 0, t.interrupt = void 0, s) : (e.consume(S), b);
|
|
4508
4508
|
}
|
|
4509
|
-
function v(
|
|
4510
|
-
const N = t.sliceStream(
|
|
4511
|
-
if (
|
|
4512
|
-
let
|
|
4513
|
-
for (;
|
|
4509
|
+
function v(S, O) {
|
|
4510
|
+
const N = t.sliceStream(S);
|
|
4511
|
+
if (O && N.push(null), S.previous = o, o && (o.next = S), o = S, i.defineSkip(S.start), i.write(N), t.parser.lazy[S.start.line]) {
|
|
4512
|
+
let k = i.events.length;
|
|
4513
|
+
for (; k--; )
|
|
4514
4514
|
if (
|
|
4515
4515
|
// The token starts before the line ending…
|
|
4516
|
-
i.events[
|
|
4517
|
-
(!i.events[
|
|
4518
|
-
i.events[
|
|
4516
|
+
i.events[k][1].start.offset < a && // …and either is not ended yet…
|
|
4517
|
+
(!i.events[k][1].end || // …or ends after it.
|
|
4518
|
+
i.events[k][1].end.offset > a)
|
|
4519
4519
|
)
|
|
4520
4520
|
return;
|
|
4521
|
-
const
|
|
4522
|
-
let P =
|
|
4521
|
+
const z = t.events.length;
|
|
4522
|
+
let P = z, M, x;
|
|
4523
4523
|
for (; P--; )
|
|
4524
4524
|
if (t.events[P][0] === "exit" && t.events[P][1].type === "chunkFlow") {
|
|
4525
|
-
if (
|
|
4525
|
+
if (M) {
|
|
4526
4526
|
x = t.events[P][1].end;
|
|
4527
4527
|
break;
|
|
4528
4528
|
}
|
|
4529
|
-
|
|
4529
|
+
M = !0;
|
|
4530
4530
|
}
|
|
4531
|
-
for (
|
|
4532
|
-
t.events[
|
|
4531
|
+
for (w(r), k = z; k < t.events.length; )
|
|
4532
|
+
t.events[k][1].end = {
|
|
4533
4533
|
...x
|
|
4534
|
-
},
|
|
4535
|
-
Ee(t.events, P + 1, 0, t.events.slice(
|
|
4534
|
+
}, k++;
|
|
4535
|
+
Ee(t.events, P + 1, 0, t.events.slice(z)), t.events.length = k;
|
|
4536
4536
|
}
|
|
4537
4537
|
}
|
|
4538
|
-
function
|
|
4539
|
-
let
|
|
4540
|
-
for (;
|
|
4541
|
-
const N = n[
|
|
4538
|
+
function w(S) {
|
|
4539
|
+
let O = n.length;
|
|
4540
|
+
for (; O-- > S; ) {
|
|
4541
|
+
const N = n[O];
|
|
4542
4542
|
t.containerState = N[1], N[0].exit.call(t, e);
|
|
4543
4543
|
}
|
|
4544
|
-
n.length =
|
|
4544
|
+
n.length = S;
|
|
4545
4545
|
}
|
|
4546
4546
|
function _() {
|
|
4547
4547
|
i.write([null]), o = void 0, i = void 0, t.containerState._closeFlow = void 0;
|
|
@@ -4784,67 +4784,67 @@ function tu(e, t, n) {
|
|
|
4784
4784
|
};
|
|
4785
4785
|
let o = 0, a = 0, s;
|
|
4786
4786
|
return l;
|
|
4787
|
-
function l(
|
|
4788
|
-
return c(
|
|
4787
|
+
function l(k) {
|
|
4788
|
+
return c(k);
|
|
4789
4789
|
}
|
|
4790
|
-
function c(
|
|
4791
|
-
const
|
|
4792
|
-
return o =
|
|
4790
|
+
function c(k) {
|
|
4791
|
+
const z = r.events[r.events.length - 1];
|
|
4792
|
+
return o = z && z[1].type === "linePrefix" ? z[2].sliceSerialize(z[1], !0).length : 0, s = k, e.enter("codeFenced"), e.enter("codeFencedFence"), e.enter("codeFencedFenceSequence"), u(k);
|
|
4793
4793
|
}
|
|
4794
|
-
function u(
|
|
4795
|
-
return
|
|
4794
|
+
function u(k) {
|
|
4795
|
+
return k === s ? (a++, e.consume(k), u) : a < 3 ? n(k) : (e.exit("codeFencedFenceSequence"), G(k) ? Y(e, f, "whitespace")(k) : f(k));
|
|
4796
4796
|
}
|
|
4797
|
-
function f(
|
|
4798
|
-
return
|
|
4797
|
+
function f(k) {
|
|
4798
|
+
return k === null || F(k) ? (e.exit("codeFencedFence"), r.interrupt ? t(k) : e.check(Si, b, O)(k)) : (e.enter("codeFencedFenceInfo"), e.enter("chunkString", {
|
|
4799
4799
|
contentType: "string"
|
|
4800
|
-
}), p(
|
|
4800
|
+
}), p(k));
|
|
4801
4801
|
}
|
|
4802
|
-
function p(
|
|
4803
|
-
return
|
|
4802
|
+
function p(k) {
|
|
4803
|
+
return k === null || F(k) ? (e.exit("chunkString"), e.exit("codeFencedFenceInfo"), f(k)) : G(k) ? (e.exit("chunkString"), e.exit("codeFencedFenceInfo"), Y(e, d, "whitespace")(k)) : k === 96 && k === s ? n(k) : (e.consume(k), p);
|
|
4804
4804
|
}
|
|
4805
|
-
function d(
|
|
4806
|
-
return
|
|
4805
|
+
function d(k) {
|
|
4806
|
+
return k === null || F(k) ? f(k) : (e.enter("codeFencedFenceMeta"), e.enter("chunkString", {
|
|
4807
4807
|
contentType: "string"
|
|
4808
|
-
}), h(
|
|
4808
|
+
}), h(k));
|
|
4809
4809
|
}
|
|
4810
|
-
function h(
|
|
4811
|
-
return
|
|
4810
|
+
function h(k) {
|
|
4811
|
+
return k === null || F(k) ? (e.exit("chunkString"), e.exit("codeFencedFenceMeta"), f(k)) : k === 96 && k === s ? n(k) : (e.consume(k), h);
|
|
4812
4812
|
}
|
|
4813
|
-
function b(
|
|
4814
|
-
return e.attempt(i,
|
|
4813
|
+
function b(k) {
|
|
4814
|
+
return e.attempt(i, O, v)(k);
|
|
4815
4815
|
}
|
|
4816
|
-
function v(
|
|
4817
|
-
return e.enter("lineEnding"), e.consume(
|
|
4816
|
+
function v(k) {
|
|
4817
|
+
return e.enter("lineEnding"), e.consume(k), e.exit("lineEnding"), w;
|
|
4818
4818
|
}
|
|
4819
|
-
function
|
|
4820
|
-
return o > 0 && G(
|
|
4819
|
+
function w(k) {
|
|
4820
|
+
return o > 0 && G(k) ? Y(e, _, "linePrefix", o + 1)(k) : _(k);
|
|
4821
4821
|
}
|
|
4822
|
-
function _(
|
|
4823
|
-
return
|
|
4822
|
+
function _(k) {
|
|
4823
|
+
return k === null || F(k) ? e.check(Si, b, O)(k) : (e.enter("codeFlowValue"), S(k));
|
|
4824
4824
|
}
|
|
4825
|
-
function k
|
|
4826
|
-
return
|
|
4825
|
+
function S(k) {
|
|
4826
|
+
return k === null || F(k) ? (e.exit("codeFlowValue"), _(k)) : (e.consume(k), S);
|
|
4827
4827
|
}
|
|
4828
|
-
function
|
|
4829
|
-
return e.exit("codeFenced"), t(
|
|
4828
|
+
function O(k) {
|
|
4829
|
+
return e.exit("codeFenced"), t(k);
|
|
4830
4830
|
}
|
|
4831
|
-
function N(
|
|
4832
|
-
let
|
|
4831
|
+
function N(k, z, P) {
|
|
4832
|
+
let M = 0;
|
|
4833
4833
|
return x;
|
|
4834
4834
|
function x(A) {
|
|
4835
|
-
return
|
|
4835
|
+
return k.enter("lineEnding"), k.consume(A), k.exit("lineEnding"), E;
|
|
4836
4836
|
}
|
|
4837
|
-
function
|
|
4838
|
-
return
|
|
4837
|
+
function E(A) {
|
|
4838
|
+
return k.enter("codeFencedFence"), G(A) ? Y(k, I, "linePrefix", r.parser.constructs.disable.null.includes("codeIndented") ? void 0 : 4)(A) : I(A);
|
|
4839
4839
|
}
|
|
4840
4840
|
function I(A) {
|
|
4841
|
-
return A === s ? (
|
|
4841
|
+
return A === s ? (k.enter("codeFencedFenceSequence"), D(A)) : P(A);
|
|
4842
4842
|
}
|
|
4843
4843
|
function D(A) {
|
|
4844
|
-
return A === s ? (
|
|
4844
|
+
return A === s ? (M++, k.consume(A), D) : M >= a ? (k.exit("codeFencedFenceSequence"), G(A) ? Y(k, R, "whitespace")(A) : R(A)) : P(A);
|
|
4845
4845
|
}
|
|
4846
4846
|
function R(A) {
|
|
4847
|
-
return A === null || F(A) ? (
|
|
4847
|
+
return A === null || F(A) ? (k.exit("codeFencedFence"), z(A)) : P(A);
|
|
4848
4848
|
}
|
|
4849
4849
|
}
|
|
4850
4850
|
}
|
|
@@ -5151,8 +5151,8 @@ function fu(e, t) {
|
|
|
5151
5151
|
// Find a void token that includes a break.
|
|
5152
5152
|
s[p][0] === "exit" && s[p - 1][0] === "enter" && s[p][1].type === s[p - 1][1].type && s[p][1].start.line !== s[p][1].end.line && (b = p + 1, v.push(b), d._tokenizer = void 0, d.previous = void 0, d = d.next);
|
|
5153
5153
|
for (a.events = [], d ? (d._tokenizer = void 0, d.previous = void 0) : v.pop(), p = v.length; p--; ) {
|
|
5154
|
-
const
|
|
5155
|
-
l.push([_, _ +
|
|
5154
|
+
const w = s.slice(v[p], v[p + 1]), _ = o.pop();
|
|
5155
|
+
l.push([_, _ + w.length - 1]), e.splice(_, 2, w);
|
|
5156
5156
|
}
|
|
5157
5157
|
for (l.reverse(), p = -1; ++p < l.length; )
|
|
5158
5158
|
c[h + l[p][0]] = h + l[p][1], h += l[p][1] - l[p][0] - 1;
|
|
@@ -5206,27 +5206,27 @@ function va(e, t, n, r, i, o, a, s, l) {
|
|
|
5206
5206
|
const c = l || Number.POSITIVE_INFINITY;
|
|
5207
5207
|
let u = 0;
|
|
5208
5208
|
return f;
|
|
5209
|
-
function f(
|
|
5210
|
-
return
|
|
5209
|
+
function f(w) {
|
|
5210
|
+
return w === 60 ? (e.enter(r), e.enter(i), e.enter(o), e.consume(w), e.exit(o), p) : w === null || w === 32 || w === 41 || cn(w) ? n(w) : (e.enter(r), e.enter(a), e.enter(s), e.enter("chunkString", {
|
|
5211
5211
|
contentType: "string"
|
|
5212
|
-
}), b(
|
|
5212
|
+
}), b(w));
|
|
5213
5213
|
}
|
|
5214
|
-
function p(
|
|
5215
|
-
return
|
|
5214
|
+
function p(w) {
|
|
5215
|
+
return w === 62 ? (e.enter(o), e.consume(w), e.exit(o), e.exit(i), e.exit(r), t) : (e.enter(s), e.enter("chunkString", {
|
|
5216
5216
|
contentType: "string"
|
|
5217
|
-
}), d(
|
|
5217
|
+
}), d(w));
|
|
5218
5218
|
}
|
|
5219
|
-
function d(
|
|
5220
|
-
return
|
|
5219
|
+
function d(w) {
|
|
5220
|
+
return w === 62 ? (e.exit("chunkString"), e.exit(s), p(w)) : w === null || w === 60 || F(w) ? n(w) : (e.consume(w), w === 92 ? h : d);
|
|
5221
5221
|
}
|
|
5222
|
-
function h(
|
|
5223
|
-
return
|
|
5222
|
+
function h(w) {
|
|
5223
|
+
return w === 60 || w === 62 || w === 92 ? (e.consume(w), d) : d(w);
|
|
5224
5224
|
}
|
|
5225
|
-
function b(
|
|
5226
|
-
return !u && (
|
|
5225
|
+
function b(w) {
|
|
5226
|
+
return !u && (w === null || w === 41 || Z(w)) ? (e.exit("chunkString"), e.exit(s), e.exit(a), e.exit(r), t(w)) : u < c && w === 40 ? (e.consume(w), u++, b) : w === 41 ? (e.consume(w), u--, b) : w === null || w === 32 || w === 40 || cn(w) ? n(w) : (e.consume(w), w === 92 ? v : b);
|
|
5227
5227
|
}
|
|
5228
|
-
function v(
|
|
5229
|
-
return
|
|
5228
|
+
function v(w) {
|
|
5229
|
+
return w === 40 || w === 41 || w === 92 ? (e.consume(w), b) : b(w);
|
|
5230
5230
|
}
|
|
5231
5231
|
}
|
|
5232
5232
|
function ka(e, t, n, r, i, o) {
|
|
@@ -5514,42 +5514,42 @@ function Ru(e, t, n) {
|
|
|
5514
5514
|
function v(g) {
|
|
5515
5515
|
if (g === null || g === 47 || g === 62 || Z(g)) {
|
|
5516
5516
|
const J = g === 47, me = a.toLowerCase();
|
|
5517
|
-
return !J && !o && Ci.includes(me) ? (i = 1, r.interrupt ? t(g) : I(g)) : _u.includes(a.toLowerCase()) ? (i = 6, J ? (e.consume(g),
|
|
5517
|
+
return !J && !o && Ci.includes(me) ? (i = 1, r.interrupt ? t(g) : I(g)) : _u.includes(a.toLowerCase()) ? (i = 6, J ? (e.consume(g), w) : r.interrupt ? t(g) : I(g)) : (i = 7, r.interrupt && !r.parser.lazy[r.now().line] ? n(g) : o ? _(g) : S(g));
|
|
5518
5518
|
}
|
|
5519
5519
|
return g === 45 || de(g) ? (e.consume(g), a += String.fromCharCode(g), v) : n(g);
|
|
5520
5520
|
}
|
|
5521
|
-
function
|
|
5521
|
+
function w(g) {
|
|
5522
5522
|
return g === 62 ? (e.consume(g), r.interrupt ? t : I) : n(g);
|
|
5523
5523
|
}
|
|
5524
5524
|
function _(g) {
|
|
5525
5525
|
return G(g) ? (e.consume(g), _) : x(g);
|
|
5526
5526
|
}
|
|
5527
|
-
function
|
|
5528
|
-
return g === 47 ? (e.consume(g), x) : g === 58 || g === 95 || ye(g) ? (e.consume(g),
|
|
5527
|
+
function S(g) {
|
|
5528
|
+
return g === 47 ? (e.consume(g), x) : g === 58 || g === 95 || ye(g) ? (e.consume(g), O) : G(g) ? (e.consume(g), S) : x(g);
|
|
5529
5529
|
}
|
|
5530
|
-
function
|
|
5531
|
-
return g === 45 || g === 46 || g === 58 || g === 95 || de(g) ? (e.consume(g),
|
|
5530
|
+
function O(g) {
|
|
5531
|
+
return g === 45 || g === 46 || g === 58 || g === 95 || de(g) ? (e.consume(g), O) : N(g);
|
|
5532
5532
|
}
|
|
5533
5533
|
function N(g) {
|
|
5534
|
-
return g === 61 ? (e.consume(g),
|
|
5534
|
+
return g === 61 ? (e.consume(g), k) : G(g) ? (e.consume(g), N) : S(g);
|
|
5535
5535
|
}
|
|
5536
|
-
function
|
|
5537
|
-
return g === null || g === 60 || g === 61 || g === 62 || g === 96 ? n(g) : g === 34 || g === 39 ? (e.consume(g), l = g,
|
|
5536
|
+
function k(g) {
|
|
5537
|
+
return g === null || g === 60 || g === 61 || g === 62 || g === 96 ? n(g) : g === 34 || g === 39 ? (e.consume(g), l = g, z) : G(g) ? (e.consume(g), k) : P(g);
|
|
5538
5538
|
}
|
|
5539
|
-
function
|
|
5540
|
-
return g === l ? (e.consume(g), l = null,
|
|
5539
|
+
function z(g) {
|
|
5540
|
+
return g === l ? (e.consume(g), l = null, M) : g === null || F(g) ? n(g) : (e.consume(g), z);
|
|
5541
5541
|
}
|
|
5542
5542
|
function P(g) {
|
|
5543
5543
|
return g === null || g === 34 || g === 39 || g === 47 || g === 60 || g === 61 || g === 62 || g === 96 || Z(g) ? N(g) : (e.consume(g), P);
|
|
5544
5544
|
}
|
|
5545
|
-
function
|
|
5546
|
-
return g === 47 || g === 62 || G(g) ?
|
|
5545
|
+
function M(g) {
|
|
5546
|
+
return g === 47 || g === 62 || G(g) ? S(g) : n(g);
|
|
5547
5547
|
}
|
|
5548
5548
|
function x(g) {
|
|
5549
|
-
return g === 62 ? (e.consume(g),
|
|
5549
|
+
return g === 62 ? (e.consume(g), E) : n(g);
|
|
5550
5550
|
}
|
|
5551
|
-
function
|
|
5552
|
-
return g === null || F(g) ? I(g) : G(g) ? (e.consume(g),
|
|
5551
|
+
function E(g) {
|
|
5552
|
+
return g === null || F(g) ? I(g) : G(g) ? (e.consume(g), E) : n(g);
|
|
5553
5553
|
}
|
|
5554
5554
|
function I(g) {
|
|
5555
5555
|
return g === 45 && i === 2 ? (e.consume(g), U) : g === 60 && i === 1 ? (e.consume(g), q) : g === 62 && i === 4 ? (e.consume(g), ae) : g === 63 && i === 3 ? (e.consume(g), m) : g === 93 && i === 5 ? (e.consume(g), ne) : F(g) && (i === 6 || i === 7) ? (e.exit("htmlFlowData"), e.check(Iu, Ne, D)(g)) : g === null || F(g) ? (e.exit("htmlFlowData"), D(g)) : (e.consume(g), I);
|
|
@@ -5617,7 +5617,7 @@ function Pu(e, t, n) {
|
|
|
5617
5617
|
return e.enter("htmlText"), e.enter("htmlTextData"), e.consume(m), l;
|
|
5618
5618
|
}
|
|
5619
5619
|
function l(m) {
|
|
5620
|
-
return m === 33 ? (e.consume(m), c) : m === 47 ? (e.consume(m), N) : m === 63 ? (e.consume(m),
|
|
5620
|
+
return m === 33 ? (e.consume(m), c) : m === 47 ? (e.consume(m), N) : m === 63 ? (e.consume(m), S) : ye(m) ? (e.consume(m), P) : n(m);
|
|
5621
5621
|
}
|
|
5622
5622
|
function c(m) {
|
|
5623
5623
|
return m === 45 ? (e.consume(m), u) : m === 91 ? (e.consume(m), o = 0, h) : ye(m) ? (e.consume(m), _) : n(m);
|
|
@@ -5642,40 +5642,40 @@ function Pu(e, t, n) {
|
|
|
5642
5642
|
return m === null ? n(m) : m === 93 ? (e.consume(m), v) : F(m) ? (a = b, q(m)) : (e.consume(m), b);
|
|
5643
5643
|
}
|
|
5644
5644
|
function v(m) {
|
|
5645
|
-
return m === 93 ? (e.consume(m),
|
|
5645
|
+
return m === 93 ? (e.consume(m), w) : b(m);
|
|
5646
5646
|
}
|
|
5647
|
-
function
|
|
5648
|
-
return m === 62 ? U(m) : m === 93 ? (e.consume(m),
|
|
5647
|
+
function w(m) {
|
|
5648
|
+
return m === 62 ? U(m) : m === 93 ? (e.consume(m), w) : b(m);
|
|
5649
5649
|
}
|
|
5650
5650
|
function _(m) {
|
|
5651
5651
|
return m === null || m === 62 ? U(m) : F(m) ? (a = _, q(m)) : (e.consume(m), _);
|
|
5652
5652
|
}
|
|
5653
|
-
function
|
|
5654
|
-
return m === null ? n(m) : m === 63 ? (e.consume(m),
|
|
5653
|
+
function S(m) {
|
|
5654
|
+
return m === null ? n(m) : m === 63 ? (e.consume(m), O) : F(m) ? (a = S, q(m)) : (e.consume(m), S);
|
|
5655
5655
|
}
|
|
5656
|
-
function
|
|
5657
|
-
return m === 62 ? U(m) :
|
|
5656
|
+
function O(m) {
|
|
5657
|
+
return m === 62 ? U(m) : S(m);
|
|
5658
5658
|
}
|
|
5659
5659
|
function N(m) {
|
|
5660
|
-
return ye(m) ? (e.consume(m),
|
|
5660
|
+
return ye(m) ? (e.consume(m), k) : n(m);
|
|
5661
5661
|
}
|
|
5662
|
-
function
|
|
5663
|
-
return m === 45 || de(m) ? (e.consume(m),
|
|
5662
|
+
function k(m) {
|
|
5663
|
+
return m === 45 || de(m) ? (e.consume(m), k) : z(m);
|
|
5664
5664
|
}
|
|
5665
|
-
function
|
|
5666
|
-
return F(m) ? (a =
|
|
5665
|
+
function z(m) {
|
|
5666
|
+
return F(m) ? (a = z, q(m)) : G(m) ? (e.consume(m), z) : U(m);
|
|
5667
5667
|
}
|
|
5668
5668
|
function P(m) {
|
|
5669
|
-
return m === 45 || de(m) ? (e.consume(m), P) : m === 47 || m === 62 || Z(m) ?
|
|
5669
|
+
return m === 45 || de(m) ? (e.consume(m), P) : m === 47 || m === 62 || Z(m) ? M(m) : n(m);
|
|
5670
5670
|
}
|
|
5671
|
-
function
|
|
5672
|
-
return m === 47 ? (e.consume(m), U) : m === 58 || m === 95 || ye(m) ? (e.consume(m), x) : F(m) ? (a =
|
|
5671
|
+
function M(m) {
|
|
5672
|
+
return m === 47 ? (e.consume(m), U) : m === 58 || m === 95 || ye(m) ? (e.consume(m), x) : F(m) ? (a = M, q(m)) : G(m) ? (e.consume(m), M) : U(m);
|
|
5673
5673
|
}
|
|
5674
5674
|
function x(m) {
|
|
5675
|
-
return m === 45 || m === 46 || m === 58 || m === 95 || de(m) ? (e.consume(m), x) :
|
|
5675
|
+
return m === 45 || m === 46 || m === 58 || m === 95 || de(m) ? (e.consume(m), x) : E(m);
|
|
5676
5676
|
}
|
|
5677
|
-
function
|
|
5678
|
-
return m === 61 ? (e.consume(m), I) : F(m) ? (a =
|
|
5677
|
+
function E(m) {
|
|
5678
|
+
return m === 61 ? (e.consume(m), I) : F(m) ? (a = E, q(m)) : G(m) ? (e.consume(m), E) : M(m);
|
|
5679
5679
|
}
|
|
5680
5680
|
function I(m) {
|
|
5681
5681
|
return m === null || m === 60 || m === 61 || m === 62 || m === 96 ? n(m) : m === 34 || m === 39 ? (e.consume(m), i = m, D) : F(m) ? (a = I, q(m)) : G(m) ? (e.consume(m), I) : (e.consume(m), R);
|
|
@@ -5684,10 +5684,10 @@ function Pu(e, t, n) {
|
|
|
5684
5684
|
return m === i ? (e.consume(m), i = void 0, A) : m === null ? n(m) : F(m) ? (a = D, q(m)) : (e.consume(m), D);
|
|
5685
5685
|
}
|
|
5686
5686
|
function R(m) {
|
|
5687
|
-
return m === null || m === 34 || m === 39 || m === 60 || m === 61 || m === 96 ? n(m) : m === 47 || m === 62 || Z(m) ?
|
|
5687
|
+
return m === null || m === 34 || m === 39 || m === 60 || m === 61 || m === 96 ? n(m) : m === 47 || m === 62 || Z(m) ? M(m) : (e.consume(m), R);
|
|
5688
5688
|
}
|
|
5689
5689
|
function A(m) {
|
|
5690
|
-
return m === 47 || m === 62 || Z(m) ?
|
|
5690
|
+
return m === 47 || m === 62 || Z(m) ? M(m) : n(m);
|
|
5691
5691
|
}
|
|
5692
5692
|
function U(m) {
|
|
5693
5693
|
return m === 62 ? (e.consume(m), e.exit("htmlTextData"), e.exit("htmlText"), t) : n(m);
|
|
@@ -6233,12 +6233,12 @@ function Sf(e, t, n) {
|
|
|
6233
6233
|
const i = {}, o = [];
|
|
6234
6234
|
let a = [], s = [];
|
|
6235
6235
|
const l = {
|
|
6236
|
-
attempt:
|
|
6237
|
-
check:
|
|
6236
|
+
attempt: z(N),
|
|
6237
|
+
check: z(k),
|
|
6238
6238
|
consume: _,
|
|
6239
|
-
enter:
|
|
6240
|
-
exit:
|
|
6241
|
-
interrupt:
|
|
6239
|
+
enter: S,
|
|
6240
|
+
exit: O,
|
|
6241
|
+
interrupt: z(k, {
|
|
6242
6242
|
interrupt: !0
|
|
6243
6243
|
})
|
|
6244
6244
|
}, c = {
|
|
@@ -6255,69 +6255,69 @@ function Sf(e, t, n) {
|
|
|
6255
6255
|
};
|
|
6256
6256
|
let u = t.tokenize.call(c, l);
|
|
6257
6257
|
return t.resolveAll && o.push(t), c;
|
|
6258
|
-
function f(
|
|
6259
|
-
return a = Ie(a,
|
|
6258
|
+
function f(E) {
|
|
6259
|
+
return a = Ie(a, E), v(), a[a.length - 1] !== null ? [] : (P(t, 0), c.events = bn(o, c.events, c), c.events);
|
|
6260
6260
|
}
|
|
6261
|
-
function p(
|
|
6262
|
-
return Cf(d(
|
|
6261
|
+
function p(E, I) {
|
|
6262
|
+
return Cf(d(E), I);
|
|
6263
6263
|
}
|
|
6264
|
-
function d(
|
|
6265
|
-
return Ef(a,
|
|
6264
|
+
function d(E) {
|
|
6265
|
+
return Ef(a, E);
|
|
6266
6266
|
}
|
|
6267
6267
|
function h() {
|
|
6268
6268
|
const {
|
|
6269
|
-
_bufferIndex:
|
|
6269
|
+
_bufferIndex: E,
|
|
6270
6270
|
_index: I,
|
|
6271
6271
|
line: D,
|
|
6272
6272
|
column: R,
|
|
6273
6273
|
offset: A
|
|
6274
6274
|
} = r;
|
|
6275
6275
|
return {
|
|
6276
|
-
_bufferIndex:
|
|
6276
|
+
_bufferIndex: E,
|
|
6277
6277
|
_index: I,
|
|
6278
6278
|
line: D,
|
|
6279
6279
|
column: R,
|
|
6280
6280
|
offset: A
|
|
6281
6281
|
};
|
|
6282
6282
|
}
|
|
6283
|
-
function b(
|
|
6284
|
-
i[
|
|
6283
|
+
function b(E) {
|
|
6284
|
+
i[E.line] = E.column, x();
|
|
6285
6285
|
}
|
|
6286
6286
|
function v() {
|
|
6287
|
-
let
|
|
6287
|
+
let E;
|
|
6288
6288
|
for (; r._index < a.length; ) {
|
|
6289
6289
|
const I = a[r._index];
|
|
6290
6290
|
if (typeof I == "string")
|
|
6291
|
-
for (
|
|
6292
|
-
|
|
6291
|
+
for (E = r._index, r._bufferIndex < 0 && (r._bufferIndex = 0); r._index === E && r._bufferIndex < I.length; )
|
|
6292
|
+
w(I.charCodeAt(r._bufferIndex));
|
|
6293
6293
|
else
|
|
6294
|
-
|
|
6294
|
+
w(I);
|
|
6295
6295
|
}
|
|
6296
6296
|
}
|
|
6297
|
-
function
|
|
6298
|
-
u = u(
|
|
6297
|
+
function w(E) {
|
|
6298
|
+
u = u(E);
|
|
6299
6299
|
}
|
|
6300
|
-
function _(
|
|
6301
|
-
F(
|
|
6300
|
+
function _(E) {
|
|
6301
|
+
F(E) ? (r.line++, r.column = 1, r.offset += E === -3 ? 2 : 1, x()) : E !== -1 && (r.column++, r.offset++), r._bufferIndex < 0 ? r._index++ : (r._bufferIndex++, r._bufferIndex === // Points w/ non-negative `_bufferIndex` reference
|
|
6302
6302
|
// strings.
|
|
6303
6303
|
/** @type {string} */
|
|
6304
|
-
a[r._index].length && (r._bufferIndex = -1, r._index++)), c.previous =
|
|
6304
|
+
a[r._index].length && (r._bufferIndex = -1, r._index++)), c.previous = E;
|
|
6305
6305
|
}
|
|
6306
|
-
function
|
|
6306
|
+
function S(E, I) {
|
|
6307
6307
|
const D = I || {};
|
|
6308
|
-
return D.type =
|
|
6308
|
+
return D.type = E, D.start = h(), c.events.push(["enter", D, c]), s.push(D), D;
|
|
6309
6309
|
}
|
|
6310
|
-
function
|
|
6310
|
+
function O(E) {
|
|
6311
6311
|
const I = s.pop();
|
|
6312
6312
|
return I.end = h(), c.events.push(["exit", I, c]), I;
|
|
6313
6313
|
}
|
|
6314
|
-
function N(
|
|
6315
|
-
P(
|
|
6314
|
+
function N(E, I) {
|
|
6315
|
+
P(E, I.from);
|
|
6316
6316
|
}
|
|
6317
|
-
function
|
|
6317
|
+
function k(E, I) {
|
|
6318
6318
|
I.restore();
|
|
6319
6319
|
}
|
|
6320
|
-
function
|
|
6320
|
+
function z(E, I) {
|
|
6321
6321
|
return D;
|
|
6322
6322
|
function D(R, A, U) {
|
|
6323
6323
|
let q, H, ne, m;
|
|
@@ -6349,7 +6349,7 @@ function Sf(e, t, n) {
|
|
|
6349
6349
|
function g(se) {
|
|
6350
6350
|
return Ke;
|
|
6351
6351
|
function Ke(Re) {
|
|
6352
|
-
return m =
|
|
6352
|
+
return m = M(), ne = se, se.partial || (c.currentConstruct = se), se.name && c.parser.constructs.disable.null.includes(se.name) ? me() : se.tokenize.call(
|
|
6353
6353
|
// If we do have fields, create an object w/ `context` as its
|
|
6354
6354
|
// prototype.
|
|
6355
6355
|
// This allows a “live binding”, which is needed for `interrupt`.
|
|
@@ -6361,24 +6361,24 @@ function Sf(e, t, n) {
|
|
|
6361
6361
|
}
|
|
6362
6362
|
}
|
|
6363
6363
|
function J(se) {
|
|
6364
|
-
return
|
|
6364
|
+
return E(ne, m), A;
|
|
6365
6365
|
}
|
|
6366
6366
|
function me(se) {
|
|
6367
6367
|
return m.restore(), ++H < q.length ? g(q[H]) : U;
|
|
6368
6368
|
}
|
|
6369
6369
|
}
|
|
6370
6370
|
}
|
|
6371
|
-
function P(
|
|
6372
|
-
|
|
6371
|
+
function P(E, I) {
|
|
6372
|
+
E.resolveAll && !o.includes(E) && o.push(E), E.resolve && Ee(c.events, I, c.events.length - I, E.resolve(c.events.slice(I), c)), E.resolveTo && (c.events = E.resolveTo(c.events, c));
|
|
6373
6373
|
}
|
|
6374
|
-
function
|
|
6375
|
-
const
|
|
6374
|
+
function M() {
|
|
6375
|
+
const E = h(), I = c.previous, D = c.currentConstruct, R = c.events.length, A = Array.from(s);
|
|
6376
6376
|
return {
|
|
6377
6377
|
from: R,
|
|
6378
6378
|
restore: U
|
|
6379
6379
|
};
|
|
6380
6380
|
function U() {
|
|
6381
|
-
r =
|
|
6381
|
+
r = E, c.previous = I, c.currentConstruct = D, c.events.length = R, s = A, x();
|
|
6382
6382
|
}
|
|
6383
6383
|
}
|
|
6384
6384
|
function x() {
|
|
@@ -6525,20 +6525,20 @@ function Lf(e) {
|
|
|
6525
6525
|
canContainEols: ["emphasis", "fragment", "heading", "paragraph", "strong"],
|
|
6526
6526
|
enter: {
|
|
6527
6527
|
autolink: o(oi),
|
|
6528
|
-
autolinkProtocol:
|
|
6529
|
-
autolinkEmail:
|
|
6528
|
+
autolinkProtocol: M,
|
|
6529
|
+
autolinkEmail: M,
|
|
6530
6530
|
atxHeading: o(ni),
|
|
6531
6531
|
blockQuote: o(rt),
|
|
6532
|
-
characterEscape:
|
|
6533
|
-
characterReference:
|
|
6532
|
+
characterEscape: M,
|
|
6533
|
+
characterReference: M,
|
|
6534
6534
|
codeFenced: o($t),
|
|
6535
6535
|
codeFencedFenceInfo: a,
|
|
6536
6536
|
codeFencedFenceMeta: a,
|
|
6537
6537
|
codeIndented: o($t, a),
|
|
6538
6538
|
codeText: o(Qs, a),
|
|
6539
|
-
codeTextData:
|
|
6540
|
-
data:
|
|
6541
|
-
codeFlowValue:
|
|
6539
|
+
codeTextData: M,
|
|
6540
|
+
data: M,
|
|
6541
|
+
codeFlowValue: M,
|
|
6542
6542
|
definition: o(Xs),
|
|
6543
6543
|
definitionDestinationString: a,
|
|
6544
6544
|
definitionLabelString: a,
|
|
@@ -6547,9 +6547,9 @@ function Lf(e) {
|
|
|
6547
6547
|
hardBreakEscape: o(ri),
|
|
6548
6548
|
hardBreakTrailing: o(ri),
|
|
6549
6549
|
htmlFlow: o(ii, a),
|
|
6550
|
-
htmlFlowData:
|
|
6550
|
+
htmlFlowData: M,
|
|
6551
6551
|
htmlText: o(ii, a),
|
|
6552
|
-
htmlTextData:
|
|
6552
|
+
htmlTextData: M,
|
|
6553
6553
|
image: o(el),
|
|
6554
6554
|
label: a,
|
|
6555
6555
|
link: o(oi),
|
|
@@ -6583,14 +6583,14 @@ function Lf(e) {
|
|
|
6583
6583
|
codeFencedFenceInfo: d,
|
|
6584
6584
|
codeFencedFenceMeta: h,
|
|
6585
6585
|
codeFlowValue: x,
|
|
6586
|
-
codeIndented: l(
|
|
6586
|
+
codeIndented: l(w),
|
|
6587
6587
|
codeText: l(A),
|
|
6588
6588
|
codeTextData: x,
|
|
6589
6589
|
data: x,
|
|
6590
6590
|
definition: l(),
|
|
6591
|
-
definitionDestinationString:
|
|
6591
|
+
definitionDestinationString: O,
|
|
6592
6592
|
definitionLabelString: _,
|
|
6593
|
-
definitionTitleString:
|
|
6593
|
+
definitionTitleString: S,
|
|
6594
6594
|
emphasis: l(),
|
|
6595
6595
|
hardBreakEscape: l(I),
|
|
6596
6596
|
hardBreakTrailing: l(I),
|
|
@@ -6601,7 +6601,7 @@ function Lf(e) {
|
|
|
6601
6601
|
image: l(q),
|
|
6602
6602
|
label: ne,
|
|
6603
6603
|
labelText: H,
|
|
6604
|
-
lineEnding:
|
|
6604
|
+
lineEnding: E,
|
|
6605
6605
|
link: l(U),
|
|
6606
6606
|
listItem: l(),
|
|
6607
6607
|
listOrdered: l(),
|
|
@@ -6612,8 +6612,8 @@ function Lf(e) {
|
|
|
6612
6612
|
resourceTitleString: ae,
|
|
6613
6613
|
resource: Ne,
|
|
6614
6614
|
setextHeading: l(P),
|
|
6615
|
-
setextHeadingLineSequence:
|
|
6616
|
-
setextHeadingText:
|
|
6615
|
+
setextHeadingLineSequence: z,
|
|
6616
|
+
setextHeadingText: k,
|
|
6617
6617
|
strong: l(),
|
|
6618
6618
|
thematicBreak: l()
|
|
6619
6619
|
}
|
|
@@ -6621,13 +6621,13 @@ function Lf(e) {
|
|
|
6621
6621
|
Aa(t, (e || {}).mdastExtensions || []);
|
|
6622
6622
|
const n = {};
|
|
6623
6623
|
return r;
|
|
6624
|
-
function r(
|
|
6625
|
-
let
|
|
6624
|
+
function r(C) {
|
|
6625
|
+
let L = {
|
|
6626
6626
|
type: "root",
|
|
6627
6627
|
children: []
|
|
6628
6628
|
};
|
|
6629
6629
|
const V = {
|
|
6630
|
-
stack: [
|
|
6630
|
+
stack: [L],
|
|
6631
6631
|
tokenStack: [],
|
|
6632
6632
|
config: t,
|
|
6633
6633
|
enter: s,
|
|
@@ -6637,43 +6637,43 @@ function Lf(e) {
|
|
|
6637
6637
|
data: n
|
|
6638
6638
|
}, K = [];
|
|
6639
6639
|
let X = -1;
|
|
6640
|
-
for (; ++X <
|
|
6641
|
-
if (
|
|
6642
|
-
if (
|
|
6640
|
+
for (; ++X < C.length; )
|
|
6641
|
+
if (C[X][1].type === "listOrdered" || C[X][1].type === "listUnordered")
|
|
6642
|
+
if (C[X][0] === "enter")
|
|
6643
6643
|
K.push(X);
|
|
6644
6644
|
else {
|
|
6645
6645
|
const Oe = K.pop();
|
|
6646
|
-
X = i(
|
|
6646
|
+
X = i(C, Oe, X);
|
|
6647
6647
|
}
|
|
6648
|
-
for (X = -1; ++X <
|
|
6649
|
-
const Oe = t[
|
|
6650
|
-
_a.call(Oe,
|
|
6651
|
-
sliceSerialize:
|
|
6652
|
-
}, V),
|
|
6648
|
+
for (X = -1; ++X < C.length; ) {
|
|
6649
|
+
const Oe = t[C[X][0]];
|
|
6650
|
+
_a.call(Oe, C[X][1].type) && Oe[C[X][1].type].call(Object.assign({
|
|
6651
|
+
sliceSerialize: C[X][2].sliceSerialize
|
|
6652
|
+
}, V), C[X][1]);
|
|
6653
6653
|
}
|
|
6654
6654
|
if (V.tokenStack.length > 0) {
|
|
6655
6655
|
const Oe = V.tokenStack[V.tokenStack.length - 1];
|
|
6656
6656
|
(Oe[1] || Ii).call(V, void 0, Oe[0]);
|
|
6657
6657
|
}
|
|
6658
|
-
for (
|
|
6659
|
-
start: Ve(
|
|
6658
|
+
for (L.position = {
|
|
6659
|
+
start: Ve(C.length > 0 ? C[0][1].start : {
|
|
6660
6660
|
line: 1,
|
|
6661
6661
|
column: 1,
|
|
6662
6662
|
offset: 0
|
|
6663
6663
|
}),
|
|
6664
|
-
end: Ve(
|
|
6664
|
+
end: Ve(C.length > 0 ? C[C.length - 2][1].end : {
|
|
6665
6665
|
line: 1,
|
|
6666
6666
|
column: 1,
|
|
6667
6667
|
offset: 0
|
|
6668
6668
|
})
|
|
6669
6669
|
}, X = -1; ++X < t.transforms.length; )
|
|
6670
|
-
|
|
6671
|
-
return
|
|
6670
|
+
L = t.transforms[X](L) || L;
|
|
6671
|
+
return L;
|
|
6672
6672
|
}
|
|
6673
|
-
function i(
|
|
6674
|
-
let K =
|
|
6673
|
+
function i(C, L, V) {
|
|
6674
|
+
let K = L - 1, X = -1, Oe = !1, Ye, Ue, wt, xt;
|
|
6675
6675
|
for (; ++K <= V; ) {
|
|
6676
|
-
const ve =
|
|
6676
|
+
const ve = C[K];
|
|
6677
6677
|
switch (ve[1].type) {
|
|
6678
6678
|
case "listUnordered":
|
|
6679
6679
|
case "listOrdered":
|
|
@@ -6698,13 +6698,13 @@ function Lf(e) {
|
|
|
6698
6698
|
if (Ye) {
|
|
6699
6699
|
let it = K;
|
|
6700
6700
|
for (Ue = void 0; it--; ) {
|
|
6701
|
-
const Be =
|
|
6701
|
+
const Be = C[it];
|
|
6702
6702
|
if (Be[1].type === "lineEnding" || Be[1].type === "lineEndingBlank") {
|
|
6703
6703
|
if (Be[0] === "exit") continue;
|
|
6704
|
-
Ue && (
|
|
6704
|
+
Ue && (C[Ue][1].type = "lineEndingBlank", Oe = !0), Be[1].type = "lineEnding", Ue = it;
|
|
6705
6705
|
} else if (!(Be[1].type === "linePrefix" || Be[1].type === "blockQuotePrefix" || Be[1].type === "blockQuotePrefixWhitespace" || Be[1].type === "blockQuoteMarker" || Be[1].type === "listItemIndent")) break;
|
|
6706
6706
|
}
|
|
6707
|
-
wt && (!Ue || wt < Ue) && (Ye._spread = !0), Ye.end = Object.assign({}, Ue ?
|
|
6707
|
+
wt && (!Ue || wt < Ue) && (Ye._spread = !0), Ye.end = Object.assign({}, Ue ? C[Ue][1].start : ve[1].end), C.splice(Ue || K, 0, ["exit", Ye, ve[2]]), K++, V++;
|
|
6708
6708
|
}
|
|
6709
6709
|
if (ve[1].type === "listItemPrefix") {
|
|
6710
6710
|
const it = {
|
|
@@ -6714,16 +6714,16 @@ function Lf(e) {
|
|
|
6714
6714
|
// @ts-expect-error: we’ll add `end` in a second.
|
|
6715
6715
|
end: void 0
|
|
6716
6716
|
};
|
|
6717
|
-
Ye = it,
|
|
6717
|
+
Ye = it, C.splice(K, 0, ["enter", it, ve[2]]), K++, V++, wt = void 0, xt = !0;
|
|
6718
6718
|
}
|
|
6719
6719
|
}
|
|
6720
6720
|
}
|
|
6721
|
-
return
|
|
6721
|
+
return C[L][1]._spread = Oe, V;
|
|
6722
6722
|
}
|
|
6723
|
-
function o(
|
|
6723
|
+
function o(C, L) {
|
|
6724
6724
|
return V;
|
|
6725
6725
|
function V(K) {
|
|
6726
|
-
s.call(this,
|
|
6726
|
+
s.call(this, C(K), K), L && L.call(this, K);
|
|
6727
6727
|
}
|
|
6728
6728
|
}
|
|
6729
6729
|
function a() {
|
|
@@ -6732,28 +6732,28 @@ function Lf(e) {
|
|
|
6732
6732
|
children: []
|
|
6733
6733
|
});
|
|
6734
6734
|
}
|
|
6735
|
-
function s(
|
|
6736
|
-
this.stack[this.stack.length - 1].children.push(
|
|
6737
|
-
start: Ve(
|
|
6735
|
+
function s(C, L, V) {
|
|
6736
|
+
this.stack[this.stack.length - 1].children.push(C), this.stack.push(C), this.tokenStack.push([L, V || void 0]), C.position = {
|
|
6737
|
+
start: Ve(L.start),
|
|
6738
6738
|
// @ts-expect-error: `end` will be patched later.
|
|
6739
6739
|
end: void 0
|
|
6740
6740
|
};
|
|
6741
6741
|
}
|
|
6742
|
-
function l(
|
|
6743
|
-
return
|
|
6744
|
-
function
|
|
6745
|
-
|
|
6742
|
+
function l(C) {
|
|
6743
|
+
return L;
|
|
6744
|
+
function L(V) {
|
|
6745
|
+
C && C.call(this, V), c.call(this, V);
|
|
6746
6746
|
}
|
|
6747
6747
|
}
|
|
6748
|
-
function c(
|
|
6748
|
+
function c(C, L) {
|
|
6749
6749
|
const V = this.stack.pop(), K = this.tokenStack.pop();
|
|
6750
6750
|
if (K)
|
|
6751
|
-
K[0].type !==
|
|
6752
|
-
else throw new Error("Cannot close `" +
|
|
6753
|
-
start:
|
|
6754
|
-
end:
|
|
6751
|
+
K[0].type !== C.type && (L ? L.call(this, C, K[0]) : (K[1] || Ii).call(this, C, K[0]));
|
|
6752
|
+
else throw new Error("Cannot close `" + C.type + "` (" + Tt({
|
|
6753
|
+
start: C.start,
|
|
6754
|
+
end: C.end
|
|
6755
6755
|
}) + "): it’s not open");
|
|
6756
|
-
V.position.end = Ve(
|
|
6756
|
+
V.position.end = Ve(C.end);
|
|
6757
6757
|
}
|
|
6758
6758
|
function u() {
|
|
6759
6759
|
return Nr(this.stack.pop());
|
|
@@ -6761,134 +6761,134 @@ function Lf(e) {
|
|
|
6761
6761
|
function f() {
|
|
6762
6762
|
this.data.expectingFirstListItemValue = !0;
|
|
6763
6763
|
}
|
|
6764
|
-
function p(
|
|
6764
|
+
function p(C) {
|
|
6765
6765
|
if (this.data.expectingFirstListItemValue) {
|
|
6766
|
-
const
|
|
6767
|
-
|
|
6766
|
+
const L = this.stack[this.stack.length - 2];
|
|
6767
|
+
L.start = Number.parseInt(this.sliceSerialize(C), 10), this.data.expectingFirstListItemValue = void 0;
|
|
6768
6768
|
}
|
|
6769
6769
|
}
|
|
6770
6770
|
function d() {
|
|
6771
|
-
const
|
|
6772
|
-
|
|
6771
|
+
const C = this.resume(), L = this.stack[this.stack.length - 1];
|
|
6772
|
+
L.lang = C;
|
|
6773
6773
|
}
|
|
6774
6774
|
function h() {
|
|
6775
|
-
const
|
|
6776
|
-
|
|
6775
|
+
const C = this.resume(), L = this.stack[this.stack.length - 1];
|
|
6776
|
+
L.meta = C;
|
|
6777
6777
|
}
|
|
6778
6778
|
function b() {
|
|
6779
6779
|
this.data.flowCodeInside || (this.buffer(), this.data.flowCodeInside = !0);
|
|
6780
6780
|
}
|
|
6781
6781
|
function v() {
|
|
6782
|
-
const
|
|
6783
|
-
|
|
6782
|
+
const C = this.resume(), L = this.stack[this.stack.length - 1];
|
|
6783
|
+
L.value = C.replace(/^(\r?\n|\r)|(\r?\n|\r)$/g, ""), this.data.flowCodeInside = void 0;
|
|
6784
6784
|
}
|
|
6785
|
-
function
|
|
6786
|
-
const
|
|
6787
|
-
|
|
6785
|
+
function w() {
|
|
6786
|
+
const C = this.resume(), L = this.stack[this.stack.length - 1];
|
|
6787
|
+
L.value = C.replace(/(\r?\n|\r)$/g, "");
|
|
6788
6788
|
}
|
|
6789
|
-
function _(
|
|
6790
|
-
const
|
|
6791
|
-
V.label =
|
|
6789
|
+
function _(C) {
|
|
6790
|
+
const L = this.resume(), V = this.stack[this.stack.length - 1];
|
|
6791
|
+
V.label = L, V.identifier = De(this.sliceSerialize(C)).toLowerCase();
|
|
6792
6792
|
}
|
|
6793
|
-
function
|
|
6794
|
-
const
|
|
6795
|
-
|
|
6796
|
-
}
|
|
6797
|
-
function
|
|
6798
|
-
const
|
|
6799
|
-
|
|
6800
|
-
}
|
|
6801
|
-
function N(
|
|
6802
|
-
const
|
|
6803
|
-
if (!
|
|
6804
|
-
const V = this.sliceSerialize(
|
|
6805
|
-
|
|
6793
|
+
function S() {
|
|
6794
|
+
const C = this.resume(), L = this.stack[this.stack.length - 1];
|
|
6795
|
+
L.title = C;
|
|
6796
|
+
}
|
|
6797
|
+
function O() {
|
|
6798
|
+
const C = this.resume(), L = this.stack[this.stack.length - 1];
|
|
6799
|
+
L.url = C;
|
|
6800
|
+
}
|
|
6801
|
+
function N(C) {
|
|
6802
|
+
const L = this.stack[this.stack.length - 1];
|
|
6803
|
+
if (!L.depth) {
|
|
6804
|
+
const V = this.sliceSerialize(C).length;
|
|
6805
|
+
L.depth = V;
|
|
6806
6806
|
}
|
|
6807
6807
|
}
|
|
6808
|
-
function
|
|
6808
|
+
function k() {
|
|
6809
6809
|
this.data.setextHeadingSlurpLineEnding = !0;
|
|
6810
6810
|
}
|
|
6811
|
-
function
|
|
6812
|
-
const
|
|
6813
|
-
|
|
6811
|
+
function z(C) {
|
|
6812
|
+
const L = this.stack[this.stack.length - 1];
|
|
6813
|
+
L.depth = this.sliceSerialize(C).codePointAt(0) === 61 ? 1 : 2;
|
|
6814
6814
|
}
|
|
6815
6815
|
function P() {
|
|
6816
6816
|
this.data.setextHeadingSlurpLineEnding = void 0;
|
|
6817
6817
|
}
|
|
6818
|
-
function
|
|
6818
|
+
function M(C) {
|
|
6819
6819
|
const V = this.stack[this.stack.length - 1].children;
|
|
6820
6820
|
let K = V[V.length - 1];
|
|
6821
6821
|
(!K || K.type !== "text") && (K = il(), K.position = {
|
|
6822
|
-
start: Ve(
|
|
6822
|
+
start: Ve(C.start),
|
|
6823
6823
|
// @ts-expect-error: we’ll add `end` later.
|
|
6824
6824
|
end: void 0
|
|
6825
6825
|
}, V.push(K)), this.stack.push(K);
|
|
6826
6826
|
}
|
|
6827
|
-
function x(
|
|
6828
|
-
const
|
|
6829
|
-
|
|
6827
|
+
function x(C) {
|
|
6828
|
+
const L = this.stack.pop();
|
|
6829
|
+
L.value += this.sliceSerialize(C), L.position.end = Ve(C.end);
|
|
6830
6830
|
}
|
|
6831
|
-
function C
|
|
6832
|
-
const
|
|
6831
|
+
function E(C) {
|
|
6832
|
+
const L = this.stack[this.stack.length - 1];
|
|
6833
6833
|
if (this.data.atHardBreak) {
|
|
6834
|
-
const V =
|
|
6835
|
-
V.position.end = Ve(
|
|
6834
|
+
const V = L.children[L.children.length - 1];
|
|
6835
|
+
V.position.end = Ve(C.end), this.data.atHardBreak = void 0;
|
|
6836
6836
|
return;
|
|
6837
6837
|
}
|
|
6838
|
-
!this.data.setextHeadingSlurpLineEnding && t.canContainEols.includes(
|
|
6838
|
+
!this.data.setextHeadingSlurpLineEnding && t.canContainEols.includes(L.type) && (M.call(this, C), x.call(this, C));
|
|
6839
6839
|
}
|
|
6840
6840
|
function I() {
|
|
6841
6841
|
this.data.atHardBreak = !0;
|
|
6842
6842
|
}
|
|
6843
6843
|
function D() {
|
|
6844
|
-
const
|
|
6845
|
-
|
|
6844
|
+
const C = this.resume(), L = this.stack[this.stack.length - 1];
|
|
6845
|
+
L.value = C;
|
|
6846
6846
|
}
|
|
6847
6847
|
function R() {
|
|
6848
|
-
const
|
|
6849
|
-
|
|
6848
|
+
const C = this.resume(), L = this.stack[this.stack.length - 1];
|
|
6849
|
+
L.value = C;
|
|
6850
6850
|
}
|
|
6851
6851
|
function A() {
|
|
6852
|
-
const
|
|
6853
|
-
|
|
6852
|
+
const C = this.resume(), L = this.stack[this.stack.length - 1];
|
|
6853
|
+
L.value = C;
|
|
6854
6854
|
}
|
|
6855
6855
|
function U() {
|
|
6856
|
-
const
|
|
6856
|
+
const C = this.stack[this.stack.length - 1];
|
|
6857
6857
|
if (this.data.inReference) {
|
|
6858
|
-
const
|
|
6859
|
-
|
|
6858
|
+
const L = this.data.referenceType || "shortcut";
|
|
6859
|
+
C.type += "Reference", C.referenceType = L, delete C.url, delete C.title;
|
|
6860
6860
|
} else
|
|
6861
|
-
delete
|
|
6861
|
+
delete C.identifier, delete C.label;
|
|
6862
6862
|
this.data.referenceType = void 0;
|
|
6863
6863
|
}
|
|
6864
6864
|
function q() {
|
|
6865
|
-
const
|
|
6865
|
+
const C = this.stack[this.stack.length - 1];
|
|
6866
6866
|
if (this.data.inReference) {
|
|
6867
|
-
const
|
|
6868
|
-
|
|
6867
|
+
const L = this.data.referenceType || "shortcut";
|
|
6868
|
+
C.type += "Reference", C.referenceType = L, delete C.url, delete C.title;
|
|
6869
6869
|
} else
|
|
6870
|
-
delete
|
|
6870
|
+
delete C.identifier, delete C.label;
|
|
6871
6871
|
this.data.referenceType = void 0;
|
|
6872
6872
|
}
|
|
6873
|
-
function H(
|
|
6874
|
-
const
|
|
6875
|
-
V.label = Nf(
|
|
6873
|
+
function H(C) {
|
|
6874
|
+
const L = this.sliceSerialize(C), V = this.stack[this.stack.length - 2];
|
|
6875
|
+
V.label = Nf(L), V.identifier = De(L).toLowerCase();
|
|
6876
6876
|
}
|
|
6877
6877
|
function ne() {
|
|
6878
|
-
const
|
|
6878
|
+
const C = this.stack[this.stack.length - 1], L = this.resume(), V = this.stack[this.stack.length - 1];
|
|
6879
6879
|
if (this.data.inReference = !0, V.type === "link") {
|
|
6880
|
-
const K =
|
|
6880
|
+
const K = C.children;
|
|
6881
6881
|
V.children = K;
|
|
6882
6882
|
} else
|
|
6883
|
-
V.alt =
|
|
6883
|
+
V.alt = L;
|
|
6884
6884
|
}
|
|
6885
6885
|
function m() {
|
|
6886
|
-
const
|
|
6887
|
-
|
|
6886
|
+
const C = this.resume(), L = this.stack[this.stack.length - 1];
|
|
6887
|
+
L.url = C;
|
|
6888
6888
|
}
|
|
6889
6889
|
function ae() {
|
|
6890
|
-
const
|
|
6891
|
-
|
|
6890
|
+
const C = this.resume(), L = this.stack[this.stack.length - 1];
|
|
6891
|
+
L.title = C;
|
|
6892
6892
|
}
|
|
6893
6893
|
function Ne() {
|
|
6894
6894
|
this.data.inReference = void 0;
|
|
@@ -6896,33 +6896,33 @@ function Lf(e) {
|
|
|
6896
6896
|
function g() {
|
|
6897
6897
|
this.data.referenceType = "collapsed";
|
|
6898
6898
|
}
|
|
6899
|
-
function J(
|
|
6900
|
-
const
|
|
6901
|
-
V.label =
|
|
6899
|
+
function J(C) {
|
|
6900
|
+
const L = this.resume(), V = this.stack[this.stack.length - 1];
|
|
6901
|
+
V.label = L, V.identifier = De(this.sliceSerialize(C)).toLowerCase(), this.data.referenceType = "full";
|
|
6902
6902
|
}
|
|
6903
|
-
function me(
|
|
6904
|
-
this.data.characterReferenceType =
|
|
6903
|
+
function me(C) {
|
|
6904
|
+
this.data.characterReferenceType = C.type;
|
|
6905
6905
|
}
|
|
6906
|
-
function se(
|
|
6907
|
-
const
|
|
6906
|
+
function se(C) {
|
|
6907
|
+
const L = this.sliceSerialize(C), V = this.data.characterReferenceType;
|
|
6908
6908
|
let K;
|
|
6909
|
-
V ? (K = ga(
|
|
6909
|
+
V ? (K = ga(L, V === "characterReferenceMarkerNumeric" ? 10 : 16), this.data.characterReferenceType = void 0) : K = Rr(L);
|
|
6910
6910
|
const X = this.stack[this.stack.length - 1];
|
|
6911
6911
|
X.value += K;
|
|
6912
6912
|
}
|
|
6913
|
-
function Ke(
|
|
6914
|
-
const
|
|
6915
|
-
|
|
6913
|
+
function Ke(C) {
|
|
6914
|
+
const L = this.stack.pop();
|
|
6915
|
+
L.position.end = Ve(C.end);
|
|
6916
6916
|
}
|
|
6917
|
-
function Re(
|
|
6918
|
-
x.call(this,
|
|
6919
|
-
const
|
|
6920
|
-
|
|
6917
|
+
function Re(C) {
|
|
6918
|
+
x.call(this, C);
|
|
6919
|
+
const L = this.stack[this.stack.length - 1];
|
|
6920
|
+
L.url = this.sliceSerialize(C);
|
|
6921
6921
|
}
|
|
6922
|
-
function qe(
|
|
6923
|
-
x.call(this,
|
|
6924
|
-
const
|
|
6925
|
-
|
|
6922
|
+
function qe(C) {
|
|
6923
|
+
x.call(this, C);
|
|
6924
|
+
const L = this.stack[this.stack.length - 1];
|
|
6925
|
+
L.url = "mailto:" + this.sliceSerialize(C);
|
|
6926
6926
|
}
|
|
6927
6927
|
function rt() {
|
|
6928
6928
|
return {
|
|
@@ -6994,19 +6994,19 @@ function Lf(e) {
|
|
|
6994
6994
|
children: []
|
|
6995
6995
|
};
|
|
6996
6996
|
}
|
|
6997
|
-
function ai(
|
|
6997
|
+
function ai(C) {
|
|
6998
6998
|
return {
|
|
6999
6999
|
type: "list",
|
|
7000
|
-
ordered:
|
|
7000
|
+
ordered: C.type === "listOrdered",
|
|
7001
7001
|
start: null,
|
|
7002
|
-
spread:
|
|
7002
|
+
spread: C._spread,
|
|
7003
7003
|
children: []
|
|
7004
7004
|
};
|
|
7005
7005
|
}
|
|
7006
|
-
function tl(
|
|
7006
|
+
function tl(C) {
|
|
7007
7007
|
return {
|
|
7008
7008
|
type: "listItem",
|
|
7009
|
-
spread:
|
|
7009
|
+
spread: C._spread,
|
|
7010
7010
|
checked: null,
|
|
7011
7011
|
children: []
|
|
7012
7012
|
};
|
|
@@ -7658,13 +7658,13 @@ function hd(e) {
|
|
|
7658
7658
|
_ && _.type === "text" ? _.value += " " : v.children.push({ type: "text", value: " " }), v.children.push(...h);
|
|
7659
7659
|
} else
|
|
7660
7660
|
u.push(...h);
|
|
7661
|
-
const
|
|
7661
|
+
const w = {
|
|
7662
7662
|
type: "element",
|
|
7663
7663
|
tagName: "li",
|
|
7664
7664
|
properties: { id: t + "fn-" + p },
|
|
7665
7665
|
children: e.wrap(u, !0)
|
|
7666
7666
|
};
|
|
7667
|
-
e.patch(c,
|
|
7667
|
+
e.patch(c, w), s.push(w);
|
|
7668
7668
|
}
|
|
7669
7669
|
if (s.length !== 0)
|
|
7670
7670
|
return {
|
|
@@ -7811,13 +7811,13 @@ function Da(e, t, n, r) {
|
|
|
7811
7811
|
if ((!t || o(l, c, u[u.length - 1] || void 0)) && (d = kd(n(l, u)), d[0] === nr))
|
|
7812
7812
|
return d;
|
|
7813
7813
|
if ("children" in l && l.children) {
|
|
7814
|
-
const
|
|
7814
|
+
const w = (
|
|
7815
7815
|
/** @type {UnistParent} */
|
|
7816
7816
|
l
|
|
7817
7817
|
);
|
|
7818
|
-
if (
|
|
7819
|
-
for (b = (r ?
|
|
7820
|
-
const _ =
|
|
7818
|
+
if (w.children && d[0] !== vd)
|
|
7819
|
+
for (b = (r ? w.children.length : -1) + a, v = u.concat(w); b > -1 && b < w.children.length; ) {
|
|
7820
|
+
const _ = w.children[b];
|
|
7821
7821
|
if (h = s(_, b, v)(), h[0] === nr)
|
|
7822
7822
|
return h;
|
|
7823
7823
|
b = typeof h[1] == "number" ? h[1] : b + a;
|
|
@@ -7865,8 +7865,8 @@ function Ed(e, t) {
|
|
|
7865
7865
|
return d(s, u, f);
|
|
7866
7866
|
if (s.options.passThrough && s.options.passThrough.includes(p)) {
|
|
7867
7867
|
if ("children" in u) {
|
|
7868
|
-
const { children: b, ...v } = u,
|
|
7869
|
-
return
|
|
7868
|
+
const { children: b, ...v } = u, w = Dt(v);
|
|
7869
|
+
return w.children = s.all(u), w;
|
|
7870
7870
|
}
|
|
7871
7871
|
return Dt(u);
|
|
7872
7872
|
}
|
|
@@ -7989,8 +7989,8 @@ function Nd() {
|
|
|
7989
7989
|
return c[u];
|
|
7990
7990
|
};
|
|
7991
7991
|
return Tn = function l() {
|
|
7992
|
-
var c, u, f, p, d, h, b = arguments[0], v = 1,
|
|
7993
|
-
for (typeof b == "boolean" && (_ = b, b = arguments[1] || {}, v = 2), (b == null || typeof b != "object" && typeof b != "function") && (b = {}); v <
|
|
7992
|
+
var c, u, f, p, d, h, b = arguments[0], v = 1, w = arguments.length, _ = !1;
|
|
7993
|
+
for (typeof b == "boolean" && (_ = b, b = arguments[1] || {}, v = 2), (b == null || typeof b != "object" && typeof b != "function") && (b = {}); v < w; ++v)
|
|
7994
7994
|
if (c = arguments[v], c != null)
|
|
7995
7995
|
for (u in c)
|
|
7996
7996
|
f = s(b, u), p = s(c, u), b !== p && (_ && p && (o(p) || (d = i(p))) ? (d ? (d = !1, h = f && i(f) ? f : []) : h = f && o(f) ? f : {}, a(b, { name: u, newValue: l(_, h, p) })) : typeof p < "u" && a(b, { name: u, newValue: p }));
|
|
@@ -9206,7 +9206,7 @@ function rp(e, t) {
|
|
|
9206
9206
|
Fragment: We,
|
|
9207
9207
|
components: i,
|
|
9208
9208
|
ignoreInvalidStyle: !0,
|
|
9209
|
-
jsx:
|
|
9209
|
+
jsx: y,
|
|
9210
9210
|
jsxs: B,
|
|
9211
9211
|
passKeys: !0,
|
|
9212
9212
|
passNode: !0
|
|
@@ -9662,24 +9662,24 @@ function gp(e, t, n) {
|
|
|
9662
9662
|
const f = u[u.length - 1], p = o[a][0], d = o[a][1];
|
|
9663
9663
|
let h = 0;
|
|
9664
9664
|
const v = f.children.indexOf(c);
|
|
9665
|
-
let
|
|
9665
|
+
let w = !1, _ = [];
|
|
9666
9666
|
p.lastIndex = 0;
|
|
9667
|
-
let
|
|
9668
|
-
for (;
|
|
9669
|
-
const
|
|
9670
|
-
index:
|
|
9671
|
-
input:
|
|
9667
|
+
let S = p.exec(c.value);
|
|
9668
|
+
for (; S; ) {
|
|
9669
|
+
const O = S.index, N = {
|
|
9670
|
+
index: S.index,
|
|
9671
|
+
input: S.input,
|
|
9672
9672
|
stack: [...u, c]
|
|
9673
9673
|
};
|
|
9674
|
-
let
|
|
9675
|
-
if (typeof
|
|
9674
|
+
let k = d(...S, N);
|
|
9675
|
+
if (typeof k == "string" && (k = k.length > 0 ? { type: "text", value: k } : void 0), k === !1 ? p.lastIndex = O + 1 : (h !== O && _.push({
|
|
9676
9676
|
type: "text",
|
|
9677
|
-
value: c.value.slice(h,
|
|
9678
|
-
}), Array.isArray(
|
|
9677
|
+
value: c.value.slice(h, O)
|
|
9678
|
+
}), Array.isArray(k) ? _.push(...k) : k && _.push(k), h = O + S[0].length, w = !0), !p.global)
|
|
9679
9679
|
break;
|
|
9680
|
-
|
|
9680
|
+
S = p.exec(c.value);
|
|
9681
9681
|
}
|
|
9682
|
-
return
|
|
9682
|
+
return w ? (h < c.value.length && _.push({ type: "text", value: c.value.slice(h) }), f.children.splice(v, 1, ..._)) : _ = [c], v + _.length;
|
|
9683
9683
|
}
|
|
9684
9684
|
}
|
|
9685
9685
|
function bp(e) {
|
|
@@ -9967,12 +9967,12 @@ function Qp(e, t) {
|
|
|
9967
9967
|
let c = 0, u = -1;
|
|
9968
9968
|
for (; ++u < e.length; ) {
|
|
9969
9969
|
const b = [], v = [];
|
|
9970
|
-
let
|
|
9971
|
-
for (e[u].length > c && (c = e[u].length); ++
|
|
9972
|
-
const _ = Xp(e[u][
|
|
9970
|
+
let w = -1;
|
|
9971
|
+
for (e[u].length > c && (c = e[u].length); ++w < e[u].length; ) {
|
|
9972
|
+
const _ = Xp(e[u][w]);
|
|
9973
9973
|
if (n.alignDelimiters !== !1) {
|
|
9974
|
-
const
|
|
9975
|
-
v[
|
|
9974
|
+
const S = i(_);
|
|
9975
|
+
v[w] = S, (l[w] === void 0 || S > l[w]) && (l[w] = S);
|
|
9976
9976
|
}
|
|
9977
9977
|
b.push(_);
|
|
9978
9978
|
}
|
|
@@ -9991,34 +9991,34 @@ function Qp(e, t) {
|
|
|
9991
9991
|
const p = [], d = [];
|
|
9992
9992
|
for (; ++f < c; ) {
|
|
9993
9993
|
const b = o[f];
|
|
9994
|
-
let v = "",
|
|
9995
|
-
b === 99 ? (v = ":",
|
|
9994
|
+
let v = "", w = "";
|
|
9995
|
+
b === 99 ? (v = ":", w = ":") : b === 108 ? v = ":" : b === 114 && (w = ":");
|
|
9996
9996
|
let _ = n.alignDelimiters === !1 ? 1 : Math.max(
|
|
9997
9997
|
1,
|
|
9998
|
-
l[f] - v.length -
|
|
9998
|
+
l[f] - v.length - w.length
|
|
9999
9999
|
);
|
|
10000
|
-
const
|
|
10001
|
-
n.alignDelimiters !== !1 && (_ = v.length + _ +
|
|
10000
|
+
const S = v + "-".repeat(_) + w;
|
|
10001
|
+
n.alignDelimiters !== !1 && (_ = v.length + _ + w.length, _ > l[f] && (l[f] = _), d[f] = _), p[f] = S;
|
|
10002
10002
|
}
|
|
10003
10003
|
a.splice(1, 0, p), s.splice(1, 0, d), u = -1;
|
|
10004
10004
|
const h = [];
|
|
10005
10005
|
for (; ++u < a.length; ) {
|
|
10006
10006
|
const b = a[u], v = s[u];
|
|
10007
10007
|
f = -1;
|
|
10008
|
-
const
|
|
10008
|
+
const w = [];
|
|
10009
10009
|
for (; ++f < c; ) {
|
|
10010
10010
|
const _ = b[f] || "";
|
|
10011
|
-
let
|
|
10011
|
+
let S = "", O = "";
|
|
10012
10012
|
if (n.alignDelimiters !== !1) {
|
|
10013
|
-
const N = l[f] - (v[f] || 0),
|
|
10014
|
-
|
|
10013
|
+
const N = l[f] - (v[f] || 0), k = o[f];
|
|
10014
|
+
k === 114 ? S = " ".repeat(N) : k === 99 ? N % 2 ? (S = " ".repeat(N / 2 + 0.5), O = " ".repeat(N / 2 - 0.5)) : (S = " ".repeat(N / 2), O = S) : O = " ".repeat(N);
|
|
10015
10015
|
}
|
|
10016
|
-
n.delimiterStart !== !1 && !f &&
|
|
10016
|
+
n.delimiterStart !== !1 && !f && w.push("|"), n.padding !== !1 && // Don’t add the opening space if we’re not aligning and the cell is
|
|
10017
10017
|
// empty: there will be a closing space.
|
|
10018
|
-
!(n.alignDelimiters === !1 && _ === "") && (n.delimiterStart !== !1 || f) &&
|
|
10018
|
+
!(n.alignDelimiters === !1 && _ === "") && (n.delimiterStart !== !1 || f) && w.push(" "), n.alignDelimiters !== !1 && w.push(S), w.push(_), n.alignDelimiters !== !1 && w.push(O), n.padding !== !1 && w.push(" "), (n.delimiterEnd !== !1 || f !== c - 1) && w.push("|");
|
|
10019
10019
|
}
|
|
10020
10020
|
h.push(
|
|
10021
|
-
n.delimiterEnd === !1 ?
|
|
10021
|
+
n.delimiterEnd === !1 ? w.join("").replace(/ +$/, "") : w.join("")
|
|
10022
10022
|
);
|
|
10023
10023
|
}
|
|
10024
10024
|
return h.join(`
|
|
@@ -10711,17 +10711,17 @@ function zh(e) {
|
|
|
10711
10711
|
return c(u(d, b, v), d.align);
|
|
10712
10712
|
}
|
|
10713
10713
|
function s(d, h, b, v) {
|
|
10714
|
-
const
|
|
10714
|
+
const w = f(d, b, v), _ = c([w]);
|
|
10715
10715
|
return _.slice(0, _.indexOf(`
|
|
10716
10716
|
`));
|
|
10717
10717
|
}
|
|
10718
10718
|
function l(d, h, b, v) {
|
|
10719
|
-
const
|
|
10719
|
+
const w = b.enter("tableCell"), _ = b.enter("phrasing"), S = b.containerPhrasing(d, {
|
|
10720
10720
|
...v,
|
|
10721
10721
|
before: o,
|
|
10722
10722
|
after: o
|
|
10723
10723
|
});
|
|
10724
|
-
return _(),
|
|
10724
|
+
return _(), w(), S;
|
|
10725
10725
|
}
|
|
10726
10726
|
function c(d, h) {
|
|
10727
10727
|
return Qp(d, {
|
|
@@ -10736,19 +10736,19 @@ function zh(e) {
|
|
|
10736
10736
|
}
|
|
10737
10737
|
function u(d, h, b) {
|
|
10738
10738
|
const v = d.children;
|
|
10739
|
-
let
|
|
10740
|
-
const _ = [],
|
|
10741
|
-
for (; ++
|
|
10742
|
-
_[
|
|
10743
|
-
return
|
|
10739
|
+
let w = -1;
|
|
10740
|
+
const _ = [], S = h.enter("table");
|
|
10741
|
+
for (; ++w < v.length; )
|
|
10742
|
+
_[w] = f(v[w], h, b);
|
|
10743
|
+
return S(), _;
|
|
10744
10744
|
}
|
|
10745
10745
|
function f(d, h, b) {
|
|
10746
10746
|
const v = d.children;
|
|
10747
|
-
let
|
|
10748
|
-
const _ = [],
|
|
10749
|
-
for (; ++
|
|
10750
|
-
_[
|
|
10751
|
-
return
|
|
10747
|
+
let w = -1;
|
|
10748
|
+
const _ = [], S = h.enter("tableRow");
|
|
10749
|
+
for (; ++w < v.length; )
|
|
10750
|
+
_[w] = l(v[w], d, h, b);
|
|
10751
|
+
return S(), _;
|
|
10752
10752
|
}
|
|
10753
10753
|
function p(d, h, b) {
|
|
10754
10754
|
let v = Za.inlineCode(d, h, b);
|
|
@@ -11257,8 +11257,8 @@ function um(e) {
|
|
|
11257
11257
|
if (h === 126)
|
|
11258
11258
|
return f > 1 ? l(h) : (a.consume(h), f++, d);
|
|
11259
11259
|
if (f < 2 && !n) return l(h);
|
|
11260
|
-
const v = a.exit("strikethroughSequenceTemporary"),
|
|
11261
|
-
return v._open = !
|
|
11260
|
+
const v = a.exit("strikethroughSequenceTemporary"), w = dt(h);
|
|
11261
|
+
return v._open = !w || w === 2 && !!b, v._close = !b || b === 2 && !!w, s(h);
|
|
11262
11262
|
}
|
|
11263
11263
|
}
|
|
11264
11264
|
}
|
|
@@ -11366,15 +11366,15 @@ function mm(e, t, n) {
|
|
|
11366
11366
|
let i = 0, o = 0, a;
|
|
11367
11367
|
return s;
|
|
11368
11368
|
function s(x) {
|
|
11369
|
-
let
|
|
11370
|
-
for (;
|
|
11371
|
-
const R = r.events[
|
|
11369
|
+
let E = r.events.length - 1;
|
|
11370
|
+
for (; E > -1; ) {
|
|
11371
|
+
const R = r.events[E][1].type;
|
|
11372
11372
|
if (R === "lineEnding" || // Note: markdown-rs uses `whitespace` instead of `linePrefix`
|
|
11373
|
-
R === "linePrefix")
|
|
11373
|
+
R === "linePrefix") E--;
|
|
11374
11374
|
else break;
|
|
11375
11375
|
}
|
|
11376
|
-
const I =
|
|
11377
|
-
return D ===
|
|
11376
|
+
const I = E > -1 ? r.events[E][1].type : null, D = I === "tableHead" || I === "tableRow" ? k : l;
|
|
11377
|
+
return D === k && r.parser.lazy[r.now().line] ? n(x) : D(x);
|
|
11378
11378
|
}
|
|
11379
11379
|
function l(x) {
|
|
11380
11380
|
return e.enter("tableHead"), e.enter("tableRow"), c(x);
|
|
@@ -11401,33 +11401,33 @@ function mm(e, t, n) {
|
|
|
11401
11401
|
return G(x) ? Y(e, v, "whitespace")(x) : v(x);
|
|
11402
11402
|
}
|
|
11403
11403
|
function v(x) {
|
|
11404
|
-
return x === 58 ? (o += 1, a = !0, e.enter("tableDelimiterMarker"), e.consume(x), e.exit("tableDelimiterMarker"),
|
|
11404
|
+
return x === 58 ? (o += 1, a = !0, e.enter("tableDelimiterMarker"), e.consume(x), e.exit("tableDelimiterMarker"), w) : x === 45 ? (o += 1, w(x)) : x === null || F(x) ? O(x) : N(x);
|
|
11405
11405
|
}
|
|
11406
|
-
function
|
|
11406
|
+
function w(x) {
|
|
11407
11407
|
return x === 45 ? (e.enter("tableDelimiterFiller"), _(x)) : N(x);
|
|
11408
11408
|
}
|
|
11409
11409
|
function _(x) {
|
|
11410
|
-
return x === 45 ? (e.consume(x), _) : x === 58 ? (a = !0, e.exit("tableDelimiterFiller"), e.enter("tableDelimiterMarker"), e.consume(x), e.exit("tableDelimiterMarker"),
|
|
11410
|
+
return x === 45 ? (e.consume(x), _) : x === 58 ? (a = !0, e.exit("tableDelimiterFiller"), e.enter("tableDelimiterMarker"), e.consume(x), e.exit("tableDelimiterMarker"), S) : (e.exit("tableDelimiterFiller"), S(x));
|
|
11411
11411
|
}
|
|
11412
|
-
function
|
|
11413
|
-
return G(x) ? Y(e,
|
|
11412
|
+
function S(x) {
|
|
11413
|
+
return G(x) ? Y(e, O, "whitespace")(x) : O(x);
|
|
11414
11414
|
}
|
|
11415
|
-
function
|
|
11415
|
+
function O(x) {
|
|
11416
11416
|
return x === 124 ? h(x) : x === null || F(x) ? !a || i !== o ? N(x) : (e.exit("tableDelimiterRow"), e.exit("tableHead"), t(x)) : N(x);
|
|
11417
11417
|
}
|
|
11418
11418
|
function N(x) {
|
|
11419
11419
|
return n(x);
|
|
11420
11420
|
}
|
|
11421
|
-
function
|
|
11422
|
-
return e.enter("tableRow"),
|
|
11421
|
+
function k(x) {
|
|
11422
|
+
return e.enter("tableRow"), z(x);
|
|
11423
11423
|
}
|
|
11424
|
-
function
|
|
11425
|
-
return x === 124 ? (e.enter("tableCellDivider"), e.consume(x), e.exit("tableCellDivider"),
|
|
11424
|
+
function z(x) {
|
|
11425
|
+
return x === 124 ? (e.enter("tableCellDivider"), e.consume(x), e.exit("tableCellDivider"), z) : x === null || F(x) ? (e.exit("tableRow"), t(x)) : G(x) ? Y(e, z, "whitespace")(x) : (e.enter("data"), P(x));
|
|
11426
11426
|
}
|
|
11427
11427
|
function P(x) {
|
|
11428
|
-
return x === null || x === 124 || Z(x) ? (e.exit("data"),
|
|
11428
|
+
return x === null || x === 124 || Z(x) ? (e.exit("data"), z(x)) : (e.consume(x), x === 92 ? M : P);
|
|
11429
11429
|
}
|
|
11430
|
-
function
|
|
11430
|
+
function M(x) {
|
|
11431
11431
|
return x === 92 || x === 124 ? (e.consume(x), P) : P(x);
|
|
11432
11432
|
}
|
|
11433
11433
|
}
|
|
@@ -11545,16 +11545,16 @@ function Sm(e) {
|
|
|
11545
11545
|
), n = e || km, r = t.data(), i = r.micromarkExtensions || (r.micromarkExtensions = []), o = r.fromMarkdownExtensions || (r.fromMarkdownExtensions = []), a = r.toMarkdownExtensions || (r.toMarkdownExtensions = []);
|
|
11546
11546
|
i.push(vm(n)), o.push(jh()), a.push(Hh(n));
|
|
11547
11547
|
}
|
|
11548
|
-
const Em = ({ text: e }) => /* @__PURE__ */
|
|
11548
|
+
const Em = ({ text: e }) => /* @__PURE__ */ y(
|
|
11549
11549
|
ep,
|
|
11550
11550
|
{
|
|
11551
11551
|
remarkPlugins: [Sm],
|
|
11552
11552
|
rehypePlugins: [hp],
|
|
11553
11553
|
components: {
|
|
11554
|
-
p: ({ children: n }) => /* @__PURE__ */
|
|
11555
|
-
ul: ({ children: n }) => /* @__PURE__ */
|
|
11556
|
-
ol: ({ children: n }) => /* @__PURE__ */
|
|
11557
|
-
a: ({ children: n, href: r }) => /* @__PURE__ */
|
|
11554
|
+
p: ({ children: n }) => /* @__PURE__ */ y("p", { className: "mb-3 last:mb-0 whitespace-pre-wrap", children: n }),
|
|
11555
|
+
ul: ({ children: n }) => /* @__PURE__ */ y("ul", { className: "list-disc ml-5 mb-3 space-y-1", children: n }),
|
|
11556
|
+
ol: ({ children: n }) => /* @__PURE__ */ y("ol", { className: "list-decimal ml-5 mb-3 space-y-1", children: n }),
|
|
11557
|
+
a: ({ children: n, href: r }) => /* @__PURE__ */ y(
|
|
11558
11558
|
"a",
|
|
11559
11559
|
{
|
|
11560
11560
|
href: r || "#",
|
|
@@ -11564,28 +11564,28 @@ const Em = ({ text: e }) => /* @__PURE__ */ w(
|
|
|
11564
11564
|
children: n
|
|
11565
11565
|
}
|
|
11566
11566
|
),
|
|
11567
|
-
blockquote: ({ children: n }) => /* @__PURE__ */
|
|
11567
|
+
blockquote: ({ children: n }) => /* @__PURE__ */ y("blockquote", { className: "border-l-4 pl-3 italic text-gray-600 my-2", children: n })
|
|
11568
11568
|
},
|
|
11569
11569
|
children: e
|
|
11570
11570
|
}
|
|
11571
11571
|
);
|
|
11572
11572
|
function Cm() {
|
|
11573
|
-
return /* @__PURE__ */
|
|
11574
|
-
/* @__PURE__ */
|
|
11573
|
+
return /* @__PURE__ */ y("div", { className: "bg-gray-100 rounded-2xl px-[12px] py-[10px]", children: /* @__PURE__ */ B("div", { className: "flex space-x-1", children: [
|
|
11574
|
+
/* @__PURE__ */ y(
|
|
11575
11575
|
"div",
|
|
11576
11576
|
{
|
|
11577
11577
|
className: "w-[7px] h-[7px] bg-gray-400 rounded-full animate-bounce",
|
|
11578
11578
|
style: { animationDelay: "0ms" }
|
|
11579
11579
|
}
|
|
11580
11580
|
),
|
|
11581
|
-
/* @__PURE__ */
|
|
11581
|
+
/* @__PURE__ */ y(
|
|
11582
11582
|
"div",
|
|
11583
11583
|
{
|
|
11584
11584
|
className: "w-[7px] h-[7px] bg-gray-400 rounded-full animate-bounce",
|
|
11585
11585
|
style: { animationDelay: "150ms" }
|
|
11586
11586
|
}
|
|
11587
11587
|
),
|
|
11588
|
-
/* @__PURE__ */
|
|
11588
|
+
/* @__PURE__ */ y(
|
|
11589
11589
|
"div",
|
|
11590
11590
|
{
|
|
11591
11591
|
className: "w-[7px] h-[7px] bg-gray-400 rounded-full animate-bounce",
|
|
@@ -11605,23 +11605,23 @@ function eo({
|
|
|
11605
11605
|
}) {
|
|
11606
11606
|
const s = !t, [l, c] = W(!1), [u, f] = W(
|
|
11607
11607
|
null
|
|
11608
|
-
), [p, d] = W(!1), [h, b] = W(!1), v = kr(), { collectUserFeedback:
|
|
11608
|
+
), [p, d] = W(!1), [h, b] = W(!1), v = kr(), { collectUserFeedback: w, onMessageClick: _ } = mn(), S = !e.isWelcomeMessage && typeof _ == "function", O = jl(
|
|
11609
11609
|
e.content,
|
|
11610
11610
|
15,
|
|
11611
11611
|
n && s
|
|
11612
11612
|
), N = j({
|
|
11613
11613
|
[v.botBubbleColor]: e.sender === "assistant",
|
|
11614
11614
|
[v.userBubbleColor]: e.sender === "user"
|
|
11615
|
-
}),
|
|
11615
|
+
}), k = j(
|
|
11616
11616
|
"text-gray-400 hover:text-primary transition-colors"
|
|
11617
|
-
),
|
|
11617
|
+
), z = e.content === "...", P = () => n && e.isThinking ? /* @__PURE__ */ y("div", { className: "flex flex-col justify-center flex-1", children: z ? /* @__PURE__ */ y("div", { className: "ml-3", children: /* @__PURE__ */ y(Cm, {}) }) : /* @__PURE__ */ y(
|
|
11618
11618
|
"p",
|
|
11619
11619
|
{
|
|
11620
11620
|
className: j("text-left", {
|
|
11621
11621
|
"text-card-foreground ml-3": e.sender === "assistant",
|
|
11622
11622
|
"text-white mr-3": e.sender === "user"
|
|
11623
11623
|
}),
|
|
11624
|
-
children:
|
|
11624
|
+
children: O
|
|
11625
11625
|
}
|
|
11626
11626
|
) }) : /* @__PURE__ */ B(
|
|
11627
11627
|
"div",
|
|
@@ -11631,7 +11631,7 @@ function eo({
|
|
|
11631
11631
|
role: _ && !e.isWelcomeMessage ? "button" : void 0,
|
|
11632
11632
|
tabIndex: 0,
|
|
11633
11633
|
children: [
|
|
11634
|
-
!r && a && /* @__PURE__ */
|
|
11634
|
+
!r && a && /* @__PURE__ */ y(
|
|
11635
11635
|
"svg",
|
|
11636
11636
|
{
|
|
11637
11637
|
className: j("absolute bottom-1 right-0 h-4 w-4", {
|
|
@@ -11640,10 +11640,10 @@ function eo({
|
|
|
11640
11640
|
}),
|
|
11641
11641
|
viewBox: "0 0 10.54 11.14",
|
|
11642
11642
|
fill: N,
|
|
11643
|
-
children: /* @__PURE__ */
|
|
11643
|
+
children: /* @__PURE__ */ y("path", { d: "M5.75,0s0,.36,0,.51c-.09,4.52-5.74,10.64-5.74,10.64,8.19.02,10.54-2.26,10.54-2.26h0c-1.6-2.96-3.19-5.92-4.79-8.88Z" })
|
|
11644
11644
|
}
|
|
11645
11645
|
),
|
|
11646
|
-
/* @__PURE__ */
|
|
11646
|
+
/* @__PURE__ */ y(
|
|
11647
11647
|
"div",
|
|
11648
11648
|
{
|
|
11649
11649
|
className: j("relative rounded-lg px-3 py-3 min-h-[48px]", {
|
|
@@ -11655,7 +11655,7 @@ function eo({
|
|
|
11655
11655
|
style: {
|
|
11656
11656
|
backgroundColor: N
|
|
11657
11657
|
},
|
|
11658
|
-
children: e.type === "image" ? /* @__PURE__ */
|
|
11658
|
+
children: e.type === "image" ? /* @__PURE__ */ y(
|
|
11659
11659
|
"img",
|
|
11660
11660
|
{
|
|
11661
11661
|
src: e.content,
|
|
@@ -11663,7 +11663,7 @@ function eo({
|
|
|
11663
11663
|
className: "max-w-full rounded-lg cursor-pointer hover:opacity-90 transition-opacity",
|
|
11664
11664
|
onClick: () => c(!0)
|
|
11665
11665
|
}
|
|
11666
|
-
) : /* @__PURE__ */
|
|
11666
|
+
) : /* @__PURE__ */ y("div", { className: "typewriter prose text-left wrap-anywhere", children: /* @__PURE__ */ y(Em, { text: O }) })
|
|
11667
11667
|
}
|
|
11668
11668
|
)
|
|
11669
11669
|
]
|
|
@@ -11671,13 +11671,13 @@ function eo({
|
|
|
11671
11671
|
);
|
|
11672
11672
|
return /* @__PURE__ */ B(We, { children: [
|
|
11673
11673
|
/* @__PURE__ */ B("div", { className: "flex flex-col flex-1 self-stretch", children: [
|
|
11674
|
-
/* @__PURE__ */
|
|
11674
|
+
/* @__PURE__ */ y(
|
|
11675
11675
|
"div",
|
|
11676
11676
|
{
|
|
11677
11677
|
className: j(
|
|
11678
11678
|
`flex flex-1 self-stretch ${e.sender === "user" ? "justify-end" : "justify-start"}`
|
|
11679
11679
|
),
|
|
11680
|
-
children: /* @__PURE__ */
|
|
11680
|
+
children: /* @__PURE__ */ y(
|
|
11681
11681
|
"div",
|
|
11682
11682
|
{
|
|
11683
11683
|
className: j("relative flex self-stretch", {
|
|
@@ -11690,8 +11690,8 @@ function eo({
|
|
|
11690
11690
|
)
|
|
11691
11691
|
}
|
|
11692
11692
|
),
|
|
11693
|
-
n && !e.isThinking && /* @__PURE__ */
|
|
11694
|
-
o && /* @__PURE__ */
|
|
11693
|
+
n && !e.isThinking && /* @__PURE__ */ y("div", { className: "flex items-center mt-2 space-x-4", children: /* @__PURE__ */ B(We, { children: [
|
|
11694
|
+
o && /* @__PURE__ */ y(
|
|
11695
11695
|
"p",
|
|
11696
11696
|
{
|
|
11697
11697
|
className: j("hidden text-xs", {
|
|
@@ -11708,65 +11708,65 @@ function eo({
|
|
|
11708
11708
|
}
|
|
11709
11709
|
),
|
|
11710
11710
|
n && /* @__PURE__ */ B("div", { className: "inline-flex gap-2 justify-end", children: [
|
|
11711
|
-
/* @__PURE__ */
|
|
11711
|
+
/* @__PURE__ */ y(
|
|
11712
11712
|
"button",
|
|
11713
11713
|
{
|
|
11714
11714
|
onClick: async () => {
|
|
11715
11715
|
await navigator.clipboard.writeText(e.content), d(!0), setTimeout(() => d(!1), 2e3);
|
|
11716
11716
|
},
|
|
11717
11717
|
className: j(
|
|
11718
|
-
|
|
11718
|
+
k,
|
|
11719
11719
|
p && "text-primary"
|
|
11720
11720
|
),
|
|
11721
11721
|
title: "Copy message",
|
|
11722
|
-
children: /* @__PURE__ */
|
|
11722
|
+
children: /* @__PURE__ */ y(al, { size: 16 })
|
|
11723
11723
|
}
|
|
11724
11724
|
),
|
|
11725
|
-
!e.isWelcomeMessage &&
|
|
11726
|
-
/* @__PURE__ */
|
|
11725
|
+
!e.isWelcomeMessage && w && /* @__PURE__ */ B(We, { children: [
|
|
11726
|
+
/* @__PURE__ */ y(
|
|
11727
11727
|
"button",
|
|
11728
11728
|
{
|
|
11729
11729
|
onClick: () => f(u === "up" ? null : "up"),
|
|
11730
11730
|
className: j(
|
|
11731
|
-
|
|
11731
|
+
k,
|
|
11732
11732
|
u === "up" && "text-primary"
|
|
11733
11733
|
),
|
|
11734
|
-
children: /* @__PURE__ */
|
|
11734
|
+
children: /* @__PURE__ */ y(sl, { size: 16 })
|
|
11735
11735
|
}
|
|
11736
11736
|
),
|
|
11737
|
-
/* @__PURE__ */
|
|
11737
|
+
/* @__PURE__ */ y(
|
|
11738
11738
|
"button",
|
|
11739
11739
|
{
|
|
11740
11740
|
onClick: () => f(
|
|
11741
11741
|
u === "down" ? null : "down"
|
|
11742
11742
|
),
|
|
11743
11743
|
className: j(
|
|
11744
|
-
|
|
11744
|
+
k,
|
|
11745
11745
|
u === "down" && "text-primary"
|
|
11746
11746
|
),
|
|
11747
|
-
children: /* @__PURE__ */
|
|
11747
|
+
children: /* @__PURE__ */ y(ll, { size: 16 })
|
|
11748
11748
|
}
|
|
11749
11749
|
)
|
|
11750
11750
|
] }),
|
|
11751
|
-
|
|
11751
|
+
S && /* @__PURE__ */ y(
|
|
11752
11752
|
"button",
|
|
11753
11753
|
{
|
|
11754
11754
|
onClick: () => {
|
|
11755
11755
|
_(e), b(!0), setTimeout(() => b(!1), 2e3);
|
|
11756
11756
|
},
|
|
11757
|
-
className: j(
|
|
11757
|
+
className: j(k, {
|
|
11758
11758
|
"text-primary": h
|
|
11759
11759
|
}),
|
|
11760
|
-
children: /* @__PURE__ */
|
|
11760
|
+
children: /* @__PURE__ */ y(cl, { size: 16 })
|
|
11761
11761
|
}
|
|
11762
11762
|
)
|
|
11763
11763
|
] })
|
|
11764
11764
|
] }) })
|
|
11765
11765
|
] }),
|
|
11766
|
-
/* @__PURE__ */
|
|
11767
|
-
/* @__PURE__ */
|
|
11768
|
-
/* @__PURE__ */
|
|
11769
|
-
/* @__PURE__ */
|
|
11766
|
+
/* @__PURE__ */ y(Nl, { open: l, onOpenChange: c, children: /* @__PURE__ */ B(Ko, { className: "max-w-[90vw] p-0 bg-transparent border-0", children: [
|
|
11767
|
+
/* @__PURE__ */ y(Yo, { className: "hidden" }),
|
|
11768
|
+
/* @__PURE__ */ y(Jo, { className: "hidden" }),
|
|
11769
|
+
/* @__PURE__ */ y(
|
|
11770
11770
|
"img",
|
|
11771
11771
|
{
|
|
11772
11772
|
src: e.content,
|
|
@@ -11788,7 +11788,7 @@ function _m({
|
|
|
11788
11788
|
"mb-0": o && !Array.isArray(t) && t.isThinking,
|
|
11789
11789
|
"w-12 h-12": o && !Array.isArray(t) && t.isThinking
|
|
11790
11790
|
});
|
|
11791
|
-
return o ? o && !a ? r ? /* @__PURE__ */
|
|
11791
|
+
return o ? o && !a ? r ? /* @__PURE__ */ y(
|
|
11792
11792
|
hn,
|
|
11793
11793
|
{
|
|
11794
11794
|
className: c,
|
|
@@ -11796,14 +11796,14 @@ function _m({
|
|
|
11796
11796
|
fgColor: "#ffffff",
|
|
11797
11797
|
src: r
|
|
11798
11798
|
}
|
|
11799
|
-
) : /* @__PURE__ */
|
|
11799
|
+
) : /* @__PURE__ */ y(
|
|
11800
11800
|
Xo,
|
|
11801
11801
|
{
|
|
11802
11802
|
className: c,
|
|
11803
11803
|
isWaiting: !Array.isArray(t) && t.isThinking
|
|
11804
11804
|
}
|
|
11805
|
-
) : /* @__PURE__ */
|
|
11806
|
-
}, l = () => Array.isArray(t) ? t.map((c) => /* @__PURE__ */
|
|
11805
|
+
) : /* @__PURE__ */ y("div", { className: c }) : null;
|
|
11806
|
+
}, l = () => Array.isArray(t) ? t.map((c) => /* @__PURE__ */ y(
|
|
11807
11807
|
eo,
|
|
11808
11808
|
{
|
|
11809
11809
|
messageData: c,
|
|
@@ -11815,7 +11815,7 @@ function _m({
|
|
|
11815
11815
|
showTail: !1
|
|
11816
11816
|
},
|
|
11817
11817
|
c.id
|
|
11818
|
-
)) : /* @__PURE__ */
|
|
11818
|
+
)) : /* @__PURE__ */ y(
|
|
11819
11819
|
eo,
|
|
11820
11820
|
{
|
|
11821
11821
|
messageData: t,
|
|
@@ -11825,7 +11825,7 @@ function _m({
|
|
|
11825
11825
|
},
|
|
11826
11826
|
t.id
|
|
11827
11827
|
);
|
|
11828
|
-
return /* @__PURE__ */
|
|
11828
|
+
return /* @__PURE__ */ y("div", { children: /* @__PURE__ */ B(
|
|
11829
11829
|
"div",
|
|
11830
11830
|
{
|
|
11831
11831
|
className: j(e, {
|
|
@@ -11845,9 +11845,9 @@ function Am(e) {
|
|
|
11845
11845
|
o(!1);
|
|
11846
11846
|
}, [n]);
|
|
11847
11847
|
const a = !n || i;
|
|
11848
|
-
return /* @__PURE__ */
|
|
11849
|
-
/* @__PURE__ */
|
|
11850
|
-
/* @__PURE__ */
|
|
11848
|
+
return /* @__PURE__ */ y("div", { className: j("w-full h-full", t), ...r, children: a ? /* @__PURE__ */ B("svg", { viewBox: "0 0 80 80", fill: "none", xmlns: "http://www.w3.org/2000/svg", children: [
|
|
11849
|
+
/* @__PURE__ */ y("rect", { width: "80", height: "80", fill: "#6F33B7" }),
|
|
11850
|
+
/* @__PURE__ */ y(
|
|
11851
11851
|
"path",
|
|
11852
11852
|
{
|
|
11853
11853
|
fillRule: "evenodd",
|
|
@@ -11856,7 +11856,7 @@ function Am(e) {
|
|
|
11856
11856
|
fill: "white"
|
|
11857
11857
|
}
|
|
11858
11858
|
)
|
|
11859
|
-
] }) : /* @__PURE__ */
|
|
11859
|
+
] }) : /* @__PURE__ */ y(
|
|
11860
11860
|
"img",
|
|
11861
11861
|
{
|
|
11862
11862
|
src: n,
|
|
@@ -11927,19 +11927,19 @@ function Tm() {
|
|
|
11927
11927
|
onViewportScroll: c,
|
|
11928
11928
|
children: [
|
|
11929
11929
|
/* @__PURE__ */ B("div", { className: "chat-interface-head mt-10", children: [
|
|
11930
|
-
/* @__PURE__ */
|
|
11930
|
+
/* @__PURE__ */ y("div", { className: "w-14 h-14 mx-auto rounded-md overflow-hidden", children: /* @__PURE__ */ y(Am, { src: e.assistantLogo }) }),
|
|
11931
11931
|
/* @__PURE__ */ B("div", { className: "mt-2 space-y-1", children: [
|
|
11932
11932
|
/* @__PURE__ */ B("h3", { className: "text-center font-semibold", children: [
|
|
11933
11933
|
e.assistantName,
|
|
11934
11934
|
" ",
|
|
11935
11935
|
e.title
|
|
11936
11936
|
] }),
|
|
11937
|
-
/* @__PURE__ */
|
|
11937
|
+
/* @__PURE__ */ y("p", { className: "text-muted-foreground text-center text-sm", children: e.subtitle })
|
|
11938
11938
|
] })
|
|
11939
11939
|
] }),
|
|
11940
|
-
/* @__PURE__ */
|
|
11940
|
+
/* @__PURE__ */ y("div", { className: "chat-interface-body flex flex-col space-y-4 mb-10", children: f.map((p, d, h) => {
|
|
11941
11941
|
const b = Array.isArray(p) ? p.map((v) => v.id).join("-") : p.id;
|
|
11942
|
-
return /* @__PURE__ */
|
|
11942
|
+
return /* @__PURE__ */ y(
|
|
11943
11943
|
_m,
|
|
11944
11944
|
{
|
|
11945
11945
|
message: p,
|
|
@@ -11957,17 +11957,17 @@ function Tm() {
|
|
|
11957
11957
|
]
|
|
11958
11958
|
}
|
|
11959
11959
|
),
|
|
11960
|
-
i && /* @__PURE__ */
|
|
11960
|
+
i && /* @__PURE__ */ y(
|
|
11961
11961
|
"button",
|
|
11962
11962
|
{
|
|
11963
11963
|
className: "flex items-center justify-center absolute left-[calc(50%-0.75rem)] bottom-10 mx-auto cursor-pointer",
|
|
11964
11964
|
onClick: () => u("instant"),
|
|
11965
|
-
children: /* @__PURE__ */
|
|
11965
|
+
children: /* @__PURE__ */ y(jo, { className: "h-6 w-6 text-primary bg-white rounded-full border" })
|
|
11966
11966
|
}
|
|
11967
11967
|
)
|
|
11968
11968
|
] });
|
|
11969
11969
|
}
|
|
11970
|
-
const us = pe.forwardRef(({ className: e, ...t }, n) => /* @__PURE__ */
|
|
11970
|
+
const us = pe.forwardRef(({ className: e, ...t }, n) => /* @__PURE__ */ y(
|
|
11971
11971
|
"textarea",
|
|
11972
11972
|
{
|
|
11973
11973
|
className: j(
|
|
@@ -12061,22 +12061,22 @@ const to = {
|
|
|
12061
12061
|
{
|
|
12062
12062
|
className: `flex items-center gap-3 ${n.bgColor} text-sm sm:text-md border-l-4 ${n.borderColor} p-3 rounded-md my-4`,
|
|
12063
12063
|
children: [
|
|
12064
|
-
/* @__PURE__ */
|
|
12065
|
-
/* @__PURE__ */
|
|
12064
|
+
/* @__PURE__ */ y(r, { className: n.iconColor, size: 25 }),
|
|
12065
|
+
/* @__PURE__ */ y("span", { className: n.textColor, children: e })
|
|
12066
12066
|
]
|
|
12067
12067
|
}
|
|
12068
12068
|
);
|
|
12069
12069
|
};
|
|
12070
12070
|
function Lm() {
|
|
12071
|
-
const { error: e } = Vt(), t = !!e, n = mn(), r = le(null), [i, o] = W(""), a = Nm(), s = kr(), l = () => i.trim() && !t ? { backgroundColor: s.userBubbleColor } : {}, c = () => n.suggestedMessages ? /* @__PURE__ */
|
|
12071
|
+
const { error: e } = Vt(), t = !!e, n = mn(), r = le(null), [i, o] = W(""), a = Nm(), s = kr(), l = () => i.trim() && !t ? { backgroundColor: s.userBubbleColor } : {}, c = () => n.suggestedMessages ? /* @__PURE__ */ y(
|
|
12072
12072
|
"div",
|
|
12073
12073
|
{
|
|
12074
12074
|
className: "w-full px-4 pb-10 -mt-20 overflow-x-auto no-scrollbar z-10 cursor-grab",
|
|
12075
12075
|
...a,
|
|
12076
|
-
children: /* @__PURE__ */
|
|
12076
|
+
children: /* @__PURE__ */ y("div", { className: "flex gap-2 min-w-min", children: [
|
|
12077
12077
|
"Tell me more about Product X.",
|
|
12078
12078
|
"Do you offer delivery in Palo Alto?"
|
|
12079
|
-
].map((d) => /* @__PURE__ */
|
|
12079
|
+
].map((d) => /* @__PURE__ */ y(
|
|
12080
12080
|
"button",
|
|
12081
12081
|
{
|
|
12082
12082
|
onClick: () => {
|
|
@@ -12109,7 +12109,7 @@ function Lm() {
|
|
|
12109
12109
|
}
|
|
12110
12110
|
};
|
|
12111
12111
|
return /* @__PURE__ */ B(vr, { className: "flex flex-col bg-background p-0", children: [
|
|
12112
|
-
n.isConversationClosed ? /* @__PURE__ */
|
|
12112
|
+
n.isConversationClosed ? /* @__PURE__ */ y("div", { className: "flex flex-col w-full items-center px-4 pb-4 -mt-6 z-20", children: /* @__PURE__ */ B(
|
|
12113
12113
|
"div",
|
|
12114
12114
|
{
|
|
12115
12115
|
className: "w-full rounded-xl border border-[#E5E3E1] bg-[#FAF9F7] p-4 shadow-sm dark:border-border dark:bg-card",
|
|
@@ -12117,7 +12117,7 @@ function Lm() {
|
|
|
12117
12117
|
"aria-live": "polite",
|
|
12118
12118
|
children: [
|
|
12119
12119
|
/* @__PURE__ */ B("div", { className: "flex items-start gap-2.5", children: [
|
|
12120
|
-
/* @__PURE__ */
|
|
12120
|
+
/* @__PURE__ */ y(
|
|
12121
12121
|
hl,
|
|
12122
12122
|
{
|
|
12123
12123
|
className: "mt-0.5 h-5 w-5 shrink-0 text-[#B2B0AE] dark:text-muted-foreground",
|
|
@@ -12126,11 +12126,11 @@ function Lm() {
|
|
|
12126
12126
|
}
|
|
12127
12127
|
),
|
|
12128
12128
|
/* @__PURE__ */ B("div", { className: "flex min-w-0 flex-1 flex-col gap-2 text-left", children: [
|
|
12129
|
-
/* @__PURE__ */
|
|
12130
|
-
/* @__PURE__ */
|
|
12129
|
+
/* @__PURE__ */ y("p", { className: "text-base font-semibold leading-tight text-foreground", children: "Session Expired" }),
|
|
12130
|
+
/* @__PURE__ */ y("p", { className: "text-sm leading-relaxed text-muted-foreground", children: "This conversation is closed. Please start a new chat to continue." })
|
|
12131
12131
|
] })
|
|
12132
12132
|
] }),
|
|
12133
|
-
/* @__PURE__ */
|
|
12133
|
+
/* @__PURE__ */ y(
|
|
12134
12134
|
"button",
|
|
12135
12135
|
{
|
|
12136
12136
|
type: "button",
|
|
@@ -12145,14 +12145,14 @@ function Lm() {
|
|
|
12145
12145
|
) }) : /* @__PURE__ */ B(We, { children: [
|
|
12146
12146
|
c(),
|
|
12147
12147
|
/* @__PURE__ */ B("div", { className: "flex flex-col w-full items-center px-4 pb-4 -mt-6 z-20", children: [
|
|
12148
|
-
t && /* @__PURE__ */
|
|
12148
|
+
t && /* @__PURE__ */ y(Om, { message: e.message, type: "error" }),
|
|
12149
12149
|
/* @__PURE__ */ B(
|
|
12150
12150
|
"form",
|
|
12151
12151
|
{
|
|
12152
12152
|
className: "relative flex items-center w-full m-0",
|
|
12153
12153
|
onSubmit: u,
|
|
12154
12154
|
children: [
|
|
12155
|
-
/* @__PURE__ */
|
|
12155
|
+
/* @__PURE__ */ y("div", { className: "flex-1 bg-card rounded-3xl shadow-[0_0_4px_0_rgba(0,0,0,0.20)]", children: /* @__PURE__ */ y(
|
|
12156
12156
|
us,
|
|
12157
12157
|
{
|
|
12158
12158
|
ref: r,
|
|
@@ -12180,7 +12180,7 @@ function Lm() {
|
|
|
12180
12180
|
}
|
|
12181
12181
|
}
|
|
12182
12182
|
) }),
|
|
12183
|
-
/* @__PURE__ */
|
|
12183
|
+
/* @__PURE__ */ y(
|
|
12184
12184
|
"button",
|
|
12185
12185
|
{
|
|
12186
12186
|
type: "submit",
|
|
@@ -12190,7 +12190,7 @@ function Lm() {
|
|
|
12190
12190
|
i.trim() && !t ? "text-primary-foreground" : "bg-muted-foreground"
|
|
12191
12191
|
),
|
|
12192
12192
|
style: l(),
|
|
12193
|
-
children: /* @__PURE__ */
|
|
12193
|
+
children: /* @__PURE__ */ y(ml, { className: "h-4 w-4" })
|
|
12194
12194
|
}
|
|
12195
12195
|
)
|
|
12196
12196
|
]
|
|
@@ -12200,10 +12200,10 @@ function Lm() {
|
|
|
12200
12200
|
] }),
|
|
12201
12201
|
/* @__PURE__ */ B("div", { className: "w-full flex flex-col items-center justify-center space-x-2 p-1 pt-0 px-0 bg-[#FAF9F7] dark:bg-background", children: [
|
|
12202
12202
|
/* @__PURE__ */ B("div", { className: "w-full flex items-center justify-center space-x-2 py-1 bg-[#FAF9F7] dark:bg-card", children: [
|
|
12203
|
-
/* @__PURE__ */
|
|
12204
|
-
/* @__PURE__ */
|
|
12203
|
+
/* @__PURE__ */ y(hn, { className: j("w-5 h-5"), bgColor: "#E5E3E1", fgColor: "#B2B0AE" }),
|
|
12204
|
+
/* @__PURE__ */ y("div", { className: "text-xs text-center text-muted-foreground p-1", children: "Powered by EloquentAI" })
|
|
12205
12205
|
] }),
|
|
12206
|
-
n.legalText && /* @__PURE__ */
|
|
12206
|
+
n.legalText && /* @__PURE__ */ y(
|
|
12207
12207
|
"div",
|
|
12208
12208
|
{
|
|
12209
12209
|
className: "text-xs text-center text-muted-foreground mt-2",
|
|
@@ -12213,7 +12213,7 @@ function Lm() {
|
|
|
12213
12213
|
] })
|
|
12214
12214
|
] });
|
|
12215
12215
|
}
|
|
12216
|
-
const ps = pe.forwardRef(({ className: e, ...t }, n) => /* @__PURE__ */
|
|
12216
|
+
const ps = pe.forwardRef(({ className: e, ...t }, n) => /* @__PURE__ */ y(
|
|
12217
12217
|
mt.Root,
|
|
12218
12218
|
{
|
|
12219
12219
|
ref: n,
|
|
@@ -12225,7 +12225,7 @@ const ps = pe.forwardRef(({ className: e, ...t }, n) => /* @__PURE__ */ w(
|
|
|
12225
12225
|
}
|
|
12226
12226
|
));
|
|
12227
12227
|
ps.displayName = mt.Root.displayName;
|
|
12228
|
-
const Dm = pe.forwardRef(({ className: e, ...t }, n) => /* @__PURE__ */
|
|
12228
|
+
const Dm = pe.forwardRef(({ className: e, ...t }, n) => /* @__PURE__ */ y(
|
|
12229
12229
|
mt.Image,
|
|
12230
12230
|
{
|
|
12231
12231
|
ref: n,
|
|
@@ -12234,7 +12234,7 @@ const Dm = pe.forwardRef(({ className: e, ...t }, n) => /* @__PURE__ */ w(
|
|
|
12234
12234
|
}
|
|
12235
12235
|
));
|
|
12236
12236
|
Dm.displayName = mt.Image.displayName;
|
|
12237
|
-
const Pm = pe.forwardRef(({ className: e, ...t }, n) => /* @__PURE__ */
|
|
12237
|
+
const Pm = pe.forwardRef(({ className: e, ...t }, n) => /* @__PURE__ */ y(
|
|
12238
12238
|
mt.Fallback,
|
|
12239
12239
|
{
|
|
12240
12240
|
ref: n,
|
|
@@ -12253,7 +12253,7 @@ function Mm({
|
|
|
12253
12253
|
const n = mn();
|
|
12254
12254
|
return /* @__PURE__ */ B(wr, { className: "p-4 flex flex-row items-center justify-between shadow-sm space-y-0", children: [
|
|
12255
12255
|
/* @__PURE__ */ B("div", { className: "flex flex-row items-center space-x-3", children: [
|
|
12256
|
-
/* @__PURE__ */
|
|
12256
|
+
/* @__PURE__ */ y(ps, { className: "h-8 w-8", children: /* @__PURE__ */ y(
|
|
12257
12257
|
hn,
|
|
12258
12258
|
{
|
|
12259
12259
|
src: n.assistantLogo,
|
|
@@ -12261,23 +12261,23 @@ function Mm({
|
|
|
12261
12261
|
fgColor: "#ffffff"
|
|
12262
12262
|
}
|
|
12263
12263
|
) }),
|
|
12264
|
-
/* @__PURE__ */
|
|
12264
|
+
/* @__PURE__ */ y("div", { className: "flex flex-col", children: /* @__PURE__ */ y("h2", { className: "text-foreground font-semibold", children: n.assistantName }) })
|
|
12265
12265
|
] }),
|
|
12266
12266
|
/* @__PURE__ */ B("div", { children: [
|
|
12267
|
-
n.cleanChatButton && /* @__PURE__ */
|
|
12267
|
+
n.cleanChatButton && /* @__PURE__ */ y(
|
|
12268
12268
|
"button",
|
|
12269
12269
|
{
|
|
12270
12270
|
onClick: e,
|
|
12271
12271
|
className: "text-gray-400 hover:text-gray-600 p-2",
|
|
12272
|
-
children: /* @__PURE__ */
|
|
12272
|
+
children: /* @__PURE__ */ y(gl, { className: "w-4 h-4" })
|
|
12273
12273
|
}
|
|
12274
12274
|
),
|
|
12275
|
-
n.closeButton === !0 && n.isMobile && /* @__PURE__ */
|
|
12275
|
+
n.closeButton === !0 && n.isMobile && /* @__PURE__ */ y(
|
|
12276
12276
|
"button",
|
|
12277
12277
|
{
|
|
12278
12278
|
onClick: t,
|
|
12279
12279
|
className: "text-gray-400 hover:text-gray-600 p-2",
|
|
12280
|
-
children: /* @__PURE__ */
|
|
12280
|
+
children: /* @__PURE__ */ y(gr, { className: "w-4 h-4" })
|
|
12281
12281
|
}
|
|
12282
12282
|
)
|
|
12283
12283
|
] })
|
|
@@ -12299,7 +12299,7 @@ function Me({
|
|
|
12299
12299
|
className: e,
|
|
12300
12300
|
...t
|
|
12301
12301
|
}) {
|
|
12302
|
-
return /* @__PURE__ */
|
|
12302
|
+
return /* @__PURE__ */ y(
|
|
12303
12303
|
"div",
|
|
12304
12304
|
{
|
|
12305
12305
|
className: j("animate-pulse rounded-md bg-muted", e),
|
|
@@ -12316,24 +12316,24 @@ function ms({
|
|
|
12316
12316
|
isMobile: t
|
|
12317
12317
|
});
|
|
12318
12318
|
return /* @__PURE__ */ B(yr, { className: r, children: [
|
|
12319
|
-
/* @__PURE__ */
|
|
12320
|
-
/* @__PURE__ */
|
|
12321
|
-
/* @__PURE__ */
|
|
12319
|
+
/* @__PURE__ */ y(wr, { className: "p-4 flex flex-row items-center justify-between shadow-sm space-y-0", children: /* @__PURE__ */ B("div", { className: "flex flex-row items-center space-x-3", children: [
|
|
12320
|
+
/* @__PURE__ */ y(Me, { className: "h-8 w-8" }),
|
|
12321
|
+
/* @__PURE__ */ y(Me, { className: "h-6 w-32" })
|
|
12322
12322
|
] }) }),
|
|
12323
|
-
/* @__PURE__ */
|
|
12323
|
+
/* @__PURE__ */ y(xr, { className: "flex-1 px-4 overflow-hidden", children: /* @__PURE__ */ B(wl, { children: [
|
|
12324
12324
|
/* @__PURE__ */ B("div", { className: "flex flex-col items-center justify-center space-y-2 pt-10", children: [
|
|
12325
|
-
/* @__PURE__ */
|
|
12326
|
-
/* @__PURE__ */
|
|
12327
|
-
/* @__PURE__ */
|
|
12325
|
+
/* @__PURE__ */ y(Me, { className: "w-14 h-14 mx-auto rounded-md" }),
|
|
12326
|
+
/* @__PURE__ */ y("div", { children: /* @__PURE__ */ y(Me, { className: "h-6 w-32 mx-auto mt-2" }) }),
|
|
12327
|
+
/* @__PURE__ */ y(Me, { className: "h-4 w-24 mx-auto" })
|
|
12328
12328
|
] }),
|
|
12329
12329
|
/* @__PURE__ */ B("div", { className: "flex flex-col space-y-4 mt-10", children: [
|
|
12330
|
-
/* @__PURE__ */
|
|
12331
|
-
/* @__PURE__ */
|
|
12332
|
-
/* @__PURE__ */
|
|
12333
|
-
/* @__PURE__ */
|
|
12330
|
+
/* @__PURE__ */ y(Me, { className: "h-12 w-2/3" }),
|
|
12331
|
+
/* @__PURE__ */ y(Me, { className: "h-12 w-2/3 self-end" }),
|
|
12332
|
+
/* @__PURE__ */ y(Me, { className: "h-12 w-2/3" }),
|
|
12333
|
+
/* @__PURE__ */ y(Me, { className: "h-12 w-2/3 self-end" })
|
|
12334
12334
|
] })
|
|
12335
12335
|
] }) }),
|
|
12336
|
-
/* @__PURE__ */
|
|
12336
|
+
/* @__PURE__ */ y(vr, { children: /* @__PURE__ */ y(Me, { className: "h-12 w-full rounded-full" }) })
|
|
12337
12337
|
] }, "chat-interface-sekelton");
|
|
12338
12338
|
}
|
|
12339
12339
|
function zm(e) {
|
|
@@ -12341,18 +12341,18 @@ function zm(e) {
|
|
|
12341
12341
|
isOpen: a,
|
|
12342
12342
|
isMobile: n
|
|
12343
12343
|
}), u = () => s ? /* @__PURE__ */ B(yr, { className: c, children: [
|
|
12344
|
-
/* @__PURE__ */
|
|
12344
|
+
/* @__PURE__ */ y(
|
|
12345
12345
|
Mm,
|
|
12346
12346
|
{
|
|
12347
12347
|
onCleanChat: () => r?.(),
|
|
12348
12348
|
onClose: () => i?.()
|
|
12349
12349
|
}
|
|
12350
12350
|
),
|
|
12351
|
-
/* @__PURE__ */
|
|
12352
|
-
/* @__PURE__ */
|
|
12351
|
+
/* @__PURE__ */ y(Tm, {}),
|
|
12352
|
+
/* @__PURE__ */ y(Lm, {})
|
|
12353
12353
|
] }) : /* @__PURE__ */ B(We, { children: [
|
|
12354
|
-
/* @__PURE__ */
|
|
12355
|
-
!s && /* @__PURE__ */
|
|
12354
|
+
/* @__PURE__ */ y(ms, { isOpen: t, isMobile: n }),
|
|
12355
|
+
!s && /* @__PURE__ */ y(
|
|
12356
12356
|
Xo,
|
|
12357
12357
|
{
|
|
12358
12358
|
className: "hidden invisible",
|
|
@@ -12360,7 +12360,7 @@ function zm(e) {
|
|
|
12360
12360
|
}
|
|
12361
12361
|
)
|
|
12362
12362
|
] });
|
|
12363
|
-
return /* @__PURE__ */
|
|
12363
|
+
return /* @__PURE__ */ y(Vo, { ...o, children: /* @__PURE__ */ y(Ol, { ...e, children: /* @__PURE__ */ y(
|
|
12364
12364
|
"main",
|
|
12365
12365
|
{
|
|
12366
12366
|
className: j(
|
|
@@ -12411,7 +12411,7 @@ function qm({
|
|
|
12411
12411
|
}, 300);
|
|
12412
12412
|
return () => clearTimeout(u);
|
|
12413
12413
|
}
|
|
12414
|
-
}, [t, n, i]), o ? /* @__PURE__ */
|
|
12414
|
+
}, [t, n, i]), o ? /* @__PURE__ */ y(
|
|
12415
12415
|
"div",
|
|
12416
12416
|
{
|
|
12417
12417
|
className: j(
|
|
@@ -12420,7 +12420,7 @@ function qm({
|
|
|
12420
12420
|
s === "visible" && "translate-x-0 opacity-100 scale-100",
|
|
12421
12421
|
s === "exiting" && "translate-x-8 opacity-0 scale-95"
|
|
12422
12422
|
),
|
|
12423
|
-
children: /* @__PURE__ */
|
|
12423
|
+
children: /* @__PURE__ */ y("div", { className: "relative", children: /* @__PURE__ */ B(
|
|
12424
12424
|
"div",
|
|
12425
12425
|
{
|
|
12426
12426
|
className: j(
|
|
@@ -12432,7 +12432,7 @@ function qm({
|
|
|
12432
12432
|
},
|
|
12433
12433
|
onClick: r,
|
|
12434
12434
|
children: [
|
|
12435
|
-
/* @__PURE__ */
|
|
12435
|
+
/* @__PURE__ */ y(
|
|
12436
12436
|
"svg",
|
|
12437
12437
|
{
|
|
12438
12438
|
className: j(
|
|
@@ -12440,19 +12440,19 @@ function qm({
|
|
|
12440
12440
|
),
|
|
12441
12441
|
viewBox: "0 0 10.54 11.14",
|
|
12442
12442
|
fill: c.botBubbleColor,
|
|
12443
|
-
children: /* @__PURE__ */
|
|
12443
|
+
children: /* @__PURE__ */ y("path", { d: "M5.75,0s0,.36,0,.51c-.09,4.52-5.74,10.64-5.74,10.64,8.19.02,10.54-2.26,10.54-2.26h0c-1.6-2.96-3.19-5.92-4.79-8.88Z" })
|
|
12444
12444
|
}
|
|
12445
12445
|
),
|
|
12446
12446
|
/* @__PURE__ */ B("div", { className: "flex items-start justify-between gap-2", children: [
|
|
12447
|
-
/* @__PURE__ */
|
|
12448
|
-
/* @__PURE__ */
|
|
12447
|
+
/* @__PURE__ */ y("p", { className: "text-sm text-gray-800 leading-relaxed flex-1", children: e }),
|
|
12448
|
+
/* @__PURE__ */ y(
|
|
12449
12449
|
"button",
|
|
12450
12450
|
{
|
|
12451
12451
|
onClick: (u) => {
|
|
12452
12452
|
u.stopPropagation(), n();
|
|
12453
12453
|
},
|
|
12454
12454
|
className: "flex-shrink-0 p-1 hover:bg-gray-100 rounded-full transition-colors duration-200",
|
|
12455
|
-
children: /* @__PURE__ */
|
|
12455
|
+
children: /* @__PURE__ */ y(gr, { className: "w-3 h-3 text-gray-500" })
|
|
12456
12456
|
}
|
|
12457
12457
|
)
|
|
12458
12458
|
] })
|
|
@@ -12660,48 +12660,48 @@ function Hm({
|
|
|
12660
12660
|
f.current = n;
|
|
12661
12661
|
const p = le(() => Promise.resolve()), d = () => {
|
|
12662
12662
|
s.current && (clearTimeout(s.current), s.current = null);
|
|
12663
|
-
}, h = (
|
|
12664
|
-
id:
|
|
12665
|
-
content:
|
|
12666
|
-
sender:
|
|
12667
|
-
timestamp:
|
|
12663
|
+
}, h = (E) => ({
|
|
12664
|
+
id: E.message_id,
|
|
12665
|
+
content: E.response.content,
|
|
12666
|
+
sender: E.role,
|
|
12667
|
+
timestamp: E.created_at,
|
|
12668
12668
|
type: "text"
|
|
12669
|
-
}), b = (
|
|
12670
|
-
message_id:
|
|
12671
|
-
response:
|
|
12669
|
+
}), b = (E) => ({
|
|
12670
|
+
message_id: E.message_id,
|
|
12671
|
+
response: E.response
|
|
12672
12672
|
}), v = te(
|
|
12673
|
-
(
|
|
12674
|
-
const D = I.map(h), R = Math.min(
|
|
12673
|
+
(E, I) => {
|
|
12674
|
+
const D = I.map(h), R = Math.min(E.length, D.length);
|
|
12675
12675
|
for (let A = 0; A < R; A++)
|
|
12676
|
-
if (
|
|
12676
|
+
if (E[A].id !== D[A].id)
|
|
12677
12677
|
return !1;
|
|
12678
12678
|
return !0;
|
|
12679
12679
|
},
|
|
12680
12680
|
[]
|
|
12681
|
-
),
|
|
12682
|
-
(
|
|
12681
|
+
), w = te(
|
|
12682
|
+
(E) => {
|
|
12683
12683
|
setTimeout(() => {
|
|
12684
|
-
o(b(
|
|
12684
|
+
o(b(E), t);
|
|
12685
12685
|
}, 100);
|
|
12686
12686
|
},
|
|
12687
12687
|
[o, t]
|
|
12688
12688
|
), _ = te(
|
|
12689
|
-
(
|
|
12689
|
+
(E, I = !1) => {
|
|
12690
12690
|
const D = f.current.filter(
|
|
12691
12691
|
(A) => A.isWelcomeMessage
|
|
12692
|
-
), R =
|
|
12692
|
+
), R = E.map(h);
|
|
12693
12693
|
if (I && R.length > 0) {
|
|
12694
|
-
const A =
|
|
12695
|
-
r([...D, ...R.slice(0, -1)]),
|
|
12694
|
+
const A = E[E.length - 1];
|
|
12695
|
+
r([...D, ...R.slice(0, -1)]), w(A);
|
|
12696
12696
|
} else
|
|
12697
12697
|
r([...D, ...R]);
|
|
12698
12698
|
},
|
|
12699
|
-
[r,
|
|
12700
|
-
),
|
|
12701
|
-
(
|
|
12702
|
-
if (
|
|
12699
|
+
[r, w]
|
|
12700
|
+
), S = te(
|
|
12701
|
+
(E) => {
|
|
12702
|
+
if (E.role === "assistant")
|
|
12703
12703
|
o(
|
|
12704
|
-
b(
|
|
12704
|
+
b(E),
|
|
12705
12705
|
t
|
|
12706
12706
|
);
|
|
12707
12707
|
else {
|
|
@@ -12709,7 +12709,7 @@ function Hm({
|
|
|
12709
12709
|
(A) => A.isWelcomeMessage
|
|
12710
12710
|
), D = f.current.filter(
|
|
12711
12711
|
(A) => !A.isThinking && !A.isWelcomeMessage
|
|
12712
|
-
), R = h(
|
|
12712
|
+
), R = h(E);
|
|
12713
12713
|
r([...I, ...D, R]);
|
|
12714
12714
|
}
|
|
12715
12715
|
c.current = Math.max(
|
|
@@ -12718,27 +12718,27 @@ function Hm({
|
|
|
12718
12718
|
);
|
|
12719
12719
|
},
|
|
12720
12720
|
[o, t, r]
|
|
12721
|
-
),
|
|
12722
|
-
(
|
|
12721
|
+
), O = te(
|
|
12722
|
+
(E, I) => {
|
|
12723
12723
|
const R = I[I.length - 1].role === "assistant";
|
|
12724
|
-
_(
|
|
12724
|
+
_(E, R), c.current = Math.max(
|
|
12725
12725
|
0,
|
|
12726
12726
|
c.current - I.length
|
|
12727
12727
|
);
|
|
12728
12728
|
},
|
|
12729
12729
|
[_]
|
|
12730
12730
|
), N = te(
|
|
12731
|
-
(
|
|
12731
|
+
(E, I, D) => {
|
|
12732
12732
|
if (I.length > 0) {
|
|
12733
12733
|
const A = I[I.length - 1].role === "assistant";
|
|
12734
|
-
_(
|
|
12734
|
+
_(E, A), c.current = Math.max(
|
|
12735
12735
|
0,
|
|
12736
12736
|
c.current - I.length
|
|
12737
12737
|
);
|
|
12738
12738
|
} else {
|
|
12739
12739
|
const R = f.current.filter(
|
|
12740
12740
|
(U) => U.isWelcomeMessage
|
|
12741
|
-
), A =
|
|
12741
|
+
), A = E.map(h);
|
|
12742
12742
|
r([
|
|
12743
12743
|
...R,
|
|
12744
12744
|
...A,
|
|
@@ -12747,24 +12747,24 @@ function Hm({
|
|
|
12747
12747
|
}
|
|
12748
12748
|
},
|
|
12749
12749
|
[_, r]
|
|
12750
|
-
),
|
|
12750
|
+
), k = te(async () => {
|
|
12751
12751
|
if (!(!e || !t || !u.current))
|
|
12752
12752
|
try {
|
|
12753
|
-
let
|
|
12754
|
-
|
|
12753
|
+
let E = await e.getChatHistory(t);
|
|
12754
|
+
E.some(ro) && (E = E.filter(
|
|
12755
12755
|
(H) => !ro(H)
|
|
12756
12756
|
), a?.(), u.current = !1, d());
|
|
12757
12757
|
const D = f.current.filter(
|
|
12758
12758
|
(H) => !H.isThinking && !H.isWelcomeMessage
|
|
12759
|
-
), R = new Set(D.map((H) => H.id)), A = new Set(
|
|
12759
|
+
), R = new Set(D.map((H) => H.id)), A = new Set(E.map((H) => H.message_id)), U = E.filter(
|
|
12760
12760
|
(H) => !R.has(H.message_id)
|
|
12761
12761
|
), q = D.filter(
|
|
12762
12762
|
(H) => !A.has(H.id)
|
|
12763
12763
|
);
|
|
12764
12764
|
if (!(U.length === 0 && q.length === 0)) {
|
|
12765
|
-
const H = v(D,
|
|
12766
|
-
H && ne ?
|
|
12767
|
-
|
|
12765
|
+
const H = v(D, E), ne = U.length === 1 && q.length === 0, m = U.length > 1 && q.length === 0;
|
|
12766
|
+
H && ne ? S(U[0]) : H && m ? O(E, U) : N(
|
|
12767
|
+
E,
|
|
12768
12768
|
U,
|
|
12769
12769
|
q
|
|
12770
12770
|
);
|
|
@@ -12776,8 +12776,8 @@ function Hm({
|
|
|
12776
12776
|
H
|
|
12777
12777
|
);
|
|
12778
12778
|
}
|
|
12779
|
-
} catch (
|
|
12780
|
-
if (console.warn("Background polling failed:",
|
|
12779
|
+
} catch (E) {
|
|
12780
|
+
if (console.warn("Background polling failed:", E), u.current) {
|
|
12781
12781
|
const I = jn[l.current];
|
|
12782
12782
|
s.current = setTimeout(
|
|
12783
12783
|
() => p.current(),
|
|
@@ -12789,33 +12789,33 @@ function Hm({
|
|
|
12789
12789
|
e,
|
|
12790
12790
|
t,
|
|
12791
12791
|
v,
|
|
12792
|
-
|
|
12793
|
-
|
|
12792
|
+
S,
|
|
12793
|
+
O,
|
|
12794
12794
|
N,
|
|
12795
12795
|
a
|
|
12796
12796
|
]);
|
|
12797
|
-
p.current =
|
|
12798
|
-
const
|
|
12797
|
+
p.current = k;
|
|
12798
|
+
const z = te(() => {
|
|
12799
12799
|
!t || u.current || (u.current = !0, p.current());
|
|
12800
12800
|
}, [t]), P = te(() => {
|
|
12801
12801
|
u.current = !1, d(), c.current = 0;
|
|
12802
|
-
}, []),
|
|
12802
|
+
}, []), M = te((E) => {
|
|
12803
12803
|
const I = l.current;
|
|
12804
|
-
if (l.current =
|
|
12804
|
+
if (l.current = E, I !== E && u.current) {
|
|
12805
12805
|
d();
|
|
12806
|
-
const D = jn[
|
|
12806
|
+
const D = jn[E];
|
|
12807
12807
|
s.current = setTimeout(() => p.current(), D);
|
|
12808
12808
|
}
|
|
12809
12809
|
}, []), x = () => {
|
|
12810
|
-
c.current += 1,
|
|
12810
|
+
c.current += 1, M("high");
|
|
12811
12811
|
};
|
|
12812
12812
|
return re(() => {
|
|
12813
|
-
const
|
|
12814
|
-
|
|
12815
|
-
}, [i,
|
|
12816
|
-
setPollingMode:
|
|
12813
|
+
const E = c.current > 0 ? "high" : i ? "medium" : "low";
|
|
12814
|
+
M(E);
|
|
12815
|
+
}, [i, M]), re(() => (t && e ? z() : P(), P), [t, e, z, P]), re(() => P, [P]), {
|
|
12816
|
+
setPollingMode: M,
|
|
12817
12817
|
expectMessage: x,
|
|
12818
|
-
startPolling:
|
|
12818
|
+
startPolling: z,
|
|
12819
12819
|
stopPolling: P
|
|
12820
12820
|
};
|
|
12821
12821
|
}
|
|
@@ -13179,14 +13179,14 @@ const bs = (e) => {
|
|
|
13179
13179
|
message: "Invalid config parameter.",
|
|
13180
13180
|
recoverySuggestion: "Ensure passing the config object imported from `amplifyconfiguration.json`."
|
|
13181
13181
|
});
|
|
13182
|
-
const { aws_appsync_apiKey: t, aws_appsync_authenticationType: n, aws_appsync_graphqlEndpoint: r, aws_appsync_region: i, aws_bots_config: o, aws_cognito_identity_pool_id: a, aws_cognito_sign_up_verification_method: s, aws_cognito_mfa_configuration: l, aws_cognito_mfa_types: c, aws_cognito_password_protection_settings: u, aws_cognito_verification_mechanisms: f, aws_cognito_signup_attributes: p, aws_cognito_social_providers: d, aws_cognito_username_attributes: h, aws_mandatory_sign_in: b, aws_mobile_analytics_app_id: v, aws_mobile_analytics_app_region:
|
|
13182
|
+
const { aws_appsync_apiKey: t, aws_appsync_authenticationType: n, aws_appsync_graphqlEndpoint: r, aws_appsync_region: i, aws_bots_config: o, aws_cognito_identity_pool_id: a, aws_cognito_sign_up_verification_method: s, aws_cognito_mfa_configuration: l, aws_cognito_mfa_types: c, aws_cognito_password_protection_settings: u, aws_cognito_verification_mechanisms: f, aws_cognito_signup_attributes: p, aws_cognito_social_providers: d, aws_cognito_username_attributes: h, aws_mandatory_sign_in: b, aws_mobile_analytics_app_id: v, aws_mobile_analytics_app_region: w, aws_user_files_s3_bucket: _, aws_user_files_s3_bucket_region: S, aws_user_files_s3_dangerously_connect_to_http_endpoint_for_testing: O, aws_user_pools_id: N, aws_user_pools_web_client_id: k, geo: z, oauth: P, predictions: M, aws_cloud_logic_custom: x, Notifications: E, modelIntrospection: I } = e, D = {};
|
|
13183
13183
|
v && (D.Analytics = {
|
|
13184
13184
|
Pinpoint: {
|
|
13185
13185
|
appId: v,
|
|
13186
|
-
region:
|
|
13186
|
+
region: w
|
|
13187
13187
|
}
|
|
13188
13188
|
});
|
|
13189
|
-
const { InAppMessaging: R, Push: A } =
|
|
13189
|
+
const { InAppMessaging: R, Push: A } = E ?? {};
|
|
13190
13190
|
if (R?.AWSPinpoint || A?.AWSPinpoint) {
|
|
13191
13191
|
if (R?.AWSPinpoint) {
|
|
13192
13192
|
const { appId: J, region: me } = R.AWSPinpoint;
|
|
@@ -13249,7 +13249,7 @@ const bs = (e) => {
|
|
|
13249
13249
|
allowGuestAccess: b !== "enable",
|
|
13250
13250
|
signUpVerificationMethod: s,
|
|
13251
13251
|
userAttributes: ne,
|
|
13252
|
-
userPoolClientId:
|
|
13252
|
+
userPoolClientId: k,
|
|
13253
13253
|
userPoolId: N,
|
|
13254
13254
|
mfa: U,
|
|
13255
13255
|
passwordFormat: q,
|
|
@@ -13272,11 +13272,11 @@ const bs = (e) => {
|
|
|
13272
13272
|
}), _ && (D.Storage = {
|
|
13273
13273
|
S3: {
|
|
13274
13274
|
bucket: _,
|
|
13275
|
-
region:
|
|
13276
|
-
dangerouslyConnectToHttpEndpointForTesting:
|
|
13275
|
+
region: S,
|
|
13276
|
+
dangerouslyConnectToHttpEndpointForTesting: O
|
|
13277
13277
|
}
|
|
13278
|
-
}),
|
|
13279
|
-
const { amazon_location_service: J } =
|
|
13278
|
+
}), z) {
|
|
13279
|
+
const { amazon_location_service: J } = z;
|
|
13280
13280
|
D.Geo = {
|
|
13281
13281
|
LocationService: {
|
|
13282
13282
|
maps: J.maps,
|
|
@@ -13299,18 +13299,18 @@ const bs = (e) => {
|
|
|
13299
13299
|
}
|
|
13300
13300
|
};
|
|
13301
13301
|
}, {})
|
|
13302
|
-
}),
|
|
13303
|
-
const { VoiceId: J } =
|
|
13302
|
+
}), M) {
|
|
13303
|
+
const { VoiceId: J } = M?.convert?.speechGenerator?.defaults ?? {};
|
|
13304
13304
|
D.Predictions = J ? {
|
|
13305
|
-
...
|
|
13305
|
+
...M,
|
|
13306
13306
|
convert: {
|
|
13307
|
-
...
|
|
13307
|
+
...M.convert,
|
|
13308
13308
|
speechGenerator: {
|
|
13309
|
-
...
|
|
13309
|
+
...M.convert.speechGenerator,
|
|
13310
13310
|
defaults: { voiceId: J }
|
|
13311
13311
|
}
|
|
13312
13312
|
}
|
|
13313
|
-
} :
|
|
13313
|
+
} : M;
|
|
13314
13314
|
}
|
|
13315
13315
|
return D;
|
|
13316
13316
|
}, oo = (e) => e?.split(",") ?? [], tg = ({ domain: e, scope: t, redirectSignIn: n, redirectSignOut: r, responseType: i }) => ({
|
|
@@ -13684,8 +13684,8 @@ function Sg(e, t, n) {
|
|
|
13684
13684
|
}
|
|
13685
13685
|
function s(d, h) {
|
|
13686
13686
|
r[d] && (i[d] = function(b) {
|
|
13687
|
-
return new Promise(function(v,
|
|
13688
|
-
o.push([d, b, v,
|
|
13687
|
+
return new Promise(function(v, w) {
|
|
13688
|
+
o.push([d, b, v, w]) > 1 || l(d, b);
|
|
13689
13689
|
});
|
|
13690
13690
|
}, h && (i[d] = h(i[d])));
|
|
13691
13691
|
}
|
|
@@ -13841,8 +13841,8 @@ var _e = 64, Cg = 32, _g = new Uint32Array([
|
|
|
13841
13841
|
var b = (d >>> 7 | d << 25) ^ (d >>> 18 | d << 14) ^ d >>> 3;
|
|
13842
13842
|
this.temp[p] = (h + this.temp[p - 7] | 0) + (b + this.temp[p - 16] | 0);
|
|
13843
13843
|
}
|
|
13844
|
-
var v = (((l >>> 6 | l << 26) ^ (l >>> 11 | l << 21) ^ (l >>> 25 | l << 7)) + (l & c ^ ~l & u) | 0) + (f + (_g[p] + this.temp[p] | 0) | 0) | 0,
|
|
13845
|
-
f = u, u = c, c = l, l = s + v | 0, s = a, a = o, o = i, i = v +
|
|
13844
|
+
var v = (((l >>> 6 | l << 26) ^ (l >>> 11 | l << 21) ^ (l >>> 25 | l << 7)) + (l & c ^ ~l & u) | 0) + (f + (_g[p] + this.temp[p] | 0) | 0) | 0, w = ((i >>> 2 | i << 30) ^ (i >>> 13 | i << 19) ^ (i >>> 22 | i << 10)) + (i & o ^ i & a ^ o & a) | 0;
|
|
13845
|
+
f = u, u = c, c = l, l = s + v | 0, s = a, a = o, o = i, i = v + w | 0;
|
|
13846
13846
|
}
|
|
13847
13847
|
r[0] += i, r[1] += o, r[2] += a, r[3] += s, r[4] += l, r[5] += c, r[6] += u, r[7] += f;
|
|
13848
13848
|
}, e;
|
|
@@ -15098,9 +15098,9 @@ var Wn = /* @__PURE__ */ (function(e) {
|
|
|
15098
15098
|
function n(r, i, o, a, s, l, c) {
|
|
15099
15099
|
var u, f, p, d;
|
|
15100
15100
|
yy(this, n), d = t.call(this, r), d.name = "GraphQLError", d.originalError = l ?? void 0, d.nodes = Oo(Array.isArray(i) ? i : i ? [i] : void 0);
|
|
15101
|
-
for (var h = [], b = 0, v = (
|
|
15102
|
-
var
|
|
15103
|
-
|
|
15101
|
+
for (var h = [], b = 0, v = (w = d.nodes) !== null && w !== void 0 ? w : []; b < v.length; b++) {
|
|
15102
|
+
var w, _ = v[b], S = _.loc;
|
|
15103
|
+
S != null && h.push(S);
|
|
15104
15104
|
}
|
|
15105
15105
|
h = Oo(h), d.source = o ?? ((u = h) === null || u === void 0 ? void 0 : u[0].source), d.positions = a ?? ((f = h) === null || f === void 0 ? void 0 : f.map(function(N) {
|
|
15106
15106
|
return N.start;
|
|
@@ -15109,8 +15109,8 @@ var Wn = /* @__PURE__ */ (function(e) {
|
|
|
15109
15109
|
}) : (p = h) === null || p === void 0 ? void 0 : p.map(function(N) {
|
|
15110
15110
|
return hr(N.source, N.start);
|
|
15111
15111
|
}), d.path = s ?? void 0;
|
|
15112
|
-
var
|
|
15113
|
-
return c == null && dy(
|
|
15112
|
+
var O = l?.extensions;
|
|
15113
|
+
return c == null && dy(O) ? d.extensions = gy({}, O) : d.extensions = c ?? {}, Object.defineProperties(It(d), {
|
|
15114
15114
|
message: {
|
|
15115
15115
|
enumerable: !0
|
|
15116
15116
|
},
|
|
@@ -15984,7 +15984,7 @@ class tw extends Qy {
|
|
|
15984
15984
|
const Xt = new tw(), _t = /* @__PURE__ */ new Set();
|
|
15985
15985
|
async function nw(e, t) {
|
|
15986
15986
|
const n = Xy();
|
|
15987
|
-
n.authenticationType = ln(t?.authMode, n.authenticationType), n.apiKey = n.apiKey, n.authToken = n.authToken, await Xt.connect(n);
|
|
15987
|
+
n.authenticationType = ln(t?.authMode, n.authenticationType), n.apiKey = t?.apiKey || n.apiKey, n.authToken = t?.authToken || n.authToken, await Xt.connect(n);
|
|
15988
15988
|
const r = dr();
|
|
15989
15989
|
_t.add(r);
|
|
15990
15990
|
let i;
|
|
@@ -16062,90 +16062,93 @@ function dw({
|
|
|
16062
16062
|
onConversationClosed: r,
|
|
16063
16063
|
chatSettings: i
|
|
16064
16064
|
}) {
|
|
16065
|
-
const [o, a] = W(!1), s = le(!1), l = le(null), { publishError: c } = Vt(), u = i?.app_sync_url, f = i?.app_sync_region, p = i?.app_sync_api_key;
|
|
16065
|
+
const [o, a] = W(!1), s = le(!1), l = le(null), { publishError: c } = Vt(), u = i?.app_sync_url, f = i?.app_sync_region, p = i?.app_sync_api_key, d = i?.app_sync_token;
|
|
16066
16066
|
re(() => {
|
|
16067
16067
|
(u || f || p) && (ei.configure(
|
|
16068
16068
|
Bl(u, p, f)
|
|
16069
16069
|
), a(!0));
|
|
16070
16070
|
}, [u, p, f]);
|
|
16071
|
-
const
|
|
16072
|
-
if (!o || !
|
|
16071
|
+
const h = async (O) => {
|
|
16072
|
+
if (!o || !O)
|
|
16073
16073
|
throw new Error(
|
|
16074
16074
|
"Cannot connect: Amplify not ready or missing conversationId"
|
|
16075
16075
|
);
|
|
16076
|
-
|
|
16077
|
-
const
|
|
16078
|
-
|
|
16079
|
-
|
|
16080
|
-
|
|
16081
|
-
|
|
16076
|
+
_();
|
|
16077
|
+
const N = `/default/chat/${O}`, z = await nw(
|
|
16078
|
+
N,
|
|
16079
|
+
d ? { authMode: "lambda", authToken: d } : void 0
|
|
16080
|
+
);
|
|
16081
|
+
l.current = z, z.subscribe({
|
|
16082
|
+
next: (P) => {
|
|
16083
|
+
if (console.log("Received event:", P), P.type !== "data")
|
|
16084
|
+
return console.warn("Unexpected event type:", P.type);
|
|
16082
16085
|
const M = fw.safeParse(
|
|
16083
|
-
|
|
16086
|
+
P.event
|
|
16084
16087
|
);
|
|
16085
16088
|
if (!M.success)
|
|
16086
16089
|
return console.error(
|
|
16087
16090
|
"Invalid conversation response:",
|
|
16088
16091
|
M.error
|
|
16089
16092
|
);
|
|
16090
|
-
const
|
|
16091
|
-
switch (
|
|
16093
|
+
const x = M.data, E = x.data.type;
|
|
16094
|
+
switch (E) {
|
|
16092
16095
|
case "utterance":
|
|
16093
|
-
return
|
|
16094
|
-
|
|
16095
|
-
|
|
16096
|
+
return b(
|
|
16097
|
+
x,
|
|
16098
|
+
O
|
|
16096
16099
|
);
|
|
16097
16100
|
case "error":
|
|
16098
|
-
return
|
|
16101
|
+
return v(x);
|
|
16099
16102
|
case "agent_cognition":
|
|
16100
|
-
return
|
|
16101
|
-
|
|
16103
|
+
return w(
|
|
16104
|
+
x
|
|
16102
16105
|
);
|
|
16103
16106
|
case "chat_closed_expired":
|
|
16104
16107
|
return r?.();
|
|
16105
16108
|
default:
|
|
16106
|
-
console.warn("Unknown notification type:",
|
|
16109
|
+
console.warn("Unknown notification type:", E);
|
|
16107
16110
|
}
|
|
16108
16111
|
},
|
|
16109
|
-
error: (
|
|
16110
|
-
console.error("Error in conversation channel:",
|
|
16112
|
+
error: (P) => {
|
|
16113
|
+
console.error("Error in conversation channel:", P);
|
|
16111
16114
|
}
|
|
16112
|
-
}), await
|
|
16113
|
-
},
|
|
16114
|
-
const
|
|
16115
|
-
message_id:
|
|
16115
|
+
}), await S();
|
|
16116
|
+
}, b = (O, N) => {
|
|
16117
|
+
const k = {
|
|
16118
|
+
message_id: O.message_id,
|
|
16116
16119
|
response: {
|
|
16117
|
-
id:
|
|
16118
|
-
type:
|
|
16119
|
-
content:
|
|
16120
|
+
id: O.message_id,
|
|
16121
|
+
type: O.data.type,
|
|
16122
|
+
content: O.data.content
|
|
16120
16123
|
}
|
|
16121
16124
|
};
|
|
16122
|
-
e(
|
|
16123
|
-
},
|
|
16124
|
-
const
|
|
16125
|
-
n?.(), c({ code:
|
|
16126
|
-
},
|
|
16127
|
-
t(
|
|
16128
|
-
},
|
|
16125
|
+
e(k, N);
|
|
16126
|
+
}, v = (O) => {
|
|
16127
|
+
const N = parseInt(O.data.code), k = fs(N);
|
|
16128
|
+
n?.(), c({ code: N, message: k });
|
|
16129
|
+
}, w = (O) => {
|
|
16130
|
+
t(O.data.content);
|
|
16131
|
+
}, _ = () => {
|
|
16129
16132
|
l.current && (l.current.close(), l.current = null);
|
|
16130
|
-
},
|
|
16131
|
-
const
|
|
16132
|
-
|
|
16133
|
+
}, S = async (O = 1e4) => s.current ? Promise.resolve() : new Promise((N, k) => {
|
|
16134
|
+
const z = setTimeout(() => {
|
|
16135
|
+
k(
|
|
16133
16136
|
new Error(
|
|
16134
|
-
`AppSync connection timeout: Failed to connect within ${
|
|
16137
|
+
`AppSync connection timeout: Failed to connect within ${O}ms`
|
|
16135
16138
|
)
|
|
16136
16139
|
);
|
|
16137
|
-
},
|
|
16138
|
-
s.current ? (clearTimeout(
|
|
16140
|
+
}, O), P = () => {
|
|
16141
|
+
s.current ? (clearTimeout(z), N()) : setTimeout(P, 100);
|
|
16139
16142
|
};
|
|
16140
|
-
|
|
16143
|
+
P();
|
|
16141
16144
|
});
|
|
16142
16145
|
return $r.listen(
|
|
16143
16146
|
"api",
|
|
16144
|
-
(
|
|
16145
|
-
const { payload:
|
|
16146
|
-
|
|
16147
|
+
(O) => {
|
|
16148
|
+
const { payload: N } = O;
|
|
16149
|
+
N.event === Ys && (N.data?.connectionState === "Connected" ? s.current = !0 : s.current = !1);
|
|
16147
16150
|
}
|
|
16148
|
-
), { connect:
|
|
16151
|
+
), { connect: h, disconnect: _ };
|
|
16149
16152
|
}
|
|
16150
16153
|
function pw({
|
|
16151
16154
|
appId: e,
|
|
@@ -16164,7 +16167,7 @@ function pw({
|
|
|
16164
16167
|
onConversationClosed: d,
|
|
16165
16168
|
isConversationClosed: h
|
|
16166
16169
|
}) {
|
|
16167
|
-
const { saveConversationData: b, clearConversationData: v, updateLastActivity:
|
|
16170
|
+
const { saveConversationData: b, clearConversationData: v, updateLastActivity: w } = Hr({ appId: e }), { publishApiError: _, publishNetworkError: S } = Vt(), { showCognition: O, hideCognition: N } = cs(), k = te(
|
|
16168
16171
|
(R, A) => {
|
|
16169
16172
|
N(), c((U) => {
|
|
16170
16173
|
const q = U.filter((m) => !m.isThinking);
|
|
@@ -16190,29 +16193,29 @@ function pw({
|
|
|
16190
16193
|
});
|
|
16191
16194
|
},
|
|
16192
16195
|
[o, N, b, c, t]
|
|
16193
|
-
),
|
|
16196
|
+
), z = te(() => {
|
|
16194
16197
|
N(), c((R) => R.filter((A) => !A.isThinking));
|
|
16195
|
-
}, [c, N]), { connect: P, disconnect:
|
|
16196
|
-
onReceiveMessage:
|
|
16197
|
-
onReceiveCognition:
|
|
16198
|
-
onError:
|
|
16198
|
+
}, [c, N]), { connect: P, disconnect: M } = dw({
|
|
16199
|
+
onReceiveMessage: k,
|
|
16200
|
+
onReceiveCognition: O,
|
|
16201
|
+
onError: z,
|
|
16199
16202
|
onConversationClosed: d,
|
|
16200
16203
|
chatSettings: s
|
|
16201
|
-
}), { expectMessage: x, stopPolling:
|
|
16204
|
+
}), { expectMessage: x, stopPolling: E } = Hm({
|
|
16202
16205
|
apiClient: a,
|
|
16203
16206
|
conversationId: u?.id || null,
|
|
16204
16207
|
messages: l,
|
|
16205
16208
|
setMessages: c,
|
|
16206
16209
|
chatOpen: p,
|
|
16207
|
-
onReceiveMessage:
|
|
16210
|
+
onReceiveMessage: k,
|
|
16208
16211
|
onConversationClosed: d
|
|
16209
16212
|
}), I = te(() => {
|
|
16210
|
-
|
|
16213
|
+
M(), E(), c(
|
|
16211
16214
|
(R) => R.filter((A) => Array.isArray(A) ? !1 : A.isWelcomeMessage)
|
|
16212
16215
|
), v(), f(null);
|
|
16213
16216
|
}, [
|
|
16214
|
-
|
|
16215
|
-
|
|
16217
|
+
M,
|
|
16218
|
+
E,
|
|
16216
16219
|
v,
|
|
16217
16220
|
c,
|
|
16218
16221
|
f
|
|
@@ -16236,9 +16239,9 @@ function pw({
|
|
|
16236
16239
|
// Temporary ID
|
|
16237
16240
|
id: crypto.randomUUID()
|
|
16238
16241
|
};
|
|
16239
|
-
|
|
16242
|
+
O();
|
|
16240
16243
|
const U = [...l, A];
|
|
16241
|
-
c(U),
|
|
16244
|
+
c(U), w();
|
|
16242
16245
|
try {
|
|
16243
16246
|
let q = u?.id;
|
|
16244
16247
|
q || (q = (await a.createConversation({
|
|
@@ -16263,16 +16266,16 @@ function pw({
|
|
|
16263
16266
|
} catch (q) {
|
|
16264
16267
|
throw N(), c(
|
|
16265
16268
|
(H) => H.filter((ne) => !ne.isThinking)
|
|
16266
|
-
), q instanceof jr || q instanceof Xe && q.status === 403 ? (
|
|
16269
|
+
), q instanceof jr || q instanceof Xe && q.status === 403 ? (S(), q) : (_(q), q instanceof Xe && q.status >= 500 && (f(null), v(), c((H) => H.slice(0, -1)), a.reset()), q);
|
|
16267
16270
|
}
|
|
16268
16271
|
},
|
|
16269
16272
|
[
|
|
16270
16273
|
a,
|
|
16271
16274
|
h,
|
|
16272
|
-
|
|
16275
|
+
O,
|
|
16273
16276
|
l,
|
|
16274
16277
|
c,
|
|
16275
|
-
|
|
16278
|
+
w,
|
|
16276
16279
|
u?.id,
|
|
16277
16280
|
i,
|
|
16278
16281
|
t,
|
|
@@ -16282,7 +16285,7 @@ function pw({
|
|
|
16282
16285
|
P,
|
|
16283
16286
|
N,
|
|
16284
16287
|
_,
|
|
16285
|
-
|
|
16288
|
+
S,
|
|
16286
16289
|
v,
|
|
16287
16290
|
n,
|
|
16288
16291
|
r
|
|
@@ -16355,38 +16358,38 @@ function gw({
|
|
|
16355
16358
|
baseURL: p,
|
|
16356
16359
|
appId: t
|
|
16357
16360
|
})
|
|
16358
|
-
), [h, b] = W(null), [v,
|
|
16361
|
+
), [h, b] = W(null), [v, w] = W(null), [_, S] = W([]), [O, N] = W(!1), z = hw(`sdk-boot-${t}`, () => d.boot()).fetch;
|
|
16359
16362
|
return re(() => {
|
|
16360
16363
|
if (c())
|
|
16361
16364
|
u();
|
|
16362
16365
|
else {
|
|
16363
16366
|
const {
|
|
16364
16367
|
conversationId: P,
|
|
16365
|
-
userId:
|
|
16368
|
+
userId: M,
|
|
16366
16369
|
messages: x
|
|
16367
16370
|
} = f();
|
|
16368
|
-
P &&
|
|
16371
|
+
P && M && (w({
|
|
16369
16372
|
id: P
|
|
16370
|
-
}), x && x.length > 0 &&
|
|
16373
|
+
}), x && x.length > 0 && S(x));
|
|
16371
16374
|
}
|
|
16372
16375
|
}, [f, c, u]), re(() => {
|
|
16373
16376
|
if (!l) return;
|
|
16374
16377
|
(async () => {
|
|
16375
|
-
const [
|
|
16378
|
+
const [M, x] = await si(
|
|
16376
16379
|
d.getOrganizationByAppId(t)
|
|
16377
16380
|
);
|
|
16378
16381
|
if (x) {
|
|
16379
16382
|
console.error("Failed to fetch organization data:", x), N(!0);
|
|
16380
16383
|
return;
|
|
16381
16384
|
}
|
|
16382
|
-
d.setRegion(
|
|
16383
|
-
const [
|
|
16385
|
+
d.setRegion(M.region);
|
|
16386
|
+
const [E, I] = await si(z());
|
|
16384
16387
|
if (I) {
|
|
16385
16388
|
N(!0);
|
|
16386
16389
|
return;
|
|
16387
16390
|
}
|
|
16388
|
-
const D =
|
|
16389
|
-
b(
|
|
16391
|
+
const D = E.chat_settings.welcome_message;
|
|
16392
|
+
b(E.chat_settings), D && _.length === 0 && S([
|
|
16390
16393
|
{
|
|
16391
16394
|
id: crypto.randomUUID(),
|
|
16392
16395
|
content: D,
|
|
@@ -16406,7 +16409,7 @@ function gw({
|
|
|
16406
16409
|
chatSettings: h,
|
|
16407
16410
|
currentConversation: v,
|
|
16408
16411
|
messages: _,
|
|
16409
|
-
isReady:
|
|
16412
|
+
isReady: O
|
|
16410
16413
|
};
|
|
16411
16414
|
}
|
|
16412
16415
|
function bw(e) {
|
|
@@ -16449,18 +16452,18 @@ function yw({
|
|
|
16449
16452
|
deviceId: h,
|
|
16450
16453
|
apiClient: b,
|
|
16451
16454
|
chatSettings: v,
|
|
16452
|
-
currentConversation:
|
|
16455
|
+
currentConversation: w,
|
|
16453
16456
|
messages: _,
|
|
16454
|
-
isReady:
|
|
16457
|
+
isReady: S
|
|
16455
16458
|
} = gw({
|
|
16456
16459
|
apiUrl: t,
|
|
16457
16460
|
appId: n,
|
|
16458
16461
|
initialUserId: r,
|
|
16459
16462
|
userName: i,
|
|
16460
16463
|
userData: o
|
|
16461
|
-
}),
|
|
16464
|
+
}), O = Um({ chatProps: a, chatSettings: v }), [N, k] = W(l ?? u), z = br(N, 200), [P, M] = W(
|
|
16462
16465
|
a?.messages ?? []
|
|
16463
|
-
), [x,
|
|
16466
|
+
), [x, E] = W(w), [I, D] = W(!1), R = te(() => {
|
|
16464
16467
|
D(!0);
|
|
16465
16468
|
}, []), [A, U] = W({
|
|
16466
16469
|
text: "",
|
|
@@ -16475,19 +16478,19 @@ function yw({
|
|
|
16475
16478
|
deviceId: h,
|
|
16476
16479
|
apiClient: b,
|
|
16477
16480
|
chatSettings: v,
|
|
16478
|
-
setMessages:
|
|
16481
|
+
setMessages: M,
|
|
16479
16482
|
messages: P,
|
|
16480
16483
|
currentConversation: x,
|
|
16481
|
-
setCurrentConversation:
|
|
16484
|
+
setCurrentConversation: E,
|
|
16482
16485
|
chatOpen: N,
|
|
16483
16486
|
onConversationClosed: R,
|
|
16484
16487
|
isConversationClosed: I
|
|
16485
16488
|
});
|
|
16486
16489
|
re(() => {
|
|
16487
|
-
_.length > 0 &&
|
|
16490
|
+
_.length > 0 && M(_);
|
|
16488
16491
|
}, [_]), re(() => {
|
|
16489
|
-
|
|
16490
|
-
}, [
|
|
16492
|
+
w && E(w);
|
|
16493
|
+
}, [w]), re(() => {
|
|
16491
16494
|
x && d && b?.identifyUser({
|
|
16492
16495
|
userId: p,
|
|
16493
16496
|
userName: i,
|
|
@@ -16514,25 +16517,25 @@ function yw({
|
|
|
16514
16517
|
}));
|
|
16515
16518
|
}, []);
|
|
16516
16519
|
return re(() => {
|
|
16517
|
-
v?.auto_display_welcome_message && v?.welcome_message &&
|
|
16520
|
+
v?.auto_display_welcome_message && v?.welcome_message && S && U((ae) => ({
|
|
16518
16521
|
...ae,
|
|
16519
16522
|
text: v.welcome_message || ae.text,
|
|
16520
16523
|
isVisible: !0
|
|
16521
16524
|
}));
|
|
16522
16525
|
}, [
|
|
16523
|
-
|
|
16526
|
+
S,
|
|
16524
16527
|
v?.auto_display_welcome_message,
|
|
16525
16528
|
v?.welcome_message
|
|
16526
16529
|
]), {
|
|
16527
|
-
isReady:
|
|
16530
|
+
isReady: S,
|
|
16528
16531
|
isMobile: u,
|
|
16529
|
-
chatInterfaceProps:
|
|
16532
|
+
chatInterfaceProps: O,
|
|
16530
16533
|
chatOpen: N,
|
|
16531
|
-
chatOpenDebounced:
|
|
16534
|
+
chatOpenDebounced: z,
|
|
16532
16535
|
messages: P,
|
|
16533
16536
|
portalContainer: f,
|
|
16534
16537
|
onSendMessage: q,
|
|
16535
|
-
setChatOpen:
|
|
16538
|
+
setChatOpen: k,
|
|
16536
16539
|
onCleanMessages: H,
|
|
16537
16540
|
proactiveMessage: A,
|
|
16538
16541
|
hideProactiveMessage: m,
|
|
@@ -16562,7 +16565,7 @@ function xw({
|
|
|
16562
16565
|
children: e
|
|
16563
16566
|
}) {
|
|
16564
16567
|
const t = ww();
|
|
16565
|
-
return /* @__PURE__ */
|
|
16568
|
+
return /* @__PURE__ */ y(ls.Provider, { value: t, children: e });
|
|
16566
16569
|
}
|
|
16567
16570
|
const vw = ({
|
|
16568
16571
|
children: e
|
|
@@ -16575,7 +16578,7 @@ const vw = ({
|
|
|
16575
16578
|
publishNetworkError: () => i(!0),
|
|
16576
16579
|
clearError: () => n(null)
|
|
16577
16580
|
};
|
|
16578
|
-
return /* @__PURE__ */
|
|
16581
|
+
return /* @__PURE__ */ y(ds.Provider, { value: c, children: e });
|
|
16579
16582
|
}, kw = 100;
|
|
16580
16583
|
function Sw({
|
|
16581
16584
|
appId: e,
|
|
@@ -16596,17 +16599,17 @@ function Sw({
|
|
|
16596
16599
|
INTERNAL_ONLY_ENVIRONMENT: b = "live",
|
|
16597
16600
|
INTERNAL_ONLY_API_URL: v
|
|
16598
16601
|
}) {
|
|
16599
|
-
const { hideSdk:
|
|
16602
|
+
const { hideSdk: w } = Vt(), {
|
|
16600
16603
|
isReady: _,
|
|
16601
|
-
isMobile:
|
|
16602
|
-
chatOpen:
|
|
16604
|
+
isMobile: S,
|
|
16605
|
+
chatOpen: O,
|
|
16603
16606
|
chatInterfaceProps: N,
|
|
16604
|
-
chatOpenDebounced:
|
|
16605
|
-
messages:
|
|
16607
|
+
chatOpenDebounced: k,
|
|
16608
|
+
messages: z,
|
|
16606
16609
|
portalContainer: P,
|
|
16607
|
-
onSendMessage:
|
|
16610
|
+
onSendMessage: M,
|
|
16608
16611
|
setChatOpen: x,
|
|
16609
|
-
onCleanMessages:
|
|
16612
|
+
onCleanMessages: E,
|
|
16610
16613
|
proactiveMessage: I,
|
|
16611
16614
|
hideProactiveMessage: D,
|
|
16612
16615
|
isConversationClosed: R,
|
|
@@ -16623,7 +16626,7 @@ function Sw({
|
|
|
16623
16626
|
initialOpen: c,
|
|
16624
16627
|
proactiveMessageHideDelay: o
|
|
16625
16628
|
});
|
|
16626
|
-
if (
|
|
16629
|
+
if (w) return null;
|
|
16627
16630
|
const U = () => /* @__PURE__ */ B(
|
|
16628
16631
|
"div",
|
|
16629
16632
|
{
|
|
@@ -16640,37 +16643,37 @@ function Sw({
|
|
|
16640
16643
|
...p ? { position: "relative", inset: 0, width: "100%", height: "100%" } : {}
|
|
16641
16644
|
},
|
|
16642
16645
|
children: [
|
|
16643
|
-
/* @__PURE__ */
|
|
16644
|
-
/* @__PURE__ */
|
|
16646
|
+
/* @__PURE__ */ y("style", { children: _l }),
|
|
16647
|
+
/* @__PURE__ */ y(
|
|
16645
16648
|
Bn,
|
|
16646
16649
|
{
|
|
16647
16650
|
className: "eloquentai-chat-messaging",
|
|
16648
16651
|
head: /* @__PURE__ */ B(We, { children: [
|
|
16649
|
-
/* @__PURE__ */
|
|
16650
|
-
/* @__PURE__ */
|
|
16651
|
-
/* @__PURE__ */
|
|
16652
|
+
/* @__PURE__ */ y("link", { rel: "preconnect", href: "https://fonts.googleapis.com" }),
|
|
16653
|
+
/* @__PURE__ */ y("link", { rel: "preconnect", href: "https://fonts.gstatic.com" }),
|
|
16654
|
+
/* @__PURE__ */ y(
|
|
16652
16655
|
"link",
|
|
16653
16656
|
{
|
|
16654
16657
|
href: "https://fonts.googleapis.com/css2?family=Roboto:ital,wght@0,100;0,300;0,400;0,500;0,700;0,900;1,100;1,300;1,400;1,500;1,700;1,900&display=swap",
|
|
16655
16658
|
rel: "stylesheet"
|
|
16656
16659
|
}
|
|
16657
16660
|
),
|
|
16658
|
-
/* @__PURE__ */
|
|
16661
|
+
/* @__PURE__ */ y("style", { children: Sn })
|
|
16659
16662
|
] }),
|
|
16660
16663
|
style: {
|
|
16661
|
-
display:
|
|
16662
|
-
width:
|
|
16664
|
+
display: O || k ? "block" : "none",
|
|
16665
|
+
width: S ? "100vw" : "400px",
|
|
16663
16666
|
// 100dvh accounts for mobile browser chrome (e.g. address bar); 100vh fallback for older browsers
|
|
16664
16667
|
"--chat-mobile-viewport-height": "100dvh",
|
|
16665
|
-
height:
|
|
16666
|
-
maxHeight:
|
|
16668
|
+
height: S ? "var(--chat-mobile-viewport-height, 100vh)" : "700px",
|
|
16669
|
+
maxHeight: S ? "var(--chat-mobile-viewport-height, 100vh)" : `calc(100% - ${kw}px)`,
|
|
16667
16670
|
border: "none",
|
|
16668
16671
|
zIndex: 2147483e3,
|
|
16669
16672
|
position: "fixed",
|
|
16670
|
-
top:
|
|
16671
|
-
left:
|
|
16672
|
-
right:
|
|
16673
|
-
bottom:
|
|
16673
|
+
top: S ? 0 : void 0,
|
|
16674
|
+
left: S ? 0 : void 0,
|
|
16675
|
+
right: S ? 0 : 17,
|
|
16676
|
+
bottom: S ? 0 : 84,
|
|
16674
16677
|
...p ? {
|
|
16675
16678
|
position: "relative",
|
|
16676
16679
|
top: 0,
|
|
@@ -16683,32 +16686,32 @@ function Sw({
|
|
|
16683
16686
|
zIndex: 0
|
|
16684
16687
|
} : {}
|
|
16685
16688
|
},
|
|
16686
|
-
children: _ ? /* @__PURE__ */
|
|
16689
|
+
children: _ ? /* @__PURE__ */ y(
|
|
16687
16690
|
zm,
|
|
16688
16691
|
{
|
|
16689
16692
|
...N,
|
|
16690
|
-
isOpen:
|
|
16691
|
-
messages:
|
|
16692
|
-
onSendMessage:
|
|
16693
|
+
isOpen: O,
|
|
16694
|
+
messages: z,
|
|
16695
|
+
onSendMessage: M,
|
|
16693
16696
|
onMessageClick: d,
|
|
16694
|
-
isMobile:
|
|
16697
|
+
isMobile: S,
|
|
16695
16698
|
closeButton: s,
|
|
16696
16699
|
cleanChatButton: l,
|
|
16697
16700
|
isConversationClosed: R,
|
|
16698
16701
|
onStartNewConversation: A,
|
|
16699
16702
|
onClose: () => x(!1),
|
|
16700
16703
|
onCleanChat: () => {
|
|
16701
|
-
|
|
16704
|
+
E(), h?.();
|
|
16702
16705
|
}
|
|
16703
16706
|
}
|
|
16704
|
-
) : /* @__PURE__ */
|
|
16707
|
+
) : /* @__PURE__ */ y(ms, { isOpen: O, isMobile: S })
|
|
16705
16708
|
}
|
|
16706
16709
|
),
|
|
16707
|
-
!u && /* @__PURE__ */
|
|
16710
|
+
!u && /* @__PURE__ */ y(
|
|
16708
16711
|
Bn,
|
|
16709
16712
|
{
|
|
16710
16713
|
className: "eloquentai-chat-launcher",
|
|
16711
|
-
head: /* @__PURE__ */
|
|
16714
|
+
head: /* @__PURE__ */ y("style", { children: Sn }),
|
|
16712
16715
|
style: {
|
|
16713
16716
|
position: "fixed",
|
|
16714
16717
|
bottom: 17,
|
|
@@ -16717,28 +16720,28 @@ function Sw({
|
|
|
16717
16720
|
width: 48,
|
|
16718
16721
|
height: 48,
|
|
16719
16722
|
border: "none",
|
|
16720
|
-
zIndex:
|
|
16723
|
+
zIndex: S ? 2147482999 : 2147483e3
|
|
16721
16724
|
},
|
|
16722
|
-
children: /* @__PURE__ */
|
|
16725
|
+
children: /* @__PURE__ */ y(
|
|
16723
16726
|
Al,
|
|
16724
16727
|
{
|
|
16725
|
-
isOpen:
|
|
16728
|
+
isOpen: O,
|
|
16726
16729
|
toggleBubble: () => x((H) => !H)
|
|
16727
16730
|
}
|
|
16728
16731
|
)
|
|
16729
16732
|
}
|
|
16730
16733
|
),
|
|
16731
|
-
N?.displayWelcomeMessages ? /* @__PURE__ */
|
|
16734
|
+
N?.displayWelcomeMessages ? /* @__PURE__ */ y(
|
|
16732
16735
|
Bn,
|
|
16733
16736
|
{
|
|
16734
16737
|
className: "eloquentai-chat-proactive-message",
|
|
16735
|
-
head: /* @__PURE__ */
|
|
16738
|
+
head: /* @__PURE__ */ y("style", { children: Sn }),
|
|
16736
16739
|
style: {
|
|
16737
16740
|
position: "fixed",
|
|
16738
16741
|
bottom: 30,
|
|
16739
16742
|
right: 17
|
|
16740
16743
|
},
|
|
16741
|
-
children: /* @__PURE__ */
|
|
16744
|
+
children: /* @__PURE__ */ y(Vo, { ...N?.theme ?? {}, children: !f && I && !c && /* @__PURE__ */ y(
|
|
16742
16745
|
qm,
|
|
16743
16746
|
{
|
|
16744
16747
|
message: I.text,
|
|
@@ -16755,15 +16758,15 @@ function Sw({
|
|
|
16755
16758
|
]
|
|
16756
16759
|
}
|
|
16757
16760
|
);
|
|
16758
|
-
return /* @__PURE__ */
|
|
16761
|
+
return /* @__PURE__ */ y(We, { children: p ? U() : P ? /* @__PURE__ */ y(Fm, { container: P, children: U() }) : null });
|
|
16759
16762
|
}
|
|
16760
16763
|
function Ew(e) {
|
|
16761
|
-
return /* @__PURE__ */
|
|
16764
|
+
return /* @__PURE__ */ y(vw, { children: /* @__PURE__ */ y(xw, { children: /* @__PURE__ */ y(Sw, { ...e }) }) });
|
|
16762
16765
|
}
|
|
16763
16766
|
function Mw(e, t) {
|
|
16764
16767
|
return ((r, i, o) => {
|
|
16765
16768
|
const a = Cl.createRoot(i);
|
|
16766
|
-
return a.render(/* @__PURE__ */
|
|
16769
|
+
return a.render(/* @__PURE__ */ y(r, { ...o })), a.unmount;
|
|
16767
16770
|
})(Ew, e, t);
|
|
16768
16771
|
}
|
|
16769
16772
|
export {
|
|
@@ -16772,4 +16775,4 @@ export {
|
|
|
16772
16775
|
aa as g,
|
|
16773
16776
|
Mw as r
|
|
16774
16777
|
};
|
|
16775
|
-
//# sourceMappingURL=index-
|
|
16778
|
+
//# sourceMappingURL=index-Dqos2v0b.js.map
|