@fewangsit/wangsvue 1.5.229-alpha.33 → 1.5.229-alpha.35
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/mcp/components.json +1 -1
- package/mcp/components.summary.txt +1 -1
- package/mcp/main.js +755 -764
- package/mcp/package.json +5 -5
- package/package.json +1 -1
package/mcp/main.js
CHANGED
|
@@ -1,20 +1,20 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
2
|
import el, { dirname as Xr, join as wn, resolve as tl } from "path";
|
|
3
|
-
import { fileURLToPath as
|
|
4
|
-
import xr, { existsSync as nl, readFileSync as
|
|
3
|
+
import { fileURLToPath as di } from "url";
|
|
4
|
+
import xr, { existsSync as nl, readFileSync as fi, statSync as gc, readdirSync as rl } from "fs";
|
|
5
5
|
import sl from "https";
|
|
6
6
|
import il from "http";
|
|
7
7
|
import al from "os";
|
|
8
8
|
import ol from "crypto";
|
|
9
9
|
import * as _t from "typescript";
|
|
10
|
-
import
|
|
11
|
-
const cl = "https://fewangsit.gitbook.io", ul = "https://fewangsit.gitbook.io/vue/llms.txt",
|
|
10
|
+
import Yi from "node:process";
|
|
11
|
+
const cl = "https://fewangsit.gitbook.io", ul = "https://fewangsit.gitbook.io/vue/llms.txt", Qi = {
|
|
12
12
|
kiro: {
|
|
13
13
|
inclusion: "always",
|
|
14
14
|
output_dir: ".kiro/steering"
|
|
15
15
|
},
|
|
16
16
|
windsurf: {
|
|
17
|
-
trigger: "
|
|
17
|
+
trigger: "always_on",
|
|
18
18
|
output_dir: ".windsurf/rules"
|
|
19
19
|
},
|
|
20
20
|
trae: {
|
|
@@ -22,7 +22,7 @@ const cl = "https://fewangsit.gitbook.io", ul = "https://fewangsit.gitbook.io/vu
|
|
|
22
22
|
output_dir: ".trae/rules"
|
|
23
23
|
},
|
|
24
24
|
copilot: {
|
|
25
|
-
applyTo: "**",
|
|
25
|
+
applyTo: "'**'",
|
|
26
26
|
output_dir: ".github/instructions"
|
|
27
27
|
},
|
|
28
28
|
default: {
|
|
@@ -31,9 +31,9 @@ const cl = "https://fewangsit.gitbook.io", ul = "https://fewangsit.gitbook.io/vu
|
|
|
31
31
|
}
|
|
32
32
|
};
|
|
33
33
|
function yc(t) {
|
|
34
|
-
return
|
|
34
|
+
return Qi[t] || Qi.default;
|
|
35
35
|
}
|
|
36
|
-
function
|
|
36
|
+
function Xi(t) {
|
|
37
37
|
return new Promise((e, n) => {
|
|
38
38
|
(t.startsWith("https") ? sl : il).get(t, (s) => {
|
|
39
39
|
let i = "";
|
|
@@ -47,19 +47,25 @@ function Qi(t) {
|
|
|
47
47
|
});
|
|
48
48
|
});
|
|
49
49
|
}
|
|
50
|
-
function ll(t) {
|
|
51
|
-
const
|
|
52
|
-
`),
|
|
53
|
-
for (const
|
|
54
|
-
const
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
50
|
+
function ll(t, e = !1) {
|
|
51
|
+
const n = t.split(`
|
|
52
|
+
`), r = [];
|
|
53
|
+
for (const s of n) {
|
|
54
|
+
const i = s.match(/\[([^\]]+)\]\(([^)]*\/(?:style-guide|testing-guide)\/[^)]+)\)/);
|
|
55
|
+
if (i) {
|
|
56
|
+
const a = i[1], o = i[2];
|
|
57
|
+
e ? (a.toLowerCase().includes("api-services") || o.toLowerCase().includes("api-services")) && r.push({
|
|
58
|
+
title: a,
|
|
59
|
+
path: o
|
|
60
|
+
}) : r.push({
|
|
61
|
+
title: a,
|
|
62
|
+
path: o
|
|
63
|
+
});
|
|
64
|
+
}
|
|
59
65
|
}
|
|
60
|
-
return
|
|
66
|
+
return r;
|
|
61
67
|
}
|
|
62
|
-
function
|
|
68
|
+
function qs(t) {
|
|
63
69
|
const n = t.replace(/^\/vue\/docs\//, "").split("/");
|
|
64
70
|
if (n.length >= 2) {
|
|
65
71
|
const r = n[0], s = n.slice(1, -1).join("-"), i = n[n.length - 1];
|
|
@@ -82,33 +88,33 @@ function fl(t, e, n) {
|
|
|
82
88
|
`;
|
|
83
89
|
let i = t.replace(/^---[\s\S]*?---\n/, "");
|
|
84
90
|
return i = i.replace(/\[([^\]]+)\]\(\/vue\/docs\/([^)]+)\)/g, (a, o, c) => {
|
|
85
|
-
const l =
|
|
91
|
+
const l = qs(c);
|
|
86
92
|
return `[${o}](${l})`;
|
|
87
93
|
}), i = i.replace(/\[([^\]]+)\]\(https:\/\/fewangsit\.gitbook\.io\/vue\/docs\/([^)]+)\)/g, (a, o, c) => {
|
|
88
|
-
let l =
|
|
94
|
+
let l = qs(c);
|
|
89
95
|
return l.endsWith(".md") || (l += ".md"), `[${o}](${l})`;
|
|
90
96
|
}), s + i;
|
|
91
97
|
}
|
|
92
|
-
async function pl(t) {
|
|
98
|
+
async function pl(t, e = !1) {
|
|
93
99
|
try {
|
|
94
|
-
const
|
|
100
|
+
const n = yc(t), r = `${process.cwd()}/${n.output_dir}`;
|
|
95
101
|
console.log("Fetching documentation index...");
|
|
96
|
-
const
|
|
97
|
-
console.log(`Found ${
|
|
98
|
-
for (const
|
|
102
|
+
const s = await Xi(ul), i = ll(s, e);
|
|
103
|
+
console.log(`Found ${i.length} documentation pages to fetch`), console.log(`Output directory: ${n.output_dir}`), e && console.log("Filter: API services documentation only");
|
|
104
|
+
for (const a of i)
|
|
99
105
|
try {
|
|
100
|
-
console.log(`Fetching: ${
|
|
101
|
-
const
|
|
102
|
-
dl(
|
|
103
|
-
const
|
|
104
|
-
xr.writeFileSync(
|
|
105
|
-
} catch (
|
|
106
|
-
console.error(`✗ Failed to fetch ${
|
|
106
|
+
console.log(`Fetching: ${a.title} from ${a.path}`);
|
|
107
|
+
const o = `${cl}${a.path}`, c = await Xi(o), l = qs(a.path), d = `${r}/${l}`;
|
|
108
|
+
dl(d);
|
|
109
|
+
const h = fl(c, a.title, t);
|
|
110
|
+
xr.writeFileSync(d, h, "utf8"), console.log(`✓ Saved: ${n.output_dir}/${l}`);
|
|
111
|
+
} catch (o) {
|
|
112
|
+
console.error(`✗ Failed to fetch ${a.title}:`, o instanceof Error ? o.message : String(o));
|
|
107
113
|
}
|
|
108
114
|
console.log(`
|
|
109
115
|
Documentation fetch completed!`);
|
|
110
|
-
} catch (
|
|
111
|
-
throw console.error("Error:",
|
|
116
|
+
} catch (n) {
|
|
117
|
+
throw console.error("Error:", n instanceof Error ? n.message : String(n)), n;
|
|
112
118
|
}
|
|
113
119
|
}
|
|
114
120
|
function vc(t) {
|
|
@@ -118,10 +124,10 @@ var pt = { exports: {} };
|
|
|
118
124
|
const hl = "16.6.1", ml = {
|
|
119
125
|
version: hl
|
|
120
126
|
};
|
|
121
|
-
var
|
|
127
|
+
var ea;
|
|
122
128
|
function gl() {
|
|
123
|
-
if (
|
|
124
|
-
|
|
129
|
+
if (ea) return pt.exports;
|
|
130
|
+
ea = 1;
|
|
125
131
|
const t = xr, e = el, n = al, r = ol, i = ml.version, a = /(?:^|^)\s*(?:export\s+)?([\w.-]+)(?:\s*=\s*?|:\s+?)(\s*'(?:\\'|[^'])*'|\s*"(?:\\"|[^"])*"|\s*`(?:\\`|[^`])*`|[^#\r\n]+)?\s*(?:#.*)?(?:$|$)/mg;
|
|
126
132
|
function o(g) {
|
|
127
133
|
const $ = {};
|
|
@@ -309,12 +315,12 @@ function gl() {
|
|
|
309
315
|
var yl = gl();
|
|
310
316
|
const vl = /* @__PURE__ */ vc(yl);
|
|
311
317
|
vl.config();
|
|
312
|
-
const _l =
|
|
318
|
+
const _l = di(import.meta.url), bl = Xr(_l);
|
|
313
319
|
function wl() {
|
|
314
320
|
const t = wn(bl, "package.json");
|
|
315
321
|
if (nl(t))
|
|
316
322
|
try {
|
|
317
|
-
return JSON.parse(
|
|
323
|
+
return JSON.parse(fi(t, "utf8")).buildContext;
|
|
318
324
|
} catch {
|
|
319
325
|
console.warn("Warning: Could not parse build context, using defaults");
|
|
320
326
|
}
|
|
@@ -411,15 +417,15 @@ var he;
|
|
|
411
417
|
}
|
|
412
418
|
t.joinValues = r, t.jsonStringifyReplacer = (s, i) => typeof i == "bigint" ? i.toString() : i;
|
|
413
419
|
})(he || (he = {}));
|
|
414
|
-
var
|
|
420
|
+
var ta;
|
|
415
421
|
(function(t) {
|
|
416
422
|
t.mergeShapes = (e, n) => ({
|
|
417
423
|
...e,
|
|
418
424
|
...n
|
|
419
425
|
// second overwrites first
|
|
420
426
|
});
|
|
421
|
-
})(
|
|
422
|
-
const
|
|
427
|
+
})(ta || (ta = {}));
|
|
428
|
+
const B = he.arrayToEnum([
|
|
423
429
|
"string",
|
|
424
430
|
"nan",
|
|
425
431
|
"number",
|
|
@@ -443,23 +449,23 @@ const G = he.arrayToEnum([
|
|
|
443
449
|
]), It = (t) => {
|
|
444
450
|
switch (typeof t) {
|
|
445
451
|
case "undefined":
|
|
446
|
-
return
|
|
452
|
+
return B.undefined;
|
|
447
453
|
case "string":
|
|
448
|
-
return
|
|
454
|
+
return B.string;
|
|
449
455
|
case "number":
|
|
450
|
-
return Number.isNaN(t) ?
|
|
456
|
+
return Number.isNaN(t) ? B.nan : B.number;
|
|
451
457
|
case "boolean":
|
|
452
|
-
return
|
|
458
|
+
return B.boolean;
|
|
453
459
|
case "function":
|
|
454
|
-
return
|
|
460
|
+
return B.function;
|
|
455
461
|
case "bigint":
|
|
456
|
-
return
|
|
462
|
+
return B.bigint;
|
|
457
463
|
case "symbol":
|
|
458
|
-
return
|
|
464
|
+
return B.symbol;
|
|
459
465
|
case "object":
|
|
460
|
-
return Array.isArray(t) ?
|
|
466
|
+
return Array.isArray(t) ? B.array : t === null ? B.null : t.then && typeof t.then == "function" && t.catch && typeof t.catch == "function" ? B.promise : typeof Map < "u" && t instanceof Map ? B.map : typeof Set < "u" && t instanceof Set ? B.set : typeof Date < "u" && t instanceof Date ? B.date : B.object;
|
|
461
467
|
default:
|
|
462
|
-
return
|
|
468
|
+
return B.unknown;
|
|
463
469
|
}
|
|
464
470
|
}, L = he.arrayToEnum([
|
|
465
471
|
"invalid_type",
|
|
@@ -543,11 +549,11 @@ class St extends Error {
|
|
|
543
549
|
}
|
|
544
550
|
}
|
|
545
551
|
St.create = (t) => new St(t);
|
|
546
|
-
const
|
|
552
|
+
const Ls = (t, e) => {
|
|
547
553
|
let n;
|
|
548
554
|
switch (t.code) {
|
|
549
555
|
case L.invalid_type:
|
|
550
|
-
t.received ===
|
|
556
|
+
t.received === B.undefined ? n = "Required" : n = `Expected ${t.expected}, received ${t.received}`;
|
|
551
557
|
break;
|
|
552
558
|
case L.invalid_literal:
|
|
553
559
|
n = `Invalid literal value, expected ${JSON.stringify(t.expected, he.jsonStringifyReplacer)}`;
|
|
@@ -599,7 +605,7 @@ const qs = (t, e) => {
|
|
|
599
605
|
}
|
|
600
606
|
return { message: n };
|
|
601
607
|
};
|
|
602
|
-
let $l =
|
|
608
|
+
let $l = Ls;
|
|
603
609
|
function Tl() {
|
|
604
610
|
return $l;
|
|
605
611
|
}
|
|
@@ -636,7 +642,7 @@ function W(t, e) {
|
|
|
636
642
|
// then schema-bound map if available
|
|
637
643
|
n,
|
|
638
644
|
// then global override map
|
|
639
|
-
n ===
|
|
645
|
+
n === Ls ? void 0 : Ls
|
|
640
646
|
// then global default map
|
|
641
647
|
].filter((s) => !!s)
|
|
642
648
|
});
|
|
@@ -685,7 +691,7 @@ class Je {
|
|
|
685
691
|
}
|
|
686
692
|
const se = Object.freeze({
|
|
687
693
|
status: "aborted"
|
|
688
|
-
}), hn = (t) => ({ status: "dirty", value: t }), Xe = (t) => ({ status: "valid", value: t }),
|
|
694
|
+
}), hn = (t) => ({ status: "dirty", value: t }), Xe = (t) => ({ status: "valid", value: t }), na = (t) => t.status === "aborted", ra = (t) => t.status === "dirty", Xt = (t) => t.status === "valid", Ar = (t) => typeof Promise < "u" && t instanceof Promise;
|
|
689
695
|
var J;
|
|
690
696
|
(function(t) {
|
|
691
697
|
t.errToObj = (e) => typeof e == "string" ? { message: e } : e || {}, t.toString = (e) => typeof e == "string" ? e : e?.message;
|
|
@@ -698,7 +704,7 @@ class Ot {
|
|
|
698
704
|
return this._cachedPath.length || (Array.isArray(this._key) ? this._cachedPath.push(...this._path, ...this._key) : this._cachedPath.push(...this._path, this._key)), this._cachedPath;
|
|
699
705
|
}
|
|
700
706
|
}
|
|
701
|
-
const
|
|
707
|
+
const sa = (t, e) => {
|
|
702
708
|
if (Xt(e))
|
|
703
709
|
return { success: !0, data: e.value };
|
|
704
710
|
if (!t.common.issues.length)
|
|
@@ -783,7 +789,7 @@ let pe = class {
|
|
|
783
789
|
data: e,
|
|
784
790
|
parsedType: It(e)
|
|
785
791
|
}, s = this._parseSync({ data: e, path: r.path, parent: r });
|
|
786
|
-
return
|
|
792
|
+
return sa(r, s);
|
|
787
793
|
}
|
|
788
794
|
"~validate"(e) {
|
|
789
795
|
const n = {
|
|
@@ -836,7 +842,7 @@ let pe = class {
|
|
|
836
842
|
data: e,
|
|
837
843
|
parsedType: It(e)
|
|
838
844
|
}, s = this._parse({ data: e, path: r.path, parent: r }), i = await (Ar(s) ? s : Promise.resolve(s));
|
|
839
|
-
return
|
|
845
|
+
return sa(r, i);
|
|
840
846
|
}
|
|
841
847
|
refine(e, n) {
|
|
842
848
|
const r = (s) => typeof n == "string" || typeof n > "u" ? { message: n } : typeof n == "function" ? n(s) : n;
|
|
@@ -899,7 +905,7 @@ let pe = class {
|
|
|
899
905
|
}
|
|
900
906
|
default(e) {
|
|
901
907
|
const n = typeof e == "function" ? e : () => e;
|
|
902
|
-
return new
|
|
908
|
+
return new Ws({
|
|
903
909
|
...ue(this._def),
|
|
904
910
|
innerType: this,
|
|
905
911
|
defaultValue: n,
|
|
@@ -907,7 +913,7 @@ let pe = class {
|
|
|
907
913
|
});
|
|
908
914
|
}
|
|
909
915
|
brand() {
|
|
910
|
-
return new
|
|
916
|
+
return new Gl({
|
|
911
917
|
typeName: F.ZodBranded,
|
|
912
918
|
type: this,
|
|
913
919
|
...ue(this._def)
|
|
@@ -915,7 +921,7 @@ let pe = class {
|
|
|
915
921
|
}
|
|
916
922
|
catch(e) {
|
|
917
923
|
const n = typeof e == "function" ? e : () => e;
|
|
918
|
-
return new
|
|
924
|
+
return new Bs({
|
|
919
925
|
...ue(this._def),
|
|
920
926
|
innerType: this,
|
|
921
927
|
catchValue: n,
|
|
@@ -930,7 +936,7 @@ let pe = class {
|
|
|
930
936
|
});
|
|
931
937
|
}
|
|
932
938
|
pipe(e) {
|
|
933
|
-
return
|
|
939
|
+
return hi.create(this, e);
|
|
934
940
|
}
|
|
935
941
|
readonly() {
|
|
936
942
|
return Gs.create(this);
|
|
@@ -978,13 +984,13 @@ function Kl(t, e) {
|
|
|
978
984
|
function Wl(t, e) {
|
|
979
985
|
return !!((e === "v4" || !e) && Ml.test(t) || (e === "v6" || !e) && Dl.test(t));
|
|
980
986
|
}
|
|
981
|
-
let
|
|
987
|
+
let Vs = class mn extends pe {
|
|
982
988
|
_parse(e) {
|
|
983
|
-
if (this._def.coerce && (e.data = String(e.data)), this._getType(e) !==
|
|
989
|
+
if (this._def.coerce && (e.data = String(e.data)), this._getType(e) !== B.string) {
|
|
984
990
|
const i = this._getOrReturnCtx(e);
|
|
985
991
|
return W(i, {
|
|
986
992
|
code: L.invalid_type,
|
|
987
|
-
expected:
|
|
993
|
+
expected: B.string,
|
|
988
994
|
received: i.parsedType
|
|
989
995
|
}), se;
|
|
990
996
|
}
|
|
@@ -1355,26 +1361,26 @@ let Ls = class mn extends pe {
|
|
|
1355
1361
|
return e;
|
|
1356
1362
|
}
|
|
1357
1363
|
};
|
|
1358
|
-
|
|
1364
|
+
Vs.create = (t) => new Vs({
|
|
1359
1365
|
checks: [],
|
|
1360
1366
|
typeName: F.ZodString,
|
|
1361
1367
|
coerce: t?.coerce ?? !1,
|
|
1362
1368
|
...ue(t)
|
|
1363
1369
|
});
|
|
1364
|
-
function
|
|
1370
|
+
function Bl(t, e) {
|
|
1365
1371
|
const n = (t.toString().split(".")[1] || "").length, r = (e.toString().split(".")[1] || "").length, s = n > r ? n : r, i = Number.parseInt(t.toFixed(s).replace(".", "")), a = Number.parseInt(e.toFixed(s).replace(".", ""));
|
|
1366
1372
|
return i % a / 10 ** s;
|
|
1367
1373
|
}
|
|
1368
|
-
let
|
|
1374
|
+
let ia = class Fs extends pe {
|
|
1369
1375
|
constructor() {
|
|
1370
1376
|
super(...arguments), this.min = this.gte, this.max = this.lte, this.step = this.multipleOf;
|
|
1371
1377
|
}
|
|
1372
1378
|
_parse(e) {
|
|
1373
|
-
if (this._def.coerce && (e.data = Number(e.data)), this._getType(e) !==
|
|
1379
|
+
if (this._def.coerce && (e.data = Number(e.data)), this._getType(e) !== B.number) {
|
|
1374
1380
|
const i = this._getOrReturnCtx(e);
|
|
1375
1381
|
return W(i, {
|
|
1376
1382
|
code: L.invalid_type,
|
|
1377
|
-
expected:
|
|
1383
|
+
expected: B.number,
|
|
1378
1384
|
received: i.parsedType
|
|
1379
1385
|
}), se;
|
|
1380
1386
|
}
|
|
@@ -1400,7 +1406,7 @@ let sa = class Vs extends pe {
|
|
|
1400
1406
|
inclusive: i.inclusive,
|
|
1401
1407
|
exact: !1,
|
|
1402
1408
|
message: i.message
|
|
1403
|
-
}), s.dirty()) : i.kind === "multipleOf" ?
|
|
1409
|
+
}), s.dirty()) : i.kind === "multipleOf" ? Bl(e.data, i.value) !== 0 && (r = this._getOrReturnCtx(e, r), W(r, {
|
|
1404
1410
|
code: L.not_multiple_of,
|
|
1405
1411
|
multipleOf: i.value,
|
|
1406
1412
|
message: i.message
|
|
@@ -1423,7 +1429,7 @@ let sa = class Vs extends pe {
|
|
|
1423
1429
|
return this.setLimit("max", e, !1, J.toString(n));
|
|
1424
1430
|
}
|
|
1425
1431
|
setLimit(e, n, r, s) {
|
|
1426
|
-
return new
|
|
1432
|
+
return new Fs({
|
|
1427
1433
|
...this._def,
|
|
1428
1434
|
checks: [
|
|
1429
1435
|
...this._def.checks,
|
|
@@ -1437,7 +1443,7 @@ let sa = class Vs extends pe {
|
|
|
1437
1443
|
});
|
|
1438
1444
|
}
|
|
1439
1445
|
_addCheck(e) {
|
|
1440
|
-
return new
|
|
1446
|
+
return new Fs({
|
|
1441
1447
|
...this._def,
|
|
1442
1448
|
checks: [...this._def.checks, e]
|
|
1443
1449
|
});
|
|
@@ -1531,7 +1537,7 @@ let sa = class Vs extends pe {
|
|
|
1531
1537
|
return Number.isFinite(n) && Number.isFinite(e);
|
|
1532
1538
|
}
|
|
1533
1539
|
};
|
|
1534
|
-
|
|
1540
|
+
ia.create = (t) => new ia({
|
|
1535
1541
|
checks: [],
|
|
1536
1542
|
typeName: F.ZodNumber,
|
|
1537
1543
|
coerce: t?.coerce || !1,
|
|
@@ -1548,7 +1554,7 @@ class kn extends pe {
|
|
|
1548
1554
|
} catch {
|
|
1549
1555
|
return this._getInvalidInput(e);
|
|
1550
1556
|
}
|
|
1551
|
-
if (this._getType(e) !==
|
|
1557
|
+
if (this._getType(e) !== B.bigint)
|
|
1552
1558
|
return this._getInvalidInput(e);
|
|
1553
1559
|
let r;
|
|
1554
1560
|
const s = new Je();
|
|
@@ -1576,7 +1582,7 @@ class kn extends pe {
|
|
|
1576
1582
|
const n = this._getOrReturnCtx(e);
|
|
1577
1583
|
return W(n, {
|
|
1578
1584
|
code: L.invalid_type,
|
|
1579
|
-
expected:
|
|
1585
|
+
expected: B.bigint,
|
|
1580
1586
|
received: n.parsedType
|
|
1581
1587
|
}), se;
|
|
1582
1588
|
}
|
|
@@ -1670,31 +1676,31 @@ kn.create = (t) => new kn({
|
|
|
1670
1676
|
coerce: t?.coerce ?? !1,
|
|
1671
1677
|
...ue(t)
|
|
1672
1678
|
});
|
|
1673
|
-
let
|
|
1679
|
+
let Us = class extends pe {
|
|
1674
1680
|
_parse(e) {
|
|
1675
|
-
if (this._def.coerce && (e.data = !!e.data), this._getType(e) !==
|
|
1681
|
+
if (this._def.coerce && (e.data = !!e.data), this._getType(e) !== B.boolean) {
|
|
1676
1682
|
const r = this._getOrReturnCtx(e);
|
|
1677
1683
|
return W(r, {
|
|
1678
1684
|
code: L.invalid_type,
|
|
1679
|
-
expected:
|
|
1685
|
+
expected: B.boolean,
|
|
1680
1686
|
received: r.parsedType
|
|
1681
1687
|
}), se;
|
|
1682
1688
|
}
|
|
1683
1689
|
return Xe(e.data);
|
|
1684
1690
|
}
|
|
1685
1691
|
};
|
|
1686
|
-
|
|
1692
|
+
Us.create = (t) => new Us({
|
|
1687
1693
|
typeName: F.ZodBoolean,
|
|
1688
1694
|
coerce: t?.coerce || !1,
|
|
1689
1695
|
...ue(t)
|
|
1690
1696
|
});
|
|
1691
1697
|
class jr extends pe {
|
|
1692
1698
|
_parse(e) {
|
|
1693
|
-
if (this._def.coerce && (e.data = new Date(e.data)), this._getType(e) !==
|
|
1699
|
+
if (this._def.coerce && (e.data = new Date(e.data)), this._getType(e) !== B.date) {
|
|
1694
1700
|
const i = this._getOrReturnCtx(e);
|
|
1695
1701
|
return W(i, {
|
|
1696
1702
|
code: L.invalid_type,
|
|
1697
|
-
expected:
|
|
1703
|
+
expected: B.date,
|
|
1698
1704
|
received: i.parsedType
|
|
1699
1705
|
}), se;
|
|
1700
1706
|
}
|
|
@@ -1766,58 +1772,58 @@ jr.create = (t) => new jr({
|
|
|
1766
1772
|
typeName: F.ZodDate,
|
|
1767
1773
|
...ue(t)
|
|
1768
1774
|
});
|
|
1769
|
-
class
|
|
1775
|
+
class aa extends pe {
|
|
1770
1776
|
_parse(e) {
|
|
1771
|
-
if (this._getType(e) !==
|
|
1777
|
+
if (this._getType(e) !== B.symbol) {
|
|
1772
1778
|
const r = this._getOrReturnCtx(e);
|
|
1773
1779
|
return W(r, {
|
|
1774
1780
|
code: L.invalid_type,
|
|
1775
|
-
expected:
|
|
1781
|
+
expected: B.symbol,
|
|
1776
1782
|
received: r.parsedType
|
|
1777
1783
|
}), se;
|
|
1778
1784
|
}
|
|
1779
1785
|
return Xe(e.data);
|
|
1780
1786
|
}
|
|
1781
1787
|
}
|
|
1782
|
-
|
|
1788
|
+
aa.create = (t) => new aa({
|
|
1783
1789
|
typeName: F.ZodSymbol,
|
|
1784
1790
|
...ue(t)
|
|
1785
1791
|
});
|
|
1786
|
-
class
|
|
1792
|
+
class oa extends pe {
|
|
1787
1793
|
_parse(e) {
|
|
1788
|
-
if (this._getType(e) !==
|
|
1794
|
+
if (this._getType(e) !== B.undefined) {
|
|
1789
1795
|
const r = this._getOrReturnCtx(e);
|
|
1790
1796
|
return W(r, {
|
|
1791
1797
|
code: L.invalid_type,
|
|
1792
|
-
expected:
|
|
1798
|
+
expected: B.undefined,
|
|
1793
1799
|
received: r.parsedType
|
|
1794
1800
|
}), se;
|
|
1795
1801
|
}
|
|
1796
1802
|
return Xe(e.data);
|
|
1797
1803
|
}
|
|
1798
1804
|
}
|
|
1799
|
-
|
|
1805
|
+
oa.create = (t) => new oa({
|
|
1800
1806
|
typeName: F.ZodUndefined,
|
|
1801
1807
|
...ue(t)
|
|
1802
1808
|
});
|
|
1803
|
-
let
|
|
1809
|
+
let ca = class extends pe {
|
|
1804
1810
|
_parse(e) {
|
|
1805
|
-
if (this._getType(e) !==
|
|
1811
|
+
if (this._getType(e) !== B.null) {
|
|
1806
1812
|
const r = this._getOrReturnCtx(e);
|
|
1807
1813
|
return W(r, {
|
|
1808
1814
|
code: L.invalid_type,
|
|
1809
|
-
expected:
|
|
1815
|
+
expected: B.null,
|
|
1810
1816
|
received: r.parsedType
|
|
1811
1817
|
}), se;
|
|
1812
1818
|
}
|
|
1813
1819
|
return Xe(e.data);
|
|
1814
1820
|
}
|
|
1815
1821
|
};
|
|
1816
|
-
|
|
1822
|
+
ca.create = (t) => new ca({
|
|
1817
1823
|
typeName: F.ZodNull,
|
|
1818
1824
|
...ue(t)
|
|
1819
1825
|
});
|
|
1820
|
-
class
|
|
1826
|
+
class ua extends pe {
|
|
1821
1827
|
constructor() {
|
|
1822
1828
|
super(...arguments), this._any = !0;
|
|
1823
1829
|
}
|
|
@@ -1825,11 +1831,11 @@ class ca extends pe {
|
|
|
1825
1831
|
return Xe(e.data);
|
|
1826
1832
|
}
|
|
1827
1833
|
}
|
|
1828
|
-
|
|
1834
|
+
ua.create = (t) => new ua({
|
|
1829
1835
|
typeName: F.ZodAny,
|
|
1830
1836
|
...ue(t)
|
|
1831
1837
|
});
|
|
1832
|
-
let
|
|
1838
|
+
let la = class extends pe {
|
|
1833
1839
|
constructor() {
|
|
1834
1840
|
super(...arguments), this._unknown = !0;
|
|
1835
1841
|
}
|
|
@@ -1837,7 +1843,7 @@ let ua = class extends pe {
|
|
|
1837
1843
|
return Xe(e.data);
|
|
1838
1844
|
}
|
|
1839
1845
|
};
|
|
1840
|
-
|
|
1846
|
+
la.create = (t) => new la({
|
|
1841
1847
|
typeName: F.ZodUnknown,
|
|
1842
1848
|
...ue(t)
|
|
1843
1849
|
});
|
|
@@ -1846,7 +1852,7 @@ let Nt = class extends pe {
|
|
|
1846
1852
|
const n = this._getOrReturnCtx(e);
|
|
1847
1853
|
return W(n, {
|
|
1848
1854
|
code: L.invalid_type,
|
|
1849
|
-
expected:
|
|
1855
|
+
expected: B.never,
|
|
1850
1856
|
received: n.parsedType
|
|
1851
1857
|
}), se;
|
|
1852
1858
|
}
|
|
@@ -1855,30 +1861,30 @@ Nt.create = (t) => new Nt({
|
|
|
1855
1861
|
typeName: F.ZodNever,
|
|
1856
1862
|
...ue(t)
|
|
1857
1863
|
});
|
|
1858
|
-
class
|
|
1864
|
+
class da extends pe {
|
|
1859
1865
|
_parse(e) {
|
|
1860
|
-
if (this._getType(e) !==
|
|
1866
|
+
if (this._getType(e) !== B.undefined) {
|
|
1861
1867
|
const r = this._getOrReturnCtx(e);
|
|
1862
1868
|
return W(r, {
|
|
1863
1869
|
code: L.invalid_type,
|
|
1864
|
-
expected:
|
|
1870
|
+
expected: B.void,
|
|
1865
1871
|
received: r.parsedType
|
|
1866
1872
|
}), se;
|
|
1867
1873
|
}
|
|
1868
1874
|
return Xe(e.data);
|
|
1869
1875
|
}
|
|
1870
1876
|
}
|
|
1871
|
-
|
|
1877
|
+
da.create = (t) => new da({
|
|
1872
1878
|
typeName: F.ZodVoid,
|
|
1873
1879
|
...ue(t)
|
|
1874
1880
|
});
|
|
1875
1881
|
let en = class Cr extends pe {
|
|
1876
1882
|
_parse(e) {
|
|
1877
1883
|
const { ctx: n, status: r } = this._processInputParams(e), s = this._def;
|
|
1878
|
-
if (n.parsedType !==
|
|
1884
|
+
if (n.parsedType !== B.array)
|
|
1879
1885
|
return W(n, {
|
|
1880
1886
|
code: L.invalid_type,
|
|
1881
|
-
expected:
|
|
1887
|
+
expected: B.array,
|
|
1882
1888
|
received: n.parsedType
|
|
1883
1889
|
}), se;
|
|
1884
1890
|
if (s.exactLength !== null) {
|
|
@@ -1972,11 +1978,11 @@ let $t = class at extends pe {
|
|
|
1972
1978
|
return this._cached = { shape: e, keys: n }, this._cached;
|
|
1973
1979
|
}
|
|
1974
1980
|
_parse(e) {
|
|
1975
|
-
if (this._getType(e) !==
|
|
1981
|
+
if (this._getType(e) !== B.object) {
|
|
1976
1982
|
const l = this._getOrReturnCtx(e);
|
|
1977
1983
|
return W(l, {
|
|
1978
1984
|
code: L.invalid_type,
|
|
1979
|
-
expected:
|
|
1985
|
+
expected: B.object,
|
|
1980
1986
|
received: l.parsedType
|
|
1981
1987
|
}), se;
|
|
1982
1988
|
}
|
|
@@ -2321,39 +2327,39 @@ zr.create = (t, e) => new zr({
|
|
|
2321
2327
|
typeName: F.ZodUnion,
|
|
2322
2328
|
...ue(e)
|
|
2323
2329
|
});
|
|
2324
|
-
function
|
|
2330
|
+
function Hs(t, e) {
|
|
2325
2331
|
const n = It(t), r = It(e);
|
|
2326
2332
|
if (t === e)
|
|
2327
2333
|
return { valid: !0, data: t };
|
|
2328
|
-
if (n ===
|
|
2334
|
+
if (n === B.object && r === B.object) {
|
|
2329
2335
|
const s = he.objectKeys(e), i = he.objectKeys(t).filter((o) => s.indexOf(o) !== -1), a = { ...t, ...e };
|
|
2330
2336
|
for (const o of i) {
|
|
2331
|
-
const c =
|
|
2337
|
+
const c = Hs(t[o], e[o]);
|
|
2332
2338
|
if (!c.valid)
|
|
2333
2339
|
return { valid: !1 };
|
|
2334
2340
|
a[o] = c.data;
|
|
2335
2341
|
}
|
|
2336
2342
|
return { valid: !0, data: a };
|
|
2337
|
-
} else if (n ===
|
|
2343
|
+
} else if (n === B.array && r === B.array) {
|
|
2338
2344
|
if (t.length !== e.length)
|
|
2339
2345
|
return { valid: !1 };
|
|
2340
2346
|
const s = [];
|
|
2341
2347
|
for (let i = 0; i < t.length; i++) {
|
|
2342
|
-
const a = t[i], o = e[i], c =
|
|
2348
|
+
const a = t[i], o = e[i], c = Hs(a, o);
|
|
2343
2349
|
if (!c.valid)
|
|
2344
2350
|
return { valid: !1 };
|
|
2345
2351
|
s.push(c.data);
|
|
2346
2352
|
}
|
|
2347
2353
|
return { valid: !0, data: s };
|
|
2348
|
-
} else return n ===
|
|
2354
|
+
} else return n === B.date && r === B.date && +t == +e ? { valid: !0, data: t } : { valid: !1 };
|
|
2349
2355
|
}
|
|
2350
2356
|
let Mr = class extends pe {
|
|
2351
2357
|
_parse(e) {
|
|
2352
2358
|
const { status: n, ctx: r } = this._processInputParams(e), s = (i, a) => {
|
|
2353
|
-
if (
|
|
2359
|
+
if (na(i) || na(a))
|
|
2354
2360
|
return se;
|
|
2355
|
-
const o =
|
|
2356
|
-
return o.valid ? ((
|
|
2361
|
+
const o = Hs(i.value, a.value);
|
|
2362
|
+
return o.valid ? ((ra(i) || ra(a)) && n.dirty(), { status: n.value, value: o.data }) : (W(r, {
|
|
2357
2363
|
code: L.invalid_intersection_types
|
|
2358
2364
|
}), se);
|
|
2359
2365
|
};
|
|
@@ -2388,10 +2394,10 @@ Mr.create = (t, e, n) => new Mr({
|
|
|
2388
2394
|
class Ut extends pe {
|
|
2389
2395
|
_parse(e) {
|
|
2390
2396
|
const { status: n, ctx: r } = this._processInputParams(e);
|
|
2391
|
-
if (r.parsedType !==
|
|
2397
|
+
if (r.parsedType !== B.array)
|
|
2392
2398
|
return W(r, {
|
|
2393
2399
|
code: L.invalid_type,
|
|
2394
|
-
expected:
|
|
2400
|
+
expected: B.array,
|
|
2395
2401
|
received: r.parsedType
|
|
2396
2402
|
}), se;
|
|
2397
2403
|
if (r.data.length < this._def.items.length)
|
|
@@ -2435,7 +2441,7 @@ Ut.create = (t, e) => {
|
|
|
2435
2441
|
...ue(e)
|
|
2436
2442
|
});
|
|
2437
2443
|
};
|
|
2438
|
-
class
|
|
2444
|
+
class fa extends pe {
|
|
2439
2445
|
get keySchema() {
|
|
2440
2446
|
return this._def.keyType;
|
|
2441
2447
|
}
|
|
@@ -2444,10 +2450,10 @@ class da extends pe {
|
|
|
2444
2450
|
}
|
|
2445
2451
|
_parse(e) {
|
|
2446
2452
|
const { status: n, ctx: r } = this._processInputParams(e);
|
|
2447
|
-
if (r.parsedType !==
|
|
2453
|
+
if (r.parsedType !== B.map)
|
|
2448
2454
|
return W(r, {
|
|
2449
2455
|
code: L.invalid_type,
|
|
2450
|
-
expected:
|
|
2456
|
+
expected: B.map,
|
|
2451
2457
|
received: r.parsedType
|
|
2452
2458
|
}), se;
|
|
2453
2459
|
const s = this._def.keyType, i = this._def.valueType, a = [...r.data.entries()].map(([o, c], l) => ({
|
|
@@ -2477,7 +2483,7 @@ class da extends pe {
|
|
|
2477
2483
|
}
|
|
2478
2484
|
}
|
|
2479
2485
|
}
|
|
2480
|
-
|
|
2486
|
+
fa.create = (t, e, n) => new fa({
|
|
2481
2487
|
valueType: e,
|
|
2482
2488
|
keyType: t,
|
|
2483
2489
|
typeName: F.ZodMap,
|
|
@@ -2486,10 +2492,10 @@ da.create = (t, e, n) => new da({
|
|
|
2486
2492
|
class Sn extends pe {
|
|
2487
2493
|
_parse(e) {
|
|
2488
2494
|
const { status: n, ctx: r } = this._processInputParams(e);
|
|
2489
|
-
if (r.parsedType !==
|
|
2495
|
+
if (r.parsedType !== B.set)
|
|
2490
2496
|
return W(r, {
|
|
2491
2497
|
code: L.invalid_type,
|
|
2492
|
-
expected:
|
|
2498
|
+
expected: B.set,
|
|
2493
2499
|
received: r.parsedType
|
|
2494
2500
|
}), se;
|
|
2495
2501
|
const s = this._def;
|
|
@@ -2547,7 +2553,7 @@ Sn.create = (t, e) => new Sn({
|
|
|
2547
2553
|
typeName: F.ZodSet,
|
|
2548
2554
|
...ue(e)
|
|
2549
2555
|
});
|
|
2550
|
-
class
|
|
2556
|
+
class pa extends pe {
|
|
2551
2557
|
get schema() {
|
|
2552
2558
|
return this._def.getter();
|
|
2553
2559
|
}
|
|
@@ -2556,12 +2562,12 @@ class fa extends pe {
|
|
|
2556
2562
|
return this._def.getter()._parse({ data: n.data, path: n.path, parent: n });
|
|
2557
2563
|
}
|
|
2558
2564
|
}
|
|
2559
|
-
|
|
2565
|
+
pa.create = (t, e) => new pa({
|
|
2560
2566
|
getter: t,
|
|
2561
2567
|
typeName: F.ZodLazy,
|
|
2562
2568
|
...ue(e)
|
|
2563
2569
|
});
|
|
2564
|
-
let
|
|
2570
|
+
let ha = class extends pe {
|
|
2565
2571
|
_parse(e) {
|
|
2566
2572
|
if (e.data !== this._def.value) {
|
|
2567
2573
|
const n = this._getOrReturnCtx(e);
|
|
@@ -2577,19 +2583,19 @@ let pa = class extends pe {
|
|
|
2577
2583
|
return this._def.value;
|
|
2578
2584
|
}
|
|
2579
2585
|
};
|
|
2580
|
-
|
|
2586
|
+
ha.create = (t, e) => new ha({
|
|
2581
2587
|
value: t,
|
|
2582
2588
|
typeName: F.ZodLiteral,
|
|
2583
2589
|
...ue(e)
|
|
2584
2590
|
});
|
|
2585
2591
|
function wc(t, e) {
|
|
2586
|
-
return new
|
|
2592
|
+
return new pi({
|
|
2587
2593
|
values: t,
|
|
2588
2594
|
typeName: F.ZodEnum,
|
|
2589
2595
|
...ue(e)
|
|
2590
2596
|
});
|
|
2591
2597
|
}
|
|
2592
|
-
let
|
|
2598
|
+
let pi = class Ks extends pe {
|
|
2593
2599
|
_parse(e) {
|
|
2594
2600
|
if (typeof e.data != "string") {
|
|
2595
2601
|
const n = this._getOrReturnCtx(e), r = this._def.values;
|
|
@@ -2631,23 +2637,23 @@ let fi = class Hs extends pe {
|
|
|
2631
2637
|
return e;
|
|
2632
2638
|
}
|
|
2633
2639
|
extract(e, n = this._def) {
|
|
2634
|
-
return
|
|
2640
|
+
return Ks.create(e, {
|
|
2635
2641
|
...this._def,
|
|
2636
2642
|
...n
|
|
2637
2643
|
});
|
|
2638
2644
|
}
|
|
2639
2645
|
exclude(e, n = this._def) {
|
|
2640
|
-
return
|
|
2646
|
+
return Ks.create(this.options.filter((r) => !e.includes(r)), {
|
|
2641
2647
|
...this._def,
|
|
2642
2648
|
...n
|
|
2643
2649
|
});
|
|
2644
2650
|
}
|
|
2645
2651
|
};
|
|
2646
|
-
|
|
2647
|
-
class
|
|
2652
|
+
pi.create = wc;
|
|
2653
|
+
class ma extends pe {
|
|
2648
2654
|
_parse(e) {
|
|
2649
2655
|
const n = he.getValidEnumValues(this._def.values), r = this._getOrReturnCtx(e);
|
|
2650
|
-
if (r.parsedType !==
|
|
2656
|
+
if (r.parsedType !== B.string && r.parsedType !== B.number) {
|
|
2651
2657
|
const s = he.objectValues(n);
|
|
2652
2658
|
return W(r, {
|
|
2653
2659
|
expected: he.joinValues(s),
|
|
@@ -2669,7 +2675,7 @@ class ha extends pe {
|
|
|
2669
2675
|
return this._def.values;
|
|
2670
2676
|
}
|
|
2671
2677
|
}
|
|
2672
|
-
|
|
2678
|
+
ma.create = (t, e) => new ma({
|
|
2673
2679
|
values: t,
|
|
2674
2680
|
typeName: F.ZodNativeEnum,
|
|
2675
2681
|
...ue(e)
|
|
@@ -2680,13 +2686,13 @@ class Zr extends pe {
|
|
|
2680
2686
|
}
|
|
2681
2687
|
_parse(e) {
|
|
2682
2688
|
const { ctx: n } = this._processInputParams(e);
|
|
2683
|
-
if (n.parsedType !==
|
|
2689
|
+
if (n.parsedType !== B.promise && n.common.async === !1)
|
|
2684
2690
|
return W(n, {
|
|
2685
2691
|
code: L.invalid_type,
|
|
2686
|
-
expected:
|
|
2692
|
+
expected: B.promise,
|
|
2687
2693
|
received: n.parsedType
|
|
2688
2694
|
}), se;
|
|
2689
|
-
const r = n.parsedType ===
|
|
2695
|
+
const r = n.parsedType === B.promise ? n.data : Promise.resolve(n.data);
|
|
2690
2696
|
return Xe(r.then((s) => this._def.type.parseAsync(s, {
|
|
2691
2697
|
path: n.path,
|
|
2692
2698
|
errorMap: n.common.contextualErrorMap
|
|
@@ -2792,7 +2798,7 @@ tn.createWithPreprocess = (t, e, n) => new tn({
|
|
|
2792
2798
|
});
|
|
2793
2799
|
let Ct = class extends pe {
|
|
2794
2800
|
_parse(e) {
|
|
2795
|
-
return this._getType(e) ===
|
|
2801
|
+
return this._getType(e) === B.undefined ? Xe(void 0) : this._def.innerType._parse(e);
|
|
2796
2802
|
}
|
|
2797
2803
|
unwrap() {
|
|
2798
2804
|
return this._def.innerType;
|
|
@@ -2805,7 +2811,7 @@ Ct.create = (t, e) => new Ct({
|
|
|
2805
2811
|
});
|
|
2806
2812
|
let nn = class extends pe {
|
|
2807
2813
|
_parse(e) {
|
|
2808
|
-
return this._getType(e) ===
|
|
2814
|
+
return this._getType(e) === B.null ? Xe(null) : this._def.innerType._parse(e);
|
|
2809
2815
|
}
|
|
2810
2816
|
unwrap() {
|
|
2811
2817
|
return this._def.innerType;
|
|
@@ -2816,11 +2822,11 @@ nn.create = (t, e) => new nn({
|
|
|
2816
2822
|
typeName: F.ZodNullable,
|
|
2817
2823
|
...ue(e)
|
|
2818
2824
|
});
|
|
2819
|
-
let
|
|
2825
|
+
let Ws = class extends pe {
|
|
2820
2826
|
_parse(e) {
|
|
2821
2827
|
const { ctx: n } = this._processInputParams(e);
|
|
2822
2828
|
let r = n.data;
|
|
2823
|
-
return n.parsedType ===
|
|
2829
|
+
return n.parsedType === B.undefined && (r = this._def.defaultValue()), this._def.innerType._parse({
|
|
2824
2830
|
data: r,
|
|
2825
2831
|
path: n.path,
|
|
2826
2832
|
parent: n
|
|
@@ -2830,13 +2836,13 @@ let Ks = class extends pe {
|
|
|
2830
2836
|
return this._def.innerType;
|
|
2831
2837
|
}
|
|
2832
2838
|
};
|
|
2833
|
-
|
|
2839
|
+
Ws.create = (t, e) => new Ws({
|
|
2834
2840
|
innerType: t,
|
|
2835
2841
|
typeName: F.ZodDefault,
|
|
2836
2842
|
defaultValue: typeof e.default == "function" ? e.default : () => e.default,
|
|
2837
2843
|
...ue(e)
|
|
2838
2844
|
});
|
|
2839
|
-
let
|
|
2845
|
+
let Bs = class extends pe {
|
|
2840
2846
|
_parse(e) {
|
|
2841
2847
|
const { ctx: n } = this._processInputParams(e), r = {
|
|
2842
2848
|
...n,
|
|
@@ -2873,30 +2879,30 @@ let Ws = class extends pe {
|
|
|
2873
2879
|
return this._def.innerType;
|
|
2874
2880
|
}
|
|
2875
2881
|
};
|
|
2876
|
-
|
|
2882
|
+
Bs.create = (t, e) => new Bs({
|
|
2877
2883
|
innerType: t,
|
|
2878
2884
|
typeName: F.ZodCatch,
|
|
2879
2885
|
catchValue: typeof e.catch == "function" ? e.catch : () => e.catch,
|
|
2880
2886
|
...ue(e)
|
|
2881
2887
|
});
|
|
2882
|
-
class
|
|
2888
|
+
class ga extends pe {
|
|
2883
2889
|
_parse(e) {
|
|
2884
|
-
if (this._getType(e) !==
|
|
2890
|
+
if (this._getType(e) !== B.nan) {
|
|
2885
2891
|
const r = this._getOrReturnCtx(e);
|
|
2886
2892
|
return W(r, {
|
|
2887
2893
|
code: L.invalid_type,
|
|
2888
|
-
expected:
|
|
2894
|
+
expected: B.nan,
|
|
2889
2895
|
received: r.parsedType
|
|
2890
2896
|
}), se;
|
|
2891
2897
|
}
|
|
2892
2898
|
return { status: "valid", value: e.data };
|
|
2893
2899
|
}
|
|
2894
2900
|
}
|
|
2895
|
-
|
|
2901
|
+
ga.create = (t) => new ga({
|
|
2896
2902
|
typeName: F.ZodNaN,
|
|
2897
2903
|
...ue(t)
|
|
2898
2904
|
});
|
|
2899
|
-
class
|
|
2905
|
+
class Gl extends pe {
|
|
2900
2906
|
_parse(e) {
|
|
2901
2907
|
const { ctx: n } = this._processInputParams(e), r = n.data;
|
|
2902
2908
|
return this._def.type._parse({
|
|
@@ -2909,7 +2915,7 @@ class Bl extends pe {
|
|
|
2909
2915
|
return this._def.type;
|
|
2910
2916
|
}
|
|
2911
2917
|
}
|
|
2912
|
-
class
|
|
2918
|
+
class hi extends pe {
|
|
2913
2919
|
_parse(e) {
|
|
2914
2920
|
const { status: n, ctx: r } = this._processInputParams(e);
|
|
2915
2921
|
if (r.common.async)
|
|
@@ -2942,7 +2948,7 @@ class pi extends pe {
|
|
|
2942
2948
|
}
|
|
2943
2949
|
}
|
|
2944
2950
|
static create(e, n) {
|
|
2945
|
-
return new
|
|
2951
|
+
return new hi({
|
|
2946
2952
|
in: e,
|
|
2947
2953
|
out: n,
|
|
2948
2954
|
typeName: F.ZodPipeline
|
|
@@ -2967,13 +2973,13 @@ var F;
|
|
|
2967
2973
|
(function(t) {
|
|
2968
2974
|
t.ZodString = "ZodString", t.ZodNumber = "ZodNumber", t.ZodNaN = "ZodNaN", t.ZodBigInt = "ZodBigInt", t.ZodBoolean = "ZodBoolean", t.ZodDate = "ZodDate", t.ZodSymbol = "ZodSymbol", t.ZodUndefined = "ZodUndefined", t.ZodNull = "ZodNull", t.ZodAny = "ZodAny", t.ZodUnknown = "ZodUnknown", t.ZodNever = "ZodNever", t.ZodVoid = "ZodVoid", t.ZodArray = "ZodArray", t.ZodObject = "ZodObject", t.ZodUnion = "ZodUnion", t.ZodDiscriminatedUnion = "ZodDiscriminatedUnion", t.ZodIntersection = "ZodIntersection", t.ZodTuple = "ZodTuple", t.ZodRecord = "ZodRecord", t.ZodMap = "ZodMap", t.ZodSet = "ZodSet", t.ZodFunction = "ZodFunction", t.ZodLazy = "ZodLazy", t.ZodLiteral = "ZodLiteral", t.ZodEnum = "ZodEnum", t.ZodEffects = "ZodEffects", t.ZodNativeEnum = "ZodNativeEnum", t.ZodOptional = "ZodOptional", t.ZodNullable = "ZodNullable", t.ZodDefault = "ZodDefault", t.ZodCatch = "ZodCatch", t.ZodPromise = "ZodPromise", t.ZodBranded = "ZodBranded", t.ZodPipeline = "ZodPipeline", t.ZodReadonly = "ZodReadonly";
|
|
2969
2975
|
})(F || (F = {}));
|
|
2970
|
-
const Re =
|
|
2976
|
+
const Re = Vs.create, yn = Us.create;
|
|
2971
2977
|
Nt.create;
|
|
2972
2978
|
const Jl = en.create, Yl = $t.create;
|
|
2973
2979
|
zr.create;
|
|
2974
2980
|
Mr.create;
|
|
2975
2981
|
Ut.create;
|
|
2976
|
-
const kc =
|
|
2982
|
+
const kc = pi.create;
|
|
2977
2983
|
Zr.create;
|
|
2978
2984
|
Ct.create;
|
|
2979
2985
|
nn.create;
|
|
@@ -3020,7 +3026,7 @@ function $c(t) {
|
|
|
3020
3026
|
function Ql(t, e) {
|
|
3021
3027
|
return typeof e == "bigint" ? e.toString() : e;
|
|
3022
3028
|
}
|
|
3023
|
-
function
|
|
3029
|
+
function mi(t) {
|
|
3024
3030
|
return {
|
|
3025
3031
|
get value() {
|
|
3026
3032
|
{
|
|
@@ -3030,10 +3036,10 @@ function hi(t) {
|
|
|
3030
3036
|
}
|
|
3031
3037
|
};
|
|
3032
3038
|
}
|
|
3033
|
-
function
|
|
3039
|
+
function gi(t) {
|
|
3034
3040
|
return t == null;
|
|
3035
3041
|
}
|
|
3036
|
-
function
|
|
3042
|
+
function yi(t) {
|
|
3037
3043
|
const e = t.startsWith("^") ? 1 : 0, n = t.endsWith("$") ? t.length - 1 : t.length;
|
|
3038
3044
|
return t.slice(e, n);
|
|
3039
3045
|
}
|
|
@@ -3074,7 +3080,7 @@ const Tc = Error.captureStackTrace ? Error.captureStackTrace : (...t) => {
|
|
|
3074
3080
|
function Dr(t) {
|
|
3075
3081
|
return typeof t == "object" && t !== null && !Array.isArray(t);
|
|
3076
3082
|
}
|
|
3077
|
-
const ed =
|
|
3083
|
+
const ed = mi(() => {
|
|
3078
3084
|
if (typeof navigator < "u" && navigator?.userAgent?.includes("Cloudflare"))
|
|
3079
3085
|
return !1;
|
|
3080
3086
|
try {
|
|
@@ -3246,7 +3252,7 @@ function At(t, e, n) {
|
|
|
3246
3252
|
}
|
|
3247
3253
|
return delete r.inst, delete r.continue, e?.reportInput || delete r.input, r;
|
|
3248
3254
|
}
|
|
3249
|
-
function
|
|
3255
|
+
function vi(t) {
|
|
3250
3256
|
return Array.isArray(t) ? "array" : typeof t == "string" ? "string" : "unknown";
|
|
3251
3257
|
}
|
|
3252
3258
|
function Tn(...t) {
|
|
@@ -3330,14 +3336,14 @@ const Rc = (t) => (e, n, r, s) => {
|
|
|
3330
3336
|
success: !1,
|
|
3331
3337
|
error: new (t ?? Pc)(i.issues.map((a) => At(a, s, xt())))
|
|
3332
3338
|
} : { success: !0, data: i.value };
|
|
3333
|
-
},
|
|
3339
|
+
}, _i = /* @__PURE__ */ Cc(es), Oc = (t) => async (e, n, r) => {
|
|
3334
3340
|
const s = r ? Object.assign(r, { async: !0 }) : { async: !0 };
|
|
3335
3341
|
let i = e._zod.run({ value: n, issues: [] }, s);
|
|
3336
3342
|
return i instanceof Promise && (i = await i), i.issues.length ? {
|
|
3337
3343
|
success: !1,
|
|
3338
3344
|
error: new t(i.issues.map((a) => At(a, s, xt())))
|
|
3339
3345
|
} : { success: !0, data: i.value };
|
|
3340
|
-
},
|
|
3346
|
+
}, bi = /* @__PURE__ */ Oc(es), hd = /^[cC][^\s-]{8,}$/, md = /^[0-9a-z]+$/, gd = /^[0-9A-HJKMNP-TV-Za-hjkmnp-tv-z]{26}$/, yd = /^[0-9a-vA-V]{20}$/, vd = /^[A-Za-z0-9]{27}$/, _d = /^[a-zA-Z0-9_-]{21}$/, bd = /^P(?:(\d+W)|(?!.*W)(?=\d|T\d)(\d+Y)?(\d+M)?(\d+D)?(T(?=\d)(\d+H)?(\d+M)?(\d+([.,]\d+)?S)?)?)$/, wd = /^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12})$/, ya = (t) => t ? new RegExp(`^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-${t}[0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12})$`) : /^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000)$/, kd = /^(?!\.)(?!.*\.\.)([A-Za-z0-9_'+\-\.]*)[A-Za-z0-9_+-]@([A-Za-z0-9][A-Za-z0-9\-]*\.)+[A-Za-z]{2,}$/, Sd = "^(\\p{Extended_Pictographic}|\\p{Emoji_Component})+$";
|
|
3341
3347
|
function $d() {
|
|
3342
3348
|
return new RegExp(Sd, "u");
|
|
3343
3349
|
}
|
|
@@ -3475,7 +3481,7 @@ const jd = (t) => {
|
|
|
3475
3481
|
var n;
|
|
3476
3482
|
Ke.init(t, e), (n = t._zod.def).when ?? (n.when = (r) => {
|
|
3477
3483
|
const s = r.value;
|
|
3478
|
-
return !
|
|
3484
|
+
return !gi(s) && s.length !== void 0;
|
|
3479
3485
|
}), t._zod.onattach.push((r) => {
|
|
3480
3486
|
const s = r._zod.bag.maximum ?? Number.POSITIVE_INFINITY;
|
|
3481
3487
|
e.maximum < s && (r._zod.bag.maximum = e.maximum);
|
|
@@ -3483,7 +3489,7 @@ const jd = (t) => {
|
|
|
3483
3489
|
const s = r.value;
|
|
3484
3490
|
if (s.length <= e.maximum)
|
|
3485
3491
|
return;
|
|
3486
|
-
const a =
|
|
3492
|
+
const a = vi(s);
|
|
3487
3493
|
r.issues.push({
|
|
3488
3494
|
origin: a,
|
|
3489
3495
|
code: "too_big",
|
|
@@ -3498,7 +3504,7 @@ const jd = (t) => {
|
|
|
3498
3504
|
var n;
|
|
3499
3505
|
Ke.init(t, e), (n = t._zod.def).when ?? (n.when = (r) => {
|
|
3500
3506
|
const s = r.value;
|
|
3501
|
-
return !
|
|
3507
|
+
return !gi(s) && s.length !== void 0;
|
|
3502
3508
|
}), t._zod.onattach.push((r) => {
|
|
3503
3509
|
const s = r._zod.bag.minimum ?? Number.NEGATIVE_INFINITY;
|
|
3504
3510
|
e.minimum > s && (r._zod.bag.minimum = e.minimum);
|
|
@@ -3506,7 +3512,7 @@ const jd = (t) => {
|
|
|
3506
3512
|
const s = r.value;
|
|
3507
3513
|
if (s.length >= e.minimum)
|
|
3508
3514
|
return;
|
|
3509
|
-
const a =
|
|
3515
|
+
const a = vi(s);
|
|
3510
3516
|
r.issues.push({
|
|
3511
3517
|
origin: a,
|
|
3512
3518
|
code: "too_small",
|
|
@@ -3521,7 +3527,7 @@ const jd = (t) => {
|
|
|
3521
3527
|
var n;
|
|
3522
3528
|
Ke.init(t, e), (n = t._zod.def).when ?? (n.when = (r) => {
|
|
3523
3529
|
const s = r.value;
|
|
3524
|
-
return !
|
|
3530
|
+
return !gi(s) && s.length !== void 0;
|
|
3525
3531
|
}), t._zod.onattach.push((r) => {
|
|
3526
3532
|
const s = r._zod.bag;
|
|
3527
3533
|
s.minimum = e.length, s.maximum = e.length, s.length = e.length;
|
|
@@ -3529,7 +3535,7 @@ const jd = (t) => {
|
|
|
3529
3535
|
const s = r.value, i = s.length;
|
|
3530
3536
|
if (i === e.length)
|
|
3531
3537
|
return;
|
|
3532
|
-
const a =
|
|
3538
|
+
const a = vi(s), o = i > e.length;
|
|
3533
3539
|
r.issues.push({
|
|
3534
3540
|
origin: a,
|
|
3535
3541
|
...o ? { code: "too_big", maximum: e.length } : { code: "too_small", minimum: e.length },
|
|
@@ -3569,9 +3575,9 @@ const jd = (t) => {
|
|
|
3569
3575
|
continue: !e.abort
|
|
3570
3576
|
});
|
|
3571
3577
|
};
|
|
3572
|
-
}),
|
|
3578
|
+
}), Bd = /* @__PURE__ */ A("$ZodCheckLowerCase", (t, e) => {
|
|
3573
3579
|
e.pattern ?? (e.pattern = qd), ts.init(t, e);
|
|
3574
|
-
}),
|
|
3580
|
+
}), Gd = /* @__PURE__ */ A("$ZodCheckUpperCase", (t, e) => {
|
|
3575
3581
|
e.pattern ?? (e.pattern = Ld), ts.init(t, e);
|
|
3576
3582
|
}), Jd = /* @__PURE__ */ A("$ZodCheckIncludes", (t, e) => {
|
|
3577
3583
|
Ke.init(t, e);
|
|
@@ -3705,16 +3711,16 @@ const tf = {
|
|
|
3705
3711
|
t["~standard"] = {
|
|
3706
3712
|
validate: (s) => {
|
|
3707
3713
|
try {
|
|
3708
|
-
const i =
|
|
3714
|
+
const i = _i(t, s);
|
|
3709
3715
|
return i.success ? { value: i.data } : { issues: i.error?.issues };
|
|
3710
3716
|
} catch {
|
|
3711
|
-
return
|
|
3717
|
+
return bi(t, s).then((a) => a.success ? { value: a.data } : { issues: a.error?.issues });
|
|
3712
3718
|
}
|
|
3713
3719
|
},
|
|
3714
3720
|
vendor: "zod",
|
|
3715
3721
|
version: 1
|
|
3716
3722
|
};
|
|
3717
|
-
}),
|
|
3723
|
+
}), wi = /* @__PURE__ */ A("$ZodString", (t, e) => {
|
|
3718
3724
|
Se.init(t, e), t._zod.pattern = [...t?._zod.bag?.patterns ?? []].pop() ?? jd(t._zod.bag), t._zod.parse = (n, r) => {
|
|
3719
3725
|
if (e.coerce)
|
|
3720
3726
|
try {
|
|
@@ -3729,7 +3735,7 @@ const tf = {
|
|
|
3729
3735
|
}), n;
|
|
3730
3736
|
};
|
|
3731
3737
|
}), $e = /* @__PURE__ */ A("$ZodStringFormat", (t, e) => {
|
|
3732
|
-
ts.init(t, e),
|
|
3738
|
+
ts.init(t, e), wi.init(t, e);
|
|
3733
3739
|
}), nf = /* @__PURE__ */ A("$ZodGUID", (t, e) => {
|
|
3734
3740
|
e.pattern ?? (e.pattern = wd), $e.init(t, e);
|
|
3735
3741
|
}), rf = /* @__PURE__ */ A("$ZodUUID", (t, e) => {
|
|
@@ -3746,9 +3752,9 @@ const tf = {
|
|
|
3746
3752
|
}[e.version];
|
|
3747
3753
|
if (r === void 0)
|
|
3748
3754
|
throw new Error(`Invalid UUID version: "${e.version}"`);
|
|
3749
|
-
e.pattern ?? (e.pattern =
|
|
3755
|
+
e.pattern ?? (e.pattern = ya(r));
|
|
3750
3756
|
} else
|
|
3751
|
-
e.pattern ?? (e.pattern =
|
|
3757
|
+
e.pattern ?? (e.pattern = ya());
|
|
3752
3758
|
$e.init(t, e);
|
|
3753
3759
|
}), sf = /* @__PURE__ */ A("$ZodEmail", (t, e) => {
|
|
3754
3760
|
e.pattern ?? (e.pattern = kd), $e.init(t, e);
|
|
@@ -3978,7 +3984,7 @@ const Pf = /* @__PURE__ */ A("$ZodJWT", (t, e) => {
|
|
|
3978
3984
|
inst: t
|
|
3979
3985
|
}), n);
|
|
3980
3986
|
});
|
|
3981
|
-
function
|
|
3987
|
+
function va(t, e, n) {
|
|
3982
3988
|
t.issues.length && e.issues.push(...Vt(n, t.issues)), e.value[n] = t.value;
|
|
3983
3989
|
}
|
|
3984
3990
|
const xf = /* @__PURE__ */ A("$ZodArray", (t, e) => {
|
|
@@ -3998,7 +4004,7 @@ const xf = /* @__PURE__ */ A("$ZodArray", (t, e) => {
|
|
|
3998
4004
|
value: o,
|
|
3999
4005
|
issues: []
|
|
4000
4006
|
}, r);
|
|
4001
|
-
c instanceof Promise ? i.push(c.then((l) =>
|
|
4007
|
+
c instanceof Promise ? i.push(c.then((l) => va(l, n, a))) : va(c, n, a);
|
|
4002
4008
|
}
|
|
4003
4009
|
return i.length ? Promise.all(i).then(() => n) : n;
|
|
4004
4010
|
};
|
|
@@ -4006,12 +4012,12 @@ const xf = /* @__PURE__ */ A("$ZodArray", (t, e) => {
|
|
|
4006
4012
|
function qn(t, e, n) {
|
|
4007
4013
|
t.issues.length && e.issues.push(...Vt(n, t.issues)), e.value[n] = t.value;
|
|
4008
4014
|
}
|
|
4009
|
-
function
|
|
4015
|
+
function _a(t, e, n, r) {
|
|
4010
4016
|
t.issues.length ? r[n] === void 0 ? n in r ? e.value[n] = void 0 : e.value[n] = t.value : e.issues.push(...Vt(n, t.issues)) : t.value === void 0 ? n in r && (e.value[n] = void 0) : e.value[n] = t.value;
|
|
4011
4017
|
}
|
|
4012
4018
|
const qc = /* @__PURE__ */ A("$ZodObject", (t, e) => {
|
|
4013
4019
|
Se.init(t, e);
|
|
4014
|
-
const n =
|
|
4020
|
+
const n = mi(() => {
|
|
4015
4021
|
const h = Object.keys(e.shape);
|
|
4016
4022
|
for (const b of h)
|
|
4017
4023
|
if (!(e.shape[b] instanceof Se))
|
|
@@ -4106,7 +4112,7 @@ const qc = /* @__PURE__ */ A("$ZodObject", (t, e) => {
|
|
|
4106
4112
|
const p = d.shape;
|
|
4107
4113
|
for (const _ of d.keys) {
|
|
4108
4114
|
const w = p[_], g = w._zod.run({ value: b[_], issues: [] }, S), $ = w._zod.optin === "optional" && w._zod.optout === "optional";
|
|
4109
|
-
g instanceof Promise ? v.push(g.then((E) => $ ?
|
|
4115
|
+
g instanceof Promise ? v.push(g.then((E) => $ ? _a(E, h, _, b) : qn(E, h, _))) : $ ? _a(g, h, _, b) : qn(g, h, _);
|
|
4110
4116
|
}
|
|
4111
4117
|
}
|
|
4112
4118
|
if (!l)
|
|
@@ -4130,7 +4136,7 @@ const qc = /* @__PURE__ */ A("$ZodObject", (t, e) => {
|
|
|
4130
4136
|
}), v.length ? Promise.all(v).then(() => h) : h;
|
|
4131
4137
|
};
|
|
4132
4138
|
});
|
|
4133
|
-
function
|
|
4139
|
+
function ba(t, e, n, r) {
|
|
4134
4140
|
for (const s of t)
|
|
4135
4141
|
if (s.issues.length === 0)
|
|
4136
4142
|
return e.value = s.value, e;
|
|
@@ -4148,7 +4154,7 @@ const Lc = /* @__PURE__ */ A("$ZodUnion", (t, e) => {
|
|
|
4148
4154
|
}), we(t._zod, "pattern", () => {
|
|
4149
4155
|
if (e.options.every((n) => n._zod.pattern)) {
|
|
4150
4156
|
const n = e.options.map((r) => r._zod.pattern);
|
|
4151
|
-
return new RegExp(`^(${n.map((r) =>
|
|
4157
|
+
return new RegExp(`^(${n.map((r) => yi(r.source)).join("|")})$`);
|
|
4152
4158
|
}
|
|
4153
4159
|
}), t._zod.parse = (n, r) => {
|
|
4154
4160
|
let s = !1;
|
|
@@ -4166,7 +4172,7 @@ const Lc = /* @__PURE__ */ A("$ZodUnion", (t, e) => {
|
|
|
4166
4172
|
i.push(o);
|
|
4167
4173
|
}
|
|
4168
4174
|
}
|
|
4169
|
-
return s ? Promise.all(i).then((a) =>
|
|
4175
|
+
return s ? Promise.all(i).then((a) => ba(a, n, t, r)) : ba(i, n, t, r);
|
|
4170
4176
|
};
|
|
4171
4177
|
}), Af = /* @__PURE__ */ A("$ZodDiscriminatedUnion", (t, e) => {
|
|
4172
4178
|
Lc.init(t, e);
|
|
@@ -4185,7 +4191,7 @@ const Lc = /* @__PURE__ */ A("$ZodUnion", (t, e) => {
|
|
|
4185
4191
|
}
|
|
4186
4192
|
return s;
|
|
4187
4193
|
});
|
|
4188
|
-
const r =
|
|
4194
|
+
const r = mi(() => {
|
|
4189
4195
|
const s = e.options, i = /* @__PURE__ */ new Map();
|
|
4190
4196
|
for (const a of s) {
|
|
4191
4197
|
const o = a._zod.propValues[e.discriminator];
|
|
@@ -4221,10 +4227,10 @@ const Lc = /* @__PURE__ */ A("$ZodUnion", (t, e) => {
|
|
|
4221
4227
|
}), jf = /* @__PURE__ */ A("$ZodIntersection", (t, e) => {
|
|
4222
4228
|
Se.init(t, e), t._zod.parse = (n, r) => {
|
|
4223
4229
|
const s = n.value, i = e.left._zod.run({ value: s, issues: [] }, r), a = e.right._zod.run({ value: s, issues: [] }, r);
|
|
4224
|
-
return i instanceof Promise || a instanceof Promise ? Promise.all([i, a]).then(([c, l]) =>
|
|
4230
|
+
return i instanceof Promise || a instanceof Promise ? Promise.all([i, a]).then(([c, l]) => wa(n, c, l)) : wa(n, i, a);
|
|
4225
4231
|
};
|
|
4226
4232
|
});
|
|
4227
|
-
function
|
|
4233
|
+
function Js(t, e) {
|
|
4228
4234
|
if (t === e)
|
|
4229
4235
|
return { valid: !0, data: t };
|
|
4230
4236
|
if (t instanceof Date && e instanceof Date && +t == +e)
|
|
@@ -4232,7 +4238,7 @@ function Bs(t, e) {
|
|
|
4232
4238
|
if (qr(t) && qr(e)) {
|
|
4233
4239
|
const n = Object.keys(e), r = Object.keys(t).filter((i) => n.indexOf(i) !== -1), s = { ...t, ...e };
|
|
4234
4240
|
for (const i of r) {
|
|
4235
|
-
const a =
|
|
4241
|
+
const a = Js(t[i], e[i]);
|
|
4236
4242
|
if (!a.valid)
|
|
4237
4243
|
return {
|
|
4238
4244
|
valid: !1,
|
|
@@ -4247,7 +4253,7 @@ function Bs(t, e) {
|
|
|
4247
4253
|
return { valid: !1, mergeErrorPath: [] };
|
|
4248
4254
|
const n = [];
|
|
4249
4255
|
for (let r = 0; r < t.length; r++) {
|
|
4250
|
-
const s = t[r], i = e[r], a =
|
|
4256
|
+
const s = t[r], i = e[r], a = Js(s, i);
|
|
4251
4257
|
if (!a.valid)
|
|
4252
4258
|
return {
|
|
4253
4259
|
valid: !1,
|
|
@@ -4259,10 +4265,10 @@ function Bs(t, e) {
|
|
|
4259
4265
|
}
|
|
4260
4266
|
return { valid: !1, mergeErrorPath: [] };
|
|
4261
4267
|
}
|
|
4262
|
-
function
|
|
4268
|
+
function wa(t, e, n) {
|
|
4263
4269
|
if (e.issues.length && t.issues.push(...e.issues), n.issues.length && t.issues.push(...n.issues), vn(t))
|
|
4264
4270
|
return t;
|
|
4265
|
-
const r =
|
|
4271
|
+
const r = Js(e.value, n.value);
|
|
4266
4272
|
if (!r.valid)
|
|
4267
4273
|
throw new Error(`Unmergable intersection. Error path: ${JSON.stringify(r.mergeErrorPath)}`);
|
|
4268
4274
|
return t.value = r.data, t;
|
|
@@ -4358,22 +4364,22 @@ const zf = /* @__PURE__ */ A("$ZodRecord", (t, e) => {
|
|
|
4358
4364
|
}), qf = /* @__PURE__ */ A("$ZodOptional", (t, e) => {
|
|
4359
4365
|
Se.init(t, e), t._zod.optin = "optional", t._zod.optout = "optional", we(t._zod, "values", () => e.innerType._zod.values ? /* @__PURE__ */ new Set([...e.innerType._zod.values, void 0]) : void 0), we(t._zod, "pattern", () => {
|
|
4360
4366
|
const n = e.innerType._zod.pattern;
|
|
4361
|
-
return n ? new RegExp(`^(${
|
|
4367
|
+
return n ? new RegExp(`^(${yi(n.source)})?$`) : void 0;
|
|
4362
4368
|
}), t._zod.parse = (n, r) => e.innerType._zod.optin === "optional" ? e.innerType._zod.run(n, r) : n.value === void 0 ? n : e.innerType._zod.run(n, r);
|
|
4363
4369
|
}), Lf = /* @__PURE__ */ A("$ZodNullable", (t, e) => {
|
|
4364
4370
|
Se.init(t, e), we(t._zod, "optin", () => e.innerType._zod.optin), we(t._zod, "optout", () => e.innerType._zod.optout), we(t._zod, "pattern", () => {
|
|
4365
4371
|
const n = e.innerType._zod.pattern;
|
|
4366
|
-
return n ? new RegExp(`^(${
|
|
4372
|
+
return n ? new RegExp(`^(${yi(n.source)}|null)$`) : void 0;
|
|
4367
4373
|
}), we(t._zod, "values", () => e.innerType._zod.values ? /* @__PURE__ */ new Set([...e.innerType._zod.values, null]) : void 0), t._zod.parse = (n, r) => n.value === null ? n : e.innerType._zod.run(n, r);
|
|
4368
4374
|
}), Vf = /* @__PURE__ */ A("$ZodDefault", (t, e) => {
|
|
4369
4375
|
Se.init(t, e), t._zod.optin = "optional", we(t._zod, "values", () => e.innerType._zod.values), t._zod.parse = (n, r) => {
|
|
4370
4376
|
if (n.value === void 0)
|
|
4371
4377
|
return n.value = e.defaultValue, n;
|
|
4372
4378
|
const s = e.innerType._zod.run(n, r);
|
|
4373
|
-
return s instanceof Promise ? s.then((i) =>
|
|
4379
|
+
return s instanceof Promise ? s.then((i) => ka(i, e)) : ka(s, e);
|
|
4374
4380
|
};
|
|
4375
4381
|
});
|
|
4376
|
-
function
|
|
4382
|
+
function ka(t, e) {
|
|
4377
4383
|
return t.value === void 0 && (t.value = e.defaultValue), t;
|
|
4378
4384
|
}
|
|
4379
4385
|
const Ff = /* @__PURE__ */ A("$ZodPrefault", (t, e) => {
|
|
@@ -4384,10 +4390,10 @@ const Ff = /* @__PURE__ */ A("$ZodPrefault", (t, e) => {
|
|
|
4384
4390
|
return n ? new Set([...n].filter((r) => r !== void 0)) : void 0;
|
|
4385
4391
|
}), t._zod.parse = (n, r) => {
|
|
4386
4392
|
const s = e.innerType._zod.run(n, r);
|
|
4387
|
-
return s instanceof Promise ? s.then((i) =>
|
|
4393
|
+
return s instanceof Promise ? s.then((i) => Sa(i, t)) : Sa(s, t);
|
|
4388
4394
|
};
|
|
4389
4395
|
});
|
|
4390
|
-
function
|
|
4396
|
+
function Sa(t, e) {
|
|
4391
4397
|
return !t.issues.length && t.value === void 0 && t.issues.push({
|
|
4392
4398
|
code: "invalid_type",
|
|
4393
4399
|
expected: "nonoptional",
|
|
@@ -4415,30 +4421,30 @@ const Hf = /* @__PURE__ */ A("$ZodCatch", (t, e) => {
|
|
|
4415
4421
|
}), Kf = /* @__PURE__ */ A("$ZodPipe", (t, e) => {
|
|
4416
4422
|
Se.init(t, e), we(t._zod, "values", () => e.in._zod.values), we(t._zod, "optin", () => e.in._zod.optin), we(t._zod, "optout", () => e.out._zod.optout), t._zod.parse = (n, r) => {
|
|
4417
4423
|
const s = e.in._zod.run(n, r);
|
|
4418
|
-
return s instanceof Promise ? s.then((i) =>
|
|
4424
|
+
return s instanceof Promise ? s.then((i) => $a(i, e, r)) : $a(s, e, r);
|
|
4419
4425
|
};
|
|
4420
4426
|
});
|
|
4421
|
-
function
|
|
4427
|
+
function $a(t, e, n) {
|
|
4422
4428
|
return vn(t) ? t : e.out._zod.run({ value: t.value, issues: t.issues }, n);
|
|
4423
4429
|
}
|
|
4424
4430
|
const Wf = /* @__PURE__ */ A("$ZodReadonly", (t, e) => {
|
|
4425
4431
|
Se.init(t, e), we(t._zod, "propValues", () => e.innerType._zod.propValues), we(t._zod, "values", () => e.innerType._zod.values), we(t._zod, "optin", () => e.innerType._zod.optin), we(t._zod, "optout", () => e.innerType._zod.optout), t._zod.parse = (n, r) => {
|
|
4426
4432
|
const s = e.innerType._zod.run(n, r);
|
|
4427
|
-
return s instanceof Promise ? s.then(
|
|
4433
|
+
return s instanceof Promise ? s.then(Ta) : Ta(s);
|
|
4428
4434
|
};
|
|
4429
4435
|
});
|
|
4430
|
-
function
|
|
4436
|
+
function Ta(t) {
|
|
4431
4437
|
return t.value = Object.freeze(t.value), t;
|
|
4432
4438
|
}
|
|
4433
|
-
const
|
|
4439
|
+
const Bf = /* @__PURE__ */ A("$ZodCustom", (t, e) => {
|
|
4434
4440
|
Ke.init(t, e), Se.init(t, e), t._zod.parse = (n, r) => n, t._zod.check = (n) => {
|
|
4435
4441
|
const r = n.value, s = e.fn(r);
|
|
4436
4442
|
if (s instanceof Promise)
|
|
4437
|
-
return s.then((i) =>
|
|
4438
|
-
|
|
4443
|
+
return s.then((i) => Ea(i, n, r, t));
|
|
4444
|
+
Ea(s, n, r, t);
|
|
4439
4445
|
};
|
|
4440
4446
|
});
|
|
4441
|
-
function
|
|
4447
|
+
function Ea(t, e, n, r) {
|
|
4442
4448
|
if (!t) {
|
|
4443
4449
|
const s = {
|
|
4444
4450
|
code: "custom",
|
|
@@ -4485,10 +4491,10 @@ class Vc {
|
|
|
4485
4491
|
return this._map.has(e);
|
|
4486
4492
|
}
|
|
4487
4493
|
}
|
|
4488
|
-
function
|
|
4494
|
+
function Gf() {
|
|
4489
4495
|
return new Vc();
|
|
4490
4496
|
}
|
|
4491
|
-
const gn = /* @__PURE__ */
|
|
4497
|
+
const gn = /* @__PURE__ */ Gf();
|
|
4492
4498
|
function Jf(t, e) {
|
|
4493
4499
|
return new t({
|
|
4494
4500
|
type: "string",
|
|
@@ -4504,7 +4510,7 @@ function Yf(t, e) {
|
|
|
4504
4510
|
...Y(e)
|
|
4505
4511
|
});
|
|
4506
4512
|
}
|
|
4507
|
-
function
|
|
4513
|
+
function Pa(t, e) {
|
|
4508
4514
|
return new t({
|
|
4509
4515
|
type: "string",
|
|
4510
4516
|
format: "guid",
|
|
@@ -4771,7 +4777,7 @@ function Pp(t, e) {
|
|
|
4771
4777
|
...Y(e)
|
|
4772
4778
|
});
|
|
4773
4779
|
}
|
|
4774
|
-
function
|
|
4780
|
+
function Ra(t, e) {
|
|
4775
4781
|
return new zc({
|
|
4776
4782
|
check: "less_than",
|
|
4777
4783
|
...Y(e),
|
|
@@ -4787,7 +4793,7 @@ function vs(t, e) {
|
|
|
4787
4793
|
inclusive: !0
|
|
4788
4794
|
});
|
|
4789
4795
|
}
|
|
4790
|
-
function
|
|
4796
|
+
function Ia(t, e) {
|
|
4791
4797
|
return new Mc({
|
|
4792
4798
|
check: "greater_than",
|
|
4793
4799
|
...Y(e),
|
|
@@ -4803,7 +4809,7 @@ function _s(t, e) {
|
|
|
4803
4809
|
inclusive: !0
|
|
4804
4810
|
});
|
|
4805
4811
|
}
|
|
4806
|
-
function
|
|
4812
|
+
function Ca(t, e) {
|
|
4807
4813
|
return new Vd({
|
|
4808
4814
|
check: "multiple_of",
|
|
4809
4815
|
...Y(e),
|
|
@@ -4840,14 +4846,14 @@ function Rp(t, e) {
|
|
|
4840
4846
|
});
|
|
4841
4847
|
}
|
|
4842
4848
|
function Ip(t) {
|
|
4843
|
-
return new
|
|
4849
|
+
return new Bd({
|
|
4844
4850
|
check: "string_format",
|
|
4845
4851
|
format: "lowercase",
|
|
4846
4852
|
...Y(t)
|
|
4847
4853
|
});
|
|
4848
4854
|
}
|
|
4849
4855
|
function Cp(t) {
|
|
4850
|
-
return new
|
|
4856
|
+
return new Gd({
|
|
4851
4857
|
check: "string_format",
|
|
4852
4858
|
format: "uppercase",
|
|
4853
4859
|
...Y(t)
|
|
@@ -4922,7 +4928,7 @@ function qp(t, e, n) {
|
|
|
4922
4928
|
...Y(n)
|
|
4923
4929
|
});
|
|
4924
4930
|
}
|
|
4925
|
-
class
|
|
4931
|
+
class Oa {
|
|
4926
4932
|
constructor(e) {
|
|
4927
4933
|
this.counter = 0, this.metadataRegistry = e?.metadata ?? gn, this.target = e?.target ?? "draft-2020-12", this.unrepresentable = e?.unrepresentable ?? "throw", this.override = e?.override ?? (() => {
|
|
4928
4934
|
}), this.io = e?.io ?? "output", this.seen = /* @__PURE__ */ new Map();
|
|
@@ -5325,7 +5331,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
5325
5331
|
}
|
|
5326
5332
|
function Lp(t, e) {
|
|
5327
5333
|
if (t instanceof Vc) {
|
|
5328
|
-
const r = new
|
|
5334
|
+
const r = new Oa(e), s = {};
|
|
5329
5335
|
for (const o of t._idmap.entries()) {
|
|
5330
5336
|
const [c, l] = o;
|
|
5331
5337
|
r.process(l);
|
|
@@ -5350,7 +5356,7 @@ function Lp(t, e) {
|
|
|
5350
5356
|
}
|
|
5351
5357
|
return { schemas: i };
|
|
5352
5358
|
}
|
|
5353
|
-
const n = new
|
|
5359
|
+
const n = new Oa(e);
|
|
5354
5360
|
return n.process(t), n.emit(t, e);
|
|
5355
5361
|
}
|
|
5356
5362
|
function Ie(t, e) {
|
|
@@ -5435,7 +5441,7 @@ function Ie(t, e) {
|
|
|
5435
5441
|
const Vp = /* @__PURE__ */ A("ZodMiniType", (t, e) => {
|
|
5436
5442
|
if (!t._zod)
|
|
5437
5443
|
throw new Error("Uninitialized schema in ZodMiniType.");
|
|
5438
|
-
Se.init(t, e), t.def = e, t.parse = (n, r) => fd(t, n, r, { callee: t.parse }), t.safeParse = (n, r) =>
|
|
5444
|
+
Se.init(t, e), t.def = e, t.parse = (n, r) => fd(t, n, r, { callee: t.parse }), t.safeParse = (n, r) => _i(t, n, r), t.parseAsync = async (n, r) => pd(t, n, r, { callee: t.parseAsync }), t.safeParseAsync = async (n, r) => bi(t, n, r), t.check = (...n) => t.clone(
|
|
5439
5445
|
{
|
|
5440
5446
|
...e,
|
|
5441
5447
|
checks: [
|
|
@@ -5448,7 +5454,7 @@ const Vp = /* @__PURE__ */ A("ZodMiniType", (t, e) => {
|
|
|
5448
5454
|
}), Fp = /* @__PURE__ */ A("ZodMiniObject", (t, e) => {
|
|
5449
5455
|
qc.init(t, e), Vp.init(t, e), we(t, "shape", () => e.shape);
|
|
5450
5456
|
});
|
|
5451
|
-
function
|
|
5457
|
+
function Na(t, e) {
|
|
5452
5458
|
const n = {
|
|
5453
5459
|
type: "object",
|
|
5454
5460
|
get shape() {
|
|
@@ -5464,19 +5470,19 @@ function ut(t) {
|
|
|
5464
5470
|
function _n(t) {
|
|
5465
5471
|
const e = Object.values(t);
|
|
5466
5472
|
if (e.length === 0)
|
|
5467
|
-
return
|
|
5473
|
+
return Na({});
|
|
5468
5474
|
const n = e.every(ut), r = e.every((s) => !ut(s));
|
|
5469
5475
|
if (n)
|
|
5470
|
-
return
|
|
5476
|
+
return Na(t);
|
|
5471
5477
|
if (r)
|
|
5472
5478
|
return Yl(t);
|
|
5473
5479
|
throw new Error("Mixed Zod versions detected in object shape.");
|
|
5474
5480
|
}
|
|
5475
5481
|
function bn(t, e) {
|
|
5476
|
-
return ut(t) ?
|
|
5482
|
+
return ut(t) ? _i(t, e) : t.safeParse(e);
|
|
5477
5483
|
}
|
|
5478
5484
|
async function bs(t, e) {
|
|
5479
|
-
return ut(t) ? await
|
|
5485
|
+
return ut(t) ? await bi(t, e) : await t.safeParseAsync(e);
|
|
5480
5486
|
}
|
|
5481
5487
|
function An(t) {
|
|
5482
5488
|
var e, n;
|
|
@@ -5574,14 +5580,14 @@ function Kc(t) {
|
|
|
5574
5580
|
const Wp = /* @__PURE__ */ A("ZodISODate", (t, e) => {
|
|
5575
5581
|
mf.init(t, e), Pe.init(t, e);
|
|
5576
5582
|
});
|
|
5577
|
-
function
|
|
5583
|
+
function Bp(t) {
|
|
5578
5584
|
return _p(Wp, t);
|
|
5579
5585
|
}
|
|
5580
|
-
const
|
|
5586
|
+
const Gp = /* @__PURE__ */ A("ZodISOTime", (t, e) => {
|
|
5581
5587
|
gf.init(t, e), Pe.init(t, e);
|
|
5582
5588
|
});
|
|
5583
5589
|
function Jp(t) {
|
|
5584
|
-
return bp(
|
|
5590
|
+
return bp(Gp, t);
|
|
5585
5591
|
}
|
|
5586
5592
|
const Yp = /* @__PURE__ */ A("ZodISODuration", (t, e) => {
|
|
5587
5593
|
yf.init(t, e), Pe.init(t, e);
|
|
@@ -5625,7 +5631,7 @@ const Xp = (t, e) => {
|
|
|
5625
5631
|
]
|
|
5626
5632
|
}
|
|
5627
5633
|
// { parent: true }
|
|
5628
|
-
), t.clone = (n, r) => zt(t, n, r), t.brand = () => t, t.register = (n, r) => (n.add(t, r), t), t.parse = (n, r) => eh(t, n, r, { callee: t.parse }), t.safeParse = (n, r) => nh(t, n, r), t.parseAsync = async (n, r) => th(t, n, r, { callee: t.parseAsync }), t.safeParseAsync = async (n, r) => rh(t, n, r), t.spa = t.safeParseAsync, t.refine = (n, r) => t.check(Wh(n, r)), t.superRefine = (n) => t.check(
|
|
5634
|
+
), t.clone = (n, r) => zt(t, n, r), t.brand = () => t, t.register = (n, r) => (n.add(t, r), t), t.parse = (n, r) => eh(t, n, r, { callee: t.parse }), t.safeParse = (n, r) => nh(t, n, r), t.parseAsync = async (n, r) => th(t, n, r, { callee: t.parseAsync }), t.safeParseAsync = async (n, r) => rh(t, n, r), t.spa = t.safeParseAsync, t.refine = (n, r) => t.check(Wh(n, r)), t.superRefine = (n) => t.check(Bh(n)), t.overwrite = (n) => t.check(xn(n)), t.optional = () => X(t), t.nullable = () => ja(t), t.nullish = () => X(ja(t)), t.nonoptional = (n) => Dh(t, n), t.array = () => de(t), t.or = (n) => Te([t, n]), t.and = (n) => ki(t, n), t.transform = (n) => Qs(t, Xc(n)), t.default = (n) => zh(t, n), t.prefault = (n) => Zh(t, n), t.catch = (n) => Lh(t, n), t.pipe = (n) => Qs(t, n), t.readonly = () => Uh(t), t.describe = (n) => {
|
|
5629
5635
|
const r = t.clone();
|
|
5630
5636
|
return gn.add(r, { description: n }), r;
|
|
5631
5637
|
}, Object.defineProperty(t, "description", {
|
|
@@ -5639,11 +5645,11 @@ const Xp = (t, e) => {
|
|
|
5639
5645
|
const r = t.clone();
|
|
5640
5646
|
return gn.add(r, n[0]), r;
|
|
5641
5647
|
}, t.isOptional = () => t.safeParse(void 0).success, t.isNullable = () => t.safeParse(null).success, t)), Wc = /* @__PURE__ */ A("_ZodString", (t, e) => {
|
|
5642
|
-
|
|
5648
|
+
wi.init(t, e), Ee.init(t, e);
|
|
5643
5649
|
const n = t._zod.bag;
|
|
5644
5650
|
t.format = n.format ?? null, t.minLength = n.minimum ?? null, t.maxLength = n.maximum ?? null, t.regex = (...r) => t.check(Rp(...r)), t.includes = (...r) => t.check(Op(...r)), t.startsWith = (...r) => t.check(Np(...r)), t.endsWith = (...r) => t.check(xp(...r)), t.min = (...r) => t.check(Lr(...r)), t.max = (...r) => t.check(Fc(...r)), t.length = (...r) => t.check(Uc(...r)), t.nonempty = (...r) => t.check(Lr(1, ...r)), t.lowercase = (r) => t.check(Ip(r)), t.uppercase = (r) => t.check(Cp(r)), t.trim = () => t.check(jp()), t.normalize = (...r) => t.check(Ap(...r)), t.toLowerCase = () => t.check(zp()), t.toUpperCase = () => t.check(Mp());
|
|
5645
5651
|
}), sh = /* @__PURE__ */ A("ZodString", (t, e) => {
|
|
5646
|
-
|
|
5652
|
+
wi.init(t, e), Wc.init(t, e), t.email = (n) => t.check(Yf(ih, n)), t.url = (n) => t.check(np(ah, n)), t.jwt = (n) => t.check(yp(wh, n)), t.emoji = (n) => t.check(rp(oh, n)), t.guid = (n) => t.check(Pa(xa, n)), t.uuid = (n) => t.check(Qf(Ln, n)), t.uuidv4 = (n) => t.check(Xf(Ln, n)), t.uuidv6 = (n) => t.check(ep(Ln, n)), t.uuidv7 = (n) => t.check(tp(Ln, n)), t.nanoid = (n) => t.check(sp(ch, n)), t.guid = (n) => t.check(Pa(xa, n)), t.cuid = (n) => t.check(ip(uh, n)), t.cuid2 = (n) => t.check(ap(lh, n)), t.ulid = (n) => t.check(op(dh, n)), t.base64 = (n) => t.check(hp(vh, n)), t.base64url = (n) => t.check(mp(_h, n)), t.xid = (n) => t.check(cp(fh, n)), t.ksuid = (n) => t.check(up(ph, n)), t.ipv4 = (n) => t.check(lp(hh, n)), t.ipv6 = (n) => t.check(dp(mh, n)), t.cidrv4 = (n) => t.check(fp(gh, n)), t.cidrv6 = (n) => t.check(pp(yh, n)), t.e164 = (n) => t.check(gp(bh, n)), t.datetime = (n) => t.check(Kc(n)), t.date = (n) => t.check(Bp(n)), t.time = (n) => t.check(Jp(n)), t.duration = (n) => t.check(Qp(n));
|
|
5647
5653
|
});
|
|
5648
5654
|
function x(t) {
|
|
5649
5655
|
return Jf(sh, t);
|
|
@@ -5652,7 +5658,7 @@ const Pe = /* @__PURE__ */ A("ZodStringFormat", (t, e) => {
|
|
|
5652
5658
|
$e.init(t, e), Wc.init(t, e);
|
|
5653
5659
|
}), ih = /* @__PURE__ */ A("ZodEmail", (t, e) => {
|
|
5654
5660
|
sf.init(t, e), Pe.init(t, e);
|
|
5655
|
-
}),
|
|
5661
|
+
}), xa = /* @__PURE__ */ A("ZodGUID", (t, e) => {
|
|
5656
5662
|
nf.init(t, e), Pe.init(t, e);
|
|
5657
5663
|
}), Ln = /* @__PURE__ */ A("ZodUUID", (t, e) => {
|
|
5658
5664
|
rf.init(t, e), Pe.init(t, e);
|
|
@@ -5688,18 +5694,18 @@ const Pe = /* @__PURE__ */ A("ZodStringFormat", (t, e) => {
|
|
|
5688
5694
|
Tf.init(t, e), Pe.init(t, e);
|
|
5689
5695
|
}), wh = /* @__PURE__ */ A("ZodJWT", (t, e) => {
|
|
5690
5696
|
Pf.init(t, e), Pe.init(t, e);
|
|
5691
|
-
}),
|
|
5692
|
-
Dc.init(t, e), Ee.init(t, e), t.gt = (r, s) => t.check(
|
|
5697
|
+
}), Bc = /* @__PURE__ */ A("ZodNumber", (t, e) => {
|
|
5698
|
+
Dc.init(t, e), Ee.init(t, e), t.gt = (r, s) => t.check(Ia(r, s)), t.gte = (r, s) => t.check(_s(r, s)), t.min = (r, s) => t.check(_s(r, s)), t.lt = (r, s) => t.check(Ra(r, s)), t.lte = (r, s) => t.check(vs(r, s)), t.max = (r, s) => t.check(vs(r, s)), t.int = (r) => t.check(Aa(r)), t.safe = (r) => t.check(Aa(r)), t.positive = (r) => t.check(Ia(0, r)), t.nonnegative = (r) => t.check(_s(0, r)), t.negative = (r) => t.check(Ra(0, r)), t.nonpositive = (r) => t.check(vs(0, r)), t.multipleOf = (r, s) => t.check(Ca(r, s)), t.step = (r, s) => t.check(Ca(r, s)), t.finite = () => t;
|
|
5693
5699
|
const n = t._zod.bag;
|
|
5694
5700
|
t.minValue = Math.max(n.minimum ?? Number.NEGATIVE_INFINITY, n.exclusiveMinimum ?? Number.NEGATIVE_INFINITY) ?? null, t.maxValue = Math.min(n.maximum ?? Number.POSITIVE_INFINITY, n.exclusiveMaximum ?? Number.POSITIVE_INFINITY) ?? null, t.isInt = (n.format ?? "").includes("int") || Number.isSafeInteger(n.multipleOf ?? 0.5), t.isFinite = !0, t.format = n.format ?? null;
|
|
5695
5701
|
});
|
|
5696
5702
|
function ke(t) {
|
|
5697
|
-
return kp(
|
|
5703
|
+
return kp(Bc, t);
|
|
5698
5704
|
}
|
|
5699
5705
|
const kh = /* @__PURE__ */ A("ZodNumberFormat", (t, e) => {
|
|
5700
|
-
Rf.init(t, e),
|
|
5706
|
+
Rf.init(t, e), Bc.init(t, e);
|
|
5701
5707
|
});
|
|
5702
|
-
function
|
|
5708
|
+
function Aa(t) {
|
|
5703
5709
|
return Sp(kh, t);
|
|
5704
5710
|
}
|
|
5705
5711
|
const Sh = /* @__PURE__ */ A("ZodBoolean", (t, e) => {
|
|
@@ -5711,7 +5717,7 @@ function Me(t) {
|
|
|
5711
5717
|
const $h = /* @__PURE__ */ A("ZodNull", (t, e) => {
|
|
5712
5718
|
Cf.init(t, e), Ee.init(t, e);
|
|
5713
5719
|
});
|
|
5714
|
-
function
|
|
5720
|
+
function Gc(t) {
|
|
5715
5721
|
return Tp($h, t);
|
|
5716
5722
|
}
|
|
5717
5723
|
const Th = /* @__PURE__ */ A("ZodUnknown", (t, e) => {
|
|
@@ -5779,7 +5785,7 @@ function Qc(t, e, n) {
|
|
|
5779
5785
|
const Ch = /* @__PURE__ */ A("ZodIntersection", (t, e) => {
|
|
5780
5786
|
jf.init(t, e), Ee.init(t, e);
|
|
5781
5787
|
});
|
|
5782
|
-
function
|
|
5788
|
+
function ki(t, e) {
|
|
5783
5789
|
return new Ch({
|
|
5784
5790
|
type: "intersection",
|
|
5785
5791
|
left: t,
|
|
@@ -5797,7 +5803,7 @@ function Oe(t, e, n) {
|
|
|
5797
5803
|
...Y(n)
|
|
5798
5804
|
});
|
|
5799
5805
|
}
|
|
5800
|
-
const
|
|
5806
|
+
const Ys = /* @__PURE__ */ A("ZodEnum", (t, e) => {
|
|
5801
5807
|
Mf.init(t, e), Ee.init(t, e), t.enum = e.entries, t.options = Object.values(e.entries);
|
|
5802
5808
|
const n = new Set(Object.keys(e.entries));
|
|
5803
5809
|
t.extract = (r, s) => {
|
|
@@ -5807,7 +5813,7 @@ const Js = /* @__PURE__ */ A("ZodEnum", (t, e) => {
|
|
|
5807
5813
|
i[a] = e.entries[a];
|
|
5808
5814
|
else
|
|
5809
5815
|
throw new Error(`Key ${a} not found in enum`);
|
|
5810
|
-
return new
|
|
5816
|
+
return new Ys({
|
|
5811
5817
|
...e,
|
|
5812
5818
|
checks: [],
|
|
5813
5819
|
...Y(s),
|
|
@@ -5820,7 +5826,7 @@ const Js = /* @__PURE__ */ A("ZodEnum", (t, e) => {
|
|
|
5820
5826
|
delete i[a];
|
|
5821
5827
|
else
|
|
5822
5828
|
throw new Error(`Key ${a} not found in enum`);
|
|
5823
|
-
return new
|
|
5829
|
+
return new Ys({
|
|
5824
5830
|
...e,
|
|
5825
5831
|
checks: [],
|
|
5826
5832
|
...Y(s),
|
|
@@ -5830,7 +5836,7 @@ const Js = /* @__PURE__ */ A("ZodEnum", (t, e) => {
|
|
|
5830
5836
|
});
|
|
5831
5837
|
function Ze(t, e) {
|
|
5832
5838
|
const n = Array.isArray(t) ? Object.fromEntries(t.map((r) => [r, r])) : t;
|
|
5833
|
-
return new
|
|
5839
|
+
return new Ys({
|
|
5834
5840
|
type: "enum",
|
|
5835
5841
|
entries: n,
|
|
5836
5842
|
...Y(e)
|
|
@@ -5884,7 +5890,7 @@ function X(t) {
|
|
|
5884
5890
|
const Ah = /* @__PURE__ */ A("ZodNullable", (t, e) => {
|
|
5885
5891
|
Lf.init(t, e), Ee.init(t, e), t.unwrap = () => t._zod.def.innerType;
|
|
5886
5892
|
});
|
|
5887
|
-
function
|
|
5893
|
+
function ja(t) {
|
|
5888
5894
|
return new Ah({
|
|
5889
5895
|
type: "nullable",
|
|
5890
5896
|
innerType: t
|
|
@@ -5937,7 +5943,7 @@ function Lh(t, e) {
|
|
|
5937
5943
|
const Vh = /* @__PURE__ */ A("ZodPipe", (t, e) => {
|
|
5938
5944
|
Kf.init(t, e), Ee.init(t, e), t.in = e.in, t.out = e.out;
|
|
5939
5945
|
});
|
|
5940
|
-
function
|
|
5946
|
+
function Qs(t, e) {
|
|
5941
5947
|
return new Vh({
|
|
5942
5948
|
type: "pipe",
|
|
5943
5949
|
in: t,
|
|
@@ -5955,7 +5961,7 @@ function Uh(t) {
|
|
|
5955
5961
|
});
|
|
5956
5962
|
}
|
|
5957
5963
|
const nu = /* @__PURE__ */ A("ZodCustom", (t, e) => {
|
|
5958
|
-
|
|
5964
|
+
Bf.init(t, e), Ee.init(t, e);
|
|
5959
5965
|
});
|
|
5960
5966
|
function Hh(t) {
|
|
5961
5967
|
const e = new Ke({
|
|
@@ -5970,7 +5976,7 @@ function Kh(t, e) {
|
|
|
5970
5976
|
function Wh(t, e = {}) {
|
|
5971
5977
|
return qp(nu, t, e);
|
|
5972
5978
|
}
|
|
5973
|
-
function
|
|
5979
|
+
function Bh(t) {
|
|
5974
5980
|
const e = Hh((n) => (n.addIssue = (r) => {
|
|
5975
5981
|
if (typeof r == "string")
|
|
5976
5982
|
n.issues.push(Tn(r, n.value, e._zod.def));
|
|
@@ -5982,19 +5988,19 @@ function Gh(t) {
|
|
|
5982
5988
|
return e;
|
|
5983
5989
|
}
|
|
5984
5990
|
function ru(t, e) {
|
|
5985
|
-
return
|
|
5991
|
+
return Qs(Xc(t), e);
|
|
5986
5992
|
}
|
|
5987
|
-
const su = "2025-11-25",
|
|
5993
|
+
const su = "2025-11-25", Gh = [su, "2025-06-18", "2025-03-26", "2024-11-05", "2024-10-07"], bt = "io.modelcontextprotocol/related-task", rs = "2.0", mt = Kh((t) => t !== null && (typeof t == "object" || typeof t == "function")), iu = Te([x(), ke().int()]), au = x(), Jh = lt({
|
|
5988
5994
|
/**
|
|
5989
5995
|
* Time in milliseconds to keep task results available after completion.
|
|
5990
5996
|
* If null, the task has unlimited lifetime until manually cleaned up.
|
|
5991
5997
|
*/
|
|
5992
|
-
ttl: Te([ke(),
|
|
5998
|
+
ttl: Te([ke(), Gc()]).optional(),
|
|
5993
5999
|
/**
|
|
5994
6000
|
* Time in milliseconds to wait between task status requests.
|
|
5995
6001
|
*/
|
|
5996
6002
|
pollInterval: ke().optional()
|
|
5997
|
-
}),
|
|
6003
|
+
}), Si = lt({
|
|
5998
6004
|
taskId: x()
|
|
5999
6005
|
}), Yh = lt({
|
|
6000
6006
|
/**
|
|
@@ -6004,7 +6010,7 @@ const su = "2025-11-25", Bh = [su, "2025-06-18", "2025-03-26", "2024-11-05", "20
|
|
|
6004
6010
|
/**
|
|
6005
6011
|
* If specified, this request is related to the provided task.
|
|
6006
6012
|
*/
|
|
6007
|
-
[bt]:
|
|
6013
|
+
[bt]: Si.optional()
|
|
6008
6014
|
}), We = lt({
|
|
6009
6015
|
/**
|
|
6010
6016
|
* If specified, the caller is requesting that the receiver create a task to represent the request.
|
|
@@ -6027,7 +6033,7 @@ const su = "2025-11-25", Bh = [su, "2025-06-18", "2025-03-26", "2024-11-05", "20
|
|
|
6027
6033
|
/**
|
|
6028
6034
|
* If specified, this notification is related to the provided task.
|
|
6029
6035
|
*/
|
|
6030
|
-
[bt]: X(
|
|
6036
|
+
[bt]: X(Si)
|
|
6031
6037
|
}).passthrough().optional()
|
|
6032
6038
|
}), et = U({
|
|
6033
6039
|
method: x(),
|
|
@@ -6041,13 +6047,13 @@ const su = "2025-11-25", Bh = [su, "2025-06-18", "2025-03-26", "2024-11-05", "20
|
|
|
6041
6047
|
/**
|
|
6042
6048
|
* If specified, this result is related to the provided task.
|
|
6043
6049
|
*/
|
|
6044
|
-
[bt]:
|
|
6050
|
+
[bt]: Si.optional()
|
|
6045
6051
|
}).optional()
|
|
6046
6052
|
}), ss = Te([x(), ke().int()]), ou = U({
|
|
6047
6053
|
jsonrpc: ee(rs),
|
|
6048
6054
|
id: ss,
|
|
6049
6055
|
...ze.shape
|
|
6050
|
-
}).strict(),
|
|
6056
|
+
}).strict(), za = (t) => ou.safeParse(t).success, cu = U({
|
|
6051
6057
|
jsonrpc: ee(rs),
|
|
6052
6058
|
...et.shape
|
|
6053
6059
|
}).strict(), Qh = (t) => cu.safeParse(t).success, uu = U({
|
|
@@ -6076,7 +6082,7 @@ const lu = U({
|
|
|
6076
6082
|
*/
|
|
6077
6083
|
data: X(Ce())
|
|
6078
6084
|
})
|
|
6079
|
-
}).strict(), Xh = (t) => lu.safeParse(t).success, em = Te([ou, cu, uu, lu]),
|
|
6085
|
+
}).strict(), Xh = (t) => lu.safeParse(t).success, em = Te([ou, cu, uu, lu]), $i = De.strict(), tm = Kt.extend({
|
|
6080
6086
|
/**
|
|
6081
6087
|
* The ID of the request to cancel.
|
|
6082
6088
|
*
|
|
@@ -6087,7 +6093,7 @@ const lu = U({
|
|
|
6087
6093
|
* An optional string describing the reason for the cancellation. This MAY be logged or presented to the user.
|
|
6088
6094
|
*/
|
|
6089
6095
|
reason: x().optional()
|
|
6090
|
-
}),
|
|
6096
|
+
}), Ti = et.extend({
|
|
6091
6097
|
method: ee("notifications/cancelled"),
|
|
6092
6098
|
params: tm
|
|
6093
6099
|
}), nm = U({
|
|
@@ -6139,9 +6145,9 @@ const lu = U({
|
|
|
6139
6145
|
* An optional URL of the website for this implementation.
|
|
6140
6146
|
*/
|
|
6141
6147
|
websiteUrl: x().optional()
|
|
6142
|
-
}), rm =
|
|
6148
|
+
}), rm = ki(U({
|
|
6143
6149
|
applyDefaults: Me().optional()
|
|
6144
|
-
}), Oe(x(), Ce())), sm = ru((t) => t && typeof t == "object" && !Array.isArray(t) && Object.keys(t).length === 0 ? { form: {} } : t,
|
|
6150
|
+
}), Oe(x(), Ce())), sm = ru((t) => t && typeof t == "object" && !Array.isArray(t) && Object.keys(t).length === 0 ? { form: {} } : t, ki(U({
|
|
6145
6151
|
form: rm.optional(),
|
|
6146
6152
|
url: mt.optional()
|
|
6147
6153
|
}), Oe(x(), Ce()).optional())), im = U({
|
|
@@ -6299,7 +6305,7 @@ const lu = U({
|
|
|
6299
6305
|
instructions: x().optional()
|
|
6300
6306
|
}), pu = et.extend({
|
|
6301
6307
|
method: ee("notifications/initialized")
|
|
6302
|
-
}),
|
|
6308
|
+
}), Ei = ze.extend({
|
|
6303
6309
|
method: ee("ping")
|
|
6304
6310
|
}), dm = U({
|
|
6305
6311
|
/**
|
|
@@ -6321,7 +6327,7 @@ const lu = U({
|
|
|
6321
6327
|
* The progress token which was given in the initial request, used to associate this notification with the request that is proceeding.
|
|
6322
6328
|
*/
|
|
6323
6329
|
progressToken: iu
|
|
6324
|
-
}),
|
|
6330
|
+
}), Pi = et.extend({
|
|
6325
6331
|
method: ee("notifications/progress"),
|
|
6326
6332
|
params: fm
|
|
6327
6333
|
}), pm = We.extend({
|
|
@@ -6345,7 +6351,7 @@ const lu = U({
|
|
|
6345
6351
|
* Time in milliseconds to keep task results available after completion.
|
|
6346
6352
|
* If null, the task has unlimited lifetime until manually cleaned up.
|
|
6347
6353
|
*/
|
|
6348
|
-
ttl: Te([ke(),
|
|
6354
|
+
ttl: Te([ke(), Gc()]),
|
|
6349
6355
|
/**
|
|
6350
6356
|
* ISO 8601 timestamp when the task was created.
|
|
6351
6357
|
*/
|
|
@@ -6364,19 +6370,19 @@ const lu = U({
|
|
|
6364
6370
|
}), hm = Kt.merge(Zn), Vr = et.extend({
|
|
6365
6371
|
method: ee("notifications/tasks/status"),
|
|
6366
6372
|
params: hm
|
|
6367
|
-
}),
|
|
6373
|
+
}), Ri = ze.extend({
|
|
6368
6374
|
method: ee("tasks/get"),
|
|
6369
6375
|
params: We.extend({
|
|
6370
6376
|
taskId: x()
|
|
6371
6377
|
})
|
|
6372
|
-
}),
|
|
6378
|
+
}), Ii = De.merge(Zn), Ci = ze.extend({
|
|
6373
6379
|
method: ee("tasks/result"),
|
|
6374
6380
|
params: We.extend({
|
|
6375
6381
|
taskId: x()
|
|
6376
6382
|
})
|
|
6377
|
-
}),
|
|
6383
|
+
}), Oi = zn.extend({
|
|
6378
6384
|
method: ee("tasks/list")
|
|
6379
|
-
}),
|
|
6385
|
+
}), Ni = Mn.extend({
|
|
6380
6386
|
tasks: de(Zn)
|
|
6381
6387
|
}), mm = ze.extend({
|
|
6382
6388
|
method: ee("tasks/cancel"),
|
|
@@ -6402,7 +6408,7 @@ const lu = U({
|
|
|
6402
6408
|
* The text of the item. This must only be set if the item can actually be represented as text (not binary data).
|
|
6403
6409
|
*/
|
|
6404
6410
|
text: x()
|
|
6405
|
-
}),
|
|
6411
|
+
}), xi = x().refine((t) => {
|
|
6406
6412
|
try {
|
|
6407
6413
|
return atob(t), !0;
|
|
6408
6414
|
} catch {
|
|
@@ -6412,7 +6418,7 @@ const lu = U({
|
|
|
6412
6418
|
/**
|
|
6413
6419
|
* A base64-encoded string representing the binary data of the item.
|
|
6414
6420
|
*/
|
|
6415
|
-
blob:
|
|
6421
|
+
blob: xi
|
|
6416
6422
|
}), an = U({
|
|
6417
6423
|
/**
|
|
6418
6424
|
* Intended audience(s) for the resource.
|
|
@@ -6478,32 +6484,32 @@ const lu = U({
|
|
|
6478
6484
|
* for notes on _meta usage.
|
|
6479
6485
|
*/
|
|
6480
6486
|
_meta: X(lt({}))
|
|
6481
|
-
}),
|
|
6487
|
+
}), Xs = zn.extend({
|
|
6482
6488
|
method: ee("resources/list")
|
|
6483
6489
|
}), vm = Mn.extend({
|
|
6484
6490
|
resources: de(yu)
|
|
6485
|
-
}),
|
|
6491
|
+
}), ei = zn.extend({
|
|
6486
6492
|
method: ee("resources/templates/list")
|
|
6487
6493
|
}), _m = Mn.extend({
|
|
6488
6494
|
resourceTemplates: de(ym)
|
|
6489
|
-
}),
|
|
6495
|
+
}), Ai = We.extend({
|
|
6490
6496
|
/**
|
|
6491
6497
|
* The URI of the resource to read. The URI can use any protocol; it is up to the server how to interpret it.
|
|
6492
6498
|
*
|
|
6493
6499
|
* @format uri
|
|
6494
6500
|
*/
|
|
6495
6501
|
uri: x()
|
|
6496
|
-
}), bm =
|
|
6502
|
+
}), bm = Ai, ti = ze.extend({
|
|
6497
6503
|
method: ee("resources/read"),
|
|
6498
6504
|
params: bm
|
|
6499
6505
|
}), wm = De.extend({
|
|
6500
6506
|
contents: de(Te([mu, gu]))
|
|
6501
6507
|
}), km = et.extend({
|
|
6502
6508
|
method: ee("notifications/resources/list_changed")
|
|
6503
|
-
}), Sm =
|
|
6509
|
+
}), Sm = Ai, $m = ze.extend({
|
|
6504
6510
|
method: ee("resources/subscribe"),
|
|
6505
6511
|
params: Sm
|
|
6506
|
-
}), Tm =
|
|
6512
|
+
}), Tm = Ai, Em = ze.extend({
|
|
6507
6513
|
method: ee("resources/unsubscribe"),
|
|
6508
6514
|
params: Tm
|
|
6509
6515
|
}), Pm = Kt.extend({
|
|
@@ -6543,7 +6549,7 @@ const lu = U({
|
|
|
6543
6549
|
* for notes on _meta usage.
|
|
6544
6550
|
*/
|
|
6545
6551
|
_meta: X(lt({}))
|
|
6546
|
-
}),
|
|
6552
|
+
}), ni = zn.extend({
|
|
6547
6553
|
method: ee("prompts/list")
|
|
6548
6554
|
}), Om = Mn.extend({
|
|
6549
6555
|
prompts: de(Cm)
|
|
@@ -6556,10 +6562,10 @@ const lu = U({
|
|
|
6556
6562
|
* Arguments to use for templating the prompt.
|
|
6557
6563
|
*/
|
|
6558
6564
|
arguments: Oe(x(), x()).optional()
|
|
6559
|
-
}),
|
|
6565
|
+
}), ri = ze.extend({
|
|
6560
6566
|
method: ee("prompts/get"),
|
|
6561
6567
|
params: Nm
|
|
6562
|
-
}),
|
|
6568
|
+
}), ji = U({
|
|
6563
6569
|
type: ee("text"),
|
|
6564
6570
|
/**
|
|
6565
6571
|
* The text content of the message.
|
|
@@ -6574,12 +6580,12 @@ const lu = U({
|
|
|
6574
6580
|
* for notes on _meta usage.
|
|
6575
6581
|
*/
|
|
6576
6582
|
_meta: Oe(x(), Ce()).optional()
|
|
6577
|
-
}),
|
|
6583
|
+
}), zi = U({
|
|
6578
6584
|
type: ee("image"),
|
|
6579
6585
|
/**
|
|
6580
6586
|
* The base64-encoded image data.
|
|
6581
6587
|
*/
|
|
6582
|
-
data:
|
|
6588
|
+
data: xi,
|
|
6583
6589
|
/**
|
|
6584
6590
|
* The MIME type of the image. Different providers may support different image types.
|
|
6585
6591
|
*/
|
|
@@ -6593,12 +6599,12 @@ const lu = U({
|
|
|
6593
6599
|
* for notes on _meta usage.
|
|
6594
6600
|
*/
|
|
6595
6601
|
_meta: Oe(x(), Ce()).optional()
|
|
6596
|
-
}),
|
|
6602
|
+
}), Mi = U({
|
|
6597
6603
|
type: ee("audio"),
|
|
6598
6604
|
/**
|
|
6599
6605
|
* The base64-encoded audio data.
|
|
6600
6606
|
*/
|
|
6601
|
-
data:
|
|
6607
|
+
data: xi,
|
|
6602
6608
|
/**
|
|
6603
6609
|
* The MIME type of the audio. Different providers may support different audio types.
|
|
6604
6610
|
*/
|
|
@@ -6648,15 +6654,15 @@ const lu = U({
|
|
|
6648
6654
|
_meta: Oe(x(), Ce()).optional()
|
|
6649
6655
|
}), jm = yu.extend({
|
|
6650
6656
|
type: ee("resource_link")
|
|
6651
|
-
}),
|
|
6652
|
-
Ai,
|
|
6657
|
+
}), Zi = Te([
|
|
6653
6658
|
ji,
|
|
6654
6659
|
zi,
|
|
6660
|
+
Mi,
|
|
6655
6661
|
jm,
|
|
6656
6662
|
Am
|
|
6657
6663
|
]), zm = U({
|
|
6658
6664
|
role: Ze(["user", "assistant"]),
|
|
6659
|
-
content:
|
|
6665
|
+
content: Zi
|
|
6660
6666
|
}), Mm = De.extend({
|
|
6661
6667
|
/**
|
|
6662
6668
|
* An optional description for the prompt.
|
|
@@ -6752,18 +6758,18 @@ const lu = U({
|
|
|
6752
6758
|
* for notes on _meta usage.
|
|
6753
6759
|
*/
|
|
6754
6760
|
_meta: Oe(x(), Ce()).optional()
|
|
6755
|
-
}),
|
|
6761
|
+
}), si = zn.extend({
|
|
6756
6762
|
method: ee("tools/list")
|
|
6757
6763
|
}), Lm = Mn.extend({
|
|
6758
6764
|
tools: de(vu)
|
|
6759
|
-
}),
|
|
6765
|
+
}), Di = De.extend({
|
|
6760
6766
|
/**
|
|
6761
6767
|
* A list of content objects that represent the result of the tool call.
|
|
6762
6768
|
*
|
|
6763
6769
|
* If the Tool does not define an outputSchema, this field MUST be present in the result.
|
|
6764
6770
|
* For backwards compatibility, this field is always present, but it may be empty.
|
|
6765
6771
|
*/
|
|
6766
|
-
content: de(
|
|
6772
|
+
content: de(Zi).default([]),
|
|
6767
6773
|
/**
|
|
6768
6774
|
* An object containing structured tool output.
|
|
6769
6775
|
*
|
|
@@ -6786,7 +6792,7 @@ const lu = U({
|
|
|
6786
6792
|
*/
|
|
6787
6793
|
isError: X(Me())
|
|
6788
6794
|
});
|
|
6789
|
-
|
|
6795
|
+
Di.or(De.extend({
|
|
6790
6796
|
toolResult: Ce()
|
|
6791
6797
|
}));
|
|
6792
6798
|
const Vm = We.extend({
|
|
@@ -6832,7 +6838,7 @@ const Vm = We.extend({
|
|
|
6832
6838
|
* A hint for a model name.
|
|
6833
6839
|
*/
|
|
6834
6840
|
name: x().optional()
|
|
6835
|
-
}),
|
|
6841
|
+
}), Bm = U({
|
|
6836
6842
|
/**
|
|
6837
6843
|
* Optional hints to use for model selection.
|
|
6838
6844
|
*/
|
|
@@ -6849,7 +6855,7 @@ const Vm = We.extend({
|
|
|
6849
6855
|
* How much to prioritize intelligence and capabilities when selecting a model.
|
|
6850
6856
|
*/
|
|
6851
6857
|
intelligencePriority: X(ke().min(0).max(1))
|
|
6852
|
-
}),
|
|
6858
|
+
}), Gm = U({
|
|
6853
6859
|
/**
|
|
6854
6860
|
* Controls when tools are used:
|
|
6855
6861
|
* - "auto": Model decides whether to use tools (default)
|
|
@@ -6860,7 +6866,7 @@ const Vm = We.extend({
|
|
|
6860
6866
|
}), Jm = U({
|
|
6861
6867
|
type: ee("tool_result"),
|
|
6862
6868
|
toolUseId: x().describe("The unique identifier for the corresponding tool call."),
|
|
6863
|
-
content: de(
|
|
6869
|
+
content: de(Zi).default([]),
|
|
6864
6870
|
structuredContent: U({}).passthrough().optional(),
|
|
6865
6871
|
isError: X(Me()),
|
|
6866
6872
|
/**
|
|
@@ -6868,10 +6874,10 @@ const Vm = We.extend({
|
|
|
6868
6874
|
* for notes on _meta usage.
|
|
6869
6875
|
*/
|
|
6870
6876
|
_meta: X(U({}).passthrough())
|
|
6871
|
-
}).passthrough(), Ym = Qc("type", [
|
|
6872
|
-
Ai,
|
|
6877
|
+
}).passthrough(), Ym = Qc("type", [ji, zi, Mi]), Hr = Qc("type", [
|
|
6873
6878
|
ji,
|
|
6874
6879
|
zi,
|
|
6880
|
+
Mi,
|
|
6875
6881
|
xm,
|
|
6876
6882
|
Jm
|
|
6877
6883
|
]), Qm = U({
|
|
@@ -6887,7 +6893,7 @@ const Vm = We.extend({
|
|
|
6887
6893
|
/**
|
|
6888
6894
|
* The server's preferences for which model to select. The client MAY modify or omit this request.
|
|
6889
6895
|
*/
|
|
6890
|
-
modelPreferences:
|
|
6896
|
+
modelPreferences: Bm.optional(),
|
|
6891
6897
|
/**
|
|
6892
6898
|
* An optional system prompt the server wants to use for sampling. The client MAY modify or omit this prompt.
|
|
6893
6899
|
*/
|
|
@@ -6922,7 +6928,7 @@ const Vm = We.extend({
|
|
|
6922
6928
|
* The client MUST return an error if this field is provided but ClientCapabilities.sampling.tools is not declared.
|
|
6923
6929
|
* Default is `{ mode: "auto" }`.
|
|
6924
6930
|
*/
|
|
6925
|
-
toolChoice: X(
|
|
6931
|
+
toolChoice: X(Gm)
|
|
6926
6932
|
}), eg = ze.extend({
|
|
6927
6933
|
method: ee("sampling/createMessage"),
|
|
6928
6934
|
params: Xm
|
|
@@ -7084,7 +7090,7 @@ const Vm = We.extend({
|
|
|
7084
7090
|
}), vg = et.extend({
|
|
7085
7091
|
method: ee("notifications/elicitation/complete"),
|
|
7086
7092
|
params: yg
|
|
7087
|
-
}),
|
|
7093
|
+
}), ii = De.extend({
|
|
7088
7094
|
/**
|
|
7089
7095
|
* The user action in response to the elicitation.
|
|
7090
7096
|
* - "accept": User submitted the form/confirmed the action
|
|
@@ -7132,7 +7138,7 @@ const Vm = We.extend({
|
|
|
7132
7138
|
*/
|
|
7133
7139
|
arguments: Oe(x(), x()).optional()
|
|
7134
7140
|
}).optional()
|
|
7135
|
-
}),
|
|
7141
|
+
}), ai = ze.extend({
|
|
7136
7142
|
method: ee("completion/complete"),
|
|
7137
7143
|
params: wg
|
|
7138
7144
|
});
|
|
@@ -7181,52 +7187,52 @@ const $g = De.extend({
|
|
|
7181
7187
|
method: ee("notifications/roots/list_changed")
|
|
7182
7188
|
});
|
|
7183
7189
|
Te([
|
|
7184
|
-
|
|
7190
|
+
Ei,
|
|
7185
7191
|
fu,
|
|
7186
|
-
|
|
7192
|
+
ai,
|
|
7187
7193
|
_u,
|
|
7194
|
+
ri,
|
|
7188
7195
|
ni,
|
|
7189
|
-
ti,
|
|
7190
|
-
Qs,
|
|
7191
7196
|
Xs,
|
|
7192
7197
|
ei,
|
|
7198
|
+
ti,
|
|
7193
7199
|
$m,
|
|
7194
7200
|
Em,
|
|
7195
7201
|
Fr,
|
|
7196
|
-
|
|
7197
|
-
|
|
7198
|
-
|
|
7199
|
-
|
|
7202
|
+
si,
|
|
7203
|
+
Ri,
|
|
7204
|
+
Ci,
|
|
7205
|
+
Oi
|
|
7200
7206
|
]);
|
|
7201
7207
|
Te([
|
|
7202
|
-
|
|
7203
|
-
|
|
7208
|
+
Ti,
|
|
7209
|
+
Pi,
|
|
7204
7210
|
pu,
|
|
7205
7211
|
Pg,
|
|
7206
7212
|
Vr
|
|
7207
7213
|
]);
|
|
7208
7214
|
Te([
|
|
7209
|
-
|
|
7215
|
+
$i,
|
|
7210
7216
|
bu,
|
|
7211
7217
|
wu,
|
|
7212
|
-
|
|
7218
|
+
ii,
|
|
7213
7219
|
ku,
|
|
7214
|
-
|
|
7215
|
-
|
|
7220
|
+
Ii,
|
|
7221
|
+
Ni,
|
|
7216
7222
|
is
|
|
7217
7223
|
]);
|
|
7218
7224
|
Te([
|
|
7219
|
-
|
|
7225
|
+
Ei,
|
|
7220
7226
|
eg,
|
|
7221
7227
|
gg,
|
|
7222
7228
|
Eg,
|
|
7223
|
-
|
|
7224
|
-
|
|
7225
|
-
|
|
7229
|
+
Ri,
|
|
7230
|
+
Ci,
|
|
7231
|
+
Oi
|
|
7226
7232
|
]);
|
|
7227
7233
|
Te([
|
|
7228
|
-
|
|
7229
|
-
|
|
7234
|
+
Ti,
|
|
7235
|
+
Pi,
|
|
7230
7236
|
Km,
|
|
7231
7237
|
Rm,
|
|
7232
7238
|
km,
|
|
@@ -7236,7 +7242,7 @@ Te([
|
|
|
7236
7242
|
vg
|
|
7237
7243
|
]);
|
|
7238
7244
|
Te([
|
|
7239
|
-
|
|
7245
|
+
$i,
|
|
7240
7246
|
lm,
|
|
7241
7247
|
$g,
|
|
7242
7248
|
Mm,
|
|
@@ -7244,10 +7250,10 @@ Te([
|
|
|
7244
7250
|
vm,
|
|
7245
7251
|
_m,
|
|
7246
7252
|
wm,
|
|
7247
|
-
|
|
7253
|
+
Di,
|
|
7248
7254
|
Lm,
|
|
7249
|
-
|
|
7250
|
-
|
|
7255
|
+
Ii,
|
|
7256
|
+
Ni,
|
|
7251
7257
|
is
|
|
7252
7258
|
]);
|
|
7253
7259
|
class ne extends Error {
|
|
@@ -7280,7 +7286,7 @@ class Rg extends ne {
|
|
|
7280
7286
|
function Zt(t) {
|
|
7281
7287
|
return t === "completed" || t === "failed" || t === "cancelled";
|
|
7282
7288
|
}
|
|
7283
|
-
const Ig = Symbol("Let zodToJsonSchema decide on which parser to use"),
|
|
7289
|
+
const Ig = Symbol("Let zodToJsonSchema decide on which parser to use"), Ma = {
|
|
7284
7290
|
name: void 0,
|
|
7285
7291
|
$refStrategy: "root",
|
|
7286
7292
|
basePath: ["#"],
|
|
@@ -7304,10 +7310,10 @@ const Ig = Symbol("Let zodToJsonSchema decide on which parser to use"), za = {
|
|
|
7304
7310
|
nameStrategy: "ref",
|
|
7305
7311
|
openAiAnyTypeName: "OpenAiAnyType"
|
|
7306
7312
|
}, Cg = (t) => typeof t == "string" ? {
|
|
7307
|
-
...
|
|
7313
|
+
...Ma,
|
|
7308
7314
|
name: t
|
|
7309
7315
|
} : {
|
|
7310
|
-
...
|
|
7316
|
+
...Ma,
|
|
7311
7317
|
...t
|
|
7312
7318
|
}, Og = (t) => {
|
|
7313
7319
|
const e = Cg(t), n = e.name !== void 0 ? [...e.basePath, e.definitionPath, e.name] : e.basePath;
|
|
@@ -7685,11 +7691,11 @@ function qe(t, e, n, r) {
|
|
|
7685
7691
|
errorMessage: { pattern: t.errorMessage.pattern }
|
|
7686
7692
|
}
|
|
7687
7693
|
}), delete t.pattern, t.errorMessage && (delete t.errorMessage.pattern, Object.keys(t.errorMessage).length === 0 && delete t.errorMessage)), t.allOf.push({
|
|
7688
|
-
pattern:
|
|
7694
|
+
pattern: Za(e, r),
|
|
7689
7695
|
...n && r.errorMessages && { errorMessage: { pattern: n } }
|
|
7690
|
-
})) : be(t, "pattern",
|
|
7696
|
+
})) : be(t, "pattern", Za(e, r), n, r);
|
|
7691
7697
|
}
|
|
7692
|
-
function
|
|
7698
|
+
function Za(t, e) {
|
|
7693
7699
|
if (!e.applyRegexFlags || !t.flags)
|
|
7694
7700
|
return t.source;
|
|
7695
7701
|
const n = {
|
|
@@ -7824,7 +7830,7 @@ function Wg(t) {
|
|
|
7824
7830
|
})
|
|
7825
7831
|
};
|
|
7826
7832
|
}
|
|
7827
|
-
function
|
|
7833
|
+
function Bg(t) {
|
|
7828
7834
|
return t.target === "openApi3" ? {
|
|
7829
7835
|
enum: ["null"],
|
|
7830
7836
|
nullable: !0
|
|
@@ -7839,9 +7845,9 @@ const Kr = {
|
|
|
7839
7845
|
ZodBoolean: "boolean",
|
|
7840
7846
|
ZodNull: "null"
|
|
7841
7847
|
};
|
|
7842
|
-
function
|
|
7848
|
+
function Gg(t, e) {
|
|
7843
7849
|
if (e.target === "openApi3")
|
|
7844
|
-
return
|
|
7850
|
+
return Da(t, e);
|
|
7845
7851
|
const n = t.options instanceof Map ? Array.from(t.options.values()) : t.options;
|
|
7846
7852
|
if (n.every((r) => r._def.typeName in Kr && (!r._def.checks || !r._def.checks.length))) {
|
|
7847
7853
|
const r = n.reduce((s, i) => {
|
|
@@ -7886,9 +7892,9 @@ function Bg(t, e) {
|
|
|
7886
7892
|
...s._def.values.filter((i) => !r.includes(i))
|
|
7887
7893
|
], [])
|
|
7888
7894
|
};
|
|
7889
|
-
return
|
|
7895
|
+
return Da(t, e);
|
|
7890
7896
|
}
|
|
7891
|
-
const
|
|
7897
|
+
const Da = (t, e) => {
|
|
7892
7898
|
const n = (t.options instanceof Map ? Array.from(t.options.values()) : t.options).map((r, s) => ye(r._def, {
|
|
7893
7899
|
...e,
|
|
7894
7900
|
currentPath: [...e.currentPath, "anyOf", `${s}`]
|
|
@@ -8078,12 +8084,12 @@ const cy = (t, e) => ye(t.innerType._def, e), uy = (t, e, n) => {
|
|
|
8078
8084
|
case F.ZodUndefined:
|
|
8079
8085
|
return ay(n);
|
|
8080
8086
|
case F.ZodNull:
|
|
8081
|
-
return
|
|
8087
|
+
return Bg(n);
|
|
8082
8088
|
case F.ZodArray:
|
|
8083
8089
|
return Ng(t, n);
|
|
8084
8090
|
case F.ZodUnion:
|
|
8085
8091
|
case F.ZodDiscriminatedUnion:
|
|
8086
|
-
return
|
|
8092
|
+
return Gg(t, n);
|
|
8087
8093
|
case F.ZodIntersection:
|
|
8088
8094
|
return Lg(t, n);
|
|
8089
8095
|
case F.ZodTuple:
|
|
@@ -8210,7 +8216,7 @@ const ly = (t, e) => {
|
|
|
8210
8216
|
function py(t) {
|
|
8211
8217
|
return !t || t === "jsonSchema7" || t === "draft-7" ? "draft-7" : t === "jsonSchema2019-09" || t === "draft-2020-12" ? "draft-2020-12" : "draft-7";
|
|
8212
8218
|
}
|
|
8213
|
-
function
|
|
8219
|
+
function qa(t, e) {
|
|
8214
8220
|
var n, r, s;
|
|
8215
8221
|
return ut(t) ? Lp(t, {
|
|
8216
8222
|
target: py(e?.target),
|
|
@@ -8220,7 +8226,7 @@ function Da(t, e) {
|
|
|
8220
8226
|
pipeStrategy: (s = e?.pipeStrategy) !== null && s !== void 0 ? s : "input"
|
|
8221
8227
|
});
|
|
8222
8228
|
}
|
|
8223
|
-
function
|
|
8229
|
+
function La(t) {
|
|
8224
8230
|
const e = An(t), n = e?.method;
|
|
8225
8231
|
if (!n)
|
|
8226
8232
|
throw new Error("Schema is missing a method literal");
|
|
@@ -8229,7 +8235,7 @@ function qa(t) {
|
|
|
8229
8235
|
throw new Error("Schema method literal must be a string");
|
|
8230
8236
|
return r;
|
|
8231
8237
|
}
|
|
8232
|
-
function
|
|
8238
|
+
function Va(t, e) {
|
|
8233
8239
|
const n = bn(t, e);
|
|
8234
8240
|
if (!n.success)
|
|
8235
8241
|
throw n.error;
|
|
@@ -8238,22 +8244,22 @@ function La(t, e) {
|
|
|
8238
8244
|
const hy = 6e4;
|
|
8239
8245
|
class my {
|
|
8240
8246
|
constructor(e) {
|
|
8241
|
-
this._options = e, this._requestMessageId = 0, this._requestHandlers = /* @__PURE__ */ new Map(), this._requestHandlerAbortControllers = /* @__PURE__ */ new Map(), this._notificationHandlers = /* @__PURE__ */ new Map(), this._responseHandlers = /* @__PURE__ */ new Map(), this._progressHandlers = /* @__PURE__ */ new Map(), this._timeoutInfo = /* @__PURE__ */ new Map(), this._pendingDebouncedNotifications = /* @__PURE__ */ new Set(), this._taskProgressTokens = /* @__PURE__ */ new Map(), this._requestResolvers = /* @__PURE__ */ new Map(), this.setNotificationHandler(
|
|
8247
|
+
this._options = e, this._requestMessageId = 0, this._requestHandlers = /* @__PURE__ */ new Map(), this._requestHandlerAbortControllers = /* @__PURE__ */ new Map(), this._notificationHandlers = /* @__PURE__ */ new Map(), this._responseHandlers = /* @__PURE__ */ new Map(), this._progressHandlers = /* @__PURE__ */ new Map(), this._timeoutInfo = /* @__PURE__ */ new Map(), this._pendingDebouncedNotifications = /* @__PURE__ */ new Set(), this._taskProgressTokens = /* @__PURE__ */ new Map(), this._requestResolvers = /* @__PURE__ */ new Map(), this.setNotificationHandler(Ti, (n) => {
|
|
8242
8248
|
this._oncancel(n);
|
|
8243
|
-
}), this.setNotificationHandler(
|
|
8249
|
+
}), this.setNotificationHandler(Pi, (n) => {
|
|
8244
8250
|
this._onprogress(n);
|
|
8245
8251
|
}), this.setRequestHandler(
|
|
8246
|
-
|
|
8252
|
+
Ei,
|
|
8247
8253
|
// Automatic pong by default.
|
|
8248
8254
|
(n) => ({})
|
|
8249
|
-
), this._taskStore = e?.taskStore, this._taskMessageQueue = e?.taskMessageQueue, this._taskStore && (this.setRequestHandler(
|
|
8255
|
+
), this._taskStore = e?.taskStore, this._taskMessageQueue = e?.taskMessageQueue, this._taskStore && (this.setRequestHandler(Ri, async (n, r) => {
|
|
8250
8256
|
const s = await this._taskStore.getTask(n.params.taskId, r.sessionId);
|
|
8251
8257
|
if (!s)
|
|
8252
8258
|
throw new ne(re.InvalidParams, "Failed to retrieve task: Task not found");
|
|
8253
8259
|
return {
|
|
8254
8260
|
...s
|
|
8255
8261
|
};
|
|
8256
|
-
}), this.setRequestHandler(
|
|
8262
|
+
}), this.setRequestHandler(Ci, async (n, r) => {
|
|
8257
8263
|
const s = async () => {
|
|
8258
8264
|
var i;
|
|
8259
8265
|
const a = n.params.taskId;
|
|
@@ -8298,7 +8304,7 @@ class my {
|
|
|
8298
8304
|
return await s();
|
|
8299
8305
|
};
|
|
8300
8306
|
return await s();
|
|
8301
|
-
}), this.setRequestHandler(
|
|
8307
|
+
}), this.setRequestHandler(Oi, async (n, r) => {
|
|
8302
8308
|
var s;
|
|
8303
8309
|
try {
|
|
8304
8310
|
const { tasks: i, nextCursor: a } = await this._taskStore.listTasks((s = n.params) === null || s === void 0 ? void 0 : s.cursor, r.sessionId);
|
|
@@ -8378,7 +8384,7 @@ class my {
|
|
|
8378
8384
|
};
|
|
8379
8385
|
const o = (s = this._transport) === null || s === void 0 ? void 0 : s.onmessage;
|
|
8380
8386
|
this._transport.onmessage = (c, l) => {
|
|
8381
|
-
o?.(c, l), Vn(c) || Xh(c) ? this._onresponse(c) :
|
|
8387
|
+
o?.(c, l), Vn(c) || Xh(c) ? this._onresponse(c) : za(c) ? this._onrequest(c, l) : Qh(c) ? this._onnotification(c) : this._onerror(new Error(`Unknown message type: ${JSON.stringify(c)}`));
|
|
8382
8388
|
}, await this._transport.start();
|
|
8383
8389
|
}
|
|
8384
8390
|
_onclose() {
|
|
@@ -8714,7 +8720,7 @@ class my {
|
|
|
8714
8720
|
* @experimental Use `client.experimental.tasks.getTask()` to access this method.
|
|
8715
8721
|
*/
|
|
8716
8722
|
async getTask(e, n) {
|
|
8717
|
-
return this.request({ method: "tasks/get", params: e },
|
|
8723
|
+
return this.request({ method: "tasks/get", params: e }, Ii, n);
|
|
8718
8724
|
}
|
|
8719
8725
|
/**
|
|
8720
8726
|
* Retrieves the result of a completed task.
|
|
@@ -8730,7 +8736,7 @@ class my {
|
|
|
8730
8736
|
* @experimental Use `client.experimental.tasks.listTasks()` to access this method.
|
|
8731
8737
|
*/
|
|
8732
8738
|
async listTasks(e, n) {
|
|
8733
|
-
return this.request({ method: "tasks/list", params: e },
|
|
8739
|
+
return this.request({ method: "tasks/list", params: e }, Ni, n);
|
|
8734
8740
|
}
|
|
8735
8741
|
/**
|
|
8736
8742
|
* Cancels a specific task.
|
|
@@ -8813,9 +8819,9 @@ class my {
|
|
|
8813
8819
|
* Note that this will replace any previous request handler for the same method.
|
|
8814
8820
|
*/
|
|
8815
8821
|
setRequestHandler(e, n) {
|
|
8816
|
-
const r =
|
|
8822
|
+
const r = La(e);
|
|
8817
8823
|
this.assertRequestHandlerCapability(r), this._requestHandlers.set(r, (s, i) => {
|
|
8818
|
-
const a =
|
|
8824
|
+
const a = Va(e, s);
|
|
8819
8825
|
return Promise.resolve(n(a, i));
|
|
8820
8826
|
});
|
|
8821
8827
|
}
|
|
@@ -8838,9 +8844,9 @@ class my {
|
|
|
8838
8844
|
* Note that this will replace any previous notification handler for the same method.
|
|
8839
8845
|
*/
|
|
8840
8846
|
setNotificationHandler(e, n) {
|
|
8841
|
-
const r =
|
|
8847
|
+
const r = La(e);
|
|
8842
8848
|
this._notificationHandlers.set(r, (s) => {
|
|
8843
|
-
const i =
|
|
8849
|
+
const i = Va(e, s);
|
|
8844
8850
|
return Promise.resolve(n(i));
|
|
8845
8851
|
});
|
|
8846
8852
|
}
|
|
@@ -8885,7 +8891,7 @@ class my {
|
|
|
8885
8891
|
if (this._taskMessageQueue) {
|
|
8886
8892
|
const r = await this._taskMessageQueue.dequeueAll(e, n);
|
|
8887
8893
|
for (const s of r)
|
|
8888
|
-
if (s.type === "request" &&
|
|
8894
|
+
if (s.type === "request" && za(s.message)) {
|
|
8889
8895
|
const i = s.message.id, a = this._requestResolvers.get(i);
|
|
8890
8896
|
a ? (a(new ne(re.InternalError, "Task cancelled or completed")), this._requestResolvers.delete(i)) : this._onerror(new Error(`Resolver missing for request ${i} during task ${e} cleanup`));
|
|
8891
8897
|
}
|
|
@@ -8968,7 +8974,7 @@ class my {
|
|
|
8968
8974
|
};
|
|
8969
8975
|
}
|
|
8970
8976
|
}
|
|
8971
|
-
function
|
|
8977
|
+
function Fa(t) {
|
|
8972
8978
|
return t !== null && typeof t == "object" && !Array.isArray(t);
|
|
8973
8979
|
}
|
|
8974
8980
|
function gy(t, e) {
|
|
@@ -8978,13 +8984,13 @@ function gy(t, e) {
|
|
|
8978
8984
|
if (i === void 0)
|
|
8979
8985
|
continue;
|
|
8980
8986
|
const a = n[s];
|
|
8981
|
-
|
|
8987
|
+
Fa(a) && Fa(i) ? n[s] = { ...a, ...i } : n[s] = i;
|
|
8982
8988
|
}
|
|
8983
8989
|
return n;
|
|
8984
8990
|
}
|
|
8985
|
-
var Fn = { exports: {} }, $s = {}, gt = {}, Dt = {}, Ts = {}, Es = {}, Ps = {},
|
|
8991
|
+
var Fn = { exports: {} }, $s = {}, gt = {}, Dt = {}, Ts = {}, Es = {}, Ps = {}, Ua;
|
|
8986
8992
|
function Wr() {
|
|
8987
|
-
return
|
|
8993
|
+
return Ua || (Ua = 1, function(t) {
|
|
8988
8994
|
Object.defineProperty(t, "__esModule", { value: !0 }), t.regexpCode = t.getEsmExportName = t.getProperty = t.safeStringify = t.stringify = t.strConcat = t.addCodeArg = t.str = t._ = t.nil = t._Code = t.Name = t.IDENTIFIER = t._CodeOrName = void 0;
|
|
8989
8995
|
class e {
|
|
8990
8996
|
}
|
|
@@ -9105,9 +9111,9 @@ function Wr() {
|
|
|
9105
9111
|
t.regexpCode = f;
|
|
9106
9112
|
}(Ps)), Ps;
|
|
9107
9113
|
}
|
|
9108
|
-
var Rs = {},
|
|
9109
|
-
function
|
|
9110
|
-
return
|
|
9114
|
+
var Rs = {}, Ha;
|
|
9115
|
+
function Ka() {
|
|
9116
|
+
return Ha || (Ha = 1, function(t) {
|
|
9111
9117
|
Object.defineProperty(t, "__esModule", { value: !0 }), t.ValueScope = t.ValueScopeName = t.Scope = t.varKinds = t.UsedValueState = void 0;
|
|
9112
9118
|
const e = Wr();
|
|
9113
9119
|
class n extends Error {
|
|
@@ -9228,11 +9234,11 @@ function Ha() {
|
|
|
9228
9234
|
t.ValueScope = o;
|
|
9229
9235
|
}(Rs)), Rs;
|
|
9230
9236
|
}
|
|
9231
|
-
var
|
|
9237
|
+
var Wa;
|
|
9232
9238
|
function oe() {
|
|
9233
|
-
return
|
|
9239
|
+
return Wa || (Wa = 1, function(t) {
|
|
9234
9240
|
Object.defineProperty(t, "__esModule", { value: !0 }), t.or = t.and = t.not = t.CodeGen = t.operators = t.varKinds = t.ValueScopeName = t.ValueScope = t.Scope = t.Name = t.regexpCode = t.stringify = t.getProperty = t.nil = t.strConcat = t.str = t._ = void 0;
|
|
9235
|
-
const e = Wr(), n =
|
|
9241
|
+
const e = Wr(), n = Ka();
|
|
9236
9242
|
var r = Wr();
|
|
9237
9243
|
Object.defineProperty(t, "_", { enumerable: !0, get: function() {
|
|
9238
9244
|
return r._;
|
|
@@ -9251,7 +9257,7 @@ function oe() {
|
|
|
9251
9257
|
} }), Object.defineProperty(t, "Name", { enumerable: !0, get: function() {
|
|
9252
9258
|
return r.Name;
|
|
9253
9259
|
} });
|
|
9254
|
-
var s =
|
|
9260
|
+
var s = Ka();
|
|
9255
9261
|
Object.defineProperty(t, "Scope", { enumerable: !0, get: function() {
|
|
9256
9262
|
return s.Scope;
|
|
9257
9263
|
} }), Object.defineProperty(t, "ValueScope", { enumerable: !0, get: function() {
|
|
@@ -9285,8 +9291,8 @@ function oe() {
|
|
|
9285
9291
|
super(), this.varKind = k, this.name = T, this.rhs = j;
|
|
9286
9292
|
}
|
|
9287
9293
|
render({ es5: k, _n: T }) {
|
|
9288
|
-
const j = k ? n.varKinds.var : this.varKind,
|
|
9289
|
-
return `${j} ${this.name}${
|
|
9294
|
+
const j = k ? n.varKinds.var : this.varKind, G = this.rhs === void 0 ? "" : ` = ${this.rhs}`;
|
|
9295
|
+
return `${j} ${this.name}${G};` + T;
|
|
9290
9296
|
}
|
|
9291
9297
|
optimizeNames(k, T) {
|
|
9292
9298
|
if (k[this.name.str])
|
|
@@ -9313,8 +9319,8 @@ function oe() {
|
|
|
9313
9319
|
}
|
|
9314
9320
|
}
|
|
9315
9321
|
class c extends o {
|
|
9316
|
-
constructor(k, T, j,
|
|
9317
|
-
super(k, j,
|
|
9322
|
+
constructor(k, T, j, G) {
|
|
9323
|
+
super(k, j, G), this.op = T;
|
|
9318
9324
|
}
|
|
9319
9325
|
render({ _n: k }) {
|
|
9320
9326
|
return `${this.lhs} ${this.op}= ${this.rhs};` + k;
|
|
@@ -9382,10 +9388,10 @@ function oe() {
|
|
|
9382
9388
|
}
|
|
9383
9389
|
optimizeNames(k, T) {
|
|
9384
9390
|
const { nodes: j } = this;
|
|
9385
|
-
let
|
|
9386
|
-
for (;
|
|
9387
|
-
const te = j[
|
|
9388
|
-
te.optimizeNames(k, T) || (ie(k, te.names), j.splice(
|
|
9391
|
+
let G = j.length;
|
|
9392
|
+
for (; G--; ) {
|
|
9393
|
+
const te = j[G];
|
|
9394
|
+
te.optimizeNames(k, T) || (ie(k, te.names), j.splice(G, 1));
|
|
9389
9395
|
}
|
|
9390
9396
|
return j.length > 0 ? this : void 0;
|
|
9391
9397
|
}
|
|
@@ -9456,12 +9462,12 @@ function oe() {
|
|
|
9456
9462
|
}
|
|
9457
9463
|
}
|
|
9458
9464
|
class _ extends u {
|
|
9459
|
-
constructor(k, T, j,
|
|
9460
|
-
super(), this.varKind = k, this.name = T, this.from = j, this.to =
|
|
9465
|
+
constructor(k, T, j, G) {
|
|
9466
|
+
super(), this.varKind = k, this.name = T, this.from = j, this.to = G;
|
|
9461
9467
|
}
|
|
9462
9468
|
render(k) {
|
|
9463
|
-
const T = k.es5 ? n.varKinds.var : this.varKind, { name: j, from:
|
|
9464
|
-
return `for(${T} ${j}=${
|
|
9469
|
+
const T = k.es5 ? n.varKinds.var : this.varKind, { name: j, from: G, to: te } = this;
|
|
9470
|
+
return `for(${T} ${j}=${G}; ${j}<${te}; ${j}++)` + super.render(k);
|
|
9465
9471
|
}
|
|
9466
9472
|
get names() {
|
|
9467
9473
|
const k = q(super.names, this.from);
|
|
@@ -9469,8 +9475,8 @@ function oe() {
|
|
|
9469
9475
|
}
|
|
9470
9476
|
}
|
|
9471
9477
|
class w extends u {
|
|
9472
|
-
constructor(k, T, j,
|
|
9473
|
-
super(), this.loop = k, this.varKind = T, this.name = j, this.iterable =
|
|
9478
|
+
constructor(k, T, j, G) {
|
|
9479
|
+
super(), this.loop = k, this.varKind = T, this.name = j, this.iterable = G;
|
|
9474
9480
|
}
|
|
9475
9481
|
render(k) {
|
|
9476
9482
|
return `for(${this.varKind} ${this.name} ${this.loop} ${this.iterable})` + super.render(k);
|
|
@@ -9508,8 +9514,8 @@ function oe() {
|
|
|
9508
9514
|
return super.optimizeNodes(), (k = this.catch) === null || k === void 0 || k.optimizeNodes(), (T = this.finally) === null || T === void 0 || T.optimizeNodes(), this;
|
|
9509
9515
|
}
|
|
9510
9516
|
optimizeNames(k, T) {
|
|
9511
|
-
var j,
|
|
9512
|
-
return super.optimizeNames(k, T), (j = this.catch) === null || j === void 0 || j.optimizeNames(k, T), (
|
|
9517
|
+
var j, G;
|
|
9518
|
+
return super.optimizeNames(k, T), (j = this.catch) === null || j === void 0 || j.optimizeNames(k, T), (G = this.finally) === null || G === void 0 || G.optimizeNames(k, T), this;
|
|
9513
9519
|
}
|
|
9514
9520
|
get names() {
|
|
9515
9521
|
const k = super.names;
|
|
@@ -9563,9 +9569,9 @@ function oe() {
|
|
|
9563
9569
|
scopeCode() {
|
|
9564
9570
|
return this._extScope.scopeCode(this._values);
|
|
9565
9571
|
}
|
|
9566
|
-
_def(k, T, j,
|
|
9572
|
+
_def(k, T, j, G) {
|
|
9567
9573
|
const te = this._scope.toName(T);
|
|
9568
|
-
return j !== void 0 &&
|
|
9574
|
+
return j !== void 0 && G && (this._constants[te.str] = j), this._leafNode(new a(k, te, j)), te;
|
|
9569
9575
|
}
|
|
9570
9576
|
// `const` declaration (`var` in es5 mode)
|
|
9571
9577
|
const(k, T, j) {
|
|
@@ -9594,8 +9600,8 @@ function oe() {
|
|
|
9594
9600
|
// returns code for object literal for the passed argument list of key-value pairs
|
|
9595
9601
|
object(...k) {
|
|
9596
9602
|
const T = ["{"];
|
|
9597
|
-
for (const [j,
|
|
9598
|
-
T.length > 1 && T.push(","), T.push(j), (j !==
|
|
9603
|
+
for (const [j, G] of k)
|
|
9604
|
+
T.length > 1 && T.push(","), T.push(j), (j !== G || this.opts.es5) && (T.push(":"), (0, e.addCodeArg)(T, G));
|
|
9599
9605
|
return T.push("}"), new e._Code(T);
|
|
9600
9606
|
}
|
|
9601
9607
|
// `if` clause (or statement if `thenBody` and, optionally, `elseBody` are passed)
|
|
@@ -9628,12 +9634,12 @@ function oe() {
|
|
|
9628
9634
|
return this._for(new p(k), T);
|
|
9629
9635
|
}
|
|
9630
9636
|
// `for` statement for a range of values
|
|
9631
|
-
forRange(k, T, j,
|
|
9637
|
+
forRange(k, T, j, G, te = this.opts.es5 ? n.varKinds.var : n.varKinds.let) {
|
|
9632
9638
|
const ge = this._scope.toName(k);
|
|
9633
|
-
return this._for(new _(te, ge, T, j), () =>
|
|
9639
|
+
return this._for(new _(te, ge, T, j), () => G(ge));
|
|
9634
9640
|
}
|
|
9635
9641
|
// `for-of` statement (in es5 mode replace with a normal for loop)
|
|
9636
|
-
forOf(k, T, j,
|
|
9642
|
+
forOf(k, T, j, G = n.varKinds.const) {
|
|
9637
9643
|
const te = this._scope.toName(k);
|
|
9638
9644
|
if (this.opts.es5) {
|
|
9639
9645
|
const ge = T instanceof e.Name ? T : this.var("_arr", T);
|
|
@@ -9641,15 +9647,15 @@ function oe() {
|
|
|
9641
9647
|
this.var(te, (0, e._)`${ge}[${le}]`), j(te);
|
|
9642
9648
|
});
|
|
9643
9649
|
}
|
|
9644
|
-
return this._for(new w("of",
|
|
9650
|
+
return this._for(new w("of", G, te, T), () => j(te));
|
|
9645
9651
|
}
|
|
9646
9652
|
// `for-in` statement.
|
|
9647
9653
|
// With option `ownProperties` replaced with a `for-of` loop for object keys
|
|
9648
|
-
forIn(k, T, j,
|
|
9654
|
+
forIn(k, T, j, G = this.opts.es5 ? n.varKinds.var : n.varKinds.const) {
|
|
9649
9655
|
if (this.opts.ownProperties)
|
|
9650
9656
|
return this.forOf(k, (0, e._)`Object.keys(${T})`, j);
|
|
9651
9657
|
const te = this._scope.toName(k);
|
|
9652
|
-
return this._for(new w("in",
|
|
9658
|
+
return this._for(new w("in", G, te, T), () => j(te));
|
|
9653
9659
|
}
|
|
9654
9660
|
// end `for` loop
|
|
9655
9661
|
endFor() {
|
|
@@ -9674,12 +9680,12 @@ function oe() {
|
|
|
9674
9680
|
try(k, T, j) {
|
|
9675
9681
|
if (!T && !j)
|
|
9676
9682
|
throw new Error('CodeGen: "try" without "catch" and "finally"');
|
|
9677
|
-
const
|
|
9678
|
-
if (this._blockNode(
|
|
9683
|
+
const G = new E();
|
|
9684
|
+
if (this._blockNode(G), this.code(k), T) {
|
|
9679
9685
|
const te = this.name("e");
|
|
9680
|
-
this._currNode =
|
|
9686
|
+
this._currNode = G.catch = new R(te), T(te);
|
|
9681
9687
|
}
|
|
9682
|
-
return j && (this._currNode =
|
|
9688
|
+
return j && (this._currNode = G.finally = new z(), this.code(j)), this._endBlockNode(R, z);
|
|
9683
9689
|
}
|
|
9684
9690
|
// `throw` statement
|
|
9685
9691
|
throw(k) {
|
|
@@ -9700,8 +9706,8 @@ function oe() {
|
|
|
9700
9706
|
return this._nodes.length = T, this;
|
|
9701
9707
|
}
|
|
9702
9708
|
// `function` heading (or definition if funcBody is passed)
|
|
9703
|
-
func(k, T = e.nil, j,
|
|
9704
|
-
return this._blockNode(new g(k, T, j)),
|
|
9709
|
+
func(k, T = e.nil, j, G) {
|
|
9710
|
+
return this._blockNode(new g(k, T, j)), G && this.code(G).endFunc(), this;
|
|
9705
9711
|
}
|
|
9706
9712
|
// end function definition
|
|
9707
9713
|
endFunc() {
|
|
@@ -9753,14 +9759,14 @@ function oe() {
|
|
|
9753
9759
|
function H(N, k, T) {
|
|
9754
9760
|
if (N instanceof e.Name)
|
|
9755
9761
|
return j(N);
|
|
9756
|
-
if (!
|
|
9762
|
+
if (!G(N))
|
|
9757
9763
|
return N;
|
|
9758
9764
|
return new e._Code(N._items.reduce((te, ge) => (ge instanceof e.Name && (ge = j(ge)), ge instanceof e._Code ? te.push(...ge._items) : te.push(ge), te), []));
|
|
9759
9765
|
function j(te) {
|
|
9760
9766
|
const ge = T[te.str];
|
|
9761
9767
|
return ge === void 0 || k[te.str] !== 1 ? te : (delete k[te.str], ge);
|
|
9762
9768
|
}
|
|
9763
|
-
function
|
|
9769
|
+
function G(te) {
|
|
9764
9770
|
return te instanceof e._Code && te._items.some((ge) => ge instanceof e.Name && k[ge.str] === 1 && T[ge.str] !== void 0);
|
|
9765
9771
|
}
|
|
9766
9772
|
}
|
|
@@ -9790,10 +9796,10 @@ function oe() {
|
|
|
9790
9796
|
}
|
|
9791
9797
|
}(Es)), Es;
|
|
9792
9798
|
}
|
|
9793
|
-
var ae = {},
|
|
9799
|
+
var ae = {}, Ba;
|
|
9794
9800
|
function me() {
|
|
9795
|
-
if (
|
|
9796
|
-
|
|
9801
|
+
if (Ba) return ae;
|
|
9802
|
+
Ba = 1, Object.defineProperty(ae, "__esModule", { value: !0 }), ae.checkStrictMode = ae.getErrorPath = ae.Type = ae.useFunc = ae.setEvaluated = ae.evaluatedPropsToName = ae.mergeEvaluated = ae.eachItem = ae.unescapeJsonPointer = ae.escapeJsonPointer = ae.escapeFragment = ae.unescapeFragment = ae.schemaRefOrVal = ae.schemaHasRulesButRef = ae.schemaHasRules = ae.checkUnknownRules = ae.alwaysValidSchema = ae.toHash = void 0;
|
|
9797
9803
|
const t = oe(), e = Wr();
|
|
9798
9804
|
function n(w) {
|
|
9799
9805
|
const g = {};
|
|
@@ -9966,9 +9972,9 @@ function Mt() {
|
|
|
9966
9972
|
};
|
|
9967
9973
|
return Un.default = e, Un;
|
|
9968
9974
|
}
|
|
9969
|
-
var
|
|
9975
|
+
var Ja;
|
|
9970
9976
|
function as() {
|
|
9971
|
-
return
|
|
9977
|
+
return Ja || (Ja = 1, function(t) {
|
|
9972
9978
|
Object.defineProperty(t, "__esModule", { value: !0 }), t.extendErrors = t.resetErrorsCount = t.reportExtraError = t.reportError = t.keyword$DataError = t.keywordError = void 0;
|
|
9973
9979
|
const e = oe(), n = me(), r = Mt();
|
|
9974
9980
|
t.keywordError = {
|
|
@@ -10042,10 +10048,10 @@ function as() {
|
|
|
10042
10048
|
}
|
|
10043
10049
|
}(Ts)), Ts;
|
|
10044
10050
|
}
|
|
10045
|
-
var
|
|
10051
|
+
var Ya;
|
|
10046
10052
|
function yy() {
|
|
10047
|
-
if (
|
|
10048
|
-
|
|
10053
|
+
if (Ya) return Dt;
|
|
10054
|
+
Ya = 1, Object.defineProperty(Dt, "__esModule", { value: !0 }), Dt.boolOrEmptySchema = Dt.topBoolOrEmptySchema = void 0;
|
|
10049
10055
|
const t = as(), e = oe(), n = Mt(), r = {
|
|
10050
10056
|
message: "boolean schema is false"
|
|
10051
10057
|
};
|
|
@@ -10074,10 +10080,10 @@ function yy() {
|
|
|
10074
10080
|
}
|
|
10075
10081
|
return Dt;
|
|
10076
10082
|
}
|
|
10077
|
-
var je = {}, qt = {},
|
|
10083
|
+
var je = {}, qt = {}, Qa;
|
|
10078
10084
|
function Iu() {
|
|
10079
|
-
if (
|
|
10080
|
-
|
|
10085
|
+
if (Qa) return qt;
|
|
10086
|
+
Qa = 1, Object.defineProperty(qt, "__esModule", { value: !0 }), qt.getRules = qt.isJSONType = void 0;
|
|
10081
10087
|
const t = ["string", "number", "integer", "boolean", "null", "object", "array"], e = new Set(t);
|
|
10082
10088
|
function n(s) {
|
|
10083
10089
|
return typeof s == "string" && e.has(s);
|
|
@@ -10100,10 +10106,10 @@ function Iu() {
|
|
|
10100
10106
|
}
|
|
10101
10107
|
return qt.getRules = r, qt;
|
|
10102
10108
|
}
|
|
10103
|
-
var yt = {},
|
|
10109
|
+
var yt = {}, Xa;
|
|
10104
10110
|
function Cu() {
|
|
10105
|
-
if (
|
|
10106
|
-
|
|
10111
|
+
if (Xa) return yt;
|
|
10112
|
+
Xa = 1, Object.defineProperty(yt, "__esModule", { value: !0 }), yt.shouldUseRule = yt.shouldUseGroup = yt.schemaHasRulesForType = void 0;
|
|
10107
10113
|
function t({ schema: r, self: s }, i) {
|
|
10108
10114
|
const a = s.RULES.types[i];
|
|
10109
10115
|
return a && a !== !0 && e(r, a);
|
|
@@ -10119,10 +10125,10 @@ function Cu() {
|
|
|
10119
10125
|
}
|
|
10120
10126
|
return yt.shouldUseRule = n, yt;
|
|
10121
10127
|
}
|
|
10122
|
-
var
|
|
10123
|
-
function
|
|
10124
|
-
if (
|
|
10125
|
-
|
|
10128
|
+
var eo;
|
|
10129
|
+
function Br() {
|
|
10130
|
+
if (eo) return je;
|
|
10131
|
+
eo = 1, Object.defineProperty(je, "__esModule", { value: !0 }), je.reportTypeError = je.checkDataTypes = je.checkDataType = je.coerceAndCheckDataType = je.getJSONTypes = je.getSchemaTypes = je.DataType = void 0;
|
|
10126
10132
|
const t = Iu(), e = Cu(), n = as(), r = oe(), s = me();
|
|
10127
10133
|
var i;
|
|
10128
10134
|
(function(u) {
|
|
@@ -10267,10 +10273,10 @@ function Gr() {
|
|
|
10267
10273
|
}
|
|
10268
10274
|
return je;
|
|
10269
10275
|
}
|
|
10270
|
-
var ln = {},
|
|
10276
|
+
var ln = {}, to;
|
|
10271
10277
|
function vy() {
|
|
10272
|
-
if (
|
|
10273
|
-
|
|
10278
|
+
if (to) return ln;
|
|
10279
|
+
to = 1, Object.defineProperty(ln, "__esModule", { value: !0 }), ln.assignDefaults = void 0;
|
|
10274
10280
|
const t = oe(), e = me();
|
|
10275
10281
|
function n(s, i) {
|
|
10276
10282
|
const { properties: a, items: o } = s.schema;
|
|
@@ -10294,10 +10300,10 @@ function vy() {
|
|
|
10294
10300
|
}
|
|
10295
10301
|
return ln;
|
|
10296
10302
|
}
|
|
10297
|
-
var it = {}, _e = {},
|
|
10303
|
+
var it = {}, _e = {}, no;
|
|
10298
10304
|
function ft() {
|
|
10299
|
-
if (
|
|
10300
|
-
|
|
10305
|
+
if (no) return _e;
|
|
10306
|
+
no = 1, Object.defineProperty(_e, "__esModule", { value: !0 }), _e.validateUnion = _e.validateArray = _e.usePattern = _e.callValidateCode = _e.schemaProperties = _e.allSchemaProperties = _e.noPropertyInData = _e.propertyInData = _e.isOwnProperty = _e.hasPropFunc = _e.reportMissingProp = _e.checkMissingProp = _e.checkReportMissingProp = void 0;
|
|
10301
10307
|
const t = oe(), e = me(), n = Mt(), r = me();
|
|
10302
10308
|
function s(u, p) {
|
|
10303
10309
|
const { gen: _, data: w, it: g } = u;
|
|
@@ -10403,10 +10409,10 @@ function ft() {
|
|
|
10403
10409
|
}
|
|
10404
10410
|
return _e.validateUnion = m, _e;
|
|
10405
10411
|
}
|
|
10406
|
-
var
|
|
10412
|
+
var ro;
|
|
10407
10413
|
function _y() {
|
|
10408
|
-
if (
|
|
10409
|
-
|
|
10414
|
+
if (ro) return it;
|
|
10415
|
+
ro = 1, Object.defineProperty(it, "__esModule", { value: !0 }), it.validateKeywordUsage = it.validSchemaType = it.funcKeywordCode = it.macroKeywordCode = void 0;
|
|
10410
10416
|
const t = oe(), e = Mt(), n = ft(), r = as();
|
|
10411
10417
|
function s(S, b) {
|
|
10412
10418
|
const { gen: v, keyword: y, schema: f, parentSchema: m, it: u } = S, p = b.macro.call(u.self, f, m, u), _ = l(v, y, p);
|
|
@@ -10492,10 +10498,10 @@ function _y() {
|
|
|
10492
10498
|
}
|
|
10493
10499
|
return it.validateKeywordUsage = h, it;
|
|
10494
10500
|
}
|
|
10495
|
-
var vt = {},
|
|
10501
|
+
var vt = {}, so;
|
|
10496
10502
|
function by() {
|
|
10497
|
-
if (
|
|
10498
|
-
|
|
10503
|
+
if (so) return vt;
|
|
10504
|
+
so = 1, Object.defineProperty(vt, "__esModule", { value: !0 }), vt.extendSubschemaMode = vt.extendSubschemaData = vt.getSubschema = void 0;
|
|
10499
10505
|
const t = oe(), e = me();
|
|
10500
10506
|
function n(i, { keyword: a, schemaProp: o, schema: c, schemaPath: l, errSchemaPath: d, topSchemaRef: h }) {
|
|
10501
10507
|
if (a !== void 0 && c !== void 0)
|
|
@@ -10548,9 +10554,9 @@ function by() {
|
|
|
10548
10554
|
}
|
|
10549
10555
|
return vt.extendSubschemaMode = s, vt;
|
|
10550
10556
|
}
|
|
10551
|
-
var Le = {}, Is,
|
|
10557
|
+
var Le = {}, Is, io;
|
|
10552
10558
|
function Ou() {
|
|
10553
|
-
return
|
|
10559
|
+
return io || (io = 1, Is = function t(e, n) {
|
|
10554
10560
|
if (e === n) return !0;
|
|
10555
10561
|
if (e && n && typeof e == "object" && typeof n == "object") {
|
|
10556
10562
|
if (e.constructor !== n.constructor) return !1;
|
|
@@ -10576,10 +10582,10 @@ function Ou() {
|
|
|
10576
10582
|
return e !== e && n !== n;
|
|
10577
10583
|
}), Is;
|
|
10578
10584
|
}
|
|
10579
|
-
var Cs = { exports: {} },
|
|
10585
|
+
var Cs = { exports: {} }, ao;
|
|
10580
10586
|
function wy() {
|
|
10581
|
-
if (
|
|
10582
|
-
|
|
10587
|
+
if (ao) return Cs.exports;
|
|
10588
|
+
ao = 1;
|
|
10583
10589
|
var t = Cs.exports = function(r, s, i) {
|
|
10584
10590
|
typeof s == "function" && (i = s, s = {}), i = s.cb || i;
|
|
10585
10591
|
var a = typeof i == "function" ? i : i.pre || function() {
|
|
@@ -10651,10 +10657,10 @@ function wy() {
|
|
|
10651
10657
|
}
|
|
10652
10658
|
return Cs.exports;
|
|
10653
10659
|
}
|
|
10654
|
-
var
|
|
10660
|
+
var oo;
|
|
10655
10661
|
function os() {
|
|
10656
|
-
if (
|
|
10657
|
-
|
|
10662
|
+
if (oo) return Le;
|
|
10663
|
+
oo = 1, Object.defineProperty(Le, "__esModule", { value: !0 }), Le.getSchemaRefs = Le.resolveUrl = Le.normalizeId = Le._getFullPath = Le.getFullPath = Le.inlineRef = void 0;
|
|
10658
10664
|
const t = me(), e = Ou(), n = wy(), r = /* @__PURE__ */ new Set([
|
|
10659
10665
|
"type",
|
|
10660
10666
|
"format",
|
|
@@ -10760,11 +10766,11 @@ function os() {
|
|
|
10760
10766
|
}
|
|
10761
10767
|
return Le.getSchemaRefs = v, Le;
|
|
10762
10768
|
}
|
|
10763
|
-
var
|
|
10769
|
+
var co;
|
|
10764
10770
|
function cs() {
|
|
10765
|
-
if (
|
|
10766
|
-
|
|
10767
|
-
const t = yy(), e =
|
|
10771
|
+
if (co) return gt;
|
|
10772
|
+
co = 1, Object.defineProperty(gt, "__esModule", { value: !0 }), gt.getData = gt.KeywordCxt = gt.validateFunctionCode = void 0;
|
|
10773
|
+
const t = yy(), e = Br(), n = Cu(), r = Br(), s = vy(), i = _y(), a = by(), o = oe(), c = Mt(), l = os(), d = me(), h = as();
|
|
10768
10774
|
function S(P) {
|
|
10769
10775
|
if (w(P) && ($(P), _(P))) {
|
|
10770
10776
|
f(P);
|
|
@@ -10870,7 +10876,7 @@ function cs() {
|
|
|
10870
10876
|
function ve(P, O, Z, K) {
|
|
10871
10877
|
const { gen: Q, schema: ce, data: xe, allErrors: nt, opts: Fe, self: Ue } = P, { RULES: Ae } = Ue;
|
|
10872
10878
|
if (ce.$ref && (Fe.ignoreKeywordsWithRef || !(0, d.schemaHasRulesButRef)(ce, Ae))) {
|
|
10873
|
-
Q.block(() =>
|
|
10879
|
+
Q.block(() => G(P, "$ref", Ae.all.$ref.definition));
|
|
10874
10880
|
return;
|
|
10875
10881
|
}
|
|
10876
10882
|
Fe.jtd || fe(P, O), Q.block(() => {
|
|
@@ -10886,7 +10892,7 @@ function cs() {
|
|
|
10886
10892
|
const { gen: Z, schema: K, opts: { useDefaults: Q } } = P;
|
|
10887
10893
|
Q && (0, s.assignDefaults)(P, O.type), Z.block(() => {
|
|
10888
10894
|
for (const ce of O.rules)
|
|
10889
|
-
(0, n.shouldUseRule)(K, ce) &&
|
|
10895
|
+
(0, n.shouldUseRule)(K, ce) && G(P, ce.keyword, ce.definition, O.type);
|
|
10890
10896
|
});
|
|
10891
10897
|
}
|
|
10892
10898
|
function fe(P, O) {
|
|
@@ -11034,7 +11040,7 @@ function cs() {
|
|
|
11034
11040
|
}
|
|
11035
11041
|
}
|
|
11036
11042
|
gt.KeywordCxt = j;
|
|
11037
|
-
function
|
|
11043
|
+
function G(P, O, Z, K) {
|
|
11038
11044
|
const Q = new j(P, Z, O);
|
|
11039
11045
|
"code" in Z ? Z.code(Q, K) : Q.$data && Z.validate ? (0, i.funcKeywordCode)(Q, Z) : "macro" in Z ? (0, i.macroKeywordCode)(Q, Z) : (Z.compile || Z.validate) && (0, i.funcKeywordCode)(Q, Z);
|
|
11040
11046
|
}
|
|
@@ -11073,10 +11079,10 @@ function cs() {
|
|
|
11073
11079
|
}
|
|
11074
11080
|
return gt.getData = le, gt;
|
|
11075
11081
|
}
|
|
11076
|
-
var Hn = {},
|
|
11077
|
-
function
|
|
11078
|
-
if (
|
|
11079
|
-
|
|
11082
|
+
var Hn = {}, uo;
|
|
11083
|
+
function qi() {
|
|
11084
|
+
if (uo) return Hn;
|
|
11085
|
+
uo = 1, Object.defineProperty(Hn, "__esModule", { value: !0 });
|
|
11080
11086
|
class t extends Error {
|
|
11081
11087
|
constructor(n) {
|
|
11082
11088
|
super("validation failed"), this.errors = n, this.ajv = this.validation = !0;
|
|
@@ -11084,10 +11090,10 @@ function Di() {
|
|
|
11084
11090
|
}
|
|
11085
11091
|
return Hn.default = t, Hn;
|
|
11086
11092
|
}
|
|
11087
|
-
var Kn = {},
|
|
11093
|
+
var Kn = {}, lo;
|
|
11088
11094
|
function us() {
|
|
11089
|
-
if (
|
|
11090
|
-
|
|
11095
|
+
if (lo) return Kn;
|
|
11096
|
+
lo = 1, Object.defineProperty(Kn, "__esModule", { value: !0 });
|
|
11091
11097
|
const t = os();
|
|
11092
11098
|
class e extends Error {
|
|
11093
11099
|
constructor(r, s, i, a) {
|
|
@@ -11096,11 +11102,11 @@ function us() {
|
|
|
11096
11102
|
}
|
|
11097
11103
|
return Kn.default = e, Kn;
|
|
11098
11104
|
}
|
|
11099
|
-
var
|
|
11100
|
-
function
|
|
11101
|
-
if (
|
|
11102
|
-
|
|
11103
|
-
const t = oe(), e =
|
|
11105
|
+
var Be = {}, fo;
|
|
11106
|
+
function Li() {
|
|
11107
|
+
if (fo) return Be;
|
|
11108
|
+
fo = 1, Object.defineProperty(Be, "__esModule", { value: !0 }), Be.resolveSchema = Be.getCompilingSchema = Be.resolveRef = Be.compileSchema = Be.SchemaEnv = void 0;
|
|
11109
|
+
const t = oe(), e = qi(), n = Mt(), r = os(), s = me(), i = cs();
|
|
11104
11110
|
class a {
|
|
11105
11111
|
constructor(m) {
|
|
11106
11112
|
var u;
|
|
@@ -11109,7 +11115,7 @@ function qi() {
|
|
|
11109
11115
|
typeof m.schema == "object" && (p = m.schema), this.schema = m.schema, this.schemaId = m.schemaId, this.root = m.root || this, this.baseId = (u = m.baseId) !== null && u !== void 0 ? u : (0, r.normalizeId)(p?.[m.schemaId || "$id"]), this.schemaPath = m.schemaPath, this.localRefs = m.localRefs, this.meta = m.meta, this.$async = p?.$async, this.refs = {};
|
|
11110
11116
|
}
|
|
11111
11117
|
}
|
|
11112
|
-
|
|
11118
|
+
Be.SchemaEnv = a;
|
|
11113
11119
|
function o(f) {
|
|
11114
11120
|
const m = d.call(this, f);
|
|
11115
11121
|
if (m)
|
|
@@ -11169,7 +11175,7 @@ function qi() {
|
|
|
11169
11175
|
this._compilations.delete(f);
|
|
11170
11176
|
}
|
|
11171
11177
|
}
|
|
11172
|
-
|
|
11178
|
+
Be.compileSchema = o;
|
|
11173
11179
|
function c(f, m, u) {
|
|
11174
11180
|
var p;
|
|
11175
11181
|
u = (0, r.resolveUrl)(this.opts.uriResolver, m, u);
|
|
@@ -11184,7 +11190,7 @@ function qi() {
|
|
|
11184
11190
|
if (w !== void 0)
|
|
11185
11191
|
return f.refs[u] = l.call(this, w);
|
|
11186
11192
|
}
|
|
11187
|
-
|
|
11193
|
+
Be.resolveRef = c;
|
|
11188
11194
|
function l(f) {
|
|
11189
11195
|
return (0, r.inlineRef)(f.schema, this.opts.inlineRefs) ? f.schema : f.validate ? f : o.call(this, f);
|
|
11190
11196
|
}
|
|
@@ -11193,7 +11199,7 @@ function qi() {
|
|
|
11193
11199
|
if (h(m, f))
|
|
11194
11200
|
return m;
|
|
11195
11201
|
}
|
|
11196
|
-
|
|
11202
|
+
Be.getCompilingSchema = d;
|
|
11197
11203
|
function h(f, m) {
|
|
11198
11204
|
return f.schema === m.schema && f.root === m.root && f.baseId === m.baseId;
|
|
11199
11205
|
}
|
|
@@ -11221,7 +11227,7 @@ function qi() {
|
|
|
11221
11227
|
return y.call(this, u, g);
|
|
11222
11228
|
}
|
|
11223
11229
|
}
|
|
11224
|
-
|
|
11230
|
+
Be.resolveSchema = b;
|
|
11225
11231
|
const v = /* @__PURE__ */ new Set([
|
|
11226
11232
|
"properties",
|
|
11227
11233
|
"patternProperties",
|
|
@@ -11252,7 +11258,7 @@ function qi() {
|
|
|
11252
11258
|
if (w = w || new a({ schema: u, schemaId: g, root: p, baseId: m }), w.schema !== w.root.schema)
|
|
11253
11259
|
return w;
|
|
11254
11260
|
}
|
|
11255
|
-
return
|
|
11261
|
+
return Be;
|
|
11256
11262
|
}
|
|
11257
11263
|
const ky = "https://raw.githubusercontent.com/ajv-validator/ajv/master/lib/refs/data.json#", Sy = "Meta-schema for $data reference (JSON AnySchema extension proposal)", $y = "object", Ty = ["$data"], Ey = { $data: { type: "string", anyOf: [{ format: "relative-json-pointer" }, { format: "json-pointer" }] } }, Py = !1, Ry = {
|
|
11258
11264
|
$id: ky,
|
|
@@ -11262,9 +11268,9 @@ const ky = "https://raw.githubusercontent.com/ajv-validator/ajv/master/lib/refs/
|
|
|
11262
11268
|
properties: Ey,
|
|
11263
11269
|
additionalProperties: Py
|
|
11264
11270
|
};
|
|
11265
|
-
var Wn = {}, dn = { exports: {} }, Os,
|
|
11271
|
+
var Wn = {}, dn = { exports: {} }, Os, po;
|
|
11266
11272
|
function Iy() {
|
|
11267
|
-
return
|
|
11273
|
+
return po || (po = 1, Os = {
|
|
11268
11274
|
HEX: {
|
|
11269
11275
|
0: 0,
|
|
11270
11276
|
1: 1,
|
|
@@ -11291,10 +11297,10 @@ function Iy() {
|
|
|
11291
11297
|
}
|
|
11292
11298
|
}), Os;
|
|
11293
11299
|
}
|
|
11294
|
-
var Ns,
|
|
11300
|
+
var Ns, ho;
|
|
11295
11301
|
function Cy() {
|
|
11296
|
-
if (
|
|
11297
|
-
|
|
11302
|
+
if (ho) return Ns;
|
|
11303
|
+
ho = 1;
|
|
11298
11304
|
const { HEX: t } = Iy(), e = /^(?:(?:25[0-5]|2[0-4]\d|1\d{2}|[1-9]\d|\d)\.){3}(?:25[0-5]|2[0-4]\d|1\d{2}|[1-9]\d|\d)$/u;
|
|
11299
11305
|
function n(y) {
|
|
11300
11306
|
if (o(y, ".") < 3)
|
|
@@ -11426,10 +11432,10 @@ function Cy() {
|
|
|
11426
11432
|
stringArrayToHexStripped: r
|
|
11427
11433
|
}, Ns;
|
|
11428
11434
|
}
|
|
11429
|
-
var xs,
|
|
11435
|
+
var xs, mo;
|
|
11430
11436
|
function Oy() {
|
|
11431
|
-
if (
|
|
11432
|
-
|
|
11437
|
+
if (mo) return xs;
|
|
11438
|
+
mo = 1;
|
|
11433
11439
|
const t = /^[\da-f]{8}-[\da-f]{4}-[\da-f]{4}-[\da-f]{4}-[\da-f]{12}$/iu, e = /([\da-z][\d\-a-z]{0,31}):((?:[\w!$'()*+,\-.:;=@]|%[\da-f]{2})+)/iu;
|
|
11434
11440
|
function n(u) {
|
|
11435
11441
|
return typeof u.secure == "boolean" ? u.secure : String(u.scheme).toLowerCase() === "wss";
|
|
@@ -11518,10 +11524,10 @@ function Oy() {
|
|
|
11518
11524
|
};
|
|
11519
11525
|
return xs = m, xs;
|
|
11520
11526
|
}
|
|
11521
|
-
var
|
|
11527
|
+
var go;
|
|
11522
11528
|
function Ny() {
|
|
11523
|
-
if (
|
|
11524
|
-
|
|
11529
|
+
if (go) return dn.exports;
|
|
11530
|
+
go = 1;
|
|
11525
11531
|
const { normalizeIPv6: t, normalizeIPv4: e, removeDotSegments: n, recomposeAuthority: r, normalizeComponentEncoding: s } = Cy(), i = Oy();
|
|
11526
11532
|
function a(f, m) {
|
|
11527
11533
|
return typeof f == "string" ? f = d(v(f, m), m) : typeof f == "object" && (f = v(d(f, m), m)), f;
|
|
@@ -11617,16 +11623,16 @@ function Ny() {
|
|
|
11617
11623
|
};
|
|
11618
11624
|
return dn.exports = y, dn.exports.default = y, dn.exports.fastUri = y, dn.exports;
|
|
11619
11625
|
}
|
|
11620
|
-
var
|
|
11626
|
+
var yo;
|
|
11621
11627
|
function xy() {
|
|
11622
|
-
if (
|
|
11623
|
-
|
|
11628
|
+
if (yo) return Wn;
|
|
11629
|
+
yo = 1, Object.defineProperty(Wn, "__esModule", { value: !0 });
|
|
11624
11630
|
const t = Ny();
|
|
11625
11631
|
return t.code = 'require("ajv/dist/runtime/uri").default', Wn.default = t, Wn;
|
|
11626
11632
|
}
|
|
11627
|
-
var
|
|
11633
|
+
var vo;
|
|
11628
11634
|
function Ay() {
|
|
11629
|
-
return
|
|
11635
|
+
return vo || (vo = 1, function(t) {
|
|
11630
11636
|
Object.defineProperty(t, "__esModule", { value: !0 }), t.CodeGen = t.Name = t.nil = t.stringify = t.str = t._ = t.KeywordCxt = void 0;
|
|
11631
11637
|
var e = cs();
|
|
11632
11638
|
Object.defineProperty(t, "KeywordCxt", { enumerable: !0, get: function() {
|
|
@@ -11646,7 +11652,7 @@ function Ay() {
|
|
|
11646
11652
|
} }), Object.defineProperty(t, "CodeGen", { enumerable: !0, get: function() {
|
|
11647
11653
|
return n.CodeGen;
|
|
11648
11654
|
} });
|
|
11649
|
-
const r =
|
|
11655
|
+
const r = qi(), s = us(), i = Iu(), a = Li(), o = oe(), c = os(), l = Br(), d = me(), h = Ry, S = xy(), b = (V, I) => new RegExp(V, I);
|
|
11650
11656
|
b.code = "new RegExp";
|
|
11651
11657
|
const v = ["removeAdditional", "useDefaults", "coerceTypes"], y = /* @__PURE__ */ new Set([
|
|
11652
11658
|
"validate",
|
|
@@ -11684,15 +11690,15 @@ function Ay() {
|
|
|
11684
11690
|
unicode: '"minLength"/"maxLength" account for unicode characters by default.'
|
|
11685
11691
|
}, u = 200;
|
|
11686
11692
|
function p(V) {
|
|
11687
|
-
var I, D, N, k, T, j,
|
|
11688
|
-
const on = V.strict, gs = (I = V.code) === null || I === void 0 ? void 0 : I.optimize, Gi = gs === !0 || gs === void 0 ? 1 : gs || 0,
|
|
11693
|
+
var I, D, N, k, T, j, G, te, ge, le, P, O, Z, K, Q, ce, xe, nt, Fe, Ue, Ae, Wt, Ye, hs, ms;
|
|
11694
|
+
const on = V.strict, gs = (I = V.code) === null || I === void 0 ? void 0 : I.optimize, Gi = gs === !0 || gs === void 0 ? 1 : gs || 0, Ji = (N = (D = V.code) === null || D === void 0 ? void 0 : D.regExp) !== null && N !== void 0 ? N : b, Xu = (k = V.uriResolver) !== null && k !== void 0 ? k : S.default;
|
|
11689
11695
|
return {
|
|
11690
11696
|
strictSchema: (j = (T = V.strictSchema) !== null && T !== void 0 ? T : on) !== null && j !== void 0 ? j : !0,
|
|
11691
|
-
strictNumbers: (te = (
|
|
11697
|
+
strictNumbers: (te = (G = V.strictNumbers) !== null && G !== void 0 ? G : on) !== null && te !== void 0 ? te : !0,
|
|
11692
11698
|
strictTypes: (le = (ge = V.strictTypes) !== null && ge !== void 0 ? ge : on) !== null && le !== void 0 ? le : "log",
|
|
11693
11699
|
strictTuples: (O = (P = V.strictTuples) !== null && P !== void 0 ? P : on) !== null && O !== void 0 ? O : "log",
|
|
11694
11700
|
strictRequired: (K = (Z = V.strictRequired) !== null && Z !== void 0 ? Z : on) !== null && K !== void 0 ? K : !1,
|
|
11695
|
-
code: V.code ? { ...V.code, optimize: Gi, regExp:
|
|
11701
|
+
code: V.code ? { ...V.code, optimize: Gi, regExp: Ji } : { optimize: Gi, regExp: Ji },
|
|
11696
11702
|
loopRequired: (Q = V.loopRequired) !== null && Q !== void 0 ? Q : u,
|
|
11697
11703
|
loopEnum: (ce = V.loopEnum) !== null && ce !== void 0 ? ce : u,
|
|
11698
11704
|
meta: (xe = V.meta) !== null && xe !== void 0 ? xe : !0,
|
|
@@ -11760,10 +11766,10 @@ function Ay() {
|
|
|
11760
11766
|
} catch (P) {
|
|
11761
11767
|
if (!(P instanceof s.default))
|
|
11762
11768
|
throw P;
|
|
11763
|
-
return
|
|
11769
|
+
return G.call(this, P), await te.call(this, P.missingSchema), j.call(this, le);
|
|
11764
11770
|
}
|
|
11765
11771
|
}
|
|
11766
|
-
function
|
|
11772
|
+
function G({ missingSchema: le, missingRef: P }) {
|
|
11767
11773
|
if (this.refs[le])
|
|
11768
11774
|
throw new Error(`AnySchema ${le} is loaded but ${P} cannot be resolved`);
|
|
11769
11775
|
}
|
|
@@ -11911,14 +11917,14 @@ function Ay() {
|
|
|
11911
11917
|
for (const k of D) {
|
|
11912
11918
|
const T = k.split("/").slice(1);
|
|
11913
11919
|
let j = I;
|
|
11914
|
-
for (const
|
|
11915
|
-
j = j[
|
|
11916
|
-
for (const
|
|
11917
|
-
const te = N[
|
|
11920
|
+
for (const G of T)
|
|
11921
|
+
j = j[G];
|
|
11922
|
+
for (const G in N) {
|
|
11923
|
+
const te = N[G];
|
|
11918
11924
|
if (typeof te != "object")
|
|
11919
11925
|
continue;
|
|
11920
|
-
const { $data: ge } = te.definition, le = j[
|
|
11921
|
-
ge && le && (j[
|
|
11926
|
+
const { $data: ge } = te.definition, le = j[G];
|
|
11927
|
+
ge && le && (j[G] = tt(le));
|
|
11922
11928
|
}
|
|
11923
11929
|
}
|
|
11924
11930
|
return I;
|
|
@@ -11931,9 +11937,9 @@ function Ay() {
|
|
|
11931
11937
|
}
|
|
11932
11938
|
_addSchema(I, D, N, k = this.opts.validateSchema, T = this.opts.addUsedSchema) {
|
|
11933
11939
|
let j;
|
|
11934
|
-
const { schemaId:
|
|
11940
|
+
const { schemaId: G } = this.opts;
|
|
11935
11941
|
if (typeof I == "object")
|
|
11936
|
-
j = I[
|
|
11942
|
+
j = I[G];
|
|
11937
11943
|
else {
|
|
11938
11944
|
if (this.opts.jtd)
|
|
11939
11945
|
throw new Error("schema must be object");
|
|
@@ -11945,7 +11951,7 @@ function Ay() {
|
|
|
11945
11951
|
return te;
|
|
11946
11952
|
N = (0, c.normalizeId)(j || N);
|
|
11947
11953
|
const ge = c.getSchemaRefs.call(this, I, N);
|
|
11948
|
-
return te = new a.SchemaEnv({ schema: I, schemaId:
|
|
11954
|
+
return te = new a.SchemaEnv({ schema: I, schemaId: G, meta: D, baseId: N, localRefs: ge }), this._cache.set(te.schema, te), T && !N.startsWith("#") && (N && this._checkUnique(N), this.refs[N] = te), k && this.validateSchema(I, !0), te;
|
|
11949
11955
|
}
|
|
11950
11956
|
_checkUnique(I) {
|
|
11951
11957
|
if (this.schemas[I] || this.refs[I])
|
|
@@ -12041,7 +12047,7 @@ function Ay() {
|
|
|
12041
12047
|
let j = k ? T.post : T.rules.find(({ type: te }) => te === D);
|
|
12042
12048
|
if (j || (j = { type: D, rules: [] }, T.rules.push(j)), T.keywords[V] = !0, !I)
|
|
12043
12049
|
return;
|
|
12044
|
-
const
|
|
12050
|
+
const G = {
|
|
12045
12051
|
keyword: V,
|
|
12046
12052
|
definition: {
|
|
12047
12053
|
...I,
|
|
@@ -12049,7 +12055,7 @@ function Ay() {
|
|
|
12049
12055
|
schemaType: (0, l.getJSONTypes)(I.schemaType)
|
|
12050
12056
|
}
|
|
12051
12057
|
};
|
|
12052
|
-
I.before ? ve.call(this, j,
|
|
12058
|
+
I.before ? ve.call(this, j, G, I.before) : j.rules.push(G), T.all[V] = G, (N = I.implements) === null || N === void 0 || N.forEach((te) => this.addKeyword(te));
|
|
12053
12059
|
}
|
|
12054
12060
|
function ve(V, I, D) {
|
|
12055
12061
|
const N = V.rules.findIndex((k) => k.keyword === D);
|
|
@@ -12067,10 +12073,10 @@ function Ay() {
|
|
|
12067
12073
|
}
|
|
12068
12074
|
}($s)), $s;
|
|
12069
12075
|
}
|
|
12070
|
-
var
|
|
12076
|
+
var Bn = {}, Gn = {}, Jn = {}, _o;
|
|
12071
12077
|
function jy() {
|
|
12072
|
-
if (
|
|
12073
|
-
|
|
12078
|
+
if (_o) return Jn;
|
|
12079
|
+
_o = 1, Object.defineProperty(Jn, "__esModule", { value: !0 });
|
|
12074
12080
|
const t = {
|
|
12075
12081
|
keyword: "id",
|
|
12076
12082
|
code() {
|
|
@@ -12079,11 +12085,11 @@ function jy() {
|
|
|
12079
12085
|
};
|
|
12080
12086
|
return Jn.default = t, Jn;
|
|
12081
12087
|
}
|
|
12082
|
-
var Et = {},
|
|
12088
|
+
var Et = {}, bo;
|
|
12083
12089
|
function zy() {
|
|
12084
|
-
if (
|
|
12085
|
-
|
|
12086
|
-
const t = us(), e = ft(), n = oe(), r = Mt(), s =
|
|
12090
|
+
if (bo) return Et;
|
|
12091
|
+
bo = 1, Object.defineProperty(Et, "__esModule", { value: !0 }), Et.callRef = Et.getValidate = void 0;
|
|
12092
|
+
const t = us(), e = ft(), n = oe(), r = Mt(), s = Li(), i = me(), a = {
|
|
12087
12093
|
keyword: "$ref",
|
|
12088
12094
|
schemaType: "string",
|
|
12089
12095
|
code(l) {
|
|
@@ -12166,10 +12172,10 @@ function zy() {
|
|
|
12166
12172
|
}
|
|
12167
12173
|
return Et.callRef = c, Et.default = a, Et;
|
|
12168
12174
|
}
|
|
12169
|
-
var
|
|
12175
|
+
var wo;
|
|
12170
12176
|
function My() {
|
|
12171
|
-
if (
|
|
12172
|
-
|
|
12177
|
+
if (wo) return Gn;
|
|
12178
|
+
wo = 1, Object.defineProperty(Gn, "__esModule", { value: !0 });
|
|
12173
12179
|
const t = jy(), e = zy(), n = [
|
|
12174
12180
|
"$schema",
|
|
12175
12181
|
"$id",
|
|
@@ -12180,12 +12186,12 @@ function My() {
|
|
|
12180
12186
|
t.default,
|
|
12181
12187
|
e.default
|
|
12182
12188
|
];
|
|
12183
|
-
return
|
|
12189
|
+
return Gn.default = n, Gn;
|
|
12184
12190
|
}
|
|
12185
|
-
var Yn = {}, Qn = {},
|
|
12191
|
+
var Yn = {}, Qn = {}, ko;
|
|
12186
12192
|
function Zy() {
|
|
12187
|
-
if (
|
|
12188
|
-
|
|
12193
|
+
if (ko) return Qn;
|
|
12194
|
+
ko = 1, Object.defineProperty(Qn, "__esModule", { value: !0 });
|
|
12189
12195
|
const t = oe(), e = t.operators, n = {
|
|
12190
12196
|
maximum: { okStr: "<=", ok: e.LTE, fail: e.GT },
|
|
12191
12197
|
minimum: { okStr: ">=", ok: e.GTE, fail: e.LT },
|
|
@@ -12207,10 +12213,10 @@ function Zy() {
|
|
|
12207
12213
|
};
|
|
12208
12214
|
return Qn.default = s, Qn;
|
|
12209
12215
|
}
|
|
12210
|
-
var Xn = {},
|
|
12216
|
+
var Xn = {}, So;
|
|
12211
12217
|
function Dy() {
|
|
12212
|
-
if (
|
|
12213
|
-
|
|
12218
|
+
if (So) return Xn;
|
|
12219
|
+
So = 1, Object.defineProperty(Xn, "__esModule", { value: !0 });
|
|
12214
12220
|
const t = oe(), n = {
|
|
12215
12221
|
keyword: "multipleOf",
|
|
12216
12222
|
type: "number",
|
|
@@ -12227,10 +12233,10 @@ function Dy() {
|
|
|
12227
12233
|
};
|
|
12228
12234
|
return Xn.default = n, Xn;
|
|
12229
12235
|
}
|
|
12230
|
-
var er = {}, tr = {},
|
|
12236
|
+
var er = {}, tr = {}, $o;
|
|
12231
12237
|
function qy() {
|
|
12232
|
-
if (
|
|
12233
|
-
|
|
12238
|
+
if ($o) return tr;
|
|
12239
|
+
$o = 1, Object.defineProperty(tr, "__esModule", { value: !0 });
|
|
12234
12240
|
function t(e) {
|
|
12235
12241
|
const n = e.length;
|
|
12236
12242
|
let r = 0, s = 0, i;
|
|
@@ -12240,10 +12246,10 @@ function qy() {
|
|
|
12240
12246
|
}
|
|
12241
12247
|
return tr.default = t, t.code = 'require("ajv/dist/runtime/ucs2length").default', tr;
|
|
12242
12248
|
}
|
|
12243
|
-
var
|
|
12249
|
+
var To;
|
|
12244
12250
|
function Ly() {
|
|
12245
|
-
if (
|
|
12246
|
-
|
|
12251
|
+
if (To) return er;
|
|
12252
|
+
To = 1, Object.defineProperty(er, "__esModule", { value: !0 });
|
|
12247
12253
|
const t = oe(), e = me(), n = qy(), s = {
|
|
12248
12254
|
keyword: ["maxLength", "minLength"],
|
|
12249
12255
|
type: "string",
|
|
@@ -12263,10 +12269,10 @@ function Ly() {
|
|
|
12263
12269
|
};
|
|
12264
12270
|
return er.default = s, er;
|
|
12265
12271
|
}
|
|
12266
|
-
var nr = {},
|
|
12272
|
+
var nr = {}, Eo;
|
|
12267
12273
|
function Vy() {
|
|
12268
|
-
if (
|
|
12269
|
-
|
|
12274
|
+
if (Eo) return nr;
|
|
12275
|
+
Eo = 1, Object.defineProperty(nr, "__esModule", { value: !0 });
|
|
12270
12276
|
const t = ft(), e = oe(), r = {
|
|
12271
12277
|
keyword: "pattern",
|
|
12272
12278
|
type: "string",
|
|
@@ -12283,10 +12289,10 @@ function Vy() {
|
|
|
12283
12289
|
};
|
|
12284
12290
|
return nr.default = r, nr;
|
|
12285
12291
|
}
|
|
12286
|
-
var rr = {},
|
|
12292
|
+
var rr = {}, Po;
|
|
12287
12293
|
function Fy() {
|
|
12288
|
-
if (
|
|
12289
|
-
|
|
12294
|
+
if (Po) return rr;
|
|
12295
|
+
Po = 1, Object.defineProperty(rr, "__esModule", { value: !0 });
|
|
12290
12296
|
const t = oe(), n = {
|
|
12291
12297
|
keyword: ["maxProperties", "minProperties"],
|
|
12292
12298
|
type: "object",
|
|
@@ -12306,10 +12312,10 @@ function Fy() {
|
|
|
12306
12312
|
};
|
|
12307
12313
|
return rr.default = n, rr;
|
|
12308
12314
|
}
|
|
12309
|
-
var sr = {},
|
|
12315
|
+
var sr = {}, Ro;
|
|
12310
12316
|
function Uy() {
|
|
12311
|
-
if (
|
|
12312
|
-
|
|
12317
|
+
if (Ro) return sr;
|
|
12318
|
+
Ro = 1, Object.defineProperty(sr, "__esModule", { value: !0 });
|
|
12313
12319
|
const t = ft(), e = oe(), n = me(), s = {
|
|
12314
12320
|
keyword: "required",
|
|
12315
12321
|
type: "object",
|
|
@@ -12363,10 +12369,10 @@ function Uy() {
|
|
|
12363
12369
|
};
|
|
12364
12370
|
return sr.default = s, sr;
|
|
12365
12371
|
}
|
|
12366
|
-
var ir = {},
|
|
12372
|
+
var ir = {}, Io;
|
|
12367
12373
|
function Hy() {
|
|
12368
|
-
if (
|
|
12369
|
-
|
|
12374
|
+
if (Io) return ir;
|
|
12375
|
+
Io = 1, Object.defineProperty(ir, "__esModule", { value: !0 });
|
|
12370
12376
|
const t = oe(), n = {
|
|
12371
12377
|
keyword: ["maxItems", "minItems"],
|
|
12372
12378
|
type: "array",
|
|
@@ -12386,18 +12392,18 @@ function Hy() {
|
|
|
12386
12392
|
};
|
|
12387
12393
|
return ir.default = n, ir;
|
|
12388
12394
|
}
|
|
12389
|
-
var ar = {}, or = {},
|
|
12390
|
-
function
|
|
12391
|
-
if (
|
|
12392
|
-
|
|
12395
|
+
var ar = {}, or = {}, Co;
|
|
12396
|
+
function Vi() {
|
|
12397
|
+
if (Co) return or;
|
|
12398
|
+
Co = 1, Object.defineProperty(or, "__esModule", { value: !0 });
|
|
12393
12399
|
const t = Ou();
|
|
12394
12400
|
return t.code = 'require("ajv/dist/runtime/equal").default', or.default = t, or;
|
|
12395
12401
|
}
|
|
12396
|
-
var
|
|
12402
|
+
var Oo;
|
|
12397
12403
|
function Ky() {
|
|
12398
|
-
if (
|
|
12399
|
-
|
|
12400
|
-
const t =
|
|
12404
|
+
if (Oo) return ar;
|
|
12405
|
+
Oo = 1, Object.defineProperty(ar, "__esModule", { value: !0 });
|
|
12406
|
+
const t = Br(), e = oe(), n = me(), r = Vi(), i = {
|
|
12401
12407
|
keyword: "uniqueItems",
|
|
12402
12408
|
type: "array",
|
|
12403
12409
|
schemaType: "boolean",
|
|
@@ -12437,11 +12443,11 @@ function Ky() {
|
|
|
12437
12443
|
};
|
|
12438
12444
|
return ar.default = i, ar;
|
|
12439
12445
|
}
|
|
12440
|
-
var cr = {},
|
|
12446
|
+
var cr = {}, No;
|
|
12441
12447
|
function Wy() {
|
|
12442
|
-
if (
|
|
12443
|
-
|
|
12444
|
-
const t = oe(), e = me(), n =
|
|
12448
|
+
if (No) return cr;
|
|
12449
|
+
No = 1, Object.defineProperty(cr, "__esModule", { value: !0 });
|
|
12450
|
+
const t = oe(), e = me(), n = Vi(), s = {
|
|
12445
12451
|
keyword: "const",
|
|
12446
12452
|
$data: !0,
|
|
12447
12453
|
error: {
|
|
@@ -12455,11 +12461,11 @@ function Wy() {
|
|
|
12455
12461
|
};
|
|
12456
12462
|
return cr.default = s, cr;
|
|
12457
12463
|
}
|
|
12458
|
-
var ur = {},
|
|
12459
|
-
function
|
|
12460
|
-
if (
|
|
12461
|
-
|
|
12462
|
-
const t = oe(), e = me(), n =
|
|
12464
|
+
var ur = {}, xo;
|
|
12465
|
+
function By() {
|
|
12466
|
+
if (xo) return ur;
|
|
12467
|
+
xo = 1, Object.defineProperty(ur, "__esModule", { value: !0 });
|
|
12468
|
+
const t = oe(), e = me(), n = Vi(), s = {
|
|
12463
12469
|
keyword: "enum",
|
|
12464
12470
|
schemaType: "array",
|
|
12465
12471
|
$data: !0,
|
|
@@ -12495,11 +12501,11 @@ function Gy() {
|
|
|
12495
12501
|
};
|
|
12496
12502
|
return ur.default = s, ur;
|
|
12497
12503
|
}
|
|
12498
|
-
var
|
|
12499
|
-
function
|
|
12500
|
-
if (
|
|
12501
|
-
|
|
12502
|
-
const t = Zy(), e = Dy(), n = Ly(), r = Vy(), s = Fy(), i = Uy(), a = Hy(), o = Ky(), c = Wy(), l =
|
|
12504
|
+
var Ao;
|
|
12505
|
+
function Gy() {
|
|
12506
|
+
if (Ao) return Yn;
|
|
12507
|
+
Ao = 1, Object.defineProperty(Yn, "__esModule", { value: !0 });
|
|
12508
|
+
const t = Zy(), e = Dy(), n = Ly(), r = Vy(), s = Fy(), i = Uy(), a = Hy(), o = Ky(), c = Wy(), l = By(), d = [
|
|
12503
12509
|
// number
|
|
12504
12510
|
t.default,
|
|
12505
12511
|
e.default,
|
|
@@ -12520,10 +12526,10 @@ function By() {
|
|
|
12520
12526
|
];
|
|
12521
12527
|
return Yn.default = d, Yn;
|
|
12522
12528
|
}
|
|
12523
|
-
var lr = {},
|
|
12529
|
+
var lr = {}, Bt = {}, jo;
|
|
12524
12530
|
function Nu() {
|
|
12525
|
-
if (
|
|
12526
|
-
|
|
12531
|
+
if (jo) return Bt;
|
|
12532
|
+
jo = 1, Object.defineProperty(Bt, "__esModule", { value: !0 }), Bt.validateAdditionalItems = void 0;
|
|
12527
12533
|
const t = oe(), e = me(), r = {
|
|
12528
12534
|
keyword: "additionalItems",
|
|
12529
12535
|
type: "array",
|
|
@@ -12558,12 +12564,12 @@ function Nu() {
|
|
|
12558
12564
|
});
|
|
12559
12565
|
}
|
|
12560
12566
|
}
|
|
12561
|
-
return
|
|
12567
|
+
return Bt.validateAdditionalItems = s, Bt.default = r, Bt;
|
|
12562
12568
|
}
|
|
12563
|
-
var dr = {},
|
|
12569
|
+
var dr = {}, Gt = {}, zo;
|
|
12564
12570
|
function xu() {
|
|
12565
|
-
if (
|
|
12566
|
-
|
|
12571
|
+
if (zo) return Gt;
|
|
12572
|
+
zo = 1, Object.defineProperty(Gt, "__esModule", { value: !0 }), Gt.validateTuple = void 0;
|
|
12567
12573
|
const t = oe(), e = me(), n = ft(), r = {
|
|
12568
12574
|
keyword: "items",
|
|
12569
12575
|
type: "array",
|
|
@@ -12595,12 +12601,12 @@ function xu() {
|
|
|
12595
12601
|
}
|
|
12596
12602
|
}
|
|
12597
12603
|
}
|
|
12598
|
-
return
|
|
12604
|
+
return Gt.validateTuple = s, Gt.default = r, Gt;
|
|
12599
12605
|
}
|
|
12600
|
-
var
|
|
12606
|
+
var Mo;
|
|
12601
12607
|
function Jy() {
|
|
12602
|
-
if (
|
|
12603
|
-
|
|
12608
|
+
if (Mo) return dr;
|
|
12609
|
+
Mo = 1, Object.defineProperty(dr, "__esModule", { value: !0 });
|
|
12604
12610
|
const t = xu(), e = {
|
|
12605
12611
|
keyword: "prefixItems",
|
|
12606
12612
|
type: "array",
|
|
@@ -12610,10 +12616,10 @@ function Jy() {
|
|
|
12610
12616
|
};
|
|
12611
12617
|
return dr.default = e, dr;
|
|
12612
12618
|
}
|
|
12613
|
-
var fr = {},
|
|
12619
|
+
var fr = {}, Zo;
|
|
12614
12620
|
function Yy() {
|
|
12615
|
-
if (
|
|
12616
|
-
|
|
12621
|
+
if (Zo) return fr;
|
|
12622
|
+
Zo = 1, Object.defineProperty(fr, "__esModule", { value: !0 });
|
|
12617
12623
|
const t = oe(), e = me(), n = ft(), r = Nu(), i = {
|
|
12618
12624
|
keyword: "items",
|
|
12619
12625
|
type: "array",
|
|
@@ -12630,10 +12636,10 @@ function Yy() {
|
|
|
12630
12636
|
};
|
|
12631
12637
|
return fr.default = i, fr;
|
|
12632
12638
|
}
|
|
12633
|
-
var pr = {},
|
|
12639
|
+
var pr = {}, Do;
|
|
12634
12640
|
function Qy() {
|
|
12635
|
-
if (
|
|
12636
|
-
|
|
12641
|
+
if (Do) return pr;
|
|
12642
|
+
Do = 1, Object.defineProperty(pr, "__esModule", { value: !0 });
|
|
12637
12643
|
const t = oe(), e = me(), r = {
|
|
12638
12644
|
keyword: "contains",
|
|
12639
12645
|
type: "array",
|
|
@@ -12687,9 +12693,9 @@ function Qy() {
|
|
|
12687
12693
|
};
|
|
12688
12694
|
return pr.default = r, pr;
|
|
12689
12695
|
}
|
|
12690
|
-
var As = {},
|
|
12696
|
+
var As = {}, qo;
|
|
12691
12697
|
function Xy() {
|
|
12692
|
-
return
|
|
12698
|
+
return qo || (qo = 1, function(t) {
|
|
12693
12699
|
Object.defineProperty(t, "__esModule", { value: !0 }), t.validateSchemaDeps = t.validatePropertyDeps = t.error = void 0;
|
|
12694
12700
|
const e = oe(), n = me(), r = ft();
|
|
12695
12701
|
t.error = {
|
|
@@ -12760,10 +12766,10 @@ function Xy() {
|
|
|
12760
12766
|
t.validateSchemaDeps = o, t.default = s;
|
|
12761
12767
|
}(As)), As;
|
|
12762
12768
|
}
|
|
12763
|
-
var hr = {},
|
|
12769
|
+
var hr = {}, Lo;
|
|
12764
12770
|
function ev() {
|
|
12765
|
-
if (
|
|
12766
|
-
|
|
12771
|
+
if (Lo) return hr;
|
|
12772
|
+
Lo = 1, Object.defineProperty(hr, "__esModule", { value: !0 });
|
|
12767
12773
|
const t = oe(), e = me(), r = {
|
|
12768
12774
|
keyword: "propertyNames",
|
|
12769
12775
|
type: "object",
|
|
@@ -12792,10 +12798,10 @@ function ev() {
|
|
|
12792
12798
|
};
|
|
12793
12799
|
return hr.default = r, hr;
|
|
12794
12800
|
}
|
|
12795
|
-
var mr = {},
|
|
12801
|
+
var mr = {}, Vo;
|
|
12796
12802
|
function Au() {
|
|
12797
|
-
if (
|
|
12798
|
-
|
|
12803
|
+
if (Vo) return mr;
|
|
12804
|
+
Vo = 1, Object.defineProperty(mr, "__esModule", { value: !0 });
|
|
12799
12805
|
const t = ft(), e = oe(), n = Mt(), r = me(), i = {
|
|
12800
12806
|
keyword: "additionalProperties",
|
|
12801
12807
|
type: ["object"],
|
|
@@ -12863,10 +12869,10 @@ function Au() {
|
|
|
12863
12869
|
};
|
|
12864
12870
|
return mr.default = i, mr;
|
|
12865
12871
|
}
|
|
12866
|
-
var gr = {},
|
|
12872
|
+
var gr = {}, Fo;
|
|
12867
12873
|
function tv() {
|
|
12868
|
-
if (
|
|
12869
|
-
|
|
12874
|
+
if (Fo) return gr;
|
|
12875
|
+
Fo = 1, Object.defineProperty(gr, "__esModule", { value: !0 });
|
|
12870
12876
|
const t = cs(), e = ft(), n = me(), r = Au(), s = {
|
|
12871
12877
|
keyword: "properties",
|
|
12872
12878
|
type: "object",
|
|
@@ -12898,10 +12904,10 @@ function tv() {
|
|
|
12898
12904
|
};
|
|
12899
12905
|
return gr.default = s, gr;
|
|
12900
12906
|
}
|
|
12901
|
-
var yr = {},
|
|
12907
|
+
var yr = {}, Uo;
|
|
12902
12908
|
function nv() {
|
|
12903
|
-
if (
|
|
12904
|
-
|
|
12909
|
+
if (Uo) return yr;
|
|
12910
|
+
Uo = 1, Object.defineProperty(yr, "__esModule", { value: !0 });
|
|
12905
12911
|
const t = ft(), e = oe(), n = me(), r = me(), s = {
|
|
12906
12912
|
keyword: "patternProperties",
|
|
12907
12913
|
type: "object",
|
|
@@ -12939,10 +12945,10 @@ function nv() {
|
|
|
12939
12945
|
};
|
|
12940
12946
|
return yr.default = s, yr;
|
|
12941
12947
|
}
|
|
12942
|
-
var vr = {},
|
|
12948
|
+
var vr = {}, Ho;
|
|
12943
12949
|
function rv() {
|
|
12944
|
-
if (
|
|
12945
|
-
|
|
12950
|
+
if (Ho) return vr;
|
|
12951
|
+
Ho = 1, Object.defineProperty(vr, "__esModule", { value: !0 });
|
|
12946
12952
|
const t = me(), e = {
|
|
12947
12953
|
keyword: "not",
|
|
12948
12954
|
schemaType: ["object", "boolean"],
|
|
@@ -12965,10 +12971,10 @@ function rv() {
|
|
|
12965
12971
|
};
|
|
12966
12972
|
return vr.default = e, vr;
|
|
12967
12973
|
}
|
|
12968
|
-
var _r = {},
|
|
12974
|
+
var _r = {}, Ko;
|
|
12969
12975
|
function sv() {
|
|
12970
|
-
if (
|
|
12971
|
-
|
|
12976
|
+
if (Ko) return _r;
|
|
12977
|
+
Ko = 1, Object.defineProperty(_r, "__esModule", { value: !0 });
|
|
12972
12978
|
const e = {
|
|
12973
12979
|
keyword: "anyOf",
|
|
12974
12980
|
schemaType: "array",
|
|
@@ -12978,10 +12984,10 @@ function sv() {
|
|
|
12978
12984
|
};
|
|
12979
12985
|
return _r.default = e, _r;
|
|
12980
12986
|
}
|
|
12981
|
-
var br = {},
|
|
12987
|
+
var br = {}, Wo;
|
|
12982
12988
|
function iv() {
|
|
12983
|
-
if (
|
|
12984
|
-
|
|
12989
|
+
if (Wo) return br;
|
|
12990
|
+
Wo = 1, Object.defineProperty(br, "__esModule", { value: !0 });
|
|
12985
12991
|
const t = oe(), e = me(), r = {
|
|
12986
12992
|
keyword: "oneOf",
|
|
12987
12993
|
schemaType: "array",
|
|
@@ -13014,10 +13020,10 @@ function iv() {
|
|
|
13014
13020
|
};
|
|
13015
13021
|
return br.default = r, br;
|
|
13016
13022
|
}
|
|
13017
|
-
var wr = {},
|
|
13023
|
+
var wr = {}, Bo;
|
|
13018
13024
|
function av() {
|
|
13019
|
-
if (
|
|
13020
|
-
|
|
13025
|
+
if (Bo) return wr;
|
|
13026
|
+
Bo = 1, Object.defineProperty(wr, "__esModule", { value: !0 });
|
|
13021
13027
|
const t = me(), e = {
|
|
13022
13028
|
keyword: "allOf",
|
|
13023
13029
|
schemaType: "array",
|
|
@@ -13083,10 +13089,10 @@ function ov() {
|
|
|
13083
13089
|
}
|
|
13084
13090
|
return kr.default = r, kr;
|
|
13085
13091
|
}
|
|
13086
|
-
var Sr = {},
|
|
13092
|
+
var Sr = {}, Jo;
|
|
13087
13093
|
function cv() {
|
|
13088
|
-
if (
|
|
13089
|
-
|
|
13094
|
+
if (Jo) return Sr;
|
|
13095
|
+
Jo = 1, Object.defineProperty(Sr, "__esModule", { value: !0 });
|
|
13090
13096
|
const t = me(), e = {
|
|
13091
13097
|
keyword: ["then", "else"],
|
|
13092
13098
|
schemaType: ["object", "boolean"],
|
|
@@ -13096,10 +13102,10 @@ function cv() {
|
|
|
13096
13102
|
};
|
|
13097
13103
|
return Sr.default = e, Sr;
|
|
13098
13104
|
}
|
|
13099
|
-
var
|
|
13105
|
+
var Yo;
|
|
13100
13106
|
function uv() {
|
|
13101
|
-
if (
|
|
13102
|
-
|
|
13107
|
+
if (Yo) return lr;
|
|
13108
|
+
Yo = 1, Object.defineProperty(lr, "__esModule", { value: !0 });
|
|
13103
13109
|
const t = Nu(), e = Jy(), n = xu(), r = Yy(), s = Qy(), i = Xy(), a = ev(), o = Au(), c = tv(), l = nv(), d = rv(), h = sv(), S = iv(), b = av(), v = ov(), y = cv();
|
|
13104
13110
|
function f(m = !1) {
|
|
13105
13111
|
const u = [
|
|
@@ -13121,10 +13127,10 @@ function uv() {
|
|
|
13121
13127
|
}
|
|
13122
13128
|
return lr.default = f, lr;
|
|
13123
13129
|
}
|
|
13124
|
-
var $r = {}, Tr = {},
|
|
13130
|
+
var $r = {}, Tr = {}, Qo;
|
|
13125
13131
|
function lv() {
|
|
13126
|
-
if (
|
|
13127
|
-
|
|
13132
|
+
if (Qo) return Tr;
|
|
13133
|
+
Qo = 1, Object.defineProperty(Tr, "__esModule", { value: !0 });
|
|
13128
13134
|
const t = oe(), n = {
|
|
13129
13135
|
keyword: "format",
|
|
13130
13136
|
type: ["number", "string"],
|
|
@@ -13190,16 +13196,16 @@ function lv() {
|
|
|
13190
13196
|
};
|
|
13191
13197
|
return Tr.default = n, Tr;
|
|
13192
13198
|
}
|
|
13193
|
-
var
|
|
13199
|
+
var Xo;
|
|
13194
13200
|
function dv() {
|
|
13195
|
-
if (
|
|
13196
|
-
|
|
13201
|
+
if (Xo) return $r;
|
|
13202
|
+
Xo = 1, Object.defineProperty($r, "__esModule", { value: !0 });
|
|
13197
13203
|
const e = [lv().default];
|
|
13198
13204
|
return $r.default = e, $r;
|
|
13199
13205
|
}
|
|
13200
|
-
var Lt = {},
|
|
13206
|
+
var Lt = {}, ec;
|
|
13201
13207
|
function fv() {
|
|
13202
|
-
return
|
|
13208
|
+
return ec || (ec = 1, Object.defineProperty(Lt, "__esModule", { value: !0 }), Lt.contentVocabulary = Lt.metadataVocabulary = void 0, Lt.metadataVocabulary = [
|
|
13203
13209
|
"title",
|
|
13204
13210
|
"description",
|
|
13205
13211
|
"default",
|
|
@@ -13213,11 +13219,11 @@ function fv() {
|
|
|
13213
13219
|
"contentSchema"
|
|
13214
13220
|
]), Lt;
|
|
13215
13221
|
}
|
|
13216
|
-
var
|
|
13222
|
+
var tc;
|
|
13217
13223
|
function pv() {
|
|
13218
|
-
if (
|
|
13219
|
-
|
|
13220
|
-
const t = My(), e =
|
|
13224
|
+
if (tc) return Bn;
|
|
13225
|
+
tc = 1, Object.defineProperty(Bn, "__esModule", { value: !0 });
|
|
13226
|
+
const t = My(), e = Gy(), n = uv(), r = dv(), s = fv(), i = [
|
|
13221
13227
|
t.default,
|
|
13222
13228
|
e.default,
|
|
13223
13229
|
(0, n.default)(),
|
|
@@ -13225,22 +13231,22 @@ function pv() {
|
|
|
13225
13231
|
s.metadataVocabulary,
|
|
13226
13232
|
s.contentVocabulary
|
|
13227
13233
|
];
|
|
13228
|
-
return
|
|
13234
|
+
return Bn.default = i, Bn;
|
|
13229
13235
|
}
|
|
13230
|
-
var Er = {}, fn = {},
|
|
13236
|
+
var Er = {}, fn = {}, nc;
|
|
13231
13237
|
function hv() {
|
|
13232
|
-
if (
|
|
13233
|
-
|
|
13238
|
+
if (nc) return fn;
|
|
13239
|
+
nc = 1, Object.defineProperty(fn, "__esModule", { value: !0 }), fn.DiscrError = void 0;
|
|
13234
13240
|
var t;
|
|
13235
13241
|
return function(e) {
|
|
13236
13242
|
e.Tag = "tag", e.Mapping = "mapping";
|
|
13237
13243
|
}(t || (fn.DiscrError = t = {})), fn;
|
|
13238
13244
|
}
|
|
13239
|
-
var
|
|
13245
|
+
var rc;
|
|
13240
13246
|
function mv() {
|
|
13241
|
-
if (
|
|
13242
|
-
|
|
13243
|
-
const t = oe(), e = hv(), n =
|
|
13247
|
+
if (rc) return Er;
|
|
13248
|
+
rc = 1, Object.defineProperty(Er, "__esModule", { value: !0 });
|
|
13249
|
+
const t = oe(), e = hv(), n = Li(), r = us(), s = me(), a = {
|
|
13244
13250
|
keyword: "discriminator",
|
|
13245
13251
|
type: "object",
|
|
13246
13252
|
schemaType: "object",
|
|
@@ -13322,9 +13328,9 @@ const gv = "http://json-schema.org/draft-07/schema#", yv = "http://json-schema.o
|
|
|
13322
13328
|
properties: wv,
|
|
13323
13329
|
default: !0
|
|
13324
13330
|
};
|
|
13325
|
-
var
|
|
13331
|
+
var sc;
|
|
13326
13332
|
function ju() {
|
|
13327
|
-
return
|
|
13333
|
+
return sc || (sc = 1, function(t, e) {
|
|
13328
13334
|
Object.defineProperty(e, "__esModule", { value: !0 }), e.MissingRefError = e.ValidationError = e.CodeGen = e.Name = e.nil = e.stringify = e.str = e._ = e.KeywordCxt = e.Ajv = void 0;
|
|
13329
13335
|
const n = Ay(), r = pv(), s = mv(), i = kv, a = ["/properties"], o = "http://json-schema.org/draft-07/schema";
|
|
13330
13336
|
class c extends n.default {
|
|
@@ -13360,7 +13366,7 @@ function ju() {
|
|
|
13360
13366
|
} }), Object.defineProperty(e, "CodeGen", { enumerable: !0, get: function() {
|
|
13361
13367
|
return d.CodeGen;
|
|
13362
13368
|
} });
|
|
13363
|
-
var h =
|
|
13369
|
+
var h = qi();
|
|
13364
13370
|
Object.defineProperty(e, "ValidationError", { enumerable: !0, get: function() {
|
|
13365
13371
|
return h.default;
|
|
13366
13372
|
} });
|
|
@@ -13370,9 +13376,9 @@ function ju() {
|
|
|
13370
13376
|
} });
|
|
13371
13377
|
}(Fn, Fn.exports)), Fn.exports;
|
|
13372
13378
|
}
|
|
13373
|
-
var Sv = ju(), Pr = { exports: {} }, js = {},
|
|
13379
|
+
var Sv = ju(), Pr = { exports: {} }, js = {}, ic;
|
|
13374
13380
|
function $v() {
|
|
13375
|
-
return
|
|
13381
|
+
return ic || (ic = 1, function(t) {
|
|
13376
13382
|
Object.defineProperty(t, "__esModule", { value: !0 }), t.formatNames = t.fastFormats = t.fullFormats = void 0;
|
|
13377
13383
|
function e(C, M) {
|
|
13378
13384
|
return { validate: C, compare: M };
|
|
@@ -13534,9 +13540,9 @@ function $v() {
|
|
|
13534
13540
|
}
|
|
13535
13541
|
}(js)), js;
|
|
13536
13542
|
}
|
|
13537
|
-
var zs = {},
|
|
13543
|
+
var zs = {}, ac;
|
|
13538
13544
|
function Tv() {
|
|
13539
|
-
return
|
|
13545
|
+
return ac || (ac = 1, function(t) {
|
|
13540
13546
|
Object.defineProperty(t, "__esModule", { value: !0 }), t.formatLimitDefinition = void 0;
|
|
13541
13547
|
const e = ju(), n = oe(), r = n.operators, s = {
|
|
13542
13548
|
formatMaximum: { okStr: "<=", ok: r.LTE, fail: r.GT },
|
|
@@ -13589,9 +13595,9 @@ function Tv() {
|
|
|
13589
13595
|
t.default = a;
|
|
13590
13596
|
}(zs)), zs;
|
|
13591
13597
|
}
|
|
13592
|
-
var
|
|
13598
|
+
var oc;
|
|
13593
13599
|
function Ev() {
|
|
13594
|
-
return
|
|
13600
|
+
return oc || (oc = 1, function(t, e) {
|
|
13595
13601
|
Object.defineProperty(e, "__esModule", { value: !0 });
|
|
13596
13602
|
const n = $v(), r = Tv(), s = oe(), i = new s.Name("fullFormats"), a = new s.Name("fastFormats"), o = (l, d = { keywords: !0 }) => {
|
|
13597
13603
|
if (Array.isArray(d))
|
|
@@ -13842,7 +13848,7 @@ class Av extends my {
|
|
|
13842
13848
|
}
|
|
13843
13849
|
return m.data;
|
|
13844
13850
|
}
|
|
13845
|
-
const f = bn(
|
|
13851
|
+
const f = bn(Di, y);
|
|
13846
13852
|
if (!f.success) {
|
|
13847
13853
|
const m = f.error instanceof Error ? f.error.message : String(f.error);
|
|
13848
13854
|
throw new ne(re.InvalidParams, `Invalid tools/call result: ${m}`);
|
|
@@ -13943,7 +13949,7 @@ class Av extends my {
|
|
|
13943
13949
|
async _oninitialize(e) {
|
|
13944
13950
|
const n = e.params.protocolVersion;
|
|
13945
13951
|
return this._clientCapabilities = e.params.capabilities, this._clientVersion = e.params.clientInfo, {
|
|
13946
|
-
protocolVersion:
|
|
13952
|
+
protocolVersion: Gh.includes(n) ? n : su,
|
|
13947
13953
|
capabilities: this.getCapabilities(),
|
|
13948
13954
|
serverInfo: this._serverInfo,
|
|
13949
13955
|
...this._instructions && { instructions: this._instructions }
|
|
@@ -13965,7 +13971,7 @@ class Av extends my {
|
|
|
13965
13971
|
return this._capabilities;
|
|
13966
13972
|
}
|
|
13967
13973
|
async ping() {
|
|
13968
|
-
return this.request({ method: "ping" },
|
|
13974
|
+
return this.request({ method: "ping" }, $i);
|
|
13969
13975
|
}
|
|
13970
13976
|
// Implementation
|
|
13971
13977
|
async createMessage(e, n) {
|
|
@@ -14002,12 +14008,12 @@ class Av extends my {
|
|
|
14002
14008
|
if (!(!((i = (s = this._clientCapabilities) === null || s === void 0 ? void 0 : s.elicitation) === null || i === void 0) && i.url))
|
|
14003
14009
|
throw new Error("Client does not support url elicitation.");
|
|
14004
14010
|
const l = e;
|
|
14005
|
-
return this.request({ method: "elicitation/create", params: l },
|
|
14011
|
+
return this.request({ method: "elicitation/create", params: l }, ii, n);
|
|
14006
14012
|
}
|
|
14007
14013
|
case "form": {
|
|
14008
14014
|
if (!(!((o = (a = this._clientCapabilities) === null || a === void 0 ? void 0 : a.elicitation) === null || o === void 0) && o.form))
|
|
14009
14015
|
throw new Error("Client does not support form elicitation.");
|
|
14010
|
-
const l = e.mode === "form" ? e : { ...e, mode: "form" }, d = await this.request({ method: "elicitation/create", params: l },
|
|
14016
|
+
const l = e.mode === "form" ? e : { ...e, mode: "form" }, d = await this.request({ method: "elicitation/create", params: l }, ii, n);
|
|
14011
14017
|
if (d.action === "accept" && d.content && l.requestedSchema)
|
|
14012
14018
|
try {
|
|
14013
14019
|
const S = this._jsonSchemaValidator.getValidator(l.requestedSchema)(d.content);
|
|
@@ -14079,10 +14085,10 @@ function zv(t) {
|
|
|
14079
14085
|
const e = t[zu];
|
|
14080
14086
|
return e?.complete;
|
|
14081
14087
|
}
|
|
14082
|
-
var
|
|
14088
|
+
var cc;
|
|
14083
14089
|
(function(t) {
|
|
14084
14090
|
t.Completable = "McpCompletable";
|
|
14085
|
-
})(
|
|
14091
|
+
})(cc || (cc = {}));
|
|
14086
14092
|
const Mv = /^[A-Za-z0-9._-]{1,128}$/;
|
|
14087
14093
|
function Zv(t) {
|
|
14088
14094
|
const e = [];
|
|
@@ -14116,7 +14122,7 @@ function Dv(t, e) {
|
|
|
14116
14122
|
console.warn("Tool registration will proceed, but this may cause compatibility issues."), console.warn("Consider updating the tool name to conform to the MCP tool naming standard."), console.warn("See SEP: Specify Format for Tool Names (https://github.com/modelcontextprotocol/modelcontextprotocol/issues/986) for more details.");
|
|
14117
14123
|
}
|
|
14118
14124
|
}
|
|
14119
|
-
function
|
|
14125
|
+
function uc(t) {
|
|
14120
14126
|
const e = Zv(t);
|
|
14121
14127
|
return Dv(t, e.warnings), e.isValid;
|
|
14122
14128
|
}
|
|
@@ -14162,11 +14168,11 @@ class Lv {
|
|
|
14162
14168
|
await this.server.close();
|
|
14163
14169
|
}
|
|
14164
14170
|
setToolRequestHandlers() {
|
|
14165
|
-
this._toolHandlersInitialized || (this.server.assertCanSetRequestHandler(Pt(
|
|
14171
|
+
this._toolHandlersInitialized || (this.server.assertCanSetRequestHandler(Pt(si)), this.server.assertCanSetRequestHandler(Pt(Fr)), this.server.registerCapabilities({
|
|
14166
14172
|
tools: {
|
|
14167
14173
|
listChanged: !0
|
|
14168
14174
|
}
|
|
14169
|
-
}), this.server.setRequestHandler(
|
|
14175
|
+
}), this.server.setRequestHandler(si, () => ({
|
|
14170
14176
|
tools: Object.entries(this._registeredTools).filter(([, e]) => e.enabled).map(([e, n]) => {
|
|
14171
14177
|
const r = {
|
|
14172
14178
|
name: e,
|
|
@@ -14174,7 +14180,7 @@ class Lv {
|
|
|
14174
14180
|
description: n.description,
|
|
14175
14181
|
inputSchema: (() => {
|
|
14176
14182
|
const s = un(n.inputSchema);
|
|
14177
|
-
return s ?
|
|
14183
|
+
return s ? qa(s, {
|
|
14178
14184
|
strictUnions: !0,
|
|
14179
14185
|
pipeStrategy: "input"
|
|
14180
14186
|
}) : Vv;
|
|
@@ -14185,7 +14191,7 @@ class Lv {
|
|
|
14185
14191
|
};
|
|
14186
14192
|
if (n.outputSchema) {
|
|
14187
14193
|
const s = un(n.outputSchema);
|
|
14188
|
-
s && (r.outputSchema =
|
|
14194
|
+
s && (r.outputSchema = qa(s, {
|
|
14189
14195
|
strictUnions: !0,
|
|
14190
14196
|
pipeStrategy: "output"
|
|
14191
14197
|
}));
|
|
@@ -14308,9 +14314,9 @@ class Lv {
|
|
|
14308
14314
|
return await r.taskStore.getTaskResult(l);
|
|
14309
14315
|
}
|
|
14310
14316
|
setCompletionRequestHandler() {
|
|
14311
|
-
this._completionHandlerInitialized || (this.server.assertCanSetRequestHandler(Pt(
|
|
14317
|
+
this._completionHandlerInitialized || (this.server.assertCanSetRequestHandler(Pt(ai)), this.server.registerCapabilities({
|
|
14312
14318
|
completions: {}
|
|
14313
|
-
}), this.server.setRequestHandler(
|
|
14319
|
+
}), this.server.setRequestHandler(ai, async (e) => {
|
|
14314
14320
|
switch (e.params.ref.type) {
|
|
14315
14321
|
case "ref/prompt":
|
|
14316
14322
|
return kg(e), this.handlePromptCompletion(e, e.params.ref);
|
|
@@ -14336,7 +14342,7 @@ class Lv {
|
|
|
14336
14342
|
if (!a)
|
|
14337
14343
|
return pn;
|
|
14338
14344
|
const o = await a(e.params.argument.value, e.params.context);
|
|
14339
|
-
return
|
|
14345
|
+
return dc(o);
|
|
14340
14346
|
}
|
|
14341
14347
|
async handleResourceCompletion(e, n) {
|
|
14342
14348
|
const r = Object.values(this._registeredResourceTemplates).find((a) => a.resourceTemplate.uriTemplate.toString() === n.uri);
|
|
@@ -14349,14 +14355,14 @@ class Lv {
|
|
|
14349
14355
|
if (!s)
|
|
14350
14356
|
return pn;
|
|
14351
14357
|
const i = await s(e.params.argument.value, e.params.context);
|
|
14352
|
-
return
|
|
14358
|
+
return dc(i);
|
|
14353
14359
|
}
|
|
14354
14360
|
setResourceRequestHandlers() {
|
|
14355
|
-
this._resourceHandlersInitialized || (this.server.assertCanSetRequestHandler(Pt(
|
|
14361
|
+
this._resourceHandlersInitialized || (this.server.assertCanSetRequestHandler(Pt(Xs)), this.server.assertCanSetRequestHandler(Pt(ei)), this.server.assertCanSetRequestHandler(Pt(ti)), this.server.registerCapabilities({
|
|
14356
14362
|
resources: {
|
|
14357
14363
|
listChanged: !0
|
|
14358
14364
|
}
|
|
14359
|
-
}), this.server.setRequestHandler(
|
|
14365
|
+
}), this.server.setRequestHandler(Xs, async (e, n) => {
|
|
14360
14366
|
const r = Object.entries(this._registeredResources).filter(([i, a]) => a.enabled).map(([i, a]) => ({
|
|
14361
14367
|
uri: i,
|
|
14362
14368
|
name: a.name,
|
|
@@ -14374,11 +14380,11 @@ class Lv {
|
|
|
14374
14380
|
});
|
|
14375
14381
|
}
|
|
14376
14382
|
return { resources: [...r, ...s] };
|
|
14377
|
-
}), this.server.setRequestHandler(
|
|
14383
|
+
}), this.server.setRequestHandler(ei, async () => ({ resourceTemplates: Object.entries(this._registeredResourceTemplates).map(([n, r]) => ({
|
|
14378
14384
|
name: n,
|
|
14379
14385
|
uriTemplate: r.resourceTemplate.uriTemplate.toString(),
|
|
14380
14386
|
...r.metadata
|
|
14381
|
-
})) })), this.server.setRequestHandler(
|
|
14387
|
+
})) })), this.server.setRequestHandler(ti, async (e, n) => {
|
|
14382
14388
|
const r = new URL(e.params.uri), s = this._registeredResources[r.toString()];
|
|
14383
14389
|
if (s) {
|
|
14384
14390
|
if (!s.enabled)
|
|
@@ -14394,18 +14400,18 @@ class Lv {
|
|
|
14394
14400
|
}), this.setCompletionRequestHandler(), this._resourceHandlersInitialized = !0);
|
|
14395
14401
|
}
|
|
14396
14402
|
setPromptRequestHandlers() {
|
|
14397
|
-
this._promptHandlersInitialized || (this.server.assertCanSetRequestHandler(Pt(
|
|
14403
|
+
this._promptHandlersInitialized || (this.server.assertCanSetRequestHandler(Pt(ni)), this.server.assertCanSetRequestHandler(Pt(ri)), this.server.registerCapabilities({
|
|
14398
14404
|
prompts: {
|
|
14399
14405
|
listChanged: !0
|
|
14400
14406
|
}
|
|
14401
|
-
}), this.server.setRequestHandler(
|
|
14407
|
+
}), this.server.setRequestHandler(ni, () => ({
|
|
14402
14408
|
prompts: Object.entries(this._registeredPrompts).filter(([, e]) => e.enabled).map(([e, n]) => ({
|
|
14403
14409
|
name: e,
|
|
14404
14410
|
title: n.title,
|
|
14405
14411
|
description: n.description,
|
|
14406
14412
|
arguments: n.argsSchema ? Uv(n.argsSchema) : void 0
|
|
14407
14413
|
}))
|
|
14408
|
-
})), this.server.setRequestHandler(
|
|
14414
|
+
})), this.server.setRequestHandler(ri, async (e, n) => {
|
|
14409
14415
|
const r = this._registeredPrompts[e.params.name];
|
|
14410
14416
|
if (!r)
|
|
14411
14417
|
throw new ne(re.InvalidParams, `Prompt ${e.params.name} not found`);
|
|
@@ -14503,12 +14509,12 @@ class Lv {
|
|
|
14503
14509
|
return this._registeredPrompts[e] = a, a;
|
|
14504
14510
|
}
|
|
14505
14511
|
_createRegisteredTool(e, n, r, s, i, a, o, c, l) {
|
|
14506
|
-
|
|
14512
|
+
uc(e);
|
|
14507
14513
|
const d = {
|
|
14508
14514
|
title: n,
|
|
14509
14515
|
description: r,
|
|
14510
|
-
inputSchema:
|
|
14511
|
-
outputSchema:
|
|
14516
|
+
inputSchema: lc(s),
|
|
14517
|
+
outputSchema: lc(i),
|
|
14512
14518
|
annotations: a,
|
|
14513
14519
|
execution: o,
|
|
14514
14520
|
_meta: c,
|
|
@@ -14518,7 +14524,7 @@ class Lv {
|
|
|
14518
14524
|
enable: () => d.update({ enabled: !0 }),
|
|
14519
14525
|
remove: () => d.update({ name: null }),
|
|
14520
14526
|
update: (h) => {
|
|
14521
|
-
typeof h.name < "u" && h.name !== e && (typeof h.name == "string" &&
|
|
14527
|
+
typeof h.name < "u" && h.name !== e && (typeof h.name == "string" && uc(h.name), delete this._registeredTools[e], h.name && (this._registeredTools[h.name] = d)), typeof h.title < "u" && (d.title = h.title), typeof h.description < "u" && (d.description = h.description), typeof h.paramsSchema < "u" && (d.inputSchema = _n(h.paramsSchema)), typeof h.callback < "u" && (d.handler = h.callback), typeof h.annotations < "u" && (d.annotations = h.annotations), typeof h._meta < "u" && (d._meta = h._meta), typeof h.enabled < "u" && (d.enabled = h.enabled), this.sendToolListChanged();
|
|
14522
14528
|
}
|
|
14523
14529
|
};
|
|
14524
14530
|
return this._registeredTools[e] = d, this.setToolRequestHandlers(), this.sendToolListChanged(), d;
|
|
@@ -14532,7 +14538,7 @@ class Lv {
|
|
|
14532
14538
|
let r, s, i, a;
|
|
14533
14539
|
if (typeof n[0] == "string" && (r = n.shift()), n.length > 1) {
|
|
14534
14540
|
const c = n[0];
|
|
14535
|
-
|
|
14541
|
+
oi(c) ? (s = n.shift(), n.length > 1 && typeof n[0] == "object" && n[0] !== null && !oi(n[0]) && (a = n.shift())) : typeof c == "object" && c !== null && (a = n.shift());
|
|
14536
14542
|
}
|
|
14537
14543
|
const o = n[0];
|
|
14538
14544
|
return this._createRegisteredTool(e, void 0, r, s, i, a, { taskSupport: "forbidden" }, void 0, o);
|
|
@@ -14611,12 +14617,12 @@ function Mu(t) {
|
|
|
14611
14617
|
function Fv(t) {
|
|
14612
14618
|
return "_def" in t || "_zod" in t || Mu(t);
|
|
14613
14619
|
}
|
|
14614
|
-
function
|
|
14620
|
+
function oi(t) {
|
|
14615
14621
|
return typeof t != "object" || t === null || Fv(t) ? !1 : Object.keys(t).length === 0 ? !0 : Object.values(t).some(Mu);
|
|
14616
14622
|
}
|
|
14617
|
-
function
|
|
14623
|
+
function lc(t) {
|
|
14618
14624
|
if (t)
|
|
14619
|
-
return
|
|
14625
|
+
return oi(t) ? _n(t) : t;
|
|
14620
14626
|
}
|
|
14621
14627
|
function Uv(t) {
|
|
14622
14628
|
const e = An(t);
|
|
@@ -14638,7 +14644,7 @@ function Pt(t) {
|
|
|
14638
14644
|
return r;
|
|
14639
14645
|
throw new Error("Schema method literal must be a string");
|
|
14640
14646
|
}
|
|
14641
|
-
function
|
|
14647
|
+
function dc(t) {
|
|
14642
14648
|
return {
|
|
14643
14649
|
completion: {
|
|
14644
14650
|
values: t.slice(0, 100),
|
|
@@ -14653,7 +14659,7 @@ const pn = {
|
|
|
14653
14659
|
hasMore: !1
|
|
14654
14660
|
}
|
|
14655
14661
|
};
|
|
14656
|
-
class
|
|
14662
|
+
class Fi {
|
|
14657
14663
|
dataSource = null;
|
|
14658
14664
|
config;
|
|
14659
14665
|
lastFetch = 0;
|
|
@@ -14806,12 +14812,12 @@ class Vi {
|
|
|
14806
14812
|
};
|
|
14807
14813
|
}
|
|
14808
14814
|
}
|
|
14809
|
-
const ls = "-", ot = "- ", Zu = ",", dt = ":",
|
|
14810
|
-
`,
|
|
14815
|
+
const ls = "-", ot = "- ", Zu = ",", dt = ":", fc = " ", Du = "|", Gr = ".", Or = "[", Hv = "]", Kv = "{", pc = "}", Ui = "null", qu = "true", Lu = "false", Qe = "\\", Ve = '"', Wv = `
|
|
14816
|
+
`, Bv = "\r", En = " ", ci = {
|
|
14811
14817
|
comma: Zu,
|
|
14812
14818
|
tab: En,
|
|
14813
14819
|
pipe: Du
|
|
14814
|
-
}, Tt =
|
|
14820
|
+
}, Tt = ci.comma;
|
|
14815
14821
|
function Vu(t) {
|
|
14816
14822
|
return t.replace(/\\/g, `${Qe}${Qe}`).replace(/"/g, `${Qe}${Ve}`).replace(/\n/g, `${Qe}n`).replace(/\r/g, `${Qe}r`).replace(/\t/g, `${Qe}t`);
|
|
14817
14823
|
}
|
|
@@ -14830,7 +14836,7 @@ function Fu(t) {
|
|
|
14830
14836
|
continue;
|
|
14831
14837
|
}
|
|
14832
14838
|
if (r === "r") {
|
|
14833
|
-
e +=
|
|
14839
|
+
e += Bv, n += 2;
|
|
14834
14840
|
continue;
|
|
14835
14841
|
}
|
|
14836
14842
|
if (r === Qe) {
|
|
@@ -14876,9 +14882,9 @@ function Uu(t, e, n = 0) {
|
|
|
14876
14882
|
return -1;
|
|
14877
14883
|
}
|
|
14878
14884
|
function Hu(t) {
|
|
14879
|
-
return t === qu || t === Lu || t ===
|
|
14885
|
+
return t === qu || t === Lu || t === Ui;
|
|
14880
14886
|
}
|
|
14881
|
-
function
|
|
14887
|
+
function Gv(t) {
|
|
14882
14888
|
if (!t || t.length > 1 && t[0] === "0" && t[1] !== ".") return !1;
|
|
14883
14889
|
const e = Number(t);
|
|
14884
14890
|
return !Number.isNaN(e) && Number.isFinite(e);
|
|
@@ -14898,14 +14904,14 @@ function Jr(t, e) {
|
|
|
14898
14904
|
let i = s + 1, a = i;
|
|
14899
14905
|
const o = t.indexOf(Kv, s);
|
|
14900
14906
|
if (o !== -1 && o < t.indexOf(dt, s)) {
|
|
14901
|
-
const y = t.indexOf(
|
|
14907
|
+
const y = t.indexOf(pc, o);
|
|
14902
14908
|
y !== -1 && (a = y + 1);
|
|
14903
14909
|
}
|
|
14904
14910
|
if (i = t.indexOf(dt, Math.max(s, a)), i === -1) return;
|
|
14905
14911
|
let c;
|
|
14906
14912
|
if (r > 0) {
|
|
14907
14913
|
const y = t.slice(0, r).trim();
|
|
14908
|
-
c = y.startsWith(Ve) ?
|
|
14914
|
+
c = y.startsWith(Ve) ? ui(y) : y;
|
|
14909
14915
|
}
|
|
14910
14916
|
const l = t.slice(i + 1).trim(), d = t.slice(r + 1, s);
|
|
14911
14917
|
let h;
|
|
@@ -14917,8 +14923,8 @@ function Jr(t, e) {
|
|
|
14917
14923
|
const { length: S, delimiter: b } = h;
|
|
14918
14924
|
let v;
|
|
14919
14925
|
if (o !== -1 && o < i) {
|
|
14920
|
-
const y = t.indexOf(
|
|
14921
|
-
y !== -1 && y < i && (v =
|
|
14926
|
+
const y = t.indexOf(pc, o);
|
|
14927
|
+
y !== -1 && y < i && (v = Hi(t.slice(o + 1, y), b).map((f) => ui(f.trim())));
|
|
14922
14928
|
}
|
|
14923
14929
|
return {
|
|
14924
14930
|
header: {
|
|
@@ -14932,7 +14938,7 @@ function Jr(t, e) {
|
|
|
14932
14938
|
}
|
|
14933
14939
|
function Jv(t, e) {
|
|
14934
14940
|
let n = t, r = e;
|
|
14935
|
-
n.endsWith(En) ? (r =
|
|
14941
|
+
n.endsWith(En) ? (r = ci.tab, n = n.slice(0, -1)) : n.endsWith(Du) && (r = ci.pipe, n = n.slice(0, -1));
|
|
14936
14942
|
const s = Number.parseInt(n, 10);
|
|
14937
14943
|
if (Number.isNaN(s)) throw new TypeError(`Invalid array length: ${t}`);
|
|
14938
14944
|
return {
|
|
@@ -14940,7 +14946,7 @@ function Jv(t, e) {
|
|
|
14940
14946
|
delimiter: r
|
|
14941
14947
|
};
|
|
14942
14948
|
}
|
|
14943
|
-
function
|
|
14949
|
+
function Hi(t, e) {
|
|
14944
14950
|
const n = [];
|
|
14945
14951
|
let r = "", s = !1, i = 0;
|
|
14946
14952
|
for (; i < t.length; ) {
|
|
@@ -14967,19 +14973,19 @@ function Ku(t) {
|
|
|
14967
14973
|
function fs(t) {
|
|
14968
14974
|
const e = t.trim();
|
|
14969
14975
|
if (!e) return "";
|
|
14970
|
-
if (e.startsWith(Ve)) return
|
|
14976
|
+
if (e.startsWith(Ve)) return ui(e);
|
|
14971
14977
|
if (Hu(e)) {
|
|
14972
14978
|
if (e === qu) return !0;
|
|
14973
14979
|
if (e === Lu) return !1;
|
|
14974
|
-
if (e ===
|
|
14980
|
+
if (e === Ui) return null;
|
|
14975
14981
|
}
|
|
14976
|
-
if (
|
|
14982
|
+
if (Gv(e)) {
|
|
14977
14983
|
const n = Number.parseFloat(e);
|
|
14978
14984
|
return Object.is(n, -0) ? 0 : n;
|
|
14979
14985
|
}
|
|
14980
14986
|
return e;
|
|
14981
14987
|
}
|
|
14982
|
-
function
|
|
14988
|
+
function ui(t) {
|
|
14983
14989
|
const e = t.trim();
|
|
14984
14990
|
if (e.startsWith(Ve)) {
|
|
14985
14991
|
const n = ds(e, 0);
|
|
@@ -15033,10 +15039,10 @@ function n_(t, e, n, r) {
|
|
|
15033
15039
|
e.lineNumber++;
|
|
15034
15040
|
const s = e.lineNumber;
|
|
15035
15041
|
let i = 0;
|
|
15036
|
-
for (; i < t.length && t[i] ===
|
|
15042
|
+
for (; i < t.length && t[i] === fc; ) i++;
|
|
15037
15043
|
const a = t.slice(i);
|
|
15038
15044
|
if (!a.trim()) {
|
|
15039
|
-
const c =
|
|
15045
|
+
const c = hc(i, n);
|
|
15040
15046
|
e.blankLines.push({
|
|
15041
15047
|
lineNumber: s,
|
|
15042
15048
|
indent: i,
|
|
@@ -15044,10 +15050,10 @@ function n_(t, e, n, r) {
|
|
|
15044
15050
|
});
|
|
15045
15051
|
return;
|
|
15046
15052
|
}
|
|
15047
|
-
const o =
|
|
15053
|
+
const o = hc(i, n);
|
|
15048
15054
|
{
|
|
15049
15055
|
let c = 0;
|
|
15050
|
-
for (; c < t.length && (t[c] ===
|
|
15056
|
+
for (; c < t.length && (t[c] === fc || t[c] === En); ) c++;
|
|
15051
15057
|
if (t.slice(0, c).includes(En)) throw new SyntaxError(`Line ${s}: Tabs are not allowed in indentation in strict mode`);
|
|
15052
15058
|
if (i > 0 && i % n !== 0) throw new SyntaxError(`Line ${s}: Indentation must be exact multiple of ${n}, but found ${i} spaces`);
|
|
15053
15059
|
}
|
|
@@ -15065,7 +15071,7 @@ function* r_(t, e, n, r) {
|
|
|
15065
15071
|
i !== void 0 && (yield i);
|
|
15066
15072
|
}
|
|
15067
15073
|
}
|
|
15068
|
-
function
|
|
15074
|
+
function hc(t, e) {
|
|
15069
15075
|
return Math.floor(t / e);
|
|
15070
15076
|
}
|
|
15071
15077
|
function Pn(t, e, n, r) {
|
|
@@ -15077,7 +15083,7 @@ function s_(t, e, n) {
|
|
|
15077
15083
|
function i_(t, e, n) {
|
|
15078
15084
|
if (t?.depth === e && !t.content.startsWith(ot) && a_(t.content, n.delimiter)) throw new RangeError(`Expected ${n.length} tabular rows, but found more`);
|
|
15079
15085
|
}
|
|
15080
|
-
function
|
|
15086
|
+
function Bu(t, e, n, r, s) {
|
|
15081
15087
|
if (!r) return;
|
|
15082
15088
|
const i = n.find((a) => a.lineNumber > t && a.lineNumber < e);
|
|
15083
15089
|
if (i) throw new SyntaxError(`Line ${i.lineNumber}: Blank lines inside ${s} are not allowed in strict mode`);
|
|
@@ -15233,7 +15239,7 @@ function* l_(t, e, n) {
|
|
|
15233
15239
|
Pn(0, t.length, "inline array items", n);
|
|
15234
15240
|
return;
|
|
15235
15241
|
}
|
|
15236
|
-
const r = Ku(
|
|
15242
|
+
const r = Ku(Hi(e, t.delimiter));
|
|
15237
15243
|
Pn(r.length, t.length, "inline array items", n);
|
|
15238
15244
|
for (const s of r) yield {
|
|
15239
15245
|
type: "primitive",
|
|
@@ -15248,13 +15254,13 @@ function* d_(t, e, n, r) {
|
|
|
15248
15254
|
if (!c || c.depth < s) break;
|
|
15249
15255
|
if (c.depth === s) {
|
|
15250
15256
|
a === void 0 && (a = c.lineNumber), o = c.lineNumber, e.advanceSync();
|
|
15251
|
-
const l =
|
|
15257
|
+
const l = Hi(c.content, t.delimiter);
|
|
15252
15258
|
Pn(l.length, t.fields.length, "tabular row values", r);
|
|
15253
15259
|
const d = Ku(l);
|
|
15254
15260
|
yield* m_(t.fields, d), i++;
|
|
15255
15261
|
} else break;
|
|
15256
15262
|
}
|
|
15257
|
-
Pn(i, t.length, "tabular rows", r), r.strict && a !== void 0 && o !== void 0 &&
|
|
15263
|
+
Pn(i, t.length, "tabular rows", r), r.strict && a !== void 0 && o !== void 0 && Bu(a, o, e.getBlankLines(), r.strict, "tabular array"), r.strict && i_(e.peekSync(), s, t);
|
|
15258
15264
|
}
|
|
15259
15265
|
function* f_(t, e, n, r) {
|
|
15260
15266
|
const s = n + 1;
|
|
@@ -15269,7 +15275,7 @@ function* f_(t, e, n, r) {
|
|
|
15269
15275
|
d && (o = d.lineNumber), i++;
|
|
15270
15276
|
} else break;
|
|
15271
15277
|
}
|
|
15272
|
-
Pn(i, t.length, "list array items", r), r.strict && a !== void 0 && o !== void 0 &&
|
|
15278
|
+
Pn(i, t.length, "list array items", r), r.strict && a !== void 0 && o !== void 0 && Bu(a, o, e.getBlankLines(), r.strict, "list array"), r.strict && s_(e.peekSync(), s, t.length);
|
|
15273
15279
|
}
|
|
15274
15280
|
function* p_(t, e, n) {
|
|
15275
15281
|
const r = t.nextSync();
|
|
@@ -15408,7 +15414,7 @@ function In(t) {
|
|
|
15408
15414
|
function y_(t) {
|
|
15409
15415
|
return t.length === 0 || t.every((e) => jt(e));
|
|
15410
15416
|
}
|
|
15411
|
-
function
|
|
15417
|
+
function Gu(t) {
|
|
15412
15418
|
return t.length === 0 || t.every((e) => ct(e));
|
|
15413
15419
|
}
|
|
15414
15420
|
function v_(t) {
|
|
@@ -15522,7 +15528,7 @@ function E_(t, e, n, r, s, i, a) {
|
|
|
15522
15528
|
if (r.keyFolding !== "safe" || !ct(e)) return;
|
|
15523
15529
|
const { segments: o, tail: c, leafValue: l } = P_(t, e, a ?? r.flattenDepth);
|
|
15524
15530
|
if (o.length < 2 || !o.every((S) => __(S))) return;
|
|
15525
|
-
const d = R_(o), h = i ? `${i}${
|
|
15531
|
+
const d = R_(o), h = i ? `${i}${Gr}${d}` : d;
|
|
15526
15532
|
if (!n.includes(d) && !(s && s.has(h)))
|
|
15527
15533
|
return {
|
|
15528
15534
|
foldedKey: d,
|
|
@@ -15551,10 +15557,10 @@ function P_(t, e, n) {
|
|
|
15551
15557
|
};
|
|
15552
15558
|
}
|
|
15553
15559
|
function R_(t) {
|
|
15554
|
-
return t.join(
|
|
15560
|
+
return t.join(Gr);
|
|
15555
15561
|
}
|
|
15556
15562
|
function sn(t, e) {
|
|
15557
|
-
return t === null ?
|
|
15563
|
+
return t === null ? Ui : typeof t == "boolean" || typeof t == "number" ? String(t) : I_(t, e);
|
|
15558
15564
|
}
|
|
15559
15565
|
function I_(t, e = Tt) {
|
|
15560
15566
|
return b_(t, e) ? t : `${Ve}${Vu(t)}${Ve}`;
|
|
@@ -15580,7 +15586,7 @@ function* C_(t, e, n) {
|
|
|
15580
15586
|
r !== "" && (yield r);
|
|
15581
15587
|
return;
|
|
15582
15588
|
}
|
|
15583
|
-
jt(t) ? yield*
|
|
15589
|
+
jt(t) ? yield* li(void 0, t, n, e) : ct(t) && (yield* Qt(t, n, e));
|
|
15584
15590
|
}
|
|
15585
15591
|
function* Qt(t, e, n, r, s, i) {
|
|
15586
15592
|
const a = Object.keys(t);
|
|
@@ -15589,59 +15595,59 @@ function* Qt(t, e, n, r, s, i) {
|
|
|
15589
15595
|
for (const [c, l] of Object.entries(t)) yield* O_(c, l, e, n, a, r, s, o);
|
|
15590
15596
|
}
|
|
15591
15597
|
function* O_(t, e, n, r, s, i, a, o) {
|
|
15592
|
-
const c = a ? `${a}${
|
|
15598
|
+
const c = a ? `${a}${Gr}${t}` : t, l = o ?? r.flattenDepth;
|
|
15593
15599
|
if (r.keyFolding === "safe" && s) {
|
|
15594
15600
|
const h = E_(t, e, s, r, i, a, l);
|
|
15595
15601
|
if (h) {
|
|
15596
15602
|
const { foldedKey: S, remainder: b, leafValue: v, segmentCount: y } = h, f = Cn(S);
|
|
15597
15603
|
if (b === void 0) {
|
|
15598
15604
|
if (Ht(v)) {
|
|
15599
|
-
yield
|
|
15605
|
+
yield Ge(n, `${f}: ${sn(v, r.delimiter)}`, r.indent);
|
|
15600
15606
|
return;
|
|
15601
15607
|
} else if (jt(v)) {
|
|
15602
|
-
yield*
|
|
15608
|
+
yield* li(S, v, n, r);
|
|
15603
15609
|
return;
|
|
15604
15610
|
} else if (ct(v) && Rn(v)) {
|
|
15605
|
-
yield
|
|
15611
|
+
yield Ge(n, `${f}:`, r.indent);
|
|
15606
15612
|
return;
|
|
15607
15613
|
}
|
|
15608
15614
|
}
|
|
15609
15615
|
if (ct(b)) {
|
|
15610
|
-
yield
|
|
15611
|
-
const m = l - y, u = a ? `${a}${
|
|
15616
|
+
yield Ge(n, `${f}:`, r.indent);
|
|
15617
|
+
const m = l - y, u = a ? `${a}${Gr}${S}` : S;
|
|
15612
15618
|
yield* Qt(b, n + 1, r, i, u, m);
|
|
15613
15619
|
return;
|
|
15614
15620
|
}
|
|
15615
15621
|
}
|
|
15616
15622
|
}
|
|
15617
15623
|
const d = Cn(t);
|
|
15618
|
-
Ht(e) ? yield
|
|
15624
|
+
Ht(e) ? yield Ge(n, `${d}: ${sn(e, r.delimiter)}`, r.indent) : jt(e) ? yield* li(t, e, n, r) : ct(e) && (yield Ge(n, `${d}:`, r.indent), Rn(e) || (yield* Qt(e, n + 1, r, i, c, l)));
|
|
15619
15625
|
}
|
|
15620
|
-
function*
|
|
15626
|
+
function* li(t, e, n, r) {
|
|
15621
15627
|
if (e.length === 0) {
|
|
15622
|
-
yield
|
|
15628
|
+
yield Ge(n, kt(0, {
|
|
15623
15629
|
key: t,
|
|
15624
15630
|
delimiter: r.delimiter
|
|
15625
15631
|
}), r.indent);
|
|
15626
15632
|
return;
|
|
15627
15633
|
}
|
|
15628
15634
|
if (In(e)) {
|
|
15629
|
-
yield
|
|
15635
|
+
yield Ge(n, ps(e, r.delimiter, t), r.indent);
|
|
15630
15636
|
return;
|
|
15631
15637
|
}
|
|
15632
15638
|
if (y_(e) && e.every((s) => In(s))) {
|
|
15633
15639
|
yield* N_(t, e, n, r);
|
|
15634
15640
|
return;
|
|
15635
15641
|
}
|
|
15636
|
-
if (
|
|
15642
|
+
if (Gu(e)) {
|
|
15637
15643
|
const s = Yu(e);
|
|
15638
|
-
s ? yield* x_(t, e, s, n, r) : yield*
|
|
15644
|
+
s ? yield* x_(t, e, s, n, r) : yield* mc(t, e, n, r);
|
|
15639
15645
|
return;
|
|
15640
15646
|
}
|
|
15641
|
-
yield*
|
|
15647
|
+
yield* mc(t, e, n, r);
|
|
15642
15648
|
}
|
|
15643
15649
|
function* N_(t, e, n, r) {
|
|
15644
|
-
yield
|
|
15650
|
+
yield Ge(n, kt(e.length, {
|
|
15645
15651
|
key: t,
|
|
15646
15652
|
delimiter: r.delimiter
|
|
15647
15653
|
}), r.indent);
|
|
@@ -15658,7 +15664,7 @@ function ps(t, e, n) {
|
|
|
15658
15664
|
return t.length === 0 ? r : `${r} ${s}`;
|
|
15659
15665
|
}
|
|
15660
15666
|
function* x_(t, e, n, r, s) {
|
|
15661
|
-
yield
|
|
15667
|
+
yield Ge(r, kt(e.length, {
|
|
15662
15668
|
key: t,
|
|
15663
15669
|
fields: n,
|
|
15664
15670
|
delimiter: s.delimiter
|
|
@@ -15679,22 +15685,22 @@ function A_(t, e) {
|
|
|
15679
15685
|
return !0;
|
|
15680
15686
|
}
|
|
15681
15687
|
function* Qu(t, e, n, r) {
|
|
15682
|
-
for (const s of t) yield
|
|
15688
|
+
for (const s of t) yield Ge(n, Ju(e.map((i) => s[i]), r.delimiter), r.indent);
|
|
15683
15689
|
}
|
|
15684
|
-
function*
|
|
15685
|
-
yield
|
|
15690
|
+
function* mc(t, e, n, r) {
|
|
15691
|
+
yield Ge(n, kt(e.length, {
|
|
15686
15692
|
key: t,
|
|
15687
15693
|
delimiter: r.delimiter
|
|
15688
15694
|
}), r.indent);
|
|
15689
|
-
for (const s of e) yield*
|
|
15695
|
+
for (const s of e) yield* Ki(s, n + 1, r);
|
|
15690
15696
|
}
|
|
15691
15697
|
function* j_(t, e, n) {
|
|
15692
15698
|
if (Rn(t)) {
|
|
15693
|
-
yield
|
|
15699
|
+
yield Ge(e, ls, n.indent);
|
|
15694
15700
|
return;
|
|
15695
15701
|
}
|
|
15696
15702
|
const r = Object.entries(t), [s, i] = r[0], a = r.slice(1);
|
|
15697
|
-
if (jt(i) &&
|
|
15703
|
+
if (jt(i) && Gu(i)) {
|
|
15698
15704
|
const c = Yu(i);
|
|
15699
15705
|
if (c) {
|
|
15700
15706
|
yield ht(e, kt(i.length, {
|
|
@@ -15711,25 +15717,25 @@ function* j_(t, e, n) {
|
|
|
15711
15717
|
else if (In(i)) yield ht(e, `${o}${ps(i, n.delimiter)}`, n.indent);
|
|
15712
15718
|
else {
|
|
15713
15719
|
yield ht(e, `${o}${kt(i.length, { delimiter: n.delimiter })}`, n.indent);
|
|
15714
|
-
for (const c of i) yield*
|
|
15720
|
+
for (const c of i) yield* Ki(c, e + 2, n);
|
|
15715
15721
|
}
|
|
15716
15722
|
else ct(i) && (yield ht(e, `${o}:`, n.indent), Rn(i) || (yield* Qt(i, e + 2, n)));
|
|
15717
15723
|
a.length > 0 && (yield* Qt(Object.fromEntries(a), e + 1, n));
|
|
15718
15724
|
}
|
|
15719
|
-
function*
|
|
15725
|
+
function* Ki(t, e, n) {
|
|
15720
15726
|
if (Ht(t)) yield ht(e, sn(t, n.delimiter), n.indent);
|
|
15721
15727
|
else if (jt(t)) if (In(t)) yield ht(e, ps(t, n.delimiter), n.indent);
|
|
15722
15728
|
else {
|
|
15723
15729
|
yield ht(e, kt(t.length, { delimiter: n.delimiter }), n.indent);
|
|
15724
|
-
for (const r of t) yield*
|
|
15730
|
+
for (const r of t) yield* Ki(r, e + 1, n);
|
|
15725
15731
|
}
|
|
15726
15732
|
else ct(t) && (yield* j_(t, e, n));
|
|
15727
15733
|
}
|
|
15728
|
-
function
|
|
15734
|
+
function Ge(t, e, n) {
|
|
15729
15735
|
return " ".repeat(n * t) + e;
|
|
15730
15736
|
}
|
|
15731
15737
|
function ht(t, e, n) {
|
|
15732
|
-
return
|
|
15738
|
+
return Ge(t, ot + e, n);
|
|
15733
15739
|
}
|
|
15734
15740
|
function z_(t, e) {
|
|
15735
15741
|
const n = e("", t, []);
|
|
@@ -15975,7 +15981,7 @@ class Nr {
|
|
|
15975
15981
|
}
|
|
15976
15982
|
}
|
|
15977
15983
|
function U_(t, e) {
|
|
15978
|
-
const n = new
|
|
15984
|
+
const n = new Fi(e);
|
|
15979
15985
|
t.registerResource(
|
|
15980
15986
|
"Components List (TOON)",
|
|
15981
15987
|
"wangs://components/list",
|
|
@@ -16042,7 +16048,7 @@ function H_(t, e) {
|
|
|
16042
16048
|
U_(t, e);
|
|
16043
16049
|
}
|
|
16044
16050
|
function K_(t, e) {
|
|
16045
|
-
const n = new
|
|
16051
|
+
const n = new Fi(e);
|
|
16046
16052
|
t.registerTool(
|
|
16047
16053
|
"analyze_component",
|
|
16048
16054
|
{
|
|
@@ -16092,7 +16098,7 @@ resolve_type_definition({ types: ['${l.name}'], includeRelated: true })`
|
|
|
16092
16098
|
);
|
|
16093
16099
|
}
|
|
16094
16100
|
function W_(t, e) {
|
|
16095
|
-
const n = new
|
|
16101
|
+
const n = new Fi(e);
|
|
16096
16102
|
t.registerTool(
|
|
16097
16103
|
"list_all_components",
|
|
16098
16104
|
{
|
|
@@ -16173,8 +16179,8 @@ ${JSON.stringify(o, null, 2)}`
|
|
|
16173
16179
|
}
|
|
16174
16180
|
);
|
|
16175
16181
|
}
|
|
16176
|
-
const
|
|
16177
|
-
function
|
|
16182
|
+
const B_ = Xr(di(import.meta.url)), Ms = /* @__PURE__ */ new Map();
|
|
16183
|
+
function Wi(t, e = t) {
|
|
16178
16184
|
const n = `${t}:${e}`;
|
|
16179
16185
|
if (Ms.has(n))
|
|
16180
16186
|
return Ms.get(n);
|
|
@@ -16184,7 +16190,7 @@ function Ki(t, e = t) {
|
|
|
16184
16190
|
for (const i of s) {
|
|
16185
16191
|
const a = wn(t, i.name);
|
|
16186
16192
|
if (i.isDirectory())
|
|
16187
|
-
i.name !== "node_modules" && r.push(...
|
|
16193
|
+
i.name !== "node_modules" && r.push(...Wi(a, e));
|
|
16188
16194
|
else if (i.isFile() && i.name.endsWith(".d.ts")) {
|
|
16189
16195
|
const o = a.replace(e + "/", "").replace(e + "\\", "");
|
|
16190
16196
|
r.push(o);
|
|
@@ -16194,7 +16200,7 @@ function Ki(t, e = t) {
|
|
|
16194
16200
|
}
|
|
16195
16201
|
return Ms.set(n, r), r;
|
|
16196
16202
|
}
|
|
16197
|
-
function
|
|
16203
|
+
function G_(t) {
|
|
16198
16204
|
const e = /* @__PURE__ */ new Map(), n = [
|
|
16199
16205
|
// import { Type1, Type2 } from 'package'
|
|
16200
16206
|
/import\s*\{\s*([^}]+)\s*\}\s*from\s*['"]([^'"]+)['"]/g,
|
|
@@ -16260,7 +16266,7 @@ function Y_(t) {
|
|
|
16260
16266
|
return e;
|
|
16261
16267
|
}
|
|
16262
16268
|
function Q_(t, e) {
|
|
16263
|
-
const n = /* @__PURE__ */ new Set(), r = /* @__PURE__ */ new Set(), s =
|
|
16269
|
+
const n = /* @__PURE__ */ new Set(), r = /* @__PURE__ */ new Set(), s = G_(t), a = t.replace(/import\s+.*?from\s+['"][^'"]*['"];?\s*/g, "").replace(/\/\*\*[\s\S]*?\*\//g, "").replace(/\/\*[\s\S]*?\*\//g, "").replace(/\/\/.*$/gm, ""), o = [
|
|
16264
16270
|
// Type references: SomeType, SomeType<T>, SomeType[]
|
|
16265
16271
|
/\b([A-Z][a-zA-Z0-9_]*(?:<[^>]*>)?(?:\[\])?)/g,
|
|
16266
16272
|
// Interface/type properties: prop: SomeType
|
|
@@ -16328,11 +16334,11 @@ function Q_(t, e) {
|
|
|
16328
16334
|
return { referencedTypes: n, externalTypes: r };
|
|
16329
16335
|
}
|
|
16330
16336
|
const Rr = /* @__PURE__ */ new Map(), Jt = /* @__PURE__ */ new Map();
|
|
16331
|
-
function
|
|
16337
|
+
function Bi(t) {
|
|
16332
16338
|
if (Rr.has(t))
|
|
16333
16339
|
return Rr.get(t);
|
|
16334
16340
|
try {
|
|
16335
|
-
const e =
|
|
16341
|
+
const e = fi(t, "utf-8");
|
|
16336
16342
|
return Rr.set(t, e), e;
|
|
16337
16343
|
} catch {
|
|
16338
16344
|
return Rr.set(t, ""), null;
|
|
@@ -16345,9 +16351,9 @@ function X_(t, e) {
|
|
|
16345
16351
|
try {
|
|
16346
16352
|
if (!gc(e).isDirectory())
|
|
16347
16353
|
return Jt.set(n, !1), !1;
|
|
16348
|
-
const r =
|
|
16354
|
+
const r = Wi(e);
|
|
16349
16355
|
for (const s of r) {
|
|
16350
|
-
const i = wn(e, s), a =
|
|
16356
|
+
const i = wn(e, s), a = Bi(i);
|
|
16351
16357
|
if (!a) continue;
|
|
16352
16358
|
if ([
|
|
16353
16359
|
new RegExp(`\\btype\\s+${t}\\b`),
|
|
@@ -16369,7 +16375,7 @@ function e0(t) {
|
|
|
16369
16375
|
if (Zs.has(t))
|
|
16370
16376
|
return Zs.get(t);
|
|
16371
16377
|
try {
|
|
16372
|
-
const e =
|
|
16378
|
+
const e = Bi(t);
|
|
16373
16379
|
if (!e) return null;
|
|
16374
16380
|
const n = _t.createSourceFile(
|
|
16375
16381
|
t,
|
|
@@ -16440,7 +16446,7 @@ function t0(t, e) {
|
|
|
16440
16446
|
const i = e0(t);
|
|
16441
16447
|
if (!i)
|
|
16442
16448
|
return Ir.set(n, r), r;
|
|
16443
|
-
const a =
|
|
16449
|
+
const a = Bi(t);
|
|
16444
16450
|
s(i);
|
|
16445
16451
|
} catch {
|
|
16446
16452
|
}
|
|
@@ -16459,14 +16465,14 @@ function n0(t, e) {
|
|
|
16459
16465
|
async (n) => {
|
|
16460
16466
|
const { types: r, includeRelated: s = !0 } = n;
|
|
16461
16467
|
try {
|
|
16462
|
-
const i = tl(
|
|
16468
|
+
const i = tl(B_, "..");
|
|
16463
16469
|
let a = "packageName";
|
|
16464
16470
|
try {
|
|
16465
16471
|
const g = wn(i, "package.json");
|
|
16466
|
-
a = JSON.parse(
|
|
16472
|
+
a = JSON.parse(fi(g, "utf-8")).name || a;
|
|
16467
16473
|
} catch {
|
|
16468
16474
|
}
|
|
16469
|
-
const o = {}, c = /* @__PURE__ */ new Set(), l = [...r], d = /* @__PURE__ */ new Set(), h = /* @__PURE__ */ new Map(), S =
|
|
16475
|
+
const o = {}, c = /* @__PURE__ */ new Set(), l = [...r], d = /* @__PURE__ */ new Set(), h = /* @__PURE__ */ new Map(), S = Wi(i);
|
|
16470
16476
|
let b = 0;
|
|
16471
16477
|
const v = 100;
|
|
16472
16478
|
for (; l.length > 0 && b < v; ) {
|
|
@@ -17507,7 +17513,7 @@ function d0(t) {
|
|
|
17507
17513
|
`;
|
|
17508
17514
|
}
|
|
17509
17515
|
class f0 {
|
|
17510
|
-
constructor(e =
|
|
17516
|
+
constructor(e = Yi.stdin, n = Yi.stdout) {
|
|
17511
17517
|
this._stdin = e, this._stdout = n, this._readBuffer = new u0(), this._started = !1, this._ondata = (r) => {
|
|
17512
17518
|
this._readBuffer.append(r), this.processReadBuffer();
|
|
17513
17519
|
}, this._onerror = (r) => {
|
|
@@ -17564,19 +17570,22 @@ async function m0() {
|
|
|
17564
17570
|
console.error("Fatal error in runStdioServer():", t, { isError: !0 }), process.exit(1);
|
|
17565
17571
|
}
|
|
17566
17572
|
}
|
|
17567
|
-
const g0 =
|
|
17573
|
+
const g0 = di(import.meta.url);
|
|
17568
17574
|
Xr(g0);
|
|
17569
|
-
function
|
|
17575
|
+
function Ds() {
|
|
17570
17576
|
console.log(`
|
|
17571
17577
|
Usage: wangsvue-mcp <command> [arguments]
|
|
17572
17578
|
|
|
17573
17579
|
Commands:
|
|
17574
17580
|
run Start the MCP server with STDIO transport
|
|
17575
|
-
init-rules <editor> Fetch documentation and initialize rules for agentic editors
|
|
17581
|
+
init-rules <editor> [options] Fetch documentation and initialize rules for agentic editors
|
|
17576
17582
|
|
|
17577
17583
|
Arguments for init-rules:
|
|
17578
17584
|
editor Set agentic editor for metadata configuration (required)
|
|
17579
17585
|
|
|
17586
|
+
Options:
|
|
17587
|
+
--api-services Only initialize rules for API services documentation
|
|
17588
|
+
|
|
17580
17589
|
Available editors:
|
|
17581
17590
|
kiro - Kiro editor (inclusion: always, output: .kiro/steering/)
|
|
17582
17591
|
windsurf - Windsurf editor (trigger: always-on, output: .windsurf/rules/)
|
|
@@ -17591,46 +17600,28 @@ Examples:
|
|
|
17591
17600
|
wangsvue-mcp init-rules trae
|
|
17592
17601
|
wangsvue-mcp init-rules copilot
|
|
17593
17602
|
wangsvue-mcp init-rules default
|
|
17603
|
+
wangsvue-mcp init-rules kiro --api-services
|
|
17594
17604
|
`);
|
|
17595
17605
|
}
|
|
17596
17606
|
async function y0() {
|
|
17597
17607
|
const t = process.argv.slice(2);
|
|
17598
|
-
t.length === 0 && (
|
|
17608
|
+
t.length === 0 && (Ds(), process.exit(1));
|
|
17599
17609
|
const e = t[0];
|
|
17600
17610
|
switch (e) {
|
|
17601
17611
|
case "run":
|
|
17602
17612
|
await m0();
|
|
17603
17613
|
break;
|
|
17604
17614
|
case "init-rules":
|
|
17605
|
-
const n = t[1];
|
|
17606
|
-
n || (
|
|
17607
|
-
Usage: wangsvue-mcp init-rules <editor>
|
|
17608
|
-
|
|
17609
|
-
Arguments:
|
|
17610
|
-
editor Set agentic editor for metadata configuration (required)
|
|
17611
|
-
|
|
17612
|
-
Available editors:
|
|
17613
|
-
kiro - Kiro editor (inclusion: always, output: .kiro/steering/)
|
|
17614
|
-
windsurf - Windsurf editor (trigger: always-on, output: .windsurf/rules/)
|
|
17615
|
-
trae - Trae editor (alwaysApply: true, output: .trae/rules/)
|
|
17616
|
-
copilot - GitHub Copilot (meta: applyTo: **, output: .github/instructions/)
|
|
17617
|
-
default - Generic configuration (inclusion: always, output: docs/)
|
|
17618
|
-
|
|
17619
|
-
Examples:
|
|
17620
|
-
wangsvue-mcp init-rules kiro
|
|
17621
|
-
wangsvue-mcp init-rules windsurf
|
|
17622
|
-
wangsvue-mcp init-rules trae
|
|
17623
|
-
wangsvue-mcp init-rules copilot
|
|
17624
|
-
wangsvue-mcp init-rules default
|
|
17625
|
-
`), process.exit(1));
|
|
17615
|
+
const n = t[1], r = t.includes("--api-services");
|
|
17616
|
+
n || (Ds(), process.exit(1));
|
|
17626
17617
|
try {
|
|
17627
|
-
console.log("Initializing rules..."), await pl(n), console.log("Rules initialization completed successfully!"), process.exit(0);
|
|
17628
|
-
} catch (
|
|
17629
|
-
console.error("Failed to initialize rules:",
|
|
17618
|
+
console.log("Initializing rules..."), await pl(n, r), console.log("Rules initialization completed successfully!"), process.exit(0);
|
|
17619
|
+
} catch (s) {
|
|
17620
|
+
console.error("Failed to initialize rules:", s), process.exit(1);
|
|
17630
17621
|
}
|
|
17631
17622
|
break;
|
|
17632
17623
|
default:
|
|
17633
|
-
console.error(`Unknown command: ${e}`),
|
|
17624
|
+
console.error(`Unknown command: ${e}`), Ds(), process.exit(1);
|
|
17634
17625
|
}
|
|
17635
17626
|
}
|
|
17636
17627
|
y0();
|