@guihz/trading-vue-editor-tes 0.0.60 → 0.0.62
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/lib/assets/{parserTccWorker-CHJsIhut.js → parserTccWorker-Bw7LmssX.js} +46 -46
- package/lib/assets/{scriptsRunWorker-CWty4DVS.js → scriptsRunWorker-B9aWCoDC.js} +2 -2
- package/lib/components/editor/parseScript/buildInFuncNamespace/input.d.ts +0 -2
- package/lib/components/editor/parseScript/constants.d.ts +1 -0
- package/lib/components/editor/parseScript/parseToJs.d.ts +1 -0
- package/lib/components/editor/parseScript/parseToLibJs.d.ts +1 -0
- package/lib/components/editor/parseScript/visitorParser.d.ts +1 -0
- package/lib/components/editor/type/index.d.ts +1 -0
- package/lib/components/editor/utils/parserTcc.d.ts +29 -0
- package/lib/components/editor/utils/scriptsRunWorker.d.ts +15 -0
- package/lib/trading-vue-editor.js +271 -265
- package/lib/trading-vue-editor.umd.cjs +20 -20
- package/package.json +1 -1
@@ -35,14 +35,14 @@ function Z_() {
|
|
35
35
|
return Ps;
|
36
36
|
gc = 1;
|
37
37
|
var a = ir, n = Symbol.for("react.element"), s = Symbol.for("react.fragment"), o = Object.prototype.hasOwnProperty, u = a.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner, c = { key: !0, ref: !0, __self: !0, __source: !0 };
|
38
|
-
function m(h,
|
38
|
+
function m(h, g, b) {
|
39
39
|
var x, T = {}, E = null, R = null;
|
40
|
-
|
41
|
-
for (x in
|
42
|
-
o.call(
|
40
|
+
b !== void 0 && (E = "" + b), g.key !== void 0 && (E = "" + g.key), g.ref !== void 0 && (R = g.ref);
|
41
|
+
for (x in g)
|
42
|
+
o.call(g, x) && !c.hasOwnProperty(x) && (T[x] = g[x]);
|
43
43
|
if (h && h.defaultProps)
|
44
|
-
for (x in
|
45
|
-
T[x] === void 0 && (T[x] =
|
44
|
+
for (x in g = h.defaultProps, g)
|
45
|
+
T[x] === void 0 && (T[x] = g[x]);
|
46
46
|
return { $$typeof: n, type: h, key: E, ref: R, props: T, _owner: u.current };
|
47
47
|
}
|
48
48
|
return Ps.Fragment = s, Ps.jsx = m, Ps.jsxs = m, Ps;
|
@@ -60,7 +60,7 @@ var Es = {};
|
|
60
60
|
var bc;
|
61
61
|
function eg() {
|
62
62
|
return bc || (bc = 1, process.env.NODE_ENV !== "production" && function() {
|
63
|
-
var a = ir, n = Symbol.for("react.element"), s = Symbol.for("react.portal"), o = Symbol.for("react.fragment"), u = Symbol.for("react.strict_mode"), c = Symbol.for("react.profiler"), m = Symbol.for("react.provider"), h = Symbol.for("react.context"),
|
63
|
+
var a = ir, n = Symbol.for("react.element"), s = Symbol.for("react.portal"), o = Symbol.for("react.fragment"), u = Symbol.for("react.strict_mode"), c = Symbol.for("react.profiler"), m = Symbol.for("react.provider"), h = Symbol.for("react.context"), g = Symbol.for("react.forward_ref"), b = Symbol.for("react.suspense"), x = Symbol.for("react.suspense_list"), T = Symbol.for("react.memo"), E = Symbol.for("react.lazy"), R = Symbol.for("react.offscreen"), M = Symbol.iterator, P = "@@iterator";
|
64
64
|
function X(y) {
|
65
65
|
if (y === null || typeof y != "object")
|
66
66
|
return null;
|
@@ -88,7 +88,7 @@ function eg() {
|
|
88
88
|
var A = !1, D = !1, F = !1, U = !1, ie = !1, ae;
|
89
89
|
ae = Symbol.for("react.module.reference");
|
90
90
|
function oe(y) {
|
91
|
-
return !!(typeof y == "string" || typeof y == "function" || y === o || y === c || ie || y === u || y ===
|
91
|
+
return !!(typeof y == "string" || typeof y == "function" || y === o || y === c || ie || y === u || y === b || y === x || U || y === R || A || D || F || typeof y == "object" && y !== null && (y.$$typeof === E || y.$$typeof === T || y.$$typeof === m || y.$$typeof === h || y.$$typeof === g || // This needs to include all possible module reference object
|
92
92
|
// types supported by any Flight configuration anywhere since
|
93
93
|
// we don't know which Flight build this will end up being used
|
94
94
|
// with.
|
@@ -120,7 +120,7 @@ function eg() {
|
|
120
120
|
return "Profiler";
|
121
121
|
case u:
|
122
122
|
return "StrictMode";
|
123
|
-
case
|
123
|
+
case b:
|
124
124
|
return "Suspense";
|
125
125
|
case x:
|
126
126
|
return "SuspenseList";
|
@@ -133,7 +133,7 @@ function eg() {
|
|
133
133
|
case m:
|
134
134
|
var j = y;
|
135
135
|
return bt(j._context) + ".Provider";
|
136
|
-
case
|
136
|
+
case g:
|
137
137
|
return gt(y, y.render, "ForwardRef");
|
138
138
|
case T:
|
139
139
|
var J = y.displayName || null;
|
@@ -316,14 +316,14 @@ function eg() {
|
|
316
316
|
if (typeof y == "string")
|
317
317
|
return jt(y);
|
318
318
|
switch (y) {
|
319
|
-
case
|
319
|
+
case b:
|
320
320
|
return jt("Suspense");
|
321
321
|
case x:
|
322
322
|
return jt("SuspenseList");
|
323
323
|
}
|
324
324
|
if (typeof y == "object")
|
325
325
|
switch (y.$$typeof) {
|
326
|
-
case
|
326
|
+
case g:
|
327
327
|
return Gs(y.render);
|
328
328
|
case T:
|
329
329
|
return Bt(y.type, N, j);
|
@@ -575,7 +575,7 @@ Check the top-level render call using <` + j + ">.");
|
|
575
575
|
var j;
|
576
576
|
if (typeof N == "function")
|
577
577
|
j = N.propTypes;
|
578
|
-
else if (typeof N == "object" && (N.$$typeof ===
|
578
|
+
else if (typeof N == "object" && (N.$$typeof === g || // Note: Memo only checks outer props here.
|
579
579
|
// Inner props are checked in the reconciler.
|
580
580
|
N.$$typeof === T))
|
581
581
|
j = N.propTypes;
|
@@ -707,8 +707,8 @@ function ig(a, n) {
|
|
707
707
|
try {
|
708
708
|
for (var m = a[Symbol.iterator](), h; !(o = (h = m.next()).done) && (s.push(h.value), !(n && s.length === n)); o = !0)
|
709
709
|
;
|
710
|
-
} catch (
|
711
|
-
u = !0, c =
|
710
|
+
} catch (g) {
|
711
|
+
u = !0, c = g;
|
712
712
|
} finally {
|
713
713
|
try {
|
714
714
|
!o && m.return != null && m.return();
|
@@ -784,8 +784,8 @@ function Ls(a) {
|
|
784
784
|
for (var s = this, o = arguments.length, u = new Array(o), c = 0; c < o; c++)
|
785
785
|
u[c] = arguments[c];
|
786
786
|
return u.length >= a.length ? a.apply(this, u) : function() {
|
787
|
-
for (var m = arguments.length, h = new Array(m),
|
788
|
-
h[
|
787
|
+
for (var m = arguments.length, h = new Array(m), g = 0; g < m; g++)
|
788
|
+
h[g] = arguments[g];
|
789
789
|
return n.apply(s, [].concat(u, h));
|
790
790
|
};
|
791
791
|
};
|
@@ -844,15 +844,15 @@ function bg(a) {
|
|
844
844
|
current: a
|
845
845
|
}, o = Ls(vg)(s, n), u = Ls(wg)(s), c = Ls(Wa.changes)(a), m = Ls(xg)(s);
|
846
846
|
function h() {
|
847
|
-
var
|
847
|
+
var b = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : function(x) {
|
848
848
|
return x;
|
849
849
|
};
|
850
|
-
return Wa.selector(
|
850
|
+
return Wa.selector(b), b(s.current);
|
851
851
|
}
|
852
|
-
function b
|
853
|
-
ug(o, u, c, m)(
|
852
|
+
function g(b) {
|
853
|
+
ug(o, u, c, m)(b);
|
854
854
|
}
|
855
|
-
return [h,
|
855
|
+
return [h, g];
|
856
856
|
}
|
857
857
|
function xg(a, n) {
|
858
858
|
return Hs(n) ? n(a.current) : n;
|
@@ -878,8 +878,8 @@ function Dg(a) {
|
|
878
878
|
for (var s = this, o = arguments.length, u = new Array(o), c = 0; c < o; c++)
|
879
879
|
u[c] = arguments[c];
|
880
880
|
return u.length >= a.length ? a.apply(this, u) : function() {
|
881
|
-
for (var m = arguments.length, h = new Array(m),
|
882
|
-
h[
|
881
|
+
for (var m = arguments.length, h = new Array(m), g = 0; g < m; g++)
|
882
|
+
h[g] = arguments[g];
|
883
883
|
return n.apply(s, [].concat(u, h));
|
884
884
|
};
|
885
885
|
};
|
@@ -1068,7 +1068,7 @@ function Jg(a, n, s, o) {
|
|
1068
1068
|
function Tu(a, n) {
|
1069
1069
|
return a.Uri.parse(n);
|
1070
1070
|
}
|
1071
|
-
function Zg({ original: a, modified: n, language: s, originalLanguage: o, modifiedLanguage: u, originalModelPath: c, modifiedModelPath: m, keepCurrentOriginalModel: h = !1, keepCurrentModifiedModel:
|
1071
|
+
function Zg({ original: a, modified: n, language: s, originalLanguage: o, modifiedLanguage: u, originalModelPath: c, modifiedModelPath: m, keepCurrentOriginalModel: h = !1, keepCurrentModifiedModel: g = !1, theme: b = "light", loading: x = "Loading...", options: T = {}, height: E = "100%", width: R = "100%", className: M, wrapperProps: P = {}, beforeMount: X = Bs, onMount: Q = Bs }) {
|
1072
1072
|
let [$, L] = ot(!1), [A, D] = ot(!0), F = Pe(null), U = Pe(null), ie = Pe(null), ae = Pe(Q), oe = Pe(X), gt = Pe(!1);
|
1073
1073
|
vu(() => {
|
1074
1074
|
let G = Li.init();
|
@@ -1094,8 +1094,8 @@ function Zg({ original: a, modified: n, language: s, originalLanguage: o, modifi
|
|
1094
1094
|
U.current.editor.setModelLanguage(G, o || s || "text"), U.current.editor.setModelLanguage(fe, u || s || "text");
|
1095
1095
|
}, [s, o, u], $), _t(() => {
|
1096
1096
|
var G;
|
1097
|
-
(G = U.current) == null || G.editor.setTheme(
|
1098
|
-
}, [
|
1097
|
+
(G = U.current) == null || G.editor.setTheme(b);
|
1098
|
+
}, [b], $), _t(() => {
|
1099
1099
|
var G;
|
1100
1100
|
(G = F.current) == null || G.updateOptions(T);
|
1101
1101
|
}, [T], $);
|
@@ -1108,8 +1108,8 @@ function Zg({ original: a, modified: n, language: s, originalLanguage: o, modifi
|
|
1108
1108
|
(Se = F.current) == null || Se.setModel({ original: G, modified: fe });
|
1109
1109
|
}, [s, n, u, a, o, c, m]), Re = Us(() => {
|
1110
1110
|
var G;
|
1111
|
-
!gt.current && ie.current && (F.current = U.current.editor.createDiffEditor(ie.current, { automaticLayout: !0, ...T }), bt(), (G = U.current) == null || G.editor.setTheme(
|
1112
|
-
}, [T,
|
1111
|
+
!gt.current && ie.current && (F.current = U.current.editor.createDiffEditor(ie.current, { automaticLayout: !0, ...T }), bt(), (G = U.current) == null || G.editor.setTheme(b), L(!0), gt.current = !0);
|
1112
|
+
}, [T, b, bt]);
|
1113
1113
|
Ye(() => {
|
1114
1114
|
$ && ae.current(F.current, U.current);
|
1115
1115
|
}, [$]), Ye(() => {
|
@@ -1118,7 +1118,7 @@ function Zg({ original: a, modified: n, language: s, originalLanguage: o, modifi
|
|
1118
1118
|
function Le() {
|
1119
1119
|
var fe, Se, Oe, lt;
|
1120
1120
|
let G = (fe = F.current) == null ? void 0 : fe.getModel();
|
1121
|
-
h || ((Se = G == null ? void 0 : G.original) == null || Se.dispose()),
|
1121
|
+
h || ((Se = G == null ? void 0 : G.original) == null || Se.dispose()), g || ((Oe = G == null ? void 0 : G.modified) == null || Oe.dispose()), (lt = F.current) == null || lt.dispose();
|
1122
1122
|
}
|
1123
1123
|
return ir.createElement(wu, { width: R, height: E, isEditorReady: $, loading: x, _ref: ie, className: M, wrapperProps: P });
|
1124
1124
|
}
|
@@ -1130,7 +1130,7 @@ function rb(a) {
|
|
1130
1130
|
}, [a]), n.current;
|
1131
1131
|
}
|
1132
1132
|
var sb = rb, Ha = /* @__PURE__ */ new Map();
|
1133
|
-
function ab({ defaultValue: a, defaultLanguage: n, defaultPath: s, value: o, language: u, path: c, theme: m = "light", line: h, loading:
|
1133
|
+
function ab({ defaultValue: a, defaultLanguage: n, defaultPath: s, value: o, language: u, path: c, theme: m = "light", line: h, loading: g = "Loading...", options: b = {}, overrideServices: x = {}, saveViewState: T = !0, keepCurrentModel: E = !1, width: R = "100%", height: M = "100%", className: P, wrapperProps: X = {}, beforeMount: Q = Bs, onMount: $ = Bs, onChange: L, onValidate: A = Bs }) {
|
1134
1134
|
let [D, F] = ot(!1), [U, ie] = ot(!0), ae = Pe(null), oe = Pe(null), gt = Pe(null), bt = Pe($), Re = Pe(Q), Le = Pe(), G = Pe(o), fe = sb(c), Se = Pe(!1), Oe = Pe(!1);
|
1135
1135
|
vu(() => {
|
1136
1136
|
let Z = Li.init();
|
@@ -1141,8 +1141,8 @@ function ab({ defaultValue: a, defaultLanguage: n, defaultPath: s, value: o, lan
|
|
1141
1141
|
Z !== ((we = oe.current) == null ? void 0 : we.getModel()) && (T && Ha.set(fe, (Be = oe.current) == null ? void 0 : Be.saveViewState()), (Gt = oe.current) == null || Gt.setModel(Z), T && ((Ve = oe.current) == null || Ve.restoreViewState(Ha.get(c))));
|
1142
1142
|
}, [c], D), _t(() => {
|
1143
1143
|
var Z;
|
1144
|
-
(Z = oe.current) == null || Z.updateOptions(
|
1145
|
-
}, [
|
1144
|
+
(Z = oe.current) == null || Z.updateOptions(b);
|
1145
|
+
}, [b], D), _t(() => {
|
1146
1146
|
!oe.current || o === void 0 || (oe.current.getOption(ae.current.editor.EditorOption.readOnly) ? oe.current.setValue(o) : o !== oe.current.getValue() && (Oe.current = !0, oe.current.executeEdits("", [{ range: oe.current.getModel().getFullModelRange(), text: o, forceMoveMarkers: !0 }]), oe.current.pushUndoStop(), Oe.current = !1));
|
1147
1147
|
}, [o], D), _t(() => {
|
1148
1148
|
var we, Be;
|
@@ -1160,9 +1160,9 @@ function ab({ defaultValue: a, defaultLanguage: n, defaultPath: s, value: o, lan
|
|
1160
1160
|
if (!(!gt.current || !ae.current) && !Se.current) {
|
1161
1161
|
Re.current(ae.current);
|
1162
1162
|
let we = c || s, Be = as(ae.current, o || a || "", n || u || "", we || "");
|
1163
|
-
oe.current = (Z = ae.current) == null ? void 0 : Z.editor.create(gt.current, { model: Be, automaticLayout: !0, ...
|
1163
|
+
oe.current = (Z = ae.current) == null ? void 0 : Z.editor.create(gt.current, { model: Be, automaticLayout: !0, ...b }, x), T && oe.current.restoreViewState(Ha.get(we)), ae.current.editor.setTheme(m), h !== void 0 && oe.current.revealLine(h), F(!0), Se.current = !0;
|
1164
1164
|
}
|
1165
|
-
}, [a, n, s, o, u, c,
|
1165
|
+
}, [a, n, s, o, u, c, b, x, T, m, h]);
|
1166
1166
|
Ye(() => {
|
1167
1167
|
D && bt.current(oe.current, ae.current);
|
1168
1168
|
}, [D]), Ye(() => {
|
@@ -1193,7 +1193,7 @@ function ab({ defaultValue: a, defaultLanguage: n, defaultPath: s, value: o, lan
|
|
1193
1193
|
var Z, we;
|
1194
1194
|
(Z = Le.current) == null || Z.dispose(), E ? T && Ha.set(c, oe.current.saveViewState()) : (we = oe.current.getModel()) == null || we.dispose(), oe.current.dispose();
|
1195
1195
|
}
|
1196
|
-
return ir.createElement(wu, { width: R, height: M, isEditorReady: D, loading:
|
1196
|
+
return ir.createElement(wu, { width: R, height: M, isEditorReady: D, loading: g, _ref: gt, className: P, wrapperProps: X });
|
1197
1197
|
}
|
1198
1198
|
var nb = ab, ib = Ri(nb);
|
1199
1199
|
const kc = {
|
@@ -60354,8 +60354,8 @@ function mb(a, n = 0, s = !0) {
|
|
60354
60354
|
const o = a[n];
|
60355
60355
|
if (!o)
|
60356
60356
|
return "";
|
60357
|
-
const u = /(Mac|iPhone|iPod|iPad)/i.test(window.navigator.userAgent), { name: c, title: m, desc: h, type:
|
60358
|
-
if (a.length > 1 && R.push(be.italic(`+${a.length - 1} overloads`)), R.push(be.delimiter), h && R.push(be.paragraph(Array.isArray(h) ? h.join(be.lineBreak) : h || "")),
|
60357
|
+
const u = /(Mac|iPhone|iPod|iPad)/i.test(window.navigator.userAgent), { name: c, title: m, desc: h, type: g, syntax: b, returns: x, remarks: T, fields: E } = o, R = [`${be.bold(c)} (${m})`];
|
60358
|
+
if (a.length > 1 && R.push(be.italic(`+${a.length - 1} overloads`)), R.push(be.delimiter), h && R.push(be.paragraph(Array.isArray(h) ? h.join(be.lineBreak) : h || "")), g && R.push(be.paragraph(be.bold(Ct.Type), be.italic(g))), b && b.length && R.push(be.paragraph(be.bold(Ct.Syntax), be.pineCode(b.join(be.lineBreak)))), x && R.push(be.paragraph(be.bold(Ct.Returns), be.lineBreak, x.join(be.lineBreak))), T && T.length && a.length <= 1) {
|
60359
60359
|
let M = "";
|
60360
60360
|
typeof T == "string" ? M = T : M = T.join(be.lineBreak) || "", M.length < 200 && R.push(be.paragraph(be.bold(Ct.Remarks), be.lineBreak, M));
|
60361
60361
|
}
|
@@ -60514,8 +60514,8 @@ class _b {
|
|
60514
60514
|
return [...c, ...m, ...u, ...this._userOutermostNsItems.values()];
|
60515
60515
|
}
|
60516
60516
|
_getAllCompletionItems() {
|
60517
|
-
const { variables: n, keywords: s, types: o, functions: u } = this._builtinSubtreeCache, c = this._getVariableCompletionItems(n), m = this._getKeywordCompletionItems(s), h = this._getTypeCompletionItems(o),
|
60518
|
-
return [...c, ...m, ...h, ...
|
60517
|
+
const { variables: n, keywords: s, types: o, functions: u } = this._builtinSubtreeCache, c = this._getVariableCompletionItems(n), m = this._getKeywordCompletionItems(s), h = this._getTypeCompletionItems(o), g = this._getFunctionCompletionItems(u), b = this._getSnippetsCompletionsList();
|
60518
|
+
return [...c, ...m, ...h, ...g, ...this._outermostNsItems.values(), ...b];
|
60519
60519
|
}
|
60520
60520
|
_getNodeKey(n, s) {
|
60521
60521
|
return `${s}_${n}`;
|
@@ -60543,22 +60543,22 @@ class _b {
|
|
60543
60543
|
_generateTreeSlice(n, s) {
|
60544
60544
|
const o = /* @__PURE__ */ new Map();
|
60545
60545
|
for (const [u, c] of n) {
|
60546
|
-
const [m, ...h] = u.split("."),
|
60546
|
+
const [m, ...h] = u.split("."), g = h.length > 0, b = o.get(this._getNodeKey(m, g ? "ns" : s));
|
60547
60547
|
let x = /* @__PURE__ */ new Map(), T = c.map((R) => ({
|
60548
60548
|
...R,
|
60549
60549
|
name: u
|
60550
60550
|
})), E = this._getNodeKey(u, s);
|
60551
|
-
if (
|
60551
|
+
if (g && s !== "type") {
|
60552
60552
|
const R = /* @__PURE__ */ new Map([[h.join("."), c]]);
|
60553
60553
|
T = [{
|
60554
60554
|
name: m,
|
60555
60555
|
title: xe.namespace
|
60556
60556
|
}], E = this._getNodeKey(m, "ns"), x = this._generateTreeSlice(R, s);
|
60557
60557
|
}
|
60558
|
-
|
60558
|
+
b && (T = [{
|
60559
60559
|
name: m,
|
60560
60560
|
title: xe.namespace
|
60561
|
-
}], x = this._mergeTreeSlices(
|
60561
|
+
}], x = this._mergeTreeSlices(b.children, x)), o.set(E, {
|
60562
60562
|
value: T,
|
60563
60563
|
children: x
|
60564
60564
|
});
|
@@ -60578,30 +60578,30 @@ class _b {
|
|
60578
60578
|
_getVariableCompletionItems(n, s) {
|
60579
60579
|
const o = [], u = [];
|
60580
60580
|
for (const [c, m] of n) {
|
60581
|
-
const { value: h, children:
|
60581
|
+
const { value: h, children: g } = m;
|
60582
60582
|
if (c.startsWith("ns")) {
|
60583
|
-
const
|
60583
|
+
const b = this._getNamespaceCompletionItem(h[0]);
|
60584
60584
|
if (s) {
|
60585
|
-
u.push({ ...
|
60586
|
-
const T = `${s}.${
|
60587
|
-
|
60585
|
+
u.push({ ...b });
|
60586
|
+
const T = `${s}.${b.label}`;
|
60587
|
+
b.label = T, b.insertText = T;
|
60588
60588
|
}
|
60589
|
-
const x = this._getVariableCompletionItems(
|
60590
|
-
s || this._outermostNsItems.set(c,
|
60589
|
+
const x = this._getVariableCompletionItems(g, b.label);
|
60590
|
+
s || this._outermostNsItems.set(c, b), o.push(...x);
|
60591
60591
|
} else {
|
60592
|
-
const
|
60592
|
+
const b = this._getVariableCompletionItem(h[0], s ? 3 : 2);
|
60593
60593
|
if (s) {
|
60594
|
-
u.push({ ...
|
60595
|
-
const { label: x } =
|
60596
|
-
|
60594
|
+
u.push({ ...b });
|
60595
|
+
const { label: x } = b;
|
60596
|
+
b.label = `${s}.${x}`, b.insertText = `${s}.${b.insertText}`, b.filterText = `${x}\r`;
|
60597
60597
|
}
|
60598
|
-
o.push(
|
60598
|
+
o.push(b);
|
60599
60599
|
}
|
60600
60600
|
}
|
60601
60601
|
return u.length && s && this._mergeCompletions(s, u), o;
|
60602
60602
|
}
|
60603
60603
|
_setUserVariableSubItems(n, s) {
|
60604
|
-
var
|
60604
|
+
var b, x, T, E;
|
60605
60605
|
let o = [];
|
60606
60606
|
const u = yb(n.type || ""), c = this._methodNamespaceCache.get(u), m = s ? `${s}.${n.name}` : n.name;
|
60607
60607
|
c && (o = c.filter((R) => {
|
@@ -60613,9 +60613,9 @@ class _b {
|
|
60613
60613
|
}
|
60614
60614
|
return X;
|
60615
60615
|
}));
|
60616
|
-
const { types: h } = St,
|
60617
|
-
if (
|
60618
|
-
for (const R of
|
60616
|
+
const { types: h } = St, g = ((x = (b = this._userTypes.get(u)) == null ? void 0 : b[0]) == null ? void 0 : x.fields) || ((E = (T = h.get(u)) == null ? void 0 : T[0]) == null ? void 0 : E.fields);
|
60617
|
+
if (g)
|
60618
|
+
for (const R of g) {
|
60619
60619
|
const M = R.name, P = R.type, X = this._getInstanceTypeCompletionItemProp({ name: M, type: P });
|
60620
60620
|
this._setUserVariableSubItems({ name: M, type: P }, n.name), o.push({ ...X });
|
60621
60621
|
}
|
@@ -60624,24 +60624,24 @@ class _b {
|
|
60624
60624
|
_getUserVariableCompletionItems(n, s) {
|
60625
60625
|
const o = [], u = [];
|
60626
60626
|
for (const [c, m] of n) {
|
60627
|
-
const { value: h, children:
|
60627
|
+
const { value: h, children: g } = m;
|
60628
60628
|
if (this._setUserVariableSubItems(h[0]), c.startsWith("ns")) {
|
60629
|
-
const
|
60629
|
+
const b = this._getNamespaceCompletionItem(h[0]);
|
60630
60630
|
if (s) {
|
60631
|
-
u.push({ ...
|
60632
|
-
const T = `${s}.${
|
60633
|
-
|
60631
|
+
u.push({ ...b });
|
60632
|
+
const T = `${s}.${b.label}`;
|
60633
|
+
b.label = T, b.insertText = T;
|
60634
60634
|
}
|
60635
|
-
const x = this._getUserVariableCompletionItems(
|
60636
|
-
s || this._userOutermostNsItems.set(c,
|
60635
|
+
const x = this._getUserVariableCompletionItems(g, b.label);
|
60636
|
+
s || this._userOutermostNsItems.set(c, b), o.push(...x);
|
60637
60637
|
} else {
|
60638
|
-
const
|
60638
|
+
const b = this._getVariableCompletionItem(h[0], s ? 2 : 1, !1);
|
60639
60639
|
if (s) {
|
60640
|
-
u.push({ ...
|
60641
|
-
const { label: x } =
|
60642
|
-
|
60640
|
+
u.push({ ...b });
|
60641
|
+
const { label: x } = b;
|
60642
|
+
b.label = `${s}.${x}`, b.insertText = `${s}.${b.insertText}`, b.filterText = `${x}\r`;
|
60643
60643
|
}
|
60644
|
-
o.push(
|
60644
|
+
o.push(b);
|
60645
60645
|
}
|
60646
60646
|
}
|
60647
60647
|
return u.length && s && this._mergeUserCompletions(s, u), o;
|
@@ -60675,19 +60675,19 @@ class _b {
|
|
60675
60675
|
for (const [u, c] of n) {
|
60676
60676
|
const { value: m, children: h } = c;
|
60677
60677
|
if (u.startsWith("ns")) {
|
60678
|
-
const
|
60678
|
+
const g = this._getNamespaceCompletionItem(m[0]);
|
60679
60679
|
if (s) {
|
60680
|
-
o.push({ ...
|
60681
|
-
const
|
60682
|
-
|
60680
|
+
o.push({ ...g });
|
60681
|
+
const b = `${s}.${g.label}`;
|
60682
|
+
g.label = b, g.insertText = b;
|
60683
60683
|
}
|
60684
|
-
this._getMethodNamespaceCache(h,
|
60684
|
+
this._getMethodNamespaceCache(h, g.label);
|
60685
60685
|
} else {
|
60686
|
-
const
|
60687
|
-
if (m.length > 1 && (
|
60688
|
-
o.push({ ...
|
60689
|
-
const { label:
|
60690
|
-
|
60686
|
+
const g = this._getFunctionCompletionItem(m[0], s ? 3 : 2);
|
60687
|
+
if (m.length > 1 && (g.detail = `${g.detail} (+${m.length - 1} overloads)`), s) {
|
60688
|
+
o.push({ ...g });
|
60689
|
+
const { label: b } = g;
|
60690
|
+
g.label = `${s}.${b}`, g.insertText = `${s}.${g.insertText}`, g.filterText = `${b}\r`;
|
60691
60691
|
}
|
60692
60692
|
}
|
60693
60693
|
}
|
@@ -60696,19 +60696,19 @@ class _b {
|
|
60696
60696
|
_getFunctionCompletionItems(n, s, o = !1) {
|
60697
60697
|
const u = [], c = [];
|
60698
60698
|
for (const [m, h] of n) {
|
60699
|
-
const { value:
|
60699
|
+
const { value: g, children: b } = h;
|
60700
60700
|
if (m.startsWith("ns")) {
|
60701
|
-
const x = this._getNamespaceCompletionItem(
|
60701
|
+
const x = this._getNamespaceCompletionItem(g[0]);
|
60702
60702
|
if (s) {
|
60703
60703
|
c.push({ ...x });
|
60704
60704
|
const E = `${s}.${x.label}`;
|
60705
60705
|
x.label = E, x.insertText = E;
|
60706
60706
|
}
|
60707
|
-
const T = this._getFunctionCompletionItems(
|
60707
|
+
const T = this._getFunctionCompletionItems(b, x.label, o);
|
60708
60708
|
s || (o ? this._userOutermostNsItems.set(m, x) : this._outermostNsItems.set(m, x)), u.push(...T);
|
60709
60709
|
} else {
|
60710
|
-
const x = this._getFunctionCompletionItem(
|
60711
|
-
if (
|
60710
|
+
const x = this._getFunctionCompletionItem(g[0], s ? 3 : 2, !o);
|
60711
|
+
if (g.length > 1 && (x.detail = `${x.detail} (+${g.length - 1} overloads)`), s) {
|
60712
60712
|
c.push({ ...x });
|
60713
60713
|
const { label: T } = x;
|
60714
60714
|
x.label = `${s}.${T}`, x.insertText = `${s}.${x.insertText}`, x.filterText = `${T}\r`;
|
@@ -60741,14 +60741,14 @@ class _b {
|
|
60741
60741
|
this._getFuncArgumentsCompletionItemsToCache(u.children, s ? `${s}.${c}` : c);
|
60742
60742
|
else {
|
60743
60743
|
const m = /* @__PURE__ */ new Map();
|
60744
|
-
u.value.reduce((
|
60744
|
+
u.value.reduce((b, x) => {
|
60745
60745
|
const T = x.args;
|
60746
60746
|
return T && T.length && T.forEach((E) => {
|
60747
|
-
|
60748
|
-
}),
|
60747
|
+
b.set(E.name, E);
|
60748
|
+
}), b;
|
60749
60749
|
}, m);
|
60750
|
-
const h = this._getNamedArgumentsCompletionList([...m.values()]),
|
60751
|
-
this._funcArgsCache.set(
|
60750
|
+
const h = this._getNamedArgumentsCompletionList([...m.values()]), g = s ? `${s}.${c}` : c;
|
60751
|
+
this._funcArgsCache.set(g, h);
|
60752
60752
|
}
|
60753
60753
|
}
|
60754
60754
|
}
|
@@ -60759,14 +60759,14 @@ class _b {
|
|
60759
60759
|
this._getUserFuncArgumentsCompletionItemsToCache(u.children, s ? `${s}.${c}` : c);
|
60760
60760
|
else {
|
60761
60761
|
const m = /* @__PURE__ */ new Map();
|
60762
|
-
u.value.reduce((
|
60762
|
+
u.value.reduce((b, x) => {
|
60763
60763
|
const T = x.args;
|
60764
60764
|
return T && T.length && T.forEach((E) => {
|
60765
|
-
|
60766
|
-
}),
|
60765
|
+
b.set(E.name, E);
|
60766
|
+
}), b;
|
60767
60767
|
}, m);
|
60768
|
-
const h = this._getNamedArgumentsCompletionList([...m.values()]),
|
60769
|
-
this._userFuncArgsCache.set(
|
60768
|
+
const h = this._getNamedArgumentsCompletionList([...m.values()]), g = s ? `${s}.${c}` : c;
|
60769
|
+
this._userFuncArgsCache.set(g, h);
|
60770
60770
|
}
|
60771
60771
|
}
|
60772
60772
|
}
|
@@ -60790,14 +60790,14 @@ class _b {
|
|
60790
60790
|
u.length ? m.push(this._createExampleSection(u)) : n.syntax && n.syntax.length && m.push(this._createSyntaxSection(n.syntax));
|
60791
60791
|
const h = {
|
60792
60792
|
value: m.join(this._formatter.lineBreak)
|
60793
|
-
},
|
60793
|
+
}, g = o ? xe.variables : xe.userDefinedVariable;
|
60794
60794
|
return {
|
60795
60795
|
documentation: h,
|
60796
60796
|
label: n.name,
|
60797
60797
|
insertText: n.name,
|
60798
60798
|
kind: et.CompletionItemKind.Variable,
|
60799
60799
|
sortText: `${s}_${n.name}`,
|
60800
|
-
detail: `(${
|
60800
|
+
detail: `(${g}) ${n.type}`
|
60801
60801
|
};
|
60802
60802
|
}
|
60803
60803
|
_getKeywordCompletionItem(n, s = 2) {
|
@@ -60856,14 +60856,14 @@ class _b {
|
|
60856
60856
|
var R;
|
60857
60857
|
const u = n.returnedTypes && n.returnedTypes[0] || n.syntax && n.syntax[0] && ((R = n.syntax[0].split("→").pop()) == null ? void 0 : R.trim()), c = this._extractExamples(n), m = this._extractDescription(n), h = [this._createDescriptionSection(m)];
|
60858
60858
|
c.length ? h.push(this._createExampleSection(c)) : n.syntax && n.syntax.length && h.push(this._createSyntaxSection(n.syntax)), n.returns && n.returns.length && h.push(this._createReturnSection(n.returns));
|
60859
|
-
const
|
60859
|
+
const g = {
|
60860
60860
|
value: h.join(this._formatter.lineBreak)
|
60861
|
-
},
|
60861
|
+
}, b = n.name, x = o ? xe.functions : xe.userDefinedFunction, T = n.template, E = T ? `${db(b)}<\${1}>` : b;
|
60862
60862
|
return {
|
60863
|
-
documentation:
|
60864
|
-
label: T ? `${
|
60863
|
+
documentation: g,
|
60864
|
+
label: T ? `${b.replace(/<.+>/, "")}<type>` : b,
|
60865
60865
|
kind: et.CompletionItemKind.Function,
|
60866
|
-
sortText: `${s}_${
|
60866
|
+
sortText: `${s}_${b}`,
|
60867
60867
|
insertTextRules: et.CompletionItemInsertTextRule.InsertAsSnippet,
|
60868
60868
|
insertText: E + this.bracketsPostfix,
|
60869
60869
|
originInsertText: E,
|
@@ -60971,12 +60971,12 @@ class gb {
|
|
60971
60971
|
}
|
60972
60972
|
return h;
|
60973
60973
|
}
|
60974
|
-
const
|
60975
|
-
if (
|
60976
|
-
return
|
60977
|
-
const
|
60978
|
-
if (
|
60979
|
-
const x = this._matchContent(
|
60974
|
+
const g = this._getFuncsDocVal(c, n, s);
|
60975
|
+
if (g)
|
60976
|
+
return g;
|
60977
|
+
const b = c.match(/[a-zA-Z_][a-zA-Z_0-9]*(\s*\.\s*[a-zA-Z_][a-zA-Z_0-9]*)*(?=\s*<)/g);
|
60978
|
+
if (b) {
|
60979
|
+
const x = this._matchContent(b, c, n);
|
60980
60980
|
if (x) {
|
60981
60981
|
const T = this._getBuildInOther(x.name);
|
60982
60982
|
if (T)
|
@@ -61011,10 +61011,10 @@ class gb {
|
|
61011
61011
|
parseCurrentInputFunc(n, s = !1, o = !1) {
|
61012
61012
|
let u = n.length - 1, c = 0, m = s, h = o;
|
61013
61013
|
for (; u >= 0; ) {
|
61014
|
-
const
|
61015
|
-
if (u -= 1, /['"]/.test(
|
61016
|
-
const
|
61017
|
-
if (
|
61014
|
+
const g = n.charAt(u);
|
61015
|
+
if (u -= 1, /['"]/.test(g)) {
|
61016
|
+
const b = g;
|
61017
|
+
if (g === "'") {
|
61018
61018
|
if (m) {
|
61019
61019
|
m = !1;
|
61020
61020
|
continue;
|
@@ -61025,27 +61025,27 @@ class gb {
|
|
61025
61025
|
}
|
61026
61026
|
for (; u >= 0; ) {
|
61027
61027
|
const x = n.charAt(u);
|
61028
|
-
if (u -= 1, x ===
|
61028
|
+
if (u -= 1, x === b)
|
61029
61029
|
break;
|
61030
61030
|
}
|
61031
61031
|
}
|
61032
|
-
if (!(m || h) && (/\)/.test(
|
61032
|
+
if (!(m || h) && (/\)/.test(g) && (c += 1), /\(/.test(g))) {
|
61033
61033
|
if (c > 0) {
|
61034
61034
|
c -= 1;
|
61035
61035
|
continue;
|
61036
61036
|
}
|
61037
|
-
let
|
61037
|
+
let b = "";
|
61038
61038
|
for (; u >= 0; ) {
|
61039
61039
|
const x = n.charAt(u);
|
61040
|
-
if (u -= 1, !(/\s/.test(x) && !
|
61040
|
+
if (u -= 1, !(/\s/.test(x) && !b)) {
|
61041
61041
|
if (/[^\w.]/.test(x))
|
61042
61042
|
break;
|
61043
|
-
|
61043
|
+
b = x + b;
|
61044
61044
|
}
|
61045
61045
|
}
|
61046
|
-
if (
|
61046
|
+
if (b)
|
61047
61047
|
return {
|
61048
|
-
funcName:
|
61048
|
+
funcName: b,
|
61049
61049
|
startIndex: u + 1
|
61050
61050
|
};
|
61051
61051
|
}
|
@@ -61060,13 +61060,13 @@ class gb {
|
|
61060
61060
|
(x !== -1 && x < h || h === -1) && (h = x);
|
61061
61061
|
}
|
61062
61062
|
h !== -1 && (m = m.substring(0, h));
|
61063
|
-
const
|
61063
|
+
const b = m.replace(/[\w.]+\(.*\)/g, "").split(",").map((x) => {
|
61064
61064
|
const T = x.trim().split("=");
|
61065
61065
|
return T.length <= 1 ? "" : T[0].trim();
|
61066
61066
|
});
|
61067
61067
|
return {
|
61068
61068
|
funcName: u,
|
61069
|
-
args:
|
61069
|
+
args: b
|
61070
61070
|
};
|
61071
61071
|
}
|
61072
61072
|
}
|
@@ -61085,12 +61085,12 @@ class gb {
|
|
61085
61085
|
}, h = this._getBuildInOther(c.name);
|
61086
61086
|
if (h)
|
61087
61087
|
return m.docValue = h, m;
|
61088
|
-
const
|
61089
|
-
if (b)
|
61090
|
-
return Object.assign(m, { docValue: [b], isBuildIn: !1 });
|
61091
|
-
const g = this._getUserTypesDocVal(c.name);
|
61088
|
+
const g = this._getUserVariablesDocVal(c.name, s, o);
|
61092
61089
|
if (g)
|
61093
|
-
return Object.assign(m, { docValue: g, isBuildIn: !1 });
|
61090
|
+
return Object.assign(m, { docValue: [g], isBuildIn: !1 });
|
61091
|
+
const b = this._getUserTypesDocVal(c.name);
|
61092
|
+
if (b)
|
61093
|
+
return Object.assign(m, { docValue: b, isBuildIn: !1 });
|
61094
61094
|
const x = this._getTypesAndFileds(n, c.name, s, o);
|
61095
61095
|
if (x && typeof x != "string")
|
61096
61096
|
return Object.assign(m, { docValue: [x], isBuildIn: !1 });
|
@@ -61098,9 +61098,9 @@ class gb {
|
|
61098
61098
|
}
|
61099
61099
|
}
|
61100
61100
|
_getUserVariablesDocVal(n, s, o) {
|
61101
|
-
const m = [...this._userVariables.get(n) || []].sort((h,
|
61102
|
-
const
|
61103
|
-
return ((
|
61101
|
+
const m = [...this._userVariables.get(n) || []].sort((h, g) => (g.scope || 0) - (h.scope || 0)).find((h) => {
|
61102
|
+
const g = h.range;
|
61103
|
+
return ((g == null ? void 0 : g.startColumn) || 0) <= s && ((g == null ? void 0 : g.startLineNumber) || 0) <= o && ((g == null ? void 0 : g.endLineNumber) || 0) >= o;
|
61104
61104
|
});
|
61105
61105
|
if (m)
|
61106
61106
|
return m.title = xe.userDefinedVariable, m.type = this._arrayTypeTransform(m.type), m;
|
@@ -61114,16 +61114,16 @@ class gb {
|
|
61114
61114
|
var c, m;
|
61115
61115
|
if (s.includes(".")) {
|
61116
61116
|
const h = s.split(".");
|
61117
|
-
let
|
61117
|
+
let g = h[0], b, x = null, T = n.indexOf(s, o - s.length) + 1, E = T + g.length - 1;
|
61118
61118
|
for (const R of h.slice(1)) {
|
61119
61119
|
if (!x) {
|
61120
|
-
const M = T <= o && E >= o, P = this._getUserVariablesDocVal(
|
61120
|
+
const M = T <= o && E >= o, P = this._getUserVariablesDocVal(g, o, u);
|
61121
61121
|
if (M && P)
|
61122
61122
|
return P;
|
61123
61123
|
x = P == null ? void 0 : P.type;
|
61124
61124
|
}
|
61125
61125
|
if (x) {
|
61126
|
-
|
61126
|
+
b = x, T = E + 2, E = E + R.length + 1;
|
61127
61127
|
const M = this._userTypes.get(x) || St.types.get(x), P = (m = (c = M == null ? void 0 : M[0]) == null ? void 0 : c.fields) == null ? void 0 : m.find((X) => X.name === R);
|
61128
61128
|
if (P && T <= o && E >= o)
|
61129
61129
|
return {
|
@@ -61134,9 +61134,9 @@ class gb {
|
|
61134
61134
|
};
|
61135
61135
|
x = P == null ? void 0 : P.type;
|
61136
61136
|
} else
|
61137
|
-
|
61137
|
+
g = `${g}.${R}`, E = E + R.length + 1;
|
61138
61138
|
}
|
61139
|
-
return
|
61139
|
+
return b;
|
61140
61140
|
}
|
61141
61141
|
}
|
61142
61142
|
_getFuncsDocVal(n, s, o) {
|
@@ -61152,12 +61152,12 @@ class gb {
|
|
61152
61152
|
}, h = this._getBuildInFunc(c.name);
|
61153
61153
|
if (h)
|
61154
61154
|
return m.index = this._getOverloadsFuncIndex(h, s, c.name, o), Object.assign(m, { docValue: h });
|
61155
|
-
const
|
61156
|
-
if (b)
|
61157
|
-
return Object.assign(m, { docValue: b, isBuildIn: !1 });
|
61158
|
-
const g = this._getUserVarFuncsDocVal(n, c.name, s, o);
|
61155
|
+
const g = this._getUserFuncsDocVal(c.name);
|
61159
61156
|
if (g)
|
61160
|
-
return Object.assign(m, { docValue:
|
61157
|
+
return m.index = this._getOverloadsFuncIndex(g, s, c.name, o), Object.assign(m, { docValue: g, isBuildIn: !1 });
|
61158
|
+
const b = this._getUserVarFuncsDocVal(n, c.name, s, o);
|
61159
|
+
if (b)
|
61160
|
+
return Object.assign(m, { docValue: [b], isBuildIn: !1 });
|
61161
61161
|
}
|
61162
61162
|
}
|
61163
61163
|
}
|
@@ -61171,25 +61171,31 @@ class gb {
|
|
61171
61171
|
}
|
61172
61172
|
_getUserFuncsDocVal(n) {
|
61173
61173
|
const s = this._userFunctions.get(n);
|
61174
|
-
if (s)
|
61175
|
-
|
61174
|
+
if (s) {
|
61175
|
+
for (const o of s)
|
61176
|
+
o.title = xe.userDefinedFunction;
|
61177
|
+
return s;
|
61178
|
+
}
|
61176
61179
|
}
|
61177
61180
|
_getUserMethodsDocVal(n) {
|
61178
61181
|
const s = this._userMethods.get(n);
|
61179
|
-
if (s)
|
61180
|
-
|
61182
|
+
if (s) {
|
61183
|
+
for (const o of s)
|
61184
|
+
o.title = xe.userDefinedFunction;
|
61185
|
+
return s;
|
61186
|
+
}
|
61181
61187
|
}
|
61182
61188
|
_getUserVarFuncsDocVal(n, s, o, u) {
|
61183
61189
|
var c;
|
61184
61190
|
if (s.includes(".")) {
|
61185
61191
|
const m = s.split("."), h = this._getTypesAndFileds(n, s, o, u);
|
61186
61192
|
if (typeof h == "string") {
|
61187
|
-
const
|
61193
|
+
const b = `${this._arrayTypeTransform(h).replace(/<[^<>]+>/, "").replace(/(series|simple|const|input)\s+([\w\d.]+)/, "$2")}.${m.pop()}`, x = this._getBuildInMethod(b);
|
61188
61194
|
if (x) {
|
61189
|
-
const T = this._getOverloadsFuncIndex(x, o,
|
61190
|
-
return { ...x[0], name:
|
61195
|
+
const T = this._getOverloadsFuncIndex(x, o, b, u);
|
61196
|
+
return { ...x[0], name: b, index: T };
|
61191
61197
|
}
|
61192
|
-
return (c = this._getUserMethodsDocVal(
|
61198
|
+
return (c = this._getUserMethodsDocVal(b)) == null ? void 0 : c[0];
|
61193
61199
|
} else
|
61194
61200
|
return h;
|
61195
61201
|
}
|
@@ -61230,7 +61236,7 @@ var Qa = { exports: {} };
|
|
61230
61236
|
Qa.exports;
|
61231
61237
|
(function(a, n) {
|
61232
61238
|
(function() {
|
61233
|
-
var s, o = "4.17.21", u = 200, c = "Unsupported core-js use. Try https://npms.io/search?q=ponyfill.", m = "Expected a function", h = "Invalid `variable` option passed into `_.template`",
|
61239
|
+
var s, o = "4.17.21", u = 200, c = "Unsupported core-js use. Try https://npms.io/search?q=ponyfill.", m = "Expected a function", h = "Invalid `variable` option passed into `_.template`", g = "__lodash_hash_undefined__", b = 500, x = "__lodash_placeholder__", T = 1, E = 2, R = 4, M = 1, P = 2, X = 1, Q = 2, $ = 4, L = 8, A = 16, D = 32, F = 64, U = 128, ie = 256, ae = 512, oe = 30, gt = "...", bt = 800, Re = 16, Le = 1, G = 2, fe = 3, Se = 1 / 0, Oe = 9007199254740991, lt = 17976931348623157e292, Me = NaN, Z = 4294967295, we = Z - 1, Be = Z >>> 1, Gt = [
|
61234
61240
|
["ary", U],
|
61235
61241
|
["bind", X],
|
61236
61242
|
["bindKey", Q],
|
@@ -61914,7 +61920,7 @@ Qa.exports;
|
|
61914
61920
|
var t = this.__data__;
|
61915
61921
|
if (vs) {
|
61916
61922
|
var r = t[e];
|
61917
|
-
return r ===
|
61923
|
+
return r === g ? s : r;
|
61918
61924
|
}
|
61919
61925
|
return ge.call(t, e) ? t[e] : s;
|
61920
61926
|
}
|
@@ -61924,7 +61930,7 @@ Qa.exports;
|
|
61924
61930
|
}
|
61925
61931
|
function pp(e, t) {
|
61926
61932
|
var r = this.__data__;
|
61927
|
-
return this.size += this.has(e) ? 0 : 1, r[e] = vs && t === s ?
|
61933
|
+
return this.size += this.has(e) ? 0 : 1, r[e] = vs && t === s ? g : t, this;
|
61928
61934
|
}
|
61929
61935
|
kr.prototype.clear = lp, kr.prototype.delete = cp, kr.prototype.get = up, kr.prototype.has = dp, kr.prototype.set = pp;
|
61930
61936
|
function Qt(e) {
|
@@ -61991,7 +61997,7 @@ Qa.exports;
|
|
61991
61997
|
this.add(e[t]);
|
61992
61998
|
}
|
61993
61999
|
function Tp(e) {
|
61994
|
-
return this.__data__.set(e,
|
62000
|
+
return this.__data__.set(e, g), this;
|
61995
62001
|
}
|
61996
62002
|
function Ip(e) {
|
61997
62003
|
return this.__data__.has(e);
|
@@ -63352,7 +63358,7 @@ Qa.exports;
|
|
63352
63358
|
}
|
63353
63359
|
function qm(e) {
|
63354
63360
|
var t = Ma(e, function(i) {
|
63355
|
-
return r.size ===
|
63361
|
+
return r.size === b && r.clear(), i;
|
63356
63362
|
}), r = t.cache;
|
63357
63363
|
return t;
|
63358
63364
|
}
|
@@ -65449,12 +65455,12 @@ class wb {
|
|
65449
65455
|
const u = /* @__PURE__ */ new Map(), c = o.indexOf("(");
|
65450
65456
|
for (let m = c + 1, h = c; m < o.length; m++)
|
65451
65457
|
o[m] !== "," && o[m] !== ")" || (h++, u.set(o.slice(h, m), h), h = m + 1);
|
65452
|
-
return s.map(({ name: m, displayType: h, desc:
|
65453
|
-
const
|
65454
|
-
return
|
65458
|
+
return s.map(({ name: m, displayType: h, desc: g }) => {
|
65459
|
+
const b = [], x = u.get(m), T = x + m.length;
|
65460
|
+
return b.push(this._formatter.paragraph(this._formatter.bold(m), this._formatter.italic(h || ""))), g && b.push(Array.isArray(g) ? g.join(this._formatter.lineBreak) : g), {
|
65455
65461
|
label: [x, T],
|
65456
65462
|
documentation: {
|
65457
|
-
value:
|
65463
|
+
value: b.join(this._formatter.lineBreak)
|
65458
65464
|
}
|
65459
65465
|
};
|
65460
65466
|
});
|
@@ -65477,11 +65483,11 @@ class wb {
|
|
65477
65483
|
const c = s.pop();
|
65478
65484
|
if (c)
|
65479
65485
|
for (const [m, h] of n.entries()) {
|
65480
|
-
const { args:
|
65481
|
-
if (
|
65482
|
-
const
|
65483
|
-
if (
|
65484
|
-
u =
|
65486
|
+
const { args: g } = h;
|
65487
|
+
if (g && g.length) {
|
65488
|
+
const b = g.findIndex((x) => x.name === c);
|
65489
|
+
if (b != -1) {
|
65490
|
+
u = b, o = m;
|
65485
65491
|
break;
|
65486
65492
|
}
|
65487
65493
|
}
|
@@ -65665,16 +65671,16 @@ function Ib(a, n, s) {
|
|
65665
65671
|
return {
|
65666
65672
|
suggestions: []
|
65667
65673
|
};
|
65668
|
-
const m = (R = c[0]) == null ? void 0 : R.match(/.*[^\w.]+([\w.]+)(?=\.)|([\w.]+)(?=\.)/), h = m ? m[1] ? m[1] : m[2] ? m[2] : void 0 : void 0,
|
65674
|
+
const m = (R = c[0]) == null ? void 0 : R.match(/.*[^\w.]+([\w.]+)(?=\.)|([\w.]+)(?=\.)/), h = m ? m[1] ? m[1] : m[2] ? m[2] : void 0 : void 0, g = a.getWordUntilPosition(n), b = ns.parseCurrentInputFunc(u), x = {
|
65669
65675
|
startLineNumber: n.lineNumber,
|
65670
65676
|
endLineNumber: n.lineNumber,
|
65671
|
-
startColumn:
|
65672
|
-
endColumn:
|
65673
|
-
}, T = a.getValueInRange({ ...x, startColumn:
|
65677
|
+
startColumn: g.startColumn,
|
65678
|
+
endColumn: g.endColumn
|
65679
|
+
}, T = a.getValueInRange({ ...x, startColumn: g.endColumn, endColumn: g.endColumn + 1 });
|
65674
65680
|
Ft.nextIsBracket = T === "(";
|
65675
65681
|
let E = Cc(Ft.getSuggestions(h) || [], x);
|
65676
|
-
if (c[0] === "." && (E = []),
|
65677
|
-
const M = Cc(Ft.getArgSuggestions(
|
65682
|
+
if (c[0] === "." && (E = []), b && !h && !/=\s*\w+$/.test(u)) {
|
65683
|
+
const M = Cc(Ft.getArgSuggestions(b.funcName) || [], x);
|
65678
65684
|
E = E.concat(M);
|
65679
65685
|
}
|
65680
65686
|
return {
|
@@ -65712,11 +65718,11 @@ function Ab(a, n) {
|
|
65712
65718
|
startColumn: 1,
|
65713
65719
|
endColumn: n.column
|
65714
65720
|
}, o = a.getValueInRange(s), u = a.findMatches(String(bb), s, !0, !1, null, !0), c = a.findMatches(String(xb), s, !0, !1, null, !0), m = (T = u.pop()) == null ? void 0 : T.matches, h = (E = c.pop()) == null ? void 0 : E.matches;
|
65715
|
-
let b = !1;
|
65716
|
-
u.length % 2 === 0 ? m && m[0] === '"' && (b = !0) : m && !m[0] && (b = !0);
|
65717
65721
|
let g = !1;
|
65718
|
-
|
65719
|
-
|
65722
|
+
u.length % 2 === 0 ? m && m[0] === '"' && (g = !0) : m && !m[0] && (g = !0);
|
65723
|
+
let b = !1;
|
65724
|
+
c.length % 2 === 0 ? h && h[0] === "'" && (b = !0) : h && !h[0] && (b = !0);
|
65725
|
+
const x = ns.parseCurrentInputFuncAndArg(o, b, g);
|
65720
65726
|
if (x) {
|
65721
65727
|
const { funcName: R, args: M } = x, P = vb.getSignatureHelpValues(R, M);
|
65722
65728
|
if (P)
|
@@ -65864,13 +65870,13 @@ xr.prototype = {
|
|
65864
65870
|
}, 0), !0) : A;
|
65865
65871
|
}
|
65866
65872
|
n = this.castInput(n), s = this.castInput(s), n = this.removeEmpty(this.tokenize(n)), s = this.removeEmpty(this.tokenize(s));
|
65867
|
-
var
|
65873
|
+
var g = s.length, b = n.length, x = 1, T = g + b;
|
65868
65874
|
u.maxEditLength && (T = Math.min(T, u.maxEditLength));
|
65869
65875
|
var E = (o = u.timeout) !== null && o !== void 0 ? o : 1 / 0, R = Date.now() + E, M = [{
|
65870
65876
|
oldPos: -1,
|
65871
65877
|
lastComponent: void 0
|
65872
65878
|
}], P = this.extractCommon(M[0], s, n, 0);
|
65873
|
-
if (M[0].oldPos + 1 >=
|
65879
|
+
if (M[0].oldPos + 1 >= b && P + 1 >= g)
|
65874
65880
|
return h([{
|
65875
65881
|
value: this.join(s),
|
65876
65882
|
count: s.length
|
@@ -65883,16 +65889,16 @@ xr.prototype = {
|
|
65883
65889
|
var ie = !1;
|
65884
65890
|
if (U) {
|
65885
65891
|
var ae = U.oldPos - A;
|
65886
|
-
ie = U && 0 <= ae && ae <
|
65892
|
+
ie = U && 0 <= ae && ae < g;
|
65887
65893
|
}
|
65888
|
-
var oe = F && F.oldPos + 1 <
|
65894
|
+
var oe = F && F.oldPos + 1 < b;
|
65889
65895
|
if (!ie && !oe) {
|
65890
65896
|
M[A] = void 0;
|
65891
65897
|
continue;
|
65892
65898
|
}
|
65893
|
-
if (!oe || ie && F.oldPos + 1 < U.oldPos ? D = m.addToPath(U, !0, void 0, 0) : D = m.addToPath(F, void 0, !0, 1), P = m.extractCommon(D, s, n, A), D.oldPos + 1 >=
|
65899
|
+
if (!oe || ie && F.oldPos + 1 < U.oldPos ? D = m.addToPath(U, !0, void 0, 0) : D = m.addToPath(F, void 0, !0, 1), P = m.extractCommon(D, s, n, A), D.oldPos + 1 >= b && P + 1 >= g)
|
65894
65900
|
return h(Eb(m, D.lastComponent, s, n, m.useLongestToken));
|
65895
|
-
M[A] = D, D.oldPos + 1 >=
|
65901
|
+
M[A] = D, D.oldPos + 1 >= b && (Q = Math.min(Q, A - 1)), P + 1 >= g && (X = Math.max(X, A + 1));
|
65896
65902
|
}
|
65897
65903
|
x++;
|
65898
65904
|
}
|
@@ -65932,12 +65938,12 @@ xr.prototype = {
|
|
65932
65938
|
};
|
65933
65939
|
},
|
65934
65940
|
extractCommon: function(n, s, o, u) {
|
65935
|
-
for (var c = s.length, m = o.length, h = n.oldPos,
|
65936
|
-
|
65937
|
-
return
|
65938
|
-
count:
|
65941
|
+
for (var c = s.length, m = o.length, h = n.oldPos, g = h - u, b = 0; g + 1 < c && h + 1 < m && this.equals(s[g + 1], o[h + 1]); )
|
65942
|
+
g++, h++, b++;
|
65943
|
+
return b && (n.lastComponent = {
|
65944
|
+
count: b,
|
65939
65945
|
previousComponent: n.lastComponent
|
65940
|
-
}), n.oldPos = h,
|
65946
|
+
}), n.oldPos = h, g;
|
65941
65947
|
},
|
65942
65948
|
equals: function(n, s) {
|
65943
65949
|
return this.options.comparator ? this.options.comparator(n, s) : n === s || this.options.ignoreCase && n.toLowerCase() === s.toLowerCase();
|
@@ -65961,7 +65967,7 @@ function Eb(a, n, s, o, u) {
|
|
65961
65967
|
for (var c = [], m; n; )
|
65962
65968
|
c.push(n), m = n.previousComponent, delete n.previousComponent, n = m;
|
65963
65969
|
c.reverse();
|
65964
|
-
for (var h = 0,
|
65970
|
+
for (var h = 0, g = c.length, b = 0, x = 0; h < g; h++) {
|
65965
65971
|
var T = c[h];
|
65966
65972
|
if (T.removed) {
|
65967
65973
|
if (T.value = a.join(o.slice(x, x + T.count)), x += T.count, h && c[h - 1].added) {
|
@@ -65970,18 +65976,18 @@ function Eb(a, n, s, o, u) {
|
|
65970
65976
|
}
|
65971
65977
|
} else {
|
65972
65978
|
if (!T.added && u) {
|
65973
|
-
var E = s.slice(
|
65979
|
+
var E = s.slice(b, b + T.count);
|
65974
65980
|
E = E.map(function(P, X) {
|
65975
65981
|
var Q = o[x + X];
|
65976
65982
|
return Q.length > P.length ? Q : P;
|
65977
65983
|
}), T.value = a.join(E);
|
65978
65984
|
} else
|
65979
|
-
T.value = a.join(s.slice(
|
65980
|
-
|
65985
|
+
T.value = a.join(s.slice(b, b + T.count));
|
65986
|
+
b += T.count, T.added || (x += T.count);
|
65981
65987
|
}
|
65982
65988
|
}
|
65983
|
-
var M = c[
|
65984
|
-
return
|
65989
|
+
var M = c[g - 1];
|
65990
|
+
return g > 1 && typeof M.value == "string" && (M.added || M.removed) && a.equals("", M.value) && (c[g - 2].value += M.value, c.pop()), c;
|
65985
65991
|
}
|
65986
65992
|
var Sc = /^[A-Za-z\xC0-\u02C6\u02C8-\u02D7\u02DE-\u02FF\u1E00-\u1EFF]+$/, zc = /\S/, ku = new xr();
|
65987
65993
|
ku.equals = function(a, n) {
|
@@ -66049,11 +66055,11 @@ function Si(a, n, s, o, u) {
|
|
66049
66055
|
}
|
66050
66056
|
if (a && a.toJSON && (a = a.toJSON()), Ka(a) === "object" && a !== null) {
|
66051
66057
|
n.push(a), m = {}, s.push(m);
|
66052
|
-
var h = [],
|
66053
|
-
for (
|
66054
|
-
a.hasOwnProperty(
|
66058
|
+
var h = [], g;
|
66059
|
+
for (g in a)
|
66060
|
+
a.hasOwnProperty(g) && h.push(g);
|
66055
66061
|
for (h.sort(), c = 0; c < h.length; c += 1)
|
66056
|
-
|
66062
|
+
g = h[c], m[g] = Si(a[g], n, s, o, g);
|
66057
66063
|
n.pop(), s.pop();
|
66058
66064
|
} else
|
66059
66065
|
m = a;
|
@@ -66131,8 +66137,8 @@ class jb {
|
|
66131
66137
|
const u = [];
|
66132
66138
|
let c = 0;
|
66133
66139
|
for (const m of n) {
|
66134
|
-
const { added: h, removed:
|
66135
|
-
h ? o && o.removed ? (s = this._changeHandle(u, s, c,
|
66140
|
+
const { added: h, removed: g, count: b = 1, value: x } = m;
|
66141
|
+
h ? o && o.removed ? (s = this._changeHandle(u, s, c, b, Ke.modified), c = 0, o = void 0) : (o && o.added && (s = this._changeHandle(u, s, c, o.count || 1, Ke.added), c = 0), o = m) : g ? o && o.added ? (s = this._changeHandle(u, s, c, o.count || 1, Ke.modified), c = 0, o = void 0) : (o && o.removed && this._addDecorationList(u, s, Ke.removed), o = m) : /^\n+$/.test(x) ? o && (o.added || o.removed) ? c = b : s += b : (o && o.added ? (s = this._changeHandle(u, s, c, o.count || 1, Ke.added), c = 0, o = void 0) : o && o.removed && (this._addDecorationList(u, s, Ke.removed), o = void 0), s += b);
|
66136
66142
|
}
|
66137
66143
|
return o && o.added ? s = this._changeHandle(u, s, c, o.count || 1, Ke.added) : o && o.removed && this._addDecorationList(u, s, Ke.removed), u;
|
66138
66144
|
}
|
@@ -66160,10 +66166,10 @@ class jb {
|
|
66160
66166
|
this._editor.addOverlayWidget(n), this._onMouseDownListener = this._editor.onMouseDown((s) => this._onMouseDownHandle(s)), this._diffPopupWidget = n;
|
66161
66167
|
}
|
66162
66168
|
_onMouseDownHandle(n) {
|
66163
|
-
var m, h,
|
66169
|
+
var m, h, g, b, x, T;
|
66164
66170
|
const s = (m = n.target.element) == null ? void 0 : m.classList, o = s == null ? void 0 : s.contains(`line-${Ke.added}`), u = s == null ? void 0 : s.contains(`line-${Ke.modified}`), c = s == null ? void 0 : s.contains(`line-${Ke.removed}`);
|
66165
66171
|
if (o || u || c) {
|
66166
|
-
const E = ((
|
66172
|
+
const E = ((g = (h = n == null ? void 0 : n.target) == null ? void 0 : h.position) == null ? void 0 : g.lineNumber) || 0, R = ((b = this._editor) == null ? void 0 : b.getTopForLineNumber(E + 1)) || 0, M = ((x = this._editor) == null ? void 0 : x.getScrollTop()) || 0, P = o ? Ke.added : u ? Ke.modified : Ke.removed;
|
66167
66173
|
(T = this._diffPopupWidget) == null || T.show(R - M, R, P), this._diffEditor || (this._diffEditor = this._createDiffEditor()), this._diffEditor.setModel({
|
66168
66174
|
original: this._originalModel,
|
66169
66175
|
modified: this._editor.getModel()
|
@@ -66284,26 +66290,26 @@ class Bb {
|
|
66284
66290
|
openCodeEditor: (n, s, o) => {
|
66285
66291
|
const u = Sb(n, o);
|
66286
66292
|
if (u) {
|
66287
|
-
const { index: c, docValue: m } = u, { title: h, name:
|
66288
|
-
let
|
66293
|
+
const { index: c, docValue: m } = u, { title: h, name: g } = m[c];
|
66294
|
+
let b = "";
|
66289
66295
|
switch (h) {
|
66290
66296
|
case xe.keywords:
|
66291
|
-
|
66297
|
+
b = "kw";
|
66292
66298
|
break;
|
66293
66299
|
case xe.functions:
|
66294
|
-
|
66300
|
+
b = "fun";
|
66295
66301
|
break;
|
66296
66302
|
case xe.variables:
|
66297
|
-
|
66303
|
+
b = "var";
|
66298
66304
|
break;
|
66299
66305
|
case xe.types:
|
66300
|
-
|
66306
|
+
b = "type";
|
66301
66307
|
break;
|
66302
66308
|
case xe.constants:
|
66303
|
-
|
66309
|
+
b = "const";
|
66304
66310
|
break;
|
66305
66311
|
}
|
66306
|
-
this._onLinkOpen && this._onLinkOpen(`${
|
66312
|
+
this._onLinkOpen && this._onLinkOpen(`${b}_${g}`, c);
|
66307
66313
|
}
|
66308
66314
|
return !0;
|
66309
66315
|
}
|
@@ -66421,42 +66427,42 @@ function Su(a, n = globalThis, s = ["*"]) {
|
|
66421
66427
|
console.warn(`Invalid origin '${u.origin}' for comlink proxy`);
|
66422
66428
|
return;
|
66423
66429
|
}
|
66424
|
-
const { id: c, type: m, path: h } = Object.assign({ path: [] }, u.data),
|
66425
|
-
let
|
66430
|
+
const { id: c, type: m, path: h } = Object.assign({ path: [] }, u.data), g = (u.data.argumentList || []).map(Pr);
|
66431
|
+
let b;
|
66426
66432
|
try {
|
66427
66433
|
const x = h.slice(0, -1).reduce((E, R) => E[R], a), T = h.reduce((E, R) => E[R], a);
|
66428
66434
|
switch (m) {
|
66429
66435
|
case "GET":
|
66430
|
-
|
66436
|
+
b = T;
|
66431
66437
|
break;
|
66432
66438
|
case "SET":
|
66433
|
-
x[h.slice(-1)[0]] = Pr(u.data.value),
|
66439
|
+
x[h.slice(-1)[0]] = Pr(u.data.value), b = !0;
|
66434
66440
|
break;
|
66435
66441
|
case "APPLY":
|
66436
|
-
|
66442
|
+
b = T.apply(x, g);
|
66437
66443
|
break;
|
66438
66444
|
case "CONSTRUCT":
|
66439
66445
|
{
|
66440
|
-
const E = new T(...
|
66441
|
-
|
66446
|
+
const E = new T(...g);
|
66447
|
+
b = Jb(E);
|
66442
66448
|
}
|
66443
66449
|
break;
|
66444
66450
|
case "ENDPOINT":
|
66445
66451
|
{
|
66446
66452
|
const { port1: E, port2: R } = new MessageChannel();
|
66447
|
-
Su(a, R),
|
66453
|
+
Su(a, R), b = Qb(E, [E]);
|
66448
66454
|
}
|
66449
66455
|
break;
|
66450
66456
|
case "RELEASE":
|
66451
|
-
|
66457
|
+
b = void 0;
|
66452
66458
|
break;
|
66453
66459
|
default:
|
66454
66460
|
return;
|
66455
66461
|
}
|
66456
66462
|
} catch (x) {
|
66457
|
-
|
66463
|
+
b = { value: x, [Ya]: 0 };
|
66458
66464
|
}
|
66459
|
-
Promise.resolve(
|
66465
|
+
Promise.resolve(b).catch((x) => ({ value: x, [Ya]: 0 })).then((x) => {
|
66460
66466
|
const [T, E] = en(x);
|
66461
66467
|
n.postMessage(Object.assign(Object.assign({}, T), { id: c }), E), m === "RELEASE" && (n.removeEventListener("message", o), zu(n), ki in a && typeof a[ki] == "function" && a[ki]());
|
66462
66468
|
}).catch((x) => {
|
@@ -66513,7 +66519,7 @@ function Ni(a, n = [], s = function() {
|
|
66513
66519
|
return { then: () => u };
|
66514
66520
|
const h = ss(a, {
|
66515
66521
|
type: "GET",
|
66516
|
-
path: n.map((
|
66522
|
+
path: n.map((g) => g.toString())
|
66517
66523
|
}).then(Pr);
|
66518
66524
|
return h.then.bind(h);
|
66519
66525
|
}
|
@@ -66521,37 +66527,37 @@ function Ni(a, n = [], s = function() {
|
|
66521
66527
|
},
|
66522
66528
|
set(c, m, h) {
|
66523
66529
|
Xa(o);
|
66524
|
-
const [
|
66530
|
+
const [g, b] = en(h);
|
66525
66531
|
return ss(a, {
|
66526
66532
|
type: "SET",
|
66527
66533
|
path: [...n, m].map((x) => x.toString()),
|
66528
|
-
value:
|
66529
|
-
},
|
66534
|
+
value: g
|
66535
|
+
}, b).then(Pr);
|
66530
66536
|
},
|
66531
66537
|
apply(c, m, h) {
|
66532
66538
|
Xa(o);
|
66533
|
-
const
|
66534
|
-
if (
|
66539
|
+
const g = n[n.length - 1];
|
66540
|
+
if (g === Ub)
|
66535
66541
|
return ss(a, {
|
66536
66542
|
type: "ENDPOINT"
|
66537
66543
|
}).then(Pr);
|
66538
|
-
if (
|
66544
|
+
if (g === "bind")
|
66539
66545
|
return Ni(a, n.slice(0, -1));
|
66540
|
-
const [
|
66546
|
+
const [b, x] = Nc(h);
|
66541
66547
|
return ss(a, {
|
66542
66548
|
type: "APPLY",
|
66543
66549
|
path: n.map((T) => T.toString()),
|
66544
|
-
argumentList:
|
66550
|
+
argumentList: b
|
66545
66551
|
}, x).then(Pr);
|
66546
66552
|
},
|
66547
66553
|
construct(c, m) {
|
66548
66554
|
Xa(o);
|
66549
|
-
const [h,
|
66555
|
+
const [h, g] = Nc(m);
|
66550
66556
|
return ss(a, {
|
66551
66557
|
type: "CONSTRUCT",
|
66552
|
-
path: n.map((
|
66558
|
+
path: n.map((b) => b.toString()),
|
66553
66559
|
argumentList: h
|
66554
|
-
},
|
66560
|
+
}, g).then(Pr);
|
66555
66561
|
}
|
66556
66562
|
});
|
66557
66563
|
return Kb(u, a), u;
|
@@ -66610,11 +66616,11 @@ function ss(a, n, s) {
|
|
66610
66616
|
function Zb() {
|
66611
66617
|
return new Array(4).fill(0).map(() => Math.floor(Math.random() * Number.MAX_SAFE_INTEGER).toString(16)).join("-");
|
66612
66618
|
}
|
66613
|
-
const Pu = new Worker(new URL("" + new URL("assets/scriptsRunWorker-
|
66619
|
+
const Pu = new Worker(new URL("" + new URL("assets/scriptsRunWorker-B9aWCoDC.js", import.meta.url).href, import.meta.url), { type: "module", name: "Run TccScript Server" });
|
66614
66620
|
Pu.onerror = (a) => {
|
66615
66621
|
console.error(a);
|
66616
66622
|
};
|
66617
|
-
const Eu = Wi(Pu), ex = Wi(new Worker(new URL("" + new URL("assets/parserTccWorker-
|
66623
|
+
const Eu = Wi(Pu), ex = Wi(new Worker(new URL("" + new URL("assets/parserTccWorker-Bw7LmssX.js", import.meta.url).href, import.meta.url), { type: "module", name: "Parser TccScript Server" }));
|
66618
66624
|
async function tx(a, n = !1) {
|
66619
66625
|
const { functions: s, types: o, constants: u, variables: c, methods: m } = St;
|
66620
66626
|
return await ex(a, n, { functions: Object.fromEntries(s), methods: Object.fromEntries(m), types: Object.fromEntries(o), constants: Object.fromEntries(u), variables: Object.fromEntries(c) });
|
@@ -66783,7 +66789,7 @@ self.MonacoEnvironment = {
|
|
66783
66789
|
Li.config({ monaco: K_ });
|
66784
66790
|
let cu = {};
|
66785
66791
|
const nx = (a, n) => {
|
66786
|
-
const { height: s, width: o, theme: u, options: c, hasDiff: m, readOnly: h, defaultValue:
|
66792
|
+
const { height: s, width: o, theme: u, options: c, hasDiff: m, readOnly: h, defaultValue: g, onChange: b, onLinkOpen: x, onDeclareConfigChange: T, onCursorPositionChange: E, onActionTrigger: R, onEditorDidMount: M } = a, P = Pe(null);
|
66787
66793
|
hu(n, () => ({
|
66788
66794
|
setOriginalScript(A) {
|
66789
66795
|
var D;
|
@@ -66826,11 +66832,11 @@ const nx = (a, n) => {
|
|
66826
66832
|
var U, ie, ae;
|
66827
66833
|
Ft.initBuiltinsTrees(), P.current = new Bb(A, D, R), x && ((U = P.current) == null || U.addLinkOpenFunc(x)), m && ((ie = P.current) == null || ie.addDiffDecorations()), hb(A), (ae = P.current) == null || ae.setEditorLayout(Number(s));
|
66828
66834
|
const F = A.getValue();
|
66829
|
-
P.current.onChangeCursorPosition(E),
|
66835
|
+
P.current.onChangeCursorPosition(E), b && b(F), !h && Q(F), M && M();
|
66830
66836
|
}
|
66831
66837
|
const Q = Us(async (A) => {
|
66832
66838
|
var lt;
|
66833
|
-
const D = Date.now(), { errors: F, functions: U, methods: ie, types: ae, variables: oe, overloadsFuncs: gt, preParserCode: bt } = await tx(A
|
66839
|
+
const D = Date.now(), { errors: F, functions: U, methods: ie, types: ae, variables: oe, overloadsFuncs: gt, preParserCode: bt } = await tx(A), Re = new Map(Object.entries(U)), Le = new Map(Object.entries(ie)), G = new Map(Object.entries(ae)), fe = new Map(Object.entries(oe));
|
66834
66840
|
ns.setUserDefined({
|
66835
66841
|
functions: Re,
|
66836
66842
|
methods: Le,
|
@@ -66869,9 +66875,9 @@ const nx = (a, n) => {
|
|
66869
66875
|
Q(A || "");
|
66870
66876
|
return;
|
66871
66877
|
}
|
66872
|
-
(D = P.current) == null || D.setModelMarkers([]), A !== void 0 && (
|
66878
|
+
(D = P.current) == null || D.setModelMarkers([]), A !== void 0 && (b && b(A), $(A));
|
66873
66879
|
}
|
66874
|
-
return O.jsx(ib, { height: s, width: o || "100%", defaultLanguage: Ee, defaultValue:
|
66880
|
+
return O.jsx(ib, { height: s, width: o || "100%", defaultLanguage: Ee, defaultValue: g || `indicator("我的脚本")
|
66875
66881
|
plot(close)
|
66876
66882
|
`, theme: u || "vs-dark", className: `tvue-script ${u || "vs-dark"}`, options: {
|
66877
66883
|
colorDecorators: !0,
|
@@ -66889,10 +66895,10 @@ plot(close)
|
|
66889
66895
|
...c
|
66890
66896
|
}, onMount: X, onChange: L });
|
66891
66897
|
}, Nx = yu(nx), Ox = (a) => {
|
66892
|
-
const { theme: n, modified: s, original: o, height: u, width: c, renderSideBySide: m = !0 } = a, h = Us((
|
66893
|
-
|
66898
|
+
const { theme: n, modified: s, original: o, height: u, width: c, renderSideBySide: m = !0 } = a, h = Us((g, b) => {
|
66899
|
+
b.languages.register({
|
66894
66900
|
id: Ee
|
66895
|
-
}),
|
66901
|
+
}), b.editor.defineTheme("vs-dark", Bi), b.editor.defineTheme("vs", ji), b.languages.setMonarchTokensProvider(Ee, Mi), b.languages.setLanguageConfiguration(Ee, Fi);
|
66896
66902
|
}, []);
|
66897
66903
|
return O.jsx(tb, { height: u || "90vh", width: c || "100%", theme: n || "vs-dark", options: {
|
66898
66904
|
readOnly: !0,
|
@@ -66935,7 +66941,7 @@ function cx(a) {
|
|
66935
66941
|
return a.replace(/#{\s*key\s*}/g, n);
|
66936
66942
|
}
|
66937
66943
|
function ux(a, n) {
|
66938
|
-
var s, o, u, c, m, h,
|
66944
|
+
var s, o, u, c, m, h, g = !1;
|
66939
66945
|
n || (n = {}), s = n.debug || !1;
|
66940
66946
|
try {
|
66941
66947
|
u = ox(), c = document.createRange(), m = document.getSelection(), h = document.createElement("span"), h.textContent = a, h.ariaHidden = "true", h.style.all = "unset", h.style.position = "fixed", h.style.top = 0, h.style.clip = "rect(0, 0, 0, 0)", h.style.whiteSpace = "pre", h.style.webkitUserSelect = "text", h.style.MozUserSelect = "text", h.style.msUserSelect = "text", h.style.userSelect = "text", h.addEventListener("copy", function(x) {
|
@@ -66948,21 +66954,21 @@ function ux(a, n) {
|
|
66948
66954
|
x.clipboardData.clearData(), x.clipboardData.setData(n.format, a);
|
66949
66955
|
n.onCopy && (x.preventDefault(), n.onCopy(x.clipboardData));
|
66950
66956
|
}), document.body.appendChild(h), c.selectNodeContents(h), m.addRange(c);
|
66951
|
-
var
|
66952
|
-
if (!
|
66957
|
+
var b = document.execCommand("copy");
|
66958
|
+
if (!b)
|
66953
66959
|
throw new Error("copy command was unsuccessful");
|
66954
|
-
|
66960
|
+
g = !0;
|
66955
66961
|
} catch (x) {
|
66956
66962
|
s && console.error("unable to copy using execCommand: ", x), s && console.warn("trying IE specific stuff");
|
66957
66963
|
try {
|
66958
|
-
window.clipboardData.setData(n.format || "text", a), n.onCopy && n.onCopy(window.clipboardData),
|
66964
|
+
window.clipboardData.setData(n.format || "text", a), n.onCopy && n.onCopy(window.clipboardData), g = !0;
|
66959
66965
|
} catch (T) {
|
66960
66966
|
s && console.error("unable to copy using clipboardData: ", T), s && console.error("falling back to prompt"), o = cx("message" in n ? n.message : lx), window.prompt(o, a);
|
66961
66967
|
}
|
66962
66968
|
} finally {
|
66963
66969
|
m && (typeof m.removeRange == "function" ? m.removeRange(c) : m.removeAllRanges()), h && document.body.removeChild(h), u();
|
66964
66970
|
}
|
66965
|
-
return
|
66971
|
+
return g;
|
66966
66972
|
}
|
66967
66973
|
var dx = ux;
|
66968
66974
|
function Oi(a) {
|
@@ -67097,8 +67103,8 @@ var Mu = /* @__PURE__ */ function(a) {
|
|
67097
67103
|
for (var u = arguments.length, c = new Array(u), m = 0; m < u; m++)
|
67098
67104
|
c[m] = arguments[m];
|
67099
67105
|
return o = n.call.apply(n, [this].concat(c)), Hi(Lu(o), "onClick", function(h) {
|
67100
|
-
var
|
67101
|
-
x && x(
|
67106
|
+
var g = o.props, b = g.text, x = g.onCopy, T = g.children, E = g.options, R = Ga.default.Children.only(T), M = (0, px.default)(b, E);
|
67107
|
+
x && x(b, M), R && R.props && typeof R.props.onClick == "function" && R.props.onClick(h);
|
67102
67108
|
}), o;
|
67103
67109
|
}
|
67104
67110
|
return _x(s, [{
|
@@ -67126,7 +67132,7 @@ async function Ix(a, n = 0) {
|
|
67126
67132
|
const s = a[n];
|
67127
67133
|
if (!s)
|
67128
67134
|
return;
|
67129
|
-
const { name: o, args: u, type: c, desc: m, examples: h, remarks:
|
67135
|
+
const { name: o, args: u, type: c, desc: m, examples: h, remarks: g, seeAlso: b, syntax: x, detailedDesc: T, fields: E, returns: R } = s, M = {
|
67130
67136
|
name: o
|
67131
67137
|
};
|
67132
67138
|
if (a.length > 1 && (M.overloads = `${a.length} overloads`), c && (M.type = c), u && (M.name = `${o}()`, M.args = u.map((P) => {
|
@@ -67153,7 +67159,7 @@ async function Ix(a, n = 0) {
|
|
67153
67159
|
});
|
67154
67160
|
}
|
67155
67161
|
}
|
67156
|
-
return R && (M.returns = R.map((P) => Or(P))),
|
67162
|
+
return R && (M.returns = R.map((P) => Or(P))), g && (M.remarks = typeof g == "string" ? [Or(g)] : g.map((P) => Or(P))), x && (M.syntax = a.map((P) => {
|
67157
67163
|
var X;
|
67158
67164
|
return (X = P.syntax) == null ? void 0 : X[0];
|
67159
67165
|
})), E && (M.fields = E.map((P) => {
|
@@ -67162,7 +67168,7 @@ async function Ix(a, n = 0) {
|
|
67162
67168
|
label: `${X} (${$})`,
|
67163
67169
|
desc: Q && Or(Q)
|
67164
67170
|
};
|
67165
|
-
})),
|
67171
|
+
})), b && (M.seeAlso = b.map((P) => Dx(P))), M;
|
67166
67172
|
}
|
67167
67173
|
function Dx(a) {
|
67168
67174
|
const s = /\[([^\[\]]+)\]\(([^\(\)]+)\)/g.exec(a);
|
@@ -67198,16 +67204,16 @@ function kx(a) {
|
|
67198
67204
|
}
|
67199
67205
|
for (const [c, m] of St[u.key])
|
67200
67206
|
for (const h of m) {
|
67201
|
-
const { name:
|
67202
|
-
label:
|
67207
|
+
const { name: g, args: b, type: x, desc: T, examples: E, remarks: R, seeAlso: M, syntax: P, detailedDesc: X, fields: Q, returns: $ } = h, L = {
|
67208
|
+
label: g,
|
67203
67209
|
group: u,
|
67204
|
-
key: `${u.prefix}_${
|
67210
|
+
key: `${u.prefix}_${g}`
|
67205
67211
|
};
|
67206
|
-
if (u.prefix === "fun" && (L.label = `${
|
67212
|
+
if (u.prefix === "fun" && (L.label = `${g}()`), L.label.includes(a))
|
67207
67213
|
break;
|
67208
|
-
if (
|
67214
|
+
if (b) {
|
67209
67215
|
let A = !1;
|
67210
|
-
for (const D of
|
67216
|
+
for (const D of b) {
|
67211
67217
|
const { name: F, desc: U, displayType: ie } = D;
|
67212
67218
|
if (F.includes(a) || U != null && U.includes(a) || ie != null && ie.includes(a)) {
|
67213
67219
|
s.push(L), A = !0;
|
@@ -67315,13 +67321,13 @@ function kx(a) {
|
|
67315
67321
|
}
|
67316
67322
|
const Ax = (a) => {
|
67317
67323
|
var $;
|
67318
|
-
const { group: n, itemKey: s, onItemClick: o, currentIndex: u } = a, [c, m] = ot(), [h,
|
67324
|
+
const { group: n, itemKey: s, onItemClick: o, currentIndex: u } = a, [c, m] = ot(), [h, g] = ot(0), [b, x] = ot("Copy code"), [T, E] = ot("Copy link");
|
67319
67325
|
Ye(() => {
|
67320
67326
|
R(u);
|
67321
67327
|
}, [s]);
|
67322
67328
|
const R = (L) => {
|
67323
67329
|
const A = s.replace(`${n == null ? void 0 : n.prefix}_`, ""), D = St[n == null ? void 0 : n.key].get(A);
|
67324
|
-
|
67330
|
+
g(L), D && Ix(D, L).then((F) => {
|
67325
67331
|
m(F);
|
67326
67332
|
});
|
67327
67333
|
}, M = (L) => {
|
@@ -67351,11 +67357,11 @@ const Ax = (a) => {
|
|
67351
67357
|
__html: L.desc || ""
|
67352
67358
|
} })] }, A))] }), (c == null ? void 0 : c.fields) && O.jsxs($t, { children: [O.jsx("div", { className: "manual-content-sub-title", children: "fields" }), c.fields.map((L, A) => O.jsxs("div", { className: "manual-content-text", children: [O.jsx("span", { className: "manual-content-args-label", children: L.label }), " ", O.jsx("span", { dangerouslySetInnerHTML: {
|
67353
67359
|
__html: L.desc || ""
|
67354
|
-
} })] }, A))] }), (c == null ? void 0 : c.examples) && O.jsxs($t, { children: [O.jsxs("div", { className: "manual-content-sub-title manual-content-example-header", children: [O.jsx("div", { children: O.jsx("span", { children: "example" }) }), O.jsx(Ai, { text: c.originalExample || "", onCopy: X, children: O.jsx("div", { "data-tooltip":
|
67360
|
+
} })] }, A))] }), (c == null ? void 0 : c.examples) && O.jsxs($t, { children: [O.jsxs("div", { className: "manual-content-sub-title manual-content-example-header", children: [O.jsx("div", { children: O.jsx("span", { children: "example" }) }), O.jsx(Ai, { text: c.originalExample || "", onCopy: X, children: O.jsx("div", { "data-tooltip": b, className: "manual-content-btn manual-content-example-copy", children: O.jsx("svg", { xmlns: "http://www.w3.org/2000/svg", width: "28", height: "28", fill: "none", children: O.jsx("path", { stroke: "currentColor", d: "M8 9.5H6.5a1 1 0 0 0-1 1v11a1 1 0 0 0 1 1h11a1 1 0 0 0 1-1V20m-8-1.5h11a1 1 0 0 0 1-1v-11a1 1 0 0 0-1-1h-11a1 1 0 0 0-1 1v11a1 1 0 0 0 1 1z" }) }) }) })] }), O.jsx("pre", { className: "manual-content-example", children: O.jsx("code", { dangerouslySetInnerHTML: {
|
67355
67361
|
__html: c.examples
|
67356
67362
|
} }) })] }), (c == null ? void 0 : c.detailedDesc) && c.detailedDesc.map((L, A) => O.jsxs($t, { children: [L.desc.map((D, F) => O.jsx("div", { className: "manual-content-text", dangerouslySetInnerHTML: {
|
67357
67363
|
__html: D
|
67358
|
-
} }, F)), O.jsxs("div", { className: "manual-content-sub-title manual-content-example-header", children: [O.jsx("div", { children: O.jsx("span", { children: "example" }) }), O.jsx(Ai, { text: L.originalExample || "", onCopy: X, children: O.jsx("div", { "data-tooltip":
|
67364
|
+
} }, F)), O.jsxs("div", { className: "manual-content-sub-title manual-content-example-header", children: [O.jsx("div", { children: O.jsx("span", { children: "example" }) }), O.jsx(Ai, { text: L.originalExample || "", onCopy: X, children: O.jsx("div", { "data-tooltip": b, className: "manual-content-btn manual-content-example-copy", children: O.jsx("svg", { xmlns: "http://www.w3.org/2000/svg", width: "28", height: "28", fill: "none", children: O.jsx("path", { stroke: "currentColor", d: "M8 9.5H6.5a1 1 0 0 0-1 1v11a1 1 0 0 0 1 1h11a1 1 0 0 0 1-1V20m-8-1.5h11a1 1 0 0 0 1-1v-11a1 1 0 0 0-1-1h-11a1 1 0 0 0-1 1v11a1 1 0 0 0 1 1z" }) }) }) })] }), O.jsx("pre", { className: "manual-content-example", children: O.jsx("code", { dangerouslySetInnerHTML: {
|
67359
67365
|
__html: L.examples || ""
|
67360
67366
|
} }) })] }, A)), (c == null ? void 0 : c.returns) && O.jsxs($t, { children: [O.jsx("div", { className: "manual-content-sub-title", children: "returns" }), c.returns.map((L, A) => O.jsx("div", { className: "manual-content-text", dangerouslySetInnerHTML: {
|
67361
67367
|
__html: L
|
@@ -67371,7 +67377,7 @@ Ws.defineTheme("vs", ji);
|
|
67371
67377
|
et.setMonarchTokensProvider(Ee, Mi);
|
67372
67378
|
et.setLanguageConfiguration(Ee, Fi);
|
67373
67379
|
const Px = ({ theme: a = "vs-dark", currentKey: n, currentIndex: s = 0 }) => {
|
67374
|
-
const [o, u] = ot(Ms[0]), [c, m] = ot(null), [h,
|
67380
|
+
const [o, u] = ot(Ms[0]), [c, m] = ot(null), [h, g] = ot(0), [b, x] = ot(""), [T, E] = ot("var_bar_index"), R = Pe(null), M = Pe(null), P = (D) => {
|
67375
67381
|
D.key === (o == null ? void 0 : o.key) && !(o != null && o.isHidden) ? u({ ...D, isHidden: !0 }) : u(D);
|
67376
67382
|
};
|
67377
67383
|
Ye(() => {
|
@@ -67379,12 +67385,12 @@ const Px = ({ theme: a = "vs-dark", currentKey: n, currentIndex: s = 0 }) => {
|
|
67379
67385
|
}, [a]), Ye(() => {
|
67380
67386
|
if (n) {
|
67381
67387
|
const [D] = n.split("_"), F = Ms.find((U) => D === U.prefix);
|
67382
|
-
F && (
|
67388
|
+
F && (g(s), L(F, n));
|
67383
67389
|
}
|
67384
67390
|
}, [n]);
|
67385
67391
|
const X = (D, F) => {
|
67386
67392
|
var U;
|
67387
|
-
D !== T && (F && u(F),
|
67393
|
+
D !== T && (F && u(F), g(0), E(D), (U = M.current) == null || U.scrollTo({ top: 0 }));
|
67388
67394
|
}, Q = (D) => {
|
67389
67395
|
if (D.target.value.trim() === "")
|
67390
67396
|
$();
|
@@ -67408,11 +67414,11 @@ const Px = ({ theme: a = "vs-dark", currentKey: n, currentIndex: s = 0 }) => {
|
|
67408
67414
|
const F = Ms.find((U) => D.startsWith(U.prefix));
|
67409
67415
|
F && L(F, D);
|
67410
67416
|
};
|
67411
|
-
return O.jsxs("div", { className: `${a} manual-warpper`, children: [O.jsxs("div", { className: "manual-left", children: [O.jsxs("div", { className: "manual-search", children: [O.jsx("span", { className: "manual-search-icon", children: O.jsx("svg", { xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 18 18", width: "18px", height: "18px", children: O.jsx("path", { fillRule: "evenodd", d: "M12.5 11h-.79l-.28-.27A6.47 6.47 0 0 0 13 6.5 6.5 6.5 0 1 0 6.5 13c1.61 0 3.09-.59 4.23-1.57l.27.28v.79l5 4.99L17.49 16l-4.99-5zm-6 0C4.01 11 2 8.99 2 6.5S4.01 2 6.5 2 11 4.01 11 6.5 8.99 11 6.5 11z" }) }) }), O.jsx("input", { onChange: Q, spellCheck: "false", value:
|
67417
|
+
return O.jsxs("div", { className: `${a} manual-warpper`, children: [O.jsxs("div", { className: "manual-left", children: [O.jsxs("div", { className: "manual-search", children: [O.jsx("span", { className: "manual-search-icon", children: O.jsx("svg", { xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 18 18", width: "18px", height: "18px", children: O.jsx("path", { fillRule: "evenodd", d: "M12.5 11h-.79l-.28-.27A6.47 6.47 0 0 0 13 6.5 6.5 6.5 0 1 0 6.5 13c1.61 0 3.09-.59 4.23-1.57l.27.28v.79l5 4.99L17.49 16l-4.99-5zm-6 0C4.01 11 2 8.99 2 6.5S4.01 2 6.5 2 11 4.01 11 6.5 8.99 11 6.5 11z" }) }) }), O.jsx("input", { onChange: Q, spellCheck: "false", value: b, className: "manual-search-input", autoComplete: "off", placeholder: "Search", type: "text" }), O.jsx("span", { onClick: $, className: `manual-search-clear ${b ? "" : "hide"}`, children: O.jsx("svg", { xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 95.939 95.939", width: "9", height: "9", children: O.jsx("path", { d: "M62.82 47.97l32.53-32.534a2 2 0 0 0 0-2.828L83.332.586a2 2 0 0 0-2.827 0L47.97 33.12 15.435.587c-.75-.75-2.078-.75-2.828 0L.587 12.607a2 2 0 0 0 0 2.83L33.12 47.97.588 80.504a2 2 0 0 0 0 2.828l12.02 12.02a1.997 1.997 0 0 0 2.83 0L47.97 62.818l32.535 32.535a2 2 0 0 0 2.827 0l12.02-12.02c.78-.783.78-2.05 0-2.83L62.82 47.97z" }) }) })] }), O.jsx("div", { className: `manual-group-search-list manual-scroll ${b ? "" : "hide"}`, children: O.jsxs("div", { children: [c == null ? void 0 : c.labelList.map((D) => O.jsx("a", { onClick: (F) => {
|
67412
67418
|
F.preventDefault(), X(D.key, D.group);
|
67413
67419
|
}, className: `manual-group-body-item ${D.key === T ? "manual-group-body-item-selected" : ""}`, "data-href": D.key, href: `#${D.key}`, children: D.label }, `search_${D.key}`)), O.jsx("div", { className: "manual-content-separator" }), c == null ? void 0 : c.contentList.map((D) => O.jsx("a", { onClick: (F) => {
|
67414
67420
|
F.preventDefault(), X(D.key, D.group);
|
67415
|
-
}, className: `manual-group-body-item ${D.key === T ? "manual-group-body-item-selected" : ""}`, "data-href": D.key, href: `#${D.key}`, children: D.label }, `search_${D.key}`))] }) }), O.jsx("div", { className: `manual-group-list manual-scroll ${
|
67421
|
+
}, className: `manual-group-body-item ${D.key === T ? "manual-group-body-item-selected" : ""}`, "data-href": D.key, href: `#${D.key}`, children: D.label }, `search_${D.key}`))] }) }), O.jsx("div", { className: `manual-group-list manual-scroll ${b ? "hide" : ""}`, ref: R, children: Ms.map((D) => {
|
67416
67422
|
var F, U;
|
67417
67423
|
return O.jsxs($t, { children: [O.jsx("div", { onClick: () => P(D), className: `manual-group-title ${D.key === (o == null ? void 0 : o.key) && !(o != null && o.isHidden) ? "active" : ""}`, children: D.title }), O.jsx("div", { className: `manual-group-body manual-scroll ${D.key !== (o == null ? void 0 : o.key) || o != null && o.isHidden ? "hide" : ""}`, children: (U = (F = Du[D.key]) == null ? void 0 : F.sort().filter((ie) => !Iu.includes(ie))) == null ? void 0 : U.map((ie) => {
|
67418
67424
|
const ae = `${D.prefix}_${ie}`;
|