@multiplayer-app/ai-agent-react 0.1.0-beta.88 → 0.1.0-beta.89
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/ai-agent-react.cjs.js +14 -14
- package/dist/ai-agent-react.cjs.js.map +1 -1
- package/dist/ai-agent-react.es.js +202 -195
- package/dist/ai-agent-react.es.js.map +1 -1
- package/dist/components/Attachments/Attachments.d.ts.map +1 -1
- package/dist/components/ChatWindow/MessageList/Message/MessageAttachments.d.ts.map +1 -1
- package/dist/config/types.d.ts +8 -2
- package/dist/config/types.d.ts.map +1 -1
- package/package.json +2 -2
|
@@ -29897,8 +29897,8 @@ function pp(e, t) {
|
|
|
29897
29897
|
Array.from(N).every((fe) => !Nr(K, fe)))
|
|
29898
29898
|
return;
|
|
29899
29899
|
if (Ct($) && Q) {
|
|
29900
|
-
const fe = Hn($), ke = hn($), Ce = /auto|scroll/, Pe = fe || Ce.test(ke.overflowX), ot = fe || Ce.test(ke.overflowY), We = Pe && $.clientWidth > 0 && $.scrollWidth > $.clientWidth, re = ot && $.clientHeight > 0 && $.scrollHeight > $.clientHeight, Se = ke.direction === "rtl",
|
|
29901
|
-
if (
|
|
29900
|
+
const fe = Hn($), ke = hn($), Ce = /auto|scroll/, Pe = fe || Ce.test(ke.overflowX), ot = fe || Ce.test(ke.overflowY), We = Pe && $.clientWidth > 0 && $.scrollWidth > $.clientWidth, re = ot && $.clientHeight > 0 && $.scrollHeight > $.clientHeight, Se = ke.direction === "rtl", He = re && (Se ? W.offsetX <= $.offsetWidth - $.clientWidth : W.offsetX > $.clientWidth), Ye = We && W.offsetY > $.clientHeight;
|
|
29901
|
+
if (He || Ye)
|
|
29902
29902
|
return;
|
|
29903
29903
|
}
|
|
29904
29904
|
const J = (R = i.current.floatingContext) == null ? void 0 : R.nodeId, O = f && ka(f.nodesRef.current, J).some((fe) => {
|
|
@@ -30287,7 +30287,7 @@ function i7e(e, t) {
|
|
|
30287
30287
|
}, [e, E]);
|
|
30288
30288
|
const R = Qt(() => {
|
|
30289
30289
|
l($.current === -1 ? null : $.current);
|
|
30290
|
-
}), U = G6e(a.domReference), H = ee.useRef(w), $ = ee.useRef(d ?? -1), V = ee.useRef(null), N = ee.useRef(!0), K = ee.useRef(R), J = ee.useRef(!!a.floating), O = ee.useRef(n), le = ee.useRef(!1), fe = ee.useRef(!1), ke = Bn(_), Ce = Bn(n), Pe = Bn(D), ot = Bn(d), [We, re] = ee.useState(), [Se,
|
|
30290
|
+
}), U = G6e(a.domReference), H = ee.useRef(w), $ = ee.useRef(d ?? -1), V = ee.useRef(null), N = ee.useRef(!0), K = ee.useRef(R), J = ee.useRef(!!a.floating), O = ee.useRef(n), le = ee.useRef(!1), fe = ee.useRef(!1), ke = Bn(_), Ce = Bn(n), Pe = Bn(D), ot = Bn(d), [We, re] = ee.useState(), [Se, He] = ee.useState(), Ye = Qt(() => {
|
|
30291
30291
|
function ce(q) {
|
|
30292
30292
|
if (f) {
|
|
30293
30293
|
var Y;
|
|
@@ -30339,7 +30339,7 @@ function i7e(e, t) {
|
|
|
30339
30339
|
if (!u || !W || !f || Q)
|
|
30340
30340
|
return;
|
|
30341
30341
|
function ce(Me) {
|
|
30342
|
-
|
|
30342
|
+
He(Me.id), P && (P.current = Me);
|
|
30343
30343
|
}
|
|
30344
30344
|
return W.events.on("virtualfocus", ce), () => {
|
|
30345
30345
|
W.events.off("virtualfocus", ce);
|
|
@@ -30465,7 +30465,7 @@ function i7e(e, t) {
|
|
|
30465
30465
|
onPointerMove() {
|
|
30466
30466
|
N.current = !0;
|
|
30467
30467
|
}
|
|
30468
|
-
}), [tt, de, E, U]),
|
|
30468
|
+
}), [tt, de, E, U]), je = ee.useMemo(() => {
|
|
30469
30469
|
function ce(ye) {
|
|
30470
30470
|
w === "auto" && Z6e(ye.nativeEvent) && (H.current = !0);
|
|
30471
30471
|
}
|
|
@@ -30487,7 +30487,7 @@ function i7e(e, t) {
|
|
|
30487
30487
|
if (te || pe) {
|
|
30488
30488
|
var Mt, Qn;
|
|
30489
30489
|
const N7 = ((Mt = Ot.context) == null ? void 0 : Mt.elements.domReference) === ye.currentTarget, Uh = pe && !N7 ? (Qn = Ot.context) == null ? void 0 : Qn.elements.domReference : te ? o.current.find((Hh) => Hh?.id === We) : null;
|
|
30490
|
-
Uh && (an(ye), Uh.dispatchEvent(qt),
|
|
30490
|
+
Uh && (an(ye), Uh.dispatchEvent(qt), He(void 0));
|
|
30491
30491
|
}
|
|
30492
30492
|
if ((Le || q) && Ot.context && Ot.context.open && Ot.parentId && ye.currentTarget !== Ot.context.elements.domReference) {
|
|
30493
30493
|
var Jn;
|
|
@@ -30519,10 +30519,10 @@ function i7e(e, t) {
|
|
|
30519
30519
|
};
|
|
30520
30520
|
}, [We, tt, x, de, ke, w, o, h, R, r, n, k, E, Ke, g, d, W, f, P]);
|
|
30521
30521
|
return ee.useMemo(() => u ? {
|
|
30522
|
-
reference:
|
|
30522
|
+
reference: je,
|
|
30523
30523
|
floating: Ze,
|
|
30524
30524
|
item: ve
|
|
30525
|
-
} : {}, [u,
|
|
30525
|
+
} : {}, [u, je, Ze, ve]);
|
|
30526
30526
|
}
|
|
30527
30527
|
const o7e = /* @__PURE__ */ new Map([["select", "listbox"], ["combobox", "listbox"], ["label", !1]]);
|
|
30528
30528
|
function fp(e, t) {
|
|
@@ -30675,7 +30675,7 @@ const An = ({
|
|
|
30675
30675
|
}
|
|
30676
30676
|
}, "aria-label": "Copy message", size: "sm" }) });
|
|
30677
30677
|
}, gn = () => {
|
|
30678
|
-
const e =
|
|
30678
|
+
const e = Ue();
|
|
30679
30679
|
return { ...od, ...e.config.translations ?? {} };
|
|
30680
30680
|
}, x2 = 300, c3 = Rt(({ field: e, isExpanded: t, canApply: n, onToggleExpand: r, onApply: a }) => {
|
|
30681
30681
|
const i = gn(), o = e.value.length > x2, s = o && !t ? `${e.value.slice(0, x2)}...` : e.value, l = Xe(() => {
|
|
@@ -30733,7 +30733,7 @@ const Ha = 30 * 1e3, Va = 5 * 60 * 1e3, u3 = 20, on = {
|
|
|
30733
30733
|
data: [],
|
|
30734
30734
|
cursor: { total: 0, skip: 0, limit: e }
|
|
30735
30735
|
}), CVe = (e) => {
|
|
30736
|
-
const t =
|
|
30736
|
+
const t = Ue(), {
|
|
30737
30737
|
groupId: n,
|
|
30738
30738
|
parentId: r,
|
|
30739
30739
|
sourceType: a,
|
|
@@ -30776,7 +30776,7 @@ const Ha = 30 * 1e3, Va = 5 * 60 * 1e3, u3 = 20, on = {
|
|
|
30776
30776
|
gcTime: Va
|
|
30777
30777
|
});
|
|
30778
30778
|
}, RVe = (e) => {
|
|
30779
|
-
const t =
|
|
30779
|
+
const t = Ue(), {
|
|
30780
30780
|
groupId: n,
|
|
30781
30781
|
parentId: r,
|
|
30782
30782
|
sourceType: a,
|
|
@@ -30820,7 +30820,7 @@ const Ha = 30 * 1e3, Va = 5 * 60 * 1e3, u3 = 20, on = {
|
|
|
30820
30820
|
hasPreviousPage: i > 1
|
|
30821
30821
|
};
|
|
30822
30822
|
}, IVe = (e) => {
|
|
30823
|
-
const t =
|
|
30823
|
+
const t = Ue();
|
|
30824
30824
|
return fr({
|
|
30825
30825
|
queryKey: on.detail(e),
|
|
30826
30826
|
queryFn: async () => !e || !t.transport.getActivity ? null : t.transport.getActivity(e),
|
|
@@ -30829,7 +30829,7 @@ const Ha = 30 * 1e3, Va = 5 * 60 * 1e3, u3 = 20, on = {
|
|
|
30829
30829
|
gcTime: Va
|
|
30830
30830
|
});
|
|
30831
30831
|
}, OVe = (e) => {
|
|
30832
|
-
const t =
|
|
30832
|
+
const t = Ue(), { enabled: n = !0, ...r } = e ?? {};
|
|
30833
30833
|
return fr({
|
|
30834
30834
|
queryKey: on.summary(r),
|
|
30835
30835
|
queryFn: async () => t.transport.getActivitySummary ? t.transport.getActivitySummary(r) : [],
|
|
@@ -30838,7 +30838,7 @@ const Ha = 30 * 1e3, Va = 5 * 60 * 1e3, u3 = 20, on = {
|
|
|
30838
30838
|
gcTime: Va
|
|
30839
30839
|
});
|
|
30840
30840
|
}, LVe = (e) => {
|
|
30841
|
-
const t =
|
|
30841
|
+
const t = Ue(), { enabled: n = !0, groupId: r, parentId: a, from: i, to: o, tenant: s, ownerId: l } = e ?? {}, u = i instanceof Date ? i.toISOString() : i, d = o instanceof Date ? o.toISOString() : o;
|
|
30842
30842
|
return fr({
|
|
30843
30843
|
queryKey: on.sourceTypes({ groupId: r, parentId: a, from: u, to: d, tenant: s, ownerId: l }),
|
|
30844
30844
|
queryFn: async () => t.transport.listActivitySourceTypes ? t.transport.listActivitySourceTypes({
|
|
@@ -30871,7 +30871,7 @@ const h3 = 30 * 1e3, m3 = 5 * 60 * 1e3, yp = 20, ar = {
|
|
|
30871
30871
|
infinite: (e) => [...ar.infinites(), e],
|
|
30872
30872
|
detail: (e) => [...ar.all, "detail", e]
|
|
30873
30873
|
}, s7e = (e) => e?.pages.flatMap((t) => t.data) ?? [], f3 = (e) => {
|
|
30874
|
-
const t =
|
|
30874
|
+
const t = Ue(), n = t.config.user?.id ?? na(), r = t.config.appId, {
|
|
30875
30875
|
pageSize: a = yp,
|
|
30876
30876
|
sortOrder: i = "desc",
|
|
30877
30877
|
sortField: o = "updatedAt",
|
|
@@ -30898,7 +30898,7 @@ const h3 = 30 * 1e3, m3 = 5 * 60 * 1e3, yp = 20, ar = {
|
|
|
30898
30898
|
gcTime: m3
|
|
30899
30899
|
});
|
|
30900
30900
|
}, l7e = f3, DVe = (e) => {
|
|
30901
|
-
const t =
|
|
30901
|
+
const t = Ue(), n = t.config.user?.id ?? na(), r = t.config.appId, {
|
|
30902
30902
|
page: a,
|
|
30903
30903
|
pageSize: i = yp,
|
|
30904
30904
|
sortOrder: o = "desc",
|
|
@@ -31014,7 +31014,7 @@ const h3 = 30 * 1e3, m3 = 5 * 60 * 1e3, yp = 20, ar = {
|
|
|
31014
31014
|
checkIsNearBottom: m
|
|
31015
31015
|
};
|
|
31016
31016
|
}, c7e = () => {
|
|
31017
|
-
const e =
|
|
31017
|
+
const e = Ue();
|
|
31018
31018
|
return fr({
|
|
31019
31019
|
queryKey: ["mp-agents", "models"],
|
|
31020
31020
|
queryFn: async () => e.transport.listModels ? await e.transport.listModels() : [],
|
|
@@ -31394,7 +31394,7 @@ const Wi = (e) => e === Kr.Streaming || e === Kr.Processing || e === Kr.WaitingF
|
|
|
31394
31394
|
removeAttachment: (s) => o(e, s)
|
|
31395
31395
|
};
|
|
31396
31396
|
}, p7e = (e) => {
|
|
31397
|
-
const t =
|
|
31397
|
+
const t = Ue();
|
|
31398
31398
|
return fr({
|
|
31399
31399
|
queryKey: ["mp-agents", "configurations", e ?? "all"],
|
|
31400
31400
|
queryFn: async () => t.transport.listAgentConfigurations ? t.transport.listAgentConfigurations(e) : [],
|
|
@@ -31402,12 +31402,12 @@ const Wi = (e) => e === Kr.Streaming || e === Kr.Processing || e === Kr.WaitingF
|
|
|
31402
31402
|
refetchOnWindowFocus: !1
|
|
31403
31403
|
});
|
|
31404
31404
|
}, zVe = (e, t = []) => {
|
|
31405
|
-
const n =
|
|
31405
|
+
const n = Ue(), r = Fe(e), a = Xe(e, t);
|
|
31406
31406
|
r.current = a;
|
|
31407
31407
|
const i = Xe((o) => r.current(o), []);
|
|
31408
31408
|
$e(() => n.registerPageContextProvider(i), [n, i]);
|
|
31409
31409
|
}, h7e = (e) => {
|
|
31410
|
-
const t =
|
|
31410
|
+
const t = Ue();
|
|
31411
31411
|
return Xe(
|
|
31412
31412
|
(r) => {
|
|
31413
31413
|
t.events.dispatchEvent(
|
|
@@ -31419,7 +31419,7 @@ const Wi = (e) => e === Kr.Streaming || e === Kr.Processing || e === Kr.WaitingF
|
|
|
31419
31419
|
[t, e]
|
|
31420
31420
|
);
|
|
31421
31421
|
}, m7e = (e, t, n = [], r) => {
|
|
31422
|
-
const a =
|
|
31422
|
+
const a = Ue(), i = Fe(t), o = Xe(t, n);
|
|
31423
31423
|
i.current = o;
|
|
31424
31424
|
const s = Xe((u) => {
|
|
31425
31425
|
i.current(u);
|
|
@@ -31436,7 +31436,7 @@ const Wi = (e) => e === Kr.Streaming || e === Kr.Processing || e === Kr.WaitingF
|
|
|
31436
31436
|
[n, e, t]
|
|
31437
31437
|
);
|
|
31438
31438
|
}, f7e = ["mp-agents", "configurations"], g7e = () => {
|
|
31439
|
-
const e =
|
|
31439
|
+
const e = Ue(), t = w5(), n = () => t.invalidateQueries({
|
|
31440
31440
|
queryKey: f7e
|
|
31441
31441
|
}), r = Vh({
|
|
31442
31442
|
mutationFn: async ({ agentName: i, input: o }) => {
|
|
@@ -31458,7 +31458,7 @@ const Wi = (e) => e === Kr.Streaming || e === Kr.Processing || e === Kr.WaitingF
|
|
|
31458
31458
|
upsertBatch: a
|
|
31459
31459
|
};
|
|
31460
31460
|
}, y7e = () => {
|
|
31461
|
-
const e =
|
|
31461
|
+
const e = Ue(), t = be((s) => s.activeChatId), n = be((s) => s.upsertChat), r = be((s) => s.setActiveChat), a = be((s) => s.setChatStatus), o = fr({
|
|
31462
31462
|
queryKey: ["mp-agents", "chat", t],
|
|
31463
31463
|
queryFn: () => e.transport.getChat(t),
|
|
31464
31464
|
enabled: !!t,
|
|
@@ -31471,7 +31471,7 @@ const Wi = (e) => e === Kr.Streaming || e === Kr.Processing || e === Kr.WaitingF
|
|
|
31471
31471
|
o.isError && t && r(void 0);
|
|
31472
31472
|
}, [o.isError, t, r]), o;
|
|
31473
31473
|
}, b7e = 20, b3 = (e) => {
|
|
31474
|
-
const t =
|
|
31474
|
+
const t = Ue(), n = t.config.messagesPageSize ?? b7e, r = be((o) => o.setChatMessages), a = be((o) => !!(e && o.chats[e])), i = Qd({
|
|
31475
31475
|
queryKey: ["mp-agents", "messages", e, n],
|
|
31476
31476
|
queryFn: async ({ pageParam: o }) => {
|
|
31477
31477
|
if (!e || !t.transport.getMessages)
|
|
@@ -31496,7 +31496,7 @@ const Wi = (e) => e === Kr.Streaming || e === Kr.Processing || e === Kr.WaitingF
|
|
|
31496
31496
|
});
|
|
31497
31497
|
}, [e, i.data, r]), i;
|
|
31498
31498
|
}, k3 = () => {
|
|
31499
|
-
const e =
|
|
31499
|
+
const e = Ue(), t = e.config.user?.id ?? na(), n = be((u) => u.activeChatId), r = be((u) => u.removeChat), a = be((u) => u.setActiveChat), [i, o] = et(/* @__PURE__ */ new Set()), s = Xe(
|
|
31500
31500
|
async (u) => {
|
|
31501
31501
|
o((d) => new Set(d).add(u));
|
|
31502
31502
|
try {
|
|
@@ -31545,7 +31545,7 @@ const Wi = (e) => e === Kr.Streaming || e === Kr.Processing || e === Kr.WaitingF
|
|
|
31545
31545
|
applyAllButtonText: n,
|
|
31546
31546
|
showStatus: r = !0
|
|
31547
31547
|
}) => {
|
|
31548
|
-
const a =
|
|
31548
|
+
const a = Ue(), i = h7e(O5), o = gn(), s = lt(() => v7e(e), [e]), [l, u] = et(/* @__PURE__ */ new Set()), d = lt(() => {
|
|
31549
31549
|
const x = (e.output ?? {})?._mp?.lastAction, D = typeof x?.action == "string" ? x.action : void 0, P = typeof x?.at == "string" ? x.at : void 0;
|
|
31550
31550
|
return { action: D, at: P };
|
|
31551
31551
|
}, [e.output]), p = lt(() => d.action === "apply", [d.action]), m = lt(() => d.action === "reject", [d.action]), h = lt(
|
|
@@ -34401,7 +34401,7 @@ Object.assign(Oi, {
|
|
|
34401
34401
|
connect: Oi
|
|
34402
34402
|
});
|
|
34403
34403
|
const T_e = Zd(null), C_e = ({ children: e }) => {
|
|
34404
|
-
const t =
|
|
34404
|
+
const t = Ue(), n = be((v) => v.upsertChat), r = be((v) => v.upsertChatState), a = be((v) => v.contextKey), i = be((v) => v.activeChatId), o = lt(() => t.config.user?.id ?? na(), [t.config.user?.id]), s = t.config.transport, [l, u] = et(null), [d, p] = et(void 0), m = Fe(a), h = Fe(n), g = Fe(r), f = Fe(void 0);
|
|
34405
34405
|
$e(() => {
|
|
34406
34406
|
m.current = a, h.current = n, g.current = r;
|
|
34407
34407
|
}, [a, n, r]), $e(() => {
|
|
@@ -34514,7 +34514,7 @@ const T_e = Zd(null), C_e = ({ children: e }) => {
|
|
|
34514
34514
|
D7e(u, l);
|
|
34515
34515
|
});
|
|
34516
34516
|
}, []), /* @__PURE__ */ C(Ep.Provider, { value: i, children: /* @__PURE__ */ C(C7, { client: i.runtime.queryClient, children: /* @__PURE__ */ C(T7e, { value: i.runtime.config.theme, children: /* @__PURE__ */ C(C_e, { children: t }) }) }) });
|
|
34517
|
-
},
|
|
34517
|
+
}, Ue = () => {
|
|
34518
34518
|
const e = Xd(Ep);
|
|
34519
34519
|
if (!e)
|
|
34520
34520
|
throw new Error("useAgentRuntime must be used inside <AgentProvider />");
|
|
@@ -34530,7 +34530,7 @@ const T_e = Zd(null), C_e = ({ children: e }) => {
|
|
|
34530
34530
|
multiUser: n = !1,
|
|
34531
34531
|
participantIds: r = []
|
|
34532
34532
|
}) => {
|
|
34533
|
-
const a =
|
|
34533
|
+
const a = Ue(), {
|
|
34534
34534
|
composer: i,
|
|
34535
34535
|
contextKey: o,
|
|
34536
34536
|
activeChatId: s,
|
|
@@ -34600,9 +34600,9 @@ const T_e = Zd(null), C_e = ({ children: e }) => {
|
|
|
34600
34600
|
const ce = await Z(V, K);
|
|
34601
34601
|
ce && ce.trim().length > 0 && (ke = { ...ke ?? {}, title: ce });
|
|
34602
34602
|
}
|
|
34603
|
-
const Ce = a.store.getState(), Pe = s ? Ce.chats[s] : void 0, We = (s ? Ce.chatState[s] : void 0)?.messages ?? [], re = N.filter((ce) => P3(ce) ? !I_e(We, ce) : !0), Se = Pe?.model,
|
|
34603
|
+
const Ce = a.store.getState(), Pe = s ? Ce.chats[s] : void 0, We = (s ? Ce.chatState[s] : void 0)?.messages ?? [], re = N.filter((ce) => P3(ce) ? !I_e(We, ce) : !0), Se = Pe?.model, He = i.model !== Se;
|
|
34604
34604
|
let Ye, Ae = !1;
|
|
34605
|
-
|
|
34605
|
+
He ? (Ye = i.model, Ae = !0) : Se ? (Ye = Se, Ae = !1) : (Ye = void 0, Ae = !1);
|
|
34606
34606
|
const ve = O_e(V), Ke = {
|
|
34607
34607
|
userId: K,
|
|
34608
34608
|
content: V,
|
|
@@ -34635,7 +34635,7 @@ const T_e = Zd(null), C_e = ({ children: e }) => {
|
|
|
34635
34635
|
} catch (ce) {
|
|
34636
34636
|
return tt(ce);
|
|
34637
34637
|
}
|
|
34638
|
-
},
|
|
34638
|
+
}, je = async () => {
|
|
34639
34639
|
let ce = `pending-${Date.now()}`, Me = "", ye;
|
|
34640
34640
|
m(le.current, Nt.Streaming), v(le.current, {
|
|
34641
34641
|
id: ce,
|
|
@@ -34693,7 +34693,7 @@ const T_e = Zd(null), C_e = ({ children: e }) => {
|
|
|
34693
34693
|
}
|
|
34694
34694
|
};
|
|
34695
34695
|
try {
|
|
34696
|
-
const ce = await (n ? Ze() :
|
|
34696
|
+
const ce = await (n ? Ze() : je());
|
|
34697
34697
|
return ce.type === "success" && (D.current = !1), ce;
|
|
34698
34698
|
} catch (ce) {
|
|
34699
34699
|
de();
|
|
@@ -34899,14 +34899,17 @@ function z_e() {
|
|
|
34899
34899
|
// All types allowed by default
|
|
34900
34900
|
};
|
|
34901
34901
|
}
|
|
34902
|
-
const q3 = (e) => {
|
|
34902
|
+
const q3 = (e, t) => {
|
|
34903
34903
|
switch (e.type) {
|
|
34904
34904
|
case bt.Link:
|
|
34905
34905
|
return /* @__PURE__ */ C(A5, { size: 12 });
|
|
34906
34906
|
case bt.Artifact:
|
|
34907
34907
|
return /* @__PURE__ */ C(ho, { size: 12 });
|
|
34908
|
-
case bt.Context:
|
|
34909
|
-
|
|
34908
|
+
case bt.Context: {
|
|
34909
|
+
const n = e?.metadata?.kind;
|
|
34910
|
+
if (n && t?.[n])
|
|
34911
|
+
return t[n];
|
|
34912
|
+
switch (n) {
|
|
34910
34913
|
case "pageContext":
|
|
34911
34914
|
return /* @__PURE__ */ C(tp, { size: 12 });
|
|
34912
34915
|
case "formSnapshot":
|
|
@@ -34915,62 +34918,66 @@ const q3 = (e) => {
|
|
|
34915
34918
|
default:
|
|
34916
34919
|
return /* @__PURE__ */ C(np, { size: 12 });
|
|
34917
34920
|
}
|
|
34921
|
+
}
|
|
34918
34922
|
case bt.File:
|
|
34919
34923
|
default:
|
|
34920
34924
|
return /* @__PURE__ */ C(S5, { size: 12 });
|
|
34921
34925
|
}
|
|
34922
|
-
}, F_e = ({ attachments: e }) =>
|
|
34923
|
-
const
|
|
34924
|
-
|
|
34925
|
-
/* @__PURE__ */
|
|
34926
|
-
|
|
34927
|
-
|
|
34928
|
-
|
|
34929
|
-
|
|
34930
|
-
|
|
34931
|
-
|
|
34932
|
-
|
|
34933
|
-
|
|
34934
|
-
|
|
34935
|
-
|
|
34936
|
-
|
|
34937
|
-
|
|
34938
|
-
|
|
34939
|
-
|
|
34940
|
-
|
|
34941
|
-
|
|
34942
|
-
|
|
34926
|
+
}, F_e = ({ attachments: e }) => {
|
|
34927
|
+
const { config: t } = Ue();
|
|
34928
|
+
return !e || e.length === 0 ? null : /* @__PURE__ */ C("div", { className: "mp-agent-message-attachments", "aria-label": "Message attachments", children: e.map((n, r) => {
|
|
34929
|
+
const a = /* @__PURE__ */ se(en, { children: [
|
|
34930
|
+
/* @__PURE__ */ C("span", { className: "mp-agent-message-attachment-icon", children: q3(n, t.contextAttachmentIcons) }),
|
|
34931
|
+
/* @__PURE__ */ C("span", { className: "mp-agent-message-attachment-name", children: n.name })
|
|
34932
|
+
] });
|
|
34933
|
+
return n.url ? /* @__PURE__ */ C(
|
|
34934
|
+
"a",
|
|
34935
|
+
{
|
|
34936
|
+
className: "mp-agent-message-attachment",
|
|
34937
|
+
href: n.url,
|
|
34938
|
+
target: "_blank",
|
|
34939
|
+
rel: "noreferrer",
|
|
34940
|
+
title: n.url,
|
|
34941
|
+
children: a
|
|
34942
|
+
},
|
|
34943
|
+
n.id || r
|
|
34944
|
+
) : /* @__PURE__ */ C("span", { className: "mp-agent-message-attachment", title: n.mimeType ?? n.name, children: a }, n.id || r);
|
|
34945
|
+
}) });
|
|
34946
|
+
}, P_e = ({ attachments: e, onRemove: t, uploadProgress: n, uploadErrors: r }) => {
|
|
34947
|
+
const a = gn(), { config: i } = Ue();
|
|
34948
|
+
return !e || e.length === 0 ? null : /* @__PURE__ */ C("div", { className: "mp-agent-composer-attachments", "aria-label": a.attachments, children: e.map((o) => {
|
|
34949
|
+
const s = n?.get(o.id), l = r?.get(o.name), u = o.metadata?.size || o.size, d = u ? ` (${Mp(u)})` : "";
|
|
34943
34950
|
return /* @__PURE__ */ se(
|
|
34944
34951
|
"span",
|
|
34945
34952
|
{
|
|
34946
|
-
className: `mp-agent-attachment-chip ${
|
|
34947
|
-
title:
|
|
34953
|
+
className: `mp-agent-attachment-chip ${l ? "mp-agent-attachment-chip-error" : ""} ${s?.status === "uploading" ? "mp-agent-attachment-chip-uploading" : ""}`,
|
|
34954
|
+
title: l || o.name,
|
|
34948
34955
|
children: [
|
|
34949
|
-
/* @__PURE__ */ C("span", { className: "mp-agent-attachment-chip-icon", children: q3(i) }),
|
|
34950
|
-
/* @__PURE__ */ se("span", { className: "mp-agent-attachment-chip-name", title:
|
|
34951
|
-
|
|
34952
|
-
|
|
34956
|
+
/* @__PURE__ */ C("span", { className: "mp-agent-attachment-chip-icon", children: q3(o, i.contextAttachmentIcons) }),
|
|
34957
|
+
/* @__PURE__ */ se("span", { className: "mp-agent-attachment-chip-name", title: o.name, children: [
|
|
34958
|
+
o.name,
|
|
34959
|
+
d
|
|
34953
34960
|
] }),
|
|
34954
|
-
|
|
34955
|
-
|
|
34961
|
+
s?.status === "uploading" && /* @__PURE__ */ se("span", { className: "mp-agent-attachment-chip-progress", children: [
|
|
34962
|
+
s.progress,
|
|
34956
34963
|
"%"
|
|
34957
34964
|
] }),
|
|
34958
|
-
|
|
34965
|
+
l && /* @__PURE__ */ C("span", { className: "mp-agent-attachment-chip-error-text", title: l, children: "⚠" }),
|
|
34959
34966
|
t ? /* @__PURE__ */ C(
|
|
34960
34967
|
dn,
|
|
34961
34968
|
{
|
|
34962
34969
|
size: "sm",
|
|
34963
34970
|
icon: "X",
|
|
34964
34971
|
type: "button",
|
|
34965
|
-
onClick: (
|
|
34966
|
-
|
|
34972
|
+
onClick: (p) => {
|
|
34973
|
+
p.preventDefault(), p.stopPropagation(), t(o.id);
|
|
34967
34974
|
},
|
|
34968
|
-
"aria-label": `Remove attachment ${
|
|
34975
|
+
"aria-label": `Remove attachment ${o.name}`
|
|
34969
34976
|
}
|
|
34970
34977
|
) : null
|
|
34971
34978
|
]
|
|
34972
34979
|
},
|
|
34973
|
-
|
|
34980
|
+
o.id
|
|
34974
34981
|
);
|
|
34975
34982
|
}) });
|
|
34976
34983
|
}, q_e = (e) => {
|
|
@@ -35280,7 +35287,7 @@ const K_e = ({
|
|
|
35280
35287
|
)
|
|
35281
35288
|
] });
|
|
35282
35289
|
}, Y_e = Rt(() => {
|
|
35283
|
-
const e =
|
|
35290
|
+
const e = Ue(), t = be((p) => p.composer), n = be((p) => p.contextKey), r = be((p) => p.setComposerOptions), a = e.config.models, { data: i, isLoading: o } = c7e(), s = lt(() => {
|
|
35284
35291
|
const p = i && i.length > 0 ? i : a;
|
|
35285
35292
|
return x3(p, e.config.transport).filter((h) => !h.contexts?.length || h.contexts.includes(n));
|
|
35286
35293
|
}, [i, a, e.config.transport, n]), l = lt(() => {
|
|
@@ -35416,7 +35423,7 @@ function J_e(e) {
|
|
|
35416
35423
|
});
|
|
35417
35424
|
}
|
|
35418
35425
|
const ewe = () => {
|
|
35419
|
-
const e = gn(), t =
|
|
35426
|
+
const e = gn(), t = Ue(), n = be((l) => l.contextKey), { data: r, isLoading: a, isError: i } = p7e(n), o = lt(() => J_e(r ?? []), [r]), s = !!t.transport.upsertAgentPreferences && !!t.transport.upsertAgentPreferencesBatch;
|
|
35420
35427
|
return a ? /* @__PURE__ */ C(en, { children: e.agentSettingsLoading }) : i ? /* @__PURE__ */ C(en, { children: e.agentSettingsError }) : /* @__PURE__ */ C(Q_e, { preferences: o, disabled: !s });
|
|
35421
35428
|
}, twe = () => {
|
|
35422
35429
|
const [e, t] = et(!1), n = gn(), { refs: r, floatingStyles: a, context: i, isPositioned: o } = hp({
|
|
@@ -35463,7 +35470,7 @@ const ewe = () => {
|
|
|
35463
35470
|
] });
|
|
35464
35471
|
}, nwe = co(
|
|
35465
35472
|
({ autoFocus: e, activeChatId: t, status: n, onStop: r, onSubmit: a }, i) => {
|
|
35466
|
-
const o = gn(), s =
|
|
35473
|
+
const o = gn(), s = Ue(), l = Fe(null), u = Fe(null), d = be((re) => re.activeChatId ?? re.draftChatKey), p = be((re) => ze(re, d).composerDraft), m = be((re) => ze(re, d).composerError), h = be((re) => ze(re, d).pageContextDismissed), g = be((re) => re.setComposerValue), f = be((re) => re.setComposerDraft), w = be((re) => re.clearComposerDraft), v = be((re) => re.setComposerError), k = be((re) => re.addComposerAttachments), _ = be((re) => re.removeComposerAttachment), E = be((re) => re.setPageContextDismissed), S = p.value, x = p.attachments, [D, P] = et(/* @__PURE__ */ new Map()), [T, L] = et(/* @__PURE__ */ new Map()), j = Fe(S), Z = Fe(x), Q = Fe(h), W = s.config.features?.pageContextAttachments !== !1, R = s.config.composerAttachmentActions, U = (re) => re.type === bt.Context && re?.metadata?.kind === "pageContext", H = x.some(U), $ = () => {
|
|
35467
35474
|
if (W)
|
|
35468
35475
|
return s.buildPageContextAttachment();
|
|
35469
35476
|
};
|
|
@@ -35486,10 +35493,10 @@ const ewe = () => {
|
|
|
35486
35493
|
const re = Z.current, Se = re.find(U);
|
|
35487
35494
|
if (!Se)
|
|
35488
35495
|
return;
|
|
35489
|
-
const
|
|
35490
|
-
if (!
|
|
35496
|
+
const He = $();
|
|
35497
|
+
if (!He)
|
|
35491
35498
|
return;
|
|
35492
|
-
const Ye = { ...
|
|
35499
|
+
const Ye = { ...He, id: Se.id }, Ae = re.map((ve) => ve.id === Se.id ? Ye : ve);
|
|
35493
35500
|
f(d, { value: j.current, attachments: Ae });
|
|
35494
35501
|
});
|
|
35495
35502
|
}, [W, d, f]), A7(i, () => ({
|
|
@@ -35511,7 +35518,7 @@ const ewe = () => {
|
|
|
35511
35518
|
const V = async (re) => {
|
|
35512
35519
|
if (!re || re.length === 0)
|
|
35513
35520
|
return;
|
|
35514
|
-
const Se = Array.from(re),
|
|
35521
|
+
const Se = Array.from(re), He = z_e(), Ye = $_e(Se, x, He);
|
|
35515
35522
|
if (Ye) {
|
|
35516
35523
|
L((Ae) => {
|
|
35517
35524
|
const ve = new Map(Ae);
|
|
@@ -35568,17 +35575,17 @@ const ewe = () => {
|
|
|
35568
35575
|
return !1;
|
|
35569
35576
|
if (x.some((Ae) => Ae.type === bt.Link && Ae.url === Se))
|
|
35570
35577
|
return !0;
|
|
35571
|
-
const
|
|
35578
|
+
const He = B_e(Se), Ye = {
|
|
35572
35579
|
id: At(),
|
|
35573
35580
|
url: Se,
|
|
35574
|
-
name:
|
|
35581
|
+
name: He,
|
|
35575
35582
|
type: bt.Link
|
|
35576
35583
|
};
|
|
35577
35584
|
return k(d, [Ye]), !0;
|
|
35578
35585
|
}, J = async (re) => {
|
|
35579
35586
|
await V(re.target.files), re.target.value = "";
|
|
35580
35587
|
}, O = (re) => {
|
|
35581
|
-
const Se = x.find((
|
|
35588
|
+
const Se = x.find((He) => He.id === re);
|
|
35582
35589
|
Se && U(Se) && E(d, !0), _(d, re);
|
|
35583
35590
|
}, le = () => {
|
|
35584
35591
|
if (typeof window > "u" || typeof document > "u")
|
|
@@ -35586,12 +35593,12 @@ const ewe = () => {
|
|
|
35586
35593
|
const re = E7e(), Se = re?.selectedText ?? window.getSelection?.()?.toString()?.trim() ?? "";
|
|
35587
35594
|
if (!Se)
|
|
35588
35595
|
return !1;
|
|
35589
|
-
const
|
|
35596
|
+
const He = window.location?.href, Ye = Se.slice(0, 20), Ae = Se.length > 20 ? Ye + "..." : Se, ve = bp({
|
|
35590
35597
|
kind: "webSnippet",
|
|
35591
|
-
url:
|
|
35598
|
+
url: He,
|
|
35592
35599
|
title: Ae,
|
|
35593
35600
|
selectedText: Se,
|
|
35594
|
-
source: { app: "browser", url:
|
|
35601
|
+
source: { app: "browser", url: He },
|
|
35595
35602
|
...re?.target ? { target: re.target } : {}
|
|
35596
35603
|
});
|
|
35597
35604
|
return k(d, [ve]), !0;
|
|
@@ -36417,7 +36424,7 @@ const gwe = (e, t) => {
|
|
|
36417
36424
|
return "[unserializable]";
|
|
36418
36425
|
}
|
|
36419
36426
|
}
|
|
36420
|
-
}, B2 = ({ call: e }) =>
|
|
36427
|
+
}, B2 = ({ call: e }) => Ue().config.debug ? /* @__PURE__ */ se("details", { className: "mp-agent-tool-debug-details", children: [
|
|
36421
36428
|
/* @__PURE__ */ C("summary", { className: "mp-agent-tool-debug-summary", children: "Details" }),
|
|
36422
36429
|
/* @__PURE__ */ se("div", { className: "mp-agent-tool-debug-body", children: [
|
|
36423
36430
|
/* @__PURE__ */ se("div", { className: "mp-agent-tool-debug-row", children: [
|
|
@@ -36442,7 +36449,7 @@ const gwe = (e, t) => {
|
|
|
36442
36449
|
] })
|
|
36443
36450
|
] })
|
|
36444
36451
|
] }) : null, U2 = ({ call: e, isExpandable: t = !1, isExpanded: n = !1, onToggleExpand: r }) => {
|
|
36445
|
-
const a =
|
|
36452
|
+
const a = Ue(), i = Fe(!1), o = e.status === Et.Succeeded || e.status === Et.Failed, s = t || a.config.debug && !o, l = s || t;
|
|
36446
36453
|
if ($e(() => {
|
|
36447
36454
|
!t || o || n || i.current || (i.current = !0, r?.());
|
|
36448
36455
|
}, [t, o, n, r]), !l)
|
|
@@ -36572,7 +36579,7 @@ const H3 = ({ call: e }) => {
|
|
|
36572
36579
|
/* @__PURE__ */ C("div", { className: "mp-agent-tool-approval-actions", children: /* @__PURE__ */ C("button", { className: "mp-agent-tool-approve-button", onClick: m, disabled: n, children: n ? "Submitting..." : "Submit response" }) })
|
|
36573
36580
|
] }) : /* @__PURE__ */ C("div", { className: "mp-agent-tool-user-action-form", children: /* @__PURE__ */ C("div", { className: "mp-agent-tool-input-error", children: "Invalid user action input schema in tool call." }) });
|
|
36574
36581
|
}, vwe = ({ call: e, messageId: t, chatId: n, onApprovalSent: r }) => {
|
|
36575
|
-
const a =
|
|
36582
|
+
const a = Ue(), i = a.tools.get(e.name)?.label ?? e.name, o = be((D) => D.appendMessagesToChat), [s, l] = et(!1), [u, d] = et(!1), [p, m] = et(!1), [h, g] = et(JSON.stringify(e.input ?? {}, null, 2)), [f, w] = et(void 0), v = a.config.user?.id ?? "guest", k = e.requiresUserAction;
|
|
36576
36583
|
$e(() => {
|
|
36577
36584
|
u || (g(JSON.stringify(e.input ?? {}, null, 2)), w(void 0));
|
|
36578
36585
|
}, [e.id, e.input, u]);
|
|
@@ -36707,7 +36714,7 @@ const H3 = ({ call: e }) => {
|
|
|
36707
36714
|
] })
|
|
36708
36715
|
] });
|
|
36709
36716
|
}, H2 = ({ call: e, messageId: t, chatId: n }) => {
|
|
36710
|
-
const r =
|
|
36717
|
+
const r = Ue(), a = be((d) => d.upsertChat), i = r.config.debug && !!e.approvalId, o = e.requiresConfirmation && e.approvalId || i, s = o && e.approved === void 0, l = o && e.approved !== void 0, u = async () => {
|
|
36711
36718
|
try {
|
|
36712
36719
|
const d = await r.transport.getChat(n);
|
|
36713
36720
|
a(d);
|
|
@@ -36720,7 +36727,7 @@ const H3 = ({ call: e }) => {
|
|
|
36720
36727
|
l && /* @__PURE__ */ C(H3, { call: e })
|
|
36721
36728
|
] });
|
|
36722
36729
|
}, V2 = ({ chatId: e, isExpanded: t }) => {
|
|
36723
|
-
const n =
|
|
36730
|
+
const n = Ue(), r = be((l) => ze(l, e).messages), a = be((l) => ze(l, e).pendingAssistant), i = be((l) => l.chats[e]?.contextKey ?? l.contextKey), o = b3(e), s = lt(() => {
|
|
36724
36731
|
const l = [...r].sort((d, p) => d.createdAt.localeCompare(p.createdAt));
|
|
36725
36732
|
if (n.config.debug)
|
|
36726
36733
|
return l;
|
|
@@ -36732,7 +36739,7 @@ const H3 = ({ call: e }) => {
|
|
|
36732
36739
|
a && /* @__PURE__ */ C(lo, { message: a, contextKey: i, isStreaming: !0 })
|
|
36733
36740
|
] }) }) });
|
|
36734
36741
|
}, _we = ({ call: e, contextKey: t, messageId: n, chatId: r }) => {
|
|
36735
|
-
const a =
|
|
36742
|
+
const a = Ue(), i = e.subagentChatId || (typeof e.input?.subagentChatId == "string" ? e.input.subagentChatId : void 0), [o, s] = et(!1), l = lt(() => a.getToolRenderer(e), [a, e]);
|
|
36736
36743
|
return l ? /* @__PURE__ */ se("div", { className: "mp-agent-tool-panel", children: [
|
|
36737
36744
|
i && /* @__PURE__ */ C(
|
|
36738
36745
|
U2,
|
|
@@ -38650,7 +38657,7 @@ const Sd = gr(/\d/), q9e = gr(/[\dA-Fa-f]/), B9e = gr(/[!-/:-@[-`{-~]/);
|
|
|
38650
38657
|
function he(e) {
|
|
38651
38658
|
return e !== null && e < -2;
|
|
38652
38659
|
}
|
|
38653
|
-
function
|
|
38660
|
+
function Ve(e) {
|
|
38654
38661
|
return e !== null && (e < 0 || e === 32);
|
|
38655
38662
|
}
|
|
38656
38663
|
function Oe(e) {
|
|
@@ -38846,7 +38853,7 @@ function G9e(e, t, n) {
|
|
|
38846
38853
|
return Te(e, e.attempt(this.parser.constructs.document, t, n), "linePrefix", this.parser.constructs.disable.null.includes("codeIndented") ? void 0 : 4);
|
|
38847
38854
|
}
|
|
38848
38855
|
function Qr(e) {
|
|
38849
|
-
if (e === null ||
|
|
38856
|
+
if (e === null || Ve(e) || xn(e))
|
|
38850
38857
|
return 1;
|
|
38851
38858
|
if (dr(e))
|
|
38852
38859
|
return 2;
|
|
@@ -39519,7 +39526,7 @@ function mv(e, t, n, r, a, i, o, s, l) {
|
|
|
39519
39526
|
return v === 60 || v === 62 || v === 92 ? (e.consume(v), h) : h(v);
|
|
39520
39527
|
}
|
|
39521
39528
|
function f(v) {
|
|
39522
|
-
return !d && (v === null || v === 41 ||
|
|
39529
|
+
return !d && (v === null || v === 41 || Ve(v)) ? (e.exit("chunkString"), e.exit(s), e.exit(o), e.exit(r), t(v)) : d < u && v === 40 ? (e.consume(v), d++, f) : v === 41 ? (e.consume(v), d--, f) : v === null || v === 32 || v === 40 || Ki(v) ? n(v) : (e.consume(v), v === 92 ? w : f);
|
|
39523
39530
|
}
|
|
39524
39531
|
function w(v) {
|
|
39525
39532
|
return v === 40 || v === 41 || v === 92 ? (e.consume(v), f) : f(v);
|
|
@@ -39607,7 +39614,7 @@ function _xe(e, t, n) {
|
|
|
39607
39614
|
return a = wn(r.sliceSerialize(r.events[r.events.length - 1][1]).slice(1, -1)), h === 58 ? (e.enter("definitionMarker"), e.consume(h), e.exit("definitionMarker"), l) : n(h);
|
|
39608
39615
|
}
|
|
39609
39616
|
function l(h) {
|
|
39610
|
-
return
|
|
39617
|
+
return Ve(h) ? Un(e, u)(h) : u(h);
|
|
39611
39618
|
}
|
|
39612
39619
|
function u(h) {
|
|
39613
39620
|
return mv(
|
|
@@ -39635,7 +39642,7 @@ function _xe(e, t, n) {
|
|
|
39635
39642
|
function wxe(e, t, n) {
|
|
39636
39643
|
return r;
|
|
39637
39644
|
function r(s) {
|
|
39638
|
-
return
|
|
39645
|
+
return Ve(s) ? Un(e, a)(s) : n(s);
|
|
39639
39646
|
}
|
|
39640
39647
|
function a(s) {
|
|
39641
39648
|
return gv(e, i, n, "definitionTitle", "definitionTitleMarker", "definitionTitleString")(s);
|
|
@@ -39688,7 +39695,7 @@ function Nxe(e, t, n) {
|
|
|
39688
39695
|
return e.enter("atxHeadingSequence"), o(d);
|
|
39689
39696
|
}
|
|
39690
39697
|
function o(d) {
|
|
39691
|
-
return d === 35 && r++ < 6 ? (e.consume(d), o) : d === null ||
|
|
39698
|
+
return d === 35 && r++ < 6 ? (e.consume(d), o) : d === null || Ve(d) ? (e.exit("atxHeadingSequence"), s(d)) : n(d);
|
|
39692
39699
|
}
|
|
39693
39700
|
function s(d) {
|
|
39694
39701
|
return d === 35 ? (e.enter("atxHeadingSequence"), l(d)) : d === null || he(d) ? (e.exit("atxHeading"), t(d)) : Oe(d) ? Te(e, s, "whitespace")(d) : (e.enter("atxHeadingText"), u(d));
|
|
@@ -39697,7 +39704,7 @@ function Nxe(e, t, n) {
|
|
|
39697
39704
|
return d === 35 ? (e.consume(d), l) : (e.exit("atxHeadingSequence"), s(d));
|
|
39698
39705
|
}
|
|
39699
39706
|
function u(d) {
|
|
39700
|
-
return d === null || d === 35 ||
|
|
39707
|
+
return d === null || d === 35 || Ve(d) ? (e.exit("atxHeadingText"), s(d)) : (e.consume(d), u);
|
|
39701
39708
|
}
|
|
39702
39709
|
}
|
|
39703
39710
|
const Axe = [
|
|
@@ -39808,7 +39815,7 @@ function Oxe(e, t, n) {
|
|
|
39808
39815
|
return zt(O) ? (e.consume(O), o = String.fromCharCode(O), w) : n(O);
|
|
39809
39816
|
}
|
|
39810
39817
|
function w(O) {
|
|
39811
|
-
if (O === null || O === 47 || O === 62 ||
|
|
39818
|
+
if (O === null || O === 47 || O === 62 || Ve(O)) {
|
|
39812
39819
|
const le = O === 47, fe = o.toLowerCase();
|
|
39813
39820
|
return !le && !i && dm.includes(fe) ? (a = 1, r.interrupt ? t(O) : Z(O)) : Axe.includes(o.toLowerCase()) ? (a = 6, le ? (e.consume(O), v) : r.interrupt ? t(O) : Z(O)) : (a = 7, r.interrupt && !r.parser.lazy[r.now().line] ? n(O) : i ? k(O) : _(O));
|
|
39814
39821
|
}
|
|
@@ -39836,7 +39843,7 @@ function Oxe(e, t, n) {
|
|
|
39836
39843
|
return O === l ? (e.consume(O), l = null, T) : O === null || he(O) ? n(O) : (e.consume(O), D);
|
|
39837
39844
|
}
|
|
39838
39845
|
function P(O) {
|
|
39839
|
-
return O === null || O === 34 || O === 39 || O === 47 || O === 60 || O === 61 || O === 62 || O === 96 ||
|
|
39846
|
+
return O === null || O === 34 || O === 39 || O === 47 || O === 60 || O === 61 || O === 62 || O === 96 || Ve(O) ? S(O) : (e.consume(O), P);
|
|
39840
39847
|
}
|
|
39841
39848
|
function T(O) {
|
|
39842
39849
|
return O === 47 || O === 62 || Oe(O) ? _(O) : n(O);
|
|
@@ -39962,7 +39969,7 @@ function zxe(e, t, n) {
|
|
|
39962
39969
|
return he(N) ? (o = D, H(N)) : Oe(N) ? (e.consume(N), D) : U(N);
|
|
39963
39970
|
}
|
|
39964
39971
|
function P(N) {
|
|
39965
|
-
return N === 45 || Tt(N) ? (e.consume(N), P) : N === 47 || N === 62 ||
|
|
39972
|
+
return N === 45 || Tt(N) ? (e.consume(N), P) : N === 47 || N === 62 || Ve(N) ? T(N) : n(N);
|
|
39966
39973
|
}
|
|
39967
39974
|
function T(N) {
|
|
39968
39975
|
return N === 47 ? (e.consume(N), U) : N === 58 || N === 95 || zt(N) ? (e.consume(N), L) : he(N) ? (o = T, H(N)) : Oe(N) ? (e.consume(N), T) : U(N);
|
|
@@ -39980,10 +39987,10 @@ function zxe(e, t, n) {
|
|
|
39980
39987
|
return N === a ? (e.consume(N), a = void 0, R) : N === null ? n(N) : he(N) ? (o = Q, H(N)) : (e.consume(N), Q);
|
|
39981
39988
|
}
|
|
39982
39989
|
function W(N) {
|
|
39983
|
-
return N === null || N === 34 || N === 39 || N === 60 || N === 61 || N === 96 ? n(N) : N === 47 || N === 62 ||
|
|
39990
|
+
return N === null || N === 34 || N === 39 || N === 60 || N === 61 || N === 96 ? n(N) : N === 47 || N === 62 || Ve(N) ? T(N) : (e.consume(N), W);
|
|
39984
39991
|
}
|
|
39985
39992
|
function R(N) {
|
|
39986
|
-
return N === 47 || N === 62 ||
|
|
39993
|
+
return N === 47 || N === 62 || Ve(N) ? T(N) : n(N);
|
|
39987
39994
|
}
|
|
39988
39995
|
function U(N) {
|
|
39989
39996
|
return N === 62 ? (e.consume(N), e.exit("htmlTextData"), e.exit("htmlText"), t) : n(N);
|
|
@@ -40097,13 +40104,13 @@ function Vxe(e, t, n) {
|
|
|
40097
40104
|
return e.enter("resource"), e.enter("resourceMarker"), e.consume(p), e.exit("resourceMarker"), a;
|
|
40098
40105
|
}
|
|
40099
40106
|
function a(p) {
|
|
40100
|
-
return
|
|
40107
|
+
return Ve(p) ? Un(e, i)(p) : i(p);
|
|
40101
40108
|
}
|
|
40102
40109
|
function i(p) {
|
|
40103
40110
|
return p === 41 ? d(p) : mv(e, o, s, "resourceDestination", "resourceDestinationLiteral", "resourceDestinationLiteralMarker", "resourceDestinationRaw", "resourceDestinationString", 32)(p);
|
|
40104
40111
|
}
|
|
40105
40112
|
function o(p) {
|
|
40106
|
-
return
|
|
40113
|
+
return Ve(p) ? Un(e, l)(p) : d(p);
|
|
40107
40114
|
}
|
|
40108
40115
|
function s(p) {
|
|
40109
40116
|
return n(p);
|
|
@@ -40112,7 +40119,7 @@ function Vxe(e, t, n) {
|
|
|
40112
40119
|
return p === 34 || p === 39 || p === 40 ? gv(e, u, n, "resourceTitle", "resourceTitleMarker", "resourceTitleString")(p) : d(p);
|
|
40113
40120
|
}
|
|
40114
40121
|
function u(p) {
|
|
40115
|
-
return
|
|
40122
|
+
return Ve(p) ? Un(e, d)(p) : d(p);
|
|
40116
40123
|
}
|
|
40117
40124
|
function d(p) {
|
|
40118
40125
|
return p === 41 ? (e.enter("resourceMarker"), e.consume(p), e.exit("resourceMarker"), e.exit("resource"), t) : n(p);
|
|
@@ -40840,7 +40847,7 @@ function LEe(e) {
|
|
|
40840
40847
|
codeTextData: T,
|
|
40841
40848
|
data: T,
|
|
40842
40849
|
codeFlowValue: T,
|
|
40843
|
-
definition: i(
|
|
40850
|
+
definition: i(He),
|
|
40844
40851
|
definitionDestinationString: o,
|
|
40845
40852
|
definitionLabelString: o,
|
|
40846
40853
|
definitionTitleString: o,
|
|
@@ -40854,7 +40861,7 @@ function LEe(e) {
|
|
|
40854
40861
|
image: i(de),
|
|
40855
40862
|
label: o,
|
|
40856
40863
|
link: i(tt),
|
|
40857
|
-
listItem: i(
|
|
40864
|
+
listItem: i(je),
|
|
40858
40865
|
listItemValue: m,
|
|
40859
40866
|
listOrdered: i(Ze, p),
|
|
40860
40867
|
listUnordered: i(Ze),
|
|
@@ -41248,7 +41255,7 @@ function LEe(e) {
|
|
|
41248
41255
|
value: ""
|
|
41249
41256
|
};
|
|
41250
41257
|
}
|
|
41251
|
-
function
|
|
41258
|
+
function He() {
|
|
41252
41259
|
return {
|
|
41253
41260
|
type: "definition",
|
|
41254
41261
|
identifier: "",
|
|
@@ -41307,7 +41314,7 @@ function LEe(e) {
|
|
|
41307
41314
|
children: []
|
|
41308
41315
|
};
|
|
41309
41316
|
}
|
|
41310
|
-
function
|
|
41317
|
+
function je(q) {
|
|
41311
41318
|
return {
|
|
41312
41319
|
type: "listItem",
|
|
41313
41320
|
spread: q._spread,
|
|
@@ -44842,7 +44849,7 @@ function ONe(e, t, n) {
|
|
|
44842
44849
|
return p === 47 ? (e.consume(p), i ? u : (i = !0, l)) : n(p);
|
|
44843
44850
|
}
|
|
44844
44851
|
function u(p) {
|
|
44845
|
-
return p === null || Ki(p) ||
|
|
44852
|
+
return p === null || Ki(p) || Ve(p) || xn(p) || dr(p) ? n(p) : e.attempt(Wv, e.attempt(Kv, d), n)(p);
|
|
44846
44853
|
}
|
|
44847
44854
|
function d(p) {
|
|
44848
44855
|
return e.exit("literalAutolinkHttp"), e.exit("literalAutolink"), t(p);
|
|
@@ -44862,7 +44869,7 @@ function DNe(e, t, n) {
|
|
|
44862
44869
|
let r, a, i;
|
|
44863
44870
|
return o;
|
|
44864
44871
|
function o(u) {
|
|
44865
|
-
return u === 46 || u === 95 ? e.check(Yv, l, s)(u) : u === null ||
|
|
44872
|
+
return u === 46 || u === 95 ? e.check(Yv, l, s)(u) : u === null || Ve(u) || xn(u) || u !== 45 && dr(u) ? l(u) : (i = !0, e.consume(u), o);
|
|
44866
44873
|
}
|
|
44867
44874
|
function s(u) {
|
|
44868
44875
|
return u === 95 ? r = !0 : (a = r, r = void 0), e.consume(u), o;
|
|
@@ -44875,7 +44882,7 @@ function $Ne(e, t) {
|
|
|
44875
44882
|
let n = 0, r = 0;
|
|
44876
44883
|
return a;
|
|
44877
44884
|
function a(o) {
|
|
44878
|
-
return o === 40 ? (n++, e.consume(o), a) : o === 41 && r < n ? i(o) : o === 33 || o === 34 || o === 38 || o === 39 || o === 41 || o === 42 || o === 44 || o === 46 || o === 58 || o === 59 || o === 60 || o === 63 || o === 93 || o === 95 || o === 126 ? e.check(Yv, t, i)(o) : o === null ||
|
|
44885
|
+
return o === 40 ? (n++, e.consume(o), a) : o === 41 && r < n ? i(o) : o === 33 || o === 34 || o === 38 || o === 39 || o === 41 || o === 42 || o === 44 || o === 46 || o === 58 || o === 59 || o === 60 || o === 63 || o === 93 || o === 95 || o === 126 ? e.check(Yv, t, i)(o) : o === null || Ve(o) || xn(o) ? t(o) : (e.consume(o), a);
|
|
44879
44886
|
}
|
|
44880
44887
|
function i(o) {
|
|
44881
44888
|
return o === 41 && r++, e.consume(o), a;
|
|
@@ -44887,11 +44894,11 @@ function zNe(e, t, n) {
|
|
|
44887
44894
|
return s === 33 || s === 34 || s === 39 || s === 41 || s === 42 || s === 44 || s === 46 || s === 58 || s === 59 || s === 63 || s === 95 || s === 126 ? (e.consume(s), r) : s === 38 ? (e.consume(s), i) : s === 93 ? (e.consume(s), a) : (
|
|
44888
44895
|
// `<` is an end.
|
|
44889
44896
|
s === 60 || // So is whitespace.
|
|
44890
|
-
s === null ||
|
|
44897
|
+
s === null || Ve(s) || xn(s) ? t(s) : n(s)
|
|
44891
44898
|
);
|
|
44892
44899
|
}
|
|
44893
44900
|
function a(s) {
|
|
44894
|
-
return s === null || s === 40 || s === 91 ||
|
|
44901
|
+
return s === null || s === 40 || s === 91 || Ve(s) || xn(s) ? t(s) : r(s);
|
|
44895
44902
|
}
|
|
44896
44903
|
function i(s) {
|
|
44897
44904
|
return zt(s) ? o(s) : n(s);
|
|
@@ -44910,7 +44917,7 @@ function FNe(e, t, n) {
|
|
|
44910
44917
|
}
|
|
44911
44918
|
}
|
|
44912
44919
|
function Qv(e) {
|
|
44913
|
-
return e === null || e === 40 || e === 42 || e === 95 || e === 91 || e === 93 || e === 126 ||
|
|
44920
|
+
return e === null || e === 40 || e === 42 || e === 95 || e === 91 || e === 93 || e === 126 || Ve(e);
|
|
44914
44921
|
}
|
|
44915
44922
|
function Jv(e) {
|
|
44916
44923
|
return !zt(e);
|
|
@@ -45057,7 +45064,7 @@ function HNe(e, t, n) {
|
|
|
45057
45064
|
i > 999 || // Closing brace with nothing.
|
|
45058
45065
|
p === 93 && !o || // Space or tab is not supported by GFM for some reason.
|
|
45059
45066
|
// `\n` and `[` not being supported makes sense.
|
|
45060
|
-
p === null || p === 91 ||
|
|
45067
|
+
p === null || p === 91 || Ve(p)
|
|
45061
45068
|
)
|
|
45062
45069
|
return n(p);
|
|
45063
45070
|
if (p === 93) {
|
|
@@ -45065,7 +45072,7 @@ function HNe(e, t, n) {
|
|
|
45065
45072
|
const m = e.exit("gfmFootnoteCallString");
|
|
45066
45073
|
return a.includes(wn(r.sliceSerialize(m))) ? (e.enter("gfmFootnoteCallLabelMarker"), e.consume(p), e.exit("gfmFootnoteCallLabelMarker"), e.exit("gfmFootnoteCall"), t) : n(p);
|
|
45067
45074
|
}
|
|
45068
|
-
return
|
|
45075
|
+
return Ve(p) || (o = !0), i++, e.consume(p), p === 92 ? d : u;
|
|
45069
45076
|
}
|
|
45070
45077
|
function d(p) {
|
|
45071
45078
|
return p === 91 || p === 92 || p === 93 ? (e.consume(p), i++, u) : u(p);
|
|
@@ -45087,7 +45094,7 @@ function VNe(e, t, n) {
|
|
|
45087
45094
|
o > 999 || // Closing brace with nothing.
|
|
45088
45095
|
g === 93 && !s || // Space or tab is not supported by GFM for some reason.
|
|
45089
45096
|
// `\n` and `[` not being supported makes sense.
|
|
45090
|
-
g === null || g === 91 ||
|
|
45097
|
+
g === null || g === 91 || Ve(g)
|
|
45091
45098
|
)
|
|
45092
45099
|
return n(g);
|
|
45093
45100
|
if (g === 93) {
|
|
@@ -45095,7 +45102,7 @@ function VNe(e, t, n) {
|
|
|
45095
45102
|
const f = e.exit("gfmFootnoteDefinitionLabelString");
|
|
45096
45103
|
return i = wn(r.sliceSerialize(f)), e.enter("gfmFootnoteDefinitionLabelMarker"), e.consume(g), e.exit("gfmFootnoteDefinitionLabelMarker"), e.exit("gfmFootnoteDefinitionLabel"), m;
|
|
45097
45104
|
}
|
|
45098
|
-
return
|
|
45105
|
+
return Ve(g) || (s = !0), o++, e.consume(g), g === 92 ? p : d;
|
|
45099
45106
|
}
|
|
45100
45107
|
function p(g) {
|
|
45101
45108
|
return g === 91 || g === 92 || g === 93 ? (e.consume(g), o++, d) : d(g);
|
|
@@ -45310,7 +45317,7 @@ function JNe(e, t, n) {
|
|
|
45310
45317
|
return L === null ? n(L) : he(L) ? i > 1 ? (i = 0, r.interrupt = !0, e.exit("tableRow"), e.enter("lineEnding"), e.consume(L), e.exit("lineEnding"), h) : n(L) : Oe(L) ? Te(e, d, "whitespace")(L) : (i += 1, o && (o = !1, a += 1), L === 124 ? (e.enter("tableCellDivider"), e.consume(L), e.exit("tableCellDivider"), o = !0, d) : (e.enter("data"), p(L)));
|
|
45311
45318
|
}
|
|
45312
45319
|
function p(L) {
|
|
45313
|
-
return L === null || L === 124 ||
|
|
45320
|
+
return L === null || L === 124 || Ve(L) ? (e.exit("data"), d(L)) : (e.consume(L), L === 92 ? m : p);
|
|
45314
45321
|
}
|
|
45315
45322
|
function m(L) {
|
|
45316
45323
|
return L === 92 || L === 124 ? (e.consume(L), p) : p(L);
|
|
@@ -45349,7 +45356,7 @@ function JNe(e, t, n) {
|
|
|
45349
45356
|
return L === 124 ? (e.enter("tableCellDivider"), e.consume(L), e.exit("tableCellDivider"), D) : L === null || he(L) ? (e.exit("tableRow"), t(L)) : Oe(L) ? Te(e, D, "whitespace")(L) : (e.enter("data"), P(L));
|
|
45350
45357
|
}
|
|
45351
45358
|
function P(L) {
|
|
45352
|
-
return L === null || L === 124 ||
|
|
45359
|
+
return L === null || L === 124 || Ve(L) ? (e.exit("data"), D(L)) : (e.consume(L), L === 92 ? T : P);
|
|
45353
45360
|
}
|
|
45354
45361
|
function T(L) {
|
|
45355
45362
|
return L === 92 || L === 124 ? (e.consume(L), P) : P(L);
|
|
@@ -45435,7 +45442,7 @@ function rAe(e, t, n) {
|
|
|
45435
45442
|
);
|
|
45436
45443
|
}
|
|
45437
45444
|
function i(l) {
|
|
45438
|
-
return
|
|
45445
|
+
return Ve(l) ? (e.enter("taskListCheckValueUnchecked"), e.consume(l), e.exit("taskListCheckValueUnchecked"), o) : l === 88 || l === 120 ? (e.enter("taskListCheckValueChecked"), e.consume(l), e.exit("taskListCheckValueChecked"), o) : n(l);
|
|
45439
45446
|
}
|
|
45440
45447
|
function o(l) {
|
|
45441
45448
|
return l === 93 ? (e.enter("taskListCheckMarker"), e.consume(l), e.exit("taskListCheckMarker"), e.exit("taskListCheck"), s) : n(l);
|
|
@@ -50470,7 +50477,7 @@ var ro = function(t) {
|
|
|
50470
50477
|
}, kt = function(t, n, r, a) {
|
|
50471
50478
|
a === void 0 && (a = [null, null]);
|
|
50472
50479
|
for (var i = [], o = 0; o < t.length; o++) {
|
|
50473
|
-
var s =
|
|
50480
|
+
var s = Ge(t[o], n);
|
|
50474
50481
|
if (s instanceof Ya) {
|
|
50475
50482
|
var l = s.children;
|
|
50476
50483
|
i.push(...l);
|
|
@@ -50534,7 +50541,7 @@ var ro = function(t) {
|
|
|
50534
50541
|
}, Da = function(t, n) {
|
|
50535
50542
|
var r = ["nulldelimiter"].concat(t.baseSizingClasses());
|
|
50536
50543
|
return Kn(n.concat(r));
|
|
50537
|
-
},
|
|
50544
|
+
}, Ge = function(t, n, r) {
|
|
50538
50545
|
if (!t)
|
|
50539
50546
|
return Kn();
|
|
50540
50547
|
if (to[t.type]) {
|
|
@@ -51013,10 +51020,10 @@ function zo(e) {
|
|
|
51013
51020
|
}
|
|
51014
51021
|
var Zp = (e, t) => {
|
|
51015
51022
|
var n, r, a;
|
|
51016
|
-
e && e.type === "supsub" ? (r = Ie(e.base, "accent"), n = r.base, e.base = n, a = ZAe(
|
|
51017
|
-
var i =
|
|
51023
|
+
e && e.type === "supsub" ? (r = Ie(e.base, "accent"), n = r.base, e.base = n, a = ZAe(Ge(e, t)), e.base = r) : (r = Ie(e, "accent"), n = r.base);
|
|
51024
|
+
var i = Ge(n, t.havingCrampedStyle()), o = r.isShifty && _e.isCharacterBox(n), s = 0;
|
|
51018
51025
|
if (o) {
|
|
51019
|
-
var l = _e.getBaseElem(n), u =
|
|
51026
|
+
var l = _e.getBaseElem(n), u = Ge(l, t.havingCrampedStyle());
|
|
51020
51027
|
s = Gm(u).skew;
|
|
51021
51028
|
}
|
|
51022
51029
|
var d = r.label === "\\c", p = d ? i.height + i.depth : Math.min(i.height, t.fontMetrics().xHeight), m;
|
|
@@ -51128,7 +51135,7 @@ me({
|
|
|
51128
51135
|
};
|
|
51129
51136
|
},
|
|
51130
51137
|
htmlBuilder: (e, t) => {
|
|
51131
|
-
var n =
|
|
51138
|
+
var n = Ge(e.base, t), r = Yn.svgSpan(e, t), a = e.label === "\\utilde" ? 0.12 : 0, i = X.makeVList({
|
|
51132
51139
|
positionType: "top",
|
|
51133
51140
|
positionData: n.height,
|
|
51134
51141
|
children: [{
|
|
@@ -51206,10 +51213,10 @@ me({
|
|
|
51206
51213
|
// Flow is unable to correctly infer the type of `group`, even though it's
|
|
51207
51214
|
// unambiguously determined from the passed-in `type` above.
|
|
51208
51215
|
htmlBuilder(e, t) {
|
|
51209
|
-
var n = t.style, r = t.havingStyle(n.sup()), a = X.wrapFragment(
|
|
51216
|
+
var n = t.style, r = t.havingStyle(n.sup()), a = X.wrapFragment(Ge(e.body, r, t), t), i = e.label.slice(0, 2) === "\\x" ? "x" : "cd";
|
|
51210
51217
|
a.classes.push(i + "-arrow-pad");
|
|
51211
51218
|
var o;
|
|
51212
|
-
e.below && (r = t.havingStyle(n.sub()), o = X.wrapFragment(
|
|
51219
|
+
e.below && (r = t.havingStyle(n.sub()), o = X.wrapFragment(Ge(e.below, r, t), t), o.classes.push(i + "-arrow-pad"));
|
|
51213
51220
|
var s = Yn.svgSpan(e, t), l = -t.fontMetrics().axisHeight + 0.5 * s.height, u = -t.fontMetrics().axisHeight - 0.5 * s.height - 0.111;
|
|
51214
51221
|
(a.depth > 0.25 || e.label === "\\xleftequilibrium") && (u -= a.depth);
|
|
51215
51222
|
var d;
|
|
@@ -51535,7 +51542,7 @@ me({
|
|
|
51535
51542
|
};
|
|
51536
51543
|
},
|
|
51537
51544
|
htmlBuilder(e, t) {
|
|
51538
|
-
var n = t.havingStyle(t.style.sup()), r = X.wrapFragment(
|
|
51545
|
+
var n = t.havingStyle(t.style.sup()), r = X.wrapFragment(Ge(e.label, n, t), t);
|
|
51539
51546
|
return r.classes.push("cd-label-" + e.side), r.style.bottom = ue(0.8 - r.depth), r.height = 0, r.depth = 0, r;
|
|
51540
51547
|
},
|
|
51541
51548
|
mathmlBuilder(e, t) {
|
|
@@ -51560,7 +51567,7 @@ me({
|
|
|
51560
51567
|
};
|
|
51561
51568
|
},
|
|
51562
51569
|
htmlBuilder(e, t) {
|
|
51563
|
-
var n = X.wrapFragment(
|
|
51570
|
+
var n = X.wrapFragment(Ge(e.fragment, t), t);
|
|
51564
51571
|
return n.classes.push("cd-vert-arrow"), n;
|
|
51565
51572
|
},
|
|
51566
51573
|
mathmlBuilder(e, t) {
|
|
@@ -52245,7 +52252,7 @@ me({
|
|
|
52245
52252
|
}
|
|
52246
52253
|
});
|
|
52247
52254
|
var Qp = (e, t) => {
|
|
52248
|
-
var n = X.wrapFragment(
|
|
52255
|
+
var n = X.wrapFragment(Ge(e.body, t), t), r = e.label.slice(1), a = t.sizeMultiplier, i, o = 0, s = _e.isCharacterBox(e.body);
|
|
52249
52256
|
if (r === "sout")
|
|
52250
52257
|
i = X.makeSpan(["stretchy", "sout"]), i.height = t.fontMetrics().defaultRuleThickness / a, o = -0.5 * t.fontMetrics().xHeight;
|
|
52251
52258
|
else if (r === "phase") {
|
|
@@ -52607,7 +52614,7 @@ var $n = function(t, n) {
|
|
|
52607
52614
|
s < S.length && (s = S.length);
|
|
52608
52615
|
var P = new Array(S.length);
|
|
52609
52616
|
for (a = 0; a < S.length; ++a) {
|
|
52610
|
-
var T =
|
|
52617
|
+
var T = Ge(S[a], n);
|
|
52611
52618
|
D < T.depth && (D = T.depth), x < T.height && (x = T.height), P[a] = T;
|
|
52612
52619
|
}
|
|
52613
52620
|
var L = t.rowGaps[r], j = 0;
|
|
@@ -52662,7 +52669,7 @@ var $n = function(t, n) {
|
|
|
52662
52669
|
}
|
|
52663
52670
|
}
|
|
52664
52671
|
if (l = X.makeSpan(["mtable"], W), u.length > 0) {
|
|
52665
|
-
for (var Se = X.makeLineSpan("hline", n, d),
|
|
52672
|
+
for (var Se = X.makeLineSpan("hline", n, d), He = X.makeLineSpan("hdashline", n, d), Ye = [{
|
|
52666
52673
|
type: "elem",
|
|
52667
52674
|
elem: l,
|
|
52668
52675
|
shift: 0
|
|
@@ -52670,7 +52677,7 @@ var $n = function(t, n) {
|
|
|
52670
52677
|
var Ae = u.pop(), ve = Ae.pos - Z;
|
|
52671
52678
|
Ae.isDashed ? Ye.push({
|
|
52672
52679
|
type: "elem",
|
|
52673
|
-
elem:
|
|
52680
|
+
elem: He,
|
|
52674
52681
|
shift: ve
|
|
52675
52682
|
}) : Ye.push({
|
|
52676
52683
|
type: "elem",
|
|
@@ -53071,7 +53078,7 @@ me({
|
|
|
53071
53078
|
});
|
|
53072
53079
|
var $6 = (e, t) => {
|
|
53073
53080
|
var n = e.font, r = t.withFont(n);
|
|
53074
|
-
return
|
|
53081
|
+
return Ge(e.body, r);
|
|
53075
53082
|
}, z6 = (e, t) => {
|
|
53076
53083
|
var n = e.font, r = t.withFont(n);
|
|
53077
53084
|
return nt(e.body, r);
|
|
@@ -53179,13 +53186,13 @@ var F6 = (e, t) => {
|
|
|
53179
53186
|
}, nh = (e, t) => {
|
|
53180
53187
|
var n = F6(e.size, t.style), r = n.fracNum(), a = n.fracDen(), i;
|
|
53181
53188
|
i = t.havingStyle(r);
|
|
53182
|
-
var o =
|
|
53189
|
+
var o = Ge(e.numer, i, t);
|
|
53183
53190
|
if (e.continued) {
|
|
53184
53191
|
var s = 8.5 / t.fontMetrics().ptPerEm, l = 3.5 / t.fontMetrics().ptPerEm;
|
|
53185
53192
|
o.height = o.height < s ? s : o.height, o.depth = o.depth < l ? l : o.depth;
|
|
53186
53193
|
}
|
|
53187
53194
|
i = t.havingStyle(a);
|
|
53188
|
-
var u =
|
|
53195
|
+
var u = Ge(e.denom, i, t), d, p, m;
|
|
53189
53196
|
e.hasBarLine ? (e.barSize ? (p = dt(e.barSize, t), d = X.makeLineSpan("frac-line", t, p)) : d = X.makeLineSpan("frac-line", t), p = d.height, m = d.height) : (d = null, p = 0, m = t.fontMetrics().defaultRuleThickness);
|
|
53190
53197
|
var h, g, f;
|
|
53191
53198
|
n.size === xe.DISPLAY.size || e.size === "display" ? (h = t.fontMetrics().num1, p > 0 ? g = 3 * m : g = 7 * m, f = t.fontMetrics().denom1) : (p > 0 ? (h = t.fontMetrics().num2, g = m) : (h = t.fontMetrics().num3, g = 3 * m), f = t.fontMetrics().denom2);
|
|
@@ -53490,8 +53497,8 @@ me({
|
|
|
53490
53497
|
});
|
|
53491
53498
|
var P6 = (e, t) => {
|
|
53492
53499
|
var n = t.style, r, a;
|
|
53493
|
-
e.type === "supsub" ? (r = e.sup ?
|
|
53494
|
-
var i =
|
|
53500
|
+
e.type === "supsub" ? (r = e.sup ? Ge(e.sup, t.havingStyle(n.sup()), t) : Ge(e.sub, t.havingStyle(n.sub()), t), a = Ie(e.base, "horizBrace")) : a = Ie(e, "horizBrace");
|
|
53501
|
+
var i = Ge(a.base, t.havingBaseStyle(xe.DISPLAY)), o = Yn.svgSpan(a, t), s;
|
|
53495
53502
|
if (a.isOver ? (s = X.makeVList({
|
|
53496
53503
|
positionType: "firstBaseline",
|
|
53497
53504
|
children: [{
|
|
@@ -53915,7 +53922,7 @@ me({
|
|
|
53915
53922
|
},
|
|
53916
53923
|
htmlBuilder: (e, t) => {
|
|
53917
53924
|
var n;
|
|
53918
|
-
e.alignment === "clap" ? (n = X.makeSpan([], [
|
|
53925
|
+
e.alignment === "clap" ? (n = X.makeSpan([], [Ge(e.body, t)]), n = X.makeSpan(["inner"], [n], t)) : n = X.makeSpan(["inner"], [Ge(e.body, t)]);
|
|
53919
53926
|
var r = X.makeSpan(["fix"], []), a = X.makeSpan([e.alignment], [n, r], t), i = X.makeSpan(["strut"]);
|
|
53920
53927
|
return i.style.height = ue(a.height + a.depth), a.depth && (i.style.verticalAlign = ue(-a.depth)), a.children.unshift(i), a = X.makeSpan(["thinbox"], [a], t), X.makeSpan(["mord", "vbox"], [a], t);
|
|
53921
53928
|
},
|
|
@@ -54011,14 +54018,14 @@ var q6 = (e, t, n, r, a, i, o) => {
|
|
|
54011
54018
|
e = X.makeSpan([], [e]);
|
|
54012
54019
|
var s = n && _e.isCharacterBox(n), l, u;
|
|
54013
54020
|
if (t) {
|
|
54014
|
-
var d =
|
|
54021
|
+
var d = Ge(t, r.havingStyle(a.sup()), r);
|
|
54015
54022
|
u = {
|
|
54016
54023
|
elem: d,
|
|
54017
54024
|
kern: Math.max(r.fontMetrics().bigOpSpacing1, r.fontMetrics().bigOpSpacing3 - d.depth)
|
|
54018
54025
|
};
|
|
54019
54026
|
}
|
|
54020
54027
|
if (n) {
|
|
54021
|
-
var p =
|
|
54028
|
+
var p = Ge(n, r.havingStyle(a.sub()), r);
|
|
54022
54029
|
l = {
|
|
54023
54030
|
elem: p,
|
|
54024
54031
|
kern: Math.max(r.fontMetrics().bigOpSpacing2, r.fontMetrics().bigOpSpacing4 - p.height)
|
|
@@ -54387,7 +54394,7 @@ me({
|
|
|
54387
54394
|
};
|
|
54388
54395
|
},
|
|
54389
54396
|
htmlBuilder(e, t) {
|
|
54390
|
-
var n =
|
|
54397
|
+
var n = Ge(e.body, t.havingCrampedStyle()), r = X.makeLineSpan("overline-line", t), a = t.fontMetrics().defaultRuleThickness, i = X.makeVList({
|
|
54391
54398
|
positionType: "firstBaseline",
|
|
54392
54399
|
children: [{
|
|
54393
54400
|
type: "elem",
|
|
@@ -54456,7 +54463,7 @@ me({
|
|
|
54456
54463
|
};
|
|
54457
54464
|
},
|
|
54458
54465
|
htmlBuilder: (e, t) => {
|
|
54459
|
-
var n = X.makeSpan([], [
|
|
54466
|
+
var n = X.makeSpan([], [Ge(e.body, t.withPhantom())]);
|
|
54460
54467
|
if (n.height = 0, n.depth = 0, n.children)
|
|
54461
54468
|
for (var r = 0; r < n.children.length; r++)
|
|
54462
54469
|
n.children[r].height = 0, n.children[r].depth = 0;
|
|
@@ -54491,7 +54498,7 @@ me({
|
|
|
54491
54498
|
};
|
|
54492
54499
|
},
|
|
54493
54500
|
htmlBuilder: (e, t) => {
|
|
54494
|
-
var n = X.makeSpan(["inner"], [
|
|
54501
|
+
var n = X.makeSpan(["inner"], [Ge(e.body, t.withPhantom())]), r = X.makeSpan(["fix"], []);
|
|
54495
54502
|
return X.makeSpan(["mord", "rlap"], [n, r], t);
|
|
54496
54503
|
},
|
|
54497
54504
|
mathmlBuilder: (e, t) => {
|
|
@@ -54519,7 +54526,7 @@ me({
|
|
|
54519
54526
|
};
|
|
54520
54527
|
},
|
|
54521
54528
|
htmlBuilder(e, t) {
|
|
54522
|
-
var n =
|
|
54529
|
+
var n = Ge(e.body, t), r = dt(e.dy, t);
|
|
54523
54530
|
return X.makeVList({
|
|
54524
54531
|
positionType: "shift",
|
|
54525
54532
|
positionData: -r,
|
|
@@ -54656,7 +54663,7 @@ me({
|
|
|
54656
54663
|
};
|
|
54657
54664
|
},
|
|
54658
54665
|
htmlBuilder: (e, t) => {
|
|
54659
|
-
var n = X.makeSpan([], [
|
|
54666
|
+
var n = X.makeSpan([], [Ge(e.body, t)]);
|
|
54660
54667
|
if (!e.smashHeight && !e.smashDepth)
|
|
54661
54668
|
return n;
|
|
54662
54669
|
if (e.smashHeight && (n.height = 0, n.children))
|
|
@@ -54698,7 +54705,7 @@ me({
|
|
|
54698
54705
|
};
|
|
54699
54706
|
},
|
|
54700
54707
|
htmlBuilder(e, t) {
|
|
54701
|
-
var n =
|
|
54708
|
+
var n = Ge(e.body, t.havingCrampedStyle());
|
|
54702
54709
|
n.height === 0 && (n.height = t.fontMetrics().xHeight), n = X.wrapFragment(n, t);
|
|
54703
54710
|
var r = t.fontMetrics(), a = r.defaultRuleThickness, i = a;
|
|
54704
54711
|
t.style.id < xe.TEXT.id && (i = t.fontMetrics().xHeight);
|
|
@@ -54728,7 +54735,7 @@ me({
|
|
|
54728
54735
|
}]
|
|
54729
54736
|
}, t);
|
|
54730
54737
|
if (e.index) {
|
|
54731
|
-
var g = t.havingStyle(xe.SCRIPTSCRIPT), f =
|
|
54738
|
+
var g = t.havingStyle(xe.SCRIPTSCRIPT), f = Ge(e.index, g, t), w = 0.6 * (h.height - h.depth), v = X.makeVList({
|
|
54732
54739
|
positionType: "shift",
|
|
54733
54740
|
positionData: -w,
|
|
54734
54741
|
children: [{
|
|
@@ -54822,14 +54829,14 @@ Cr({
|
|
|
54822
54829
|
base: r,
|
|
54823
54830
|
sup: a,
|
|
54824
54831
|
sub: i
|
|
54825
|
-
} = e, o =
|
|
54832
|
+
} = e, o = Ge(r, t), s, l, u = t.fontMetrics(), d = 0, p = 0, m = r && _e.isCharacterBox(r);
|
|
54826
54833
|
if (a) {
|
|
54827
54834
|
var h = t.havingStyle(t.style.sup());
|
|
54828
|
-
s =
|
|
54835
|
+
s = Ge(a, h, t), m || (d = o.height - h.fontMetrics().supDrop * h.sizeMultiplier / t.sizeMultiplier);
|
|
54829
54836
|
}
|
|
54830
54837
|
if (i) {
|
|
54831
54838
|
var g = t.havingStyle(t.style.sub());
|
|
54832
|
-
l =
|
|
54839
|
+
l = Ge(i, g, t), m || (p = o.depth + g.fontMetrics().subDrop * g.sizeMultiplier / t.sizeMultiplier);
|
|
54833
54840
|
}
|
|
54834
54841
|
var f;
|
|
54835
54842
|
t.style === xe.DISPLAY ? f = u.sup1 : t.style.cramped ? f = u.sup3 : f = u.sup2;
|
|
@@ -55094,7 +55101,7 @@ me({
|
|
|
55094
55101
|
};
|
|
55095
55102
|
},
|
|
55096
55103
|
htmlBuilder(e, t) {
|
|
55097
|
-
var n =
|
|
55104
|
+
var n = Ge(e.body, t), r = X.makeLineSpan("underline-line", t), a = t.fontMetrics().defaultRuleThickness, i = X.makeVList({
|
|
55098
55105
|
positionType: "top",
|
|
55099
55106
|
positionData: n.height,
|
|
55100
55107
|
children: [{
|
|
@@ -55140,7 +55147,7 @@ me({
|
|
|
55140
55147
|
};
|
|
55141
55148
|
},
|
|
55142
55149
|
htmlBuilder(e, t) {
|
|
55143
|
-
var n =
|
|
55150
|
+
var n = Ge(e.body, t), r = t.fontMetrics().axisHeight, a = 0.5 * (n.height - r - (n.depth + r));
|
|
55144
55151
|
return X.makeVList({
|
|
55145
55152
|
positionType: "shift",
|
|
55146
55153
|
positionData: a,
|
|
@@ -58107,7 +58114,7 @@ function uh(e, t, n, r, a, i, o, s, l, u, d, p, m, h, g) {
|
|
|
58107
58114
|
return e.enter(r), e.enter(a), e.consume(R), e.exit(a), k;
|
|
58108
58115
|
}
|
|
58109
58116
|
function k(R) {
|
|
58110
|
-
return R === 35 ? (f = o, _(R)) : R === 46 ? (f = s, _(R)) : g && Oe(R) ? Te(e, k, "whitespace")(R) : !g &&
|
|
58117
|
+
return R === 35 ? (f = o, _(R)) : R === 46 ? (f = s, _(R)) : g && Oe(R) ? Te(e, k, "whitespace")(R) : !g && Ve(R) ? Un(e, k)(R) : R === null || he(R) || xn(R) || dr(R) && R !== 45 && R !== 95 ? W(R) : (e.enter(i), e.enter(l), e.consume(R), x);
|
|
58111
58118
|
}
|
|
58112
58119
|
function _(R) {
|
|
58113
58120
|
const U = (
|
|
@@ -58117,7 +58124,7 @@ function uh(e, t, n, r, a, i, o, s, l, u, d, p, m, h, g) {
|
|
|
58117
58124
|
return e.enter(i), e.enter(f), e.enter(U), e.consume(R), e.exit(U), E;
|
|
58118
58125
|
}
|
|
58119
58126
|
function E(R) {
|
|
58120
|
-
if (R === null || R === 34 || R === 35 || R === 39 || R === 46 || R === 60 || R === 61 || R === 62 || R === 96 || R === 125 ||
|
|
58127
|
+
if (R === null || R === 34 || R === 35 || R === 39 || R === 46 || R === 60 || R === 61 || R === 62 || R === 96 || R === 125 || Ve(R))
|
|
58121
58128
|
return n(R);
|
|
58122
58129
|
const U = (
|
|
58123
58130
|
/** @type {TokenType} */
|
|
@@ -58128,7 +58135,7 @@ function uh(e, t, n, r, a, i, o, s, l, u, d, p, m, h, g) {
|
|
|
58128
58135
|
function S(R) {
|
|
58129
58136
|
if (R === null || R === 34 || R === 39 || R === 60 || R === 61 || R === 62 || R === 96)
|
|
58130
58137
|
return n(R);
|
|
58131
|
-
if (R === 35 || R === 46 || R === 125 ||
|
|
58138
|
+
if (R === 35 || R === 46 || R === 125 || Ve(R)) {
|
|
58132
58139
|
const U = (
|
|
58133
58140
|
/** @type {TokenType} */
|
|
58134
58141
|
f + "Value"
|
|
@@ -58138,16 +58145,16 @@ function uh(e, t, n, r, a, i, o, s, l, u, d, p, m, h, g) {
|
|
|
58138
58145
|
return e.consume(R), S;
|
|
58139
58146
|
}
|
|
58140
58147
|
function x(R) {
|
|
58141
|
-
return R === null || he(R) || xn(R) || dr(R) && R !== 45 && R !== 46 && R !== 58 && R !== 95 ? (e.exit(l), g && Oe(R) ? Te(e, D, "whitespace")(R) : !g &&
|
|
58148
|
+
return R === null || he(R) || xn(R) || dr(R) && R !== 45 && R !== 46 && R !== 58 && R !== 95 ? (e.exit(l), g && Oe(R) ? Te(e, D, "whitespace")(R) : !g && Ve(R) ? Un(e, D)(R) : D(R)) : (e.consume(R), x);
|
|
58142
58149
|
}
|
|
58143
58150
|
function D(R) {
|
|
58144
58151
|
return R === 61 ? (e.enter(u), e.consume(R), e.exit(u), P) : (e.exit(i), k(R));
|
|
58145
58152
|
}
|
|
58146
58153
|
function P(R) {
|
|
58147
|
-
return R === null || R === 60 || R === 61 || R === 62 || R === 96 || R === 125 || g && he(R) ? n(R) : R === 34 || R === 39 ? (e.enter(d), e.enter(m), e.consume(R), e.exit(m), w = R, L) : g && Oe(R) ? Te(e, P, "whitespace")(R) : !g &&
|
|
58154
|
+
return R === null || R === 60 || R === 61 || R === 62 || R === 96 || R === 125 || g && he(R) ? n(R) : R === 34 || R === 39 ? (e.enter(d), e.enter(m), e.consume(R), e.exit(m), w = R, L) : g && Oe(R) ? Te(e, P, "whitespace")(R) : !g && Ve(R) ? Un(e, P)(R) : (e.enter(p), e.enter(h), e.consume(R), w = void 0, T);
|
|
58148
58155
|
}
|
|
58149
58156
|
function T(R) {
|
|
58150
|
-
return R === null || R === 34 || R === 39 || R === 60 || R === 61 || R === 62 || R === 96 ? n(R) : R === 125 ||
|
|
58157
|
+
return R === null || R === 34 || R === 39 || R === 60 || R === 61 || R === 62 || R === 96 ? n(R) : R === 125 || Ve(R) ? (e.exit(h), e.exit(p), e.exit(i), k(R)) : (e.consume(R), T);
|
|
58151
58158
|
}
|
|
58152
58159
|
function L(R) {
|
|
58153
58160
|
return R === w ? (e.enter(m), e.consume(R), e.exit(m), e.exit(d), e.exit(i), Q) : (e.enter(p), j(R));
|
|
@@ -58159,7 +58166,7 @@ function uh(e, t, n, r, a, i, o, s, l, u, d, p, m, h, g) {
|
|
|
58159
58166
|
return R === w || R === null || he(R) ? (e.exit(h), j(R)) : (e.consume(R), Z);
|
|
58160
58167
|
}
|
|
58161
58168
|
function Q(R) {
|
|
58162
|
-
return R === 125 ||
|
|
58169
|
+
return R === 125 || Ve(R) ? k(R) : W(R);
|
|
58163
58170
|
}
|
|
58164
58171
|
function W(R) {
|
|
58165
58172
|
return R === 125 ? (e.enter(a), e.consume(R), e.exit(a), e.exit(r), t) : n(R);
|
|
@@ -70099,7 +70106,7 @@ function iOe(e) {
|
|
|
70099
70106
|
...Uf
|
|
70100
70107
|
],
|
|
70101
70108
|
end: /}/
|
|
70102
|
-
},
|
|
70109
|
+
}, He = {
|
|
70103
70110
|
match: [
|
|
70104
70111
|
/class\b/,
|
|
70105
70112
|
/\s+/,
|
|
@@ -70182,7 +70189,7 @@ function iOe(e) {
|
|
|
70182
70189
|
...r,
|
|
70183
70190
|
ot,
|
|
70184
70191
|
We,
|
|
70185
|
-
|
|
70192
|
+
He,
|
|
70186
70193
|
Ye,
|
|
70187
70194
|
Ae,
|
|
70188
70195
|
re,
|
|
@@ -72320,14 +72327,14 @@ https://github.com/highlightjs/highlight.js/issues/2277`), N = U, V = H), $ ===
|
|
|
72320
72327
|
}
|
|
72321
72328
|
function J() {
|
|
72322
72329
|
if (!de.keywords) {
|
|
72323
|
-
Ze.addText(
|
|
72330
|
+
Ze.addText(je);
|
|
72324
72331
|
return;
|
|
72325
72332
|
}
|
|
72326
72333
|
let q = 0;
|
|
72327
72334
|
de.keywordPatternRe.lastIndex = 0;
|
|
72328
|
-
let Y = de.keywordPatternRe.exec(
|
|
72335
|
+
let Y = de.keywordPatternRe.exec(je), te = "";
|
|
72329
72336
|
for (; Y; ) {
|
|
72330
|
-
te +=
|
|
72337
|
+
te += je.substring(q, Y.index);
|
|
72331
72338
|
const pe = Ae.case_insensitive ? Y[0].toLowerCase() : Y[0], Ee = K(de, pe);
|
|
72332
72339
|
if (Ee) {
|
|
72333
72340
|
const [Le, _t] = Ee;
|
|
@@ -72339,27 +72346,27 @@ https://github.com/highlightjs/highlight.js/issues/2277`), N = U, V = H), $ ===
|
|
|
72339
72346
|
}
|
|
72340
72347
|
} else
|
|
72341
72348
|
te += Y[0];
|
|
72342
|
-
q = de.keywordPatternRe.lastIndex, Y = de.keywordPatternRe.exec(
|
|
72349
|
+
q = de.keywordPatternRe.lastIndex, Y = de.keywordPatternRe.exec(je);
|
|
72343
72350
|
}
|
|
72344
|
-
te +=
|
|
72351
|
+
te += je.substring(q), Ze.addText(te);
|
|
72345
72352
|
}
|
|
72346
72353
|
function O() {
|
|
72347
|
-
if (
|
|
72354
|
+
if (je === "")
|
|
72348
72355
|
return;
|
|
72349
72356
|
let q = null;
|
|
72350
72357
|
if (typeof de.subLanguage == "string") {
|
|
72351
72358
|
if (!t[de.subLanguage]) {
|
|
72352
|
-
Ze.addText(
|
|
72359
|
+
Ze.addText(je);
|
|
72353
72360
|
return;
|
|
72354
72361
|
}
|
|
72355
|
-
q = p(de.subLanguage,
|
|
72362
|
+
q = p(de.subLanguage, je, !0, tt[de.subLanguage]), tt[de.subLanguage] = /** @type {CompiledMode} */
|
|
72356
72363
|
q._top;
|
|
72357
72364
|
} else
|
|
72358
|
-
q = h(
|
|
72365
|
+
q = h(je, de.subLanguage.length ? de.subLanguage : null);
|
|
72359
72366
|
de.relevance > 0 && (ce += q.relevance), Ze.__addSublanguage(q._emitter, q.language);
|
|
72360
72367
|
}
|
|
72361
72368
|
function le() {
|
|
72362
|
-
de.subLanguage != null ? O() : J(),
|
|
72369
|
+
de.subLanguage != null ? O() : J(), je = "";
|
|
72363
72370
|
}
|
|
72364
72371
|
function fe(q, Y) {
|
|
72365
72372
|
q !== "" && (Ze.startScope(Y), Ze.addText(q), Ze.endScope());
|
|
@@ -72373,11 +72380,11 @@ https://github.com/highlightjs/highlight.js/issues/2277`), N = U, V = H), $ ===
|
|
|
72373
72380
|
continue;
|
|
72374
72381
|
}
|
|
72375
72382
|
const Ee = Ae.classNameAliases[q[te]] || q[te], Le = Y[te];
|
|
72376
|
-
Ee ? fe(Le, Ee) : (
|
|
72383
|
+
Ee ? fe(Le, Ee) : (je = Le, J(), je = ""), te++;
|
|
72377
72384
|
}
|
|
72378
72385
|
}
|
|
72379
72386
|
function Ce(q, Y) {
|
|
72380
|
-
return q.scope && typeof q.scope == "string" && Ze.openNode(Ae.classNameAliases[q.scope] || q.scope), q.beginScope && (q.beginScope._wrap ? (fe(
|
|
72387
|
+
return q.scope && typeof q.scope == "string" && Ze.openNode(Ae.classNameAliases[q.scope] || q.scope), q.beginScope && (q.beginScope._wrap ? (fe(je, Ae.classNameAliases[q.beginScope._wrap] || q.beginScope._wrap), je = "") : q.beginScope._multi && (ke(q.beginScope, Y), je = "")), de = Object.create(q, { parent: { value: de } }), de;
|
|
72381
72388
|
}
|
|
72382
72389
|
function Pe(q, Y, te) {
|
|
72383
72390
|
let pe = vOe(q.endRe, te);
|
|
@@ -72396,21 +72403,21 @@ https://github.com/highlightjs/highlight.js/issues/2277`), N = U, V = H), $ ===
|
|
|
72396
72403
|
return Pe(q.parent, Y, te);
|
|
72397
72404
|
}
|
|
72398
72405
|
function ot(q) {
|
|
72399
|
-
return de.matcher.regexIndex === 0 ? (
|
|
72406
|
+
return de.matcher.regexIndex === 0 ? (je += q[0], 1) : (qe = !0, 0);
|
|
72400
72407
|
}
|
|
72401
72408
|
function We(q) {
|
|
72402
72409
|
const Y = q[0], te = q.rule, pe = new Vf(te), Ee = [te.__beforeBegin, te["on:begin"]];
|
|
72403
72410
|
for (const Le of Ee)
|
|
72404
72411
|
if (Le && (Le(q, pe), pe.isMatchIgnored))
|
|
72405
72412
|
return ot(Y);
|
|
72406
|
-
return te.skip ?
|
|
72413
|
+
return te.skip ? je += Y : (te.excludeBegin && (je += Y), le(), !te.returnBegin && !te.excludeBegin && (je = Y)), Ce(te, q), te.returnBegin ? 0 : Y.length;
|
|
72407
72414
|
}
|
|
72408
72415
|
function re(q) {
|
|
72409
72416
|
const Y = q[0], te = H.substring(q.index), pe = Pe(de, q, te);
|
|
72410
72417
|
if (!pe)
|
|
72411
72418
|
return Zf;
|
|
72412
72419
|
const Ee = de;
|
|
72413
|
-
de.endScope && de.endScope._wrap ? (le(), fe(Y, de.endScope._wrap)) : de.endScope && de.endScope._multi ? (le(), ke(de.endScope, q)) : Ee.skip ?
|
|
72420
|
+
de.endScope && de.endScope._wrap ? (le(), fe(Y, de.endScope._wrap)) : de.endScope && de.endScope._multi ? (le(), ke(de.endScope, q)) : Ee.skip ? je += Y : (Ee.returnEnd || Ee.excludeEnd || (je += Y), le(), Ee.excludeEnd && (je = Y));
|
|
72414
72421
|
do
|
|
72415
72422
|
de.scope && Ze.closeNode(), !de.skip && !de.subLanguage && (ce += de.relevance), de = de.parent;
|
|
72416
72423
|
while (de !== pe.parent);
|
|
@@ -72422,19 +72429,19 @@ https://github.com/highlightjs/highlight.js/issues/2277`), N = U, V = H), $ ===
|
|
|
72422
72429
|
Y.scope && q.unshift(Y.scope);
|
|
72423
72430
|
q.forEach((Y) => Ze.openNode(Y));
|
|
72424
72431
|
}
|
|
72425
|
-
let
|
|
72432
|
+
let He = {};
|
|
72426
72433
|
function Ye(q, Y) {
|
|
72427
72434
|
const te = Y && Y[0];
|
|
72428
|
-
if (
|
|
72435
|
+
if (je += q, te == null)
|
|
72429
72436
|
return le(), 0;
|
|
72430
|
-
if (
|
|
72431
|
-
if (
|
|
72437
|
+
if (He.type === "begin" && Y.type === "end" && He.index === Y.index && te === "") {
|
|
72438
|
+
if (je += H.slice(Y.index, Y.index + 1), !a) {
|
|
72432
72439
|
const pe = new Error(`0 width match regex (${U})`);
|
|
72433
|
-
throw pe.languageName = U, pe.badRule =
|
|
72440
|
+
throw pe.languageName = U, pe.badRule = He.rule, pe;
|
|
72434
72441
|
}
|
|
72435
72442
|
return 1;
|
|
72436
72443
|
}
|
|
72437
|
-
if (
|
|
72444
|
+
if (He = Y, Y.type === "begin")
|
|
72438
72445
|
return We(Y);
|
|
72439
72446
|
if (Y.type === "illegal" && !$) {
|
|
72440
72447
|
const pe = new Error('Illegal lexeme "' + te + '" for mode "' + (de.scope || "<unnamed>") + '"');
|
|
@@ -72445,11 +72452,11 @@ https://github.com/highlightjs/highlight.js/issues/2277`), N = U, V = H), $ ===
|
|
|
72445
72452
|
return pe;
|
|
72446
72453
|
}
|
|
72447
72454
|
if (Y.type === "illegal" && te === "")
|
|
72448
|
-
return
|
|
72455
|
+
return je += `
|
|
72449
72456
|
`, 1;
|
|
72450
72457
|
if (ye > 1e5 && ye > Y.index * 3)
|
|
72451
72458
|
throw new Error("potential infinite loop, way more iterations than matches");
|
|
72452
|
-
return
|
|
72459
|
+
return je += te, te.length;
|
|
72453
72460
|
}
|
|
72454
72461
|
const Ae = P(U);
|
|
72455
72462
|
if (!Ae)
|
|
@@ -72458,7 +72465,7 @@ https://github.com/highlightjs/highlight.js/issues/2277`), N = U, V = H), $ ===
|
|
|
72458
72465
|
let Ke = "", de = V || ve;
|
|
72459
72466
|
const tt = {}, Ze = new s.__emitter(s);
|
|
72460
72467
|
Se();
|
|
72461
|
-
let
|
|
72468
|
+
let je = "", ce = 0, Me = 0, ye = 0, qe = !1;
|
|
72462
72469
|
try {
|
|
72463
72470
|
if (Ae.__emitTokens)
|
|
72464
72471
|
Ae.__emitTokens(H, Ze);
|
|
@@ -74934,11 +74941,11 @@ var p7 = { exports: {} };
|
|
|
74934
74941
|
Pe && (re = m(_, re, Pe), V += Pe.length), h(_, re, K);
|
|
74935
74942
|
var Se = new l(P, Z ? s.tokenize(Ce, Z) : Ce, R, Ce);
|
|
74936
74943
|
if ($ = m(_, re, Se), ot && m(_, $, ot), K > 1) {
|
|
74937
|
-
var
|
|
74944
|
+
var He = {
|
|
74938
74945
|
cause: P + "," + L,
|
|
74939
74946
|
reach: We
|
|
74940
74947
|
};
|
|
74941
|
-
d(k, _, E, $.prev, V,
|
|
74948
|
+
d(k, _, E, $.prev, V, He), D && He.reach > D.reach && (D.reach = He.reach);
|
|
74942
74949
|
}
|
|
74943
74950
|
}
|
|
74944
74951
|
}
|
|
@@ -96449,7 +96456,7 @@ const lVe = () => /* @__PURE__ */ se("span", { className: "mp-agent-message-typi
|
|
|
96449
96456
|
isStreaming: n,
|
|
96450
96457
|
showParticipantChrome: r = !1
|
|
96451
96458
|
}) => {
|
|
96452
|
-
const o =
|
|
96459
|
+
const o = Ue().config.features?.reasoning !== !1 && e.role === Qe.Assistant && !!e.reasoning, s = e.role === Qe.Assistant && typeof e.content == "string" && e.content.trim().length > 0, l = !!(n && !o && !s), u = typeof e.content == "string" && e.content.trim().length > 0 || (e.attachments?.length ?? 0) > 0, d = (() => {
|
|
96453
96460
|
const p = e.toolCalls ?? [];
|
|
96454
96461
|
if (p.length <= 1)
|
|
96455
96462
|
return p;
|
|
@@ -96589,7 +96596,7 @@ const lVe = () => /* @__PURE__ */ se("span", { className: "mp-agent-message-typi
|
|
|
96589
96596
|
);
|
|
96590
96597
|
}
|
|
96591
96598
|
), mVe = ({ onClose: e, agentLogo: t }) => {
|
|
96592
|
-
const n = gn(), a =
|
|
96599
|
+
const n = gn(), a = Ue().config.features?.historySidebar !== !1, i = be((u) => u.isChatHistoryOpen), o = be((u) => u.setChatHistoryOpen), s = be((u) => u.setActiveChat), l = () => {
|
|
96593
96600
|
s(void 0);
|
|
96594
96601
|
};
|
|
96595
96602
|
return /* @__PURE__ */ se("div", { className: "mp-agent-agent-controls", children: [
|
|
@@ -96682,7 +96689,7 @@ const lVe = () => /* @__PURE__ */ se("span", { className: "mp-agent-message-typi
|
|
|
96682
96689
|
] })
|
|
96683
96690
|
] });
|
|
96684
96691
|
}, gVe = ({ loadChats: e = !0, multiUser: t = !1 }) => {
|
|
96685
|
-
const n =
|
|
96692
|
+
const n = Ue(), r = be((o) => o.isChatHistoryOpen), a = n.config.features?.historySidebar !== !1, i = g3({ enabled: e && a, multiUser: t });
|
|
96686
96693
|
return !a || !r ? null : /* @__PURE__ */ C("div", { className: "mp-agent-chat-history-panel", children: /* @__PURE__ */ C(
|
|
96687
96694
|
fVe,
|
|
96688
96695
|
{
|
|
@@ -96703,7 +96710,7 @@ const lVe = () => /* @__PURE__ */ se("span", { className: "mp-agent-message-typi
|
|
|
96703
96710
|
loadChats: i = !0,
|
|
96704
96711
|
restoreLastActiveChat: o = !0
|
|
96705
96712
|
}) => {
|
|
96706
|
-
const s = gn(), l =
|
|
96713
|
+
const s = gn(), l = Ue(), u = be((g) => g.activeChatId), d = be((g) => g.setActiveChat), { isLoading: p } = y7e(), { isLoading: m, error: h } = g3({ enabled: i, multiUser: r });
|
|
96707
96714
|
return uo(() => {
|
|
96708
96715
|
if (!o)
|
|
96709
96716
|
return;
|
|
@@ -96872,7 +96879,7 @@ export {
|
|
|
96872
96879
|
OVe as useActivitySummary,
|
|
96873
96880
|
p7e as useAgentConfigurations,
|
|
96874
96881
|
g7e as useAgentPreferences,
|
|
96875
|
-
|
|
96882
|
+
Ue as useAgentRuntime,
|
|
96876
96883
|
be as useAgentStore,
|
|
96877
96884
|
C7e as useAgentTheme,
|
|
96878
96885
|
$Ve as useAutoScroll,
|