@vtj/parser 0.18.0 → 0.18.1
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/index.cjs +15 -15
- package/dist/index.mjs +423 -405
- package/package.json +3 -3
- package/types/version.d.ts +2 -2
package/dist/index.mjs
CHANGED
|
@@ -3,9 +3,9 @@ import { parse as me } from "@babel/parser";
|
|
|
3
3
|
import vu from "@babel/traverse";
|
|
4
4
|
import Eu from "@babel/generator";
|
|
5
5
|
import { BlockModel as Hu } from "@vtj/core";
|
|
6
|
-
import { GLOBAL_API_MAP as gu, UI_PACKAGES as xe, UI_GLOBAL_API_MAPS as Wu, tsFormatter as
|
|
6
|
+
import { GLOBAL_API_MAP as gu, UI_PACKAGES as xe, UI_GLOBAL_API_MAPS as Wu, tsFormatter as ru } from "@vtj/coder";
|
|
7
7
|
import { NodeTypes as v } from "@vue/compiler-core";
|
|
8
|
-
import { upperFirstCamelCase as ge, unBase64 as ye, uid as
|
|
8
|
+
import { upperFirstCamelCase as ge, unBase64 as ye, uid as nu } from "@vtj/base";
|
|
9
9
|
import Se from "postcss";
|
|
10
10
|
import * as ve from "sass";
|
|
11
11
|
import * as q from "@babel/types";
|
|
@@ -13,11 +13,11 @@ import * as q from "@babel/types";
|
|
|
13
13
|
* Copyright (c) 2026, VTJ.PRO All rights reserved.
|
|
14
14
|
* @name @vtj/parser
|
|
15
15
|
* @author CHC chenhuachun1549@dingtalk.com
|
|
16
|
-
* @version 0.18.
|
|
16
|
+
* @version 0.18.1
|
|
17
17
|
* @license <a href="https://vtj.pro/license.html">MIT License</a>
|
|
18
18
|
*/
|
|
19
|
-
const
|
|
20
|
-
function
|
|
19
|
+
const l0 = "0.18.1";
|
|
20
|
+
function P(e) {
|
|
21
21
|
const { descriptor: u, errors: t } = Uu(e), a = u.template?.content || "", r = !!u.scriptSetup, n = (u.scriptSetup || u.script)?.content || "", i = u.styles.map((s) => s.content);
|
|
22
22
|
return {
|
|
23
23
|
template: a,
|
|
@@ -36,7 +36,7 @@ function J(e, u) {
|
|
|
36
36
|
function A(e) {
|
|
37
37
|
if (!e) return "";
|
|
38
38
|
try {
|
|
39
|
-
return
|
|
39
|
+
return au(e), (Eu.default || Eu)(e, {
|
|
40
40
|
comments: !1,
|
|
41
41
|
concise: !0,
|
|
42
42
|
retainLines: !1,
|
|
@@ -48,28 +48,46 @@ function A(e) {
|
|
|
48
48
|
return console.error("代码生成错误", u), "";
|
|
49
49
|
}
|
|
50
50
|
}
|
|
51
|
-
|
|
51
|
+
const Ee = /* @__PURE__ */ new Set([
|
|
52
|
+
"TSAsExpression",
|
|
53
|
+
"TSTypeAssertion",
|
|
54
|
+
"TSNonNullExpression"
|
|
55
|
+
]);
|
|
56
|
+
function au(e) {
|
|
52
57
|
if (!(!e || typeof e != "object")) {
|
|
53
58
|
if (Array.isArray(e)) {
|
|
54
|
-
for (const u of e)
|
|
59
|
+
for (const u of e) au(u);
|
|
60
|
+
return;
|
|
61
|
+
}
|
|
62
|
+
if (Ee.has(e.type) && e.expression) {
|
|
63
|
+
const u = e.expression;
|
|
64
|
+
au(u);
|
|
65
|
+
const t = {
|
|
66
|
+
start: e.start,
|
|
67
|
+
end: e.end,
|
|
68
|
+
loc: e.loc
|
|
69
|
+
};
|
|
70
|
+
for (const a of Object.keys(u))
|
|
71
|
+
a === "type" || a === "loc" || a === "start" || a === "end" || a === "extra" || a === "leadingComments" || a === "trailingComments" || a === "innerComments" || (e[a] = u[a]);
|
|
72
|
+
e.type = u.type, e.start = t.start, e.end = t.end, e.loc = t.loc, delete e.typeAnnotation, delete e.typeParameters;
|
|
55
73
|
return;
|
|
56
74
|
}
|
|
57
75
|
delete e.typeAnnotation, delete e.returnType, delete e.typeParameters, e.type === "Identifier" && delete e.optional;
|
|
58
76
|
for (const u of Object.keys(e))
|
|
59
|
-
u === "type" || u === "loc" || u === "start" || u === "end" || u === "extra" || u === "leadingComments" || u === "trailingComments" || u === "innerComments" || u === "errors" ||
|
|
77
|
+
u === "type" || u === "loc" || u === "start" || u === "end" || u === "extra" || u === "leadingComments" || u === "trailingComments" || u === "innerComments" || u === "errors" || au(e[u]);
|
|
60
78
|
}
|
|
61
79
|
}
|
|
62
|
-
function
|
|
80
|
+
function iu(e) {
|
|
63
81
|
return !!e && e.type === "JSExpression";
|
|
64
82
|
}
|
|
65
|
-
function
|
|
83
|
+
function we(e) {
|
|
66
84
|
return typeof e == "object" && !!e && e.type === "JSFunction";
|
|
67
85
|
}
|
|
68
|
-
function
|
|
69
|
-
return !!
|
|
86
|
+
function du(e) {
|
|
87
|
+
return !!iu(e) || !!we(e);
|
|
70
88
|
}
|
|
71
|
-
function
|
|
72
|
-
return !!e && !
|
|
89
|
+
function Ie(e) {
|
|
90
|
+
return !!e && !iu(e) && typeof e != "string";
|
|
73
91
|
}
|
|
74
92
|
function Ju(e, u) {
|
|
75
93
|
try {
|
|
@@ -79,7 +97,7 @@ function Ju(e, u) {
|
|
|
79
97
|
return "";
|
|
80
98
|
}
|
|
81
99
|
}
|
|
82
|
-
function
|
|
100
|
+
function Ae(e) {
|
|
83
101
|
if (!e) return "";
|
|
84
102
|
try {
|
|
85
103
|
const u = B(e);
|
|
@@ -117,7 +135,7 @@ function Ie(e) {
|
|
|
117
135
|
return e;
|
|
118
136
|
}
|
|
119
137
|
}
|
|
120
|
-
function
|
|
138
|
+
function ke(e, u) {
|
|
121
139
|
const t = [];
|
|
122
140
|
try {
|
|
123
141
|
const { descriptor: a, errors: r } = Uu(e);
|
|
@@ -156,7 +174,7 @@ function Ae(e, u) {
|
|
|
156
174
|
return t.length > 0 ? t : null;
|
|
157
175
|
}
|
|
158
176
|
function f0(e) {
|
|
159
|
-
const u =
|
|
177
|
+
const u = P(e), t = B(u.script), a = {};
|
|
160
178
|
return u.styles && (a.css = u.styles[0] || ""), J(t, {
|
|
161
179
|
CallExpression(r) {
|
|
162
180
|
const n = r.node.callee?.name;
|
|
@@ -173,12 +191,12 @@ function f0(e) {
|
|
|
173
191
|
function R(e, u, t) {
|
|
174
192
|
if (!e.includes(u)) return e;
|
|
175
193
|
try {
|
|
176
|
-
return
|
|
194
|
+
return Te(e, u, t);
|
|
177
195
|
} catch {
|
|
178
196
|
return e;
|
|
179
197
|
}
|
|
180
198
|
}
|
|
181
|
-
function
|
|
199
|
+
function Te(e, u, t) {
|
|
182
200
|
let a, r = 0;
|
|
183
201
|
try {
|
|
184
202
|
a = B(e);
|
|
@@ -191,18 +209,18 @@ function ke(e, u, t) {
|
|
|
191
209
|
Identifier(s) {
|
|
192
210
|
const o = s.node;
|
|
193
211
|
if (o.name !== u) return;
|
|
194
|
-
const c =
|
|
212
|
+
const c = Ve(s);
|
|
195
213
|
if (c === "skip") return;
|
|
196
|
-
const d = (o.start ?? 0) - r,
|
|
197
|
-
if (d < 0 ||
|
|
214
|
+
const d = (o.start ?? 0) - r, l = (o.end ?? 0) - r;
|
|
215
|
+
if (d < 0 || l > e.length) return;
|
|
198
216
|
const p = c === "expand" ? `${u}: ${t}` : t;
|
|
199
|
-
n.some((b) => b.start === d && b.end ===
|
|
217
|
+
n.some((b) => b.start === d && b.end === l) || n.push({ start: d, end: l, text: p });
|
|
200
218
|
},
|
|
201
219
|
StringLiteral(s) {
|
|
202
|
-
|
|
220
|
+
Ne(s, u, t, r, e, n);
|
|
203
221
|
},
|
|
204
222
|
TemplateLiteral(s) {
|
|
205
|
-
|
|
223
|
+
je(s, u, t, r, e, n);
|
|
206
224
|
},
|
|
207
225
|
MemberExpression(s) {
|
|
208
226
|
wu(s, u, t, r, e, n);
|
|
@@ -217,7 +235,7 @@ function ke(e, u, t) {
|
|
|
217
235
|
i = i.slice(0, s) + c + i.slice(o);
|
|
218
236
|
return i;
|
|
219
237
|
}
|
|
220
|
-
function
|
|
238
|
+
function Ne(e, u, t, a, r, n) {
|
|
221
239
|
const i = e.node;
|
|
222
240
|
if (!i.value.includes(u)) return;
|
|
223
241
|
const s = e.parent;
|
|
@@ -228,11 +246,11 @@ function Te(e, u, t, a, r, n) {
|
|
|
228
246
|
for (; c < o.length; ) {
|
|
229
247
|
const d = o.indexOf(u, c);
|
|
230
248
|
if (d === -1) break;
|
|
231
|
-
const
|
|
249
|
+
const l = 1 + d, p = (i.start ?? 0) - a + l, b = p + u.length;
|
|
232
250
|
p >= 0 && b <= r.length && !n.some((h) => h.start === p && h.end === b) && n.push({ start: p, end: b, text: t }), c = d + u.length;
|
|
233
251
|
}
|
|
234
252
|
}
|
|
235
|
-
function
|
|
253
|
+
function je(e, u, t, a, r, n) {
|
|
236
254
|
const i = e.parent;
|
|
237
255
|
if (i?.type !== "NewExpression" || i?.callee?.name !== "RegExp")
|
|
238
256
|
return;
|
|
@@ -240,14 +258,14 @@ function Ne(e, u, t, a, r, n) {
|
|
|
240
258
|
for (const c of o) {
|
|
241
259
|
const d = c.value?.raw ?? "";
|
|
242
260
|
if (!d.includes(u)) continue;
|
|
243
|
-
let
|
|
244
|
-
for (;
|
|
245
|
-
const p = d.indexOf(u,
|
|
261
|
+
let l = 0;
|
|
262
|
+
for (; l < d.length; ) {
|
|
263
|
+
const p = d.indexOf(u, l);
|
|
246
264
|
if (p === -1) break;
|
|
247
265
|
const b = (c.start ?? 0) - a;
|
|
248
266
|
if (b < 0 || b > r.length) break;
|
|
249
267
|
const h = b + p, S = h + u.length;
|
|
250
|
-
h >= 0 && S <= r.length && !n.some((E) => E.start === h && E.end === S) && n.push({ start: h, end: S, text: t }),
|
|
268
|
+
h >= 0 && S <= r.length && !n.some((E) => E.start === h && E.end === S) && n.push({ start: h, end: S, text: t }), l = p + u.length;
|
|
251
269
|
}
|
|
252
270
|
}
|
|
253
271
|
}
|
|
@@ -258,7 +276,7 @@ function wu(e, u, t, a, r, n) {
|
|
|
258
276
|
const s = (i.start ?? 0) - a, o = (i.end ?? 0) - a;
|
|
259
277
|
s < 0 || o > r.length || n.some((c) => c.start === s && c.end === o) || n.push({ start: s, end: o, text: t });
|
|
260
278
|
}
|
|
261
|
-
function
|
|
279
|
+
function Ve(e, u) {
|
|
262
280
|
const t = e.parent, a = t?.type ?? "", r = e.parentPath?.parent;
|
|
263
281
|
switch (a) {
|
|
264
282
|
// 成员访问 obj.key / obj[key] / obj?.key / obj?.[key]
|
|
@@ -365,9 +383,9 @@ function je(e, u) {
|
|
|
365
383
|
break;
|
|
366
384
|
}
|
|
367
385
|
}
|
|
368
|
-
return
|
|
386
|
+
return qe(e) || De(e) ? "skip" : "replace";
|
|
369
387
|
}
|
|
370
|
-
function
|
|
388
|
+
function qe(e) {
|
|
371
389
|
let u = e.parentPath;
|
|
372
390
|
for (; u; ) {
|
|
373
391
|
const t = u.node, a = t?.type ?? "";
|
|
@@ -379,7 +397,7 @@ function Ve(e) {
|
|
|
379
397
|
}
|
|
380
398
|
return !1;
|
|
381
399
|
}
|
|
382
|
-
function
|
|
400
|
+
function De(e) {
|
|
383
401
|
let u = e.parentPath;
|
|
384
402
|
for (; u; ) {
|
|
385
403
|
const t = u.node?.type ?? "";
|
|
@@ -406,8 +424,8 @@ function Iu(e, u, t) {
|
|
|
406
424
|
e.includes(`this.${d}.value`) || (e = R(e, d, `this.${d}.value`));
|
|
407
425
|
for (const d of s)
|
|
408
426
|
e = R(e, d, `this.${d}`);
|
|
409
|
-
for (const [d,
|
|
410
|
-
e = R(e, d, `this.$libs.${
|
|
427
|
+
for (const [d, l] of Object.entries(n))
|
|
428
|
+
e = R(e, d, `this.$libs.${l}.${d}`), e = R(e, `this.${d}`, `this.$libs.${l}.${d}`);
|
|
411
429
|
for (const d of i)
|
|
412
430
|
e = R(e, d, `this.${d}`);
|
|
413
431
|
if (o === "uniapp") {
|
|
@@ -428,7 +446,7 @@ function C(e) {
|
|
|
428
446
|
value: e
|
|
429
447
|
};
|
|
430
448
|
}
|
|
431
|
-
const
|
|
449
|
+
const Re = [
|
|
432
450
|
"beforeCreate",
|
|
433
451
|
"created",
|
|
434
452
|
"beforeMount",
|
|
@@ -442,18 +460,18 @@ const De = [
|
|
|
442
460
|
"renderTriggered",
|
|
443
461
|
"activated",
|
|
444
462
|
"deactivated"
|
|
445
|
-
],
|
|
463
|
+
], Ce = "html,body,base,head,link,meta,style,title,address,article,aside,footer,header,hgroup,h1,h2,h3,h4,h5,h6,nav,section,div,dd,dl,dt,figcaption,figure,picture,hr,img,li,main,ol,p,pre,ul,a,b,abbr,bdi,bdo,br,cite,code,data,dfn,em,i,kbd,mark,q,rp,rt,ruby,s,samp,small,span,strong,sub,sup,time,u,var,wbr,area,audio,map,track,video,embed,object,param,source,canvas,script,noscript,del,ins,caption,col,colgroup,table,thead,tbody,td,th,tr,button,datalist,fieldset,form,input,label,legend,meter,optgroup,option,output,progress,select,textarea,details,dialog,menu,summary,template,blockquote,iframe,tfoot,svg,path,circle,rect,polygon".split(
|
|
446
464
|
","
|
|
447
|
-
),
|
|
465
|
+
), _e = "component,slot,template".split(","), Le = "view,swiper,progress,icon,text,button,checkbox,editor,form,input,label,picker,radio,slider,switch,textarea,audio,camera,image,video,map,canvas".split(
|
|
448
466
|
","
|
|
449
467
|
);
|
|
450
|
-
function
|
|
468
|
+
function Pe(e, u = "web") {
|
|
451
469
|
return u === "uniapp" && Le.includes(e);
|
|
452
470
|
}
|
|
453
|
-
function
|
|
454
|
-
return (
|
|
471
|
+
function Xu(e, u = "web") {
|
|
472
|
+
return (Ce.includes(e) || _e.includes(e)) && !Pe(e, u) ? e : ge(e);
|
|
455
473
|
}
|
|
456
|
-
function
|
|
474
|
+
function zu(e) {
|
|
457
475
|
return e.replace(/\s+/g, " ").split(";").reduce((t, a) => {
|
|
458
476
|
const [r, n] = a.split(":").map((i) => i.trim());
|
|
459
477
|
return r && n && (t[r] = n), t;
|
|
@@ -476,12 +494,12 @@ function Qu(e = "") {
|
|
|
476
494
|
const Oe = /* @__PURE__ */ new Uint16Array(
|
|
477
495
|
// prettier-ignore
|
|
478
496
|
/* @__PURE__ */ 'ᵁ<Õıʊҝջאٵ۞ޢߖࠏઑඡ༉༦ረዡᐕᒝᓃᓟᔥ\0\0\0\0\0\0ᕫᛍᦍᰒᷝ↰⊍⏀⏻⑂⠤⤒ⴈ⹈⿎〖㊺㘹㞬㣾㨨㩱㫠㬮ࠀEMabcfglmnoprstu\\bfms¦³¹ÈÏlig耻Æ䃆P耻&䀦cute耻Á䃁reve;䄂Āiyx}rc耻Â䃂;䐐r;쀀𝔄rave耻À䃀pha;䎑acr;䄀d;橓Āgp¡on;䄄f;쀀𝔸plyFunction;恡ing耻Å䃅Ācs¾Ãr;쀀𝒜ign;扔ilde耻Ã䃃ml耻Ä䃄ЀaceforsuåûþėĜĢħĪĀcrêòkslash;或Ŷöø;櫧ed;挆y;䐑ƀcrtąċĔause;戵noullis;愬a;䎒r;쀀𝔅pf;쀀𝔹eve;䋘còēmpeq;扎܀HOacdefhilorsuōőŖƀƞƢƵƷƺǜȕɳɸɾcy;䐧PY耻©䂩ƀcpyŝŢźute;䄆Ā;iŧŨ拒talDifferentialD;慅leys;愭ȀaeioƉƎƔƘron;䄌dil耻Ç䃇rc;䄈nint;戰ot;䄊ĀdnƧƭilla;䂸terDot;䂷òſi;䎧rcleȀDMPTLJNjǑǖot;抙inus;抖lus;投imes;抗oĀcsǢǸkwiseContourIntegral;戲eCurlyĀDQȃȏoubleQuote;思uote;怙ȀlnpuȞȨɇɕonĀ;eȥȦ户;橴ƀgitȯȶȺruent;扡nt;戯ourIntegral;戮ĀfrɌɎ;愂oduct;成nterClockwiseContourIntegral;戳oss;樯cr;쀀𝒞pĀ;Cʄʅ拓ap;才րDJSZacefiosʠʬʰʴʸˋ˗ˡ˦̳ҍĀ;oŹʥtrahd;椑cy;䐂cy;䐅cy;䐏ƀgrsʿ˄ˇger;怡r;憡hv;櫤Āayː˕ron;䄎;䐔lĀ;t˝˞戇a;䎔r;쀀𝔇Āaf˫̧Ācm˰̢riticalȀADGT̖̜̀̆cute;䂴oŴ̋̍;䋙bleAcute;䋝rave;䁠ilde;䋜ond;拄ferentialD;慆Ѱ̽\0\0\0͔͂\0Ѕf;쀀𝔻ƀ;DE͈͉͍䂨ot;惜qual;扐blèCDLRUVͣͲϏϢϸontourIntegraìȹoɴ\0\0ͻ»͉nArrow;懓Āeo·ΤftƀARTΐΖΡrrow;懐ightArrow;懔eåˊngĀLRΫτeftĀARγιrrow;柸ightArrow;柺ightArrow;柹ightĀATϘϞrrow;懒ee;抨pɁϩ\0\0ϯrrow;懑ownArrow;懕erticalBar;戥ǹABLRTaВЪаўѿͼrrowƀ;BUНОТ憓ar;椓pArrow;懵reve;䌑eft˒к\0ц\0ѐightVector;楐eeVector;楞ectorĀ;Bљњ憽ar;楖ightǔѧ\0ѱeeVector;楟ectorĀ;BѺѻ懁ar;楗eeĀ;A҆҇护rrow;憧ĀctҒҗr;쀀𝒟rok;䄐ࠀNTacdfglmopqstuxҽӀӄӋӞӢӧӮӵԡԯԶՒ՝ՠեG;䅊H耻Ð䃐cute耻É䃉ƀaiyӒӗӜron;䄚rc耻Ê䃊;䐭ot;䄖r;쀀𝔈rave耻È䃈ement;戈ĀapӺӾcr;䄒tyɓԆ\0\0ԒmallSquare;旻erySmallSquare;斫ĀgpԦԪon;䄘f;쀀𝔼silon;䎕uĀaiԼՉlĀ;TՂՃ橵ilde;扂librium;懌Āci՚r;愰m;橳a;䎗ml耻Ë䃋Āipժկsts;戃onentialE;慇ʀcfiosօֈ֍ֲy;䐤r;쀀𝔉lledɓ֗\0\0֣mallSquare;旼erySmallSquare;斪Ͱֺ\0ֿ\0\0ׄf;쀀𝔽All;戀riertrf;愱còJTabcdfgorstרׯؒؖ؛؝أ٬ٲcy;䐃耻>䀾mmaĀ;d䎓;䏜reve;䄞ƀeiy؇،ؐdil;䄢rc;䄜;䐓ot;䄠r;쀀𝔊;拙pf;쀀𝔾eater̀EFGLSTصلَٖٛ٦qualĀ;Lؾؿ扥ess;招ullEqual;执reater;檢ess;扷lantEqual;橾ilde;扳cr;쀀𝒢;扫ЀAacfiosuڅڋږڛڞڪھۊRDcy;䐪Āctڐڔek;䋇;䁞irc;䄤r;愌lbertSpace;愋ǰگ\0ڲf;愍izontalLine;攀Āctۃۅòکrok;䄦mpńېۘownHumðįqual;扏܀EJOacdfgmnostuۺ۾܃܇ܚܞܡܨ݄ݸދޏޕcy;䐕lig;䄲cy;䐁cute耻Í䃍Āiyܓܘrc耻Î䃎;䐘ot;䄰r;愑rave耻Ì䃌ƀ;apܠܯܿĀcgܴܷr;䄪inaryI;慈lieóϝǴ݉\0ݢĀ;eݍݎ戬Āgrݓݘral;戫section;拂isibleĀCTݬݲomma;恣imes;恢ƀgptݿރވon;䄮f;쀀𝕀a;䎙cr;愐ilde;䄨ǫޚ\0ޞcy;䐆l耻Ï䃏ʀcfosuެ߂ߐĀiyޱrc;䄴;䐙r;쀀𝔍pf;쀀𝕁ǣ߇\0ߌr;쀀𝒥rcy;䐈kcy;䐄HJacfosߤߨ߽߬߱ࠂࠈcy;䐥cy;䐌ppa;䎚Āey߶dil;䄶;䐚r;쀀𝔎pf;쀀𝕂cr;쀀𝒦րJTaceflmostࠥࠩࠬࡐࡣসে্ੇcy;䐉耻<䀼ʀcmnpr࠷࠼ࡁࡄࡍute;䄹bda;䎛g;柪lacetrf;愒r;憞ƀaeyࡗࡡron;䄽dil;䄻;䐛Āfsࡨ॰tԀACDFRTUVarࡾࢩࢱࣦ࣠ࣼयज़ΐ४ĀnrࢃgleBracket;柨rowƀ;BR࢙࢚࢞憐ar;懤ightArrow;懆eiling;挈oǵࢷ\0ࣃbleBracket;柦nǔࣈ\0࣒eeVector;楡ectorĀ;Bࣛࣜ懃ar;楙loor;挊ightĀAV࣯ࣵrrow;憔ector;楎Āerँगeƀ;AVउऊऐ抣rrow;憤ector;楚iangleƀ;BEतथऩ抲ar;槏qual;抴pƀDTVषूौownVector;楑eeVector;楠ectorĀ;Bॖॗ憿ar;楘ectorĀ;B॥०憼ar;楒ightáΜs̀EFGLSTॾঋকঝঢভqualGreater;拚ullEqual;扦reater;扶ess;檡lantEqual;橽ilde;扲r;쀀𝔏Ā;eঽা拘ftarrow;懚idot;䄿ƀnpwਖਛgȀLRlr৷ਂਐeftĀAR০৬rrow;柵ightArrow;柷ightArrow;柶eftĀarγਊightáοightáϊf;쀀𝕃erĀLRਢਬeftArrow;憙ightArrow;憘ƀchtਾੀੂòࡌ;憰rok;䅁;扪Ѐacefiosuਗ਼અઋp;椅y;䐜Ādl੯iumSpace;恟lintrf;愳r;쀀𝔐nusPlus;戓pf;쀀𝕄cò੶;䎜ҀJacefostuણધભીଔଙඑඞcy;䐊cute;䅃ƀaeyહાron;䅇dil;䅅;䐝ƀgswે૰ativeƀMTV૨ediumSpace;怋hiĀcn૦ëeryThiîtedĀGLଆreaterGreateòٳessLesóੈLine;䀊r;쀀𝔑ȀBnptଢନଷreak;恠BreakingSpace;䂠f;愕ڀ;CDEGHLNPRSTV୕ୖ୪௫ఄ಄ದൡඅ櫬Āoungruent;扢pCap;扭oubleVerticalBar;戦ƀlqxஃஊement;戉ualĀ;Tஒஓ扠ilde;쀀≂̸ists;戄reater;EFGLSTஶஷ扯qual;扱ullEqual;쀀≧̸reater;쀀≫̸ess;批lantEqual;쀀⩾̸ilde;扵umpń௲ownHump;쀀≎̸qual;쀀≏̸eĀfsఊధtTriangleƀ;BEచఛడ拪ar;쀀⧏̸qual;括s̀;EGLSTవశ఼ౄోౘ扮qual;扰reater;扸ess;쀀≪̸lantEqual;쀀⩽̸ilde;扴estedĀGL౨౹reaterGreater;쀀⪢̸essLess;쀀⪡̸recedesƀ;ESಒಓಛ技qual;쀀⪯̸lantEqual;拠ĀeiಫಹverseElement;戌ghtTriangleƀ;BEೋೌ拫ar;쀀⧐̸qual;拭ĀquೝഌuareSuĀbp೨setĀ;Eೳ쀀⊏̸qual;拢ersetĀ;Eഃആ쀀⊐̸qual;拣ƀbcpഓതൎsetĀ;Eഛഞ쀀⊂⃒qual;抈ceedsȀ;ESTലള഻െ抁qual;쀀⪰̸lantEqual;拡ilde;쀀≿̸ersetĀ;E൘൛쀀⊃⃒qual;抉ildeȀ;EFT൮൯൵ൿ扁qual;扄ullEqual;扇ilde;扉erticalBar;戤cr;쀀𝒩ilde耻Ñ䃑;䎝܀Eacdfgmoprstuvලෂෛ෧ขภยา฿ไlig;䅒cute耻Ó䃓Āiyීrc耻Ô䃔;䐞blac;䅐r;쀀𝔒rave耻Ò䃒ƀaei෮ෲcr;䅌ga;䎩cron;䎟pf;쀀𝕆enCurlyĀDQฎบoubleQuote;怜uote;怘;橔Āclวฬr;쀀𝒪ash耻Ø䃘iŬืde耻Õ䃕es;樷ml耻Ö䃖erĀBP๋Āar๐๓r;怾acĀek๚;揞et;掴arenthesis;揜ҀacfhilorsງຊຏຒດຝະrtialD;戂y;䐟r;쀀𝔓i;䎦;䎠usMinus;䂱Āipຢອncareplanåڝf;愙Ȁ;eio຺ູ檻cedesȀ;EST່້扺qual;檯lantEqual;扼ilde;找me;怳Ādpuct;戏ortionĀ;aȥl;戝Āci༁༆r;쀀𝒫;䎨ȀUfos༑༖༛༟OT耻"䀢r;쀀𝔔pf;愚cr;쀀𝒬BEacefhiorsu༾གྷཇའཱིྦྷྪྭ႖ႩႴႾarr;椐G耻®䂮ƀcnrཎནབute;䅔g;柫rĀ;tཛྷཝ憠l;椖ƀaeyཧཬཱron;䅘dil;䅖;䐠Ā;vླྀཹ愜erseĀEUྂྙĀlq྇ྎement;戋uilibrium;懋pEquilibrium;楯r»ཹo;䎡ghtЀACDFTUVa࿁ဢဨၛႇϘĀnr࿆࿒gleBracket;柩rowƀ;BL憒ar;懥eftArrow;懄eiling;按oǵ\0စbleBracket;柧nǔည\0နeeVector;楝ectorĀ;Bဝသ懂ar;楕loor;挋Āerိ၃eƀ;AVဵံြ抢rrow;憦ector;楛iangleƀ;BEၐၑၕ抳ar;槐qual;抵pƀDTVၣၮၸownVector;楏eeVector;楜ectorĀ;Bႂႃ憾ar;楔ectorĀ;B႑႒懀ar;楓Āpuႛ႞f;愝ndImplies;楰ightarrow;懛ĀchႹႼr;愛;憱leDelayed;槴ڀHOacfhimoqstuფჱჷჽᄙᄞᅑᅖᅡᅧᆵᆻᆿĀCcჩხHcy;䐩y;䐨FTcy;䐬cute;䅚ʀ;aeiyᄈᄉᄎᄓᄗ檼ron;䅠dil;䅞rc;䅜;䐡r;쀀𝔖ortȀDLRUᄪᄴᄾᅉownArrow»ОeftArrow»࢚ightArrow»pArrow;憑gma;䎣allCircle;战pf;쀀𝕊ɲᅭ\0\0ᅰt;戚areȀ;ISUᅻᅼᆉᆯ斡ntersection;抓uĀbpᆏᆞsetĀ;Eᆗᆘ抏qual;抑ersetĀ;Eᆨᆩ抐qual;抒nion;抔cr;쀀𝒮ar;拆ȀbcmpᇈᇛሉላĀ;sᇍᇎ拐etĀ;Eᇍᇕqual;抆ĀchᇠህeedsȀ;ESTᇭᇮᇴᇿ扻qual;檰lantEqual;扽ilde;承Tháྌ;我ƀ;esሒሓሣ拑rsetĀ;Eሜም抃qual;抇et»ሓրHRSacfhiorsሾቄቕቱቶኟዂወዑORN耻Þ䃞ADE;愢ĀHcቒcy;䐋y;䐦Ābuቚቜ;䀉;䎤ƀaeyብቪቯron;䅤dil;䅢;䐢r;쀀𝔗ĀeiቻDzኀ\0ኇefore;戴a;䎘ĀcnኘkSpace;쀀 Space;怉ldeȀ;EFTካኬኲኼ戼qual;扃ullEqual;扅ilde;扈pf;쀀𝕋ipleDot;惛Āctዖዛr;쀀𝒯rok;䅦ૡዷጎጚጦ\0ጬጱ\0\0\0\0\0ጸጽ፷ᎅ\0ᐄᐊᐐĀcrዻጁute耻Ú䃚rĀ;oጇገ憟cir;楉rǣጓ\0y;䐎ve;䅬Āiyጞጣrc耻Û䃛;䐣blac;䅰r;쀀𝔘rave耻Ù䃙acr;䅪Ādiፁ፩erĀBPፈ፝Āarፍፐr;䁟acĀekፗፙ;揟et;掵arenthesis;揝onĀ;P፰፱拃lus;抎Āgp፻on;䅲f;쀀𝕌ЀADETadps᎕ᎮᎸᏄϨᏒᏗᏳrrowƀ;BDᅐᎠᎤar;椒ownArrow;懅ownArrow;憕quilibrium;楮eeĀ;AᏋᏌ报rrow;憥ownáϳerĀLRᏞᏨeftArrow;憖ightArrow;憗iĀ;lᏹᏺ䏒on;䎥ing;䅮cr;쀀𝒰ilde;䅨ml耻Ü䃜ҀDbcdefosvᐧᐬᐰᐳᐾᒅᒊᒐᒖash;披ar;櫫y;䐒ashĀ;lᐻᐼ抩;櫦Āerᑃᑅ;拁ƀbtyᑌᑐᑺar;怖Ā;iᑏᑕcalȀBLSTᑡᑥᑪᑴar;戣ine;䁼eparator;杘ilde;所ThinSpace;怊r;쀀𝔙pf;쀀𝕍cr;쀀𝒱dash;抪ʀcefosᒧᒬᒱᒶᒼirc;䅴dge;拀r;쀀𝔚pf;쀀𝕎cr;쀀𝒲Ȁfiosᓋᓐᓒᓘr;쀀𝔛;䎞pf;쀀𝕏cr;쀀𝒳ҀAIUacfosuᓱᓵᓹᓽᔄᔏᔔᔚᔠcy;䐯cy;䐇cy;䐮cute耻Ý䃝Āiyᔉᔍrc;䅶;䐫r;쀀𝔜pf;쀀𝕐cr;쀀𝒴ml;䅸ЀHacdefosᔵᔹᔿᕋᕏᕝᕠᕤcy;䐖cute;䅹Āayᕄᕉron;䅽;䐗ot;䅻Dzᕔ\0ᕛoWidtèa;䎖r;愨pf;愤cr;쀀𝒵ᖃᖊᖐ\0ᖰᖶᖿ\0\0\0\0ᗆᗛᗫᙟ᙭\0ᚕ᚛ᚲᚹ\0ᚾcute耻á䃡reve;䄃̀;Ediuyᖜᖝᖡᖣᖨᖭ戾;쀀∾̳;房rc耻â䃢te肻´̆;䐰lig耻æ䃦Ā;r²ᖺ;쀀𝔞rave耻à䃠ĀepᗊᗖĀfpᗏᗔsym;愵èᗓha;䎱ĀapᗟcĀclᗤᗧr;䄁g;樿ɤᗰ\0\0ᘊʀ;adsvᗺᗻᗿᘁᘇ戧nd;橕;橜lope;橘;橚;elmrszᘘᘙᘛᘞᘿᙏᙙ戠;榤e»ᘙsdĀ;aᘥᘦ戡ѡᘰᘲᘴᘶᘸᘺᘼᘾ;榨;榩;榪;榫;榬;榭;榮;榯tĀ;vᙅᙆ戟bĀ;dᙌᙍ抾;榝Āptᙔᙗh;戢»¹arr;捼Āgpᙣᙧon;䄅f;쀀𝕒;Eaeiopᙻᙽᚂᚄᚇᚊ;橰cir;橯;扊d;手s;䀧roxĀ;eᚒñᚃing耻å䃥ƀctyᚡᚦᚨr;쀀𝒶;䀪mpĀ;eᚯñʈilde耻ã䃣ml耻ä䃤Āciᛂᛈoninôɲnt;樑ࠀNabcdefiklnoprsu᛭ᛱᜰᝃᝈ០៦ᠹᡐᜍ᥈ᥰot;櫭ĀcrᛶkȀcepsᜀᜅᜍᜓong;扌psilon;䏶rime;怵imĀ;e戽q;拍Ŷᜢᜦee;抽edĀ;gᜬᜭ挅e»ᜭrkĀ;tbrk;掶Āoyᜁᝁ;䐱quo;怞ʀcmprtᝓᝡᝤᝨausĀ;eĊĉptyv;榰séᜌnoõēƀahwᝯᝳ;䎲;愶een;扬r;쀀𝔟gcostuvwឍឝឳេ៕៛ƀaiuបពរðݠrc;旯p»፱ƀdptឤឨឭot;樀lus;樁imes;樂ɱឹ\0\0ើcup;樆ar;昅riangleĀdu៍្own;施p;斳plus;樄eåᑄåᒭarow;植ƀakoᠦᠵĀcn៲ᠣkƀlst֫᠂ozenge;槫riangleȀ;dlr᠒᠓᠘斴own;斾eft;旂ight;斸k;搣Ʊᠫ\0ᠳƲᠯ\0ᠱ;斒;斑4;斓ck;斈ĀeoᠾᡍĀ;qᡃᡆ쀀=⃥uiv;쀀≡⃥t;挐Ȁptwxᡙᡞᡧᡬf;쀀𝕓Ā;tᏋᡣom»Ꮜtie;拈DHUVbdhmptuvᢅᢖᢪᢻᣗᣛᣬᤅᤊᤐᤡȀLRlrᢎᢐᢒᢔ;敗;敔;敖;敓ʀ;DUduᢡᢢᢤᢦᢨ敐;敦;敩;敤;敧ȀLRlrᢳᢵᢷᢹ;敝;敚;敜;教;HLRhlrᣊᣋᣍᣏᣑᣓᣕ救;敬;散;敠;敫;敢;敟ox;槉ȀLRlrᣤᣦᣨᣪ;敕;敒;攐;攌ʀ;DUduڽ;敥;敨;攬;攴inus;抟lus;択imes;抠ȀLRlrᤙᤛᤝ;敛;敘;攘;攔;HLRhlrᤰᤱᤳᤵᤷ᤻᤹攂;敪;敡;敞;攼;攤;攜Āevģbar耻¦䂦Ȁceioᥑᥖᥚᥠr;쀀𝒷mi;恏mĀ;elƀ;bhᥨᥩᥫ䁜;槅sub;柈ŬᥴlĀ;e怢t»pƀ;Eeįᦅᦇ;檮Ā;qۜۛೡᦧ\0᧨ᨑᨕᨲ\0ᨷᩐ\0\0᪴\0\0᫁\0\0ᬡᬮ᭒\0᯽\0ᰌƀcprᦲute;䄇̀;abcdsᦿᧀᧄ᧕᧙戩nd;橄rcup;橉Āau᧒p;橋p;橇ot;橀;쀀∩︀Āeo᧢᧥t;恁îړȀaeiu᧰᧻ᨁᨅǰ᧵\0᧸s;橍on;䄍dil耻ç䃧rc;䄉psĀ;sᨌᨍ橌m;橐ot;䄋ƀdmnᨛᨠᨦil肻¸ƭptyv;榲t脀¢;eᨭᨮ䂢räƲr;쀀𝔠ƀceiᨽᩀᩍy;䑇ckĀ;mᩇᩈ朓ark»ᩈ;䏇r;Ecefms᩠ᩢᩫ᪤᪪旋;槃ƀ;elᩩᩪᩭ䋆q;扗eɡᩴ\0\0᪈rrowĀlr᩼᪁eft;憺ight;憻ʀRSacd᪒᪔᪖»ཇ;擈st;抛irc;抚ash;抝nint;樐id;櫯cir;槂ubsĀ;u᪻᪼晣it»᪼ˬ᫇\0ᬊonĀ;eᫍᫎ䀺Ā;qÇÆɭ\0\0aĀ;t䀬;䁀ƀ;fl戁îᅠeĀmxent»eóɍǧ\0ᬇĀ;dኻᬂot;橭nôɆƀfryᬐᬔᬗ;쀀𝕔oäɔ脀©;sŕᬝr;愗Āaoᬥᬩrr;憵ss;朗Ācuᬲᬷr;쀀𝒸Ābpᬼ᭄Ā;eᭁᭂ櫏;櫑Ā;eᭉᭊ櫐;櫒dot;拯delprvw᭠᭬᭷ᮂᮬᯔarrĀlr᭨᭪;椸;椵ɰ᭲\0\0᭵r;拞c;拟arrĀ;pᮀ憶;椽̀;bcdosᮏᮐᮖᮡᮥᮨ截rcap;橈Āauᮛᮞp;橆p;橊ot;抍r;橅;쀀∪︀Ȁalrv᮵ᮿᯞᯣrrĀ;mᮼᮽ憷;椼yƀevwᯇᯔᯘqɰᯎ\0\0ᯒreã᭳uã᭵ee;拎edge;拏en耻¤䂤earrowĀlrᯮ᯳eft»ᮀight»ᮽeäᯝĀciᰁᰇoninôǷnt;戱lcty;挭ঀAHabcdefhijlorstuwz᰻᰿ᱝᱩᱵᲞᲬᲷᴍᵻᶑᶫᶻ᷆᷍ròar;楥Ȁglrs᱈ᱍ᱒᱔ger;怠eth;愸òᄳhĀ;vᱚᱛ怐»ऊūᱡᱧarow;椏aã̕Āayᱮᱳron;䄏;䐴ƀ;ao̲ᱼᲄĀgrʿᲁr;懊tseq;橷ƀglmᲑᲔᲘ耻°䂰ta;䎴ptyv;榱ĀirᲣᲨsht;楿;쀀𝔡arĀlrᲳᲵ»ࣜ»သʀaegsv᳂᳖᳜᳠mƀ;oș᳔ndĀ;ș᳑uit;晦amma;䏝in;拲ƀ;io᳧᳨᳸䃷de脀÷;o᳧ᳰntimes;拇nø᳷cy;䑒cɯᴆ\0\0ᴊrn;挞op;挍ʀlptuwᴘᴝᴢᵉᵕlar;䀤f;쀀𝕕ʀ;emps̋ᴭᴷᴽᵂqĀ;d͒ᴳot;扑inus;戸lus;戔quare;抡blebarwedgåúnƀadhᄮᵝᵧownarrowóᲃarpoonĀlrᵲᵶefôᲴighôᲶŢᵿᶅkaro÷གɯᶊ\0\0ᶎrn;挟op;挌ƀcotᶘᶣᶦĀryᶝᶡ;쀀𝒹;䑕l;槶rok;䄑Ādrᶰᶴot;拱iĀ;fᶺ᠖斿Āah᷀᷃ròЩaòྦangle;榦Āci᷒ᷕy;䑟grarr;柿ऀDacdefglmnopqrstuxḁḉḙḸոḼṉṡṾấắẽỡἪἷὄĀDoḆᴴoôĀcsḎḔute耻é䃩ter;橮ȀaioyḢḧḱḶron;䄛rĀ;cḭḮ扖耻ê䃪lon;払;䑍ot;䄗ĀDrṁṅot;扒;쀀𝔢ƀ;rsṐṑṗ檚ave耻è䃨Ā;dṜṝ檖ot;檘Ȁ;ilsṪṫṲṴ檙nters;揧;愓Ā;dṹṺ檕ot;檗ƀapsẅẉẗcr;䄓tyƀ;svẒẓẕ戅et»ẓpĀ1;ẝẤijạả;怄;怅怃ĀgsẪẬ;䅋p;怂ĀgpẴẸon;䄙f;쀀𝕖ƀalsỄỎỒrĀ;sỊị拕l;槣us;橱iƀ;lvỚớở䎵on»ớ;䏵ȀcsuvỪỳἋἣĀioữḱrc»Ḯɩỹ\0\0ỻíՈantĀglἂἆtr»ṝess»ṺƀaeiἒἚls;䀽st;扟vĀ;DȵἠD;橸parsl;槥ĀDaἯἳot;打rr;楱ƀcdiἾὁỸr;愯oô͒ĀahὉὋ;䎷耻ð䃰Āmrὓὗl耻ë䃫o;悬ƀcipὡὤὧl;䀡sôծĀeoὬὴctatioîՙnentialåչৡᾒ\0ᾞ\0ᾡᾧ\0\0ῆῌ\0ΐ\0ῦῪ \0 ⁚llingdotseñṄy;䑄male;晀ƀilrᾭᾳ῁lig;耀ffiɩᾹ\0\0᾽g;耀ffig;耀ffl;쀀𝔣lig;耀filig;쀀fjƀaltῙῡt;晭ig;耀flns;斱of;䆒ǰ΅\0ῳf;쀀𝕗ĀakֿῷĀ;vῼ´拔;櫙artint;樍Āao⁕Ācs‑⁒ႉ‸⁅⁈\0⁐β•‥‧\0耻½䂽;慓耻¼䂼;慕;慙;慛Ƴ‴\0‶;慔;慖ʴ‾⁁\0\0⁃耻¾䂾;慗;慜5;慘ƶ⁌\0⁎;慚;慝8;慞l;恄wn;挢cr;쀀𝒻ࢀEabcdefgijlnorstv₂₉₥₰₴⃰℃ℒℸ̗ℾ⅒↞Ā;lٍ₇;檌ƀcmpₐₕute;䇵maĀ;dₜ᳚䎳;檆reve;䄟Āiy₪₮rc;䄝;䐳ot;䄡Ȁ;lqsؾق₽ƀ;qsؾٌlanô٥Ȁ;cdl٥⃒⃥⃕c;檩otĀ;o⃜⃝檀Ā;l⃢⃣檂;檄Ā;e⃪⃭쀀⋛︀s;檔r;쀀𝔤Ā;gٳ؛mel;愷cy;䑓Ȁ;Eajٚℌℎℐ;檒;檥;檤ȀEaesℛℝ℩ℴ;扩pĀ;p℣ℤ檊rox»ℤĀ;q℮ℯ檈Ā;q℮ℛim;拧pf;쀀𝕘Āci⅃ⅆr;愊mƀ;el٫ⅎ⅐;檎;檐茀>;cdlqrⅠⅪⅮⅳⅹĀciⅥⅧ;檧r;橺ot;拗Par;榕uest;橼ʀadelsↄⅪ←ٖ↛ǰ↉\0proør;楸qĀlqؿ↖lesó₈ií٫Āen↣↭rtneqq;쀀≩︀Å↪ԀAabcefkosy⇄⇇⇱⇵⇺∘∝∯≨≽ròΠȀilmr⇐⇔⇗⇛rsðᒄf»․ilôکĀdr⇠⇤cy;䑊ƀ;cwࣴ⇫⇯ir;楈;憭ar;意irc;䄥ƀalr∁∎∓rtsĀ;u∉∊晥it»∊lip;怦con;抹r;쀀𝔥sĀew∣∩arow;椥arow;椦ʀamopr∺∾≃≞≣rr;懿tht;戻kĀlr≉≓eftarrow;憩ightarrow;憪f;쀀𝕙bar;怕ƀclt≯≴≸r;쀀𝒽asè⇴rok;䄧Ābp⊂⊇ull;恃hen»ᱛૡ⊣\0⊪\0⊸⋅⋎\0⋕⋳\0\0⋸⌢⍧⍢⍿\0⎆⎪⎴cute耻í䃭ƀ;iyݱ⊰⊵rc耻î䃮;䐸Ācx⊼⊿y;䐵cl耻¡䂡ĀfrΟ⋉;쀀𝔦rave耻ì䃬Ȁ;inoܾ⋝⋩⋮Āin⋢⋦nt;樌t;戭fin;槜ta;愩lig;䄳ƀaop⋾⌚⌝ƀcgt⌅⌈⌗r;䄫ƀelpܟ⌏⌓inåގarôܠh;䄱f;抷ed;䆵ʀ;cfotӴ⌬⌱⌽⍁are;愅inĀ;t⌸⌹戞ie;槝doô⌙ʀ;celpݗ⍌⍐⍛⍡al;抺Āgr⍕⍙eróᕣã⍍arhk;樗rod;樼Ȁcgpt⍯⍲⍶⍻y;䑑on;䄯f;쀀𝕚a;䎹uest耻¿䂿Āci⎊⎏r;쀀𝒾nʀ;EdsvӴ⎛⎝⎡ӳ;拹ot;拵Ā;v⎦⎧拴;拳Ā;iݷ⎮lde;䄩ǫ⎸\0⎼cy;䑖l耻ï䃯̀cfmosu⏌⏗⏜⏡⏧⏵Āiy⏑⏕rc;䄵;䐹r;쀀𝔧ath;䈷pf;쀀𝕛ǣ⏬\0⏱r;쀀𝒿rcy;䑘kcy;䑔Ѐacfghjos␋␖␢ppaĀ;v␓␔䎺;䏰Āey␛␠dil;䄷;䐺r;쀀𝔨reen;䄸cy;䑅cy;䑜pf;쀀𝕜cr;쀀𝓀ABEHabcdefghjlmnoprstuv⑰⒁⒆⒍⒑┎┽╚▀♎♞♥♹♽⚚⚲⛘❝❨➋⟀⠁⠒ƀart⑷⑺⑼ròòΕail;椛arr;椎Ā;gঔ⒋;檋ar;楢ॣ⒥\0⒪\0⒱\0\0\0\0\0⒵Ⓔ\0ⓆⓈⓍ\0⓹ute;䄺mptyv;榴raîࡌbda;䎻gƀ;dlࢎⓁⓃ;榑åࢎ;檅uo耻«䂫rЀ;bfhlpst࢙ⓞⓦⓩ⓫⓮⓱⓵Ā;f࢝ⓣs;椟s;椝ë≒p;憫l;椹im;楳l;憢ƀ;ae⓿─┄檫il;椙Ā;s┉┊檭;쀀⪭︀ƀabr┕┙┝rr;椌rk;杲Āak┢┬cĀek┨┪;䁻;䁛Āes┱┳;榋lĀdu┹┻;榏;榍Ȁaeuy╆╋╖╘ron;䄾Ādi═╔il;䄼ìࢰâ┩;䐻Ȁcqrs╣╦╭╽a;椶uoĀ;rนᝆĀdu╲╷har;楧shar;楋h;憲ʀ;fgqs▋▌উ◳◿扤tʀahlrt▘▤▷◂◨rrowĀ;t࢙□aé⓶arpoonĀdu▯▴own»њp»०eftarrows;懇ightƀahs◍◖◞rrowĀ;sࣴࢧarpoonóquigarro÷⇰hreetimes;拋ƀ;qs▋ও◺lanôবʀ;cdgsব☊☍☝☨c;檨otĀ;o☔☕橿Ā;r☚☛檁;檃Ā;e☢☥쀀⋚︀s;檓ʀadegs☳☹☽♉♋pproøⓆot;拖qĀgq♃♅ôউgtò⒌ôছiíলƀilr♕࣡♚sht;楼;쀀𝔩Ā;Eজ♣;檑š♩♶rĀdu▲♮Ā;l॥♳;楪lk;斄cy;䑙ʀ;achtੈ⚈⚋⚑⚖rò◁orneòᴈard;楫ri;旺Āio⚟⚤dot;䅀ustĀ;a⚬⚭掰che»⚭ȀEaes⚻⚽⛉⛔;扨pĀ;p⛃⛄檉rox»⛄Ā;q⛎⛏檇Ā;q⛎⚻im;拦Ѐabnoptwz⛩⛴⛷✚✯❁❇❐Ānr⛮⛱g;柬r;懽rëࣁgƀlmr⛿✍✔eftĀar০✇ightá৲apsto;柼ightá৽parrowĀlr✥✩efô⓭ight;憬ƀafl✶✹✽r;榅;쀀𝕝us;樭imes;樴š❋❏st;戗áፎƀ;ef❗❘᠀旊nge»❘arĀ;l❤❥䀨t;榓ʀachmt❳❶❼➅➇ròࢨorneòᶌarĀ;d➃;業;怎ri;抿̀achiqt➘➝ੀ➢➮➻quo;怹r;쀀𝓁mƀ;egল➪➬;檍;檏Ābu┪➳oĀ;rฟ➹;怚rok;䅂萀<;cdhilqrࠫ⟒☹⟜⟠⟥⟪⟰Āci⟗⟙;檦r;橹reå◲mes;拉arr;楶uest;橻ĀPi⟵⟹ar;榖ƀ;ef⠀भ旃rĀdu⠇⠍shar;楊har;楦Āen⠗⠡rtneqq;쀀≨︀Å⠞܀Dacdefhilnopsu⡀⡅⢂⢎⢓⢠⢥⢨⣚⣢⣤ઃ⣳⤂Dot;戺Ȁclpr⡎⡒⡣⡽r耻¯䂯Āet⡗⡙;時Ā;e⡞⡟朠se»⡟Ā;sျ⡨toȀ;dluျ⡳⡷⡻owîҌefôएðᏑker;斮Āoy⢇⢌mma;権;䐼ash;怔asuredangle»ᘦr;쀀𝔪o;愧ƀcdn⢯⢴⣉ro耻µ䂵Ȁ;acdᑤ⢽⣀⣄sôᚧir;櫰ot肻·Ƶusƀ;bd⣒ᤃ⣓戒Ā;uᴼ⣘;横ţ⣞⣡p;櫛ò−ðઁĀdp⣩⣮els;抧f;쀀𝕞Āct⣸⣽r;쀀𝓂pos»ᖝƀ;lm⤉⤊⤍䎼timap;抸ఀGLRVabcdefghijlmoprstuvw⥂⥓⥾⦉⦘⧚⧩⨕⨚⩘⩝⪃⪕⪤⪨⬄⬇⭄⭿⮮ⰴⱧⱼ⳩Āgt⥇⥋;쀀⋙̸Ā;v⥐쀀≫⃒ƀelt⥚⥲⥶ftĀar⥡⥧rrow;懍ightarrow;懎;쀀⋘̸Ā;v⥻ే쀀≪⃒ightarrow;懏ĀDd⦎⦓ash;抯ash;抮ʀbcnpt⦣⦧⦬⦱⧌la»˞ute;䅄g;쀀∠⃒ʀ;Eiop⦼⧀⧅⧈;쀀⩰̸d;쀀≋̸s;䅉roøurĀ;a⧓⧔普lĀ;s⧓ସdz⧟\0⧣p肻 ଷmpĀ;e௹ఀʀaeouy⧴⧾⨃⨐⨓ǰ⧹\0⧻;橃on;䅈dil;䅆ngĀ;dൾ⨊ot;쀀⩭̸p;橂;䐽ash;怓;Aadqsxஒ⨩⨭⨻⩁⩅⩐rr;懗rĀhr⨳⨶k;椤Ā;oᏲᏰot;쀀≐̸uiöୣĀei⩊⩎ar;椨íistĀ;sடr;쀀𝔫ȀEest⩦⩹⩼ƀ;qs⩭ƀ;qs⩴lanôií௪Ā;rஶ⪁»ஷƀAap⪊⪍⪑rò⥱rr;憮ar;櫲ƀ;svྍ⪜ྌĀ;d⪡⪢拼;拺cy;䑚AEadest⪷⪺⪾⫂⫅⫶⫹rò⥦;쀀≦̸rr;憚r;急Ȁ;fqs⫎⫣⫯tĀar⫔⫙rro÷⫁ightarro÷⪐ƀ;qs⪺⫪lanôౕĀ;sౕ⫴»శiíౝĀ;rవ⫾iĀ;eచథiäඐĀpt⬌⬑f;쀀𝕟膀¬;in⬙⬚⬶䂬nȀ;Edvஉ⬤⬨⬮;쀀⋹̸ot;쀀⋵̸ǡஉ⬳⬵;拷;拶iĀ;vಸ⬼ǡಸ⭁⭃;拾;拽ƀaor⭋⭣⭩rȀ;ast⭕⭚⭟lleìl;쀀⫽⃥;쀀∂̸lint;樔ƀ;ceಒ⭰⭳uåಥĀ;cಘ⭸Ā;eಒ⭽ñಘȀAait⮈⮋⮝⮧rò⦈rrƀ;cw⮔⮕⮙憛;쀀⤳̸;쀀↝̸ghtarrow»⮕riĀ;eೋೖchimpqu⮽⯍⯙⬄⯤⯯Ȁ;cerല⯆ഷ⯉uå;쀀𝓃ortɭ⬅\0\0⯖ará⭖mĀ;e൮⯟Ā;q൴൳suĀbp⯫⯭ååഋƀbcp⯶ⰑⰙȀ;Ees⯿ⰀഢⰄ抄;쀀⫅̸etĀ;eഛⰋqĀ;qണⰀcĀ;eലⰗñസȀ;EesⰢⰣൟⰧ抅;쀀⫆̸etĀ;e൘ⰮqĀ;qൠⰣȀgilrⰽⰿⱅⱇìௗlde耻ñ䃱çృiangleĀlrⱒⱜeftĀ;eచⱚñదightĀ;eೋⱥñĀ;mⱬⱭ䎽ƀ;esⱴⱵⱹ䀣ro;愖p;怇ҀDHadgilrsⲏⲔⲙⲞⲣⲰⲶⳓⳣash;抭arr;椄p;쀀≍⃒ash;抬ĀetⲨⲬ;쀀≥⃒;쀀>⃒nfin;槞ƀAetⲽⳁⳅrr;椂;쀀≤⃒Ā;rⳊⳍ쀀<⃒ie;쀀⊴⃒ĀAtⳘⳜrr;椃rie;쀀⊵⃒im;쀀∼⃒ƀAan⳰ⴂrr;懖rĀhr⳺⳽k;椣Ā;oᏧᏥear;椧ቓ᪕\0\0\0\0\0\0\0\0\0\0\0\0\0ⴭ\0ⴸⵈⵠⵥⶄᬇ\0\0ⶍⶫ\0ⷈⷎ\0ⷜ⸙⸫⸾⹃Ācsⴱ᪗ute耻ó䃳ĀiyⴼⵅrĀ;cⵂ耻ô䃴;䐾ʀabios᪠ⵒⵗLjⵚlac;䅑v;樸old;榼lig;䅓Ācrir;榿;쀀𝔬ͯ\0\0\0ⶂn;䋛ave耻ò䃲;槁Ābmⶈ෴ar;榵Ȁacitⶕⶥⶨrò᪀Āirⶠr;榾oss;榻nå๒;槀ƀaeiⶱⶵⶹcr;䅍ga;䏉ƀcdnⷀⷅǍron;䎿;榶pf;쀀𝕠ƀaelⷔǒr;榷rp;榹;adiosvⷪⷫⷮ⸈⸍⸐⸖戨rò᪆Ȁ;efmⷷⷸ⸂⸅橝rĀ;oⷾⷿ愴f»ⷿ耻ª䂪耻º䂺gof;抶r;橖lope;橗;橛ƀclo⸟⸡⸧ò⸁ash耻ø䃸l;折iŬⸯ⸴de耻õ䃵esĀ;aǛ⸺s;樶ml耻ö䃶bar;挽ૡ\0\0⺀⺝\0⺢⺹\0\0⻋ຜ\0⼓\0\0⼫⾼\0⿈rȀ;astЃ脀¶;l䂶leìЃɩ\0\0m;櫳;櫽y;䐿rʀcimpt⺋⺏⺓ᡥ⺗nt;䀥od;䀮il;怰enk;怱r;쀀𝔭ƀimo⺨⺰⺴Ā;v⺭⺮䏆;䏕maô੶ne;明ƀ;tv⺿⻀⻈䏀chfork»´;䏖Āau⻏⻟nĀck⻕⻝kĀ;h⇴⻛;愎ö⇴sҀ;abcdemst⻳ᤈ⼄⼆⼊⼎䀫cir;樣ir;樢Āouᵀ⼂;樥;橲n肻±ຝim;樦wo;樧ƀipu⼙⼠⼥ntint;樕f;쀀𝕡nd耻£䂣Ԁ;Eaceinosu່⼿⽁⽄⽇⾁⾉⾒⽾⾶;檳p;檷uå໙Ā;c໎⽌̀;acens່⽙⽟⽦⽨⽾pproø⽃urlyeñ໙ñ໎ƀaes⽯⽶⽺pprox;檹qq;檵im;拨iíໟmeĀ;s⾈ຮ怲ƀEas⽸⾐⽺ð⽵ƀdfp⾙⾯ƀals⾠⾥⾪lar;挮ine;挒urf;挓Ā;t⾴ïrel;抰Āci⿀⿅r;쀀𝓅;䏈ncsp;怈̀fiopsu⋢⿱r;쀀𝔮pf;쀀𝕢rime;恗cr;쀀𝓆ƀaeo⿸〉〓tĀei々rnionóڰnt;樖stĀ;e【】䀿ñἙô༔ABHabcdefhilmnoprstuxけさすムㄎㄫㅇㅢㅲㆎ㈆㈕㈤㈩㉘㉮㉲㊐㊰㊷ƀartぇおがròႳòϝail;検aròᱥar;楤cdenqrtとふへみわゔヌĀeuねぱ;쀀∽̱te;䅕iãᅮmptyv;榳gȀ;del࿑らるろ;榒;榥å࿑uo耻»䂻rր;abcfhlpstwガクシスゼゾダッデナp;極Ā;fゴs;椠;椳s;椞ë≝ð✮l;楅im;楴l;憣;憝Āaiパフil;椚oĀ;nホボ戶aló༞ƀabrョリヮrò៥rk;杳ĀakンヽcĀekヹ・;䁽;䁝Āes;榌lĀduㄊㄌ;榎;榐Ȁaeuyㄗㄜㄧㄩron;䅙Ādiㄡㄥil;䅗ìâヺ;䑀Ȁclqsㄴㄷㄽㅄa;椷dhar;楩uoĀ;rȎȍh;憳ƀacgㅎㅟངlȀ;ipsླྀㅘㅛႜnåႻarôྩt;断ƀilrㅩဣㅮsht;楽;쀀𝔯ĀaoㅷㆆrĀduㅽㅿ»ѻĀ;l႑ㆄ;楬Ā;vㆋㆌ䏁;䏱ƀgns㆕ㇹㇼht̀ahlrstㆤㆰ㇂㇘rrowĀ;tㆭaéトarpoonĀduㆻㆿowîㅾp»႒eftĀah㇊㇐rrowóarpoonóՑightarrows;應quigarro÷ニhreetimes;拌g;䋚ingdotseñἲƀahm㈍㈐㈓ròaòՑ;怏oustĀ;a㈞掱che»mid;櫮Ȁabpt㈲㈽㉀㉒Ānr㈷㈺g;柭r;懾rëဃƀafl㉇㉊㉎r;榆;쀀𝕣us;樮imes;樵Āap㉝㉧rĀ;g㉣㉤䀩t;榔olint;樒arò㇣Ȁachq㉻㊀Ⴜ㊅quo;怺r;쀀𝓇Ābu・㊊oĀ;rȔȓƀhir㊗㊛㊠reåㇸmes;拊iȀ;efl㊪ၙᠡ㊫方tri;槎luhar;楨;愞ൡ㋕㋛㋟㌬㌸㍱\0㍺㎤\0\0㏬㏰\0㐨㑈㑚㒭㒱㓊㓱\0㘖\0\0㘳cute;䅛quï➺Ԁ;Eaceinpsyᇭ㋳㋵㋿㌂㌋㌏㌟㌦㌩;檴ǰ㋺\0㋼;檸on;䅡uåᇾĀ;dᇳ㌇il;䅟rc;䅝ƀEas㌖㌘㌛;檶p;檺im;择olint;樓iíሄ;䑁otƀ;be㌴ᵇ㌵担;橦Aacmstx㍆㍊㍗㍛㍞㍣㍭rr;懘rĀhr㍐㍒ë∨Ā;oਸ਼t耻§䂧i;䀻war;椩mĀin㍩ðnuóñt;朶rĀ;o㍶⁕쀀𝔰Ȁacoy㎂㎆㎑㎠rp;景Āhy㎋㎏cy;䑉;䑈rtɭ㎙\0\0㎜iäᑤaraì耻䂭Āgm㎨㎴maƀ;fv㎱㎲㎲䏃;䏂Ѐ;deglnprካ㏅㏉㏎㏖㏞㏡㏦ot;橪Ā;qኰĀ;E㏓㏔檞;檠Ā;E㏛㏜檝;檟e;扆lus;樤arr;楲aròᄽȀaeit㏸㐈㐏㐗Āls㏽㐄lsetmé㍪hp;樳parsl;槤Ādlᑣ㐔e;挣Ā;e㐜㐝檪Ā;s㐢㐣檬;쀀⪬︀ƀflp㐮㐳㑂tcy;䑌Ā;b㐸㐹䀯Ā;a㐾㐿槄r;挿f;쀀𝕤aĀdr㑍ЂesĀ;u㑔㑕晠it»㑕ƀcsu㑠㑹㒟Āau㑥㑯pĀ;sᆈ㑫;쀀⊓︀pĀ;sᆴ㑵;쀀⊔︀uĀbp㑿㒏ƀ;esᆗᆜ㒆etĀ;eᆗ㒍ñᆝƀ;esᆨᆭ㒖etĀ;eᆨ㒝ñᆮƀ;afᅻ㒦ְrť㒫ֱ»ᅼaròᅈȀcemt㒹㒾㓂㓅r;쀀𝓈tmîñiì㐕aræᆾĀar㓎㓕rĀ;f㓔ឿ昆Āan㓚㓭ightĀep㓣㓪psiloîỠhé⺯s»⡒ʀbcmnp㓻㕞ሉ㖋㖎Ҁ;Edemnprs㔎㔏㔑㔕㔞㔣㔬㔱㔶抂;櫅ot;檽Ā;dᇚ㔚ot;櫃ult;櫁ĀEe㔨㔪;櫋;把lus;檿arr;楹ƀeiu㔽㕒㕕tƀ;en㔎㕅㕋qĀ;qᇚ㔏eqĀ;q㔫㔨m;櫇Ābp㕚㕜;櫕;櫓c̀;acensᇭ㕬㕲㕹㕻㌦pproø㋺urlyeñᇾñᇳƀaes㖂㖈㌛pproø㌚qñ㌗g;晪ڀ123;Edehlmnps㖩㖬㖯ሜ㖲㖴㗀㗉㗕㗚㗟㗨㗭耻¹䂹耻²䂲耻³䂳;櫆Āos㖹㖼t;檾ub;櫘Ā;dሢ㗅ot;櫄sĀou㗏㗒l;柉b;櫗arr;楻ult;櫂ĀEe㗤㗦;櫌;抋lus;櫀ƀeiu㗴㘉㘌tƀ;enሜ㗼㘂qĀ;qሢ㖲eqĀ;q㗧㗤m;櫈Ābp㘑㘓;櫔;櫖ƀAan㘜㘠㘭rr;懙rĀhr㘦㘨ë∮Ā;oਫwar;椪lig耻ß䃟㙑㙝㙠ዎ㙳㙹\0㙾㛂\0\0\0\0\0㛛㜃\0㜉㝬\0\0\0㞇ɲ㙖\0\0㙛get;挖;䏄rëƀaey㙦㙫㙰ron;䅥dil;䅣;䑂lrec;挕r;쀀𝔱Ȁeiko㚆㚝㚵㚼Dz㚋\0㚑eĀ4fኄኁaƀ;sv㚘㚙㚛䎸ym;䏑Ācn㚢㚲kĀas㚨㚮pproøim»ኬsðኞĀas㚺㚮ðrn耻þ䃾Ǭ̟㛆⋧es膀×;bd㛏㛐㛘䃗Ā;aᤏ㛕r;樱;樰ƀeps㛡㛣㜀á⩍Ȁ;bcf҆㛬㛰㛴ot;挶ir;櫱Ā;o㛹㛼쀀𝕥rk;櫚á㍢rime;怴ƀaip㜏㜒㝤dåቈadempst㜡㝍㝀㝑㝗㝜㝟ngleʀ;dlqr㜰㜱㜶㝀㝂斵own»ᶻeftĀ;e⠀㜾ñम;扜ightĀ;e㊪㝋ñၚot;旬inus;樺lus;樹b;槍ime;樻ezium;揢ƀcht㝲㝽㞁Āry㝷㝻;쀀𝓉;䑆cy;䑛rok;䅧Āio㞋㞎xôheadĀlr㞗㞠eftarro÷ࡏightarrow»ཝऀAHabcdfghlmoprstuw㟐㟓㟗㟤㟰㟼㠎㠜㠣㠴㡑㡝㡫㢩㣌㣒㣪㣶ròϭar;楣Ācr㟜㟢ute耻ú䃺òᅐrǣ㟪\0㟭y;䑞ve;䅭Āiy㟵㟺rc耻û䃻;䑃ƀabh㠃㠆㠋ròᎭlac;䅱aòᏃĀir㠓㠘sht;楾;쀀𝔲rave耻ù䃹š㠧㠱rĀlr㠬㠮»ॗ»ႃlk;斀Āct㠹㡍ɯ㠿\0\0㡊rnĀ;e㡅㡆挜r»㡆op;挏ri;旸Āal㡖㡚cr;䅫肻¨͉Āgp㡢㡦on;䅳f;쀀𝕦̀adhlsuᅋ㡸㡽፲㢑㢠ownáᎳarpoonĀlr㢈㢌efô㠭ighô㠯iƀ;hl㢙㢚㢜䏅»ᏺon»㢚parrows;懈ƀcit㢰㣄㣈ɯ㢶\0\0㣁rnĀ;e㢼㢽挝r»㢽op;挎ng;䅯ri;旹cr;쀀𝓊ƀdir㣙㣝㣢ot;拰lde;䅩iĀ;f㜰㣨»᠓Āam㣯㣲rò㢨l耻ü䃼angle;榧ހABDacdeflnoprsz㤜㤟㤩㤭㦵㦸㦽㧟㧤㧨㧳㧹㧽㨁㨠ròϷarĀ;v㤦㤧櫨;櫩asèϡĀnr㤲㤷grt;榜eknprst㓣㥆㥋㥒㥝㥤㦖appá␕othinçẖƀhir㓫⻈㥙opô⾵Ā;hᎷ㥢ïㆍĀiu㥩㥭gmá㎳Ābp㥲㦄setneqĀ;q㥽㦀쀀⊊︀;쀀⫋︀setneqĀ;q㦏㦒쀀⊋︀;쀀⫌︀Āhr㦛㦟etá㚜iangleĀlr㦪㦯eft»थight»ၑy;䐲ash»ံƀelr㧄㧒㧗ƀ;beⷪ㧋㧏ar;抻q;扚lip;拮Ābt㧜ᑨaòᑩr;쀀𝔳tré㦮suĀbp㧯㧱»ജ»൙pf;쀀𝕧roðtré㦴Ācu㨆㨋r;쀀𝓋Ābp㨐㨘nĀEe㦀㨖»㥾nĀEe㦒㨞»㦐igzag;榚cefoprs㨶㨻㩖㩛㩔㩡㩪irc;䅵Ādi㩀㩑Ābg㩅㩉ar;機eĀ;qᗺ㩏;扙erp;愘r;쀀𝔴pf;쀀𝕨Ā;eᑹ㩦atèᑹcr;쀀𝓌ૣណ㪇\0㪋\0㪐㪛\0\0㪝㪨㪫㪯\0\0㫃㫎\0㫘ៜtré៑r;쀀𝔵ĀAa㪔㪗ròσrò৶;䎾ĀAa㪡㪤ròθrò৫að✓is;拻ƀdptឤ㪵㪾Āfl㪺ឩ;쀀𝕩imåឲĀAa㫇㫊ròώròਁĀcq㫒ីr;쀀𝓍Āpt៖㫜ré។Ѐacefiosu㫰㫽㬈㬌㬑㬕㬛㬡cĀuy㫶㫻te耻ý䃽;䑏Āiy㬂㬆rc;䅷;䑋n耻¥䂥r;쀀𝔶cy;䑗pf;쀀𝕪cr;쀀𝓎Ācm㬦㬩y;䑎l耻ÿ䃿Ԁacdefhiosw㭂㭈㭔㭘㭤㭩㭭㭴㭺㮀cute;䅺Āay㭍㭒ron;䅾;䐷ot;䅼Āet㭝㭡træᕟa;䎶r;쀀𝔷cy;䐶grarr;懝pf;쀀𝕫cr;쀀𝓏Ājn㮅㮇;怍j;怌'.split("").map((e) => e.charCodeAt(0))
|
|
479
|
-
),
|
|
497
|
+
), Be = /* @__PURE__ */ new Uint16Array(
|
|
480
498
|
// prettier-ignore
|
|
481
499
|
/* @__PURE__ */ "Ȁaglq \x1Bɭ\0\0p;䀦os;䀧t;䀾t;䀼uot;䀢".split("").map((e) => e.charCodeAt(0))
|
|
482
500
|
);
|
|
483
501
|
var fu;
|
|
484
|
-
const
|
|
502
|
+
const Fe = /* @__PURE__ */ new Map([
|
|
485
503
|
[0, 65533],
|
|
486
504
|
// C1 Unicode control character reference replacements
|
|
487
505
|
[128, 8364],
|
|
@@ -518,15 +536,15 @@ const Be = /* @__PURE__ */ new Map([
|
|
|
518
536
|
return e > 65535 && (e -= 65536, u += String.fromCharCode(e >>> 10 & 1023 | 55296), e = 56320 | e & 1023), u += String.fromCharCode(e), u;
|
|
519
537
|
}
|
|
520
538
|
);
|
|
521
|
-
function
|
|
539
|
+
function $e(e) {
|
|
522
540
|
var u;
|
|
523
|
-
return e >= 55296 && e <= 57343 || e > 1114111 ? 65533 : (u =
|
|
541
|
+
return e >= 55296 && e <= 57343 || e > 1114111 ? 65533 : (u = Fe.get(e)) !== null && u !== void 0 ? u : e;
|
|
524
542
|
}
|
|
525
543
|
var V;
|
|
526
544
|
(function(e) {
|
|
527
545
|
e[e.NUM = 35] = "NUM", e[e.SEMI = 59] = "SEMI", e[e.EQUALS = 61] = "EQUALS", e[e.ZERO = 48] = "ZERO", e[e.NINE = 57] = "NINE", e[e.LOWER_A = 97] = "LOWER_A", e[e.LOWER_F = 102] = "LOWER_F", e[e.LOWER_X = 120] = "LOWER_X", e[e.LOWER_Z = 122] = "LOWER_Z", e[e.UPPER_A = 65] = "UPPER_A", e[e.UPPER_F = 70] = "UPPER_F", e[e.UPPER_Z = 90] = "UPPER_Z";
|
|
528
546
|
})(V || (V = {}));
|
|
529
|
-
const
|
|
547
|
+
const Ue = 32;
|
|
530
548
|
var W;
|
|
531
549
|
(function(e) {
|
|
532
550
|
e[e.VALUE_LENGTH = 49152] = "VALUE_LENGTH", e[e.BRANCH_LENGTH = 16256] = "BRANCH_LENGTH", e[e.JUMP_TABLE = 127] = "JUMP_TABLE";
|
|
@@ -534,26 +552,26 @@ var W;
|
|
|
534
552
|
function pu(e) {
|
|
535
553
|
return e >= V.ZERO && e <= V.NINE;
|
|
536
554
|
}
|
|
537
|
-
function
|
|
555
|
+
function Ge(e) {
|
|
538
556
|
return e >= V.UPPER_A && e <= V.UPPER_F || e >= V.LOWER_A && e <= V.LOWER_F;
|
|
539
557
|
}
|
|
540
|
-
function
|
|
558
|
+
function He(e) {
|
|
541
559
|
return e >= V.UPPER_A && e <= V.UPPER_Z || e >= V.LOWER_A && e <= V.LOWER_Z || pu(e);
|
|
542
560
|
}
|
|
543
|
-
function
|
|
544
|
-
return e === V.EQUALS ||
|
|
561
|
+
function We(e) {
|
|
562
|
+
return e === V.EQUALS || He(e);
|
|
545
563
|
}
|
|
546
564
|
var j;
|
|
547
565
|
(function(e) {
|
|
548
566
|
e[e.EntityStart = 0] = "EntityStart", e[e.NumericStart = 1] = "NumericStart", e[e.NumericDecimal = 2] = "NumericDecimal", e[e.NumericHex = 3] = "NumericHex", e[e.NamedEntity = 4] = "NamedEntity";
|
|
549
567
|
})(j || (j = {}));
|
|
550
|
-
var
|
|
568
|
+
var M;
|
|
551
569
|
(function(e) {
|
|
552
570
|
e[e.Legacy = 0] = "Legacy", e[e.Strict = 1] = "Strict", e[e.Attribute = 2] = "Attribute";
|
|
553
|
-
})(
|
|
554
|
-
class
|
|
571
|
+
})(M || (M = {}));
|
|
572
|
+
class Je {
|
|
555
573
|
constructor(u, t, a) {
|
|
556
|
-
this.decodeTree = u, this.emitCodePoint = t, this.errors = a, this.state = j.EntityStart, this.consumed = 1, this.result = 0, this.treeIndex = 0, this.excess = 1, this.decodeMode =
|
|
574
|
+
this.decodeTree = u, this.emitCodePoint = t, this.errors = a, this.state = j.EntityStart, this.consumed = 1, this.result = 0, this.treeIndex = 0, this.excess = 1, this.decodeMode = M.Strict;
|
|
557
575
|
}
|
|
558
576
|
/** Resets the instance to make it reusable. */
|
|
559
577
|
startEntity(u) {
|
|
@@ -594,7 +612,7 @@ class We {
|
|
|
594
612
|
* @returns The number of characters that were consumed, or -1 if the entity is incomplete.
|
|
595
613
|
*/
|
|
596
614
|
stateNumericStart(u, t) {
|
|
597
|
-
return t >= u.length ? -1 : (u.charCodeAt(t) |
|
|
615
|
+
return t >= u.length ? -1 : (u.charCodeAt(t) | Ue) === V.LOWER_X ? (this.state = j.NumericHex, this.consumed += 1, this.stateNumericHex(u, t + 1)) : (this.state = j.NumericDecimal, this.stateNumericDecimal(u, t));
|
|
598
616
|
}
|
|
599
617
|
addToNumericResult(u, t, a, r) {
|
|
600
618
|
if (t !== a) {
|
|
@@ -615,7 +633,7 @@ class We {
|
|
|
615
633
|
const a = t;
|
|
616
634
|
for (; t < u.length; ) {
|
|
617
635
|
const r = u.charCodeAt(t);
|
|
618
|
-
if (pu(r) ||
|
|
636
|
+
if (pu(r) || Ge(r))
|
|
619
637
|
t += 1;
|
|
620
638
|
else
|
|
621
639
|
return this.addToNumericResult(u, a, t, 16), this.emitNumericEntity(r, 3);
|
|
@@ -661,9 +679,9 @@ class We {
|
|
|
661
679
|
return (a = this.errors) === null || a === void 0 || a.absenceOfDigitsInNumericCharacterReference(this.consumed), 0;
|
|
662
680
|
if (u === V.SEMI)
|
|
663
681
|
this.consumed += 1;
|
|
664
|
-
else if (this.decodeMode ===
|
|
682
|
+
else if (this.decodeMode === M.Strict)
|
|
665
683
|
return 0;
|
|
666
|
-
return this.emitCodePoint(
|
|
684
|
+
return this.emitCodePoint($e(this.result), this.consumed), this.errors && (u !== V.SEMI && this.errors.missingSemicolonAfterCharacterReference(), this.errors.validateNumericCharacterReference(this.result)), this.consumed;
|
|
667
685
|
}
|
|
668
686
|
/**
|
|
669
687
|
* Parses a named entity.
|
|
@@ -679,15 +697,15 @@ class We {
|
|
|
679
697
|
let r = a[this.treeIndex], n = (r & W.VALUE_LENGTH) >> 14;
|
|
680
698
|
for (; t < u.length; t++, this.excess++) {
|
|
681
699
|
const i = u.charCodeAt(t);
|
|
682
|
-
if (this.treeIndex =
|
|
700
|
+
if (this.treeIndex = Xe(a, r, this.treeIndex + Math.max(1, n), i), this.treeIndex < 0)
|
|
683
701
|
return this.result === 0 || // If we are parsing an attribute
|
|
684
|
-
this.decodeMode ===
|
|
702
|
+
this.decodeMode === M.Attribute && // We shouldn't have consumed any characters after the entity,
|
|
685
703
|
(n === 0 || // And there should be no invalid characters.
|
|
686
|
-
|
|
704
|
+
We(i)) ? 0 : this.emitNotTerminatedNamedEntity();
|
|
687
705
|
if (r = a[this.treeIndex], n = (r & W.VALUE_LENGTH) >> 14, n !== 0) {
|
|
688
706
|
if (i === V.SEMI)
|
|
689
707
|
return this.emitNamedEntityData(this.treeIndex, n, this.consumed + this.excess);
|
|
690
|
-
this.decodeMode !==
|
|
708
|
+
this.decodeMode !== M.Strict && (this.result = this.treeIndex, this.consumed += this.excess, this.excess = 0);
|
|
691
709
|
}
|
|
692
710
|
}
|
|
693
711
|
return -1;
|
|
@@ -726,7 +744,7 @@ class We {
|
|
|
726
744
|
var u;
|
|
727
745
|
switch (this.state) {
|
|
728
746
|
case j.NamedEntity:
|
|
729
|
-
return this.result !== 0 && (this.decodeMode !==
|
|
747
|
+
return this.result !== 0 && (this.decodeMode !== M.Attribute || this.result === this.treeIndex) ? this.emitNotTerminatedNamedEntity() : 0;
|
|
730
748
|
// Otherwise, emit a numeric entity if we have one.
|
|
731
749
|
case j.NumericDecimal:
|
|
732
750
|
return this.emitNumericEntity(0, 2);
|
|
@@ -739,7 +757,7 @@ class We {
|
|
|
739
757
|
}
|
|
740
758
|
}
|
|
741
759
|
}
|
|
742
|
-
function
|
|
760
|
+
function Xe(e, u, t, a) {
|
|
743
761
|
const r = (u & W.BRANCH_LENGTH) >> 7, n = u & W.JUMP_TABLE;
|
|
744
762
|
if (r === 0)
|
|
745
763
|
return n !== 0 && a === n ? t : -1;
|
|
@@ -763,10 +781,10 @@ var g;
|
|
|
763
781
|
(function(e) {
|
|
764
782
|
e[e.Tab = 9] = "Tab", e[e.NewLine = 10] = "NewLine", e[e.FormFeed = 12] = "FormFeed", e[e.CarriageReturn = 13] = "CarriageReturn", e[e.Space = 32] = "Space", e[e.ExclamationMark = 33] = "ExclamationMark", e[e.Number = 35] = "Number", e[e.Amp = 38] = "Amp", e[e.SingleQuote = 39] = "SingleQuote", e[e.DoubleQuote = 34] = "DoubleQuote", e[e.Dash = 45] = "Dash", e[e.Slash = 47] = "Slash", e[e.Zero = 48] = "Zero", e[e.Nine = 57] = "Nine", e[e.Semi = 59] = "Semi", e[e.Lt = 60] = "Lt", e[e.Eq = 61] = "Eq", e[e.Gt = 62] = "Gt", e[e.Questionmark = 63] = "Questionmark", e[e.UpperA = 65] = "UpperA", e[e.LowerA = 97] = "LowerA", e[e.UpperF = 70] = "UpperF", e[e.LowerF = 102] = "LowerF", e[e.UpperZ = 90] = "UpperZ", e[e.LowerZ = 122] = "LowerZ", e[e.LowerX = 120] = "LowerX", e[e.OpeningSquareBracket = 91] = "OpeningSquareBracket";
|
|
765
783
|
})(g || (g = {}));
|
|
766
|
-
var
|
|
784
|
+
var f;
|
|
767
785
|
(function(e) {
|
|
768
786
|
e[e.Text = 1] = "Text", e[e.BeforeTagName = 2] = "BeforeTagName", e[e.InTagName = 3] = "InTagName", e[e.InSelfClosingTag = 4] = "InSelfClosingTag", e[e.BeforeClosingTagName = 5] = "BeforeClosingTagName", e[e.InClosingTagName = 6] = "InClosingTagName", e[e.AfterClosingTagName = 7] = "AfterClosingTagName", e[e.BeforeAttributeName = 8] = "BeforeAttributeName", e[e.InAttributeName = 9] = "InAttributeName", e[e.AfterAttributeName = 10] = "AfterAttributeName", e[e.BeforeAttributeValue = 11] = "BeforeAttributeValue", e[e.InAttributeValueDq = 12] = "InAttributeValueDq", e[e.InAttributeValueSq = 13] = "InAttributeValueSq", e[e.InAttributeValueNq = 14] = "InAttributeValueNq", e[e.BeforeDeclaration = 15] = "BeforeDeclaration", e[e.InDeclaration = 16] = "InDeclaration", e[e.InProcessingInstruction = 17] = "InProcessingInstruction", e[e.BeforeComment = 18] = "BeforeComment", e[e.CDATASequence = 19] = "CDATASequence", e[e.InSpecialComment = 20] = "InSpecialComment", e[e.InCommentLike = 21] = "InCommentLike", e[e.BeforeSpecialS = 22] = "BeforeSpecialS", e[e.BeforeSpecialT = 23] = "BeforeSpecialT", e[e.SpecialStartSequence = 24] = "SpecialStartSequence", e[e.InSpecialTag = 25] = "InSpecialTag", e[e.InEntity = 26] = "InEntity";
|
|
769
|
-
})(
|
|
787
|
+
})(f || (f = {}));
|
|
770
788
|
function U(e) {
|
|
771
789
|
return e === g.Space || e === g.NewLine || e === g.Tab || e === g.FormFeed || e === g.CarriageReturn;
|
|
772
790
|
}
|
|
@@ -776,10 +794,10 @@ function tu(e) {
|
|
|
776
794
|
function ze(e) {
|
|
777
795
|
return e >= g.LowerA && e <= g.LowerZ || e >= g.UpperA && e <= g.UpperZ;
|
|
778
796
|
}
|
|
779
|
-
var
|
|
797
|
+
var O;
|
|
780
798
|
(function(e) {
|
|
781
799
|
e[e.NoValue = 0] = "NoValue", e[e.Unquoted = 1] = "Unquoted", e[e.Single = 2] = "Single", e[e.Double = 3] = "Double";
|
|
782
|
-
})(
|
|
800
|
+
})(O || (O = {}));
|
|
783
801
|
const N = {
|
|
784
802
|
Cdata: new Uint8Array([67, 68, 65, 84, 65, 91]),
|
|
785
803
|
// CDATA[
|
|
@@ -809,12 +827,12 @@ const N = {
|
|
|
809
827
|
XmpEnd: new Uint8Array([60, 47, 120, 109, 112])
|
|
810
828
|
// `</xmp`
|
|
811
829
|
};
|
|
812
|
-
class
|
|
830
|
+
class Qe {
|
|
813
831
|
constructor({ xmlMode: u = !1, decodeEntities: t = !0 }, a) {
|
|
814
|
-
this.cbs = a, this.state =
|
|
832
|
+
this.cbs = a, this.state = f.Text, this.buffer = "", this.sectionStart = 0, this.index = 0, this.entityStart = 0, this.baseState = f.Text, this.isSpecial = !1, this.running = !0, this.offset = 0, this.currentSequence = void 0, this.sequenceIndex = 0, this.xmlMode = u, this.decodeEntities = t, this.entityDecoder = new Je(u ? Be : Oe, (r, n) => this.emitCodePoint(r, n));
|
|
815
833
|
}
|
|
816
834
|
reset() {
|
|
817
|
-
this.state =
|
|
835
|
+
this.state = f.Text, this.buffer = "", this.sectionStart = 0, this.index = 0, this.baseState = f.Text, this.currentSequence = void 0, this.running = !0, this.offset = 0;
|
|
818
836
|
}
|
|
819
837
|
write(u) {
|
|
820
838
|
this.offset += this.buffer.length, this.buffer = u, this.parse();
|
|
@@ -829,7 +847,7 @@ class Xe {
|
|
|
829
847
|
this.running = !0, this.index < this.buffer.length + this.offset && this.parse();
|
|
830
848
|
}
|
|
831
849
|
stateText(u) {
|
|
832
|
-
u === g.Lt || !this.decodeEntities && this.fastForwardTo(g.Lt) ? (this.index > this.sectionStart && this.cbs.ontext(this.sectionStart, this.index), this.state =
|
|
850
|
+
u === g.Lt || !this.decodeEntities && this.fastForwardTo(g.Lt) ? (this.index > this.sectionStart && this.cbs.ontext(this.sectionStart, this.index), this.state = f.BeforeTagName, this.sectionStart = this.index) : this.decodeEntities && u === g.Amp && this.startEntity();
|
|
833
851
|
}
|
|
834
852
|
stateSpecialStartSequence(u) {
|
|
835
853
|
const t = this.sequenceIndex === this.currentSequence.length;
|
|
@@ -845,7 +863,7 @@ class Xe {
|
|
|
845
863
|
this.sequenceIndex++;
|
|
846
864
|
return;
|
|
847
865
|
}
|
|
848
|
-
this.sequenceIndex = 0, this.state =
|
|
866
|
+
this.sequenceIndex = 0, this.state = f.InTagName, this.stateInTagName(u);
|
|
849
867
|
}
|
|
850
868
|
/** Look for an end tag. For <title> tags, also decode entities. */
|
|
851
869
|
stateInSpecialTag(u) {
|
|
@@ -864,7 +882,7 @@ class Xe {
|
|
|
864
882
|
(u | 32) === this.currentSequence[this.sequenceIndex] ? this.sequenceIndex += 1 : this.sequenceIndex === 0 ? this.currentSequence === N.TitleEnd ? this.decodeEntities && u === g.Amp && this.startEntity() : this.fastForwardTo(g.Lt) && (this.sequenceIndex = 1) : this.sequenceIndex = +(u === g.Lt);
|
|
865
883
|
}
|
|
866
884
|
stateCDATASequence(u) {
|
|
867
|
-
u === N.Cdata[this.sequenceIndex] ? ++this.sequenceIndex === N.Cdata.length && (this.state =
|
|
885
|
+
u === N.Cdata[this.sequenceIndex] ? ++this.sequenceIndex === N.Cdata.length && (this.state = f.InCommentLike, this.currentSequence = N.CdataEnd, this.sequenceIndex = 0, this.sectionStart = this.index + 1) : (this.sequenceIndex = 0, this.state = f.InDeclaration, this.stateInDeclaration(u));
|
|
868
886
|
}
|
|
869
887
|
/**
|
|
870
888
|
* When we wait for one specific character, we can speed things up
|
|
@@ -887,7 +905,7 @@ class Xe {
|
|
|
887
905
|
* - All characters but the start character of the sequence can be skipped.
|
|
888
906
|
*/
|
|
889
907
|
stateInCommentLike(u) {
|
|
890
|
-
u === this.currentSequence[this.sequenceIndex] ? ++this.sequenceIndex === this.currentSequence.length && (this.currentSequence === N.CdataEnd ? this.cbs.oncdata(this.sectionStart, this.index, 2) : this.cbs.oncomment(this.sectionStart, this.index, 2), this.sequenceIndex = 0, this.sectionStart = this.index + 1, this.state =
|
|
908
|
+
u === this.currentSequence[this.sequenceIndex] ? ++this.sequenceIndex === this.currentSequence.length && (this.currentSequence === N.CdataEnd ? this.cbs.oncdata(this.sectionStart, this.index, 2) : this.cbs.oncomment(this.sectionStart, this.index, 2), this.sequenceIndex = 0, this.sectionStart = this.index + 1, this.state = f.Text) : this.sequenceIndex === 0 ? this.fastForwardTo(this.currentSequence[0]) && (this.sequenceIndex = 1) : u !== this.currentSequence[this.sequenceIndex - 1] && (this.sequenceIndex = 0);
|
|
891
909
|
}
|
|
892
910
|
/**
|
|
893
911
|
* HTML only allows ASCII alpha characters (a-z and A-Z) at the beginning of a tag name.
|
|
@@ -899,47 +917,47 @@ class Xe {
|
|
|
899
917
|
return this.xmlMode ? !tu(u) : ze(u);
|
|
900
918
|
}
|
|
901
919
|
startSpecial(u, t) {
|
|
902
|
-
this.isSpecial = !0, this.currentSequence = u, this.sequenceIndex = t, this.state =
|
|
920
|
+
this.isSpecial = !0, this.currentSequence = u, this.sequenceIndex = t, this.state = f.SpecialStartSequence;
|
|
903
921
|
}
|
|
904
922
|
stateBeforeTagName(u) {
|
|
905
923
|
if (u === g.ExclamationMark)
|
|
906
|
-
this.state =
|
|
924
|
+
this.state = f.BeforeDeclaration, this.sectionStart = this.index + 1;
|
|
907
925
|
else if (u === g.Questionmark)
|
|
908
|
-
this.state =
|
|
926
|
+
this.state = f.InProcessingInstruction, this.sectionStart = this.index + 1;
|
|
909
927
|
else if (this.isTagStartChar(u)) {
|
|
910
928
|
const t = u | 32;
|
|
911
|
-
this.sectionStart = this.index, this.xmlMode ? this.state =
|
|
912
|
-
} else u === g.Slash ? this.state =
|
|
929
|
+
this.sectionStart = this.index, this.xmlMode ? this.state = f.InTagName : t === N.ScriptEnd[2] ? this.state = f.BeforeSpecialS : t === N.TitleEnd[2] || t === N.XmpEnd[2] ? this.state = f.BeforeSpecialT : this.state = f.InTagName;
|
|
930
|
+
} else u === g.Slash ? this.state = f.BeforeClosingTagName : (this.state = f.Text, this.stateText(u));
|
|
913
931
|
}
|
|
914
932
|
stateInTagName(u) {
|
|
915
|
-
tu(u) && (this.cbs.onopentagname(this.sectionStart, this.index), this.sectionStart = -1, this.state =
|
|
933
|
+
tu(u) && (this.cbs.onopentagname(this.sectionStart, this.index), this.sectionStart = -1, this.state = f.BeforeAttributeName, this.stateBeforeAttributeName(u));
|
|
916
934
|
}
|
|
917
935
|
stateBeforeClosingTagName(u) {
|
|
918
|
-
U(u) || (u === g.Gt ? this.state =
|
|
936
|
+
U(u) || (u === g.Gt ? this.state = f.Text : (this.state = this.isTagStartChar(u) ? f.InClosingTagName : f.InSpecialComment, this.sectionStart = this.index));
|
|
919
937
|
}
|
|
920
938
|
stateInClosingTagName(u) {
|
|
921
|
-
(u === g.Gt || U(u)) && (this.cbs.onclosetag(this.sectionStart, this.index), this.sectionStart = -1, this.state =
|
|
939
|
+
(u === g.Gt || U(u)) && (this.cbs.onclosetag(this.sectionStart, this.index), this.sectionStart = -1, this.state = f.AfterClosingTagName, this.stateAfterClosingTagName(u));
|
|
922
940
|
}
|
|
923
941
|
stateAfterClosingTagName(u) {
|
|
924
|
-
(u === g.Gt || this.fastForwardTo(g.Gt)) && (this.state =
|
|
942
|
+
(u === g.Gt || this.fastForwardTo(g.Gt)) && (this.state = f.Text, this.sectionStart = this.index + 1);
|
|
925
943
|
}
|
|
926
944
|
stateBeforeAttributeName(u) {
|
|
927
|
-
u === g.Gt ? (this.cbs.onopentagend(this.index), this.isSpecial ? (this.state =
|
|
945
|
+
u === g.Gt ? (this.cbs.onopentagend(this.index), this.isSpecial ? (this.state = f.InSpecialTag, this.sequenceIndex = 0) : this.state = f.Text, this.sectionStart = this.index + 1) : u === g.Slash ? this.state = f.InSelfClosingTag : U(u) || (this.state = f.InAttributeName, this.sectionStart = this.index);
|
|
928
946
|
}
|
|
929
947
|
stateInSelfClosingTag(u) {
|
|
930
|
-
u === g.Gt ? (this.cbs.onselfclosingtag(this.index), this.state =
|
|
948
|
+
u === g.Gt ? (this.cbs.onselfclosingtag(this.index), this.state = f.Text, this.sectionStart = this.index + 1, this.isSpecial = !1) : U(u) || (this.state = f.BeforeAttributeName, this.stateBeforeAttributeName(u));
|
|
931
949
|
}
|
|
932
950
|
stateInAttributeName(u) {
|
|
933
|
-
(u === g.Eq || tu(u)) && (this.cbs.onattribname(this.sectionStart, this.index), this.sectionStart = this.index, this.state =
|
|
951
|
+
(u === g.Eq || tu(u)) && (this.cbs.onattribname(this.sectionStart, this.index), this.sectionStart = this.index, this.state = f.AfterAttributeName, this.stateAfterAttributeName(u));
|
|
934
952
|
}
|
|
935
953
|
stateAfterAttributeName(u) {
|
|
936
|
-
u === g.Eq ? this.state =
|
|
954
|
+
u === g.Eq ? this.state = f.BeforeAttributeValue : u === g.Slash || u === g.Gt ? (this.cbs.onattribend(O.NoValue, this.sectionStart), this.sectionStart = -1, this.state = f.BeforeAttributeName, this.stateBeforeAttributeName(u)) : U(u) || (this.cbs.onattribend(O.NoValue, this.sectionStart), this.state = f.InAttributeName, this.sectionStart = this.index);
|
|
937
955
|
}
|
|
938
956
|
stateBeforeAttributeValue(u) {
|
|
939
|
-
u === g.DoubleQuote ? (this.state =
|
|
957
|
+
u === g.DoubleQuote ? (this.state = f.InAttributeValueDq, this.sectionStart = this.index + 1) : u === g.SingleQuote ? (this.state = f.InAttributeValueSq, this.sectionStart = this.index + 1) : U(u) || (this.sectionStart = this.index, this.state = f.InAttributeValueNq, this.stateInAttributeValueNoQuotes(u));
|
|
940
958
|
}
|
|
941
959
|
handleInAttributeValue(u, t) {
|
|
942
|
-
u === t || !this.decodeEntities && this.fastForwardTo(t) ? (this.cbs.onattribdata(this.sectionStart, this.index), this.sectionStart = -1, this.cbs.onattribend(t === g.DoubleQuote ?
|
|
960
|
+
u === t || !this.decodeEntities && this.fastForwardTo(t) ? (this.cbs.onattribdata(this.sectionStart, this.index), this.sectionStart = -1, this.cbs.onattribend(t === g.DoubleQuote ? O.Double : O.Single, this.index + 1), this.state = f.BeforeAttributeName) : this.decodeEntities && u === g.Amp && this.startEntity();
|
|
943
961
|
}
|
|
944
962
|
stateInAttributeValueDoubleQuotes(u) {
|
|
945
963
|
this.handleInAttributeValue(u, g.DoubleQuote);
|
|
@@ -948,26 +966,26 @@ class Xe {
|
|
|
948
966
|
this.handleInAttributeValue(u, g.SingleQuote);
|
|
949
967
|
}
|
|
950
968
|
stateInAttributeValueNoQuotes(u) {
|
|
951
|
-
U(u) || u === g.Gt ? (this.cbs.onattribdata(this.sectionStart, this.index), this.sectionStart = -1, this.cbs.onattribend(
|
|
969
|
+
U(u) || u === g.Gt ? (this.cbs.onattribdata(this.sectionStart, this.index), this.sectionStart = -1, this.cbs.onattribend(O.Unquoted, this.index), this.state = f.BeforeAttributeName, this.stateBeforeAttributeName(u)) : this.decodeEntities && u === g.Amp && this.startEntity();
|
|
952
970
|
}
|
|
953
971
|
stateBeforeDeclaration(u) {
|
|
954
|
-
u === g.OpeningSquareBracket ? (this.state =
|
|
972
|
+
u === g.OpeningSquareBracket ? (this.state = f.CDATASequence, this.sequenceIndex = 0) : this.state = u === g.Dash ? f.BeforeComment : f.InDeclaration;
|
|
955
973
|
}
|
|
956
974
|
stateInDeclaration(u) {
|
|
957
|
-
(u === g.Gt || this.fastForwardTo(g.Gt)) && (this.cbs.ondeclaration(this.sectionStart, this.index), this.state =
|
|
975
|
+
(u === g.Gt || this.fastForwardTo(g.Gt)) && (this.cbs.ondeclaration(this.sectionStart, this.index), this.state = f.Text, this.sectionStart = this.index + 1);
|
|
958
976
|
}
|
|
959
977
|
stateInProcessingInstruction(u) {
|
|
960
|
-
(u === g.Gt || this.fastForwardTo(g.Gt)) && (this.cbs.onprocessinginstruction(this.sectionStart, this.index), this.state =
|
|
978
|
+
(u === g.Gt || this.fastForwardTo(g.Gt)) && (this.cbs.onprocessinginstruction(this.sectionStart, this.index), this.state = f.Text, this.sectionStart = this.index + 1);
|
|
961
979
|
}
|
|
962
980
|
stateBeforeComment(u) {
|
|
963
|
-
u === g.Dash ? (this.state =
|
|
981
|
+
u === g.Dash ? (this.state = f.InCommentLike, this.currentSequence = N.CommentEnd, this.sequenceIndex = 2, this.sectionStart = this.index + 1) : this.state = f.InDeclaration;
|
|
964
982
|
}
|
|
965
983
|
stateInSpecialComment(u) {
|
|
966
|
-
(u === g.Gt || this.fastForwardTo(g.Gt)) && (this.cbs.oncomment(this.sectionStart, this.index, 0), this.state =
|
|
984
|
+
(u === g.Gt || this.fastForwardTo(g.Gt)) && (this.cbs.oncomment(this.sectionStart, this.index, 0), this.state = f.Text, this.sectionStart = this.index + 1);
|
|
967
985
|
}
|
|
968
986
|
stateBeforeSpecialS(u) {
|
|
969
987
|
const t = u | 32;
|
|
970
|
-
t === N.ScriptEnd[3] ? this.startSpecial(N.ScriptEnd, 4) : t === N.StyleEnd[3] ? this.startSpecial(N.StyleEnd, 4) : (this.state =
|
|
988
|
+
t === N.ScriptEnd[3] ? this.startSpecial(N.ScriptEnd, 4) : t === N.StyleEnd[3] ? this.startSpecial(N.StyleEnd, 4) : (this.state = f.InTagName, this.stateInTagName(u));
|
|
971
989
|
}
|
|
972
990
|
stateBeforeSpecialT(u) {
|
|
973
991
|
switch (u | 32) {
|
|
@@ -984,11 +1002,11 @@ class Xe {
|
|
|
984
1002
|
break;
|
|
985
1003
|
}
|
|
986
1004
|
default:
|
|
987
|
-
this.state =
|
|
1005
|
+
this.state = f.InTagName, this.stateInTagName(u);
|
|
988
1006
|
}
|
|
989
1007
|
}
|
|
990
1008
|
startEntity() {
|
|
991
|
-
this.baseState = this.state, this.state =
|
|
1009
|
+
this.baseState = this.state, this.state = f.InEntity, this.entityStart = this.index, this.entityDecoder.startEntity(this.xmlMode ? M.Strict : this.baseState === f.Text || this.baseState === f.InSpecialTag ? M.Legacy : M.Attribute);
|
|
992
1010
|
}
|
|
993
1011
|
stateInEntity() {
|
|
994
1012
|
const u = this.entityDecoder.write(this.buffer, this.index - this.offset);
|
|
@@ -998,7 +1016,7 @@ class Xe {
|
|
|
998
1016
|
* Remove data that has already been consumed from the buffer.
|
|
999
1017
|
*/
|
|
1000
1018
|
cleanup() {
|
|
1001
|
-
this.running && this.sectionStart !== this.index && (this.state ===
|
|
1019
|
+
this.running && this.sectionStart !== this.index && (this.state === f.Text || this.state === f.InSpecialTag && this.sequenceIndex === 0 ? (this.cbs.ontext(this.sectionStart, this.index), this.sectionStart = this.index) : (this.state === f.InAttributeValueDq || this.state === f.InAttributeValueSq || this.state === f.InAttributeValueNq) && (this.cbs.onattribdata(this.sectionStart, this.index), this.sectionStart = this.index));
|
|
1002
1020
|
}
|
|
1003
1021
|
shouldContinue() {
|
|
1004
1022
|
return this.index < this.buffer.length + this.offset && this.running;
|
|
@@ -1012,107 +1030,107 @@ class Xe {
|
|
|
1012
1030
|
for (; this.shouldContinue(); ) {
|
|
1013
1031
|
const u = this.buffer.charCodeAt(this.index - this.offset);
|
|
1014
1032
|
switch (this.state) {
|
|
1015
|
-
case
|
|
1033
|
+
case f.Text: {
|
|
1016
1034
|
this.stateText(u);
|
|
1017
1035
|
break;
|
|
1018
1036
|
}
|
|
1019
|
-
case
|
|
1037
|
+
case f.SpecialStartSequence: {
|
|
1020
1038
|
this.stateSpecialStartSequence(u);
|
|
1021
1039
|
break;
|
|
1022
1040
|
}
|
|
1023
|
-
case
|
|
1041
|
+
case f.InSpecialTag: {
|
|
1024
1042
|
this.stateInSpecialTag(u);
|
|
1025
1043
|
break;
|
|
1026
1044
|
}
|
|
1027
|
-
case
|
|
1045
|
+
case f.CDATASequence: {
|
|
1028
1046
|
this.stateCDATASequence(u);
|
|
1029
1047
|
break;
|
|
1030
1048
|
}
|
|
1031
|
-
case
|
|
1049
|
+
case f.InAttributeValueDq: {
|
|
1032
1050
|
this.stateInAttributeValueDoubleQuotes(u);
|
|
1033
1051
|
break;
|
|
1034
1052
|
}
|
|
1035
|
-
case
|
|
1053
|
+
case f.InAttributeName: {
|
|
1036
1054
|
this.stateInAttributeName(u);
|
|
1037
1055
|
break;
|
|
1038
1056
|
}
|
|
1039
|
-
case
|
|
1057
|
+
case f.InCommentLike: {
|
|
1040
1058
|
this.stateInCommentLike(u);
|
|
1041
1059
|
break;
|
|
1042
1060
|
}
|
|
1043
|
-
case
|
|
1061
|
+
case f.InSpecialComment: {
|
|
1044
1062
|
this.stateInSpecialComment(u);
|
|
1045
1063
|
break;
|
|
1046
1064
|
}
|
|
1047
|
-
case
|
|
1065
|
+
case f.BeforeAttributeName: {
|
|
1048
1066
|
this.stateBeforeAttributeName(u);
|
|
1049
1067
|
break;
|
|
1050
1068
|
}
|
|
1051
|
-
case
|
|
1069
|
+
case f.InTagName: {
|
|
1052
1070
|
this.stateInTagName(u);
|
|
1053
1071
|
break;
|
|
1054
1072
|
}
|
|
1055
|
-
case
|
|
1073
|
+
case f.InClosingTagName: {
|
|
1056
1074
|
this.stateInClosingTagName(u);
|
|
1057
1075
|
break;
|
|
1058
1076
|
}
|
|
1059
|
-
case
|
|
1077
|
+
case f.BeforeTagName: {
|
|
1060
1078
|
this.stateBeforeTagName(u);
|
|
1061
1079
|
break;
|
|
1062
1080
|
}
|
|
1063
|
-
case
|
|
1081
|
+
case f.AfterAttributeName: {
|
|
1064
1082
|
this.stateAfterAttributeName(u);
|
|
1065
1083
|
break;
|
|
1066
1084
|
}
|
|
1067
|
-
case
|
|
1085
|
+
case f.InAttributeValueSq: {
|
|
1068
1086
|
this.stateInAttributeValueSingleQuotes(u);
|
|
1069
1087
|
break;
|
|
1070
1088
|
}
|
|
1071
|
-
case
|
|
1089
|
+
case f.BeforeAttributeValue: {
|
|
1072
1090
|
this.stateBeforeAttributeValue(u);
|
|
1073
1091
|
break;
|
|
1074
1092
|
}
|
|
1075
|
-
case
|
|
1093
|
+
case f.BeforeClosingTagName: {
|
|
1076
1094
|
this.stateBeforeClosingTagName(u);
|
|
1077
1095
|
break;
|
|
1078
1096
|
}
|
|
1079
|
-
case
|
|
1097
|
+
case f.AfterClosingTagName: {
|
|
1080
1098
|
this.stateAfterClosingTagName(u);
|
|
1081
1099
|
break;
|
|
1082
1100
|
}
|
|
1083
|
-
case
|
|
1101
|
+
case f.BeforeSpecialS: {
|
|
1084
1102
|
this.stateBeforeSpecialS(u);
|
|
1085
1103
|
break;
|
|
1086
1104
|
}
|
|
1087
|
-
case
|
|
1105
|
+
case f.BeforeSpecialT: {
|
|
1088
1106
|
this.stateBeforeSpecialT(u);
|
|
1089
1107
|
break;
|
|
1090
1108
|
}
|
|
1091
|
-
case
|
|
1109
|
+
case f.InAttributeValueNq: {
|
|
1092
1110
|
this.stateInAttributeValueNoQuotes(u);
|
|
1093
1111
|
break;
|
|
1094
1112
|
}
|
|
1095
|
-
case
|
|
1113
|
+
case f.InSelfClosingTag: {
|
|
1096
1114
|
this.stateInSelfClosingTag(u);
|
|
1097
1115
|
break;
|
|
1098
1116
|
}
|
|
1099
|
-
case
|
|
1117
|
+
case f.InDeclaration: {
|
|
1100
1118
|
this.stateInDeclaration(u);
|
|
1101
1119
|
break;
|
|
1102
1120
|
}
|
|
1103
|
-
case
|
|
1121
|
+
case f.BeforeDeclaration: {
|
|
1104
1122
|
this.stateBeforeDeclaration(u);
|
|
1105
1123
|
break;
|
|
1106
1124
|
}
|
|
1107
|
-
case
|
|
1125
|
+
case f.BeforeComment: {
|
|
1108
1126
|
this.stateBeforeComment(u);
|
|
1109
1127
|
break;
|
|
1110
1128
|
}
|
|
1111
|
-
case
|
|
1129
|
+
case f.InProcessingInstruction: {
|
|
1112
1130
|
this.stateInProcessingInstruction(u);
|
|
1113
1131
|
break;
|
|
1114
1132
|
}
|
|
1115
|
-
case
|
|
1133
|
+
case f.InEntity: {
|
|
1116
1134
|
this.stateInEntity();
|
|
1117
1135
|
break;
|
|
1118
1136
|
}
|
|
@@ -1122,18 +1140,18 @@ class Xe {
|
|
|
1122
1140
|
this.cleanup();
|
|
1123
1141
|
}
|
|
1124
1142
|
finish() {
|
|
1125
|
-
this.state ===
|
|
1143
|
+
this.state === f.InEntity && (this.entityDecoder.end(), this.state = this.baseState), this.handleTrailingData(), this.cbs.onend();
|
|
1126
1144
|
}
|
|
1127
1145
|
/** Handle any trailing data. */
|
|
1128
1146
|
handleTrailingData() {
|
|
1129
1147
|
const u = this.buffer.length + this.offset;
|
|
1130
|
-
this.sectionStart >= u || (this.state ===
|
|
1148
|
+
this.sectionStart >= u || (this.state === f.InCommentLike ? this.currentSequence === N.CdataEnd ? this.cbs.oncdata(this.sectionStart, u, 0) : this.cbs.oncomment(this.sectionStart, u, 0) : this.state === f.InTagName || this.state === f.BeforeAttributeName || this.state === f.BeforeAttributeValue || this.state === f.AfterAttributeName || this.state === f.InAttributeName || this.state === f.InAttributeValueSq || this.state === f.InAttributeValueDq || this.state === f.InAttributeValueNq || this.state === f.InClosingTagName || this.cbs.ontext(this.sectionStart, u));
|
|
1131
1149
|
}
|
|
1132
1150
|
emitCodePoint(u, t) {
|
|
1133
|
-
this.baseState !==
|
|
1151
|
+
this.baseState !== f.Text && this.baseState !== f.InSpecialTag ? (this.sectionStart < this.entityStart && this.cbs.onattribdata(this.sectionStart, this.entityStart), this.sectionStart = this.entityStart + t, this.index = this.sectionStart - 1, this.cbs.onattribentity(u)) : (this.sectionStart < this.entityStart && this.cbs.ontext(this.sectionStart, this.entityStart), this.sectionStart = this.entityStart + t, this.index = this.sectionStart - 1, this.cbs.ontextentity(u, this.sectionStart));
|
|
1134
1152
|
}
|
|
1135
1153
|
}
|
|
1136
|
-
const
|
|
1154
|
+
const z = /* @__PURE__ */ new Set([
|
|
1137
1155
|
"input",
|
|
1138
1156
|
"option",
|
|
1139
1157
|
"optgroup",
|
|
@@ -1141,7 +1159,7 @@ const X = /* @__PURE__ */ new Set([
|
|
|
1141
1159
|
"button",
|
|
1142
1160
|
"datalist",
|
|
1143
1161
|
"textarea"
|
|
1144
|
-
]), k = /* @__PURE__ */ new Set(["p"]), ku = /* @__PURE__ */ new Set(["thead", "tbody"]), Tu = /* @__PURE__ */ new Set(["dd", "dt"]), Nu = /* @__PURE__ */ new Set(["rt", "rp"]),
|
|
1162
|
+
]), k = /* @__PURE__ */ new Set(["p"]), ku = /* @__PURE__ */ new Set(["thead", "tbody"]), Tu = /* @__PURE__ */ new Set(["dd", "dt"]), Nu = /* @__PURE__ */ new Set(["rt", "rp"]), Ze = /* @__PURE__ */ new Map([
|
|
1145
1163
|
["tr", /* @__PURE__ */ new Set(["tr", "th", "td"])],
|
|
1146
1164
|
["th", /* @__PURE__ */ new Set(["th"])],
|
|
1147
1165
|
["td", /* @__PURE__ */ new Set(["thead", "th", "td"])],
|
|
@@ -1154,12 +1172,12 @@ const X = /* @__PURE__ */ new Set([
|
|
|
1154
1172
|
["h4", k],
|
|
1155
1173
|
["h5", k],
|
|
1156
1174
|
["h6", k],
|
|
1157
|
-
["select",
|
|
1158
|
-
["input",
|
|
1159
|
-
["output",
|
|
1160
|
-
["button",
|
|
1161
|
-
["datalist",
|
|
1162
|
-
["textarea",
|
|
1175
|
+
["select", z],
|
|
1176
|
+
["input", z],
|
|
1177
|
+
["output", z],
|
|
1178
|
+
["button", z],
|
|
1179
|
+
["datalist", z],
|
|
1180
|
+
["textarea", z],
|
|
1163
1181
|
["option", /* @__PURE__ */ new Set(["option"])],
|
|
1164
1182
|
["optgroup", /* @__PURE__ */ new Set(["optgroup", "option"])],
|
|
1165
1183
|
["dd", Tu],
|
|
@@ -1189,7 +1207,7 @@ const X = /* @__PURE__ */ new Set([
|
|
|
1189
1207
|
["rp", Nu],
|
|
1190
1208
|
["tbody", ku],
|
|
1191
1209
|
["tfoot", ku]
|
|
1192
|
-
]),
|
|
1210
|
+
]), Ke = /* @__PURE__ */ new Set([
|
|
1193
1211
|
"area",
|
|
1194
1212
|
"base",
|
|
1195
1213
|
"basefont",
|
|
@@ -1219,11 +1237,11 @@ const X = /* @__PURE__ */ new Set([
|
|
|
1219
1237
|
"foreignobject",
|
|
1220
1238
|
"desc",
|
|
1221
1239
|
"title"
|
|
1222
|
-
]),
|
|
1223
|
-
class
|
|
1240
|
+
]), Ye = /\s|\//;
|
|
1241
|
+
class ut {
|
|
1224
1242
|
constructor(u, t = {}) {
|
|
1225
1243
|
var a, r, n, i, s, o;
|
|
1226
|
-
this.options = t, this.startIndex = 0, this.endIndex = 0, this.openTagStart = 0, this.tagname = "", this.attribname = "", this.attribvalue = "", this.attribs = null, this.stack = [], this.buffers = [], this.bufferOffset = 0, this.writeIndex = 0, this.ended = !1, this.cbs = u ?? {}, this.htmlMode = !this.options.xmlMode, this.lowerCaseTagNames = (a = t.lowerCaseTags) !== null && a !== void 0 ? a : this.htmlMode, this.lowerCaseAttributeNames = (r = t.lowerCaseAttributeNames) !== null && r !== void 0 ? r : this.htmlMode, this.recognizeSelfClosing = (n = t.recognizeSelfClosing) !== null && n !== void 0 ? n : !this.htmlMode, this.tokenizer = new ((i = t.Tokenizer) !== null && i !== void 0 ? i :
|
|
1244
|
+
this.options = t, this.startIndex = 0, this.endIndex = 0, this.openTagStart = 0, this.tagname = "", this.attribname = "", this.attribvalue = "", this.attribs = null, this.stack = [], this.buffers = [], this.bufferOffset = 0, this.writeIndex = 0, this.ended = !1, this.cbs = u ?? {}, this.htmlMode = !this.options.xmlMode, this.lowerCaseTagNames = (a = t.lowerCaseTags) !== null && a !== void 0 ? a : this.htmlMode, this.lowerCaseAttributeNames = (r = t.lowerCaseAttributeNames) !== null && r !== void 0 ? r : this.htmlMode, this.recognizeSelfClosing = (n = t.recognizeSelfClosing) !== null && n !== void 0 ? n : !this.htmlMode, this.tokenizer = new ((i = t.Tokenizer) !== null && i !== void 0 ? i : Qe)(this.options, this), this.foreignContext = [!this.htmlMode], (o = (s = this.cbs).onparserinit) === null || o === void 0 || o.call(s, this);
|
|
1227
1245
|
}
|
|
1228
1246
|
// Tokenizer event handlers
|
|
1229
1247
|
/** @internal */
|
|
@@ -1242,7 +1260,7 @@ class Ye {
|
|
|
1242
1260
|
* to specify your own additional void elements.
|
|
1243
1261
|
*/
|
|
1244
1262
|
isVoidElement(u) {
|
|
1245
|
-
return this.htmlMode &&
|
|
1263
|
+
return this.htmlMode && Ke.has(u);
|
|
1246
1264
|
}
|
|
1247
1265
|
/** @internal */
|
|
1248
1266
|
onopentagname(u, t) {
|
|
@@ -1253,7 +1271,7 @@ class Ye {
|
|
|
1253
1271
|
emitOpenTag(u) {
|
|
1254
1272
|
var t, a, r, n;
|
|
1255
1273
|
this.openTagStart = this.startIndex, this.tagname = u;
|
|
1256
|
-
const i = this.htmlMode &&
|
|
1274
|
+
const i = this.htmlMode && Ze.get(u);
|
|
1257
1275
|
if (i)
|
|
1258
1276
|
for (; this.stack.length > 0 && i.has(this.stack[0]); ) {
|
|
1259
1277
|
const s = this.stack.shift();
|
|
@@ -1273,17 +1291,17 @@ class Ye {
|
|
|
1273
1291
|
onclosetag(u, t) {
|
|
1274
1292
|
var a, r, n, i, s, o, c, d;
|
|
1275
1293
|
this.endIndex = t;
|
|
1276
|
-
let
|
|
1277
|
-
if (this.lowerCaseTagNames && (
|
|
1278
|
-
this.htmlMode &&
|
|
1294
|
+
let l = this.getSlice(u, t);
|
|
1295
|
+
if (this.lowerCaseTagNames && (l = l.toLowerCase()), this.htmlMode && (ju.has(l) || Vu.has(l)) && this.foreignContext.shift(), this.isVoidElement(l))
|
|
1296
|
+
this.htmlMode && l === "br" && ((i = (n = this.cbs).onopentagname) === null || i === void 0 || i.call(n, "br"), (o = (s = this.cbs).onopentag) === null || o === void 0 || o.call(s, "br", {}, !0), (d = (c = this.cbs).onclosetag) === null || d === void 0 || d.call(c, "br", !1));
|
|
1279
1297
|
else {
|
|
1280
|
-
const p = this.stack.indexOf(
|
|
1298
|
+
const p = this.stack.indexOf(l);
|
|
1281
1299
|
if (p !== -1)
|
|
1282
1300
|
for (let b = 0; b <= p; b++) {
|
|
1283
1301
|
const h = this.stack.shift();
|
|
1284
1302
|
(r = (a = this.cbs).onclosetag) === null || r === void 0 || r.call(a, h, b !== p);
|
|
1285
1303
|
}
|
|
1286
|
-
else this.htmlMode &&
|
|
1304
|
+
else this.htmlMode && l === "p" && (this.emitOpenTag("p"), this.closeCurrentTag(!0));
|
|
1287
1305
|
}
|
|
1288
1306
|
this.startIndex = t + 1;
|
|
1289
1307
|
}
|
|
@@ -1313,10 +1331,10 @@ class Ye {
|
|
|
1313
1331
|
/** @internal */
|
|
1314
1332
|
onattribend(u, t) {
|
|
1315
1333
|
var a, r;
|
|
1316
|
-
this.endIndex = t, (r = (a = this.cbs).onattribute) === null || r === void 0 || r.call(a, this.attribname, this.attribvalue, u ===
|
|
1334
|
+
this.endIndex = t, (r = (a = this.cbs).onattribute) === null || r === void 0 || r.call(a, this.attribname, this.attribvalue, u === O.Double ? '"' : u === O.Single ? "'" : u === O.NoValue ? void 0 : null), this.attribs && !Object.prototype.hasOwnProperty.call(this.attribs, this.attribname) && (this.attribs[this.attribname] = this.attribvalue), this.attribvalue = "";
|
|
1317
1335
|
}
|
|
1318
1336
|
getInstructionName(u) {
|
|
1319
|
-
const t = u.search(
|
|
1337
|
+
const t = u.search(Ye);
|
|
1320
1338
|
let a = t < 0 ? u : u.substr(0, t);
|
|
1321
1339
|
return this.lowerCaseTagNames && (a = a.toLowerCase()), a;
|
|
1322
1340
|
}
|
|
@@ -1347,10 +1365,10 @@ class Ye {
|
|
|
1347
1365
|
}
|
|
1348
1366
|
/** @internal */
|
|
1349
1367
|
oncdata(u, t, a) {
|
|
1350
|
-
var r, n, i, s, o, c, d,
|
|
1368
|
+
var r, n, i, s, o, c, d, l, p, b;
|
|
1351
1369
|
this.endIndex = t;
|
|
1352
1370
|
const h = this.getSlice(u, t - a);
|
|
1353
|
-
!this.htmlMode || this.options.recognizeCDATA ? ((n = (r = this.cbs).oncdatastart) === null || n === void 0 || n.call(r), (s = (i = this.cbs).ontext) === null || s === void 0 || s.call(i, h), (c = (o = this.cbs).oncdataend) === null || c === void 0 || c.call(o)) : ((
|
|
1371
|
+
!this.htmlMode || this.options.recognizeCDATA ? ((n = (r = this.cbs).oncdatastart) === null || n === void 0 || n.call(r), (s = (i = this.cbs).ontext) === null || s === void 0 || s.call(i, h), (c = (o = this.cbs).oncdataend) === null || c === void 0 || c.call(o)) : ((l = (d = this.cbs).oncomment) === null || l === void 0 || l.call(d, `[CDATA[${h}]]`), (b = (p = this.cbs).oncommentend) === null || b === void 0 || b.call(p)), this.startIndex = t + 1;
|
|
1354
1372
|
}
|
|
1355
1373
|
/** @internal */
|
|
1356
1374
|
onend() {
|
|
@@ -1451,7 +1469,7 @@ class Ye {
|
|
|
1451
1469
|
function qu(e, u = "web") {
|
|
1452
1470
|
const t = { name: "", children: [] }, a = [t];
|
|
1453
1471
|
let r = "";
|
|
1454
|
-
const n = new
|
|
1472
|
+
const n = new ut(
|
|
1455
1473
|
{
|
|
1456
1474
|
onopentag: (i, s, o) => {
|
|
1457
1475
|
const c = a[a.length - 1];
|
|
@@ -1466,18 +1484,18 @@ function qu(e, u = "web") {
|
|
|
1466
1484
|
},
|
|
1467
1485
|
{}
|
|
1468
1486
|
);
|
|
1469
|
-
d.style && (d.style =
|
|
1470
|
-
const
|
|
1471
|
-
name:
|
|
1487
|
+
d.style && (d.style = zu(d.style));
|
|
1488
|
+
const l = {
|
|
1489
|
+
name: Xu(i, u),
|
|
1472
1490
|
props: d
|
|
1473
1491
|
};
|
|
1474
|
-
Array.isArray(c.children) ? c.children.push(
|
|
1492
|
+
Array.isArray(c.children) ? c.children.push(l) : c.children ? c.children = [
|
|
1475
1493
|
{
|
|
1476
1494
|
name: "span",
|
|
1477
1495
|
children: c.children
|
|
1478
1496
|
},
|
|
1479
|
-
|
|
1480
|
-
] : c.children = [
|
|
1497
|
+
l
|
|
1498
|
+
] : c.children = [l], o || a.push(l);
|
|
1481
1499
|
},
|
|
1482
1500
|
ontext: (i) => {
|
|
1483
1501
|
const s = i.trim();
|
|
@@ -1495,9 +1513,9 @@ function qu(e, u = "web") {
|
|
|
1495
1513
|
);
|
|
1496
1514
|
return n.write(e.replace(/\\"/g, '"')), n.end(), t.children || [];
|
|
1497
1515
|
}
|
|
1498
|
-
function
|
|
1516
|
+
function et(e, u) {
|
|
1499
1517
|
const a = {
|
|
1500
|
-
imports:
|
|
1518
|
+
imports: tt(e),
|
|
1501
1519
|
emits: [],
|
|
1502
1520
|
errors: []
|
|
1503
1521
|
}, r = B(e);
|
|
@@ -1508,60 +1526,60 @@ function ut(e, u) {
|
|
|
1508
1526
|
const s = i.arguments[0];
|
|
1509
1527
|
if (s?.type !== "ObjectExpression") return;
|
|
1510
1528
|
const o = s.properties.filter(
|
|
1511
|
-
(
|
|
1529
|
+
(l) => l.type === "ObjectProperty"
|
|
1512
1530
|
), c = s.properties.filter(
|
|
1513
|
-
(
|
|
1531
|
+
(l) => l.type == "ObjectMethod"
|
|
1514
1532
|
), d = o.find(
|
|
1515
|
-
(
|
|
1533
|
+
(l) => l.key.name === "computed"
|
|
1516
1534
|
);
|
|
1517
|
-
d && (a.computed = Zu(d.value), a.watchers =
|
|
1518
|
-
for (const
|
|
1519
|
-
switch (
|
|
1535
|
+
d && (a.computed = Zu(d.value), a.watchers = ct(d.value));
|
|
1536
|
+
for (const l of o)
|
|
1537
|
+
switch (l.key.name) {
|
|
1520
1538
|
case "name":
|
|
1521
|
-
a.name =
|
|
1539
|
+
a.name = l.value.value;
|
|
1522
1540
|
break;
|
|
1523
1541
|
case "methods":
|
|
1524
|
-
a.handlers =
|
|
1525
|
-
|
|
1542
|
+
a.handlers = st(l.value), a.methods = it(l.value), a.dataSources = nt(
|
|
1543
|
+
l.value,
|
|
1526
1544
|
u
|
|
1527
1545
|
);
|
|
1528
1546
|
break;
|
|
1529
1547
|
case "watch":
|
|
1530
|
-
a.watch =
|
|
1531
|
-
|
|
1548
|
+
a.watch = ot(
|
|
1549
|
+
l.value,
|
|
1532
1550
|
a.watchers
|
|
1533
1551
|
);
|
|
1534
1552
|
break;
|
|
1535
1553
|
case "props":
|
|
1536
|
-
a.props = ft(
|
|
1554
|
+
a.props = ft(l.value);
|
|
1537
1555
|
break;
|
|
1538
1556
|
case "inject":
|
|
1539
|
-
a.inject =
|
|
1557
|
+
a.inject = pt(l.value);
|
|
1540
1558
|
break;
|
|
1541
1559
|
case "expose":
|
|
1542
|
-
a.expose =
|
|
1560
|
+
a.expose = ht(l.value);
|
|
1543
1561
|
break;
|
|
1544
1562
|
case "directives":
|
|
1545
|
-
a.directives =
|
|
1563
|
+
a.directives = xt(l.value);
|
|
1546
1564
|
break;
|
|
1547
1565
|
}
|
|
1548
|
-
for (const
|
|
1549
|
-
switch (
|
|
1566
|
+
for (const l of c)
|
|
1567
|
+
switch (l.key.name) {
|
|
1550
1568
|
case "setup":
|
|
1551
|
-
a.state =
|
|
1569
|
+
a.state = rt(l.body);
|
|
1552
1570
|
break;
|
|
1553
1571
|
}
|
|
1554
|
-
a.lifeCycles =
|
|
1572
|
+
a.lifeCycles = dt(c);
|
|
1555
1573
|
},
|
|
1556
1574
|
CallExpression(n) {
|
|
1557
|
-
const i =
|
|
1575
|
+
const i = bt(n.node);
|
|
1558
1576
|
if (i.length)
|
|
1559
1577
|
for (let s of i)
|
|
1560
1578
|
a.emits?.find((c) => c.name === s.name) || a.emits?.push(s);
|
|
1561
1579
|
}
|
|
1562
1580
|
}), a;
|
|
1563
1581
|
}
|
|
1564
|
-
function
|
|
1582
|
+
function tt(e) {
|
|
1565
1583
|
const u = /import\s+{(.+?)}\s+from\s+['"](.+?)['"]/g, t = /import\s+(.+?)\s+from\s+['"](.+?)['"]/g, a = /^{(.+?)}$/, r = [];
|
|
1566
1584
|
let n;
|
|
1567
1585
|
const i = e.replace(/\n/g, " ");
|
|
@@ -1581,7 +1599,7 @@ function et(e) {
|
|
|
1581
1599
|
}
|
|
1582
1600
|
return r;
|
|
1583
1601
|
}
|
|
1584
|
-
function
|
|
1602
|
+
function at(e) {
|
|
1585
1603
|
for (const u of e.body)
|
|
1586
1604
|
if (u.type === "VariableDeclaration" && u.kind == "const") {
|
|
1587
1605
|
const { id: t, init: a } = u.declarations[0];
|
|
@@ -1590,8 +1608,8 @@ function tt(e) {
|
|
|
1590
1608
|
}
|
|
1591
1609
|
return null;
|
|
1592
1610
|
}
|
|
1593
|
-
function
|
|
1594
|
-
const u =
|
|
1611
|
+
function rt(e) {
|
|
1612
|
+
const u = at(e);
|
|
1595
1613
|
if (!u) return {};
|
|
1596
1614
|
const t = {};
|
|
1597
1615
|
for (const a of u.properties)
|
|
@@ -1610,7 +1628,7 @@ function at(e) {
|
|
|
1610
1628
|
}
|
|
1611
1629
|
return t;
|
|
1612
1630
|
}
|
|
1613
|
-
function
|
|
1631
|
+
function X(e) {
|
|
1614
1632
|
const { key: u, async: t, params: a, body: r } = e, n = a?.map((i) => i.type === "ObjectPattern" ? `{${i.properties.map((o) => o.key?.name || o.name).join(",")}}` : i.type === "AssignmentPattern" ? i.left.name + "=" + (i.right?.extra?.raw || "null") : i.name).join(", ");
|
|
1615
1633
|
if (u.type === "Identifier") {
|
|
1616
1634
|
const i = u.name;
|
|
@@ -1621,11 +1639,11 @@ function z(e) {
|
|
|
1621
1639
|
let b = A(o) || "";
|
|
1622
1640
|
b = b.replace("function () {", "() => {"), s = `{ return (${b})}`;
|
|
1623
1641
|
}
|
|
1624
|
-
const d = `${t ? "async " : ""}(${n}) => ${s}`,
|
|
1642
|
+
const d = `${t ? "async " : ""}(${n}) => ${s}`, l = i.startsWith("watcher_");
|
|
1625
1643
|
return {
|
|
1626
|
-
id:
|
|
1644
|
+
id: l ? i.replace("watcher_", "") : "",
|
|
1627
1645
|
name: i,
|
|
1628
|
-
watcher:
|
|
1646
|
+
watcher: l,
|
|
1629
1647
|
exp: C(d)
|
|
1630
1648
|
};
|
|
1631
1649
|
}
|
|
@@ -1634,12 +1652,12 @@ function Zu(e) {
|
|
|
1634
1652
|
if (!e) return {};
|
|
1635
1653
|
const u = {};
|
|
1636
1654
|
for (const t of e.properties) {
|
|
1637
|
-
const a =
|
|
1655
|
+
const a = X(t);
|
|
1638
1656
|
a && !a.watcher && !a.exp.value.includes("this.provider.createMock") && !a.exp.value.includes("this.provider.apis") && (u[a.name] = a.exp);
|
|
1639
1657
|
}
|
|
1640
1658
|
return u;
|
|
1641
1659
|
}
|
|
1642
|
-
function
|
|
1660
|
+
function nt(e, u) {
|
|
1643
1661
|
if (!e) return {};
|
|
1644
1662
|
const t = {}, a = /apis\['([\w]*)'\]/, r = (n) => {
|
|
1645
1663
|
const i = n.indexOf(".then(");
|
|
@@ -1652,15 +1670,15 @@ function rt(e, u) {
|
|
|
1652
1670
|
return n.substring(i + 6, o - 1).trim();
|
|
1653
1671
|
};
|
|
1654
1672
|
for (const n of e.properties) {
|
|
1655
|
-
const i =
|
|
1673
|
+
const i = X(n), s = n.body.body?.[0], o = (s?.leadingComments?.[0].value || "").trim(), c = Qu(o);
|
|
1656
1674
|
if (i && i.exp.value.includes("this.provider.apis")) {
|
|
1657
|
-
const
|
|
1658
|
-
if (!
|
|
1659
|
-
const p =
|
|
1675
|
+
const l = (i.exp.value.match(a) || [])[1];
|
|
1676
|
+
if (!l) continue;
|
|
1677
|
+
const p = mt(u, l);
|
|
1660
1678
|
if (!p) continue;
|
|
1661
1679
|
const b = r(i.exp.value);
|
|
1662
1680
|
t[i.name] = {
|
|
1663
|
-
ref:
|
|
1681
|
+
ref: l,
|
|
1664
1682
|
name: i.name,
|
|
1665
1683
|
test: c?.test || {
|
|
1666
1684
|
type: "JSFunction",
|
|
@@ -1680,7 +1698,7 @@ function rt(e, u) {
|
|
|
1680
1698
|
};
|
|
1681
1699
|
}
|
|
1682
1700
|
if (i && i.exp.value.includes("this.provider.createMock")) {
|
|
1683
|
-
const d = s?.declarations?.[0]?.init?.arguments?.[0],
|
|
1701
|
+
const d = s?.declarations?.[0]?.init?.arguments?.[0], l = r(i.exp.value);
|
|
1684
1702
|
t[i.name] = {
|
|
1685
1703
|
ref: "",
|
|
1686
1704
|
name: i.name,
|
|
@@ -1694,7 +1712,7 @@ function rt(e, u) {
|
|
|
1694
1712
|
label: c?.label || "",
|
|
1695
1713
|
transform: c?.transform || {
|
|
1696
1714
|
type: "JSFunction",
|
|
1697
|
-
value:
|
|
1715
|
+
value: l || `(res) => {
|
|
1698
1716
|
return res;
|
|
1699
1717
|
}`
|
|
1700
1718
|
},
|
|
@@ -1707,13 +1725,13 @@ function rt(e, u) {
|
|
|
1707
1725
|
}
|
|
1708
1726
|
return t;
|
|
1709
1727
|
}
|
|
1710
|
-
function
|
|
1728
|
+
function it(e) {
|
|
1711
1729
|
const u = Zu(e), t = /\_([\w]{5,})$/, a = {};
|
|
1712
1730
|
for (const r of Object.keys(u))
|
|
1713
1731
|
t.test(r) || (a[r] = u[r]);
|
|
1714
1732
|
return a;
|
|
1715
1733
|
}
|
|
1716
|
-
function
|
|
1734
|
+
function st(e) {
|
|
1717
1735
|
if (!e) return {};
|
|
1718
1736
|
const u = {}, t = /\_([\w]{5,})$/;
|
|
1719
1737
|
for (const a of e.properties) {
|
|
@@ -1726,18 +1744,18 @@ function it(e) {
|
|
|
1726
1744
|
);
|
|
1727
1745
|
u[r] = C(n);
|
|
1728
1746
|
} else
|
|
1729
|
-
u[r] =
|
|
1747
|
+
u[r] = X(a)?.exp;
|
|
1730
1748
|
} catch (n) {
|
|
1731
1749
|
console.warn(n);
|
|
1732
1750
|
}
|
|
1733
1751
|
}
|
|
1734
1752
|
return u;
|
|
1735
1753
|
}
|
|
1736
|
-
function
|
|
1754
|
+
function ct(e) {
|
|
1737
1755
|
if (!e) return {};
|
|
1738
1756
|
const u = {};
|
|
1739
1757
|
for (const t of e.properties) {
|
|
1740
|
-
const a =
|
|
1758
|
+
const a = X(t);
|
|
1741
1759
|
a && a.watcher && (u[a.name] = a.exp);
|
|
1742
1760
|
}
|
|
1743
1761
|
return u;
|
|
@@ -1755,9 +1773,9 @@ function Du(e, u) {
|
|
|
1755
1773
|
(a) => a.key?.name === u
|
|
1756
1774
|
);
|
|
1757
1775
|
if (t)
|
|
1758
|
-
return
|
|
1776
|
+
return X(t)?.exp;
|
|
1759
1777
|
}
|
|
1760
|
-
function
|
|
1778
|
+
function ot(e, u = {}) {
|
|
1761
1779
|
const t = [];
|
|
1762
1780
|
for (const a of e.properties) {
|
|
1763
1781
|
const { key: r, value: n } = a, i = r.value || r.name || "";
|
|
@@ -1771,18 +1789,18 @@ function ct(e, u = {}) {
|
|
|
1771
1789
|
handler: Du(s, "handler")
|
|
1772
1790
|
});
|
|
1773
1791
|
} else if (a.type === "ObjectMethod" && t.push({
|
|
1774
|
-
id:
|
|
1792
|
+
id: nu(),
|
|
1775
1793
|
source: {
|
|
1776
1794
|
type: "JSFunction",
|
|
1777
1795
|
value: `() => { return this.${i}; }`
|
|
1778
1796
|
},
|
|
1779
1797
|
deep: !1,
|
|
1780
1798
|
immediate: !1,
|
|
1781
|
-
handler:
|
|
1799
|
+
handler: X(a)?.exp
|
|
1782
1800
|
}), a.type === "ObjectProperty") {
|
|
1783
1801
|
const s = n.properties;
|
|
1784
1802
|
t.push({
|
|
1785
|
-
id:
|
|
1803
|
+
id: nu(),
|
|
1786
1804
|
source: {
|
|
1787
1805
|
type: "JSFunction",
|
|
1788
1806
|
value: `() => { return this.${i}; }`
|
|
@@ -1795,18 +1813,18 @@ function ct(e, u = {}) {
|
|
|
1795
1813
|
}
|
|
1796
1814
|
return t;
|
|
1797
1815
|
}
|
|
1798
|
-
function
|
|
1816
|
+
function dt(e) {
|
|
1799
1817
|
const u = {};
|
|
1800
1818
|
for (const t of e) {
|
|
1801
1819
|
const a = t.key.name;
|
|
1802
|
-
if (
|
|
1803
|
-
const r =
|
|
1820
|
+
if (Re.includes(a)) {
|
|
1821
|
+
const r = X(t);
|
|
1804
1822
|
r && (u[r.name] = r.exp);
|
|
1805
1823
|
}
|
|
1806
1824
|
}
|
|
1807
1825
|
return u;
|
|
1808
1826
|
}
|
|
1809
|
-
function
|
|
1827
|
+
function lt(e) {
|
|
1810
1828
|
const u = e?.find(
|
|
1811
1829
|
(t) => t.key?.name === "type"
|
|
1812
1830
|
);
|
|
@@ -1828,12 +1846,12 @@ function ft(e) {
|
|
|
1828
1846
|
return {
|
|
1829
1847
|
name: a.name,
|
|
1830
1848
|
required: Y(n, "required"),
|
|
1831
|
-
type:
|
|
1849
|
+
type: lt(n),
|
|
1832
1850
|
default: Yu(n)
|
|
1833
1851
|
};
|
|
1834
1852
|
})), u;
|
|
1835
1853
|
}
|
|
1836
|
-
function
|
|
1854
|
+
function bt(e) {
|
|
1837
1855
|
const u = [];
|
|
1838
1856
|
if (e.callee.type === "MemberExpression" && e.callee.property?.name === "$emit") {
|
|
1839
1857
|
const [a, ...r] = (e.arguments || []).map(
|
|
@@ -1846,7 +1864,7 @@ function lt(e) {
|
|
|
1846
1864
|
}
|
|
1847
1865
|
return u;
|
|
1848
1866
|
}
|
|
1849
|
-
function
|
|
1867
|
+
function pt(e) {
|
|
1850
1868
|
let u = [];
|
|
1851
1869
|
return e.type === "ObjectExpression" && (u = e.properties?.map((t) => {
|
|
1852
1870
|
const { key: a, value: r } = t, n = r.properties, i = a.name, s = Ku(n, "from"), o = Yu(n);
|
|
@@ -1857,13 +1875,13 @@ function bt(e) {
|
|
|
1857
1875
|
};
|
|
1858
1876
|
})), u;
|
|
1859
1877
|
}
|
|
1860
|
-
function
|
|
1878
|
+
function ht(e) {
|
|
1861
1879
|
return e && e.elements ? e.elements.map((u) => u?.type === "StringLiteral" ? u.value : "").filter((u) => !!u) : [];
|
|
1862
1880
|
}
|
|
1863
|
-
function
|
|
1881
|
+
function mt(e, u) {
|
|
1864
1882
|
return (e.apis || []).find((t) => t.id === u || t.name === u);
|
|
1865
1883
|
}
|
|
1866
|
-
function
|
|
1884
|
+
function xt(e) {
|
|
1867
1885
|
if (!e?.properties) return {};
|
|
1868
1886
|
const u = {};
|
|
1869
1887
|
for (const t of e.properties) {
|
|
@@ -1875,9 +1893,9 @@ function mt(e) {
|
|
|
1875
1893
|
}
|
|
1876
1894
|
return u;
|
|
1877
1895
|
}
|
|
1878
|
-
let hu = [],
|
|
1896
|
+
let hu = [], su = {}, ue = {}, ee = {}, te = {}, cu = "web", ae = [];
|
|
1879
1897
|
function re(e, u, t = "", a) {
|
|
1880
|
-
hu = [],
|
|
1898
|
+
hu = [], su = {}, ue = a?.handlers || {}, te = a?.styles || {}, cu = a?.platform || "web", ae = a?.imports || [], ee = a?.directives || {};
|
|
1881
1899
|
const n = Gu({
|
|
1882
1900
|
id: e,
|
|
1883
1901
|
filename: u,
|
|
@@ -1892,10 +1910,10 @@ function re(e, u, t = "", a) {
|
|
|
1892
1910
|
return {
|
|
1893
1911
|
nodes: i.filter((s) => !!s),
|
|
1894
1912
|
slots: hu,
|
|
1895
|
-
context:
|
|
1913
|
+
context: su
|
|
1896
1914
|
};
|
|
1897
1915
|
}
|
|
1898
|
-
function
|
|
1916
|
+
function gt(e) {
|
|
1899
1917
|
if (e.name === "slot") {
|
|
1900
1918
|
let u = "default";
|
|
1901
1919
|
const t = [];
|
|
@@ -1907,7 +1925,7 @@ function xt(e) {
|
|
|
1907
1925
|
});
|
|
1908
1926
|
}
|
|
1909
1927
|
}
|
|
1910
|
-
function
|
|
1928
|
+
function yt(e) {
|
|
1911
1929
|
const u = {};
|
|
1912
1930
|
for (const t of e) {
|
|
1913
1931
|
if (t.type === v.ATTRIBUTE)
|
|
@@ -1916,7 +1934,7 @@ function gt(e) {
|
|
|
1916
1934
|
s && (u.style = s), i.length && (u.class = i.join(" "));
|
|
1917
1935
|
} else if (t.name === "style") {
|
|
1918
1936
|
const a = t.value?.content || "";
|
|
1919
|
-
a && (u.style =
|
|
1937
|
+
a && (u.style = zu(a));
|
|
1920
1938
|
} else
|
|
1921
1939
|
u[t.name] = t.value?.content || "";
|
|
1922
1940
|
if (t.type === v.DIRECTIVE && t.name === "bind" && (t.exp?.type === v.SIMPLE_EXPRESSION && t.arg?.type === v.SIMPLE_EXPRESSION && (u[t.arg.content] = T(`(${t.exp.content})`)), t.exp?.type === v.COMPOUND_EXPRESSION && t.arg?.type === v.SIMPLE_EXPRESSION))
|
|
@@ -1934,13 +1952,13 @@ function gt(e) {
|
|
|
1934
1952
|
}
|
|
1935
1953
|
return u;
|
|
1936
1954
|
}
|
|
1937
|
-
function
|
|
1955
|
+
function St(e = {}) {
|
|
1938
1956
|
const u = {};
|
|
1939
1957
|
for (const [t, a] of Object.entries(e))
|
|
1940
1958
|
u[t === "tap" ? "click" : t] = a;
|
|
1941
1959
|
return u;
|
|
1942
1960
|
}
|
|
1943
|
-
function
|
|
1961
|
+
function vt(e, u = {}) {
|
|
1944
1962
|
const t = {};
|
|
1945
1963
|
for (const a of e)
|
|
1946
1964
|
if (a.type === v.DIRECTIVE && a.name === "on" && a.arg?.type === v.SIMPLE_EXPRESSION) {
|
|
@@ -1966,7 +1984,7 @@ function St(e, u = {}) {
|
|
|
1966
1984
|
};
|
|
1967
1985
|
}
|
|
1968
1986
|
}
|
|
1969
|
-
return
|
|
1987
|
+
return St(t);
|
|
1970
1988
|
}
|
|
1971
1989
|
function eu(e, u) {
|
|
1972
1990
|
const t = [], a = ["if", "for", "model", "show", "bind", "html"];
|
|
@@ -2018,7 +2036,7 @@ function eu(e, u) {
|
|
|
2018
2036
|
});
|
|
2019
2037
|
const c = r.filter((d) => !a.includes(d.name));
|
|
2020
2038
|
for (const d of c) {
|
|
2021
|
-
const
|
|
2039
|
+
const l = (d.modifiers || []).reduce(
|
|
2022
2040
|
(h, S) => (h[S.content] = !0, h),
|
|
2023
2041
|
{}
|
|
2024
2042
|
), p = d.arg?.content || void 0, b = ee[d.name];
|
|
@@ -2026,7 +2044,7 @@ function eu(e, u) {
|
|
|
2026
2044
|
name: b,
|
|
2027
2045
|
value: T(d.exp?.loc.source || ""),
|
|
2028
2046
|
arg: p,
|
|
2029
|
-
modifiers:
|
|
2047
|
+
modifiers: l
|
|
2030
2048
|
});
|
|
2031
2049
|
}
|
|
2032
2050
|
}
|
|
@@ -2045,9 +2063,9 @@ function ne(e) {
|
|
|
2045
2063
|
u = i.match(s)?.[1] || "";
|
|
2046
2064
|
}
|
|
2047
2065
|
}
|
|
2048
|
-
return u ||
|
|
2066
|
+
return u || nu();
|
|
2049
2067
|
}
|
|
2050
|
-
function
|
|
2068
|
+
function Et(e) {
|
|
2051
2069
|
const u = /\.\/(.+?)\.vue/;
|
|
2052
2070
|
for (const { from: t, imports: a } of ae) {
|
|
2053
2071
|
if (Array.isArray(a) && a.includes(e))
|
|
@@ -2063,7 +2081,7 @@ function vt(e) {
|
|
|
2063
2081
|
}
|
|
2064
2082
|
}
|
|
2065
2083
|
function mu(e, u) {
|
|
2066
|
-
const t = new Set(u?.id ?
|
|
2084
|
+
const t = new Set(u?.id ? su[u.id] : []), a = (e.directives || []).find((i) => i.name === "vFor");
|
|
2067
2085
|
let r = new Set(Array.from(t));
|
|
2068
2086
|
if (a) {
|
|
2069
2087
|
const { item: i = "item", index: s = "index" } = a.iterator || {};
|
|
@@ -2074,38 +2092,38 @@ function mu(e, u) {
|
|
|
2074
2092
|
const i = typeof n == "string" ? [] : n.params || [], s = i.length ? i : [`scope_${u?.id}`];
|
|
2075
2093
|
r = /* @__PURE__ */ new Set([...s, ...Array.from(r)]);
|
|
2076
2094
|
}
|
|
2077
|
-
|
|
2095
|
+
su[e.id] = r;
|
|
2078
2096
|
}
|
|
2079
|
-
function
|
|
2097
|
+
function bu(e, u, t, a) {
|
|
2080
2098
|
const r = {
|
|
2081
|
-
name:
|
|
2082
|
-
from:
|
|
2083
|
-
props:
|
|
2084
|
-
events:
|
|
2099
|
+
name: Xu(e.tag, cu),
|
|
2100
|
+
from: Et(e.tag),
|
|
2101
|
+
props: yt(e.props),
|
|
2102
|
+
events: vt(e.props, ue),
|
|
2085
2103
|
directives: eu(t || e, a)
|
|
2086
2104
|
};
|
|
2087
2105
|
r.id = ne(e), mu(r, u);
|
|
2088
|
-
const n =
|
|
2089
|
-
return mu(r, u),
|
|
2106
|
+
const n = ou(r, e.children);
|
|
2107
|
+
return mu(r, u), gt(n), n;
|
|
2090
2108
|
}
|
|
2091
|
-
function
|
|
2109
|
+
function wt(e = [], u) {
|
|
2092
2110
|
return e.map((t) => Q(t, u, e));
|
|
2093
2111
|
}
|
|
2094
2112
|
function Q(e, u, t) {
|
|
2095
2113
|
if (e.type === v.ELEMENT)
|
|
2096
|
-
return
|
|
2114
|
+
return bu(e, u);
|
|
2097
2115
|
if (e.type === v.IF)
|
|
2098
|
-
return
|
|
2116
|
+
return It(e);
|
|
2099
2117
|
if (t && e.type === v.IF_BRANCH) {
|
|
2100
2118
|
const a = e.children.find(
|
|
2101
2119
|
(r) => r.type === v.ELEMENT || r.type === v.FOR
|
|
2102
2120
|
);
|
|
2103
2121
|
if (a) {
|
|
2104
2122
|
if (a.type === v.ELEMENT)
|
|
2105
|
-
return
|
|
2123
|
+
return bu(a, u, e, t);
|
|
2106
2124
|
if (a.type === v.FOR) {
|
|
2107
2125
|
const n = { name: "div", directives: eu(e) };
|
|
2108
|
-
return
|
|
2126
|
+
return ou(n, e.children || []);
|
|
2109
2127
|
}
|
|
2110
2128
|
}
|
|
2111
2129
|
return "";
|
|
@@ -2114,9 +2132,9 @@ function Q(e, u, t) {
|
|
|
2114
2132
|
const a = e.children[0];
|
|
2115
2133
|
if (e.children.length > 1 || a.type !== v.ELEMENT) {
|
|
2116
2134
|
const n = { name: "span", directives: eu(e) };
|
|
2117
|
-
return
|
|
2135
|
+
return ou(n, e.children);
|
|
2118
2136
|
} else
|
|
2119
|
-
return
|
|
2137
|
+
return bu(a, u, e);
|
|
2120
2138
|
}
|
|
2121
2139
|
if (e.type === v.TEXT_CALL)
|
|
2122
2140
|
return e.content.type == v.TEXT ? e.content.content : e.content.type === v.INTERPOLATION ? T(e.content.content.loc.source) : e.content.type === v.COMPOUND_EXPRESSION ? Ru(
|
|
@@ -2144,13 +2162,13 @@ function Ru(e = []) {
|
|
|
2144
2162
|
children: t
|
|
2145
2163
|
};
|
|
2146
2164
|
}
|
|
2147
|
-
function
|
|
2165
|
+
function ou(e, u = []) {
|
|
2148
2166
|
const t = [];
|
|
2149
2167
|
for (const a of u)
|
|
2150
2168
|
if (a.type === v.ELEMENT && a.codegenNode?.value?.arguments) {
|
|
2151
2169
|
const r = a.codegenNode.value.arguments[0];
|
|
2152
2170
|
if (r) {
|
|
2153
|
-
const n = qu(r,
|
|
2171
|
+
const n = qu(r, cu);
|
|
2154
2172
|
t.push(...n);
|
|
2155
2173
|
}
|
|
2156
2174
|
} else if (a.type === v.ELEMENT && a.tag === "template") {
|
|
@@ -2161,7 +2179,7 @@ function cu(e, u = []) {
|
|
|
2161
2179
|
children: Q(n, e)
|
|
2162
2180
|
} : Q(n, e);
|
|
2163
2181
|
i && (Array.isArray(i) ? i : [i]).forEach((o) => {
|
|
2164
|
-
|
|
2182
|
+
Ie(o) && r?.type === v.DIRECTIVE && (o.id = ne(n), o.slot = {
|
|
2165
2183
|
name: r.arg?.content || "default",
|
|
2166
2184
|
params: r.exp?.identifiers || [],
|
|
2167
2185
|
scope: r.exp?.type === v.SIMPLE_EXPRESSION ? r.exp.content : ""
|
|
@@ -2171,7 +2189,7 @@ function cu(e, u = []) {
|
|
|
2171
2189
|
} else if (a.type === v.JS_CALL_EXPRESSION) {
|
|
2172
2190
|
const r = a.arguments?.[0];
|
|
2173
2191
|
if (r) {
|
|
2174
|
-
const n = qu(r,
|
|
2192
|
+
const n = qu(r, cu);
|
|
2175
2193
|
t.push(...n);
|
|
2176
2194
|
}
|
|
2177
2195
|
} else if (a.type === v.TEXT_CALL) {
|
|
@@ -2183,20 +2201,20 @@ function cu(e, u = []) {
|
|
|
2183
2201
|
}
|
|
2184
2202
|
if (t.length === 1) {
|
|
2185
2203
|
const a = t[0];
|
|
2186
|
-
e.children = typeof a == "string" ||
|
|
2204
|
+
e.children = typeof a == "string" || iu(a) ? a : [a];
|
|
2187
2205
|
} else
|
|
2188
|
-
e.children = t.map((a) => typeof a == "string" ||
|
|
2206
|
+
e.children = t.map((a) => typeof a == "string" || iu(a) ? { name: "span", children: a } : a);
|
|
2189
2207
|
return e;
|
|
2190
2208
|
}
|
|
2191
|
-
function
|
|
2209
|
+
function It(e) {
|
|
2192
2210
|
const u = e.branches || [], t = u[0], a = t.children || [];
|
|
2193
2211
|
if (t?.isTemplateIf || a.length > 1 || a[0].type !== v.ELEMENT) {
|
|
2194
2212
|
const n = { name: "span", directives: eu(t, u) };
|
|
2195
|
-
return
|
|
2213
|
+
return ou(n, t.children);
|
|
2196
2214
|
} else
|
|
2197
|
-
return
|
|
2215
|
+
return wt(u);
|
|
2198
2216
|
}
|
|
2199
|
-
const
|
|
2217
|
+
const At = {
|
|
2200
2218
|
onBeforeMount: "beforeMount",
|
|
2201
2219
|
onMounted: "mounted",
|
|
2202
2220
|
onBeforeUpdate: "beforeUpdate",
|
|
@@ -2227,16 +2245,16 @@ const It = {
|
|
|
2227
2245
|
onNavigationBarSearchInputClicked: "onNavigationBarSearchInputClicked",
|
|
2228
2246
|
onShareTimeline: "onShareTimeline",
|
|
2229
2247
|
onAddToFavorites: "onAddToFavorites"
|
|
2230
|
-
},
|
|
2248
|
+
}, kt = /* @__PURE__ */ new Set([
|
|
2231
2249
|
"vue-router",
|
|
2232
2250
|
"pinia",
|
|
2233
2251
|
"vue-i18n",
|
|
2234
2252
|
"@vtj/renderer"
|
|
2235
|
-
]),
|
|
2253
|
+
]), Tt = new Set(
|
|
2236
2254
|
Object.values(gu).map((e) => e.composable).filter((e) => !!e)
|
|
2237
2255
|
);
|
|
2238
|
-
function
|
|
2239
|
-
const t =
|
|
2256
|
+
function Nt(e, u) {
|
|
2257
|
+
const t = jt(e), a = Vt(t), { dependencies: r = [] } = u || {}, n = r.reduce(
|
|
2240
2258
|
(c, d) => (c[d.package] = d.library, c),
|
|
2241
2259
|
{}
|
|
2242
2260
|
), i = {
|
|
@@ -2270,7 +2288,7 @@ function Tt(e, u) {
|
|
|
2270
2288
|
if (b.type === "CallExpression") {
|
|
2271
2289
|
const h = Cu(b);
|
|
2272
2290
|
if (h === "ref") {
|
|
2273
|
-
const E =
|
|
2291
|
+
const E = _(p.id);
|
|
2274
2292
|
if (E) {
|
|
2275
2293
|
const m = b.arguments[0] ? A(b.arguments[0]) : "undefined";
|
|
2276
2294
|
i.refs[E] = T(m);
|
|
@@ -2278,10 +2296,10 @@ function Tt(e, u) {
|
|
|
2278
2296
|
return;
|
|
2279
2297
|
}
|
|
2280
2298
|
if (h === "reactive") {
|
|
2281
|
-
const E =
|
|
2299
|
+
const E = _(p.id);
|
|
2282
2300
|
if (E)
|
|
2283
2301
|
if (E === "__state")
|
|
2284
|
-
i.state =
|
|
2302
|
+
i.state = Dt(b.arguments[0]);
|
|
2285
2303
|
else {
|
|
2286
2304
|
const m = b.arguments[0] ? A(b.arguments[0]) : "{}";
|
|
2287
2305
|
i.reactives[E] = T(m);
|
|
@@ -2289,7 +2307,7 @@ function Tt(e, u) {
|
|
|
2289
2307
|
return;
|
|
2290
2308
|
}
|
|
2291
2309
|
if (h === "computed") {
|
|
2292
|
-
const E =
|
|
2310
|
+
const E = _(p.id);
|
|
2293
2311
|
if (E) {
|
|
2294
2312
|
const m = b.arguments[0] ? A(b.arguments[0]) : "() => {}";
|
|
2295
2313
|
i.computed[E] = C(m);
|
|
@@ -2297,9 +2315,9 @@ function Tt(e, u) {
|
|
|
2297
2315
|
return;
|
|
2298
2316
|
}
|
|
2299
2317
|
if (h === "inject") {
|
|
2300
|
-
const E =
|
|
2318
|
+
const E = _(p.id);
|
|
2301
2319
|
if (E) {
|
|
2302
|
-
const m = b.arguments[0], y = b.arguments[1], x = m ?
|
|
2320
|
+
const m = b.arguments[0], y = b.arguments[1], x = m ? Lu(m) : E;
|
|
2303
2321
|
i.inject.push({
|
|
2304
2322
|
name: E,
|
|
2305
2323
|
from: x || E,
|
|
@@ -2309,24 +2327,24 @@ function Tt(e, u) {
|
|
|
2309
2327
|
return;
|
|
2310
2328
|
}
|
|
2311
2329
|
if (h === "defineProps" || h === "withDefaults") {
|
|
2312
|
-
i.props =
|
|
2330
|
+
i.props = Pu(b);
|
|
2313
2331
|
return;
|
|
2314
2332
|
}
|
|
2315
2333
|
if (h === "defineEmits") {
|
|
2316
|
-
i.emits =
|
|
2334
|
+
i.emits = Ou(b);
|
|
2317
2335
|
return;
|
|
2318
2336
|
}
|
|
2319
2337
|
if (h && /^use[A-Z]/.test(h)) {
|
|
2320
2338
|
const E = a.get(h);
|
|
2321
|
-
if (
|
|
2322
|
-
const x =
|
|
2339
|
+
if (qt(h, E)) {
|
|
2340
|
+
const x = _u(p.id);
|
|
2323
2341
|
x.length > 0 && (i.globalApiDestructured ??= [], i.globalApiDestructured.push({ callee: h, destructure: x }));
|
|
2324
2342
|
return;
|
|
2325
2343
|
}
|
|
2326
2344
|
if (h === "useProvider") return;
|
|
2327
2345
|
if (!E)
|
|
2328
2346
|
continue;
|
|
2329
|
-
const m =
|
|
2347
|
+
const m = _(p.id), y = _u(p.id);
|
|
2330
2348
|
if (m || y.length) {
|
|
2331
2349
|
if (m && i.composables.some((D) => D.name === m))
|
|
2332
2350
|
return;
|
|
@@ -2346,12 +2364,12 @@ function Tt(e, u) {
|
|
|
2346
2364
|
}
|
|
2347
2365
|
return;
|
|
2348
2366
|
}
|
|
2349
|
-
const S =
|
|
2367
|
+
const S = _(p.id);
|
|
2350
2368
|
if (S && S.startsWith("__") || h === "getCurrentInstance")
|
|
2351
2369
|
return;
|
|
2352
2370
|
}
|
|
2353
2371
|
if (b.type === "ArrowFunctionExpression" || b.type === "FunctionExpression") {
|
|
2354
|
-
const h =
|
|
2372
|
+
const h = _(p.id);
|
|
2355
2373
|
if (h) {
|
|
2356
2374
|
const S = A(b);
|
|
2357
2375
|
if (Bu(S)) {
|
|
@@ -2372,7 +2390,7 @@ function Tt(e, u) {
|
|
|
2372
2390
|
}
|
|
2373
2391
|
}
|
|
2374
2392
|
if (d.declarations.some((p) => {
|
|
2375
|
-
const b =
|
|
2393
|
+
const b = _(p.id);
|
|
2376
2394
|
return b && b.startsWith("__");
|
|
2377
2395
|
}))
|
|
2378
2396
|
return;
|
|
@@ -2381,7 +2399,7 @@ function Tt(e, u) {
|
|
|
2381
2399
|
return b && (b.type === "ObjectExpression" || b.type === "ArrayExpression");
|
|
2382
2400
|
}) && d.declarations.length > 0) {
|
|
2383
2401
|
for (const p of d.declarations) {
|
|
2384
|
-
const b =
|
|
2402
|
+
const b = _(p.id);
|
|
2385
2403
|
b && p.init && (i.reactives[b] = T(A(p.init)));
|
|
2386
2404
|
}
|
|
2387
2405
|
return;
|
|
@@ -2389,7 +2407,7 @@ function Tt(e, u) {
|
|
|
2389
2407
|
for (const p of d.declarations) {
|
|
2390
2408
|
const b = p.init;
|
|
2391
2409
|
if (b) {
|
|
2392
|
-
const h =
|
|
2410
|
+
const h = _(p.id) || "(unknown)", S = A(b), E = b.type;
|
|
2393
2411
|
throw new Error(
|
|
2394
2412
|
`[vtj/parser] 无法处理顶层变量声明 "const ${h} = ${S}":不支持的类型 "${E}"。仅支持 ObjectExpression / ArrayExpression 兜底自动转换为 reactive()。请改用 ref()、reactive()、computed() 或函数声明。`
|
|
2395
2413
|
);
|
|
@@ -2404,49 +2422,49 @@ function Tt(e, u) {
|
|
|
2404
2422
|
if (c.parent.type !== "Program") return;
|
|
2405
2423
|
const d = c.node;
|
|
2406
2424
|
if (!d.id) return;
|
|
2407
|
-
const
|
|
2425
|
+
const l = d.id.name, p = Lt(d);
|
|
2408
2426
|
if (Bu(p)) {
|
|
2409
|
-
const b = Fu(
|
|
2427
|
+
const b = Fu(l, p, u);
|
|
2410
2428
|
if (b) {
|
|
2411
|
-
i.dataSources[
|
|
2429
|
+
i.dataSources[l] = b;
|
|
2412
2430
|
return;
|
|
2413
2431
|
}
|
|
2414
2432
|
}
|
|
2415
|
-
i.methods[
|
|
2433
|
+
i.methods[l] = C(p);
|
|
2416
2434
|
},
|
|
2417
2435
|
// 顶层类声明 → 禁止,抛出异常
|
|
2418
2436
|
ClassDeclaration(c) {
|
|
2419
2437
|
if (c.parent.type !== "Program") return;
|
|
2420
|
-
const
|
|
2438
|
+
const l = c.node.id?.name || "(anonymous)";
|
|
2421
2439
|
throw new Error(
|
|
2422
|
-
`[vtj/parser] 无法处理顶层类声明 "class ${
|
|
2440
|
+
`[vtj/parser] 无法处理顶层类声明 "class ${l}":DSL 不支持顶层 class 声明,请改用 ref()、reactive() 或函数声明。`
|
|
2423
2441
|
);
|
|
2424
2442
|
},
|
|
2425
2443
|
// 顶层表达式语句
|
|
2426
2444
|
ExpressionStatement(c) {
|
|
2427
2445
|
if (c.parent.type !== "Program") return;
|
|
2428
|
-
const d = c.node,
|
|
2429
|
-
if (
|
|
2446
|
+
const d = c.node, l = d.expression;
|
|
2447
|
+
if (l.type !== "CallExpression") {
|
|
2430
2448
|
const h = A(d);
|
|
2431
2449
|
throw new Error(
|
|
2432
2450
|
`[vtj/parser] 无法处理顶层表达式语句 "${h}":DSL 不支持游离的顶层表达式,请改用生命周期钩子(如 onMounted)或声明确赋值。`
|
|
2433
2451
|
);
|
|
2434
2452
|
}
|
|
2435
|
-
const p = Cu(
|
|
2453
|
+
const p = Cu(l);
|
|
2436
2454
|
if (p === "watch") {
|
|
2437
|
-
const h =
|
|
2455
|
+
const h = _t(l);
|
|
2438
2456
|
h && i.watch.push(h);
|
|
2439
2457
|
return;
|
|
2440
2458
|
}
|
|
2441
|
-
if (p && p in
|
|
2442
|
-
const h =
|
|
2459
|
+
if (p && p in At) {
|
|
2460
|
+
const h = l.arguments[0];
|
|
2443
2461
|
h && (i.lifeCycles[p] = C(A(h)));
|
|
2444
2462
|
return;
|
|
2445
2463
|
}
|
|
2446
2464
|
if (p === "provide") {
|
|
2447
|
-
const h =
|
|
2465
|
+
const h = l.arguments[0], S = l.arguments[1];
|
|
2448
2466
|
if (h && S) {
|
|
2449
|
-
const E =
|
|
2467
|
+
const E = Lu(h);
|
|
2450
2468
|
if (E) {
|
|
2451
2469
|
const m = A(S);
|
|
2452
2470
|
S.type === "ArrowFunctionExpression" || S.type === "FunctionExpression" ? i.provide[E] = C(m) : i.provide[E] = T(m);
|
|
@@ -2455,15 +2473,15 @@ function Tt(e, u) {
|
|
|
2455
2473
|
return;
|
|
2456
2474
|
}
|
|
2457
2475
|
if (p === "defineExpose") {
|
|
2458
|
-
i.expose =
|
|
2476
|
+
i.expose = Ct(l);
|
|
2459
2477
|
return;
|
|
2460
2478
|
}
|
|
2461
2479
|
if (p === "defineProps" || p === "withDefaults") {
|
|
2462
|
-
i.props =
|
|
2480
|
+
i.props = Pu(l);
|
|
2463
2481
|
return;
|
|
2464
2482
|
}
|
|
2465
2483
|
if (p === "defineEmits") {
|
|
2466
|
-
i.emits =
|
|
2484
|
+
i.emits = Ou(l);
|
|
2467
2485
|
return;
|
|
2468
2486
|
}
|
|
2469
2487
|
const b = A(d);
|
|
@@ -2472,7 +2490,7 @@ function Tt(e, u) {
|
|
|
2472
2490
|
);
|
|
2473
2491
|
}
|
|
2474
2492
|
}), s.length > 0) {
|
|
2475
|
-
const d = s.some((
|
|
2493
|
+
const d = s.some((l) => /\bawait\b/.test(l)) ? "async () =>" : "() =>";
|
|
2476
2494
|
i.setup = C(
|
|
2477
2495
|
`${d} {
|
|
2478
2496
|
${s.join(`
|
|
@@ -2482,7 +2500,7 @@ ${s.join(`
|
|
|
2482
2500
|
}
|
|
2483
2501
|
return i;
|
|
2484
2502
|
}
|
|
2485
|
-
function
|
|
2503
|
+
function jt(e) {
|
|
2486
2504
|
const u = /import\s+{(.+?)}\s+from\s+['"](.+?)['"]/g, t = /import\s+(.+?)\s+from\s+['"](.+?)['"]/g, a = /^{(.+?)}$/, r = [];
|
|
2487
2505
|
let n;
|
|
2488
2506
|
const i = e.replace(/\n/g, " ");
|
|
@@ -2502,7 +2520,7 @@ function Nt(e) {
|
|
|
2502
2520
|
}
|
|
2503
2521
|
return r;
|
|
2504
2522
|
}
|
|
2505
|
-
function
|
|
2523
|
+
function Vt(e) {
|
|
2506
2524
|
const u = /* @__PURE__ */ new Map();
|
|
2507
2525
|
for (const t of e)
|
|
2508
2526
|
if (Array.isArray(t.imports))
|
|
@@ -2514,22 +2532,22 @@ function jt(e) {
|
|
|
2514
2532
|
u.set(t.imports, t.from);
|
|
2515
2533
|
return u;
|
|
2516
2534
|
}
|
|
2517
|
-
function
|
|
2518
|
-
return u &&
|
|
2535
|
+
function qt(e, u) {
|
|
2536
|
+
return u && kt.has(u) ? !0 : Tt.has(e);
|
|
2519
2537
|
}
|
|
2520
2538
|
function Cu(e) {
|
|
2521
2539
|
return e.callee.type === "Identifier" ? e.callee.name : null;
|
|
2522
2540
|
}
|
|
2523
|
-
function
|
|
2541
|
+
function _(e) {
|
|
2524
2542
|
return e?.type === "Identifier" ? e.name : null;
|
|
2525
2543
|
}
|
|
2526
|
-
function
|
|
2544
|
+
function _u(e) {
|
|
2527
2545
|
return e?.type === "ObjectPattern" ? e.properties.map((u) => u.type === "ObjectProperty" && u.key?.type === "Identifier" ? u.key.name : u.type === "RestElement" && u.argument?.type === "Identifier" ? u.argument.name : null).filter(Boolean) : e?.type === "ArrayPattern" ? e.elements.map((u) => u?.type === "Identifier" ? u.name : null).filter(Boolean) : [];
|
|
2528
2546
|
}
|
|
2529
|
-
function
|
|
2547
|
+
function Lu(e) {
|
|
2530
2548
|
return e.type === "StringLiteral" ? e.value : null;
|
|
2531
2549
|
}
|
|
2532
|
-
function
|
|
2550
|
+
function Dt(e) {
|
|
2533
2551
|
if (!e || e.type !== "ObjectExpression") return {};
|
|
2534
2552
|
const u = {};
|
|
2535
2553
|
for (const t of e.properties)
|
|
@@ -2545,17 +2563,17 @@ function qt(e) {
|
|
|
2545
2563
|
}
|
|
2546
2564
|
return u;
|
|
2547
2565
|
}
|
|
2548
|
-
function
|
|
2566
|
+
function Pu(e) {
|
|
2549
2567
|
if (e.callee.type === "Identifier" && e.callee.name === "withDefaults") {
|
|
2550
2568
|
const u = e.arguments[0];
|
|
2551
2569
|
if (u?.type === "CallExpression") {
|
|
2552
|
-
const t =
|
|
2553
|
-
return a?.type === "ObjectExpression" &&
|
|
2570
|
+
const t = Mu(u), a = e.arguments[1];
|
|
2571
|
+
return a?.type === "ObjectExpression" && Rt(t, a), t;
|
|
2554
2572
|
}
|
|
2555
2573
|
}
|
|
2556
|
-
return
|
|
2574
|
+
return Mu(e);
|
|
2557
2575
|
}
|
|
2558
|
-
function
|
|
2576
|
+
function Mu(e) {
|
|
2559
2577
|
const u = e.arguments[0];
|
|
2560
2578
|
return u ? u.type === "ArrayExpression" ? u.elements.map((t) => t?.type === "StringLiteral" ? t.value : "").filter(Boolean) : u.type === "ObjectExpression" ? u.properties.map((t) => {
|
|
2561
2579
|
if (t.type !== "ObjectProperty") return null;
|
|
@@ -2567,7 +2585,7 @@ function Ou(e) {
|
|
|
2567
2585
|
const r = t.value.properties;
|
|
2568
2586
|
return {
|
|
2569
2587
|
name: a,
|
|
2570
|
-
type:
|
|
2588
|
+
type: Pt(r),
|
|
2571
2589
|
required: xu(r, "required"),
|
|
2572
2590
|
default: Mt(r)
|
|
2573
2591
|
};
|
|
@@ -2575,7 +2593,7 @@ function Ou(e) {
|
|
|
2575
2593
|
return a;
|
|
2576
2594
|
}).filter(Boolean) : [] : [];
|
|
2577
2595
|
}
|
|
2578
|
-
function
|
|
2596
|
+
function Rt(e, u) {
|
|
2579
2597
|
for (const t of u.properties) {
|
|
2580
2598
|
if (t.type !== "ObjectProperty") continue;
|
|
2581
2599
|
const a = t.key?.name;
|
|
@@ -2592,15 +2610,15 @@ function Dt(e, u) {
|
|
|
2592
2610
|
}
|
|
2593
2611
|
}
|
|
2594
2612
|
}
|
|
2595
|
-
function
|
|
2613
|
+
function Ou(e) {
|
|
2596
2614
|
const u = e.arguments[0];
|
|
2597
2615
|
return u ? u.type === "ArrayExpression" ? u.elements.map((t) => t?.type === "StringLiteral" ? { name: t.value, params: [] } : null).filter(Boolean) : [] : [];
|
|
2598
2616
|
}
|
|
2599
|
-
function
|
|
2617
|
+
function Ct(e) {
|
|
2600
2618
|
const u = e.arguments[0];
|
|
2601
2619
|
return !u || u.type !== "ObjectExpression" ? [] : u.properties.map((t) => (t.type === "ObjectProperty" || t.type === "ObjectMethod") && t.key?.name || "").filter(Boolean);
|
|
2602
2620
|
}
|
|
2603
|
-
function
|
|
2621
|
+
function _t(e) {
|
|
2604
2622
|
const [u, t, a] = e.arguments;
|
|
2605
2623
|
if (!u || !t) return null;
|
|
2606
2624
|
const r = A(u), n = A(t);
|
|
@@ -2610,7 +2628,7 @@ function Ct(e) {
|
|
|
2610
2628
|
i = xu(o, "deep"), s = xu(o, "immediate");
|
|
2611
2629
|
}
|
|
2612
2630
|
return {
|
|
2613
|
-
id:
|
|
2631
|
+
id: nu(),
|
|
2614
2632
|
source: C(
|
|
2615
2633
|
u.type === "ArrowFunctionExpression" || u.type === "FunctionExpression" ? r : `() => { return ${r}; }`
|
|
2616
2634
|
),
|
|
@@ -2632,15 +2650,15 @@ function Fu(e, u, t) {
|
|
|
2632
2650
|
if (o === -1) return null;
|
|
2633
2651
|
let c = 1, d = o + 6;
|
|
2634
2652
|
for (; d < s.length && c > 0; ) {
|
|
2635
|
-
const
|
|
2636
|
-
|
|
2653
|
+
const l = s[d];
|
|
2654
|
+
l === "(" ? c++ : l === ")" && c--, d++;
|
|
2637
2655
|
}
|
|
2638
2656
|
return s.substring(o + 6, d - 1).trim();
|
|
2639
2657
|
};
|
|
2640
2658
|
if (u.includes("__provider.apis")) {
|
|
2641
2659
|
const o = (u.match(a) || [])[1];
|
|
2642
2660
|
if (!o) return null;
|
|
2643
|
-
const c = (t.apis || []).find((
|
|
2661
|
+
const c = (t.apis || []).find((l) => l.id === o || l.name === o);
|
|
2644
2662
|
if (!c) return null;
|
|
2645
2663
|
const d = i(u);
|
|
2646
2664
|
return {
|
|
@@ -2695,7 +2713,7 @@ function xu(e, u) {
|
|
|
2695
2713
|
(a) => a.key?.name === u
|
|
2696
2714
|
)?.value?.value;
|
|
2697
2715
|
}
|
|
2698
|
-
function
|
|
2716
|
+
function Pt(e) {
|
|
2699
2717
|
const u = e?.find(
|
|
2700
2718
|
(t) => t.key?.name === "type"
|
|
2701
2719
|
);
|
|
@@ -2740,11 +2758,11 @@ function uu(e, u, t) {
|
|
|
2740
2758
|
const s = e.slice(r, i.index);
|
|
2741
2759
|
a += s.replace(u, t);
|
|
2742
2760
|
const o = i[0];
|
|
2743
|
-
o.startsWith("`") ? a +=
|
|
2761
|
+
o.startsWith("`") ? a += Bt(o, u, t) : a += o, r = i.index + i[0].length;
|
|
2744
2762
|
}
|
|
2745
2763
|
return a += e.slice(r).replace(u, t), a;
|
|
2746
2764
|
}
|
|
2747
|
-
function
|
|
2765
|
+
function Bt(e, u, t) {
|
|
2748
2766
|
let a = "", r = 0;
|
|
2749
2767
|
const n = /\$\{([^}]*)\}/g;
|
|
2750
2768
|
let i;
|
|
@@ -2755,7 +2773,7 @@ function Pt(e, u, t) {
|
|
|
2755
2773
|
}
|
|
2756
2774
|
return a += e.slice(r), a;
|
|
2757
2775
|
}
|
|
2758
|
-
function
|
|
2776
|
+
function Ft(e, u) {
|
|
2759
2777
|
if (!e) return e;
|
|
2760
2778
|
let t = e;
|
|
2761
2779
|
const a = [...u.refs, ...u.computed];
|
|
@@ -2790,7 +2808,7 @@ function Bt(e, u) {
|
|
|
2790
2808
|
t = uu(t, o, `this.${s}`);
|
|
2791
2809
|
}
|
|
2792
2810
|
for (const r of u.props)
|
|
2793
|
-
t =
|
|
2811
|
+
t = $t(t, "__props", r, `this.${r}`);
|
|
2794
2812
|
for (const r of u.props)
|
|
2795
2813
|
t = R(t, r, `this.${r}`);
|
|
2796
2814
|
for (const [r, n] of Object.entries(u.reverseApiMap))
|
|
@@ -2811,7 +2829,7 @@ function Bt(e, u) {
|
|
|
2811
2829
|
function Z(e) {
|
|
2812
2830
|
return e.replace(/[.*+?^${}()|[\]\\]/g, "\\$&");
|
|
2813
2831
|
}
|
|
2814
|
-
function
|
|
2832
|
+
function $t(e, u, t, a) {
|
|
2815
2833
|
const r = new RegExp(
|
|
2816
2834
|
`\\b${Z(u)}\\.${Z(t)}\\b`,
|
|
2817
2835
|
"g"
|
|
@@ -2841,11 +2859,11 @@ function ie(e) {
|
|
|
2841
2859
|
}
|
|
2842
2860
|
return { simple: u, member: t };
|
|
2843
2861
|
}
|
|
2844
|
-
function
|
|
2862
|
+
function Ut(e) {
|
|
2845
2863
|
for (const u of e)
|
|
2846
2864
|
if (xe.includes(u.from)) return u.from;
|
|
2847
2865
|
}
|
|
2848
|
-
function
|
|
2866
|
+
function Gt(e) {
|
|
2849
2867
|
const u = {}, t = (a) => {
|
|
2850
2868
|
for (const [r, n] of Object.entries(a)) {
|
|
2851
2869
|
if (!n.composable || !n.replace || !n.replace.includes("."))
|
|
@@ -2876,16 +2894,16 @@ function $u(e, u) {
|
|
|
2876
2894
|
reverseApiMap: u.globalApiVars,
|
|
2877
2895
|
reverseMemberApiMap: u.reverseMemberApiMap || ie().member
|
|
2878
2896
|
};
|
|
2879
|
-
let a =
|
|
2897
|
+
let a = Ft(e, t);
|
|
2880
2898
|
a = a.replace(/_ctx\./g, "this."), a = a.replace(/this\.this\./g, "this.");
|
|
2881
2899
|
for (const [r, n] of Object.entries(u.libs || {}))
|
|
2882
2900
|
a = R(a, r, `this.$libs.${n}.${r}`);
|
|
2883
2901
|
return a;
|
|
2884
2902
|
}
|
|
2885
|
-
function
|
|
2886
|
-
const u =
|
|
2903
|
+
function Ht(e) {
|
|
2904
|
+
const u = Ut(e.imports || []), { simple: t, member: a } = ie(u);
|
|
2887
2905
|
if (e.globalApiDestructured && e.globalApiDestructured.length > 0) {
|
|
2888
|
-
const n =
|
|
2906
|
+
const n = Gt(u);
|
|
2889
2907
|
for (const { callee: i, destructure: s } of e.globalApiDestructured) {
|
|
2890
2908
|
const o = n[i];
|
|
2891
2909
|
if (o)
|
|
@@ -2916,10 +2934,10 @@ function Gt(e) {
|
|
|
2916
2934
|
}
|
|
2917
2935
|
const se = "arrow-double-left, arrow-double-right, contact, notes, records, cash-back-record, newspaper, discount, completed, user, description, list-switch, list-switching, link-o, miniprogram-o, qq, wechat-moments, weibo, cash-o, guide-o, invitation, shield-o, exchange, eye, enlarge, expand-o, eye-o, expand, filter-o, fire, fail, failure, fire-o, flag-o, font, font-o, gem-o, flower-o, gem, gift-card, friends, friends-o, gold-coin, gold-coin-o, good-job-o, gift, gift-o, gift-card-o, good-job, home-o, goods-collect, graphic, goods-collect-o, hot-o, info, hotel-o, info-o, hot-sale-o, hot, like, idcard, like-o, hot-sale, location-o, location, label, lock, label-o, map-marked, logistics, manager, more, live, manager-o, medal, more-o, music-o, music, new-arrival-o, medal-o, new-o, free-postage, newspaper-o, new-arrival, minus, orders-o, new, paid, notes-o, other-pay, pause-circle, pause, pause-circle-o, peer-pay, pending-payment, passed, plus, phone-circle-o, phone-o, printer, photo-fail, phone, photo-o, play-circle, play, phone-circle, point-gift-o, point-gift, play-circle-o, shrink, photo, qr, qr-invalid, question-o, revoke, replay, service, question, search, refund-o, service-o, scan, share, send-gift-o, share-o, setting, points, photograph, shop, shop-o, shop-collect-o, shop-collect, smile, shopping-cart-o, sign, sort, star-o, smile-comment-o, stop, stop-circle-o, smile-o, star, success, stop-circle, records-o, shopping-cart, tosend, todo-list, thumb-circle-o, thumb-circle, umbrella-circle, underway, upgrade, todo-list-o, tv-o, underway-o, user-o, vip-card-o, vip-card, send-gift, wap-home, wap-nav, volume-o, video, wap-home-o, volume, warning, weapp-nav, wechat-pay, wechat, setting-o, youzan-shield, warn-o, smile-comment, user-circle-o, video-o, add-square, add, arrow-down, arrow-up, arrow, after-sale, add-o, alipay, ascending, apps-o, aim, award, arrow-left, award-o, audio, bag-o, balance-list, back-top, bag, balance-pay, balance-o, bar-chart-o, bars, balance-list-o, birthday-cake-o, bookmark, bill, bell, browsing-history-o, browsing-history, bookmark-o, bulb-o, bullhorn-o, bill-o, calendar-o, brush-o, card, cart-o, cart-circle, cart-circle-o, cart, cash-on-deliver, cash-back-record-o, cashier-o, chart-trending-o, certificate, chat, clear, chat-o, checked, clock, clock-o, close, closed-eye, circle, cluster-o, column, comment-circle-o, cluster, comment, comment-o, comment-circle, completed-o, credit-pay, coupon, debit-pay, coupon-o, contact-o, descending, desktop-o, diamond-o, description-o, delete, diamond, delete-o, cross, edit, ellipsis, down, discount-o, ecard-pay, envelop-o".split(
|
|
2918
2936
|
", "
|
|
2919
|
-
),
|
|
2937
|
+
), Wt = "AddLocation, Aim, AlarmClock, Apple, ArrowDownBold, ArrowDown, ArrowLeftBold, ArrowLeft, ArrowRightBold, ArrowRight, ArrowUpBold, ArrowUp, Avatar, Back, Baseball, Basketball, BellFilled, Bell, Bicycle, BottomLeft, BottomRight, Bottom, Bowl, Box, Briefcase, BrushFilled, Brush, Burger, Calendar, CameraFilled, Camera, CaretBottom, CaretLeft, CaretRight, CaretTop, Cellphone, ChatDotRound, ChatDotSquare, ChatLineRound, ChatLineSquare, ChatRound, ChatSquare, Check, Checked, Cherry, Chicken, ChromeFilled, CircleCheckFilled, CircleCheck, CircleCloseFilled, CircleClose, CirclePlusFilled, CirclePlus, Clock, CloseBold, Close, Cloudy, CoffeeCup, Coffee, Coin, ColdDrink, CollectionTag, Collection, Comment, Compass, Connection, Coordinate, CopyDocument, Cpu, CreditCard, Crop, DArrowLeft, DArrowRight, DCaret, DataAnalysis, DataBoard, DataLine, DeleteFilled, DeleteLocation, Delete, Dessert, Discount, DishDot, Dish, DocumentAdd, DocumentChecked, DocumentCopy, DocumentDelete, DocumentRemove, Document, Download, Drizzling, EditPen, Edit, ElemeFilled, Eleme, ElementPlus, Expand, Failed, Female, Files, Film, Filter, Finished, FirstAidKit, Flag, Fold, FolderAdd, FolderChecked, FolderDelete, FolderOpened, FolderRemove, Folder, Food, Football, ForkSpoon, Fries, FullScreen, GobletFull, GobletSquareFull, GobletSquare, Goblet, GoldMedal, GoodsFilled, Goods, Grape, Grid, Guide, Handbag, Headset, HelpFilled, Help, Hide, Histogram, HomeFilled, HotWater, House, IceCreamRound, IceCreamSquare, IceCream, IceDrink, IceTea, InfoFilled, Iphone, Key, KnifeFork, Lightning, Link, List, Loading, LocationFilled, LocationInformation, Location, Lock, Lollipop, MagicStick, Magnet, Male, Management, MapLocation, Medal, Memo, Menu, MessageBox, Message, Mic, Microphone, MilkTea, Minus, Money, Monitor, MoonNight, Moon, MoreFilled, More, MostlyCloudy, Mouse, Mug, MuteNotification, Mute, NoSmoking, Notebook, Notification, Odometer, OfficeBuilding, Open, Operation, Opportunity, Orange, Paperclip, PartlyCloudy, Pear, PhoneFilled, Phone, PictureFilled, PictureRounded, Picture, PieChart, Place, Platform, Plus, Pointer, Position, Postcard, Pouring, Present, PriceTag, Printer, Promotion, QuartzWatch, QuestionFilled, Rank, ReadingLamp, Reading, RefreshLeft, RefreshRight, Refresh, Refrigerator, RemoveFilled, Remove, Right, ScaleToOriginal, School, Scissor, Search, Select, Sell, SemiSelect, Service, SetUp, Setting, Share, Ship, Shop, ShoppingBag, ShoppingCartFull, ShoppingCart, ShoppingTrolley, Smoking, Soccer, SoldOut, SortDown, SortUp, Sort, Stamp, StarFilled, Star, Stopwatch, SuccessFilled, Sugar, SuitcaseLine, Suitcase, Sunny, Sunrise, Sunset, SwitchButton, SwitchFilled, Switch, TakeawayBox, Ticket, Tickets, Timer, ToiletPaper, Tools, TopLeft, TopRight, Top, TrendCharts, TrophyBase, Trophy, TurnOff, Umbrella, Unlock, UploadFilled, Upload, UserFilled, User, Van, VideoCameraFilled, VideoCamera, VideoPause, VideoPlay, View, WalletFilled, Wallet, WarnTriangleFilled, WarningFilled, Warning, Watch, Watermelon, WindPower, ZoomIn, ZoomOut, VtjIconChatRecord, VtjIconNewChat, VtjIconAi, VtjIconUniapp, VtjIconWindowMax, VtjIconWindowMin, VtjIconWindowClose, VtjIconWindowNormal, VtjIconWindowDown, VtjIconWindowUp, VtjIconNpSave, VtjIconNpFile, VtjIconNpEdit, VtjIconNpShare, VtjIconNpSearch, VtjIconNpExport, VtjIconNpImport, VtjIconNpList, VtjIconNpPrint, VtjIconNpCancel, VtjIconNpConfirm, VtjIconNpReset, VtjIconNpReturnAll, VtjIconNpReturn, VtjIconNpRemove, VtjIconNpRemoveRow, VtjIconNpDelete, VtjIconNpExit, VtjIconNpRefresh, VtjIconNpAdd, VtjIconNpSelect, VtjIconNpAddRow, VtjIconNpExtend, VtjIconNpClose, VtjIconNpSubmit, VtjIconDeps, VtjIconBack, VtjIconHome, VtjIconApi, VtjIconExport, VtjIconImport, VtjIconGreater, VtjIconSmaller, VtjIconCheck, VtjIconSwitch, VtjIconCopy, VtjIconLock, VtjIconUnlock, VtjIconLayers, VtjIconConsole, VtjIconTeam, VtjIconPublish, VtjIconPreview, VtjIconSave, VtjIconPc, VtjIconPhone, VtjIconPad, VtjIconRedo, VtjIconRefresh, VtjIconUndo, VtjIconCategory, VtjIconProject, VtjIconNotice, VtjIconFav, VtjIconBug, VtjIconFile, VtjIconFolder, VtjIconUpload, VtjIconDownload, VtjIconUser, VtjIconSetting, VtjIconArrowRight, VtjIconArrowLeft, VtjIconArrowDown, VtjIconArrowUp, VtjIconShare, VtjIconData, VtjIconTemplate, VtjIconExitFullscreen, VtjIconFullscreen, VtjIconEdit, VtjIconRemove, VtjIconJs, VtjIconDatabase, VtjIconInfo, VtjIconPlus, VtjIconMinus, VtjIconHelp, VtjIconVars, VtjIconOutline, VtjIconVisible, VtjIconInvisible, VtjIconDocument, VtjIconHistory, VtjIconFixed, VtjIconUnfixed, VtjIconSearch, VtjIconMore, VtjIconClose, VtjIconComponents, VtjIconBlock".split(
|
|
2920
2938
|
", "
|
|
2921
|
-
),
|
|
2922
|
-
class
|
|
2939
|
+
), Jt = "user", L = "User";
|
|
2940
|
+
class Xt {
|
|
2923
2941
|
validate(u) {
|
|
2924
2942
|
const t = {
|
|
2925
2943
|
valid: !0,
|
|
@@ -2933,7 +2951,7 @@ class Jt {
|
|
|
2933
2951
|
}
|
|
2934
2952
|
isCompleteSFC(u) {
|
|
2935
2953
|
try {
|
|
2936
|
-
const t =
|
|
2954
|
+
const t = P(u);
|
|
2937
2955
|
return !!(t.template && t.script && t.styles);
|
|
2938
2956
|
} catch {
|
|
2939
2957
|
return !1;
|
|
@@ -2942,7 +2960,7 @@ class Jt {
|
|
|
2942
2960
|
checkSyntax(u) {
|
|
2943
2961
|
let t = "";
|
|
2944
2962
|
try {
|
|
2945
|
-
const a =
|
|
2963
|
+
const a = P(u);
|
|
2946
2964
|
B(a.script);
|
|
2947
2965
|
} catch (a) {
|
|
2948
2966
|
a instanceof SyntaxError && (t = a.message);
|
|
@@ -2950,7 +2968,7 @@ class Jt {
|
|
|
2950
2968
|
return t;
|
|
2951
2969
|
}
|
|
2952
2970
|
checkSetup(u) {
|
|
2953
|
-
const t =
|
|
2971
|
+
const t = P(u);
|
|
2954
2972
|
if (t.isScriptSetup)
|
|
2955
2973
|
return !0;
|
|
2956
2974
|
let a = 0;
|
|
@@ -2963,7 +2981,7 @@ class Jt {
|
|
|
2963
2981
|
}), a === 3;
|
|
2964
2982
|
}
|
|
2965
2983
|
findVantIcons(u) {
|
|
2966
|
-
const t =
|
|
2984
|
+
const t = P(u), a = /<(?:VanIcon|van-icon)\b[^>]*>/g, r = t.template.match(a) || [], n = [];
|
|
2967
2985
|
return r.forEach((i) => {
|
|
2968
2986
|
const s = i.match(/\bname="([^"]+)"/);
|
|
2969
2987
|
s && n.push(s[1]);
|
|
@@ -2976,13 +2994,13 @@ class Jt {
|
|
|
2976
2994
|
return a;
|
|
2977
2995
|
}
|
|
2978
2996
|
findVtjIcons(u) {
|
|
2979
|
-
const t =
|
|
2997
|
+
const t = P(u), a = /import\s*{([^}]+)}\s*from\s*['"]\@vtj\/icons['"]/, r = t.script.match(a);
|
|
2980
2998
|
return !r || !r[1] ? [] : r[1].split(",").map((n) => n.trim()).filter(Boolean);
|
|
2981
2999
|
}
|
|
2982
3000
|
checkVtjIcons(u) {
|
|
2983
3001
|
const t = this.findVtjIcons(u), a = [];
|
|
2984
3002
|
for (const r of t)
|
|
2985
|
-
|
|
3003
|
+
Wt.includes(r) || a.push(r);
|
|
2986
3004
|
return a;
|
|
2987
3005
|
}
|
|
2988
3006
|
hasUnchangedComment(u) {
|
|
@@ -3000,7 +3018,7 @@ class Jt {
|
|
|
3000
3018
|
function zt(e) {
|
|
3001
3019
|
const u = [];
|
|
3002
3020
|
let t = e;
|
|
3003
|
-
const a =
|
|
3021
|
+
const a = P(e);
|
|
3004
3022
|
if (!a.template || !a.script)
|
|
3005
3023
|
return {
|
|
3006
3024
|
fixed: !1,
|
|
@@ -3008,7 +3026,7 @@ function zt(e) {
|
|
|
3008
3026
|
fixedCode: e,
|
|
3009
3027
|
changes: []
|
|
3010
3028
|
};
|
|
3011
|
-
const r =
|
|
3029
|
+
const r = Qt(a.script), n = a.template;
|
|
3012
3030
|
let i = n;
|
|
3013
3031
|
const s = [], o = /\{\{([^}]+)\}\}/g;
|
|
3014
3032
|
let c;
|
|
@@ -3053,8 +3071,8 @@ function zt(e) {
|
|
|
3053
3071
|
});
|
|
3054
3072
|
}
|
|
3055
3073
|
}
|
|
3056
|
-
const
|
|
3057
|
-
for (; (c =
|
|
3074
|
+
const l = /v-(if|else-if|show)="([^"]+)"/g;
|
|
3075
|
+
for (; (c = l.exec(n)) !== null; ) {
|
|
3058
3076
|
const m = c[0], y = c[1], x = c[2], w = H(x, r);
|
|
3059
3077
|
if (w !== x) {
|
|
3060
3078
|
const I = G(n, c.index);
|
|
@@ -3083,12 +3101,12 @@ function zt(e) {
|
|
|
3083
3101
|
r
|
|
3084
3102
|
);
|
|
3085
3103
|
if (D !== I) {
|
|
3086
|
-
const F = G(n, c.index),
|
|
3104
|
+
const F = G(n, c.index), lu = `v-for="${w} in ${D}"`;
|
|
3087
3105
|
s.push({
|
|
3088
3106
|
start: c.index,
|
|
3089
3107
|
end: c.index + m.length,
|
|
3090
3108
|
original: m,
|
|
3091
|
-
replacement:
|
|
3109
|
+
replacement: lu,
|
|
3092
3110
|
line: F.line,
|
|
3093
3111
|
column: F.column
|
|
3094
3112
|
}), u.push({
|
|
@@ -3166,7 +3184,7 @@ function zt(e) {
|
|
|
3166
3184
|
}
|
|
3167
3185
|
const E = /(@|v-on:)(\w+)="([^"]+)"/g;
|
|
3168
3186
|
for (; (c = E.exec(n)) !== null; ) {
|
|
3169
|
-
const m = c[0], y = c[1], x = c[2], w = c[3], I =
|
|
3187
|
+
const m = c[0], y = c[1], x = c[2], w = c[3], I = Zt(w, r);
|
|
3170
3188
|
if (I !== w) {
|
|
3171
3189
|
const D = G(n, c.index);
|
|
3172
3190
|
s.push({
|
|
@@ -3200,7 +3218,7 @@ function zt(e) {
|
|
|
3200
3218
|
changes: u
|
|
3201
3219
|
};
|
|
3202
3220
|
}
|
|
3203
|
-
function
|
|
3221
|
+
function Qt(e) {
|
|
3204
3222
|
const u = /* @__PURE__ */ new Set();
|
|
3205
3223
|
try {
|
|
3206
3224
|
const t = B(e);
|
|
@@ -3226,7 +3244,7 @@ function H(e, u) {
|
|
|
3226
3244
|
r.test(t) && !t.includes(`state.${a}`) && (t = t.replace(r, `state.${a}`));
|
|
3227
3245
|
}), t;
|
|
3228
3246
|
}
|
|
3229
|
-
function
|
|
3247
|
+
function Zt(e, u) {
|
|
3230
3248
|
let t = e.trim();
|
|
3231
3249
|
return u.forEach((a) => {
|
|
3232
3250
|
const r = new RegExp(
|
|
@@ -3247,36 +3265,36 @@ function G(e, u) {
|
|
|
3247
3265
|
column: t[t.length - 1].length
|
|
3248
3266
|
};
|
|
3249
3267
|
}
|
|
3250
|
-
class
|
|
3268
|
+
class Kt {
|
|
3251
3269
|
fixBasedOnValidation(u, t) {
|
|
3252
3270
|
let a = u;
|
|
3253
3271
|
return t.illegalVantIcons.length && (a = this.fixVantIcons(a)), t.illegalVtjIcons.length && (a = this.fixVtjIcons(a, t.illegalVtjIcons)), zt(a).fixedCode;
|
|
3254
3272
|
}
|
|
3255
3273
|
fixVantIcons(u) {
|
|
3256
|
-
const t =
|
|
3274
|
+
const t = P(u), a = t.template.replace(
|
|
3257
3275
|
/<(?:VanIcon|van-icon)\s+[^>]*name="([^"]+)"[^>]*>/g,
|
|
3258
|
-
(r, n) => r.includes(":name=") || r.includes("v-bind:name=") || se.includes(n) ? r : r.replace(n,
|
|
3276
|
+
(r, n) => r.includes(":name=") || r.includes("v-bind:name=") || se.includes(n) ? r : r.replace(n, Jt)
|
|
3259
3277
|
);
|
|
3260
3278
|
return this.reconstructSFC(t, a, t.script);
|
|
3261
3279
|
}
|
|
3262
3280
|
fixVtjIcons(u, t = []) {
|
|
3263
|
-
const a =
|
|
3281
|
+
const a = P(u);
|
|
3264
3282
|
let r = !1;
|
|
3265
3283
|
a.script = Ju(a.script, {
|
|
3266
3284
|
ImportDeclaration(s) {
|
|
3267
3285
|
if (s.node.source.value === "@vtj/icons") {
|
|
3268
3286
|
const o = s.node.specifiers, c = [];
|
|
3269
3287
|
let d = !1;
|
|
3270
|
-
for (const
|
|
3271
|
-
const p =
|
|
3272
|
-
p ===
|
|
3273
|
-
q.importSpecifier(
|
|
3288
|
+
for (const l of o) {
|
|
3289
|
+
const p = l.imported?.name;
|
|
3290
|
+
p === L && (d = !0, r = !0), t.includes(p) || c.push(
|
|
3291
|
+
q.importSpecifier(l.local, l.imported)
|
|
3274
3292
|
);
|
|
3275
3293
|
}
|
|
3276
3294
|
!d && !r && (r = !0, c.push(
|
|
3277
3295
|
q.importSpecifier(
|
|
3278
|
-
q.identifier(
|
|
3279
|
-
q.identifier(
|
|
3296
|
+
q.identifier(L),
|
|
3297
|
+
q.identifier(L)
|
|
3280
3298
|
)
|
|
3281
3299
|
)), s.node.specifiers = c;
|
|
3282
3300
|
}
|
|
@@ -3288,11 +3306,11 @@ class Zt {
|
|
|
3288
3306
|
if (q.isReturnStatement(c) && q.isObjectExpression(c.argument)) {
|
|
3289
3307
|
const d = c.argument.properties || [];
|
|
3290
3308
|
c.argument.properties = d.filter(
|
|
3291
|
-
(
|
|
3309
|
+
(l) => !t.includes(l.key.name)
|
|
3292
3310
|
), c.argument.properties.push(
|
|
3293
3311
|
q.objectProperty(
|
|
3294
|
-
q.identifier(
|
|
3295
|
-
q.identifier(
|
|
3312
|
+
q.identifier(L),
|
|
3313
|
+
q.identifier(L),
|
|
3296
3314
|
!1,
|
|
3297
3315
|
!0
|
|
3298
3316
|
)
|
|
@@ -3301,13 +3319,13 @@ class Zt {
|
|
|
3301
3319
|
}
|
|
3302
3320
|
},
|
|
3303
3321
|
ObjectProperty(s) {
|
|
3304
|
-
if (q.isIdentifier(s.node.value) && t.includes(s.node.value.name) && (s.node.value = q.identifier(
|
|
3322
|
+
if (q.isIdentifier(s.node.value) && t.includes(s.node.value.name) && (s.node.value = q.identifier(L)), q.isArrayExpression(s.node.value)) {
|
|
3305
3323
|
const o = s.node.value.elements;
|
|
3306
|
-
s.node.value.elements = o.map((c) => q.isIdentifier(c) && t.includes(c.name) ? q.identifier(
|
|
3324
|
+
s.node.value.elements = o.map((c) => q.isIdentifier(c) && t.includes(c.name) ? q.identifier(L) : c);
|
|
3307
3325
|
}
|
|
3308
3326
|
},
|
|
3309
3327
|
AssignmentExpression(s) {
|
|
3310
|
-
q.isIdentifier(s.node.right) && t.includes(s.node.right.name) && (s.node.right = q.identifier(
|
|
3328
|
+
q.isIdentifier(s.node.right) && t.includes(s.node.right.name) && (s.node.right = q.identifier(L));
|
|
3311
3329
|
}
|
|
3312
3330
|
});
|
|
3313
3331
|
const n = /:icon\s*=\s*["']([^"']+)["']/g, i = a.template.match(n);
|
|
@@ -3315,13 +3333,13 @@ class Zt {
|
|
|
3315
3333
|
for (const s of i) {
|
|
3316
3334
|
let o = s;
|
|
3317
3335
|
for (const c of t)
|
|
3318
|
-
o = o.replace(new RegExp(c, "g"),
|
|
3336
|
+
o = o.replace(new RegExp(c, "g"), L);
|
|
3319
3337
|
a.template = a.template.replace(s, o);
|
|
3320
3338
|
}
|
|
3321
3339
|
for (const s of t)
|
|
3322
3340
|
a.template = a.template.replace(
|
|
3323
3341
|
new RegExp(`:icon="${s}"`, "g"),
|
|
3324
|
-
`:icon="${
|
|
3342
|
+
`:icon="${L}"`
|
|
3325
3343
|
);
|
|
3326
3344
|
return this.reconstructSFC(a, a.template, a.script);
|
|
3327
3345
|
}
|
|
@@ -3348,23 +3366,23 @@ ${a}
|
|
|
3348
3366
|
}), r;
|
|
3349
3367
|
}
|
|
3350
3368
|
}
|
|
3351
|
-
async function
|
|
3352
|
-
const { id: u, name: t, source: a, project: r } = e, n =
|
|
3369
|
+
async function b0(e) {
|
|
3370
|
+
const { id: u, name: t, source: a, project: r } = e, n = ke(a, t);
|
|
3353
3371
|
if (n)
|
|
3354
3372
|
return Promise.reject(n);
|
|
3355
|
-
const { dependencies: i = [], platform: s = "web" } = r || {}, o = new
|
|
3356
|
-
let
|
|
3373
|
+
const { dependencies: i = [], platform: s = "web" } = r || {}, o = new Xt(), c = new Kt(), d = o.validate(a);
|
|
3374
|
+
let l = [];
|
|
3357
3375
|
if (!d.valid)
|
|
3358
|
-
return
|
|
3359
|
-
const p = c.fixBasedOnValidation(a, d), b =
|
|
3360
|
-
b.script =
|
|
3376
|
+
return l = d.errors, Promise.reject(l);
|
|
3377
|
+
const p = c.fixBasedOnValidation(a, d), b = P(p);
|
|
3378
|
+
b.script = Ae(b.script);
|
|
3361
3379
|
const {
|
|
3362
3380
|
styles: h,
|
|
3363
3381
|
css: S,
|
|
3364
3382
|
errors: E
|
|
3365
3383
|
} = Ot(b.styles.join(`
|
|
3366
3384
|
`));
|
|
3367
|
-
return
|
|
3385
|
+
return l.push(...E), l.length ? Promise.reject(l) : b.isScriptSetup ? u0(b, {
|
|
3368
3386
|
id: u,
|
|
3369
3387
|
name: t,
|
|
3370
3388
|
project: r,
|
|
@@ -3372,7 +3390,7 @@ async function l0(e) {
|
|
|
3372
3390
|
dependencies: i,
|
|
3373
3391
|
styles: h,
|
|
3374
3392
|
css: S
|
|
3375
|
-
}) :
|
|
3393
|
+
}) : Yt(b, {
|
|
3376
3394
|
id: u,
|
|
3377
3395
|
name: t,
|
|
3378
3396
|
project: r,
|
|
@@ -3382,11 +3400,11 @@ async function l0(e) {
|
|
|
3382
3400
|
css: S
|
|
3383
3401
|
});
|
|
3384
3402
|
}
|
|
3385
|
-
async function
|
|
3403
|
+
async function Yt(e, u) {
|
|
3386
3404
|
const { id: t, name: a, project: r, platform: n, dependencies: i, styles: s, css: o } = u, {
|
|
3387
3405
|
state: c,
|
|
3388
3406
|
watch: d,
|
|
3389
|
-
lifeCycles:
|
|
3407
|
+
lifeCycles: l,
|
|
3390
3408
|
computed: p,
|
|
3391
3409
|
methods: b,
|
|
3392
3410
|
props: h,
|
|
@@ -3397,7 +3415,7 @@ async function Kt(e, u) {
|
|
|
3397
3415
|
imports: x,
|
|
3398
3416
|
dataSources: w,
|
|
3399
3417
|
directives: I
|
|
3400
|
-
} =
|
|
3418
|
+
} = et(e.script, r), { nodes: D, slots: F, context: lu } = re(t, a, e.template, {
|
|
3401
3419
|
platform: n,
|
|
3402
3420
|
handlers: y,
|
|
3403
3421
|
styles: s,
|
|
@@ -3410,7 +3428,7 @@ async function Kt(e, u) {
|
|
|
3410
3428
|
props: h,
|
|
3411
3429
|
state: c,
|
|
3412
3430
|
watch: d,
|
|
3413
|
-
lifeCycles:
|
|
3431
|
+
lifeCycles: l,
|
|
3414
3432
|
computed: p,
|
|
3415
3433
|
methods: b,
|
|
3416
3434
|
dataSources: w,
|
|
@@ -3419,7 +3437,7 @@ async function Kt(e, u) {
|
|
|
3419
3437
|
expose: E,
|
|
3420
3438
|
nodes: D,
|
|
3421
3439
|
css: o
|
|
3422
|
-
},
|
|
3440
|
+
}, le = Object.keys(p || {}), fe = (h || []).map(
|
|
3423
3441
|
($) => typeof $ == "string" ? $ : $.name
|
|
3424
3442
|
), be = [
|
|
3425
3443
|
"$el",
|
|
@@ -3440,30 +3458,30 @@ async function Kt(e, u) {
|
|
|
3440
3458
|
...Object.keys(b || {})
|
|
3441
3459
|
], { libs: pe } = de(x, i), Su = {
|
|
3442
3460
|
platform: n,
|
|
3443
|
-
context:
|
|
3444
|
-
computed:
|
|
3461
|
+
context: lu,
|
|
3462
|
+
computed: le,
|
|
3445
3463
|
libs: pe,
|
|
3446
3464
|
members: be,
|
|
3447
|
-
props:
|
|
3465
|
+
props: fe
|
|
3448
3466
|
};
|
|
3449
3467
|
return await ce(
|
|
3450
3468
|
yu,
|
|
3451
3469
|
async ($) => {
|
|
3452
3470
|
await oe($, async (K) => {
|
|
3453
|
-
if (
|
|
3454
|
-
const he = await
|
|
3471
|
+
if (du(K)) {
|
|
3472
|
+
const he = await ru(K.value);
|
|
3455
3473
|
K.value = Iu(he, $.id, Su);
|
|
3456
3474
|
}
|
|
3457
3475
|
});
|
|
3458
3476
|
},
|
|
3459
3477
|
async ($) => {
|
|
3460
|
-
const K = await
|
|
3478
|
+
const K = await ru($.value);
|
|
3461
3479
|
$.value = Iu(K, "", Su);
|
|
3462
3480
|
}
|
|
3463
3481
|
), new Hu(yu).toDsl();
|
|
3464
3482
|
}
|
|
3465
|
-
async function
|
|
3466
|
-
const { id: t, name: a, project: r, platform: n, styles: i, css: s, dependencies: o } = u, c =
|
|
3483
|
+
async function u0(e, u) {
|
|
3484
|
+
const { id: t, name: a, project: r, platform: n, styles: i, css: s, dependencies: o } = u, c = Nt(e.script, r), { nodes: d, slots: l, context: p } = re(t, a, e.template, {
|
|
3467
3485
|
platform: n,
|
|
3468
3486
|
handlers: c.handlers,
|
|
3469
3487
|
styles: i,
|
|
@@ -3486,12 +3504,12 @@ async function Yt(e, u) {
|
|
|
3486
3504
|
computed: c.computed,
|
|
3487
3505
|
methods: c.methods,
|
|
3488
3506
|
dataSources: c.dataSources,
|
|
3489
|
-
slots:
|
|
3507
|
+
slots: l,
|
|
3490
3508
|
emits: c.emits,
|
|
3491
3509
|
expose: c.expose,
|
|
3492
3510
|
nodes: d,
|
|
3493
3511
|
css: s
|
|
3494
|
-
}, { libs: h } = de(c.imports, o), S =
|
|
3512
|
+
}, { libs: h } = de(c.imports, o), S = Ht(c), E = {
|
|
3495
3513
|
refs: Array.from(S.refs),
|
|
3496
3514
|
reactives: Array.from(S.reactives),
|
|
3497
3515
|
hasState: S.hasState,
|
|
@@ -3509,8 +3527,8 @@ async function Yt(e, u) {
|
|
|
3509
3527
|
b,
|
|
3510
3528
|
async (y) => {
|
|
3511
3529
|
await oe(y, async (x) => {
|
|
3512
|
-
if (
|
|
3513
|
-
const w = await
|
|
3530
|
+
if (du(x)) {
|
|
3531
|
+
const w = await ru(x.value);
|
|
3514
3532
|
let I = $u(w, E);
|
|
3515
3533
|
const D = Array.from(
|
|
3516
3534
|
p[y.id] || /* @__PURE__ */ new Set()
|
|
@@ -3522,7 +3540,7 @@ async function Yt(e, u) {
|
|
|
3522
3540
|
});
|
|
3523
3541
|
},
|
|
3524
3542
|
async (y) => {
|
|
3525
|
-
const x = await
|
|
3543
|
+
const x = await ru(y.value);
|
|
3526
3544
|
y.value = $u(x, E);
|
|
3527
3545
|
}
|
|
3528
3546
|
), new Hu(b).toDsl();
|
|
@@ -3541,7 +3559,7 @@ async function ce(e, u, t) {
|
|
|
3541
3559
|
}
|
|
3542
3560
|
const y = Object.values(m);
|
|
3543
3561
|
for (const x of y)
|
|
3544
|
-
|
|
3562
|
+
du(x) ? await t(x) : await r(x);
|
|
3545
3563
|
}, {
|
|
3546
3564
|
state: n,
|
|
3547
3565
|
watch: i,
|
|
@@ -3549,7 +3567,7 @@ async function ce(e, u, t) {
|
|
|
3549
3567
|
props: o,
|
|
3550
3568
|
dataSources: c,
|
|
3551
3569
|
methods: d,
|
|
3552
|
-
lifeCycles:
|
|
3570
|
+
lifeCycles: l,
|
|
3553
3571
|
inject: p,
|
|
3554
3572
|
setup: b,
|
|
3555
3573
|
provide: h,
|
|
@@ -3563,7 +3581,7 @@ async function ce(e, u, t) {
|
|
|
3563
3581
|
props: o,
|
|
3564
3582
|
dataSources: c,
|
|
3565
3583
|
methods: d,
|
|
3566
|
-
lifeCycles:
|
|
3584
|
+
lifeCycles: l,
|
|
3567
3585
|
inject: p,
|
|
3568
3586
|
setup: b,
|
|
3569
3587
|
provide: h,
|
|
@@ -3581,7 +3599,7 @@ async function oe(e, u) {
|
|
|
3581
3599
|
await u(n), await t(n);
|
|
3582
3600
|
return;
|
|
3583
3601
|
}
|
|
3584
|
-
if (
|
|
3602
|
+
if (du(a)) {
|
|
3585
3603
|
await u(a);
|
|
3586
3604
|
return;
|
|
3587
3605
|
}
|
|
@@ -3611,12 +3629,12 @@ function de(e = [], u = []) {
|
|
|
3611
3629
|
};
|
|
3612
3630
|
}
|
|
3613
3631
|
export {
|
|
3614
|
-
|
|
3615
|
-
|
|
3616
|
-
|
|
3632
|
+
Kt as AutoFixer,
|
|
3633
|
+
Xt as ComponentValidator,
|
|
3634
|
+
l0 as VTJ_PARSER_VERSION,
|
|
3617
3635
|
qu as htmlToNodes,
|
|
3618
3636
|
f0 as parseUniApp,
|
|
3619
|
-
|
|
3637
|
+
b0 as parseVue,
|
|
3620
3638
|
Iu as patchCode,
|
|
3621
3639
|
R as replacer
|
|
3622
3640
|
};
|