page-agent-sdk 4.2.1 → 4.2.2
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/page-agent-sdk.headless.js +2 -1
- package/dist/page-agent-sdk.iife.js +17 -17
- package/dist/page-agent-sdk.js +668 -663
- package/dist/page-agent-sdk.legacy.js +565 -559
- package/dist/page-agent-sdk.umd.cjs +30 -30
- package/dist/style.css +1 -1
- package/package.json +1 -1
- package/style.css +1 -1
package/dist/page-agent-sdk.js
CHANGED
|
@@ -17523,6 +17523,7 @@ function nw(e = {}) {
|
|
|
17523
17523
|
content: "",
|
|
17524
17524
|
timestamp: Date.now(),
|
|
17525
17525
|
reasoning: "",
|
|
17526
|
+
reasoningTotal: 0,
|
|
17526
17527
|
steps: []
|
|
17527
17528
|
}), r = !1;
|
|
17528
17529
|
s.messages.push(t);
|
|
@@ -17533,7 +17534,7 @@ function nw(e = {}) {
|
|
|
17533
17534
|
e.round > 1 && (t.content || t.reasoning) && (r = !0);
|
|
17534
17535
|
break;
|
|
17535
17536
|
case "reasoning":
|
|
17536
|
-
r &&= (t.reasoning += "\n", !1), t.reasoning = (t.reasoning + e.delta).slice(-4e3);
|
|
17537
|
+
r &&= (t.reasoning += "\n", !1), t.reasoningTotal += e.delta.length, t.reasoning = (t.reasoning + e.delta).slice(-4e3);
|
|
17537
17538
|
break;
|
|
17538
17539
|
case "text":
|
|
17539
17540
|
r &&= (t.content += "\n", !1), t.content += e.delta;
|
|
@@ -19502,12 +19503,13 @@ var WT = ["innerHTML"], GT = {
|
|
|
19502
19503
|
running: {
|
|
19503
19504
|
type: Boolean,
|
|
19504
19505
|
default: !1
|
|
19505
|
-
}
|
|
19506
|
+
},
|
|
19507
|
+
total: { default: void 0 }
|
|
19506
19508
|
},
|
|
19507
19509
|
emits: ["toggle"],
|
|
19508
19510
|
setup(e) {
|
|
19509
19511
|
let t = e, n = sc(() => {
|
|
19510
|
-
let e = t.text.length;
|
|
19512
|
+
let e = t.total ?? t.text.length;
|
|
19511
19513
|
if (e < 1e3) return String(e);
|
|
19512
19514
|
let n = e / 1e3;
|
|
19513
19515
|
return `${n >= 100 ? Math.round(n) : +n.toFixed(1)}k`;
|
|
@@ -19525,10 +19527,10 @@ var WT = ["innerHTML"], GT = {
|
|
|
19525
19527
|
Z("span", IE, W(e.expanded ? "收起" : "展开"), 1)
|
|
19526
19528
|
]), e.expanded ? (Y(), X("div", LE, W(e.text), 1)) : Q("", !0)], 2)) : Q("", !0);
|
|
19527
19529
|
}
|
|
19528
|
-
}), [["__scopeId", "data-v-
|
|
19530
|
+
}), [["__scopeId", "data-v-7ff8ea75"]]), zE = ["open"], BE = { class: "sub-reason-head" }, VE = {
|
|
19529
19531
|
key: 0,
|
|
19530
19532
|
class: "sub-reason-trunc"
|
|
19531
|
-
}, HE = ["title"],
|
|
19533
|
+
}, HE = { class: "sub-reason-toggle" }, UE = ["title"], WE = /*#__PURE__*/ qT(/* @__PURE__ */ Wi({
|
|
19532
19534
|
__name: "SubReasonDetails",
|
|
19533
19535
|
props: {
|
|
19534
19536
|
subReason: {},
|
|
@@ -19562,52 +19564,53 @@ var WT = ["innerHTML"], GT = {
|
|
|
19562
19564
|
Z("span", { class: Be(["status-dot sm", e.status === "running" ? "running" : "ok"]) }, null, 2),
|
|
19563
19565
|
Z("span", { class: Be(["sub-reason-label", { pulsing: e.status === "running" }]) }, W(e.status === "running" ? `${e.messages.thinkingCountPrefix}${a.value}${e.messages.charCountSuffix}` : e.messages.reasoningTitle), 3),
|
|
19564
19566
|
o.value ? (Y(), X("span", VE, W(e.messages.truncatedNotePrefix) + W(e.subReason.length) + W(e.messages.truncatedNoteSuffix), 1)) : Q("", !0),
|
|
19567
|
+
Z("span", HE, W(r.value ? e.messages.collapse : e.messages.expand), 1),
|
|
19565
19568
|
Z("button", {
|
|
19566
19569
|
type: "button",
|
|
19567
19570
|
class: Be(["sub-reason-copy", { copied: s.value }]),
|
|
19568
19571
|
title: o.value ? e.messages.copyThinkingTruncTitle : e.messages.copyThinking,
|
|
19569
19572
|
onClick: Ol(c, ["stop", "prevent"])
|
|
19570
|
-
}, W(s.value ? e.messages.copied : e.messages.copy), 11,
|
|
19573
|
+
}, W(s.value ? e.messages.copied : e.messages.copy), 11, UE)
|
|
19571
19574
|
]), Z("div", {
|
|
19572
19575
|
ref_key: "bodyRef",
|
|
19573
19576
|
ref: n,
|
|
19574
19577
|
class: "sub-reason-body"
|
|
19575
19578
|
}, W(o.value ? "…(前面已截断)\n" : "") + W(e.subReason), 513)], 40, zE));
|
|
19576
19579
|
}
|
|
19577
|
-
}), [["__scopeId", "data-v-
|
|
19580
|
+
}), [["__scopeId", "data-v-ee8bc184"]]), GE = {
|
|
19578
19581
|
key: 0,
|
|
19579
19582
|
class: "steps-block"
|
|
19580
|
-
},
|
|
19583
|
+
}, KE = { class: "step-head" }, qE = { class: "step-name" }, JE = ["title"], YE = {
|
|
19581
19584
|
key: 1,
|
|
19582
19585
|
class: "step-count"
|
|
19583
|
-
},
|
|
19586
|
+
}, XE = {
|
|
19584
19587
|
key: 2,
|
|
19585
19588
|
class: "step-duration"
|
|
19586
|
-
},
|
|
19589
|
+
}, ZE = ["onClick"], QE = {
|
|
19587
19590
|
key: 0,
|
|
19588
19591
|
class: "step-detail"
|
|
19589
|
-
},
|
|
19592
|
+
}, $E = {
|
|
19590
19593
|
key: 0,
|
|
19591
19594
|
class: "step-detail-call-label"
|
|
19592
|
-
},
|
|
19595
|
+
}, eD = {
|
|
19593
19596
|
key: 1,
|
|
19594
19597
|
class: "step-detail-section"
|
|
19595
|
-
},
|
|
19598
|
+
}, tD = { class: "step-detail-head" }, nD = ["onClick"], rD = { class: "step-detail-pre" }, iD = {
|
|
19596
19599
|
key: 2,
|
|
19597
19600
|
class: "step-detail-section"
|
|
19598
|
-
},
|
|
19601
|
+
}, aD = { class: "step-detail-head" }, oD = ["onClick"], sD = {
|
|
19599
19602
|
key: 3,
|
|
19600
19603
|
class: "step-detail-empty"
|
|
19601
|
-
},
|
|
19604
|
+
}, cD = {
|
|
19602
19605
|
key: 2,
|
|
19603
19606
|
class: "step-children"
|
|
19604
|
-
},
|
|
19607
|
+
}, lD = { class: "step-children-label" }, uD = { class: "step-name" }, dD = {
|
|
19605
19608
|
key: 0,
|
|
19606
19609
|
class: "step-count"
|
|
19607
|
-
},
|
|
19610
|
+
}, fD = {
|
|
19608
19611
|
key: 1,
|
|
19609
19612
|
class: "step-status running"
|
|
19610
|
-
},
|
|
19613
|
+
}, pD = 2e3, mD = 4e3, hD = /*#__PURE__*/ qT(/* @__PURE__ */ Wi({
|
|
19611
19614
|
__name: "MessageSteps",
|
|
19612
19615
|
props: {
|
|
19613
19616
|
steps: {},
|
|
@@ -19686,8 +19689,8 @@ var WT = ["innerHTML"], GT = {
|
|
|
19686
19689
|
} catch {
|
|
19687
19690
|
n = String(e);
|
|
19688
19691
|
}
|
|
19689
|
-
return n.length >
|
|
19690
|
-
text: n.slice(0,
|
|
19692
|
+
return n.length > pD ? {
|
|
19693
|
+
text: n.slice(0, pD) + t.messages.displayTruncatedSuffix,
|
|
19691
19694
|
truncated: !0
|
|
19692
19695
|
} : {
|
|
19693
19696
|
text: n,
|
|
@@ -19707,8 +19710,8 @@ var WT = ["innerHTML"], GT = {
|
|
|
19707
19710
|
truncated: !1
|
|
19708
19711
|
};
|
|
19709
19712
|
let n = m(e);
|
|
19710
|
-
return n.length >
|
|
19711
|
-
text: n.slice(0,
|
|
19713
|
+
return n.length > mD ? {
|
|
19714
|
+
text: n.slice(0, mD) + t.messages.displayTruncatedSuffix,
|
|
19712
19715
|
truncated: !0
|
|
19713
19716
|
} : {
|
|
19714
19717
|
text: n,
|
|
@@ -19728,45 +19731,45 @@ var WT = ["innerHTML"], GT = {
|
|
|
19728
19731
|
}
|
|
19729
19732
|
rw(e);
|
|
19730
19733
|
}
|
|
19731
|
-
return (t, s) => e.steps.length ? (Y(), X("div",
|
|
19734
|
+
return (t, s) => e.steps.length ? (Y(), X("div", GE, [(Y(!0), X(J, null, ga(i.value, (t, i) => (Y(), X("div", {
|
|
19732
19735
|
key: i,
|
|
19733
19736
|
class: Be(["step-item", t.status])
|
|
19734
19737
|
}, [
|
|
19735
|
-
Z("div",
|
|
19738
|
+
Z("div", KE, [
|
|
19736
19739
|
Z("span", { class: Be(["status-dot", t.status]) }, null, 2),
|
|
19737
|
-
Z("span",
|
|
19740
|
+
Z("span", qE, W(t.name), 1),
|
|
19738
19741
|
a(t.name) ? (Y(), X("span", {
|
|
19739
19742
|
key: 0,
|
|
19740
19743
|
class: "subagent-badge",
|
|
19741
19744
|
title: e.messages.subagentBadgeTitle
|
|
19742
|
-
}, [xs(JT, { icon: e.icons.subagent }, null, 8, ["icon"]), Es(" " + W(e.messages.subagentBadge), 1)], 8,
|
|
19743
|
-
t.count > 1 ? (Y(), X("span",
|
|
19745
|
+
}, [xs(JT, { icon: e.icons.subagent }, null, 8, ["icon"]), Es(" " + W(e.messages.subagentBadge), 1)], 8, JE)) : Q("", !0),
|
|
19746
|
+
t.count > 1 ? (Y(), X("span", YE, "×" + W(t.count), 1)) : Q("", !0),
|
|
19744
19747
|
Z("span", { class: Be(["step-status", t.status]) }, [xs(XT, { text: n(t.status) }, null, 8, ["text"])], 2),
|
|
19745
|
-
t.durationMs != null && t.status !== "running" ? (Y(), X("span",
|
|
19748
|
+
t.durationMs != null && t.status !== "running" ? (Y(), X("span", XE, W(o(t.durationMs)), 1)) : Q("", !0),
|
|
19746
19749
|
f(t.calls) ? (Y(), X("button", {
|
|
19747
19750
|
key: 3,
|
|
19748
19751
|
type: "button",
|
|
19749
19752
|
class: Be(["step-detail-toggle", { open: u.has(i) }]),
|
|
19750
19753
|
onClick: (e) => d(i)
|
|
19751
|
-
}, W(u.has(i) ? e.messages.collapse : e.messages.expand), 11,
|
|
19754
|
+
}, W(u.has(i) ? e.messages.collapse : e.messages.expand), 11, ZE)) : Q("", !0)
|
|
19752
19755
|
]),
|
|
19753
|
-
u.has(i) && t.calls?.length ? (Y(), X("div",
|
|
19756
|
+
u.has(i) && t.calls?.length ? (Y(), X("div", QE, [(Y(!0), X(J, null, ga(t.calls, (n, r) => (Y(), X("div", {
|
|
19754
19757
|
key: r,
|
|
19755
19758
|
class: "step-detail-call"
|
|
19756
19759
|
}, [
|
|
19757
|
-
t.count > 1 ? (Y(), X("div",
|
|
19758
|
-
p(n.args).text ? (Y(), X("div",
|
|
19760
|
+
t.count > 1 ? (Y(), X("div", $E, W(e.messages.nthCallPrefix) + W(r + 1) + W(e.messages.nthCallSuffix), 1)) : Q("", !0),
|
|
19761
|
+
p(n.args).text ? (Y(), X("div", eD, [Z("div", tD, [Es(W(e.messages.argsLabel), 1), Z("button", {
|
|
19759
19762
|
type: "button",
|
|
19760
19763
|
class: "step-detail-copy",
|
|
19761
19764
|
onClick: (e) => g(p(n.args).text, p(n.args).truncated, n.args)
|
|
19762
|
-
}, W(e.messages.copy), 9,
|
|
19763
|
-
n.status !== "running" && h(n.result).text ? (Y(), X("div",
|
|
19765
|
+
}, W(e.messages.copy), 9, nD)]), Z("pre", rD, W(p(n.args).text), 1)])) : Q("", !0),
|
|
19766
|
+
n.status !== "running" && h(n.result).text ? (Y(), X("div", iD, [Z("div", aD, [Es(W(e.messages.resultLabel), 1), Z("button", {
|
|
19764
19767
|
type: "button",
|
|
19765
19768
|
class: "step-detail-copy",
|
|
19766
19769
|
onClick: (e) => g(h(n.result).text, h(n.result).truncated, n.result)
|
|
19767
|
-
}, W(e.messages.copy), 9,
|
|
19770
|
+
}, W(e.messages.copy), 9, oD)]), Z("pre", { class: Be(["step-detail-pre", { err: n.status === "error" }]) }, W(h(n.result).text), 3)])) : n.status !== "running" && !h(n.result).text ? (Y(), X("div", sD, W(e.messages.noResult), 1)) : Q("", !0)
|
|
19768
19771
|
]))), 128))])) : Q("", !0),
|
|
19769
|
-
t.subReason ? (Y(), ms(
|
|
19772
|
+
t.subReason ? (Y(), ms(WE, {
|
|
19770
19773
|
key: 1,
|
|
19771
19774
|
"sub-reason": t.subReason,
|
|
19772
19775
|
"sub-reason-full": t.subReasonFull,
|
|
@@ -19778,21 +19781,21 @@ var WT = ["innerHTML"], GT = {
|
|
|
19778
19781
|
"status",
|
|
19779
19782
|
"messages"
|
|
19780
19783
|
])) : Q("", !0),
|
|
19781
|
-
t.children && t.children.length ? (Y(), X("div",
|
|
19784
|
+
t.children && t.children.length ? (Y(), X("div", cD, [Z("div", lD, [xs(JT, { icon: e.icons.subagentProgress }, null, 8, ["icon"]), Es(" " + W(e.messages.subagentProgress), 1)]), (Y(!0), X(J, null, ga(r(t.children), (e, t) => (Y(), X("div", {
|
|
19782
19785
|
key: t,
|
|
19783
19786
|
class: Be(["step-child", e.status])
|
|
19784
19787
|
}, [
|
|
19785
19788
|
Z("span", { class: Be(["status-dot sm", e.status]) }, null, 2),
|
|
19786
|
-
Z("span",
|
|
19787
|
-
e.count > 1 ? (Y(), X("span",
|
|
19788
|
-
e.status === "running" ? (Y(), X("span",
|
|
19789
|
+
Z("span", uD, W(e.name), 1),
|
|
19790
|
+
e.count > 1 ? (Y(), X("span", dD, "×" + W(e.count), 1)) : Q("", !0),
|
|
19791
|
+
e.status === "running" ? (Y(), X("span", fD, "…")) : Q("", !0)
|
|
19789
19792
|
], 2))), 128))])) : Q("", !0)
|
|
19790
19793
|
], 2))), 128))])) : Q("", !0);
|
|
19791
19794
|
}
|
|
19792
19795
|
}), [["__scopeId", "data-v-09c0a586"]]);
|
|
19793
19796
|
//#endregion
|
|
19794
19797
|
//#region node_modules/marked/lib/marked.esm.js
|
|
19795
|
-
function
|
|
19798
|
+
function gD() {
|
|
19796
19799
|
return {
|
|
19797
19800
|
async: !1,
|
|
19798
19801
|
breaks: !1,
|
|
@@ -19806,35 +19809,35 @@ function hD() {
|
|
|
19806
19809
|
walkTokens: null
|
|
19807
19810
|
};
|
|
19808
19811
|
}
|
|
19809
|
-
var
|
|
19810
|
-
function
|
|
19811
|
-
|
|
19812
|
+
var _D = gD();
|
|
19813
|
+
function vD(e) {
|
|
19814
|
+
_D = e;
|
|
19812
19815
|
}
|
|
19813
|
-
var
|
|
19814
|
-
function
|
|
19816
|
+
var yD = { exec: () => null };
|
|
19817
|
+
function bD(e) {
|
|
19815
19818
|
let t = [];
|
|
19816
19819
|
return (n) => {
|
|
19817
19820
|
let r = Math.max(0, Math.min(3, n - 1)), i = t[r];
|
|
19818
19821
|
return i || (i = e(r), t[r] = i), i;
|
|
19819
19822
|
};
|
|
19820
19823
|
}
|
|
19821
|
-
function
|
|
19824
|
+
function xD(e, t = "") {
|
|
19822
19825
|
let n = typeof e == "string" ? e : e.source, r = {
|
|
19823
19826
|
replace: (e, t) => {
|
|
19824
19827
|
let i = typeof t == "string" ? t : t.source;
|
|
19825
|
-
return i = i.replace(
|
|
19828
|
+
return i = i.replace(CD.caret, "$1"), n = n.replace(e, i), r;
|
|
19826
19829
|
},
|
|
19827
19830
|
getRegex: () => new RegExp(n, t)
|
|
19828
19831
|
};
|
|
19829
19832
|
return r;
|
|
19830
19833
|
}
|
|
19831
|
-
var
|
|
19834
|
+
var SD = ((e = "") => {
|
|
19832
19835
|
try {
|
|
19833
19836
|
return !!RegExp("(?<=1)(?<!1)" + e);
|
|
19834
19837
|
} catch {
|
|
19835
19838
|
return !1;
|
|
19836
19839
|
}
|
|
19837
|
-
})(),
|
|
19840
|
+
})(), CD = {
|
|
19838
19841
|
codeRemoveIndent: /^(?: {1,4}| {0,3}\t)/gm,
|
|
19839
19842
|
outputLinkReplace: /\\([\[\]])/g,
|
|
19840
19843
|
indentCodeCompensation: /^(\s+)(?:```)/,
|
|
@@ -19885,121 +19888,121 @@ var xD = ((e = "") => {
|
|
|
19885
19888
|
notSpaceStart: /^\S*/,
|
|
19886
19889
|
endingNewline: /\n$/,
|
|
19887
19890
|
listItemRegex: (e) => RegExp(`^( {0,3}${e})((?:[ ][^\\n]*)?(?:\\n|$))`),
|
|
19888
|
-
nextBulletRegex:
|
|
19889
|
-
hrRegex:
|
|
19890
|
-
fencesBeginRegex:
|
|
19891
|
-
headingBeginRegex:
|
|
19892
|
-
htmlBeginRegex:
|
|
19893
|
-
blockquoteBeginRegex:
|
|
19894
|
-
},
|
|
19895
|
-
blockquote:
|
|
19896
|
-
code:
|
|
19897
|
-
def:
|
|
19898
|
-
fences:
|
|
19899
|
-
heading:
|
|
19900
|
-
hr:
|
|
19901
|
-
html:
|
|
19902
|
-
lheading: AD,
|
|
19903
|
-
list: ID,
|
|
19904
|
-
newline: CD,
|
|
19905
|
-
paragraph: VD,
|
|
19906
|
-
table: vD,
|
|
19907
|
-
text: ND
|
|
19908
|
-
}, WD = bD("^ *([^\\n ].*)\\n {0,3}((?:\\| *)?:?-+:? *(?:\\| *:?-+:? *)*(?:\\| *)?)(?:\\n((?:(?! *\\n|hr|heading|blockquote|code|fences|list|html).*(?:\\n|$))*)\\n*|$)").replace("hr", ED).replace("heading", " {0,3}#{1,6}(?:\\s|$)").replace("blockquote", " {0,3}>").replace("code", "(?: {4}| {0,3} )[^\\n]").replace("fences", " {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list", " {0,3}(?:[*+-]|1[.)])[ \\t]").replace("html", "</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag", LD).getRegex(), GD = {
|
|
19909
|
-
...UD,
|
|
19891
|
+
nextBulletRegex: bD((e) => RegExp(`^ {0,${e}}(?:[*+-]|\\d{1,9}[.)])((?:[ ][^\\n]*)?(?:\\n|$))`)),
|
|
19892
|
+
hrRegex: bD((e) => RegExp(`^ {0,${e}}((?:- *){3,}|(?:_ *){3,}|(?:\\* *){3,})(?:\\n+|$)`)),
|
|
19893
|
+
fencesBeginRegex: bD((e) => RegExp(`^ {0,${e}}(?:\`\`\`|~~~)`)),
|
|
19894
|
+
headingBeginRegex: bD((e) => RegExp(`^ {0,${e}}#`)),
|
|
19895
|
+
htmlBeginRegex: bD((e) => RegExp(`^ {0,${e}}<(?:[a-z].*>|!--)`, "i")),
|
|
19896
|
+
blockquoteBeginRegex: bD((e) => RegExp(`^ {0,${e}}>`))
|
|
19897
|
+
}, wD = /^(?:[ \t]*(?:\n|$))+/, TD = /^((?: {4}| {0,3}\t)[^\n]+(?:\n(?:[ \t]*(?:\n|$))*)?)+/, ED = /^ {0,3}(`{3,}(?=[^`\n]*(?:\n|$))|~{3,})([^\n]*)(?:\n|$)(?:|([\s\S]*?)(?:\n|$))(?: {0,3}\1[~`]* *(?=\n|$)|$)/, DD = /^ {0,3}((?:-[\t ]*){3,}|(?:_[ \t]*){3,}|(?:\*[ \t]*){3,})(?:\n+|$)/, OD = /^ {0,3}(#{1,6})(?=\s|$)(.*)(?:\n+|$)/, kD = / {0,3}(?:[*+-]|\d{1,9}[.)])/, AD = /^(?!bull |blockCode|fences|blockquote|heading|html|table)((?:.|\n(?!\s*?\n|bull |blockCode|fences|blockquote|heading|html|table))+?)\n {0,3}(=+|-+) *(?:\n+|$)/, jD = xD(AD).replace(/bull/g, kD).replace(/blockCode/g, /(?: {4}| {0,3}\t)/).replace(/fences/g, / {0,3}(?:`{3,}|~{3,})/).replace(/blockquote/g, / {0,3}>/).replace(/heading/g, / {0,3}#{1,6}/).replace(/html/g, / {0,3}<[^\n>]+>\n/).replace(/\|table/g, "").getRegex(), MD = xD(AD).replace(/bull/g, kD).replace(/blockCode/g, /(?: {4}| {0,3}\t)/).replace(/fences/g, / {0,3}(?:`{3,}|~{3,})/).replace(/blockquote/g, / {0,3}>/).replace(/heading/g, / {0,3}#{1,6}/).replace(/html/g, / {0,3}<[^\n>]+>\n/).replace(/table/g, / {0,3}\|?(?:[:\- ]*\|)+[\:\- ]*\n/).getRegex(), ND = /^([^\n]+(?:\n(?!hr|heading|lheading|blockquote|fences|list|html|table| +\n)[^\n]+)*)/, PD = /^[^\n]+/, FD = /(?!\s*\])(?:\\[\s\S]|[^\[\]\\])+/, ID = xD(/^ {0,3}\[(label)\]: *(?:\n[ \t]*)?([^<\s][^\s]*|<.*?>)(?:(?: +(?:\n[ \t]*)?| *\n[ \t]*)(title))? *(?:\n+|$)/).replace("label", FD).replace("title", /(?:"(?:\\"?|[^"\\])*"|'[^'\n]*(?:\n[^'\n]+)*\n?'|\([^()]*\))/).getRegex(), LD = xD(/^(bull)([ \t][^\n]*?)?(?:\n|$)/).replace(/bull/g, kD).getRegex(), RD = "address|article|aside|base|basefont|blockquote|body|caption|center|col|colgroup|dd|details|dialog|dir|div|dl|dt|fieldset|figcaption|figure|footer|form|frame|frameset|h[1-6]|head|header|hr|html|iframe|legend|li|link|main|menu|menuitem|meta|nav|noframes|ol|optgroup|option|p|param|search|section|summary|table|tbody|td|tfoot|th|thead|title|tr|track|ul", zD = /<!--(?:-?>|[\s\S]*?(?:-->|$))/, BD = xD("^ {0,3}(?:<(script|pre|style|textarea)[\\s>][\\s\\S]*?(?:</\\1>[^\\n]*\\n+|$)|comment[^\\n]*(\\n+|$)|<\\?[\\s\\S]*?(?:\\?>[^\\n]*\\n+|$)|<![A-Z][\\s\\S]*?(?:>[^\\n]*\\n+|$)|<!\\[CDATA\\[[\\s\\S]*?(?:\\]\\]>[^\\n]*\\n+|$)|</?(tag)(?: +|\\n|/?>)[\\s\\S]*?(?:(?:\\n[ ]*)+\\n|$)|<(?!script|pre|style|textarea)([a-z][\\w-]*)(?:attribute)*? */?>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n[ ]*)+\\n|$)|</(?!script|pre|style|textarea)[a-z][\\w-]*\\s*>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n[ ]*)+\\n|$))", "i").replace("comment", zD).replace("tag", RD).replace("attribute", / +[a-zA-Z:_][\w.:-]*(?: *= *"[^"\n]*"| *= *'[^'\n]*'| *= *[^\s"'=<>`]+)?/).getRegex(), VD = (e) => xD(ND).replace("hr", DD).replace("heading", " {0,3}#{1,6}(?:\\s|$)").replace("|lheading", "").replace("|table", "").replace("blockquote", " {0,3}>").replace("fences", " {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list", e).replace("html", "</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag", RD).getRegex(), HD = VD(/ {0,3}(?:[*+-]|1[.)])[ \t]+[^ \t\n]/), UD = VD(/ {0,3}(?:[*+-]|\d{1,9}[.)])[ \t]+[^ \t\n]/), WD = {
|
|
19898
|
+
blockquote: xD(/^( {0,3}> ?(paragraph|[^\n]*)(?:\n|$))+/).replace("paragraph", UD).getRegex(),
|
|
19899
|
+
code: TD,
|
|
19900
|
+
def: ID,
|
|
19901
|
+
fences: ED,
|
|
19902
|
+
heading: OD,
|
|
19903
|
+
hr: DD,
|
|
19904
|
+
html: BD,
|
|
19910
19905
|
lheading: jD,
|
|
19911
|
-
|
|
19912
|
-
|
|
19913
|
-
|
|
19914
|
-
|
|
19915
|
-
|
|
19906
|
+
list: LD,
|
|
19907
|
+
newline: wD,
|
|
19908
|
+
paragraph: HD,
|
|
19909
|
+
table: yD,
|
|
19910
|
+
text: PD
|
|
19911
|
+
}, GD = xD("^ *([^\\n ].*)\\n {0,3}((?:\\| *)?:?-+:? *(?:\\| *:?-+:? *)*(?:\\| *)?)(?:\\n((?:(?! *\\n|hr|heading|blockquote|code|fences|list|html).*(?:\\n|$))*)\\n*|$)").replace("hr", DD).replace("heading", " {0,3}#{1,6}(?:\\s|$)").replace("blockquote", " {0,3}>").replace("code", "(?: {4}| {0,3} )[^\\n]").replace("fences", " {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list", " {0,3}(?:[*+-]|1[.)])[ \\t]").replace("html", "</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag", RD).getRegex(), KD = {
|
|
19912
|
+
...WD,
|
|
19913
|
+
lheading: MD,
|
|
19914
|
+
table: GD,
|
|
19915
|
+
paragraph: xD(ND).replace("hr", DD).replace("heading", " {0,3}#{1,6}(?:\\s|$)").replace("|lheading", "").replace("table", GD).replace("blockquote", " {0,3}>").replace("fences", " {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list", " {0,3}(?:[*+-]|1[.)])[ \\t]+[^ \\t\\n]").replace("html", "</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag", RD).getRegex()
|
|
19916
|
+
}, qD = {
|
|
19917
|
+
...WD,
|
|
19918
|
+
html: xD("^ *(?:comment *(?:\\n|\\s*$)|<(tag)[\\s\\S]+?</\\1> *(?:\\n{2,}|\\s*$)|<tag(?:\"[^\"]*\"|'[^']*'|\\s[^'\"/>\\s]*)*?/?> *(?:\\n{2,}|\\s*$))").replace("comment", zD).replace(/tag/g, "(?!(?:a|em|strong|small|s|cite|q|dfn|abbr|data|time|code|var|samp|kbd|sub|sup|i|b|u|mark|ruby|rt|rp|bdi|bdo|span|br|wbr|ins|del|img)\\b)\\w+(?!:|[^\\w\\s@]*@)\\b").getRegex(),
|
|
19916
19919
|
def: /^ *\[([^\]]+)\]: *<?([^\s>]+)>?(?: +(["(][^\n]+[")]))? *(?:\n+|$)/,
|
|
19917
19920
|
heading: /^(#{1,6})(.*)(?:\n+|$)/,
|
|
19918
|
-
fences:
|
|
19921
|
+
fences: yD,
|
|
19919
19922
|
lheading: /^(.+?)\n {0,3}(=+|-+) *(?:\n+|$)/,
|
|
19920
|
-
paragraph:
|
|
19921
|
-
},
|
|
19922
|
-
_backpedal:
|
|
19923
|
-
anyPunctuation:
|
|
19924
|
-
autolink:
|
|
19925
|
-
blockSkip:
|
|
19926
|
-
br:
|
|
19927
|
-
code:
|
|
19928
|
-
del:
|
|
19929
|
-
delLDelim:
|
|
19930
|
-
delRDelim:
|
|
19931
|
-
emStrongLDelim: oO,
|
|
19932
|
-
emStrongRDelimAst: lO,
|
|
19933
|
-
emStrongRDelimUnd: dO,
|
|
19934
|
-
escape: qD,
|
|
19935
|
-
link: yO,
|
|
19936
|
-
nolink: xO,
|
|
19937
|
-
punctuation: eO,
|
|
19938
|
-
reflink: bO,
|
|
19939
|
-
reflinkSearch: SO,
|
|
19940
|
-
tag: _O,
|
|
19941
|
-
text: XD,
|
|
19942
|
-
url: vD
|
|
19943
|
-
}, TO = {
|
|
19944
|
-
...wO,
|
|
19945
|
-
link: bD(/^!?\[(label)\]\((.*?)\)/).replace("label", vO).getRegex(),
|
|
19946
|
-
reflink: bD(/^!?\[(label)\]\s*\[([^\]]*)\]/).replace("label", vO).getRegex()
|
|
19947
|
-
}, EO = {
|
|
19948
|
-
...wO,
|
|
19949
|
-
emStrongRDelimAst: uO,
|
|
19923
|
+
paragraph: xD(ND).replace("hr", DD).replace("heading", " *#{1,6} *[^\n]").replace("lheading", jD).replace("|table", "").replace("blockquote", " {0,3}>").replace("|fences", "").replace("|list", "").replace("|html", "").replace("|tag", "").getRegex()
|
|
19924
|
+
}, JD = /^\\([!"#$%&'()*+,\-./:;<=>?@\[\]\\^_`{|}~])/, YD = /^(`+)([^`]|[^`][\s\S]*?[^`])\1(?!`)/, XD = /^( {2,}|\\)\n(?!\s*$)/, ZD = /^(`+|[^`])(?:(?= {2,}\n)|[\s\S]*?(?:(?=[\\<!\[`*_]|\b_|$)|[^ ](?= {2,}\n)))/, QD = /[\p{P}\p{S}]/u, $D = /[\s\p{P}\p{S}]/u, eO = /[^\s\p{P}\p{S}]/u, tO = xD(/^((?![*_])punctSpace)/, "u").replace(/punctSpace/g, $D).getRegex(), nO = /(?!~)[\p{P}\p{S}]/u, rO = /(?!~)[\s\p{P}\p{S}]/u, iO = /(?:[^\s\p{P}\p{S}]|~)/u, aO = xD(/link|precode-code|html/, "g").replace("link", /\[(?:[^\[\]`]|(?<a>`+)[^`]+\k<a>(?!`))*?\]\((?:\\[\s\S]|[^\\\(\)]|\((?:\\[\s\S]|[^\\\(\)])*\))*\)/).replace("precode-", SD ? "(?<!`)()" : "(^^|[^`])").replace("code", /(?<b>`+)[^`]+\k<b>(?!`)/).replace("html", /<(?! )[^<>]*?>/).getRegex(), oO = /^(?:\*+(?:((?!\*)punct)|([^\s*]))?)|^_+(?:((?!_)punct)|([^\s_]))?/, sO = xD(oO, "u").replace(/punct/g, QD).getRegex(), cO = xD(oO, "u").replace(/punct/g, nO).getRegex(), lO = "^[^_*]*?__[^_*]*?\\*[^_*]*?(?=__)|[^*]+(?=[^*])|(?!\\*)punct(\\*+)(?=[\\s]|$)|notPunctSpace(\\*+)(?!\\*)(?=punctSpace|$)|(?!\\*)punctSpace(\\*+)(?=notPunctSpace)|[\\s](\\*+)(?!\\*)(?=punct)|(?!\\*)punct(\\*+)(?!\\*)(?=punct)|notPunctSpace(\\*+)(?=notPunctSpace)", uO = xD(lO, "gu").replace(/notPunctSpace/g, eO).replace(/punctSpace/g, $D).replace(/punct/g, QD).getRegex(), dO = xD(lO, "gu").replace(/notPunctSpace/g, iO).replace(/punctSpace/g, rO).replace(/punct/g, nO).getRegex(), fO = xD("^[^_*]*?\\*\\*[^_*]*?_[^_*]*?(?=\\*\\*)|[^_]+(?=[^_])|(?!_)punct(_+)(?=[\\s]|$)|notPunctSpace(_+)(?!_)(?=punctSpace|$)|(?!_)punctSpace(_+)(?=notPunctSpace)|[\\s](_+)(?!_)(?=punct)|(?!_)punct(_+)(?!_)(?=punct)", "gu").replace(/notPunctSpace/g, eO).replace(/punctSpace/g, $D).replace(/punct/g, QD).getRegex(), pO = xD(/^~~?(?:((?!~)punct)|[^\s~])/, "u").replace(/punct/g, QD).getRegex(), mO = xD("^[^~]+(?=[^~])|(?!~)punct(~~?)(?=[\\s]|$)|notPunctSpace(~~?)(?!~)(?=punctSpace|$)|(?!~)punctSpace(~~?)(?=notPunctSpace)|[\\s](~~?)(?!~)(?=punct)|(?!~)punct(~~?)(?!~)(?=punct)|notPunctSpace(~~?)(?=notPunctSpace)", "gu").replace(/notPunctSpace/g, eO).replace(/punctSpace/g, $D).replace(/punct/g, QD).getRegex(), hO = xD(/\\(punct)/, "gu").replace(/punct/g, QD).getRegex(), gO = xD(/^<(scheme:[^\s\x00-\x1f<>]*|email)>/).replace("scheme", /[a-zA-Z][a-zA-Z0-9+.-]{1,31}/).replace("email", /[a-zA-Z0-9.!#$%&'*+/=?^_`{|}~-]+(@)[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)+(?![-_])/).getRegex(), _O = xD(zD).replace("(?:-->|$)", "-->").getRegex(), vO = xD("^comment|^</[a-zA-Z][\\w:-]*\\s*>|^<[a-zA-Z][\\w-]*(?:attribute)*?\\s*/?>|^<\\?[\\s\\S]*?\\?>|^<![a-zA-Z]+\\s[\\s\\S]*?>|^<!\\[CDATA\\[[\\s\\S]*?\\]\\]>").replace("comment", _O).replace("attribute", /\s+[a-zA-Z:_][\w.:-]*(?:\s*=\s*"[^"]*"|\s*=\s*'[^']*'|\s*=\s*[^\s"'=<>`]+)?/).getRegex(), yO = /(?:\[(?:\\[\s\S]|[^\[\]\\])*\]|\\[\s\S]|`+(?!`)[^`]*?`+(?!`)|``+(?=\])|[^\[\]\\`])*?/, bO = xD(/^!?\[(label)\]\(\s*(href)(?:(?:[ \t]+(?:\n[ \t]*)?|\n[ \t]*)(title))?\s*\)/).replace("label", yO).replace("href", /<(?:\\.|[^\n<>\\])+>|[^ \t\n\x00-\x1f]+|(?=\))/).replace("title", /"(?:\\"?|[^"\\])*"|'(?:\\'?|[^'\\])*'|\((?:\\\)?|[^)\\])*\)/).getRegex(), xO = xD(/^!?\[(label)\]\[(ref)\]/).replace("label", yO).replace("ref", FD).getRegex(), SO = xD(/^!?\[(ref)\](?:\[\])?/).replace("ref", FD).getRegex(), CO = xD("reflink|nolink(?!\\()", "g").replace("reflink", xO).replace("nolink", SO).getRegex(), wO = /[hH][tT][tT][pP][sS]?|[fF][tT][pP]/, TO = {
|
|
19925
|
+
_backpedal: yD,
|
|
19926
|
+
anyPunctuation: hO,
|
|
19927
|
+
autolink: gO,
|
|
19928
|
+
blockSkip: aO,
|
|
19929
|
+
br: XD,
|
|
19930
|
+
code: YD,
|
|
19931
|
+
del: yD,
|
|
19932
|
+
delLDelim: yD,
|
|
19933
|
+
delRDelim: yD,
|
|
19950
19934
|
emStrongLDelim: sO,
|
|
19951
|
-
|
|
19952
|
-
|
|
19953
|
-
|
|
19935
|
+
emStrongRDelimAst: uO,
|
|
19936
|
+
emStrongRDelimUnd: fO,
|
|
19937
|
+
escape: JD,
|
|
19938
|
+
link: bO,
|
|
19939
|
+
nolink: SO,
|
|
19940
|
+
punctuation: tO,
|
|
19941
|
+
reflink: xO,
|
|
19942
|
+
reflinkSearch: CO,
|
|
19943
|
+
tag: vO,
|
|
19944
|
+
text: ZD,
|
|
19945
|
+
url: yD
|
|
19946
|
+
}, EO = {
|
|
19947
|
+
...TO,
|
|
19948
|
+
link: xD(/^!?\[(label)\]\((.*?)\)/).replace("label", yO).getRegex(),
|
|
19949
|
+
reflink: xD(/^!?\[(label)\]\s*\[([^\]]*)\]/).replace("label", yO).getRegex()
|
|
19950
|
+
}, DO = {
|
|
19951
|
+
...TO,
|
|
19952
|
+
emStrongRDelimAst: dO,
|
|
19953
|
+
emStrongLDelim: cO,
|
|
19954
|
+
delLDelim: pO,
|
|
19955
|
+
delRDelim: mO,
|
|
19956
|
+
url: xD(/^((?:protocol):\/\/|www\.)(?:[a-zA-Z0-9\-]+\.?)+[^\s<]*|^email/).replace("protocol", wO).replace("email", /[A-Za-z0-9._+-]+(@)[a-zA-Z0-9-_]+(?:\.[a-zA-Z0-9-_]*[a-zA-Z0-9])+(?![-_])/).getRegex(),
|
|
19954
19957
|
_backpedal: /(?:[^?!.,:;*_'"~()&]+|\([^)]*\)|&(?![a-zA-Z0-9]+;$)|[?!.,:;*_'"~)]+(?!$))+/,
|
|
19955
19958
|
del: /^(~~?)(?=[^\s~])((?:\\[\s\S]|[^\\])*?(?:\\[\s\S]|[^\s~\\]))\1(?=[^~]|$)/,
|
|
19956
|
-
text:
|
|
19957
|
-
}, DO = {
|
|
19958
|
-
...EO,
|
|
19959
|
-
br: bD(YD).replace("{2,}", "*").getRegex(),
|
|
19960
|
-
text: bD(EO.text).replace("\\b_", "\\b_| {2,}\\n").replace(/\{2,\}/g, "*").getRegex()
|
|
19959
|
+
text: xD(/^([`~]+|[^`~])(?:(?= {2,}\n)|(?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@)|[\s\S]*?(?:(?=[\\<!\[`*~_]|\b_|protocol:\/\/|www\.|$)|[^ ](?= {2,}\n)|[^a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-](?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@)))/).replace("protocol", wO).getRegex()
|
|
19961
19960
|
}, OO = {
|
|
19962
|
-
|
|
19963
|
-
|
|
19964
|
-
|
|
19961
|
+
...DO,
|
|
19962
|
+
br: xD(XD).replace("{2,}", "*").getRegex(),
|
|
19963
|
+
text: xD(DO.text).replace("\\b_", "\\b_| {2,}\\n").replace(/\{2,\}/g, "*").getRegex()
|
|
19965
19964
|
}, kO = {
|
|
19966
|
-
normal:
|
|
19967
|
-
gfm:
|
|
19968
|
-
|
|
19969
|
-
pedantic: TO
|
|
19965
|
+
normal: WD,
|
|
19966
|
+
gfm: KD,
|
|
19967
|
+
pedantic: qD
|
|
19970
19968
|
}, AO = {
|
|
19969
|
+
normal: TO,
|
|
19970
|
+
gfm: DO,
|
|
19971
|
+
breaks: OO,
|
|
19972
|
+
pedantic: EO
|
|
19973
|
+
}, jO = {
|
|
19971
19974
|
"&": "&",
|
|
19972
19975
|
"<": "<",
|
|
19973
19976
|
">": ">",
|
|
19974
19977
|
"\"": """,
|
|
19975
19978
|
"'": "'"
|
|
19976
|
-
},
|
|
19977
|
-
function
|
|
19979
|
+
}, MO = (e) => jO[e];
|
|
19980
|
+
function NO(e, t) {
|
|
19978
19981
|
if (t) {
|
|
19979
|
-
if (
|
|
19980
|
-
} else if (
|
|
19982
|
+
if (CD.escapeTest.test(e)) return e.replace(CD.escapeReplace, MO);
|
|
19983
|
+
} else if (CD.escapeTestNoEncode.test(e)) return e.replace(CD.escapeReplaceNoEncode, MO);
|
|
19981
19984
|
return e;
|
|
19982
19985
|
}
|
|
19983
|
-
function
|
|
19986
|
+
function PO(e) {
|
|
19984
19987
|
try {
|
|
19985
|
-
e = encodeURI(e).replace(
|
|
19988
|
+
e = encodeURI(e).replace(CD.percentDecode, "%");
|
|
19986
19989
|
} catch {
|
|
19987
19990
|
return null;
|
|
19988
19991
|
}
|
|
19989
19992
|
return e;
|
|
19990
19993
|
}
|
|
19991
|
-
function
|
|
19992
|
-
let n = e.replace(
|
|
19994
|
+
function FO(e, t) {
|
|
19995
|
+
let n = e.replace(CD.findPipe, (e, t, n) => {
|
|
19993
19996
|
let r = !1, i = t;
|
|
19994
19997
|
for (; --i >= 0 && n[i] === "\\";) r = !r;
|
|
19995
19998
|
return r ? "|" : " |";
|
|
19996
|
-
}).split(
|
|
19999
|
+
}).split(CD.splitPipe), r = 0;
|
|
19997
20000
|
if (n[0].trim() || n.shift(), n.length > 0 && !n.at(-1)?.trim() && n.pop(), t) if (n.length > t) n.splice(t);
|
|
19998
20001
|
else for (; n.length < t;) n.push("");
|
|
19999
|
-
for (; r < n.length; r++) n[r] = n[r].trim().replace(
|
|
20002
|
+
for (; r < n.length; r++) n[r] = n[r].trim().replace(CD.slashPipe, "|");
|
|
20000
20003
|
return n;
|
|
20001
20004
|
}
|
|
20002
|
-
function
|
|
20005
|
+
function IO(e, t, n) {
|
|
20003
20006
|
let r = e.length;
|
|
20004
20007
|
if (r === 0) return "";
|
|
20005
20008
|
let i = 0;
|
|
@@ -20011,12 +20014,12 @@ function FO(e, t, n) {
|
|
|
20011
20014
|
}
|
|
20012
20015
|
return e.slice(0, r - i);
|
|
20013
20016
|
}
|
|
20014
|
-
function
|
|
20017
|
+
function LO(e) {
|
|
20015
20018
|
let t = e.split("\n"), n = t.length - 1;
|
|
20016
|
-
for (; n >= 0 &&
|
|
20019
|
+
for (; n >= 0 && CD.blankLine.test(t[n]);) n--;
|
|
20017
20020
|
return t.length - n <= 2 ? e : t.slice(0, n + 1).join("\n");
|
|
20018
20021
|
}
|
|
20019
|
-
function
|
|
20022
|
+
function RO(e, t) {
|
|
20020
20023
|
if (e.indexOf(t[1]) === -1) return -1;
|
|
20021
20024
|
let n = 0;
|
|
20022
20025
|
for (let r = 0; r < e.length; r++) if (e[r] === "\\") r++;
|
|
@@ -20024,7 +20027,7 @@ function LO(e, t) {
|
|
|
20024
20027
|
else if (e[r] === t[1] && (n--, n < 0)) return r;
|
|
20025
20028
|
return n > 0 ? -2 : -1;
|
|
20026
20029
|
}
|
|
20027
|
-
function
|
|
20030
|
+
function zO(e, t = 0) {
|
|
20028
20031
|
let n = t, r = "";
|
|
20029
20032
|
for (let t of e) if (t === " ") {
|
|
20030
20033
|
let e = 4 - n % 4;
|
|
@@ -20032,7 +20035,7 @@ function RO(e, t = 0) {
|
|
|
20032
20035
|
} else r += t, n++;
|
|
20033
20036
|
return r;
|
|
20034
20037
|
}
|
|
20035
|
-
function
|
|
20038
|
+
function BO(e, t, n, r, i) {
|
|
20036
20039
|
let a = t.href, o = t.title || null, s = e[1].replace(i.other.outputLinkReplace, "$1");
|
|
20037
20040
|
r.state.inLink = !0;
|
|
20038
20041
|
let c = {
|
|
@@ -20045,7 +20048,7 @@ function zO(e, t, n, r, i) {
|
|
|
20045
20048
|
};
|
|
20046
20049
|
return r.state.inLink = !1, c;
|
|
20047
20050
|
}
|
|
20048
|
-
function
|
|
20051
|
+
function VO(e, t, n) {
|
|
20049
20052
|
let r = e.match(n.other.indentCodeCompensation);
|
|
20050
20053
|
if (r === null) return t;
|
|
20051
20054
|
let i = r[1];
|
|
@@ -20056,12 +20059,12 @@ function BO(e, t, n) {
|
|
|
20056
20059
|
return r.length >= i.length ? e.slice(i.length) : e;
|
|
20057
20060
|
}).join("\n");
|
|
20058
20061
|
}
|
|
20059
|
-
var
|
|
20062
|
+
var HO = class {
|
|
20060
20063
|
options;
|
|
20061
20064
|
rules;
|
|
20062
20065
|
lexer;
|
|
20063
20066
|
constructor(e) {
|
|
20064
|
-
this.options = e ||
|
|
20067
|
+
this.options = e || _D;
|
|
20065
20068
|
}
|
|
20066
20069
|
space(e) {
|
|
20067
20070
|
let t = this.rules.block.newline.exec(e);
|
|
@@ -20073,7 +20076,7 @@ var VO = class {
|
|
|
20073
20076
|
code(e) {
|
|
20074
20077
|
let t = this.rules.block.code.exec(e);
|
|
20075
20078
|
if (t) {
|
|
20076
|
-
let e = this.options.pedantic ? t[0] :
|
|
20079
|
+
let e = this.options.pedantic ? t[0] : LO(t[0]);
|
|
20077
20080
|
return {
|
|
20078
20081
|
type: "code",
|
|
20079
20082
|
raw: e,
|
|
@@ -20085,7 +20088,7 @@ var VO = class {
|
|
|
20085
20088
|
fences(e) {
|
|
20086
20089
|
let t = this.rules.block.fences.exec(e);
|
|
20087
20090
|
if (t) {
|
|
20088
|
-
let e = t[0], n =
|
|
20091
|
+
let e = t[0], n = VO(e, t[3] || "", this.rules);
|
|
20089
20092
|
return {
|
|
20090
20093
|
type: "code",
|
|
20091
20094
|
raw: e,
|
|
@@ -20099,12 +20102,12 @@ var VO = class {
|
|
|
20099
20102
|
if (t) {
|
|
20100
20103
|
let e = t[2].trim();
|
|
20101
20104
|
if (this.rules.other.endingHash.test(e)) {
|
|
20102
|
-
let t =
|
|
20105
|
+
let t = IO(e, "#");
|
|
20103
20106
|
(this.options.pedantic || !t || this.rules.other.endingSpaceChar.test(t)) && (e = t.trim());
|
|
20104
20107
|
}
|
|
20105
20108
|
return {
|
|
20106
20109
|
type: "heading",
|
|
20107
|
-
raw:
|
|
20110
|
+
raw: IO(t[0], "\n"),
|
|
20108
20111
|
depth: t[1].length,
|
|
20109
20112
|
text: e,
|
|
20110
20113
|
tokens: this.lexer.inline(e)
|
|
@@ -20115,13 +20118,13 @@ var VO = class {
|
|
|
20115
20118
|
let t = this.rules.block.hr.exec(e);
|
|
20116
20119
|
if (t) return {
|
|
20117
20120
|
type: "hr",
|
|
20118
|
-
raw:
|
|
20121
|
+
raw: IO(t[0], "\n")
|
|
20119
20122
|
};
|
|
20120
20123
|
}
|
|
20121
20124
|
blockquote(e) {
|
|
20122
20125
|
let t = this.rules.block.blockquote.exec(e);
|
|
20123
20126
|
if (t) {
|
|
20124
|
-
let e =
|
|
20127
|
+
let e = IO(t[0], "\n").split("\n"), n = "", r = "", i = [];
|
|
20125
20128
|
for (; e.length > 0;) {
|
|
20126
20129
|
let t = !1, a = [], o;
|
|
20127
20130
|
for (o = 0; o < e.length; o++) if (this.rules.other.blockquoteStart.test(e[o])) a.push(e[o]), t = !0;
|
|
@@ -20171,7 +20174,7 @@ ${c}` : c;
|
|
|
20171
20174
|
let n = !1, r = "", s = "";
|
|
20172
20175
|
if (!(t = a.exec(e)) || this.rules.block.hr.test(e)) break;
|
|
20173
20176
|
r = t[0], e = e.substring(r.length);
|
|
20174
|
-
let c =
|
|
20177
|
+
let c = zO(t[2].split("\n", 1)[0], t[1].length), l = e.split("\n", 1)[0], u = !c.trim(), d = 0;
|
|
20175
20178
|
if (this.options.pedantic ? (d = 2, s = c.trimStart()) : u ? d = t[1].length + 1 : (d = c.search(this.rules.other.nonSpaceChar), d = d > 4 ? 1 : d, s = c.slice(d), d += t[1].length), u && this.rules.other.blankLine.test(l) && (r += l + "\n", e = e.substring(l.length + 1), n = !0), !n) {
|
|
20176
20179
|
let t = this.rules.other.nextBulletRegex(d), n = this.rules.other.hrRegex(d), i = this.rules.other.fencesBeginRegex(d), a = this.rules.other.headingBeginRegex(d), o = this.rules.other.htmlBeginRegex(d), f = this.rules.other.blockquoteBeginRegex(d);
|
|
20177
20180
|
for (; e;) {
|
|
@@ -20237,7 +20240,7 @@ ${c}` : c;
|
|
|
20237
20240
|
html(e) {
|
|
20238
20241
|
let t = this.rules.block.html.exec(e);
|
|
20239
20242
|
if (t) {
|
|
20240
|
-
let e =
|
|
20243
|
+
let e = LO(t[0]);
|
|
20241
20244
|
return {
|
|
20242
20245
|
type: "html",
|
|
20243
20246
|
block: !0,
|
|
@@ -20254,7 +20257,7 @@ ${c}` : c;
|
|
|
20254
20257
|
return {
|
|
20255
20258
|
type: "def",
|
|
20256
20259
|
tag: e,
|
|
20257
|
-
raw:
|
|
20260
|
+
raw: IO(t[0], "\n"),
|
|
20258
20261
|
href: n,
|
|
20259
20262
|
title: r
|
|
20260
20263
|
};
|
|
@@ -20263,9 +20266,9 @@ ${c}` : c;
|
|
|
20263
20266
|
table(e) {
|
|
20264
20267
|
let t = this.rules.block.table.exec(e);
|
|
20265
20268
|
if (!t || !this.rules.other.tableDelimiter.test(t[2])) return;
|
|
20266
|
-
let n =
|
|
20269
|
+
let n = FO(t[1]), r = t[2].replace(this.rules.other.tableAlignChars, "").split("|"), i = t[3]?.trim() ? t[3].replace(this.rules.other.tableRowBlankLine, "").split("\n") : [], a = {
|
|
20267
20270
|
type: "table",
|
|
20268
|
-
raw:
|
|
20271
|
+
raw: IO(t[0], "\n"),
|
|
20269
20272
|
header: [],
|
|
20270
20273
|
align: [],
|
|
20271
20274
|
rows: []
|
|
@@ -20278,7 +20281,7 @@ ${c}` : c;
|
|
|
20278
20281
|
header: !0,
|
|
20279
20282
|
align: a.align[e]
|
|
20280
20283
|
});
|
|
20281
|
-
for (let e of i) a.rows.push(
|
|
20284
|
+
for (let e of i) a.rows.push(FO(e, a.header.length).map((e, t) => ({
|
|
20282
20285
|
text: e,
|
|
20283
20286
|
tokens: this.lexer.inline(e),
|
|
20284
20287
|
header: !1,
|
|
@@ -20293,7 +20296,7 @@ ${c}` : c;
|
|
|
20293
20296
|
let e = t[1].trim();
|
|
20294
20297
|
return {
|
|
20295
20298
|
type: "heading",
|
|
20296
|
-
raw:
|
|
20299
|
+
raw: IO(t[0], "\n"),
|
|
20297
20300
|
depth: t[2].charAt(0) === "=" ? 1 : 2,
|
|
20298
20301
|
text: e,
|
|
20299
20302
|
tokens: this.lexer.inline(e)
|
|
@@ -20346,10 +20349,10 @@ ${c}` : c;
|
|
|
20346
20349
|
let e = t[2].trim();
|
|
20347
20350
|
if (!this.options.pedantic && this.rules.other.startAngleBracket.test(e)) {
|
|
20348
20351
|
if (!this.rules.other.endAngleBracket.test(e)) return;
|
|
20349
|
-
let t =
|
|
20352
|
+
let t = IO(e.slice(0, -1), "\\");
|
|
20350
20353
|
if ((e.length - t.length) % 2 == 0) return;
|
|
20351
20354
|
} else {
|
|
20352
|
-
let e =
|
|
20355
|
+
let e = RO(t[2], "()");
|
|
20353
20356
|
if (e === -2) return;
|
|
20354
20357
|
if (e > -1) {
|
|
20355
20358
|
let n = (t[0].indexOf("!") === 0 ? 5 : 4) + t[1].length + e;
|
|
@@ -20361,7 +20364,7 @@ ${c}` : c;
|
|
|
20361
20364
|
let e = this.rules.other.pedanticHrefTitle.exec(n);
|
|
20362
20365
|
e && (n = e[1], r = e[3]);
|
|
20363
20366
|
} else r = t[3] ? t[3].slice(1, -1) : "";
|
|
20364
|
-
return n = n.trim(), this.rules.other.startAngleBracket.test(n) && (n = this.options.pedantic && !this.rules.other.endAngleBracket.test(e) ? n.slice(1) : n.slice(1, -1)),
|
|
20367
|
+
return n = n.trim(), this.rules.other.startAngleBracket.test(n) && (n = this.options.pedantic && !this.rules.other.endAngleBracket.test(e) ? n.slice(1) : n.slice(1, -1)), BO(t, {
|
|
20365
20368
|
href: n && n.replace(this.rules.inline.anyPunctuation, "$1"),
|
|
20366
20369
|
title: r && r.replace(this.rules.inline.anyPunctuation, "$1")
|
|
20367
20370
|
}, t[0], this.lexer, this.rules);
|
|
@@ -20379,7 +20382,7 @@ ${c}` : c;
|
|
|
20379
20382
|
text: e
|
|
20380
20383
|
};
|
|
20381
20384
|
}
|
|
20382
|
-
return
|
|
20385
|
+
return BO(n, e, n[0], this.lexer, this.rules);
|
|
20383
20386
|
}
|
|
20384
20387
|
}
|
|
20385
20388
|
emStrong(e, t, n = "") {
|
|
@@ -20511,29 +20514,29 @@ ${c}` : c;
|
|
|
20511
20514
|
};
|
|
20512
20515
|
}
|
|
20513
20516
|
}
|
|
20514
|
-
},
|
|
20517
|
+
}, UO = class e {
|
|
20515
20518
|
tokens;
|
|
20516
20519
|
options;
|
|
20517
20520
|
state;
|
|
20518
20521
|
inlineQueue;
|
|
20519
20522
|
tokenizer;
|
|
20520
20523
|
constructor(e) {
|
|
20521
|
-
this.tokens = [], this.tokens.links = Object.create(null), this.options = e ||
|
|
20524
|
+
this.tokens = [], this.tokens.links = Object.create(null), this.options = e || _D, this.options.tokenizer = this.options.tokenizer || new HO(), this.tokenizer = this.options.tokenizer, this.tokenizer.options = this.options, this.tokenizer.lexer = this, this.inlineQueue = [], this.state = {
|
|
20522
20525
|
inLink: !1,
|
|
20523
20526
|
inRawBlock: !1,
|
|
20524
20527
|
top: !0
|
|
20525
20528
|
};
|
|
20526
20529
|
let t = {
|
|
20527
|
-
other:
|
|
20528
|
-
block:
|
|
20529
|
-
inline:
|
|
20530
|
+
other: CD,
|
|
20531
|
+
block: kO.normal,
|
|
20532
|
+
inline: AO.normal
|
|
20530
20533
|
};
|
|
20531
|
-
this.options.pedantic ? (t.block =
|
|
20534
|
+
this.options.pedantic ? (t.block = kO.pedantic, t.inline = AO.pedantic) : this.options.gfm && (t.block = kO.gfm, this.options.breaks ? t.inline = AO.breaks : t.inline = AO.gfm), this.tokenizer.rules = t;
|
|
20532
20535
|
}
|
|
20533
20536
|
static get rules() {
|
|
20534
20537
|
return {
|
|
20535
|
-
block:
|
|
20536
|
-
inline:
|
|
20538
|
+
block: kO,
|
|
20539
|
+
inline: AO
|
|
20537
20540
|
};
|
|
20538
20541
|
}
|
|
20539
20542
|
static lex(t, n) {
|
|
@@ -20543,7 +20546,7 @@ ${c}` : c;
|
|
|
20543
20546
|
return new e(n).inlineTokens(t);
|
|
20544
20547
|
}
|
|
20545
20548
|
lex(e) {
|
|
20546
|
-
e = e.replace(
|
|
20549
|
+
e = e.replace(CD.carriageReturn, "\n"), this.blockTokens(e, this.tokens);
|
|
20547
20550
|
for (let e = 0; e < this.inlineQueue.length; e++) {
|
|
20548
20551
|
let t = this.inlineQueue[e];
|
|
20549
20552
|
this.inlineTokens(t.src, t.tokens);
|
|
@@ -20551,7 +20554,7 @@ ${c}` : c;
|
|
|
20551
20554
|
return this.inlineQueue = [], this.tokens;
|
|
20552
20555
|
}
|
|
20553
20556
|
blockTokens(e, t = [], n = !1) {
|
|
20554
|
-
this.tokenizer.lexer = this, this.options.pedantic && (e = e.replace(
|
|
20557
|
+
this.tokenizer.lexer = this, this.options.pedantic && (e = e.replace(CD.tabCharGlobal, " ").replace(CD.spaceLine, ""));
|
|
20555
20558
|
let r = Infinity;
|
|
20556
20559
|
for (; e;) {
|
|
20557
20560
|
if (e.length < r) r = e.length;
|
|
@@ -20733,18 +20736,18 @@ ${c}` : c;
|
|
|
20733
20736
|
if (this.options.silent) console.error(t);
|
|
20734
20737
|
else throw Error(t);
|
|
20735
20738
|
}
|
|
20736
|
-
},
|
|
20739
|
+
}, WO = class {
|
|
20737
20740
|
options;
|
|
20738
20741
|
parser;
|
|
20739
20742
|
constructor(e) {
|
|
20740
|
-
this.options = e ||
|
|
20743
|
+
this.options = e || _D;
|
|
20741
20744
|
}
|
|
20742
20745
|
space(e) {
|
|
20743
20746
|
return "";
|
|
20744
20747
|
}
|
|
20745
20748
|
code({ text: e, lang: t, escaped: n }) {
|
|
20746
|
-
let r = (t || "").match(
|
|
20747
|
-
return r ? "<pre><code class=\"language-" +
|
|
20749
|
+
let r = (t || "").match(CD.notSpaceStart)?.[0], i = e.replace(CD.endingNewline, "") + "\n";
|
|
20750
|
+
return r ? "<pre><code class=\"language-" + NO(r) + "\">" + (n ? i : NO(i, !0)) + "</code></pre>\n" : "<pre><code>" + (n ? i : NO(i, !0)) + "</code></pre>\n";
|
|
20748
20751
|
}
|
|
20749
20752
|
blockquote({ tokens: e }) {
|
|
20750
20753
|
return `<blockquote>
|
|
@@ -20814,7 +20817,7 @@ ${e}</tr>
|
|
|
20814
20817
|
return `<em>${this.parser.parseInline(e)}</em>`;
|
|
20815
20818
|
}
|
|
20816
20819
|
codespan({ text: e }) {
|
|
20817
|
-
return `<code>${
|
|
20820
|
+
return `<code>${NO(e, !0)}</code>`;
|
|
20818
20821
|
}
|
|
20819
20822
|
br(e) {
|
|
20820
20823
|
return "<br>";
|
|
@@ -20823,24 +20826,24 @@ ${e}</tr>
|
|
|
20823
20826
|
return `<del>${this.parser.parseInline(e)}</del>`;
|
|
20824
20827
|
}
|
|
20825
20828
|
link({ href: e, title: t, tokens: n }) {
|
|
20826
|
-
let r = this.parser.parseInline(n), i =
|
|
20829
|
+
let r = this.parser.parseInline(n), i = PO(e);
|
|
20827
20830
|
if (i === null) return r;
|
|
20828
20831
|
e = i;
|
|
20829
20832
|
let a = "<a href=\"" + e + "\"";
|
|
20830
|
-
return t && (a += " title=\"" +
|
|
20833
|
+
return t && (a += " title=\"" + NO(t) + "\""), a += ">" + r + "</a>", a;
|
|
20831
20834
|
}
|
|
20832
20835
|
image({ href: e, title: t, text: n, tokens: r }) {
|
|
20833
20836
|
r && (n = this.parser.parseInline(r, this.parser.textRenderer));
|
|
20834
|
-
let i =
|
|
20835
|
-
if (i === null) return
|
|
20837
|
+
let i = PO(e);
|
|
20838
|
+
if (i === null) return NO(n);
|
|
20836
20839
|
e = i;
|
|
20837
|
-
let a = `<img src="${e}" alt="${
|
|
20838
|
-
return t && (a += ` title="${
|
|
20840
|
+
let a = `<img src="${e}" alt="${NO(n)}"`;
|
|
20841
|
+
return t && (a += ` title="${NO(t)}"`), a += ">", a;
|
|
20839
20842
|
}
|
|
20840
20843
|
text(e) {
|
|
20841
|
-
return "tokens" in e && e.tokens ? this.parser.parseInline(e.tokens) : "escaped" in e && e.escaped ? e.text :
|
|
20844
|
+
return "tokens" in e && e.tokens ? this.parser.parseInline(e.tokens) : "escaped" in e && e.escaped ? e.text : NO(e.text);
|
|
20842
20845
|
}
|
|
20843
|
-
},
|
|
20846
|
+
}, GO = class {
|
|
20844
20847
|
strong({ text: e }) {
|
|
20845
20848
|
return e;
|
|
20846
20849
|
}
|
|
@@ -20871,12 +20874,12 @@ ${e}</tr>
|
|
|
20871
20874
|
checkbox({ raw: e }) {
|
|
20872
20875
|
return e;
|
|
20873
20876
|
}
|
|
20874
|
-
},
|
|
20877
|
+
}, KO = class e {
|
|
20875
20878
|
options;
|
|
20876
20879
|
renderer;
|
|
20877
20880
|
textRenderer;
|
|
20878
20881
|
constructor(e) {
|
|
20879
|
-
this.options = e ||
|
|
20882
|
+
this.options = e || _D, this.options.renderer = this.options.renderer || new WO(), this.renderer = this.options.renderer, this.renderer.options = this.options, this.renderer.parser = this, this.textRenderer = new GO();
|
|
20880
20883
|
}
|
|
20881
20884
|
static parse(t, n) {
|
|
20882
20885
|
return new e(n).parse(t);
|
|
@@ -21022,11 +21025,11 @@ ${e}</tr>
|
|
|
21022
21025
|
}
|
|
21023
21026
|
return n;
|
|
21024
21027
|
}
|
|
21025
|
-
},
|
|
21028
|
+
}, qO = class {
|
|
21026
21029
|
options;
|
|
21027
21030
|
block;
|
|
21028
21031
|
constructor(e) {
|
|
21029
|
-
this.options = e ||
|
|
21032
|
+
this.options = e || _D;
|
|
21030
21033
|
}
|
|
21031
21034
|
static passThroughHooks = /* @__PURE__ */ new Set([
|
|
21032
21035
|
"preprocess",
|
|
@@ -21052,22 +21055,22 @@ ${e}</tr>
|
|
|
21052
21055
|
return e;
|
|
21053
21056
|
}
|
|
21054
21057
|
provideLexer(e = this.block) {
|
|
21055
|
-
return e ?
|
|
21058
|
+
return e ? UO.lex : UO.lexInline;
|
|
21056
21059
|
}
|
|
21057
21060
|
provideParser(e = this.block) {
|
|
21058
|
-
return e ?
|
|
21061
|
+
return e ? KO.parse : KO.parseInline;
|
|
21059
21062
|
}
|
|
21060
|
-
},
|
|
21061
|
-
defaults =
|
|
21063
|
+
}, JO = new class {
|
|
21064
|
+
defaults = gD();
|
|
21062
21065
|
options = this.setOptions;
|
|
21063
21066
|
parse = this.parseMarkdown(!0);
|
|
21064
21067
|
parseInline = this.parseMarkdown(!1);
|
|
21065
|
-
Parser =
|
|
21066
|
-
Renderer =
|
|
21067
|
-
TextRenderer =
|
|
21068
|
-
Lexer =
|
|
21069
|
-
Tokenizer =
|
|
21070
|
-
Hooks =
|
|
21068
|
+
Parser = KO;
|
|
21069
|
+
Renderer = WO;
|
|
21070
|
+
TextRenderer = GO;
|
|
21071
|
+
Lexer = UO;
|
|
21072
|
+
Tokenizer = HO;
|
|
21073
|
+
Hooks = qO;
|
|
21071
21074
|
constructor(...e) {
|
|
21072
21075
|
this.use(...e);
|
|
21073
21076
|
}
|
|
@@ -21118,7 +21121,7 @@ ${e}</tr>
|
|
|
21118
21121
|
}
|
|
21119
21122
|
"childTokens" in e && e.childTokens && (t.childTokens[e.name] = e.childTokens);
|
|
21120
21123
|
}), n.extensions = t), e.renderer) {
|
|
21121
|
-
let t = this.defaults.renderer || new
|
|
21124
|
+
let t = this.defaults.renderer || new WO(this.defaults);
|
|
21122
21125
|
for (let n in e.renderer) {
|
|
21123
21126
|
if (!(n in t)) throw Error(`renderer '${n}' does not exist`);
|
|
21124
21127
|
if (["options", "parser"].includes(n)) continue;
|
|
@@ -21131,7 +21134,7 @@ ${e}</tr>
|
|
|
21131
21134
|
n.renderer = t;
|
|
21132
21135
|
}
|
|
21133
21136
|
if (e.tokenizer) {
|
|
21134
|
-
let t = this.defaults.tokenizer || new
|
|
21137
|
+
let t = this.defaults.tokenizer || new HO(this.defaults);
|
|
21135
21138
|
for (let n in e.tokenizer) {
|
|
21136
21139
|
if (!(n in t)) throw Error(`tokenizer '${n}' does not exist`);
|
|
21137
21140
|
if ([
|
|
@@ -21148,13 +21151,13 @@ ${e}</tr>
|
|
|
21148
21151
|
n.tokenizer = t;
|
|
21149
21152
|
}
|
|
21150
21153
|
if (e.hooks) {
|
|
21151
|
-
let t = this.defaults.hooks || new
|
|
21154
|
+
let t = this.defaults.hooks || new qO();
|
|
21152
21155
|
for (let n in e.hooks) {
|
|
21153
21156
|
if (!(n in t)) throw Error(`hook '${n}' does not exist`);
|
|
21154
21157
|
if (["options", "block"].includes(n)) continue;
|
|
21155
21158
|
let r = n, i = e.hooks[r], a = t[r];
|
|
21156
|
-
|
|
21157
|
-
if (this.defaults.async &&
|
|
21159
|
+
qO.passThroughHooks.has(n) ? t[r] = (e) => {
|
|
21160
|
+
if (this.defaults.async && qO.passThroughHooksRespectAsync.has(n)) return (async () => {
|
|
21158
21161
|
let n = await i.call(t, e);
|
|
21159
21162
|
return a.call(t, n);
|
|
21160
21163
|
})();
|
|
@@ -21191,10 +21194,10 @@ ${e}</tr>
|
|
|
21191
21194
|
}, this;
|
|
21192
21195
|
}
|
|
21193
21196
|
lexer(e, t) {
|
|
21194
|
-
return
|
|
21197
|
+
return UO.lex(e, t ?? this.defaults);
|
|
21195
21198
|
}
|
|
21196
21199
|
parser(e, t) {
|
|
21197
|
-
return
|
|
21200
|
+
return KO.parse(e, t ?? this.defaults);
|
|
21198
21201
|
}
|
|
21199
21202
|
parseMarkdown(e) {
|
|
21200
21203
|
return (t, n) => {
|
|
@@ -21206,16 +21209,16 @@ ${e}</tr>
|
|
|
21206
21209
|
if (typeof t > "u" || t === null) return a(/* @__PURE__ */ Error("marked(): input parameter is undefined or null"));
|
|
21207
21210
|
if (typeof t != "string") return a(/* @__PURE__ */ Error("marked(): input parameter is of type " + Object.prototype.toString.call(t) + ", string expected"));
|
|
21208
21211
|
if (i.hooks && (i.hooks.options = i, i.hooks.block = e), i.async) return (async () => {
|
|
21209
|
-
let n = i.hooks ? await i.hooks.preprocess(t) : t, r = await (i.hooks ? await i.hooks.provideLexer(e) : e ?
|
|
21212
|
+
let n = i.hooks ? await i.hooks.preprocess(t) : t, r = await (i.hooks ? await i.hooks.provideLexer(e) : e ? UO.lex : UO.lexInline)(n, i), a = i.hooks ? await i.hooks.processAllTokens(r) : r;
|
|
21210
21213
|
i.walkTokens && await Promise.all(this.walkTokens(a, i.walkTokens));
|
|
21211
|
-
let o = await (i.hooks ? await i.hooks.provideParser(e) : e ?
|
|
21214
|
+
let o = await (i.hooks ? await i.hooks.provideParser(e) : e ? KO.parse : KO.parseInline)(a, i);
|
|
21212
21215
|
return i.hooks ? await i.hooks.postprocess(o) : o;
|
|
21213
21216
|
})().catch(a);
|
|
21214
21217
|
try {
|
|
21215
21218
|
i.hooks && (t = i.hooks.preprocess(t));
|
|
21216
|
-
let n = (i.hooks ? i.hooks.provideLexer(e) : e ?
|
|
21219
|
+
let n = (i.hooks ? i.hooks.provideLexer(e) : e ? UO.lex : UO.lexInline)(t, i);
|
|
21217
21220
|
i.hooks && (n = i.hooks.processAllTokens(n)), i.walkTokens && this.walkTokens(n, i.walkTokens);
|
|
21218
|
-
let r = (i.hooks ? i.hooks.provideParser(e) : e ?
|
|
21221
|
+
let r = (i.hooks ? i.hooks.provideParser(e) : e ? KO.parse : KO.parseInline)(n, i);
|
|
21219
21222
|
return i.hooks && (r = i.hooks.postprocess(r)), r;
|
|
21220
21223
|
} catch (e) {
|
|
21221
21224
|
return a(e);
|
|
@@ -21225,7 +21228,7 @@ ${e}</tr>
|
|
|
21225
21228
|
onError(e, t) {
|
|
21226
21229
|
return (n) => {
|
|
21227
21230
|
if (n.message += "\nPlease report this to https://github.com/markedjs/marked.", e) {
|
|
21228
|
-
let e = "<p>An error occurred:</p><pre>" +
|
|
21231
|
+
let e = "<p>An error occurred:</p><pre>" + NO(n.message + "", !0) + "</pre>";
|
|
21229
21232
|
return t ? Promise.resolve(e) : e;
|
|
21230
21233
|
}
|
|
21231
21234
|
if (t) return Promise.reject(n);
|
|
@@ -21233,19 +21236,19 @@ ${e}</tr>
|
|
|
21233
21236
|
};
|
|
21234
21237
|
}
|
|
21235
21238
|
}();
|
|
21236
|
-
function
|
|
21237
|
-
return
|
|
21238
|
-
}
|
|
21239
|
-
|
|
21240
|
-
return
|
|
21241
|
-
},
|
|
21242
|
-
return
|
|
21243
|
-
},
|
|
21244
|
-
return
|
|
21245
|
-
},
|
|
21239
|
+
function YO(e, t) {
|
|
21240
|
+
return JO.parse(e, t);
|
|
21241
|
+
}
|
|
21242
|
+
YO.options = YO.setOptions = function(e) {
|
|
21243
|
+
return JO.setOptions(e), YO.defaults = JO.defaults, vD(YO.defaults), YO;
|
|
21244
|
+
}, YO.getDefaults = gD, YO.defaults = _D, YO.use = function(...e) {
|
|
21245
|
+
return JO.use(...e), YO.defaults = JO.defaults, vD(YO.defaults), YO;
|
|
21246
|
+
}, YO.walkTokens = function(e, t) {
|
|
21247
|
+
return JO.walkTokens(e, t);
|
|
21248
|
+
}, YO.parseInline = JO.parseInline, YO.Parser = KO, YO.parser = KO.parse, YO.Renderer = WO, YO.TextRenderer = GO, YO.Lexer = UO, YO.lexer = UO.lex, YO.Tokenizer = HO, YO.Hooks = qO, YO.parse = YO, YO.options, YO.setOptions, YO.use, YO.walkTokens, YO.parseInline, KO.parse, UO.lex;
|
|
21246
21249
|
//#endregion
|
|
21247
21250
|
//#region node_modules/highlight.js/lib/core.js
|
|
21248
|
-
var
|
|
21251
|
+
var XO = /* @__PURE__ */ h(((e, t) => {
|
|
21249
21252
|
function n(e) {
|
|
21250
21253
|
return e instanceof Map ? e.clear = e.delete = e.set = function() {
|
|
21251
21254
|
throw Error("map is read-only");
|
|
@@ -22086,7 +22089,7 @@ var YO = /* @__PURE__ */ h(((e, t) => {
|
|
|
22086
22089
|
return Object.assign(e, F), e;
|
|
22087
22090
|
}, ke = Oe({});
|
|
22088
22091
|
ke.newInstance = () => Oe({}), t.exports = ke, ke.HighlightJS = ke, ke.default = ke;
|
|
22089
|
-
})),
|
|
22092
|
+
})), ZO = /* @__PURE__ */ h(((e, t) => {
|
|
22090
22093
|
function n(e) {
|
|
22091
22094
|
let t = e.regex, n = t.concat(/[\p{L}_]/u, t.optional(/[\p{L}0-9_.-]*:/u), /[\p{L}0-9_.-]*/u), r = /[\p{L}0-9._:-]+/u, i = {
|
|
22092
22095
|
className: "symbol",
|
|
@@ -22251,7 +22254,7 @@ var YO = /* @__PURE__ */ h(((e, t) => {
|
|
|
22251
22254
|
};
|
|
22252
22255
|
}
|
|
22253
22256
|
t.exports = n;
|
|
22254
|
-
})),
|
|
22257
|
+
})), QO = /* @__PURE__ */ h(((e, t) => {
|
|
22255
22258
|
function n(e) {
|
|
22256
22259
|
let t = e.regex, n = {}, r = {
|
|
22257
22260
|
begin: /\$\{/,
|
|
@@ -22419,7 +22422,7 @@ var YO = /* @__PURE__ */ h(((e, t) => {
|
|
|
22419
22422
|
};
|
|
22420
22423
|
}
|
|
22421
22424
|
t.exports = n;
|
|
22422
|
-
})),
|
|
22425
|
+
})), $O = /* @__PURE__ */ h(((e, t) => {
|
|
22423
22426
|
function n(e) {
|
|
22424
22427
|
let t = e.regex, n = e.COMMENT("//", "$", { contains: [{ begin: /\\\n/ }] }), r = "[a-zA-Z_]\\w*::", i = "(decltype\\(auto\\)|" + t.optional(r) + "[a-zA-Z_]\\w*" + t.optional("<[^<>]+>") + ")", a = {
|
|
22425
22428
|
className: "type",
|
|
@@ -22594,7 +22597,7 @@ var YO = /* @__PURE__ */ h(((e, t) => {
|
|
|
22594
22597
|
};
|
|
22595
22598
|
}
|
|
22596
22599
|
t.exports = n;
|
|
22597
|
-
})),
|
|
22600
|
+
})), ek = /* @__PURE__ */ h(((e, t) => {
|
|
22598
22601
|
function n(e) {
|
|
22599
22602
|
let t = e.regex, n = e.COMMENT("//", "$", { contains: [{ begin: /\\\n/ }] }), r = "[a-zA-Z_]\\w*::", i = "(?!struct)(decltype\\(auto\\)|" + t.optional(r) + "[a-zA-Z_]\\w*" + t.optional("<[^<>]+>") + ")", a = {
|
|
22600
22603
|
className: "type",
|
|
@@ -22818,7 +22821,7 @@ var YO = /* @__PURE__ */ h(((e, t) => {
|
|
|
22818
22821
|
};
|
|
22819
22822
|
}
|
|
22820
22823
|
t.exports = n;
|
|
22821
|
-
})),
|
|
22824
|
+
})), tk = /* @__PURE__ */ h(((e, t) => {
|
|
22822
22825
|
function n(e) {
|
|
22823
22826
|
let t = [
|
|
22824
22827
|
"bool",
|
|
@@ -23077,7 +23080,7 @@ var YO = /* @__PURE__ */ h(((e, t) => {
|
|
|
23077
23080
|
};
|
|
23078
23081
|
}
|
|
23079
23082
|
t.exports = n;
|
|
23080
|
-
})),
|
|
23083
|
+
})), nk = /* @__PURE__ */ h(((e, t) => {
|
|
23081
23084
|
var n = (e) => ({
|
|
23082
23085
|
IMPORTANT: {
|
|
23083
23086
|
scope: "meta",
|
|
@@ -23216,7 +23219,7 @@ var YO = /* @__PURE__ */ h(((e, t) => {
|
|
|
23216
23219
|
};
|
|
23217
23220
|
}
|
|
23218
23221
|
t.exports = u;
|
|
23219
|
-
})),
|
|
23222
|
+
})), rk = /* @__PURE__ */ h(((e, t) => {
|
|
23220
23223
|
function n(e) {
|
|
23221
23224
|
let t = e.regex, n = {
|
|
23222
23225
|
begin: /<\/?[A-Za-z_]/,
|
|
@@ -23396,7 +23399,7 @@ var YO = /* @__PURE__ */ h(((e, t) => {
|
|
|
23396
23399
|
};
|
|
23397
23400
|
}
|
|
23398
23401
|
t.exports = n;
|
|
23399
|
-
})),
|
|
23402
|
+
})), ik = /* @__PURE__ */ h(((e, t) => {
|
|
23400
23403
|
function n(e) {
|
|
23401
23404
|
let t = e.regex;
|
|
23402
23405
|
return {
|
|
@@ -23434,7 +23437,7 @@ var YO = /* @__PURE__ */ h(((e, t) => {
|
|
|
23434
23437
|
};
|
|
23435
23438
|
}
|
|
23436
23439
|
t.exports = n;
|
|
23437
|
-
})),
|
|
23440
|
+
})), ak = /* @__PURE__ */ h(((e, t) => {
|
|
23438
23441
|
function n(e) {
|
|
23439
23442
|
let t = e.regex, n = "([a-zA-Z_]\\w*[!?=]?|[-+~]@|<<|>>|=~|===?|<=>|[<>]=?|\\*\\*|[-/+%^&*~`|]|\\[\\]=?)", r = t.either(/\b([A-Z]+[a-z0-9]+)+/, /\b([A-Z]+[a-z0-9]+)+[A-Z]+/), i = t.concat(r, /(::\w+)*/), a = {
|
|
23440
23443
|
"variable.constant": [
|
|
@@ -23695,7 +23698,7 @@ var YO = /* @__PURE__ */ h(((e, t) => {
|
|
|
23695
23698
|
};
|
|
23696
23699
|
}
|
|
23697
23700
|
t.exports = n;
|
|
23698
|
-
})),
|
|
23701
|
+
})), ok = /* @__PURE__ */ h(((e, t) => {
|
|
23699
23702
|
function n(e) {
|
|
23700
23703
|
let t = {
|
|
23701
23704
|
keyword: [
|
|
@@ -23834,7 +23837,7 @@ var YO = /* @__PURE__ */ h(((e, t) => {
|
|
|
23834
23837
|
};
|
|
23835
23838
|
}
|
|
23836
23839
|
t.exports = n;
|
|
23837
|
-
})),
|
|
23840
|
+
})), sk = /* @__PURE__ */ h(((e, t) => {
|
|
23838
23841
|
function n(e) {
|
|
23839
23842
|
let t = e.regex;
|
|
23840
23843
|
return {
|
|
@@ -23900,7 +23903,7 @@ var YO = /* @__PURE__ */ h(((e, t) => {
|
|
|
23900
23903
|
};
|
|
23901
23904
|
}
|
|
23902
23905
|
t.exports = n;
|
|
23903
|
-
})),
|
|
23906
|
+
})), ck = /* @__PURE__ */ h(((e, t) => {
|
|
23904
23907
|
function n(e) {
|
|
23905
23908
|
let t = e.regex, n = {
|
|
23906
23909
|
className: "number",
|
|
@@ -23987,7 +23990,7 @@ var YO = /* @__PURE__ */ h(((e, t) => {
|
|
|
23987
23990
|
};
|
|
23988
23991
|
}
|
|
23989
23992
|
t.exports = n;
|
|
23990
|
-
})),
|
|
23993
|
+
})), lk = /* @__PURE__ */ h(((e, t) => {
|
|
23991
23994
|
var n = "[0-9](_*[0-9])*", r = `\\.(${n})`, i = "[0-9a-fA-F](_*[0-9a-fA-F])*", a = {
|
|
23992
23995
|
className: "number",
|
|
23993
23996
|
variants: [
|
|
@@ -24155,7 +24158,7 @@ var YO = /* @__PURE__ */ h(((e, t) => {
|
|
|
24155
24158
|
};
|
|
24156
24159
|
}
|
|
24157
24160
|
t.exports = s;
|
|
24158
|
-
})),
|
|
24161
|
+
})), uk = /* @__PURE__ */ h(((e, t) => {
|
|
24159
24162
|
var n = "[A-Za-z$_][0-9A-Za-z$_]*", r = /* @__PURE__ */ "as.in.of.if.for.while.finally.var.new.function.do.return.void.else.break.catch.instanceof.with.throw.case.default.try.switch.continue.typeof.delete.let.yield.const.class.debugger.async.await.static.import.from.export.extends.using".split("."), i = [
|
|
24160
24163
|
"true",
|
|
24161
24164
|
"false",
|
|
@@ -24590,7 +24593,7 @@ var YO = /* @__PURE__ */ h(((e, t) => {
|
|
|
24590
24593
|
};
|
|
24591
24594
|
}
|
|
24592
24595
|
t.exports = u;
|
|
24593
|
-
})),
|
|
24596
|
+
})), dk = /* @__PURE__ */ h(((e, t) => {
|
|
24594
24597
|
function n(e) {
|
|
24595
24598
|
let t = {
|
|
24596
24599
|
className: "attr",
|
|
@@ -24625,7 +24628,7 @@ var YO = /* @__PURE__ */ h(((e, t) => {
|
|
|
24625
24628
|
};
|
|
24626
24629
|
}
|
|
24627
24630
|
t.exports = n;
|
|
24628
|
-
})),
|
|
24631
|
+
})), fk = /* @__PURE__ */ h(((e, t) => {
|
|
24629
24632
|
var n = "[0-9](_*[0-9])*", r = `\\.(${n})`, i = "[0-9a-fA-F](_*[0-9a-fA-F])*", a = {
|
|
24630
24633
|
className: "number",
|
|
24631
24634
|
variants: [
|
|
@@ -24825,7 +24828,7 @@ var YO = /* @__PURE__ */ h(((e, t) => {
|
|
|
24825
24828
|
};
|
|
24826
24829
|
}
|
|
24827
24830
|
t.exports = o;
|
|
24828
|
-
})),
|
|
24831
|
+
})), pk = /* @__PURE__ */ h(((e, t) => {
|
|
24829
24832
|
var n = (e) => ({
|
|
24830
24833
|
IMPORTANT: {
|
|
24831
24834
|
scope: "meta",
|
|
@@ -25016,7 +25019,7 @@ var YO = /* @__PURE__ */ h(((e, t) => {
|
|
|
25016
25019
|
};
|
|
25017
25020
|
}
|
|
25018
25021
|
t.exports = d;
|
|
25019
|
-
})),
|
|
25022
|
+
})), mk = /* @__PURE__ */ h(((e, t) => {
|
|
25020
25023
|
function n(e) {
|
|
25021
25024
|
let t = "\\[=*\\[", n = "\\]=*\\]", r = {
|
|
25022
25025
|
begin: t,
|
|
@@ -25061,7 +25064,7 @@ var YO = /* @__PURE__ */ h(((e, t) => {
|
|
|
25061
25064
|
};
|
|
25062
25065
|
}
|
|
25063
25066
|
t.exports = n;
|
|
25064
|
-
})),
|
|
25067
|
+
})), hk = /* @__PURE__ */ h(((e, t) => {
|
|
25065
25068
|
function n(e) {
|
|
25066
25069
|
let t = {
|
|
25067
25070
|
className: "variable",
|
|
@@ -25117,7 +25120,7 @@ var YO = /* @__PURE__ */ h(((e, t) => {
|
|
|
25117
25120
|
};
|
|
25118
25121
|
}
|
|
25119
25122
|
t.exports = n;
|
|
25120
|
-
})),
|
|
25123
|
+
})), gk = /* @__PURE__ */ h(((e, t) => {
|
|
25121
25124
|
function n(e) {
|
|
25122
25125
|
let t = e.regex, n = /* @__PURE__ */ "abs.accept.alarm.and.atan2.bind.binmode.bless.break.caller.chdir.chmod.chomp.chop.chown.chr.chroot.class.close.closedir.connect.continue.cos.crypt.dbmclose.dbmopen.defined.delete.die.do.dump.each.else.elsif.endgrent.endhostent.endnetent.endprotoent.endpwent.endservent.eof.eval.exec.exists.exit.exp.fcntl.field.fileno.flock.for.foreach.fork.format.formline.getc.getgrent.getgrgid.getgrnam.gethostbyaddr.gethostbyname.gethostent.getlogin.getnetbyaddr.getnetbyname.getnetent.getpeername.getpgrp.getpriority.getprotobyname.getprotobynumber.getprotoent.getpwent.getpwnam.getpwuid.getservbyname.getservbyport.getservent.getsockname.getsockopt.given.glob.gmtime.goto.grep.gt.hex.if.index.int.ioctl.join.keys.kill.last.lc.lcfirst.length.link.listen.local.localtime.log.lstat.lt.ma.map.method.mkdir.msgctl.msgget.msgrcv.msgsnd.my.ne.next.no.not.oct.open.opendir.or.ord.our.pack.package.pipe.pop.pos.print.printf.prototype.push.q|0.qq.quotemeta.qw.qx.rand.read.readdir.readline.readlink.readpipe.recv.redo.ref.rename.require.reset.return.reverse.rewinddir.rindex.rmdir.say.scalar.seek.seekdir.select.semctl.semget.semop.send.setgrent.sethostent.setnetent.setpgrp.setpriority.setprotoent.setpwent.setservent.setsockopt.shift.shmctl.shmget.shmread.shmwrite.shutdown.sin.sleep.socket.socketpair.sort.splice.split.sprintf.sqrt.srand.stat.state.study.sub.substr.symlink.syscall.sysopen.sysread.sysseek.system.syswrite.tell.telldir.tie.tied.time.times.tr.truncate.uc.ucfirst.umask.undef.unless.unlink.unpack.unshift.untie.until.use.utime.values.vec.wait.waitpid.wantarray.warn.when.while.write.x|0.xor.y|0".split("."), r = /[dualxmsipngr]{0,12}/, i = {
|
|
25123
25126
|
$pattern: /[\w.]+/,
|
|
@@ -25308,7 +25311,7 @@ var YO = /* @__PURE__ */ h(((e, t) => {
|
|
|
25308
25311
|
};
|
|
25309
25312
|
}
|
|
25310
25313
|
t.exports = n;
|
|
25311
|
-
})),
|
|
25314
|
+
})), _k = /* @__PURE__ */ h(((e, t) => {
|
|
25312
25315
|
function n(e) {
|
|
25313
25316
|
let t = {
|
|
25314
25317
|
className: "built_in",
|
|
@@ -25424,7 +25427,7 @@ var YO = /* @__PURE__ */ h(((e, t) => {
|
|
|
25424
25427
|
};
|
|
25425
25428
|
}
|
|
25426
25429
|
t.exports = n;
|
|
25427
|
-
})),
|
|
25430
|
+
})), vk = /* @__PURE__ */ h(((e, t) => {
|
|
25428
25431
|
function n(e) {
|
|
25429
25432
|
let t = e.regex, n = /(?![A-Za-z0-9])(?![$])/, r = t.concat(/[a-zA-Z_\x7f-\xff][a-zA-Z0-9_\x7f-\xff]*/, n), i = t.concat(/(\\?[A-Z][a-z0-9_\x7f-\xff]+|\\?[A-Z]+(?=[A-Z][a-z0-9_\x7f-\xff])){1,}/, n), a = t.concat(/[A-Z]+/, n), o = {
|
|
25430
25433
|
scope: "variable",
|
|
@@ -25717,7 +25720,7 @@ var YO = /* @__PURE__ */ h(((e, t) => {
|
|
|
25717
25720
|
};
|
|
25718
25721
|
}
|
|
25719
25722
|
t.exports = n;
|
|
25720
|
-
})),
|
|
25723
|
+
})), yk = /* @__PURE__ */ h(((e, t) => {
|
|
25721
25724
|
function n(e) {
|
|
25722
25725
|
return {
|
|
25723
25726
|
name: "PHP template",
|
|
@@ -25759,7 +25762,7 @@ var YO = /* @__PURE__ */ h(((e, t) => {
|
|
|
25759
25762
|
};
|
|
25760
25763
|
}
|
|
25761
25764
|
t.exports = n;
|
|
25762
|
-
})),
|
|
25765
|
+
})), bk = /* @__PURE__ */ h(((e, t) => {
|
|
25763
25766
|
function n(e) {
|
|
25764
25767
|
return {
|
|
25765
25768
|
name: "Plain text",
|
|
@@ -25768,7 +25771,7 @@ var YO = /* @__PURE__ */ h(((e, t) => {
|
|
|
25768
25771
|
};
|
|
25769
25772
|
}
|
|
25770
25773
|
t.exports = n;
|
|
25771
|
-
})),
|
|
25774
|
+
})), xk = /* @__PURE__ */ h(((e, t) => {
|
|
25772
25775
|
function n(e) {
|
|
25773
25776
|
let t = e.regex, n = /[\p{XID_Start}_]\p{XID_Continue}*/u, r = /* @__PURE__ */ "and.as.assert.async.await.break.case.class.continue.def.del.elif.else.except.finally.for.from.global.if.import.in.is.lambda.match.nonlocal|10.not.or.pass.raise.return.try.while.with.yield".split("."), i = {
|
|
25774
25777
|
$pattern: /[A-Za-z]\w+|__\w+__/,
|
|
@@ -26005,7 +26008,7 @@ var YO = /* @__PURE__ */ h(((e, t) => {
|
|
|
26005
26008
|
};
|
|
26006
26009
|
}
|
|
26007
26010
|
t.exports = n;
|
|
26008
|
-
})),
|
|
26011
|
+
})), Sk = /* @__PURE__ */ h(((e, t) => {
|
|
26009
26012
|
function n(e) {
|
|
26010
26013
|
return {
|
|
26011
26014
|
aliases: ["pycon"],
|
|
@@ -26023,7 +26026,7 @@ var YO = /* @__PURE__ */ h(((e, t) => {
|
|
|
26023
26026
|
};
|
|
26024
26027
|
}
|
|
26025
26028
|
t.exports = n;
|
|
26026
|
-
})),
|
|
26029
|
+
})), Ck = /* @__PURE__ */ h(((e, t) => {
|
|
26027
26030
|
function n(e) {
|
|
26028
26031
|
let t = e.regex, n = /(?:(?:[a-zA-Z]|\.[._a-zA-Z])[._a-zA-Z0-9]*)|\.(?!\d)/, r = t.either(/0[xX][0-9a-fA-F]+\.[0-9a-fA-F]*[pP][+-]?\d+i?/, /0[xX][0-9a-fA-F]+(?:[pP][+-]?\d+)?[Li]?/, /(?:\d+(?:\.\d*)?|\.\d+)(?:[eE][+-]?\d+)?[Li]?/), i = /[=!<>:]=|\|\||&&|:::?|<-|<<-|->>|->|\|>|[-+*\/?!$&|:<=>@^~]|\*\*/, a = t.either(/[()]/, /[{}]/, /\[\[/, /[[\]]/, /\\/, /,/);
|
|
26029
26032
|
return {
|
|
@@ -26162,7 +26165,7 @@ var YO = /* @__PURE__ */ h(((e, t) => {
|
|
|
26162
26165
|
};
|
|
26163
26166
|
}
|
|
26164
26167
|
t.exports = n;
|
|
26165
|
-
})),
|
|
26168
|
+
})), wk = /* @__PURE__ */ h(((e, t) => {
|
|
26166
26169
|
function n(e) {
|
|
26167
26170
|
let t = e.regex, n = /(r#)?/, r = t.concat(n, e.UNDERSCORE_IDENT_RE), i = t.concat(n, e.IDENT_RE), a = {
|
|
26168
26171
|
className: "title.function.invoke",
|
|
@@ -26330,7 +26333,7 @@ var YO = /* @__PURE__ */ h(((e, t) => {
|
|
|
26330
26333
|
};
|
|
26331
26334
|
}
|
|
26332
26335
|
t.exports = n;
|
|
26333
|
-
})),
|
|
26336
|
+
})), Tk = /* @__PURE__ */ h(((e, t) => {
|
|
26334
26337
|
var n = (e) => ({
|
|
26335
26338
|
IMPORTANT: {
|
|
26336
26339
|
scope: "meta",
|
|
@@ -26479,7 +26482,7 @@ var YO = /* @__PURE__ */ h(((e, t) => {
|
|
|
26479
26482
|
};
|
|
26480
26483
|
}
|
|
26481
26484
|
t.exports = u;
|
|
26482
|
-
})),
|
|
26485
|
+
})), Ek = /* @__PURE__ */ h(((e, t) => {
|
|
26483
26486
|
function n(e) {
|
|
26484
26487
|
return {
|
|
26485
26488
|
name: "Shell Session",
|
|
@@ -26495,7 +26498,7 @@ var YO = /* @__PURE__ */ h(((e, t) => {
|
|
|
26495
26498
|
};
|
|
26496
26499
|
}
|
|
26497
26500
|
t.exports = n;
|
|
26498
|
-
})),
|
|
26501
|
+
})), Dk = /* @__PURE__ */ h(((e, t) => {
|
|
26499
26502
|
function n(e) {
|
|
26500
26503
|
let t = e.regex, n = e.COMMENT("--", "$"), r = {
|
|
26501
26504
|
scope: "string",
|
|
@@ -26612,7 +26615,7 @@ var YO = /* @__PURE__ */ h(((e, t) => {
|
|
|
26612
26615
|
};
|
|
26613
26616
|
}
|
|
26614
26617
|
t.exports = n;
|
|
26615
|
-
})),
|
|
26618
|
+
})), Ok = /* @__PURE__ */ h(((e, t) => {
|
|
26616
26619
|
function n(e) {
|
|
26617
26620
|
return e ? typeof e == "string" ? e : e.source : null;
|
|
26618
26621
|
}
|
|
@@ -27185,7 +27188,7 @@ var YO = /* @__PURE__ */ h(((e, t) => {
|
|
|
27185
27188
|
};
|
|
27186
27189
|
}
|
|
27187
27190
|
t.exports = T;
|
|
27188
|
-
})),
|
|
27191
|
+
})), kk = /* @__PURE__ */ h(((e, t) => {
|
|
27189
27192
|
function n(e) {
|
|
27190
27193
|
let t = "true false yes no null", n = {
|
|
27191
27194
|
className: "attr",
|
|
@@ -27328,7 +27331,7 @@ var YO = /* @__PURE__ */ h(((e, t) => {
|
|
|
27328
27331
|
};
|
|
27329
27332
|
}
|
|
27330
27333
|
t.exports = n;
|
|
27331
|
-
})),
|
|
27334
|
+
})), Ak = /* @__PURE__ */ h(((e, t) => {
|
|
27332
27335
|
var n = "[A-Za-z$_][0-9A-Za-z$_]*", r = /* @__PURE__ */ "as.in.of.if.for.while.finally.var.new.function.do.return.void.else.break.catch.instanceof.with.throw.case.default.try.switch.continue.typeof.delete.let.yield.const.class.debugger.async.await.static.import.from.export.extends.using".split("."), i = [
|
|
27333
27336
|
"true",
|
|
27334
27337
|
"false",
|
|
@@ -27848,7 +27851,7 @@ var YO = /* @__PURE__ */ h(((e, t) => {
|
|
|
27848
27851
|
}), a;
|
|
27849
27852
|
}
|
|
27850
27853
|
t.exports = d;
|
|
27851
|
-
})),
|
|
27854
|
+
})), jk = /* @__PURE__ */ h(((e, t) => {
|
|
27852
27855
|
function n(e) {
|
|
27853
27856
|
let t = e.regex, n = {
|
|
27854
27857
|
className: "string",
|
|
@@ -27916,7 +27919,7 @@ var YO = /* @__PURE__ */ h(((e, t) => {
|
|
|
27916
27919
|
};
|
|
27917
27920
|
}
|
|
27918
27921
|
t.exports = n;
|
|
27919
|
-
})),
|
|
27922
|
+
})), Mk = /* @__PURE__ */ h(((e, t) => {
|
|
27920
27923
|
function n(e) {
|
|
27921
27924
|
e.regex;
|
|
27922
27925
|
let t = e.COMMENT(/\(;/, /;\)/);
|
|
@@ -27978,65 +27981,65 @@ var YO = /* @__PURE__ */ h(((e, t) => {
|
|
|
27978
27981
|
};
|
|
27979
27982
|
}
|
|
27980
27983
|
t.exports = n;
|
|
27981
|
-
})),
|
|
27982
|
-
var n =
|
|
27983
|
-
n.registerLanguage("xml",
|
|
27984
|
+
})), Nk = (/* @__PURE__ */ _((/* @__PURE__ */ h(((e, t) => {
|
|
27985
|
+
var n = XO();
|
|
27986
|
+
n.registerLanguage("xml", ZO()), n.registerLanguage("bash", QO()), n.registerLanguage("c", $O()), n.registerLanguage("cpp", ek()), n.registerLanguage("csharp", tk()), n.registerLanguage("css", nk()), n.registerLanguage("markdown", rk()), n.registerLanguage("diff", ik()), n.registerLanguage("ruby", ak()), n.registerLanguage("go", ok()), n.registerLanguage("graphql", sk()), n.registerLanguage("ini", ck()), n.registerLanguage("java", lk()), n.registerLanguage("javascript", uk()), n.registerLanguage("json", dk()), n.registerLanguage("kotlin", fk()), n.registerLanguage("less", pk()), n.registerLanguage("lua", mk()), n.registerLanguage("makefile", hk()), n.registerLanguage("perl", gk()), n.registerLanguage("objectivec", _k()), n.registerLanguage("php", vk()), n.registerLanguage("php-template", yk()), n.registerLanguage("plaintext", bk()), n.registerLanguage("python", xk()), n.registerLanguage("python-repl", Sk()), n.registerLanguage("r", Ck()), n.registerLanguage("rust", wk()), n.registerLanguage("scss", Tk()), n.registerLanguage("shell", Ek()), n.registerLanguage("sql", Dk()), n.registerLanguage("swift", Ok()), n.registerLanguage("yaml", kk()), n.registerLanguage("typescript", Ak()), n.registerLanguage("vbnet", jk()), n.registerLanguage("wasm", Mk()), n.HighlightJS = n, n.default = n, t.exports = n;
|
|
27984
27987
|
})))())).default;
|
|
27985
27988
|
//#endregion
|
|
27986
27989
|
//#region src/core/composables/useMarkdown.ts
|
|
27987
|
-
|
|
27990
|
+
YO.setOptions({
|
|
27988
27991
|
breaks: !0,
|
|
27989
27992
|
gfm: !0
|
|
27990
27993
|
});
|
|
27991
|
-
var
|
|
27992
|
-
|
|
27994
|
+
var Pk = 2e4, Fk = new YO.Renderer();
|
|
27995
|
+
Fk.code = ({ text: e, lang: t }) => {
|
|
27993
27996
|
let n = (t || "").trim() || "plaintext", r = "";
|
|
27994
|
-
if (e.length > 2e4) r =
|
|
27997
|
+
if (e.length > 2e4) r = Lk(e);
|
|
27995
27998
|
else try {
|
|
27996
|
-
r =
|
|
27999
|
+
r = Nk.highlight(e, {
|
|
27997
28000
|
language: n,
|
|
27998
28001
|
ignoreIllegals: !0
|
|
27999
28002
|
}).value;
|
|
28000
28003
|
} catch {
|
|
28001
|
-
r =
|
|
28004
|
+
r = Lk(e);
|
|
28002
28005
|
}
|
|
28003
|
-
let i = encodeURIComponent(e), a =
|
|
28006
|
+
let i = encodeURIComponent(e), a = Ik(n);
|
|
28004
28007
|
return `<pre class="code-block" data-lang="${a}" data-code="${i}"><code class="hljs language-${a}">${r}</code></pre>`;
|
|
28005
28008
|
};
|
|
28006
|
-
function
|
|
28009
|
+
function Ik(e) {
|
|
28007
28010
|
return e.replace(/&/g, "&").replace(/"/g, """).replace(/</g, "<").replace(/>/g, ">");
|
|
28008
28011
|
}
|
|
28009
|
-
function
|
|
28012
|
+
function Lk(e) {
|
|
28010
28013
|
return e.replace(/&/g, "&").replace(/</g, "<").replace(/>/g, ">");
|
|
28011
28014
|
}
|
|
28012
|
-
var
|
|
28015
|
+
var Rk = { ADD_ATTR: [
|
|
28013
28016
|
"data-code",
|
|
28014
28017
|
"data-lang",
|
|
28015
28018
|
"target",
|
|
28016
28019
|
"rel"
|
|
28017
28020
|
] };
|
|
28018
|
-
function Rk(e) {
|
|
28019
|
-
return FT.sanitize(e, Lk);
|
|
28020
|
-
}
|
|
28021
28021
|
function zk(e) {
|
|
28022
|
-
return
|
|
28022
|
+
return FT.sanitize(e, Rk);
|
|
28023
28023
|
}
|
|
28024
28024
|
function Bk(e) {
|
|
28025
|
-
return
|
|
28025
|
+
return YO.parse(e || "", { renderer: Fk });
|
|
28026
|
+
}
|
|
28027
|
+
function Vk(e) {
|
|
28028
|
+
return zk(Bk(e));
|
|
28026
28029
|
}
|
|
28027
|
-
var
|
|
28028
|
-
function
|
|
28029
|
-
let t = /* @__PURE__ */ Nn(
|
|
28030
|
+
var Hk = 100, Uk = 2e3;
|
|
28031
|
+
function Wk(e) {
|
|
28032
|
+
let t = /* @__PURE__ */ Nn(Vk(e())), n = 0, r = null;
|
|
28030
28033
|
function i() {
|
|
28031
|
-
r = null, n = Date.now(), t.value =
|
|
28034
|
+
r = null, n = Date.now(), t.value = Vk(e());
|
|
28032
28035
|
}
|
|
28033
28036
|
return di(e, () => {
|
|
28034
28037
|
let a = e();
|
|
28035
|
-
if (a.length <=
|
|
28036
|
-
r &&= (clearTimeout(r), null), n = Date.now(), t.value =
|
|
28038
|
+
if (a.length <= Uk) {
|
|
28039
|
+
r &&= (clearTimeout(r), null), n = Date.now(), t.value = Vk(a);
|
|
28037
28040
|
return;
|
|
28038
28041
|
}
|
|
28039
|
-
let o = n +
|
|
28042
|
+
let o = n + Hk - Date.now();
|
|
28040
28043
|
o <= 0 ? (r &&= (clearTimeout(r), null), i()) : r ||= setTimeout(i, o);
|
|
28041
28044
|
}), at(() => {
|
|
28042
28045
|
r &&= (clearTimeout(r), null);
|
|
@@ -28054,14 +28057,14 @@ function Uk(e) {
|
|
|
28054
28057
|
}
|
|
28055
28058
|
//#endregion
|
|
28056
28059
|
//#region src/core/components/MessageContent.vue?vue&type=script&setup=true&lang.ts
|
|
28057
|
-
var
|
|
28060
|
+
var Gk = ["innerHTML"], Kk = /* @__PURE__ */ Wi({
|
|
28058
28061
|
__name: "MessageContent",
|
|
28059
28062
|
props: {
|
|
28060
28063
|
content: {},
|
|
28061
28064
|
messages: { default: () => ow }
|
|
28062
28065
|
},
|
|
28063
28066
|
setup(e) {
|
|
28064
|
-
let t = e, { html: n, codeBlocks: r } =
|
|
28067
|
+
let t = e, { html: n, codeBlocks: r } = Wk(() => t.content), i = /* @__PURE__ */ Mn(null);
|
|
28065
28068
|
function a(e, t) {
|
|
28066
28069
|
let n = {
|
|
28067
28070
|
html: "html",
|
|
@@ -28115,12 +28118,12 @@ var Wk = ["innerHTML"], Gk = /* @__PURE__ */ Wi({
|
|
|
28115
28118
|
ref_key: "containerRef",
|
|
28116
28119
|
ref: i,
|
|
28117
28120
|
innerHTML: K(n)
|
|
28118
|
-
}, null, 8,
|
|
28121
|
+
}, null, 8, Gk));
|
|
28119
28122
|
}
|
|
28120
|
-
}),
|
|
28123
|
+
}), qk = { class: "typing-text" }, Jk = {
|
|
28121
28124
|
key: 0,
|
|
28122
28125
|
class: "stream-cursor"
|
|
28123
|
-
},
|
|
28126
|
+
}, Yk = /*#__PURE__*/ qT(/* @__PURE__ */ Wi({
|
|
28124
28127
|
__name: "MessageBubble",
|
|
28125
28128
|
props: {
|
|
28126
28129
|
content: {},
|
|
@@ -28131,29 +28134,29 @@ var Wk = ["innerHTML"], Gk = /* @__PURE__ */ Wi({
|
|
|
28131
28134
|
messages: { default: () => ({ ...ow }) }
|
|
28132
28135
|
},
|
|
28133
28136
|
setup(e) {
|
|
28134
|
-
return (t, n) => (Y(), X(J, null, [Z("div", { class: Be(["message-bubble", [e.role, { typing: e.isPendingAssistant }]]) }, [e.isPendingAssistant ? (Y(), X(J, { key: 0 }, [Z("span", { class: Be(["typing-dot", { pulse: e.showTyping }]) }, null, 2), Z("span",
|
|
28137
|
+
return (t, n) => (Y(), X(J, null, [Z("div", { class: Be(["message-bubble", [e.role, { typing: e.isPendingAssistant }]]) }, [e.isPendingAssistant ? (Y(), X(J, { key: 0 }, [Z("span", { class: Be(["typing-dot", { pulse: e.showTyping }]) }, null, 2), Z("span", qk, [xs(XT, { text: e.messages.thinking }, null, 8, ["text"])])], 64)) : (Y(), X(J, { key: 1 }, [e.role === "assistant" ? (Y(), ms(Kk, {
|
|
28135
28138
|
key: 0,
|
|
28136
28139
|
content: e.content,
|
|
28137
28140
|
messages: e.messages
|
|
28138
|
-
}, null, 8, ["content", "messages"])) : (Y(), X(J, { key: 1 }, [Es(W(e.content), 1)], 64))], 64))], 2), e.showCursor ? (Y(), X("span",
|
|
28141
|
+
}, null, 8, ["content", "messages"])) : (Y(), X(J, { key: 1 }, [Es(W(e.content), 1)], 64))], 64))], 2), e.showCursor ? (Y(), X("span", Jk)) : Q("", !0)], 64));
|
|
28139
28142
|
}
|
|
28140
|
-
}), [["__scopeId", "data-v-4b4111d8"]]),
|
|
28143
|
+
}), [["__scopeId", "data-v-4b4111d8"]]), Xk = { class: "message-time" }, Zk = /*#__PURE__*/ qT(/* @__PURE__ */ Wi({
|
|
28141
28144
|
__name: "MessageTime",
|
|
28142
28145
|
props: { time: {} },
|
|
28143
28146
|
setup(e) {
|
|
28144
|
-
return (t, n) => (Y(), X("div",
|
|
28147
|
+
return (t, n) => (Y(), X("div", Xk, W(e.time), 1));
|
|
28145
28148
|
}
|
|
28146
|
-
}), [["__scopeId", "data-v-4a976e4a"]]),
|
|
28149
|
+
}), [["__scopeId", "data-v-4a976e4a"]]), Qk = { class: "msg-actions" }, $k = ["title"], eA = {
|
|
28147
28150
|
key: 0,
|
|
28148
28151
|
viewBox: "0 0 16 16",
|
|
28149
28152
|
fill: "none",
|
|
28150
28153
|
"aria-hidden": "true"
|
|
28151
|
-
},
|
|
28154
|
+
}, tA = {
|
|
28152
28155
|
key: 1,
|
|
28153
28156
|
viewBox: "0 0 16 16",
|
|
28154
28157
|
fill: "none",
|
|
28155
28158
|
"aria-hidden": "true"
|
|
28156
|
-
},
|
|
28159
|
+
}, nA = /*#__PURE__*/ qT(/* @__PURE__ */ Wi({
|
|
28157
28160
|
__name: "MessageActions",
|
|
28158
28161
|
props: {
|
|
28159
28162
|
copied: { type: Boolean },
|
|
@@ -28161,17 +28164,17 @@ var Wk = ["innerHTML"], Gk = /* @__PURE__ */ Wi({
|
|
|
28161
28164
|
},
|
|
28162
28165
|
emits: ["copy", "regenerate"],
|
|
28163
28166
|
setup(e) {
|
|
28164
|
-
return (t, n) => (Y(), X("div",
|
|
28167
|
+
return (t, n) => (Y(), X("div", Qk, [Z("button", {
|
|
28165
28168
|
class: Be(["msg-action-btn", { done: e.copied }]),
|
|
28166
28169
|
title: e.copied ? e.messages.copied : e.messages.copy,
|
|
28167
28170
|
onClick: n[0] ||= (e) => t.$emit("copy")
|
|
28168
|
-
}, [e.copied ? (Y(), X("svg",
|
|
28171
|
+
}, [e.copied ? (Y(), X("svg", eA, [...n[2] ||= [Z("path", {
|
|
28169
28172
|
d: "M3 8.5l3 3 7-7",
|
|
28170
28173
|
stroke: "currentColor",
|
|
28171
28174
|
"stroke-width": "1.6",
|
|
28172
28175
|
"stroke-linecap": "round",
|
|
28173
28176
|
"stroke-linejoin": "round"
|
|
28174
|
-
}, null, -1)]])) : (Y(), X("svg",
|
|
28177
|
+
}, null, -1)]])) : (Y(), X("svg", tA, [...n[3] ||= [Z("rect", {
|
|
28175
28178
|
x: "5.5",
|
|
28176
28179
|
y: "5.5",
|
|
28177
28180
|
width: "8",
|
|
@@ -28183,7 +28186,7 @@ var Wk = ["innerHTML"], Gk = /* @__PURE__ */ Wi({
|
|
|
28183
28186
|
d: "M10.5 3.5v-.5A1.5 1.5 0 0 0 9 1.5H3.5A1.5 1.5 0 0 0 2 3v5.5A1.5 1.5 0 0 0 3.5 10H4",
|
|
28184
28187
|
stroke: "currentColor",
|
|
28185
28188
|
"stroke-width": "1.3"
|
|
28186
|
-
}, null, -1)]])), Z("span", null, W(e.copied ? e.messages.copied : e.messages.copy), 1)], 10,
|
|
28189
|
+
}, null, -1)]])), Z("span", null, W(e.copied ? e.messages.copied : e.messages.copy), 1)], 10, $k), Z("button", {
|
|
28187
28190
|
class: "msg-action-btn",
|
|
28188
28191
|
onClick: n[1] ||= (e) => t.$emit("regenerate")
|
|
28189
28192
|
}, [n[4] ||= Z("svg", {
|
|
@@ -28203,19 +28206,19 @@ var Wk = ["innerHTML"], Gk = /* @__PURE__ */ Wi({
|
|
|
28203
28206
|
"stroke-linejoin": "round"
|
|
28204
28207
|
})], -1), Z("span", null, W(e.messages.regenerate), 1)])]));
|
|
28205
28208
|
}
|
|
28206
|
-
}), [["__scopeId", "data-v-dc051a49"]]),
|
|
28209
|
+
}), [["__scopeId", "data-v-dc051a49"]]), rA = {
|
|
28207
28210
|
key: 1,
|
|
28208
28211
|
class: "avatar-icon",
|
|
28209
28212
|
viewBox: "0 0 1024 1024",
|
|
28210
28213
|
xmlns: "http://www.w3.org/2000/svg",
|
|
28211
28214
|
"aria-hidden": "true"
|
|
28212
|
-
},
|
|
28215
|
+
}, iA = {
|
|
28213
28216
|
key: 2,
|
|
28214
28217
|
class: "avatar-icon",
|
|
28215
28218
|
viewBox: "0 0 1024 1024",
|
|
28216
28219
|
xmlns: "http://www.w3.org/2000/svg",
|
|
28217
28220
|
"aria-hidden": "true"
|
|
28218
|
-
},
|
|
28221
|
+
}, aA = /*#__PURE__*/ qT(/* @__PURE__ */ Wi({
|
|
28219
28222
|
__name: "AvatarIcon",
|
|
28220
28223
|
props: {
|
|
28221
28224
|
role: {},
|
|
@@ -28226,18 +28229,18 @@ var Wk = ["innerHTML"], Gk = /* @__PURE__ */ Wi({
|
|
|
28226
28229
|
key: 0,
|
|
28227
28230
|
icon: e.glyph,
|
|
28228
28231
|
class: "avatar-glyph"
|
|
28229
|
-
}, null, 8, ["icon"])) : e.role === "user" ? (Y(), X("svg",
|
|
28232
|
+
}, null, 8, ["icon"])) : e.role === "user" ? (Y(), X("svg", rA, [...n[0] ||= [Z("path", { d: "M512 170.688a149.312 149.312 0 1 0 0 298.624 149.312 149.312 0 0 0 0-298.624zM277.312 320a234.688 234.688 0 1 1 469.376 0 234.688 234.688 0 0 1-469.376 0zM128 810.688a213.312 213.312 0 0 1 213.312-213.312h341.376A213.312 213.312 0 0 1 896 810.688v128H128v-128z m213.312-128a128 128 0 0 0-128 128v42.688h597.376v-42.688a128 128 0 0 0-128-128H341.312z" }, null, -1)]])) : (Y(), X("svg", iA, [...n[1] ||= [Z("path", { d: "M717.12 274H762c82.842 0 150 67.158 150 150v200c0 82.842-67.158 150-150 150H262c-82.842 0-150-67.158-150-150V424c0-82.842 67.158-150 150-150h44.88l-18.268-109.602c-4.086-24.514 12.476-47.7 36.99-51.786 24.514-4.086 47.7 12.476 51.786 36.99l20 120c0.246 1.472 0.416 2.94 0.516 4.398h228.192c0.1-1.46 0.27-2.926 0.516-4.398l20-120c4.086-24.514 27.272-41.076 51.786-36.99 24.514 4.086 41.076 27.272 36.99 51.786L717.12 274zM262 364c-33.138 0-60 26.862-60 60v200c0 33.138 26.862 60 60 60h500c33.138 0 60-26.862 60-60V424c0-33.138-26.862-60-60-60H262z m50 548c-24.852 0-45-20.148-45-45S287.148 822 312 822h400c24.852 0 45 20.148 45 45S736.852 912 712 912H312z m-4-428c0-24.852 20.148-45 45-45S398 459.148 398 484v40c0 24.852-20.148 45-45 45S308 548.852 308 524v-40z m318 0c0-24.852 20.148-45 45-45S716 459.148 716 484v40c0 24.852-20.148 45-45 45S626 548.852 626 524v-40z" }, null, -1)]]));
|
|
28230
28233
|
}
|
|
28231
|
-
}), [["__scopeId", "data-v-a0b508ea"]]),
|
|
28234
|
+
}), [["__scopeId", "data-v-a0b508ea"]]), oA = ["data-msg-idx"], sA = {
|
|
28232
28235
|
key: 0,
|
|
28233
28236
|
class: "message-avatar"
|
|
28234
|
-
},
|
|
28237
|
+
}, cA = { class: "message-content" }, lA = {
|
|
28235
28238
|
key: 2,
|
|
28236
28239
|
class: "msg-focuses"
|
|
28237
|
-
},
|
|
28240
|
+
}, uA = ["title", "onClick"], dA = ["data-img-count"], fA = ["href", "title"], pA = ["src", "alt"], mA = {
|
|
28238
28241
|
key: 1,
|
|
28239
28242
|
class: "msg-image-lost"
|
|
28240
|
-
},
|
|
28243
|
+
}, hA = /*#__PURE__*/ qT(/* @__PURE__ */ Wi({
|
|
28241
28244
|
__name: "MessageRow",
|
|
28242
28245
|
props: {
|
|
28243
28246
|
message: {},
|
|
@@ -28257,28 +28260,30 @@ var Wk = ["innerHTML"], Gk = /* @__PURE__ */ Wi({
|
|
|
28257
28260
|
"regenerate"
|
|
28258
28261
|
],
|
|
28259
28262
|
setup(e) {
|
|
28260
|
-
let t = e, n = fw(), r = sc(() => t.message.role === "assistant"), i = sc(() => r.value && "reasoning" in t.message ? t.message.reasoning ?? "" : ""), a = sc(() => r.value && "steps" in t.message ? t.message.steps ?? [] : []),
|
|
28261
|
-
return (t,
|
|
28263
|
+
let t = e, n = fw(), r = sc(() => t.message.role === "assistant"), i = sc(() => r.value && "reasoning" in t.message ? t.message.reasoning ?? "" : ""), a = sc(() => r.value && "reasoningTotal" in t.message ? t.message.reasoningTotal : void 0), o = sc(() => r.value && "steps" in t.message ? t.message.steps ?? [] : []), s = sc(() => r.value && !!t.message.content && !t.loading && t.isLast), c = sc(() => r.value && t.loading && t.isLast && !!t.message.content);
|
|
28264
|
+
return (t, l) => (Y(), X("div", {
|
|
28262
28265
|
class: Be(["message-row", e.message.role]),
|
|
28263
28266
|
"data-msg-idx": e.index
|
|
28264
|
-
}, [e.showAvatar ? (Y(), X("div",
|
|
28267
|
+
}, [e.showAvatar ? (Y(), X("div", sA, [xs(aA, {
|
|
28265
28268
|
role: e.message.role,
|
|
28266
28269
|
glyph: e.message.role === "user" ? K(n).icons.userAvatar : K(n).icons.assistantAvatar
|
|
28267
|
-
}, null, 8, ["role", "glyph"])])) : Q("", !0), Z("div",
|
|
28270
|
+
}, null, 8, ["role", "glyph"])])) : Q("", !0), Z("div", cA, [
|
|
28268
28271
|
r.value ? (Y(), ms(RE, {
|
|
28269
28272
|
key: 0,
|
|
28270
28273
|
text: i.value,
|
|
28274
|
+
total: a.value,
|
|
28271
28275
|
expanded: e.reasoningExpanded,
|
|
28272
28276
|
running: e.loading && e.isLast,
|
|
28273
|
-
onToggle:
|
|
28277
|
+
onToggle: l[0] ||= (e) => t.$emit("toggle-reasoning")
|
|
28274
28278
|
}, null, 8, [
|
|
28275
28279
|
"text",
|
|
28280
|
+
"total",
|
|
28276
28281
|
"expanded",
|
|
28277
28282
|
"running"
|
|
28278
28283
|
])) : Q("", !0),
|
|
28279
|
-
r.value ? (Y(), ms(
|
|
28284
|
+
r.value ? (Y(), ms(hD, {
|
|
28280
28285
|
key: 1,
|
|
28281
|
-
steps:
|
|
28286
|
+
steps: o.value,
|
|
28282
28287
|
icons: K(n).icons,
|
|
28283
28288
|
messages: K(n).messages
|
|
28284
28289
|
}, null, 8, [
|
|
@@ -28286,12 +28291,12 @@ var Wk = ["innerHTML"], Gk = /* @__PURE__ */ Wi({
|
|
|
28286
28291
|
"icons",
|
|
28287
28292
|
"messages"
|
|
28288
28293
|
])) : Q("", !0),
|
|
28289
|
-
e.message.role === "user" && e.message.focuses?.length ? (Y(), X("div",
|
|
28294
|
+
e.message.role === "user" && e.message.focuses?.length ? (Y(), X("div", lA, [(Y(!0), X(J, null, ga(e.message.focuses, (e) => (Y(), X("span", {
|
|
28290
28295
|
key: e.path,
|
|
28291
28296
|
class: "msg-focus-chip",
|
|
28292
28297
|
title: K(n).messages.historyFocusChipTitlePrefix + e.path,
|
|
28293
28298
|
onClick: (t) => K(n).focusChipClick(e)
|
|
28294
|
-
}, [xs(JT, { icon: K(n).icons.focus }, null, 8, ["icon"]), Es(" " + W(e.path), 1)], 8,
|
|
28299
|
+
}, [xs(JT, { icon: K(n).icons.focus }, null, 8, ["icon"]), Es(" " + W(e.path), 1)], 8, uA))), 128))])) : Q("", !0),
|
|
28295
28300
|
e.message.role === "user" && e.message.images?.length ? (Y(), X("div", {
|
|
28296
28301
|
key: 3,
|
|
28297
28302
|
class: "msg-images",
|
|
@@ -28308,15 +28313,15 @@ var Wk = ["innerHTML"], Gk = /* @__PURE__ */ Wi({
|
|
|
28308
28313
|
class: "msg-image-thumb",
|
|
28309
28314
|
src: e.thumb || e.dataUri,
|
|
28310
28315
|
alt: e.name || K(n).messages.imageAlt
|
|
28311
|
-
}, null, 8,
|
|
28312
|
-
!r.value || e.message.content || e.isPendingAssistant ? (Y(), ms(
|
|
28316
|
+
}, null, 8, pA)) : (Y(), X("span", mA, "🖼️"))], 8, fA))), 128))], 8, dA)) : Q("", !0),
|
|
28317
|
+
!r.value || e.message.content || e.isPendingAssistant ? (Y(), ms(Yk, {
|
|
28313
28318
|
key: 4,
|
|
28314
28319
|
messages: K(n).messages,
|
|
28315
28320
|
content: e.message.content,
|
|
28316
28321
|
role: e.message.role,
|
|
28317
28322
|
"is-pending-assistant": e.isPendingAssistant,
|
|
28318
28323
|
"show-typing": e.showTyping,
|
|
28319
|
-
"show-cursor":
|
|
28324
|
+
"show-cursor": c.value
|
|
28320
28325
|
}, null, 8, [
|
|
28321
28326
|
"messages",
|
|
28322
28327
|
"content",
|
|
@@ -28325,29 +28330,29 @@ var Wk = ["innerHTML"], Gk = /* @__PURE__ */ Wi({
|
|
|
28325
28330
|
"show-typing",
|
|
28326
28331
|
"show-cursor"
|
|
28327
28332
|
])) : Q("", !0),
|
|
28328
|
-
xs(
|
|
28329
|
-
|
|
28333
|
+
xs(Zk, { time: e.time }, null, 8, ["time"]),
|
|
28334
|
+
s.value ? (Y(), ms(nA, {
|
|
28330
28335
|
key: 5,
|
|
28331
28336
|
messages: K(n).messages,
|
|
28332
28337
|
copied: e.copied,
|
|
28333
|
-
onCopy:
|
|
28334
|
-
onRegenerate:
|
|
28338
|
+
onCopy: l[1] ||= (e) => t.$emit("copy"),
|
|
28339
|
+
onRegenerate: l[2] ||= (e) => t.$emit("regenerate")
|
|
28335
28340
|
}, null, 8, ["messages", "copied"])) : Q("", !0)
|
|
28336
|
-
])], 10,
|
|
28341
|
+
])], 10, oA));
|
|
28337
28342
|
}
|
|
28338
|
-
}), [["__scopeId", "data-v-
|
|
28343
|
+
}), [["__scopeId", "data-v-dc92d354"]]), gA = { class: "chat-body" }, _A = {
|
|
28339
28344
|
key: 0,
|
|
28340
28345
|
class: "empty-state"
|
|
28341
|
-
},
|
|
28346
|
+
}, vA = { class: "empty-icon" }, yA = {
|
|
28342
28347
|
key: 1,
|
|
28343
28348
|
class: "message-row assistant"
|
|
28344
|
-
},
|
|
28349
|
+
}, bA = {
|
|
28345
28350
|
key: 0,
|
|
28346
28351
|
class: "message-avatar"
|
|
28347
|
-
},
|
|
28352
|
+
}, xA = { class: "message-content" }, SA = {
|
|
28348
28353
|
key: 2,
|
|
28349
28354
|
class: "error-bar"
|
|
28350
|
-
},
|
|
28355
|
+
}, CA = { class: "error-text" }, wA = ["title"], TA = /*#__PURE__*/ qT(/* @__PURE__ */ Wi({
|
|
28351
28356
|
__name: "MessageList",
|
|
28352
28357
|
props: {
|
|
28353
28358
|
showAvatar: { type: Boolean },
|
|
@@ -28355,9 +28360,9 @@ var Wk = ["innerHTML"], Gk = /* @__PURE__ */ Wi({
|
|
|
28355
28360
|
},
|
|
28356
28361
|
setup(e) {
|
|
28357
28362
|
let { chat: t, formatTime: n, copiedMsg: r, copyMessage: i, isPendingAssistant: a, isReasoningExpanded: o, toggleReasoning: s, canUndo: c, undo: l, icons: u, messages: d } = fw(), { state: f, retry: p, regenerate: m } = t, h = sc(() => f.messages.length > 0), g = sc(() => f.messages.some((e) => e.role === "user")), _ = sc(() => f.messages[f.messages.length - 1]?.role === "assistant");
|
|
28358
|
-
return (t, v) => (Y(), X("div",
|
|
28359
|
-
h.value ? Q("", !0) : (Y(), X("div",
|
|
28360
|
-
(Y(!0), X(J, null, ga(K(f).messages, (t, c) => (Y(), ms(
|
|
28363
|
+
return (t, v) => (Y(), X("div", gA, [
|
|
28364
|
+
h.value ? Q("", !0) : (Y(), X("div", _A, [Z("div", vA, [xs(JT, { icon: K(u).empty }, null, 8, ["icon"])]), Z("p", null, [xs(XT, { text: K(d).emptyGreeting }, null, 8, ["text"])])])),
|
|
28365
|
+
(Y(!0), X(J, null, ga(K(f).messages, (t, c) => (Y(), ms(hA, {
|
|
28361
28366
|
key: c,
|
|
28362
28367
|
message: t,
|
|
28363
28368
|
index: c,
|
|
@@ -28387,10 +28392,10 @@ var Wk = ["innerHTML"], Gk = /* @__PURE__ */ Wi({
|
|
|
28387
28392
|
"onCopy",
|
|
28388
28393
|
"onRegenerate"
|
|
28389
28394
|
]))), 128)),
|
|
28390
|
-
K(f).loading && !_.value ? (Y(), X("div",
|
|
28395
|
+
K(f).loading && !_.value ? (Y(), X("div", yA, [e.showAvatar ? (Y(), X("div", bA, [xs(aA, {
|
|
28391
28396
|
role: "assistant",
|
|
28392
28397
|
glyph: K(u).assistantAvatar
|
|
28393
|
-
}, null, 8, ["glyph"])])) : Q("", !0), Z("div",
|
|
28398
|
+
}, null, 8, ["glyph"])])) : Q("", !0), Z("div", xA, [xs(Yk, {
|
|
28394
28399
|
content: "",
|
|
28395
28400
|
role: "assistant",
|
|
28396
28401
|
"is-pending-assistant": !0,
|
|
@@ -28398,8 +28403,8 @@ var Wk = ["innerHTML"], Gk = /* @__PURE__ */ Wi({
|
|
|
28398
28403
|
"show-cursor": !1,
|
|
28399
28404
|
messages: K(d)
|
|
28400
28405
|
}, null, 8, ["show-typing", "messages"])])])) : Q("", !0),
|
|
28401
|
-
K(f).error ? (Y(), X("div",
|
|
28402
|
-
Z("span",
|
|
28406
|
+
K(f).error ? (Y(), X("div", SA, [
|
|
28407
|
+
Z("span", CA, W(K(f).error), 1),
|
|
28403
28408
|
g.value ? (Y(), X("button", {
|
|
28404
28409
|
key: 0,
|
|
28405
28410
|
class: "retry-btn",
|
|
@@ -28410,61 +28415,61 @@ var Wk = ["innerHTML"], Gk = /* @__PURE__ */ Wi({
|
|
|
28410
28415
|
class: "undo-btn",
|
|
28411
28416
|
title: K(d).undoTitle,
|
|
28412
28417
|
onClick: v[1] ||= (...e) => K(l) && K(l)(...e)
|
|
28413
|
-
}, [xs(XT, { text: K(d).undo }, null, 8, ["text"])], 8,
|
|
28418
|
+
}, [xs(XT, { text: K(d).undo }, null, 8, ["text"])], 8, wA)) : Q("", !0)
|
|
28414
28419
|
])) : Q("", !0)
|
|
28415
28420
|
]));
|
|
28416
28421
|
}
|
|
28417
|
-
}), [["__scopeId", "data-v-113939bc"]]),
|
|
28422
|
+
}), [["__scopeId", "data-v-113939bc"]]), EA = {
|
|
28418
28423
|
key: 0,
|
|
28419
28424
|
class: "queued-bar"
|
|
28420
|
-
},
|
|
28425
|
+
}, DA = { class: "queued-head" }, OA = { class: "queued-icon" }, kA = { class: "queued-title" }, AA = { class: "queued-count" }, jA = { class: "queued-idx" }, MA = { class: "queued-text" }, NA = ["title", "onClick"], PA = ["title", "onClick"], FA = /*#__PURE__*/ qT(/* @__PURE__ */ Wi({
|
|
28421
28426
|
__name: "QueuedBar",
|
|
28422
28427
|
setup(e) {
|
|
28423
28428
|
let { chat: t, editQueued: n, icons: r, messages: i } = fw(), { queuedTasks: a, removeQueuedTask: o } = t;
|
|
28424
|
-
return (e, t) => K(a).length ? (Y(), X("div",
|
|
28425
|
-
Z("span",
|
|
28426
|
-
Z("span",
|
|
28427
|
-
Z("span",
|
|
28429
|
+
return (e, t) => K(a).length ? (Y(), X("div", EA, [Z("div", DA, [
|
|
28430
|
+
Z("span", OA, [xs(JT, { icon: K(r).queued }, null, 8, ["icon"])]),
|
|
28431
|
+
Z("span", kA, W(K(i).queuedTitle), 1),
|
|
28432
|
+
Z("span", AA, W(K(a).length), 1)
|
|
28428
28433
|
]), (Y(!0), X(J, null, ga(K(a), (e, t) => (Y(), X("div", {
|
|
28429
28434
|
key: t,
|
|
28430
28435
|
class: "queued-item"
|
|
28431
28436
|
}, [
|
|
28432
|
-
Z("span",
|
|
28433
|
-
Z("span",
|
|
28437
|
+
Z("span", jA, W(t + 1), 1),
|
|
28438
|
+
Z("span", MA, W(e), 1),
|
|
28434
28439
|
Z("button", {
|
|
28435
28440
|
class: "queued-act",
|
|
28436
28441
|
title: K(i).queuedEditTitle,
|
|
28437
28442
|
onClick: (e) => K(n)(t)
|
|
28438
|
-
}, [xs(JT, { icon: K(r).queuedEdit }, null, 8, ["icon"])], 8,
|
|
28443
|
+
}, [xs(JT, { icon: K(r).queuedEdit }, null, 8, ["icon"])], 8, NA),
|
|
28439
28444
|
Z("button", {
|
|
28440
28445
|
class: "queued-act queued-del",
|
|
28441
28446
|
title: K(i).removeQueuedTitle,
|
|
28442
28447
|
onClick: (e) => K(o)(t)
|
|
28443
|
-
}, "✕", 8,
|
|
28448
|
+
}, "✕", 8, PA)
|
|
28444
28449
|
]))), 128))])) : Q("", !0);
|
|
28445
28450
|
}
|
|
28446
|
-
}), [["__scopeId", "data-v-02414fc9"]]),
|
|
28451
|
+
}), [["__scopeId", "data-v-02414fc9"]]), IA = {
|
|
28447
28452
|
key: 0,
|
|
28448
28453
|
class: "approval-bar"
|
|
28449
|
-
},
|
|
28454
|
+
}, LA = { class: "approval-head" }, RA = { class: "approval-title" }, zA = {
|
|
28450
28455
|
key: 0,
|
|
28451
28456
|
class: "approval-question"
|
|
28452
|
-
},
|
|
28457
|
+
}, BA = {
|
|
28453
28458
|
key: 1,
|
|
28454
28459
|
class: "approval-context"
|
|
28455
|
-
},
|
|
28460
|
+
}, VA = {
|
|
28456
28461
|
key: 2,
|
|
28457
28462
|
class: "approval-recommend"
|
|
28458
|
-
},
|
|
28463
|
+
}, HA = {
|
|
28459
28464
|
key: 3,
|
|
28460
28465
|
class: "approval-options"
|
|
28461
|
-
},
|
|
28466
|
+
}, UA = ["onClick"], WA = { class: "approval-actions" }, GA = { class: "approval-head" }, KA = { class: "approval-title" }, qA = {
|
|
28462
28467
|
key: 0,
|
|
28463
28468
|
class: "approval-args"
|
|
28464
|
-
},
|
|
28469
|
+
}, JA = {
|
|
28465
28470
|
key: 1,
|
|
28466
28471
|
class: "approval-plan-context"
|
|
28467
|
-
},
|
|
28472
|
+
}, YA = { class: "approval-actions" }, XA = /*#__PURE__*/ qT(/* @__PURE__ */ Wi({
|
|
28468
28473
|
__name: "ApprovalBar",
|
|
28469
28474
|
setup(e) {
|
|
28470
28475
|
let t = fw(), { pendingApproval: n, resolveApproval: r } = t.chat, i = t.messages, a = t.planConfirmation, o = /* @__PURE__ */ Mn(!1);
|
|
@@ -28484,17 +28489,17 @@ var Wk = ["innerHTML"], Gk = /* @__PURE__ */ Wi({
|
|
|
28484
28489
|
return String(e);
|
|
28485
28490
|
}
|
|
28486
28491
|
});
|
|
28487
|
-
return (e, u) => K(n) ? (Y(), X("div",
|
|
28488
|
-
Z("div",
|
|
28489
|
-
K(n).args?.question ? (Y(), X("div",
|
|
28490
|
-
K(n).args?.context ? (Y(), X("div",
|
|
28491
|
-
K(n).args?.recommendation ? (Y(), X("div",
|
|
28492
|
-
c.value.length ? (Y(), X("div",
|
|
28492
|
+
return (e, u) => K(n) ? (Y(), X("div", IA, [s.value ? (Y(), X(J, { key: 0 }, [
|
|
28493
|
+
Z("div", LA, [u[5] ||= Z("span", { class: "approval-icon" }, "❓", -1), Z("span", RA, W(K(i).humanConfirmTitle), 1)]),
|
|
28494
|
+
K(n).args?.question ? (Y(), X("div", zA, W(K(n).args.question), 1)) : Q("", !0),
|
|
28495
|
+
K(n).args?.context ? (Y(), X("div", BA, W(K(n).args.context), 1)) : Q("", !0),
|
|
28496
|
+
K(n).args?.recommendation ? (Y(), X("div", VA, [xs(JT, { icon: K(t).icons.recommend }, null, 8, ["icon"]), Es(W(K(i).recommendPrefix) + W(K(n).args.recommendation), 1)])) : Q("", !0),
|
|
28497
|
+
c.value.length ? (Y(), X("div", HA, [(Y(!0), X(J, null, ga(c.value, (e) => (Y(), X("button", {
|
|
28493
28498
|
key: e,
|
|
28494
28499
|
class: "approval-opt",
|
|
28495
28500
|
onClick: (t) => K(r)(e)
|
|
28496
|
-
}, W(e), 9,
|
|
28497
|
-
Z("div",
|
|
28501
|
+
}, W(e), 9, UA))), 128))])) : Q("", !0),
|
|
28502
|
+
Z("div", WA, [Z("button", {
|
|
28498
28503
|
class: "approval-deny",
|
|
28499
28504
|
onClick: u[0] ||= (e) => K(r)(!1)
|
|
28500
28505
|
}, [xs(XT, { text: K(i).deny }, null, 8, ["text"])]), c.value.length ? Q("", !0) : (Y(), X("button", {
|
|
@@ -28503,18 +28508,18 @@ var Wk = ["innerHTML"], Gk = /* @__PURE__ */ Wi({
|
|
|
28503
28508
|
onClick: u[1] ||= (e) => K(r)(!0)
|
|
28504
28509
|
}, [xs(XT, { text: K(i).approve }, null, 8, ["text"])]))])
|
|
28505
28510
|
], 64)) : (Y(), X(J, { key: 1 }, [
|
|
28506
|
-
Z("div",
|
|
28511
|
+
Z("div", GA, [
|
|
28507
28512
|
u[6] ||= Z("span", { class: "approval-icon" }, "✋", -1),
|
|
28508
|
-
Z("span",
|
|
28513
|
+
Z("span", KA, [Es(W(K(i).toolConfirmPrefix), 1), Z("code", null, W(K(n).toolName), 1)]),
|
|
28509
28514
|
l.value ? (Y(), X("button", {
|
|
28510
28515
|
key: 0,
|
|
28511
28516
|
class: "approval-toggle",
|
|
28512
28517
|
onClick: u[2] ||= (e) => o.value = !o.value
|
|
28513
28518
|
}, W(o.value ? K(i).collapseArgs : K(i).viewArgs) + W(o.value ? " ▴" : " ▾"), 1)) : Q("", !0)
|
|
28514
28519
|
]),
|
|
28515
|
-
l.value && o.value ? (Y(), X("pre",
|
|
28516
|
-
K(a) ? (Y(), X("div",
|
|
28517
|
-
Z("div",
|
|
28520
|
+
l.value && o.value ? (Y(), X("pre", qA, W(l.value), 1)) : Q("", !0),
|
|
28521
|
+
K(a) ? (Y(), X("div", JA, [xs(JT, { icon: K(t).icons.recommend }, null, 8, ["icon"]), Es(W(K(i).planConfirmedPrefix) + W(K(a).choice) + W(K(i).planConfirmedSuffix), 1)])) : Q("", !0),
|
|
28522
|
+
Z("div", YA, [Z("button", {
|
|
28518
28523
|
class: "approval-deny",
|
|
28519
28524
|
onClick: u[3] ||= (e) => K(r)(!1)
|
|
28520
28525
|
}, [xs(XT, { text: K(i).deny }, null, 8, ["text"])]), Z("button", {
|
|
@@ -28523,13 +28528,13 @@ var Wk = ["innerHTML"], Gk = /* @__PURE__ */ Wi({
|
|
|
28523
28528
|
}, [xs(XT, { text: K(i).approve }, null, 8, ["text"])])])
|
|
28524
28529
|
], 64))])) : Q("", !0);
|
|
28525
28530
|
}
|
|
28526
|
-
}), [["__scopeId", "data-v-4b13623e"]]),
|
|
28531
|
+
}), [["__scopeId", "data-v-4b13623e"]]), ZA = {
|
|
28527
28532
|
key: 0,
|
|
28528
28533
|
class: "conflict-bar"
|
|
28529
|
-
},
|
|
28534
|
+
}, QA = { class: "conflict-head" }, $A = { class: "conflict-icon" }, ej = { class: "conflict-title" }, tj = { class: "conflict-detail" }, nj = {
|
|
28530
28535
|
key: 0,
|
|
28531
28536
|
class: "conflict-diff"
|
|
28532
|
-
},
|
|
28537
|
+
}, rj = { class: "conflict-diff-col" }, ij = { class: "conflict-diff-label" }, aj = { class: "conflict-diff-pre" }, oj = { class: "conflict-diff-col" }, sj = { class: "conflict-diff-label" }, cj = { class: "conflict-diff-pre" }, lj = { class: "conflict-actions" }, uj = ["title"], dj = ["title"], fj = ["title"], pj = /*#__PURE__*/ qT(/* @__PURE__ */ Wi({
|
|
28533
28538
|
__name: "ConflictBar",
|
|
28534
28539
|
props: {
|
|
28535
28540
|
pendingConflict: {},
|
|
@@ -28561,55 +28566,55 @@ var Wk = ["innerHTML"], Gk = /* @__PURE__ */ Wi({
|
|
|
28561
28566
|
return String(e);
|
|
28562
28567
|
}
|
|
28563
28568
|
});
|
|
28564
|
-
return (t, a) => e.pendingConflict ? (Y(), X("div",
|
|
28565
|
-
Z("div",
|
|
28569
|
+
return (t, a) => e.pendingConflict ? (Y(), X("div", ZA, [
|
|
28570
|
+
Z("div", QA, [Z("span", $A, [xs(JT, { icon: e.icons.conflict }, null, 8, ["icon"])]), Z("span", ej, [
|
|
28566
28571
|
Es(W(e.messages.conflictTitlePrefix), 1),
|
|
28567
28572
|
Z("code", null, W(e.pendingConflict.path), 1),
|
|
28568
28573
|
Es(W(e.messages.conflictTitleSuffix), 1)
|
|
28569
28574
|
])]),
|
|
28570
|
-
Z("div",
|
|
28575
|
+
Z("div", tj, W(e.messages.conflictDetailTemplate.replace("{op}", e.pendingConflict.op === "delete" ? e.messages.conflictOpDelete : e.messages.conflictOpWrite)), 1),
|
|
28571
28576
|
Z("button", {
|
|
28572
28577
|
class: "conflict-toggle",
|
|
28573
28578
|
onClick: a[0] ||= (e) => n.value = !n.value
|
|
28574
28579
|
}, W(n.value ? e.messages.collapseDiff : e.messages.viewDiff) + W(n.value ? " ▴" : " ▾"), 1),
|
|
28575
|
-
n.value ? (Y(), X("div",
|
|
28576
|
-
Z("div",
|
|
28580
|
+
n.value ? (Y(), X("div", nj, [Z("div", rj, [Z("div", ij, W(e.messages.agentValueLabel), 1), Z("pre", aj, W(r.value || e.messages.deleteNoValue), 1)]), Z("div", oj, [Z("div", sj, W(e.messages.currentValueLabel), 1), Z("pre", cj, W(i.value), 1)])])) : Q("", !0),
|
|
28581
|
+
Z("div", lj, [
|
|
28577
28582
|
Z("button", {
|
|
28578
28583
|
class: "conflict-keep",
|
|
28579
28584
|
onClick: a[1] ||= (t) => e.onResolve?.("keep_external"),
|
|
28580
28585
|
title: e.messages.keepExternalTitle
|
|
28581
|
-
}, [xs(XT, { text: e.messages.keepExternal }, null, 8, ["text"])], 8,
|
|
28586
|
+
}, [xs(XT, { text: e.messages.keepExternal }, null, 8, ["text"])], 8, uj),
|
|
28582
28587
|
Z("button", {
|
|
28583
28588
|
class: "conflict-overwrite",
|
|
28584
28589
|
onClick: a[2] ||= (t) => e.onResolve?.("overwrite"),
|
|
28585
28590
|
title: e.messages.overwriteTitle
|
|
28586
|
-
}, [xs(XT, { text: e.messages.overwrite }, null, 8, ["text"])], 8,
|
|
28591
|
+
}, [xs(XT, { text: e.messages.overwrite }, null, 8, ["text"])], 8, dj),
|
|
28587
28592
|
Z("button", {
|
|
28588
28593
|
class: "conflict-restore",
|
|
28589
28594
|
onClick: a[3] ||= (t) => e.onResolve?.("restore"),
|
|
28590
28595
|
title: e.messages.restoreTitle
|
|
28591
|
-
}, [xs(XT, { text: e.messages.restore }, null, 8, ["text"])], 8,
|
|
28596
|
+
}, [xs(XT, { text: e.messages.restore }, null, 8, ["text"])], 8, fj)
|
|
28592
28597
|
])
|
|
28593
28598
|
])) : Q("", !0);
|
|
28594
28599
|
}
|
|
28595
|
-
}), [["__scopeId", "data-v-36dda58c"]]),
|
|
28600
|
+
}), [["__scopeId", "data-v-36dda58c"]]), mj = { class: "chat-footer" }, hj = ["title"], gj = {
|
|
28596
28601
|
key: 0,
|
|
28597
28602
|
class: "drop-hint"
|
|
28598
|
-
},
|
|
28603
|
+
}, _j = {
|
|
28599
28604
|
key: 1,
|
|
28600
28605
|
class: "chip-stack"
|
|
28601
|
-
},
|
|
28606
|
+
}, vj = {
|
|
28602
28607
|
key: 0,
|
|
28603
28608
|
class: "focus-chips"
|
|
28604
|
-
},
|
|
28609
|
+
}, yj = ["title", "onClick"], bj = { class: "focus-chip-icon" }, xj = { class: "focus-chip-path" }, Sj = ["title", "onClick"], Cj = {
|
|
28605
28610
|
key: 1,
|
|
28606
28611
|
class: "img-chips",
|
|
28607
28612
|
"data-test": "img-chips"
|
|
28608
|
-
},
|
|
28613
|
+
}, wj = ["title"], Tj = ["src", "alt"], Ej = ["onClick"], Dj = {
|
|
28609
28614
|
key: 2,
|
|
28610
28615
|
class: "img-error",
|
|
28611
28616
|
"data-test": "img-error"
|
|
28612
|
-
},
|
|
28617
|
+
}, Oj = ["placeholder", "rows"], kj = { class: "input-actions" }, Aj = { class: "send-hint" }, jj = ["title"], Mj = {
|
|
28613
28618
|
key: 1,
|
|
28614
28619
|
width: "15",
|
|
28615
28620
|
height: "15",
|
|
@@ -28619,13 +28624,13 @@ var Wk = ["innerHTML"], Gk = /* @__PURE__ */ Wi({
|
|
|
28619
28624
|
"stroke-width": "2",
|
|
28620
28625
|
"stroke-linecap": "round",
|
|
28621
28626
|
"stroke-linejoin": "round"
|
|
28622
|
-
},
|
|
28627
|
+
}, Nj = ["disabled", "title"], Pj = {
|
|
28623
28628
|
key: 0,
|
|
28624
28629
|
width: "16",
|
|
28625
28630
|
height: "16",
|
|
28626
28631
|
viewBox: "0 0 24 24",
|
|
28627
28632
|
fill: "currentColor"
|
|
28628
|
-
},
|
|
28633
|
+
}, Fj = {
|
|
28629
28634
|
key: 2,
|
|
28630
28635
|
width: "18",
|
|
28631
28636
|
height: "18",
|
|
@@ -28633,7 +28638,7 @@ var Wk = ["innerHTML"], Gk = /* @__PURE__ */ Wi({
|
|
|
28633
28638
|
fill: "none",
|
|
28634
28639
|
stroke: "currentColor",
|
|
28635
28640
|
"stroke-width": "2"
|
|
28636
|
-
},
|
|
28641
|
+
}, Ij = /*#__PURE__*/ qT(/* @__PURE__ */ Wi({
|
|
28637
28642
|
__name: "ChatInput",
|
|
28638
28643
|
props: {
|
|
28639
28644
|
placeholder: {},
|
|
@@ -28657,36 +28662,36 @@ var Wk = ["innerHTML"], Gk = /* @__PURE__ */ Wi({
|
|
|
28657
28662
|
}
|
|
28658
28663
|
n.length && h(n);
|
|
28659
28664
|
};
|
|
28660
|
-
return (t, h) => (Y(), X("div",
|
|
28665
|
+
return (t, h) => (Y(), X("div", mj, [K(a) ? (Y(), X("button", {
|
|
28661
28666
|
key: 0,
|
|
28662
28667
|
class: "undo-foot-btn",
|
|
28663
28668
|
title: K(d).undoTitle,
|
|
28664
28669
|
onClick: h[0] ||= (...e) => K(o) && K(o)(...e)
|
|
28665
|
-
}, W(K(d).undo), 9,
|
|
28670
|
+
}, W(K(d).undo), 9, hj)) : Q("", !0), Z("div", {
|
|
28666
28671
|
class: Be(["chat-input-wrap", { "drag-over": b.value }]),
|
|
28667
28672
|
onDragover: h[4] ||= Ol((e) => b.value = !0, ["prevent"]),
|
|
28668
28673
|
onDragleave: h[5] ||= (e) => b.value = !1,
|
|
28669
28674
|
onDrop: Ol(C, ["prevent"])
|
|
28670
28675
|
}, [
|
|
28671
|
-
b.value ? (Y(), X("div",
|
|
28672
|
-
K(s).length || K(m).length || K(_) ? (Y(), X("div",
|
|
28673
|
-
K(s).length ? (Y(), X("div",
|
|
28676
|
+
b.value ? (Y(), X("div", gj, W(K(d).imageDropHint), 1)) : Q("", !0),
|
|
28677
|
+
K(s).length || K(m).length || K(_) ? (Y(), X("div", _j, [
|
|
28678
|
+
K(s).length ? (Y(), X("div", vj, [(Y(!0), X(J, null, ga(K(s), (e) => (Y(), X("span", {
|
|
28674
28679
|
key: e.path,
|
|
28675
28680
|
class: "focus-chip",
|
|
28676
28681
|
title: K(d).focusChipTitlePrefix + e.path + K(d).focusChipTitleHint,
|
|
28677
28682
|
onClick: (t) => K(l)(e)
|
|
28678
28683
|
}, [
|
|
28679
|
-
Z("span",
|
|
28680
|
-
Z("code",
|
|
28684
|
+
Z("span", bj, [xs(JT, { icon: K(u).focus }, null, 8, ["icon"])]),
|
|
28685
|
+
Z("code", xj, W(e.path), 1),
|
|
28681
28686
|
Z("button", {
|
|
28682
28687
|
type: "button",
|
|
28683
28688
|
class: "focus-chip-x",
|
|
28684
28689
|
"data-test": "focus-clear",
|
|
28685
28690
|
title: K(d).removeFocus,
|
|
28686
28691
|
onClick: Ol((t) => K(c)(e.path), ["stop"])
|
|
28687
|
-
}, "✕", 8,
|
|
28688
|
-
], 8,
|
|
28689
|
-
K(m).length ? (Y(), X("div",
|
|
28692
|
+
}, "✕", 8, Sj)
|
|
28693
|
+
], 8, yj))), 128))])) : Q("", !0),
|
|
28694
|
+
K(m).length ? (Y(), X("div", Cj, [(Y(!0), X(J, null, ga(K(m), (e) => (Y(), X("span", {
|
|
28690
28695
|
key: e.id,
|
|
28691
28696
|
class: "img-chip",
|
|
28692
28697
|
title: e.name || K(d).imageAlt
|
|
@@ -28694,13 +28699,13 @@ var Wk = ["innerHTML"], Gk = /* @__PURE__ */ Wi({
|
|
|
28694
28699
|
class: "img-chip-thumb",
|
|
28695
28700
|
src: e.dataUri,
|
|
28696
28701
|
alt: e.name || K(d).imageAlt
|
|
28697
|
-
}, null, 8,
|
|
28702
|
+
}, null, 8, Tj), Z("button", {
|
|
28698
28703
|
type: "button",
|
|
28699
28704
|
class: "img-chip-x",
|
|
28700
28705
|
"data-test": "img-chip-x",
|
|
28701
28706
|
onClick: (t) => K(g)(e.id)
|
|
28702
|
-
}, "✕", 8,
|
|
28703
|
-
K(_) ? (Y(), X("div",
|
|
28707
|
+
}, "✕", 8, Ej)], 8, wj))), 128))])) : Q("", !0),
|
|
28708
|
+
K(_) ? (Y(), X("div", Dj, W(K(_)), 1)) : Q("", !0)
|
|
28704
28709
|
])) : Q("", !0),
|
|
28705
28710
|
ai(Z("textarea", {
|
|
28706
28711
|
"onUpdate:modelValue": h[1] ||= (e) => /* @__PURE__ */ jn(n) ? n.value = e : null,
|
|
@@ -28709,9 +28714,9 @@ var Wk = ["innerHTML"], Gk = /* @__PURE__ */ Wi({
|
|
|
28709
28714
|
rows: e.inputRows,
|
|
28710
28715
|
onKeydown: h[2] ||= (...e) => K(i) && K(i)(...e),
|
|
28711
28716
|
onPaste: w
|
|
28712
|
-
}, null, 40,
|
|
28713
|
-
Z("div",
|
|
28714
|
-
Z("span",
|
|
28717
|
+
}, null, 40, Oj), [[Tl, K(n)]]),
|
|
28718
|
+
Z("div", kj, [
|
|
28719
|
+
Z("span", Aj, W(K(d).sendHint), 1),
|
|
28715
28720
|
Z("button", {
|
|
28716
28721
|
class: "attach-btn",
|
|
28717
28722
|
title: K(d).attachImageTitle,
|
|
@@ -28720,7 +28725,7 @@ var Wk = ["innerHTML"], Gk = /* @__PURE__ */ Wi({
|
|
|
28720
28725
|
}, [K(u).attachImage ? (Y(), ms(JT, {
|
|
28721
28726
|
key: 0,
|
|
28722
28727
|
icon: K(u).attachImage
|
|
28723
|
-
}, null, 8, ["icon"])) : (Y(), X("svg",
|
|
28728
|
+
}, null, 8, ["icon"])) : (Y(), X("svg", Mj, [...h[6] ||= [Z("path", { d: "M21.44 11.05l-9.19 9.19a6 6 0 0 1-8.49-8.49l9.19-9.19a4 4 0 0 1 5.66 5.66l-9.2 9.19a2 2 0 0 1-2.83-2.83l8.49-8.48" }, null, -1)]]))], 8, jj),
|
|
28724
28729
|
Z("input", {
|
|
28725
28730
|
ref_key: "fileInput",
|
|
28726
28731
|
ref: y,
|
|
@@ -28736,7 +28741,7 @@ var Wk = ["innerHTML"], Gk = /* @__PURE__ */ Wi({
|
|
|
28736
28741
|
disabled: !K(f).loading && !K(n).trim() && !K(m).length && !K(v),
|
|
28737
28742
|
title: K(f).loading ? K(d).stopTitle : K(d).sendTitle,
|
|
28738
28743
|
onClick: h[3] ||= (e) => K(f).loading ? K(p)() : K(r)()
|
|
28739
|
-
}, [K(f).loading ? (Y(), X("svg",
|
|
28744
|
+
}, [K(f).loading ? (Y(), X("svg", Pj, [...h[7] ||= [Z("rect", {
|
|
28740
28745
|
x: "6",
|
|
28741
28746
|
y: "6",
|
|
28742
28747
|
width: "12",
|
|
@@ -28745,187 +28750,187 @@ var Wk = ["innerHTML"], Gk = /* @__PURE__ */ Wi({
|
|
|
28745
28750
|
}, null, -1)]])) : K(u).send ? (Y(), ms(JT, {
|
|
28746
28751
|
key: 1,
|
|
28747
28752
|
icon: K(u).send
|
|
28748
|
-
}, null, 8, ["icon"])) : (Y(), X("svg",
|
|
28753
|
+
}, null, 8, ["icon"])) : (Y(), X("svg", Fj, [...h[8] ||= [Z("line", {
|
|
28749
28754
|
x1: "22",
|
|
28750
28755
|
y1: "2",
|
|
28751
28756
|
x2: "11",
|
|
28752
28757
|
y2: "13"
|
|
28753
|
-
}, null, -1), Z("polygon", { points: "22 2 15 22 11 13 2 9 22 2" }, null, -1)]]))], 10,
|
|
28758
|
+
}, null, -1), Z("polygon", { points: "22 2 15 22 11 13 2 9 22 2" }, null, -1)]]))], 10, Nj)
|
|
28754
28759
|
])
|
|
28755
28760
|
], 34)]));
|
|
28756
28761
|
}
|
|
28757
|
-
}), [["__scopeId", "data-v-5ceb07ef"]]),
|
|
28762
|
+
}), [["__scopeId", "data-v-5ceb07ef"]]), Lj = {
|
|
28758
28763
|
key: 0,
|
|
28759
28764
|
class: "debug-drawer"
|
|
28760
|
-
},
|
|
28765
|
+
}, Rj = { class: "drawer-header" }, zj = { class: "tab-group" }, Bj = { class: "header-actions" }, Vj = ["title"], Hj = ["title"], Uj = ["title"], Wj = {
|
|
28761
28766
|
key: 0,
|
|
28762
28767
|
class: "drawer-filters"
|
|
28763
|
-
},
|
|
28768
|
+
}, Gj = ["onClick"], Kj = { class: "chip-count" }, qj = { class: "chip-count" }, Jj = {
|
|
28764
28769
|
key: 0,
|
|
28765
28770
|
class: "context-panel"
|
|
28766
|
-
},
|
|
28771
|
+
}, Yj = {
|
|
28767
28772
|
key: 0,
|
|
28768
28773
|
class: "trace-empty"
|
|
28769
|
-
},
|
|
28774
|
+
}, Xj = { class: "ctx-overview" }, Zj = { class: "ctx-occupancy" }, Qj = ["title"], $j = ["title"], eM = { class: "ctx-pct" }, tM = { class: "ctx-kv-row" }, nM = { class: "ctx-kv" }, rM = {
|
|
28770
28775
|
key: 0,
|
|
28771
28776
|
class: "ctx-kv"
|
|
28772
|
-
},
|
|
28777
|
+
}, iM = {
|
|
28773
28778
|
key: 1,
|
|
28774
28779
|
class: "ctx-kv"
|
|
28775
|
-
},
|
|
28780
|
+
}, aM = { class: "ctx-section-title" }, oM = ["title"], sM = { class: "ctx-cat-bar" }, cM = { class: "ctx-cat-tokens" }, lM = {
|
|
28776
28781
|
key: 0,
|
|
28777
28782
|
class: "ctx-compression"
|
|
28778
|
-
},
|
|
28783
|
+
}, uM = { class: "ctx-section-title" }, dM = { class: "ctx-kv-row" }, fM = { class: "ctx-kv" }, pM = { class: "ctx-kv" }, mM = { class: "ctx-kv" }, hM = {
|
|
28779
28784
|
key: 0,
|
|
28780
28785
|
class: "ctx-kv"
|
|
28781
|
-
},
|
|
28786
|
+
}, gM = {
|
|
28782
28787
|
key: 1,
|
|
28783
28788
|
class: "subagent-panel"
|
|
28784
|
-
},
|
|
28789
|
+
}, _M = {
|
|
28785
28790
|
key: 0,
|
|
28786
28791
|
class: "sub-section"
|
|
28787
|
-
},
|
|
28792
|
+
}, vM = { class: "sub-section-title" }, yM = {
|
|
28788
28793
|
key: 1,
|
|
28789
28794
|
class: "trace-empty"
|
|
28790
|
-
},
|
|
28795
|
+
}, bM = {
|
|
28791
28796
|
key: 0,
|
|
28792
28797
|
class: "sub-section"
|
|
28793
|
-
},
|
|
28798
|
+
}, xM = { class: "sub-section-title" }, SM = { class: "sub-head" }, CM = { class: "sub-label" }, wM = { class: "sub-steps-badge" }, TM = { class: "sub-task" }, EM = {
|
|
28794
28799
|
key: 1,
|
|
28795
28800
|
class: "sub-section"
|
|
28796
|
-
},
|
|
28801
|
+
}, DM = { class: "sub-section-title" }, OM = { class: "sub-head" }, kM = { class: "sub-label" }, AM = {
|
|
28797
28802
|
key: 0,
|
|
28798
28803
|
class: "sub-dur"
|
|
28799
|
-
},
|
|
28804
|
+
}, jM = ["onClick"], MM = { class: "sub-task" }, NM = {
|
|
28800
28805
|
key: 0,
|
|
28801
28806
|
class: "sub-result"
|
|
28802
|
-
},
|
|
28807
|
+
}, PM = {
|
|
28803
28808
|
key: 1,
|
|
28804
28809
|
class: "sub-steps-list"
|
|
28805
|
-
},
|
|
28810
|
+
}, FM = { class: "sub-step-kind" }, IM = { class: "sub-step-name" }, LM = { class: "sub-step-ts" }, RM = {
|
|
28806
28811
|
key: 0,
|
|
28807
28812
|
class: "empty"
|
|
28808
|
-
},
|
|
28813
|
+
}, zM = ["onClick"], BM = { class: "log-group-title" }, VM = { class: "log-group-meta" }, HM = {
|
|
28809
28814
|
key: 0,
|
|
28810
28815
|
class: "lg-badge"
|
|
28811
|
-
},
|
|
28816
|
+
}, UM = {
|
|
28812
28817
|
key: 1,
|
|
28813
28818
|
class: "lg-badge"
|
|
28814
|
-
},
|
|
28819
|
+
}, WM = {
|
|
28815
28820
|
key: 2,
|
|
28816
28821
|
class: "lg-badge err"
|
|
28817
|
-
},
|
|
28822
|
+
}, GM = { class: "log-group-body" }, KM = { class: "log-head" }, qM = {
|
|
28818
28823
|
key: 0,
|
|
28819
28824
|
class: "log-source"
|
|
28820
|
-
},
|
|
28825
|
+
}, JM = { class: "log-time" }, YM = { class: "log-body" }, XM = { class: "kv-grid" }, ZM = { class: "kv" }, QM = { class: "k" }, $M = { class: "v" }, eN = { class: "kv" }, tN = { class: "k" }, nN = { class: "v" }, rN = { class: "kv" }, iN = { class: "v" }, aN = { class: "kv" }, oN = { class: "k" }, sN = { class: "v" }, cN = { class: "section-label" }, lN = { class: "chip-row" }, uN = { class: "section-label" }, dN = { class: "msg-list" }, fN = { class: "msg-text" }, pN = { class: "badge-row" }, mN = { class: "badge" }, hN = {
|
|
28821
28826
|
key: 0,
|
|
28822
28827
|
class: "badge muted"
|
|
28823
|
-
},
|
|
28828
|
+
}, gN = { class: "badge muted" }, _N = {
|
|
28824
28829
|
key: 1,
|
|
28825
28830
|
class: "badge muted"
|
|
28826
|
-
},
|
|
28831
|
+
}, vN = ["onClick"], yN = ["title", "onClick"], bN = ["onClick"], xN = ["title", "onClick"], SN = { class: "msg-detail" }, CN = {
|
|
28827
28832
|
key: 0,
|
|
28828
28833
|
class: "msg-text"
|
|
28829
|
-
},
|
|
28834
|
+
}, wN = { class: "tc-inline-name" }, TN = { class: "tc-inline-args" }, EN = {
|
|
28830
28835
|
key: 1,
|
|
28831
28836
|
class: "tc-id"
|
|
28832
|
-
},
|
|
28837
|
+
}, DN = {
|
|
28833
28838
|
key: 1,
|
|
28834
28839
|
class: "log-raw"
|
|
28835
|
-
},
|
|
28840
|
+
}, ON = { class: "badge-row" }, kN = { class: "badge" }, AN = {
|
|
28836
28841
|
key: 0,
|
|
28837
28842
|
class: "badge warn"
|
|
28838
|
-
},
|
|
28843
|
+
}, jN = {
|
|
28839
28844
|
key: 0,
|
|
28840
28845
|
class: "resp-content"
|
|
28841
|
-
},
|
|
28846
|
+
}, MN = {
|
|
28842
28847
|
key: 1,
|
|
28843
28848
|
class: "tc-list"
|
|
28844
|
-
},
|
|
28849
|
+
}, NN = { class: "tc-name" }, PN = { class: "tc-args" }, FN = {
|
|
28845
28850
|
key: 2,
|
|
28846
28851
|
class: "usage-row"
|
|
28847
|
-
},
|
|
28852
|
+
}, IN = { class: "usage" }, LN = { class: "usage" }, RN = { class: "usage" }, zN = {
|
|
28848
28853
|
key: 0,
|
|
28849
28854
|
class: "usage"
|
|
28850
|
-
},
|
|
28855
|
+
}, BN = { class: "tc-name" }, VN = {
|
|
28851
28856
|
key: 0,
|
|
28852
28857
|
class: "tc-dur"
|
|
28853
|
-
},
|
|
28858
|
+
}, HN = ["title", "onClick"], UN = { class: "tc-args" }, WN = { class: "tc-result-sep" }, GN = { class: "tc-args tc-result" }, KN = {
|
|
28854
28859
|
key: 1,
|
|
28855
28860
|
class: "tc-card inline"
|
|
28856
|
-
},
|
|
28861
|
+
}, qN = { class: "tc-name" }, JN = {
|
|
28857
28862
|
key: 0,
|
|
28858
28863
|
class: "tc-dur running"
|
|
28859
|
-
},
|
|
28864
|
+
}, YN = { class: "tc-args" }, XN = {
|
|
28860
28865
|
key: 4,
|
|
28861
28866
|
class: "err-box"
|
|
28862
|
-
},
|
|
28867
|
+
}, ZN = { class: "log-footer" }, QN = ["onClick"], $N = ["onClick"], eP = {
|
|
28863
28868
|
key: 0,
|
|
28864
28869
|
class: "log-raw"
|
|
28865
|
-
},
|
|
28870
|
+
}, tP = {
|
|
28866
28871
|
key: 3,
|
|
28867
28872
|
class: "info-body"
|
|
28868
|
-
},
|
|
28873
|
+
}, nP = {
|
|
28869
28874
|
key: 0,
|
|
28870
28875
|
class: "empty"
|
|
28871
|
-
},
|
|
28876
|
+
}, rP = { class: "info-section" }, iP = { class: "info-title" }, aP = { class: "kv-grid" }, oP = { class: "kv" }, sP = { class: "v" }, cP = { class: "kv" }, lP = { class: "k" }, uP = { class: "v" }, dP = { class: "kv" }, fP = { class: "k" }, pP = { class: "v" }, mP = { class: "kv" }, hP = { class: "k" }, gP = { class: "v" }, _P = {
|
|
28872
28877
|
class: "kv",
|
|
28873
28878
|
style: { "margin-top": "6px" }
|
|
28874
|
-
},
|
|
28879
|
+
}, vP = { class: "k" }, yP = {
|
|
28875
28880
|
class: "v",
|
|
28876
28881
|
style: { "font-size": "11px" }
|
|
28877
|
-
},
|
|
28882
|
+
}, bP = { class: "info-section" }, xP = { class: "info-title" }, SP = { class: "info-name" }, CP = { class: "info-desc" }, wP = {
|
|
28878
28883
|
key: 0,
|
|
28879
28884
|
class: "info-section"
|
|
28880
|
-
},
|
|
28885
|
+
}, TP = { class: "info-title" }, EP = { class: "info-hint" }, DP = ["onClick"], OP = { class: "info-desc" }, kP = {
|
|
28881
28886
|
key: 0,
|
|
28882
28887
|
class: "skill-content"
|
|
28883
|
-
},
|
|
28888
|
+
}, AP = {
|
|
28884
28889
|
key: 0,
|
|
28885
28890
|
class: "skill-loading"
|
|
28886
|
-
},
|
|
28891
|
+
}, jP = {
|
|
28887
28892
|
key: 1,
|
|
28888
28893
|
class: "skill-error"
|
|
28889
|
-
},
|
|
28894
|
+
}, MP = {
|
|
28890
28895
|
key: 2,
|
|
28891
28896
|
class: "skill-pre"
|
|
28892
|
-
},
|
|
28897
|
+
}, NP = {
|
|
28893
28898
|
key: 1,
|
|
28894
28899
|
class: "info-section"
|
|
28895
|
-
},
|
|
28900
|
+
}, PP = { class: "info-title" }, FP = { class: "info-item" }, IP = { class: "info-name" }, LP = { class: "info-desc" }, RP = { class: "info-section" }, zP = { class: "info-title" }, BP = { class: "kv-grid" }, VP = { class: "kv" }, HP = { class: "k" }, UP = { class: "v" }, WP = { class: "kv" }, GP = { class: "k" }, KP = { class: "v" }, qP = { class: "kv" }, JP = { class: "k" }, YP = { class: "v" }, XP = { class: "kv" }, ZP = { class: "k" }, QP = {
|
|
28896
28901
|
class: "v",
|
|
28897
28902
|
style: { "font-size": "11px" }
|
|
28898
|
-
},
|
|
28903
|
+
}, $P = {
|
|
28899
28904
|
key: 2,
|
|
28900
28905
|
class: "info-section"
|
|
28901
|
-
},
|
|
28906
|
+
}, eF = { class: "info-title" }, tF = { class: "info-name" }, nF = { class: "src-tag mcp" }, rF = { class: "info-desc" }, iF = {
|
|
28902
28907
|
key: 3,
|
|
28903
28908
|
class: "info-section"
|
|
28904
|
-
},
|
|
28909
|
+
}, aF = { class: "info-title" }, oF = { class: "kv-grid" }, sF = { class: "kv" }, cF = { class: "k" }, lF = { class: "v" }, uF = { class: "kv" }, dF = { class: "k" }, fF = { class: "v" }, pF = { class: "kv" }, mF = { class: "k" }, hF = { class: "v" }, gF = {
|
|
28905
28910
|
key: 0,
|
|
28906
28911
|
class: "kv"
|
|
28907
|
-
},
|
|
28912
|
+
}, _F = { class: "k" }, vF = {
|
|
28908
28913
|
class: "v",
|
|
28909
28914
|
style: { "font-size": "11px" }
|
|
28910
|
-
},
|
|
28915
|
+
}, yF = {
|
|
28911
28916
|
key: 4,
|
|
28912
28917
|
class: "info-section"
|
|
28913
|
-
},
|
|
28918
|
+
}, bF = { class: "info-title" }, xF = {
|
|
28914
28919
|
key: 5,
|
|
28915
28920
|
class: "info-section"
|
|
28916
|
-
},
|
|
28921
|
+
}, SF = { class: "info-title" }, CF = { class: "info-pre" }, wF = {
|
|
28917
28922
|
key: 6,
|
|
28918
28923
|
class: "info-section"
|
|
28919
|
-
},
|
|
28924
|
+
}, TF = { class: "info-title" }, EF = { class: "info-kv" }, DF = { class: "kv" }, OF = { class: "k" }, kF = { class: "v" }, AF = { class: "kv" }, jF = { class: "k" }, MF = { class: "v" }, NF = { class: "kv" }, PF = { class: "k" }, FF = { class: "v" }, IF = { class: "kv" }, LF = { class: "k" }, RF = { class: "v" }, zF = { class: "kv" }, BF = { class: "k" }, VF = {
|
|
28920
28925
|
class: "v",
|
|
28921
28926
|
style: { "font-size": "11px" }
|
|
28922
|
-
},
|
|
28927
|
+
}, HF = {
|
|
28923
28928
|
key: 0,
|
|
28924
28929
|
class: "kv"
|
|
28925
|
-
},
|
|
28930
|
+
}, UF = { class: "k" }, WF = {
|
|
28926
28931
|
class: "v",
|
|
28927
28932
|
style: { "font-size": "11px" }
|
|
28928
|
-
},
|
|
28933
|
+
}, GF = 400, KF = /*#__PURE__*/ qT(/* @__PURE__ */ Wi({
|
|
28929
28934
|
__name: "DebugDrawer",
|
|
28930
28935
|
props: {
|
|
28931
28936
|
logs: { default: () => [] },
|
|
@@ -29329,8 +29334,8 @@ var Wk = ["innerHTML"], Gk = /* @__PURE__ */ Wi({
|
|
|
29329
29334
|
return `${e.windowRatio == null ? `keepRounds=${e.keepRounds ?? "?"}` : `windowRatio=${e.windowRatio}`} · ${e.summarize.mode}${y.value.debugSummaryMode} · ${y.value.debugCtxRecalled}${e.recallTopK ?? "?"}${e.reason ? " · " + e.reason : ""}`;
|
|
29330
29335
|
}
|
|
29331
29336
|
return (t, n) => (Y(), ms(Ei, { to: "body" }, [xs(Tc, { name: "drawer" }, {
|
|
29332
|
-
default: ri(() => [e.visible ? (Y(), X("div",
|
|
29333
|
-
Z("div",
|
|
29337
|
+
default: ri(() => [e.visible ? (Y(), X("div", Lj, [Z("div", { class: Be(["drawer-panel", { "cs-theme-dark": e.csTheme === "dark" }]) }, [
|
|
29338
|
+
Z("div", Rj, [Z("div", zj, [
|
|
29334
29339
|
Z("button", {
|
|
29335
29340
|
class: Be(["tab-btn", { active: ce.value === "logs" }]),
|
|
29336
29341
|
onClick: n[0] ||= (e) => le("logs")
|
|
@@ -29350,33 +29355,33 @@ var Wk = ["innerHTML"], Gk = /* @__PURE__ */ Wi({
|
|
|
29350
29355
|
class: Be(["tab-btn", { active: ce.value === "info" }]),
|
|
29351
29356
|
onClick: n[3] ||= (e) => le("info")
|
|
29352
29357
|
}, "🧬 " + W(y.value.debugTabInfo), 3)) : Q("", !0)
|
|
29353
|
-
]), Z("div",
|
|
29358
|
+
]), Z("div", Bj, [
|
|
29354
29359
|
Z("button", {
|
|
29355
29360
|
class: "hd-btn",
|
|
29356
29361
|
title: y.value.debugCopyReport,
|
|
29357
29362
|
onClick: v
|
|
29358
|
-
}, W(g.value === "report" ? "✓" : "💾"), 9,
|
|
29363
|
+
}, W(g.value === "report" ? "✓" : "💾"), 9, Vj),
|
|
29359
29364
|
ce.value === "logs" ? (Y(), X("button", {
|
|
29360
29365
|
key: 0,
|
|
29361
29366
|
class: "hd-btn",
|
|
29362
29367
|
title: y.value.debugClearLogs,
|
|
29363
29368
|
onClick: se
|
|
29364
|
-
}, "🗑️", 8,
|
|
29369
|
+
}, "🗑️", 8, Hj)) : Q("", !0),
|
|
29365
29370
|
Z("button", {
|
|
29366
29371
|
class: "hd-btn",
|
|
29367
29372
|
title: y.value.close,
|
|
29368
29373
|
onClick: oe
|
|
29369
|
-
}, "✕", 8,
|
|
29374
|
+
}, "✕", 8, Uj)
|
|
29370
29375
|
])]),
|
|
29371
|
-
ce.value === "logs" ? (Y(), X("div",
|
|
29376
|
+
ce.value === "logs" ? (Y(), X("div", Wj, [(Y(!0), X(J, null, ga(b.value, (e, t) => (Y(), X("button", {
|
|
29372
29377
|
key: t,
|
|
29373
29378
|
class: Be(["filter-chip", { active: i.value === t }]),
|
|
29374
29379
|
style: Fe({ "--chip-color": e.color }),
|
|
29375
29380
|
onClick: (e) => i.value = t
|
|
29376
|
-
}, [Es(W(e.icon) + " " + W(e.label) + " ", 1), Z("span",
|
|
29381
|
+
}, [Es(W(e.icon) + " " + W(e.label) + " ", 1), Z("span", Kj, W(C.value[t] || 0), 1)], 14, Gj))), 128)), Z("button", {
|
|
29377
29382
|
class: Be(["filter-chip all", { active: i.value === "all" }]),
|
|
29378
29383
|
onClick: n[4] ||= (e) => i.value = "all"
|
|
29379
|
-
}, [Es(W(y.value.debugFilterAll) + " ", 1), Z("span",
|
|
29384
|
+
}, [Es(W(y.value.debugFilterAll) + " ", 1), Z("span", qj, W(C.value.all || 0), 1)], 2)])) : Q("", !0),
|
|
29380
29385
|
Z("div", {
|
|
29381
29386
|
class: "drawer-body",
|
|
29382
29387
|
ref_key: "drawerBodyEl",
|
|
@@ -29390,8 +29395,8 @@ var Wk = ["innerHTML"], Gk = /* @__PURE__ */ Wi({
|
|
|
29390
29395
|
ref_key: "drawerContentsEl",
|
|
29391
29396
|
ref: c
|
|
29392
29397
|
}, [
|
|
29393
|
-
ce.value === "context" ? (Y(), X("div",
|
|
29394
|
-
Z("div",
|
|
29398
|
+
ce.value === "context" ? (Y(), X("div", Jj, [U.value ? (Y(), X(J, { key: 1 }, [U.value ? (Y(), X(J, { key: 0 }, [
|
|
29399
|
+
Z("div", Xj, [Z("div", Zj, [Z("div", {
|
|
29395
29400
|
class: "ctx-bar-track",
|
|
29396
29401
|
title: `${y.value.debugCtxOccupancy} ${Math.round(U.value.occupancy * 100)}%`
|
|
29397
29402
|
}, [Z("div", {
|
|
@@ -29402,12 +29407,12 @@ var Wk = ["innerHTML"], Gk = /* @__PURE__ */ Wi({
|
|
|
29402
29407
|
class: "ctx-threshold-mark",
|
|
29403
29408
|
style: Fe({ left: Math.min(U.value.thresholdRatio * 100, 100) + "%" }),
|
|
29404
29409
|
title: y.value.debugCtxThreshold
|
|
29405
|
-
}, null, 12,
|
|
29406
|
-
Z("span",
|
|
29407
|
-
U.value.contextWindow ? (Y(), X("span",
|
|
29408
|
-
U.value.thresholdRatio > 0 ? (Y(), X("span",
|
|
29410
|
+
}, null, 12, $j)) : Q("", !0)], 8, Qj), Z("span", eM, W(Math.round(U.value.occupancy * 100)) + "%", 1)]), Z("div", tM, [
|
|
29411
|
+
Z("span", nM, W(y.value.debugCtxTokens) + " " + W(U.value.totalTokens) + " token", 1),
|
|
29412
|
+
U.value.contextWindow ? (Y(), X("span", rM, W(y.value.debugCtxWindow) + " " + W(U.value.contextWindow), 1)) : Q("", !0),
|
|
29413
|
+
U.value.thresholdRatio > 0 ? (Y(), X("span", iM, W(y.value.debugCtxThresholdPct) + " " + W(Math.round(U.value.thresholdRatio * 100)) + "%", 1)) : Q("", !0)
|
|
29409
29414
|
])]),
|
|
29410
|
-
Z("div",
|
|
29415
|
+
Z("div", aM, W(y.value.debugCtxCategories), 1),
|
|
29411
29416
|
(Y(!0), X(J, null, ga(U.value.categories, (e) => (Y(), X("div", {
|
|
29412
29417
|
key: e.key,
|
|
29413
29418
|
class: "ctx-cat"
|
|
@@ -29415,62 +29420,62 @@ var Wk = ["innerHTML"], Gk = /* @__PURE__ */ Wi({
|
|
|
29415
29420
|
Z("span", {
|
|
29416
29421
|
class: "ctx-cat-label",
|
|
29417
29422
|
title: e.label
|
|
29418
|
-
}, W(e.label), 9,
|
|
29419
|
-
Z("div",
|
|
29423
|
+
}, W(e.label), 9, oM),
|
|
29424
|
+
Z("div", sM, [Z("div", {
|
|
29420
29425
|
class: "ctx-cat-fill",
|
|
29421
29426
|
style: Fe({ width: Math.max(Math.round(e.pct * 100), 2) + "%" })
|
|
29422
29427
|
}, null, 4)]),
|
|
29423
|
-
Z("span",
|
|
29428
|
+
Z("span", cM, [Es(W(e.tokens) + " ", 1), Z("i", null, "(" + W(Math.round(e.pct * 100)) + "%)", 1)])
|
|
29424
29429
|
]))), 128)),
|
|
29425
|
-
U.value.compression ? (Y(), X("div",
|
|
29426
|
-
Z("span",
|
|
29427
|
-
Z("span",
|
|
29428
|
-
Z("span",
|
|
29429
|
-
U.value.compression.decision ? (Y(), X("span",
|
|
29430
|
+
U.value.compression ? (Y(), X("div", lM, [Z("div", uM, W(y.value.debugCtxLastCompression), 1), Z("div", dM, [
|
|
29431
|
+
Z("span", fM, W(y.value.debugCtxSummarized) + " " + W(U.value.compression.roundsSummarized) + "/" + W(U.value.compression.roundsTotal) + W(y.value.debugCtxRoundsSuffix), 1),
|
|
29432
|
+
Z("span", pM, W(y.value.debugCtxRecalled) + " " + W(U.value.compression.roundsRecalled), 1),
|
|
29433
|
+
Z("span", mM, W(U.value.compression.strategy), 1),
|
|
29434
|
+
U.value.compression.decision ? (Y(), X("span", hM, "🤖 " + W(y.value.debugCtxAgentDecision) + W(be(U.value.compression.decision)), 1)) : Q("", !0)
|
|
29430
29435
|
])])) : Q("", !0)
|
|
29431
|
-
], 64)) : Q("", !0)], 64)) : (Y(), X("div",
|
|
29432
|
-
ce.value === "subagent" ? (Y(), X("div",
|
|
29436
|
+
], 64)) : Q("", !0)], 64)) : (Y(), X("div", Yj, W(y.value.debugCtxEmpty), 1))])) : Q("", !0),
|
|
29437
|
+
ce.value === "subagent" ? (Y(), X("div", gM, [ge.value.length ? (Y(), X("div", _M, [Z("div", vM, "🔒 " + W(y.value.debugLocksTitle) + " (" + W(ge.value.length) + ")", 1), (Y(!0), X(J, null, ga(ge.value, ([e, t]) => (Y(), X("div", {
|
|
29433
29438
|
key: "lock-" + e,
|
|
29434
29439
|
class: "sub-task"
|
|
29435
|
-
}, "🔒 " + W(e) + " ← " + W(t), 1))), 128))])) : Q("", !0), !me.value.length && !he.value.length ? (Y(), X("div",
|
|
29440
|
+
}, "🔒 " + W(e) + " ← " + W(t), 1))), 128))])) : Q("", !0), !me.value.length && !he.value.length ? (Y(), X("div", yM, W(y.value.debugSubagentEmpty), 1)) : (Y(), X(J, { key: 2 }, [me.value.length ? (Y(), X("div", bM, [Z("div", xM, "▶ " + W(y.value.debugSubRunningTitle) + " (" + W(me.value.length) + ")", 1), (Y(!0), X(J, null, ga(me.value, (e, t) => (Y(), X("div", {
|
|
29436
29441
|
key: "a" + t,
|
|
29437
29442
|
class: Be(["sub-card", e.status])
|
|
29438
|
-
}, [Z("div",
|
|
29443
|
+
}, [Z("div", SM, [
|
|
29439
29444
|
Z("span", {
|
|
29440
29445
|
class: "sub-status",
|
|
29441
29446
|
style: Fe({ background: _e.value[e.status] && _e.value[e.status].color || "#9ca3af" })
|
|
29442
29447
|
}, W(_e.value[e.status] && _e.value[e.status].label || e.status), 5),
|
|
29443
|
-
Z("span",
|
|
29444
|
-
Z("span",
|
|
29445
|
-
]), Z("div",
|
|
29448
|
+
Z("span", CM, W(e.label), 1),
|
|
29449
|
+
Z("span", wM, W(e.steps.length) + W(y.value.debugStepsCountSuffix), 1)
|
|
29450
|
+
]), Z("div", TM, W(de(e.task, 80)), 1)], 2))), 128))])) : Q("", !0), he.value.length ? (Y(), X("div", EM, [Z("div", DM, "🕐 " + W(y.value.debugSubHistoryTitle) + " (" + W(he.value.length) + ")", 1), (Y(!0), X(J, null, ga(he.value, (e, t) => (Y(), X("div", {
|
|
29446
29451
|
key: "h" + t,
|
|
29447
29452
|
class: Be(["sub-card", e.status])
|
|
29448
29453
|
}, [
|
|
29449
|
-
Z("div",
|
|
29454
|
+
Z("div", OM, [
|
|
29450
29455
|
Z("span", {
|
|
29451
29456
|
class: "sub-status",
|
|
29452
29457
|
style: Fe({ background: _e.value[e.status] && _e.value[e.status].color || "#9ca3af" })
|
|
29453
29458
|
}, W(_e.value[e.status] && _e.value[e.status].label || e.status), 5),
|
|
29454
|
-
Z("span",
|
|
29455
|
-
e.durationMs == null ? Q("", !0) : (Y(), X("span",
|
|
29459
|
+
Z("span", kM, W(e.label), 1),
|
|
29460
|
+
e.durationMs == null ? Q("", !0) : (Y(), X("span", AM, W(fe(e.durationMs)), 1)),
|
|
29456
29461
|
e.steps.length ? (Y(), X("button", {
|
|
29457
29462
|
key: 1,
|
|
29458
29463
|
class: "sub-toggle",
|
|
29459
29464
|
onClick: (e) => ye(t)
|
|
29460
|
-
}, W(ve.value.has(t) ? y.value.collapse : y.value.debugStepsBtn), 9,
|
|
29465
|
+
}, W(ve.value.has(t) ? y.value.collapse : y.value.debugStepsBtn), 9, jM)) : Q("", !0)
|
|
29461
29466
|
]),
|
|
29462
|
-
Z("div",
|
|
29463
|
-
e.resultPreview ? (Y(), X("div",
|
|
29464
|
-
ve.value.has(t) && e.steps.length ? (Y(), X("div",
|
|
29467
|
+
Z("div", MM, W(de(e.task, 80)), 1),
|
|
29468
|
+
e.resultPreview ? (Y(), X("div", NM, W(e.resultPreview), 1)) : Q("", !0),
|
|
29469
|
+
ve.value.has(t) && e.steps.length ? (Y(), X("div", PM, [(Y(!0), X(J, null, ga(e.steps, (e, t) => (Y(), X("div", {
|
|
29465
29470
|
key: t,
|
|
29466
29471
|
class: "sub-step"
|
|
29467
29472
|
}, [
|
|
29468
|
-
Z("span",
|
|
29469
|
-
Z("span",
|
|
29470
|
-
Z("span",
|
|
29473
|
+
Z("span", FM, W(e.kind === "tool_call" ? "🔧" : "✅"), 1),
|
|
29474
|
+
Z("span", IM, W(e.name), 1),
|
|
29475
|
+
Z("span", LM, W(N(e.ts)), 1)
|
|
29471
29476
|
]))), 128))])) : Q("", !0)
|
|
29472
29477
|
], 2))), 128))])) : Q("", !0)], 64))])) : Q("", !0),
|
|
29473
|
-
ce.value === "logs" ? (Y(), X(J, { key: 2 }, [S.value.length === 0 ? (Y(), X("div",
|
|
29478
|
+
ce.value === "logs" ? (Y(), X(J, { key: 2 }, [S.value.length === 0 ? (Y(), X("div", RM, W(y.value.debugLogsEmpty), 1)) : Q("", !0), (Y(!0), X(J, null, ga(O.value, (e) => (Y(), X("div", {
|
|
29474
29479
|
key: e.key,
|
|
29475
29480
|
class: "log-group"
|
|
29476
29481
|
}, [Z("div", {
|
|
@@ -29478,185 +29483,185 @@ var Wk = ["innerHTML"], Gk = /* @__PURE__ */ Wi({
|
|
|
29478
29483
|
onClick: (t) => M(e.key)
|
|
29479
29484
|
}, [
|
|
29480
29485
|
Z("span", { class: Be(["log-group-arrow", { open: j(e.key) }]) }, "▶", 2),
|
|
29481
|
-
Z("span",
|
|
29482
|
-
Z("span",
|
|
29486
|
+
Z("span", BM, W(ne(e)), 1),
|
|
29487
|
+
Z("span", VM, [
|
|
29483
29488
|
Es(W(N(e.firstTs)), 1),
|
|
29484
29489
|
e.lastTs > e.firstTs ? (Y(), X(J, { key: 0 }, [Es(" ~ " + W(N(e.lastTs)), 1)], 64)) : Q("", !0),
|
|
29485
29490
|
Es(" · " + W(fe(e.lastTs - e.firstTs)), 1)
|
|
29486
29491
|
]),
|
|
29487
|
-
e.toolCount ? (Y(), X("span",
|
|
29488
|
-
e.tokens == null ? Q("", !0) : (Y(), X("span",
|
|
29489
|
-
e.errorCount ? (Y(), X("span",
|
|
29490
|
-
], 10,
|
|
29492
|
+
e.toolCount ? (Y(), X("span", HM, "🔧 " + W(e.toolCount), 1)) : Q("", !0),
|
|
29493
|
+
e.tokens == null ? Q("", !0) : (Y(), X("span", UM, "Σ " + W(e.tokens) + " tok", 1)),
|
|
29494
|
+
e.errorCount ? (Y(), X("span", WM, "❌ " + W(e.errorCount), 1)) : Q("", !0)
|
|
29495
|
+
], 10, zM), ai(Z("div", GM, [(Y(!0), X(J, null, ga(e.entries, ({ log: e, pairCall: t, prevMsgCount: r, uid: i }) => (Y(), X("div", {
|
|
29491
29496
|
key: i,
|
|
29492
29497
|
class: "log-item"
|
|
29493
29498
|
}, [
|
|
29494
|
-
Z("div",
|
|
29499
|
+
Z("div", KM, [
|
|
29495
29500
|
Z("span", {
|
|
29496
29501
|
class: "log-type",
|
|
29497
29502
|
style: Fe({ background: b.value[e.type].color })
|
|
29498
29503
|
}, W(b.value[e.type].icon) + " " + W(b.value[e.type].label), 5),
|
|
29499
|
-
e.source ? (Y(), X("span",
|
|
29500
|
-
Z("span",
|
|
29504
|
+
e.source ? (Y(), X("span", qM, "↳ " + W(e.source), 1)) : Q("", !0),
|
|
29505
|
+
Z("span", JM, W(N(e.timestamp)), 1)
|
|
29501
29506
|
]),
|
|
29502
|
-
Z("div",
|
|
29503
|
-
Z("div",
|
|
29504
|
-
Z("div",
|
|
29505
|
-
Z("div",
|
|
29506
|
-
Z("div",
|
|
29507
|
-
Z("div",
|
|
29507
|
+
Z("div", YM, [e.type === "context" ? (Y(), X(J, { key: 0 }, [
|
|
29508
|
+
Z("div", XM, [
|
|
29509
|
+
Z("div", ZM, [Z("span", QM, W(y.value.debugModel), 1), Z("span", $M, W(e.data.model), 1)]),
|
|
29510
|
+
Z("div", eN, [Z("span", tN, W(y.value.debugTemperature), 1), Z("span", nN, W(e.data.temperature), 1)]),
|
|
29511
|
+
Z("div", rN, [n[5] ||= Z("span", { class: "k" }, "MaxTokens", -1), Z("span", iN, W(e.data.maxTokens), 1)]),
|
|
29512
|
+
Z("div", aN, [Z("span", oN, W(y.value.debugMessageCount), 1), Z("span", sN, W(e.data.totalMessages), 1)])
|
|
29508
29513
|
]),
|
|
29509
|
-
Z("div",
|
|
29510
|
-
Z("div",
|
|
29514
|
+
Z("div", cN, W(y.value.debugToolsLabel) + " (" + W(e.data.tools?.length || 0) + ")", 1),
|
|
29515
|
+
Z("div", lN, [(Y(!0), X(J, null, ga(e.data.tools, (e) => (Y(), X("span", {
|
|
29511
29516
|
key: e,
|
|
29512
29517
|
class: "tool-chip"
|
|
29513
29518
|
}, W(e), 1))), 128))]),
|
|
29514
|
-
Z("div",
|
|
29515
|
-
Z("div",
|
|
29519
|
+
Z("div", uN, W(y.value.debugContextMessages), 1),
|
|
29520
|
+
Z("div", dN, [(Y(!0), X(J, null, ga(e.data.messages, (e, t) => (Y(), X("div", {
|
|
29516
29521
|
key: t,
|
|
29517
29522
|
class: "msg-row"
|
|
29518
29523
|
}, [Z("span", {
|
|
29519
29524
|
class: "msg-role",
|
|
29520
29525
|
style: Fe({ background: ae(e.type).color })
|
|
29521
|
-
}, W(ae(e.type).label), 5), Z("span",
|
|
29522
|
-
], 64)) : e.type === "llm_request" ? (Y(), X(J, { key: 1 }, [Z("div",
|
|
29523
|
-
Z("span",
|
|
29524
|
-
e.data.model ? (Y(), X("span",
|
|
29525
|
-
Z("span",
|
|
29526
|
-
e.data.tools?.length ? (Y(), X("span",
|
|
29526
|
+
}, W(ae(e.type).label), 5), Z("span", fN, W(e.content), 1)]))), 128))])
|
|
29527
|
+
], 64)) : e.type === "llm_request" ? (Y(), X(J, { key: 1 }, [Z("div", pN, [
|
|
29528
|
+
Z("span", mN, W(y.value.debugRoundPrefix) + W(e.data.round) + W(y.value.debugRoundSuffix), 1),
|
|
29529
|
+
e.data.model ? (Y(), X("span", hN, W(e.data.model), 1)) : Q("", !0),
|
|
29530
|
+
Z("span", gN, [Es(W((e.data.messages || []).length) + W(y.value.debugMsgCountSuffix), 1), r != null && r < (e.data.messages || []).length ? (Y(), X(J, { key: 0 }, [Es("(+" + W((e.data.messages || []).length - r) + ")", 1)], 64)) : Q("", !0)]),
|
|
29531
|
+
e.data.tools?.length ? (Y(), X("span", _N, W(e.data.tools.length) + W(y.value.debugToolCountSuffix), 1)) : Q("", !0),
|
|
29527
29532
|
r != null && r > 0 ? (Y(), X("button", {
|
|
29528
29533
|
key: 2,
|
|
29529
29534
|
class: "view-toggle only-new-btn",
|
|
29530
29535
|
onClick: (e) => h(i)
|
|
29531
|
-
}, W(m.value.has(i) ? y.value.debugShowAll : y.value.debugOnlyNew), 9,
|
|
29536
|
+
}, W(m.value.has(i) ? y.value.debugShowAll : y.value.debugOnlyNew), 9, vN)) : Q("", !0),
|
|
29532
29537
|
Z("button", {
|
|
29533
29538
|
class: "view-toggle copy-btn",
|
|
29534
29539
|
title: y.value.copy,
|
|
29535
29540
|
onClick: (t) => _(F(e.data.messages), "req" + i)
|
|
29536
|
-
}, W(g.value === "req" + i ? "✓" : "📋"), 9,
|
|
29541
|
+
}, W(g.value === "req" + i ? "✓" : "📋"), 9, yN),
|
|
29537
29542
|
Z("button", {
|
|
29538
29543
|
class: "view-toggle",
|
|
29539
29544
|
onClick: (e) => P(i)
|
|
29540
|
-
}, W(d.value.has(i) ? y.value.debugCardView : y.value.debugRequestBody), 9,
|
|
29541
|
-
]), d.value.has(i) ? (Y(), X("pre",
|
|
29545
|
+
}, W(d.value.has(i) ? y.value.debugCardView : y.value.debugRequestBody), 9, bN)
|
|
29546
|
+
]), d.value.has(i) ? (Y(), X("pre", DN, [Z("code", null, W(F(e.data.messages)), 1)])) : (Y(!0), X(J, { key: 0 }, ga([re(e, r, m.value.has(i))], (e) => (Y(), X("div", {
|
|
29542
29547
|
key: e.base,
|
|
29543
29548
|
class: "msg-list"
|
|
29544
29549
|
}, [(Y(!0), X(J, null, ga(e.list, (t, n) => (Y(), X("div", {
|
|
29545
29550
|
key: n,
|
|
29546
|
-
class: Be(["msg-row", { clamped: !f.value.has(i + ":" + (e.base + n)) && String(t.content ?? "").length >
|
|
29547
|
-
title: String(t.content ?? "").length >
|
|
29548
|
-
onClick: (r) => String(t.content ?? "").length >
|
|
29551
|
+
class: Be(["msg-row", { clamped: !f.value.has(i + ":" + (e.base + n)) && String(t.content ?? "").length > GF }]),
|
|
29552
|
+
title: String(t.content ?? "").length > GF ? f.value.has(i + ":" + (e.base + n)) ? y.value.collapse : y.value.expand : void 0,
|
|
29553
|
+
onClick: (r) => String(t.content ?? "").length > GF && p(i + ":" + (e.base + n))
|
|
29549
29554
|
}, [Z("span", {
|
|
29550
29555
|
class: "msg-role",
|
|
29551
29556
|
style: Fe({ background: ae(t.role).color })
|
|
29552
|
-
}, W(ae(t.role).label), 5), Z("div",
|
|
29553
|
-
t.content ? (Y(), X("span",
|
|
29557
|
+
}, W(ae(t.role).label), 5), Z("div", SN, [
|
|
29558
|
+
t.content ? (Y(), X("span", CN, W(t.content), 1)) : Q("", !0),
|
|
29554
29559
|
(Y(!0), X(J, null, ga(t.tool_calls || [], (e, t) => (Y(), X("div", {
|
|
29555
29560
|
key: t,
|
|
29556
29561
|
class: "tc-inline"
|
|
29557
|
-
}, [Z("span",
|
|
29558
|
-
t.tool_call_id ? (Y(), X("span",
|
|
29559
|
-
])], 10,
|
|
29560
|
-
Z("div",
|
|
29561
|
-
e.data.content ? (Y(), X("div",
|
|
29562
|
-
e.data.toolCalls?.length ? (Y(), X("div",
|
|
29562
|
+
}, [Z("span", wN, "🔧 " + W(e.function?.name || e.name), 1), Z("code", TN, W(e.function?.arguments ?? e.args), 1)]))), 128)),
|
|
29563
|
+
t.tool_call_id ? (Y(), X("span", EN, "↳ tool_call_id: " + W(t.tool_call_id), 1)) : Q("", !0)
|
|
29564
|
+
])], 10, xN))), 128))]))), 128))], 64)) : e.type === "llm_response" ? (Y(), X(J, { key: 2 }, [
|
|
29565
|
+
Z("div", ON, [Z("span", kN, W(y.value.debugRoundPrefix) + W(e.data.round) + W(y.value.debugRoundSuffix), 1), e.data.toolCalls?.length ? (Y(), X("span", AN, "🔧 " + W(e.data.toolCalls.length) + W(y.value.debugToolCallsSuffix), 1)) : Q("", !0)]),
|
|
29566
|
+
e.data.content ? (Y(), X("div", jN, W(e.data.content), 1)) : Q("", !0),
|
|
29567
|
+
e.data.toolCalls?.length ? (Y(), X("div", MN, [(Y(!0), X(J, null, ga(e.data.toolCalls, (e, t) => (Y(), X("div", {
|
|
29563
29568
|
key: t,
|
|
29564
29569
|
class: "tc-card"
|
|
29565
|
-
}, [Z("div",
|
|
29566
|
-
e.data.usage ? (Y(), X("div",
|
|
29567
|
-
Z("span",
|
|
29568
|
-
Z("span",
|
|
29569
|
-
Z("span",
|
|
29570
|
-
e.data.usage.reasoning_tokens ? (Y(), X("span",
|
|
29570
|
+
}, [Z("div", NN, "🔧 " + W(e.name), 1), Z("pre", PN, W(F(e.args)), 1)]))), 128))])) : Q("", !0),
|
|
29571
|
+
e.data.usage ? (Y(), X("div", FN, [
|
|
29572
|
+
Z("span", IN, "prompt: " + W(e.data.usage.prompt_tokens ?? "-"), 1),
|
|
29573
|
+
Z("span", LN, "completion: " + W(e.data.usage.completion_tokens ?? "-"), 1),
|
|
29574
|
+
Z("span", RN, "total: " + W(e.data.usage.total_tokens ?? "-"), 1),
|
|
29575
|
+
e.data.usage.reasoning_tokens ? (Y(), X("span", zN, "reasoning: " + W(e.data.usage.reasoning_tokens) + "(" + W(Math.round(e.data.usage.reasoning_tokens / Math.max(1, e.data.usage.completion_tokens ?? 0) * 100)) + "%)", 1)) : Q("", !0)
|
|
29571
29576
|
])) : Q("", !0)
|
|
29572
29577
|
], 64)) : e.type === "tool_call" || e.type === "tool_result" ? (Y(), X(J, { key: 3 }, [t ? (Y(), X("div", {
|
|
29573
29578
|
key: 0,
|
|
29574
29579
|
class: Be(["tc-card inline paired", { error: e.data.status === "error" }])
|
|
29575
29580
|
}, [
|
|
29576
|
-
Z("div",
|
|
29581
|
+
Z("div", BN, [
|
|
29577
29582
|
Es(W(e.data.status === "error" ? "❌" : "✅") + " " + W(e.data.name) + " ", 1),
|
|
29578
|
-
e.data.durationMs == null ? Q("", !0) : (Y(), X("span",
|
|
29583
|
+
e.data.durationMs == null ? Q("", !0) : (Y(), X("span", VN, W(fe(e.data.durationMs)), 1)),
|
|
29579
29584
|
Z("button", {
|
|
29580
29585
|
class: "view-toggle copy-btn",
|
|
29581
29586
|
title: y.value.copy,
|
|
29582
29587
|
onClick: (t) => _(String(e.data.result ?? ""), "res" + i)
|
|
29583
|
-
}, W(g.value === "res" + i ? "✓" : "📋"), 9,
|
|
29588
|
+
}, W(g.value === "res" + i ? "✓" : "📋"), 9, HN)
|
|
29584
29589
|
]),
|
|
29585
|
-
Z("pre",
|
|
29586
|
-
Z("div",
|
|
29587
|
-
Z("pre",
|
|
29588
|
-
], 2)) : (Y(), X("div",
|
|
29589
|
-
Z("div",
|
|
29590
|
+
Z("pre", UN, W(F(t.data.args)), 1),
|
|
29591
|
+
Z("div", WN, "↓ " + W(y.value.resultLabel), 1),
|
|
29592
|
+
Z("pre", GN, W(e.data.result), 1)
|
|
29593
|
+
], 2)) : (Y(), X("div", KN, [Z("div", qN, [Es(W(e.type === "tool_call" ? "🔧" : "✅") + " " + W(e.data.name) + " ", 1), e.type === "tool_call" ? (Y(), X("span", JN, W(y.value.statusRunning) + "…", 1)) : Q("", !0)]), Z("pre", YN, W(e.type === "tool_call" ? F(e.data.args) : e.data.result), 1)]))], 64)) : e.type === "error" ? (Y(), X("div", XN, W(e.data.tool ? `[${e.data.tool}] ` : "") + W(e.data.error), 1)) : Q("", !0)]),
|
|
29594
|
+
Z("div", ZN, [Z("button", {
|
|
29590
29595
|
class: "raw-toggle",
|
|
29591
29596
|
onClick: (e) => ie(i)
|
|
29592
|
-
}, W(a.value.has(i) ? y.value.debugCollapseRawJson : y.value.debugViewRawJson), 9,
|
|
29597
|
+
}, W(a.value.has(i) ? y.value.debugCollapseRawJson : y.value.debugViewRawJson), 9, QN), Z("button", {
|
|
29593
29598
|
class: "raw-toggle",
|
|
29594
29599
|
onClick: (t) => K(rw)(F(e.data))
|
|
29595
|
-
}, W(y.value.copy), 9,
|
|
29596
|
-
a.value.has(i) ? (Y(), X("pre",
|
|
29597
|
-
]))), 128))], 512), [[Uc, j(e.key)]])]))), 128))], 64)) : ce.value === "info" ? (Y(), X("div",
|
|
29598
|
-
Z("div",
|
|
29599
|
-
Z("div",
|
|
29600
|
-
Z("div",
|
|
29601
|
-
Z("div",
|
|
29602
|
-
Z("div",
|
|
29603
|
-
Z("div",
|
|
29604
|
-
Z("div",
|
|
29600
|
+
}, W(y.value.copy), 9, $N)]),
|
|
29601
|
+
a.value.has(i) ? (Y(), X("pre", eP, [Z("code", null, W(F(e.data)), 1)])) : Q("", !0)
|
|
29602
|
+
]))), 128))], 512), [[Uc, j(e.key)]])]))), 128))], 64)) : ce.value === "info" ? (Y(), X("div", tP, [L.value ? (Y(), X(J, { key: 1 }, [
|
|
29603
|
+
Z("div", rP, [
|
|
29604
|
+
Z("div", iP, W(y.value.debugInfoBasic), 1),
|
|
29605
|
+
Z("div", aP, [
|
|
29606
|
+
Z("div", oP, [n[6] ||= Z("span", { class: "k" }, "ID", -1), Z("span", sP, W(L.value.id), 1)]),
|
|
29607
|
+
Z("div", cP, [Z("span", lP, W(y.value.debugModel), 1), Z("span", uP, W(L.value.model || "-"), 1)]),
|
|
29608
|
+
Z("div", dP, [Z("span", fP, W(y.value.debugToolCount), 1), Z("span", pP, W(L.value.tools.length), 1)]),
|
|
29609
|
+
Z("div", mP, [Z("span", hP, W(y.value.debugMiddleware), 1), Z("span", gP, W(L.value.middleware.length), 1)])
|
|
29605
29610
|
]),
|
|
29606
|
-
Z("div",
|
|
29611
|
+
Z("div", _P, [Z("span", vP, W(y.value.debugMiddlewareStack), 1), Z("span", yP, W(L.value.middleware.join(" → ") || "-"), 1)])
|
|
29607
29612
|
]),
|
|
29608
|
-
Z("div",
|
|
29613
|
+
Z("div", bP, [Z("div", xP, "🔧 " + W(y.value.debugToolsLabel) + " (" + W(L.value.tools.length) + ")", 1), (Y(!0), X(J, null, ga(L.value.tools, (e) => (Y(), X("div", {
|
|
29609
29614
|
key: e.name,
|
|
29610
29615
|
class: "info-item"
|
|
29611
|
-
}, [Z("div",
|
|
29616
|
+
}, [Z("div", SP, [Es(W(e.name), 1), e.source ? (Y(), X("span", {
|
|
29612
29617
|
key: 0,
|
|
29613
29618
|
class: Be(["src-tag", H(e.source)])
|
|
29614
|
-
}, W(e.source), 3)) : Q("", !0)]), Z("div",
|
|
29615
|
-
L.value.skills.length ? (Y(), X("div",
|
|
29619
|
+
}, W(e.source), 3)) : Q("", !0)]), Z("div", CP, W(e.description), 1)]))), 128))]),
|
|
29620
|
+
L.value.skills.length ? (Y(), X("div", wP, [Z("div", TP, [Es("📘 " + W(y.value.debugSkillsTitle) + " (" + W(L.value.skills.length) + ")", 1), Z("span", EP, W(y.value.debugSkillsHint), 1)]), (Y(!0), X(J, null, ga(L.value.skills, (e) => (Y(), X("div", {
|
|
29616
29621
|
key: e.name,
|
|
29617
29622
|
class: "info-item"
|
|
29618
29623
|
}, [
|
|
29619
29624
|
Z("div", {
|
|
29620
29625
|
class: "info-name skill-toggle",
|
|
29621
29626
|
onClick: (t) => z(e.name)
|
|
29622
|
-
}, [Z("span", { class: Be(["skill-arrow", { open: !!R.value[e.name] }]) }, "▶", 2), Es(" " + W(e.name), 1)], 8,
|
|
29623
|
-
Z("div",
|
|
29624
|
-
R.value[e.name] ? (Y(), X("div",
|
|
29627
|
+
}, [Z("span", { class: Be(["skill-arrow", { open: !!R.value[e.name] }]) }, "▶", 2), Es(" " + W(e.name), 1)], 8, DP),
|
|
29628
|
+
Z("div", OP, W(e.description), 1),
|
|
29629
|
+
R.value[e.name] ? (Y(), X("div", kP, [R.value[e.name].loading ? (Y(), X("div", AP, W(y.value.debugLoading), 1)) : R.value[e.name].error ? (Y(), X("div", jP, W(R.value[e.name].error), 1)) : R.value[e.name].content ? (Y(), X("pre", MP, W(R.value[e.name].content), 1)) : Q("", !0)])) : Q("", !0)
|
|
29625
29630
|
]))), 128))])) : Q("", !0),
|
|
29626
|
-
L.value.data ? (Y(), X("div",
|
|
29627
|
-
Z("div",
|
|
29628
|
-
Z("div",
|
|
29629
|
-
Z("div",
|
|
29630
|
-
Z("div",
|
|
29631
|
-
Z("div",
|
|
29631
|
+
L.value.data ? (Y(), X("div", NP, [Z("div", PP, "📊 " + W(y.value.debugDataTitle), 1), Z("div", FP, [Z("div", IP, W(L.value.data.description || y.value.debugDataFallback), 1), Z("div", LP, W(y.value.debugSchemaPrefix) + W(L.value.data.schema ? y.value.debugSchemaDeclared : y.value.debugSchemaMissing), 1)])])) : Q("", !0),
|
|
29632
|
+
Z("div", RP, [Z("div", zP, "🧬 " + W(y.value.debugSubagentTitle), 1), Z("div", BP, [
|
|
29633
|
+
Z("div", VP, [Z("span", HP, W(y.value.debugEnabled), 1), Z("span", UP, W(L.value.subagent.enabled ? y.value.debugYes : y.value.debugNo), 1)]),
|
|
29634
|
+
Z("div", WP, [Z("span", GP, W(y.value.debugMaxDepth), 1), Z("span", KP, W(L.value.subagent.maxDepth), 1)]),
|
|
29635
|
+
Z("div", qP, [Z("span", JP, W(y.value.debugMaxParallel), 1), Z("span", YP, W(L.value.subagent.maxParallel), 1)]),
|
|
29636
|
+
Z("div", XP, [Z("span", ZP, W(y.value.debugExtraTools), 1), Z("span", QP, W(L.value.subagent.allowedTools.length ? L.value.subagent.allowedTools.join(", ") : y.value.debugDefaultReadonly), 1)])
|
|
29632
29637
|
])]),
|
|
29633
|
-
L.value.mcp?.servers?.length ? (Y(), X("div",
|
|
29638
|
+
L.value.mcp?.servers?.length ? (Y(), X("div", $P, [Z("div", eF, "🔌 MCP (" + W(L.value.mcp.servers.length) + ")", 1), (Y(!0), X(J, null, ga(L.value.mcp.servers, (e) => (Y(), X("div", {
|
|
29634
29639
|
key: e.name,
|
|
29635
29640
|
class: "info-item"
|
|
29636
|
-
}, [Z("div",
|
|
29637
|
-
L.value.verify ? (Y(), X("div",
|
|
29638
|
-
Z("div",
|
|
29639
|
-
Z("div",
|
|
29640
|
-
Z("div",
|
|
29641
|
-
L.value.verify.adversarial ? (Y(), X("div",
|
|
29641
|
+
}, [Z("div", tF, [Es(W(e.name) + " ", 1), Z("span", nF, W(e.toolCount) + W(y.value.debugToolCountSuffix), 1)]), Z("div", rF, W(e.url), 1)]))), 128))])) : Q("", !0),
|
|
29642
|
+
L.value.verify ? (Y(), X("div", iF, [Z("div", aF, "✅ " + W(y.value.debugVerifyTitle), 1), Z("div", oF, [
|
|
29643
|
+
Z("div", sF, [Z("span", cF, W(y.value.debugEnabled), 1), Z("span", lF, W(L.value.verify.enabled ? y.value.debugYes : y.value.debugNo), 1)]),
|
|
29644
|
+
Z("div", uF, [Z("span", dF, W(y.value.debugMaxAttempts), 1), Z("span", fF, W(L.value.verify.maxAttempts), 1)]),
|
|
29645
|
+
Z("div", pF, [Z("span", mF, W(y.value.debugAdversarial), 1), Z("span", hF, W(L.value.verify.adversarial ? y.value.debugOn : y.value.debugOff), 1)]),
|
|
29646
|
+
L.value.verify.adversarial ? (Y(), X("div", gF, [Z("span", _F, W(y.value.debugAdversarialModel), 1), Z("span", vF, W(L.value.model || "-") + W(y.value.debugSameAsMain), 1)])) : Q("", !0)
|
|
29642
29647
|
])])) : Q("", !0),
|
|
29643
|
-
L.value.todos.length ? (Y(), X("div",
|
|
29648
|
+
L.value.todos.length ? (Y(), X("div", yF, [Z("div", bF, "📋 " + W(y.value.debugTodosTitle) + " (" + W(L.value.todos.length) + ")", 1), (Y(!0), X(J, null, ga(L.value.todos, (e, t) => (Y(), X("div", {
|
|
29644
29649
|
key: t,
|
|
29645
29650
|
class: "info-todo"
|
|
29646
29651
|
}, [Z("span", {
|
|
29647
29652
|
class: "todo-tag",
|
|
29648
29653
|
style: Fe({ background: V.value[e.status] && V.value[e.status].color || "#9ca3af" })
|
|
29649
29654
|
}, W(ue(e.status)), 5), Z("span", null, W(e.content), 1)]))), 128))])) : Q("", !0),
|
|
29650
|
-
L.value.memory ? (Y(), X("div",
|
|
29651
|
-
L.value.lastCompression ? (Y(), X("div",
|
|
29652
|
-
Z("div",
|
|
29653
|
-
Z("div",
|
|
29654
|
-
Z("div",
|
|
29655
|
-
Z("div",
|
|
29656
|
-
Z("div",
|
|
29657
|
-
L.value.lastCompression.decision ? (Y(), X("div",
|
|
29655
|
+
L.value.memory ? (Y(), X("div", xF, [Z("div", SF, "📝 " + W(y.value.debugMemoryTitle), 1), Z("pre", CF, W(L.value.memory), 1)])) : Q("", !0),
|
|
29656
|
+
L.value.lastCompression ? (Y(), X("div", wF, [Z("div", TF, "🗜️ " + W(y.value.debugLastCompTitle), 1), Z("div", EF, [
|
|
29657
|
+
Z("div", DF, [Z("span", OF, W(y.value.debugTriggered), 1), Z("span", kF, W(L.value.lastCompression.triggered ? "✓" : y.value.debugNotTriggered), 1)]),
|
|
29658
|
+
Z("div", AF, [Z("span", jF, W(y.value.debugRoundsSummarized), 1), Z("span", MF, W(L.value.lastCompression.roundsSummarized) + " / " + W(L.value.lastCompression.roundsTotal), 1)]),
|
|
29659
|
+
Z("div", NF, [Z("span", PF, W(y.value.debugCtxRecalled), 1), Z("span", FF, W(L.value.lastCompression.roundsRecalled) + W(y.value.debugCountSuffix), 1)]),
|
|
29660
|
+
Z("div", IF, [Z("span", LF, W(y.value.debugMessageCount), 1), Z("span", RF, W(L.value.lastCompression.originalMessages) + " → " + W(L.value.lastCompression.compressedMessages), 1)]),
|
|
29661
|
+
Z("div", zF, [Z("span", BF, W(y.value.debugStrategy), 1), Z("span", VF, W(L.value.lastCompression.strategy), 1)]),
|
|
29662
|
+
L.value.lastCompression.decision ? (Y(), X("div", HF, [Z("span", UF, W(y.value.debugDecision), 1), Z("span", WF, "🤖 " + W(be(L.value.lastCompression.decision)), 1)])) : Q("", !0)
|
|
29658
29663
|
])])) : Q("", !0)
|
|
29659
|
-
], 64)) : (Y(), X("div",
|
|
29664
|
+
], 64)) : (Y(), X("div", nP, W(y.value.debugNoInfo), 1))])) : Q("", !0)
|
|
29660
29665
|
], 512)], 512)], 512)
|
|
29661
29666
|
], 2), Z("div", {
|
|
29662
29667
|
class: "drawer-mask",
|
|
@@ -29665,16 +29670,16 @@ var Wk = ["innerHTML"], Gk = /* @__PURE__ */ Wi({
|
|
|
29665
29670
|
_: 1
|
|
29666
29671
|
})]));
|
|
29667
29672
|
}
|
|
29668
|
-
}), [["__scopeId", "data-v-ffd46605"]]),
|
|
29673
|
+
}), [["__scopeId", "data-v-ffd46605"]]), qF = { class: "skill-panel" }, JF = { class: "skill-header" }, YF = { class: "skill-title" }, XF = ["title"], ZF = { class: "skill-section" }, QF = { class: "section-title" }, $F = ["title"], eI = { class: "field" }, tI = { class: "field-label" }, nI = ["disabled", "placeholder"], rI = { class: "field" }, iI = { class: "field-label" }, aI = ["placeholder"], oI = { class: "field field-textarea" }, sI = { class: "field-label" }, cI = ["placeholder"], lI = {
|
|
29669
29674
|
key: 0,
|
|
29670
29675
|
class: "skill-error"
|
|
29671
|
-
},
|
|
29676
|
+
}, uI = { class: "skill-section" }, dI = { class: "section-title" }, fI = {
|
|
29672
29677
|
key: 0,
|
|
29673
29678
|
class: "empty-hint"
|
|
29674
|
-
},
|
|
29679
|
+
}, pI = {
|
|
29675
29680
|
key: 1,
|
|
29676
29681
|
class: "skill-list"
|
|
29677
|
-
},
|
|
29682
|
+
}, mI = { class: "skill-actions" }, hI = ["title", "onClick"], gI = ["title", "onClick"], _I = { class: "skill-hint" }, vI = /*#__PURE__*/ qT(/* @__PURE__ */ Wi({
|
|
29678
29683
|
__name: "SkillPanel",
|
|
29679
29684
|
props: {
|
|
29680
29685
|
visible: { type: Boolean },
|
|
@@ -29729,55 +29734,55 @@ var Wk = ["innerHTML"], Gk = /* @__PURE__ */ Wi({
|
|
|
29729
29734
|
key: 0,
|
|
29730
29735
|
class: "skill-mask",
|
|
29731
29736
|
onClick: n[4] ||= Ol((e) => r("close"), ["self"])
|
|
29732
|
-
}, [Z("div",
|
|
29733
|
-
Z("div",
|
|
29737
|
+
}, [Z("div", qF, [
|
|
29738
|
+
Z("div", JF, [Z("span", YF, W(e.messages.skillPanelTitle), 1), Z("button", {
|
|
29734
29739
|
class: "skill-close",
|
|
29735
29740
|
title: e.messages.close,
|
|
29736
29741
|
onClick: n[0] ||= (e) => r("close")
|
|
29737
|
-
}, "✕", 8,
|
|
29738
|
-
Z("div",
|
|
29739
|
-
Z("div",
|
|
29742
|
+
}, "✕", 8, XF)]),
|
|
29743
|
+
Z("div", ZF, [
|
|
29744
|
+
Z("div", QF, [Es(W(u.value ? `${e.messages.skillEditingPrefix}${u.value}` : e.messages.skillCreateNew) + " ", 1), u.value ? (Y(), X("button", {
|
|
29740
29745
|
key: 0,
|
|
29741
29746
|
class: "btn btn-ghost btn-cancel",
|
|
29742
29747
|
title: e.messages.skillCancelEdit,
|
|
29743
29748
|
onClick: h
|
|
29744
|
-
}, W(e.messages.skillCancelEdit), 9,
|
|
29745
|
-
Z("label",
|
|
29749
|
+
}, W(e.messages.skillCancelEdit), 9, $F)) : Q("", !0)]),
|
|
29750
|
+
Z("label", eI, [Z("span", tI, W(e.messages.skillNameLabel), 1), ai(Z("input", {
|
|
29746
29751
|
"onUpdate:modelValue": n[1] ||= (e) => i.value = e,
|
|
29747
29752
|
disabled: !!u.value,
|
|
29748
29753
|
placeholder: e.messages.skillNamePlaceholder,
|
|
29749
29754
|
class: "field-input"
|
|
29750
|
-
}, null, 8,
|
|
29751
|
-
Z("label",
|
|
29755
|
+
}, null, 8, nI), [[Tl, i.value]])]),
|
|
29756
|
+
Z("label", rI, [Z("span", iI, W(e.messages.skillDescLabel), 1), ai(Z("input", {
|
|
29752
29757
|
"onUpdate:modelValue": n[2] ||= (e) => a.value = e,
|
|
29753
29758
|
placeholder: e.messages.skillDescPlaceholder,
|
|
29754
29759
|
class: "field-input"
|
|
29755
|
-
}, null, 8,
|
|
29756
|
-
Z("label",
|
|
29760
|
+
}, null, 8, aI), [[Tl, a.value]])]),
|
|
29761
|
+
Z("label", oI, [Z("span", sI, W(e.messages.skillContentLabel), 1), ai(Z("textarea", {
|
|
29757
29762
|
"onUpdate:modelValue": n[3] ||= (e) => o.value = e,
|
|
29758
29763
|
placeholder: e.messages.skillContentPlaceholder,
|
|
29759
29764
|
rows: "6",
|
|
29760
29765
|
class: "field-input"
|
|
29761
|
-
}, null, 8,
|
|
29762
|
-
s.value ? (Y(), X("div",
|
|
29766
|
+
}, null, 8, cI), [[Tl, o.value]])]),
|
|
29767
|
+
s.value ? (Y(), X("div", lI, W(s.value), 1)) : Q("", !0),
|
|
29763
29768
|
Z("button", {
|
|
29764
29769
|
class: "btn btn-primary",
|
|
29765
29770
|
onClick: f
|
|
29766
29771
|
}, W(u.value ? e.messages.skillSave : e.messages.skillAdd), 1)
|
|
29767
29772
|
]),
|
|
29768
|
-
Z("div",
|
|
29773
|
+
Z("div", uI, [Z("div", dI, W(e.messages.skillCreatedTitle) + "(" + W(c.value.length) + ")", 1), c.value.length ? (Y(), X("ul", pI, [(Y(!0), X(J, null, ga(c.value, (t) => (Y(), X("li", {
|
|
29769
29774
|
key: t,
|
|
29770
29775
|
class: "skill-item"
|
|
29771
|
-
}, [Z("span", { class: Be(["skill-name", { active: u.value === t }]) }, W(t), 3), Z("span",
|
|
29776
|
+
}, [Z("span", { class: Be(["skill-name", { active: u.value === t }]) }, W(t), 3), Z("span", mI, [Z("button", {
|
|
29772
29777
|
class: "btn btn-ghost btn-edit",
|
|
29773
29778
|
title: e.messages.skillEditTitle,
|
|
29774
29779
|
onClick: (e) => m(t)
|
|
29775
|
-
}, W(e.messages.skillEditBtn), 9,
|
|
29780
|
+
}, W(e.messages.skillEditBtn), 9, hI), Z("button", {
|
|
29776
29781
|
class: "btn btn-ghost btn-del",
|
|
29777
29782
|
title: e.messages.skillDeleteTitle,
|
|
29778
29783
|
onClick: (e) => p(t)
|
|
29779
|
-
}, W(e.messages.skillDeleteBtn), 9,
|
|
29780
|
-
Z("div",
|
|
29784
|
+
}, W(e.messages.skillDeleteBtn), 9, gI)])]))), 128))])) : (Y(), X("div", fI, W(e.messages.skillEmpty), 1))]),
|
|
29785
|
+
Z("div", _I, [
|
|
29781
29786
|
Es(" 💡 " + W(e.messages.skillHintA) + " ", 1),
|
|
29782
29787
|
n[5] ||= Z("code", null, "load_skill(name)", -1),
|
|
29783
29788
|
Es(" " + W(e.messages.skillHintB) + " ", 1),
|
|
@@ -29788,7 +29793,7 @@ var Wk = ["innerHTML"], Gk = /* @__PURE__ */ Wi({
|
|
|
29788
29793
|
_: 1
|
|
29789
29794
|
})]));
|
|
29790
29795
|
}
|
|
29791
|
-
}), [["__scopeId", "data-v-fcd21121"]]),
|
|
29796
|
+
}), [["__scopeId", "data-v-fcd21121"]]), yI = /*#__PURE__*/ qT(/* @__PURE__ */ Wi({
|
|
29792
29797
|
__name: "ChatDialog",
|
|
29793
29798
|
props: {
|
|
29794
29799
|
fetchResponse: {},
|
|
@@ -29977,7 +29982,7 @@ var Wk = ["innerHTML"], Gk = /* @__PURE__ */ Wi({
|
|
|
29977
29982
|
key: 0,
|
|
29978
29983
|
name: "cs-slide"
|
|
29979
29984
|
}, {
|
|
29980
|
-
default: ri(() => [_a(t.$slots, "body", { chat: K(i) }, () => [ai(xs(
|
|
29985
|
+
default: ri(() => [_a(t.$slots, "body", { chat: K(i) }, () => [ai(xs(TA, {
|
|
29981
29986
|
"show-avatar": e.showAvatar,
|
|
29982
29987
|
"show-typing": e.showTyping
|
|
29983
29988
|
}, null, 8, ["show-avatar", "show-typing"]), [[Uc, K(a)]])], !0)]),
|
|
@@ -29986,15 +29991,15 @@ var Wk = ["innerHTML"], Gk = /* @__PURE__ */ Wi({
|
|
|
29986
29991
|
h("queued") ? _a(t.$slots, "queued", {
|
|
29987
29992
|
key: 1,
|
|
29988
29993
|
chat: K(i)
|
|
29989
|
-
}, () => [xs(
|
|
29994
|
+
}, () => [xs(FA)], !0) : Q("", !0),
|
|
29990
29995
|
h("approval") ? _a(t.$slots, "approval", {
|
|
29991
29996
|
key: 2,
|
|
29992
29997
|
chat: K(i)
|
|
29993
|
-
}, () => [xs(
|
|
29998
|
+
}, () => [xs(XA)], !0) : Q("", !0),
|
|
29994
29999
|
h("conflict") ? _a(t.$slots, "conflict", {
|
|
29995
30000
|
key: 3,
|
|
29996
30001
|
chat: K(i)
|
|
29997
|
-
}, () => [xs(
|
|
30002
|
+
}, () => [xs(pj, {
|
|
29998
30003
|
"pending-conflict": e.pendingConflict,
|
|
29999
30004
|
"on-resolve": e.onResolveConflict,
|
|
30000
30005
|
icons: K(i).icons,
|
|
@@ -30010,7 +30015,7 @@ var Wk = ["innerHTML"], Gk = /* @__PURE__ */ Wi({
|
|
|
30010
30015
|
key: 2,
|
|
30011
30016
|
name: "cs-slide"
|
|
30012
30017
|
}, {
|
|
30013
|
-
default: ri(() => [_a(t.$slots, "footer", { chat: K(i) }, () => [xs(
|
|
30018
|
+
default: ri(() => [_a(t.$slots, "footer", { chat: K(i) }, () => [xs(Ij, {
|
|
30014
30019
|
placeholder: e.placeholder || K(i).messages.inputPlaceholder,
|
|
30015
30020
|
"input-rows": e.inputRows
|
|
30016
30021
|
}, null, 8, ["placeholder", "input-rows"])], !0)]),
|
|
@@ -30019,7 +30024,7 @@ var Wk = ["innerHTML"], Gk = /* @__PURE__ */ Wi({
|
|
|
30019
30024
|
h("debug") ? _a(t.$slots, "debug", {
|
|
30020
30025
|
key: 3,
|
|
30021
30026
|
chat: K(i)
|
|
30022
|
-
}, () => [xs(
|
|
30027
|
+
}, () => [xs(KF, {
|
|
30023
30028
|
visible: K(o),
|
|
30024
30029
|
"onUpdate:visible": n[4] ||= (e) => /* @__PURE__ */ jn(o) ? o.value = e : null,
|
|
30025
30030
|
logs: e.debugLogs,
|
|
@@ -30045,7 +30050,7 @@ var Wk = ["innerHTML"], Gk = /* @__PURE__ */ Wi({
|
|
|
30045
30050
|
h("skill") ? _a(t.$slots, "skill", {
|
|
30046
30051
|
key: 4,
|
|
30047
30052
|
chat: K(i)
|
|
30048
|
-
}, () => [xs(
|
|
30053
|
+
}, () => [xs(vI, {
|
|
30049
30054
|
visible: K(s),
|
|
30050
30055
|
"on-add-skill": e.onAddSkill,
|
|
30051
30056
|
"on-remove-skill": e.onRemoveSkill,
|
|
@@ -30067,10 +30072,10 @@ var Wk = ["innerHTML"], Gk = /* @__PURE__ */ Wi({
|
|
|
30067
30072
|
}), [["__scopeId", "data-v-e3c6c516"]]);
|
|
30068
30073
|
//#endregion
|
|
30069
30074
|
//#region src/core/sdk/mountChatDialog.ts
|
|
30070
|
-
function
|
|
30075
|
+
function bI(e) {
|
|
30071
30076
|
let { core: t, dialogCfg: n } = e, r = null, i = e.el, a = t.agent.debugLogs;
|
|
30072
30077
|
return r = Pl(/* @__PURE__ */ Wi({ setup() {
|
|
30073
|
-
return () => cc(
|
|
30078
|
+
return () => cc(yI, {
|
|
30074
30079
|
fetchStream: e.streaming ? t.stream : void 0,
|
|
30075
30080
|
fetchResponse: e.streaming ? void 0 : (e, n) => {
|
|
30076
30081
|
if (n) {
|
|
@@ -30190,7 +30195,7 @@ function yI(e) {
|
|
|
30190
30195
|
}
|
|
30191
30196
|
//#endregion
|
|
30192
30197
|
//#region src/core/sdk/ragSubagent.ts
|
|
30193
|
-
function
|
|
30198
|
+
function xI(e, t, n, r, i) {
|
|
30194
30199
|
let a = [];
|
|
30195
30200
|
e && a.push("vfs_grep + vfs_read(搜预注入文档)"), t && a.push(`${r}(语义检索)`), n && a.push(`${i}(按 source 加载)`), a.push("fetch_document(公网 URL)");
|
|
30196
30201
|
let o = [];
|
|
@@ -30205,7 +30210,7 @@ function bI(e, t, n, r, i) {
|
|
|
30205
30210
|
|
|
30206
30211
|
你是只读检索角色,不要尝试修改任何数据。不要尝试上面未列出的工具。`;
|
|
30207
30212
|
}
|
|
30208
|
-
function
|
|
30213
|
+
function SI(e, t, n, r, i) {
|
|
30209
30214
|
let a = [], o = [];
|
|
30210
30215
|
return e && (a.push("- vfs_grep / vfs_read:搜集成方预注入 vfs 的文档(组件文档 / UI 规范)—— 快、静态,先查"), o.push("- 静态文档(组件库文档 / UI 规范):vfs_grep")), t && (a.push(`- ${r}:语义检索(retriever 向量库)—— 模糊匹配,关键词不确定 / 语义相似时用`), o.push(`- 语义相似(「瀑布流组件」「倒计时」「拼团」):${r}`)), n && (a.push(`- ${i}:按 source 精确加载(已知文档 id / URL / key)—— 精确取特定文档`), o.push(`- 已知文档 id / URL:${i}`)), a.push("- fetch_document:公网 URL —— 查公开资料"), o.push("- 公开 URL(设计规范网站 / 第三方文档):fetch_document"), `# 知识检索策略(RAG)
|
|
30211
30216
|
|
|
@@ -30222,12 +30227,12 @@ ${a.join("\n")}
|
|
|
30222
30227
|
## 何时用何源
|
|
30223
30228
|
${o.join("\n")}`;
|
|
30224
30229
|
}
|
|
30225
|
-
var
|
|
30230
|
+
var CI = {
|
|
30226
30231
|
name: "rag-search",
|
|
30227
30232
|
description: "多源知识检索策略:vfs 预注入文档 → 语义检索 → 指定文档加载 → 公网;综合结构化结论 + 溯源",
|
|
30228
|
-
getContent: () =>
|
|
30233
|
+
getContent: () => SI(!0, !0, !0, "search_docs", "load_doc")
|
|
30229
30234
|
};
|
|
30230
|
-
function
|
|
30235
|
+
function wI(e, n, i) {
|
|
30231
30236
|
let a = r(async ({ query: e, topK: t }) => {
|
|
30232
30237
|
try {
|
|
30233
30238
|
let r = await n(e, { topK: t ?? i });
|
|
@@ -30245,7 +30250,7 @@ function CI(e, n, i) {
|
|
|
30245
30250
|
});
|
|
30246
30251
|
return hu([a]), a;
|
|
30247
30252
|
}
|
|
30248
|
-
function
|
|
30253
|
+
function TI(e, n) {
|
|
30249
30254
|
let i = r(async ({ source: e }) => {
|
|
30250
30255
|
try {
|
|
30251
30256
|
let t = await n(e), r = Array.isArray(t) ? t : [t];
|
|
@@ -30260,19 +30265,19 @@ function wI(e, n) {
|
|
|
30260
30265
|
});
|
|
30261
30266
|
return hu([i]), i;
|
|
30262
30267
|
}
|
|
30263
|
-
function
|
|
30268
|
+
function EI(e) {
|
|
30264
30269
|
let { retriever: t, loader: n, useVfs: r = !0, id: i = "rag", description: a, topK: o = 5, searchToolName: s = "search_docs", loadToolName: c = "load_doc", maxToolRounds: l = 8, summarization: u, skills: d, extraTools: f } = e;
|
|
30265
30270
|
if (!t && !n && r === !1) throw Error("[page-agent-sdk][createRagSubagent] 至少配一种知识源:retriever / loader / useVfs(true)");
|
|
30266
30271
|
let p = [];
|
|
30267
|
-
t && p.push(
|
|
30272
|
+
t && p.push(wI(s, t, o)), n && p.push(TI(c, n)), f && p.push(...f);
|
|
30268
30273
|
let m = r ? [
|
|
30269
30274
|
"vfs_grep",
|
|
30270
30275
|
"vfs_read",
|
|
30271
30276
|
"vfs_json_read"
|
|
30272
|
-
] : void 0, h =
|
|
30277
|
+
] : void 0, h = xI(r, !!t, !!n, s, c), g = {
|
|
30273
30278
|
name: "rag-search",
|
|
30274
|
-
description:
|
|
30275
|
-
getContent: () =>
|
|
30279
|
+
description: CI.description,
|
|
30280
|
+
getContent: () => SI(r, !!t, !!n, s, c)
|
|
30276
30281
|
};
|
|
30277
30282
|
return {
|
|
30278
30283
|
id: i,
|
|
@@ -30287,20 +30292,20 @@ function TI(e) {
|
|
|
30287
30292
|
}
|
|
30288
30293
|
//#endregion
|
|
30289
30294
|
//#region src/core/components/CodePreview.vue?vue&type=script&setup=true&lang.ts
|
|
30290
|
-
var
|
|
30295
|
+
var DI = { class: "code-preview-modal" }, OI = { class: "preview-header" }, kI = { class: "preview-title" }, AI = { class: "preview-tabs" }, jI = ["disabled"], MI = { class: "preview-actions" }, NI = ["title"], PI = {
|
|
30291
30296
|
key: 0,
|
|
30292
30297
|
viewBox: "0 0 16 16",
|
|
30293
30298
|
fill: "none",
|
|
30294
30299
|
"aria-hidden": "true"
|
|
30295
|
-
},
|
|
30300
|
+
}, FI = {
|
|
30296
30301
|
key: 1,
|
|
30297
30302
|
viewBox: "0 0 16 16",
|
|
30298
30303
|
fill: "none",
|
|
30299
30304
|
"aria-hidden": "true"
|
|
30300
|
-
},
|
|
30305
|
+
}, II = ["title"], LI = ["title"], RI = { class: "preview-body" }, zI = ["srcdoc"], BI = {
|
|
30301
30306
|
key: 1,
|
|
30302
30307
|
class: "preview-source"
|
|
30303
|
-
},
|
|
30308
|
+
}, VI = /*#__PURE__*/ qT(/* @__PURE__ */ Wi({
|
|
30304
30309
|
__name: "CodePreview",
|
|
30305
30310
|
props: {
|
|
30306
30311
|
code: {},
|
|
@@ -30367,28 +30372,28 @@ app.mount('#app');
|
|
|
30367
30372
|
return (t, n) => (Y(), X("div", {
|
|
30368
30373
|
class: "code-preview-overlay",
|
|
30369
30374
|
onClick: n[3] ||= Ol((e) => r("close"), ["self"])
|
|
30370
|
-
}, [Z("div",
|
|
30371
|
-
Z("span",
|
|
30372
|
-
Z("div",
|
|
30375
|
+
}, [Z("div", DI, [Z("div", OI, [
|
|
30376
|
+
Z("span", kI, W(e.messages.codePreviewTitlePrefix) + W(e.lang), 1),
|
|
30377
|
+
Z("div", AI, [Z("button", {
|
|
30373
30378
|
class: Be({ active: a.value === "preview" }),
|
|
30374
30379
|
disabled: !s.value,
|
|
30375
30380
|
onClick: n[0] ||= (e) => a.value = "preview"
|
|
30376
|
-
}, W(e.messages.codePreviewTab), 11,
|
|
30381
|
+
}, W(e.messages.codePreviewTab), 11, jI), Z("button", {
|
|
30377
30382
|
class: Be({ active: a.value === "source" }),
|
|
30378
30383
|
onClick: n[1] ||= (e) => a.value = "source"
|
|
30379
30384
|
}, W(e.messages.codeSourceTab), 3)]),
|
|
30380
|
-
Z("div",
|
|
30385
|
+
Z("div", MI, [
|
|
30381
30386
|
Z("button", {
|
|
30382
30387
|
class: Be(["icon-btn", { done: o.value }]),
|
|
30383
30388
|
title: o.value ? e.messages.copied : e.messages.codeCopyTitle,
|
|
30384
30389
|
onClick: u
|
|
30385
|
-
}, [o.value ? (Y(), X("svg",
|
|
30390
|
+
}, [o.value ? (Y(), X("svg", PI, [...n[4] ||= [Z("path", {
|
|
30386
30391
|
d: "M3 8.5l3 3 7-7",
|
|
30387
30392
|
stroke: "currentColor",
|
|
30388
30393
|
"stroke-width": "1.6",
|
|
30389
30394
|
"stroke-linecap": "round",
|
|
30390
30395
|
"stroke-linejoin": "round"
|
|
30391
|
-
}, null, -1)]])) : (Y(), X("svg",
|
|
30396
|
+
}, null, -1)]])) : (Y(), X("svg", FI, [...n[5] ||= [Z("rect", {
|
|
30392
30397
|
x: "5.5",
|
|
30393
30398
|
y: "5.5",
|
|
30394
30399
|
width: "8",
|
|
@@ -30400,7 +30405,7 @@ app.mount('#app');
|
|
|
30400
30405
|
d: "M10.5 3.5v-.5A1.5 1.5 0 0 0 9 1.5H3.5A1.5 1.5 0 0 0 2 3v5.5A1.5 1.5 0 0 0 3.5 10H4",
|
|
30401
30406
|
stroke: "currentColor",
|
|
30402
30407
|
"stroke-width": "1.3"
|
|
30403
|
-
}, null, -1)]]))], 10,
|
|
30408
|
+
}, null, -1)]]))], 10, NI),
|
|
30404
30409
|
Z("button", {
|
|
30405
30410
|
class: "icon-btn",
|
|
30406
30411
|
title: e.messages.codeOpenTitle,
|
|
@@ -30420,7 +30425,7 @@ app.mount('#app');
|
|
|
30420
30425
|
"stroke-width": "1.3",
|
|
30421
30426
|
"stroke-linecap": "round",
|
|
30422
30427
|
"stroke-linejoin": "round"
|
|
30423
|
-
})], -1)]], 8,
|
|
30428
|
+
})], -1)]], 8, II),
|
|
30424
30429
|
Z("button", {
|
|
30425
30430
|
class: "icon-btn",
|
|
30426
30431
|
title: e.messages.close,
|
|
@@ -30434,22 +30439,22 @@ app.mount('#app');
|
|
|
30434
30439
|
stroke: "currentColor",
|
|
30435
30440
|
"stroke-width": "1.4",
|
|
30436
30441
|
"stroke-linecap": "round"
|
|
30437
|
-
})], -1)]], 8,
|
|
30442
|
+
})], -1)]], 8, LI)
|
|
30438
30443
|
])
|
|
30439
|
-
]), Z("div",
|
|
30444
|
+
]), Z("div", RI, [a.value === "preview" && s.value ? (Y(), X("iframe", {
|
|
30440
30445
|
key: 0,
|
|
30441
30446
|
ref_key: "iframeRef",
|
|
30442
30447
|
ref: i,
|
|
30443
30448
|
class: "preview-iframe",
|
|
30444
30449
|
sandbox: "allow-scripts allow-modals allow-popups allow-forms",
|
|
30445
30450
|
srcdoc: c.value
|
|
30446
|
-
}, null, 8,
|
|
30451
|
+
}, null, 8, zI)) : (Y(), X("pre", BI, [Z("code", null, W(e.code), 1)]))])])]));
|
|
30447
30452
|
}
|
|
30448
30453
|
}), [["__scopeId", "data-v-27eac25e"]]);
|
|
30449
30454
|
//#endregion
|
|
30450
30455
|
//#region src/core/index.ts
|
|
30451
|
-
function
|
|
30452
|
-
return Jy(e,
|
|
30456
|
+
function HI(e) {
|
|
30457
|
+
return Jy(e, bI);
|
|
30453
30458
|
}
|
|
30454
30459
|
//#endregion
|
|
30455
|
-
export {
|
|
30460
|
+
export { XA as ApprovalBar, zv as CAPABILITIES, Hv as CONTEXT_PRESETS, yI as ChatDialog, CE as ChatHeader, Ij as ChatInput, VI as CodePreview, Z_ as CompressDecisionSchema, pj as ConflictBar, ty as DEFAULT_COMPUTED_STYLES, iw as DEFAULT_DIALOG_ICONS, Sm as DEFAULT_PROMPT_SOFT_CAP, qh as DEFAULT_SYSTEM_PROMPT, Jh as DEFAULT_SYSTEM_PROMPT_EN, KF as DebugDrawer, PE as FocusBar, Pk as HLJS_BLOCK_MAX_CHARS, Kg as HTML_VOID_TAGS, lh as HUMAN_CONFIRM_TOOL_NAME, JT as IconGlyph, Yl as ImageInputError, sw as MESSAGES_EN_US, ow as MESSAGES_ZH_CN, S as MIN_CONTEXT_WINDOW, Mu as MODEL_UNAVAILABLE_GUIDANCE, Kk as MessageContent, TA as MessageList, hA as MessageRow, FA as QueuedBar, xm as SOFT_CAP_MIN_WINDOW, hm as STOP_WORDS, vI as SkillPanel, _p as UNSAFE_KEYS, Cy as actionsToInspectInfo, Sy as actionsToTools, Gl as agentError, Bh as analyzeContext, Mp as applyPatchToClone, Fp as applyPatchToLive, Pg as applyPatchesToBind, Af as arrayMinLength, Wl as asAgentError, M_ as buildCollectorJs, oy as buildCssPath, Yh as buildDataPrompt, O_ as buildDiagnosticsReport, H_ as buildHtmlFragmentSkill, N_ as buildSandboxSrcdoc, Xh as buildSystemPrompt, uw as chatContextKey, Ng as commitSetToBind, z_ as composeStructureThenRender, ou as compressImage, Kh as connectMcp, A as constructLlmFromConfig, te as constructOpenLlmSync, rw as copyText, bf as createAgent, ch as createApprovalMiddleware, dw as createChatContext, HI as createChatSdk, yh as createCheckpointManager, bh as createCheckpointMiddleware, lv as createConflictManager, Vh as createContextInspectorMiddleware, Gg as createDataOps, W_ as createHtmlFormatCheck, R_ as createHtmlRenderCheck, q_ as createHtmlSubagent, fh as createHumanConfirmMiddleware, dh as createHumanConfirmTool, jv as createMemoryBackend, th as createMemoryMiddleware, y as createProxyLlm, EI as createRagSubagent, Ru as createSandboxRunner, Vv as createSdkEvents, By as createSerialRunner, Fv as createSessionStore, Iy as createSkillStore, Km as createSubagentMiddleware, Om as createSubagentTracker, Ym as createSubagentsMiddleware, Ay as createUsageHintsMiddleware, xh as createVerifyMiddleware, eg as createVfs, Nv as createWebStorageBackend, Dh as createWriteBackCheck, Nu as decorateModelUnavailable, Cp as deepClone, Ey as defineDataToolset, Gp as defineSkill, J_ as defineTool, Sp as deleteByPath, Q_ as deriveTitle, Wf as describeSchemaNode, of as detectGarbledToolCall, jd as detectTransitionalReply, zp as diffObjects, dy as domInfoTool, fy as domInspectSkill, uy as domSearchTool, Qv as domToStructure, ey as domTools, Ty as domToolsStatic, jf as elementSchemaCandidates, iy as ensureDomListenerRecorder, _m as estimateMessageTokens, vm as estimateRoundTokens, w as estimateTokens, M as extractReasoningDelta, rp as extractSchemaHint, Hh as extractText, j as extractTextDelta, ne as extractUsage, Jv as fetchDocTools, wy as fetchTools, Rp as findStrippedKeys, Gf as formatConstraints, Bl as formatZodIssues, bp as getByPath, $v as getDomTool, ly as getElementInfo, hy as getEnvSummary, ay as getRecordedListeners, I_ as getSandboxLifecycle, wf as getSchemaAtPath, xf as getSchemaTopKeys, Ap as hashValue, U_ as htmlFragmentSkill, Qf as htmlOrchestratorPrompt, ym as indexSummarize, vy as inspectEnvTool, yy as inspectTools, $_ as isChatModel, Au as isContextLengthError, IT as isIconHtml, ju as isModelUnavailableError, Sf as isPathAllowed, Cv as isQuotaError, vp as isUnsafePath, Ju as jpEval, Hl as jsonParseError, Dp as limitDepth, Bk as markedToHtml, E_ as maskUrlCredentials, Tp as maybeParseValue, b_ as measureWriteScale, Pp as moveByPath, k as normalizeBaseUrl, j_ as normalizeRenderResult, N as normalizeUsage, E as offloadPassThroughChars, T as offloadThresholdChars, Zf as presets, Rf as projectBySchema, Lf as projectBySchemaDeep, Ep as projectFields, bm as recallRounds, L_ as renderInSandbox, Vk as renderMarkdownHtml, Kf as renderSchemaHint, qf as renderSchemaOverview, Xf as renderSchemaShallow, Bv as resolveCapabilities, Wv as resolveContextOptions, Rv as resolveDialogConfig, aw as resolveDialogIcons, lw as resolveDialogMessages, cv as resolveLlm, C as resolveModelCaps, Cm as resolvePromptSoftCap, Df as resolveSchemaPath, Lv as resolveStorage, Lp as restoreInPlace, Ip as restoreLive, Ul as routeError, Qu as runSandboxedScript, yp as safeMerge, my as safeSerialize, Op as safeStringify, sf as sanitizeGarbledContent, BT as sanitizeIconHtml, UT as sanitizeMessageHtml, kf as schemaHasRefinement, sy as searchDom, Xu as searchJson, Dy as selectBuiltinTools, xp as setByPath, wm as shouldTriggerCompression, k_ as stringifyDiagnosticsReport, O as stripStainlessFetch, $f as systemPromptHelpers, gm as tokenize, $ as toolError, Cf as unwrapSchema, nw as useChat, fw as useChatContext, Of as validateAtPath, Jg as validateHtmlFormat, jg as validateRootValueLocally, Mg as validateWriteLocally, jp as watchFieldsHash, e as z, Vl as zodError };
|