ct-rich-text-editor 1.2.3 → 1.2.5
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/assets/style.css +5319 -1
- package/dist/{babel-1c4a328b.js → babel-d155920e.js} +2303 -2279
- package/dist/{babel-1c4a328b.js.map → babel-d155920e.js.map} +1 -1
- package/dist/estree-b1fff53b.js +4706 -0
- package/dist/{estree-2cbea43c.js.map → estree-b1fff53b.js.map} +1 -1
- package/dist/html-f95ee5dc.js +2885 -0
- package/dist/{html-c18fb60e.js.map → html-f95ee5dc.js.map} +1 -1
- package/dist/index-7c4c0170.js +655 -0
- package/dist/index-7c4c0170.js.map +1 -0
- package/dist/index-c98eb13a.js +27325 -0
- package/dist/index-c98eb13a.js.map +1 -0
- package/dist/index.js +48 -15
- package/dist/index.js.map +1 -1
- package/dist/markdown-1d9e6c3f.js +3759 -0
- package/dist/markdown-1d9e6c3f.js.map +1 -0
- package/dist/postcss-c2592f3f.js +5399 -0
- package/dist/postcss-c2592f3f.js.map +1 -0
- package/dist/standalone-bcc7f37a.js +2649 -0
- package/dist/standalone-bcc7f37a.js.map +1 -0
- package/dist/typescript-48c10f50.js +13601 -0
- package/dist/{typescript-39d06710.js.map → typescript-48c10f50.js.map} +1 -1
- package/package.json +4 -4
- package/dist/estree-2cbea43c.js +0 -4668
- package/dist/html-c18fb60e.js +0 -2842
- package/dist/index-0e027fdf.js +0 -806
- package/dist/index-0e027fdf.js.map +0 -1
- package/dist/index-bd25a91b.js +0 -35926
- package/dist/index-bd25a91b.js.map +0 -1
- package/dist/markdown-39c3822b.js +0 -3548
- package/dist/markdown-39c3822b.js.map +0 -1
- package/dist/postcss-bbcc713e.js +0 -5152
- package/dist/postcss-bbcc713e.js.map +0 -1
- package/dist/standalone-36ad3877.js +0 -2601
- package/dist/standalone-36ad3877.js.map +0 -1
- package/dist/typescript-39d06710.js +0 -13534
package/dist/html-c18fb60e.js
DELETED
|
@@ -1,2842 +0,0 @@
|
|
|
1
|
-
var on = Object.defineProperty;
|
|
2
|
-
var ln = (e, t, r) => t in e ? on(e, t, { enumerable: !0, configurable: !0, writable: !0, value: r }) : e[t] = r;
|
|
3
|
-
var We = (e, t, r) => (ln(e, typeof t != "symbol" ? t + "" : t, r), r);
|
|
4
|
-
var ar = Object.defineProperty, ir = (e) => {
|
|
5
|
-
throw TypeError(e);
|
|
6
|
-
}, cn = (e, t, r) => t in e ? ar(e, t, { enumerable: !0, configurable: !0, writable: !0, value: r }) : e[t] = r, sr = (e, t) => {
|
|
7
|
-
for (var r in t)
|
|
8
|
-
ar(e, r, { get: t[r], enumerable: !0 });
|
|
9
|
-
}, Et = (e, t, r) => cn(e, typeof t != "symbol" ? t + "" : t, r), ur = (e, t, r) => t.has(e) || ir("Cannot " + r), F = (e, t, r) => (ur(e, t, "read from private field"), r ? r.call(e) : t.get(e)), or = (e, t, r) => t.has(e) ? ir("Cannot add the same private member more than once") : t instanceof WeakSet ? t.add(e) : t.set(e, r), pn = (e, t, r, n) => (ur(e, t, "write to private field"), n ? n.call(e, r) : t.set(e, r), r), lr = {};
|
|
10
|
-
sr(lr, { languages: () => Ki, options: () => Yi, parsers: () => Xr, printers: () => nu });
|
|
11
|
-
var hn = (e, t, r, n) => {
|
|
12
|
-
if (!(e && t == null))
|
|
13
|
-
return t.replaceAll ? t.replaceAll(r, n) : r.global ? t.replace(r, n) : t.split(r).join(n);
|
|
14
|
-
}, L = hn, cr = "string", pr = "array", hr = "cursor", it = "indent", st = "align", dr = "trim", ut = "group", ot = "fill", lt = "if-break", ct = "indent-if-break", mr = "line-suffix", gr = "line-suffix-boundary", Q = "line", fr = "label", pt = "break-parent", vr = /* @__PURE__ */ new Set([hr, it, st, dr, ut, ot, lt, ct, mr, gr, Q, fr, pt]), dn = (e, t, r) => {
|
|
15
|
-
if (!(e && t == null))
|
|
16
|
-
return Array.isArray(t) || typeof t == "string" ? t[r < 0 ? t.length + r : r] : t.at(r);
|
|
17
|
-
}, de = dn;
|
|
18
|
-
function mn(e) {
|
|
19
|
-
if (typeof e == "string")
|
|
20
|
-
return cr;
|
|
21
|
-
if (Array.isArray(e))
|
|
22
|
-
return pr;
|
|
23
|
-
if (!e)
|
|
24
|
-
return;
|
|
25
|
-
let { type: t } = e;
|
|
26
|
-
if (vr.has(t))
|
|
27
|
-
return t;
|
|
28
|
-
}
|
|
29
|
-
var Cr = mn, gn = (e) => new Intl.ListFormat("en-US", { type: "disjunction" }).format(e);
|
|
30
|
-
function fn(e) {
|
|
31
|
-
let t = e === null ? "null" : typeof e;
|
|
32
|
-
if (t !== "string" && t !== "object")
|
|
33
|
-
return `Unexpected doc '${t}',
|
|
34
|
-
Expected it to be 'string' or 'object'.`;
|
|
35
|
-
if (Cr(e))
|
|
36
|
-
throw new Error("doc is valid.");
|
|
37
|
-
let r = Object.prototype.toString.call(e);
|
|
38
|
-
if (r !== "[object Object]")
|
|
39
|
-
return `Unexpected doc '${r}'.`;
|
|
40
|
-
let n = gn([...vr].map((a) => `'${a}'`));
|
|
41
|
-
return `Unexpected doc.type '${e.type}'.
|
|
42
|
-
Expected it to be ${n}.`;
|
|
43
|
-
}
|
|
44
|
-
var vn = class extends Error {
|
|
45
|
-
constructor(t) {
|
|
46
|
-
super(fn(t));
|
|
47
|
-
We(this, "name", "InvalidDocError");
|
|
48
|
-
this.doc = t;
|
|
49
|
-
}
|
|
50
|
-
}, Cn = vn;
|
|
51
|
-
function Sr(e, t) {
|
|
52
|
-
if (typeof e == "string")
|
|
53
|
-
return t(e);
|
|
54
|
-
let r = /* @__PURE__ */ new Map();
|
|
55
|
-
return n(e);
|
|
56
|
-
function n(i) {
|
|
57
|
-
if (r.has(i))
|
|
58
|
-
return r.get(i);
|
|
59
|
-
let s = a(i);
|
|
60
|
-
return r.set(i, s), s;
|
|
61
|
-
}
|
|
62
|
-
function a(i) {
|
|
63
|
-
switch (Cr(i)) {
|
|
64
|
-
case pr:
|
|
65
|
-
return t(i.map(n));
|
|
66
|
-
case ot:
|
|
67
|
-
return t({ ...i, parts: i.parts.map(n) });
|
|
68
|
-
case lt:
|
|
69
|
-
return t({ ...i, breakContents: n(i.breakContents), flatContents: n(i.flatContents) });
|
|
70
|
-
case ut: {
|
|
71
|
-
let { expandedStates: s, contents: u } = i;
|
|
72
|
-
return s ? (s = s.map(n), u = s[0]) : u = n(u), t({ ...i, contents: u, expandedStates: s });
|
|
73
|
-
}
|
|
74
|
-
case st:
|
|
75
|
-
case it:
|
|
76
|
-
case ct:
|
|
77
|
-
case fr:
|
|
78
|
-
case mr:
|
|
79
|
-
return t({ ...i, contents: n(i.contents) });
|
|
80
|
-
case cr:
|
|
81
|
-
case hr:
|
|
82
|
-
case dr:
|
|
83
|
-
case gr:
|
|
84
|
-
case Q:
|
|
85
|
-
case pt:
|
|
86
|
-
return t(i);
|
|
87
|
-
default:
|
|
88
|
-
throw new Cn(i);
|
|
89
|
-
}
|
|
90
|
-
}
|
|
91
|
-
}
|
|
92
|
-
function P(e, t = En) {
|
|
93
|
-
return Sr(e, (r) => typeof r == "string" ? Z(t, r.split(`
|
|
94
|
-
`)) : r);
|
|
95
|
-
}
|
|
96
|
-
var Sn = () => {
|
|
97
|
-
}, yn = Sn;
|
|
98
|
-
function M(e) {
|
|
99
|
-
return { type: it, contents: e };
|
|
100
|
-
}
|
|
101
|
-
function yr(e, t) {
|
|
102
|
-
return { type: st, contents: t, n: e };
|
|
103
|
-
}
|
|
104
|
-
function k(e, t = {}) {
|
|
105
|
-
return yn(t.expandedStates), { type: ut, id: t.id, contents: e, break: !!t.shouldBreak, expandedStates: t.expandedStates };
|
|
106
|
-
}
|
|
107
|
-
function bn(e) {
|
|
108
|
-
return yr(Number.NEGATIVE_INFINITY, e);
|
|
109
|
-
}
|
|
110
|
-
function _n(e) {
|
|
111
|
-
return yr({ type: "root" }, e);
|
|
112
|
-
}
|
|
113
|
-
function br(e) {
|
|
114
|
-
return { type: ot, parts: e };
|
|
115
|
-
}
|
|
116
|
-
function xe(e, t = "", r = {}) {
|
|
117
|
-
return { type: lt, breakContents: e, flatContents: t, groupId: r.groupId };
|
|
118
|
-
}
|
|
119
|
-
function wn(e, t) {
|
|
120
|
-
return { type: ct, contents: e, groupId: t.groupId, negate: t.negate };
|
|
121
|
-
}
|
|
122
|
-
var me = { type: pt }, An = { type: Q, hard: !0 }, kn = { type: Q, hard: !0, literal: !0 }, _ = { type: Q }, D = { type: Q, soft: !0 }, S = [An, me], En = [kn, me];
|
|
123
|
-
function Z(e, t) {
|
|
124
|
-
let r = [];
|
|
125
|
-
for (let n = 0; n < t.length; n++)
|
|
126
|
-
n !== 0 && r.push(e), r.push(t[n]);
|
|
127
|
-
return r;
|
|
128
|
-
}
|
|
129
|
-
var ye = "'", xt = '"';
|
|
130
|
-
function xn(e, t) {
|
|
131
|
-
let r = t === !0 || t === ye ? ye : xt, n = r === ye ? xt : ye, a = 0, i = 0;
|
|
132
|
-
for (let s of e)
|
|
133
|
-
s === r ? a++ : s === n && i++;
|
|
134
|
-
return a > i ? n : r;
|
|
135
|
-
}
|
|
136
|
-
var Dn = xn;
|
|
137
|
-
function Tn(e) {
|
|
138
|
-
if (typeof e != "string")
|
|
139
|
-
throw new TypeError("Expected a string");
|
|
140
|
-
return e.replace(/[|\\{}()[\]^$+*?.]/g, "\\$&").replace(/-/g, "\\x2d");
|
|
141
|
-
}
|
|
142
|
-
var N, Bn = class {
|
|
143
|
-
constructor(e) {
|
|
144
|
-
or(this, N), pn(this, N, new Set(e));
|
|
145
|
-
}
|
|
146
|
-
getLeadingWhitespaceCount(e) {
|
|
147
|
-
let t = F(this, N), r = 0;
|
|
148
|
-
for (let n = 0; n < e.length && t.has(e.charAt(n)); n++)
|
|
149
|
-
r++;
|
|
150
|
-
return r;
|
|
151
|
-
}
|
|
152
|
-
getTrailingWhitespaceCount(e) {
|
|
153
|
-
let t = F(this, N), r = 0;
|
|
154
|
-
for (let n = e.length - 1; n >= 0 && t.has(e.charAt(n)); n--)
|
|
155
|
-
r++;
|
|
156
|
-
return r;
|
|
157
|
-
}
|
|
158
|
-
getLeadingWhitespace(e) {
|
|
159
|
-
let t = this.getLeadingWhitespaceCount(e);
|
|
160
|
-
return e.slice(0, t);
|
|
161
|
-
}
|
|
162
|
-
getTrailingWhitespace(e) {
|
|
163
|
-
let t = this.getTrailingWhitespaceCount(e);
|
|
164
|
-
return e.slice(e.length - t);
|
|
165
|
-
}
|
|
166
|
-
hasLeadingWhitespace(e) {
|
|
167
|
-
return F(this, N).has(e.charAt(0));
|
|
168
|
-
}
|
|
169
|
-
hasTrailingWhitespace(e) {
|
|
170
|
-
return F(this, N).has(de(!1, e, -1));
|
|
171
|
-
}
|
|
172
|
-
trimStart(e) {
|
|
173
|
-
let t = this.getLeadingWhitespaceCount(e);
|
|
174
|
-
return e.slice(t);
|
|
175
|
-
}
|
|
176
|
-
trimEnd(e) {
|
|
177
|
-
let t = this.getTrailingWhitespaceCount(e);
|
|
178
|
-
return e.slice(0, e.length - t);
|
|
179
|
-
}
|
|
180
|
-
trim(e) {
|
|
181
|
-
return this.trimEnd(this.trimStart(e));
|
|
182
|
-
}
|
|
183
|
-
split(e, t = !1) {
|
|
184
|
-
let r = `[${Tn([...F(this, N)].join(""))}]+`, n = new RegExp(t ? `(${r})` : r, "u");
|
|
185
|
-
return e.split(n);
|
|
186
|
-
}
|
|
187
|
-
hasWhitespaceCharacter(e) {
|
|
188
|
-
let t = F(this, N);
|
|
189
|
-
return Array.prototype.some.call(e, (r) => t.has(r));
|
|
190
|
-
}
|
|
191
|
-
hasNonWhitespaceCharacter(e) {
|
|
192
|
-
let t = F(this, N);
|
|
193
|
-
return Array.prototype.some.call(e, (r) => !t.has(r));
|
|
194
|
-
}
|
|
195
|
-
isWhitespaceOnly(e) {
|
|
196
|
-
let t = F(this, N);
|
|
197
|
-
return Array.prototype.every.call(e, (r) => t.has(r));
|
|
198
|
-
}
|
|
199
|
-
};
|
|
200
|
-
N = /* @__PURE__ */ new WeakMap();
|
|
201
|
-
var Ln = Bn, Fn = [" ", `
|
|
202
|
-
`, "\f", "\r", " "], qn = new Ln(Fn), R = qn, Nn = class extends Error {
|
|
203
|
-
constructor(t, r, n = "type") {
|
|
204
|
-
super(`Unexpected ${r} node ${n}: ${JSON.stringify(t[n])}.`);
|
|
205
|
-
We(this, "name", "UnexpectedNodeError");
|
|
206
|
-
this.node = t;
|
|
207
|
-
}
|
|
208
|
-
}, In = Nn;
|
|
209
|
-
function Pn(e) {
|
|
210
|
-
return (e == null ? void 0 : e.type) === "front-matter";
|
|
211
|
-
}
|
|
212
|
-
var Ne = Pn, Hn = /* @__PURE__ */ new Set(["sourceSpan", "startSourceSpan", "endSourceSpan", "nameSpan", "valueSpan", "keySpan", "tagDefinition", "tokens", "valueTokens", "switchValueSourceSpan", "expSourceSpan", "valueSourceSpan"]), Mn = /* @__PURE__ */ new Set(["if", "else if", "for", "switch", "case"]);
|
|
213
|
-
function _r(e, t) {
|
|
214
|
-
var r;
|
|
215
|
-
if (e.type === "text" || e.type === "comment" || Ne(e) || e.type === "yaml" || e.type === "toml")
|
|
216
|
-
return null;
|
|
217
|
-
if (e.type === "attribute" && delete t.value, e.type === "docType" && delete t.value, e.type === "angularControlFlowBlock" && (r = e.parameters) != null && r.children)
|
|
218
|
-
for (let n of t.parameters.children)
|
|
219
|
-
Mn.has(e.name) ? delete n.expression : n.expression = n.expression.trim();
|
|
220
|
-
e.type === "angularIcuExpression" && (t.switchValue = e.switchValue.trim()), e.type === "angularLetDeclarationInitializer" && delete t.value;
|
|
221
|
-
}
|
|
222
|
-
_r.ignoredProperties = Hn;
|
|
223
|
-
var Rn = _r;
|
|
224
|
-
async function Un(e, t) {
|
|
225
|
-
if (e.language === "yaml") {
|
|
226
|
-
let r = e.value.trim(), n = r ? await t(r, { parser: "yaml" }) : "";
|
|
227
|
-
return _n([e.startDelimiter, e.explicitLanguage, S, n, n ? S : "", e.endDelimiter]);
|
|
228
|
-
}
|
|
229
|
-
}
|
|
230
|
-
var Vn = Un;
|
|
231
|
-
function Ie(e, t = !0) {
|
|
232
|
-
return [M([D, e]), t ? D : ""];
|
|
233
|
-
}
|
|
234
|
-
function ee(e, t) {
|
|
235
|
-
let r = e.type === "NGRoot" ? e.node.type === "NGMicrosyntax" && e.node.body.length === 1 && e.node.body[0].type === "NGMicrosyntaxExpression" ? e.node.body[0].expression : e.node : e.type === "JsExpressionRoot" ? e.node : e;
|
|
236
|
-
return r && (r.type === "ObjectExpression" || r.type === "ArrayExpression" || (t.parser === "__vue_expression" || t.parser === "__vue_ts_expression") && (r.type === "TemplateLiteral" || r.type === "StringLiteral"));
|
|
237
|
-
}
|
|
238
|
-
async function H(e, t, r, n) {
|
|
239
|
-
r = { __isInHtmlAttribute: !0, __embeddedInHtml: !0, ...r };
|
|
240
|
-
let a = !0;
|
|
241
|
-
n && (r.__onHtmlBindingRoot = (s, u) => {
|
|
242
|
-
a = n(s, u);
|
|
243
|
-
});
|
|
244
|
-
let i = await t(e, r, t);
|
|
245
|
-
return a ? k(i) : Ie(i);
|
|
246
|
-
}
|
|
247
|
-
function On(e, t, r, n) {
|
|
248
|
-
let { node: a } = r, i = n.originalText.slice(a.sourceSpan.start.offset, a.sourceSpan.end.offset);
|
|
249
|
-
return /^\s*$/u.test(i) ? "" : H(i, e, { parser: "__ng_directive", __isInHtmlAttribute: !1 }, ee);
|
|
250
|
-
}
|
|
251
|
-
var Wn = On, zn = (e) => String(e).split(/[/\\]/u).pop();
|
|
252
|
-
function Dt(e, t) {
|
|
253
|
-
if (!t)
|
|
254
|
-
return;
|
|
255
|
-
let r = zn(t).toLowerCase();
|
|
256
|
-
return e.find(({ filenames: n }) => n == null ? void 0 : n.some((a) => a.toLowerCase() === r)) ?? e.find(({ extensions: n }) => n == null ? void 0 : n.some((a) => r.endsWith(a)));
|
|
257
|
-
}
|
|
258
|
-
function $n(e, t) {
|
|
259
|
-
if (t)
|
|
260
|
-
return e.find(({ name: r }) => r.toLowerCase() === t) ?? e.find(({ aliases: r }) => r == null ? void 0 : r.includes(t)) ?? e.find(({ extensions: r }) => r == null ? void 0 : r.includes(`.${t}`));
|
|
261
|
-
}
|
|
262
|
-
function jn(e, t) {
|
|
263
|
-
let r = e.plugins.flatMap((a) => a.languages ?? []), n = $n(r, t.language) ?? Dt(r, t.physicalFile) ?? Dt(r, t.file) ?? (t.physicalFile, void 0);
|
|
264
|
-
return n == null ? void 0 : n.parsers[0];
|
|
265
|
-
}
|
|
266
|
-
var Pe = jn, Gn = "inline", Kn = { area: "none", base: "none", basefont: "none", datalist: "none", head: "none", link: "none", meta: "none", noembed: "none", noframes: "none", param: "block", rp: "none", script: "block", style: "none", template: "inline", title: "none", html: "block", body: "block", address: "block", blockquote: "block", center: "block", dialog: "block", div: "block", figure: "block", figcaption: "block", footer: "block", form: "block", header: "block", hr: "block", legend: "block", listing: "block", main: "block", p: "block", plaintext: "block", pre: "block", search: "block", xmp: "block", slot: "contents", ruby: "ruby", rt: "ruby-text", article: "block", aside: "block", h1: "block", h2: "block", h3: "block", h4: "block", h5: "block", h6: "block", hgroup: "block", nav: "block", section: "block", dir: "block", dd: "block", dl: "block", dt: "block", menu: "block", ol: "block", ul: "block", li: "list-item", table: "table", caption: "table-caption", colgroup: "table-column-group", col: "table-column", thead: "table-header-group", tbody: "table-row-group", tfoot: "table-footer-group", tr: "table-row", td: "table-cell", th: "table-cell", input: "inline-block", button: "inline-block", fieldset: "block", details: "block", summary: "block", marquee: "inline-block", source: "block", track: "block", meter: "inline-block", progress: "inline-block", object: "inline-block", video: "inline-block", audio: "inline-block", select: "inline-block", option: "block", optgroup: "block" }, Xn = "normal", Yn = { listing: "pre", plaintext: "pre", pre: "pre", xmp: "pre", nobr: "nowrap", table: "initial", textarea: "pre-wrap" };
|
|
267
|
-
function Jn(e) {
|
|
268
|
-
return e.type === "element" && !e.hasExplicitNamespace && !["html", "svg"].includes(e.namespace);
|
|
269
|
-
}
|
|
270
|
-
var pe = Jn, Qn = (e) => L(!1, e, /^[\t\f\r ]*\n/gu, ""), wr = (e) => Qn(R.trimEnd(e)), Zn = (e) => {
|
|
271
|
-
let t = e, r = R.getLeadingWhitespace(t);
|
|
272
|
-
r && (t = t.slice(r.length));
|
|
273
|
-
let n = R.getTrailingWhitespace(t);
|
|
274
|
-
return n && (t = t.slice(0, -n.length)), { leadingWhitespace: r, trailingWhitespace: n, text: t };
|
|
275
|
-
};
|
|
276
|
-
function Ar(e, t) {
|
|
277
|
-
return !!(e.type === "ieConditionalComment" && e.lastChild && !e.lastChild.isSelfClosing && !e.lastChild.endSourceSpan || e.type === "ieConditionalComment" && !e.complete || J(e) && e.children.some((r) => r.type !== "text" && r.type !== "interpolation") || dt(e, t) && !U(e) && e.type !== "interpolation");
|
|
278
|
-
}
|
|
279
|
-
function He(e) {
|
|
280
|
-
return e.type === "attribute" || !e.parent || !e.prev ? !1 : ea(e.prev);
|
|
281
|
-
}
|
|
282
|
-
function ea(e) {
|
|
283
|
-
return e.type === "comment" && e.value.trim() === "prettier-ignore";
|
|
284
|
-
}
|
|
285
|
-
function q(e) {
|
|
286
|
-
return e.type === "text" || e.type === "comment";
|
|
287
|
-
}
|
|
288
|
-
function U(e) {
|
|
289
|
-
return e.type === "element" && (e.fullName === "script" || e.fullName === "style" || e.fullName === "svg:style" || e.fullName === "svg:script" || pe(e) && (e.name === "script" || e.name === "style"));
|
|
290
|
-
}
|
|
291
|
-
function ta(e) {
|
|
292
|
-
return e.children && !U(e);
|
|
293
|
-
}
|
|
294
|
-
function ra(e) {
|
|
295
|
-
return U(e) || e.type === "interpolation" || kr(e);
|
|
296
|
-
}
|
|
297
|
-
function kr(e) {
|
|
298
|
-
return Fr(e).startsWith("pre");
|
|
299
|
-
}
|
|
300
|
-
function na(e, t) {
|
|
301
|
-
var r, n;
|
|
302
|
-
let a = i();
|
|
303
|
-
if (a && !e.prev && (n = (r = e.parent) == null ? void 0 : r.tagDefinition) != null && n.ignoreFirstLf)
|
|
304
|
-
return e.type === "interpolation";
|
|
305
|
-
return a;
|
|
306
|
-
function i() {
|
|
307
|
-
return Ne(e) || e.type === "angularControlFlowBlock" ? !1 : (e.type === "text" || e.type === "interpolation") && e.prev && (e.prev.type === "text" || e.prev.type === "interpolation") ? !0 : !e.parent || e.parent.cssDisplay === "none" ? !1 : J(e.parent) ? !0 : !(!e.prev && (e.parent.type === "root" || J(e) && e.parent || U(e.parent) || Me(e.parent, t) || !ha(e.parent.cssDisplay)) || e.prev && !ga(e.prev.cssDisplay));
|
|
308
|
-
}
|
|
309
|
-
}
|
|
310
|
-
function aa(e, t) {
|
|
311
|
-
return Ne(e) || e.type === "angularControlFlowBlock" ? !1 : (e.type === "text" || e.type === "interpolation") && e.next && (e.next.type === "text" || e.next.type === "interpolation") ? !0 : !e.parent || e.parent.cssDisplay === "none" ? !1 : J(e.parent) ? !0 : !(!e.next && (e.parent.type === "root" || J(e) && e.parent || U(e.parent) || Me(e.parent, t) || !da(e.parent.cssDisplay)) || e.next && !ma(e.next.cssDisplay));
|
|
312
|
-
}
|
|
313
|
-
function ia(e) {
|
|
314
|
-
return fa(e.cssDisplay) && !U(e);
|
|
315
|
-
}
|
|
316
|
-
function be(e) {
|
|
317
|
-
return Ne(e) || e.next && e.sourceSpan.end && e.sourceSpan.end.line + 1 < e.next.sourceSpan.start.line;
|
|
318
|
-
}
|
|
319
|
-
function sa(e) {
|
|
320
|
-
return Er(e) || e.type === "element" && e.children.length > 0 && (["body", "script", "style"].includes(e.name) || e.children.some((t) => oa(t))) || e.firstChild && e.firstChild === e.lastChild && e.firstChild.type !== "text" && Dr(e.firstChild) && (!e.lastChild.isTrailingSpaceSensitive || Tr(e.lastChild));
|
|
321
|
-
}
|
|
322
|
-
function Er(e) {
|
|
323
|
-
return e.type === "element" && e.children.length > 0 && (["html", "head", "ul", "ol", "select"].includes(e.name) || e.cssDisplay.startsWith("table") && e.cssDisplay !== "table-cell");
|
|
324
|
-
}
|
|
325
|
-
function ze(e) {
|
|
326
|
-
return Br(e) || e.prev && ua(e.prev) || xr(e);
|
|
327
|
-
}
|
|
328
|
-
function ua(e) {
|
|
329
|
-
return Br(e) || e.type === "element" && e.fullName === "br" || xr(e);
|
|
330
|
-
}
|
|
331
|
-
function xr(e) {
|
|
332
|
-
return Dr(e) && Tr(e);
|
|
333
|
-
}
|
|
334
|
-
function Dr(e) {
|
|
335
|
-
return e.hasLeadingSpaces && (e.prev ? e.prev.sourceSpan.end.line < e.sourceSpan.start.line : e.parent.type === "root" || e.parent.startSourceSpan.end.line < e.sourceSpan.start.line);
|
|
336
|
-
}
|
|
337
|
-
function Tr(e) {
|
|
338
|
-
return e.hasTrailingSpaces && (e.next ? e.next.sourceSpan.start.line > e.sourceSpan.end.line : e.parent.type === "root" || e.parent.endSourceSpan && e.parent.endSourceSpan.start.line > e.sourceSpan.end.line);
|
|
339
|
-
}
|
|
340
|
-
function Br(e) {
|
|
341
|
-
switch (e.type) {
|
|
342
|
-
case "ieConditionalComment":
|
|
343
|
-
case "comment":
|
|
344
|
-
case "directive":
|
|
345
|
-
return !0;
|
|
346
|
-
case "element":
|
|
347
|
-
return ["script", "select"].includes(e.name);
|
|
348
|
-
}
|
|
349
|
-
return !1;
|
|
350
|
-
}
|
|
351
|
-
function ht(e) {
|
|
352
|
-
return e.lastChild ? ht(e.lastChild) : e;
|
|
353
|
-
}
|
|
354
|
-
function oa(e) {
|
|
355
|
-
var t;
|
|
356
|
-
return (t = e.children) == null ? void 0 : t.some((r) => r.type !== "text");
|
|
357
|
-
}
|
|
358
|
-
function Lr(e) {
|
|
359
|
-
if (e)
|
|
360
|
-
switch (e) {
|
|
361
|
-
case "module":
|
|
362
|
-
case "text/javascript":
|
|
363
|
-
case "text/babel":
|
|
364
|
-
case "application/javascript":
|
|
365
|
-
return "babel";
|
|
366
|
-
case "application/x-typescript":
|
|
367
|
-
return "typescript";
|
|
368
|
-
case "text/markdown":
|
|
369
|
-
return "markdown";
|
|
370
|
-
case "text/html":
|
|
371
|
-
return "html";
|
|
372
|
-
case "text/x-handlebars-template":
|
|
373
|
-
return "glimmer";
|
|
374
|
-
default:
|
|
375
|
-
if (e.endsWith("json") || e.endsWith("importmap") || e === "speculationrules")
|
|
376
|
-
return "json";
|
|
377
|
-
}
|
|
378
|
-
}
|
|
379
|
-
function la(e, t) {
|
|
380
|
-
let { name: r, attrMap: n } = e;
|
|
381
|
-
if (r !== "script" || Object.prototype.hasOwnProperty.call(n, "src"))
|
|
382
|
-
return;
|
|
383
|
-
let { type: a, lang: i } = e.attrMap;
|
|
384
|
-
return !i && !a ? "babel" : Pe(t, { language: i }) ?? Lr(a);
|
|
385
|
-
}
|
|
386
|
-
function ca(e, t) {
|
|
387
|
-
if (!dt(e, t))
|
|
388
|
-
return;
|
|
389
|
-
let { attrMap: r } = e;
|
|
390
|
-
if (Object.prototype.hasOwnProperty.call(r, "src"))
|
|
391
|
-
return;
|
|
392
|
-
let { type: n, lang: a } = r;
|
|
393
|
-
return Pe(t, { language: a }) ?? Lr(n);
|
|
394
|
-
}
|
|
395
|
-
function pa(e, t) {
|
|
396
|
-
if (e.name !== "style")
|
|
397
|
-
return;
|
|
398
|
-
let { lang: r } = e.attrMap;
|
|
399
|
-
return r ? Pe(t, { language: r }) : "css";
|
|
400
|
-
}
|
|
401
|
-
function Tt(e, t) {
|
|
402
|
-
return la(e, t) ?? pa(e, t) ?? ca(e, t);
|
|
403
|
-
}
|
|
404
|
-
function ge(e) {
|
|
405
|
-
return e === "block" || e === "list-item" || e.startsWith("table");
|
|
406
|
-
}
|
|
407
|
-
function ha(e) {
|
|
408
|
-
return !ge(e) && e !== "inline-block";
|
|
409
|
-
}
|
|
410
|
-
function da(e) {
|
|
411
|
-
return !ge(e) && e !== "inline-block";
|
|
412
|
-
}
|
|
413
|
-
function ma(e) {
|
|
414
|
-
return !ge(e);
|
|
415
|
-
}
|
|
416
|
-
function ga(e) {
|
|
417
|
-
return !ge(e);
|
|
418
|
-
}
|
|
419
|
-
function fa(e) {
|
|
420
|
-
return !ge(e) && e !== "inline-block";
|
|
421
|
-
}
|
|
422
|
-
function J(e) {
|
|
423
|
-
return Fr(e).startsWith("pre");
|
|
424
|
-
}
|
|
425
|
-
function va(e, t) {
|
|
426
|
-
let r = e;
|
|
427
|
-
for (; r; ) {
|
|
428
|
-
if (t(r))
|
|
429
|
-
return !0;
|
|
430
|
-
r = r.parent;
|
|
431
|
-
}
|
|
432
|
-
return !1;
|
|
433
|
-
}
|
|
434
|
-
function Ca(e, t) {
|
|
435
|
-
var r;
|
|
436
|
-
if (te(e, t))
|
|
437
|
-
return "block";
|
|
438
|
-
if (((r = e.prev) == null ? void 0 : r.type) === "comment") {
|
|
439
|
-
let a = e.prev.value.match(/^\s*display:\s*([a-z]+)\s*$/u);
|
|
440
|
-
if (a)
|
|
441
|
-
return a[1];
|
|
442
|
-
}
|
|
443
|
-
let n = !1;
|
|
444
|
-
if (e.type === "element" && e.namespace === "svg")
|
|
445
|
-
if (va(e, (a) => a.fullName === "svg:foreignObject"))
|
|
446
|
-
n = !0;
|
|
447
|
-
else
|
|
448
|
-
return e.name === "svg" ? "inline-block" : "block";
|
|
449
|
-
switch (t.htmlWhitespaceSensitivity) {
|
|
450
|
-
case "strict":
|
|
451
|
-
return "inline";
|
|
452
|
-
case "ignore":
|
|
453
|
-
return "block";
|
|
454
|
-
default:
|
|
455
|
-
return e.type === "element" && (!e.namespace || n || pe(e)) && Kn[e.name] || Gn;
|
|
456
|
-
}
|
|
457
|
-
}
|
|
458
|
-
function Fr(e) {
|
|
459
|
-
return e.type === "element" && (!e.namespace || pe(e)) && Yn[e.name] || Xn;
|
|
460
|
-
}
|
|
461
|
-
function Sa(e) {
|
|
462
|
-
let t = Number.POSITIVE_INFINITY;
|
|
463
|
-
for (let r of e.split(`
|
|
464
|
-
`)) {
|
|
465
|
-
if (r.length === 0)
|
|
466
|
-
continue;
|
|
467
|
-
let n = R.getLeadingWhitespaceCount(r);
|
|
468
|
-
if (n === 0)
|
|
469
|
-
return 0;
|
|
470
|
-
r.length !== n && n < t && (t = n);
|
|
471
|
-
}
|
|
472
|
-
return t === Number.POSITIVE_INFINITY ? 0 : t;
|
|
473
|
-
}
|
|
474
|
-
function qr(e, t = Sa(e)) {
|
|
475
|
-
return t === 0 ? e : e.split(`
|
|
476
|
-
`).map((r) => r.slice(t)).join(`
|
|
477
|
-
`);
|
|
478
|
-
}
|
|
479
|
-
function Nr(e) {
|
|
480
|
-
return L(!1, L(!1, e, "'", "'"), """, '"');
|
|
481
|
-
}
|
|
482
|
-
function O(e) {
|
|
483
|
-
return Nr(e.value);
|
|
484
|
-
}
|
|
485
|
-
var ya = /* @__PURE__ */ new Set(["template", "style", "script"]);
|
|
486
|
-
function Me(e, t) {
|
|
487
|
-
return te(e, t) && !ya.has(e.fullName);
|
|
488
|
-
}
|
|
489
|
-
function te(e, t) {
|
|
490
|
-
return t.parser === "vue" && e.type === "element" && e.parent.type === "root" && e.fullName.toLowerCase() !== "html";
|
|
491
|
-
}
|
|
492
|
-
function dt(e, t) {
|
|
493
|
-
return te(e, t) && (Me(e, t) || e.attrMap.lang && e.attrMap.lang !== "html");
|
|
494
|
-
}
|
|
495
|
-
function ba(e) {
|
|
496
|
-
let t = e.fullName;
|
|
497
|
-
return t.charAt(0) === "#" || t === "slot-scope" || t === "v-slot" || t.startsWith("v-slot:");
|
|
498
|
-
}
|
|
499
|
-
function _a(e, t) {
|
|
500
|
-
let r = e.parent;
|
|
501
|
-
if (!te(r, t))
|
|
502
|
-
return !1;
|
|
503
|
-
let n = r.fullName, a = e.fullName;
|
|
504
|
-
return n === "script" && a === "setup" || n === "style" && a === "vars";
|
|
505
|
-
}
|
|
506
|
-
function Ir(e, t = e.value) {
|
|
507
|
-
return e.parent.isWhitespaceSensitive ? e.parent.isIndentationSensitive ? P(t) : P(qr(wr(t)), S) : Z(_, R.split(t));
|
|
508
|
-
}
|
|
509
|
-
function Pr(e, t) {
|
|
510
|
-
return te(e, t) && e.name === "script";
|
|
511
|
-
}
|
|
512
|
-
var Hr = /\{\{(.+?)\}\}/su;
|
|
513
|
-
async function wa(e, t) {
|
|
514
|
-
let r = [];
|
|
515
|
-
for (let [n, a] of e.split(Hr).entries())
|
|
516
|
-
if (n % 2 === 0)
|
|
517
|
-
r.push(P(a));
|
|
518
|
-
else
|
|
519
|
-
try {
|
|
520
|
-
r.push(k(["{{", M([_, await H(a, t, { parser: "__ng_interpolation", __isInHtmlInterpolation: !0 })]), _, "}}"]));
|
|
521
|
-
} catch {
|
|
522
|
-
r.push("{{", P(a), "}}");
|
|
523
|
-
}
|
|
524
|
-
return r;
|
|
525
|
-
}
|
|
526
|
-
function mt({ parser: e }) {
|
|
527
|
-
return (t, r, n) => H(O(n.node), t, { parser: e }, ee);
|
|
528
|
-
}
|
|
529
|
-
var Aa = mt({ parser: "__ng_action" }), ka = mt({ parser: "__ng_binding" }), Ea = mt({ parser: "__ng_directive" });
|
|
530
|
-
function xa(e, t) {
|
|
531
|
-
if (t.parser !== "angular")
|
|
532
|
-
return;
|
|
533
|
-
let { node: r } = e, n = r.fullName;
|
|
534
|
-
if (n.startsWith("(") && n.endsWith(")") || n.startsWith("on-"))
|
|
535
|
-
return Aa;
|
|
536
|
-
if (n.startsWith("[") && n.endsWith("]") || /^bind(?:on)?-/u.test(n) || /^ng-(?:if|show|hide|class|style)$/u.test(n))
|
|
537
|
-
return ka;
|
|
538
|
-
if (n.startsWith("*"))
|
|
539
|
-
return Ea;
|
|
540
|
-
let a = O(r);
|
|
541
|
-
if (/^i18n(?:-.+)?$/u.test(n))
|
|
542
|
-
return () => Ie(br(Ir(r, a.trim())), !a.includes("@@"));
|
|
543
|
-
if (Hr.test(a))
|
|
544
|
-
return (i) => wa(a, i);
|
|
545
|
-
}
|
|
546
|
-
var Da = xa;
|
|
547
|
-
function Ta(e, t) {
|
|
548
|
-
let { node: r } = e, n = O(r);
|
|
549
|
-
if (r.fullName === "class" && !t.parentParser && !n.includes("{{"))
|
|
550
|
-
return () => n.trim().split(/\s+/u).join(" ");
|
|
551
|
-
}
|
|
552
|
-
var Ba = Ta;
|
|
553
|
-
function Bt(e) {
|
|
554
|
-
return e === " " || e === `
|
|
555
|
-
` || e === "\f" || e === "\r" || e === " ";
|
|
556
|
-
}
|
|
557
|
-
var La = /^[ \t\n\r\u000c]+/, Fa = /^[, \t\n\r\u000c]+/, qa = /^[^ \t\n\r\u000c]+/, Na = /[,]+$/, Lt = /^\d+$/, Ia = /^-?(?:[0-9]+|[0-9]*\.[0-9]+)(?:[eE][+-]?[0-9]+)?$/;
|
|
558
|
-
function Pa(e) {
|
|
559
|
-
let t = e.length, r, n, a, i, s, u = 0, o;
|
|
560
|
-
function p(m) {
|
|
561
|
-
let C, w = m.exec(e.substring(u));
|
|
562
|
-
if (w)
|
|
563
|
-
return [C] = w, u += C.length, C;
|
|
564
|
-
}
|
|
565
|
-
let l = [];
|
|
566
|
-
for (; ; ) {
|
|
567
|
-
if (p(Fa), u >= t) {
|
|
568
|
-
if (l.length === 0)
|
|
569
|
-
throw new Error("Must contain one or more image candidate strings.");
|
|
570
|
-
return l;
|
|
571
|
-
}
|
|
572
|
-
o = u, r = p(qa), n = [], r.slice(-1) === "," ? (r = r.replace(Na, ""), v()) : f();
|
|
573
|
-
}
|
|
574
|
-
function f() {
|
|
575
|
-
for (p(La), a = "", i = "in descriptor"; ; ) {
|
|
576
|
-
if (s = e.charAt(u), i === "in descriptor")
|
|
577
|
-
if (Bt(s))
|
|
578
|
-
a && (n.push(a), a = "", i = "after descriptor");
|
|
579
|
-
else if (s === ",") {
|
|
580
|
-
u += 1, a && n.push(a), v();
|
|
581
|
-
return;
|
|
582
|
-
} else if (s === "(")
|
|
583
|
-
a += s, i = "in parens";
|
|
584
|
-
else if (s === "") {
|
|
585
|
-
a && n.push(a), v();
|
|
586
|
-
return;
|
|
587
|
-
} else
|
|
588
|
-
a += s;
|
|
589
|
-
else if (i === "in parens")
|
|
590
|
-
if (s === ")")
|
|
591
|
-
a += s, i = "in descriptor";
|
|
592
|
-
else if (s === "") {
|
|
593
|
-
n.push(a), v();
|
|
594
|
-
return;
|
|
595
|
-
} else
|
|
596
|
-
a += s;
|
|
597
|
-
else if (i === "after descriptor" && !Bt(s))
|
|
598
|
-
if (s === "") {
|
|
599
|
-
v();
|
|
600
|
-
return;
|
|
601
|
-
} else
|
|
602
|
-
i = "in descriptor", u -= 1;
|
|
603
|
-
u += 1;
|
|
604
|
-
}
|
|
605
|
-
}
|
|
606
|
-
function v() {
|
|
607
|
-
let m = !1, C, w, E, x, c = {}, g, A, y, T, G;
|
|
608
|
-
for (x = 0; x < n.length; x++)
|
|
609
|
-
g = n[x], A = g[g.length - 1], y = g.substring(0, g.length - 1), T = parseInt(y, 10), G = parseFloat(y), Lt.test(y) && A === "w" ? ((C || w) && (m = !0), T === 0 ? m = !0 : C = T) : Ia.test(y) && A === "x" ? ((C || w || E) && (m = !0), G < 0 ? m = !0 : w = G) : Lt.test(y) && A === "h" ? ((E || w) && (m = !0), T === 0 ? m = !0 : E = T) : m = !0;
|
|
610
|
-
if (!m)
|
|
611
|
-
c.source = { value: r, startOffset: o }, C && (c.width = { value: C }), w && (c.density = { value: w }), E && (c.height = { value: E }), l.push(c);
|
|
612
|
-
else
|
|
613
|
-
throw new Error(`Invalid srcset descriptor found in "${e}" at "${g}".`);
|
|
614
|
-
}
|
|
615
|
-
}
|
|
616
|
-
var Ha = Pa;
|
|
617
|
-
function Ma(e) {
|
|
618
|
-
if (e.node.fullName === "srcset" && (e.parent.fullName === "img" || e.parent.fullName === "source"))
|
|
619
|
-
return () => Ua(O(e.node));
|
|
620
|
-
}
|
|
621
|
-
var Mr = { width: "w", height: "h", density: "x" }, Ra = Object.keys(Mr);
|
|
622
|
-
function Ua(e) {
|
|
623
|
-
let t = Ha(e), r = Ra.filter((l) => t.some((f) => Object.prototype.hasOwnProperty.call(f, l)));
|
|
624
|
-
if (r.length > 1)
|
|
625
|
-
throw new Error("Mixed descriptor in srcset is not supported");
|
|
626
|
-
let [n] = r, a = Mr[n], i = t.map((l) => l.source.value), s = Math.max(...i.map((l) => l.length)), u = t.map((l) => l[n] ? String(l[n].value) : ""), o = u.map((l) => {
|
|
627
|
-
let f = l.indexOf(".");
|
|
628
|
-
return f === -1 ? l.length : f;
|
|
629
|
-
}), p = Math.max(...o);
|
|
630
|
-
return Ie(Z([",", _], i.map((l, f) => {
|
|
631
|
-
let v = [l], m = u[f];
|
|
632
|
-
if (m) {
|
|
633
|
-
let C = s - l.length + 1, w = p - o[f], E = " ".repeat(C + w);
|
|
634
|
-
v.push(xe(E, " "), m + a);
|
|
635
|
-
}
|
|
636
|
-
return v;
|
|
637
|
-
})));
|
|
638
|
-
}
|
|
639
|
-
var Va = Ma;
|
|
640
|
-
function Oa(e, t) {
|
|
641
|
-
let { node: r } = e, n = O(e.node).trim();
|
|
642
|
-
if (r.fullName === "style" && !t.parentParser && !n.includes("{{"))
|
|
643
|
-
return async (a) => Ie(await a(n, { parser: "css", __isHTMLStyleAttribute: !0 }));
|
|
644
|
-
}
|
|
645
|
-
var $e = /* @__PURE__ */ new WeakMap();
|
|
646
|
-
function Wa(e, t) {
|
|
647
|
-
let { root: r } = e;
|
|
648
|
-
return $e.has(r) || $e.set(r, r.children.some((n) => Pr(n, t) && ["ts", "typescript"].includes(n.attrMap.lang))), $e.get(r);
|
|
649
|
-
}
|
|
650
|
-
var gt = Wa;
|
|
651
|
-
function za(e, t, r) {
|
|
652
|
-
let { node: n } = r, a = O(n);
|
|
653
|
-
return H(`type T<${a}> = any`, e, { parser: "babel-ts", __isEmbeddedTypescriptGenericParameters: !0 }, ee);
|
|
654
|
-
}
|
|
655
|
-
function $a(e, t, { parseWithTs: r }) {
|
|
656
|
-
return H(`function _(${e}) {}`, t, { parser: r ? "babel-ts" : "babel", __isVueBindings: !0 });
|
|
657
|
-
}
|
|
658
|
-
async function ja(e, t, r, n) {
|
|
659
|
-
let a = O(r.node), { left: i, operator: s, right: u } = Ga(a), o = gt(r, n);
|
|
660
|
-
return [k(await H(`function _(${i}) {}`, e, { parser: o ? "babel-ts" : "babel", __isVueForBindingLeft: !0 })), " ", s, " ", await H(u, e, { parser: o ? "__ts_expression" : "__js_expression" })];
|
|
661
|
-
}
|
|
662
|
-
function Ga(e) {
|
|
663
|
-
let t = /(.*?)\s+(in|of)\s+(.*)/su, r = /,([^,\]}]*)(?:,([^,\]}]*))?$/u, n = /^\(|\)$/gu, a = e.match(t);
|
|
664
|
-
if (!a)
|
|
665
|
-
return;
|
|
666
|
-
let i = {};
|
|
667
|
-
if (i.for = a[3].trim(), !i.for)
|
|
668
|
-
return;
|
|
669
|
-
let s = L(!1, a[1].trim(), n, ""), u = s.match(r);
|
|
670
|
-
u ? (i.alias = s.replace(r, ""), i.iterator1 = u[1].trim(), u[2] && (i.iterator2 = u[2].trim())) : i.alias = s;
|
|
671
|
-
let o = [i.alias, i.iterator1, i.iterator2];
|
|
672
|
-
if (!o.some((p, l) => !p && (l === 0 || o.slice(l + 1).some(Boolean))))
|
|
673
|
-
return { left: o.filter(Boolean).join(","), operator: a[2], right: i.for };
|
|
674
|
-
}
|
|
675
|
-
function Ka(e, t) {
|
|
676
|
-
if (t.parser !== "vue")
|
|
677
|
-
return;
|
|
678
|
-
let { node: r } = e, n = r.fullName;
|
|
679
|
-
if (n === "v-for")
|
|
680
|
-
return ja;
|
|
681
|
-
if (n === "generic" && Pr(r.parent, t))
|
|
682
|
-
return za;
|
|
683
|
-
let a = O(r), i = gt(e, t);
|
|
684
|
-
if (ba(r) || _a(r, t))
|
|
685
|
-
return (s) => $a(a, s, { parseWithTs: i });
|
|
686
|
-
if (n.startsWith("@") || n.startsWith("v-on:"))
|
|
687
|
-
return (s) => Xa(a, s, { parseWithTs: i });
|
|
688
|
-
if (n.startsWith(":") || n.startsWith(".") || n.startsWith("v-bind:"))
|
|
689
|
-
return (s) => Ya(a, s, { parseWithTs: i });
|
|
690
|
-
if (n.startsWith("v-"))
|
|
691
|
-
return (s) => Rr(a, s, { parseWithTs: i });
|
|
692
|
-
}
|
|
693
|
-
async function Xa(e, t, { parseWithTs: r }) {
|
|
694
|
-
var n;
|
|
695
|
-
try {
|
|
696
|
-
return await Rr(e, t, { parseWithTs: r });
|
|
697
|
-
} catch (a) {
|
|
698
|
-
if (((n = a.cause) == null ? void 0 : n.code) !== "BABEL_PARSER_SYNTAX_ERROR")
|
|
699
|
-
throw a;
|
|
700
|
-
}
|
|
701
|
-
return H(e, t, { parser: r ? "__vue_ts_event_binding" : "__vue_event_binding" }, ee);
|
|
702
|
-
}
|
|
703
|
-
function Ya(e, t, { parseWithTs: r }) {
|
|
704
|
-
return H(e, t, { parser: r ? "__vue_ts_expression" : "__vue_expression" }, ee);
|
|
705
|
-
}
|
|
706
|
-
function Rr(e, t, { parseWithTs: r }) {
|
|
707
|
-
return H(e, t, { parser: r ? "__ts_expression" : "__js_expression" }, ee);
|
|
708
|
-
}
|
|
709
|
-
var Ja = Ka;
|
|
710
|
-
function Qa(e, t) {
|
|
711
|
-
let { node: r } = e;
|
|
712
|
-
if (r.value) {
|
|
713
|
-
if (/^PRETTIER_HTML_PLACEHOLDER_\d+_\d+_IN_JS$/u.test(t.originalText.slice(r.valueSpan.start.offset, r.valueSpan.end.offset)) || t.parser === "lwc" && r.value.startsWith("{") && r.value.endsWith("}"))
|
|
714
|
-
return [r.rawName, "=", r.value];
|
|
715
|
-
for (let n of [Va, Oa, Ba, Ja, Da]) {
|
|
716
|
-
let a = n(e, t);
|
|
717
|
-
if (a)
|
|
718
|
-
return Za(a);
|
|
719
|
-
}
|
|
720
|
-
}
|
|
721
|
-
}
|
|
722
|
-
function Za(e) {
|
|
723
|
-
return async (t, r, n, a) => {
|
|
724
|
-
let i = await e(t, r, n, a);
|
|
725
|
-
if (i)
|
|
726
|
-
return i = Sr(i, (s) => typeof s == "string" ? L(!1, s, '"', """) : s), [n.node.rawName, '="', k(i), '"'];
|
|
727
|
-
};
|
|
728
|
-
}
|
|
729
|
-
var ei = Qa, Ur = new Proxy(() => {
|
|
730
|
-
}, { get: () => Ur }), Vr = Ur;
|
|
731
|
-
function ti(e) {
|
|
732
|
-
return Array.isArray(e) && e.length > 0;
|
|
733
|
-
}
|
|
734
|
-
var ft = ti;
|
|
735
|
-
function fe(e) {
|
|
736
|
-
return e.sourceSpan.start.offset;
|
|
737
|
-
}
|
|
738
|
-
function ve(e) {
|
|
739
|
-
return e.sourceSpan.end.offset;
|
|
740
|
-
}
|
|
741
|
-
function Je(e, t) {
|
|
742
|
-
return [e.isSelfClosing ? "" : ri(e, t), oe(e, t)];
|
|
743
|
-
}
|
|
744
|
-
function ri(e, t) {
|
|
745
|
-
return e.lastChild && he(e.lastChild) ? "" : [ni(e, t), vt(e, t)];
|
|
746
|
-
}
|
|
747
|
-
function oe(e, t) {
|
|
748
|
-
return (e.next ? $(e.next) : Se(e.parent)) ? "" : [Ce(e, t), z(e, t)];
|
|
749
|
-
}
|
|
750
|
-
function ni(e, t) {
|
|
751
|
-
return Se(e) ? Ce(e.lastChild, t) : "";
|
|
752
|
-
}
|
|
753
|
-
function z(e, t) {
|
|
754
|
-
return he(e) ? vt(e.parent, t) : Re(e) ? Ct(e.next, t) : "";
|
|
755
|
-
}
|
|
756
|
-
function vt(e, t) {
|
|
757
|
-
if (Vr.ok(!e.isSelfClosing), Or(e, t))
|
|
758
|
-
return "";
|
|
759
|
-
switch (e.type) {
|
|
760
|
-
case "ieConditionalComment":
|
|
761
|
-
return "<!";
|
|
762
|
-
case "element":
|
|
763
|
-
if (e.hasHtmComponentClosingTag)
|
|
764
|
-
return "<//";
|
|
765
|
-
default:
|
|
766
|
-
return `</${e.rawName}`;
|
|
767
|
-
}
|
|
768
|
-
}
|
|
769
|
-
function Ce(e, t) {
|
|
770
|
-
if (Or(e, t))
|
|
771
|
-
return "";
|
|
772
|
-
switch (e.type) {
|
|
773
|
-
case "ieConditionalComment":
|
|
774
|
-
case "ieConditionalEndComment":
|
|
775
|
-
return "[endif]-->";
|
|
776
|
-
case "ieConditionalStartComment":
|
|
777
|
-
return "]><!-->";
|
|
778
|
-
case "interpolation":
|
|
779
|
-
return "}}";
|
|
780
|
-
case "angularIcuExpression":
|
|
781
|
-
return "}";
|
|
782
|
-
case "element":
|
|
783
|
-
if (e.isSelfClosing)
|
|
784
|
-
return "/>";
|
|
785
|
-
default:
|
|
786
|
-
return ">";
|
|
787
|
-
}
|
|
788
|
-
}
|
|
789
|
-
function Or(e, t) {
|
|
790
|
-
return !e.isSelfClosing && !e.endSourceSpan && (He(e) || Ar(e.parent, t));
|
|
791
|
-
}
|
|
792
|
-
function $(e) {
|
|
793
|
-
return e.prev && e.prev.type !== "docType" && e.type !== "angularControlFlowBlock" && !q(e.prev) && e.isLeadingSpaceSensitive && !e.hasLeadingSpaces;
|
|
794
|
-
}
|
|
795
|
-
function Se(e) {
|
|
796
|
-
var t;
|
|
797
|
-
return ((t = e.lastChild) == null ? void 0 : t.isTrailingSpaceSensitive) && !e.lastChild.hasTrailingSpaces && !q(ht(e.lastChild)) && !J(e);
|
|
798
|
-
}
|
|
799
|
-
function he(e) {
|
|
800
|
-
return !e.next && !e.hasTrailingSpaces && e.isTrailingSpaceSensitive && q(ht(e));
|
|
801
|
-
}
|
|
802
|
-
function Re(e) {
|
|
803
|
-
return e.next && !q(e.next) && q(e) && e.isTrailingSpaceSensitive && !e.hasTrailingSpaces;
|
|
804
|
-
}
|
|
805
|
-
function ai(e) {
|
|
806
|
-
let t = e.trim().match(/^prettier-ignore-attribute(?:\s+(.+))?$/su);
|
|
807
|
-
return t ? t[1] ? t[1].split(/\s+/u) : !0 : !1;
|
|
808
|
-
}
|
|
809
|
-
function Ue(e) {
|
|
810
|
-
return !e.prev && e.isLeadingSpaceSensitive && !e.hasLeadingSpaces;
|
|
811
|
-
}
|
|
812
|
-
function ii(e, t, r) {
|
|
813
|
-
var n;
|
|
814
|
-
let { node: a } = e;
|
|
815
|
-
if (!ft(a.attrs))
|
|
816
|
-
return a.isSelfClosing ? " " : "";
|
|
817
|
-
let i = ((n = a.prev) == null ? void 0 : n.type) === "comment" && ai(a.prev.value), s = typeof i == "boolean" ? () => i : Array.isArray(i) ? (f) => i.includes(f.rawName) : () => !1, u = e.map(({ node: f }) => s(f) ? P(t.originalText.slice(fe(f), ve(f))) : r(), "attrs"), o = a.type === "element" && a.fullName === "script" && a.attrs.length === 1 && a.attrs[0].fullName === "src" && a.children.length === 0, p = t.singleAttributePerLine && a.attrs.length > 1 && !te(a, t) ? S : _, l = [M([o ? " " : _, Z(p, u)])];
|
|
818
|
-
return a.firstChild && Ue(a.firstChild) || a.isSelfClosing && Se(a.parent) || o ? l.push(a.isSelfClosing ? " " : "") : l.push(t.bracketSameLine ? a.isSelfClosing ? " " : "" : a.isSelfClosing ? _ : D), l;
|
|
819
|
-
}
|
|
820
|
-
function si(e) {
|
|
821
|
-
return e.firstChild && Ue(e.firstChild) ? "" : St(e);
|
|
822
|
-
}
|
|
823
|
-
function Qe(e, t, r) {
|
|
824
|
-
let { node: n } = e;
|
|
825
|
-
return [le(n, t), ii(e, t, r), n.isSelfClosing ? "" : si(n)];
|
|
826
|
-
}
|
|
827
|
-
function le(e, t) {
|
|
828
|
-
return e.prev && Re(e.prev) ? "" : [j(e, t), Ct(e, t)];
|
|
829
|
-
}
|
|
830
|
-
function j(e, t) {
|
|
831
|
-
return Ue(e) ? St(e.parent) : $(e) ? Ce(e.prev, t) : "";
|
|
832
|
-
}
|
|
833
|
-
var Ft = "<!doctype";
|
|
834
|
-
function Ct(e, t) {
|
|
835
|
-
switch (e.type) {
|
|
836
|
-
case "ieConditionalComment":
|
|
837
|
-
case "ieConditionalStartComment":
|
|
838
|
-
return `<!--[if ${e.condition}`;
|
|
839
|
-
case "ieConditionalEndComment":
|
|
840
|
-
return "<!--<!";
|
|
841
|
-
case "interpolation":
|
|
842
|
-
return "{{";
|
|
843
|
-
case "docType": {
|
|
844
|
-
if (e.value === "html") {
|
|
845
|
-
let r = t.filepath ?? "";
|
|
846
|
-
if (/\.html?$/u.test(r))
|
|
847
|
-
return Ft;
|
|
848
|
-
}
|
|
849
|
-
return t.originalText.slice(fe(e), ve(e)).slice(0, Ft.length);
|
|
850
|
-
}
|
|
851
|
-
case "angularIcuExpression":
|
|
852
|
-
return "{";
|
|
853
|
-
case "element":
|
|
854
|
-
if (e.condition)
|
|
855
|
-
return `<!--[if ${e.condition}]><!--><${e.rawName}`;
|
|
856
|
-
default:
|
|
857
|
-
return `<${e.rawName}`;
|
|
858
|
-
}
|
|
859
|
-
}
|
|
860
|
-
function St(e) {
|
|
861
|
-
switch (Vr.ok(!e.isSelfClosing), e.type) {
|
|
862
|
-
case "ieConditionalComment":
|
|
863
|
-
return "]>";
|
|
864
|
-
case "element":
|
|
865
|
-
if (e.condition)
|
|
866
|
-
return "><!--<![endif]-->";
|
|
867
|
-
default:
|
|
868
|
-
return ">";
|
|
869
|
-
}
|
|
870
|
-
}
|
|
871
|
-
function ui(e, t) {
|
|
872
|
-
if (!e.endSourceSpan)
|
|
873
|
-
return "";
|
|
874
|
-
let r = e.startSourceSpan.end.offset;
|
|
875
|
-
e.firstChild && Ue(e.firstChild) && (r -= St(e).length);
|
|
876
|
-
let n = e.endSourceSpan.start.offset;
|
|
877
|
-
return e.lastChild && he(e.lastChild) ? n += vt(e, t).length : Se(e) && (n -= Ce(e.lastChild, t).length), t.originalText.slice(r, n);
|
|
878
|
-
}
|
|
879
|
-
var Wr = ui, oi = /* @__PURE__ */ new Set(["if", "else if", "for", "switch", "case"]);
|
|
880
|
-
function li(e, t) {
|
|
881
|
-
let { node: r } = e;
|
|
882
|
-
switch (r.type) {
|
|
883
|
-
case "element":
|
|
884
|
-
if (U(r) || r.type === "interpolation")
|
|
885
|
-
return;
|
|
886
|
-
if (!r.isSelfClosing && dt(r, t)) {
|
|
887
|
-
let n = Tt(r, t);
|
|
888
|
-
return n ? async (a, i) => {
|
|
889
|
-
let s = Wr(r, t), u = /^\s*$/u.test(s), o = "";
|
|
890
|
-
return u || (o = await a(wr(s), { parser: n, __embeddedInHtml: !0 }), u = o === ""), [j(r, t), k(Qe(e, t, i)), u ? "" : S, o, u ? "" : S, Je(r, t), z(r, t)];
|
|
891
|
-
} : void 0;
|
|
892
|
-
}
|
|
893
|
-
break;
|
|
894
|
-
case "text":
|
|
895
|
-
if (U(r.parent)) {
|
|
896
|
-
let n = Tt(r.parent, t);
|
|
897
|
-
if (n)
|
|
898
|
-
return async (a) => {
|
|
899
|
-
let i = n === "markdown" ? qr(r.value.replace(/^[^\S\n]*\n/u, "")) : r.value, s = { parser: n, __embeddedInHtml: !0 };
|
|
900
|
-
if (t.parser === "html" && n === "babel") {
|
|
901
|
-
let u = "script", { attrMap: o } = r.parent;
|
|
902
|
-
o && (o.type === "module" || o.type === "text/babel" && o["data-type"] === "module") && (u = "module"), s.__babelSourceType = u;
|
|
903
|
-
}
|
|
904
|
-
return [me, j(r, t), await a(i, s), z(r, t)];
|
|
905
|
-
};
|
|
906
|
-
} else if (r.parent.type === "interpolation")
|
|
907
|
-
return async (n) => {
|
|
908
|
-
let a = { __isInHtmlInterpolation: !0, __embeddedInHtml: !0 };
|
|
909
|
-
return t.parser === "angular" ? a.parser = "__ng_interpolation" : t.parser === "vue" ? a.parser = gt(e, t) ? "__vue_ts_expression" : "__vue_expression" : a.parser = "__js_expression", [M([_, await n(r.value, a)]), r.parent.next && $(r.parent.next) ? " " : _];
|
|
910
|
-
};
|
|
911
|
-
break;
|
|
912
|
-
case "attribute":
|
|
913
|
-
return ei(e, t);
|
|
914
|
-
case "front-matter":
|
|
915
|
-
return (n) => Vn(r, n);
|
|
916
|
-
case "angularControlFlowBlockParameters":
|
|
917
|
-
return oi.has(e.parent.name) ? Wn : void 0;
|
|
918
|
-
case "angularLetDeclarationInitializer":
|
|
919
|
-
return (n) => H(r.value, n, { parser: "__ng_binding", __isInHtmlAttribute: !1 });
|
|
920
|
-
}
|
|
921
|
-
}
|
|
922
|
-
var ci = li, ne = null;
|
|
923
|
-
function ce(e) {
|
|
924
|
-
if (ne !== null && typeof ne.property) {
|
|
925
|
-
let t = ne;
|
|
926
|
-
return ne = ce.prototype = null, t;
|
|
927
|
-
}
|
|
928
|
-
return ne = ce.prototype = e ?? /* @__PURE__ */ Object.create(null), new ce();
|
|
929
|
-
}
|
|
930
|
-
var pi = 10;
|
|
931
|
-
for (let e = 0; e <= pi; e++)
|
|
932
|
-
ce();
|
|
933
|
-
function hi(e) {
|
|
934
|
-
return ce(e);
|
|
935
|
-
}
|
|
936
|
-
function di(e, t = "type") {
|
|
937
|
-
hi(e);
|
|
938
|
-
function r(n) {
|
|
939
|
-
let a = n[t], i = e[a];
|
|
940
|
-
if (!Array.isArray(i))
|
|
941
|
-
throw Object.assign(new Error(`Missing visitor keys for '${a}'.`), { node: n });
|
|
942
|
-
return i;
|
|
943
|
-
}
|
|
944
|
-
return r;
|
|
945
|
-
}
|
|
946
|
-
var mi = di, gi = { "front-matter": [], root: ["children"], element: ["attrs", "children"], ieConditionalComment: ["children"], ieConditionalStartComment: [], ieConditionalEndComment: [], interpolation: ["children"], text: ["children"], docType: [], comment: [], attribute: [], cdata: [], angularControlFlowBlock: ["children", "parameters"], angularControlFlowBlockParameters: ["children"], angularControlFlowBlockParameter: [], angularLetDeclaration: ["init"], angularLetDeclarationInitializer: [], angularIcuExpression: ["cases"], angularIcuCase: ["expression"] }, fi = gi, vi = mi(fi), Ci = vi;
|
|
947
|
-
function Si(e) {
|
|
948
|
-
return /^\s*<!--\s*@(?:format|prettier)\s*-->/u.test(e);
|
|
949
|
-
}
|
|
950
|
-
function yi(e) {
|
|
951
|
-
return `<!-- @format -->
|
|
952
|
-
|
|
953
|
-
` + e;
|
|
954
|
-
}
|
|
955
|
-
var bi = /* @__PURE__ */ new Map([["if", /* @__PURE__ */ new Set(["else if", "else"])], ["else if", /* @__PURE__ */ new Set(["else if", "else"])], ["for", /* @__PURE__ */ new Set(["empty"])], ["defer", /* @__PURE__ */ new Set(["placeholder", "error", "loading"])], ["placeholder", /* @__PURE__ */ new Set(["placeholder", "error", "loading"])], ["error", /* @__PURE__ */ new Set(["placeholder", "error", "loading"])], ["loading", /* @__PURE__ */ new Set(["placeholder", "error", "loading"])]]);
|
|
956
|
-
function zr(e) {
|
|
957
|
-
let t = ve(e);
|
|
958
|
-
return e.type === "element" && !e.endSourceSpan && ft(e.children) ? Math.max(t, zr(de(!1, e.children, -1))) : t;
|
|
959
|
-
}
|
|
960
|
-
function ae(e, t, r) {
|
|
961
|
-
let n = e.node;
|
|
962
|
-
if (He(n)) {
|
|
963
|
-
let a = zr(n);
|
|
964
|
-
return [j(n, t), P(R.trimEnd(t.originalText.slice(fe(n) + (n.prev && Re(n.prev) ? Ct(n).length : 0), a - (n.next && $(n.next) ? Ce(n, t).length : 0)))), z(n, t)];
|
|
965
|
-
}
|
|
966
|
-
return r();
|
|
967
|
-
}
|
|
968
|
-
function _e(e, t) {
|
|
969
|
-
return q(e) && q(t) ? e.isTrailingSpaceSensitive ? e.hasTrailingSpaces ? ze(t) ? S : _ : "" : ze(t) ? S : D : Re(e) && (He(t) || t.firstChild || t.isSelfClosing || t.type === "element" && t.attrs.length > 0) || e.type === "element" && e.isSelfClosing && $(t) ? "" : !t.isLeadingSpaceSensitive || ze(t) || $(t) && e.lastChild && he(e.lastChild) && e.lastChild.lastChild && he(e.lastChild.lastChild) ? S : t.hasLeadingSpaces ? _ : D;
|
|
970
|
-
}
|
|
971
|
-
function yt(e, t, r) {
|
|
972
|
-
let { node: n } = e;
|
|
973
|
-
if (Er(n))
|
|
974
|
-
return [me, ...e.map((i) => {
|
|
975
|
-
let s = i.node, u = s.prev ? _e(s.prev, s) : "";
|
|
976
|
-
return [u ? [u, be(s.prev) ? S : ""] : "", ae(i, t, r)];
|
|
977
|
-
}, "children")];
|
|
978
|
-
let a = n.children.map(() => Symbol(""));
|
|
979
|
-
return e.map((i, s) => {
|
|
980
|
-
let u = i.node;
|
|
981
|
-
if (q(u)) {
|
|
982
|
-
if (u.prev && q(u.prev)) {
|
|
983
|
-
let C = _e(u.prev, u);
|
|
984
|
-
if (C)
|
|
985
|
-
return be(u.prev) ? [S, S, ae(i, t, r)] : [C, ae(i, t, r)];
|
|
986
|
-
}
|
|
987
|
-
return ae(i, t, r);
|
|
988
|
-
}
|
|
989
|
-
let o = [], p = [], l = [], f = [], v = u.prev ? _e(u.prev, u) : "", m = u.next ? _e(u, u.next) : "";
|
|
990
|
-
return v && (be(u.prev) ? o.push(S, S) : v === S ? o.push(S) : q(u.prev) ? p.push(v) : p.push(xe("", D, { groupId: a[s - 1] }))), m && (be(u) ? q(u.next) && f.push(S, S) : m === S ? q(u.next) && f.push(S) : l.push(m)), [...o, k([...p, k([ae(i, t, r), ...l], { id: a[s] })]), ...f];
|
|
991
|
-
}, "children");
|
|
992
|
-
}
|
|
993
|
-
function _i(e, t, r) {
|
|
994
|
-
let { node: n } = e, a = [];
|
|
995
|
-
wi(e) && a.push("} "), a.push("@", n.name), n.parameters && a.push(" (", k(r("parameters")), ")"), a.push(" {");
|
|
996
|
-
let i = $r(n);
|
|
997
|
-
return n.children.length > 0 ? (n.firstChild.hasLeadingSpaces = !0, n.lastChild.hasTrailingSpaces = !0, a.push(M([S, yt(e, t, r)])), i && a.push(S, "}")) : i && a.push("}"), k(a, { shouldBreak: !0 });
|
|
998
|
-
}
|
|
999
|
-
function $r(e) {
|
|
1000
|
-
var t, r;
|
|
1001
|
-
return !(((t = e.next) == null ? void 0 : t.type) === "angularControlFlowBlock" && (r = bi.get(e.name)) != null && r.has(e.next.name));
|
|
1002
|
-
}
|
|
1003
|
-
function wi(e) {
|
|
1004
|
-
let { previous: t } = e;
|
|
1005
|
-
return (t == null ? void 0 : t.type) === "angularControlFlowBlock" && !He(t) && !$r(t);
|
|
1006
|
-
}
|
|
1007
|
-
function Ai(e, t, r) {
|
|
1008
|
-
return [M([D, Z([";", _], e.map(r, "children"))]), D];
|
|
1009
|
-
}
|
|
1010
|
-
function ki(e, t, r) {
|
|
1011
|
-
let { node: n } = e;
|
|
1012
|
-
return [le(n, t), k([n.switchValue.trim(), ", ", n.clause, n.cases.length > 0 ? [",", M([_, Z(_, e.map(r, "cases"))])] : "", D]), oe(n, t)];
|
|
1013
|
-
}
|
|
1014
|
-
function Ei(e, t, r) {
|
|
1015
|
-
let { node: n } = e;
|
|
1016
|
-
return [n.value, " {", k([M([D, e.map(({ node: a, isLast: i }) => {
|
|
1017
|
-
let s = [r()];
|
|
1018
|
-
return a.type === "text" && (a.hasLeadingSpaces && s.unshift(_), a.hasTrailingSpaces && !i && s.push(_)), s;
|
|
1019
|
-
}, "expression")]), D]), "}"];
|
|
1020
|
-
}
|
|
1021
|
-
function xi(e, t, r) {
|
|
1022
|
-
let { node: n } = e;
|
|
1023
|
-
if (Ar(n, t))
|
|
1024
|
-
return [j(n, t), k(Qe(e, t, r)), P(Wr(n, t)), ...Je(n, t), z(n, t)];
|
|
1025
|
-
let a = n.children.length === 1 && (n.firstChild.type === "interpolation" || n.firstChild.type === "angularIcuExpression") && n.firstChild.isLeadingSpaceSensitive && !n.firstChild.hasLeadingSpaces && n.lastChild.isTrailingSpaceSensitive && !n.lastChild.hasTrailingSpaces, i = Symbol("element-attr-group-id"), s = (l) => k([k(Qe(e, t, r), { id: i }), l, Je(n, t)]), u = (l) => a ? wn(l, { groupId: i }) : (U(n) || Me(n, t)) && n.parent.type === "root" && t.parser === "vue" && !t.vueIndentScriptAndStyle ? l : M(l), o = () => a ? xe(D, "", { groupId: i }) : n.firstChild.hasLeadingSpaces && n.firstChild.isLeadingSpaceSensitive ? _ : n.firstChild.type === "text" && n.isWhitespaceSensitive && n.isIndentationSensitive ? bn(D) : D, p = () => (n.next ? $(n.next) : Se(n.parent)) ? n.lastChild.hasTrailingSpaces && n.lastChild.isTrailingSpaceSensitive ? " " : "" : a ? xe(D, "", { groupId: i }) : n.lastChild.hasTrailingSpaces && n.lastChild.isTrailingSpaceSensitive ? _ : (n.lastChild.type === "comment" || n.lastChild.type === "text" && n.isWhitespaceSensitive && n.isIndentationSensitive) && new RegExp(`\\n[\\t ]{${t.tabWidth * (e.ancestors.length - 1)}}$`, "u").test(n.lastChild.value) ? "" : D;
|
|
1026
|
-
return n.children.length === 0 ? s(n.hasDanglingSpaces && n.isDanglingSpaceSensitive ? _ : "") : s([sa(n) ? me : "", u([o(), yt(e, t, r)]), p()]);
|
|
1027
|
-
}
|
|
1028
|
-
function De(e) {
|
|
1029
|
-
return e >= 9 && e <= 32 || e == 160;
|
|
1030
|
-
}
|
|
1031
|
-
function bt(e) {
|
|
1032
|
-
return 48 <= e && e <= 57;
|
|
1033
|
-
}
|
|
1034
|
-
function Te(e) {
|
|
1035
|
-
return e >= 97 && e <= 122 || e >= 65 && e <= 90;
|
|
1036
|
-
}
|
|
1037
|
-
function Di(e) {
|
|
1038
|
-
return e >= 97 && e <= 102 || e >= 65 && e <= 70 || bt(e);
|
|
1039
|
-
}
|
|
1040
|
-
function _t(e) {
|
|
1041
|
-
return e === 10 || e === 13;
|
|
1042
|
-
}
|
|
1043
|
-
function qt(e) {
|
|
1044
|
-
return 48 <= e && e <= 55;
|
|
1045
|
-
}
|
|
1046
|
-
function je(e) {
|
|
1047
|
-
return e === 39 || e === 34 || e === 96;
|
|
1048
|
-
}
|
|
1049
|
-
var Ti = /-+([a-z0-9])/g;
|
|
1050
|
-
function Bi(e) {
|
|
1051
|
-
return e.replace(Ti, (...t) => t[1].toUpperCase());
|
|
1052
|
-
}
|
|
1053
|
-
var Ze = class jr {
|
|
1054
|
-
constructor(t, r, n, a) {
|
|
1055
|
-
this.file = t, this.offset = r, this.line = n, this.col = a;
|
|
1056
|
-
}
|
|
1057
|
-
toString() {
|
|
1058
|
-
return this.offset != null ? `${this.file.url}@${this.line}:${this.col}` : this.file.url;
|
|
1059
|
-
}
|
|
1060
|
-
moveBy(t) {
|
|
1061
|
-
let r = this.file.content, n = r.length, a = this.offset, i = this.line, s = this.col;
|
|
1062
|
-
for (; a > 0 && t < 0; )
|
|
1063
|
-
if (a--, t++, r.charCodeAt(a) == 10) {
|
|
1064
|
-
i--;
|
|
1065
|
-
let u = r.substring(0, a - 1).lastIndexOf(String.fromCharCode(10));
|
|
1066
|
-
s = u > 0 ? a - u : a;
|
|
1067
|
-
} else
|
|
1068
|
-
s--;
|
|
1069
|
-
for (; a < n && t > 0; ) {
|
|
1070
|
-
let u = r.charCodeAt(a);
|
|
1071
|
-
a++, t--, u == 10 ? (i++, s = 0) : s++;
|
|
1072
|
-
}
|
|
1073
|
-
return new jr(this.file, a, i, s);
|
|
1074
|
-
}
|
|
1075
|
-
getContext(t, r) {
|
|
1076
|
-
let n = this.file.content, a = this.offset;
|
|
1077
|
-
if (a != null) {
|
|
1078
|
-
a > n.length - 1 && (a = n.length - 1);
|
|
1079
|
-
let i = a, s = 0, u = 0;
|
|
1080
|
-
for (; s < t && a > 0 && (a--, s++, !(n[a] == `
|
|
1081
|
-
` && ++u == r)); )
|
|
1082
|
-
;
|
|
1083
|
-
for (s = 0, u = 0; s < t && i < n.length - 1 && (i++, s++, !(n[i] == `
|
|
1084
|
-
` && ++u == r)); )
|
|
1085
|
-
;
|
|
1086
|
-
return { before: n.substring(a, this.offset), after: n.substring(this.offset, i + 1) };
|
|
1087
|
-
}
|
|
1088
|
-
return null;
|
|
1089
|
-
}
|
|
1090
|
-
}, Gr = class {
|
|
1091
|
-
constructor(e, t) {
|
|
1092
|
-
this.content = e, this.url = t;
|
|
1093
|
-
}
|
|
1094
|
-
}, d = class {
|
|
1095
|
-
constructor(e, t, r = e, n = null) {
|
|
1096
|
-
this.start = e, this.end = t, this.fullStart = r, this.details = n;
|
|
1097
|
-
}
|
|
1098
|
-
toString() {
|
|
1099
|
-
return this.start.file.content.substring(this.start.offset, this.end.offset);
|
|
1100
|
-
}
|
|
1101
|
-
}, Be;
|
|
1102
|
-
(function(e) {
|
|
1103
|
-
e[e.WARNING = 0] = "WARNING", e[e.ERROR = 1] = "ERROR";
|
|
1104
|
-
})(Be || (Be = {}));
|
|
1105
|
-
var Kr = class {
|
|
1106
|
-
constructor(e, t, r = Be.ERROR) {
|
|
1107
|
-
this.span = e, this.msg = t, this.level = r;
|
|
1108
|
-
}
|
|
1109
|
-
contextualMessage() {
|
|
1110
|
-
let e = this.span.start.getContext(100, 3);
|
|
1111
|
-
return e ? `${this.msg} ("${e.before}[${Be[this.level]} ->]${e.after}")` : this.msg;
|
|
1112
|
-
}
|
|
1113
|
-
toString() {
|
|
1114
|
-
let e = this.span.details ? `, ${this.span.details}` : "";
|
|
1115
|
-
return `${this.contextualMessage()}: ${this.span.start}${e}`;
|
|
1116
|
-
}
|
|
1117
|
-
}, Li = [qi, Ni, Pi, Mi, Ri, Oi, Ui, Vi, Wi, Hi];
|
|
1118
|
-
function Fi(e, t) {
|
|
1119
|
-
for (let r of Li)
|
|
1120
|
-
r(e, t);
|
|
1121
|
-
return e;
|
|
1122
|
-
}
|
|
1123
|
-
function qi(e) {
|
|
1124
|
-
e.walk((t) => {
|
|
1125
|
-
if (t.type === "element" && t.tagDefinition.ignoreFirstLf && t.children.length > 0 && t.children[0].type === "text" && t.children[0].value[0] === `
|
|
1126
|
-
`) {
|
|
1127
|
-
let r = t.children[0];
|
|
1128
|
-
r.value.length === 1 ? t.removeChild(r) : r.value = r.value.slice(1);
|
|
1129
|
-
}
|
|
1130
|
-
});
|
|
1131
|
-
}
|
|
1132
|
-
function Ni(e) {
|
|
1133
|
-
let t = (r) => {
|
|
1134
|
-
var n, a;
|
|
1135
|
-
return r.type === "element" && ((n = r.prev) == null ? void 0 : n.type) === "ieConditionalStartComment" && r.prev.sourceSpan.end.offset === r.startSourceSpan.start.offset && ((a = r.firstChild) == null ? void 0 : a.type) === "ieConditionalEndComment" && r.firstChild.sourceSpan.start.offset === r.startSourceSpan.end.offset;
|
|
1136
|
-
};
|
|
1137
|
-
e.walk((r) => {
|
|
1138
|
-
if (r.children)
|
|
1139
|
-
for (let n = 0; n < r.children.length; n++) {
|
|
1140
|
-
let a = r.children[n];
|
|
1141
|
-
if (!t(a))
|
|
1142
|
-
continue;
|
|
1143
|
-
let i = a.prev, s = a.firstChild;
|
|
1144
|
-
r.removeChild(i), n--;
|
|
1145
|
-
let u = new d(i.sourceSpan.start, s.sourceSpan.end), o = new d(u.start, a.sourceSpan.end);
|
|
1146
|
-
a.condition = i.condition, a.sourceSpan = o, a.startSourceSpan = u, a.removeChild(s);
|
|
1147
|
-
}
|
|
1148
|
-
});
|
|
1149
|
-
}
|
|
1150
|
-
function Ii(e, t, r) {
|
|
1151
|
-
e.walk((n) => {
|
|
1152
|
-
if (n.children)
|
|
1153
|
-
for (let a = 0; a < n.children.length; a++) {
|
|
1154
|
-
let i = n.children[a];
|
|
1155
|
-
if (i.type !== "text" && !t(i))
|
|
1156
|
-
continue;
|
|
1157
|
-
i.type !== "text" && (i.type = "text", i.value = r(i));
|
|
1158
|
-
let s = i.prev;
|
|
1159
|
-
!s || s.type !== "text" || (s.value += i.value, s.sourceSpan = new d(s.sourceSpan.start, i.sourceSpan.end), n.removeChild(i), a--);
|
|
1160
|
-
}
|
|
1161
|
-
});
|
|
1162
|
-
}
|
|
1163
|
-
function Pi(e) {
|
|
1164
|
-
return Ii(e, (t) => t.type === "cdata", (t) => `<![CDATA[${t.value}]]>`);
|
|
1165
|
-
}
|
|
1166
|
-
function Hi(e) {
|
|
1167
|
-
let t = (r) => {
|
|
1168
|
-
var n, a;
|
|
1169
|
-
return r.type === "element" && r.attrs.length === 0 && r.children.length === 1 && r.firstChild.type === "text" && !R.hasWhitespaceCharacter(r.children[0].value) && !r.firstChild.hasLeadingSpaces && !r.firstChild.hasTrailingSpaces && r.isLeadingSpaceSensitive && !r.hasLeadingSpaces && r.isTrailingSpaceSensitive && !r.hasTrailingSpaces && ((n = r.prev) == null ? void 0 : n.type) === "text" && ((a = r.next) == null ? void 0 : a.type) === "text";
|
|
1170
|
-
};
|
|
1171
|
-
e.walk((r) => {
|
|
1172
|
-
if (r.children)
|
|
1173
|
-
for (let n = 0; n < r.children.length; n++) {
|
|
1174
|
-
let a = r.children[n];
|
|
1175
|
-
if (!t(a))
|
|
1176
|
-
continue;
|
|
1177
|
-
let i = a.prev, s = a.next;
|
|
1178
|
-
i.value += `<${a.rawName}>` + a.firstChild.value + `</${a.rawName}>` + s.value, i.sourceSpan = new d(i.sourceSpan.start, s.sourceSpan.end), i.isTrailingSpaceSensitive = s.isTrailingSpaceSensitive, i.hasTrailingSpaces = s.hasTrailingSpaces, r.removeChild(a), n--, r.removeChild(s);
|
|
1179
|
-
}
|
|
1180
|
-
});
|
|
1181
|
-
}
|
|
1182
|
-
function Mi(e, t) {
|
|
1183
|
-
if (t.parser === "html")
|
|
1184
|
-
return;
|
|
1185
|
-
let r = /\{\{(.+?)\}\}/su;
|
|
1186
|
-
e.walk((n) => {
|
|
1187
|
-
if (ta(n))
|
|
1188
|
-
for (let a of n.children) {
|
|
1189
|
-
if (a.type !== "text")
|
|
1190
|
-
continue;
|
|
1191
|
-
let i = a.sourceSpan.start, s = null, u = a.value.split(r);
|
|
1192
|
-
for (let o = 0; o < u.length; o++, i = s) {
|
|
1193
|
-
let p = u[o];
|
|
1194
|
-
if (o % 2 === 0) {
|
|
1195
|
-
s = i.moveBy(p.length), p.length > 0 && n.insertChildBefore(a, { type: "text", value: p, sourceSpan: new d(i, s) });
|
|
1196
|
-
continue;
|
|
1197
|
-
}
|
|
1198
|
-
s = i.moveBy(p.length + 4), n.insertChildBefore(a, { type: "interpolation", sourceSpan: new d(i, s), children: p.length === 0 ? [] : [{ type: "text", value: p, sourceSpan: new d(i.moveBy(2), s.moveBy(-2)) }] });
|
|
1199
|
-
}
|
|
1200
|
-
n.removeChild(a);
|
|
1201
|
-
}
|
|
1202
|
-
});
|
|
1203
|
-
}
|
|
1204
|
-
function Ri(e) {
|
|
1205
|
-
e.walk((t) => {
|
|
1206
|
-
let r = t.$children;
|
|
1207
|
-
if (!r)
|
|
1208
|
-
return;
|
|
1209
|
-
if (r.length === 0 || r.length === 1 && r[0].type === "text" && R.trim(r[0].value).length === 0) {
|
|
1210
|
-
t.hasDanglingSpaces = r.length > 0, t.$children = [];
|
|
1211
|
-
return;
|
|
1212
|
-
}
|
|
1213
|
-
let n = ra(t), a = kr(t);
|
|
1214
|
-
if (!n)
|
|
1215
|
-
for (let i = 0; i < r.length; i++) {
|
|
1216
|
-
let s = r[i];
|
|
1217
|
-
if (s.type !== "text")
|
|
1218
|
-
continue;
|
|
1219
|
-
let { leadingWhitespace: u, text: o, trailingWhitespace: p } = Zn(s.value), l = s.prev, f = s.next;
|
|
1220
|
-
o ? (s.value = o, s.sourceSpan = new d(s.sourceSpan.start.moveBy(u.length), s.sourceSpan.end.moveBy(-p.length)), u && (l && (l.hasTrailingSpaces = !0), s.hasLeadingSpaces = !0), p && (s.hasTrailingSpaces = !0, f && (f.hasLeadingSpaces = !0))) : (t.removeChild(s), i--, (u || p) && (l && (l.hasTrailingSpaces = !0), f && (f.hasLeadingSpaces = !0)));
|
|
1221
|
-
}
|
|
1222
|
-
t.isWhitespaceSensitive = n, t.isIndentationSensitive = a;
|
|
1223
|
-
});
|
|
1224
|
-
}
|
|
1225
|
-
function Ui(e) {
|
|
1226
|
-
e.walk((t) => {
|
|
1227
|
-
t.isSelfClosing = !t.children || t.type === "element" && (t.tagDefinition.isVoid || t.endSourceSpan && t.startSourceSpan.start === t.endSourceSpan.start && t.startSourceSpan.end === t.endSourceSpan.end);
|
|
1228
|
-
});
|
|
1229
|
-
}
|
|
1230
|
-
function Vi(e, t) {
|
|
1231
|
-
e.walk((r) => {
|
|
1232
|
-
r.type === "element" && (r.hasHtmComponentClosingTag = r.endSourceSpan && /^<\s*\/\s*\/\s*>$/u.test(t.originalText.slice(r.endSourceSpan.start.offset, r.endSourceSpan.end.offset)));
|
|
1233
|
-
});
|
|
1234
|
-
}
|
|
1235
|
-
function Oi(e, t) {
|
|
1236
|
-
e.walk((r) => {
|
|
1237
|
-
r.cssDisplay = Ca(r, t);
|
|
1238
|
-
});
|
|
1239
|
-
}
|
|
1240
|
-
function Wi(e, t) {
|
|
1241
|
-
e.walk((r) => {
|
|
1242
|
-
let { children: n } = r;
|
|
1243
|
-
if (n) {
|
|
1244
|
-
if (n.length === 0) {
|
|
1245
|
-
r.isDanglingSpaceSensitive = ia(r);
|
|
1246
|
-
return;
|
|
1247
|
-
}
|
|
1248
|
-
for (let a of n)
|
|
1249
|
-
a.isLeadingSpaceSensitive = na(a, t), a.isTrailingSpaceSensitive = aa(a, t);
|
|
1250
|
-
for (let a = 0; a < n.length; a++) {
|
|
1251
|
-
let i = n[a];
|
|
1252
|
-
i.isLeadingSpaceSensitive = (a === 0 || i.prev.isTrailingSpaceSensitive) && i.isLeadingSpaceSensitive, i.isTrailingSpaceSensitive = (a === n.length - 1 || i.next.isLeadingSpaceSensitive) && i.isTrailingSpaceSensitive;
|
|
1253
|
-
}
|
|
1254
|
-
}
|
|
1255
|
-
});
|
|
1256
|
-
}
|
|
1257
|
-
var zi = Fi;
|
|
1258
|
-
function $i(e, t, r) {
|
|
1259
|
-
let { node: n } = e;
|
|
1260
|
-
switch (n.type) {
|
|
1261
|
-
case "front-matter":
|
|
1262
|
-
return P(n.raw);
|
|
1263
|
-
case "root":
|
|
1264
|
-
return t.__onHtmlRoot && t.__onHtmlRoot(n), [k(yt(e, t, r)), S];
|
|
1265
|
-
case "element":
|
|
1266
|
-
case "ieConditionalComment":
|
|
1267
|
-
return xi(e, t, r);
|
|
1268
|
-
case "angularControlFlowBlock":
|
|
1269
|
-
return _i(e, t, r);
|
|
1270
|
-
case "angularControlFlowBlockParameters":
|
|
1271
|
-
return Ai(e, t, r);
|
|
1272
|
-
case "angularControlFlowBlockParameter":
|
|
1273
|
-
return R.trim(n.expression);
|
|
1274
|
-
case "angularLetDeclaration":
|
|
1275
|
-
return k(["@let ", k([n.id, " =", k(M([_, r("init")]))]), ";"]);
|
|
1276
|
-
case "angularLetDeclarationInitializer":
|
|
1277
|
-
return n.value;
|
|
1278
|
-
case "angularIcuExpression":
|
|
1279
|
-
return ki(e, t, r);
|
|
1280
|
-
case "angularIcuCase":
|
|
1281
|
-
return Ei(e, t, r);
|
|
1282
|
-
case "ieConditionalStartComment":
|
|
1283
|
-
case "ieConditionalEndComment":
|
|
1284
|
-
return [le(n), oe(n)];
|
|
1285
|
-
case "interpolation":
|
|
1286
|
-
return [le(n, t), ...e.map(r, "children"), oe(n, t)];
|
|
1287
|
-
case "text": {
|
|
1288
|
-
if (n.parent.type === "interpolation") {
|
|
1289
|
-
let u = /\n[^\S\n]*$/u, o = u.test(n.value), p = o ? n.value.replace(u, "") : n.value;
|
|
1290
|
-
return [P(p), o ? S : ""];
|
|
1291
|
-
}
|
|
1292
|
-
let a = j(n, t), i = Ir(n), s = z(n, t);
|
|
1293
|
-
return i[0] = [a, i[0]], i.push([i.pop(), s]), br(i);
|
|
1294
|
-
}
|
|
1295
|
-
case "docType":
|
|
1296
|
-
return [k([le(n, t), " ", L(!1, n.value.replace(/^html\b/iu, "html"), /\s+/gu, " ")]), oe(n, t)];
|
|
1297
|
-
case "comment":
|
|
1298
|
-
return [j(n, t), P(t.originalText.slice(fe(n), ve(n))), z(n, t)];
|
|
1299
|
-
case "attribute": {
|
|
1300
|
-
if (n.value === null)
|
|
1301
|
-
return n.rawName;
|
|
1302
|
-
let a = Nr(n.value), i = Dn(a, '"');
|
|
1303
|
-
return [n.rawName, "=", i, P(i === '"' ? L(!1, a, '"', """) : L(!1, a, "'", "'")), i];
|
|
1304
|
-
}
|
|
1305
|
-
case "cdata":
|
|
1306
|
-
default:
|
|
1307
|
-
throw new In(n, "HTML");
|
|
1308
|
-
}
|
|
1309
|
-
}
|
|
1310
|
-
var ji = { preprocess: zi, print: $i, insertPragma: yi, massageAstNode: Rn, embed: ci, getVisitorKeys: Ci }, Gi = ji, Ki = [{ linguistLanguageId: 146, name: "Angular", type: "markup", tmScope: "text.html.basic", aceMode: "html", codemirrorMode: "htmlmixed", codemirrorMimeType: "text/html", color: "#e34c26", aliases: ["xhtml"], extensions: [".component.html"], parsers: ["angular"], vscodeLanguageIds: ["html"], filenames: [] }, { linguistLanguageId: 146, name: "HTML", type: "markup", tmScope: "text.html.basic", aceMode: "html", codemirrorMode: "htmlmixed", codemirrorMimeType: "text/html", color: "#e34c26", aliases: ["xhtml"], extensions: [".html", ".hta", ".htm", ".html.hl", ".inc", ".xht", ".xhtml", ".mjml"], parsers: ["html"], vscodeLanguageIds: ["html"] }, { linguistLanguageId: 146, name: "Lightning Web Components", type: "markup", tmScope: "text.html.basic", aceMode: "html", codemirrorMode: "htmlmixed", codemirrorMimeType: "text/html", color: "#e34c26", aliases: ["xhtml"], extensions: [], parsers: ["lwc"], vscodeLanguageIds: ["html"], filenames: [] }, { linguistLanguageId: 391, name: "Vue", type: "markup", color: "#41b883", extensions: [".vue"], tmScope: "text.html.vue", aceMode: "html", parsers: ["vue"], vscodeLanguageIds: ["vue"] }], Nt = { bracketSpacing: { category: "Common", type: "boolean", default: !0, description: "Print spaces between brackets.", oppositeDescription: "Do not print spaces between brackets." }, objectWrap: { category: "Common", type: "choice", default: "preserve", description: "How to wrap object literals.", choices: [{ value: "preserve", description: "Keep as multi-line, if there is a newline between the opening brace and first property." }, { value: "collapse", description: "Fit to a single line when possible." }] }, singleQuote: { category: "Common", type: "boolean", default: !1, description: "Use single quotes instead of double quotes." }, proseWrap: { category: "Common", type: "choice", default: "preserve", description: "How to wrap prose.", choices: [{ value: "always", description: "Wrap prose if it exceeds the print width." }, { value: "never", description: "Do not wrap prose." }, { value: "preserve", description: "Wrap prose as-is." }] }, bracketSameLine: { category: "Common", type: "boolean", default: !1, description: "Put > of opening tags on the last line instead of on a new line." }, singleAttributePerLine: { category: "Common", type: "boolean", default: !1, description: "Enforce single attribute per line in HTML, Vue and JSX." } }, It = "HTML", Xi = { bracketSameLine: Nt.bracketSameLine, htmlWhitespaceSensitivity: { category: It, type: "choice", default: "css", description: "How to handle whitespaces in HTML.", choices: [{ value: "css", description: "Respect the default value of CSS display property." }, { value: "strict", description: "Whitespaces are considered sensitive." }, { value: "ignore", description: "Whitespaces are considered insensitive." }] }, singleAttributePerLine: Nt.singleAttributePerLine, vueIndentScriptAndStyle: { category: It, type: "boolean", default: !1, description: "Indent script and style tags in Vue files." } }, Yi = Xi, Xr = {};
|
|
1311
|
-
sr(Xr, { angular: () => eu, html: () => Zs, lwc: () => ru, vue: () => tu });
|
|
1312
|
-
var Pt;
|
|
1313
|
-
(function(e) {
|
|
1314
|
-
e[e.Emulated = 0] = "Emulated", e[e.None = 2] = "None", e[e.ShadowDom = 3] = "ShadowDom";
|
|
1315
|
-
})(Pt || (Pt = {}));
|
|
1316
|
-
var Ht;
|
|
1317
|
-
(function(e) {
|
|
1318
|
-
e[e.OnPush = 0] = "OnPush", e[e.Default = 1] = "Default";
|
|
1319
|
-
})(Ht || (Ht = {}));
|
|
1320
|
-
var Mt;
|
|
1321
|
-
(function(e) {
|
|
1322
|
-
e[e.None = 0] = "None", e[e.SignalBased = 1] = "SignalBased", e[e.HasDecoratorInputTransform = 2] = "HasDecoratorInputTransform";
|
|
1323
|
-
})(Mt || (Mt = {}));
|
|
1324
|
-
var Rt = { name: "custom-elements" }, Ut = { name: "no-errors-schema" }, W;
|
|
1325
|
-
(function(e) {
|
|
1326
|
-
e[e.NONE = 0] = "NONE", e[e.HTML = 1] = "HTML", e[e.STYLE = 2] = "STYLE", e[e.SCRIPT = 3] = "SCRIPT", e[e.URL = 4] = "URL", e[e.RESOURCE_URL = 5] = "RESOURCE_URL";
|
|
1327
|
-
})(W || (W = {}));
|
|
1328
|
-
var Vt;
|
|
1329
|
-
(function(e) {
|
|
1330
|
-
e[e.Error = 0] = "Error", e[e.Warning = 1] = "Warning", e[e.Ignore = 2] = "Ignore";
|
|
1331
|
-
})(Vt || (Vt = {}));
|
|
1332
|
-
var I;
|
|
1333
|
-
(function(e) {
|
|
1334
|
-
e[e.RAW_TEXT = 0] = "RAW_TEXT", e[e.ESCAPABLE_RAW_TEXT = 1] = "ESCAPABLE_RAW_TEXT", e[e.PARSABLE_DATA = 2] = "PARSABLE_DATA";
|
|
1335
|
-
})(I || (I = {}));
|
|
1336
|
-
function Ve(e, t = !0) {
|
|
1337
|
-
if (e[0] != ":")
|
|
1338
|
-
return [null, e];
|
|
1339
|
-
let r = e.indexOf(":", 1);
|
|
1340
|
-
if (r === -1) {
|
|
1341
|
-
if (t)
|
|
1342
|
-
throw new Error(`Unsupported format "${e}" expecting ":namespace:name"`);
|
|
1343
|
-
return [null, e];
|
|
1344
|
-
}
|
|
1345
|
-
return [e.slice(1, r), e.slice(r + 1)];
|
|
1346
|
-
}
|
|
1347
|
-
function Ot(e) {
|
|
1348
|
-
return Ve(e)[1] === "ng-container";
|
|
1349
|
-
}
|
|
1350
|
-
function Wt(e) {
|
|
1351
|
-
return Ve(e)[1] === "ng-content";
|
|
1352
|
-
}
|
|
1353
|
-
function ke(e) {
|
|
1354
|
-
return e === null ? null : Ve(e)[0];
|
|
1355
|
-
}
|
|
1356
|
-
function Le(e, t) {
|
|
1357
|
-
return e ? `:${e}:${t}` : t;
|
|
1358
|
-
}
|
|
1359
|
-
var Ee;
|
|
1360
|
-
function zt() {
|
|
1361
|
-
return Ee || (Ee = {}, we(W.HTML, ["iframe|srcdoc", "*|innerHTML", "*|outerHTML"]), we(W.STYLE, ["*|style"]), we(W.URL, ["*|formAction", "area|href", "area|ping", "audio|src", "a|href", "a|ping", "blockquote|cite", "body|background", "del|cite", "form|action", "img|src", "input|src", "ins|cite", "q|cite", "source|src", "track|src", "video|poster", "video|src"]), we(W.RESOURCE_URL, ["applet|code", "applet|codebase", "base|href", "embed|src", "frame|src", "head|profile", "html|manifest", "iframe|src", "link|href", "media|src", "object|codebase", "object|data", "script|src"])), Ee;
|
|
1362
|
-
}
|
|
1363
|
-
function we(e, t) {
|
|
1364
|
-
for (let r of t)
|
|
1365
|
-
Ee[r.toLowerCase()] = e;
|
|
1366
|
-
}
|
|
1367
|
-
var Ji = class {
|
|
1368
|
-
}, Qi = "boolean", Zi = "number", es = "string", ts = "object", rs = ["[Element]|textContent,%ariaAtomic,%ariaAutoComplete,%ariaBusy,%ariaChecked,%ariaColCount,%ariaColIndex,%ariaColSpan,%ariaCurrent,%ariaDescription,%ariaDisabled,%ariaExpanded,%ariaHasPopup,%ariaHidden,%ariaKeyShortcuts,%ariaLabel,%ariaLevel,%ariaLive,%ariaModal,%ariaMultiLine,%ariaMultiSelectable,%ariaOrientation,%ariaPlaceholder,%ariaPosInSet,%ariaPressed,%ariaReadOnly,%ariaRelevant,%ariaRequired,%ariaRoleDescription,%ariaRowCount,%ariaRowIndex,%ariaRowSpan,%ariaSelected,%ariaSetSize,%ariaSort,%ariaValueMax,%ariaValueMin,%ariaValueNow,%ariaValueText,%classList,className,elementTiming,id,innerHTML,*beforecopy,*beforecut,*beforepaste,*fullscreenchange,*fullscreenerror,*search,*webkitfullscreenchange,*webkitfullscreenerror,outerHTML,%part,#scrollLeft,#scrollTop,slot,*message,*mozfullscreenchange,*mozfullscreenerror,*mozpointerlockchange,*mozpointerlockerror,*webglcontextcreationerror,*webglcontextlost,*webglcontextrestored", "[HTMLElement]^[Element]|accessKey,autocapitalize,!autofocus,contentEditable,dir,!draggable,enterKeyHint,!hidden,!inert,innerText,inputMode,lang,nonce,*abort,*animationend,*animationiteration,*animationstart,*auxclick,*beforexrselect,*blur,*cancel,*canplay,*canplaythrough,*change,*click,*close,*contextmenu,*copy,*cuechange,*cut,*dblclick,*drag,*dragend,*dragenter,*dragleave,*dragover,*dragstart,*drop,*durationchange,*emptied,*ended,*error,*focus,*formdata,*gotpointercapture,*input,*invalid,*keydown,*keypress,*keyup,*load,*loadeddata,*loadedmetadata,*loadstart,*lostpointercapture,*mousedown,*mouseenter,*mouseleave,*mousemove,*mouseout,*mouseover,*mouseup,*mousewheel,*paste,*pause,*play,*playing,*pointercancel,*pointerdown,*pointerenter,*pointerleave,*pointermove,*pointerout,*pointerover,*pointerrawupdate,*pointerup,*progress,*ratechange,*reset,*resize,*scroll,*securitypolicyviolation,*seeked,*seeking,*select,*selectionchange,*selectstart,*slotchange,*stalled,*submit,*suspend,*timeupdate,*toggle,*transitioncancel,*transitionend,*transitionrun,*transitionstart,*volumechange,*waiting,*webkitanimationend,*webkitanimationiteration,*webkitanimationstart,*webkittransitionend,*wheel,outerText,!spellcheck,%style,#tabIndex,title,!translate,virtualKeyboardPolicy", "abbr,address,article,aside,b,bdi,bdo,cite,content,code,dd,dfn,dt,em,figcaption,figure,footer,header,hgroup,i,kbd,main,mark,nav,noscript,rb,rp,rt,rtc,ruby,s,samp,section,small,strong,sub,sup,u,var,wbr^[HTMLElement]|accessKey,autocapitalize,!autofocus,contentEditable,dir,!draggable,enterKeyHint,!hidden,innerText,inputMode,lang,nonce,*abort,*animationend,*animationiteration,*animationstart,*auxclick,*beforexrselect,*blur,*cancel,*canplay,*canplaythrough,*change,*click,*close,*contextmenu,*copy,*cuechange,*cut,*dblclick,*drag,*dragend,*dragenter,*dragleave,*dragover,*dragstart,*drop,*durationchange,*emptied,*ended,*error,*focus,*formdata,*gotpointercapture,*input,*invalid,*keydown,*keypress,*keyup,*load,*loadeddata,*loadedmetadata,*loadstart,*lostpointercapture,*mousedown,*mouseenter,*mouseleave,*mousemove,*mouseout,*mouseover,*mouseup,*mousewheel,*paste,*pause,*play,*playing,*pointercancel,*pointerdown,*pointerenter,*pointerleave,*pointermove,*pointerout,*pointerover,*pointerrawupdate,*pointerup,*progress,*ratechange,*reset,*resize,*scroll,*securitypolicyviolation,*seeked,*seeking,*select,*selectionchange,*selectstart,*slotchange,*stalled,*submit,*suspend,*timeupdate,*toggle,*transitioncancel,*transitionend,*transitionrun,*transitionstart,*volumechange,*waiting,*webkitanimationend,*webkitanimationiteration,*webkitanimationstart,*webkittransitionend,*wheel,outerText,!spellcheck,%style,#tabIndex,title,!translate,virtualKeyboardPolicy", "media^[HTMLElement]|!autoplay,!controls,%controlsList,%crossOrigin,#currentTime,!defaultMuted,#defaultPlaybackRate,!disableRemotePlayback,!loop,!muted,*encrypted,*waitingforkey,#playbackRate,preload,!preservesPitch,src,%srcObject,#volume", ":svg:^[HTMLElement]|!autofocus,nonce,*abort,*animationend,*animationiteration,*animationstart,*auxclick,*beforexrselect,*blur,*cancel,*canplay,*canplaythrough,*change,*click,*close,*contextmenu,*copy,*cuechange,*cut,*dblclick,*drag,*dragend,*dragenter,*dragleave,*dragover,*dragstart,*drop,*durationchange,*emptied,*ended,*error,*focus,*formdata,*gotpointercapture,*input,*invalid,*keydown,*keypress,*keyup,*load,*loadeddata,*loadedmetadata,*loadstart,*lostpointercapture,*mousedown,*mouseenter,*mouseleave,*mousemove,*mouseout,*mouseover,*mouseup,*mousewheel,*paste,*pause,*play,*playing,*pointercancel,*pointerdown,*pointerenter,*pointerleave,*pointermove,*pointerout,*pointerover,*pointerrawupdate,*pointerup,*progress,*ratechange,*reset,*resize,*scroll,*securitypolicyviolation,*seeked,*seeking,*select,*selectionchange,*selectstart,*slotchange,*stalled,*submit,*suspend,*timeupdate,*toggle,*transitioncancel,*transitionend,*transitionrun,*transitionstart,*volumechange,*waiting,*webkitanimationend,*webkitanimationiteration,*webkitanimationstart,*webkittransitionend,*wheel,%style,#tabIndex", ":svg:graphics^:svg:|", ":svg:animation^:svg:|*begin,*end,*repeat", ":svg:geometry^:svg:|", ":svg:componentTransferFunction^:svg:|", ":svg:gradient^:svg:|", ":svg:textContent^:svg:graphics|", ":svg:textPositioning^:svg:textContent|", "a^[HTMLElement]|charset,coords,download,hash,host,hostname,href,hreflang,name,password,pathname,ping,port,protocol,referrerPolicy,rel,%relList,rev,search,shape,target,text,type,username", "area^[HTMLElement]|alt,coords,download,hash,host,hostname,href,!noHref,password,pathname,ping,port,protocol,referrerPolicy,rel,%relList,search,shape,target,username", "audio^media|", "br^[HTMLElement]|clear", "base^[HTMLElement]|href,target", "body^[HTMLElement]|aLink,background,bgColor,link,*afterprint,*beforeprint,*beforeunload,*blur,*error,*focus,*hashchange,*languagechange,*load,*message,*messageerror,*offline,*online,*pagehide,*pageshow,*popstate,*rejectionhandled,*resize,*scroll,*storage,*unhandledrejection,*unload,text,vLink", "button^[HTMLElement]|!disabled,formAction,formEnctype,formMethod,!formNoValidate,formTarget,name,type,value", "canvas^[HTMLElement]|#height,#width", "content^[HTMLElement]|select", "dl^[HTMLElement]|!compact", "data^[HTMLElement]|value", "datalist^[HTMLElement]|", "details^[HTMLElement]|!open", "dialog^[HTMLElement]|!open,returnValue", "dir^[HTMLElement]|!compact", "div^[HTMLElement]|align", "embed^[HTMLElement]|align,height,name,src,type,width", "fieldset^[HTMLElement]|!disabled,name", "font^[HTMLElement]|color,face,size", "form^[HTMLElement]|acceptCharset,action,autocomplete,encoding,enctype,method,name,!noValidate,target", "frame^[HTMLElement]|frameBorder,longDesc,marginHeight,marginWidth,name,!noResize,scrolling,src", "frameset^[HTMLElement]|cols,*afterprint,*beforeprint,*beforeunload,*blur,*error,*focus,*hashchange,*languagechange,*load,*message,*messageerror,*offline,*online,*pagehide,*pageshow,*popstate,*rejectionhandled,*resize,*scroll,*storage,*unhandledrejection,*unload,rows", "hr^[HTMLElement]|align,color,!noShade,size,width", "head^[HTMLElement]|", "h1,h2,h3,h4,h5,h6^[HTMLElement]|align", "html^[HTMLElement]|version", "iframe^[HTMLElement]|align,allow,!allowFullscreen,!allowPaymentRequest,csp,frameBorder,height,loading,longDesc,marginHeight,marginWidth,name,referrerPolicy,%sandbox,scrolling,src,srcdoc,width", "img^[HTMLElement]|align,alt,border,%crossOrigin,decoding,#height,#hspace,!isMap,loading,longDesc,lowsrc,name,referrerPolicy,sizes,src,srcset,useMap,#vspace,#width", "input^[HTMLElement]|accept,align,alt,autocomplete,!checked,!defaultChecked,defaultValue,dirName,!disabled,%files,formAction,formEnctype,formMethod,!formNoValidate,formTarget,#height,!incremental,!indeterminate,max,#maxLength,min,#minLength,!multiple,name,pattern,placeholder,!readOnly,!required,selectionDirection,#selectionEnd,#selectionStart,#size,src,step,type,useMap,value,%valueAsDate,#valueAsNumber,#width", "li^[HTMLElement]|type,#value", "label^[HTMLElement]|htmlFor", "legend^[HTMLElement]|align", "link^[HTMLElement]|as,charset,%crossOrigin,!disabled,href,hreflang,imageSizes,imageSrcset,integrity,media,referrerPolicy,rel,%relList,rev,%sizes,target,type", "map^[HTMLElement]|name", "marquee^[HTMLElement]|behavior,bgColor,direction,height,#hspace,#loop,#scrollAmount,#scrollDelay,!trueSpeed,#vspace,width", "menu^[HTMLElement]|!compact", "meta^[HTMLElement]|content,httpEquiv,media,name,scheme", "meter^[HTMLElement]|#high,#low,#max,#min,#optimum,#value", "ins,del^[HTMLElement]|cite,dateTime", "ol^[HTMLElement]|!compact,!reversed,#start,type", "object^[HTMLElement]|align,archive,border,code,codeBase,codeType,data,!declare,height,#hspace,name,standby,type,useMap,#vspace,width", "optgroup^[HTMLElement]|!disabled,label", "option^[HTMLElement]|!defaultSelected,!disabled,label,!selected,text,value", "output^[HTMLElement]|defaultValue,%htmlFor,name,value", "p^[HTMLElement]|align", "param^[HTMLElement]|name,type,value,valueType", "picture^[HTMLElement]|", "pre^[HTMLElement]|#width", "progress^[HTMLElement]|#max,#value", "q,blockquote,cite^[HTMLElement]|", "script^[HTMLElement]|!async,charset,%crossOrigin,!defer,event,htmlFor,integrity,!noModule,%referrerPolicy,src,text,type", "select^[HTMLElement]|autocomplete,!disabled,#length,!multiple,name,!required,#selectedIndex,#size,value", "slot^[HTMLElement]|name", "source^[HTMLElement]|#height,media,sizes,src,srcset,type,#width", "span^[HTMLElement]|", "style^[HTMLElement]|!disabled,media,type", "caption^[HTMLElement]|align", "th,td^[HTMLElement]|abbr,align,axis,bgColor,ch,chOff,#colSpan,headers,height,!noWrap,#rowSpan,scope,vAlign,width", "col,colgroup^[HTMLElement]|align,ch,chOff,#span,vAlign,width", "table^[HTMLElement]|align,bgColor,border,%caption,cellPadding,cellSpacing,frame,rules,summary,%tFoot,%tHead,width", "tr^[HTMLElement]|align,bgColor,ch,chOff,vAlign", "tfoot,thead,tbody^[HTMLElement]|align,ch,chOff,vAlign", "template^[HTMLElement]|", "textarea^[HTMLElement]|autocomplete,#cols,defaultValue,dirName,!disabled,#maxLength,#minLength,name,placeholder,!readOnly,!required,#rows,selectionDirection,#selectionEnd,#selectionStart,value,wrap", "time^[HTMLElement]|dateTime", "title^[HTMLElement]|text", "track^[HTMLElement]|!default,kind,label,src,srclang", "ul^[HTMLElement]|!compact,type", "unknown^[HTMLElement]|", "video^media|!disablePictureInPicture,#height,*enterpictureinpicture,*leavepictureinpicture,!playsInline,poster,#width", ":svg:a^:svg:graphics|", ":svg:animate^:svg:animation|", ":svg:animateMotion^:svg:animation|", ":svg:animateTransform^:svg:animation|", ":svg:circle^:svg:geometry|", ":svg:clipPath^:svg:graphics|", ":svg:defs^:svg:graphics|", ":svg:desc^:svg:|", ":svg:discard^:svg:|", ":svg:ellipse^:svg:geometry|", ":svg:feBlend^:svg:|", ":svg:feColorMatrix^:svg:|", ":svg:feComponentTransfer^:svg:|", ":svg:feComposite^:svg:|", ":svg:feConvolveMatrix^:svg:|", ":svg:feDiffuseLighting^:svg:|", ":svg:feDisplacementMap^:svg:|", ":svg:feDistantLight^:svg:|", ":svg:feDropShadow^:svg:|", ":svg:feFlood^:svg:|", ":svg:feFuncA^:svg:componentTransferFunction|", ":svg:feFuncB^:svg:componentTransferFunction|", ":svg:feFuncG^:svg:componentTransferFunction|", ":svg:feFuncR^:svg:componentTransferFunction|", ":svg:feGaussianBlur^:svg:|", ":svg:feImage^:svg:|", ":svg:feMerge^:svg:|", ":svg:feMergeNode^:svg:|", ":svg:feMorphology^:svg:|", ":svg:feOffset^:svg:|", ":svg:fePointLight^:svg:|", ":svg:feSpecularLighting^:svg:|", ":svg:feSpotLight^:svg:|", ":svg:feTile^:svg:|", ":svg:feTurbulence^:svg:|", ":svg:filter^:svg:|", ":svg:foreignObject^:svg:graphics|", ":svg:g^:svg:graphics|", ":svg:image^:svg:graphics|decoding", ":svg:line^:svg:geometry|", ":svg:linearGradient^:svg:gradient|", ":svg:mpath^:svg:|", ":svg:marker^:svg:|", ":svg:mask^:svg:|", ":svg:metadata^:svg:|", ":svg:path^:svg:geometry|", ":svg:pattern^:svg:|", ":svg:polygon^:svg:geometry|", ":svg:polyline^:svg:geometry|", ":svg:radialGradient^:svg:gradient|", ":svg:rect^:svg:geometry|", ":svg:svg^:svg:graphics|#currentScale,#zoomAndPan", ":svg:script^:svg:|type", ":svg:set^:svg:animation|", ":svg:stop^:svg:|", ":svg:style^:svg:|!disabled,media,title,type", ":svg:switch^:svg:graphics|", ":svg:symbol^:svg:|", ":svg:tspan^:svg:textPositioning|", ":svg:text^:svg:textPositioning|", ":svg:textPath^:svg:textContent|", ":svg:title^:svg:|", ":svg:use^:svg:graphics|", ":svg:view^:svg:|#zoomAndPan", "data^[HTMLElement]|value", "keygen^[HTMLElement]|!autofocus,challenge,!disabled,form,keytype,name", "menuitem^[HTMLElement]|type,label,icon,!disabled,!checked,radiogroup,!default", "summary^[HTMLElement]|", "time^[HTMLElement]|dateTime", ":svg:cursor^:svg:|", ":math:^[HTMLElement]|!autofocus,nonce,*abort,*animationend,*animationiteration,*animationstart,*auxclick,*beforeinput,*beforematch,*beforetoggle,*beforexrselect,*blur,*cancel,*canplay,*canplaythrough,*change,*click,*close,*contentvisibilityautostatechange,*contextlost,*contextmenu,*contextrestored,*copy,*cuechange,*cut,*dblclick,*drag,*dragend,*dragenter,*dragleave,*dragover,*dragstart,*drop,*durationchange,*emptied,*ended,*error,*focus,*formdata,*gotpointercapture,*input,*invalid,*keydown,*keypress,*keyup,*load,*loadeddata,*loadedmetadata,*loadstart,*lostpointercapture,*mousedown,*mouseenter,*mouseleave,*mousemove,*mouseout,*mouseover,*mouseup,*mousewheel,*paste,*pause,*play,*playing,*pointercancel,*pointerdown,*pointerenter,*pointerleave,*pointermove,*pointerout,*pointerover,*pointerrawupdate,*pointerup,*progress,*ratechange,*reset,*resize,*scroll,*scrollend,*securitypolicyviolation,*seeked,*seeking,*select,*selectionchange,*selectstart,*slotchange,*stalled,*submit,*suspend,*timeupdate,*toggle,*transitioncancel,*transitionend,*transitionrun,*transitionstart,*volumechange,*waiting,*webkitanimationend,*webkitanimationiteration,*webkitanimationstart,*webkittransitionend,*wheel,%style,#tabIndex", ":math:math^:math:|", ":math:maction^:math:|", ":math:menclose^:math:|", ":math:merror^:math:|", ":math:mfenced^:math:|", ":math:mfrac^:math:|", ":math:mi^:math:|", ":math:mmultiscripts^:math:|", ":math:mn^:math:|", ":math:mo^:math:|", ":math:mover^:math:|", ":math:mpadded^:math:|", ":math:mphantom^:math:|", ":math:mroot^:math:|", ":math:mrow^:math:|", ":math:ms^:math:|", ":math:mspace^:math:|", ":math:msqrt^:math:|", ":math:mstyle^:math:|", ":math:msub^:math:|", ":math:msubsup^:math:|", ":math:msup^:math:|", ":math:mtable^:math:|", ":math:mtd^:math:|", ":math:mtext^:math:|", ":math:mtr^:math:|", ":math:munder^:math:|", ":math:munderover^:math:|", ":math:semantics^:math:|"], Yr = new Map(Object.entries({ class: "className", for: "htmlFor", formaction: "formAction", innerHtml: "innerHTML", readonly: "readOnly", tabindex: "tabIndex" })), ns = Array.from(Yr).reduce((e, [t, r]) => (e.set(t, r), e), /* @__PURE__ */ new Map()), as = class extends Ji {
|
|
1369
|
-
constructor() {
|
|
1370
|
-
super(), this._schema = /* @__PURE__ */ new Map(), this._eventSchema = /* @__PURE__ */ new Map(), rs.forEach((e) => {
|
|
1371
|
-
let t = /* @__PURE__ */ new Map(), r = /* @__PURE__ */ new Set(), [n, a] = e.split("|"), i = a.split(","), [s, u] = n.split("^");
|
|
1372
|
-
s.split(",").forEach((p) => {
|
|
1373
|
-
this._schema.set(p.toLowerCase(), t), this._eventSchema.set(p.toLowerCase(), r);
|
|
1374
|
-
});
|
|
1375
|
-
let o = u && this._schema.get(u.toLowerCase());
|
|
1376
|
-
if (o) {
|
|
1377
|
-
for (let [p, l] of o)
|
|
1378
|
-
t.set(p, l);
|
|
1379
|
-
for (let p of this._eventSchema.get(u.toLowerCase()))
|
|
1380
|
-
r.add(p);
|
|
1381
|
-
}
|
|
1382
|
-
i.forEach((p) => {
|
|
1383
|
-
if (p.length > 0)
|
|
1384
|
-
switch (p[0]) {
|
|
1385
|
-
case "*":
|
|
1386
|
-
r.add(p.substring(1));
|
|
1387
|
-
break;
|
|
1388
|
-
case "!":
|
|
1389
|
-
t.set(p.substring(1), Qi);
|
|
1390
|
-
break;
|
|
1391
|
-
case "#":
|
|
1392
|
-
t.set(p.substring(1), Zi);
|
|
1393
|
-
break;
|
|
1394
|
-
case "%":
|
|
1395
|
-
t.set(p.substring(1), ts);
|
|
1396
|
-
break;
|
|
1397
|
-
default:
|
|
1398
|
-
t.set(p, es);
|
|
1399
|
-
}
|
|
1400
|
-
});
|
|
1401
|
-
});
|
|
1402
|
-
}
|
|
1403
|
-
hasProperty(e, t, r) {
|
|
1404
|
-
if (r.some((n) => n.name === Ut.name))
|
|
1405
|
-
return !0;
|
|
1406
|
-
if (e.indexOf("-") > -1) {
|
|
1407
|
-
if (Ot(e) || Wt(e))
|
|
1408
|
-
return !1;
|
|
1409
|
-
if (r.some((n) => n.name === Rt.name))
|
|
1410
|
-
return !0;
|
|
1411
|
-
}
|
|
1412
|
-
return (this._schema.get(e.toLowerCase()) || this._schema.get("unknown")).has(t);
|
|
1413
|
-
}
|
|
1414
|
-
hasElement(e, t) {
|
|
1415
|
-
return t.some((r) => r.name === Ut.name) || e.indexOf("-") > -1 && (Ot(e) || Wt(e) || t.some((r) => r.name === Rt.name)) ? !0 : this._schema.has(e.toLowerCase());
|
|
1416
|
-
}
|
|
1417
|
-
securityContext(e, t, r) {
|
|
1418
|
-
r && (t = this.getMappedPropName(t)), e = e.toLowerCase(), t = t.toLowerCase();
|
|
1419
|
-
let n = zt()[e + "|" + t];
|
|
1420
|
-
return n || (n = zt()["*|" + t], n || W.NONE);
|
|
1421
|
-
}
|
|
1422
|
-
getMappedPropName(e) {
|
|
1423
|
-
return Yr.get(e) ?? e;
|
|
1424
|
-
}
|
|
1425
|
-
getDefaultComponentElementName() {
|
|
1426
|
-
return "ng-component";
|
|
1427
|
-
}
|
|
1428
|
-
validateProperty(e) {
|
|
1429
|
-
return e.toLowerCase().startsWith("on") ? { error: !0, msg: `Binding to event property '${e}' is disallowed for security reasons, please use (${e.slice(2)})=...
|
|
1430
|
-
If '${e}' is a directive input, make sure the directive is imported by the current module.` } : { error: !1 };
|
|
1431
|
-
}
|
|
1432
|
-
validateAttribute(e) {
|
|
1433
|
-
return e.toLowerCase().startsWith("on") ? { error: !0, msg: `Binding to event attribute '${e}' is disallowed for security reasons, please use (${e.slice(2)})=...` } : { error: !1 };
|
|
1434
|
-
}
|
|
1435
|
-
allKnownElementNames() {
|
|
1436
|
-
return Array.from(this._schema.keys());
|
|
1437
|
-
}
|
|
1438
|
-
allKnownAttributesOfElement(e) {
|
|
1439
|
-
let t = this._schema.get(e.toLowerCase()) || this._schema.get("unknown");
|
|
1440
|
-
return Array.from(t.keys()).map((r) => ns.get(r) ?? r);
|
|
1441
|
-
}
|
|
1442
|
-
allKnownEventsOfElement(e) {
|
|
1443
|
-
return Array.from(this._eventSchema.get(e.toLowerCase()) ?? []);
|
|
1444
|
-
}
|
|
1445
|
-
normalizeAnimationStyleProperty(e) {
|
|
1446
|
-
return Bi(e);
|
|
1447
|
-
}
|
|
1448
|
-
normalizeAnimationStyleValue(e, t, r) {
|
|
1449
|
-
let n = "", a = r.toString().trim(), i = null;
|
|
1450
|
-
if (is(e) && r !== 0 && r !== "0")
|
|
1451
|
-
if (typeof r == "number")
|
|
1452
|
-
n = "px";
|
|
1453
|
-
else {
|
|
1454
|
-
let s = r.match(/^[+-]?[\d\.]+([a-z]*)$/);
|
|
1455
|
-
s && s[1].length == 0 && (i = `Please provide a CSS unit value for ${t}:${r}`);
|
|
1456
|
-
}
|
|
1457
|
-
return { error: i, value: a + n };
|
|
1458
|
-
}
|
|
1459
|
-
};
|
|
1460
|
-
function is(e) {
|
|
1461
|
-
switch (e) {
|
|
1462
|
-
case "width":
|
|
1463
|
-
case "height":
|
|
1464
|
-
case "minWidth":
|
|
1465
|
-
case "minHeight":
|
|
1466
|
-
case "maxWidth":
|
|
1467
|
-
case "maxHeight":
|
|
1468
|
-
case "left":
|
|
1469
|
-
case "top":
|
|
1470
|
-
case "bottom":
|
|
1471
|
-
case "right":
|
|
1472
|
-
case "fontSize":
|
|
1473
|
-
case "outlineWidth":
|
|
1474
|
-
case "outlineOffset":
|
|
1475
|
-
case "paddingTop":
|
|
1476
|
-
case "paddingLeft":
|
|
1477
|
-
case "paddingBottom":
|
|
1478
|
-
case "paddingRight":
|
|
1479
|
-
case "marginTop":
|
|
1480
|
-
case "marginLeft":
|
|
1481
|
-
case "marginBottom":
|
|
1482
|
-
case "marginRight":
|
|
1483
|
-
case "borderRadius":
|
|
1484
|
-
case "borderWidth":
|
|
1485
|
-
case "borderTopWidth":
|
|
1486
|
-
case "borderLeftWidth":
|
|
1487
|
-
case "borderRightWidth":
|
|
1488
|
-
case "borderBottomWidth":
|
|
1489
|
-
case "textIndent":
|
|
1490
|
-
return !0;
|
|
1491
|
-
default:
|
|
1492
|
-
return !1;
|
|
1493
|
-
}
|
|
1494
|
-
}
|
|
1495
|
-
var h = class {
|
|
1496
|
-
constructor({ closedByChildren: e, implicitNamespacePrefix: t, contentType: r = I.PARSABLE_DATA, closedByParent: n = !1, isVoid: a = !1, ignoreFirstLf: i = !1, preventNamespaceInheritance: s = !1, canSelfClose: u = !1 } = {}) {
|
|
1497
|
-
this.closedByChildren = {}, this.closedByParent = !1, e && e.length > 0 && e.forEach((o) => this.closedByChildren[o] = !0), this.isVoid = a, this.closedByParent = n || a, this.implicitNamespacePrefix = t || null, this.contentType = r, this.ignoreFirstLf = i, this.preventNamespaceInheritance = s, this.canSelfClose = u ?? a;
|
|
1498
|
-
}
|
|
1499
|
-
isClosedByChild(e) {
|
|
1500
|
-
return this.isVoid || e.toLowerCase() in this.closedByChildren;
|
|
1501
|
-
}
|
|
1502
|
-
getContentType(e) {
|
|
1503
|
-
return typeof this.contentType == "object" ? (e === void 0 ? void 0 : this.contentType[e]) ?? this.contentType.default : this.contentType;
|
|
1504
|
-
}
|
|
1505
|
-
}, $t, ie;
|
|
1506
|
-
function et(e) {
|
|
1507
|
-
return ie || ($t = new h({ canSelfClose: !0 }), ie = Object.assign(/* @__PURE__ */ Object.create(null), { base: new h({ isVoid: !0 }), meta: new h({ isVoid: !0 }), area: new h({ isVoid: !0 }), embed: new h({ isVoid: !0 }), link: new h({ isVoid: !0 }), img: new h({ isVoid: !0 }), input: new h({ isVoid: !0 }), param: new h({ isVoid: !0 }), hr: new h({ isVoid: !0 }), br: new h({ isVoid: !0 }), source: new h({ isVoid: !0 }), track: new h({ isVoid: !0 }), wbr: new h({ isVoid: !0 }), p: new h({ closedByChildren: ["address", "article", "aside", "blockquote", "div", "dl", "fieldset", "footer", "form", "h1", "h2", "h3", "h4", "h5", "h6", "header", "hgroup", "hr", "main", "nav", "ol", "p", "pre", "section", "table", "ul"], closedByParent: !0 }), thead: new h({ closedByChildren: ["tbody", "tfoot"] }), tbody: new h({ closedByChildren: ["tbody", "tfoot"], closedByParent: !0 }), tfoot: new h({ closedByChildren: ["tbody"], closedByParent: !0 }), tr: new h({ closedByChildren: ["tr"], closedByParent: !0 }), td: new h({ closedByChildren: ["td", "th"], closedByParent: !0 }), th: new h({ closedByChildren: ["td", "th"], closedByParent: !0 }), col: new h({ isVoid: !0 }), svg: new h({ implicitNamespacePrefix: "svg" }), foreignObject: new h({ implicitNamespacePrefix: "svg", preventNamespaceInheritance: !0 }), math: new h({ implicitNamespacePrefix: "math" }), li: new h({ closedByChildren: ["li"], closedByParent: !0 }), dt: new h({ closedByChildren: ["dt", "dd"] }), dd: new h({ closedByChildren: ["dt", "dd"], closedByParent: !0 }), rb: new h({ closedByChildren: ["rb", "rt", "rtc", "rp"], closedByParent: !0 }), rt: new h({ closedByChildren: ["rb", "rt", "rtc", "rp"], closedByParent: !0 }), rtc: new h({ closedByChildren: ["rb", "rtc", "rp"], closedByParent: !0 }), rp: new h({ closedByChildren: ["rb", "rt", "rtc", "rp"], closedByParent: !0 }), optgroup: new h({ closedByChildren: ["optgroup"], closedByParent: !0 }), option: new h({ closedByChildren: ["option", "optgroup"], closedByParent: !0 }), pre: new h({ ignoreFirstLf: !0 }), listing: new h({ ignoreFirstLf: !0 }), style: new h({ contentType: I.RAW_TEXT }), script: new h({ contentType: I.RAW_TEXT }), title: new h({ contentType: { default: I.ESCAPABLE_RAW_TEXT, svg: I.PARSABLE_DATA } }), textarea: new h({ contentType: I.ESCAPABLE_RAW_TEXT, ignoreFirstLf: !0 }) }), new as().allKnownElementNames().forEach((t) => {
|
|
1508
|
-
!ie[t] && ke(t) === null && (ie[t] = new h({ canSelfClose: !1 }));
|
|
1509
|
-
})), ie[e] ?? $t;
|
|
1510
|
-
}
|
|
1511
|
-
var re = class {
|
|
1512
|
-
constructor(e, t) {
|
|
1513
|
-
this.sourceSpan = e, this.i18n = t;
|
|
1514
|
-
}
|
|
1515
|
-
}, ss = class extends re {
|
|
1516
|
-
constructor(e, t, r, n) {
|
|
1517
|
-
super(t, n), this.value = e, this.tokens = r, this.type = "text";
|
|
1518
|
-
}
|
|
1519
|
-
visit(e, t) {
|
|
1520
|
-
return e.visitText(this, t);
|
|
1521
|
-
}
|
|
1522
|
-
}, us = class extends re {
|
|
1523
|
-
constructor(e, t, r, n) {
|
|
1524
|
-
super(t, n), this.value = e, this.tokens = r, this.type = "cdata";
|
|
1525
|
-
}
|
|
1526
|
-
visit(e, t) {
|
|
1527
|
-
return e.visitCdata(this, t);
|
|
1528
|
-
}
|
|
1529
|
-
}, os = class extends re {
|
|
1530
|
-
constructor(e, t, r, n, a, i) {
|
|
1531
|
-
super(n, i), this.switchValue = e, this.type = t, this.cases = r, this.switchValueSourceSpan = a;
|
|
1532
|
-
}
|
|
1533
|
-
visit(e, t) {
|
|
1534
|
-
return e.visitExpansion(this, t);
|
|
1535
|
-
}
|
|
1536
|
-
}, ls = class {
|
|
1537
|
-
constructor(e, t, r, n, a) {
|
|
1538
|
-
this.value = e, this.expression = t, this.sourceSpan = r, this.valueSourceSpan = n, this.expSourceSpan = a, this.type = "expansionCase";
|
|
1539
|
-
}
|
|
1540
|
-
visit(e, t) {
|
|
1541
|
-
return e.visitExpansionCase(this, t);
|
|
1542
|
-
}
|
|
1543
|
-
}, cs = class extends re {
|
|
1544
|
-
constructor(e, t, r, n, a, i, s) {
|
|
1545
|
-
super(r, s), this.name = e, this.value = t, this.keySpan = n, this.valueSpan = a, this.valueTokens = i, this.type = "attribute";
|
|
1546
|
-
}
|
|
1547
|
-
visit(e, t) {
|
|
1548
|
-
return e.visitAttribute(this, t);
|
|
1549
|
-
}
|
|
1550
|
-
get nameSpan() {
|
|
1551
|
-
return this.keySpan;
|
|
1552
|
-
}
|
|
1553
|
-
}, V = class extends re {
|
|
1554
|
-
constructor(e, t, r, n, a, i = null, s = null, u) {
|
|
1555
|
-
super(n, u), this.name = e, this.attrs = t, this.children = r, this.startSourceSpan = a, this.endSourceSpan = i, this.nameSpan = s, this.type = "element";
|
|
1556
|
-
}
|
|
1557
|
-
visit(e, t) {
|
|
1558
|
-
return e.visitElement(this, t);
|
|
1559
|
-
}
|
|
1560
|
-
}, ps = class {
|
|
1561
|
-
constructor(e, t) {
|
|
1562
|
-
this.value = e, this.sourceSpan = t, this.type = "comment";
|
|
1563
|
-
}
|
|
1564
|
-
visit(e, t) {
|
|
1565
|
-
return e.visitComment(this, t);
|
|
1566
|
-
}
|
|
1567
|
-
}, hs = class {
|
|
1568
|
-
constructor(e, t) {
|
|
1569
|
-
this.value = e, this.sourceSpan = t, this.type = "docType";
|
|
1570
|
-
}
|
|
1571
|
-
visit(e, t) {
|
|
1572
|
-
return e.visitDocType(this, t);
|
|
1573
|
-
}
|
|
1574
|
-
}, K = class extends re {
|
|
1575
|
-
constructor(e, t, r, n, a, i, s = null, u) {
|
|
1576
|
-
super(n, u), this.name = e, this.parameters = t, this.children = r, this.nameSpan = a, this.startSourceSpan = i, this.endSourceSpan = s, this.type = "block";
|
|
1577
|
-
}
|
|
1578
|
-
visit(e, t) {
|
|
1579
|
-
return e.visitBlock(this, t);
|
|
1580
|
-
}
|
|
1581
|
-
}, jt = class {
|
|
1582
|
-
constructor(e, t) {
|
|
1583
|
-
this.expression = e, this.sourceSpan = t, this.type = "blockParameter", this.startSourceSpan = null, this.endSourceSpan = null;
|
|
1584
|
-
}
|
|
1585
|
-
visit(e, t) {
|
|
1586
|
-
return e.visitBlockParameter(this, t);
|
|
1587
|
-
}
|
|
1588
|
-
}, Gt = class {
|
|
1589
|
-
constructor(e, t, r, n, a) {
|
|
1590
|
-
this.name = e, this.value = t, this.sourceSpan = r, this.nameSpan = n, this.valueSpan = a, this.type = "letDeclaration", this.startSourceSpan = null, this.endSourceSpan = null;
|
|
1591
|
-
}
|
|
1592
|
-
visit(e, t) {
|
|
1593
|
-
return e.visitLetDeclaration(this, t);
|
|
1594
|
-
}
|
|
1595
|
-
};
|
|
1596
|
-
function Jr(e, t, r = null) {
|
|
1597
|
-
let n = [], a = e.visit ? (i) => e.visit(i, r) || i.visit(e, r) : (i) => i.visit(e, r);
|
|
1598
|
-
return t.forEach((i) => {
|
|
1599
|
-
let s = a(i);
|
|
1600
|
-
s && n.push(s);
|
|
1601
|
-
}), n;
|
|
1602
|
-
}
|
|
1603
|
-
var ds = class {
|
|
1604
|
-
constructor() {
|
|
1605
|
-
}
|
|
1606
|
-
visitElement(e, t) {
|
|
1607
|
-
this.visitChildren(t, (r) => {
|
|
1608
|
-
r(e.attrs), r(e.children);
|
|
1609
|
-
});
|
|
1610
|
-
}
|
|
1611
|
-
visitAttribute(e, t) {
|
|
1612
|
-
}
|
|
1613
|
-
visitText(e, t) {
|
|
1614
|
-
}
|
|
1615
|
-
visitCdata(e, t) {
|
|
1616
|
-
}
|
|
1617
|
-
visitComment(e, t) {
|
|
1618
|
-
}
|
|
1619
|
-
visitDocType(e, t) {
|
|
1620
|
-
}
|
|
1621
|
-
visitExpansion(e, t) {
|
|
1622
|
-
return this.visitChildren(t, (r) => {
|
|
1623
|
-
r(e.cases);
|
|
1624
|
-
});
|
|
1625
|
-
}
|
|
1626
|
-
visitExpansionCase(e, t) {
|
|
1627
|
-
}
|
|
1628
|
-
visitBlock(e, t) {
|
|
1629
|
-
this.visitChildren(t, (r) => {
|
|
1630
|
-
r(e.parameters), r(e.children);
|
|
1631
|
-
});
|
|
1632
|
-
}
|
|
1633
|
-
visitBlockParameter(e, t) {
|
|
1634
|
-
}
|
|
1635
|
-
visitLetDeclaration(e, t) {
|
|
1636
|
-
}
|
|
1637
|
-
visitChildren(e, t) {
|
|
1638
|
-
let r = [], n = this;
|
|
1639
|
-
function a(i) {
|
|
1640
|
-
i && r.push(Jr(n, i, e));
|
|
1641
|
-
}
|
|
1642
|
-
return t(a), Array.prototype.concat.apply([], r);
|
|
1643
|
-
}
|
|
1644
|
-
}, Fe = { AElig: "Æ", AMP: "&", amp: "&", Aacute: "Á", Abreve: "Ă", Acirc: "Â", Acy: "А", Afr: "𝔄", Agrave: "À", Alpha: "Α", Amacr: "Ā", And: "⩓", Aogon: "Ą", Aopf: "𝔸", ApplyFunction: "", af: "", Aring: "Å", angst: "Å", Ascr: "𝒜", Assign: "≔", colone: "≔", coloneq: "≔", Atilde: "Ã", Auml: "Ä", Backslash: "∖", setminus: "∖", setmn: "∖", smallsetminus: "∖", ssetmn: "∖", Barv: "⫧", Barwed: "⌆", doublebarwedge: "⌆", Bcy: "Б", Because: "∵", becaus: "∵", because: "∵", Bernoullis: "ℬ", Bscr: "ℬ", bernou: "ℬ", Beta: "Β", Bfr: "𝔅", Bopf: "𝔹", Breve: "˘", breve: "˘", Bumpeq: "≎", HumpDownHump: "≎", bump: "≎", CHcy: "Ч", COPY: "©", copy: "©", Cacute: "Ć", Cap: "⋒", CapitalDifferentialD: "ⅅ", DD: "ⅅ", Cayleys: "ℭ", Cfr: "ℭ", Ccaron: "Č", Ccedil: "Ç", Ccirc: "Ĉ", Cconint: "∰", Cdot: "Ċ", Cedilla: "¸", cedil: "¸", CenterDot: "·", centerdot: "·", middot: "·", Chi: "Χ", CircleDot: "⊙", odot: "⊙", CircleMinus: "⊖", ominus: "⊖", CirclePlus: "⊕", oplus: "⊕", CircleTimes: "⊗", otimes: "⊗", ClockwiseContourIntegral: "∲", cwconint: "∲", CloseCurlyDoubleQuote: "”", rdquo: "”", rdquor: "”", CloseCurlyQuote: "’", rsquo: "’", rsquor: "’", Colon: "∷", Proportion: "∷", Colone: "⩴", Congruent: "≡", equiv: "≡", Conint: "∯", DoubleContourIntegral: "∯", ContourIntegral: "∮", conint: "∮", oint: "∮", Copf: "ℂ", complexes: "ℂ", Coproduct: "∐", coprod: "∐", CounterClockwiseContourIntegral: "∳", awconint: "∳", Cross: "⨯", Cscr: "𝒞", Cup: "⋓", CupCap: "≍", asympeq: "≍", DDotrahd: "⤑", DJcy: "Ђ", DScy: "Ѕ", DZcy: "Џ", Dagger: "‡", ddagger: "‡", Darr: "↡", Dashv: "⫤", DoubleLeftTee: "⫤", Dcaron: "Ď", Dcy: "Д", Del: "∇", nabla: "∇", Delta: "Δ", Dfr: "𝔇", DiacriticalAcute: "´", acute: "´", DiacriticalDot: "˙", dot: "˙", DiacriticalDoubleAcute: "˝", dblac: "˝", DiacriticalGrave: "`", grave: "`", DiacriticalTilde: "˜", tilde: "˜", Diamond: "⋄", diam: "⋄", diamond: "⋄", DifferentialD: "ⅆ", dd: "ⅆ", Dopf: "𝔻", Dot: "¨", DoubleDot: "¨", die: "¨", uml: "¨", DotDot: "⃜", DotEqual: "≐", doteq: "≐", esdot: "≐", DoubleDownArrow: "⇓", Downarrow: "⇓", dArr: "⇓", DoubleLeftArrow: "⇐", Leftarrow: "⇐", lArr: "⇐", DoubleLeftRightArrow: "⇔", Leftrightarrow: "⇔", hArr: "⇔", iff: "⇔", DoubleLongLeftArrow: "⟸", Longleftarrow: "⟸", xlArr: "⟸", DoubleLongLeftRightArrow: "⟺", Longleftrightarrow: "⟺", xhArr: "⟺", DoubleLongRightArrow: "⟹", Longrightarrow: "⟹", xrArr: "⟹", DoubleRightArrow: "⇒", Implies: "⇒", Rightarrow: "⇒", rArr: "⇒", DoubleRightTee: "⊨", vDash: "⊨", DoubleUpArrow: "⇑", Uparrow: "⇑", uArr: "⇑", DoubleUpDownArrow: "⇕", Updownarrow: "⇕", vArr: "⇕", DoubleVerticalBar: "∥", par: "∥", parallel: "∥", shortparallel: "∥", spar: "∥", DownArrow: "↓", ShortDownArrow: "↓", darr: "↓", downarrow: "↓", DownArrowBar: "⤓", DownArrowUpArrow: "⇵", duarr: "⇵", DownBreve: "̑", DownLeftRightVector: "⥐", DownLeftTeeVector: "⥞", DownLeftVector: "↽", leftharpoondown: "↽", lhard: "↽", DownLeftVectorBar: "⥖", DownRightTeeVector: "⥟", DownRightVector: "⇁", rhard: "⇁", rightharpoondown: "⇁", DownRightVectorBar: "⥗", DownTee: "⊤", top: "⊤", DownTeeArrow: "↧", mapstodown: "↧", Dscr: "𝒟", Dstrok: "Đ", ENG: "Ŋ", ETH: "Ð", Eacute: "É", Ecaron: "Ě", Ecirc: "Ê", Ecy: "Э", Edot: "Ė", Efr: "𝔈", Egrave: "È", Element: "∈", in: "∈", isin: "∈", isinv: "∈", Emacr: "Ē", EmptySmallSquare: "◻", EmptyVerySmallSquare: "▫", Eogon: "Ę", Eopf: "𝔼", Epsilon: "Ε", Equal: "⩵", EqualTilde: "≂", eqsim: "≂", esim: "≂", Equilibrium: "⇌", rightleftharpoons: "⇌", rlhar: "⇌", Escr: "ℰ", expectation: "ℰ", Esim: "⩳", Eta: "Η", Euml: "Ë", Exists: "∃", exist: "∃", ExponentialE: "ⅇ", ee: "ⅇ", exponentiale: "ⅇ", Fcy: "Ф", Ffr: "𝔉", FilledSmallSquare: "◼", FilledVerySmallSquare: "▪", blacksquare: "▪", squarf: "▪", squf: "▪", Fopf: "𝔽", ForAll: "∀", forall: "∀", Fouriertrf: "ℱ", Fscr: "ℱ", GJcy: "Ѓ", GT: ">", gt: ">", Gamma: "Γ", Gammad: "Ϝ", Gbreve: "Ğ", Gcedil: "Ģ", Gcirc: "Ĝ", Gcy: "Г", Gdot: "Ġ", Gfr: "𝔊", Gg: "⋙", ggg: "⋙", Gopf: "𝔾", GreaterEqual: "≥", ge: "≥", geq: "≥", GreaterEqualLess: "⋛", gel: "⋛", gtreqless: "⋛", GreaterFullEqual: "≧", gE: "≧", geqq: "≧", GreaterGreater: "⪢", GreaterLess: "≷", gl: "≷", gtrless: "≷", GreaterSlantEqual: "⩾", geqslant: "⩾", ges: "⩾", GreaterTilde: "≳", gsim: "≳", gtrsim: "≳", Gscr: "𝒢", Gt: "≫", NestedGreaterGreater: "≫", gg: "≫", HARDcy: "Ъ", Hacek: "ˇ", caron: "ˇ", Hat: "^", Hcirc: "Ĥ", Hfr: "ℌ", Poincareplane: "ℌ", HilbertSpace: "ℋ", Hscr: "ℋ", hamilt: "ℋ", Hopf: "ℍ", quaternions: "ℍ", HorizontalLine: "─", boxh: "─", Hstrok: "Ħ", HumpEqual: "≏", bumpe: "≏", bumpeq: "≏", IEcy: "Е", IJlig: "IJ", IOcy: "Ё", Iacute: "Í", Icirc: "Î", Icy: "И", Idot: "İ", Ifr: "ℑ", Im: "ℑ", image: "ℑ", imagpart: "ℑ", Igrave: "Ì", Imacr: "Ī", ImaginaryI: "ⅈ", ii: "ⅈ", Int: "∬", Integral: "∫", int: "∫", Intersection: "⋂", bigcap: "⋂", xcap: "⋂", InvisibleComma: "", ic: "", InvisibleTimes: "", it: "", Iogon: "Į", Iopf: "𝕀", Iota: "Ι", Iscr: "ℐ", imagline: "ℐ", Itilde: "Ĩ", Iukcy: "І", Iuml: "Ï", Jcirc: "Ĵ", Jcy: "Й", Jfr: "𝔍", Jopf: "𝕁", Jscr: "𝒥", Jsercy: "Ј", Jukcy: "Є", KHcy: "Х", KJcy: "Ќ", Kappa: "Κ", Kcedil: "Ķ", Kcy: "К", Kfr: "𝔎", Kopf: "𝕂", Kscr: "𝒦", LJcy: "Љ", LT: "<", lt: "<", Lacute: "Ĺ", Lambda: "Λ", Lang: "⟪", Laplacetrf: "ℒ", Lscr: "ℒ", lagran: "ℒ", Larr: "↞", twoheadleftarrow: "↞", Lcaron: "Ľ", Lcedil: "Ļ", Lcy: "Л", LeftAngleBracket: "⟨", lang: "⟨", langle: "⟨", LeftArrow: "←", ShortLeftArrow: "←", larr: "←", leftarrow: "←", slarr: "←", LeftArrowBar: "⇤", larrb: "⇤", LeftArrowRightArrow: "⇆", leftrightarrows: "⇆", lrarr: "⇆", LeftCeiling: "⌈", lceil: "⌈", LeftDoubleBracket: "⟦", lobrk: "⟦", LeftDownTeeVector: "⥡", LeftDownVector: "⇃", dharl: "⇃", downharpoonleft: "⇃", LeftDownVectorBar: "⥙", LeftFloor: "⌊", lfloor: "⌊", LeftRightArrow: "↔", harr: "↔", leftrightarrow: "↔", LeftRightVector: "⥎", LeftTee: "⊣", dashv: "⊣", LeftTeeArrow: "↤", mapstoleft: "↤", LeftTeeVector: "⥚", LeftTriangle: "⊲", vartriangleleft: "⊲", vltri: "⊲", LeftTriangleBar: "⧏", LeftTriangleEqual: "⊴", ltrie: "⊴", trianglelefteq: "⊴", LeftUpDownVector: "⥑", LeftUpTeeVector: "⥠", LeftUpVector: "↿", uharl: "↿", upharpoonleft: "↿", LeftUpVectorBar: "⥘", LeftVector: "↼", leftharpoonup: "↼", lharu: "↼", LeftVectorBar: "⥒", LessEqualGreater: "⋚", leg: "⋚", lesseqgtr: "⋚", LessFullEqual: "≦", lE: "≦", leqq: "≦", LessGreater: "≶", lessgtr: "≶", lg: "≶", LessLess: "⪡", LessSlantEqual: "⩽", leqslant: "⩽", les: "⩽", LessTilde: "≲", lesssim: "≲", lsim: "≲", Lfr: "𝔏", Ll: "⋘", Lleftarrow: "⇚", lAarr: "⇚", Lmidot: "Ŀ", LongLeftArrow: "⟵", longleftarrow: "⟵", xlarr: "⟵", LongLeftRightArrow: "⟷", longleftrightarrow: "⟷", xharr: "⟷", LongRightArrow: "⟶", longrightarrow: "⟶", xrarr: "⟶", Lopf: "𝕃", LowerLeftArrow: "↙", swarr: "↙", swarrow: "↙", LowerRightArrow: "↘", searr: "↘", searrow: "↘", Lsh: "↰", lsh: "↰", Lstrok: "Ł", Lt: "≪", NestedLessLess: "≪", ll: "≪", Map: "⤅", Mcy: "М", MediumSpace: " ", Mellintrf: "ℳ", Mscr: "ℳ", phmmat: "ℳ", Mfr: "𝔐", MinusPlus: "∓", mnplus: "∓", mp: "∓", Mopf: "𝕄", Mu: "Μ", NJcy: "Њ", Nacute: "Ń", Ncaron: "Ň", Ncedil: "Ņ", Ncy: "Н", NegativeMediumSpace: "", NegativeThickSpace: "", NegativeThinSpace: "", NegativeVeryThinSpace: "", ZeroWidthSpace: "", NewLine: `
|
|
1645
|
-
`, Nfr: "𝔑", NoBreak: "", NonBreakingSpace: " ", nbsp: " ", Nopf: "ℕ", naturals: "ℕ", Not: "⫬", NotCongruent: "≢", nequiv: "≢", NotCupCap: "≭", NotDoubleVerticalBar: "∦", npar: "∦", nparallel: "∦", nshortparallel: "∦", nspar: "∦", NotElement: "∉", notin: "∉", notinva: "∉", NotEqual: "≠", ne: "≠", NotEqualTilde: "≂̸", nesim: "≂̸", NotExists: "∄", nexist: "∄", nexists: "∄", NotGreater: "≯", ngt: "≯", ngtr: "≯", NotGreaterEqual: "≱", nge: "≱", ngeq: "≱", NotGreaterFullEqual: "≧̸", ngE: "≧̸", ngeqq: "≧̸", NotGreaterGreater: "≫̸", nGtv: "≫̸", NotGreaterLess: "≹", ntgl: "≹", NotGreaterSlantEqual: "⩾̸", ngeqslant: "⩾̸", nges: "⩾̸", NotGreaterTilde: "≵", ngsim: "≵", NotHumpDownHump: "≎̸", nbump: "≎̸", NotHumpEqual: "≏̸", nbumpe: "≏̸", NotLeftTriangle: "⋪", nltri: "⋪", ntriangleleft: "⋪", NotLeftTriangleBar: "⧏̸", NotLeftTriangleEqual: "⋬", nltrie: "⋬", ntrianglelefteq: "⋬", NotLess: "≮", nless: "≮", nlt: "≮", NotLessEqual: "≰", nle: "≰", nleq: "≰", NotLessGreater: "≸", ntlg: "≸", NotLessLess: "≪̸", nLtv: "≪̸", NotLessSlantEqual: "⩽̸", nleqslant: "⩽̸", nles: "⩽̸", NotLessTilde: "≴", nlsim: "≴", NotNestedGreaterGreater: "⪢̸", NotNestedLessLess: "⪡̸", NotPrecedes: "⊀", npr: "⊀", nprec: "⊀", NotPrecedesEqual: "⪯̸", npre: "⪯̸", npreceq: "⪯̸", NotPrecedesSlantEqual: "⋠", nprcue: "⋠", NotReverseElement: "∌", notni: "∌", notniva: "∌", NotRightTriangle: "⋫", nrtri: "⋫", ntriangleright: "⋫", NotRightTriangleBar: "⧐̸", NotRightTriangleEqual: "⋭", nrtrie: "⋭", ntrianglerighteq: "⋭", NotSquareSubset: "⊏̸", NotSquareSubsetEqual: "⋢", nsqsube: "⋢", NotSquareSuperset: "⊐̸", NotSquareSupersetEqual: "⋣", nsqsupe: "⋣", NotSubset: "⊂⃒", nsubset: "⊂⃒", vnsub: "⊂⃒", NotSubsetEqual: "⊈", nsube: "⊈", nsubseteq: "⊈", NotSucceeds: "⊁", nsc: "⊁", nsucc: "⊁", NotSucceedsEqual: "⪰̸", nsce: "⪰̸", nsucceq: "⪰̸", NotSucceedsSlantEqual: "⋡", nsccue: "⋡", NotSucceedsTilde: "≿̸", NotSuperset: "⊃⃒", nsupset: "⊃⃒", vnsup: "⊃⃒", NotSupersetEqual: "⊉", nsupe: "⊉", nsupseteq: "⊉", NotTilde: "≁", nsim: "≁", NotTildeEqual: "≄", nsime: "≄", nsimeq: "≄", NotTildeFullEqual: "≇", ncong: "≇", NotTildeTilde: "≉", nap: "≉", napprox: "≉", NotVerticalBar: "∤", nmid: "∤", nshortmid: "∤", nsmid: "∤", Nscr: "𝒩", Ntilde: "Ñ", Nu: "Ν", OElig: "Œ", Oacute: "Ó", Ocirc: "Ô", Ocy: "О", Odblac: "Ő", Ofr: "𝔒", Ograve: "Ò", Omacr: "Ō", Omega: "Ω", ohm: "Ω", Omicron: "Ο", Oopf: "𝕆", OpenCurlyDoubleQuote: "“", ldquo: "“", OpenCurlyQuote: "‘", lsquo: "‘", Or: "⩔", Oscr: "𝒪", Oslash: "Ø", Otilde: "Õ", Otimes: "⨷", Ouml: "Ö", OverBar: "‾", oline: "‾", OverBrace: "⏞", OverBracket: "⎴", tbrk: "⎴", OverParenthesis: "⏜", PartialD: "∂", part: "∂", Pcy: "П", Pfr: "𝔓", Phi: "Φ", Pi: "Π", PlusMinus: "±", plusmn: "±", pm: "±", Popf: "ℙ", primes: "ℙ", Pr: "⪻", Precedes: "≺", pr: "≺", prec: "≺", PrecedesEqual: "⪯", pre: "⪯", preceq: "⪯", PrecedesSlantEqual: "≼", prcue: "≼", preccurlyeq: "≼", PrecedesTilde: "≾", precsim: "≾", prsim: "≾", Prime: "″", Product: "∏", prod: "∏", Proportional: "∝", prop: "∝", propto: "∝", varpropto: "∝", vprop: "∝", Pscr: "𝒫", Psi: "Ψ", QUOT: '"', quot: '"', Qfr: "𝔔", Qopf: "ℚ", rationals: "ℚ", Qscr: "𝒬", RBarr: "⤐", drbkarow: "⤐", REG: "®", circledR: "®", reg: "®", Racute: "Ŕ", Rang: "⟫", Rarr: "↠", twoheadrightarrow: "↠", Rarrtl: "⤖", Rcaron: "Ř", Rcedil: "Ŗ", Rcy: "Р", Re: "ℜ", Rfr: "ℜ", real: "ℜ", realpart: "ℜ", ReverseElement: "∋", SuchThat: "∋", ni: "∋", niv: "∋", ReverseEquilibrium: "⇋", leftrightharpoons: "⇋", lrhar: "⇋", ReverseUpEquilibrium: "⥯", duhar: "⥯", Rho: "Ρ", RightAngleBracket: "⟩", rang: "⟩", rangle: "⟩", RightArrow: "→", ShortRightArrow: "→", rarr: "→", rightarrow: "→", srarr: "→", RightArrowBar: "⇥", rarrb: "⇥", RightArrowLeftArrow: "⇄", rightleftarrows: "⇄", rlarr: "⇄", RightCeiling: "⌉", rceil: "⌉", RightDoubleBracket: "⟧", robrk: "⟧", RightDownTeeVector: "⥝", RightDownVector: "⇂", dharr: "⇂", downharpoonright: "⇂", RightDownVectorBar: "⥕", RightFloor: "⌋", rfloor: "⌋", RightTee: "⊢", vdash: "⊢", RightTeeArrow: "↦", map: "↦", mapsto: "↦", RightTeeVector: "⥛", RightTriangle: "⊳", vartriangleright: "⊳", vrtri: "⊳", RightTriangleBar: "⧐", RightTriangleEqual: "⊵", rtrie: "⊵", trianglerighteq: "⊵", RightUpDownVector: "⥏", RightUpTeeVector: "⥜", RightUpVector: "↾", uharr: "↾", upharpoonright: "↾", RightUpVectorBar: "⥔", RightVector: "⇀", rharu: "⇀", rightharpoonup: "⇀", RightVectorBar: "⥓", Ropf: "ℝ", reals: "ℝ", RoundImplies: "⥰", Rrightarrow: "⇛", rAarr: "⇛", Rscr: "ℛ", realine: "ℛ", Rsh: "↱", rsh: "↱", RuleDelayed: "⧴", SHCHcy: "Щ", SHcy: "Ш", SOFTcy: "Ь", Sacute: "Ś", Sc: "⪼", Scaron: "Š", Scedil: "Ş", Scirc: "Ŝ", Scy: "С", Sfr: "𝔖", ShortUpArrow: "↑", UpArrow: "↑", uarr: "↑", uparrow: "↑", Sigma: "Σ", SmallCircle: "∘", compfn: "∘", Sopf: "𝕊", Sqrt: "√", radic: "√", Square: "□", squ: "□", square: "□", SquareIntersection: "⊓", sqcap: "⊓", SquareSubset: "⊏", sqsub: "⊏", sqsubset: "⊏", SquareSubsetEqual: "⊑", sqsube: "⊑", sqsubseteq: "⊑", SquareSuperset: "⊐", sqsup: "⊐", sqsupset: "⊐", SquareSupersetEqual: "⊒", sqsupe: "⊒", sqsupseteq: "⊒", SquareUnion: "⊔", sqcup: "⊔", Sscr: "𝒮", Star: "⋆", sstarf: "⋆", Sub: "⋐", Subset: "⋐", SubsetEqual: "⊆", sube: "⊆", subseteq: "⊆", Succeeds: "≻", sc: "≻", succ: "≻", SucceedsEqual: "⪰", sce: "⪰", succeq: "⪰", SucceedsSlantEqual: "≽", sccue: "≽", succcurlyeq: "≽", SucceedsTilde: "≿", scsim: "≿", succsim: "≿", Sum: "∑", sum: "∑", Sup: "⋑", Supset: "⋑", Superset: "⊃", sup: "⊃", supset: "⊃", SupersetEqual: "⊇", supe: "⊇", supseteq: "⊇", THORN: "Þ", TRADE: "™", trade: "™", TSHcy: "Ћ", TScy: "Ц", Tab: " ", Tau: "Τ", Tcaron: "Ť", Tcedil: "Ţ", Tcy: "Т", Tfr: "𝔗", Therefore: "∴", there4: "∴", therefore: "∴", Theta: "Θ", ThickSpace: " ", ThinSpace: " ", thinsp: " ", Tilde: "∼", sim: "∼", thicksim: "∼", thksim: "∼", TildeEqual: "≃", sime: "≃", simeq: "≃", TildeFullEqual: "≅", cong: "≅", TildeTilde: "≈", ap: "≈", approx: "≈", asymp: "≈", thickapprox: "≈", thkap: "≈", Topf: "𝕋", TripleDot: "⃛", tdot: "⃛", Tscr: "𝒯", Tstrok: "Ŧ", Uacute: "Ú", Uarr: "↟", Uarrocir: "⥉", Ubrcy: "Ў", Ubreve: "Ŭ", Ucirc: "Û", Ucy: "У", Udblac: "Ű", Ufr: "𝔘", Ugrave: "Ù", Umacr: "Ū", UnderBar: "_", lowbar: "_", UnderBrace: "⏟", UnderBracket: "⎵", bbrk: "⎵", UnderParenthesis: "⏝", Union: "⋃", bigcup: "⋃", xcup: "⋃", UnionPlus: "⊎", uplus: "⊎", Uogon: "Ų", Uopf: "𝕌", UpArrowBar: "⤒", UpArrowDownArrow: "⇅", udarr: "⇅", UpDownArrow: "↕", updownarrow: "↕", varr: "↕", UpEquilibrium: "⥮", udhar: "⥮", UpTee: "⊥", bot: "⊥", bottom: "⊥", perp: "⊥", UpTeeArrow: "↥", mapstoup: "↥", UpperLeftArrow: "↖", nwarr: "↖", nwarrow: "↖", UpperRightArrow: "↗", nearr: "↗", nearrow: "↗", Upsi: "ϒ", upsih: "ϒ", Upsilon: "Υ", Uring: "Ů", Uscr: "𝒰", Utilde: "Ũ", Uuml: "Ü", VDash: "⊫", Vbar: "⫫", Vcy: "В", Vdash: "⊩", Vdashl: "⫦", Vee: "⋁", bigvee: "⋁", xvee: "⋁", Verbar: "‖", Vert: "‖", VerticalBar: "∣", mid: "∣", shortmid: "∣", smid: "∣", VerticalLine: "|", verbar: "|", vert: "|", VerticalSeparator: "❘", VerticalTilde: "≀", wr: "≀", wreath: "≀", VeryThinSpace: " ", hairsp: " ", Vfr: "𝔙", Vopf: "𝕍", Vscr: "𝒱", Vvdash: "⊪", Wcirc: "Ŵ", Wedge: "⋀", bigwedge: "⋀", xwedge: "⋀", Wfr: "𝔚", Wopf: "𝕎", Wscr: "𝒲", Xfr: "𝔛", Xi: "Ξ", Xopf: "𝕏", Xscr: "𝒳", YAcy: "Я", YIcy: "Ї", YUcy: "Ю", Yacute: "Ý", Ycirc: "Ŷ", Ycy: "Ы", Yfr: "𝔜", Yopf: "𝕐", Yscr: "𝒴", Yuml: "Ÿ", ZHcy: "Ж", Zacute: "Ź", Zcaron: "Ž", Zcy: "З", Zdot: "Ż", Zeta: "Ζ", Zfr: "ℨ", zeetrf: "ℨ", Zopf: "ℤ", integers: "ℤ", Zscr: "𝒵", aacute: "á", abreve: "ă", ac: "∾", mstpos: "∾", acE: "∾̳", acd: "∿", acirc: "â", acy: "а", aelig: "æ", afr: "𝔞", agrave: "à", alefsym: "ℵ", aleph: "ℵ", alpha: "α", amacr: "ā", amalg: "⨿", and: "∧", wedge: "∧", andand: "⩕", andd: "⩜", andslope: "⩘", andv: "⩚", ang: "∠", angle: "∠", ange: "⦤", angmsd: "∡", measuredangle: "∡", angmsdaa: "⦨", angmsdab: "⦩", angmsdac: "⦪", angmsdad: "⦫", angmsdae: "⦬", angmsdaf: "⦭", angmsdag: "⦮", angmsdah: "⦯", angrt: "∟", angrtvb: "⊾", angrtvbd: "⦝", angsph: "∢", angzarr: "⍼", aogon: "ą", aopf: "𝕒", apE: "⩰", apacir: "⩯", ape: "≊", approxeq: "≊", apid: "≋", apos: "'", aring: "å", ascr: "𝒶", ast: "*", midast: "*", atilde: "ã", auml: "ä", awint: "⨑", bNot: "⫭", backcong: "≌", bcong: "≌", backepsilon: "϶", bepsi: "϶", backprime: "‵", bprime: "‵", backsim: "∽", bsim: "∽", backsimeq: "⋍", bsime: "⋍", barvee: "⊽", barwed: "⌅", barwedge: "⌅", bbrktbrk: "⎶", bcy: "б", bdquo: "„", ldquor: "„", bemptyv: "⦰", beta: "β", beth: "ℶ", between: "≬", twixt: "≬", bfr: "𝔟", bigcirc: "◯", xcirc: "◯", bigodot: "⨀", xodot: "⨀", bigoplus: "⨁", xoplus: "⨁", bigotimes: "⨂", xotime: "⨂", bigsqcup: "⨆", xsqcup: "⨆", bigstar: "★", starf: "★", bigtriangledown: "▽", xdtri: "▽", bigtriangleup: "△", xutri: "△", biguplus: "⨄", xuplus: "⨄", bkarow: "⤍", rbarr: "⤍", blacklozenge: "⧫", lozf: "⧫", blacktriangle: "▴", utrif: "▴", blacktriangledown: "▾", dtrif: "▾", blacktriangleleft: "◂", ltrif: "◂", blacktriangleright: "▸", rtrif: "▸", blank: "␣", blk12: "▒", blk14: "░", blk34: "▓", block: "█", bne: "=⃥", bnequiv: "≡⃥", bnot: "⌐", bopf: "𝕓", bowtie: "⋈", boxDL: "╗", boxDR: "╔", boxDl: "╖", boxDr: "╓", boxH: "═", boxHD: "╦", boxHU: "╩", boxHd: "╤", boxHu: "╧", boxUL: "╝", boxUR: "╚", boxUl: "╜", boxUr: "╙", boxV: "║", boxVH: "╬", boxVL: "╣", boxVR: "╠", boxVh: "╫", boxVl: "╢", boxVr: "╟", boxbox: "⧉", boxdL: "╕", boxdR: "╒", boxdl: "┐", boxdr: "┌", boxhD: "╥", boxhU: "╨", boxhd: "┬", boxhu: "┴", boxminus: "⊟", minusb: "⊟", boxplus: "⊞", plusb: "⊞", boxtimes: "⊠", timesb: "⊠", boxuL: "╛", boxuR: "╘", boxul: "┘", boxur: "└", boxv: "│", boxvH: "╪", boxvL: "╡", boxvR: "╞", boxvh: "┼", boxvl: "┤", boxvr: "├", brvbar: "¦", bscr: "𝒷", bsemi: "⁏", bsol: "\\", bsolb: "⧅", bsolhsub: "⟈", bull: "•", bullet: "•", bumpE: "⪮", cacute: "ć", cap: "∩", capand: "⩄", capbrcup: "⩉", capcap: "⩋", capcup: "⩇", capdot: "⩀", caps: "∩︀", caret: "⁁", ccaps: "⩍", ccaron: "č", ccedil: "ç", ccirc: "ĉ", ccups: "⩌", ccupssm: "⩐", cdot: "ċ", cemptyv: "⦲", cent: "¢", cfr: "𝔠", chcy: "ч", check: "✓", checkmark: "✓", chi: "χ", cir: "○", cirE: "⧃", circ: "ˆ", circeq: "≗", cire: "≗", circlearrowleft: "↺", olarr: "↺", circlearrowright: "↻", orarr: "↻", circledS: "Ⓢ", oS: "Ⓢ", circledast: "⊛", oast: "⊛", circledcirc: "⊚", ocir: "⊚", circleddash: "⊝", odash: "⊝", cirfnint: "⨐", cirmid: "⫯", cirscir: "⧂", clubs: "♣", clubsuit: "♣", colon: ":", comma: ",", commat: "@", comp: "∁", complement: "∁", congdot: "⩭", copf: "𝕔", copysr: "℗", crarr: "↵", cross: "✗", cscr: "𝒸", csub: "⫏", csube: "⫑", csup: "⫐", csupe: "⫒", ctdot: "⋯", cudarrl: "⤸", cudarrr: "⤵", cuepr: "⋞", curlyeqprec: "⋞", cuesc: "⋟", curlyeqsucc: "⋟", cularr: "↶", curvearrowleft: "↶", cularrp: "⤽", cup: "∪", cupbrcap: "⩈", cupcap: "⩆", cupcup: "⩊", cupdot: "⊍", cupor: "⩅", cups: "∪︀", curarr: "↷", curvearrowright: "↷", curarrm: "⤼", curlyvee: "⋎", cuvee: "⋎", curlywedge: "⋏", cuwed: "⋏", curren: "¤", cwint: "∱", cylcty: "⌭", dHar: "⥥", dagger: "†", daleth: "ℸ", dash: "‐", hyphen: "‐", dbkarow: "⤏", rBarr: "⤏", dcaron: "ď", dcy: "д", ddarr: "⇊", downdownarrows: "⇊", ddotseq: "⩷", eDDot: "⩷", deg: "°", delta: "δ", demptyv: "⦱", dfisht: "⥿", dfr: "𝔡", diamondsuit: "♦", diams: "♦", digamma: "ϝ", gammad: "ϝ", disin: "⋲", div: "÷", divide: "÷", divideontimes: "⋇", divonx: "⋇", djcy: "ђ", dlcorn: "⌞", llcorner: "⌞", dlcrop: "⌍", dollar: "$", dopf: "𝕕", doteqdot: "≑", eDot: "≑", dotminus: "∸", minusd: "∸", dotplus: "∔", plusdo: "∔", dotsquare: "⊡", sdotb: "⊡", drcorn: "⌟", lrcorner: "⌟", drcrop: "⌌", dscr: "𝒹", dscy: "ѕ", dsol: "⧶", dstrok: "đ", dtdot: "⋱", dtri: "▿", triangledown: "▿", dwangle: "⦦", dzcy: "џ", dzigrarr: "⟿", eacute: "é", easter: "⩮", ecaron: "ě", ecir: "≖", eqcirc: "≖", ecirc: "ê", ecolon: "≕", eqcolon: "≕", ecy: "э", edot: "ė", efDot: "≒", fallingdotseq: "≒", efr: "𝔢", eg: "⪚", egrave: "è", egs: "⪖", eqslantgtr: "⪖", egsdot: "⪘", el: "⪙", elinters: "⏧", ell: "ℓ", els: "⪕", eqslantless: "⪕", elsdot: "⪗", emacr: "ē", empty: "∅", emptyset: "∅", emptyv: "∅", varnothing: "∅", emsp13: " ", emsp14: " ", emsp: " ", eng: "ŋ", ensp: " ", eogon: "ę", eopf: "𝕖", epar: "⋕", eparsl: "⧣", eplus: "⩱", epsi: "ε", epsilon: "ε", epsiv: "ϵ", straightepsilon: "ϵ", varepsilon: "ϵ", equals: "=", equest: "≟", questeq: "≟", equivDD: "⩸", eqvparsl: "⧥", erDot: "≓", risingdotseq: "≓", erarr: "⥱", escr: "ℯ", eta: "η", eth: "ð", euml: "ë", euro: "€", excl: "!", fcy: "ф", female: "♀", ffilig: "ffi", fflig: "ff", ffllig: "ffl", ffr: "𝔣", filig: "fi", fjlig: "fj", flat: "♭", fllig: "fl", fltns: "▱", fnof: "ƒ", fopf: "𝕗", fork: "⋔", pitchfork: "⋔", forkv: "⫙", fpartint: "⨍", frac12: "½", half: "½", frac13: "⅓", frac14: "¼", frac15: "⅕", frac16: "⅙", frac18: "⅛", frac23: "⅔", frac25: "⅖", frac34: "¾", frac35: "⅗", frac38: "⅜", frac45: "⅘", frac56: "⅚", frac58: "⅝", frac78: "⅞", frasl: "⁄", frown: "⌢", sfrown: "⌢", fscr: "𝒻", gEl: "⪌", gtreqqless: "⪌", gacute: "ǵ", gamma: "γ", gap: "⪆", gtrapprox: "⪆", gbreve: "ğ", gcirc: "ĝ", gcy: "г", gdot: "ġ", gescc: "⪩", gesdot: "⪀", gesdoto: "⪂", gesdotol: "⪄", gesl: "⋛︀", gesles: "⪔", gfr: "𝔤", gimel: "ℷ", gjcy: "ѓ", glE: "⪒", gla: "⪥", glj: "⪤", gnE: "≩", gneqq: "≩", gnap: "⪊", gnapprox: "⪊", gne: "⪈", gneq: "⪈", gnsim: "⋧", gopf: "𝕘", gscr: "ℊ", gsime: "⪎", gsiml: "⪐", gtcc: "⪧", gtcir: "⩺", gtdot: "⋗", gtrdot: "⋗", gtlPar: "⦕", gtquest: "⩼", gtrarr: "⥸", gvertneqq: "≩︀", gvnE: "≩︀", hardcy: "ъ", harrcir: "⥈", harrw: "↭", leftrightsquigarrow: "↭", hbar: "ℏ", hslash: "ℏ", planck: "ℏ", plankv: "ℏ", hcirc: "ĥ", hearts: "♥", heartsuit: "♥", hellip: "…", mldr: "…", hercon: "⊹", hfr: "𝔥", hksearow: "⤥", searhk: "⤥", hkswarow: "⤦", swarhk: "⤦", hoarr: "⇿", homtht: "∻", hookleftarrow: "↩", larrhk: "↩", hookrightarrow: "↪", rarrhk: "↪", hopf: "𝕙", horbar: "―", hscr: "𝒽", hstrok: "ħ", hybull: "⁃", iacute: "í", icirc: "î", icy: "и", iecy: "е", iexcl: "¡", ifr: "𝔦", igrave: "ì", iiiint: "⨌", qint: "⨌", iiint: "∭", tint: "∭", iinfin: "⧜", iiota: "℩", ijlig: "ij", imacr: "ī", imath: "ı", inodot: "ı", imof: "⊷", imped: "Ƶ", incare: "℅", infin: "∞", infintie: "⧝", intcal: "⊺", intercal: "⊺", intlarhk: "⨗", intprod: "⨼", iprod: "⨼", iocy: "ё", iogon: "į", iopf: "𝕚", iota: "ι", iquest: "¿", iscr: "𝒾", isinE: "⋹", isindot: "⋵", isins: "⋴", isinsv: "⋳", itilde: "ĩ", iukcy: "і", iuml: "ï", jcirc: "ĵ", jcy: "й", jfr: "𝔧", jmath: "ȷ", jopf: "𝕛", jscr: "𝒿", jsercy: "ј", jukcy: "є", kappa: "κ", kappav: "ϰ", varkappa: "ϰ", kcedil: "ķ", kcy: "к", kfr: "𝔨", kgreen: "ĸ", khcy: "х", kjcy: "ќ", kopf: "𝕜", kscr: "𝓀", lAtail: "⤛", lBarr: "⤎", lEg: "⪋", lesseqqgtr: "⪋", lHar: "⥢", lacute: "ĺ", laemptyv: "⦴", lambda: "λ", langd: "⦑", lap: "⪅", lessapprox: "⪅", laquo: "«", larrbfs: "⤟", larrfs: "⤝", larrlp: "↫", looparrowleft: "↫", larrpl: "⤹", larrsim: "⥳", larrtl: "↢", leftarrowtail: "↢", lat: "⪫", latail: "⤙", late: "⪭", lates: "⪭︀", lbarr: "⤌", lbbrk: "❲", lbrace: "{", lcub: "{", lbrack: "[", lsqb: "[", lbrke: "⦋", lbrksld: "⦏", lbrkslu: "⦍", lcaron: "ľ", lcedil: "ļ", lcy: "л", ldca: "⤶", ldrdhar: "⥧", ldrushar: "⥋", ldsh: "↲", le: "≤", leq: "≤", leftleftarrows: "⇇", llarr: "⇇", leftthreetimes: "⋋", lthree: "⋋", lescc: "⪨", lesdot: "⩿", lesdoto: "⪁", lesdotor: "⪃", lesg: "⋚︀", lesges: "⪓", lessdot: "⋖", ltdot: "⋖", lfisht: "⥼", lfr: "𝔩", lgE: "⪑", lharul: "⥪", lhblk: "▄", ljcy: "љ", llhard: "⥫", lltri: "◺", lmidot: "ŀ", lmoust: "⎰", lmoustache: "⎰", lnE: "≨", lneqq: "≨", lnap: "⪉", lnapprox: "⪉", lne: "⪇", lneq: "⪇", lnsim: "⋦", loang: "⟬", loarr: "⇽", longmapsto: "⟼", xmap: "⟼", looparrowright: "↬", rarrlp: "↬", lopar: "⦅", lopf: "𝕝", loplus: "⨭", lotimes: "⨴", lowast: "∗", loz: "◊", lozenge: "◊", lpar: "(", lparlt: "⦓", lrhard: "⥭", lrm: "", lrtri: "⊿", lsaquo: "‹", lscr: "𝓁", lsime: "⪍", lsimg: "⪏", lsquor: "‚", sbquo: "‚", lstrok: "ł", ltcc: "⪦", ltcir: "⩹", ltimes: "⋉", ltlarr: "⥶", ltquest: "⩻", ltrPar: "⦖", ltri: "◃", triangleleft: "◃", lurdshar: "⥊", luruhar: "⥦", lvertneqq: "≨︀", lvnE: "≨︀", mDDot: "∺", macr: "¯", strns: "¯", male: "♂", malt: "✠", maltese: "✠", marker: "▮", mcomma: "⨩", mcy: "м", mdash: "—", mfr: "𝔪", mho: "℧", micro: "µ", midcir: "⫰", minus: "−", minusdu: "⨪", mlcp: "⫛", models: "⊧", mopf: "𝕞", mscr: "𝓂", mu: "μ", multimap: "⊸", mumap: "⊸", nGg: "⋙̸", nGt: "≫⃒", nLeftarrow: "⇍", nlArr: "⇍", nLeftrightarrow: "⇎", nhArr: "⇎", nLl: "⋘̸", nLt: "≪⃒", nRightarrow: "⇏", nrArr: "⇏", nVDash: "⊯", nVdash: "⊮", nacute: "ń", nang: "∠⃒", napE: "⩰̸", napid: "≋̸", napos: "ʼn", natur: "♮", natural: "♮", ncap: "⩃", ncaron: "ň", ncedil: "ņ", ncongdot: "⩭̸", ncup: "⩂", ncy: "н", ndash: "–", neArr: "⇗", nearhk: "⤤", nedot: "≐̸", nesear: "⤨", toea: "⤨", nfr: "𝔫", nharr: "↮", nleftrightarrow: "↮", nhpar: "⫲", nis: "⋼", nisd: "⋺", njcy: "њ", nlE: "≦̸", nleqq: "≦̸", nlarr: "↚", nleftarrow: "↚", nldr: "‥", nopf: "𝕟", not: "¬", notinE: "⋹̸", notindot: "⋵̸", notinvb: "⋷", notinvc: "⋶", notnivb: "⋾", notnivc: "⋽", nparsl: "⫽⃥", npart: "∂̸", npolint: "⨔", nrarr: "↛", nrightarrow: "↛", nrarrc: "⤳̸", nrarrw: "↝̸", nscr: "𝓃", nsub: "⊄", nsubE: "⫅̸", nsubseteqq: "⫅̸", nsup: "⊅", nsupE: "⫆̸", nsupseteqq: "⫆̸", ntilde: "ñ", nu: "ν", num: "#", numero: "№", numsp: " ", nvDash: "⊭", nvHarr: "⤄", nvap: "≍⃒", nvdash: "⊬", nvge: "≥⃒", nvgt: ">⃒", nvinfin: "⧞", nvlArr: "⤂", nvle: "≤⃒", nvlt: "<⃒", nvltrie: "⊴⃒", nvrArr: "⤃", nvrtrie: "⊵⃒", nvsim: "∼⃒", nwArr: "⇖", nwarhk: "⤣", nwnear: "⤧", oacute: "ó", ocirc: "ô", ocy: "о", odblac: "ő", odiv: "⨸", odsold: "⦼", oelig: "œ", ofcir: "⦿", ofr: "𝔬", ogon: "˛", ograve: "ò", ogt: "⧁", ohbar: "⦵", olcir: "⦾", olcross: "⦻", olt: "⧀", omacr: "ō", omega: "ω", omicron: "ο", omid: "⦶", oopf: "𝕠", opar: "⦷", operp: "⦹", or: "∨", vee: "∨", ord: "⩝", order: "ℴ", orderof: "ℴ", oscr: "ℴ", ordf: "ª", ordm: "º", origof: "⊶", oror: "⩖", orslope: "⩗", orv: "⩛", oslash: "ø", osol: "⊘", otilde: "õ", otimesas: "⨶", ouml: "ö", ovbar: "⌽", para: "¶", parsim: "⫳", parsl: "⫽", pcy: "п", percnt: "%", period: ".", permil: "‰", pertenk: "‱", pfr: "𝔭", phi: "φ", phiv: "ϕ", straightphi: "ϕ", varphi: "ϕ", phone: "☎", pi: "π", piv: "ϖ", varpi: "ϖ", planckh: "ℎ", plus: "+", plusacir: "⨣", pluscir: "⨢", plusdu: "⨥", pluse: "⩲", plussim: "⨦", plustwo: "⨧", pointint: "⨕", popf: "𝕡", pound: "£", prE: "⪳", prap: "⪷", precapprox: "⪷", precnapprox: "⪹", prnap: "⪹", precneqq: "⪵", prnE: "⪵", precnsim: "⋨", prnsim: "⋨", prime: "′", profalar: "⌮", profline: "⌒", profsurf: "⌓", prurel: "⊰", pscr: "𝓅", psi: "ψ", puncsp: " ", qfr: "𝔮", qopf: "𝕢", qprime: "⁗", qscr: "𝓆", quatint: "⨖", quest: "?", rAtail: "⤜", rHar: "⥤", race: "∽̱", racute: "ŕ", raemptyv: "⦳", rangd: "⦒", range: "⦥", raquo: "»", rarrap: "⥵", rarrbfs: "⤠", rarrc: "⤳", rarrfs: "⤞", rarrpl: "⥅", rarrsim: "⥴", rarrtl: "↣", rightarrowtail: "↣", rarrw: "↝", rightsquigarrow: "↝", ratail: "⤚", ratio: "∶", rbbrk: "❳", rbrace: "}", rcub: "}", rbrack: "]", rsqb: "]", rbrke: "⦌", rbrksld: "⦎", rbrkslu: "⦐", rcaron: "ř", rcedil: "ŗ", rcy: "р", rdca: "⤷", rdldhar: "⥩", rdsh: "↳", rect: "▭", rfisht: "⥽", rfr: "𝔯", rharul: "⥬", rho: "ρ", rhov: "ϱ", varrho: "ϱ", rightrightarrows: "⇉", rrarr: "⇉", rightthreetimes: "⋌", rthree: "⋌", ring: "˚", rlm: "", rmoust: "⎱", rmoustache: "⎱", rnmid: "⫮", roang: "⟭", roarr: "⇾", ropar: "⦆", ropf: "𝕣", roplus: "⨮", rotimes: "⨵", rpar: ")", rpargt: "⦔", rppolint: "⨒", rsaquo: "›", rscr: "𝓇", rtimes: "⋊", rtri: "▹", triangleright: "▹", rtriltri: "⧎", ruluhar: "⥨", rx: "℞", sacute: "ś", scE: "⪴", scap: "⪸", succapprox: "⪸", scaron: "š", scedil: "ş", scirc: "ŝ", scnE: "⪶", succneqq: "⪶", scnap: "⪺", succnapprox: "⪺", scnsim: "⋩", succnsim: "⋩", scpolint: "⨓", scy: "с", sdot: "⋅", sdote: "⩦", seArr: "⇘", sect: "§", semi: ";", seswar: "⤩", tosa: "⤩", sext: "✶", sfr: "𝔰", sharp: "♯", shchcy: "щ", shcy: "ш", shy: "", sigma: "σ", sigmaf: "ς", sigmav: "ς", varsigma: "ς", simdot: "⩪", simg: "⪞", simgE: "⪠", siml: "⪝", simlE: "⪟", simne: "≆", simplus: "⨤", simrarr: "⥲", smashp: "⨳", smeparsl: "⧤", smile: "⌣", ssmile: "⌣", smt: "⪪", smte: "⪬", smtes: "⪬︀", softcy: "ь", sol: "/", solb: "⧄", solbar: "⌿", sopf: "𝕤", spades: "♠", spadesuit: "♠", sqcaps: "⊓︀", sqcups: "⊔︀", sscr: "𝓈", star: "☆", sub: "⊂", subset: "⊂", subE: "⫅", subseteqq: "⫅", subdot: "⪽", subedot: "⫃", submult: "⫁", subnE: "⫋", subsetneqq: "⫋", subne: "⊊", subsetneq: "⊊", subplus: "⪿", subrarr: "⥹", subsim: "⫇", subsub: "⫕", subsup: "⫓", sung: "♪", sup1: "¹", sup2: "²", sup3: "³", supE: "⫆", supseteqq: "⫆", supdot: "⪾", supdsub: "⫘", supedot: "⫄", suphsol: "⟉", suphsub: "⫗", suplarr: "⥻", supmult: "⫂", supnE: "⫌", supsetneqq: "⫌", supne: "⊋", supsetneq: "⊋", supplus: "⫀", supsim: "⫈", supsub: "⫔", supsup: "⫖", swArr: "⇙", swnwar: "⤪", szlig: "ß", target: "⌖", tau: "τ", tcaron: "ť", tcedil: "ţ", tcy: "т", telrec: "⌕", tfr: "𝔱", theta: "θ", thetasym: "ϑ", thetav: "ϑ", vartheta: "ϑ", thorn: "þ", times: "×", timesbar: "⨱", timesd: "⨰", topbot: "⌶", topcir: "⫱", topf: "𝕥", topfork: "⫚", tprime: "‴", triangle: "▵", utri: "▵", triangleq: "≜", trie: "≜", tridot: "◬", triminus: "⨺", triplus: "⨹", trisb: "⧍", tritime: "⨻", trpezium: "⏢", tscr: "𝓉", tscy: "ц", tshcy: "ћ", tstrok: "ŧ", uHar: "⥣", uacute: "ú", ubrcy: "ў", ubreve: "ŭ", ucirc: "û", ucy: "у", udblac: "ű", ufisht: "⥾", ufr: "𝔲", ugrave: "ù", uhblk: "▀", ulcorn: "⌜", ulcorner: "⌜", ulcrop: "⌏", ultri: "◸", umacr: "ū", uogon: "ų", uopf: "𝕦", upsi: "υ", upsilon: "υ", upuparrows: "⇈", uuarr: "⇈", urcorn: "⌝", urcorner: "⌝", urcrop: "⌎", uring: "ů", urtri: "◹", uscr: "𝓊", utdot: "⋰", utilde: "ũ", uuml: "ü", uwangle: "⦧", vBar: "⫨", vBarv: "⫩", vangrt: "⦜", varsubsetneq: "⊊︀", vsubne: "⊊︀", varsubsetneqq: "⫋︀", vsubnE: "⫋︀", varsupsetneq: "⊋︀", vsupne: "⊋︀", varsupsetneqq: "⫌︀", vsupnE: "⫌︀", vcy: "в", veebar: "⊻", veeeq: "≚", vellip: "⋮", vfr: "𝔳", vopf: "𝕧", vscr: "𝓋", vzigzag: "⦚", wcirc: "ŵ", wedbar: "⩟", wedgeq: "≙", weierp: "℘", wp: "℘", wfr: "𝔴", wopf: "𝕨", wscr: "𝓌", xfr: "𝔵", xi: "ξ", xnis: "⋻", xopf: "𝕩", xscr: "𝓍", yacute: "ý", yacy: "я", ycirc: "ŷ", ycy: "ы", yen: "¥", yfr: "𝔶", yicy: "ї", yopf: "𝕪", yscr: "𝓎", yucy: "ю", yuml: "ÿ", zacute: "ź", zcaron: "ž", zcy: "з", zdot: "ż", zeta: "ζ", zfr: "𝔷", zhcy: "ж", zigrarr: "⇝", zopf: "𝕫", zscr: "𝓏", zwj: "", zwnj: "" }, ms = "";
|
|
1646
|
-
Fe.ngsp = ms;
|
|
1647
|
-
var gs = [/@/, /^\s*$/, /[<>]/, /^[{}]$/, /&(#|[a-z])/i, /^\/\//];
|
|
1648
|
-
function fs(e, t) {
|
|
1649
|
-
if (t != null && !(Array.isArray(t) && t.length == 2))
|
|
1650
|
-
throw new Error(`Expected '${e}' to be an array, [start, end].`);
|
|
1651
|
-
if (t != null) {
|
|
1652
|
-
let r = t[0], n = t[1];
|
|
1653
|
-
gs.forEach((a) => {
|
|
1654
|
-
if (a.test(r) || a.test(n))
|
|
1655
|
-
throw new Error(`['${r}', '${n}'] contains unusable interpolation symbol.`);
|
|
1656
|
-
});
|
|
1657
|
-
}
|
|
1658
|
-
}
|
|
1659
|
-
var vs = class Qr {
|
|
1660
|
-
static fromArray(t) {
|
|
1661
|
-
return t ? (fs("interpolation", t), new Qr(t[0], t[1])) : Zr;
|
|
1662
|
-
}
|
|
1663
|
-
constructor(t, r) {
|
|
1664
|
-
this.start = t, this.end = r;
|
|
1665
|
-
}
|
|
1666
|
-
}, Zr = new vs("{{", "}}"), Ge = class extends Kr {
|
|
1667
|
-
constructor(e, t, r) {
|
|
1668
|
-
super(r, e), this.tokenType = t;
|
|
1669
|
-
}
|
|
1670
|
-
}, Cs = class {
|
|
1671
|
-
constructor(e, t, r) {
|
|
1672
|
-
this.tokens = e, this.errors = t, this.nonNormalizedIcuExpressions = r;
|
|
1673
|
-
}
|
|
1674
|
-
};
|
|
1675
|
-
function Ss(e, t, r, n = {}) {
|
|
1676
|
-
let a = new _s(new Gr(e, t), r, n);
|
|
1677
|
-
return a.tokenize(), new Cs(Ds(a.tokens), a.errors, a.nonNormalizedIcuExpressions);
|
|
1678
|
-
}
|
|
1679
|
-
var ys = /\r\n?/g;
|
|
1680
|
-
function X(e) {
|
|
1681
|
-
return `Unexpected character "${e === 0 ? "EOF" : String.fromCharCode(e)}"`;
|
|
1682
|
-
}
|
|
1683
|
-
function Kt(e) {
|
|
1684
|
-
return `Unknown entity "${e}" - use the "&#<decimal>;" or "&#x<hex>;" syntax`;
|
|
1685
|
-
}
|
|
1686
|
-
function bs(e, t) {
|
|
1687
|
-
return `Unable to parse entity "${t}" - ${e} character reference entities must end with ";"`;
|
|
1688
|
-
}
|
|
1689
|
-
var qe;
|
|
1690
|
-
(function(e) {
|
|
1691
|
-
e.HEX = "hexadecimal", e.DEC = "decimal";
|
|
1692
|
-
})(qe || (qe = {}));
|
|
1693
|
-
var Ke = class {
|
|
1694
|
-
constructor(e) {
|
|
1695
|
-
this.error = e;
|
|
1696
|
-
}
|
|
1697
|
-
}, _s = class {
|
|
1698
|
-
constructor(e, t, r) {
|
|
1699
|
-
this._getTagContentType = t, this._currentTokenStart = null, this._currentTokenType = null, this._expansionCaseStack = [], this._inInterpolation = !1, this._fullNameStack = [], this.tokens = [], this.errors = [], this.nonNormalizedIcuExpressions = [], this._tokenizeIcu = r.tokenizeExpansionForms || !1, this._interpolationConfig = r.interpolationConfig || Zr, this._leadingTriviaCodePoints = r.leadingTriviaChars && r.leadingTriviaChars.map((a) => a.codePointAt(0) || 0), this._canSelfClose = r.canSelfClose || !1, this._allowHtmComponentClosingTags = r.allowHtmComponentClosingTags || !1;
|
|
1700
|
-
let n = r.range || { endPos: e.content.length, startPos: 0, startLine: 0, startCol: 0 };
|
|
1701
|
-
this._cursor = r.escapedString ? new Ts(e, n) : new en(e, n), this._preserveLineEndings = r.preserveLineEndings || !1, this._i18nNormalizeLineEndingsInICUs = r.i18nNormalizeLineEndingsInICUs || !1, this._tokenizeBlocks = r.tokenizeBlocks ?? !0, this._tokenizeLet = r.tokenizeLet ?? !0;
|
|
1702
|
-
try {
|
|
1703
|
-
this._cursor.init();
|
|
1704
|
-
} catch (a) {
|
|
1705
|
-
this.handleError(a);
|
|
1706
|
-
}
|
|
1707
|
-
}
|
|
1708
|
-
_processCarriageReturns(e) {
|
|
1709
|
-
return this._preserveLineEndings ? e : e.replace(ys, `
|
|
1710
|
-
`);
|
|
1711
|
-
}
|
|
1712
|
-
tokenize() {
|
|
1713
|
-
for (; this._cursor.peek() !== 0; ) {
|
|
1714
|
-
let e = this._cursor.clone();
|
|
1715
|
-
try {
|
|
1716
|
-
if (this._attemptCharCode(60))
|
|
1717
|
-
if (this._attemptCharCode(33))
|
|
1718
|
-
this._attemptStr("[CDATA[") ? this._consumeCdata(e) : this._attemptStr("--") ? this._consumeComment(e) : this._attemptStrCaseInsensitive("doctype") ? this._consumeDocType(e) : this._consumeBogusComment(e);
|
|
1719
|
-
else if (this._attemptCharCode(47))
|
|
1720
|
-
this._consumeTagClose(e);
|
|
1721
|
-
else {
|
|
1722
|
-
let t = this._cursor.clone();
|
|
1723
|
-
this._attemptCharCode(63) ? (this._cursor = t, this._consumeBogusComment(e)) : this._consumeTagOpen(e);
|
|
1724
|
-
}
|
|
1725
|
-
else
|
|
1726
|
-
this._tokenizeLet && this._cursor.peek() === 64 && !this._inInterpolation && this._attemptStr("@let") ? this._consumeLetDeclaration(e) : this._tokenizeBlocks && this._attemptCharCode(64) ? this._consumeBlockStart(e) : this._tokenizeBlocks && !this._inInterpolation && !this._isInExpansionCase() && !this._isInExpansionForm() && this._attemptCharCode(125) ? this._consumeBlockEnd(e) : this._tokenizeIcu && this._tokenizeExpansionForm() || this._consumeWithInterpolation(5, 8, () => this._isTextEnd(), () => this._isTagStart());
|
|
1727
|
-
} catch (t) {
|
|
1728
|
-
this.handleError(t);
|
|
1729
|
-
}
|
|
1730
|
-
}
|
|
1731
|
-
this._beginToken(34), this._endToken([]);
|
|
1732
|
-
}
|
|
1733
|
-
_getBlockName() {
|
|
1734
|
-
let e = !1, t = this._cursor.clone();
|
|
1735
|
-
return this._attemptCharCodeUntilFn((r) => De(r) ? !e : Jt(r) ? (e = !0, !1) : !0), this._cursor.getChars(t).trim();
|
|
1736
|
-
}
|
|
1737
|
-
_consumeBlockStart(e) {
|
|
1738
|
-
this._beginToken(25, e);
|
|
1739
|
-
let t = this._endToken([this._getBlockName()]);
|
|
1740
|
-
if (this._cursor.peek() === 40)
|
|
1741
|
-
if (this._cursor.advance(), this._consumeBlockParameters(), this._attemptCharCodeUntilFn(b), this._attemptCharCode(41))
|
|
1742
|
-
this._attemptCharCodeUntilFn(b);
|
|
1743
|
-
else {
|
|
1744
|
-
t.type = 29;
|
|
1745
|
-
return;
|
|
1746
|
-
}
|
|
1747
|
-
this._attemptCharCode(123) ? (this._beginToken(26), this._endToken([])) : t.type = 29;
|
|
1748
|
-
}
|
|
1749
|
-
_consumeBlockEnd(e) {
|
|
1750
|
-
this._beginToken(27, e), this._endToken([]);
|
|
1751
|
-
}
|
|
1752
|
-
_consumeBlockParameters() {
|
|
1753
|
-
for (this._attemptCharCodeUntilFn(Qt); this._cursor.peek() !== 41 && this._cursor.peek() !== 0; ) {
|
|
1754
|
-
this._beginToken(28);
|
|
1755
|
-
let e = this._cursor.clone(), t = null, r = 0;
|
|
1756
|
-
for (; this._cursor.peek() !== 59 && this._cursor.peek() !== 0 || t !== null; ) {
|
|
1757
|
-
let n = this._cursor.peek();
|
|
1758
|
-
if (n === 92)
|
|
1759
|
-
this._cursor.advance();
|
|
1760
|
-
else if (n === t)
|
|
1761
|
-
t = null;
|
|
1762
|
-
else if (t === null && je(n))
|
|
1763
|
-
t = n;
|
|
1764
|
-
else if (n === 40 && t === null)
|
|
1765
|
-
r++;
|
|
1766
|
-
else if (n === 41 && t === null) {
|
|
1767
|
-
if (r === 0)
|
|
1768
|
-
break;
|
|
1769
|
-
r > 0 && r--;
|
|
1770
|
-
}
|
|
1771
|
-
this._cursor.advance();
|
|
1772
|
-
}
|
|
1773
|
-
this._endToken([this._cursor.getChars(e)]), this._attemptCharCodeUntilFn(Qt);
|
|
1774
|
-
}
|
|
1775
|
-
}
|
|
1776
|
-
_consumeLetDeclaration(e) {
|
|
1777
|
-
if (this._beginToken(30, e), De(this._cursor.peek()))
|
|
1778
|
-
this._attemptCharCodeUntilFn(b);
|
|
1779
|
-
else {
|
|
1780
|
-
let r = this._endToken([this._cursor.getChars(e)]);
|
|
1781
|
-
r.type = 33;
|
|
1782
|
-
return;
|
|
1783
|
-
}
|
|
1784
|
-
let t = this._endToken([this._getLetDeclarationName()]);
|
|
1785
|
-
if (this._attemptCharCodeUntilFn(b), !this._attemptCharCode(61)) {
|
|
1786
|
-
t.type = 33;
|
|
1787
|
-
return;
|
|
1788
|
-
}
|
|
1789
|
-
this._attemptCharCodeUntilFn((r) => b(r) && !_t(r)), this._consumeLetDeclarationValue(), this._cursor.peek() === 59 ? (this._beginToken(32), this._endToken([]), this._cursor.advance()) : (t.type = 33, t.sourceSpan = this._cursor.getSpan(e));
|
|
1790
|
-
}
|
|
1791
|
-
_getLetDeclarationName() {
|
|
1792
|
-
let e = this._cursor.clone(), t = !1;
|
|
1793
|
-
return this._attemptCharCodeUntilFn((r) => Te(r) || r === 36 || r === 95 || t && bt(r) ? (t = !0, !1) : !0), this._cursor.getChars(e).trim();
|
|
1794
|
-
}
|
|
1795
|
-
_consumeLetDeclarationValue() {
|
|
1796
|
-
let e = this._cursor.clone();
|
|
1797
|
-
for (this._beginToken(31, e); this._cursor.peek() !== 0; ) {
|
|
1798
|
-
let t = this._cursor.peek();
|
|
1799
|
-
if (t === 59)
|
|
1800
|
-
break;
|
|
1801
|
-
je(t) && (this._cursor.advance(), this._attemptCharCodeUntilFn((r) => r === 92 ? (this._cursor.advance(), !1) : r === t)), this._cursor.advance();
|
|
1802
|
-
}
|
|
1803
|
-
this._endToken([this._cursor.getChars(e)]);
|
|
1804
|
-
}
|
|
1805
|
-
_tokenizeExpansionForm() {
|
|
1806
|
-
if (this.isExpansionFormStart())
|
|
1807
|
-
return this._consumeExpansionFormStart(), !0;
|
|
1808
|
-
if (Es(this._cursor.peek()) && this._isInExpansionForm())
|
|
1809
|
-
return this._consumeExpansionCaseStart(), !0;
|
|
1810
|
-
if (this._cursor.peek() === 125) {
|
|
1811
|
-
if (this._isInExpansionCase())
|
|
1812
|
-
return this._consumeExpansionCaseEnd(), !0;
|
|
1813
|
-
if (this._isInExpansionForm())
|
|
1814
|
-
return this._consumeExpansionFormEnd(), !0;
|
|
1815
|
-
}
|
|
1816
|
-
return !1;
|
|
1817
|
-
}
|
|
1818
|
-
_beginToken(e, t = this._cursor.clone()) {
|
|
1819
|
-
this._currentTokenStart = t, this._currentTokenType = e;
|
|
1820
|
-
}
|
|
1821
|
-
_endToken(e, t) {
|
|
1822
|
-
if (this._currentTokenStart === null)
|
|
1823
|
-
throw new Ge("Programming error - attempted to end a token when there was no start to the token", this._currentTokenType, this._cursor.getSpan(t));
|
|
1824
|
-
if (this._currentTokenType === null)
|
|
1825
|
-
throw new Ge("Programming error - attempted to end a token which has no token type", null, this._cursor.getSpan(this._currentTokenStart));
|
|
1826
|
-
let r = { type: this._currentTokenType, parts: e, sourceSpan: (t ?? this._cursor).getSpan(this._currentTokenStart, this._leadingTriviaCodePoints) };
|
|
1827
|
-
return this.tokens.push(r), this._currentTokenStart = null, this._currentTokenType = null, r;
|
|
1828
|
-
}
|
|
1829
|
-
_createError(e, t) {
|
|
1830
|
-
this._isInExpansionForm() && (e += ` (Do you have an unescaped "{" in your template? Use "{{ '{' }}") to escape it.)`);
|
|
1831
|
-
let r = new Ge(e, this._currentTokenType, t);
|
|
1832
|
-
return this._currentTokenStart = null, this._currentTokenType = null, new Ke(r);
|
|
1833
|
-
}
|
|
1834
|
-
handleError(e) {
|
|
1835
|
-
if (e instanceof wt && (e = this._createError(e.msg, this._cursor.getSpan(e.cursor))), e instanceof Ke)
|
|
1836
|
-
this.errors.push(e.error);
|
|
1837
|
-
else
|
|
1838
|
-
throw e;
|
|
1839
|
-
}
|
|
1840
|
-
_attemptCharCode(e) {
|
|
1841
|
-
return this._cursor.peek() === e ? (this._cursor.advance(), !0) : !1;
|
|
1842
|
-
}
|
|
1843
|
-
_attemptCharCodeCaseInsensitive(e) {
|
|
1844
|
-
return xs(this._cursor.peek(), e) ? (this._cursor.advance(), !0) : !1;
|
|
1845
|
-
}
|
|
1846
|
-
_requireCharCode(e) {
|
|
1847
|
-
let t = this._cursor.clone();
|
|
1848
|
-
if (!this._attemptCharCode(e))
|
|
1849
|
-
throw this._createError(X(this._cursor.peek()), this._cursor.getSpan(t));
|
|
1850
|
-
}
|
|
1851
|
-
_attemptStr(e) {
|
|
1852
|
-
let t = e.length;
|
|
1853
|
-
if (this._cursor.charsLeft() < t)
|
|
1854
|
-
return !1;
|
|
1855
|
-
let r = this._cursor.clone();
|
|
1856
|
-
for (let n = 0; n < t; n++)
|
|
1857
|
-
if (!this._attemptCharCode(e.charCodeAt(n)))
|
|
1858
|
-
return this._cursor = r, !1;
|
|
1859
|
-
return !0;
|
|
1860
|
-
}
|
|
1861
|
-
_attemptStrCaseInsensitive(e) {
|
|
1862
|
-
for (let t = 0; t < e.length; t++)
|
|
1863
|
-
if (!this._attemptCharCodeCaseInsensitive(e.charCodeAt(t)))
|
|
1864
|
-
return !1;
|
|
1865
|
-
return !0;
|
|
1866
|
-
}
|
|
1867
|
-
_requireStr(e) {
|
|
1868
|
-
let t = this._cursor.clone();
|
|
1869
|
-
if (!this._attemptStr(e))
|
|
1870
|
-
throw this._createError(X(this._cursor.peek()), this._cursor.getSpan(t));
|
|
1871
|
-
}
|
|
1872
|
-
_requireStrCaseInsensitive(e) {
|
|
1873
|
-
let t = this._cursor.clone();
|
|
1874
|
-
if (!this._attemptStrCaseInsensitive(e))
|
|
1875
|
-
throw this._createError(X(this._cursor.peek()), this._cursor.getSpan(t));
|
|
1876
|
-
}
|
|
1877
|
-
_attemptCharCodeUntilFn(e) {
|
|
1878
|
-
for (; !e(this._cursor.peek()); )
|
|
1879
|
-
this._cursor.advance();
|
|
1880
|
-
}
|
|
1881
|
-
_requireCharCodeUntilFn(e, t) {
|
|
1882
|
-
let r = this._cursor.clone();
|
|
1883
|
-
if (this._attemptCharCodeUntilFn(e), this._cursor.diff(r) < t)
|
|
1884
|
-
throw this._createError(X(this._cursor.peek()), this._cursor.getSpan(r));
|
|
1885
|
-
}
|
|
1886
|
-
_attemptUntilChar(e) {
|
|
1887
|
-
for (; this._cursor.peek() !== e; )
|
|
1888
|
-
this._cursor.advance();
|
|
1889
|
-
}
|
|
1890
|
-
_readChar() {
|
|
1891
|
-
let e = String.fromCodePoint(this._cursor.peek());
|
|
1892
|
-
return this._cursor.advance(), e;
|
|
1893
|
-
}
|
|
1894
|
-
_consumeEntity(e) {
|
|
1895
|
-
this._beginToken(9);
|
|
1896
|
-
let t = this._cursor.clone();
|
|
1897
|
-
if (this._cursor.advance(), this._attemptCharCode(35)) {
|
|
1898
|
-
let r = this._attemptCharCode(120) || this._attemptCharCode(88), n = this._cursor.clone();
|
|
1899
|
-
if (this._attemptCharCodeUntilFn(As), this._cursor.peek() != 59) {
|
|
1900
|
-
this._cursor.advance();
|
|
1901
|
-
let i = r ? qe.HEX : qe.DEC;
|
|
1902
|
-
throw this._createError(bs(i, this._cursor.getChars(t)), this._cursor.getSpan());
|
|
1903
|
-
}
|
|
1904
|
-
let a = this._cursor.getChars(n);
|
|
1905
|
-
this._cursor.advance();
|
|
1906
|
-
try {
|
|
1907
|
-
let i = parseInt(a, r ? 16 : 10);
|
|
1908
|
-
this._endToken([String.fromCharCode(i), this._cursor.getChars(t)]);
|
|
1909
|
-
} catch {
|
|
1910
|
-
throw this._createError(Kt(this._cursor.getChars(t)), this._cursor.getSpan());
|
|
1911
|
-
}
|
|
1912
|
-
} else {
|
|
1913
|
-
let r = this._cursor.clone();
|
|
1914
|
-
if (this._attemptCharCodeUntilFn(ks), this._cursor.peek() != 59)
|
|
1915
|
-
this._beginToken(e, t), this._cursor = r, this._endToken(["&"]);
|
|
1916
|
-
else {
|
|
1917
|
-
let n = this._cursor.getChars(r);
|
|
1918
|
-
this._cursor.advance();
|
|
1919
|
-
let a = Fe[n];
|
|
1920
|
-
if (!a)
|
|
1921
|
-
throw this._createError(Kt(n), this._cursor.getSpan(t));
|
|
1922
|
-
this._endToken([a, `&${n};`]);
|
|
1923
|
-
}
|
|
1924
|
-
}
|
|
1925
|
-
}
|
|
1926
|
-
_consumeRawText(e, t) {
|
|
1927
|
-
this._beginToken(e ? 6 : 7);
|
|
1928
|
-
let r = [];
|
|
1929
|
-
for (; ; ) {
|
|
1930
|
-
let n = this._cursor.clone(), a = t();
|
|
1931
|
-
if (this._cursor = n, a)
|
|
1932
|
-
break;
|
|
1933
|
-
e && this._cursor.peek() === 38 ? (this._endToken([this._processCarriageReturns(r.join(""))]), r.length = 0, this._consumeEntity(6), this._beginToken(6)) : r.push(this._readChar());
|
|
1934
|
-
}
|
|
1935
|
-
this._endToken([this._processCarriageReturns(r.join(""))]);
|
|
1936
|
-
}
|
|
1937
|
-
_consumeComment(e) {
|
|
1938
|
-
this._beginToken(10, e), this._endToken([]), this._consumeRawText(!1, () => this._attemptStr("-->")), this._beginToken(11), this._requireStr("-->"), this._endToken([]);
|
|
1939
|
-
}
|
|
1940
|
-
_consumeBogusComment(e) {
|
|
1941
|
-
this._beginToken(10, e), this._endToken([]), this._consumeRawText(!1, () => this._cursor.peek() === 62), this._beginToken(11), this._cursor.advance(), this._endToken([]);
|
|
1942
|
-
}
|
|
1943
|
-
_consumeCdata(e) {
|
|
1944
|
-
this._beginToken(12, e), this._endToken([]), this._consumeRawText(!1, () => this._attemptStr("]]>")), this._beginToken(13), this._requireStr("]]>"), this._endToken([]);
|
|
1945
|
-
}
|
|
1946
|
-
_consumeDocType(e) {
|
|
1947
|
-
this._beginToken(18, e), this._endToken([]), this._consumeRawText(!1, () => this._cursor.peek() === 62), this._beginToken(19), this._cursor.advance(), this._endToken([]);
|
|
1948
|
-
}
|
|
1949
|
-
_consumePrefixAndName() {
|
|
1950
|
-
let e = this._cursor.clone(), t = "";
|
|
1951
|
-
for (; this._cursor.peek() !== 58 && !ws(this._cursor.peek()); )
|
|
1952
|
-
this._cursor.advance();
|
|
1953
|
-
let r;
|
|
1954
|
-
this._cursor.peek() === 58 ? (t = this._cursor.getChars(e), this._cursor.advance(), r = this._cursor.clone()) : r = e, this._requireCharCodeUntilFn(Xt, t === "" ? 0 : 1);
|
|
1955
|
-
let n = this._cursor.getChars(r);
|
|
1956
|
-
return [t, n];
|
|
1957
|
-
}
|
|
1958
|
-
_consumeTagOpen(e) {
|
|
1959
|
-
let t, r, n, a = [];
|
|
1960
|
-
try {
|
|
1961
|
-
if (!Te(this._cursor.peek()))
|
|
1962
|
-
throw this._createError(X(this._cursor.peek()), this._cursor.getSpan(e));
|
|
1963
|
-
for (n = this._consumeTagOpenStart(e), r = n.parts[0], t = n.parts[1], this._attemptCharCodeUntilFn(b); this._cursor.peek() !== 47 && this._cursor.peek() !== 62 && this._cursor.peek() !== 60 && this._cursor.peek() !== 0; ) {
|
|
1964
|
-
let [s, u] = this._consumeAttributeName();
|
|
1965
|
-
if (this._attemptCharCodeUntilFn(b), this._attemptCharCode(61)) {
|
|
1966
|
-
this._attemptCharCodeUntilFn(b);
|
|
1967
|
-
let o = this._consumeAttributeValue();
|
|
1968
|
-
a.push({ prefix: s, name: u, value: o });
|
|
1969
|
-
} else
|
|
1970
|
-
a.push({ prefix: s, name: u });
|
|
1971
|
-
this._attemptCharCodeUntilFn(b);
|
|
1972
|
-
}
|
|
1973
|
-
this._consumeTagOpenEnd();
|
|
1974
|
-
} catch (s) {
|
|
1975
|
-
if (s instanceof Ke) {
|
|
1976
|
-
n ? n.type = 4 : (this._beginToken(5, e), this._endToken(["<"]));
|
|
1977
|
-
return;
|
|
1978
|
-
}
|
|
1979
|
-
throw s;
|
|
1980
|
-
}
|
|
1981
|
-
if (this._canSelfClose && this.tokens[this.tokens.length - 1].type === 2)
|
|
1982
|
-
return;
|
|
1983
|
-
let i = this._getTagContentType(t, r, this._fullNameStack.length > 0, a);
|
|
1984
|
-
this._handleFullNameStackForTagOpen(r, t), i === I.RAW_TEXT ? this._consumeRawTextWithTagClose(r, t, !1) : i === I.ESCAPABLE_RAW_TEXT && this._consumeRawTextWithTagClose(r, t, !0);
|
|
1985
|
-
}
|
|
1986
|
-
_consumeRawTextWithTagClose(e, t, r) {
|
|
1987
|
-
this._consumeRawText(r, () => !this._attemptCharCode(60) || !this._attemptCharCode(47) || (this._attemptCharCodeUntilFn(b), !this._attemptStrCaseInsensitive(e ? `${e}:${t}` : t)) ? !1 : (this._attemptCharCodeUntilFn(b), this._attemptCharCode(62))), this._beginToken(3), this._requireCharCodeUntilFn((n) => n === 62, 3), this._cursor.advance(), this._endToken([e, t]), this._handleFullNameStackForTagClose(e, t);
|
|
1988
|
-
}
|
|
1989
|
-
_consumeTagOpenStart(e) {
|
|
1990
|
-
this._beginToken(0, e);
|
|
1991
|
-
let t = this._consumePrefixAndName();
|
|
1992
|
-
return this._endToken(t);
|
|
1993
|
-
}
|
|
1994
|
-
_consumeAttributeName() {
|
|
1995
|
-
let e = this._cursor.peek();
|
|
1996
|
-
if (e === 39 || e === 34)
|
|
1997
|
-
throw this._createError(X(e), this._cursor.getSpan());
|
|
1998
|
-
this._beginToken(14);
|
|
1999
|
-
let t = this._consumePrefixAndName();
|
|
2000
|
-
return this._endToken(t), t;
|
|
2001
|
-
}
|
|
2002
|
-
_consumeAttributeValue() {
|
|
2003
|
-
let e;
|
|
2004
|
-
if (this._cursor.peek() === 39 || this._cursor.peek() === 34) {
|
|
2005
|
-
let t = this._cursor.peek();
|
|
2006
|
-
this._consumeQuote(t);
|
|
2007
|
-
let r = () => this._cursor.peek() === t;
|
|
2008
|
-
e = this._consumeWithInterpolation(16, 17, r, r), this._consumeQuote(t);
|
|
2009
|
-
} else {
|
|
2010
|
-
let t = () => Xt(this._cursor.peek());
|
|
2011
|
-
e = this._consumeWithInterpolation(16, 17, t, t);
|
|
2012
|
-
}
|
|
2013
|
-
return e;
|
|
2014
|
-
}
|
|
2015
|
-
_consumeQuote(e) {
|
|
2016
|
-
this._beginToken(15), this._requireCharCode(e), this._endToken([String.fromCodePoint(e)]);
|
|
2017
|
-
}
|
|
2018
|
-
_consumeTagOpenEnd() {
|
|
2019
|
-
let e = this._attemptCharCode(47) ? 2 : 1;
|
|
2020
|
-
this._beginToken(e), this._requireCharCode(62), this._endToken([]);
|
|
2021
|
-
}
|
|
2022
|
-
_consumeTagClose(e) {
|
|
2023
|
-
if (this._beginToken(3, e), this._attemptCharCodeUntilFn(b), this._allowHtmComponentClosingTags && this._attemptCharCode(47))
|
|
2024
|
-
this._attemptCharCodeUntilFn(b), this._requireCharCode(62), this._endToken([]);
|
|
2025
|
-
else {
|
|
2026
|
-
let [t, r] = this._consumePrefixAndName();
|
|
2027
|
-
this._attemptCharCodeUntilFn(b), this._requireCharCode(62), this._endToken([t, r]), this._handleFullNameStackForTagClose(t, r);
|
|
2028
|
-
}
|
|
2029
|
-
}
|
|
2030
|
-
_consumeExpansionFormStart() {
|
|
2031
|
-
this._beginToken(20), this._requireCharCode(123), this._endToken([]), this._expansionCaseStack.push(20), this._beginToken(7);
|
|
2032
|
-
let e = this._readUntil(44), t = this._processCarriageReturns(e);
|
|
2033
|
-
if (this._i18nNormalizeLineEndingsInICUs)
|
|
2034
|
-
this._endToken([t]);
|
|
2035
|
-
else {
|
|
2036
|
-
let n = this._endToken([e]);
|
|
2037
|
-
t !== e && this.nonNormalizedIcuExpressions.push(n);
|
|
2038
|
-
}
|
|
2039
|
-
this._requireCharCode(44), this._attemptCharCodeUntilFn(b), this._beginToken(7);
|
|
2040
|
-
let r = this._readUntil(44);
|
|
2041
|
-
this._endToken([r]), this._requireCharCode(44), this._attemptCharCodeUntilFn(b);
|
|
2042
|
-
}
|
|
2043
|
-
_consumeExpansionCaseStart() {
|
|
2044
|
-
this._beginToken(21);
|
|
2045
|
-
let e = this._readUntil(123).trim();
|
|
2046
|
-
this._endToken([e]), this._attemptCharCodeUntilFn(b), this._beginToken(22), this._requireCharCode(123), this._endToken([]), this._attemptCharCodeUntilFn(b), this._expansionCaseStack.push(22);
|
|
2047
|
-
}
|
|
2048
|
-
_consumeExpansionCaseEnd() {
|
|
2049
|
-
this._beginToken(23), this._requireCharCode(125), this._endToken([]), this._attemptCharCodeUntilFn(b), this._expansionCaseStack.pop();
|
|
2050
|
-
}
|
|
2051
|
-
_consumeExpansionFormEnd() {
|
|
2052
|
-
this._beginToken(24), this._requireCharCode(125), this._endToken([]), this._expansionCaseStack.pop();
|
|
2053
|
-
}
|
|
2054
|
-
_consumeWithInterpolation(e, t, r, n) {
|
|
2055
|
-
this._beginToken(e);
|
|
2056
|
-
let a = [];
|
|
2057
|
-
for (; !r(); ) {
|
|
2058
|
-
let s = this._cursor.clone();
|
|
2059
|
-
this._interpolationConfig && this._attemptStr(this._interpolationConfig.start) ? (this._endToken([this._processCarriageReturns(a.join(""))], s), a.length = 0, this._consumeInterpolation(t, s, n), this._beginToken(e)) : this._cursor.peek() === 38 ? (this._endToken([this._processCarriageReturns(a.join(""))]), a.length = 0, this._consumeEntity(e), this._beginToken(e)) : a.push(this._readChar());
|
|
2060
|
-
}
|
|
2061
|
-
this._inInterpolation = !1;
|
|
2062
|
-
let i = this._processCarriageReturns(a.join(""));
|
|
2063
|
-
return this._endToken([i]), i;
|
|
2064
|
-
}
|
|
2065
|
-
_consumeInterpolation(e, t, r) {
|
|
2066
|
-
let n = [];
|
|
2067
|
-
this._beginToken(e, t), n.push(this._interpolationConfig.start);
|
|
2068
|
-
let a = this._cursor.clone(), i = null, s = !1;
|
|
2069
|
-
for (; this._cursor.peek() !== 0 && (r === null || !r()); ) {
|
|
2070
|
-
let u = this._cursor.clone();
|
|
2071
|
-
if (this._isTagStart()) {
|
|
2072
|
-
this._cursor = u, n.push(this._getProcessedChars(a, u)), this._endToken(n);
|
|
2073
|
-
return;
|
|
2074
|
-
}
|
|
2075
|
-
if (i === null)
|
|
2076
|
-
if (this._attemptStr(this._interpolationConfig.end)) {
|
|
2077
|
-
n.push(this._getProcessedChars(a, u)), n.push(this._interpolationConfig.end), this._endToken(n);
|
|
2078
|
-
return;
|
|
2079
|
-
} else
|
|
2080
|
-
this._attemptStr("//") && (s = !0);
|
|
2081
|
-
let o = this._cursor.peek();
|
|
2082
|
-
this._cursor.advance(), o === 92 ? this._cursor.advance() : o === i ? i = null : !s && i === null && je(o) && (i = o);
|
|
2083
|
-
}
|
|
2084
|
-
n.push(this._getProcessedChars(a, this._cursor)), this._endToken(n);
|
|
2085
|
-
}
|
|
2086
|
-
_getProcessedChars(e, t) {
|
|
2087
|
-
return this._processCarriageReturns(t.getChars(e));
|
|
2088
|
-
}
|
|
2089
|
-
_isTextEnd() {
|
|
2090
|
-
return !!(this._isTagStart() || this._cursor.peek() === 0 || this._tokenizeIcu && !this._inInterpolation && (this.isExpansionFormStart() || this._cursor.peek() === 125 && this._isInExpansionCase()) || this._tokenizeBlocks && !this._inInterpolation && !this._isInExpansion() && (this._isBlockStart() || this._cursor.peek() === 64 || this._cursor.peek() === 125));
|
|
2091
|
-
}
|
|
2092
|
-
_isTagStart() {
|
|
2093
|
-
if (this._cursor.peek() === 60) {
|
|
2094
|
-
let e = this._cursor.clone();
|
|
2095
|
-
e.advance();
|
|
2096
|
-
let t = e.peek();
|
|
2097
|
-
if (97 <= t && t <= 122 || 65 <= t && t <= 90 || t === 47 || t === 33)
|
|
2098
|
-
return !0;
|
|
2099
|
-
}
|
|
2100
|
-
return !1;
|
|
2101
|
-
}
|
|
2102
|
-
_isBlockStart() {
|
|
2103
|
-
if (this._tokenizeBlocks && this._cursor.peek() === 64) {
|
|
2104
|
-
let e = this._cursor.clone();
|
|
2105
|
-
if (e.advance(), Jt(e.peek()))
|
|
2106
|
-
return !0;
|
|
2107
|
-
}
|
|
2108
|
-
return !1;
|
|
2109
|
-
}
|
|
2110
|
-
_readUntil(e) {
|
|
2111
|
-
let t = this._cursor.clone();
|
|
2112
|
-
return this._attemptUntilChar(e), this._cursor.getChars(t);
|
|
2113
|
-
}
|
|
2114
|
-
_isInExpansion() {
|
|
2115
|
-
return this._isInExpansionCase() || this._isInExpansionForm();
|
|
2116
|
-
}
|
|
2117
|
-
_isInExpansionCase() {
|
|
2118
|
-
return this._expansionCaseStack.length > 0 && this._expansionCaseStack[this._expansionCaseStack.length - 1] === 22;
|
|
2119
|
-
}
|
|
2120
|
-
_isInExpansionForm() {
|
|
2121
|
-
return this._expansionCaseStack.length > 0 && this._expansionCaseStack[this._expansionCaseStack.length - 1] === 20;
|
|
2122
|
-
}
|
|
2123
|
-
isExpansionFormStart() {
|
|
2124
|
-
if (this._cursor.peek() !== 123)
|
|
2125
|
-
return !1;
|
|
2126
|
-
if (this._interpolationConfig) {
|
|
2127
|
-
let e = this._cursor.clone(), t = this._attemptStr(this._interpolationConfig.start);
|
|
2128
|
-
return this._cursor = e, !t;
|
|
2129
|
-
}
|
|
2130
|
-
return !0;
|
|
2131
|
-
}
|
|
2132
|
-
_handleFullNameStackForTagOpen(e, t) {
|
|
2133
|
-
let r = Le(e, t);
|
|
2134
|
-
(this._fullNameStack.length === 0 || this._fullNameStack[this._fullNameStack.length - 1] === r) && this._fullNameStack.push(r);
|
|
2135
|
-
}
|
|
2136
|
-
_handleFullNameStackForTagClose(e, t) {
|
|
2137
|
-
let r = Le(e, t);
|
|
2138
|
-
this._fullNameStack.length !== 0 && this._fullNameStack[this._fullNameStack.length - 1] === r && this._fullNameStack.pop();
|
|
2139
|
-
}
|
|
2140
|
-
};
|
|
2141
|
-
function b(e) {
|
|
2142
|
-
return !De(e) || e === 0;
|
|
2143
|
-
}
|
|
2144
|
-
function Xt(e) {
|
|
2145
|
-
return De(e) || e === 62 || e === 60 || e === 47 || e === 39 || e === 34 || e === 61 || e === 0;
|
|
2146
|
-
}
|
|
2147
|
-
function ws(e) {
|
|
2148
|
-
return (e < 97 || 122 < e) && (e < 65 || 90 < e) && (e < 48 || e > 57);
|
|
2149
|
-
}
|
|
2150
|
-
function As(e) {
|
|
2151
|
-
return e === 59 || e === 0 || !Di(e);
|
|
2152
|
-
}
|
|
2153
|
-
function ks(e) {
|
|
2154
|
-
return e === 59 || e === 0 || !Te(e);
|
|
2155
|
-
}
|
|
2156
|
-
function Es(e) {
|
|
2157
|
-
return e !== 125;
|
|
2158
|
-
}
|
|
2159
|
-
function xs(e, t) {
|
|
2160
|
-
return Yt(e) === Yt(t);
|
|
2161
|
-
}
|
|
2162
|
-
function Yt(e) {
|
|
2163
|
-
return e >= 97 && e <= 122 ? e - 97 + 65 : e;
|
|
2164
|
-
}
|
|
2165
|
-
function Jt(e) {
|
|
2166
|
-
return Te(e) || bt(e) || e === 95;
|
|
2167
|
-
}
|
|
2168
|
-
function Qt(e) {
|
|
2169
|
-
return e !== 59 && b(e);
|
|
2170
|
-
}
|
|
2171
|
-
function Ds(e) {
|
|
2172
|
-
let t = [], r;
|
|
2173
|
-
for (let n = 0; n < e.length; n++) {
|
|
2174
|
-
let a = e[n];
|
|
2175
|
-
r && r.type === 5 && a.type === 5 || r && r.type === 16 && a.type === 16 ? (r.parts[0] += a.parts[0], r.sourceSpan.end = a.sourceSpan.end) : (r = a, t.push(r));
|
|
2176
|
-
}
|
|
2177
|
-
return t;
|
|
2178
|
-
}
|
|
2179
|
-
var en = class tt {
|
|
2180
|
-
constructor(t, r) {
|
|
2181
|
-
if (t instanceof tt) {
|
|
2182
|
-
this.file = t.file, this.input = t.input, this.end = t.end;
|
|
2183
|
-
let n = t.state;
|
|
2184
|
-
this.state = { peek: n.peek, offset: n.offset, line: n.line, column: n.column };
|
|
2185
|
-
} else {
|
|
2186
|
-
if (!r)
|
|
2187
|
-
throw new Error("Programming error: the range argument must be provided with a file argument.");
|
|
2188
|
-
this.file = t, this.input = t.content, this.end = r.endPos, this.state = { peek: -1, offset: r.startPos, line: r.startLine, column: r.startCol };
|
|
2189
|
-
}
|
|
2190
|
-
}
|
|
2191
|
-
clone() {
|
|
2192
|
-
return new tt(this);
|
|
2193
|
-
}
|
|
2194
|
-
peek() {
|
|
2195
|
-
return this.state.peek;
|
|
2196
|
-
}
|
|
2197
|
-
charsLeft() {
|
|
2198
|
-
return this.end - this.state.offset;
|
|
2199
|
-
}
|
|
2200
|
-
diff(t) {
|
|
2201
|
-
return this.state.offset - t.state.offset;
|
|
2202
|
-
}
|
|
2203
|
-
advance() {
|
|
2204
|
-
this.advanceState(this.state);
|
|
2205
|
-
}
|
|
2206
|
-
init() {
|
|
2207
|
-
this.updatePeek(this.state);
|
|
2208
|
-
}
|
|
2209
|
-
getSpan(t, r) {
|
|
2210
|
-
t = t || this;
|
|
2211
|
-
let n = t;
|
|
2212
|
-
if (r)
|
|
2213
|
-
for (; this.diff(t) > 0 && r.indexOf(t.peek()) !== -1; )
|
|
2214
|
-
n === t && (t = t.clone()), t.advance();
|
|
2215
|
-
let a = this.locationFromCursor(t), i = this.locationFromCursor(this), s = n !== t ? this.locationFromCursor(n) : a;
|
|
2216
|
-
return new d(a, i, s);
|
|
2217
|
-
}
|
|
2218
|
-
getChars(t) {
|
|
2219
|
-
return this.input.substring(t.state.offset, this.state.offset);
|
|
2220
|
-
}
|
|
2221
|
-
charAt(t) {
|
|
2222
|
-
return this.input.charCodeAt(t);
|
|
2223
|
-
}
|
|
2224
|
-
advanceState(t) {
|
|
2225
|
-
if (t.offset >= this.end)
|
|
2226
|
-
throw this.state = t, new wt('Unexpected character "EOF"', this);
|
|
2227
|
-
let r = this.charAt(t.offset);
|
|
2228
|
-
r === 10 ? (t.line++, t.column = 0) : _t(r) || t.column++, t.offset++, this.updatePeek(t);
|
|
2229
|
-
}
|
|
2230
|
-
updatePeek(t) {
|
|
2231
|
-
t.peek = t.offset >= this.end ? 0 : this.charAt(t.offset);
|
|
2232
|
-
}
|
|
2233
|
-
locationFromCursor(t) {
|
|
2234
|
-
return new Ze(t.file, t.state.offset, t.state.line, t.state.column);
|
|
2235
|
-
}
|
|
2236
|
-
}, Ts = class rt extends en {
|
|
2237
|
-
constructor(t, r) {
|
|
2238
|
-
t instanceof rt ? (super(t), this.internalState = { ...t.internalState }) : (super(t, r), this.internalState = this.state);
|
|
2239
|
-
}
|
|
2240
|
-
advance() {
|
|
2241
|
-
this.state = this.internalState, super.advance(), this.processEscapeSequence();
|
|
2242
|
-
}
|
|
2243
|
-
init() {
|
|
2244
|
-
super.init(), this.processEscapeSequence();
|
|
2245
|
-
}
|
|
2246
|
-
clone() {
|
|
2247
|
-
return new rt(this);
|
|
2248
|
-
}
|
|
2249
|
-
getChars(t) {
|
|
2250
|
-
let r = t.clone(), n = "";
|
|
2251
|
-
for (; r.internalState.offset < this.internalState.offset; )
|
|
2252
|
-
n += String.fromCodePoint(r.peek()), r.advance();
|
|
2253
|
-
return n;
|
|
2254
|
-
}
|
|
2255
|
-
processEscapeSequence() {
|
|
2256
|
-
let t = () => this.internalState.peek;
|
|
2257
|
-
if (t() === 92)
|
|
2258
|
-
if (this.internalState = { ...this.state }, this.advanceState(this.internalState), t() === 110)
|
|
2259
|
-
this.state.peek = 10;
|
|
2260
|
-
else if (t() === 114)
|
|
2261
|
-
this.state.peek = 13;
|
|
2262
|
-
else if (t() === 118)
|
|
2263
|
-
this.state.peek = 11;
|
|
2264
|
-
else if (t() === 116)
|
|
2265
|
-
this.state.peek = 9;
|
|
2266
|
-
else if (t() === 98)
|
|
2267
|
-
this.state.peek = 8;
|
|
2268
|
-
else if (t() === 102)
|
|
2269
|
-
this.state.peek = 12;
|
|
2270
|
-
else if (t() === 117)
|
|
2271
|
-
if (this.advanceState(this.internalState), t() === 123) {
|
|
2272
|
-
this.advanceState(this.internalState);
|
|
2273
|
-
let r = this.clone(), n = 0;
|
|
2274
|
-
for (; t() !== 125; )
|
|
2275
|
-
this.advanceState(this.internalState), n++;
|
|
2276
|
-
this.state.peek = this.decodeHexDigits(r, n);
|
|
2277
|
-
} else {
|
|
2278
|
-
let r = this.clone();
|
|
2279
|
-
this.advanceState(this.internalState), this.advanceState(this.internalState), this.advanceState(this.internalState), this.state.peek = this.decodeHexDigits(r, 4);
|
|
2280
|
-
}
|
|
2281
|
-
else if (t() === 120) {
|
|
2282
|
-
this.advanceState(this.internalState);
|
|
2283
|
-
let r = this.clone();
|
|
2284
|
-
this.advanceState(this.internalState), this.state.peek = this.decodeHexDigits(r, 2);
|
|
2285
|
-
} else if (qt(t())) {
|
|
2286
|
-
let r = "", n = 0, a = this.clone();
|
|
2287
|
-
for (; qt(t()) && n < 3; )
|
|
2288
|
-
a = this.clone(), r += String.fromCodePoint(t()), this.advanceState(this.internalState), n++;
|
|
2289
|
-
this.state.peek = parseInt(r, 8), this.internalState = a.internalState;
|
|
2290
|
-
} else
|
|
2291
|
-
_t(this.internalState.peek) ? (this.advanceState(this.internalState), this.state = this.internalState) : this.state.peek = this.internalState.peek;
|
|
2292
|
-
}
|
|
2293
|
-
decodeHexDigits(t, r) {
|
|
2294
|
-
let n = this.input.slice(t.internalState.offset, t.internalState.offset + r), a = parseInt(n, 16);
|
|
2295
|
-
if (isNaN(a))
|
|
2296
|
-
throw t.state = t.internalState, new wt("Invalid hexadecimal escape sequence", t);
|
|
2297
|
-
return a;
|
|
2298
|
-
}
|
|
2299
|
-
}, wt = class {
|
|
2300
|
-
constructor(e, t) {
|
|
2301
|
-
this.msg = e, this.cursor = t;
|
|
2302
|
-
}
|
|
2303
|
-
}, B = class tn extends Kr {
|
|
2304
|
-
static create(t, r, n) {
|
|
2305
|
-
return new tn(t, r, n);
|
|
2306
|
-
}
|
|
2307
|
-
constructor(t, r, n) {
|
|
2308
|
-
super(r, n), this.elementName = t;
|
|
2309
|
-
}
|
|
2310
|
-
}, Bs = class {
|
|
2311
|
-
constructor(e, t) {
|
|
2312
|
-
this.rootNodes = e, this.errors = t;
|
|
2313
|
-
}
|
|
2314
|
-
}, Ls = class {
|
|
2315
|
-
constructor(e) {
|
|
2316
|
-
this.getTagDefinition = e;
|
|
2317
|
-
}
|
|
2318
|
-
parse(e, t, r, n = !1, a) {
|
|
2319
|
-
let i = (m) => (C, ...w) => m(C.toLowerCase(), ...w), s = n ? this.getTagDefinition : i(this.getTagDefinition), u = (m) => s(m).getContentType(), o = n ? a : i(a), p = Ss(e, t, a ? (m, C, w, E) => {
|
|
2320
|
-
let x = o(m, C, w, E);
|
|
2321
|
-
return x !== void 0 ? x : u(m);
|
|
2322
|
-
} : u, r), l = r && r.canSelfClose || !1, f = r && r.allowHtmComponentClosingTags || !1, v = new Fs(p.tokens, s, l, f, n);
|
|
2323
|
-
return v.build(), new Bs(v.rootNodes, p.errors.concat(v.errors));
|
|
2324
|
-
}
|
|
2325
|
-
}, Fs = class rn {
|
|
2326
|
-
constructor(t, r, n, a, i) {
|
|
2327
|
-
this.tokens = t, this.getTagDefinition = r, this.canSelfClose = n, this.allowHtmComponentClosingTags = a, this.isTagNameCaseSensitive = i, this._index = -1, this._containerStack = [], this.rootNodes = [], this.errors = [], this._advance();
|
|
2328
|
-
}
|
|
2329
|
-
build() {
|
|
2330
|
-
for (; this._peek.type !== 34; )
|
|
2331
|
-
this._peek.type === 0 || this._peek.type === 4 ? this._consumeStartTag(this._advance()) : this._peek.type === 3 ? (this._closeVoidElement(), this._consumeEndTag(this._advance())) : this._peek.type === 12 ? (this._closeVoidElement(), this._consumeCdata(this._advance())) : this._peek.type === 10 ? (this._closeVoidElement(), this._consumeComment(this._advance())) : this._peek.type === 5 || this._peek.type === 7 || this._peek.type === 6 ? (this._closeVoidElement(), this._consumeText(this._advance())) : this._peek.type === 20 ? this._consumeExpansion(this._advance()) : this._peek.type === 25 ? (this._closeVoidElement(), this._consumeBlockOpen(this._advance())) : this._peek.type === 27 ? (this._closeVoidElement(), this._consumeBlockClose(this._advance())) : this._peek.type === 29 ? (this._closeVoidElement(), this._consumeIncompleteBlock(this._advance())) : this._peek.type === 30 ? (this._closeVoidElement(), this._consumeLet(this._advance())) : this._peek.type === 18 ? this._consumeDocType(this._advance()) : this._peek.type === 33 ? (this._closeVoidElement(), this._consumeIncompleteLet(this._advance())) : this._advance();
|
|
2332
|
-
for (let t of this._containerStack)
|
|
2333
|
-
t instanceof K && this.errors.push(B.create(t.name, t.sourceSpan, `Unclosed block "${t.name}"`));
|
|
2334
|
-
}
|
|
2335
|
-
_advance() {
|
|
2336
|
-
let t = this._peek;
|
|
2337
|
-
return this._index < this.tokens.length - 1 && this._index++, this._peek = this.tokens[this._index], t;
|
|
2338
|
-
}
|
|
2339
|
-
_advanceIf(t) {
|
|
2340
|
-
return this._peek.type === t ? this._advance() : null;
|
|
2341
|
-
}
|
|
2342
|
-
_consumeCdata(t) {
|
|
2343
|
-
let r = this._advance(), n = this._getText(r), a = this._advanceIf(13);
|
|
2344
|
-
this._addToParent(new us(n, new d(t.sourceSpan.start, (a || r).sourceSpan.end), [r]));
|
|
2345
|
-
}
|
|
2346
|
-
_consumeComment(t) {
|
|
2347
|
-
let r = this._advanceIf(7), n = this._advanceIf(11), a = r != null ? r.parts[0].trim() : null, i = n == null ? t.sourceSpan : new d(t.sourceSpan.start, n.sourceSpan.end, t.sourceSpan.fullStart);
|
|
2348
|
-
this._addToParent(new ps(a, i));
|
|
2349
|
-
}
|
|
2350
|
-
_consumeDocType(t) {
|
|
2351
|
-
let r = this._advanceIf(7), n = this._advanceIf(19), a = r != null ? r.parts[0].trim() : null, i = new d(t.sourceSpan.start, (n || r || t).sourceSpan.end);
|
|
2352
|
-
this._addToParent(new hs(a, i));
|
|
2353
|
-
}
|
|
2354
|
-
_consumeExpansion(t) {
|
|
2355
|
-
let r = this._advance(), n = this._advance(), a = [];
|
|
2356
|
-
for (; this._peek.type === 21; ) {
|
|
2357
|
-
let s = this._parseExpansionCase();
|
|
2358
|
-
if (!s)
|
|
2359
|
-
return;
|
|
2360
|
-
a.push(s);
|
|
2361
|
-
}
|
|
2362
|
-
if (this._peek.type !== 24) {
|
|
2363
|
-
this.errors.push(B.create(null, this._peek.sourceSpan, "Invalid ICU message. Missing '}'."));
|
|
2364
|
-
return;
|
|
2365
|
-
}
|
|
2366
|
-
let i = new d(t.sourceSpan.start, this._peek.sourceSpan.end, t.sourceSpan.fullStart);
|
|
2367
|
-
this._addToParent(new os(r.parts[0], n.parts[0], a, i, r.sourceSpan)), this._advance();
|
|
2368
|
-
}
|
|
2369
|
-
_parseExpansionCase() {
|
|
2370
|
-
let t = this._advance();
|
|
2371
|
-
if (this._peek.type !== 22)
|
|
2372
|
-
return this.errors.push(B.create(null, this._peek.sourceSpan, "Invalid ICU message. Missing '{'.")), null;
|
|
2373
|
-
let r = this._advance(), n = this._collectExpansionExpTokens(r);
|
|
2374
|
-
if (!n)
|
|
2375
|
-
return null;
|
|
2376
|
-
let a = this._advance();
|
|
2377
|
-
n.push({ type: 34, parts: [], sourceSpan: a.sourceSpan });
|
|
2378
|
-
let i = new rn(n, this.getTagDefinition, this.canSelfClose, this.allowHtmComponentClosingTags, this.isTagNameCaseSensitive);
|
|
2379
|
-
if (i.build(), i.errors.length > 0)
|
|
2380
|
-
return this.errors = this.errors.concat(i.errors), null;
|
|
2381
|
-
let s = new d(t.sourceSpan.start, a.sourceSpan.end, t.sourceSpan.fullStart), u = new d(r.sourceSpan.start, a.sourceSpan.end, r.sourceSpan.fullStart);
|
|
2382
|
-
return new ls(t.parts[0], i.rootNodes, s, t.sourceSpan, u);
|
|
2383
|
-
}
|
|
2384
|
-
_collectExpansionExpTokens(t) {
|
|
2385
|
-
let r = [], n = [22];
|
|
2386
|
-
for (; ; ) {
|
|
2387
|
-
if ((this._peek.type === 20 || this._peek.type === 22) && n.push(this._peek.type), this._peek.type === 23)
|
|
2388
|
-
if (Zt(n, 22)) {
|
|
2389
|
-
if (n.pop(), n.length === 0)
|
|
2390
|
-
return r;
|
|
2391
|
-
} else
|
|
2392
|
-
return this.errors.push(B.create(null, t.sourceSpan, "Invalid ICU message. Missing '}'.")), null;
|
|
2393
|
-
if (this._peek.type === 24)
|
|
2394
|
-
if (Zt(n, 20))
|
|
2395
|
-
n.pop();
|
|
2396
|
-
else
|
|
2397
|
-
return this.errors.push(B.create(null, t.sourceSpan, "Invalid ICU message. Missing '}'.")), null;
|
|
2398
|
-
if (this._peek.type === 34)
|
|
2399
|
-
return this.errors.push(B.create(null, t.sourceSpan, "Invalid ICU message. Missing '}'.")), null;
|
|
2400
|
-
r.push(this._advance());
|
|
2401
|
-
}
|
|
2402
|
-
}
|
|
2403
|
-
_getText(t) {
|
|
2404
|
-
let r = t.parts[0];
|
|
2405
|
-
if (r.length > 0 && r[0] == `
|
|
2406
|
-
`) {
|
|
2407
|
-
let n = this._getClosestParentElement();
|
|
2408
|
-
n != null && n.children.length == 0 && this.getTagDefinition(n.name).ignoreFirstLf && (r = r.substring(1));
|
|
2409
|
-
}
|
|
2410
|
-
return r;
|
|
2411
|
-
}
|
|
2412
|
-
_consumeText(t) {
|
|
2413
|
-
let r = [t], n = t.sourceSpan, a = t.parts[0];
|
|
2414
|
-
if (a.length > 0 && a[0] === `
|
|
2415
|
-
`) {
|
|
2416
|
-
let i = this._getContainer();
|
|
2417
|
-
i != null && i.children.length === 0 && this.getTagDefinition(i.name).ignoreFirstLf && (a = a.substring(1), r[0] = { type: t.type, sourceSpan: t.sourceSpan, parts: [a] });
|
|
2418
|
-
}
|
|
2419
|
-
for (; this._peek.type === 8 || this._peek.type === 5 || this._peek.type === 9; )
|
|
2420
|
-
t = this._advance(), r.push(t), t.type === 8 ? a += t.parts.join("").replace(/&([^;]+);/g, er) : t.type === 9 ? a += t.parts[0] : a += t.parts.join("");
|
|
2421
|
-
if (a.length > 0) {
|
|
2422
|
-
let i = t.sourceSpan;
|
|
2423
|
-
this._addToParent(new ss(a, new d(n.start, i.end, n.fullStart, n.details), r));
|
|
2424
|
-
}
|
|
2425
|
-
}
|
|
2426
|
-
_closeVoidElement() {
|
|
2427
|
-
let t = this._getContainer();
|
|
2428
|
-
t instanceof V && this.getTagDefinition(t.name).isVoid && this._containerStack.pop();
|
|
2429
|
-
}
|
|
2430
|
-
_consumeStartTag(t) {
|
|
2431
|
-
let [r, n] = t.parts, a = [];
|
|
2432
|
-
for (; this._peek.type === 14; )
|
|
2433
|
-
a.push(this._consumeAttr(this._advance()));
|
|
2434
|
-
let i = this._getElementFullName(r, n, this._getClosestParentElement()), s = !1;
|
|
2435
|
-
if (this._peek.type === 2) {
|
|
2436
|
-
this._advance(), s = !0;
|
|
2437
|
-
let m = this.getTagDefinition(i);
|
|
2438
|
-
this.canSelfClose || m.canSelfClose || ke(i) !== null || m.isVoid || this.errors.push(B.create(i, t.sourceSpan, `Only void, custom and foreign elements can be self closed "${t.parts[1]}"`));
|
|
2439
|
-
} else
|
|
2440
|
-
this._peek.type === 1 && (this._advance(), s = !1);
|
|
2441
|
-
let u = this._peek.sourceSpan.fullStart, o = new d(t.sourceSpan.start, u, t.sourceSpan.fullStart), p = new d(t.sourceSpan.start, u, t.sourceSpan.fullStart), l = new d(t.sourceSpan.start.moveBy(1), t.sourceSpan.end), f = new V(i, a, [], o, p, void 0, l), v = this._getContainer();
|
|
2442
|
-
this._pushContainer(f, v instanceof V && this.getTagDefinition(v.name).isClosedByChild(f.name)), s ? this._popContainer(i, V, o) : t.type === 4 && (this._popContainer(i, V, null), this.errors.push(B.create(i, o, `Opening tag "${i}" not terminated.`)));
|
|
2443
|
-
}
|
|
2444
|
-
_pushContainer(t, r) {
|
|
2445
|
-
r && this._containerStack.pop(), this._addToParent(t), this._containerStack.push(t);
|
|
2446
|
-
}
|
|
2447
|
-
_consumeEndTag(t) {
|
|
2448
|
-
let r = this.allowHtmComponentClosingTags && t.parts.length === 0 ? null : this._getElementFullName(t.parts[0], t.parts[1], this._getClosestParentElement());
|
|
2449
|
-
if (r && this.getTagDefinition(r).isVoid)
|
|
2450
|
-
this.errors.push(B.create(r, t.sourceSpan, `Void elements do not have end tags "${t.parts[1]}"`));
|
|
2451
|
-
else if (!this._popContainer(r, V, t.sourceSpan)) {
|
|
2452
|
-
let n = `Unexpected closing tag "${r}". It may happen when the tag has already been closed by another tag. For more info see https://www.w3.org/TR/html5/syntax.html#closing-elements-that-have-implied-end-tags`;
|
|
2453
|
-
this.errors.push(B.create(r, t.sourceSpan, n));
|
|
2454
|
-
}
|
|
2455
|
-
}
|
|
2456
|
-
_popContainer(t, r, n) {
|
|
2457
|
-
let a = !1;
|
|
2458
|
-
for (let i = this._containerStack.length - 1; i >= 0; i--) {
|
|
2459
|
-
let s = this._containerStack[i];
|
|
2460
|
-
if (ke(s.name) ? s.name === t : (t == null || s.name.toLowerCase() === t.toLowerCase()) && s instanceof r)
|
|
2461
|
-
return s.endSourceSpan = n, s.sourceSpan.end = n !== null ? n.end : s.sourceSpan.end, this._containerStack.splice(i, this._containerStack.length - i), !a;
|
|
2462
|
-
(s instanceof K || s instanceof V && !this.getTagDefinition(s.name).closedByParent) && (a = !0);
|
|
2463
|
-
}
|
|
2464
|
-
return !1;
|
|
2465
|
-
}
|
|
2466
|
-
_consumeAttr(t) {
|
|
2467
|
-
let r = Le(t.parts[0], t.parts[1]), n = t.sourceSpan.end, a;
|
|
2468
|
-
this._peek.type === 15 && (a = this._advance());
|
|
2469
|
-
let i = "", s = [], u, o;
|
|
2470
|
-
if (this._peek.type === 16)
|
|
2471
|
-
for (u = this._peek.sourceSpan, o = this._peek.sourceSpan.end; this._peek.type === 16 || this._peek.type === 17 || this._peek.type === 9; ) {
|
|
2472
|
-
let l = this._advance();
|
|
2473
|
-
s.push(l), l.type === 17 ? i += l.parts.join("").replace(/&([^;]+);/g, er) : l.type === 9 ? i += l.parts[0] : i += l.parts.join(""), o = n = l.sourceSpan.end;
|
|
2474
|
-
}
|
|
2475
|
-
this._peek.type === 15 && (o = n = this._advance().sourceSpan.end);
|
|
2476
|
-
let p = u && o && new d((a == null ? void 0 : a.sourceSpan.start) ?? u.start, o, (a == null ? void 0 : a.sourceSpan.fullStart) ?? u.fullStart);
|
|
2477
|
-
return new cs(r, i, new d(t.sourceSpan.start, n, t.sourceSpan.fullStart), t.sourceSpan, p, s.length > 0 ? s : void 0, void 0);
|
|
2478
|
-
}
|
|
2479
|
-
_consumeBlockOpen(t) {
|
|
2480
|
-
let r = [];
|
|
2481
|
-
for (; this._peek.type === 28; ) {
|
|
2482
|
-
let u = this._advance();
|
|
2483
|
-
r.push(new jt(u.parts[0], u.sourceSpan));
|
|
2484
|
-
}
|
|
2485
|
-
this._peek.type === 26 && this._advance();
|
|
2486
|
-
let n = this._peek.sourceSpan.fullStart, a = new d(t.sourceSpan.start, n, t.sourceSpan.fullStart), i = new d(t.sourceSpan.start, n, t.sourceSpan.fullStart), s = new K(t.parts[0], r, [], a, t.sourceSpan, i);
|
|
2487
|
-
this._pushContainer(s, !1);
|
|
2488
|
-
}
|
|
2489
|
-
_consumeBlockClose(t) {
|
|
2490
|
-
this._popContainer(null, K, t.sourceSpan) || this.errors.push(B.create(null, t.sourceSpan, 'Unexpected closing block. The block may have been closed earlier. If you meant to write the } character, you should use the "}" HTML entity instead.'));
|
|
2491
|
-
}
|
|
2492
|
-
_consumeIncompleteBlock(t) {
|
|
2493
|
-
let r = [];
|
|
2494
|
-
for (; this._peek.type === 28; ) {
|
|
2495
|
-
let u = this._advance();
|
|
2496
|
-
r.push(new jt(u.parts[0], u.sourceSpan));
|
|
2497
|
-
}
|
|
2498
|
-
let n = this._peek.sourceSpan.fullStart, a = new d(t.sourceSpan.start, n, t.sourceSpan.fullStart), i = new d(t.sourceSpan.start, n, t.sourceSpan.fullStart), s = new K(t.parts[0], r, [], a, t.sourceSpan, i);
|
|
2499
|
-
this._pushContainer(s, !1), this._popContainer(null, K, null), this.errors.push(B.create(t.parts[0], a, `Incomplete block "${t.parts[0]}". If you meant to write the @ character, you should use the "@" HTML entity instead.`));
|
|
2500
|
-
}
|
|
2501
|
-
_consumeLet(t) {
|
|
2502
|
-
let r = t.parts[0], n, a;
|
|
2503
|
-
if (this._peek.type !== 31) {
|
|
2504
|
-
this.errors.push(B.create(t.parts[0], t.sourceSpan, `Invalid @let declaration "${r}". Declaration must have a value.`));
|
|
2505
|
-
return;
|
|
2506
|
-
} else
|
|
2507
|
-
n = this._advance();
|
|
2508
|
-
if (this._peek.type !== 32) {
|
|
2509
|
-
this.errors.push(B.create(t.parts[0], t.sourceSpan, `Unterminated @let declaration "${r}". Declaration must be terminated with a semicolon.`));
|
|
2510
|
-
return;
|
|
2511
|
-
} else
|
|
2512
|
-
a = this._advance();
|
|
2513
|
-
let i = a.sourceSpan.fullStart, s = new d(t.sourceSpan.start, i, t.sourceSpan.fullStart), u = t.sourceSpan.toString().lastIndexOf(r), o = t.sourceSpan.start.moveBy(u), p = new d(o, t.sourceSpan.end), l = new Gt(r, n.parts[0], s, p, n.sourceSpan);
|
|
2514
|
-
this._addToParent(l);
|
|
2515
|
-
}
|
|
2516
|
-
_consumeIncompleteLet(t) {
|
|
2517
|
-
let r = t.parts[0] ?? "", n = r ? ` "${r}"` : "";
|
|
2518
|
-
if (r.length > 0) {
|
|
2519
|
-
let a = t.sourceSpan.toString().lastIndexOf(r), i = t.sourceSpan.start.moveBy(a), s = new d(i, t.sourceSpan.end), u = new d(t.sourceSpan.start, t.sourceSpan.start.moveBy(0)), o = new Gt(r, "", t.sourceSpan, s, u);
|
|
2520
|
-
this._addToParent(o);
|
|
2521
|
-
}
|
|
2522
|
-
this.errors.push(B.create(t.parts[0], t.sourceSpan, `Incomplete @let declaration${n}. @let declarations must be written as \`@let <name> = <value>;\``));
|
|
2523
|
-
}
|
|
2524
|
-
_getContainer() {
|
|
2525
|
-
return this._containerStack.length > 0 ? this._containerStack[this._containerStack.length - 1] : null;
|
|
2526
|
-
}
|
|
2527
|
-
_getClosestParentElement() {
|
|
2528
|
-
for (let t = this._containerStack.length - 1; t > -1; t--)
|
|
2529
|
-
if (this._containerStack[t] instanceof V)
|
|
2530
|
-
return this._containerStack[t];
|
|
2531
|
-
return null;
|
|
2532
|
-
}
|
|
2533
|
-
_addToParent(t) {
|
|
2534
|
-
let r = this._getContainer();
|
|
2535
|
-
r === null ? this.rootNodes.push(t) : r.children.push(t);
|
|
2536
|
-
}
|
|
2537
|
-
_getElementFullName(t, r, n) {
|
|
2538
|
-
if (t === "" && (t = this.getTagDefinition(r).implicitNamespacePrefix || "", t === "" && n != null)) {
|
|
2539
|
-
let a = Ve(n.name)[1];
|
|
2540
|
-
this.getTagDefinition(a).preventNamespaceInheritance || (t = ke(n.name));
|
|
2541
|
-
}
|
|
2542
|
-
return Le(t, r);
|
|
2543
|
-
}
|
|
2544
|
-
};
|
|
2545
|
-
function Zt(e, t) {
|
|
2546
|
-
return e.length > 0 && e[e.length - 1] === t;
|
|
2547
|
-
}
|
|
2548
|
-
function er(e, t) {
|
|
2549
|
-
return Fe[t] !== void 0 ? Fe[t] || e : /^#x[a-f0-9]+$/i.test(t) ? String.fromCodePoint(parseInt(t.slice(2), 16)) : /^#\d+$/.test(t) ? String.fromCodePoint(parseInt(t.slice(1), 10)) : e;
|
|
2550
|
-
}
|
|
2551
|
-
var qs = class extends Ls {
|
|
2552
|
-
constructor() {
|
|
2553
|
-
super(et);
|
|
2554
|
-
}
|
|
2555
|
-
parse(e, t, r, n = !1, a) {
|
|
2556
|
-
return super.parse(e, t, r, n, a);
|
|
2557
|
-
}
|
|
2558
|
-
}, Xe = null, Ns = () => (Xe || (Xe = new qs()), Xe);
|
|
2559
|
-
function tr(e, t = {}) {
|
|
2560
|
-
let { canSelfClose: r = !1, allowHtmComponentClosingTags: n = !1, isTagNameCaseSensitive: a = !1, getTagContentType: i, tokenizeAngularBlocks: s = !1, tokenizeAngularLetDeclaration: u = !1 } = t;
|
|
2561
|
-
return Ns().parse(e, "angular-html-parser", { tokenizeExpansionForms: s, interpolationConfig: void 0, canSelfClose: r, allowHtmComponentClosingTags: n, tokenizeBlocks: s, tokenizeLet: u }, a, i);
|
|
2562
|
-
}
|
|
2563
|
-
function Is(e, t) {
|
|
2564
|
-
let r = new SyntaxError(e + " (" + t.loc.start.line + ":" + t.loc.start.column + ")");
|
|
2565
|
-
return Object.assign(r, t);
|
|
2566
|
-
}
|
|
2567
|
-
var Ps = Is, se = 3;
|
|
2568
|
-
function Hs(e) {
|
|
2569
|
-
let t = e.slice(0, se);
|
|
2570
|
-
if (t !== "---" && t !== "+++")
|
|
2571
|
-
return;
|
|
2572
|
-
let r = e.indexOf(`
|
|
2573
|
-
`, se);
|
|
2574
|
-
if (r === -1)
|
|
2575
|
-
return;
|
|
2576
|
-
let n = e.slice(se, r).trim(), a = e.indexOf(`
|
|
2577
|
-
${t}`, r), i = n;
|
|
2578
|
-
if (i || (i = t === "+++" ? "toml" : "yaml"), a === -1 && t === "---" && i === "yaml" && (a = e.indexOf(`
|
|
2579
|
-
...`, r)), a === -1)
|
|
2580
|
-
return;
|
|
2581
|
-
let s = a + 1 + se, u = e.charAt(s + 1);
|
|
2582
|
-
if (!/\s?/u.test(u))
|
|
2583
|
-
return;
|
|
2584
|
-
let o = e.slice(0, s);
|
|
2585
|
-
return { type: "front-matter", language: i, explicitLanguage: n, value: e.slice(r + 1, a), startDelimiter: t, endDelimiter: o.slice(-se), raw: o };
|
|
2586
|
-
}
|
|
2587
|
-
function Ms(e) {
|
|
2588
|
-
let t = Hs(e);
|
|
2589
|
-
if (!t)
|
|
2590
|
-
return { content: e };
|
|
2591
|
-
let { raw: r } = t;
|
|
2592
|
-
return { frontMatter: t, content: L(!1, r, /[^\n]/gu, " ") + e.slice(r.length) };
|
|
2593
|
-
}
|
|
2594
|
-
var Rs = Ms, Ae = { attrs: !0, children: !0, cases: !0, expression: !0 }, rr = /* @__PURE__ */ new Set(["parent"]), Y, nt, at, Us = class ue {
|
|
2595
|
-
constructor(t = {}) {
|
|
2596
|
-
or(this, Y), Et(this, "type"), Et(this, "parent");
|
|
2597
|
-
for (let r of /* @__PURE__ */ new Set([...rr, ...Object.keys(t)]))
|
|
2598
|
-
this.setProperty(r, t[r]);
|
|
2599
|
-
}
|
|
2600
|
-
setProperty(t, r) {
|
|
2601
|
-
if (this[t] !== r) {
|
|
2602
|
-
if (t in Ae && (r = r.map((n) => this.createChild(n))), !rr.has(t)) {
|
|
2603
|
-
this[t] = r;
|
|
2604
|
-
return;
|
|
2605
|
-
}
|
|
2606
|
-
Object.defineProperty(this, t, { value: r, enumerable: !1, configurable: !0 });
|
|
2607
|
-
}
|
|
2608
|
-
}
|
|
2609
|
-
map(t) {
|
|
2610
|
-
let r;
|
|
2611
|
-
for (let n in Ae) {
|
|
2612
|
-
let a = this[n];
|
|
2613
|
-
if (a) {
|
|
2614
|
-
let i = Os(a, (s) => s.map(t));
|
|
2615
|
-
r !== a && (r || (r = new ue({ parent: this.parent })), r.setProperty(n, i));
|
|
2616
|
-
}
|
|
2617
|
-
}
|
|
2618
|
-
if (r)
|
|
2619
|
-
for (let n in this)
|
|
2620
|
-
n in Ae || (r[n] = this[n]);
|
|
2621
|
-
return t(r || this);
|
|
2622
|
-
}
|
|
2623
|
-
walk(t) {
|
|
2624
|
-
for (let r in Ae) {
|
|
2625
|
-
let n = this[r];
|
|
2626
|
-
if (n)
|
|
2627
|
-
for (let a = 0; a < n.length; a++)
|
|
2628
|
-
n[a].walk(t);
|
|
2629
|
-
}
|
|
2630
|
-
t(this);
|
|
2631
|
-
}
|
|
2632
|
-
createChild(t) {
|
|
2633
|
-
let r = t instanceof ue ? t.clone() : new ue(t);
|
|
2634
|
-
return r.setProperty("parent", this), r;
|
|
2635
|
-
}
|
|
2636
|
-
insertChildBefore(t, r) {
|
|
2637
|
-
let n = this.$children;
|
|
2638
|
-
n.splice(n.indexOf(t), 0, this.createChild(r));
|
|
2639
|
-
}
|
|
2640
|
-
removeChild(t) {
|
|
2641
|
-
let r = this.$children;
|
|
2642
|
-
r.splice(r.indexOf(t), 1);
|
|
2643
|
-
}
|
|
2644
|
-
replaceChild(t, r) {
|
|
2645
|
-
let n = this.$children;
|
|
2646
|
-
n[n.indexOf(t)] = this.createChild(r);
|
|
2647
|
-
}
|
|
2648
|
-
clone() {
|
|
2649
|
-
return new ue(this);
|
|
2650
|
-
}
|
|
2651
|
-
get $children() {
|
|
2652
|
-
return this[F(this, Y, nt)];
|
|
2653
|
-
}
|
|
2654
|
-
set $children(t) {
|
|
2655
|
-
this[F(this, Y, nt)] = t;
|
|
2656
|
-
}
|
|
2657
|
-
get firstChild() {
|
|
2658
|
-
var t;
|
|
2659
|
-
return (t = this.$children) == null ? void 0 : t[0];
|
|
2660
|
-
}
|
|
2661
|
-
get lastChild() {
|
|
2662
|
-
return de(!0, this.$children, -1);
|
|
2663
|
-
}
|
|
2664
|
-
get prev() {
|
|
2665
|
-
let t = F(this, Y, at);
|
|
2666
|
-
return t[t.indexOf(this) - 1];
|
|
2667
|
-
}
|
|
2668
|
-
get next() {
|
|
2669
|
-
let t = F(this, Y, at);
|
|
2670
|
-
return t[t.indexOf(this) + 1];
|
|
2671
|
-
}
|
|
2672
|
-
get rawName() {
|
|
2673
|
-
return this.hasExplicitNamespace ? this.fullName : this.name;
|
|
2674
|
-
}
|
|
2675
|
-
get fullName() {
|
|
2676
|
-
return this.namespace ? this.namespace + ":" + this.name : this.name;
|
|
2677
|
-
}
|
|
2678
|
-
get attrMap() {
|
|
2679
|
-
return Object.fromEntries(this.attrs.map((t) => [t.fullName, t.value]));
|
|
2680
|
-
}
|
|
2681
|
-
};
|
|
2682
|
-
Y = /* @__PURE__ */ new WeakSet(), nt = function() {
|
|
2683
|
-
return this.type === "angularIcuCase" ? "expression" : this.type === "angularIcuExpression" ? "cases" : "children";
|
|
2684
|
-
}, at = function() {
|
|
2685
|
-
var e;
|
|
2686
|
-
return ((e = this.parent) == null ? void 0 : e.$children) ?? [];
|
|
2687
|
-
};
|
|
2688
|
-
var Vs = Us;
|
|
2689
|
-
function Os(e, t) {
|
|
2690
|
-
let r = e.map(t);
|
|
2691
|
-
return r.some((n, a) => n !== e[a]) ? r : e;
|
|
2692
|
-
}
|
|
2693
|
-
var Ws = [{ regex: /^(\[if([^\]]*)\]>)(.*?)<!\s*\[endif\]$/su, parse: $s }, { regex: /^\[if([^\]]*)\]><!$/u, parse: js }, { regex: /^<!\s*\[endif\]$/u, parse: Gs }];
|
|
2694
|
-
function zs(e, t) {
|
|
2695
|
-
if (e.value)
|
|
2696
|
-
for (let { regex: r, parse: n } of Ws) {
|
|
2697
|
-
let a = e.value.match(r);
|
|
2698
|
-
if (a)
|
|
2699
|
-
return n(e, t, a);
|
|
2700
|
-
}
|
|
2701
|
-
return null;
|
|
2702
|
-
}
|
|
2703
|
-
function $s(e, t, r) {
|
|
2704
|
-
let [, n, a, i] = r, s = 4 + n.length, u = e.sourceSpan.start.moveBy(s), o = u.moveBy(i.length), [p, l] = (() => {
|
|
2705
|
-
try {
|
|
2706
|
-
return [!0, t(i, u).children];
|
|
2707
|
-
} catch {
|
|
2708
|
-
return [!1, [{ type: "text", value: i, sourceSpan: new d(u, o) }]];
|
|
2709
|
-
}
|
|
2710
|
-
})();
|
|
2711
|
-
return { type: "ieConditionalComment", complete: p, children: l, condition: L(!1, a.trim(), /\s+/gu, " "), sourceSpan: e.sourceSpan, startSourceSpan: new d(e.sourceSpan.start, u), endSourceSpan: new d(o, e.sourceSpan.end) };
|
|
2712
|
-
}
|
|
2713
|
-
function js(e, t, r) {
|
|
2714
|
-
let [, n] = r;
|
|
2715
|
-
return { type: "ieConditionalStartComment", condition: L(!1, n.trim(), /\s+/gu, " "), sourceSpan: e.sourceSpan };
|
|
2716
|
-
}
|
|
2717
|
-
function Gs(e) {
|
|
2718
|
-
return { type: "ieConditionalEndComment", sourceSpan: e.sourceSpan };
|
|
2719
|
-
}
|
|
2720
|
-
var Ye = /* @__PURE__ */ new Map([["*", /* @__PURE__ */ new Set(["accesskey", "autocapitalize", "autofocus", "class", "contenteditable", "dir", "draggable", "enterkeyhint", "hidden", "id", "inert", "inputmode", "is", "itemid", "itemprop", "itemref", "itemscope", "itemtype", "lang", "nonce", "popover", "slot", "spellcheck", "style", "tabindex", "title", "translate", "writingsuggestions"])], ["a", /* @__PURE__ */ new Set(["charset", "coords", "download", "href", "hreflang", "name", "ping", "referrerpolicy", "rel", "rev", "shape", "target", "type"])], ["applet", /* @__PURE__ */ new Set(["align", "alt", "archive", "code", "codebase", "height", "hspace", "name", "object", "vspace", "width"])], ["area", /* @__PURE__ */ new Set(["alt", "coords", "download", "href", "hreflang", "nohref", "ping", "referrerpolicy", "rel", "shape", "target", "type"])], ["audio", /* @__PURE__ */ new Set(["autoplay", "controls", "crossorigin", "loop", "muted", "preload", "src"])], ["base", /* @__PURE__ */ new Set(["href", "target"])], ["basefont", /* @__PURE__ */ new Set(["color", "face", "size"])], ["blockquote", /* @__PURE__ */ new Set(["cite"])], ["body", /* @__PURE__ */ new Set(["alink", "background", "bgcolor", "link", "text", "vlink"])], ["br", /* @__PURE__ */ new Set(["clear"])], ["button", /* @__PURE__ */ new Set(["disabled", "form", "formaction", "formenctype", "formmethod", "formnovalidate", "formtarget", "name", "popovertarget", "popovertargetaction", "type", "value"])], ["canvas", /* @__PURE__ */ new Set(["height", "width"])], ["caption", /* @__PURE__ */ new Set(["align"])], ["col", /* @__PURE__ */ new Set(["align", "char", "charoff", "span", "valign", "width"])], ["colgroup", /* @__PURE__ */ new Set(["align", "char", "charoff", "span", "valign", "width"])], ["data", /* @__PURE__ */ new Set(["value"])], ["del", /* @__PURE__ */ new Set(["cite", "datetime"])], ["details", /* @__PURE__ */ new Set(["name", "open"])], ["dialog", /* @__PURE__ */ new Set(["open"])], ["dir", /* @__PURE__ */ new Set(["compact"])], ["div", /* @__PURE__ */ new Set(["align"])], ["dl", /* @__PURE__ */ new Set(["compact"])], ["embed", /* @__PURE__ */ new Set(["height", "src", "type", "width"])], ["fieldset", /* @__PURE__ */ new Set(["disabled", "form", "name"])], ["font", /* @__PURE__ */ new Set(["color", "face", "size"])], ["form", /* @__PURE__ */ new Set(["accept", "accept-charset", "action", "autocomplete", "enctype", "method", "name", "novalidate", "target"])], ["frame", /* @__PURE__ */ new Set(["frameborder", "longdesc", "marginheight", "marginwidth", "name", "noresize", "scrolling", "src"])], ["frameset", /* @__PURE__ */ new Set(["cols", "rows"])], ["h1", /* @__PURE__ */ new Set(["align"])], ["h2", /* @__PURE__ */ new Set(["align"])], ["h3", /* @__PURE__ */ new Set(["align"])], ["h4", /* @__PURE__ */ new Set(["align"])], ["h5", /* @__PURE__ */ new Set(["align"])], ["h6", /* @__PURE__ */ new Set(["align"])], ["head", /* @__PURE__ */ new Set(["profile"])], ["hr", /* @__PURE__ */ new Set(["align", "noshade", "size", "width"])], ["html", /* @__PURE__ */ new Set(["manifest", "version"])], ["iframe", /* @__PURE__ */ new Set(["align", "allow", "allowfullscreen", "allowpaymentrequest", "allowusermedia", "frameborder", "height", "loading", "longdesc", "marginheight", "marginwidth", "name", "referrerpolicy", "sandbox", "scrolling", "src", "srcdoc", "width"])], ["img", /* @__PURE__ */ new Set(["align", "alt", "border", "crossorigin", "decoding", "fetchpriority", "height", "hspace", "ismap", "loading", "longdesc", "name", "referrerpolicy", "sizes", "src", "srcset", "usemap", "vspace", "width"])], ["input", /* @__PURE__ */ new Set(["accept", "align", "alt", "autocomplete", "checked", "dirname", "disabled", "form", "formaction", "formenctype", "formmethod", "formnovalidate", "formtarget", "height", "ismap", "list", "max", "maxlength", "min", "minlength", "multiple", "name", "pattern", "placeholder", "popovertarget", "popovertargetaction", "readonly", "required", "size", "src", "step", "type", "usemap", "value", "width"])], ["ins", /* @__PURE__ */ new Set(["cite", "datetime"])], ["isindex", /* @__PURE__ */ new Set(["prompt"])], ["label", /* @__PURE__ */ new Set(["for", "form"])], ["legend", /* @__PURE__ */ new Set(["align"])], ["li", /* @__PURE__ */ new Set(["type", "value"])], ["link", /* @__PURE__ */ new Set(["as", "blocking", "charset", "color", "crossorigin", "disabled", "fetchpriority", "href", "hreflang", "imagesizes", "imagesrcset", "integrity", "media", "referrerpolicy", "rel", "rev", "sizes", "target", "type"])], ["map", /* @__PURE__ */ new Set(["name"])], ["menu", /* @__PURE__ */ new Set(["compact"])], ["meta", /* @__PURE__ */ new Set(["charset", "content", "http-equiv", "media", "name", "scheme"])], ["meter", /* @__PURE__ */ new Set(["high", "low", "max", "min", "optimum", "value"])], ["object", /* @__PURE__ */ new Set(["align", "archive", "border", "classid", "codebase", "codetype", "data", "declare", "form", "height", "hspace", "name", "standby", "type", "typemustmatch", "usemap", "vspace", "width"])], ["ol", /* @__PURE__ */ new Set(["compact", "reversed", "start", "type"])], ["optgroup", /* @__PURE__ */ new Set(["disabled", "label"])], ["option", /* @__PURE__ */ new Set(["disabled", "label", "selected", "value"])], ["output", /* @__PURE__ */ new Set(["for", "form", "name"])], ["p", /* @__PURE__ */ new Set(["align"])], ["param", /* @__PURE__ */ new Set(["name", "type", "value", "valuetype"])], ["pre", /* @__PURE__ */ new Set(["width"])], ["progress", /* @__PURE__ */ new Set(["max", "value"])], ["q", /* @__PURE__ */ new Set(["cite"])], ["script", /* @__PURE__ */ new Set(["async", "blocking", "charset", "crossorigin", "defer", "fetchpriority", "integrity", "language", "nomodule", "referrerpolicy", "src", "type"])], ["select", /* @__PURE__ */ new Set(["autocomplete", "disabled", "form", "multiple", "name", "required", "size"])], ["slot", /* @__PURE__ */ new Set(["name"])], ["source", /* @__PURE__ */ new Set(["height", "media", "sizes", "src", "srcset", "type", "width"])], ["style", /* @__PURE__ */ new Set(["blocking", "media", "type"])], ["table", /* @__PURE__ */ new Set(["align", "bgcolor", "border", "cellpadding", "cellspacing", "frame", "rules", "summary", "width"])], ["tbody", /* @__PURE__ */ new Set(["align", "char", "charoff", "valign"])], ["td", /* @__PURE__ */ new Set(["abbr", "align", "axis", "bgcolor", "char", "charoff", "colspan", "headers", "height", "nowrap", "rowspan", "scope", "valign", "width"])], ["template", /* @__PURE__ */ new Set(["shadowrootclonable", "shadowrootdelegatesfocus", "shadowrootmode"])], ["textarea", /* @__PURE__ */ new Set(["autocomplete", "cols", "dirname", "disabled", "form", "maxlength", "minlength", "name", "placeholder", "readonly", "required", "rows", "wrap"])], ["tfoot", /* @__PURE__ */ new Set(["align", "char", "charoff", "valign"])], ["th", /* @__PURE__ */ new Set(["abbr", "align", "axis", "bgcolor", "char", "charoff", "colspan", "headers", "height", "nowrap", "rowspan", "scope", "valign", "width"])], ["thead", /* @__PURE__ */ new Set(["align", "char", "charoff", "valign"])], ["time", /* @__PURE__ */ new Set(["datetime"])], ["tr", /* @__PURE__ */ new Set(["align", "bgcolor", "char", "charoff", "valign"])], ["track", /* @__PURE__ */ new Set(["default", "kind", "label", "src", "srclang"])], ["ul", /* @__PURE__ */ new Set(["compact", "type"])], ["video", /* @__PURE__ */ new Set(["autoplay", "controls", "crossorigin", "height", "loop", "muted", "playsinline", "poster", "preload", "src", "width"])]]), Ks = /* @__PURE__ */ new Set(["a", "abbr", "acronym", "address", "applet", "area", "article", "aside", "audio", "b", "base", "basefont", "bdi", "bdo", "bgsound", "big", "blink", "blockquote", "body", "br", "button", "canvas", "caption", "center", "cite", "code", "col", "colgroup", "command", "content", "data", "datalist", "dd", "del", "details", "dfn", "dialog", "dir", "div", "dl", "dt", "element", "em", "embed", "fieldset", "figcaption", "figure", "font", "footer", "form", "frame", "frameset", "h1", "h2", "h3", "h4", "h5", "h6", "head", "header", "hgroup", "hr", "html", "i", "iframe", "image", "img", "input", "ins", "isindex", "kbd", "keygen", "label", "legend", "li", "link", "listing", "main", "map", "mark", "marquee", "math", "menu", "menuitem", "meta", "meter", "multicol", "nav", "nextid", "nobr", "noembed", "noframes", "noscript", "object", "ol", "optgroup", "option", "output", "p", "param", "picture", "plaintext", "pre", "progress", "q", "rb", "rbc", "rp", "rt", "rtc", "ruby", "s", "samp", "script", "search", "section", "select", "shadow", "slot", "small", "source", "spacer", "span", "strike", "strong", "style", "sub", "summary", "sup", "svg", "table", "tbody", "td", "template", "textarea", "tfoot", "th", "thead", "time", "title", "tr", "track", "tt", "u", "ul", "var", "video", "wbr", "xmp"]);
|
|
2721
|
-
function Xs(e) {
|
|
2722
|
-
if (e.type === "block") {
|
|
2723
|
-
if (e.name = L(!1, e.name.toLowerCase(), /\s+/gu, " ").trim(), e.type = "angularControlFlowBlock", !ft(e.parameters)) {
|
|
2724
|
-
delete e.parameters;
|
|
2725
|
-
return;
|
|
2726
|
-
}
|
|
2727
|
-
for (let t of e.parameters)
|
|
2728
|
-
t.type = "angularControlFlowBlockParameter";
|
|
2729
|
-
e.parameters = { type: "angularControlFlowBlockParameters", children: e.parameters, sourceSpan: new d(e.parameters[0].sourceSpan.start, de(!1, e.parameters, -1).sourceSpan.end) };
|
|
2730
|
-
}
|
|
2731
|
-
}
|
|
2732
|
-
function Ys(e) {
|
|
2733
|
-
e.type === "letDeclaration" && (e.type = "angularLetDeclaration", e.id = e.name, e.init = { type: "angularLetDeclarationInitializer", sourceSpan: new d(e.valueSpan.start, e.valueSpan.end), value: e.value }, delete e.name, delete e.value);
|
|
2734
|
-
}
|
|
2735
|
-
function Js(e) {
|
|
2736
|
-
(e.type === "plural" || e.type === "select") && (e.clause = e.type, e.type = "angularIcuExpression"), e.type === "expansionCase" && (e.type = "angularIcuCase");
|
|
2737
|
-
}
|
|
2738
|
-
function nn(e, t, r) {
|
|
2739
|
-
let { name: n, canSelfClose: a = !0, normalizeTagName: i = !1, normalizeAttributeName: s = !1, allowHtmComponentClosingTags: u = !1, isTagNameCaseSensitive: o = !1, shouldParseAsRawText: p } = t, { rootNodes: l, errors: f } = tr(e, { canSelfClose: a, allowHtmComponentClosingTags: u, isTagNameCaseSensitive: o, getTagContentType: p ? (...c) => p(...c) ? I.RAW_TEXT : void 0 : void 0, tokenizeAngularBlocks: n === "angular" ? !0 : void 0, tokenizeAngularLetDeclaration: n === "angular" ? !0 : void 0 });
|
|
2740
|
-
if (n === "vue") {
|
|
2741
|
-
if (l.some((y) => y.type === "docType" && y.value === "html" || y.type === "element" && y.name.toLowerCase() === "html"))
|
|
2742
|
-
return nn(e, sn, r);
|
|
2743
|
-
let c, g = () => c ?? (c = tr(e, { canSelfClose: a, allowHtmComponentClosingTags: u, isTagNameCaseSensitive: o })), A = (y) => g().rootNodes.find(({ startSourceSpan: T }) => T && T.start.offset === y.startSourceSpan.start.offset) ?? y;
|
|
2744
|
-
for (let [y, T] of l.entries()) {
|
|
2745
|
-
let { endSourceSpan: G, startSourceSpan: un } = T;
|
|
2746
|
-
if (G === null)
|
|
2747
|
-
f = g().errors, l[y] = A(T);
|
|
2748
|
-
else if (Qs(T, r)) {
|
|
2749
|
-
let At = g().errors.find((kt) => kt.span.start.offset > un.start.offset && kt.span.start.offset < G.end.offset);
|
|
2750
|
-
At && nr(At), l[y] = A(T);
|
|
2751
|
-
}
|
|
2752
|
-
}
|
|
2753
|
-
}
|
|
2754
|
-
f.length > 0 && nr(f[0]);
|
|
2755
|
-
let v = (c) => {
|
|
2756
|
-
let g = c.name.startsWith(":") ? c.name.slice(1).split(":")[0] : null, A = c.nameSpan.toString(), y = g !== null && A.startsWith(`${g}:`), T = y ? A.slice(g.length + 1) : A;
|
|
2757
|
-
c.name = T, c.namespace = g, c.hasExplicitNamespace = y;
|
|
2758
|
-
}, m = (c) => {
|
|
2759
|
-
switch (c.type) {
|
|
2760
|
-
case "element":
|
|
2761
|
-
v(c);
|
|
2762
|
-
for (let g of c.attrs)
|
|
2763
|
-
v(g), g.valueSpan ? (g.value = g.valueSpan.toString(), /["']/u.test(g.value[0]) && (g.value = g.value.slice(1, -1))) : g.value = null;
|
|
2764
|
-
break;
|
|
2765
|
-
case "comment":
|
|
2766
|
-
c.value = c.sourceSpan.toString().slice(4, -3);
|
|
2767
|
-
break;
|
|
2768
|
-
case "text":
|
|
2769
|
-
c.value = c.sourceSpan.toString();
|
|
2770
|
-
break;
|
|
2771
|
-
}
|
|
2772
|
-
}, C = (c, g) => {
|
|
2773
|
-
let A = c.toLowerCase();
|
|
2774
|
-
return g(A) ? A : c;
|
|
2775
|
-
}, w = (c) => {
|
|
2776
|
-
if (c.type === "element" && (i && (!c.namespace || c.namespace === c.tagDefinition.implicitNamespacePrefix || pe(c)) && (c.name = C(c.name, (g) => Ks.has(g))), s))
|
|
2777
|
-
for (let g of c.attrs)
|
|
2778
|
-
g.namespace || (g.name = C(g.name, (A) => Ye.has(c.name) && (Ye.get("*").has(A) || Ye.get(c.name).has(A))));
|
|
2779
|
-
}, E = (c) => {
|
|
2780
|
-
c.sourceSpan && c.endSourceSpan && (c.sourceSpan = new d(c.sourceSpan.start, c.endSourceSpan.end));
|
|
2781
|
-
}, x = (c) => {
|
|
2782
|
-
if (c.type === "element") {
|
|
2783
|
-
let g = et(o ? c.name : c.name.toLowerCase());
|
|
2784
|
-
!c.namespace || c.namespace === g.implicitNamespacePrefix || pe(c) ? c.tagDefinition = g : c.tagDefinition = et("");
|
|
2785
|
-
}
|
|
2786
|
-
};
|
|
2787
|
-
return Jr(new class extends ds {
|
|
2788
|
-
visitExpansionCase(c, g) {
|
|
2789
|
-
n === "angular" && this.visitChildren(g, (A) => {
|
|
2790
|
-
A(c.expression);
|
|
2791
|
-
});
|
|
2792
|
-
}
|
|
2793
|
-
visit(c) {
|
|
2794
|
-
m(c), x(c), w(c), E(c);
|
|
2795
|
-
}
|
|
2796
|
-
}(), l), l;
|
|
2797
|
-
}
|
|
2798
|
-
function Qs(e, t) {
|
|
2799
|
-
var r;
|
|
2800
|
-
if (e.type !== "element" || e.name !== "template")
|
|
2801
|
-
return !1;
|
|
2802
|
-
let n = (r = e.attrs.find((a) => a.name === "lang")) == null ? void 0 : r.value;
|
|
2803
|
-
return !n || Pe(t, { language: n }) === "html";
|
|
2804
|
-
}
|
|
2805
|
-
function nr(e) {
|
|
2806
|
-
let { msg: t, span: { start: r, end: n } } = e;
|
|
2807
|
-
throw Ps(t, { loc: { start: { line: r.line + 1, column: r.col + 1 }, end: { line: n.line + 1, column: n.col + 1 } }, cause: e });
|
|
2808
|
-
}
|
|
2809
|
-
function an(e, t, r = {}, n = !0) {
|
|
2810
|
-
let { frontMatter: a, content: i } = n ? Rs(e) : { frontMatter: null, content: e }, s = new Gr(e, r.filepath), u = new Ze(s, 0, 0, 0), o = u.moveBy(e.length), p = { type: "root", sourceSpan: new d(u, o), children: nn(i, t, r) };
|
|
2811
|
-
if (a) {
|
|
2812
|
-
let v = new Ze(s, 0, 0, 0), m = v.moveBy(a.raw.length);
|
|
2813
|
-
a.sourceSpan = new d(v, m), p.children.unshift(a);
|
|
2814
|
-
}
|
|
2815
|
-
let l = new Vs(p), f = (v, m) => {
|
|
2816
|
-
let { offset: C } = m, w = L(!1, e.slice(0, C), /[^\n\r]/gu, " "), E = an(w + v, t, r, !1);
|
|
2817
|
-
E.sourceSpan = new d(m, de(!1, E.children, -1).sourceSpan.end);
|
|
2818
|
-
let x = E.children[0];
|
|
2819
|
-
return x.length === C ? E.children.shift() : (x.sourceSpan = new d(x.sourceSpan.start.moveBy(C), x.sourceSpan.end), x.value = x.value.slice(C)), E;
|
|
2820
|
-
};
|
|
2821
|
-
return l.walk((v) => {
|
|
2822
|
-
if (v.type === "comment") {
|
|
2823
|
-
let m = zs(v, f);
|
|
2824
|
-
m && v.parent.replaceChild(v, m);
|
|
2825
|
-
}
|
|
2826
|
-
Xs(v), Ys(v), Js(v);
|
|
2827
|
-
}), l;
|
|
2828
|
-
}
|
|
2829
|
-
function Oe(e) {
|
|
2830
|
-
return { parse: (t, r) => an(t, e, r), hasPragma: Si, astFormat: "html", locStart: fe, locEnd: ve };
|
|
2831
|
-
}
|
|
2832
|
-
var sn = { name: "html", normalizeTagName: !0, normalizeAttributeName: !0, allowHtmComponentClosingTags: !0 }, Zs = Oe(sn), eu = Oe({ name: "angular" }), tu = Oe({ name: "vue", isTagNameCaseSensitive: !0, shouldParseAsRawText(e, t, r, n) {
|
|
2833
|
-
return e.toLowerCase() !== "html" && !r && (e !== "template" || n.some(({ name: a, value: i }) => a === "lang" && i !== "html" && i !== "" && i !== void 0));
|
|
2834
|
-
} }), ru = Oe({ name: "lwc", canSelfClose: !1 }), nu = { html: Gi }, iu = lr;
|
|
2835
|
-
export {
|
|
2836
|
-
iu as default,
|
|
2837
|
-
Ki as languages,
|
|
2838
|
-
Yi as options,
|
|
2839
|
-
Xr as parsers,
|
|
2840
|
-
nu as printers
|
|
2841
|
-
};
|
|
2842
|
-
//# sourceMappingURL=html-c18fb60e.js.map
|