@powerlines/deepkit 0.5.0 → 0.5.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/capnp.cjs +48 -47
- package/dist/capnp.js +3 -2
- package/dist/{chunk-TVDEXHJN.js → chunk-2ODODKQQ.js} +8 -9
- package/dist/{chunk-KYFUOGZ6.cjs → chunk-6QPIKQMO.cjs} +9 -10
- package/dist/chunk-7J3ZDT6O.cjs +30 -0
- package/dist/chunk-C7BRLIIA.js +187 -0
- package/dist/{chunk-55HOZO7D.cjs → chunk-EKHXI2JI.cjs} +5 -7
- package/dist/chunk-GRNJVY7I.cjs +19 -0
- package/dist/{chunk-DGXATHAN.js → chunk-I5CVIT7W.js} +41 -46
- package/dist/chunk-IRPJW6HH.js +16 -0
- package/dist/{chunk-SKYW5GV2.cjs → chunk-J2FVIV7W.cjs} +127 -132
- package/dist/chunk-J4SVRFV4.js +127 -0
- package/dist/{chunk-BTXPY3B4.js → chunk-LPLPOVLC.js} +2 -4
- package/dist/{chunk-FEBG7WWO.js → chunk-MEMIQ5AA.js} +1 -3
- package/dist/{chunk-U4JSDAXK.js → chunk-MNUBEEIW.js} +12 -7
- package/dist/chunk-ORA4UQMU.cjs +2 -0
- package/dist/chunk-OULCUN6I.js +1 -0
- package/dist/chunk-QABG54Y3.cjs +193 -0
- package/dist/chunk-QLKLDV3V.cjs +135 -0
- package/dist/{chunk-JHEBLHYK.cjs → chunk-VMRRVNO2.cjs} +2 -4
- package/dist/chunk-VXZTOOL6.cjs +69 -0
- package/dist/chunk-XGQQM64U.js +8 -0
- package/dist/esbuild-plugin.cjs +5 -5
- package/dist/esbuild-plugin.d.cts +3 -2
- package/dist/esbuild-plugin.d.ts +3 -2
- package/dist/esbuild-plugin.js +4 -4
- package/dist/index.cjs +69 -69
- package/dist/index.js +10 -12
- package/dist/reflect-type.cjs +7 -6
- package/dist/reflect-type.js +6 -5
- package/dist/resolve-reflections.cjs +3 -3
- package/dist/resolve-reflections.js +2 -2
- package/dist/transformer.cjs +4 -4
- package/dist/transformer.js +2 -2
- package/dist/transpile.cjs +4 -4
- package/dist/transpile.js +3 -3
- package/dist/types.cjs +1 -2
- package/dist/types.js +1 -2
- package/dist/utilities.cjs +10 -9
- package/dist/utilities.js +3 -2
- package/dist/vendor/chunk-IOMA7ABE.js +359 -0
- package/dist/vendor/chunk-K5KCTNDL.cjs +2678 -0
- package/dist/vendor/chunk-L3KIZV6P.js +2664 -0
- package/dist/vendor/chunk-M3FJ3QXG.cjs +377 -0
- package/dist/vendor/compiler.cjs +12 -13
- package/dist/vendor/compiler.js +2 -5
- package/dist/vendor/config.cjs +9 -10
- package/dist/vendor/config.js +1 -5
- package/dist/vendor/core.cjs +130 -130
- package/dist/vendor/core.js +2 -5
- package/dist/vendor/index.cjs +42 -22
- package/dist/vendor/index.d.cts +2 -0
- package/dist/vendor/index.d.ts +2 -0
- package/dist/vendor/index.js +4 -11
- package/dist/vendor/type-spec.cjs +5 -5
- package/dist/vendor/type-spec.js +2 -5
- package/dist/vendor/type.cjs +2269 -691
- package/dist/vendor/type.js +1607 -92
- package/package.json +5 -5
- package/dist/chunk-2V4ET57D.js +0 -6954
- package/dist/chunk-4WJJKR53.js +0 -3731
- package/dist/chunk-6ETLMANX.js +0 -3472
- package/dist/chunk-6IQVU53O.cjs +0 -24
- package/dist/chunk-6OXPIOZY.cjs +0 -43
- package/dist/chunk-7WAH4JD3.js +0 -115
- package/dist/chunk-B4PTD5KQ.js +0 -4
- package/dist/chunk-ITQKPDCW.cjs +0 -3859
- package/dist/chunk-LBHO5BRF.js +0 -2251
- package/dist/chunk-OYRIJX67.cjs +0 -3487
- package/dist/chunk-PANPZ6S6.cjs +0 -6
- package/dist/chunk-QPSZUUB6.cjs +0 -2259
- package/dist/chunk-QQ7GKXIS.js +0 -43
- package/dist/chunk-SA3DCC4M.cjs +0 -6968
- package/dist/chunk-WVKPC33H.cjs +0 -49
- package/dist/chunk-YKFG2BZQ.cjs +0 -115
- package/dist/chunk-YUO4MCOI.js +0 -18
- package/dist/vendor/chunk-MCNMRQDT.js +0 -3513
- package/dist/vendor/chunk-RH4YMONA.js +0 -7064
- package/dist/vendor/chunk-RZKB5IQZ.cjs +0 -3531
- package/dist/vendor/chunk-WOXMCJJU.cjs +0 -7078
- package/dist/vendor/type-compiler/compiler.cjs +0 -46
- package/dist/vendor/type-compiler/compiler.d.cts +0 -1
- package/dist/vendor/type-compiler/compiler.d.ts +0 -1
- package/dist/vendor/type-compiler/compiler.js +0 -7
- package/dist/vendor/type-compiler/config.cjs +0 -36
- package/dist/vendor/type-compiler/config.d.cts +0 -6
- package/dist/vendor/type-compiler/config.d.ts +0 -6
- package/dist/vendor/type-compiler/config.js +0 -5
- package/dist/vendor/type-compiler/index.cjs +0 -108
- package/dist/vendor/type-compiler/index.d.cts +0 -1
- package/dist/vendor/type-compiler/index.d.ts +0 -1
- package/dist/vendor/type-compiler/index.js +0 -67
package/dist/chunk-QPSZUUB6.cjs
DELETED
|
@@ -1,2259 +0,0 @@
|
|
|
1
|
-
'use strict';
|
|
2
|
-
|
|
3
|
-
var chunkWVKPC33H_cjs = require('./chunk-WVKPC33H.cjs');
|
|
4
|
-
var type = require('@powerlines/deepkit/vendor/type');
|
|
5
|
-
var buffer = require('buffer');
|
|
6
|
-
var isNull$1 = require('@stryke/type-checks/is-null');
|
|
7
|
-
var isString$1 = require('@stryke/type-checks/is-string');
|
|
8
|
-
var isUndefined$1 = require('@stryke/type-checks/is-undefined');
|
|
9
|
-
|
|
10
|
-
// src/utilities.ts
|
|
11
|
-
chunkWVKPC33H_cjs.init_cjs_shims();
|
|
12
|
-
|
|
13
|
-
// ../../node_modules/.pnpm/@stryke+helpers@0.9.31/node_modules/@stryke/helpers/dist/get-unique.mjs
|
|
14
|
-
chunkWVKPC33H_cjs.init_cjs_shims();
|
|
15
|
-
function t(e7, t7 = (e8) => e8) {
|
|
16
|
-
let n6 = /* @__PURE__ */ new Map();
|
|
17
|
-
for (let r5 of e7) {
|
|
18
|
-
let e8 = t7(r5);
|
|
19
|
-
n6.has(e8) || n6.set(e8, r5);
|
|
20
|
-
}
|
|
21
|
-
return [...n6.values()];
|
|
22
|
-
}
|
|
23
|
-
chunkWVKPC33H_cjs.__name(t, "t");
|
|
24
|
-
|
|
25
|
-
// ../../node_modules/.pnpm/@stryke+json@0.9.32/node_modules/@stryke/json/dist/storm-json.mjs
|
|
26
|
-
chunkWVKPC33H_cjs.init_cjs_shims();
|
|
27
|
-
|
|
28
|
-
// ../../node_modules/.pnpm/@stryke+json@0.9.32/node_modules/@stryke/json/dist/type-checks/src/is-object.mjs
|
|
29
|
-
chunkWVKPC33H_cjs.init_cjs_shims();
|
|
30
|
-
|
|
31
|
-
// ../../node_modules/.pnpm/@stryke+json@0.9.32/node_modules/@stryke/json/dist/type-checks/src/is-plain-object.mjs
|
|
32
|
-
chunkWVKPC33H_cjs.init_cjs_shims();
|
|
33
|
-
|
|
34
|
-
// ../../node_modules/.pnpm/@stryke+json@0.9.32/node_modules/@stryke/json/dist/type-checks/src/get-object-tag.mjs
|
|
35
|
-
chunkWVKPC33H_cjs.init_cjs_shims();
|
|
36
|
-
var e = /* @__PURE__ */ chunkWVKPC33H_cjs.__name((e7) => e7 == null ? e7 === void 0 ? `[object Undefined]` : `[object Null]` : Object.prototype.toString.call(e7), "e");
|
|
37
|
-
|
|
38
|
-
// ../../node_modules/.pnpm/@stryke+json@0.9.32/node_modules/@stryke/json/dist/type-checks/src/is-plain-object.mjs
|
|
39
|
-
var t2 = /* @__PURE__ */ chunkWVKPC33H_cjs.__name((e7) => typeof e7 == `object` && !!e7, "t");
|
|
40
|
-
var n = /* @__PURE__ */ chunkWVKPC33H_cjs.__name((n6) => {
|
|
41
|
-
if (!t2(n6) || e(n6) !== `[object Object]`) return false;
|
|
42
|
-
if (Object.getPrototypeOf(n6) === null) return true;
|
|
43
|
-
let r5 = n6;
|
|
44
|
-
for (; Object.getPrototypeOf(r5) !== null; ) r5 = Object.getPrototypeOf(r5);
|
|
45
|
-
return Object.getPrototypeOf(n6) === r5;
|
|
46
|
-
}, "n");
|
|
47
|
-
|
|
48
|
-
// ../../node_modules/.pnpm/@stryke+json@0.9.32/node_modules/@stryke/json/dist/type-checks/src/is-object.mjs
|
|
49
|
-
var t3 = /* @__PURE__ */ chunkWVKPC33H_cjs.__name((t7) => {
|
|
50
|
-
try {
|
|
51
|
-
return typeof t7 == `object` || !!t7 && t7?.constructor === Object || n(t7);
|
|
52
|
-
} catch {
|
|
53
|
-
return false;
|
|
54
|
-
}
|
|
55
|
-
}, "t");
|
|
56
|
-
|
|
57
|
-
// ../../node_modules/.pnpm/@stryke+json@0.9.32/node_modules/@stryke/json/dist/type-checks/src/is-string.mjs
|
|
58
|
-
chunkWVKPC33H_cjs.init_cjs_shims();
|
|
59
|
-
var e2 = /* @__PURE__ */ chunkWVKPC33H_cjs.__name((e7) => {
|
|
60
|
-
try {
|
|
61
|
-
return typeof e7 == `string`;
|
|
62
|
-
} catch {
|
|
63
|
-
return false;
|
|
64
|
-
}
|
|
65
|
-
}, "e");
|
|
66
|
-
|
|
67
|
-
// ../../node_modules/.pnpm/@stryke+json@0.9.32/node_modules/@stryke/json/dist/utils/parse.mjs
|
|
68
|
-
chunkWVKPC33H_cjs.init_cjs_shims();
|
|
69
|
-
|
|
70
|
-
// ../../node_modules/.pnpm/@stryke+json@0.9.32/node_modules/@stryke/json/dist/utils/strip-comments.mjs
|
|
71
|
-
chunkWVKPC33H_cjs.init_cjs_shims();
|
|
72
|
-
|
|
73
|
-
// ../../node_modules/.pnpm/@stryke+json@0.9.32/node_modules/@stryke/json/dist/types/src/base.mjs
|
|
74
|
-
chunkWVKPC33H_cjs.init_cjs_shims();
|
|
75
|
-
var e3 = ``;
|
|
76
|
-
|
|
77
|
-
// ../../node_modules/.pnpm/@stryke+json@0.9.32/node_modules/@stryke/json/dist/utils/strip-comments.mjs
|
|
78
|
-
var t4 = Symbol(`singleComment`);
|
|
79
|
-
var n2 = Symbol(`multiComment`);
|
|
80
|
-
function r() {
|
|
81
|
-
return ``;
|
|
82
|
-
}
|
|
83
|
-
chunkWVKPC33H_cjs.__name(r, "r");
|
|
84
|
-
function i(e7, t7, n6) {
|
|
85
|
-
return e7.slice(t7, n6).replace(/\S/g, ` `);
|
|
86
|
-
}
|
|
87
|
-
chunkWVKPC33H_cjs.__name(i, "i");
|
|
88
|
-
function a(e7, t7) {
|
|
89
|
-
let n6 = t7 - 1, r5 = 0;
|
|
90
|
-
for (; e7[n6] === `\\`; ) --n6, r5 += 1;
|
|
91
|
-
return !!(r5 % 2);
|
|
92
|
-
}
|
|
93
|
-
chunkWVKPC33H_cjs.__name(a, "a");
|
|
94
|
-
function o(o4, { whitespace: s = true, trailingCommas: c2 = false } = {}) {
|
|
95
|
-
if (typeof o4 != `string`) throw TypeError(`Expected argument \`jsonString\` to be a \`string\`, got \`${typeof o4}\``);
|
|
96
|
-
let l = s ? i : r, u = false, d = false, f = 0, p = ``, m = ``, h = -1;
|
|
97
|
-
for (let r5 = 0; r5 < o4.length; r5++) {
|
|
98
|
-
let i3 = o4[r5], s2 = o4[r5 + 1];
|
|
99
|
-
!d && i3 === `"` && (a(o4, r5) || (u = !u)), !u && (!d && i3 + (s2 ?? e3) === `//` ? (p += o4.slice(f, r5), f = r5, d = t4, r5++) : d === t4 && i3 + (s2 ?? e3) === `\r
|
|
100
|
-
` ? (r5++, d = false, p += l(o4, f, r5), f = r5) : d === t4 && i3 === `
|
|
101
|
-
` ? (d = false, p += l(o4, f, r5), f = r5) : !d && i3 + (s2 ?? e3) === `/*` ? (p += o4.slice(f, r5), f = r5, d = n2, r5++) : d === n2 && i3 + (s2 ?? e3) === `*/` ? (r5++, d = false, p += l(o4, f, r5 + 1), f = r5 + 1) : c2 && !d && (h === -1 ? i3 === `,` && (m += p + o4.slice(f, r5), p = ``, f = r5, h = r5) : i3 === `}` || i3 === `]` ? (p += o4.slice(f, r5), m += l(p, 0, 1) + p.slice(1), p = ``, f = r5, h = -1) : i3 !== ` ` && i3 !== ` ` && i3 !== `\r` && i3 !== `
|
|
102
|
-
` && (p += o4.slice(f, r5), f = r5, h = -1)));
|
|
103
|
-
}
|
|
104
|
-
return m + p + (d ? l(o4.slice(f)) : o4.slice(f));
|
|
105
|
-
}
|
|
106
|
-
chunkWVKPC33H_cjs.__name(o, "o");
|
|
107
|
-
|
|
108
|
-
// ../../node_modules/.pnpm/@stryke+json@0.9.32/node_modules/@stryke/json/dist/utils/parse.mjs
|
|
109
|
-
var t5 = /"(?:_|\\u0{2}5[Ff]){2}(?:p|\\u0{2}70)(?:r|\\u0{2}72)(?:o|\\u0{2}6[Ff])(?:t|\\u0{2}74)(?:o|\\u0{2}6[Ff])(?:_|\\u0{2}5[Ff]){2}"\s*:/;
|
|
110
|
-
var n3 = /"(?:c|\\u0063)(?:o|\\u006[Ff])(?:n|\\u006[Ee])(?:s|\\u0073)(?:t|\\u0074)(?:r|\\u0072)(?:u|\\u0075)(?:c|\\u0063)(?:t|\\u0074)(?:o|\\u006[Ff])(?:r|\\u0072)"\s*:/;
|
|
111
|
-
var r2 = /^\s*["[{]|^\s*-?\d{1,16}(?:\.\d{1,17})?(?:E[+-]?\d+)?\s*$/i;
|
|
112
|
-
function i2(e7, t7) {
|
|
113
|
-
if (e7 === `__proto__` || e7 === `constructor` && t7 && typeof t7 == `object` && `prototype` in t7) {
|
|
114
|
-
console.warn(`Dropping "${e7}" key to prevent prototype pollution.`);
|
|
115
|
-
return;
|
|
116
|
-
}
|
|
117
|
-
return t7;
|
|
118
|
-
}
|
|
119
|
-
chunkWVKPC33H_cjs.__name(i2, "i");
|
|
120
|
-
function a2(a3, o4 = {}) {
|
|
121
|
-
if (typeof a3 != `string`) return a3;
|
|
122
|
-
let s = o(a3);
|
|
123
|
-
if (s[0] === `"` && s[s.length - 1] === `"` && !s.includes(`\\`)) return s.slice(1, -1);
|
|
124
|
-
if (s = s.trim(), s.length <= 9) switch (s.toLowerCase()) {
|
|
125
|
-
case `true`:
|
|
126
|
-
return true;
|
|
127
|
-
case `false`:
|
|
128
|
-
return false;
|
|
129
|
-
case `undefined`:
|
|
130
|
-
return;
|
|
131
|
-
case `null`:
|
|
132
|
-
return null;
|
|
133
|
-
case `nan`:
|
|
134
|
-
return NaN;
|
|
135
|
-
case `infinity`:
|
|
136
|
-
return 1 / 0;
|
|
137
|
-
case `-infinity`:
|
|
138
|
-
return -1 / 0;
|
|
139
|
-
}
|
|
140
|
-
if (!r2.test(s)) {
|
|
141
|
-
if (o4.strict) throw Error(`Invalid JSON`);
|
|
142
|
-
return s;
|
|
143
|
-
}
|
|
144
|
-
try {
|
|
145
|
-
if (t5.test(s) || n3.test(s)) {
|
|
146
|
-
if (o4.strict) throw Error(`Possible prototype pollution`);
|
|
147
|
-
return JSON.parse(s, i2);
|
|
148
|
-
}
|
|
149
|
-
return JSON.parse(s);
|
|
150
|
-
} catch (e7) {
|
|
151
|
-
if (o4.strict) throw e7;
|
|
152
|
-
return a3;
|
|
153
|
-
}
|
|
154
|
-
}
|
|
155
|
-
chunkWVKPC33H_cjs.__name(a2, "a");
|
|
156
|
-
|
|
157
|
-
// ../../node_modules/.pnpm/@stryke+json@0.9.32/node_modules/@stryke/json/dist/utils/parse-error.mjs
|
|
158
|
-
chunkWVKPC33H_cjs.init_cjs_shims();
|
|
159
|
-
|
|
160
|
-
// ../../node_modules/.pnpm/@stryke+json@0.9.32/node_modules/@stryke/json/dist/utils/code-frames.mjs
|
|
161
|
-
chunkWVKPC33H_cjs.init_cjs_shims();
|
|
162
|
-
var e4 = /\r\n|[\n\r\u2028\u2029]/;
|
|
163
|
-
function t6(e7, t7, n6 = {}) {
|
|
164
|
-
let r5 = { column: 0, line: -1, ...e7.start }, i3 = { ...r5, ...e7.end }, { linesAbove: a3 = 2, linesBelow: o4 = 3 } = n6 || {}, s = r5.line, c2 = r5.column, l = i3.line, u = i3.column, d = Math.max(s - (a3 + 1), 0), f = Math.min(t7.length, l + o4);
|
|
165
|
-
s === -1 && (d = 0), l === -1 && (f = t7.length);
|
|
166
|
-
let p = l - s, m = {};
|
|
167
|
-
if (p) for (let e8 = 0; e8 <= p; e8++) {
|
|
168
|
-
let n7 = e8 + s;
|
|
169
|
-
c2 ? e8 === 0 ? m[n7] = [c2, (t7[n7 - 1]?.length ?? 0) - c2 + 1] : e8 === p ? m[n7] = [0, u] : m[n7] = [0, t7[n7 - e8]?.length ?? 0] : m[n7] = true;
|
|
170
|
-
}
|
|
171
|
-
else c2 === u ? m[s] = c2 ? [c2, 0] : true : m[s] = [c2, u - c2];
|
|
172
|
-
return { start: d, end: f, markerLines: m };
|
|
173
|
-
}
|
|
174
|
-
chunkWVKPC33H_cjs.__name(t6, "t");
|
|
175
|
-
function n4(n6, r5, i3 = {}) {
|
|
176
|
-
let { start: a3, end: o4, markerLines: s } = t6(r5, n6.split(e4), i3), c2 = String(o4).length;
|
|
177
|
-
return (i3.highlight ? i3.highlight(n6) : n6).split(e4).slice(a3, o4).map((e7, t7) => {
|
|
178
|
-
let n7 = a3 + 1 + t7, r6 = ` ${` ${n7}`.slice(-c2)} | `, i4 = !!(s[n7] ?? false);
|
|
179
|
-
if (i4) {
|
|
180
|
-
let t8 = ``;
|
|
181
|
-
if (Array.isArray(i4)) {
|
|
182
|
-
let n8 = e7.slice(0, Math.max(i4[0] - 1, 0)).replace(/[^\t]/g, ` `), a4 = i4[1] || 1;
|
|
183
|
-
t8 = [`
|
|
184
|
-
`, r6.replace(/\d/g, ` `), n8, `^`.repeat(a4)].join(``);
|
|
185
|
-
}
|
|
186
|
-
return [`>`, r6, e7, t8].join(``);
|
|
187
|
-
}
|
|
188
|
-
return ` ${r6}${e7}`;
|
|
189
|
-
}).join(`
|
|
190
|
-
`);
|
|
191
|
-
}
|
|
192
|
-
chunkWVKPC33H_cjs.__name(n4, "n");
|
|
193
|
-
|
|
194
|
-
// ../../node_modules/.pnpm/jsonc-parser@3.2.0/node_modules/jsonc-parser/lib/esm/main.js
|
|
195
|
-
chunkWVKPC33H_cjs.init_cjs_shims();
|
|
196
|
-
|
|
197
|
-
// ../../node_modules/.pnpm/jsonc-parser@3.2.0/node_modules/jsonc-parser/lib/esm/impl/format.js
|
|
198
|
-
chunkWVKPC33H_cjs.init_cjs_shims();
|
|
199
|
-
|
|
200
|
-
// ../../node_modules/.pnpm/jsonc-parser@3.2.0/node_modules/jsonc-parser/lib/esm/impl/scanner.js
|
|
201
|
-
chunkWVKPC33H_cjs.init_cjs_shims();
|
|
202
|
-
function createScanner(text, ignoreTrivia = false) {
|
|
203
|
-
const len = text.length;
|
|
204
|
-
let pos = 0, value = "", tokenOffset = 0, token = 16, lineNumber = 0, lineStartOffset = 0, tokenLineStartOffset = 0, prevTokenLineStartOffset = 0, scanError = 0;
|
|
205
|
-
function scanHexDigits(count, exact) {
|
|
206
|
-
let digits = 0;
|
|
207
|
-
let value2 = 0;
|
|
208
|
-
while (digits < count || !exact) {
|
|
209
|
-
let ch = text.charCodeAt(pos);
|
|
210
|
-
if (ch >= 48 && ch <= 57) {
|
|
211
|
-
value2 = value2 * 16 + ch - 48;
|
|
212
|
-
} else if (ch >= 65 && ch <= 70) {
|
|
213
|
-
value2 = value2 * 16 + ch - 65 + 10;
|
|
214
|
-
} else if (ch >= 97 && ch <= 102) {
|
|
215
|
-
value2 = value2 * 16 + ch - 97 + 10;
|
|
216
|
-
} else {
|
|
217
|
-
break;
|
|
218
|
-
}
|
|
219
|
-
pos++;
|
|
220
|
-
digits++;
|
|
221
|
-
}
|
|
222
|
-
if (digits < count) {
|
|
223
|
-
value2 = -1;
|
|
224
|
-
}
|
|
225
|
-
return value2;
|
|
226
|
-
}
|
|
227
|
-
chunkWVKPC33H_cjs.__name(scanHexDigits, "scanHexDigits");
|
|
228
|
-
function setPosition(newPosition) {
|
|
229
|
-
pos = newPosition;
|
|
230
|
-
value = "";
|
|
231
|
-
tokenOffset = 0;
|
|
232
|
-
token = 16;
|
|
233
|
-
scanError = 0;
|
|
234
|
-
}
|
|
235
|
-
chunkWVKPC33H_cjs.__name(setPosition, "setPosition");
|
|
236
|
-
function scanNumber() {
|
|
237
|
-
let start = pos;
|
|
238
|
-
if (text.charCodeAt(pos) === 48) {
|
|
239
|
-
pos++;
|
|
240
|
-
} else {
|
|
241
|
-
pos++;
|
|
242
|
-
while (pos < text.length && isDigit(text.charCodeAt(pos))) {
|
|
243
|
-
pos++;
|
|
244
|
-
}
|
|
245
|
-
}
|
|
246
|
-
if (pos < text.length && text.charCodeAt(pos) === 46) {
|
|
247
|
-
pos++;
|
|
248
|
-
if (pos < text.length && isDigit(text.charCodeAt(pos))) {
|
|
249
|
-
pos++;
|
|
250
|
-
while (pos < text.length && isDigit(text.charCodeAt(pos))) {
|
|
251
|
-
pos++;
|
|
252
|
-
}
|
|
253
|
-
} else {
|
|
254
|
-
scanError = 3;
|
|
255
|
-
return text.substring(start, pos);
|
|
256
|
-
}
|
|
257
|
-
}
|
|
258
|
-
let end = pos;
|
|
259
|
-
if (pos < text.length && (text.charCodeAt(pos) === 69 || text.charCodeAt(pos) === 101)) {
|
|
260
|
-
pos++;
|
|
261
|
-
if (pos < text.length && text.charCodeAt(pos) === 43 || text.charCodeAt(pos) === 45) {
|
|
262
|
-
pos++;
|
|
263
|
-
}
|
|
264
|
-
if (pos < text.length && isDigit(text.charCodeAt(pos))) {
|
|
265
|
-
pos++;
|
|
266
|
-
while (pos < text.length && isDigit(text.charCodeAt(pos))) {
|
|
267
|
-
pos++;
|
|
268
|
-
}
|
|
269
|
-
end = pos;
|
|
270
|
-
} else {
|
|
271
|
-
scanError = 3;
|
|
272
|
-
}
|
|
273
|
-
}
|
|
274
|
-
return text.substring(start, end);
|
|
275
|
-
}
|
|
276
|
-
chunkWVKPC33H_cjs.__name(scanNumber, "scanNumber");
|
|
277
|
-
function scanString() {
|
|
278
|
-
let result = "", start = pos;
|
|
279
|
-
while (true) {
|
|
280
|
-
if (pos >= len) {
|
|
281
|
-
result += text.substring(start, pos);
|
|
282
|
-
scanError = 2;
|
|
283
|
-
break;
|
|
284
|
-
}
|
|
285
|
-
const ch = text.charCodeAt(pos);
|
|
286
|
-
if (ch === 34) {
|
|
287
|
-
result += text.substring(start, pos);
|
|
288
|
-
pos++;
|
|
289
|
-
break;
|
|
290
|
-
}
|
|
291
|
-
if (ch === 92) {
|
|
292
|
-
result += text.substring(start, pos);
|
|
293
|
-
pos++;
|
|
294
|
-
if (pos >= len) {
|
|
295
|
-
scanError = 2;
|
|
296
|
-
break;
|
|
297
|
-
}
|
|
298
|
-
const ch2 = text.charCodeAt(pos++);
|
|
299
|
-
switch (ch2) {
|
|
300
|
-
case 34:
|
|
301
|
-
result += '"';
|
|
302
|
-
break;
|
|
303
|
-
case 92:
|
|
304
|
-
result += "\\";
|
|
305
|
-
break;
|
|
306
|
-
case 47:
|
|
307
|
-
result += "/";
|
|
308
|
-
break;
|
|
309
|
-
case 98:
|
|
310
|
-
result += "\b";
|
|
311
|
-
break;
|
|
312
|
-
case 102:
|
|
313
|
-
result += "\f";
|
|
314
|
-
break;
|
|
315
|
-
case 110:
|
|
316
|
-
result += "\n";
|
|
317
|
-
break;
|
|
318
|
-
case 114:
|
|
319
|
-
result += "\r";
|
|
320
|
-
break;
|
|
321
|
-
case 116:
|
|
322
|
-
result += " ";
|
|
323
|
-
break;
|
|
324
|
-
case 117:
|
|
325
|
-
const ch3 = scanHexDigits(4, true);
|
|
326
|
-
if (ch3 >= 0) {
|
|
327
|
-
result += String.fromCharCode(ch3);
|
|
328
|
-
} else {
|
|
329
|
-
scanError = 4;
|
|
330
|
-
}
|
|
331
|
-
break;
|
|
332
|
-
default:
|
|
333
|
-
scanError = 5;
|
|
334
|
-
}
|
|
335
|
-
start = pos;
|
|
336
|
-
continue;
|
|
337
|
-
}
|
|
338
|
-
if (ch >= 0 && ch <= 31) {
|
|
339
|
-
if (isLineBreak(ch)) {
|
|
340
|
-
result += text.substring(start, pos);
|
|
341
|
-
scanError = 2;
|
|
342
|
-
break;
|
|
343
|
-
} else {
|
|
344
|
-
scanError = 6;
|
|
345
|
-
}
|
|
346
|
-
}
|
|
347
|
-
pos++;
|
|
348
|
-
}
|
|
349
|
-
return result;
|
|
350
|
-
}
|
|
351
|
-
chunkWVKPC33H_cjs.__name(scanString, "scanString");
|
|
352
|
-
function scanNext() {
|
|
353
|
-
value = "";
|
|
354
|
-
scanError = 0;
|
|
355
|
-
tokenOffset = pos;
|
|
356
|
-
lineStartOffset = lineNumber;
|
|
357
|
-
prevTokenLineStartOffset = tokenLineStartOffset;
|
|
358
|
-
if (pos >= len) {
|
|
359
|
-
tokenOffset = len;
|
|
360
|
-
return token = 17;
|
|
361
|
-
}
|
|
362
|
-
let code = text.charCodeAt(pos);
|
|
363
|
-
if (isWhiteSpace(code)) {
|
|
364
|
-
do {
|
|
365
|
-
pos++;
|
|
366
|
-
value += String.fromCharCode(code);
|
|
367
|
-
code = text.charCodeAt(pos);
|
|
368
|
-
} while (isWhiteSpace(code));
|
|
369
|
-
return token = 15;
|
|
370
|
-
}
|
|
371
|
-
if (isLineBreak(code)) {
|
|
372
|
-
pos++;
|
|
373
|
-
value += String.fromCharCode(code);
|
|
374
|
-
if (code === 13 && text.charCodeAt(pos) === 10) {
|
|
375
|
-
pos++;
|
|
376
|
-
value += "\n";
|
|
377
|
-
}
|
|
378
|
-
lineNumber++;
|
|
379
|
-
tokenLineStartOffset = pos;
|
|
380
|
-
return token = 14;
|
|
381
|
-
}
|
|
382
|
-
switch (code) {
|
|
383
|
-
// tokens: []{}:,
|
|
384
|
-
case 123:
|
|
385
|
-
pos++;
|
|
386
|
-
return token = 1;
|
|
387
|
-
case 125:
|
|
388
|
-
pos++;
|
|
389
|
-
return token = 2;
|
|
390
|
-
case 91:
|
|
391
|
-
pos++;
|
|
392
|
-
return token = 3;
|
|
393
|
-
case 93:
|
|
394
|
-
pos++;
|
|
395
|
-
return token = 4;
|
|
396
|
-
case 58:
|
|
397
|
-
pos++;
|
|
398
|
-
return token = 6;
|
|
399
|
-
case 44:
|
|
400
|
-
pos++;
|
|
401
|
-
return token = 5;
|
|
402
|
-
// strings
|
|
403
|
-
case 34:
|
|
404
|
-
pos++;
|
|
405
|
-
value = scanString();
|
|
406
|
-
return token = 10;
|
|
407
|
-
// comments
|
|
408
|
-
case 47:
|
|
409
|
-
const start = pos - 1;
|
|
410
|
-
if (text.charCodeAt(pos + 1) === 47) {
|
|
411
|
-
pos += 2;
|
|
412
|
-
while (pos < len) {
|
|
413
|
-
if (isLineBreak(text.charCodeAt(pos))) {
|
|
414
|
-
break;
|
|
415
|
-
}
|
|
416
|
-
pos++;
|
|
417
|
-
}
|
|
418
|
-
value = text.substring(start, pos);
|
|
419
|
-
return token = 12;
|
|
420
|
-
}
|
|
421
|
-
if (text.charCodeAt(pos + 1) === 42) {
|
|
422
|
-
pos += 2;
|
|
423
|
-
const safeLength = len - 1;
|
|
424
|
-
let commentClosed = false;
|
|
425
|
-
while (pos < safeLength) {
|
|
426
|
-
const ch = text.charCodeAt(pos);
|
|
427
|
-
if (ch === 42 && text.charCodeAt(pos + 1) === 47) {
|
|
428
|
-
pos += 2;
|
|
429
|
-
commentClosed = true;
|
|
430
|
-
break;
|
|
431
|
-
}
|
|
432
|
-
pos++;
|
|
433
|
-
if (isLineBreak(ch)) {
|
|
434
|
-
if (ch === 13 && text.charCodeAt(pos) === 10) {
|
|
435
|
-
pos++;
|
|
436
|
-
}
|
|
437
|
-
lineNumber++;
|
|
438
|
-
tokenLineStartOffset = pos;
|
|
439
|
-
}
|
|
440
|
-
}
|
|
441
|
-
if (!commentClosed) {
|
|
442
|
-
pos++;
|
|
443
|
-
scanError = 1;
|
|
444
|
-
}
|
|
445
|
-
value = text.substring(start, pos);
|
|
446
|
-
return token = 13;
|
|
447
|
-
}
|
|
448
|
-
value += String.fromCharCode(code);
|
|
449
|
-
pos++;
|
|
450
|
-
return token = 16;
|
|
451
|
-
// numbers
|
|
452
|
-
case 45:
|
|
453
|
-
value += String.fromCharCode(code);
|
|
454
|
-
pos++;
|
|
455
|
-
if (pos === len || !isDigit(text.charCodeAt(pos))) {
|
|
456
|
-
return token = 16;
|
|
457
|
-
}
|
|
458
|
-
// found a minus, followed by a number so
|
|
459
|
-
// we fall through to proceed with scanning
|
|
460
|
-
// numbers
|
|
461
|
-
case 48:
|
|
462
|
-
case 49:
|
|
463
|
-
case 50:
|
|
464
|
-
case 51:
|
|
465
|
-
case 52:
|
|
466
|
-
case 53:
|
|
467
|
-
case 54:
|
|
468
|
-
case 55:
|
|
469
|
-
case 56:
|
|
470
|
-
case 57:
|
|
471
|
-
value += scanNumber();
|
|
472
|
-
return token = 11;
|
|
473
|
-
// literals and unknown symbols
|
|
474
|
-
default:
|
|
475
|
-
while (pos < len && isUnknownContentCharacter(code)) {
|
|
476
|
-
pos++;
|
|
477
|
-
code = text.charCodeAt(pos);
|
|
478
|
-
}
|
|
479
|
-
if (tokenOffset !== pos) {
|
|
480
|
-
value = text.substring(tokenOffset, pos);
|
|
481
|
-
switch (value) {
|
|
482
|
-
case "true":
|
|
483
|
-
return token = 8;
|
|
484
|
-
case "false":
|
|
485
|
-
return token = 9;
|
|
486
|
-
case "null":
|
|
487
|
-
return token = 7;
|
|
488
|
-
}
|
|
489
|
-
return token = 16;
|
|
490
|
-
}
|
|
491
|
-
value += String.fromCharCode(code);
|
|
492
|
-
pos++;
|
|
493
|
-
return token = 16;
|
|
494
|
-
}
|
|
495
|
-
}
|
|
496
|
-
chunkWVKPC33H_cjs.__name(scanNext, "scanNext");
|
|
497
|
-
function isUnknownContentCharacter(code) {
|
|
498
|
-
if (isWhiteSpace(code) || isLineBreak(code)) {
|
|
499
|
-
return false;
|
|
500
|
-
}
|
|
501
|
-
switch (code) {
|
|
502
|
-
case 125:
|
|
503
|
-
case 93:
|
|
504
|
-
case 123:
|
|
505
|
-
case 91:
|
|
506
|
-
case 34:
|
|
507
|
-
case 58:
|
|
508
|
-
case 44:
|
|
509
|
-
case 47:
|
|
510
|
-
return false;
|
|
511
|
-
}
|
|
512
|
-
return true;
|
|
513
|
-
}
|
|
514
|
-
chunkWVKPC33H_cjs.__name(isUnknownContentCharacter, "isUnknownContentCharacter");
|
|
515
|
-
function scanNextNonTrivia() {
|
|
516
|
-
let result;
|
|
517
|
-
do {
|
|
518
|
-
result = scanNext();
|
|
519
|
-
} while (result >= 12 && result <= 15);
|
|
520
|
-
return result;
|
|
521
|
-
}
|
|
522
|
-
chunkWVKPC33H_cjs.__name(scanNextNonTrivia, "scanNextNonTrivia");
|
|
523
|
-
return {
|
|
524
|
-
setPosition,
|
|
525
|
-
getPosition: /* @__PURE__ */ chunkWVKPC33H_cjs.__name(() => pos, "getPosition"),
|
|
526
|
-
scan: ignoreTrivia ? scanNextNonTrivia : scanNext,
|
|
527
|
-
getToken: /* @__PURE__ */ chunkWVKPC33H_cjs.__name(() => token, "getToken"),
|
|
528
|
-
getTokenValue: /* @__PURE__ */ chunkWVKPC33H_cjs.__name(() => value, "getTokenValue"),
|
|
529
|
-
getTokenOffset: /* @__PURE__ */ chunkWVKPC33H_cjs.__name(() => tokenOffset, "getTokenOffset"),
|
|
530
|
-
getTokenLength: /* @__PURE__ */ chunkWVKPC33H_cjs.__name(() => pos - tokenOffset, "getTokenLength"),
|
|
531
|
-
getTokenStartLine: /* @__PURE__ */ chunkWVKPC33H_cjs.__name(() => lineStartOffset, "getTokenStartLine"),
|
|
532
|
-
getTokenStartCharacter: /* @__PURE__ */ chunkWVKPC33H_cjs.__name(() => tokenOffset - prevTokenLineStartOffset, "getTokenStartCharacter"),
|
|
533
|
-
getTokenError: /* @__PURE__ */ chunkWVKPC33H_cjs.__name(() => scanError, "getTokenError")
|
|
534
|
-
};
|
|
535
|
-
}
|
|
536
|
-
chunkWVKPC33H_cjs.__name(createScanner, "createScanner");
|
|
537
|
-
function isWhiteSpace(ch) {
|
|
538
|
-
return ch === 32 || ch === 9;
|
|
539
|
-
}
|
|
540
|
-
chunkWVKPC33H_cjs.__name(isWhiteSpace, "isWhiteSpace");
|
|
541
|
-
function isLineBreak(ch) {
|
|
542
|
-
return ch === 10 || ch === 13;
|
|
543
|
-
}
|
|
544
|
-
chunkWVKPC33H_cjs.__name(isLineBreak, "isLineBreak");
|
|
545
|
-
function isDigit(ch) {
|
|
546
|
-
return ch >= 48 && ch <= 57;
|
|
547
|
-
}
|
|
548
|
-
chunkWVKPC33H_cjs.__name(isDigit, "isDigit");
|
|
549
|
-
var CharacterCodes;
|
|
550
|
-
(function(CharacterCodes2) {
|
|
551
|
-
CharacterCodes2[CharacterCodes2["lineFeed"] = 10] = "lineFeed";
|
|
552
|
-
CharacterCodes2[CharacterCodes2["carriageReturn"] = 13] = "carriageReturn";
|
|
553
|
-
CharacterCodes2[CharacterCodes2["space"] = 32] = "space";
|
|
554
|
-
CharacterCodes2[CharacterCodes2["_0"] = 48] = "_0";
|
|
555
|
-
CharacterCodes2[CharacterCodes2["_1"] = 49] = "_1";
|
|
556
|
-
CharacterCodes2[CharacterCodes2["_2"] = 50] = "_2";
|
|
557
|
-
CharacterCodes2[CharacterCodes2["_3"] = 51] = "_3";
|
|
558
|
-
CharacterCodes2[CharacterCodes2["_4"] = 52] = "_4";
|
|
559
|
-
CharacterCodes2[CharacterCodes2["_5"] = 53] = "_5";
|
|
560
|
-
CharacterCodes2[CharacterCodes2["_6"] = 54] = "_6";
|
|
561
|
-
CharacterCodes2[CharacterCodes2["_7"] = 55] = "_7";
|
|
562
|
-
CharacterCodes2[CharacterCodes2["_8"] = 56] = "_8";
|
|
563
|
-
CharacterCodes2[CharacterCodes2["_9"] = 57] = "_9";
|
|
564
|
-
CharacterCodes2[CharacterCodes2["a"] = 97] = "a";
|
|
565
|
-
CharacterCodes2[CharacterCodes2["b"] = 98] = "b";
|
|
566
|
-
CharacterCodes2[CharacterCodes2["c"] = 99] = "c";
|
|
567
|
-
CharacterCodes2[CharacterCodes2["d"] = 100] = "d";
|
|
568
|
-
CharacterCodes2[CharacterCodes2["e"] = 101] = "e";
|
|
569
|
-
CharacterCodes2[CharacterCodes2["f"] = 102] = "f";
|
|
570
|
-
CharacterCodes2[CharacterCodes2["g"] = 103] = "g";
|
|
571
|
-
CharacterCodes2[CharacterCodes2["h"] = 104] = "h";
|
|
572
|
-
CharacterCodes2[CharacterCodes2["i"] = 105] = "i";
|
|
573
|
-
CharacterCodes2[CharacterCodes2["j"] = 106] = "j";
|
|
574
|
-
CharacterCodes2[CharacterCodes2["k"] = 107] = "k";
|
|
575
|
-
CharacterCodes2[CharacterCodes2["l"] = 108] = "l";
|
|
576
|
-
CharacterCodes2[CharacterCodes2["m"] = 109] = "m";
|
|
577
|
-
CharacterCodes2[CharacterCodes2["n"] = 110] = "n";
|
|
578
|
-
CharacterCodes2[CharacterCodes2["o"] = 111] = "o";
|
|
579
|
-
CharacterCodes2[CharacterCodes2["p"] = 112] = "p";
|
|
580
|
-
CharacterCodes2[CharacterCodes2["q"] = 113] = "q";
|
|
581
|
-
CharacterCodes2[CharacterCodes2["r"] = 114] = "r";
|
|
582
|
-
CharacterCodes2[CharacterCodes2["s"] = 115] = "s";
|
|
583
|
-
CharacterCodes2[CharacterCodes2["t"] = 116] = "t";
|
|
584
|
-
CharacterCodes2[CharacterCodes2["u"] = 117] = "u";
|
|
585
|
-
CharacterCodes2[CharacterCodes2["v"] = 118] = "v";
|
|
586
|
-
CharacterCodes2[CharacterCodes2["w"] = 119] = "w";
|
|
587
|
-
CharacterCodes2[CharacterCodes2["x"] = 120] = "x";
|
|
588
|
-
CharacterCodes2[CharacterCodes2["y"] = 121] = "y";
|
|
589
|
-
CharacterCodes2[CharacterCodes2["z"] = 122] = "z";
|
|
590
|
-
CharacterCodes2[CharacterCodes2["A"] = 65] = "A";
|
|
591
|
-
CharacterCodes2[CharacterCodes2["B"] = 66] = "B";
|
|
592
|
-
CharacterCodes2[CharacterCodes2["C"] = 67] = "C";
|
|
593
|
-
CharacterCodes2[CharacterCodes2["D"] = 68] = "D";
|
|
594
|
-
CharacterCodes2[CharacterCodes2["E"] = 69] = "E";
|
|
595
|
-
CharacterCodes2[CharacterCodes2["F"] = 70] = "F";
|
|
596
|
-
CharacterCodes2[CharacterCodes2["G"] = 71] = "G";
|
|
597
|
-
CharacterCodes2[CharacterCodes2["H"] = 72] = "H";
|
|
598
|
-
CharacterCodes2[CharacterCodes2["I"] = 73] = "I";
|
|
599
|
-
CharacterCodes2[CharacterCodes2["J"] = 74] = "J";
|
|
600
|
-
CharacterCodes2[CharacterCodes2["K"] = 75] = "K";
|
|
601
|
-
CharacterCodes2[CharacterCodes2["L"] = 76] = "L";
|
|
602
|
-
CharacterCodes2[CharacterCodes2["M"] = 77] = "M";
|
|
603
|
-
CharacterCodes2[CharacterCodes2["N"] = 78] = "N";
|
|
604
|
-
CharacterCodes2[CharacterCodes2["O"] = 79] = "O";
|
|
605
|
-
CharacterCodes2[CharacterCodes2["P"] = 80] = "P";
|
|
606
|
-
CharacterCodes2[CharacterCodes2["Q"] = 81] = "Q";
|
|
607
|
-
CharacterCodes2[CharacterCodes2["R"] = 82] = "R";
|
|
608
|
-
CharacterCodes2[CharacterCodes2["S"] = 83] = "S";
|
|
609
|
-
CharacterCodes2[CharacterCodes2["T"] = 84] = "T";
|
|
610
|
-
CharacterCodes2[CharacterCodes2["U"] = 85] = "U";
|
|
611
|
-
CharacterCodes2[CharacterCodes2["V"] = 86] = "V";
|
|
612
|
-
CharacterCodes2[CharacterCodes2["W"] = 87] = "W";
|
|
613
|
-
CharacterCodes2[CharacterCodes2["X"] = 88] = "X";
|
|
614
|
-
CharacterCodes2[CharacterCodes2["Y"] = 89] = "Y";
|
|
615
|
-
CharacterCodes2[CharacterCodes2["Z"] = 90] = "Z";
|
|
616
|
-
CharacterCodes2[CharacterCodes2["asterisk"] = 42] = "asterisk";
|
|
617
|
-
CharacterCodes2[CharacterCodes2["backslash"] = 92] = "backslash";
|
|
618
|
-
CharacterCodes2[CharacterCodes2["closeBrace"] = 125] = "closeBrace";
|
|
619
|
-
CharacterCodes2[CharacterCodes2["closeBracket"] = 93] = "closeBracket";
|
|
620
|
-
CharacterCodes2[CharacterCodes2["colon"] = 58] = "colon";
|
|
621
|
-
CharacterCodes2[CharacterCodes2["comma"] = 44] = "comma";
|
|
622
|
-
CharacterCodes2[CharacterCodes2["dot"] = 46] = "dot";
|
|
623
|
-
CharacterCodes2[CharacterCodes2["doubleQuote"] = 34] = "doubleQuote";
|
|
624
|
-
CharacterCodes2[CharacterCodes2["minus"] = 45] = "minus";
|
|
625
|
-
CharacterCodes2[CharacterCodes2["openBrace"] = 123] = "openBrace";
|
|
626
|
-
CharacterCodes2[CharacterCodes2["openBracket"] = 91] = "openBracket";
|
|
627
|
-
CharacterCodes2[CharacterCodes2["plus"] = 43] = "plus";
|
|
628
|
-
CharacterCodes2[CharacterCodes2["slash"] = 47] = "slash";
|
|
629
|
-
CharacterCodes2[CharacterCodes2["formFeed"] = 12] = "formFeed";
|
|
630
|
-
CharacterCodes2[CharacterCodes2["tab"] = 9] = "tab";
|
|
631
|
-
})(CharacterCodes || (CharacterCodes = {}));
|
|
632
|
-
|
|
633
|
-
// ../../node_modules/.pnpm/jsonc-parser@3.2.0/node_modules/jsonc-parser/lib/esm/impl/edit.js
|
|
634
|
-
chunkWVKPC33H_cjs.init_cjs_shims();
|
|
635
|
-
|
|
636
|
-
// ../../node_modules/.pnpm/jsonc-parser@3.2.0/node_modules/jsonc-parser/lib/esm/impl/parser.js
|
|
637
|
-
chunkWVKPC33H_cjs.init_cjs_shims();
|
|
638
|
-
var ParseOptions;
|
|
639
|
-
(function(ParseOptions2) {
|
|
640
|
-
ParseOptions2.DEFAULT = {
|
|
641
|
-
allowTrailingComma: false
|
|
642
|
-
};
|
|
643
|
-
})(ParseOptions || (ParseOptions = {}));
|
|
644
|
-
function parse(text, errors = [], options = ParseOptions.DEFAULT) {
|
|
645
|
-
let currentProperty = null;
|
|
646
|
-
let currentParent = [];
|
|
647
|
-
const previousParents = [];
|
|
648
|
-
function onValue(value) {
|
|
649
|
-
if (Array.isArray(currentParent)) {
|
|
650
|
-
currentParent.push(value);
|
|
651
|
-
} else if (currentProperty !== null) {
|
|
652
|
-
currentParent[currentProperty] = value;
|
|
653
|
-
}
|
|
654
|
-
}
|
|
655
|
-
chunkWVKPC33H_cjs.__name(onValue, "onValue");
|
|
656
|
-
const visitor = {
|
|
657
|
-
onObjectBegin: /* @__PURE__ */ chunkWVKPC33H_cjs.__name(() => {
|
|
658
|
-
const object = {};
|
|
659
|
-
onValue(object);
|
|
660
|
-
previousParents.push(currentParent);
|
|
661
|
-
currentParent = object;
|
|
662
|
-
currentProperty = null;
|
|
663
|
-
}, "onObjectBegin"),
|
|
664
|
-
onObjectProperty: /* @__PURE__ */ chunkWVKPC33H_cjs.__name((name) => {
|
|
665
|
-
currentProperty = name;
|
|
666
|
-
}, "onObjectProperty"),
|
|
667
|
-
onObjectEnd: /* @__PURE__ */ chunkWVKPC33H_cjs.__name(() => {
|
|
668
|
-
currentParent = previousParents.pop();
|
|
669
|
-
}, "onObjectEnd"),
|
|
670
|
-
onArrayBegin: /* @__PURE__ */ chunkWVKPC33H_cjs.__name(() => {
|
|
671
|
-
const array = [];
|
|
672
|
-
onValue(array);
|
|
673
|
-
previousParents.push(currentParent);
|
|
674
|
-
currentParent = array;
|
|
675
|
-
currentProperty = null;
|
|
676
|
-
}, "onArrayBegin"),
|
|
677
|
-
onArrayEnd: /* @__PURE__ */ chunkWVKPC33H_cjs.__name(() => {
|
|
678
|
-
currentParent = previousParents.pop();
|
|
679
|
-
}, "onArrayEnd"),
|
|
680
|
-
onLiteralValue: onValue,
|
|
681
|
-
onError: /* @__PURE__ */ chunkWVKPC33H_cjs.__name((error, offset, length) => {
|
|
682
|
-
errors.push({
|
|
683
|
-
error,
|
|
684
|
-
offset,
|
|
685
|
-
length
|
|
686
|
-
});
|
|
687
|
-
}, "onError")
|
|
688
|
-
};
|
|
689
|
-
visit(text, visitor, options);
|
|
690
|
-
return currentParent[0];
|
|
691
|
-
}
|
|
692
|
-
chunkWVKPC33H_cjs.__name(parse, "parse");
|
|
693
|
-
function visit(text, visitor, options = ParseOptions.DEFAULT) {
|
|
694
|
-
const _scanner = createScanner(text, false);
|
|
695
|
-
const _jsonPath = [];
|
|
696
|
-
function toNoArgVisit(visitFunction) {
|
|
697
|
-
return visitFunction ? () => visitFunction(_scanner.getTokenOffset(), _scanner.getTokenLength(), _scanner.getTokenStartLine(), _scanner.getTokenStartCharacter()) : () => true;
|
|
698
|
-
}
|
|
699
|
-
chunkWVKPC33H_cjs.__name(toNoArgVisit, "toNoArgVisit");
|
|
700
|
-
function toNoArgVisitWithPath(visitFunction) {
|
|
701
|
-
return visitFunction ? () => visitFunction(_scanner.getTokenOffset(), _scanner.getTokenLength(), _scanner.getTokenStartLine(), _scanner.getTokenStartCharacter(), () => _jsonPath.slice()) : () => true;
|
|
702
|
-
}
|
|
703
|
-
chunkWVKPC33H_cjs.__name(toNoArgVisitWithPath, "toNoArgVisitWithPath");
|
|
704
|
-
function toOneArgVisit(visitFunction) {
|
|
705
|
-
return visitFunction ? (arg) => visitFunction(arg, _scanner.getTokenOffset(), _scanner.getTokenLength(), _scanner.getTokenStartLine(), _scanner.getTokenStartCharacter()) : () => true;
|
|
706
|
-
}
|
|
707
|
-
chunkWVKPC33H_cjs.__name(toOneArgVisit, "toOneArgVisit");
|
|
708
|
-
function toOneArgVisitWithPath(visitFunction) {
|
|
709
|
-
return visitFunction ? (arg) => visitFunction(arg, _scanner.getTokenOffset(), _scanner.getTokenLength(), _scanner.getTokenStartLine(), _scanner.getTokenStartCharacter(), () => _jsonPath.slice()) : () => true;
|
|
710
|
-
}
|
|
711
|
-
chunkWVKPC33H_cjs.__name(toOneArgVisitWithPath, "toOneArgVisitWithPath");
|
|
712
|
-
const onObjectBegin = toNoArgVisitWithPath(visitor.onObjectBegin), onObjectProperty = toOneArgVisitWithPath(visitor.onObjectProperty), onObjectEnd = toNoArgVisit(visitor.onObjectEnd), onArrayBegin = toNoArgVisitWithPath(visitor.onArrayBegin), onArrayEnd = toNoArgVisit(visitor.onArrayEnd), onLiteralValue = toOneArgVisitWithPath(visitor.onLiteralValue), onSeparator = toOneArgVisit(visitor.onSeparator), onComment = toNoArgVisit(visitor.onComment), onError = toOneArgVisit(visitor.onError);
|
|
713
|
-
const disallowComments = options && options.disallowComments;
|
|
714
|
-
const allowTrailingComma = options && options.allowTrailingComma;
|
|
715
|
-
function scanNext() {
|
|
716
|
-
while (true) {
|
|
717
|
-
const token = _scanner.scan();
|
|
718
|
-
switch (_scanner.getTokenError()) {
|
|
719
|
-
case 4:
|
|
720
|
-
handleError(
|
|
721
|
-
14
|
|
722
|
-
/* ParseErrorCode.InvalidUnicode */
|
|
723
|
-
);
|
|
724
|
-
break;
|
|
725
|
-
case 5:
|
|
726
|
-
handleError(
|
|
727
|
-
15
|
|
728
|
-
/* ParseErrorCode.InvalidEscapeCharacter */
|
|
729
|
-
);
|
|
730
|
-
break;
|
|
731
|
-
case 3:
|
|
732
|
-
handleError(
|
|
733
|
-
13
|
|
734
|
-
/* ParseErrorCode.UnexpectedEndOfNumber */
|
|
735
|
-
);
|
|
736
|
-
break;
|
|
737
|
-
case 1:
|
|
738
|
-
if (!disallowComments) {
|
|
739
|
-
handleError(
|
|
740
|
-
11
|
|
741
|
-
/* ParseErrorCode.UnexpectedEndOfComment */
|
|
742
|
-
);
|
|
743
|
-
}
|
|
744
|
-
break;
|
|
745
|
-
case 2:
|
|
746
|
-
handleError(
|
|
747
|
-
12
|
|
748
|
-
/* ParseErrorCode.UnexpectedEndOfString */
|
|
749
|
-
);
|
|
750
|
-
break;
|
|
751
|
-
case 6:
|
|
752
|
-
handleError(
|
|
753
|
-
16
|
|
754
|
-
/* ParseErrorCode.InvalidCharacter */
|
|
755
|
-
);
|
|
756
|
-
break;
|
|
757
|
-
}
|
|
758
|
-
switch (token) {
|
|
759
|
-
case 12:
|
|
760
|
-
case 13:
|
|
761
|
-
if (disallowComments) {
|
|
762
|
-
handleError(
|
|
763
|
-
10
|
|
764
|
-
/* ParseErrorCode.InvalidCommentToken */
|
|
765
|
-
);
|
|
766
|
-
} else {
|
|
767
|
-
onComment();
|
|
768
|
-
}
|
|
769
|
-
break;
|
|
770
|
-
case 16:
|
|
771
|
-
handleError(
|
|
772
|
-
1
|
|
773
|
-
/* ParseErrorCode.InvalidSymbol */
|
|
774
|
-
);
|
|
775
|
-
break;
|
|
776
|
-
case 15:
|
|
777
|
-
case 14:
|
|
778
|
-
break;
|
|
779
|
-
default:
|
|
780
|
-
return token;
|
|
781
|
-
}
|
|
782
|
-
}
|
|
783
|
-
}
|
|
784
|
-
chunkWVKPC33H_cjs.__name(scanNext, "scanNext");
|
|
785
|
-
function handleError(error, skipUntilAfter = [], skipUntil = []) {
|
|
786
|
-
onError(error);
|
|
787
|
-
if (skipUntilAfter.length + skipUntil.length > 0) {
|
|
788
|
-
let token = _scanner.getToken();
|
|
789
|
-
while (token !== 17) {
|
|
790
|
-
if (skipUntilAfter.indexOf(token) !== -1) {
|
|
791
|
-
scanNext();
|
|
792
|
-
break;
|
|
793
|
-
} else if (skipUntil.indexOf(token) !== -1) {
|
|
794
|
-
break;
|
|
795
|
-
}
|
|
796
|
-
token = scanNext();
|
|
797
|
-
}
|
|
798
|
-
}
|
|
799
|
-
}
|
|
800
|
-
chunkWVKPC33H_cjs.__name(handleError, "handleError");
|
|
801
|
-
function parseString(isValue) {
|
|
802
|
-
const value = _scanner.getTokenValue();
|
|
803
|
-
if (isValue) {
|
|
804
|
-
onLiteralValue(value);
|
|
805
|
-
} else {
|
|
806
|
-
onObjectProperty(value);
|
|
807
|
-
_jsonPath.push(value);
|
|
808
|
-
}
|
|
809
|
-
scanNext();
|
|
810
|
-
return true;
|
|
811
|
-
}
|
|
812
|
-
chunkWVKPC33H_cjs.__name(parseString, "parseString");
|
|
813
|
-
function parseLiteral() {
|
|
814
|
-
switch (_scanner.getToken()) {
|
|
815
|
-
case 11:
|
|
816
|
-
const tokenValue = _scanner.getTokenValue();
|
|
817
|
-
let value = Number(tokenValue);
|
|
818
|
-
if (isNaN(value)) {
|
|
819
|
-
handleError(
|
|
820
|
-
2
|
|
821
|
-
/* ParseErrorCode.InvalidNumberFormat */
|
|
822
|
-
);
|
|
823
|
-
value = 0;
|
|
824
|
-
}
|
|
825
|
-
onLiteralValue(value);
|
|
826
|
-
break;
|
|
827
|
-
case 7:
|
|
828
|
-
onLiteralValue(null);
|
|
829
|
-
break;
|
|
830
|
-
case 8:
|
|
831
|
-
onLiteralValue(true);
|
|
832
|
-
break;
|
|
833
|
-
case 9:
|
|
834
|
-
onLiteralValue(false);
|
|
835
|
-
break;
|
|
836
|
-
default:
|
|
837
|
-
return false;
|
|
838
|
-
}
|
|
839
|
-
scanNext();
|
|
840
|
-
return true;
|
|
841
|
-
}
|
|
842
|
-
chunkWVKPC33H_cjs.__name(parseLiteral, "parseLiteral");
|
|
843
|
-
function parseProperty() {
|
|
844
|
-
if (_scanner.getToken() !== 10) {
|
|
845
|
-
handleError(3, [], [
|
|
846
|
-
2,
|
|
847
|
-
5
|
|
848
|
-
/* SyntaxKind.CommaToken */
|
|
849
|
-
]);
|
|
850
|
-
return false;
|
|
851
|
-
}
|
|
852
|
-
parseString(false);
|
|
853
|
-
if (_scanner.getToken() === 6) {
|
|
854
|
-
onSeparator(":");
|
|
855
|
-
scanNext();
|
|
856
|
-
if (!parseValue()) {
|
|
857
|
-
handleError(4, [], [
|
|
858
|
-
2,
|
|
859
|
-
5
|
|
860
|
-
/* SyntaxKind.CommaToken */
|
|
861
|
-
]);
|
|
862
|
-
}
|
|
863
|
-
} else {
|
|
864
|
-
handleError(5, [], [
|
|
865
|
-
2,
|
|
866
|
-
5
|
|
867
|
-
/* SyntaxKind.CommaToken */
|
|
868
|
-
]);
|
|
869
|
-
}
|
|
870
|
-
_jsonPath.pop();
|
|
871
|
-
return true;
|
|
872
|
-
}
|
|
873
|
-
chunkWVKPC33H_cjs.__name(parseProperty, "parseProperty");
|
|
874
|
-
function parseObject() {
|
|
875
|
-
onObjectBegin();
|
|
876
|
-
scanNext();
|
|
877
|
-
let needsComma = false;
|
|
878
|
-
while (_scanner.getToken() !== 2 && _scanner.getToken() !== 17) {
|
|
879
|
-
if (_scanner.getToken() === 5) {
|
|
880
|
-
if (!needsComma) {
|
|
881
|
-
handleError(4, [], []);
|
|
882
|
-
}
|
|
883
|
-
onSeparator(",");
|
|
884
|
-
scanNext();
|
|
885
|
-
if (_scanner.getToken() === 2 && allowTrailingComma) {
|
|
886
|
-
break;
|
|
887
|
-
}
|
|
888
|
-
} else if (needsComma) {
|
|
889
|
-
handleError(6, [], []);
|
|
890
|
-
}
|
|
891
|
-
if (!parseProperty()) {
|
|
892
|
-
handleError(4, [], [
|
|
893
|
-
2,
|
|
894
|
-
5
|
|
895
|
-
/* SyntaxKind.CommaToken */
|
|
896
|
-
]);
|
|
897
|
-
}
|
|
898
|
-
needsComma = true;
|
|
899
|
-
}
|
|
900
|
-
onObjectEnd();
|
|
901
|
-
if (_scanner.getToken() !== 2) {
|
|
902
|
-
handleError(7, [
|
|
903
|
-
2
|
|
904
|
-
/* SyntaxKind.CloseBraceToken */
|
|
905
|
-
], []);
|
|
906
|
-
} else {
|
|
907
|
-
scanNext();
|
|
908
|
-
}
|
|
909
|
-
return true;
|
|
910
|
-
}
|
|
911
|
-
chunkWVKPC33H_cjs.__name(parseObject, "parseObject");
|
|
912
|
-
function parseArray() {
|
|
913
|
-
onArrayBegin();
|
|
914
|
-
scanNext();
|
|
915
|
-
let isFirstElement = true;
|
|
916
|
-
let needsComma = false;
|
|
917
|
-
while (_scanner.getToken() !== 4 && _scanner.getToken() !== 17) {
|
|
918
|
-
if (_scanner.getToken() === 5) {
|
|
919
|
-
if (!needsComma) {
|
|
920
|
-
handleError(4, [], []);
|
|
921
|
-
}
|
|
922
|
-
onSeparator(",");
|
|
923
|
-
scanNext();
|
|
924
|
-
if (_scanner.getToken() === 4 && allowTrailingComma) {
|
|
925
|
-
break;
|
|
926
|
-
}
|
|
927
|
-
} else if (needsComma) {
|
|
928
|
-
handleError(6, [], []);
|
|
929
|
-
}
|
|
930
|
-
if (isFirstElement) {
|
|
931
|
-
_jsonPath.push(0);
|
|
932
|
-
isFirstElement = false;
|
|
933
|
-
} else {
|
|
934
|
-
_jsonPath[_jsonPath.length - 1]++;
|
|
935
|
-
}
|
|
936
|
-
if (!parseValue()) {
|
|
937
|
-
handleError(4, [], [
|
|
938
|
-
4,
|
|
939
|
-
5
|
|
940
|
-
/* SyntaxKind.CommaToken */
|
|
941
|
-
]);
|
|
942
|
-
}
|
|
943
|
-
needsComma = true;
|
|
944
|
-
}
|
|
945
|
-
onArrayEnd();
|
|
946
|
-
if (!isFirstElement) {
|
|
947
|
-
_jsonPath.pop();
|
|
948
|
-
}
|
|
949
|
-
if (_scanner.getToken() !== 4) {
|
|
950
|
-
handleError(8, [
|
|
951
|
-
4
|
|
952
|
-
/* SyntaxKind.CloseBracketToken */
|
|
953
|
-
], []);
|
|
954
|
-
} else {
|
|
955
|
-
scanNext();
|
|
956
|
-
}
|
|
957
|
-
return true;
|
|
958
|
-
}
|
|
959
|
-
chunkWVKPC33H_cjs.__name(parseArray, "parseArray");
|
|
960
|
-
function parseValue() {
|
|
961
|
-
switch (_scanner.getToken()) {
|
|
962
|
-
case 3:
|
|
963
|
-
return parseArray();
|
|
964
|
-
case 1:
|
|
965
|
-
return parseObject();
|
|
966
|
-
case 10:
|
|
967
|
-
return parseString(true);
|
|
968
|
-
default:
|
|
969
|
-
return parseLiteral();
|
|
970
|
-
}
|
|
971
|
-
}
|
|
972
|
-
chunkWVKPC33H_cjs.__name(parseValue, "parseValue");
|
|
973
|
-
scanNext();
|
|
974
|
-
if (_scanner.getToken() === 17) {
|
|
975
|
-
if (options.allowEmptyContent) {
|
|
976
|
-
return true;
|
|
977
|
-
}
|
|
978
|
-
handleError(4, [], []);
|
|
979
|
-
return false;
|
|
980
|
-
}
|
|
981
|
-
if (!parseValue()) {
|
|
982
|
-
handleError(4, [], []);
|
|
983
|
-
return false;
|
|
984
|
-
}
|
|
985
|
-
if (_scanner.getToken() !== 17) {
|
|
986
|
-
handleError(9, [], []);
|
|
987
|
-
}
|
|
988
|
-
return true;
|
|
989
|
-
}
|
|
990
|
-
chunkWVKPC33H_cjs.__name(visit, "visit");
|
|
991
|
-
|
|
992
|
-
// ../../node_modules/.pnpm/jsonc-parser@3.2.0/node_modules/jsonc-parser/lib/esm/main.js
|
|
993
|
-
var ScanError;
|
|
994
|
-
(function(ScanError2) {
|
|
995
|
-
ScanError2[ScanError2["None"] = 0] = "None";
|
|
996
|
-
ScanError2[ScanError2["UnexpectedEndOfComment"] = 1] = "UnexpectedEndOfComment";
|
|
997
|
-
ScanError2[ScanError2["UnexpectedEndOfString"] = 2] = "UnexpectedEndOfString";
|
|
998
|
-
ScanError2[ScanError2["UnexpectedEndOfNumber"] = 3] = "UnexpectedEndOfNumber";
|
|
999
|
-
ScanError2[ScanError2["InvalidUnicode"] = 4] = "InvalidUnicode";
|
|
1000
|
-
ScanError2[ScanError2["InvalidEscapeCharacter"] = 5] = "InvalidEscapeCharacter";
|
|
1001
|
-
ScanError2[ScanError2["InvalidCharacter"] = 6] = "InvalidCharacter";
|
|
1002
|
-
})(ScanError || (ScanError = {}));
|
|
1003
|
-
var SyntaxKind;
|
|
1004
|
-
(function(SyntaxKind2) {
|
|
1005
|
-
SyntaxKind2[SyntaxKind2["OpenBraceToken"] = 1] = "OpenBraceToken";
|
|
1006
|
-
SyntaxKind2[SyntaxKind2["CloseBraceToken"] = 2] = "CloseBraceToken";
|
|
1007
|
-
SyntaxKind2[SyntaxKind2["OpenBracketToken"] = 3] = "OpenBracketToken";
|
|
1008
|
-
SyntaxKind2[SyntaxKind2["CloseBracketToken"] = 4] = "CloseBracketToken";
|
|
1009
|
-
SyntaxKind2[SyntaxKind2["CommaToken"] = 5] = "CommaToken";
|
|
1010
|
-
SyntaxKind2[SyntaxKind2["ColonToken"] = 6] = "ColonToken";
|
|
1011
|
-
SyntaxKind2[SyntaxKind2["NullKeyword"] = 7] = "NullKeyword";
|
|
1012
|
-
SyntaxKind2[SyntaxKind2["TrueKeyword"] = 8] = "TrueKeyword";
|
|
1013
|
-
SyntaxKind2[SyntaxKind2["FalseKeyword"] = 9] = "FalseKeyword";
|
|
1014
|
-
SyntaxKind2[SyntaxKind2["StringLiteral"] = 10] = "StringLiteral";
|
|
1015
|
-
SyntaxKind2[SyntaxKind2["NumericLiteral"] = 11] = "NumericLiteral";
|
|
1016
|
-
SyntaxKind2[SyntaxKind2["LineCommentTrivia"] = 12] = "LineCommentTrivia";
|
|
1017
|
-
SyntaxKind2[SyntaxKind2["BlockCommentTrivia"] = 13] = "BlockCommentTrivia";
|
|
1018
|
-
SyntaxKind2[SyntaxKind2["LineBreakTrivia"] = 14] = "LineBreakTrivia";
|
|
1019
|
-
SyntaxKind2[SyntaxKind2["Trivia"] = 15] = "Trivia";
|
|
1020
|
-
SyntaxKind2[SyntaxKind2["Unknown"] = 16] = "Unknown";
|
|
1021
|
-
SyntaxKind2[SyntaxKind2["EOF"] = 17] = "EOF";
|
|
1022
|
-
})(SyntaxKind || (SyntaxKind = {}));
|
|
1023
|
-
var parse2 = parse;
|
|
1024
|
-
var ParseErrorCode;
|
|
1025
|
-
(function(ParseErrorCode2) {
|
|
1026
|
-
ParseErrorCode2[ParseErrorCode2["InvalidSymbol"] = 1] = "InvalidSymbol";
|
|
1027
|
-
ParseErrorCode2[ParseErrorCode2["InvalidNumberFormat"] = 2] = "InvalidNumberFormat";
|
|
1028
|
-
ParseErrorCode2[ParseErrorCode2["PropertyNameExpected"] = 3] = "PropertyNameExpected";
|
|
1029
|
-
ParseErrorCode2[ParseErrorCode2["ValueExpected"] = 4] = "ValueExpected";
|
|
1030
|
-
ParseErrorCode2[ParseErrorCode2["ColonExpected"] = 5] = "ColonExpected";
|
|
1031
|
-
ParseErrorCode2[ParseErrorCode2["CommaExpected"] = 6] = "CommaExpected";
|
|
1032
|
-
ParseErrorCode2[ParseErrorCode2["CloseBraceExpected"] = 7] = "CloseBraceExpected";
|
|
1033
|
-
ParseErrorCode2[ParseErrorCode2["CloseBracketExpected"] = 8] = "CloseBracketExpected";
|
|
1034
|
-
ParseErrorCode2[ParseErrorCode2["EndOfFileExpected"] = 9] = "EndOfFileExpected";
|
|
1035
|
-
ParseErrorCode2[ParseErrorCode2["InvalidCommentToken"] = 10] = "InvalidCommentToken";
|
|
1036
|
-
ParseErrorCode2[ParseErrorCode2["UnexpectedEndOfComment"] = 11] = "UnexpectedEndOfComment";
|
|
1037
|
-
ParseErrorCode2[ParseErrorCode2["UnexpectedEndOfString"] = 12] = "UnexpectedEndOfString";
|
|
1038
|
-
ParseErrorCode2[ParseErrorCode2["UnexpectedEndOfNumber"] = 13] = "UnexpectedEndOfNumber";
|
|
1039
|
-
ParseErrorCode2[ParseErrorCode2["InvalidUnicode"] = 14] = "InvalidUnicode";
|
|
1040
|
-
ParseErrorCode2[ParseErrorCode2["InvalidEscapeCharacter"] = 15] = "InvalidEscapeCharacter";
|
|
1041
|
-
ParseErrorCode2[ParseErrorCode2["InvalidCharacter"] = 16] = "InvalidCharacter";
|
|
1042
|
-
})(ParseErrorCode || (ParseErrorCode = {}));
|
|
1043
|
-
function printParseErrorCode(code) {
|
|
1044
|
-
switch (code) {
|
|
1045
|
-
case 1:
|
|
1046
|
-
return "InvalidSymbol";
|
|
1047
|
-
case 2:
|
|
1048
|
-
return "InvalidNumberFormat";
|
|
1049
|
-
case 3:
|
|
1050
|
-
return "PropertyNameExpected";
|
|
1051
|
-
case 4:
|
|
1052
|
-
return "ValueExpected";
|
|
1053
|
-
case 5:
|
|
1054
|
-
return "ColonExpected";
|
|
1055
|
-
case 6:
|
|
1056
|
-
return "CommaExpected";
|
|
1057
|
-
case 7:
|
|
1058
|
-
return "CloseBraceExpected";
|
|
1059
|
-
case 8:
|
|
1060
|
-
return "CloseBracketExpected";
|
|
1061
|
-
case 9:
|
|
1062
|
-
return "EndOfFileExpected";
|
|
1063
|
-
case 10:
|
|
1064
|
-
return "InvalidCommentToken";
|
|
1065
|
-
case 11:
|
|
1066
|
-
return "UnexpectedEndOfComment";
|
|
1067
|
-
case 12:
|
|
1068
|
-
return "UnexpectedEndOfString";
|
|
1069
|
-
case 13:
|
|
1070
|
-
return "UnexpectedEndOfNumber";
|
|
1071
|
-
case 14:
|
|
1072
|
-
return "InvalidUnicode";
|
|
1073
|
-
case 15:
|
|
1074
|
-
return "InvalidEscapeCharacter";
|
|
1075
|
-
case 16:
|
|
1076
|
-
return "InvalidCharacter";
|
|
1077
|
-
}
|
|
1078
|
-
return "<unknown ParseErrorCode>";
|
|
1079
|
-
}
|
|
1080
|
-
chunkWVKPC33H_cjs.__name(printParseErrorCode, "printParseErrorCode");
|
|
1081
|
-
|
|
1082
|
-
// ../../node_modules/.pnpm/lines-and-columns@2.0.4/node_modules/lines-and-columns/build/index.mjs
|
|
1083
|
-
chunkWVKPC33H_cjs.init_cjs_shims();
|
|
1084
|
-
var LF = "\n";
|
|
1085
|
-
var CR = "\r";
|
|
1086
|
-
var LinesAndColumns = (
|
|
1087
|
-
/** @class */
|
|
1088
|
-
(function() {
|
|
1089
|
-
function LinesAndColumns2(string) {
|
|
1090
|
-
this.length = string.length;
|
|
1091
|
-
var offsets = [0];
|
|
1092
|
-
for (var offset = 0; offset < string.length; ) {
|
|
1093
|
-
switch (string[offset]) {
|
|
1094
|
-
case LF:
|
|
1095
|
-
offset += LF.length;
|
|
1096
|
-
offsets.push(offset);
|
|
1097
|
-
break;
|
|
1098
|
-
case CR:
|
|
1099
|
-
offset += CR.length;
|
|
1100
|
-
if (string[offset] === LF) {
|
|
1101
|
-
offset += LF.length;
|
|
1102
|
-
}
|
|
1103
|
-
offsets.push(offset);
|
|
1104
|
-
break;
|
|
1105
|
-
default:
|
|
1106
|
-
offset++;
|
|
1107
|
-
break;
|
|
1108
|
-
}
|
|
1109
|
-
}
|
|
1110
|
-
this.offsets = offsets;
|
|
1111
|
-
}
|
|
1112
|
-
chunkWVKPC33H_cjs.__name(LinesAndColumns2, "LinesAndColumns");
|
|
1113
|
-
LinesAndColumns2.prototype.locationForIndex = function(index) {
|
|
1114
|
-
if (index < 0 || index > this.length) {
|
|
1115
|
-
return null;
|
|
1116
|
-
}
|
|
1117
|
-
var line = 0;
|
|
1118
|
-
var offsets = this.offsets;
|
|
1119
|
-
while (offsets[line + 1] <= index) {
|
|
1120
|
-
line++;
|
|
1121
|
-
}
|
|
1122
|
-
var column = index - offsets[line];
|
|
1123
|
-
return { line, column };
|
|
1124
|
-
};
|
|
1125
|
-
LinesAndColumns2.prototype.indexForLocation = function(location) {
|
|
1126
|
-
var line = location.line, column = location.column;
|
|
1127
|
-
if (line < 0 || line >= this.offsets.length) {
|
|
1128
|
-
return null;
|
|
1129
|
-
}
|
|
1130
|
-
if (column < 0 || column > this.lengthOfLine(line)) {
|
|
1131
|
-
return null;
|
|
1132
|
-
}
|
|
1133
|
-
return this.offsets[line] + column;
|
|
1134
|
-
};
|
|
1135
|
-
LinesAndColumns2.prototype.lengthOfLine = function(line) {
|
|
1136
|
-
var offset = this.offsets[line];
|
|
1137
|
-
var nextOffset = line === this.offsets.length - 1 ? this.length : this.offsets[line + 1];
|
|
1138
|
-
return nextOffset - offset;
|
|
1139
|
-
};
|
|
1140
|
-
return LinesAndColumns2;
|
|
1141
|
-
})()
|
|
1142
|
-
);
|
|
1143
|
-
|
|
1144
|
-
// ../../node_modules/.pnpm/@stryke+json@0.9.32/node_modules/@stryke/json/dist/utils/parse-error.mjs
|
|
1145
|
-
function r3(r5, i3) {
|
|
1146
|
-
let { error: a3, offset: o4, length: s } = i3, c2 = new LinesAndColumns(r5).locationForIndex(o4), l = c2?.line ?? 0, u = c2?.column ?? 0;
|
|
1147
|
-
return l++, u++, `${printParseErrorCode(a3)} in JSON at ${l}:${u}
|
|
1148
|
-
${n4(r5, { start: { line: l, column: u }, end: { line: l, column: u + s } })}
|
|
1149
|
-
`;
|
|
1150
|
-
}
|
|
1151
|
-
chunkWVKPC33H_cjs.__name(r3, "r");
|
|
1152
|
-
|
|
1153
|
-
// ../../node_modules/.pnpm/@stryke+json@0.9.32/node_modules/@stryke/json/dist/utils/stringify.mjs
|
|
1154
|
-
chunkWVKPC33H_cjs.init_cjs_shims();
|
|
1155
|
-
|
|
1156
|
-
// ../../node_modules/.pnpm/@stryke+json@0.9.32/node_modules/@stryke/json/dist/type-checks/src/is-number.mjs
|
|
1157
|
-
chunkWVKPC33H_cjs.init_cjs_shims();
|
|
1158
|
-
var e5 = /* @__PURE__ */ chunkWVKPC33H_cjs.__name((e7) => {
|
|
1159
|
-
try {
|
|
1160
|
-
return e7 instanceof Number || typeof e7 == `number` || Number(e7) === e7;
|
|
1161
|
-
} catch {
|
|
1162
|
-
return false;
|
|
1163
|
-
}
|
|
1164
|
-
}, "e");
|
|
1165
|
-
|
|
1166
|
-
// ../../node_modules/.pnpm/@stryke+json@0.9.32/node_modules/@stryke/json/dist/type-checks/src/is-undefined.mjs
|
|
1167
|
-
chunkWVKPC33H_cjs.init_cjs_shims();
|
|
1168
|
-
var e6 = /* @__PURE__ */ chunkWVKPC33H_cjs.__name((e7) => e7 === void 0, "e");
|
|
1169
|
-
|
|
1170
|
-
// ../../node_modules/.pnpm/@stryke+json@0.9.32/node_modules/@stryke/json/dist/utils/stringify.mjs
|
|
1171
|
-
var n5 = `@/#$ :;,.!?&=+-*%^~|\\"'\`{}[]()<>`.split(``);
|
|
1172
|
-
var r4 = /* @__PURE__ */ chunkWVKPC33H_cjs.__name((i3, a3 = 2) => {
|
|
1173
|
-
let o4 = e5(a3) ? ` `.repeat(a3) : a3;
|
|
1174
|
-
switch (i3) {
|
|
1175
|
-
case null:
|
|
1176
|
-
return `null`;
|
|
1177
|
-
case void 0:
|
|
1178
|
-
return `"undefined"`;
|
|
1179
|
-
case true:
|
|
1180
|
-
return `true`;
|
|
1181
|
-
case false:
|
|
1182
|
-
return `false`;
|
|
1183
|
-
case 1 / 0:
|
|
1184
|
-
return `infinity`;
|
|
1185
|
-
case -1 / 0:
|
|
1186
|
-
return `-infinity`;
|
|
1187
|
-
}
|
|
1188
|
-
if (Array.isArray(i3)) return `[${o4}${i3.map((e7) => r4(e7, o4)).join(`,${o4}`)}${o4}]`;
|
|
1189
|
-
if (i3 instanceof Uint8Array) return i3.toString();
|
|
1190
|
-
switch (typeof i3) {
|
|
1191
|
-
case `number`:
|
|
1192
|
-
return `${i3}`;
|
|
1193
|
-
case `string`:
|
|
1194
|
-
return JSON.stringify(i3);
|
|
1195
|
-
case `object`:
|
|
1196
|
-
return `{${o4}${Object.keys(i3).filter((e7) => !e6(i3[e7])).map((e7) => `${n5.some((t7) => e7.includes(t7)) ? `"${e7}"` : e7}: ${o4}${r4(i3[e7], o4)}`).join(`,${o4}`)}${o4}}`;
|
|
1197
|
-
default:
|
|
1198
|
-
return `null`;
|
|
1199
|
-
}
|
|
1200
|
-
}, "r");
|
|
1201
|
-
|
|
1202
|
-
// ../../node_modules/.pnpm/superjson@2.2.2/node_modules/superjson/dist/index.js
|
|
1203
|
-
chunkWVKPC33H_cjs.init_cjs_shims();
|
|
1204
|
-
|
|
1205
|
-
// ../../node_modules/.pnpm/superjson@2.2.2/node_modules/superjson/dist/class-registry.js
|
|
1206
|
-
chunkWVKPC33H_cjs.init_cjs_shims();
|
|
1207
|
-
|
|
1208
|
-
// ../../node_modules/.pnpm/superjson@2.2.2/node_modules/superjson/dist/registry.js
|
|
1209
|
-
chunkWVKPC33H_cjs.init_cjs_shims();
|
|
1210
|
-
|
|
1211
|
-
// ../../node_modules/.pnpm/superjson@2.2.2/node_modules/superjson/dist/double-indexed-kv.js
|
|
1212
|
-
chunkWVKPC33H_cjs.init_cjs_shims();
|
|
1213
|
-
var DoubleIndexedKV = class {
|
|
1214
|
-
static {
|
|
1215
|
-
chunkWVKPC33H_cjs.__name(this, "DoubleIndexedKV");
|
|
1216
|
-
}
|
|
1217
|
-
constructor() {
|
|
1218
|
-
this.keyToValue = /* @__PURE__ */ new Map();
|
|
1219
|
-
this.valueToKey = /* @__PURE__ */ new Map();
|
|
1220
|
-
}
|
|
1221
|
-
set(key, value) {
|
|
1222
|
-
this.keyToValue.set(key, value);
|
|
1223
|
-
this.valueToKey.set(value, key);
|
|
1224
|
-
}
|
|
1225
|
-
getByKey(key) {
|
|
1226
|
-
return this.keyToValue.get(key);
|
|
1227
|
-
}
|
|
1228
|
-
getByValue(value) {
|
|
1229
|
-
return this.valueToKey.get(value);
|
|
1230
|
-
}
|
|
1231
|
-
clear() {
|
|
1232
|
-
this.keyToValue.clear();
|
|
1233
|
-
this.valueToKey.clear();
|
|
1234
|
-
}
|
|
1235
|
-
};
|
|
1236
|
-
|
|
1237
|
-
// ../../node_modules/.pnpm/superjson@2.2.2/node_modules/superjson/dist/registry.js
|
|
1238
|
-
var Registry = class {
|
|
1239
|
-
static {
|
|
1240
|
-
chunkWVKPC33H_cjs.__name(this, "Registry");
|
|
1241
|
-
}
|
|
1242
|
-
constructor(generateIdentifier) {
|
|
1243
|
-
this.generateIdentifier = generateIdentifier;
|
|
1244
|
-
this.kv = new DoubleIndexedKV();
|
|
1245
|
-
}
|
|
1246
|
-
register(value, identifier) {
|
|
1247
|
-
if (this.kv.getByValue(value)) {
|
|
1248
|
-
return;
|
|
1249
|
-
}
|
|
1250
|
-
if (!identifier) {
|
|
1251
|
-
identifier = this.generateIdentifier(value);
|
|
1252
|
-
}
|
|
1253
|
-
this.kv.set(identifier, value);
|
|
1254
|
-
}
|
|
1255
|
-
clear() {
|
|
1256
|
-
this.kv.clear();
|
|
1257
|
-
}
|
|
1258
|
-
getIdentifier(value) {
|
|
1259
|
-
return this.kv.getByValue(value);
|
|
1260
|
-
}
|
|
1261
|
-
getValue(identifier) {
|
|
1262
|
-
return this.kv.getByKey(identifier);
|
|
1263
|
-
}
|
|
1264
|
-
};
|
|
1265
|
-
|
|
1266
|
-
// ../../node_modules/.pnpm/superjson@2.2.2/node_modules/superjson/dist/class-registry.js
|
|
1267
|
-
var ClassRegistry = class extends Registry {
|
|
1268
|
-
static {
|
|
1269
|
-
chunkWVKPC33H_cjs.__name(this, "ClassRegistry");
|
|
1270
|
-
}
|
|
1271
|
-
constructor() {
|
|
1272
|
-
super((c2) => c2.name);
|
|
1273
|
-
this.classToAllowedProps = /* @__PURE__ */ new Map();
|
|
1274
|
-
}
|
|
1275
|
-
register(value, options) {
|
|
1276
|
-
if (typeof options === "object") {
|
|
1277
|
-
if (options.allowProps) {
|
|
1278
|
-
this.classToAllowedProps.set(value, options.allowProps);
|
|
1279
|
-
}
|
|
1280
|
-
super.register(value, options.identifier);
|
|
1281
|
-
} else {
|
|
1282
|
-
super.register(value, options);
|
|
1283
|
-
}
|
|
1284
|
-
}
|
|
1285
|
-
getAllowedProps(value) {
|
|
1286
|
-
return this.classToAllowedProps.get(value);
|
|
1287
|
-
}
|
|
1288
|
-
};
|
|
1289
|
-
|
|
1290
|
-
// ../../node_modules/.pnpm/superjson@2.2.2/node_modules/superjson/dist/custom-transformer-registry.js
|
|
1291
|
-
chunkWVKPC33H_cjs.init_cjs_shims();
|
|
1292
|
-
|
|
1293
|
-
// ../../node_modules/.pnpm/superjson@2.2.2/node_modules/superjson/dist/util.js
|
|
1294
|
-
chunkWVKPC33H_cjs.init_cjs_shims();
|
|
1295
|
-
function valuesOfObj(record) {
|
|
1296
|
-
if ("values" in Object) {
|
|
1297
|
-
return Object.values(record);
|
|
1298
|
-
}
|
|
1299
|
-
const values = [];
|
|
1300
|
-
for (const key in record) {
|
|
1301
|
-
if (record.hasOwnProperty(key)) {
|
|
1302
|
-
values.push(record[key]);
|
|
1303
|
-
}
|
|
1304
|
-
}
|
|
1305
|
-
return values;
|
|
1306
|
-
}
|
|
1307
|
-
chunkWVKPC33H_cjs.__name(valuesOfObj, "valuesOfObj");
|
|
1308
|
-
function find(record, predicate) {
|
|
1309
|
-
const values = valuesOfObj(record);
|
|
1310
|
-
if ("find" in values) {
|
|
1311
|
-
return values.find(predicate);
|
|
1312
|
-
}
|
|
1313
|
-
const valuesNotNever = values;
|
|
1314
|
-
for (let i3 = 0; i3 < valuesNotNever.length; i3++) {
|
|
1315
|
-
const value = valuesNotNever[i3];
|
|
1316
|
-
if (predicate(value)) {
|
|
1317
|
-
return value;
|
|
1318
|
-
}
|
|
1319
|
-
}
|
|
1320
|
-
return void 0;
|
|
1321
|
-
}
|
|
1322
|
-
chunkWVKPC33H_cjs.__name(find, "find");
|
|
1323
|
-
function forEach(record, run) {
|
|
1324
|
-
Object.entries(record).forEach(([key, value]) => run(value, key));
|
|
1325
|
-
}
|
|
1326
|
-
chunkWVKPC33H_cjs.__name(forEach, "forEach");
|
|
1327
|
-
function includes(arr, value) {
|
|
1328
|
-
return arr.indexOf(value) !== -1;
|
|
1329
|
-
}
|
|
1330
|
-
chunkWVKPC33H_cjs.__name(includes, "includes");
|
|
1331
|
-
function findArr(record, predicate) {
|
|
1332
|
-
for (let i3 = 0; i3 < record.length; i3++) {
|
|
1333
|
-
const value = record[i3];
|
|
1334
|
-
if (predicate(value)) {
|
|
1335
|
-
return value;
|
|
1336
|
-
}
|
|
1337
|
-
}
|
|
1338
|
-
return void 0;
|
|
1339
|
-
}
|
|
1340
|
-
chunkWVKPC33H_cjs.__name(findArr, "findArr");
|
|
1341
|
-
|
|
1342
|
-
// ../../node_modules/.pnpm/superjson@2.2.2/node_modules/superjson/dist/custom-transformer-registry.js
|
|
1343
|
-
var CustomTransformerRegistry = class {
|
|
1344
|
-
static {
|
|
1345
|
-
chunkWVKPC33H_cjs.__name(this, "CustomTransformerRegistry");
|
|
1346
|
-
}
|
|
1347
|
-
constructor() {
|
|
1348
|
-
this.transfomers = {};
|
|
1349
|
-
}
|
|
1350
|
-
register(transformer) {
|
|
1351
|
-
this.transfomers[transformer.name] = transformer;
|
|
1352
|
-
}
|
|
1353
|
-
findApplicable(v) {
|
|
1354
|
-
return find(this.transfomers, (transformer) => transformer.isApplicable(v));
|
|
1355
|
-
}
|
|
1356
|
-
findByName(name) {
|
|
1357
|
-
return this.transfomers[name];
|
|
1358
|
-
}
|
|
1359
|
-
};
|
|
1360
|
-
|
|
1361
|
-
// ../../node_modules/.pnpm/superjson@2.2.2/node_modules/superjson/dist/plainer.js
|
|
1362
|
-
chunkWVKPC33H_cjs.init_cjs_shims();
|
|
1363
|
-
|
|
1364
|
-
// ../../node_modules/.pnpm/superjson@2.2.2/node_modules/superjson/dist/is.js
|
|
1365
|
-
chunkWVKPC33H_cjs.init_cjs_shims();
|
|
1366
|
-
var getType = /* @__PURE__ */ chunkWVKPC33H_cjs.__name((payload) => Object.prototype.toString.call(payload).slice(8, -1), "getType");
|
|
1367
|
-
var isUndefined = /* @__PURE__ */ chunkWVKPC33H_cjs.__name((payload) => typeof payload === "undefined", "isUndefined");
|
|
1368
|
-
var isNull = /* @__PURE__ */ chunkWVKPC33H_cjs.__name((payload) => payload === null, "isNull");
|
|
1369
|
-
var isPlainObject = /* @__PURE__ */ chunkWVKPC33H_cjs.__name((payload) => {
|
|
1370
|
-
if (typeof payload !== "object" || payload === null) return false;
|
|
1371
|
-
if (payload === Object.prototype) return false;
|
|
1372
|
-
if (Object.getPrototypeOf(payload) === null) return true;
|
|
1373
|
-
return Object.getPrototypeOf(payload) === Object.prototype;
|
|
1374
|
-
}, "isPlainObject");
|
|
1375
|
-
var isEmptyObject = /* @__PURE__ */ chunkWVKPC33H_cjs.__name((payload) => isPlainObject(payload) && Object.keys(payload).length === 0, "isEmptyObject");
|
|
1376
|
-
var isArray = /* @__PURE__ */ chunkWVKPC33H_cjs.__name((payload) => Array.isArray(payload), "isArray");
|
|
1377
|
-
var isString = /* @__PURE__ */ chunkWVKPC33H_cjs.__name((payload) => typeof payload === "string", "isString");
|
|
1378
|
-
var isNumber = /* @__PURE__ */ chunkWVKPC33H_cjs.__name((payload) => typeof payload === "number" && !isNaN(payload), "isNumber");
|
|
1379
|
-
var isBoolean = /* @__PURE__ */ chunkWVKPC33H_cjs.__name((payload) => typeof payload === "boolean", "isBoolean");
|
|
1380
|
-
var isRegExp = /* @__PURE__ */ chunkWVKPC33H_cjs.__name((payload) => payload instanceof RegExp, "isRegExp");
|
|
1381
|
-
var isMap = /* @__PURE__ */ chunkWVKPC33H_cjs.__name((payload) => payload instanceof Map, "isMap");
|
|
1382
|
-
var isSet = /* @__PURE__ */ chunkWVKPC33H_cjs.__name((payload) => payload instanceof Set, "isSet");
|
|
1383
|
-
var isSymbol = /* @__PURE__ */ chunkWVKPC33H_cjs.__name((payload) => getType(payload) === "Symbol", "isSymbol");
|
|
1384
|
-
var isDate = /* @__PURE__ */ chunkWVKPC33H_cjs.__name((payload) => payload instanceof Date && !isNaN(payload.valueOf()), "isDate");
|
|
1385
|
-
var isError = /* @__PURE__ */ chunkWVKPC33H_cjs.__name((payload) => payload instanceof Error, "isError");
|
|
1386
|
-
var isNaNValue = /* @__PURE__ */ chunkWVKPC33H_cjs.__name((payload) => typeof payload === "number" && isNaN(payload), "isNaNValue");
|
|
1387
|
-
var isPrimitive = /* @__PURE__ */ chunkWVKPC33H_cjs.__name((payload) => isBoolean(payload) || isNull(payload) || isUndefined(payload) || isNumber(payload) || isString(payload) || isSymbol(payload), "isPrimitive");
|
|
1388
|
-
var isBigint = /* @__PURE__ */ chunkWVKPC33H_cjs.__name((payload) => typeof payload === "bigint", "isBigint");
|
|
1389
|
-
var isInfinite = /* @__PURE__ */ chunkWVKPC33H_cjs.__name((payload) => payload === Infinity || payload === -Infinity, "isInfinite");
|
|
1390
|
-
var isTypedArray = /* @__PURE__ */ chunkWVKPC33H_cjs.__name((payload) => ArrayBuffer.isView(payload) && !(payload instanceof DataView), "isTypedArray");
|
|
1391
|
-
var isURL = /* @__PURE__ */ chunkWVKPC33H_cjs.__name((payload) => payload instanceof URL, "isURL");
|
|
1392
|
-
|
|
1393
|
-
// ../../node_modules/.pnpm/superjson@2.2.2/node_modules/superjson/dist/pathstringifier.js
|
|
1394
|
-
chunkWVKPC33H_cjs.init_cjs_shims();
|
|
1395
|
-
var escapeKey = /* @__PURE__ */ chunkWVKPC33H_cjs.__name((key) => key.replace(/\./g, "\\."), "escapeKey");
|
|
1396
|
-
var stringifyPath = /* @__PURE__ */ chunkWVKPC33H_cjs.__name((path) => path.map(String).map(escapeKey).join("."), "stringifyPath");
|
|
1397
|
-
var parsePath = /* @__PURE__ */ chunkWVKPC33H_cjs.__name((string) => {
|
|
1398
|
-
const result = [];
|
|
1399
|
-
let segment = "";
|
|
1400
|
-
for (let i3 = 0; i3 < string.length; i3++) {
|
|
1401
|
-
let char = string.charAt(i3);
|
|
1402
|
-
const isEscapedDot = char === "\\" && string.charAt(i3 + 1) === ".";
|
|
1403
|
-
if (isEscapedDot) {
|
|
1404
|
-
segment += ".";
|
|
1405
|
-
i3++;
|
|
1406
|
-
continue;
|
|
1407
|
-
}
|
|
1408
|
-
const isEndOfSegment = char === ".";
|
|
1409
|
-
if (isEndOfSegment) {
|
|
1410
|
-
result.push(segment);
|
|
1411
|
-
segment = "";
|
|
1412
|
-
continue;
|
|
1413
|
-
}
|
|
1414
|
-
segment += char;
|
|
1415
|
-
}
|
|
1416
|
-
const lastSegment = segment;
|
|
1417
|
-
result.push(lastSegment);
|
|
1418
|
-
return result;
|
|
1419
|
-
}, "parsePath");
|
|
1420
|
-
|
|
1421
|
-
// ../../node_modules/.pnpm/superjson@2.2.2/node_modules/superjson/dist/transformer.js
|
|
1422
|
-
chunkWVKPC33H_cjs.init_cjs_shims();
|
|
1423
|
-
function simpleTransformation(isApplicable, annotation, transform, untransform) {
|
|
1424
|
-
return {
|
|
1425
|
-
isApplicable,
|
|
1426
|
-
annotation,
|
|
1427
|
-
transform,
|
|
1428
|
-
untransform
|
|
1429
|
-
};
|
|
1430
|
-
}
|
|
1431
|
-
chunkWVKPC33H_cjs.__name(simpleTransformation, "simpleTransformation");
|
|
1432
|
-
var simpleRules = [
|
|
1433
|
-
simpleTransformation(isUndefined, "undefined", () => null, () => void 0),
|
|
1434
|
-
simpleTransformation(isBigint, "bigint", (v) => v.toString(), (v) => {
|
|
1435
|
-
if (typeof BigInt !== "undefined") {
|
|
1436
|
-
return BigInt(v);
|
|
1437
|
-
}
|
|
1438
|
-
console.error("Please add a BigInt polyfill.");
|
|
1439
|
-
return v;
|
|
1440
|
-
}),
|
|
1441
|
-
simpleTransformation(isDate, "Date", (v) => v.toISOString(), (v) => new Date(v)),
|
|
1442
|
-
simpleTransformation(isError, "Error", (v, superJson) => {
|
|
1443
|
-
const baseError = {
|
|
1444
|
-
name: v.name,
|
|
1445
|
-
message: v.message
|
|
1446
|
-
};
|
|
1447
|
-
superJson.allowedErrorProps.forEach((prop) => {
|
|
1448
|
-
baseError[prop] = v[prop];
|
|
1449
|
-
});
|
|
1450
|
-
return baseError;
|
|
1451
|
-
}, (v, superJson) => {
|
|
1452
|
-
const e7 = new Error(v.message);
|
|
1453
|
-
e7.name = v.name;
|
|
1454
|
-
e7.stack = v.stack;
|
|
1455
|
-
superJson.allowedErrorProps.forEach((prop) => {
|
|
1456
|
-
e7[prop] = v[prop];
|
|
1457
|
-
});
|
|
1458
|
-
return e7;
|
|
1459
|
-
}),
|
|
1460
|
-
simpleTransformation(isRegExp, "regexp", (v) => "" + v, (regex) => {
|
|
1461
|
-
const body = regex.slice(1, regex.lastIndexOf("/"));
|
|
1462
|
-
const flags = regex.slice(regex.lastIndexOf("/") + 1);
|
|
1463
|
-
return new RegExp(body, flags);
|
|
1464
|
-
}),
|
|
1465
|
-
simpleTransformation(
|
|
1466
|
-
isSet,
|
|
1467
|
-
"set",
|
|
1468
|
-
// (sets only exist in es6+)
|
|
1469
|
-
// eslint-disable-next-line es5/no-es6-methods
|
|
1470
|
-
(v) => [
|
|
1471
|
-
...v.values()
|
|
1472
|
-
],
|
|
1473
|
-
(v) => new Set(v)
|
|
1474
|
-
),
|
|
1475
|
-
simpleTransformation(isMap, "map", (v) => [
|
|
1476
|
-
...v.entries()
|
|
1477
|
-
], (v) => new Map(v)),
|
|
1478
|
-
simpleTransformation((v) => isNaNValue(v) || isInfinite(v), "number", (v) => {
|
|
1479
|
-
if (isNaNValue(v)) {
|
|
1480
|
-
return "NaN";
|
|
1481
|
-
}
|
|
1482
|
-
if (v > 0) {
|
|
1483
|
-
return "Infinity";
|
|
1484
|
-
} else {
|
|
1485
|
-
return "-Infinity";
|
|
1486
|
-
}
|
|
1487
|
-
}, Number),
|
|
1488
|
-
simpleTransformation((v) => v === 0 && 1 / v === -Infinity, "number", () => {
|
|
1489
|
-
return "-0";
|
|
1490
|
-
}, Number),
|
|
1491
|
-
simpleTransformation(isURL, "URL", (v) => v.toString(), (v) => new URL(v))
|
|
1492
|
-
];
|
|
1493
|
-
function compositeTransformation(isApplicable, annotation, transform, untransform) {
|
|
1494
|
-
return {
|
|
1495
|
-
isApplicable,
|
|
1496
|
-
annotation,
|
|
1497
|
-
transform,
|
|
1498
|
-
untransform
|
|
1499
|
-
};
|
|
1500
|
-
}
|
|
1501
|
-
chunkWVKPC33H_cjs.__name(compositeTransformation, "compositeTransformation");
|
|
1502
|
-
var symbolRule = compositeTransformation((s, superJson) => {
|
|
1503
|
-
if (isSymbol(s)) {
|
|
1504
|
-
const isRegistered = !!superJson.symbolRegistry.getIdentifier(s);
|
|
1505
|
-
return isRegistered;
|
|
1506
|
-
}
|
|
1507
|
-
return false;
|
|
1508
|
-
}, (s, superJson) => {
|
|
1509
|
-
const identifier = superJson.symbolRegistry.getIdentifier(s);
|
|
1510
|
-
return [
|
|
1511
|
-
"symbol",
|
|
1512
|
-
identifier
|
|
1513
|
-
];
|
|
1514
|
-
}, (v) => v.description, (_, a3, superJson) => {
|
|
1515
|
-
const value = superJson.symbolRegistry.getValue(a3[1]);
|
|
1516
|
-
if (!value) {
|
|
1517
|
-
throw new Error("Trying to deserialize unknown symbol");
|
|
1518
|
-
}
|
|
1519
|
-
return value;
|
|
1520
|
-
});
|
|
1521
|
-
var constructorToName = [
|
|
1522
|
-
Int8Array,
|
|
1523
|
-
Uint8Array,
|
|
1524
|
-
Int16Array,
|
|
1525
|
-
Uint16Array,
|
|
1526
|
-
Int32Array,
|
|
1527
|
-
Uint32Array,
|
|
1528
|
-
Float32Array,
|
|
1529
|
-
Float64Array,
|
|
1530
|
-
Uint8ClampedArray
|
|
1531
|
-
].reduce((obj, ctor) => {
|
|
1532
|
-
obj[ctor.name] = ctor;
|
|
1533
|
-
return obj;
|
|
1534
|
-
}, {});
|
|
1535
|
-
var typedArrayRule = compositeTransformation(isTypedArray, (v) => [
|
|
1536
|
-
"typed-array",
|
|
1537
|
-
v.constructor.name
|
|
1538
|
-
], (v) => [
|
|
1539
|
-
...v
|
|
1540
|
-
], (v, a3) => {
|
|
1541
|
-
const ctor = constructorToName[a3[1]];
|
|
1542
|
-
if (!ctor) {
|
|
1543
|
-
throw new Error("Trying to deserialize unknown typed array");
|
|
1544
|
-
}
|
|
1545
|
-
return new ctor(v);
|
|
1546
|
-
});
|
|
1547
|
-
function isInstanceOfRegisteredClass(potentialClass, superJson) {
|
|
1548
|
-
if (potentialClass?.constructor) {
|
|
1549
|
-
const isRegistered = !!superJson.classRegistry.getIdentifier(potentialClass.constructor);
|
|
1550
|
-
return isRegistered;
|
|
1551
|
-
}
|
|
1552
|
-
return false;
|
|
1553
|
-
}
|
|
1554
|
-
chunkWVKPC33H_cjs.__name(isInstanceOfRegisteredClass, "isInstanceOfRegisteredClass");
|
|
1555
|
-
var classRule = compositeTransformation(isInstanceOfRegisteredClass, (clazz, superJson) => {
|
|
1556
|
-
const identifier = superJson.classRegistry.getIdentifier(clazz.constructor);
|
|
1557
|
-
return [
|
|
1558
|
-
"class",
|
|
1559
|
-
identifier
|
|
1560
|
-
];
|
|
1561
|
-
}, (clazz, superJson) => {
|
|
1562
|
-
const allowedProps = superJson.classRegistry.getAllowedProps(clazz.constructor);
|
|
1563
|
-
if (!allowedProps) {
|
|
1564
|
-
return {
|
|
1565
|
-
...clazz
|
|
1566
|
-
};
|
|
1567
|
-
}
|
|
1568
|
-
const result = {};
|
|
1569
|
-
allowedProps.forEach((prop) => {
|
|
1570
|
-
result[prop] = clazz[prop];
|
|
1571
|
-
});
|
|
1572
|
-
return result;
|
|
1573
|
-
}, (v, a3, superJson) => {
|
|
1574
|
-
const clazz = superJson.classRegistry.getValue(a3[1]);
|
|
1575
|
-
if (!clazz) {
|
|
1576
|
-
throw new Error(`Trying to deserialize unknown class '${a3[1]}' - check https://github.com/blitz-js/superjson/issues/116#issuecomment-773996564`);
|
|
1577
|
-
}
|
|
1578
|
-
return Object.assign(Object.create(clazz.prototype), v);
|
|
1579
|
-
});
|
|
1580
|
-
var customRule = compositeTransformation((value, superJson) => {
|
|
1581
|
-
return !!superJson.customTransformerRegistry.findApplicable(value);
|
|
1582
|
-
}, (value, superJson) => {
|
|
1583
|
-
const transformer = superJson.customTransformerRegistry.findApplicable(value);
|
|
1584
|
-
return [
|
|
1585
|
-
"custom",
|
|
1586
|
-
transformer.name
|
|
1587
|
-
];
|
|
1588
|
-
}, (value, superJson) => {
|
|
1589
|
-
const transformer = superJson.customTransformerRegistry.findApplicable(value);
|
|
1590
|
-
return transformer.serialize(value);
|
|
1591
|
-
}, (v, a3, superJson) => {
|
|
1592
|
-
const transformer = superJson.customTransformerRegistry.findByName(a3[1]);
|
|
1593
|
-
if (!transformer) {
|
|
1594
|
-
throw new Error("Trying to deserialize unknown custom value");
|
|
1595
|
-
}
|
|
1596
|
-
return transformer.deserialize(v);
|
|
1597
|
-
});
|
|
1598
|
-
var compositeRules = [
|
|
1599
|
-
classRule,
|
|
1600
|
-
symbolRule,
|
|
1601
|
-
customRule,
|
|
1602
|
-
typedArrayRule
|
|
1603
|
-
];
|
|
1604
|
-
var transformValue = /* @__PURE__ */ chunkWVKPC33H_cjs.__name((value, superJson) => {
|
|
1605
|
-
const applicableCompositeRule = findArr(compositeRules, (rule) => rule.isApplicable(value, superJson));
|
|
1606
|
-
if (applicableCompositeRule) {
|
|
1607
|
-
return {
|
|
1608
|
-
value: applicableCompositeRule.transform(value, superJson),
|
|
1609
|
-
type: applicableCompositeRule.annotation(value, superJson)
|
|
1610
|
-
};
|
|
1611
|
-
}
|
|
1612
|
-
const applicableSimpleRule = findArr(simpleRules, (rule) => rule.isApplicable(value, superJson));
|
|
1613
|
-
if (applicableSimpleRule) {
|
|
1614
|
-
return {
|
|
1615
|
-
value: applicableSimpleRule.transform(value, superJson),
|
|
1616
|
-
type: applicableSimpleRule.annotation
|
|
1617
|
-
};
|
|
1618
|
-
}
|
|
1619
|
-
return void 0;
|
|
1620
|
-
}, "transformValue");
|
|
1621
|
-
var simpleRulesByAnnotation = {};
|
|
1622
|
-
simpleRules.forEach((rule) => {
|
|
1623
|
-
simpleRulesByAnnotation[rule.annotation] = rule;
|
|
1624
|
-
});
|
|
1625
|
-
var untransformValue = /* @__PURE__ */ chunkWVKPC33H_cjs.__name((json, type, superJson) => {
|
|
1626
|
-
if (isArray(type)) {
|
|
1627
|
-
switch (type[0]) {
|
|
1628
|
-
case "symbol":
|
|
1629
|
-
return symbolRule.untransform(json, type, superJson);
|
|
1630
|
-
case "class":
|
|
1631
|
-
return classRule.untransform(json, type, superJson);
|
|
1632
|
-
case "custom":
|
|
1633
|
-
return customRule.untransform(json, type, superJson);
|
|
1634
|
-
case "typed-array":
|
|
1635
|
-
return typedArrayRule.untransform(json, type, superJson);
|
|
1636
|
-
default:
|
|
1637
|
-
throw new Error("Unknown transformation: " + type);
|
|
1638
|
-
}
|
|
1639
|
-
} else {
|
|
1640
|
-
const transformation = simpleRulesByAnnotation[type];
|
|
1641
|
-
if (!transformation) {
|
|
1642
|
-
throw new Error("Unknown transformation: " + type);
|
|
1643
|
-
}
|
|
1644
|
-
return transformation.untransform(json, superJson);
|
|
1645
|
-
}
|
|
1646
|
-
}, "untransformValue");
|
|
1647
|
-
|
|
1648
|
-
// ../../node_modules/.pnpm/superjson@2.2.2/node_modules/superjson/dist/accessDeep.js
|
|
1649
|
-
chunkWVKPC33H_cjs.init_cjs_shims();
|
|
1650
|
-
var getNthKey = /* @__PURE__ */ chunkWVKPC33H_cjs.__name((value, n6) => {
|
|
1651
|
-
if (n6 > value.size) throw new Error("index out of bounds");
|
|
1652
|
-
const keys = value.keys();
|
|
1653
|
-
while (n6 > 0) {
|
|
1654
|
-
keys.next();
|
|
1655
|
-
n6--;
|
|
1656
|
-
}
|
|
1657
|
-
return keys.next().value;
|
|
1658
|
-
}, "getNthKey");
|
|
1659
|
-
function validatePath(path) {
|
|
1660
|
-
if (includes(path, "__proto__")) {
|
|
1661
|
-
throw new Error("__proto__ is not allowed as a property");
|
|
1662
|
-
}
|
|
1663
|
-
if (includes(path, "prototype")) {
|
|
1664
|
-
throw new Error("prototype is not allowed as a property");
|
|
1665
|
-
}
|
|
1666
|
-
if (includes(path, "constructor")) {
|
|
1667
|
-
throw new Error("constructor is not allowed as a property");
|
|
1668
|
-
}
|
|
1669
|
-
}
|
|
1670
|
-
chunkWVKPC33H_cjs.__name(validatePath, "validatePath");
|
|
1671
|
-
var getDeep = /* @__PURE__ */ chunkWVKPC33H_cjs.__name((object, path) => {
|
|
1672
|
-
validatePath(path);
|
|
1673
|
-
for (let i3 = 0; i3 < path.length; i3++) {
|
|
1674
|
-
const key = path[i3];
|
|
1675
|
-
if (isSet(object)) {
|
|
1676
|
-
object = getNthKey(object, +key);
|
|
1677
|
-
} else if (isMap(object)) {
|
|
1678
|
-
const row = +key;
|
|
1679
|
-
const type = +path[++i3] === 0 ? "key" : "value";
|
|
1680
|
-
const keyOfRow = getNthKey(object, row);
|
|
1681
|
-
switch (type) {
|
|
1682
|
-
case "key":
|
|
1683
|
-
object = keyOfRow;
|
|
1684
|
-
break;
|
|
1685
|
-
case "value":
|
|
1686
|
-
object = object.get(keyOfRow);
|
|
1687
|
-
break;
|
|
1688
|
-
}
|
|
1689
|
-
} else {
|
|
1690
|
-
object = object[key];
|
|
1691
|
-
}
|
|
1692
|
-
}
|
|
1693
|
-
return object;
|
|
1694
|
-
}, "getDeep");
|
|
1695
|
-
var setDeep = /* @__PURE__ */ chunkWVKPC33H_cjs.__name((object, path, mapper) => {
|
|
1696
|
-
validatePath(path);
|
|
1697
|
-
if (path.length === 0) {
|
|
1698
|
-
return mapper(object);
|
|
1699
|
-
}
|
|
1700
|
-
let parent = object;
|
|
1701
|
-
for (let i3 = 0; i3 < path.length - 1; i3++) {
|
|
1702
|
-
const key = path[i3];
|
|
1703
|
-
if (isArray(parent)) {
|
|
1704
|
-
const index = +key;
|
|
1705
|
-
parent = parent[index];
|
|
1706
|
-
} else if (isPlainObject(parent)) {
|
|
1707
|
-
parent = parent[key];
|
|
1708
|
-
} else if (isSet(parent)) {
|
|
1709
|
-
const row = +key;
|
|
1710
|
-
parent = getNthKey(parent, row);
|
|
1711
|
-
} else if (isMap(parent)) {
|
|
1712
|
-
const isEnd = i3 === path.length - 2;
|
|
1713
|
-
if (isEnd) {
|
|
1714
|
-
break;
|
|
1715
|
-
}
|
|
1716
|
-
const row = +key;
|
|
1717
|
-
const type = +path[++i3] === 0 ? "key" : "value";
|
|
1718
|
-
const keyOfRow = getNthKey(parent, row);
|
|
1719
|
-
switch (type) {
|
|
1720
|
-
case "key":
|
|
1721
|
-
parent = keyOfRow;
|
|
1722
|
-
break;
|
|
1723
|
-
case "value":
|
|
1724
|
-
parent = parent.get(keyOfRow);
|
|
1725
|
-
break;
|
|
1726
|
-
}
|
|
1727
|
-
}
|
|
1728
|
-
}
|
|
1729
|
-
const lastKey = path[path.length - 1];
|
|
1730
|
-
if (isArray(parent)) {
|
|
1731
|
-
parent[+lastKey] = mapper(parent[+lastKey]);
|
|
1732
|
-
} else if (isPlainObject(parent)) {
|
|
1733
|
-
parent[lastKey] = mapper(parent[lastKey]);
|
|
1734
|
-
}
|
|
1735
|
-
if (isSet(parent)) {
|
|
1736
|
-
const oldValue = getNthKey(parent, +lastKey);
|
|
1737
|
-
const newValue = mapper(oldValue);
|
|
1738
|
-
if (oldValue !== newValue) {
|
|
1739
|
-
parent.delete(oldValue);
|
|
1740
|
-
parent.add(newValue);
|
|
1741
|
-
}
|
|
1742
|
-
}
|
|
1743
|
-
if (isMap(parent)) {
|
|
1744
|
-
const row = +path[path.length - 2];
|
|
1745
|
-
const keyToRow = getNthKey(parent, row);
|
|
1746
|
-
const type = +lastKey === 0 ? "key" : "value";
|
|
1747
|
-
switch (type) {
|
|
1748
|
-
case "key": {
|
|
1749
|
-
const newKey = mapper(keyToRow);
|
|
1750
|
-
parent.set(newKey, parent.get(keyToRow));
|
|
1751
|
-
if (newKey !== keyToRow) {
|
|
1752
|
-
parent.delete(keyToRow);
|
|
1753
|
-
}
|
|
1754
|
-
break;
|
|
1755
|
-
}
|
|
1756
|
-
case "value": {
|
|
1757
|
-
parent.set(keyToRow, mapper(parent.get(keyToRow)));
|
|
1758
|
-
break;
|
|
1759
|
-
}
|
|
1760
|
-
}
|
|
1761
|
-
}
|
|
1762
|
-
return object;
|
|
1763
|
-
}, "setDeep");
|
|
1764
|
-
|
|
1765
|
-
// ../../node_modules/.pnpm/superjson@2.2.2/node_modules/superjson/dist/plainer.js
|
|
1766
|
-
function traverse(tree, walker2, origin = []) {
|
|
1767
|
-
if (!tree) {
|
|
1768
|
-
return;
|
|
1769
|
-
}
|
|
1770
|
-
if (!isArray(tree)) {
|
|
1771
|
-
forEach(tree, (subtree, key) => traverse(subtree, walker2, [
|
|
1772
|
-
...origin,
|
|
1773
|
-
...parsePath(key)
|
|
1774
|
-
]));
|
|
1775
|
-
return;
|
|
1776
|
-
}
|
|
1777
|
-
const [nodeValue, children] = tree;
|
|
1778
|
-
if (children) {
|
|
1779
|
-
forEach(children, (child, key) => {
|
|
1780
|
-
traverse(child, walker2, [
|
|
1781
|
-
...origin,
|
|
1782
|
-
...parsePath(key)
|
|
1783
|
-
]);
|
|
1784
|
-
});
|
|
1785
|
-
}
|
|
1786
|
-
walker2(nodeValue, origin);
|
|
1787
|
-
}
|
|
1788
|
-
chunkWVKPC33H_cjs.__name(traverse, "traverse");
|
|
1789
|
-
function applyValueAnnotations(plain, annotations, superJson) {
|
|
1790
|
-
traverse(annotations, (type, path) => {
|
|
1791
|
-
plain = setDeep(plain, path, (v) => untransformValue(v, type, superJson));
|
|
1792
|
-
});
|
|
1793
|
-
return plain;
|
|
1794
|
-
}
|
|
1795
|
-
chunkWVKPC33H_cjs.__name(applyValueAnnotations, "applyValueAnnotations");
|
|
1796
|
-
function applyReferentialEqualityAnnotations(plain, annotations) {
|
|
1797
|
-
function apply(identicalPaths, path) {
|
|
1798
|
-
const object = getDeep(plain, parsePath(path));
|
|
1799
|
-
identicalPaths.map(parsePath).forEach((identicalObjectPath) => {
|
|
1800
|
-
plain = setDeep(plain, identicalObjectPath, () => object);
|
|
1801
|
-
});
|
|
1802
|
-
}
|
|
1803
|
-
chunkWVKPC33H_cjs.__name(apply, "apply");
|
|
1804
|
-
if (isArray(annotations)) {
|
|
1805
|
-
const [root, other] = annotations;
|
|
1806
|
-
root.forEach((identicalPath) => {
|
|
1807
|
-
plain = setDeep(plain, parsePath(identicalPath), () => plain);
|
|
1808
|
-
});
|
|
1809
|
-
if (other) {
|
|
1810
|
-
forEach(other, apply);
|
|
1811
|
-
}
|
|
1812
|
-
} else {
|
|
1813
|
-
forEach(annotations, apply);
|
|
1814
|
-
}
|
|
1815
|
-
return plain;
|
|
1816
|
-
}
|
|
1817
|
-
chunkWVKPC33H_cjs.__name(applyReferentialEqualityAnnotations, "applyReferentialEqualityAnnotations");
|
|
1818
|
-
var isDeep = /* @__PURE__ */ chunkWVKPC33H_cjs.__name((object, superJson) => isPlainObject(object) || isArray(object) || isMap(object) || isSet(object) || isInstanceOfRegisteredClass(object, superJson), "isDeep");
|
|
1819
|
-
function addIdentity(object, path, identities) {
|
|
1820
|
-
const existingSet = identities.get(object);
|
|
1821
|
-
if (existingSet) {
|
|
1822
|
-
existingSet.push(path);
|
|
1823
|
-
} else {
|
|
1824
|
-
identities.set(object, [
|
|
1825
|
-
path
|
|
1826
|
-
]);
|
|
1827
|
-
}
|
|
1828
|
-
}
|
|
1829
|
-
chunkWVKPC33H_cjs.__name(addIdentity, "addIdentity");
|
|
1830
|
-
function generateReferentialEqualityAnnotations(identitites, dedupe) {
|
|
1831
|
-
const result = {};
|
|
1832
|
-
let rootEqualityPaths = void 0;
|
|
1833
|
-
identitites.forEach((paths) => {
|
|
1834
|
-
if (paths.length <= 1) {
|
|
1835
|
-
return;
|
|
1836
|
-
}
|
|
1837
|
-
if (!dedupe) {
|
|
1838
|
-
paths = paths.map((path) => path.map(String)).sort((a3, b) => a3.length - b.length);
|
|
1839
|
-
}
|
|
1840
|
-
const [representativePath, ...identicalPaths] = paths;
|
|
1841
|
-
if (representativePath.length === 0) {
|
|
1842
|
-
rootEqualityPaths = identicalPaths.map(stringifyPath);
|
|
1843
|
-
} else {
|
|
1844
|
-
result[stringifyPath(representativePath)] = identicalPaths.map(stringifyPath);
|
|
1845
|
-
}
|
|
1846
|
-
});
|
|
1847
|
-
if (rootEqualityPaths) {
|
|
1848
|
-
if (isEmptyObject(result)) {
|
|
1849
|
-
return [
|
|
1850
|
-
rootEqualityPaths
|
|
1851
|
-
];
|
|
1852
|
-
} else {
|
|
1853
|
-
return [
|
|
1854
|
-
rootEqualityPaths,
|
|
1855
|
-
result
|
|
1856
|
-
];
|
|
1857
|
-
}
|
|
1858
|
-
} else {
|
|
1859
|
-
return isEmptyObject(result) ? void 0 : result;
|
|
1860
|
-
}
|
|
1861
|
-
}
|
|
1862
|
-
chunkWVKPC33H_cjs.__name(generateReferentialEqualityAnnotations, "generateReferentialEqualityAnnotations");
|
|
1863
|
-
var walker = /* @__PURE__ */ chunkWVKPC33H_cjs.__name((object, identities, superJson, dedupe, path = [], objectsInThisPath = [], seenObjects = /* @__PURE__ */ new Map()) => {
|
|
1864
|
-
const primitive = isPrimitive(object);
|
|
1865
|
-
if (!primitive) {
|
|
1866
|
-
addIdentity(object, path, identities);
|
|
1867
|
-
const seen = seenObjects.get(object);
|
|
1868
|
-
if (seen) {
|
|
1869
|
-
return dedupe ? {
|
|
1870
|
-
transformedValue: null
|
|
1871
|
-
} : seen;
|
|
1872
|
-
}
|
|
1873
|
-
}
|
|
1874
|
-
if (!isDeep(object, superJson)) {
|
|
1875
|
-
const transformed2 = transformValue(object, superJson);
|
|
1876
|
-
const result2 = transformed2 ? {
|
|
1877
|
-
transformedValue: transformed2.value,
|
|
1878
|
-
annotations: [
|
|
1879
|
-
transformed2.type
|
|
1880
|
-
]
|
|
1881
|
-
} : {
|
|
1882
|
-
transformedValue: object
|
|
1883
|
-
};
|
|
1884
|
-
if (!primitive) {
|
|
1885
|
-
seenObjects.set(object, result2);
|
|
1886
|
-
}
|
|
1887
|
-
return result2;
|
|
1888
|
-
}
|
|
1889
|
-
if (includes(objectsInThisPath, object)) {
|
|
1890
|
-
return {
|
|
1891
|
-
transformedValue: null
|
|
1892
|
-
};
|
|
1893
|
-
}
|
|
1894
|
-
const transformationResult = transformValue(object, superJson);
|
|
1895
|
-
const transformed = transformationResult?.value ?? object;
|
|
1896
|
-
const transformedValue = isArray(transformed) ? [] : {};
|
|
1897
|
-
const innerAnnotations = {};
|
|
1898
|
-
forEach(transformed, (value, index) => {
|
|
1899
|
-
if (index === "__proto__" || index === "constructor" || index === "prototype") {
|
|
1900
|
-
throw new Error(`Detected property ${index}. This is a prototype pollution risk, please remove it from your object.`);
|
|
1901
|
-
}
|
|
1902
|
-
const recursiveResult = walker(value, identities, superJson, dedupe, [
|
|
1903
|
-
...path,
|
|
1904
|
-
index
|
|
1905
|
-
], [
|
|
1906
|
-
...objectsInThisPath,
|
|
1907
|
-
object
|
|
1908
|
-
], seenObjects);
|
|
1909
|
-
transformedValue[index] = recursiveResult.transformedValue;
|
|
1910
|
-
if (isArray(recursiveResult.annotations)) {
|
|
1911
|
-
innerAnnotations[index] = recursiveResult.annotations;
|
|
1912
|
-
} else if (isPlainObject(recursiveResult.annotations)) {
|
|
1913
|
-
forEach(recursiveResult.annotations, (tree, key) => {
|
|
1914
|
-
innerAnnotations[escapeKey(index) + "." + key] = tree;
|
|
1915
|
-
});
|
|
1916
|
-
}
|
|
1917
|
-
});
|
|
1918
|
-
const result = isEmptyObject(innerAnnotations) ? {
|
|
1919
|
-
transformedValue,
|
|
1920
|
-
annotations: !!transformationResult ? [
|
|
1921
|
-
transformationResult.type
|
|
1922
|
-
] : void 0
|
|
1923
|
-
} : {
|
|
1924
|
-
transformedValue,
|
|
1925
|
-
annotations: !!transformationResult ? [
|
|
1926
|
-
transformationResult.type,
|
|
1927
|
-
innerAnnotations
|
|
1928
|
-
] : innerAnnotations
|
|
1929
|
-
};
|
|
1930
|
-
if (!primitive) {
|
|
1931
|
-
seenObjects.set(object, result);
|
|
1932
|
-
}
|
|
1933
|
-
return result;
|
|
1934
|
-
}, "walker");
|
|
1935
|
-
|
|
1936
|
-
// ../../node_modules/.pnpm/copy-anything@3.0.5/node_modules/copy-anything/dist/index.js
|
|
1937
|
-
chunkWVKPC33H_cjs.init_cjs_shims();
|
|
1938
|
-
|
|
1939
|
-
// ../../node_modules/.pnpm/is-what@4.1.16/node_modules/is-what/dist/index.js
|
|
1940
|
-
chunkWVKPC33H_cjs.init_cjs_shims();
|
|
1941
|
-
function getType2(payload) {
|
|
1942
|
-
return Object.prototype.toString.call(payload).slice(8, -1);
|
|
1943
|
-
}
|
|
1944
|
-
chunkWVKPC33H_cjs.__name(getType2, "getType");
|
|
1945
|
-
function isArray2(payload) {
|
|
1946
|
-
return getType2(payload) === "Array";
|
|
1947
|
-
}
|
|
1948
|
-
chunkWVKPC33H_cjs.__name(isArray2, "isArray");
|
|
1949
|
-
function isPlainObject2(payload) {
|
|
1950
|
-
if (getType2(payload) !== "Object") return false;
|
|
1951
|
-
const prototype = Object.getPrototypeOf(payload);
|
|
1952
|
-
return !!prototype && prototype.constructor === Object && prototype === Object.prototype;
|
|
1953
|
-
}
|
|
1954
|
-
chunkWVKPC33H_cjs.__name(isPlainObject2, "isPlainObject");
|
|
1955
|
-
function isNull2(payload) {
|
|
1956
|
-
return getType2(payload) === "Null";
|
|
1957
|
-
}
|
|
1958
|
-
chunkWVKPC33H_cjs.__name(isNull2, "isNull");
|
|
1959
|
-
function isOneOf(a3, b, c2, d, e7) {
|
|
1960
|
-
return (value) => a3(value) || b(value) || !!c2 && c2(value) || !!d && d(value) || !!e7 && e7(value);
|
|
1961
|
-
}
|
|
1962
|
-
chunkWVKPC33H_cjs.__name(isOneOf, "isOneOf");
|
|
1963
|
-
function isUndefined2(payload) {
|
|
1964
|
-
return getType2(payload) === "Undefined";
|
|
1965
|
-
}
|
|
1966
|
-
chunkWVKPC33H_cjs.__name(isUndefined2, "isUndefined");
|
|
1967
|
-
|
|
1968
|
-
// ../../node_modules/.pnpm/copy-anything@3.0.5/node_modules/copy-anything/dist/index.js
|
|
1969
|
-
function assignProp(carry, key, newVal, originalObject, includeNonenumerable) {
|
|
1970
|
-
const propType = {}.propertyIsEnumerable.call(originalObject, key) ? "enumerable" : "nonenumerable";
|
|
1971
|
-
if (propType === "enumerable") carry[key] = newVal;
|
|
1972
|
-
if (includeNonenumerable && propType === "nonenumerable") {
|
|
1973
|
-
Object.defineProperty(carry, key, {
|
|
1974
|
-
value: newVal,
|
|
1975
|
-
enumerable: false,
|
|
1976
|
-
writable: true,
|
|
1977
|
-
configurable: true
|
|
1978
|
-
});
|
|
1979
|
-
}
|
|
1980
|
-
}
|
|
1981
|
-
chunkWVKPC33H_cjs.__name(assignProp, "assignProp");
|
|
1982
|
-
function copy(target, options = {}) {
|
|
1983
|
-
if (isArray2(target)) {
|
|
1984
|
-
return target.map((item) => copy(item, options));
|
|
1985
|
-
}
|
|
1986
|
-
if (!isPlainObject2(target)) {
|
|
1987
|
-
return target;
|
|
1988
|
-
}
|
|
1989
|
-
const props = Object.getOwnPropertyNames(target);
|
|
1990
|
-
const symbols = Object.getOwnPropertySymbols(target);
|
|
1991
|
-
return [
|
|
1992
|
-
...props,
|
|
1993
|
-
...symbols
|
|
1994
|
-
].reduce((carry, key) => {
|
|
1995
|
-
if (isArray2(options.props) && !options.props.includes(key)) {
|
|
1996
|
-
return carry;
|
|
1997
|
-
}
|
|
1998
|
-
const val = target[key];
|
|
1999
|
-
const newVal = copy(val, options);
|
|
2000
|
-
assignProp(carry, key, newVal, target, options.nonenumerable);
|
|
2001
|
-
return carry;
|
|
2002
|
-
}, {});
|
|
2003
|
-
}
|
|
2004
|
-
chunkWVKPC33H_cjs.__name(copy, "copy");
|
|
2005
|
-
|
|
2006
|
-
// ../../node_modules/.pnpm/superjson@2.2.2/node_modules/superjson/dist/index.js
|
|
2007
|
-
var SuperJSON = class {
|
|
2008
|
-
static {
|
|
2009
|
-
chunkWVKPC33H_cjs.__name(this, "SuperJSON");
|
|
2010
|
-
}
|
|
2011
|
-
/**
|
|
2012
|
-
* @param dedupeReferentialEqualities If true, SuperJSON will make sure only one instance of referentially equal objects are serialized and the rest are replaced with `null`.
|
|
2013
|
-
*/
|
|
2014
|
-
constructor({ dedupe = false } = {}) {
|
|
2015
|
-
this.classRegistry = new ClassRegistry();
|
|
2016
|
-
this.symbolRegistry = new Registry((s) => s.description ?? "");
|
|
2017
|
-
this.customTransformerRegistry = new CustomTransformerRegistry();
|
|
2018
|
-
this.allowedErrorProps = [];
|
|
2019
|
-
this.dedupe = dedupe;
|
|
2020
|
-
}
|
|
2021
|
-
serialize(object) {
|
|
2022
|
-
const identities = /* @__PURE__ */ new Map();
|
|
2023
|
-
const output = walker(object, identities, this, this.dedupe);
|
|
2024
|
-
const res = {
|
|
2025
|
-
json: output.transformedValue
|
|
2026
|
-
};
|
|
2027
|
-
if (output.annotations) {
|
|
2028
|
-
res.meta = {
|
|
2029
|
-
...res.meta,
|
|
2030
|
-
values: output.annotations
|
|
2031
|
-
};
|
|
2032
|
-
}
|
|
2033
|
-
const equalityAnnotations = generateReferentialEqualityAnnotations(identities, this.dedupe);
|
|
2034
|
-
if (equalityAnnotations) {
|
|
2035
|
-
res.meta = {
|
|
2036
|
-
...res.meta,
|
|
2037
|
-
referentialEqualities: equalityAnnotations
|
|
2038
|
-
};
|
|
2039
|
-
}
|
|
2040
|
-
return res;
|
|
2041
|
-
}
|
|
2042
|
-
deserialize(payload) {
|
|
2043
|
-
const { json, meta } = payload;
|
|
2044
|
-
let result = copy(json);
|
|
2045
|
-
if (meta?.values) {
|
|
2046
|
-
result = applyValueAnnotations(result, meta.values, this);
|
|
2047
|
-
}
|
|
2048
|
-
if (meta?.referentialEqualities) {
|
|
2049
|
-
result = applyReferentialEqualityAnnotations(result, meta.referentialEqualities);
|
|
2050
|
-
}
|
|
2051
|
-
return result;
|
|
2052
|
-
}
|
|
2053
|
-
stringify(object) {
|
|
2054
|
-
return JSON.stringify(this.serialize(object));
|
|
2055
|
-
}
|
|
2056
|
-
parse(string) {
|
|
2057
|
-
return this.deserialize(JSON.parse(string));
|
|
2058
|
-
}
|
|
2059
|
-
registerClass(v, options) {
|
|
2060
|
-
this.classRegistry.register(v, options);
|
|
2061
|
-
}
|
|
2062
|
-
registerSymbol(v, identifier) {
|
|
2063
|
-
this.symbolRegistry.register(v, identifier);
|
|
2064
|
-
}
|
|
2065
|
-
registerCustom(transformer, name) {
|
|
2066
|
-
this.customTransformerRegistry.register({
|
|
2067
|
-
name,
|
|
2068
|
-
...transformer
|
|
2069
|
-
});
|
|
2070
|
-
}
|
|
2071
|
-
allowErrorProps(...props) {
|
|
2072
|
-
this.allowedErrorProps.push(...props);
|
|
2073
|
-
}
|
|
2074
|
-
};
|
|
2075
|
-
SuperJSON.defaultInstance = new SuperJSON();
|
|
2076
|
-
SuperJSON.serialize = SuperJSON.defaultInstance.serialize.bind(SuperJSON.defaultInstance);
|
|
2077
|
-
SuperJSON.deserialize = SuperJSON.defaultInstance.deserialize.bind(SuperJSON.defaultInstance);
|
|
2078
|
-
SuperJSON.stringify = SuperJSON.defaultInstance.stringify.bind(SuperJSON.defaultInstance);
|
|
2079
|
-
SuperJSON.parse = SuperJSON.defaultInstance.parse.bind(SuperJSON.defaultInstance);
|
|
2080
|
-
SuperJSON.registerClass = SuperJSON.defaultInstance.registerClass.bind(SuperJSON.defaultInstance);
|
|
2081
|
-
SuperJSON.registerSymbol = SuperJSON.defaultInstance.registerSymbol.bind(SuperJSON.defaultInstance);
|
|
2082
|
-
SuperJSON.registerCustom = SuperJSON.defaultInstance.registerCustom.bind(SuperJSON.defaultInstance);
|
|
2083
|
-
SuperJSON.allowErrorProps = SuperJSON.defaultInstance.allowErrorProps.bind(SuperJSON.defaultInstance);
|
|
2084
|
-
SuperJSON.serialize;
|
|
2085
|
-
SuperJSON.deserialize;
|
|
2086
|
-
SuperJSON.stringify;
|
|
2087
|
-
SuperJSON.parse;
|
|
2088
|
-
SuperJSON.registerClass;
|
|
2089
|
-
SuperJSON.registerCustom;
|
|
2090
|
-
SuperJSON.registerSymbol;
|
|
2091
|
-
SuperJSON.allowErrorProps;
|
|
2092
|
-
|
|
2093
|
-
// ../../node_modules/.pnpm/@stryke+json@0.9.32/node_modules/@stryke/json/dist/storm-json.mjs
|
|
2094
|
-
var c = class o3 extends SuperJSON {
|
|
2095
|
-
static {
|
|
2096
|
-
chunkWVKPC33H_cjs.__name(this, "o");
|
|
2097
|
-
}
|
|
2098
|
-
static #e;
|
|
2099
|
-
static get instance() {
|
|
2100
|
-
return o3.#e ||= new o3(), o3.#e;
|
|
2101
|
-
}
|
|
2102
|
-
static deserialize(e7) {
|
|
2103
|
-
return o3.instance.deserialize(e7);
|
|
2104
|
-
}
|
|
2105
|
-
static serialize(e7) {
|
|
2106
|
-
return o3.instance.serialize(e7);
|
|
2107
|
-
}
|
|
2108
|
-
static parse(e7) {
|
|
2109
|
-
return a2(e7);
|
|
2110
|
-
}
|
|
2111
|
-
static stringify(e7, t7) {
|
|
2112
|
-
let n6 = o3.instance.customTransformerRegistry.findApplicable(e7), r5 = e7;
|
|
2113
|
-
return n6 && n6.isApplicable(e7) && (r5 = n6.serialize(r5)), r4(r5);
|
|
2114
|
-
}
|
|
2115
|
-
static parseJson(e7, t7) {
|
|
2116
|
-
try {
|
|
2117
|
-
if (t7?.expectComments === false) return o3.instance.parse(e7);
|
|
2118
|
-
} catch {
|
|
2119
|
-
}
|
|
2120
|
-
let n6 = [], i3 = parse2(e7, n6, { allowTrailingComma: true, ...t7 });
|
|
2121
|
-
if (n6.length > 0 && n6[0]) throw Error(r3(e7, n6[0]));
|
|
2122
|
-
return i3;
|
|
2123
|
-
}
|
|
2124
|
-
static register(e7, t7, n6, r5) {
|
|
2125
|
-
o3.instance.registerCustom({ isApplicable: r5, serialize: t7, deserialize: n6 }, e7);
|
|
2126
|
-
}
|
|
2127
|
-
static registerClass(n6, r5) {
|
|
2128
|
-
o3.instance.registerClass(n6, { identifier: e2(r5) ? r5 : r5?.identifier || n6.name, allowProps: r5 && t3(r5) && r5?.allowProps && Array.isArray(r5.allowProps) ? r5.allowProps : [`__typename`] });
|
|
2129
|
-
}
|
|
2130
|
-
constructor() {
|
|
2131
|
-
super({ dedupe: true });
|
|
2132
|
-
}
|
|
2133
|
-
};
|
|
2134
|
-
c.instance.registerCustom({ isApplicable: /* @__PURE__ */ chunkWVKPC33H_cjs.__name((e7) => buffer.Buffer.isBuffer(e7), "isApplicable"), serialize: /* @__PURE__ */ chunkWVKPC33H_cjs.__name((e7) => e7.toString(`base64`), "serialize"), deserialize: /* @__PURE__ */ chunkWVKPC33H_cjs.__name((e7) => buffer.Buffer.from(e7, `base64`), "deserialize") }, `Bytes`);
|
|
2135
|
-
function stringifyDefaultValue(property, value) {
|
|
2136
|
-
return stringifyValue(property.type, value ?? property.getDefaultValue());
|
|
2137
|
-
}
|
|
2138
|
-
chunkWVKPC33H_cjs.__name(stringifyDefaultValue, "stringifyDefaultValue");
|
|
2139
|
-
function stringifyStringValue(value) {
|
|
2140
|
-
return `"${String(value).replaceAll('"', '\\"')}"`;
|
|
2141
|
-
}
|
|
2142
|
-
chunkWVKPC33H_cjs.__name(stringifyStringValue, "stringifyStringValue");
|
|
2143
|
-
function stringifyValue(type$1, value) {
|
|
2144
|
-
return isUndefined$1.isUndefined(value) ? "undefined" : isNull$1.isNull(value) ? "null" : type$1.kind === type.ReflectionKind.boolean ? String(value).trim().toLowerCase() === "true" ? "true" : "false" : type$1.kind === type.ReflectionKind.string || type$1.kind === type.ReflectionKind.literal && isString$1.isString(type$1.literal) ? stringifyStringValue(value) : type$1.kind === type.ReflectionKind.enum ? getEnumReflectionType(type$1).kind === type.ReflectionKind.string ? stringifyStringValue(value) : `${String(value)}` : type$1.kind === type.ReflectionKind.union ? isStringUnion(type$1) ? stringifyStringValue(value) : `${String(value)}` : type$1.kind === type.ReflectionKind.array ? stringifyStringValue(c.stringify(value)) : type$1.kind === type.ReflectionKind.object || type$1.kind === type.ReflectionKind.objectLiteral ? c.stringify(value) : type$1.kind === type.ReflectionKind.property || type$1.kind === type.ReflectionKind.parameter ? stringifyValue(type$1.type, value) : String(value);
|
|
2145
|
-
}
|
|
2146
|
-
chunkWVKPC33H_cjs.__name(stringifyValue, "stringifyValue");
|
|
2147
|
-
function getEnumReflectionType(type$1) {
|
|
2148
|
-
if (type$1.kind !== type.ReflectionKind.enum) {
|
|
2149
|
-
throw new Error(`Expected a TypeEnum, but received ${type$1.kind}.`);
|
|
2150
|
-
}
|
|
2151
|
-
const unique = t(type$1.values.filter((value) => value !== void 0 && value !== null), (enumMember) => isString$1.isString(enumMember) ? {
|
|
2152
|
-
kind: type.ReflectionKind.string
|
|
2153
|
-
} : {
|
|
2154
|
-
kind: type.ReflectionKind.number
|
|
2155
|
-
});
|
|
2156
|
-
if (unique.length === 0) {
|
|
2157
|
-
throw new Error(`No valid enum members could be found.`);
|
|
2158
|
-
}
|
|
2159
|
-
return unique[0] && isString$1.isString(unique[0]) ? {
|
|
2160
|
-
kind: type.ReflectionKind.string
|
|
2161
|
-
} : {
|
|
2162
|
-
kind: type.ReflectionKind.number
|
|
2163
|
-
};
|
|
2164
|
-
}
|
|
2165
|
-
chunkWVKPC33H_cjs.__name(getEnumReflectionType, "getEnumReflectionType");
|
|
2166
|
-
function getUnionTypes(type$1) {
|
|
2167
|
-
if (type$1.kind === type.ReflectionKind.union && type$1.types.length > 0) {
|
|
2168
|
-
return t(type$1.types, (member) => member.kind);
|
|
2169
|
-
}
|
|
2170
|
-
throw new Error(`Expected a TypeUnion, but received ${type$1.kind}.`);
|
|
2171
|
-
}
|
|
2172
|
-
chunkWVKPC33H_cjs.__name(getUnionTypes, "getUnionTypes");
|
|
2173
|
-
function isStringUnion(type$1) {
|
|
2174
|
-
return getUnionTypes(type$1).some((member) => member.kind === type.ReflectionKind.string || member.kind === type.ReflectionKind.literal && isString$1.isString(member.literal));
|
|
2175
|
-
}
|
|
2176
|
-
chunkWVKPC33H_cjs.__name(isStringUnion, "isStringUnion");
|
|
2177
|
-
function kindToName(kind) {
|
|
2178
|
-
if (kind === type.ReflectionKind.void) {
|
|
2179
|
-
return "void";
|
|
2180
|
-
} else if (kind === type.ReflectionKind.never) {
|
|
2181
|
-
return "never";
|
|
2182
|
-
} else if (kind === type.ReflectionKind.null) {
|
|
2183
|
-
return "null";
|
|
2184
|
-
} else if (kind === type.ReflectionKind.undefined) {
|
|
2185
|
-
return "undefined";
|
|
2186
|
-
} else if (kind === type.ReflectionKind.symbol) {
|
|
2187
|
-
return "symbol";
|
|
2188
|
-
} else if (kind === type.ReflectionKind.bigint) {
|
|
2189
|
-
return "bigint";
|
|
2190
|
-
} else if (kind === type.ReflectionKind.number) {
|
|
2191
|
-
return "number";
|
|
2192
|
-
} else if (kind === type.ReflectionKind.string) {
|
|
2193
|
-
return "string";
|
|
2194
|
-
} else if (kind === type.ReflectionKind.boolean) {
|
|
2195
|
-
return "boolean";
|
|
2196
|
-
} else if (kind === type.ReflectionKind.literal) {
|
|
2197
|
-
return "literal";
|
|
2198
|
-
} else if (kind === type.ReflectionKind.class) {
|
|
2199
|
-
return "class";
|
|
2200
|
-
} else if (kind === type.ReflectionKind.array) {
|
|
2201
|
-
return "array";
|
|
2202
|
-
} else if (kind === type.ReflectionKind.object) {
|
|
2203
|
-
return "object";
|
|
2204
|
-
} else if (kind === type.ReflectionKind.objectLiteral) {
|
|
2205
|
-
return "objectLiteral";
|
|
2206
|
-
} else if (kind === type.ReflectionKind.union) {
|
|
2207
|
-
return "union";
|
|
2208
|
-
} else if (kind === type.ReflectionKind.enum) {
|
|
2209
|
-
return "enum";
|
|
2210
|
-
} else if (kind === type.ReflectionKind.regexp) {
|
|
2211
|
-
return "regexp";
|
|
2212
|
-
} else if (kind === type.ReflectionKind.templateLiteral) {
|
|
2213
|
-
return "templateLiteral";
|
|
2214
|
-
} else if (kind === type.ReflectionKind.property) {
|
|
2215
|
-
return "property";
|
|
2216
|
-
} else if (kind === type.ReflectionKind.method) {
|
|
2217
|
-
return "method";
|
|
2218
|
-
} else if (kind === type.ReflectionKind.function) {
|
|
2219
|
-
return "function";
|
|
2220
|
-
} else if (kind === type.ReflectionKind.parameter) {
|
|
2221
|
-
return "parameter";
|
|
2222
|
-
} else if (kind === type.ReflectionKind.promise) {
|
|
2223
|
-
return "promise";
|
|
2224
|
-
} else if (kind === type.ReflectionKind.typeParameter) {
|
|
2225
|
-
return "typeParameter";
|
|
2226
|
-
} else if (kind === type.ReflectionKind.tuple) {
|
|
2227
|
-
return "tuple";
|
|
2228
|
-
} else if (kind === type.ReflectionKind.tupleMember) {
|
|
2229
|
-
return "tupleMember";
|
|
2230
|
-
} else if (kind === type.ReflectionKind.enumMember) {
|
|
2231
|
-
return "enumMember";
|
|
2232
|
-
} else if (kind === type.ReflectionKind.rest) {
|
|
2233
|
-
return "rest";
|
|
2234
|
-
} else if (kind === type.ReflectionKind.indexSignature) {
|
|
2235
|
-
return "indexSignature";
|
|
2236
|
-
} else if (kind === type.ReflectionKind.propertySignature) {
|
|
2237
|
-
return "propertySignature";
|
|
2238
|
-
} else if (kind === type.ReflectionKind.methodSignature) {
|
|
2239
|
-
return "methodSignature";
|
|
2240
|
-
} else if (kind === type.ReflectionKind.infer) {
|
|
2241
|
-
return "infer";
|
|
2242
|
-
} else if (kind === type.ReflectionKind.callSignature) {
|
|
2243
|
-
return "callSignature";
|
|
2244
|
-
} else if (kind === type.ReflectionKind.any) {
|
|
2245
|
-
return "any";
|
|
2246
|
-
} else if (kind === type.ReflectionKind.intersection) {
|
|
2247
|
-
return "intersection";
|
|
2248
|
-
}
|
|
2249
|
-
return "unknown";
|
|
2250
|
-
}
|
|
2251
|
-
chunkWVKPC33H_cjs.__name(kindToName, "kindToName");
|
|
2252
|
-
|
|
2253
|
-
exports.getEnumReflectionType = getEnumReflectionType;
|
|
2254
|
-
exports.getUnionTypes = getUnionTypes;
|
|
2255
|
-
exports.isStringUnion = isStringUnion;
|
|
2256
|
-
exports.kindToName = kindToName;
|
|
2257
|
-
exports.stringifyDefaultValue = stringifyDefaultValue;
|
|
2258
|
-
exports.stringifyStringValue = stringifyStringValue;
|
|
2259
|
-
exports.stringifyValue = stringifyValue;
|