@restura/core 0.1.0-alpha.8 → 0.1.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (38) hide show
  1. package/dist/index.d.mts +1439 -177
  2. package/dist/index.d.ts +1439 -177
  3. package/dist/index.js +1767 -708
  4. package/dist/index.js.map +1 -1
  5. package/dist/index.mjs +1751 -705
  6. package/dist/index.mjs.map +1 -1
  7. package/package.json +17 -6
  8. package/dist/acorn-SW5GI5G7.mjs +0 -3016
  9. package/dist/acorn-SW5GI5G7.mjs.map +0 -1
  10. package/dist/angular-FYEH6QOL.mjs +0 -1547
  11. package/dist/angular-FYEH6QOL.mjs.map +0 -1
  12. package/dist/babel-V6GZHMYX.mjs +0 -6911
  13. package/dist/babel-V6GZHMYX.mjs.map +0 -1
  14. package/dist/chunk-TL4KRYOF.mjs +0 -58
  15. package/dist/chunk-TL4KRYOF.mjs.map +0 -1
  16. package/dist/estree-67ZCSSSI.mjs +0 -4396
  17. package/dist/estree-67ZCSSSI.mjs.map +0 -1
  18. package/dist/flow-SJW7PRXX.mjs +0 -26365
  19. package/dist/flow-SJW7PRXX.mjs.map +0 -1
  20. package/dist/glimmer-PF2X22V2.mjs +0 -2995
  21. package/dist/glimmer-PF2X22V2.mjs.map +0 -1
  22. package/dist/graphql-NOJ5HX7K.mjs +0 -1253
  23. package/dist/graphql-NOJ5HX7K.mjs.map +0 -1
  24. package/dist/html-ROPIWVPQ.mjs +0 -2780
  25. package/dist/html-ROPIWVPQ.mjs.map +0 -1
  26. package/dist/index.cjs +0 -34
  27. package/dist/index.cjs.map +0 -1
  28. package/dist/index.d.cts +0 -3
  29. package/dist/markdown-PFYT4MSP.mjs +0 -3423
  30. package/dist/markdown-PFYT4MSP.mjs.map +0 -1
  31. package/dist/meriyah-5NLZXLMA.mjs +0 -2356
  32. package/dist/meriyah-5NLZXLMA.mjs.map +0 -1
  33. package/dist/postcss-ITO6IEN5.mjs +0 -5027
  34. package/dist/postcss-ITO6IEN5.mjs.map +0 -1
  35. package/dist/typescript-6IE7K56Q.mjs +0 -13392
  36. package/dist/typescript-6IE7K56Q.mjs.map +0 -1
  37. package/dist/yaml-DB2OVPLH.mjs +0 -4230
  38. package/dist/yaml-DB2OVPLH.mjs.map +0 -1
@@ -1,2995 +0,0 @@
1
- import {
2
- __publicField,
3
- __spreadProps,
4
- __spreadValues
5
- } from "./chunk-TL4KRYOF.mjs";
6
-
7
- // ../../node_modules/.pnpm/prettier@3.3.3/node_modules/prettier/plugins/glimmer.mjs
8
- var rs = Object.defineProperty;
9
- var Fr = (t5) => {
10
- throw TypeError(t5);
11
- };
12
- var zt = (t5, e) => {
13
- for (var r in e) rs(t5, r, { get: e[r], enumerable: true });
14
- };
15
- var Mr = (t5, e, r) => e.has(t5) || Fr("Cannot " + r);
16
- var $ = (t5, e, r) => (Mr(t5, e, "read from private field"), r ? r.call(t5) : e.get(t5));
17
- var Gt = (t5, e, r) => e.has(t5) ? Fr("Cannot add the same private member more than once") : e instanceof WeakSet ? e.add(t5) : e.set(t5, r);
18
- var Yt = (t5, e, r, n) => (Mr(t5, e, "write to private field"), n ? n.call(t5, r) : e.set(t5, r), r);
19
- var Rr = {};
20
- zt(Rr, { languages: () => Sn, parsers: () => Ir, printers: () => pa });
21
- var ns = (t5, e, r, n) => {
22
- if (!(t5 && e == null)) return e.replaceAll ? e.replaceAll(r, n) : r.global ? e.replace(r, n) : e.split(r).join(n);
23
- };
24
- var Kt = ns;
25
- var ze = "string";
26
- var Ge = "array";
27
- var Ye = "cursor";
28
- var Le = "indent";
29
- var _e = "align";
30
- var Ke = "trim";
31
- var De = "group";
32
- var Oe = "fill";
33
- var Be = "if-break";
34
- var We = "indent-if-break";
35
- var $e = "line-suffix";
36
- var je = "line-suffix-boundary";
37
- var ee = "line";
38
- var Qe = "label";
39
- var Ie = "break-parent";
40
- var ft = /* @__PURE__ */ new Set([Ye, Le, _e, Ke, De, Oe, Be, We, $e, je, ee, Qe, Ie]);
41
- function ss(t5) {
42
- if (typeof t5 == "string") return ze;
43
- if (Array.isArray(t5)) return Ge;
44
- if (!t5) return;
45
- let { type: e } = t5;
46
- if (ft.has(e)) return e;
47
- }
48
- var Xe = ss;
49
- var is = (t5) => new Intl.ListFormat("en-US", { type: "disjunction" }).format(t5);
50
- function as(t5) {
51
- let e = t5 === null ? "null" : typeof t5;
52
- if (e !== "string" && e !== "object") return `Unexpected doc '${e}',
53
- Expected it to be 'string' or 'object'.`;
54
- if (Xe(t5)) throw new Error("doc is valid.");
55
- let r = Object.prototype.toString.call(t5);
56
- if (r !== "[object Object]") return `Unexpected doc '${r}'.`;
57
- let n = is([...ft].map((s) => `'${s}'`));
58
- return `Unexpected doc.type '${t5.type}'.
59
- Expected it to be ${n}.`;
60
- }
61
- var Wt = class extends Error {
62
- constructor(e) {
63
- super(as(e));
64
- __publicField(this, "name", "InvalidDocError");
65
- this.doc = e;
66
- }
67
- };
68
- var $t = Wt;
69
- var zr = () => {
70
- };
71
- var be = zr;
72
- var dt = zr;
73
- function R(t5) {
74
- return be(t5), { type: Le, contents: t5 };
75
- }
76
- function os(t5, e) {
77
- return be(e), { type: _e, contents: e, n: t5 };
78
- }
79
- function q(t5, e = {}) {
80
- return be(t5), dt(e.expandedStates, true), { type: De, id: e.id, contents: t5, break: !!e.shouldBreak, expandedStates: e.expandedStates };
81
- }
82
- function jt(t5) {
83
- return os(-1, t5);
84
- }
85
- function Qt(t5) {
86
- return dt(t5), { type: Oe, parts: t5 };
87
- }
88
- function Xt(t5, e = "", r = {}) {
89
- return be(t5), e !== "" && be(e), { type: Be, breakContents: t5, flatContents: e, groupId: r.groupId };
90
- }
91
- var Gr = { type: Ie };
92
- var ls = { type: ee, hard: true };
93
- var cs = { type: ee, hard: true, literal: true };
94
- var D = { type: ee };
95
- var Y = { type: ee, soft: true };
96
- var ye = [ls, Gr];
97
- var Yr = [cs, Gr];
98
- function Ee(t5, e) {
99
- be(t5), dt(e);
100
- let r = [];
101
- for (let n = 0; n < e.length; n++) n !== 0 && r.push(t5), r.push(e[n]);
102
- return r;
103
- }
104
- var us = (t5, e, r) => {
105
- if (!(t5 && e == null)) return Array.isArray(e) || typeof e == "string" ? e[r < 0 ? e.length + r : r] : e.at(r);
106
- };
107
- var oe = us;
108
- function hs(t5, e) {
109
- if (typeof t5 == "string") return e(t5);
110
- let r = /* @__PURE__ */ new Map();
111
- return n(t5);
112
- function n(i) {
113
- if (r.has(i)) return r.get(i);
114
- let a = s(i);
115
- return r.set(i, a), a;
116
- }
117
- function s(i) {
118
- switch (Xe(i)) {
119
- case Ge:
120
- return e(i.map(n));
121
- case Oe:
122
- return e(__spreadProps(__spreadValues({}, i), { parts: i.parts.map(n) }));
123
- case Be:
124
- return e(__spreadProps(__spreadValues({}, i), { breakContents: n(i.breakContents), flatContents: n(i.flatContents) }));
125
- case De: {
126
- let { expandedStates: a, contents: o } = i;
127
- return a ? (a = a.map(n), o = a[0]) : o = n(o), e(__spreadProps(__spreadValues({}, i), { contents: o, expandedStates: a }));
128
- }
129
- case _e:
130
- case Le:
131
- case We:
132
- case Qe:
133
- case $e:
134
- return e(__spreadProps(__spreadValues({}, i), { contents: n(i.contents) }));
135
- case ze:
136
- case Ye:
137
- case Ke:
138
- case je:
139
- case ee:
140
- case Ie:
141
- return e(i);
142
- default:
143
- throw new $t(i);
144
- }
145
- }
146
- }
147
- function Kr(t5, e = Yr) {
148
- return hs(t5, (r) => typeof r == "string" ? Ee(e, r.split(`
149
- `)) : r);
150
- }
151
- var mt = "'";
152
- var Wr = '"';
153
- function ps(t5, e) {
154
- let r = e === true || e === mt ? mt : Wr, n = r === mt ? Wr : mt, s = 0, i = 0;
155
- for (let a of t5) a === r ? s++ : a === n && i++;
156
- return s > i ? n : r;
157
- }
158
- var gt = ps;
159
- function Jt(t5) {
160
- if (typeof t5 != "string") throw new TypeError("Expected a string");
161
- return t5.replace(/[|\\{}()[\]^$+*?.]/g, "\\$&").replace(/-/g, "\\x2d");
162
- }
163
- var G;
164
- var Zt = class {
165
- constructor(e) {
166
- Gt(this, G);
167
- Yt(this, G, new Set(e));
168
- }
169
- getLeadingWhitespaceCount(e) {
170
- let r = $(this, G), n = 0;
171
- for (let s = 0; s < e.length && r.has(e.charAt(s)); s++) n++;
172
- return n;
173
- }
174
- getTrailingWhitespaceCount(e) {
175
- let r = $(this, G), n = 0;
176
- for (let s = e.length - 1; s >= 0 && r.has(e.charAt(s)); s--) n++;
177
- return n;
178
- }
179
- getLeadingWhitespace(e) {
180
- let r = this.getLeadingWhitespaceCount(e);
181
- return e.slice(0, r);
182
- }
183
- getTrailingWhitespace(e) {
184
- let r = this.getTrailingWhitespaceCount(e);
185
- return e.slice(e.length - r);
186
- }
187
- hasLeadingWhitespace(e) {
188
- return $(this, G).has(e.charAt(0));
189
- }
190
- hasTrailingWhitespace(e) {
191
- return $(this, G).has(oe(false, e, -1));
192
- }
193
- trimStart(e) {
194
- let r = this.getLeadingWhitespaceCount(e);
195
- return e.slice(r);
196
- }
197
- trimEnd(e) {
198
- let r = this.getTrailingWhitespaceCount(e);
199
- return e.slice(0, e.length - r);
200
- }
201
- trim(e) {
202
- return this.trimEnd(this.trimStart(e));
203
- }
204
- split(e, r = false) {
205
- let n = `[${Jt([...$(this, G)].join(""))}]+`, s = new RegExp(r ? `(${n})` : n, "u");
206
- return e.split(s);
207
- }
208
- hasWhitespaceCharacter(e) {
209
- let r = $(this, G);
210
- return Array.prototype.some.call(e, (n) => r.has(n));
211
- }
212
- hasNonWhitespaceCharacter(e) {
213
- let r = $(this, G);
214
- return Array.prototype.some.call(e, (n) => !r.has(n));
215
- }
216
- isWhitespaceOnly(e) {
217
- let r = $(this, G);
218
- return Array.prototype.every.call(e, (n) => r.has(n));
219
- }
220
- };
221
- G = /* @__PURE__ */ new WeakMap();
222
- var $r = Zt;
223
- var fs = [" ", `
224
- `, "\f", "\r", " "];
225
- var ds = new $r(fs);
226
- var K = ds;
227
- function ms(t5) {
228
- return Array.isArray(t5) && t5.length > 0;
229
- }
230
- var Je = ms;
231
- var er = class extends Error {
232
- constructor(e, r, n = "type") {
233
- super(`Unexpected ${r} node ${n}: ${JSON.stringify(e[n])}.`);
234
- __publicField(this, "name", "UnexpectedNodeError");
235
- this.node = e;
236
- }
237
- };
238
- var jr = er;
239
- function Qr(t5, e) {
240
- if (t5.type === "TextNode") {
241
- let r = t5.chars.trim();
242
- if (!r) return null;
243
- e.chars = K.split(r).join(" ");
244
- }
245
- t5.type === "ElementNode" && (delete e.startTag, delete e.openTag, delete e.parts, delete e.endTag, delete e.closeTag, delete e.nameNode, delete e.body, delete e.blockParamNodes, delete e.params, delete e.path), t5.type === "Block" && (delete e.blockParamNodes, delete e.params), t5.type === "AttrNode" && t5.name.toLowerCase() === "class" && delete e.value, t5.type === "PathExpression" && (e.head = t5.head.original);
246
- }
247
- Qr.ignoredProperties = /* @__PURE__ */ new Set(["loc", "selfClosing"]);
248
- var Xr = Qr;
249
- var Ze = null;
250
- function et(t5) {
251
- if (Ze !== null && typeof Ze.property) {
252
- let e = Ze;
253
- return Ze = et.prototype = null, e;
254
- }
255
- return Ze = et.prototype = t5 != null ? t5 : /* @__PURE__ */ Object.create(null), new et();
256
- }
257
- var gs = 10;
258
- for (let t5 = 0; t5 <= gs; t5++) et();
259
- function tr(t5) {
260
- return et(t5);
261
- }
262
- function bs(t5, e = "type") {
263
- tr(t5);
264
- function r(n) {
265
- let s = n[e], i = t5[s];
266
- if (!Array.isArray(i)) throw Object.assign(new Error(`Missing visitor keys for '${s}'.`), { node: n });
267
- return i;
268
- }
269
- return r;
270
- }
271
- var Jr = bs;
272
- var Zr = { Template: ["body"], Block: ["body"], MustacheStatement: ["path", "params", "hash"], BlockStatement: ["path", "params", "hash", "program", "inverse"], ElementModifierStatement: ["path", "params", "hash"], CommentStatement: [], MustacheCommentStatement: [], ElementNode: ["attributes", "modifiers", "children", "comments"], AttrNode: ["value"], TextNode: [], ConcatStatement: ["parts"], SubExpression: ["path", "params", "hash"], PathExpression: [], StringLiteral: [], BooleanLiteral: [], NumberLiteral: [], NullLiteral: [], UndefinedLiteral: [], Hash: ["pairs"], HashPair: ["value"] };
273
- var ys = Jr(Zr);
274
- var en = ys;
275
- function Se(t5) {
276
- return t5.loc.start.offset;
277
- }
278
- function tt(t5) {
279
- return t5.loc.end.offset;
280
- }
281
- var tn = /* @__PURE__ */ new Set(["area", "base", "br", "col", "command", "embed", "hr", "img", "input", "keygen", "link", "meta", "param", "source", "track", "wbr"]);
282
- function nn(t5) {
283
- return t5.toUpperCase() === t5;
284
- }
285
- function Es(t5) {
286
- return t5.type === "ElementNode" && typeof t5.tag == "string" && !t5.tag.startsWith(":") && (nn(t5.tag[0]) || t5.tag.includes("."));
287
- }
288
- function Ss(t5) {
289
- return tn.has(t5.toLowerCase()) && !nn(t5[0]);
290
- }
291
- function rr(t5) {
292
- return t5.selfClosing === true || Ss(t5.tag) || Es(t5) && t5.children.every((e) => bt(e));
293
- }
294
- function bt(t5) {
295
- return t5.type === "TextNode" && !/\S/u.test(t5.chars);
296
- }
297
- function rn(t5) {
298
- return (t5 == null ? void 0 : t5.type) === "MustacheCommentStatement" && typeof t5.value == "string" && t5.value.trim() === "prettier-ignore";
299
- }
300
- function sn(t5) {
301
- return rn(t5.node) || t5.isInArray && (t5.key === "children" || t5.key === "body" || t5.key === "parts") && rn(t5.siblings[t5.index - 2]);
302
- }
303
- var fn = 2;
304
- function ws(t5, e, r) {
305
- var s, i, a, o, c, p, h, d, N;
306
- let { node: n } = t5;
307
- switch (n.type) {
308
- case "Block":
309
- case "Program":
310
- case "Template":
311
- return q(t5.map(r, "body"));
312
- case "ElementNode": {
313
- let g = q(Ts(t5, r)), T = e.htmlWhitespaceSensitivity === "ignore" && ((s = t5.next) == null ? void 0 : s.type) === "ElementNode" ? Y : "";
314
- if (rr(n)) return [g, T];
315
- let x = ["</", n.tag, ">"];
316
- return n.children.length === 0 ? [g, R(x), T] : e.htmlWhitespaceSensitivity === "ignore" ? [g, R(an(t5, e, r)), ye, R(x), T] : [g, R(q(an(t5, e, r))), R(x), T];
317
- }
318
- case "BlockStatement":
319
- return Cs(t5) ? [Ls(t5, r), cn(t5, r, e), un(t5, r, e)] : [Ps(t5, r), q([cn(t5, r, e), un(t5, r, e), _s(t5, r, e)])];
320
- case "ElementModifierStatement":
321
- return q(["{{", pn(t5, r), "}}"]);
322
- case "MustacheStatement":
323
- return q([yt(n), pn(t5, r), Et(n)]);
324
- case "SubExpression":
325
- return q(["(", Hs(t5, r), Y, ")"]);
326
- case "AttrNode": {
327
- let { name: g, value: T } = n, x = T.type === "TextNode";
328
- if (x && T.chars === "" && Se(T) === tt(T)) return g;
329
- let v = x ? gt(T.chars, e.singleQuote) : T.type === "ConcatStatement" ? gt(T.parts.map((H) => H.type === "TextNode" ? H.chars : "").join(""), e.singleQuote) : "", M = r("value");
330
- return [g, "=", v, g === "class" && v ? q(R(M)) : M, v];
331
- }
332
- case "ConcatStatement":
333
- return t5.map(r, "parts");
334
- case "Hash":
335
- return Ee(D, t5.map(r, "pairs"));
336
- case "HashPair":
337
- return [n.key, "=", r("value")];
338
- case "TextNode": {
339
- let g = Kt(false, n.chars, "{{", String.raw`\{{`), T = Os(t5);
340
- if (T) {
341
- if (T === "class") {
342
- let J = g.trim().split(/\s+/u).join(" "), re = false, V = false;
343
- return t5.parent.type === "ConcatStatement" && (((i = t5.previous) == null ? void 0 : i.type) === "MustacheStatement" && /^\s/u.test(g) && (re = true), ((a = t5.next) == null ? void 0 : a.type) === "MustacheStatement" && /\s$/u.test(g) && J !== "" && (V = true)), [re ? D : "", J, V ? D : ""];
344
- }
345
- return Kr(g);
346
- }
347
- let x = K.isWhitespaceOnly(g), { isFirst: C, isLast: v } = t5;
348
- if (e.htmlWhitespaceSensitivity !== "ignore") {
349
- let J = v && t5.parent.type === "Template", re = C && t5.parent.type === "Template";
350
- if (x) {
351
- if (re || J) return "";
352
- let _ = [D], se = Re(g);
353
- return se && (_ = rt(se)), v && (_ = _.map((ut) => jt(ut))), _;
354
- }
355
- let V = K.getLeadingWhitespace(g), Pe = [];
356
- if (V) {
357
- Pe = [D];
358
- let _ = Re(V);
359
- _ && (Pe = rt(_)), g = g.slice(V.length);
360
- }
361
- let U = K.getTrailingWhitespace(g), ne = [];
362
- if (U) {
363
- if (!J) {
364
- ne = [D];
365
- let _ = Re(U);
366
- _ && (ne = rt(_)), v && (ne = ne.map((se) => jt(se)));
367
- }
368
- g = g.slice(0, -U.length);
369
- }
370
- return [...Pe, Qt(hn(g)), ...ne];
371
- }
372
- let M = Re(g), H = Bs(g), X = Is(g);
373
- if ((C || v) && x && (t5.parent.type === "Block" || t5.parent.type === "ElementNode" || t5.parent.type === "Template")) return "";
374
- x && M ? (H = Math.min(M, fn), X = 0) : ((((o = t5.next) == null ? void 0 : o.type) === "BlockStatement" || ((c = t5.next) == null ? void 0 : c.type) === "ElementNode") && (X = Math.max(X, 1)), (((p = t5.previous) == null ? void 0 : p.type) === "BlockStatement" || ((h = t5.previous) == null ? void 0 : h.type) === "ElementNode") && (H = Math.max(H, 1)));
375
- let ve = "", Ae = "";
376
- return X === 0 && ((d = t5.next) == null ? void 0 : d.type) === "MustacheStatement" && (Ae = " "), H === 0 && ((N = t5.previous) == null ? void 0 : N.type) === "MustacheStatement" && (ve = " "), C && (H = 0, ve = ""), v && (X = 0, Ae = ""), K.hasLeadingWhitespace(g) && (g = ve + K.trimStart(g)), K.hasTrailingWhitespace(g) && (g = K.trimEnd(g) + Ae), [...rt(H), Qt(hn(g)), ...rt(X)];
377
- }
378
- case "MustacheCommentStatement": {
379
- let g = Se(n), T = tt(n), x = e.originalText.charAt(g + 2) === "~", C = e.originalText.charAt(T - 3) === "~", v = n.value.includes("}}") ? "--" : "";
380
- return ["{{", x ? "~" : "", "!", v, n.value, v, C ? "~" : "", "}}"];
381
- }
382
- case "PathExpression":
383
- return Ms(n);
384
- case "BooleanLiteral":
385
- return String(n.value);
386
- case "CommentStatement":
387
- return ["<!--", n.value, "-->"];
388
- case "StringLiteral":
389
- return Rs(t5, e);
390
- case "NumberLiteral":
391
- return String(n.value);
392
- case "UndefinedLiteral":
393
- return "undefined";
394
- case "NullLiteral":
395
- return "null";
396
- case "AtHead":
397
- case "VarHead":
398
- case "ThisHead":
399
- default:
400
- throw new jr(n, "Handlebars");
401
- }
402
- }
403
- function ks(t5, e) {
404
- return Se(t5) - Se(e);
405
- }
406
- function Ts(t5, e) {
407
- let { node: r } = t5, n = ["attributes", "modifiers", "comments"].filter((i) => Je(r[i])), s = n.flatMap((i) => r[i]).sort(ks);
408
- for (let i of n) t5.each(({ node: a }) => {
409
- let o = s.indexOf(a);
410
- s.splice(o, 1, [D, e()]);
411
- }, i);
412
- return Je(r.blockParams) && s.push(D, sr(r)), ["<", r.tag, R(s), Ns(r)];
413
- }
414
- function an(t5, e, r) {
415
- let { node: n } = t5, s = n.children.every((i) => bt(i));
416
- return e.htmlWhitespaceSensitivity === "ignore" && s ? "" : t5.map(({ isFirst: i }) => {
417
- let a = r();
418
- return i && e.htmlWhitespaceSensitivity === "ignore" ? [Y, a] : a;
419
- }, "children");
420
- }
421
- function Ns(t5) {
422
- return rr(t5) ? Xt([Y, "/>"], [" />", Y]) : Xt([Y, ">"], ">");
423
- }
424
- function yt(t5) {
425
- var n;
426
- let e = t5.trusting ? "{{{" : "{{", r = (n = t5.strip) != null && n.open ? "~" : "";
427
- return [e, r];
428
- }
429
- function Et(t5) {
430
- var n;
431
- let e = t5.trusting ? "}}}" : "}}";
432
- return [(n = t5.strip) != null && n.close ? "~" : "", e];
433
- }
434
- function vs(t5) {
435
- let e = yt(t5), r = t5.openStrip.open ? "~" : "";
436
- return [e, r, "#"];
437
- }
438
- function As(t5) {
439
- let e = Et(t5);
440
- return [t5.openStrip.close ? "~" : "", e];
441
- }
442
- function on(t5) {
443
- let e = yt(t5), r = t5.closeStrip.open ? "~" : "";
444
- return [e, r, "/"];
445
- }
446
- function ln(t5) {
447
- let e = Et(t5);
448
- return [t5.closeStrip.close ? "~" : "", e];
449
- }
450
- function dn(t5) {
451
- let e = yt(t5), r = t5.inverseStrip.open ? "~" : "";
452
- return [e, r];
453
- }
454
- function mn(t5) {
455
- let e = Et(t5);
456
- return [t5.inverseStrip.close ? "~" : "", e];
457
- }
458
- function Ps(t5, e) {
459
- let { node: r } = t5, n = [], s = St(t5, e);
460
- return s && n.push(q(s)), Je(r.program.blockParams) && n.push(sr(r.program)), q([vs(r), nr(t5, e), n.length > 0 ? R([D, Ee(D, n)]) : "", Y, As(r)]);
461
- }
462
- function xs(t5, e) {
463
- return [e.htmlWhitespaceSensitivity === "ignore" ? ye : "", dn(t5), "else", mn(t5)];
464
- }
465
- var gn = (t5, e) => t5.head.type === "VarHead" && e.head.type === "VarHead" && t5.head.name === e.head.name;
466
- function Cs(t5) {
467
- var n;
468
- let { grandparent: e, node: r } = t5;
469
- return ((n = e == null ? void 0 : e.inverse) == null ? void 0 : n.body.length) === 1 && e.inverse.body[0] === r && gn(e.inverse.body[0].path, e.path);
470
- }
471
- function Ls(t5, e) {
472
- let { node: r, grandparent: n } = t5;
473
- return q([dn(n), ["else", " ", n.inverse.body[0].path.head.name], R([D, q(St(t5, e)), ...Je(r.program.blockParams) ? [D, sr(r.program)] : []]), Y, mn(n)]);
474
- }
475
- function _s(t5, e, r) {
476
- let { node: n } = t5;
477
- return r.htmlWhitespaceSensitivity === "ignore" ? [bn(n) ? Y : ye, on(n), e("path"), ln(n)] : [on(n), e("path"), ln(n)];
478
- }
479
- function bn(t5) {
480
- return t5.type === "BlockStatement" && t5.program.body.every((e) => bt(e));
481
- }
482
- function Ds(t5) {
483
- return yn(t5) && t5.inverse.body.length === 1 && t5.inverse.body[0].type === "BlockStatement" && gn(t5.inverse.body[0].path, t5.path);
484
- }
485
- function yn(t5) {
486
- return t5.type === "BlockStatement" && t5.inverse;
487
- }
488
- function cn(t5, e, r) {
489
- let { node: n } = t5;
490
- if (bn(n)) return "";
491
- let s = e("program");
492
- return r.htmlWhitespaceSensitivity === "ignore" ? R([ye, s]) : R(s);
493
- }
494
- function un(t5, e, r) {
495
- let { node: n } = t5, s = e("inverse"), i = r.htmlWhitespaceSensitivity === "ignore" ? [ye, s] : s;
496
- return Ds(n) ? i : yn(n) ? [xs(n, r), R(i)] : "";
497
- }
498
- function hn(t5) {
499
- return Ee(D, K.split(t5));
500
- }
501
- function Os(t5) {
502
- for (let e = 0; e < 2; e++) {
503
- let r = t5.getParentNode(e);
504
- if ((r == null ? void 0 : r.type) === "AttrNode") return r.name.toLowerCase();
505
- }
506
- }
507
- function Re(t5) {
508
- return t5 = typeof t5 == "string" ? t5 : "", t5.split(`
509
- `).length - 1;
510
- }
511
- function Bs(t5) {
512
- t5 = typeof t5 == "string" ? t5 : "";
513
- let e = (t5.match(/^([^\S\n\r]*[\n\r])+/gu) || [])[0] || "";
514
- return Re(e);
515
- }
516
- function Is(t5) {
517
- t5 = typeof t5 == "string" ? t5 : "";
518
- let e = (t5.match(/([\n\r][^\S\n\r]*)+$/gu) || [])[0] || "";
519
- return Re(e);
520
- }
521
- function rt(t5 = 0) {
522
- return Array.from({ length: Math.min(t5, fn) }).fill(ye);
523
- }
524
- function Rs(t5, e) {
525
- let { node: { value: r } } = t5, n = gt(r, qs(t5) ? !e.singleQuote : e.singleQuote);
526
- return [n, Kt(false, r, n, `\\${n}`), n];
527
- }
528
- function qs(t5) {
529
- let { ancestors: e } = t5, r = e.findIndex((n) => n.type !== "SubExpression");
530
- return r !== -1 && e[r + 1].type === "ConcatStatement" && e[r + 2].type === "AttrNode";
531
- }
532
- function Hs(t5, e) {
533
- let r = nr(t5, e), n = St(t5, e);
534
- return n ? R([r, D, q(n)]) : r;
535
- }
536
- function pn(t5, e) {
537
- let r = nr(t5, e), n = St(t5, e);
538
- return n ? [R([r, D, n]), Y] : r;
539
- }
540
- function nr(t5, e) {
541
- return e("path");
542
- }
543
- function St(t5, e) {
544
- var s;
545
- let { node: r } = t5, n = [];
546
- return r.params.length > 0 && n.push(...t5.map(e, "params")), ((s = r.hash) == null ? void 0 : s.pairs.length) > 0 && n.push(e("hash")), n.length === 0 ? "" : Ee(D, n);
547
- }
548
- function sr(t5) {
549
- return ["as |", t5.blockParams.join(" "), "|"];
550
- }
551
- var Vs = new Set("!\"#%&'()*+,./;<=>@[\\]^`{|}~");
552
- var Us = /* @__PURE__ */ new Set(["true", "false", "null", "undefined"]);
553
- var Fs = (t5, e) => e === 0 && t5.startsWith("@") ? false : e !== 0 && Us.has(t5) || /\s/u.test(t5) || /^\d/u.test(t5) || Array.prototype.some.call(t5, (r) => Vs.has(r));
554
- function Ms(t5) {
555
- return t5.tail.length === 0 && t5.original.includes("/") ? t5.original : [t5.head.original, ...t5.tail].map((r, n) => Fs(r, n) ? `[${r}]` : r).join(".");
556
- }
557
- var zs = { print: ws, massageAstNode: Xr, hasPrettierIgnore: sn, getVisitorKeys: en };
558
- var En = zs;
559
- var Sn = [{ linguistLanguageId: 155, name: "Handlebars", type: "markup", color: "#f7931e", aliases: ["hbs", "htmlbars"], extensions: [".handlebars", ".hbs"], tmScope: "text.html.handlebars", aceMode: "handlebars", parsers: ["glimmer"], vscodeLanguageIds: ["handlebars"] }];
560
- var Ir = {};
561
- zt(Ir, { glimmer: () => ha });
562
- var Gs = Object.freeze([]);
563
- function kn() {
564
- return Gs;
565
- }
566
- var Po = kn();
567
- var xo = kn();
568
- function w(t5, e) {
569
- if (!t5) throw new Error(e || "assertion failure");
570
- }
571
- function F(t5) {
572
- Js.warn(`DEPRECATION: ${t5}`);
573
- }
574
- function kt(t5) {
575
- if (t5 == null) throw new Error("Expected value to be present");
576
- return t5;
577
- }
578
- function Tn(t5, e) {
579
- if (t5 == null) throw new Error(e);
580
- return t5;
581
- }
582
- function we(t5) {
583
- return t5.length > 0;
584
- }
585
- function Tt(t5, e = "unexpected empty list") {
586
- if (!we(t5)) throw new Error(e);
587
- }
588
- function qe(t5, e = "unexpected empty list") {
589
- return Tt(t5, e), t5;
590
- }
591
- function Nt(t5) {
592
- return t5.length === 0 ? void 0 : t5[t5.length - 1];
593
- }
594
- function Nn(t5) {
595
- return t5.length === 0 ? void 0 : t5[0];
596
- }
597
- if (false) {
598
- let t5 = (n) => {
599
- let s = n.name;
600
- if (s === void 0) {
601
- let i = /function (\w+)\s*\(/u.exec(String(n));
602
- s = i && i[1] || "";
603
- }
604
- return s.replace(/^bound /u, "");
605
- }, e = (n) => {
606
- let s, i;
607
- return n.constructor && typeof n.constructor == "function" && (i = t5(n.constructor)), "toString" in n && n.toString !== Object.prototype.toString && n.toString !== Function.prototype.toString && (s = n.toString()), s && /<.*:ember\d+>/u.test(s) && i && i[0] !== "_" && i.length > 2 && i !== "Class" ? s.replace(/<.*:/u, `<${i}:`) : s || i;
608
- }, r = (n) => String(n);
609
- Ys = (n) => typeof n == "function" ? t5(n) || "(unknown function)" : typeof n == "object" && n !== null ? e(n) || "(unknown object)" : r(n);
610
- }
611
- var ir = function(t5) {
612
- return t5[t5.MAX_SMI = 1073741823] = "MAX_SMI", t5[t5.MIN_SMI = -1073741824] = "MIN_SMI", t5[t5.SIGN_BIT = -536870913] = "SIGN_BIT", t5[t5.MAX_INT = 536870911] = "MAX_INT", t5[t5.MIN_INT = -536870912] = "MIN_INT", t5[t5.FALSE_HANDLE = 0] = "FALSE_HANDLE", t5[t5.TRUE_HANDLE = 1] = "TRUE_HANDLE", t5[t5.NULL_HANDLE = 2] = "NULL_HANDLE", t5[t5.UNDEFINED_HANDLE = 3] = "UNDEFINED_HANDLE", t5[t5.ENCODED_FALSE_HANDLE = 0] = "ENCODED_FALSE_HANDLE", t5[t5.ENCODED_TRUE_HANDLE = 1] = "ENCODED_TRUE_HANDLE", t5[t5.ENCODED_NULL_HANDLE = 2] = "ENCODED_NULL_HANDLE", t5[t5.ENCODED_UNDEFINED_HANDLE = 3] = "ENCODED_UNDEFINED_HANDLE", t5;
613
- }({});
614
- function Ks(t5) {
615
- return t5 & ir.SIGN_BIT;
616
- }
617
- function Ws(t5) {
618
- return t5 | ~ir.SIGN_BIT;
619
- }
620
- function $s(t5) {
621
- return ~t5;
622
- }
623
- function js(t5) {
624
- return ~t5;
625
- }
626
- function Qs(t5) {
627
- return t5 |= 0, t5 < 0 ? Ks(t5) : $s(t5);
628
- }
629
- function Xs(t5) {
630
- return t5 |= 0, t5 > ir.SIGN_BIT ? js(t5) : Ws(t5);
631
- }
632
- [1, -1].forEach((t5) => Xs(Qs(t5)));
633
- var ar = Object.assign;
634
- var Js = console;
635
- var wn = console;
636
- function vn(t5, e = "unexpected unreachable branch") {
637
- throw wn.log("unreachable", t5), wn.log(`${e} :: ${JSON.stringify(t5)} (${t5})`), new Error("code reached unreachable");
638
- }
639
- var Zs = function() {
640
- var t5 = function(ie, m, E, b) {
641
- for (E = E || {}, b = ie.length; b--; E[ie[b]] = m) ;
642
- return E;
643
- }, e = [2, 44], r = [1, 20], n = [5, 14, 15, 19, 29, 34, 39, 44, 47, 48, 52, 56, 60], s = [1, 35], i = [1, 38], a = [1, 30], o = [1, 31], c = [1, 32], p = [1, 33], h = [1, 34], d = [1, 37], N = [14, 15, 19, 29, 34, 39, 44, 47, 48, 52, 56, 60], g = [14, 15, 19, 29, 34, 44, 47, 48, 52, 56, 60], T = [15, 18], x = [14, 15, 19, 29, 34, 47, 48, 52, 56, 60], C = [33, 64, 71, 79, 80, 81, 82, 83, 84], v = [23, 33, 55, 64, 67, 71, 74, 79, 80, 81, 82, 83, 84], M = [1, 51], H = [23, 33, 55, 64, 67, 71, 74, 79, 80, 81, 82, 83, 84, 86], X = [2, 43], ve = [55, 64, 71, 79, 80, 81, 82, 83, 84], Ae = [1, 58], J = [1, 59], re = [1, 66], V = [33, 64, 71, 74, 79, 80, 81, 82, 83, 84], Pe = [23, 64, 71, 79, 80, 81, 82, 83, 84], U = [1, 76], ne = [64, 67, 71, 79, 80, 81, 82, 83, 84], _ = [33, 74], se = [23, 33, 55, 67, 71, 74], ut = [1, 106], It = [1, 118], qr = [71, 76], Rt = { trace: function() {
644
- }, yy: {}, symbols_: { error: 2, root: 3, program: 4, EOF: 5, program_repetition0: 6, statement: 7, mustache: 8, block: 9, rawBlock: 10, partial: 11, partialBlock: 12, content: 13, COMMENT: 14, CONTENT: 15, openRawBlock: 16, rawBlock_repetition0: 17, END_RAW_BLOCK: 18, OPEN_RAW_BLOCK: 19, helperName: 20, openRawBlock_repetition0: 21, openRawBlock_option0: 22, CLOSE_RAW_BLOCK: 23, openBlock: 24, block_option0: 25, closeBlock: 26, openInverse: 27, block_option1: 28, OPEN_BLOCK: 29, openBlock_repetition0: 30, openBlock_option0: 31, openBlock_option1: 32, CLOSE: 33, OPEN_INVERSE: 34, openInverse_repetition0: 35, openInverse_option0: 36, openInverse_option1: 37, openInverseChain: 38, OPEN_INVERSE_CHAIN: 39, openInverseChain_repetition0: 40, openInverseChain_option0: 41, openInverseChain_option1: 42, inverseAndProgram: 43, INVERSE: 44, inverseChain: 45, inverseChain_option0: 46, OPEN_ENDBLOCK: 47, OPEN: 48, expr: 49, mustache_repetition0: 50, mustache_option0: 51, OPEN_UNESCAPED: 52, mustache_repetition1: 53, mustache_option1: 54, CLOSE_UNESCAPED: 55, OPEN_PARTIAL: 56, partial_repetition0: 57, partial_option0: 58, openPartialBlock: 59, OPEN_PARTIAL_BLOCK: 60, openPartialBlock_repetition0: 61, openPartialBlock_option0: 62, sexpr: 63, OPEN_SEXPR: 64, sexpr_repetition0: 65, sexpr_option0: 66, CLOSE_SEXPR: 67, hash: 68, hash_repetition_plus0: 69, hashSegment: 70, ID: 71, EQUALS: 72, blockParams: 73, OPEN_BLOCK_PARAMS: 74, blockParams_repetition_plus0: 75, CLOSE_BLOCK_PARAMS: 76, path: 77, dataName: 78, STRING: 79, NUMBER: 80, BOOLEAN: 81, UNDEFINED: 82, NULL: 83, DATA: 84, pathSegments: 85, SEP: 86, $accept: 0, $end: 1 }, terminals_: { 2: "error", 5: "EOF", 14: "COMMENT", 15: "CONTENT", 18: "END_RAW_BLOCK", 19: "OPEN_RAW_BLOCK", 23: "CLOSE_RAW_BLOCK", 29: "OPEN_BLOCK", 33: "CLOSE", 34: "OPEN_INVERSE", 39: "OPEN_INVERSE_CHAIN", 44: "INVERSE", 47: "OPEN_ENDBLOCK", 48: "OPEN", 52: "OPEN_UNESCAPED", 55: "CLOSE_UNESCAPED", 56: "OPEN_PARTIAL", 60: "OPEN_PARTIAL_BLOCK", 64: "OPEN_SEXPR", 67: "CLOSE_SEXPR", 71: "ID", 72: "EQUALS", 74: "OPEN_BLOCK_PARAMS", 76: "CLOSE_BLOCK_PARAMS", 79: "STRING", 80: "NUMBER", 81: "BOOLEAN", 82: "UNDEFINED", 83: "NULL", 84: "DATA", 86: "SEP" }, productions_: [0, [3, 2], [4, 1], [7, 1], [7, 1], [7, 1], [7, 1], [7, 1], [7, 1], [7, 1], [13, 1], [10, 3], [16, 5], [9, 4], [9, 4], [24, 6], [27, 6], [38, 6], [43, 2], [45, 3], [45, 1], [26, 3], [8, 5], [8, 5], [11, 5], [12, 3], [59, 5], [49, 1], [49, 1], [63, 5], [68, 1], [70, 3], [73, 3], [20, 1], [20, 1], [20, 1], [20, 1], [20, 1], [20, 1], [20, 1], [78, 2], [77, 1], [85, 3], [85, 1], [6, 0], [6, 2], [17, 0], [17, 2], [21, 0], [21, 2], [22, 0], [22, 1], [25, 0], [25, 1], [28, 0], [28, 1], [30, 0], [30, 2], [31, 0], [31, 1], [32, 0], [32, 1], [35, 0], [35, 2], [36, 0], [36, 1], [37, 0], [37, 1], [40, 0], [40, 2], [41, 0], [41, 1], [42, 0], [42, 1], [46, 0], [46, 1], [50, 0], [50, 2], [51, 0], [51, 1], [53, 0], [53, 2], [54, 0], [54, 1], [57, 0], [57, 2], [58, 0], [58, 1], [61, 0], [61, 2], [62, 0], [62, 1], [65, 0], [65, 2], [66, 0], [66, 1], [69, 1], [69, 2], [75, 1], [75, 2]], performAction: function(m, E, b, y, P, l, xe) {
645
- var u = l.length - 1;
646
- switch (P) {
647
- case 1:
648
- return l[u - 1];
649
- case 2:
650
- this.$ = y.prepareProgram(l[u]);
651
- break;
652
- case 3:
653
- case 4:
654
- case 5:
655
- case 6:
656
- case 7:
657
- case 8:
658
- case 20:
659
- case 27:
660
- case 28:
661
- case 33:
662
- case 34:
663
- this.$ = l[u];
664
- break;
665
- case 9:
666
- this.$ = { type: "CommentStatement", value: y.stripComment(l[u]), strip: y.stripFlags(l[u], l[u]), loc: y.locInfo(this._$) };
667
- break;
668
- case 10:
669
- this.$ = { type: "ContentStatement", original: l[u], value: l[u], loc: y.locInfo(this._$) };
670
- break;
671
- case 11:
672
- this.$ = y.prepareRawBlock(l[u - 2], l[u - 1], l[u], this._$);
673
- break;
674
- case 12:
675
- this.$ = { path: l[u - 3], params: l[u - 2], hash: l[u - 1] };
676
- break;
677
- case 13:
678
- this.$ = y.prepareBlock(l[u - 3], l[u - 2], l[u - 1], l[u], false, this._$);
679
- break;
680
- case 14:
681
- this.$ = y.prepareBlock(l[u - 3], l[u - 2], l[u - 1], l[u], true, this._$);
682
- break;
683
- case 15:
684
- this.$ = { open: l[u - 5], path: l[u - 4], params: l[u - 3], hash: l[u - 2], blockParams: l[u - 1], strip: y.stripFlags(l[u - 5], l[u]) };
685
- break;
686
- case 16:
687
- case 17:
688
- this.$ = { path: l[u - 4], params: l[u - 3], hash: l[u - 2], blockParams: l[u - 1], strip: y.stripFlags(l[u - 5], l[u]) };
689
- break;
690
- case 18:
691
- this.$ = { strip: y.stripFlags(l[u - 1], l[u - 1]), program: l[u] };
692
- break;
693
- case 19:
694
- var ae = y.prepareBlock(l[u - 2], l[u - 1], l[u], l[u], false, this._$), Me = y.prepareProgram([ae], l[u - 1].loc);
695
- Me.chained = true, this.$ = { strip: l[u - 2].strip, program: Me, chain: true };
696
- break;
697
- case 21:
698
- this.$ = { path: l[u - 1], strip: y.stripFlags(l[u - 2], l[u]) };
699
- break;
700
- case 22:
701
- case 23:
702
- this.$ = y.prepareMustache(l[u - 3], l[u - 2], l[u - 1], l[u - 4], y.stripFlags(l[u - 4], l[u]), this._$);
703
- break;
704
- case 24:
705
- this.$ = { type: "PartialStatement", name: l[u - 3], params: l[u - 2], hash: l[u - 1], indent: "", strip: y.stripFlags(l[u - 4], l[u]), loc: y.locInfo(this._$) };
706
- break;
707
- case 25:
708
- this.$ = y.preparePartialBlock(l[u - 2], l[u - 1], l[u], this._$);
709
- break;
710
- case 26:
711
- this.$ = { path: l[u - 3], params: l[u - 2], hash: l[u - 1], strip: y.stripFlags(l[u - 4], l[u]) };
712
- break;
713
- case 29:
714
- this.$ = { type: "SubExpression", path: l[u - 3], params: l[u - 2], hash: l[u - 1], loc: y.locInfo(this._$) };
715
- break;
716
- case 30:
717
- this.$ = { type: "Hash", pairs: l[u], loc: y.locInfo(this._$) };
718
- break;
719
- case 31:
720
- this.$ = { type: "HashPair", key: y.id(l[u - 2]), value: l[u], loc: y.locInfo(this._$) };
721
- break;
722
- case 32:
723
- this.$ = y.id(l[u - 1]);
724
- break;
725
- case 35:
726
- this.$ = { type: "StringLiteral", value: l[u], original: l[u], loc: y.locInfo(this._$) };
727
- break;
728
- case 36:
729
- this.$ = { type: "NumberLiteral", value: Number(l[u]), original: Number(l[u]), loc: y.locInfo(this._$) };
730
- break;
731
- case 37:
732
- this.$ = { type: "BooleanLiteral", value: l[u] === "true", original: l[u] === "true", loc: y.locInfo(this._$) };
733
- break;
734
- case 38:
735
- this.$ = { type: "UndefinedLiteral", original: void 0, value: void 0, loc: y.locInfo(this._$) };
736
- break;
737
- case 39:
738
- this.$ = { type: "NullLiteral", original: null, value: null, loc: y.locInfo(this._$) };
739
- break;
740
- case 40:
741
- this.$ = y.preparePath(true, l[u], this._$);
742
- break;
743
- case 41:
744
- this.$ = y.preparePath(false, l[u], this._$);
745
- break;
746
- case 42:
747
- l[u - 2].push({ part: y.id(l[u]), original: l[u], separator: l[u - 1] }), this.$ = l[u - 2];
748
- break;
749
- case 43:
750
- this.$ = [{ part: y.id(l[u]), original: l[u] }];
751
- break;
752
- case 44:
753
- case 46:
754
- case 48:
755
- case 56:
756
- case 62:
757
- case 68:
758
- case 76:
759
- case 80:
760
- case 84:
761
- case 88:
762
- case 92:
763
- this.$ = [];
764
- break;
765
- case 45:
766
- case 47:
767
- case 49:
768
- case 57:
769
- case 63:
770
- case 69:
771
- case 77:
772
- case 81:
773
- case 85:
774
- case 89:
775
- case 93:
776
- case 97:
777
- case 99:
778
- l[u - 1].push(l[u]);
779
- break;
780
- case 96:
781
- case 98:
782
- this.$ = [l[u]];
783
- break;
784
- }
785
- }, table: [t5([5, 14, 15, 19, 29, 34, 48, 52, 56, 60], e, { 3: 1, 4: 2, 6: 3 }), { 1: [3] }, { 5: [1, 4] }, t5([5, 39, 44, 47], [2, 2], { 7: 5, 8: 6, 9: 7, 10: 8, 11: 9, 12: 10, 13: 11, 24: 15, 27: 16, 16: 17, 59: 19, 14: [1, 12], 15: r, 19: [1, 23], 29: [1, 21], 34: [1, 22], 48: [1, 13], 52: [1, 14], 56: [1, 18], 60: [1, 24] }), { 1: [2, 1] }, t5(n, [2, 45]), t5(n, [2, 3]), t5(n, [2, 4]), t5(n, [2, 5]), t5(n, [2, 6]), t5(n, [2, 7]), t5(n, [2, 8]), t5(n, [2, 9]), { 20: 26, 49: 25, 63: 27, 64: s, 71: i, 77: 28, 78: 29, 79: a, 80: o, 81: c, 82: p, 83: h, 84: d, 85: 36 }, { 20: 26, 49: 39, 63: 27, 64: s, 71: i, 77: 28, 78: 29, 79: a, 80: o, 81: c, 82: p, 83: h, 84: d, 85: 36 }, t5(N, e, { 6: 3, 4: 40 }), t5(g, e, { 6: 3, 4: 41 }), t5(T, [2, 46], { 17: 42 }), { 20: 26, 49: 43, 63: 27, 64: s, 71: i, 77: 28, 78: 29, 79: a, 80: o, 81: c, 82: p, 83: h, 84: d, 85: 36 }, t5(x, e, { 6: 3, 4: 44 }), t5([5, 14, 15, 18, 19, 29, 34, 39, 44, 47, 48, 52, 56, 60], [2, 10]), { 20: 45, 71: i, 77: 28, 78: 29, 79: a, 80: o, 81: c, 82: p, 83: h, 84: d, 85: 36 }, { 20: 46, 71: i, 77: 28, 78: 29, 79: a, 80: o, 81: c, 82: p, 83: h, 84: d, 85: 36 }, { 20: 47, 71: i, 77: 28, 78: 29, 79: a, 80: o, 81: c, 82: p, 83: h, 84: d, 85: 36 }, { 20: 26, 49: 48, 63: 27, 64: s, 71: i, 77: 28, 78: 29, 79: a, 80: o, 81: c, 82: p, 83: h, 84: d, 85: 36 }, t5(C, [2, 76], { 50: 49 }), t5(v, [2, 27]), t5(v, [2, 28]), t5(v, [2, 33]), t5(v, [2, 34]), t5(v, [2, 35]), t5(v, [2, 36]), t5(v, [2, 37]), t5(v, [2, 38]), t5(v, [2, 39]), { 20: 26, 49: 50, 63: 27, 64: s, 71: i, 77: 28, 78: 29, 79: a, 80: o, 81: c, 82: p, 83: h, 84: d, 85: 36 }, t5(v, [2, 41], { 86: M }), { 71: i, 85: 52 }, t5(H, X), t5(ve, [2, 80], { 53: 53 }), { 25: 54, 38: 56, 39: Ae, 43: 57, 44: J, 45: 55, 47: [2, 52] }, { 28: 60, 43: 61, 44: J, 47: [2, 54] }, { 13: 63, 15: r, 18: [1, 62] }, t5(C, [2, 84], { 57: 64 }), { 26: 65, 47: re }, t5(V, [2, 56], { 30: 67 }), t5(V, [2, 62], { 35: 68 }), t5(Pe, [2, 48], { 21: 69 }), t5(C, [2, 88], { 61: 70 }), { 20: 26, 33: [2, 78], 49: 72, 51: 71, 63: 27, 64: s, 68: 73, 69: 74, 70: 75, 71: U, 77: 28, 78: 29, 79: a, 80: o, 81: c, 82: p, 83: h, 84: d, 85: 36 }, t5(ne, [2, 92], { 65: 77 }), { 71: [1, 78] }, t5(v, [2, 40], { 86: M }), { 20: 26, 49: 80, 54: 79, 55: [2, 82], 63: 27, 64: s, 68: 81, 69: 74, 70: 75, 71: U, 77: 28, 78: 29, 79: a, 80: o, 81: c, 82: p, 83: h, 84: d, 85: 36 }, { 26: 82, 47: re }, { 47: [2, 53] }, t5(N, e, { 6: 3, 4: 83 }), { 47: [2, 20] }, { 20: 84, 71: i, 77: 28, 78: 29, 79: a, 80: o, 81: c, 82: p, 83: h, 84: d, 85: 36 }, t5(x, e, { 6: 3, 4: 85 }), { 26: 86, 47: re }, { 47: [2, 55] }, t5(n, [2, 11]), t5(T, [2, 47]), { 20: 26, 33: [2, 86], 49: 88, 58: 87, 63: 27, 64: s, 68: 89, 69: 74, 70: 75, 71: U, 77: 28, 78: 29, 79: a, 80: o, 81: c, 82: p, 83: h, 84: d, 85: 36 }, t5(n, [2, 25]), { 20: 90, 71: i, 77: 28, 78: 29, 79: a, 80: o, 81: c, 82: p, 83: h, 84: d, 85: 36 }, t5(_, [2, 58], { 20: 26, 63: 27, 77: 28, 78: 29, 85: 36, 69: 74, 70: 75, 31: 91, 49: 92, 68: 93, 64: s, 71: U, 79: a, 80: o, 81: c, 82: p, 83: h, 84: d }), t5(_, [2, 64], { 20: 26, 63: 27, 77: 28, 78: 29, 85: 36, 69: 74, 70: 75, 36: 94, 49: 95, 68: 96, 64: s, 71: U, 79: a, 80: o, 81: c, 82: p, 83: h, 84: d }), { 20: 26, 22: 97, 23: [2, 50], 49: 98, 63: 27, 64: s, 68: 99, 69: 74, 70: 75, 71: U, 77: 28, 78: 29, 79: a, 80: o, 81: c, 82: p, 83: h, 84: d, 85: 36 }, { 20: 26, 33: [2, 90], 49: 101, 62: 100, 63: 27, 64: s, 68: 102, 69: 74, 70: 75, 71: U, 77: 28, 78: 29, 79: a, 80: o, 81: c, 82: p, 83: h, 84: d, 85: 36 }, { 33: [1, 103] }, t5(C, [2, 77]), { 33: [2, 79] }, t5([23, 33, 55, 67, 74], [2, 30], { 70: 104, 71: [1, 105] }), t5(se, [2, 96]), t5(H, X, { 72: ut }), { 20: 26, 49: 108, 63: 27, 64: s, 66: 107, 67: [2, 94], 68: 109, 69: 74, 70: 75, 71: U, 77: 28, 78: 29, 79: a, 80: o, 81: c, 82: p, 83: h, 84: d, 85: 36 }, t5(H, [2, 42]), { 55: [1, 110] }, t5(ve, [2, 81]), { 55: [2, 83] }, t5(n, [2, 13]), { 38: 56, 39: Ae, 43: 57, 44: J, 45: 112, 46: 111, 47: [2, 74] }, t5(V, [2, 68], { 40: 113 }), { 47: [2, 18] }, t5(n, [2, 14]), { 33: [1, 114] }, t5(C, [2, 85]), { 33: [2, 87] }, { 33: [1, 115] }, { 32: 116, 33: [2, 60], 73: 117, 74: It }, t5(V, [2, 57]), t5(_, [2, 59]), { 33: [2, 66], 37: 119, 73: 120, 74: It }, t5(V, [2, 63]), t5(_, [2, 65]), { 23: [1, 121] }, t5(Pe, [2, 49]), { 23: [2, 51] }, { 33: [1, 122] }, t5(C, [2, 89]), { 33: [2, 91] }, t5(n, [2, 22]), t5(se, [2, 97]), { 72: ut }, { 20: 26, 49: 123, 63: 27, 64: s, 71: i, 77: 28, 78: 29, 79: a, 80: o, 81: c, 82: p, 83: h, 84: d, 85: 36 }, { 67: [1, 124] }, t5(ne, [2, 93]), { 67: [2, 95] }, t5(n, [2, 23]), { 47: [2, 19] }, { 47: [2, 75] }, t5(_, [2, 70], { 20: 26, 63: 27, 77: 28, 78: 29, 85: 36, 69: 74, 70: 75, 41: 125, 49: 126, 68: 127, 64: s, 71: U, 79: a, 80: o, 81: c, 82: p, 83: h, 84: d }), t5(n, [2, 24]), t5(n, [2, 21]), { 33: [1, 128] }, { 33: [2, 61] }, { 71: [1, 130], 75: 129 }, { 33: [1, 131] }, { 33: [2, 67] }, t5(T, [2, 12]), t5(x, [2, 26]), t5(se, [2, 31]), t5(v, [2, 29]), { 33: [2, 72], 42: 132, 73: 133, 74: It }, t5(V, [2, 69]), t5(_, [2, 71]), t5(N, [2, 15]), { 71: [1, 135], 76: [1, 134] }, t5(qr, [2, 98]), t5(g, [2, 16]), { 33: [1, 136] }, { 33: [2, 73] }, { 33: [2, 32] }, t5(qr, [2, 99]), t5(N, [2, 17])], defaultActions: { 4: [2, 1], 55: [2, 53], 57: [2, 20], 61: [2, 55], 73: [2, 79], 81: [2, 83], 85: [2, 18], 89: [2, 87], 99: [2, 51], 102: [2, 91], 109: [2, 95], 111: [2, 19], 112: [2, 75], 117: [2, 61], 120: [2, 67], 133: [2, 73], 134: [2, 32] }, parseError: function(m, E) {
786
- if (E.recoverable) this.trace(m);
787
- else {
788
- var b = new Error(m);
789
- throw b.hash = E, b;
790
- }
791
- }, parse: function(m) {
792
- var E = this, b = [0], y = [], P = [null], l = [], xe = this.table, u = "", ae = 0, Me = 0, Hr = 0, Jn = 2, Vr = 1, Zn = l.slice.call(arguments, 1), L = Object.create(this.lexer), me = { yy: {} };
793
- for (var Ht in this.yy) Object.prototype.hasOwnProperty.call(this.yy, Ht) && (me.yy[Ht] = this.yy[Ht]);
794
- L.setInput(m, me.yy), me.yy.lexer = L, me.yy.parser = this, typeof L.yylloc > "u" && (L.yylloc = {});
795
- var Vt = L.yylloc;
796
- l.push(Vt);
797
- var es = L.options && L.options.ranges;
798
- typeof me.yy.parseError == "function" ? this.parseError = me.yy.parseError : this.parseError = Object.getPrototypeOf(this).parseError;
799
- function fa(W) {
800
- b.length = b.length - 2 * W, P.length = P.length - W, l.length = l.length - W;
801
- }
802
- for (var ts = function() {
803
- var W;
804
- return W = L.lex() || Vr, typeof W != "number" && (W = E.symbols_[W] || W), W;
805
- }, I, Ut, ge, z, da, Ft, Ce = {}, ht, Z, Ur, pt; ; ) {
806
- if (ge = b[b.length - 1], this.defaultActions[ge] ? z = this.defaultActions[ge] : ((I === null || typeof I > "u") && (I = ts()), z = xe[ge] && xe[ge][I]), typeof z > "u" || !z.length || !z[0]) {
807
- var Mt = "";
808
- pt = [];
809
- for (ht in xe[ge]) this.terminals_[ht] && ht > Jn && pt.push("'" + this.terminals_[ht] + "'");
810
- L.showPosition ? Mt = "Parse error on line " + (ae + 1) + `:
811
- ` + L.showPosition() + `
812
- Expecting ` + pt.join(", ") + ", got '" + (this.terminals_[I] || I) + "'" : Mt = "Parse error on line " + (ae + 1) + ": Unexpected " + (I == Vr ? "end of input" : "'" + (this.terminals_[I] || I) + "'"), this.parseError(Mt, { text: L.match, token: this.terminals_[I] || I, line: L.yylineno, loc: Vt, expected: pt });
813
- }
814
- if (z[0] instanceof Array && z.length > 1) throw new Error("Parse Error: multiple actions possible at state: " + ge + ", token: " + I);
815
- switch (z[0]) {
816
- case 1:
817
- b.push(I), P.push(L.yytext), l.push(L.yylloc), b.push(z[1]), I = null, Ut ? (I = Ut, Ut = null) : (Me = L.yyleng, u = L.yytext, ae = L.yylineno, Vt = L.yylloc, Hr > 0 && Hr--);
818
- break;
819
- case 2:
820
- if (Z = this.productions_[z[1]][1], Ce.$ = P[P.length - Z], Ce._$ = { first_line: l[l.length - (Z || 1)].first_line, last_line: l[l.length - 1].last_line, first_column: l[l.length - (Z || 1)].first_column, last_column: l[l.length - 1].last_column }, es && (Ce._$.range = [l[l.length - (Z || 1)].range[0], l[l.length - 1].range[1]]), Ft = this.performAction.apply(Ce, [u, Me, ae, me.yy, z[1], P, l].concat(Zn)), typeof Ft < "u") return Ft;
821
- Z && (b = b.slice(0, -1 * Z * 2), P = P.slice(0, -1 * Z), l = l.slice(0, -1 * Z)), b.push(this.productions_[z[1]][0]), P.push(Ce.$), l.push(Ce._$), Ur = xe[b[b.length - 2]][b[b.length - 1]], b.push(Ur);
822
- break;
823
- case 3:
824
- return true;
825
- }
826
- }
827
- return true;
828
- } }, Xn = /* @__PURE__ */ function() {
829
- var ie = { EOF: 1, parseError: function(E, b) {
830
- if (this.yy.parser) this.yy.parser.parseError(E, b);
831
- else throw new Error(E);
832
- }, setInput: function(m, E) {
833
- return this.yy = E || this.yy || {}, this._input = m, this._more = this._backtrack = this.done = false, this.yylineno = this.yyleng = 0, this.yytext = this.matched = this.match = "", this.conditionStack = ["INITIAL"], this.yylloc = { first_line: 1, first_column: 0, last_line: 1, last_column: 0 }, this.options.ranges && (this.yylloc.range = [0, 0]), this.offset = 0, this;
834
- }, input: function() {
835
- var m = this._input[0];
836
- this.yytext += m, this.yyleng++, this.offset++, this.match += m, this.matched += m;
837
- var E = m.match(/(?:\r\n?|\n).*/g);
838
- return E ? (this.yylineno++, this.yylloc.last_line++) : this.yylloc.last_column++, this.options.ranges && this.yylloc.range[1]++, this._input = this._input.slice(1), m;
839
- }, unput: function(m) {
840
- var E = m.length, b = m.split(/(?:\r\n?|\n)/g);
841
- this._input = m + this._input, this.yytext = this.yytext.substr(0, this.yytext.length - E), this.offset -= E;
842
- var y = this.match.split(/(?:\r\n?|\n)/g);
843
- this.match = this.match.substr(0, this.match.length - 1), this.matched = this.matched.substr(0, this.matched.length - 1), b.length - 1 && (this.yylineno -= b.length - 1);
844
- var P = this.yylloc.range;
845
- return this.yylloc = { first_line: this.yylloc.first_line, last_line: this.yylineno + 1, first_column: this.yylloc.first_column, last_column: b ? (b.length === y.length ? this.yylloc.first_column : 0) + y[y.length - b.length].length - b[0].length : this.yylloc.first_column - E }, this.options.ranges && (this.yylloc.range = [P[0], P[0] + this.yyleng - E]), this.yyleng = this.yytext.length, this;
846
- }, more: function() {
847
- return this._more = true, this;
848
- }, reject: function() {
849
- if (this.options.backtrack_lexer) this._backtrack = true;
850
- else return this.parseError("Lexical error on line " + (this.yylineno + 1) + `. You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true).
851
- ` + this.showPosition(), { text: "", token: null, line: this.yylineno });
852
- return this;
853
- }, less: function(m) {
854
- this.unput(this.match.slice(m));
855
- }, pastInput: function() {
856
- var m = this.matched.substr(0, this.matched.length - this.match.length);
857
- return (m.length > 20 ? "..." : "") + m.substr(-20).replace(/\n/g, "");
858
- }, upcomingInput: function() {
859
- var m = this.match;
860
- return m.length < 20 && (m += this._input.substr(0, 20 - m.length)), (m.substr(0, 20) + (m.length > 20 ? "..." : "")).replace(/\n/g, "");
861
- }, showPosition: function() {
862
- var m = this.pastInput(), E = new Array(m.length + 1).join("-");
863
- return m + this.upcomingInput() + `
864
- ` + E + "^";
865
- }, test_match: function(m, E) {
866
- var b, y, P;
867
- if (this.options.backtrack_lexer && (P = { yylineno: this.yylineno, yylloc: { first_line: this.yylloc.first_line, last_line: this.last_line, first_column: this.yylloc.first_column, last_column: this.yylloc.last_column }, yytext: this.yytext, match: this.match, matches: this.matches, matched: this.matched, yyleng: this.yyleng, offset: this.offset, _more: this._more, _input: this._input, yy: this.yy, conditionStack: this.conditionStack.slice(0), done: this.done }, this.options.ranges && (P.yylloc.range = this.yylloc.range.slice(0))), y = m[0].match(/(?:\r\n?|\n).*/g), y && (this.yylineno += y.length), this.yylloc = { first_line: this.yylloc.last_line, last_line: this.yylineno + 1, first_column: this.yylloc.last_column, last_column: y ? y[y.length - 1].length - y[y.length - 1].match(/\r?\n?/)[0].length : this.yylloc.last_column + m[0].length }, this.yytext += m[0], this.match += m[0], this.matches = m, this.yyleng = this.yytext.length, this.options.ranges && (this.yylloc.range = [this.offset, this.offset += this.yyleng]), this._more = false, this._backtrack = false, this._input = this._input.slice(m[0].length), this.matched += m[0], b = this.performAction.call(this, this.yy, this, E, this.conditionStack[this.conditionStack.length - 1]), this.done && this._input && (this.done = false), b) return b;
868
- if (this._backtrack) {
869
- for (var l in P) this[l] = P[l];
870
- return false;
871
- }
872
- return false;
873
- }, next: function() {
874
- if (this.done) return this.EOF;
875
- this._input || (this.done = true);
876
- var m, E, b, y;
877
- this._more || (this.yytext = "", this.match = "");
878
- for (var P = this._currentRules(), l = 0; l < P.length; l++) if (b = this._input.match(this.rules[P[l]]), b && (!E || b[0].length > E[0].length)) {
879
- if (E = b, y = l, this.options.backtrack_lexer) {
880
- if (m = this.test_match(b, P[l]), m !== false) return m;
881
- if (this._backtrack) {
882
- E = false;
883
- continue;
884
- } else return false;
885
- } else if (!this.options.flex) break;
886
- }
887
- return E ? (m = this.test_match(E, P[y]), m !== false ? m : false) : this._input === "" ? this.EOF : this.parseError("Lexical error on line " + (this.yylineno + 1) + `. Unrecognized text.
888
- ` + this.showPosition(), { text: "", token: null, line: this.yylineno });
889
- }, lex: function() {
890
- var E = this.next();
891
- return E || this.lex();
892
- }, begin: function(E) {
893
- this.conditionStack.push(E);
894
- }, popState: function() {
895
- var E = this.conditionStack.length - 1;
896
- return E > 0 ? this.conditionStack.pop() : this.conditionStack[0];
897
- }, _currentRules: function() {
898
- return this.conditionStack.length && this.conditionStack[this.conditionStack.length - 1] ? this.conditions[this.conditionStack[this.conditionStack.length - 1]].rules : this.conditions.INITIAL.rules;
899
- }, topState: function(E) {
900
- return E = this.conditionStack.length - 1 - Math.abs(E || 0), E >= 0 ? this.conditionStack[E] : "INITIAL";
901
- }, pushState: function(E) {
902
- this.begin(E);
903
- }, stateStackSize: function() {
904
- return this.conditionStack.length;
905
- }, options: {}, performAction: function(E, b, y, P) {
906
- function l(u, ae) {
907
- return b.yytext = b.yytext.substring(u, b.yyleng - ae + u);
908
- }
909
- var xe = P;
910
- switch (y) {
911
- case 0:
912
- if (b.yytext.slice(-2) === "\\\\" ? (l(0, 1), this.begin("mu")) : b.yytext.slice(-1) === "\\" ? (l(0, 1), this.begin("emu")) : this.begin("mu"), b.yytext) return 15;
913
- break;
914
- case 1:
915
- return 15;
916
- case 2:
917
- return this.popState(), 15;
918
- break;
919
- case 3:
920
- return this.begin("raw"), 15;
921
- break;
922
- case 4:
923
- return this.popState(), this.conditionStack[this.conditionStack.length - 1] === "raw" ? 15 : (l(5, 9), 18);
924
- case 5:
925
- return 15;
926
- case 6:
927
- return this.popState(), 14;
928
- break;
929
- case 7:
930
- return 64;
931
- case 8:
932
- return 67;
933
- case 9:
934
- return 19;
935
- case 10:
936
- return this.popState(), this.begin("raw"), 23;
937
- break;
938
- case 11:
939
- return 56;
940
- case 12:
941
- return 60;
942
- case 13:
943
- return 29;
944
- case 14:
945
- return 47;
946
- case 15:
947
- return this.popState(), 44;
948
- break;
949
- case 16:
950
- return this.popState(), 44;
951
- break;
952
- case 17:
953
- return 34;
954
- case 18:
955
- return 39;
956
- case 19:
957
- return 52;
958
- case 20:
959
- return 48;
960
- case 21:
961
- this.unput(b.yytext), this.popState(), this.begin("com");
962
- break;
963
- case 22:
964
- return this.popState(), 14;
965
- break;
966
- case 23:
967
- return 48;
968
- case 24:
969
- return 72;
970
- case 25:
971
- return 71;
972
- case 26:
973
- return 71;
974
- case 27:
975
- return 86;
976
- case 28:
977
- break;
978
- case 29:
979
- return this.popState(), 55;
980
- break;
981
- case 30:
982
- return this.popState(), 33;
983
- break;
984
- case 31:
985
- return b.yytext = l(1, 2).replace(/\\"/g, '"'), 79;
986
- break;
987
- case 32:
988
- return b.yytext = l(1, 2).replace(/\\'/g, "'"), 79;
989
- break;
990
- case 33:
991
- return 84;
992
- case 34:
993
- return 81;
994
- case 35:
995
- return 81;
996
- case 36:
997
- return 82;
998
- case 37:
999
- return 83;
1000
- case 38:
1001
- return 80;
1002
- case 39:
1003
- return 74;
1004
- case 40:
1005
- return 76;
1006
- case 41:
1007
- return 71;
1008
- case 42:
1009
- return b.yytext = b.yytext.replace(/\\([\\\]])/g, "$1"), 71;
1010
- break;
1011
- case 43:
1012
- return "INVALID";
1013
- case 44:
1014
- return 5;
1015
- }
1016
- }, rules: [/^(?:[^\x00]*?(?=(\{\{)))/, /^(?:[^\x00]+)/, /^(?:[^\x00]{2,}?(?=(\{\{|\\\{\{|\\\\\{\{|$)))/, /^(?:\{\{\{\{(?=[^/]))/, /^(?:\{\{\{\{\/[^\s!"#%-,\.\/;->@\[-\^`\{-~]+(?=[=}\s\/.])\}\}\}\})/, /^(?:[^\x00]+?(?=(\{\{\{\{)))/, /^(?:[\s\S]*?--(~)?\}\})/, /^(?:\()/, /^(?:\))/, /^(?:\{\{\{\{)/, /^(?:\}\}\}\})/, /^(?:\{\{(~)?>)/, /^(?:\{\{(~)?#>)/, /^(?:\{\{(~)?#\*?)/, /^(?:\{\{(~)?\/)/, /^(?:\{\{(~)?\^\s*(~)?\}\})/, /^(?:\{\{(~)?\s*else\s*(~)?\}\})/, /^(?:\{\{(~)?\^)/, /^(?:\{\{(~)?\s*else\b)/, /^(?:\{\{(~)?\{)/, /^(?:\{\{(~)?&)/, /^(?:\{\{(~)?!--)/, /^(?:\{\{(~)?![\s\S]*?\}\})/, /^(?:\{\{(~)?\*?)/, /^(?:=)/, /^(?:\.\.)/, /^(?:\.(?=([=~}\s\/.)|])))/, /^(?:[\/.])/, /^(?:\s+)/, /^(?:\}(~)?\}\})/, /^(?:(~)?\}\})/, /^(?:"(\\["]|[^"])*")/, /^(?:'(\\[']|[^'])*')/, /^(?:@)/, /^(?:true(?=([~}\s)])))/, /^(?:false(?=([~}\s)])))/, /^(?:undefined(?=([~}\s)])))/, /^(?:null(?=([~}\s)])))/, /^(?:-?[0-9]+(?:\.[0-9]+)?(?=([~}\s)])))/, /^(?:as\s+\|)/, /^(?:\|)/, /^(?:([^\s!"#%-,\.\/;->@\[-\^`\{-~]+(?=([=~}\s\/.)|]))))/, /^(?:\[(\\\]|[^\]])*\])/, /^(?:.)/, /^(?:$)/], conditions: { mu: { rules: [7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44], inclusive: false }, emu: { rules: [2], inclusive: false }, com: { rules: [6], inclusive: false }, raw: { rules: [3, 4, 5], inclusive: false }, INITIAL: { rules: [0, 1, 44], inclusive: true } } };
1017
- return ie;
1018
- }();
1019
- Rt.lexer = Xn;
1020
- function qt() {
1021
- this.yy = {};
1022
- }
1023
- return qt.prototype = Rt, Rt.Parser = qt, new qt();
1024
- }();
1025
- var vt = Zs;
1026
- var or = ["description", "fileName", "lineNumber", "endLineNumber", "message", "name", "number", "stack"];
1027
- function lr(t5, e) {
1028
- var r = e && e.loc, n, s, i, a;
1029
- r && (n = r.start.line, s = r.end.line, i = r.start.column, a = r.end.column, t5 += " - " + n + ":" + i);
1030
- for (var o = Error.prototype.constructor.call(this, t5), c = 0; c < or.length; c++) this[or[c]] = o[or[c]];
1031
- Error.captureStackTrace && Error.captureStackTrace(this, lr);
1032
- try {
1033
- r && (this.lineNumber = n, this.endLineNumber = s, Object.defineProperty ? (Object.defineProperty(this, "column", { value: i, enumerable: true }), Object.defineProperty(this, "endColumn", { value: a, enumerable: true })) : (this.column = i, this.endColumn = a));
1034
- } catch (e2) {
1035
- }
1036
- }
1037
- lr.prototype = new Error();
1038
- var le = lr;
1039
- function At() {
1040
- this.parents = [];
1041
- }
1042
- At.prototype = { constructor: At, mutating: false, acceptKey: function(t5, e) {
1043
- var r = this.accept(t5[e]);
1044
- if (this.mutating) {
1045
- if (r && !At.prototype[r.type]) throw new le('Unexpected node type "' + r.type + '" found when accepting ' + e + " on " + t5.type);
1046
- t5[e] = r;
1047
- }
1048
- }, acceptRequired: function(t5, e) {
1049
- if (this.acceptKey(t5, e), !t5[e]) throw new le(t5.type + " requires " + e);
1050
- }, acceptArray: function(t5) {
1051
- for (var e = 0, r = t5.length; e < r; e++) this.acceptKey(t5, e), t5[e] || (t5.splice(e, 1), e--, r--);
1052
- }, accept: function(t5) {
1053
- if (t5) {
1054
- if (!this[t5.type]) throw new le("Unknown type: " + t5.type, t5);
1055
- this.current && this.parents.unshift(this.current), this.current = t5;
1056
- var e = this[t5.type](t5);
1057
- if (this.current = this.parents.shift(), !this.mutating || e) return e;
1058
- if (e !== false) return t5;
1059
- }
1060
- }, Program: function(t5) {
1061
- this.acceptArray(t5.body);
1062
- }, MustacheStatement: Pt, Decorator: Pt, BlockStatement: An, DecoratorBlock: An, PartialStatement: Pn, PartialBlockStatement: function(t5) {
1063
- Pn.call(this, t5), this.acceptKey(t5, "program");
1064
- }, ContentStatement: function() {
1065
- }, CommentStatement: function() {
1066
- }, SubExpression: Pt, PathExpression: function() {
1067
- }, StringLiteral: function() {
1068
- }, NumberLiteral: function() {
1069
- }, BooleanLiteral: function() {
1070
- }, UndefinedLiteral: function() {
1071
- }, NullLiteral: function() {
1072
- }, Hash: function(t5) {
1073
- this.acceptArray(t5.pairs);
1074
- }, HashPair: function(t5) {
1075
- this.acceptRequired(t5, "value");
1076
- } };
1077
- function Pt(t5) {
1078
- this.acceptRequired(t5, "path"), this.acceptArray(t5.params), this.acceptKey(t5, "hash");
1079
- }
1080
- function An(t5) {
1081
- Pt.call(this, t5), this.acceptKey(t5, "program"), this.acceptKey(t5, "inverse");
1082
- }
1083
- function Pn(t5) {
1084
- this.acceptRequired(t5, "name"), this.acceptArray(t5.params), this.acceptKey(t5, "hash");
1085
- }
1086
- var xn = At;
1087
- function j(t5) {
1088
- t5 === void 0 && (t5 = {}), this.options = t5;
1089
- }
1090
- j.prototype = new xn();
1091
- j.prototype.Program = function(t5) {
1092
- var e = !this.options.ignoreStandalone, r = !this.isRootSeen;
1093
- this.isRootSeen = true;
1094
- for (var n = t5.body, s = 0, i = n.length; s < i; s++) {
1095
- var a = n[s], o = this.accept(a);
1096
- if (o) {
1097
- var c = cr(n, s, r), p = ur(n, s, r), h = o.openStandalone && c, d = o.closeStandalone && p, N = o.inlineStandalone && c && p;
1098
- o.close && ke(n, s, true), o.open && ce(n, s, true), e && N && (ke(n, s), ce(n, s) && a.type === "PartialStatement" && (a.indent = /([ \t]+$)/.exec(n[s - 1].original)[1])), e && h && (ke((a.program || a.inverse).body), ce(n, s)), e && d && (ke(n, s), ce((a.inverse || a.program).body));
1099
- }
1100
- }
1101
- return t5;
1102
- };
1103
- j.prototype.BlockStatement = j.prototype.DecoratorBlock = j.prototype.PartialBlockStatement = function(t5) {
1104
- this.accept(t5.program), this.accept(t5.inverse);
1105
- var e = t5.program || t5.inverse, r = t5.program && t5.inverse, n = r, s = r;
1106
- if (r && r.chained) for (n = r.body[0].program; s.chained; ) s = s.body[s.body.length - 1].program;
1107
- var i = { open: t5.openStrip.open, close: t5.closeStrip.close, openStandalone: ur(e.body), closeStandalone: cr((n || e).body) };
1108
- if (t5.openStrip.close && ke(e.body, null, true), r) {
1109
- var a = t5.inverseStrip;
1110
- a.open && ce(e.body, null, true), a.close && ke(n.body, null, true), t5.closeStrip.open && ce(s.body, null, true), !this.options.ignoreStandalone && cr(e.body) && ur(n.body) && (ce(e.body), ke(n.body));
1111
- } else t5.closeStrip.open && ce(e.body, null, true);
1112
- return i;
1113
- };
1114
- j.prototype.Decorator = j.prototype.MustacheStatement = function(t5) {
1115
- return t5.strip;
1116
- };
1117
- j.prototype.PartialStatement = j.prototype.CommentStatement = function(t5) {
1118
- var e = t5.strip || {};
1119
- return { inlineStandalone: true, open: e.open, close: e.close };
1120
- };
1121
- function cr(t5, e, r) {
1122
- e === void 0 && (e = t5.length);
1123
- var n = t5[e - 1], s = t5[e - 2];
1124
- if (!n) return r;
1125
- if (n.type === "ContentStatement") return (s || !r ? /\r?\n\s*?$/ : /(^|\r?\n)\s*?$/).test(n.original);
1126
- }
1127
- function ur(t5, e, r) {
1128
- e === void 0 && (e = -1);
1129
- var n = t5[e + 1], s = t5[e + 2];
1130
- if (!n) return r;
1131
- if (n.type === "ContentStatement") return (s || !r ? /^\s*?\r?\n/ : /^\s*?(\r?\n|$)/).test(n.original);
1132
- }
1133
- function ke(t5, e, r) {
1134
- var n = t5[e == null ? 0 : e + 1];
1135
- if (!(!n || n.type !== "ContentStatement" || !r && n.rightStripped)) {
1136
- var s = n.value;
1137
- n.value = n.value.replace(r ? /^\s+/ : /^[ \t]*\r?\n?/, ""), n.rightStripped = n.value !== s;
1138
- }
1139
- }
1140
- function ce(t5, e, r) {
1141
- var n = t5[e == null ? t5.length - 1 : e - 1];
1142
- if (!(!n || n.type !== "ContentStatement" || !r && n.leftStripped)) {
1143
- var s = n.value;
1144
- return n.value = n.value.replace(r ? /\s+$/ : /[ \t]+$/, ""), n.leftStripped = n.value !== s, n.leftStripped;
1145
- }
1146
- }
1147
- var Cn = j;
1148
- var nt = {};
1149
- zt(nt, { SourceLocation: () => pr, id: () => ei, prepareBlock: () => ai, prepareMustache: () => si, preparePartialBlock: () => li, preparePath: () => ni, prepareProgram: () => oi, prepareRawBlock: () => ii, stripComment: () => ri, stripFlags: () => ti });
1150
- function hr(t5, e) {
1151
- if (e = e.path ? e.path.original : e, t5.path.original !== e) {
1152
- var r = { loc: t5.path.loc };
1153
- throw new le(t5.path.original + " doesn't match " + e, r);
1154
- }
1155
- }
1156
- function pr(t5, e) {
1157
- this.source = t5, this.start = { line: e.first_line, column: e.first_column }, this.end = { line: e.last_line, column: e.last_column };
1158
- }
1159
- function ei(t5) {
1160
- return /^\[.*\]$/.test(t5) ? t5.substring(1, t5.length - 1) : t5;
1161
- }
1162
- function ti(t5, e) {
1163
- return { open: t5.charAt(2) === "~", close: e.charAt(e.length - 3) === "~" };
1164
- }
1165
- function ri(t5) {
1166
- return t5.replace(/^\{\{~?!-?-?/, "").replace(/-?-?~?\}\}$/, "");
1167
- }
1168
- function ni(t5, e, r) {
1169
- r = this.locInfo(r);
1170
- for (var n = t5 ? "@" : "", s = [], i = 0, a = 0, o = e.length; a < o; a++) {
1171
- var c = e[a].part, p = e[a].original !== c;
1172
- if (n += (e[a].separator || "") + c, !p && (c === ".." || c === "." || c === "this")) {
1173
- if (s.length > 0) throw new le("Invalid path: " + n, { loc: r });
1174
- c === ".." && i++;
1175
- } else s.push(c);
1176
- }
1177
- return { type: "PathExpression", data: t5, depth: i, parts: s, original: n, loc: r };
1178
- }
1179
- function si(t5, e, r, n, s, i) {
1180
- var a = n.charAt(3) || n.charAt(2), o = a !== "{" && a !== "&", c = /\*/.test(n);
1181
- return { type: c ? "Decorator" : "MustacheStatement", path: t5, params: e, hash: r, escaped: o, strip: s, loc: this.locInfo(i) };
1182
- }
1183
- function ii(t5, e, r, n) {
1184
- hr(t5, r), n = this.locInfo(n);
1185
- var s = { type: "Program", body: e, strip: {}, loc: n };
1186
- return { type: "BlockStatement", path: t5.path, params: t5.params, hash: t5.hash, program: s, openStrip: {}, inverseStrip: {}, closeStrip: {}, loc: n };
1187
- }
1188
- function ai(t5, e, r, n, s, i) {
1189
- n && n.path && hr(t5, n);
1190
- var a = /\*/.test(t5.open);
1191
- e.blockParams = t5.blockParams;
1192
- var o, c;
1193
- if (r) {
1194
- if (a) throw new le("Unexpected inverse block on decorator", r);
1195
- r.chain && (r.program.body[0].closeStrip = n.strip), c = r.strip, o = r.program;
1196
- }
1197
- return s && (s = o, o = e, e = s), { type: a ? "DecoratorBlock" : "BlockStatement", path: t5.path, params: t5.params, hash: t5.hash, program: e, inverse: o, openStrip: t5.strip, inverseStrip: c, closeStrip: n && n.strip, loc: this.locInfo(i) };
1198
- }
1199
- function oi(t5, e) {
1200
- if (!e && t5.length) {
1201
- var r = t5[0].loc, n = t5[t5.length - 1].loc;
1202
- r && n && (e = { source: r.source, start: { line: r.start.line, column: r.start.column }, end: { line: n.end.line, column: n.end.column } });
1203
- }
1204
- return { type: "Program", body: t5, strip: {}, loc: e };
1205
- }
1206
- function li(t5, e, r, n) {
1207
- return hr(t5, r), { type: "PartialBlockStatement", name: t5.path, params: t5.params, hash: t5.hash, program: e, openStrip: t5.strip, closeStrip: r && r.strip, loc: this.locInfo(n) };
1208
- }
1209
- var Ln = {};
1210
- for (xt in nt) Object.prototype.hasOwnProperty.call(nt, xt) && (Ln[xt] = nt[xt]);
1211
- var xt;
1212
- function Ct(t5, e) {
1213
- if (t5.type === "Program") return t5;
1214
- vt.yy = Ln, vt.yy.locInfo = function(n) {
1215
- return new pr(e && e.srcName, n);
1216
- };
1217
- var r = vt.parse(t5);
1218
- return r;
1219
- }
1220
- function fr(t5, e) {
1221
- var r = Ct(t5, e), n = new Cn(e);
1222
- return n.accept(r);
1223
- }
1224
- var Dn = { Aacute: "\xC1", aacute: "\xE1", Abreve: "\u0102", abreve: "\u0103", ac: "\u223E", acd: "\u223F", acE: "\u223E\u0333", Acirc: "\xC2", acirc: "\xE2", acute: "\xB4", Acy: "\u0410", acy: "\u0430", AElig: "\xC6", aelig: "\xE6", af: "\u2061", Afr: "\u{1D504}", afr: "\u{1D51E}", Agrave: "\xC0", agrave: "\xE0", alefsym: "\u2135", aleph: "\u2135", Alpha: "\u0391", alpha: "\u03B1", Amacr: "\u0100", amacr: "\u0101", amalg: "\u2A3F", amp: "&", AMP: "&", andand: "\u2A55", And: "\u2A53", and: "\u2227", andd: "\u2A5C", andslope: "\u2A58", andv: "\u2A5A", ang: "\u2220", ange: "\u29A4", angle: "\u2220", angmsdaa: "\u29A8", angmsdab: "\u29A9", angmsdac: "\u29AA", angmsdad: "\u29AB", angmsdae: "\u29AC", angmsdaf: "\u29AD", angmsdag: "\u29AE", angmsdah: "\u29AF", angmsd: "\u2221", angrt: "\u221F", angrtvb: "\u22BE", angrtvbd: "\u299D", angsph: "\u2222", angst: "\xC5", angzarr: "\u237C", Aogon: "\u0104", aogon: "\u0105", Aopf: "\u{1D538}", aopf: "\u{1D552}", apacir: "\u2A6F", ap: "\u2248", apE: "\u2A70", ape: "\u224A", apid: "\u224B", apos: "'", ApplyFunction: "\u2061", approx: "\u2248", approxeq: "\u224A", Aring: "\xC5", aring: "\xE5", Ascr: "\u{1D49C}", ascr: "\u{1D4B6}", Assign: "\u2254", ast: "*", asymp: "\u2248", asympeq: "\u224D", Atilde: "\xC3", atilde: "\xE3", Auml: "\xC4", auml: "\xE4", awconint: "\u2233", awint: "\u2A11", backcong: "\u224C", backepsilon: "\u03F6", backprime: "\u2035", backsim: "\u223D", backsimeq: "\u22CD", Backslash: "\u2216", Barv: "\u2AE7", barvee: "\u22BD", barwed: "\u2305", Barwed: "\u2306", barwedge: "\u2305", bbrk: "\u23B5", bbrktbrk: "\u23B6", bcong: "\u224C", Bcy: "\u0411", bcy: "\u0431", bdquo: "\u201E", becaus: "\u2235", because: "\u2235", Because: "\u2235", bemptyv: "\u29B0", bepsi: "\u03F6", bernou: "\u212C", Bernoullis: "\u212C", Beta: "\u0392", beta: "\u03B2", beth: "\u2136", between: "\u226C", Bfr: "\u{1D505}", bfr: "\u{1D51F}", bigcap: "\u22C2", bigcirc: "\u25EF", bigcup: "\u22C3", bigodot: "\u2A00", bigoplus: "\u2A01", bigotimes: "\u2A02", bigsqcup: "\u2A06", bigstar: "\u2605", bigtriangledown: "\u25BD", bigtriangleup: "\u25B3", biguplus: "\u2A04", bigvee: "\u22C1", bigwedge: "\u22C0", bkarow: "\u290D", blacklozenge: "\u29EB", blacksquare: "\u25AA", blacktriangle: "\u25B4", blacktriangledown: "\u25BE", blacktriangleleft: "\u25C2", blacktriangleright: "\u25B8", blank: "\u2423", blk12: "\u2592", blk14: "\u2591", blk34: "\u2593", block: "\u2588", bne: "=\u20E5", bnequiv: "\u2261\u20E5", bNot: "\u2AED", bnot: "\u2310", Bopf: "\u{1D539}", bopf: "\u{1D553}", bot: "\u22A5", bottom: "\u22A5", bowtie: "\u22C8", boxbox: "\u29C9", boxdl: "\u2510", boxdL: "\u2555", boxDl: "\u2556", boxDL: "\u2557", boxdr: "\u250C", boxdR: "\u2552", boxDr: "\u2553", boxDR: "\u2554", boxh: "\u2500", boxH: "\u2550", boxhd: "\u252C", boxHd: "\u2564", boxhD: "\u2565", boxHD: "\u2566", boxhu: "\u2534", boxHu: "\u2567", boxhU: "\u2568", boxHU: "\u2569", boxminus: "\u229F", boxplus: "\u229E", boxtimes: "\u22A0", boxul: "\u2518", boxuL: "\u255B", boxUl: "\u255C", boxUL: "\u255D", boxur: "\u2514", boxuR: "\u2558", boxUr: "\u2559", boxUR: "\u255A", boxv: "\u2502", boxV: "\u2551", boxvh: "\u253C", boxvH: "\u256A", boxVh: "\u256B", boxVH: "\u256C", boxvl: "\u2524", boxvL: "\u2561", boxVl: "\u2562", boxVL: "\u2563", boxvr: "\u251C", boxvR: "\u255E", boxVr: "\u255F", boxVR: "\u2560", bprime: "\u2035", breve: "\u02D8", Breve: "\u02D8", brvbar: "\xA6", bscr: "\u{1D4B7}", Bscr: "\u212C", bsemi: "\u204F", bsim: "\u223D", bsime: "\u22CD", bsolb: "\u29C5", bsol: "\\", bsolhsub: "\u27C8", bull: "\u2022", bullet: "\u2022", bump: "\u224E", bumpE: "\u2AAE", bumpe: "\u224F", Bumpeq: "\u224E", bumpeq: "\u224F", Cacute: "\u0106", cacute: "\u0107", capand: "\u2A44", capbrcup: "\u2A49", capcap: "\u2A4B", cap: "\u2229", Cap: "\u22D2", capcup: "\u2A47", capdot: "\u2A40", CapitalDifferentialD: "\u2145", caps: "\u2229\uFE00", caret: "\u2041", caron: "\u02C7", Cayleys: "\u212D", ccaps: "\u2A4D", Ccaron: "\u010C", ccaron: "\u010D", Ccedil: "\xC7", ccedil: "\xE7", Ccirc: "\u0108", ccirc: "\u0109", Cconint: "\u2230", ccups: "\u2A4C", ccupssm: "\u2A50", Cdot: "\u010A", cdot: "\u010B", cedil: "\xB8", Cedilla: "\xB8", cemptyv: "\u29B2", cent: "\xA2", centerdot: "\xB7", CenterDot: "\xB7", cfr: "\u{1D520}", Cfr: "\u212D", CHcy: "\u0427", chcy: "\u0447", check: "\u2713", checkmark: "\u2713", Chi: "\u03A7", chi: "\u03C7", circ: "\u02C6", circeq: "\u2257", circlearrowleft: "\u21BA", circlearrowright: "\u21BB", circledast: "\u229B", circledcirc: "\u229A", circleddash: "\u229D", CircleDot: "\u2299", circledR: "\xAE", circledS: "\u24C8", CircleMinus: "\u2296", CirclePlus: "\u2295", CircleTimes: "\u2297", cir: "\u25CB", cirE: "\u29C3", cire: "\u2257", cirfnint: "\u2A10", cirmid: "\u2AEF", cirscir: "\u29C2", ClockwiseContourIntegral: "\u2232", CloseCurlyDoubleQuote: "\u201D", CloseCurlyQuote: "\u2019", clubs: "\u2663", clubsuit: "\u2663", colon: ":", Colon: "\u2237", Colone: "\u2A74", colone: "\u2254", coloneq: "\u2254", comma: ",", commat: "@", comp: "\u2201", compfn: "\u2218", complement: "\u2201", complexes: "\u2102", cong: "\u2245", congdot: "\u2A6D", Congruent: "\u2261", conint: "\u222E", Conint: "\u222F", ContourIntegral: "\u222E", copf: "\u{1D554}", Copf: "\u2102", coprod: "\u2210", Coproduct: "\u2210", copy: "\xA9", COPY: "\xA9", copysr: "\u2117", CounterClockwiseContourIntegral: "\u2233", crarr: "\u21B5", cross: "\u2717", Cross: "\u2A2F", Cscr: "\u{1D49E}", cscr: "\u{1D4B8}", csub: "\u2ACF", csube: "\u2AD1", csup: "\u2AD0", csupe: "\u2AD2", ctdot: "\u22EF", cudarrl: "\u2938", cudarrr: "\u2935", cuepr: "\u22DE", cuesc: "\u22DF", cularr: "\u21B6", cularrp: "\u293D", cupbrcap: "\u2A48", cupcap: "\u2A46", CupCap: "\u224D", cup: "\u222A", Cup: "\u22D3", cupcup: "\u2A4A", cupdot: "\u228D", cupor: "\u2A45", cups: "\u222A\uFE00", curarr: "\u21B7", curarrm: "\u293C", curlyeqprec: "\u22DE", curlyeqsucc: "\u22DF", curlyvee: "\u22CE", curlywedge: "\u22CF", curren: "\xA4", curvearrowleft: "\u21B6", curvearrowright: "\u21B7", cuvee: "\u22CE", cuwed: "\u22CF", cwconint: "\u2232", cwint: "\u2231", cylcty: "\u232D", dagger: "\u2020", Dagger: "\u2021", daleth: "\u2138", darr: "\u2193", Darr: "\u21A1", dArr: "\u21D3", dash: "\u2010", Dashv: "\u2AE4", dashv: "\u22A3", dbkarow: "\u290F", dblac: "\u02DD", Dcaron: "\u010E", dcaron: "\u010F", Dcy: "\u0414", dcy: "\u0434", ddagger: "\u2021", ddarr: "\u21CA", DD: "\u2145", dd: "\u2146", DDotrahd: "\u2911", ddotseq: "\u2A77", deg: "\xB0", Del: "\u2207", Delta: "\u0394", delta: "\u03B4", demptyv: "\u29B1", dfisht: "\u297F", Dfr: "\u{1D507}", dfr: "\u{1D521}", dHar: "\u2965", dharl: "\u21C3", dharr: "\u21C2", DiacriticalAcute: "\xB4", DiacriticalDot: "\u02D9", DiacriticalDoubleAcute: "\u02DD", DiacriticalGrave: "`", DiacriticalTilde: "\u02DC", diam: "\u22C4", diamond: "\u22C4", Diamond: "\u22C4", diamondsuit: "\u2666", diams: "\u2666", die: "\xA8", DifferentialD: "\u2146", digamma: "\u03DD", disin: "\u22F2", div: "\xF7", divide: "\xF7", divideontimes: "\u22C7", divonx: "\u22C7", DJcy: "\u0402", djcy: "\u0452", dlcorn: "\u231E", dlcrop: "\u230D", dollar: "$", Dopf: "\u{1D53B}", dopf: "\u{1D555}", Dot: "\xA8", dot: "\u02D9", DotDot: "\u20DC", doteq: "\u2250", doteqdot: "\u2251", DotEqual: "\u2250", dotminus: "\u2238", dotplus: "\u2214", dotsquare: "\u22A1", doublebarwedge: "\u2306", DoubleContourIntegral: "\u222F", DoubleDot: "\xA8", DoubleDownArrow: "\u21D3", DoubleLeftArrow: "\u21D0", DoubleLeftRightArrow: "\u21D4", DoubleLeftTee: "\u2AE4", DoubleLongLeftArrow: "\u27F8", DoubleLongLeftRightArrow: "\u27FA", DoubleLongRightArrow: "\u27F9", DoubleRightArrow: "\u21D2", DoubleRightTee: "\u22A8", DoubleUpArrow: "\u21D1", DoubleUpDownArrow: "\u21D5", DoubleVerticalBar: "\u2225", DownArrowBar: "\u2913", downarrow: "\u2193", DownArrow: "\u2193", Downarrow: "\u21D3", DownArrowUpArrow: "\u21F5", DownBreve: "\u0311", downdownarrows: "\u21CA", downharpoonleft: "\u21C3", downharpoonright: "\u21C2", DownLeftRightVector: "\u2950", DownLeftTeeVector: "\u295E", DownLeftVectorBar: "\u2956", DownLeftVector: "\u21BD", DownRightTeeVector: "\u295F", DownRightVectorBar: "\u2957", DownRightVector: "\u21C1", DownTeeArrow: "\u21A7", DownTee: "\u22A4", drbkarow: "\u2910", drcorn: "\u231F", drcrop: "\u230C", Dscr: "\u{1D49F}", dscr: "\u{1D4B9}", DScy: "\u0405", dscy: "\u0455", dsol: "\u29F6", Dstrok: "\u0110", dstrok: "\u0111", dtdot: "\u22F1", dtri: "\u25BF", dtrif: "\u25BE", duarr: "\u21F5", duhar: "\u296F", dwangle: "\u29A6", DZcy: "\u040F", dzcy: "\u045F", dzigrarr: "\u27FF", Eacute: "\xC9", eacute: "\xE9", easter: "\u2A6E", Ecaron: "\u011A", ecaron: "\u011B", Ecirc: "\xCA", ecirc: "\xEA", ecir: "\u2256", ecolon: "\u2255", Ecy: "\u042D", ecy: "\u044D", eDDot: "\u2A77", Edot: "\u0116", edot: "\u0117", eDot: "\u2251", ee: "\u2147", efDot: "\u2252", Efr: "\u{1D508}", efr: "\u{1D522}", eg: "\u2A9A", Egrave: "\xC8", egrave: "\xE8", egs: "\u2A96", egsdot: "\u2A98", el: "\u2A99", Element: "\u2208", elinters: "\u23E7", ell: "\u2113", els: "\u2A95", elsdot: "\u2A97", Emacr: "\u0112", emacr: "\u0113", empty: "\u2205", emptyset: "\u2205", EmptySmallSquare: "\u25FB", emptyv: "\u2205", EmptyVerySmallSquare: "\u25AB", emsp13: "\u2004", emsp14: "\u2005", emsp: "\u2003", ENG: "\u014A", eng: "\u014B", ensp: "\u2002", Eogon: "\u0118", eogon: "\u0119", Eopf: "\u{1D53C}", eopf: "\u{1D556}", epar: "\u22D5", eparsl: "\u29E3", eplus: "\u2A71", epsi: "\u03B5", Epsilon: "\u0395", epsilon: "\u03B5", epsiv: "\u03F5", eqcirc: "\u2256", eqcolon: "\u2255", eqsim: "\u2242", eqslantgtr: "\u2A96", eqslantless: "\u2A95", Equal: "\u2A75", equals: "=", EqualTilde: "\u2242", equest: "\u225F", Equilibrium: "\u21CC", equiv: "\u2261", equivDD: "\u2A78", eqvparsl: "\u29E5", erarr: "\u2971", erDot: "\u2253", escr: "\u212F", Escr: "\u2130", esdot: "\u2250", Esim: "\u2A73", esim: "\u2242", Eta: "\u0397", eta: "\u03B7", ETH: "\xD0", eth: "\xF0", Euml: "\xCB", euml: "\xEB", euro: "\u20AC", excl: "!", exist: "\u2203", Exists: "\u2203", expectation: "\u2130", exponentiale: "\u2147", ExponentialE: "\u2147", fallingdotseq: "\u2252", Fcy: "\u0424", fcy: "\u0444", female: "\u2640", ffilig: "\uFB03", fflig: "\uFB00", ffllig: "\uFB04", Ffr: "\u{1D509}", ffr: "\u{1D523}", filig: "\uFB01", FilledSmallSquare: "\u25FC", FilledVerySmallSquare: "\u25AA", fjlig: "fj", flat: "\u266D", fllig: "\uFB02", fltns: "\u25B1", fnof: "\u0192", Fopf: "\u{1D53D}", fopf: "\u{1D557}", forall: "\u2200", ForAll: "\u2200", fork: "\u22D4", forkv: "\u2AD9", Fouriertrf: "\u2131", fpartint: "\u2A0D", frac12: "\xBD", frac13: "\u2153", frac14: "\xBC", frac15: "\u2155", frac16: "\u2159", frac18: "\u215B", frac23: "\u2154", frac25: "\u2156", frac34: "\xBE", frac35: "\u2157", frac38: "\u215C", frac45: "\u2158", frac56: "\u215A", frac58: "\u215D", frac78: "\u215E", frasl: "\u2044", frown: "\u2322", fscr: "\u{1D4BB}", Fscr: "\u2131", gacute: "\u01F5", Gamma: "\u0393", gamma: "\u03B3", Gammad: "\u03DC", gammad: "\u03DD", gap: "\u2A86", Gbreve: "\u011E", gbreve: "\u011F", Gcedil: "\u0122", Gcirc: "\u011C", gcirc: "\u011D", Gcy: "\u0413", gcy: "\u0433", Gdot: "\u0120", gdot: "\u0121", ge: "\u2265", gE: "\u2267", gEl: "\u2A8C", gel: "\u22DB", geq: "\u2265", geqq: "\u2267", geqslant: "\u2A7E", gescc: "\u2AA9", ges: "\u2A7E", gesdot: "\u2A80", gesdoto: "\u2A82", gesdotol: "\u2A84", gesl: "\u22DB\uFE00", gesles: "\u2A94", Gfr: "\u{1D50A}", gfr: "\u{1D524}", gg: "\u226B", Gg: "\u22D9", ggg: "\u22D9", gimel: "\u2137", GJcy: "\u0403", gjcy: "\u0453", gla: "\u2AA5", gl: "\u2277", glE: "\u2A92", glj: "\u2AA4", gnap: "\u2A8A", gnapprox: "\u2A8A", gne: "\u2A88", gnE: "\u2269", gneq: "\u2A88", gneqq: "\u2269", gnsim: "\u22E7", Gopf: "\u{1D53E}", gopf: "\u{1D558}", grave: "`", GreaterEqual: "\u2265", GreaterEqualLess: "\u22DB", GreaterFullEqual: "\u2267", GreaterGreater: "\u2AA2", GreaterLess: "\u2277", GreaterSlantEqual: "\u2A7E", GreaterTilde: "\u2273", Gscr: "\u{1D4A2}", gscr: "\u210A", gsim: "\u2273", gsime: "\u2A8E", gsiml: "\u2A90", gtcc: "\u2AA7", gtcir: "\u2A7A", gt: ">", GT: ">", Gt: "\u226B", gtdot: "\u22D7", gtlPar: "\u2995", gtquest: "\u2A7C", gtrapprox: "\u2A86", gtrarr: "\u2978", gtrdot: "\u22D7", gtreqless: "\u22DB", gtreqqless: "\u2A8C", gtrless: "\u2277", gtrsim: "\u2273", gvertneqq: "\u2269\uFE00", gvnE: "\u2269\uFE00", Hacek: "\u02C7", hairsp: "\u200A", half: "\xBD", hamilt: "\u210B", HARDcy: "\u042A", hardcy: "\u044A", harrcir: "\u2948", harr: "\u2194", hArr: "\u21D4", harrw: "\u21AD", Hat: "^", hbar: "\u210F", Hcirc: "\u0124", hcirc: "\u0125", hearts: "\u2665", heartsuit: "\u2665", hellip: "\u2026", hercon: "\u22B9", hfr: "\u{1D525}", Hfr: "\u210C", HilbertSpace: "\u210B", hksearow: "\u2925", hkswarow: "\u2926", hoarr: "\u21FF", homtht: "\u223B", hookleftarrow: "\u21A9", hookrightarrow: "\u21AA", hopf: "\u{1D559}", Hopf: "\u210D", horbar: "\u2015", HorizontalLine: "\u2500", hscr: "\u{1D4BD}", Hscr: "\u210B", hslash: "\u210F", Hstrok: "\u0126", hstrok: "\u0127", HumpDownHump: "\u224E", HumpEqual: "\u224F", hybull: "\u2043", hyphen: "\u2010", Iacute: "\xCD", iacute: "\xED", ic: "\u2063", Icirc: "\xCE", icirc: "\xEE", Icy: "\u0418", icy: "\u0438", Idot: "\u0130", IEcy: "\u0415", iecy: "\u0435", iexcl: "\xA1", iff: "\u21D4", ifr: "\u{1D526}", Ifr: "\u2111", Igrave: "\xCC", igrave: "\xEC", ii: "\u2148", iiiint: "\u2A0C", iiint: "\u222D", iinfin: "\u29DC", iiota: "\u2129", IJlig: "\u0132", ijlig: "\u0133", Imacr: "\u012A", imacr: "\u012B", image: "\u2111", ImaginaryI: "\u2148", imagline: "\u2110", imagpart: "\u2111", imath: "\u0131", Im: "\u2111", imof: "\u22B7", imped: "\u01B5", Implies: "\u21D2", incare: "\u2105", in: "\u2208", infin: "\u221E", infintie: "\u29DD", inodot: "\u0131", intcal: "\u22BA", int: "\u222B", Int: "\u222C", integers: "\u2124", Integral: "\u222B", intercal: "\u22BA", Intersection: "\u22C2", intlarhk: "\u2A17", intprod: "\u2A3C", InvisibleComma: "\u2063", InvisibleTimes: "\u2062", IOcy: "\u0401", iocy: "\u0451", Iogon: "\u012E", iogon: "\u012F", Iopf: "\u{1D540}", iopf: "\u{1D55A}", Iota: "\u0399", iota: "\u03B9", iprod: "\u2A3C", iquest: "\xBF", iscr: "\u{1D4BE}", Iscr: "\u2110", isin: "\u2208", isindot: "\u22F5", isinE: "\u22F9", isins: "\u22F4", isinsv: "\u22F3", isinv: "\u2208", it: "\u2062", Itilde: "\u0128", itilde: "\u0129", Iukcy: "\u0406", iukcy: "\u0456", Iuml: "\xCF", iuml: "\xEF", Jcirc: "\u0134", jcirc: "\u0135", Jcy: "\u0419", jcy: "\u0439", Jfr: "\u{1D50D}", jfr: "\u{1D527}", jmath: "\u0237", Jopf: "\u{1D541}", jopf: "\u{1D55B}", Jscr: "\u{1D4A5}", jscr: "\u{1D4BF}", Jsercy: "\u0408", jsercy: "\u0458", Jukcy: "\u0404", jukcy: "\u0454", Kappa: "\u039A", kappa: "\u03BA", kappav: "\u03F0", Kcedil: "\u0136", kcedil: "\u0137", Kcy: "\u041A", kcy: "\u043A", Kfr: "\u{1D50E}", kfr: "\u{1D528}", kgreen: "\u0138", KHcy: "\u0425", khcy: "\u0445", KJcy: "\u040C", kjcy: "\u045C", Kopf: "\u{1D542}", kopf: "\u{1D55C}", Kscr: "\u{1D4A6}", kscr: "\u{1D4C0}", lAarr: "\u21DA", Lacute: "\u0139", lacute: "\u013A", laemptyv: "\u29B4", lagran: "\u2112", Lambda: "\u039B", lambda: "\u03BB", lang: "\u27E8", Lang: "\u27EA", langd: "\u2991", langle: "\u27E8", lap: "\u2A85", Laplacetrf: "\u2112", laquo: "\xAB", larrb: "\u21E4", larrbfs: "\u291F", larr: "\u2190", Larr: "\u219E", lArr: "\u21D0", larrfs: "\u291D", larrhk: "\u21A9", larrlp: "\u21AB", larrpl: "\u2939", larrsim: "\u2973", larrtl: "\u21A2", latail: "\u2919", lAtail: "\u291B", lat: "\u2AAB", late: "\u2AAD", lates: "\u2AAD\uFE00", lbarr: "\u290C", lBarr: "\u290E", lbbrk: "\u2772", lbrace: "{", lbrack: "[", lbrke: "\u298B", lbrksld: "\u298F", lbrkslu: "\u298D", Lcaron: "\u013D", lcaron: "\u013E", Lcedil: "\u013B", lcedil: "\u013C", lceil: "\u2308", lcub: "{", Lcy: "\u041B", lcy: "\u043B", ldca: "\u2936", ldquo: "\u201C", ldquor: "\u201E", ldrdhar: "\u2967", ldrushar: "\u294B", ldsh: "\u21B2", le: "\u2264", lE: "\u2266", LeftAngleBracket: "\u27E8", LeftArrowBar: "\u21E4", leftarrow: "\u2190", LeftArrow: "\u2190", Leftarrow: "\u21D0", LeftArrowRightArrow: "\u21C6", leftarrowtail: "\u21A2", LeftCeiling: "\u2308", LeftDoubleBracket: "\u27E6", LeftDownTeeVector: "\u2961", LeftDownVectorBar: "\u2959", LeftDownVector: "\u21C3", LeftFloor: "\u230A", leftharpoondown: "\u21BD", leftharpoonup: "\u21BC", leftleftarrows: "\u21C7", leftrightarrow: "\u2194", LeftRightArrow: "\u2194", Leftrightarrow: "\u21D4", leftrightarrows: "\u21C6", leftrightharpoons: "\u21CB", leftrightsquigarrow: "\u21AD", LeftRightVector: "\u294E", LeftTeeArrow: "\u21A4", LeftTee: "\u22A3", LeftTeeVector: "\u295A", leftthreetimes: "\u22CB", LeftTriangleBar: "\u29CF", LeftTriangle: "\u22B2", LeftTriangleEqual: "\u22B4", LeftUpDownVector: "\u2951", LeftUpTeeVector: "\u2960", LeftUpVectorBar: "\u2958", LeftUpVector: "\u21BF", LeftVectorBar: "\u2952", LeftVector: "\u21BC", lEg: "\u2A8B", leg: "\u22DA", leq: "\u2264", leqq: "\u2266", leqslant: "\u2A7D", lescc: "\u2AA8", les: "\u2A7D", lesdot: "\u2A7F", lesdoto: "\u2A81", lesdotor: "\u2A83", lesg: "\u22DA\uFE00", lesges: "\u2A93", lessapprox: "\u2A85", lessdot: "\u22D6", lesseqgtr: "\u22DA", lesseqqgtr: "\u2A8B", LessEqualGreater: "\u22DA", LessFullEqual: "\u2266", LessGreater: "\u2276", lessgtr: "\u2276", LessLess: "\u2AA1", lesssim: "\u2272", LessSlantEqual: "\u2A7D", LessTilde: "\u2272", lfisht: "\u297C", lfloor: "\u230A", Lfr: "\u{1D50F}", lfr: "\u{1D529}", lg: "\u2276", lgE: "\u2A91", lHar: "\u2962", lhard: "\u21BD", lharu: "\u21BC", lharul: "\u296A", lhblk: "\u2584", LJcy: "\u0409", ljcy: "\u0459", llarr: "\u21C7", ll: "\u226A", Ll: "\u22D8", llcorner: "\u231E", Lleftarrow: "\u21DA", llhard: "\u296B", lltri: "\u25FA", Lmidot: "\u013F", lmidot: "\u0140", lmoustache: "\u23B0", lmoust: "\u23B0", lnap: "\u2A89", lnapprox: "\u2A89", lne: "\u2A87", lnE: "\u2268", lneq: "\u2A87", lneqq: "\u2268", lnsim: "\u22E6", loang: "\u27EC", loarr: "\u21FD", lobrk: "\u27E6", longleftarrow: "\u27F5", LongLeftArrow: "\u27F5", Longleftarrow: "\u27F8", longleftrightarrow: "\u27F7", LongLeftRightArrow: "\u27F7", Longleftrightarrow: "\u27FA", longmapsto: "\u27FC", longrightarrow: "\u27F6", LongRightArrow: "\u27F6", Longrightarrow: "\u27F9", looparrowleft: "\u21AB", looparrowright: "\u21AC", lopar: "\u2985", Lopf: "\u{1D543}", lopf: "\u{1D55D}", loplus: "\u2A2D", lotimes: "\u2A34", lowast: "\u2217", lowbar: "_", LowerLeftArrow: "\u2199", LowerRightArrow: "\u2198", loz: "\u25CA", lozenge: "\u25CA", lozf: "\u29EB", lpar: "(", lparlt: "\u2993", lrarr: "\u21C6", lrcorner: "\u231F", lrhar: "\u21CB", lrhard: "\u296D", lrm: "\u200E", lrtri: "\u22BF", lsaquo: "\u2039", lscr: "\u{1D4C1}", Lscr: "\u2112", lsh: "\u21B0", Lsh: "\u21B0", lsim: "\u2272", lsime: "\u2A8D", lsimg: "\u2A8F", lsqb: "[", lsquo: "\u2018", lsquor: "\u201A", Lstrok: "\u0141", lstrok: "\u0142", ltcc: "\u2AA6", ltcir: "\u2A79", lt: "<", LT: "<", Lt: "\u226A", ltdot: "\u22D6", lthree: "\u22CB", ltimes: "\u22C9", ltlarr: "\u2976", ltquest: "\u2A7B", ltri: "\u25C3", ltrie: "\u22B4", ltrif: "\u25C2", ltrPar: "\u2996", lurdshar: "\u294A", luruhar: "\u2966", lvertneqq: "\u2268\uFE00", lvnE: "\u2268\uFE00", macr: "\xAF", male: "\u2642", malt: "\u2720", maltese: "\u2720", Map: "\u2905", map: "\u21A6", mapsto: "\u21A6", mapstodown: "\u21A7", mapstoleft: "\u21A4", mapstoup: "\u21A5", marker: "\u25AE", mcomma: "\u2A29", Mcy: "\u041C", mcy: "\u043C", mdash: "\u2014", mDDot: "\u223A", measuredangle: "\u2221", MediumSpace: "\u205F", Mellintrf: "\u2133", Mfr: "\u{1D510}", mfr: "\u{1D52A}", mho: "\u2127", micro: "\xB5", midast: "*", midcir: "\u2AF0", mid: "\u2223", middot: "\xB7", minusb: "\u229F", minus: "\u2212", minusd: "\u2238", minusdu: "\u2A2A", MinusPlus: "\u2213", mlcp: "\u2ADB", mldr: "\u2026", mnplus: "\u2213", models: "\u22A7", Mopf: "\u{1D544}", mopf: "\u{1D55E}", mp: "\u2213", mscr: "\u{1D4C2}", Mscr: "\u2133", mstpos: "\u223E", Mu: "\u039C", mu: "\u03BC", multimap: "\u22B8", mumap: "\u22B8", nabla: "\u2207", Nacute: "\u0143", nacute: "\u0144", nang: "\u2220\u20D2", nap: "\u2249", napE: "\u2A70\u0338", napid: "\u224B\u0338", napos: "\u0149", napprox: "\u2249", natural: "\u266E", naturals: "\u2115", natur: "\u266E", nbsp: "\xA0", nbump: "\u224E\u0338", nbumpe: "\u224F\u0338", ncap: "\u2A43", Ncaron: "\u0147", ncaron: "\u0148", Ncedil: "\u0145", ncedil: "\u0146", ncong: "\u2247", ncongdot: "\u2A6D\u0338", ncup: "\u2A42", Ncy: "\u041D", ncy: "\u043D", ndash: "\u2013", nearhk: "\u2924", nearr: "\u2197", neArr: "\u21D7", nearrow: "\u2197", ne: "\u2260", nedot: "\u2250\u0338", NegativeMediumSpace: "\u200B", NegativeThickSpace: "\u200B", NegativeThinSpace: "\u200B", NegativeVeryThinSpace: "\u200B", nequiv: "\u2262", nesear: "\u2928", nesim: "\u2242\u0338", NestedGreaterGreater: "\u226B", NestedLessLess: "\u226A", NewLine: `
1225
- `, nexist: "\u2204", nexists: "\u2204", Nfr: "\u{1D511}", nfr: "\u{1D52B}", ngE: "\u2267\u0338", nge: "\u2271", ngeq: "\u2271", ngeqq: "\u2267\u0338", ngeqslant: "\u2A7E\u0338", nges: "\u2A7E\u0338", nGg: "\u22D9\u0338", ngsim: "\u2275", nGt: "\u226B\u20D2", ngt: "\u226F", ngtr: "\u226F", nGtv: "\u226B\u0338", nharr: "\u21AE", nhArr: "\u21CE", nhpar: "\u2AF2", ni: "\u220B", nis: "\u22FC", nisd: "\u22FA", niv: "\u220B", NJcy: "\u040A", njcy: "\u045A", nlarr: "\u219A", nlArr: "\u21CD", nldr: "\u2025", nlE: "\u2266\u0338", nle: "\u2270", nleftarrow: "\u219A", nLeftarrow: "\u21CD", nleftrightarrow: "\u21AE", nLeftrightarrow: "\u21CE", nleq: "\u2270", nleqq: "\u2266\u0338", nleqslant: "\u2A7D\u0338", nles: "\u2A7D\u0338", nless: "\u226E", nLl: "\u22D8\u0338", nlsim: "\u2274", nLt: "\u226A\u20D2", nlt: "\u226E", nltri: "\u22EA", nltrie: "\u22EC", nLtv: "\u226A\u0338", nmid: "\u2224", NoBreak: "\u2060", NonBreakingSpace: "\xA0", nopf: "\u{1D55F}", Nopf: "\u2115", Not: "\u2AEC", not: "\xAC", NotCongruent: "\u2262", NotCupCap: "\u226D", NotDoubleVerticalBar: "\u2226", NotElement: "\u2209", NotEqual: "\u2260", NotEqualTilde: "\u2242\u0338", NotExists: "\u2204", NotGreater: "\u226F", NotGreaterEqual: "\u2271", NotGreaterFullEqual: "\u2267\u0338", NotGreaterGreater: "\u226B\u0338", NotGreaterLess: "\u2279", NotGreaterSlantEqual: "\u2A7E\u0338", NotGreaterTilde: "\u2275", NotHumpDownHump: "\u224E\u0338", NotHumpEqual: "\u224F\u0338", notin: "\u2209", notindot: "\u22F5\u0338", notinE: "\u22F9\u0338", notinva: "\u2209", notinvb: "\u22F7", notinvc: "\u22F6", NotLeftTriangleBar: "\u29CF\u0338", NotLeftTriangle: "\u22EA", NotLeftTriangleEqual: "\u22EC", NotLess: "\u226E", NotLessEqual: "\u2270", NotLessGreater: "\u2278", NotLessLess: "\u226A\u0338", NotLessSlantEqual: "\u2A7D\u0338", NotLessTilde: "\u2274", NotNestedGreaterGreater: "\u2AA2\u0338", NotNestedLessLess: "\u2AA1\u0338", notni: "\u220C", notniva: "\u220C", notnivb: "\u22FE", notnivc: "\u22FD", NotPrecedes: "\u2280", NotPrecedesEqual: "\u2AAF\u0338", NotPrecedesSlantEqual: "\u22E0", NotReverseElement: "\u220C", NotRightTriangleBar: "\u29D0\u0338", NotRightTriangle: "\u22EB", NotRightTriangleEqual: "\u22ED", NotSquareSubset: "\u228F\u0338", NotSquareSubsetEqual: "\u22E2", NotSquareSuperset: "\u2290\u0338", NotSquareSupersetEqual: "\u22E3", NotSubset: "\u2282\u20D2", NotSubsetEqual: "\u2288", NotSucceeds: "\u2281", NotSucceedsEqual: "\u2AB0\u0338", NotSucceedsSlantEqual: "\u22E1", NotSucceedsTilde: "\u227F\u0338", NotSuperset: "\u2283\u20D2", NotSupersetEqual: "\u2289", NotTilde: "\u2241", NotTildeEqual: "\u2244", NotTildeFullEqual: "\u2247", NotTildeTilde: "\u2249", NotVerticalBar: "\u2224", nparallel: "\u2226", npar: "\u2226", nparsl: "\u2AFD\u20E5", npart: "\u2202\u0338", npolint: "\u2A14", npr: "\u2280", nprcue: "\u22E0", nprec: "\u2280", npreceq: "\u2AAF\u0338", npre: "\u2AAF\u0338", nrarrc: "\u2933\u0338", nrarr: "\u219B", nrArr: "\u21CF", nrarrw: "\u219D\u0338", nrightarrow: "\u219B", nRightarrow: "\u21CF", nrtri: "\u22EB", nrtrie: "\u22ED", nsc: "\u2281", nsccue: "\u22E1", nsce: "\u2AB0\u0338", Nscr: "\u{1D4A9}", nscr: "\u{1D4C3}", nshortmid: "\u2224", nshortparallel: "\u2226", nsim: "\u2241", nsime: "\u2244", nsimeq: "\u2244", nsmid: "\u2224", nspar: "\u2226", nsqsube: "\u22E2", nsqsupe: "\u22E3", nsub: "\u2284", nsubE: "\u2AC5\u0338", nsube: "\u2288", nsubset: "\u2282\u20D2", nsubseteq: "\u2288", nsubseteqq: "\u2AC5\u0338", nsucc: "\u2281", nsucceq: "\u2AB0\u0338", nsup: "\u2285", nsupE: "\u2AC6\u0338", nsupe: "\u2289", nsupset: "\u2283\u20D2", nsupseteq: "\u2289", nsupseteqq: "\u2AC6\u0338", ntgl: "\u2279", Ntilde: "\xD1", ntilde: "\xF1", ntlg: "\u2278", ntriangleleft: "\u22EA", ntrianglelefteq: "\u22EC", ntriangleright: "\u22EB", ntrianglerighteq: "\u22ED", Nu: "\u039D", nu: "\u03BD", num: "#", numero: "\u2116", numsp: "\u2007", nvap: "\u224D\u20D2", nvdash: "\u22AC", nvDash: "\u22AD", nVdash: "\u22AE", nVDash: "\u22AF", nvge: "\u2265\u20D2", nvgt: ">\u20D2", nvHarr: "\u2904", nvinfin: "\u29DE", nvlArr: "\u2902", nvle: "\u2264\u20D2", nvlt: "<\u20D2", nvltrie: "\u22B4\u20D2", nvrArr: "\u2903", nvrtrie: "\u22B5\u20D2", nvsim: "\u223C\u20D2", nwarhk: "\u2923", nwarr: "\u2196", nwArr: "\u21D6", nwarrow: "\u2196", nwnear: "\u2927", Oacute: "\xD3", oacute: "\xF3", oast: "\u229B", Ocirc: "\xD4", ocirc: "\xF4", ocir: "\u229A", Ocy: "\u041E", ocy: "\u043E", odash: "\u229D", Odblac: "\u0150", odblac: "\u0151", odiv: "\u2A38", odot: "\u2299", odsold: "\u29BC", OElig: "\u0152", oelig: "\u0153", ofcir: "\u29BF", Ofr: "\u{1D512}", ofr: "\u{1D52C}", ogon: "\u02DB", Ograve: "\xD2", ograve: "\xF2", ogt: "\u29C1", ohbar: "\u29B5", ohm: "\u03A9", oint: "\u222E", olarr: "\u21BA", olcir: "\u29BE", olcross: "\u29BB", oline: "\u203E", olt: "\u29C0", Omacr: "\u014C", omacr: "\u014D", Omega: "\u03A9", omega: "\u03C9", Omicron: "\u039F", omicron: "\u03BF", omid: "\u29B6", ominus: "\u2296", Oopf: "\u{1D546}", oopf: "\u{1D560}", opar: "\u29B7", OpenCurlyDoubleQuote: "\u201C", OpenCurlyQuote: "\u2018", operp: "\u29B9", oplus: "\u2295", orarr: "\u21BB", Or: "\u2A54", or: "\u2228", ord: "\u2A5D", order: "\u2134", orderof: "\u2134", ordf: "\xAA", ordm: "\xBA", origof: "\u22B6", oror: "\u2A56", orslope: "\u2A57", orv: "\u2A5B", oS: "\u24C8", Oscr: "\u{1D4AA}", oscr: "\u2134", Oslash: "\xD8", oslash: "\xF8", osol: "\u2298", Otilde: "\xD5", otilde: "\xF5", otimesas: "\u2A36", Otimes: "\u2A37", otimes: "\u2297", Ouml: "\xD6", ouml: "\xF6", ovbar: "\u233D", OverBar: "\u203E", OverBrace: "\u23DE", OverBracket: "\u23B4", OverParenthesis: "\u23DC", para: "\xB6", parallel: "\u2225", par: "\u2225", parsim: "\u2AF3", parsl: "\u2AFD", part: "\u2202", PartialD: "\u2202", Pcy: "\u041F", pcy: "\u043F", percnt: "%", period: ".", permil: "\u2030", perp: "\u22A5", pertenk: "\u2031", Pfr: "\u{1D513}", pfr: "\u{1D52D}", Phi: "\u03A6", phi: "\u03C6", phiv: "\u03D5", phmmat: "\u2133", phone: "\u260E", Pi: "\u03A0", pi: "\u03C0", pitchfork: "\u22D4", piv: "\u03D6", planck: "\u210F", planckh: "\u210E", plankv: "\u210F", plusacir: "\u2A23", plusb: "\u229E", pluscir: "\u2A22", plus: "+", plusdo: "\u2214", plusdu: "\u2A25", pluse: "\u2A72", PlusMinus: "\xB1", plusmn: "\xB1", plussim: "\u2A26", plustwo: "\u2A27", pm: "\xB1", Poincareplane: "\u210C", pointint: "\u2A15", popf: "\u{1D561}", Popf: "\u2119", pound: "\xA3", prap: "\u2AB7", Pr: "\u2ABB", pr: "\u227A", prcue: "\u227C", precapprox: "\u2AB7", prec: "\u227A", preccurlyeq: "\u227C", Precedes: "\u227A", PrecedesEqual: "\u2AAF", PrecedesSlantEqual: "\u227C", PrecedesTilde: "\u227E", preceq: "\u2AAF", precnapprox: "\u2AB9", precneqq: "\u2AB5", precnsim: "\u22E8", pre: "\u2AAF", prE: "\u2AB3", precsim: "\u227E", prime: "\u2032", Prime: "\u2033", primes: "\u2119", prnap: "\u2AB9", prnE: "\u2AB5", prnsim: "\u22E8", prod: "\u220F", Product: "\u220F", profalar: "\u232E", profline: "\u2312", profsurf: "\u2313", prop: "\u221D", Proportional: "\u221D", Proportion: "\u2237", propto: "\u221D", prsim: "\u227E", prurel: "\u22B0", Pscr: "\u{1D4AB}", pscr: "\u{1D4C5}", Psi: "\u03A8", psi: "\u03C8", puncsp: "\u2008", Qfr: "\u{1D514}", qfr: "\u{1D52E}", qint: "\u2A0C", qopf: "\u{1D562}", Qopf: "\u211A", qprime: "\u2057", Qscr: "\u{1D4AC}", qscr: "\u{1D4C6}", quaternions: "\u210D", quatint: "\u2A16", quest: "?", questeq: "\u225F", quot: '"', QUOT: '"', rAarr: "\u21DB", race: "\u223D\u0331", Racute: "\u0154", racute: "\u0155", radic: "\u221A", raemptyv: "\u29B3", rang: "\u27E9", Rang: "\u27EB", rangd: "\u2992", range: "\u29A5", rangle: "\u27E9", raquo: "\xBB", rarrap: "\u2975", rarrb: "\u21E5", rarrbfs: "\u2920", rarrc: "\u2933", rarr: "\u2192", Rarr: "\u21A0", rArr: "\u21D2", rarrfs: "\u291E", rarrhk: "\u21AA", rarrlp: "\u21AC", rarrpl: "\u2945", rarrsim: "\u2974", Rarrtl: "\u2916", rarrtl: "\u21A3", rarrw: "\u219D", ratail: "\u291A", rAtail: "\u291C", ratio: "\u2236", rationals: "\u211A", rbarr: "\u290D", rBarr: "\u290F", RBarr: "\u2910", rbbrk: "\u2773", rbrace: "}", rbrack: "]", rbrke: "\u298C", rbrksld: "\u298E", rbrkslu: "\u2990", Rcaron: "\u0158", rcaron: "\u0159", Rcedil: "\u0156", rcedil: "\u0157", rceil: "\u2309", rcub: "}", Rcy: "\u0420", rcy: "\u0440", rdca: "\u2937", rdldhar: "\u2969", rdquo: "\u201D", rdquor: "\u201D", rdsh: "\u21B3", real: "\u211C", realine: "\u211B", realpart: "\u211C", reals: "\u211D", Re: "\u211C", rect: "\u25AD", reg: "\xAE", REG: "\xAE", ReverseElement: "\u220B", ReverseEquilibrium: "\u21CB", ReverseUpEquilibrium: "\u296F", rfisht: "\u297D", rfloor: "\u230B", rfr: "\u{1D52F}", Rfr: "\u211C", rHar: "\u2964", rhard: "\u21C1", rharu: "\u21C0", rharul: "\u296C", Rho: "\u03A1", rho: "\u03C1", rhov: "\u03F1", RightAngleBracket: "\u27E9", RightArrowBar: "\u21E5", rightarrow: "\u2192", RightArrow: "\u2192", Rightarrow: "\u21D2", RightArrowLeftArrow: "\u21C4", rightarrowtail: "\u21A3", RightCeiling: "\u2309", RightDoubleBracket: "\u27E7", RightDownTeeVector: "\u295D", RightDownVectorBar: "\u2955", RightDownVector: "\u21C2", RightFloor: "\u230B", rightharpoondown: "\u21C1", rightharpoonup: "\u21C0", rightleftarrows: "\u21C4", rightleftharpoons: "\u21CC", rightrightarrows: "\u21C9", rightsquigarrow: "\u219D", RightTeeArrow: "\u21A6", RightTee: "\u22A2", RightTeeVector: "\u295B", rightthreetimes: "\u22CC", RightTriangleBar: "\u29D0", RightTriangle: "\u22B3", RightTriangleEqual: "\u22B5", RightUpDownVector: "\u294F", RightUpTeeVector: "\u295C", RightUpVectorBar: "\u2954", RightUpVector: "\u21BE", RightVectorBar: "\u2953", RightVector: "\u21C0", ring: "\u02DA", risingdotseq: "\u2253", rlarr: "\u21C4", rlhar: "\u21CC", rlm: "\u200F", rmoustache: "\u23B1", rmoust: "\u23B1", rnmid: "\u2AEE", roang: "\u27ED", roarr: "\u21FE", robrk: "\u27E7", ropar: "\u2986", ropf: "\u{1D563}", Ropf: "\u211D", roplus: "\u2A2E", rotimes: "\u2A35", RoundImplies: "\u2970", rpar: ")", rpargt: "\u2994", rppolint: "\u2A12", rrarr: "\u21C9", Rrightarrow: "\u21DB", rsaquo: "\u203A", rscr: "\u{1D4C7}", Rscr: "\u211B", rsh: "\u21B1", Rsh: "\u21B1", rsqb: "]", rsquo: "\u2019", rsquor: "\u2019", rthree: "\u22CC", rtimes: "\u22CA", rtri: "\u25B9", rtrie: "\u22B5", rtrif: "\u25B8", rtriltri: "\u29CE", RuleDelayed: "\u29F4", ruluhar: "\u2968", rx: "\u211E", Sacute: "\u015A", sacute: "\u015B", sbquo: "\u201A", scap: "\u2AB8", Scaron: "\u0160", scaron: "\u0161", Sc: "\u2ABC", sc: "\u227B", sccue: "\u227D", sce: "\u2AB0", scE: "\u2AB4", Scedil: "\u015E", scedil: "\u015F", Scirc: "\u015C", scirc: "\u015D", scnap: "\u2ABA", scnE: "\u2AB6", scnsim: "\u22E9", scpolint: "\u2A13", scsim: "\u227F", Scy: "\u0421", scy: "\u0441", sdotb: "\u22A1", sdot: "\u22C5", sdote: "\u2A66", searhk: "\u2925", searr: "\u2198", seArr: "\u21D8", searrow: "\u2198", sect: "\xA7", semi: ";", seswar: "\u2929", setminus: "\u2216", setmn: "\u2216", sext: "\u2736", Sfr: "\u{1D516}", sfr: "\u{1D530}", sfrown: "\u2322", sharp: "\u266F", SHCHcy: "\u0429", shchcy: "\u0449", SHcy: "\u0428", shcy: "\u0448", ShortDownArrow: "\u2193", ShortLeftArrow: "\u2190", shortmid: "\u2223", shortparallel: "\u2225", ShortRightArrow: "\u2192", ShortUpArrow: "\u2191", shy: "\xAD", Sigma: "\u03A3", sigma: "\u03C3", sigmaf: "\u03C2", sigmav: "\u03C2", sim: "\u223C", simdot: "\u2A6A", sime: "\u2243", simeq: "\u2243", simg: "\u2A9E", simgE: "\u2AA0", siml: "\u2A9D", simlE: "\u2A9F", simne: "\u2246", simplus: "\u2A24", simrarr: "\u2972", slarr: "\u2190", SmallCircle: "\u2218", smallsetminus: "\u2216", smashp: "\u2A33", smeparsl: "\u29E4", smid: "\u2223", smile: "\u2323", smt: "\u2AAA", smte: "\u2AAC", smtes: "\u2AAC\uFE00", SOFTcy: "\u042C", softcy: "\u044C", solbar: "\u233F", solb: "\u29C4", sol: "/", Sopf: "\u{1D54A}", sopf: "\u{1D564}", spades: "\u2660", spadesuit: "\u2660", spar: "\u2225", sqcap: "\u2293", sqcaps: "\u2293\uFE00", sqcup: "\u2294", sqcups: "\u2294\uFE00", Sqrt: "\u221A", sqsub: "\u228F", sqsube: "\u2291", sqsubset: "\u228F", sqsubseteq: "\u2291", sqsup: "\u2290", sqsupe: "\u2292", sqsupset: "\u2290", sqsupseteq: "\u2292", square: "\u25A1", Square: "\u25A1", SquareIntersection: "\u2293", SquareSubset: "\u228F", SquareSubsetEqual: "\u2291", SquareSuperset: "\u2290", SquareSupersetEqual: "\u2292", SquareUnion: "\u2294", squarf: "\u25AA", squ: "\u25A1", squf: "\u25AA", srarr: "\u2192", Sscr: "\u{1D4AE}", sscr: "\u{1D4C8}", ssetmn: "\u2216", ssmile: "\u2323", sstarf: "\u22C6", Star: "\u22C6", star: "\u2606", starf: "\u2605", straightepsilon: "\u03F5", straightphi: "\u03D5", strns: "\xAF", sub: "\u2282", Sub: "\u22D0", subdot: "\u2ABD", subE: "\u2AC5", sube: "\u2286", subedot: "\u2AC3", submult: "\u2AC1", subnE: "\u2ACB", subne: "\u228A", subplus: "\u2ABF", subrarr: "\u2979", subset: "\u2282", Subset: "\u22D0", subseteq: "\u2286", subseteqq: "\u2AC5", SubsetEqual: "\u2286", subsetneq: "\u228A", subsetneqq: "\u2ACB", subsim: "\u2AC7", subsub: "\u2AD5", subsup: "\u2AD3", succapprox: "\u2AB8", succ: "\u227B", succcurlyeq: "\u227D", Succeeds: "\u227B", SucceedsEqual: "\u2AB0", SucceedsSlantEqual: "\u227D", SucceedsTilde: "\u227F", succeq: "\u2AB0", succnapprox: "\u2ABA", succneqq: "\u2AB6", succnsim: "\u22E9", succsim: "\u227F", SuchThat: "\u220B", sum: "\u2211", Sum: "\u2211", sung: "\u266A", sup1: "\xB9", sup2: "\xB2", sup3: "\xB3", sup: "\u2283", Sup: "\u22D1", supdot: "\u2ABE", supdsub: "\u2AD8", supE: "\u2AC6", supe: "\u2287", supedot: "\u2AC4", Superset: "\u2283", SupersetEqual: "\u2287", suphsol: "\u27C9", suphsub: "\u2AD7", suplarr: "\u297B", supmult: "\u2AC2", supnE: "\u2ACC", supne: "\u228B", supplus: "\u2AC0", supset: "\u2283", Supset: "\u22D1", supseteq: "\u2287", supseteqq: "\u2AC6", supsetneq: "\u228B", supsetneqq: "\u2ACC", supsim: "\u2AC8", supsub: "\u2AD4", supsup: "\u2AD6", swarhk: "\u2926", swarr: "\u2199", swArr: "\u21D9", swarrow: "\u2199", swnwar: "\u292A", szlig: "\xDF", Tab: " ", target: "\u2316", Tau: "\u03A4", tau: "\u03C4", tbrk: "\u23B4", Tcaron: "\u0164", tcaron: "\u0165", Tcedil: "\u0162", tcedil: "\u0163", Tcy: "\u0422", tcy: "\u0442", tdot: "\u20DB", telrec: "\u2315", Tfr: "\u{1D517}", tfr: "\u{1D531}", there4: "\u2234", therefore: "\u2234", Therefore: "\u2234", Theta: "\u0398", theta: "\u03B8", thetasym: "\u03D1", thetav: "\u03D1", thickapprox: "\u2248", thicksim: "\u223C", ThickSpace: "\u205F\u200A", ThinSpace: "\u2009", thinsp: "\u2009", thkap: "\u2248", thksim: "\u223C", THORN: "\xDE", thorn: "\xFE", tilde: "\u02DC", Tilde: "\u223C", TildeEqual: "\u2243", TildeFullEqual: "\u2245", TildeTilde: "\u2248", timesbar: "\u2A31", timesb: "\u22A0", times: "\xD7", timesd: "\u2A30", tint: "\u222D", toea: "\u2928", topbot: "\u2336", topcir: "\u2AF1", top: "\u22A4", Topf: "\u{1D54B}", topf: "\u{1D565}", topfork: "\u2ADA", tosa: "\u2929", tprime: "\u2034", trade: "\u2122", TRADE: "\u2122", triangle: "\u25B5", triangledown: "\u25BF", triangleleft: "\u25C3", trianglelefteq: "\u22B4", triangleq: "\u225C", triangleright: "\u25B9", trianglerighteq: "\u22B5", tridot: "\u25EC", trie: "\u225C", triminus: "\u2A3A", TripleDot: "\u20DB", triplus: "\u2A39", trisb: "\u29CD", tritime: "\u2A3B", trpezium: "\u23E2", Tscr: "\u{1D4AF}", tscr: "\u{1D4C9}", TScy: "\u0426", tscy: "\u0446", TSHcy: "\u040B", tshcy: "\u045B", Tstrok: "\u0166", tstrok: "\u0167", twixt: "\u226C", twoheadleftarrow: "\u219E", twoheadrightarrow: "\u21A0", Uacute: "\xDA", uacute: "\xFA", uarr: "\u2191", Uarr: "\u219F", uArr: "\u21D1", Uarrocir: "\u2949", Ubrcy: "\u040E", ubrcy: "\u045E", Ubreve: "\u016C", ubreve: "\u016D", Ucirc: "\xDB", ucirc: "\xFB", Ucy: "\u0423", ucy: "\u0443", udarr: "\u21C5", Udblac: "\u0170", udblac: "\u0171", udhar: "\u296E", ufisht: "\u297E", Ufr: "\u{1D518}", ufr: "\u{1D532}", Ugrave: "\xD9", ugrave: "\xF9", uHar: "\u2963", uharl: "\u21BF", uharr: "\u21BE", uhblk: "\u2580", ulcorn: "\u231C", ulcorner: "\u231C", ulcrop: "\u230F", ultri: "\u25F8", Umacr: "\u016A", umacr: "\u016B", uml: "\xA8", UnderBar: "_", UnderBrace: "\u23DF", UnderBracket: "\u23B5", UnderParenthesis: "\u23DD", Union: "\u22C3", UnionPlus: "\u228E", Uogon: "\u0172", uogon: "\u0173", Uopf: "\u{1D54C}", uopf: "\u{1D566}", UpArrowBar: "\u2912", uparrow: "\u2191", UpArrow: "\u2191", Uparrow: "\u21D1", UpArrowDownArrow: "\u21C5", updownarrow: "\u2195", UpDownArrow: "\u2195", Updownarrow: "\u21D5", UpEquilibrium: "\u296E", upharpoonleft: "\u21BF", upharpoonright: "\u21BE", uplus: "\u228E", UpperLeftArrow: "\u2196", UpperRightArrow: "\u2197", upsi: "\u03C5", Upsi: "\u03D2", upsih: "\u03D2", Upsilon: "\u03A5", upsilon: "\u03C5", UpTeeArrow: "\u21A5", UpTee: "\u22A5", upuparrows: "\u21C8", urcorn: "\u231D", urcorner: "\u231D", urcrop: "\u230E", Uring: "\u016E", uring: "\u016F", urtri: "\u25F9", Uscr: "\u{1D4B0}", uscr: "\u{1D4CA}", utdot: "\u22F0", Utilde: "\u0168", utilde: "\u0169", utri: "\u25B5", utrif: "\u25B4", uuarr: "\u21C8", Uuml: "\xDC", uuml: "\xFC", uwangle: "\u29A7", vangrt: "\u299C", varepsilon: "\u03F5", varkappa: "\u03F0", varnothing: "\u2205", varphi: "\u03D5", varpi: "\u03D6", varpropto: "\u221D", varr: "\u2195", vArr: "\u21D5", varrho: "\u03F1", varsigma: "\u03C2", varsubsetneq: "\u228A\uFE00", varsubsetneqq: "\u2ACB\uFE00", varsupsetneq: "\u228B\uFE00", varsupsetneqq: "\u2ACC\uFE00", vartheta: "\u03D1", vartriangleleft: "\u22B2", vartriangleright: "\u22B3", vBar: "\u2AE8", Vbar: "\u2AEB", vBarv: "\u2AE9", Vcy: "\u0412", vcy: "\u0432", vdash: "\u22A2", vDash: "\u22A8", Vdash: "\u22A9", VDash: "\u22AB", Vdashl: "\u2AE6", veebar: "\u22BB", vee: "\u2228", Vee: "\u22C1", veeeq: "\u225A", vellip: "\u22EE", verbar: "|", Verbar: "\u2016", vert: "|", Vert: "\u2016", VerticalBar: "\u2223", VerticalLine: "|", VerticalSeparator: "\u2758", VerticalTilde: "\u2240", VeryThinSpace: "\u200A", Vfr: "\u{1D519}", vfr: "\u{1D533}", vltri: "\u22B2", vnsub: "\u2282\u20D2", vnsup: "\u2283\u20D2", Vopf: "\u{1D54D}", vopf: "\u{1D567}", vprop: "\u221D", vrtri: "\u22B3", Vscr: "\u{1D4B1}", vscr: "\u{1D4CB}", vsubnE: "\u2ACB\uFE00", vsubne: "\u228A\uFE00", vsupnE: "\u2ACC\uFE00", vsupne: "\u228B\uFE00", Vvdash: "\u22AA", vzigzag: "\u299A", Wcirc: "\u0174", wcirc: "\u0175", wedbar: "\u2A5F", wedge: "\u2227", Wedge: "\u22C0", wedgeq: "\u2259", weierp: "\u2118", Wfr: "\u{1D51A}", wfr: "\u{1D534}", Wopf: "\u{1D54E}", wopf: "\u{1D568}", wp: "\u2118", wr: "\u2240", wreath: "\u2240", Wscr: "\u{1D4B2}", wscr: "\u{1D4CC}", xcap: "\u22C2", xcirc: "\u25EF", xcup: "\u22C3", xdtri: "\u25BD", Xfr: "\u{1D51B}", xfr: "\u{1D535}", xharr: "\u27F7", xhArr: "\u27FA", Xi: "\u039E", xi: "\u03BE", xlarr: "\u27F5", xlArr: "\u27F8", xmap: "\u27FC", xnis: "\u22FB", xodot: "\u2A00", Xopf: "\u{1D54F}", xopf: "\u{1D569}", xoplus: "\u2A01", xotime: "\u2A02", xrarr: "\u27F6", xrArr: "\u27F9", Xscr: "\u{1D4B3}", xscr: "\u{1D4CD}", xsqcup: "\u2A06", xuplus: "\u2A04", xutri: "\u25B3", xvee: "\u22C1", xwedge: "\u22C0", Yacute: "\xDD", yacute: "\xFD", YAcy: "\u042F", yacy: "\u044F", Ycirc: "\u0176", ycirc: "\u0177", Ycy: "\u042B", ycy: "\u044B", yen: "\xA5", Yfr: "\u{1D51C}", yfr: "\u{1D536}", YIcy: "\u0407", yicy: "\u0457", Yopf: "\u{1D550}", yopf: "\u{1D56A}", Yscr: "\u{1D4B4}", yscr: "\u{1D4CE}", YUcy: "\u042E", yucy: "\u044E", yuml: "\xFF", Yuml: "\u0178", Zacute: "\u0179", zacute: "\u017A", Zcaron: "\u017D", zcaron: "\u017E", Zcy: "\u0417", zcy: "\u0437", Zdot: "\u017B", zdot: "\u017C", zeetrf: "\u2128", ZeroWidthSpace: "\u200B", Zeta: "\u0396", zeta: "\u03B6", zfr: "\u{1D537}", Zfr: "\u2128", ZHcy: "\u0416", zhcy: "\u0436", zigrarr: "\u21DD", zopf: "\u{1D56B}", Zopf: "\u2124", Zscr: "\u{1D4B5}", zscr: "\u{1D4CF}", zwj: "\u200D", zwnj: "\u200C" };
1226
- var ci = /^#[xX]([A-Fa-f0-9]+)$/;
1227
- var ui = /^#([0-9]+)$/;
1228
- var hi = /^([A-Za-z0-9]+)$/;
1229
- var dr = function() {
1230
- function t5(e) {
1231
- this.named = e;
1232
- }
1233
- return t5.prototype.parse = function(e) {
1234
- if (e) {
1235
- var r = e.match(ci);
1236
- if (r) return String.fromCharCode(parseInt(r[1], 16));
1237
- if (r = e.match(ui), r) return String.fromCharCode(parseInt(r[1], 10));
1238
- if (r = e.match(hi), r) return this.named[r[1]];
1239
- }
1240
- }, t5;
1241
- }();
1242
- var pi = /[\t\n\f ]/;
1243
- var fi = /[A-Za-z]/;
1244
- var di = /\r\n?/g;
1245
- function B(t5) {
1246
- return pi.test(t5);
1247
- }
1248
- function _n(t5) {
1249
- return fi.test(t5);
1250
- }
1251
- function mi(t5) {
1252
- return t5.replace(di, `
1253
- `);
1254
- }
1255
- var mr = function() {
1256
- function t5(e, r, n) {
1257
- n === void 0 && (n = "precompile"), this.delegate = e, this.entityParser = r, this.mode = n, this.state = "beforeData", this.line = -1, this.column = -1, this.input = "", this.index = -1, this.tagNameBuffer = "", this.states = { beforeData: function() {
1258
- var s = this.peek();
1259
- if (s === "<" && !this.isIgnoredEndTag()) this.transitionTo("tagOpen"), this.markTagStart(), this.consume();
1260
- else {
1261
- if (this.mode === "precompile" && s === `
1262
- `) {
1263
- var i = this.tagNameBuffer.toLowerCase();
1264
- (i === "pre" || i === "textarea") && this.consume();
1265
- }
1266
- this.transitionTo("data"), this.delegate.beginData();
1267
- }
1268
- }, data: function() {
1269
- var s = this.peek(), i = this.tagNameBuffer;
1270
- s === "<" && !this.isIgnoredEndTag() ? (this.delegate.finishData(), this.transitionTo("tagOpen"), this.markTagStart(), this.consume()) : s === "&" && i !== "script" && i !== "style" ? (this.consume(), this.delegate.appendToData(this.consumeCharRef() || "&")) : (this.consume(), this.delegate.appendToData(s));
1271
- }, tagOpen: function() {
1272
- var s = this.consume();
1273
- s === "!" ? this.transitionTo("markupDeclarationOpen") : s === "/" ? this.transitionTo("endTagOpen") : (s === "@" || s === ":" || _n(s)) && (this.transitionTo("tagName"), this.tagNameBuffer = "", this.delegate.beginStartTag(), this.appendToTagName(s));
1274
- }, markupDeclarationOpen: function() {
1275
- var s = this.consume();
1276
- if (s === "-" && this.peek() === "-") this.consume(), this.transitionTo("commentStart"), this.delegate.beginComment();
1277
- else {
1278
- var i = s.toUpperCase() + this.input.substring(this.index, this.index + 6).toUpperCase();
1279
- i === "DOCTYPE" && (this.consume(), this.consume(), this.consume(), this.consume(), this.consume(), this.consume(), this.transitionTo("doctype"), this.delegate.beginDoctype && this.delegate.beginDoctype());
1280
- }
1281
- }, doctype: function() {
1282
- var s = this.consume();
1283
- B(s) && this.transitionTo("beforeDoctypeName");
1284
- }, beforeDoctypeName: function() {
1285
- var s = this.consume();
1286
- B(s) || (this.transitionTo("doctypeName"), this.delegate.appendToDoctypeName && this.delegate.appendToDoctypeName(s.toLowerCase()));
1287
- }, doctypeName: function() {
1288
- var s = this.consume();
1289
- B(s) ? this.transitionTo("afterDoctypeName") : s === ">" ? (this.delegate.endDoctype && this.delegate.endDoctype(), this.transitionTo("beforeData")) : this.delegate.appendToDoctypeName && this.delegate.appendToDoctypeName(s.toLowerCase());
1290
- }, afterDoctypeName: function() {
1291
- var s = this.consume();
1292
- if (!B(s)) if (s === ">") this.delegate.endDoctype && this.delegate.endDoctype(), this.transitionTo("beforeData");
1293
- else {
1294
- var i = s.toUpperCase() + this.input.substring(this.index, this.index + 5).toUpperCase(), a = i.toUpperCase() === "PUBLIC", o = i.toUpperCase() === "SYSTEM";
1295
- (a || o) && (this.consume(), this.consume(), this.consume(), this.consume(), this.consume(), this.consume()), a ? this.transitionTo("afterDoctypePublicKeyword") : o && this.transitionTo("afterDoctypeSystemKeyword");
1296
- }
1297
- }, afterDoctypePublicKeyword: function() {
1298
- var s = this.peek();
1299
- B(s) ? (this.transitionTo("beforeDoctypePublicIdentifier"), this.consume()) : s === '"' ? (this.transitionTo("doctypePublicIdentifierDoubleQuoted"), this.consume()) : s === "'" ? (this.transitionTo("doctypePublicIdentifierSingleQuoted"), this.consume()) : s === ">" && (this.consume(), this.delegate.endDoctype && this.delegate.endDoctype(), this.transitionTo("beforeData"));
1300
- }, doctypePublicIdentifierDoubleQuoted: function() {
1301
- var s = this.consume();
1302
- s === '"' ? this.transitionTo("afterDoctypePublicIdentifier") : s === ">" ? (this.delegate.endDoctype && this.delegate.endDoctype(), this.transitionTo("beforeData")) : this.delegate.appendToDoctypePublicIdentifier && this.delegate.appendToDoctypePublicIdentifier(s);
1303
- }, doctypePublicIdentifierSingleQuoted: function() {
1304
- var s = this.consume();
1305
- s === "'" ? this.transitionTo("afterDoctypePublicIdentifier") : s === ">" ? (this.delegate.endDoctype && this.delegate.endDoctype(), this.transitionTo("beforeData")) : this.delegate.appendToDoctypePublicIdentifier && this.delegate.appendToDoctypePublicIdentifier(s);
1306
- }, afterDoctypePublicIdentifier: function() {
1307
- var s = this.consume();
1308
- B(s) ? this.transitionTo("betweenDoctypePublicAndSystemIdentifiers") : s === ">" ? (this.delegate.endDoctype && this.delegate.endDoctype(), this.transitionTo("beforeData")) : s === '"' ? this.transitionTo("doctypeSystemIdentifierDoubleQuoted") : s === "'" && this.transitionTo("doctypeSystemIdentifierSingleQuoted");
1309
- }, betweenDoctypePublicAndSystemIdentifiers: function() {
1310
- var s = this.consume();
1311
- B(s) || (s === ">" ? (this.delegate.endDoctype && this.delegate.endDoctype(), this.transitionTo("beforeData")) : s === '"' ? this.transitionTo("doctypeSystemIdentifierDoubleQuoted") : s === "'" && this.transitionTo("doctypeSystemIdentifierSingleQuoted"));
1312
- }, doctypeSystemIdentifierDoubleQuoted: function() {
1313
- var s = this.consume();
1314
- s === '"' ? this.transitionTo("afterDoctypeSystemIdentifier") : s === ">" ? (this.delegate.endDoctype && this.delegate.endDoctype(), this.transitionTo("beforeData")) : this.delegate.appendToDoctypeSystemIdentifier && this.delegate.appendToDoctypeSystemIdentifier(s);
1315
- }, doctypeSystemIdentifierSingleQuoted: function() {
1316
- var s = this.consume();
1317
- s === "'" ? this.transitionTo("afterDoctypeSystemIdentifier") : s === ">" ? (this.delegate.endDoctype && this.delegate.endDoctype(), this.transitionTo("beforeData")) : this.delegate.appendToDoctypeSystemIdentifier && this.delegate.appendToDoctypeSystemIdentifier(s);
1318
- }, afterDoctypeSystemIdentifier: function() {
1319
- var s = this.consume();
1320
- B(s) || s === ">" && (this.delegate.endDoctype && this.delegate.endDoctype(), this.transitionTo("beforeData"));
1321
- }, commentStart: function() {
1322
- var s = this.consume();
1323
- s === "-" ? this.transitionTo("commentStartDash") : s === ">" ? (this.delegate.finishComment(), this.transitionTo("beforeData")) : (this.delegate.appendToCommentData(s), this.transitionTo("comment"));
1324
- }, commentStartDash: function() {
1325
- var s = this.consume();
1326
- s === "-" ? this.transitionTo("commentEnd") : s === ">" ? (this.delegate.finishComment(), this.transitionTo("beforeData")) : (this.delegate.appendToCommentData("-"), this.transitionTo("comment"));
1327
- }, comment: function() {
1328
- var s = this.consume();
1329
- s === "-" ? this.transitionTo("commentEndDash") : this.delegate.appendToCommentData(s);
1330
- }, commentEndDash: function() {
1331
- var s = this.consume();
1332
- s === "-" ? this.transitionTo("commentEnd") : (this.delegate.appendToCommentData("-" + s), this.transitionTo("comment"));
1333
- }, commentEnd: function() {
1334
- var s = this.consume();
1335
- s === ">" ? (this.delegate.finishComment(), this.transitionTo("beforeData")) : (this.delegate.appendToCommentData("--" + s), this.transitionTo("comment"));
1336
- }, tagName: function() {
1337
- var s = this.consume();
1338
- B(s) ? this.transitionTo("beforeAttributeName") : s === "/" ? this.transitionTo("selfClosingStartTag") : s === ">" ? (this.delegate.finishTag(), this.transitionTo("beforeData")) : this.appendToTagName(s);
1339
- }, endTagName: function() {
1340
- var s = this.consume();
1341
- B(s) ? (this.transitionTo("beforeAttributeName"), this.tagNameBuffer = "") : s === "/" ? (this.transitionTo("selfClosingStartTag"), this.tagNameBuffer = "") : s === ">" ? (this.delegate.finishTag(), this.transitionTo("beforeData"), this.tagNameBuffer = "") : this.appendToTagName(s);
1342
- }, beforeAttributeName: function() {
1343
- var s = this.peek();
1344
- if (B(s)) {
1345
- this.consume();
1346
- return;
1347
- } else s === "/" ? (this.transitionTo("selfClosingStartTag"), this.consume()) : s === ">" ? (this.consume(), this.delegate.finishTag(), this.transitionTo("beforeData")) : s === "=" ? (this.delegate.reportSyntaxError("attribute name cannot start with equals sign"), this.transitionTo("attributeName"), this.delegate.beginAttribute(), this.consume(), this.delegate.appendToAttributeName(s)) : (this.transitionTo("attributeName"), this.delegate.beginAttribute());
1348
- }, attributeName: function() {
1349
- var s = this.peek();
1350
- B(s) ? (this.transitionTo("afterAttributeName"), this.consume()) : s === "/" ? (this.delegate.beginAttributeValue(false), this.delegate.finishAttributeValue(), this.consume(), this.transitionTo("selfClosingStartTag")) : s === "=" ? (this.transitionTo("beforeAttributeValue"), this.consume()) : s === ">" ? (this.delegate.beginAttributeValue(false), this.delegate.finishAttributeValue(), this.consume(), this.delegate.finishTag(), this.transitionTo("beforeData")) : s === '"' || s === "'" || s === "<" ? (this.delegate.reportSyntaxError(s + " is not a valid character within attribute names"), this.consume(), this.delegate.appendToAttributeName(s)) : (this.consume(), this.delegate.appendToAttributeName(s));
1351
- }, afterAttributeName: function() {
1352
- var s = this.peek();
1353
- if (B(s)) {
1354
- this.consume();
1355
- return;
1356
- } else s === "/" ? (this.delegate.beginAttributeValue(false), this.delegate.finishAttributeValue(), this.consume(), this.transitionTo("selfClosingStartTag")) : s === "=" ? (this.consume(), this.transitionTo("beforeAttributeValue")) : s === ">" ? (this.delegate.beginAttributeValue(false), this.delegate.finishAttributeValue(), this.consume(), this.delegate.finishTag(), this.transitionTo("beforeData")) : (this.delegate.beginAttributeValue(false), this.delegate.finishAttributeValue(), this.transitionTo("attributeName"), this.delegate.beginAttribute(), this.consume(), this.delegate.appendToAttributeName(s));
1357
- }, beforeAttributeValue: function() {
1358
- var s = this.peek();
1359
- B(s) ? this.consume() : s === '"' ? (this.transitionTo("attributeValueDoubleQuoted"), this.delegate.beginAttributeValue(true), this.consume()) : s === "'" ? (this.transitionTo("attributeValueSingleQuoted"), this.delegate.beginAttributeValue(true), this.consume()) : s === ">" ? (this.delegate.beginAttributeValue(false), this.delegate.finishAttributeValue(), this.consume(), this.delegate.finishTag(), this.transitionTo("beforeData")) : (this.transitionTo("attributeValueUnquoted"), this.delegate.beginAttributeValue(false), this.consume(), this.delegate.appendToAttributeValue(s));
1360
- }, attributeValueDoubleQuoted: function() {
1361
- var s = this.consume();
1362
- s === '"' ? (this.delegate.finishAttributeValue(), this.transitionTo("afterAttributeValueQuoted")) : s === "&" ? this.delegate.appendToAttributeValue(this.consumeCharRef() || "&") : this.delegate.appendToAttributeValue(s);
1363
- }, attributeValueSingleQuoted: function() {
1364
- var s = this.consume();
1365
- s === "'" ? (this.delegate.finishAttributeValue(), this.transitionTo("afterAttributeValueQuoted")) : s === "&" ? this.delegate.appendToAttributeValue(this.consumeCharRef() || "&") : this.delegate.appendToAttributeValue(s);
1366
- }, attributeValueUnquoted: function() {
1367
- var s = this.peek();
1368
- B(s) ? (this.delegate.finishAttributeValue(), this.consume(), this.transitionTo("beforeAttributeName")) : s === "/" ? (this.delegate.finishAttributeValue(), this.consume(), this.transitionTo("selfClosingStartTag")) : s === "&" ? (this.consume(), this.delegate.appendToAttributeValue(this.consumeCharRef() || "&")) : s === ">" ? (this.delegate.finishAttributeValue(), this.consume(), this.delegate.finishTag(), this.transitionTo("beforeData")) : (this.consume(), this.delegate.appendToAttributeValue(s));
1369
- }, afterAttributeValueQuoted: function() {
1370
- var s = this.peek();
1371
- B(s) ? (this.consume(), this.transitionTo("beforeAttributeName")) : s === "/" ? (this.consume(), this.transitionTo("selfClosingStartTag")) : s === ">" ? (this.consume(), this.delegate.finishTag(), this.transitionTo("beforeData")) : this.transitionTo("beforeAttributeName");
1372
- }, selfClosingStartTag: function() {
1373
- var s = this.peek();
1374
- s === ">" ? (this.consume(), this.delegate.markTagAsSelfClosing(), this.delegate.finishTag(), this.transitionTo("beforeData")) : this.transitionTo("beforeAttributeName");
1375
- }, endTagOpen: function() {
1376
- var s = this.consume();
1377
- (s === "@" || s === ":" || _n(s)) && (this.transitionTo("endTagName"), this.tagNameBuffer = "", this.delegate.beginEndTag(), this.appendToTagName(s));
1378
- } }, this.reset();
1379
- }
1380
- return t5.prototype.reset = function() {
1381
- this.transitionTo("beforeData"), this.input = "", this.tagNameBuffer = "", this.index = 0, this.line = 1, this.column = 0, this.delegate.reset();
1382
- }, t5.prototype.transitionTo = function(e) {
1383
- this.state = e;
1384
- }, t5.prototype.tokenize = function(e) {
1385
- this.reset(), this.tokenizePart(e), this.tokenizeEOF();
1386
- }, t5.prototype.tokenizePart = function(e) {
1387
- for (this.input += mi(e); this.index < this.input.length; ) {
1388
- var r = this.states[this.state];
1389
- if (r !== void 0) r.call(this);
1390
- else throw new Error("unhandled state " + this.state);
1391
- }
1392
- }, t5.prototype.tokenizeEOF = function() {
1393
- this.flushData();
1394
- }, t5.prototype.flushData = function() {
1395
- this.state === "data" && (this.delegate.finishData(), this.transitionTo("beforeData"));
1396
- }, t5.prototype.peek = function() {
1397
- return this.input.charAt(this.index);
1398
- }, t5.prototype.consume = function() {
1399
- var e = this.peek();
1400
- return this.index++, e === `
1401
- ` ? (this.line++, this.column = 0) : this.column++, e;
1402
- }, t5.prototype.consumeCharRef = function() {
1403
- var e = this.input.indexOf(";", this.index);
1404
- if (e !== -1) {
1405
- var r = this.input.slice(this.index, e), n = this.entityParser.parse(r);
1406
- if (n) {
1407
- for (var s = r.length; s; ) this.consume(), s--;
1408
- return this.consume(), n;
1409
- }
1410
- }
1411
- }, t5.prototype.markTagStart = function() {
1412
- this.delegate.tagOpen();
1413
- }, t5.prototype.appendToTagName = function(e) {
1414
- this.tagNameBuffer += e, this.delegate.appendToTagName(e);
1415
- }, t5.prototype.isIgnoredEndTag = function() {
1416
- var e = this.tagNameBuffer;
1417
- return e === "title" && this.input.substring(this.index, this.index + 8) !== "</title>" || e === "style" && this.input.substring(this.index, this.index + 8) !== "</style>" || e === "script" && this.input.substring(this.index, this.index + 9) !== "</script>";
1418
- }, t5;
1419
- }();
1420
- var Uo = function() {
1421
- function t5(e, r) {
1422
- r === void 0 && (r = {}), this.options = r, this.token = null, this.startLine = 1, this.startColumn = 0, this.tokens = [], this.tokenizer = new mr(this, e, r.mode), this._currentAttribute = void 0;
1423
- }
1424
- return t5.prototype.tokenize = function(e) {
1425
- return this.tokens = [], this.tokenizer.tokenize(e), this.tokens;
1426
- }, t5.prototype.tokenizePart = function(e) {
1427
- return this.tokens = [], this.tokenizer.tokenizePart(e), this.tokens;
1428
- }, t5.prototype.tokenizeEOF = function() {
1429
- return this.tokens = [], this.tokenizer.tokenizeEOF(), this.tokens[0];
1430
- }, t5.prototype.reset = function() {
1431
- this.token = null, this.startLine = 1, this.startColumn = 0;
1432
- }, t5.prototype.current = function() {
1433
- var e = this.token;
1434
- if (e === null) throw new Error("token was unexpectedly null");
1435
- if (arguments.length === 0) return e;
1436
- for (var r = 0; r < arguments.length; r++) if (e.type === arguments[r]) return e;
1437
- throw new Error("token type was unexpectedly " + e.type);
1438
- }, t5.prototype.push = function(e) {
1439
- this.token = e, this.tokens.push(e);
1440
- }, t5.prototype.currentAttribute = function() {
1441
- return this._currentAttribute;
1442
- }, t5.prototype.addLocInfo = function() {
1443
- this.options.loc && (this.current().loc = { start: { line: this.startLine, column: this.startColumn }, end: { line: this.tokenizer.line, column: this.tokenizer.column } }), this.startLine = this.tokenizer.line, this.startColumn = this.tokenizer.column;
1444
- }, t5.prototype.beginDoctype = function() {
1445
- this.push({ type: "Doctype", name: "" });
1446
- }, t5.prototype.appendToDoctypeName = function(e) {
1447
- this.current("Doctype").name += e;
1448
- }, t5.prototype.appendToDoctypePublicIdentifier = function(e) {
1449
- var r = this.current("Doctype");
1450
- r.publicIdentifier === void 0 ? r.publicIdentifier = e : r.publicIdentifier += e;
1451
- }, t5.prototype.appendToDoctypeSystemIdentifier = function(e) {
1452
- var r = this.current("Doctype");
1453
- r.systemIdentifier === void 0 ? r.systemIdentifier = e : r.systemIdentifier += e;
1454
- }, t5.prototype.endDoctype = function() {
1455
- this.addLocInfo();
1456
- }, t5.prototype.beginData = function() {
1457
- this.push({ type: "Chars", chars: "" });
1458
- }, t5.prototype.appendToData = function(e) {
1459
- this.current("Chars").chars += e;
1460
- }, t5.prototype.finishData = function() {
1461
- this.addLocInfo();
1462
- }, t5.prototype.beginComment = function() {
1463
- this.push({ type: "Comment", chars: "" });
1464
- }, t5.prototype.appendToCommentData = function(e) {
1465
- this.current("Comment").chars += e;
1466
- }, t5.prototype.finishComment = function() {
1467
- this.addLocInfo();
1468
- }, t5.prototype.tagOpen = function() {
1469
- }, t5.prototype.beginStartTag = function() {
1470
- this.push({ type: "StartTag", tagName: "", attributes: [], selfClosing: false });
1471
- }, t5.prototype.beginEndTag = function() {
1472
- this.push({ type: "EndTag", tagName: "" });
1473
- }, t5.prototype.finishTag = function() {
1474
- this.addLocInfo();
1475
- }, t5.prototype.markTagAsSelfClosing = function() {
1476
- this.current("StartTag").selfClosing = true;
1477
- }, t5.prototype.appendToTagName = function(e) {
1478
- this.current("StartTag", "EndTag").tagName += e;
1479
- }, t5.prototype.beginAttribute = function() {
1480
- this._currentAttribute = ["", "", false];
1481
- }, t5.prototype.appendToAttributeName = function(e) {
1482
- this.currentAttribute()[0] += e;
1483
- }, t5.prototype.beginAttributeValue = function(e) {
1484
- this.currentAttribute()[2] = e;
1485
- }, t5.prototype.appendToAttributeValue = function(e) {
1486
- this.currentAttribute()[1] += e;
1487
- }, t5.prototype.finishAttributeValue = function() {
1488
- this.current("StartTag").attributes.push(this._currentAttribute);
1489
- }, t5.prototype.reportSyntaxError = function(e) {
1490
- this.current().syntaxError = e;
1491
- }, t5;
1492
- }();
1493
- var gr = { Append: 1, TrustingAppend: 2, Comment: 3, Modifier: 4, StrictModifier: 5, Block: 6, StrictBlock: 7, Component: 8, OpenElement: 10, OpenElementWithSplat: 11, FlushElement: 12, CloseElement: 13, StaticAttr: 14, DynamicAttr: 15, ComponentAttr: 16, AttrSplat: 17, Yield: 18, DynamicArg: 20, StaticArg: 21, TrustingDynamicAttr: 22, TrustingComponentAttr: 23, StaticComponentAttr: 24, Debugger: 26, Undefined: 27, Call: 28, Concat: 29, GetSymbol: 30, GetLexicalSymbol: 32, GetStrictKeyword: 31, GetFreeAsComponentOrHelperHead: 35, GetFreeAsHelperHead: 37, GetFreeAsModifierHead: 38, GetFreeAsComponentHead: 39, InElement: 40, If: 41, Each: 42, Let: 44, WithDynamicVars: 45, InvokeComponent: 46, HasBlock: 48, HasBlockParams: 49, Curry: 50, Not: 51, IfInline: 52, GetDynamicVar: 53, Log: 54 };
1494
- function On(t5) {
1495
- return function(e) {
1496
- return Array.isArray(e) && e[0] === t5;
1497
- };
1498
- }
1499
- var Mo = On(gr.FlushElement);
1500
- var zo = On(gr.GetSymbol);
1501
- var gi = /["&\xA0]/u;
1502
- var Zo = new RegExp(gi.source, "gu");
1503
- var bi = /[&<>\xA0]/u;
1504
- var el = new RegExp(bi.source, "gu");
1505
- var kr = /* @__PURE__ */ new Set(["area", "base", "br", "col", "command", "embed", "hr", "img", "input", "keygen", "link", "meta", "param", "source", "track", "wbr"]);
1506
- function yi(t5) {
1507
- var e;
1508
- return kr.has(t5.toLowerCase()) && ((e = t5[0]) == null ? void 0 : e.toLowerCase()) === t5[0];
1509
- }
1510
- var pe = Object.freeze({ line: 1, column: 0 });
1511
- var Ei = Object.freeze({ source: "(synthetic)", start: pe, end: pe });
1512
- var st = Object.freeze({ source: "(nonexistent)", start: pe, end: pe });
1513
- var ue = Object.freeze({ source: "(broken)", start: pe, end: pe });
1514
- var k = function(t5) {
1515
- return t5.CharPosition = "CharPosition", t5.HbsPosition = "HbsPosition", t5.InternalsSynthetic = "InternalsSynthetic", t5.NonExistent = "NonExistent", t5.Broken = "Broken", t5;
1516
- }({});
1517
- var it = "MATCH_ANY";
1518
- var Tr = "IS_INVISIBLE";
1519
- var Nr = class {
1520
- constructor(e) {
1521
- __publicField(this, "_whens");
1522
- this._whens = e;
1523
- }
1524
- first(e) {
1525
- for (let r of this._whens) {
1526
- let n = r.match(e);
1527
- if (we(n)) return n[0];
1528
- }
1529
- return null;
1530
- }
1531
- };
1532
- var Dt = class {
1533
- constructor() {
1534
- __publicField(this, "_map", /* @__PURE__ */ new Map());
1535
- }
1536
- get(e, r) {
1537
- let n = this._map.get(e);
1538
- return n || (n = r(), this._map.set(e, n), n);
1539
- }
1540
- add(e, r) {
1541
- this._map.set(e, r);
1542
- }
1543
- match(e) {
1544
- let r = Si(e), n = [], s = this._map.get(r), i = this._map.get(it);
1545
- return s && n.push(s), i && n.push(i), n;
1546
- }
1547
- };
1548
- function Hn(t5) {
1549
- return t5(new vr()).check();
1550
- }
1551
- var vr = class {
1552
- constructor() {
1553
- __publicField(this, "_whens", new Dt());
1554
- }
1555
- check() {
1556
- return (e, r) => this.matchFor(e.kind, r.kind)(e, r);
1557
- }
1558
- matchFor(e, r) {
1559
- let n = this._whens.match(e);
1560
- w(we(n), `no match defined for (${e}, ${r}) and no AnyMatch defined either`);
1561
- let s = new Nr(n).first(r);
1562
- return w(s !== null, `no match defined for (${e}, ${r}) and no AnyMatch defined either`), s;
1563
- }
1564
- when(e, r, n) {
1565
- return this._whens.get(e, () => new Dt()).add(r, n), this;
1566
- }
1567
- };
1568
- function Si(t5) {
1569
- switch (t5) {
1570
- case k.Broken:
1571
- case k.InternalsSynthetic:
1572
- case k.NonExistent:
1573
- return Tr;
1574
- default:
1575
- return t5;
1576
- }
1577
- }
1578
- var Ar = class t {
1579
- constructor(e) {
1580
- __publicField(this, "chars");
1581
- __publicField(this, "loc");
1582
- this.loc = e.loc, this.chars = e.chars;
1583
- }
1584
- static synthetic(e) {
1585
- let r = O.synthetic(e);
1586
- return new t({ loc: r, chars: e });
1587
- }
1588
- static load(e, r) {
1589
- return new t({ loc: O.load(e, r[1]), chars: r[0] });
1590
- }
1591
- getString() {
1592
- return this.chars;
1593
- }
1594
- serialize() {
1595
- return [this.chars, this.loc.serialize()];
1596
- }
1597
- };
1598
- var O = class t2 {
1599
- constructor(e) {
1600
- __publicField(this, "isInvisible");
1601
- this.data = e, this.isInvisible = e.kind !== k.CharPosition && e.kind !== k.HbsPosition;
1602
- }
1603
- static get NON_EXISTENT() {
1604
- return new te(k.NonExistent, st).wrap();
1605
- }
1606
- static load(e, r) {
1607
- if (typeof r == "number") return t2.forCharPositions(e, r, r);
1608
- if (typeof r == "string") return t2.synthetic(r);
1609
- if (Array.isArray(r)) return t2.forCharPositions(e, r[0], r[1]);
1610
- if (r === k.NonExistent) return t2.NON_EXISTENT;
1611
- if (r === k.Broken) return t2.broken(ue);
1612
- vn(r);
1613
- }
1614
- static forHbsLoc(e, r) {
1615
- let n = new de(e, r.start), s = new de(e, r.end);
1616
- return new ot(e, { start: n, end: s }, r).wrap();
1617
- }
1618
- static forCharPositions(e, r, n) {
1619
- let s = new Ne(e, r), i = new Ne(e, n);
1620
- return new at(e, { start: s, end: i }).wrap();
1621
- }
1622
- static synthetic(e) {
1623
- return new te(k.InternalsSynthetic, st, e).wrap();
1624
- }
1625
- static broken(e = ue) {
1626
- return new te(k.Broken, e).wrap();
1627
- }
1628
- getStart() {
1629
- return this.data.getStart().wrap();
1630
- }
1631
- getEnd() {
1632
- return this.data.getEnd().wrap();
1633
- }
1634
- get loc() {
1635
- let e = this.data.toHbsSpan();
1636
- return e === null ? ue : e.toHbsLoc();
1637
- }
1638
- get module() {
1639
- return this.data.getModule();
1640
- }
1641
- get startPosition() {
1642
- return this.loc.start;
1643
- }
1644
- get endPosition() {
1645
- return this.loc.end;
1646
- }
1647
- toJSON() {
1648
- return this.loc;
1649
- }
1650
- withStart(e) {
1651
- return Q(e.data, this.data.getEnd());
1652
- }
1653
- withEnd(e) {
1654
- return Q(this.data.getStart(), e.data);
1655
- }
1656
- asString() {
1657
- return this.data.asString();
1658
- }
1659
- toSlice(e) {
1660
- let r = this.data.asString();
1661
- return false, new Ar({ loc: this, chars: e || r });
1662
- }
1663
- get start() {
1664
- return this.loc.start;
1665
- }
1666
- set start(e) {
1667
- this.data.locDidUpdate({ start: e });
1668
- }
1669
- get end() {
1670
- return this.loc.end;
1671
- }
1672
- set end(e) {
1673
- this.data.locDidUpdate({ end: e });
1674
- }
1675
- get source() {
1676
- return this.module;
1677
- }
1678
- collapse(e) {
1679
- switch (e) {
1680
- case "start":
1681
- return this.getStart().collapsed();
1682
- case "end":
1683
- return this.getEnd().collapsed();
1684
- }
1685
- }
1686
- extend(e) {
1687
- return Q(this.data.getStart(), e.data.getEnd());
1688
- }
1689
- serialize() {
1690
- return this.data.serialize();
1691
- }
1692
- slice({ skipStart: e = 0, skipEnd: r = 0 }) {
1693
- return Q(this.getStart().move(e).data, this.getEnd().move(-r).data);
1694
- }
1695
- sliceStartChars({ skipStart: e = 0, chars: r }) {
1696
- return Q(this.getStart().move(e).data, this.getStart().move(e + r).data);
1697
- }
1698
- sliceEndChars({ skipEnd: e = 0, chars: r }) {
1699
- return Q(this.getEnd().move(e - r).data, this.getStart().move(-e).data);
1700
- }
1701
- };
1702
- var at = class {
1703
- constructor(e, r) {
1704
- __publicField(this, "kind", k.CharPosition);
1705
- __publicField(this, "_locPosSpan", null);
1706
- this.source = e, this.charPositions = r;
1707
- }
1708
- wrap() {
1709
- return new O(this);
1710
- }
1711
- asString() {
1712
- return this.source.slice(this.charPositions.start.charPos, this.charPositions.end.charPos);
1713
- }
1714
- getModule() {
1715
- return this.source.module;
1716
- }
1717
- getStart() {
1718
- return this.charPositions.start;
1719
- }
1720
- getEnd() {
1721
- return this.charPositions.end;
1722
- }
1723
- locDidUpdate() {
1724
- }
1725
- toHbsSpan() {
1726
- let e = this._locPosSpan;
1727
- if (e === null) {
1728
- let r = this.charPositions.start.toHbsPos(), n = this.charPositions.end.toHbsPos();
1729
- r === null || n === null ? e = this._locPosSpan = fe : e = this._locPosSpan = new ot(this.source, { start: r, end: n });
1730
- }
1731
- return e === fe ? null : e;
1732
- }
1733
- serialize() {
1734
- let { start: { charPos: e }, end: { charPos: r } } = this.charPositions;
1735
- return e === r ? e : [e, r];
1736
- }
1737
- toCharPosSpan() {
1738
- return this;
1739
- }
1740
- };
1741
- var ot = class {
1742
- constructor(e, r, n = null) {
1743
- __publicField(this, "kind", k.HbsPosition);
1744
- __publicField(this, "_charPosSpan", null);
1745
- __publicField(this, "_providedHbsLoc");
1746
- this.source = e, this.hbsPositions = r, this._providedHbsLoc = n;
1747
- }
1748
- serialize() {
1749
- let e = this.toCharPosSpan();
1750
- return e === null ? k.Broken : e.wrap().serialize();
1751
- }
1752
- wrap() {
1753
- return new O(this);
1754
- }
1755
- updateProvided(e, r) {
1756
- this._providedHbsLoc && (this._providedHbsLoc[r] = e), this._charPosSpan = null, this._providedHbsLoc = { start: e, end: e };
1757
- }
1758
- locDidUpdate({ start: e, end: r }) {
1759
- e !== void 0 && (this.updateProvided(e, "start"), this.hbsPositions.start = new de(this.source, e, null)), r !== void 0 && (this.updateProvided(r, "end"), this.hbsPositions.end = new de(this.source, r, null));
1760
- }
1761
- asString() {
1762
- let e = this.toCharPosSpan();
1763
- return e === null ? "" : e.asString();
1764
- }
1765
- getModule() {
1766
- return this.source.module;
1767
- }
1768
- getStart() {
1769
- return this.hbsPositions.start;
1770
- }
1771
- getEnd() {
1772
- return this.hbsPositions.end;
1773
- }
1774
- toHbsLoc() {
1775
- return { start: this.hbsPositions.start.hbsPos, end: this.hbsPositions.end.hbsPos };
1776
- }
1777
- toHbsSpan() {
1778
- return this;
1779
- }
1780
- toCharPosSpan() {
1781
- let e = this._charPosSpan;
1782
- if (e === null) {
1783
- let r = this.hbsPositions.start.toCharPos(), n = this.hbsPositions.end.toCharPos();
1784
- if (r && n) e = this._charPosSpan = new at(this.source, { start: r, end: n });
1785
- else return e = this._charPosSpan = fe, null;
1786
- }
1787
- return e === fe ? null : e;
1788
- }
1789
- };
1790
- var te = class {
1791
- constructor(e, r, n = null) {
1792
- this.kind = e, this.loc = r, this.string = n;
1793
- }
1794
- serialize() {
1795
- switch (this.kind) {
1796
- case k.Broken:
1797
- case k.NonExistent:
1798
- return this.kind;
1799
- case k.InternalsSynthetic:
1800
- return this.string || "";
1801
- }
1802
- }
1803
- wrap() {
1804
- return new O(this);
1805
- }
1806
- asString() {
1807
- return this.string || "";
1808
- }
1809
- locDidUpdate({ start: e, end: r }) {
1810
- e !== void 0 && (this.loc.start = e), r !== void 0 && (this.loc.end = r);
1811
- }
1812
- getModule() {
1813
- return "an unknown module";
1814
- }
1815
- getStart() {
1816
- return new lt(this.kind, this.loc.start);
1817
- }
1818
- getEnd() {
1819
- return new lt(this.kind, this.loc.end);
1820
- }
1821
- toCharPosSpan() {
1822
- return this;
1823
- }
1824
- toHbsSpan() {
1825
- return null;
1826
- }
1827
- toHbsLoc() {
1828
- return ue;
1829
- }
1830
- };
1831
- var Q = Hn((t5) => t5.when(k.HbsPosition, k.HbsPosition, (e, r) => new ot(e.source, { start: e, end: r }).wrap()).when(k.CharPosition, k.CharPosition, (e, r) => new at(e.source, { start: e, end: r }).wrap()).when(k.CharPosition, k.HbsPosition, (e, r) => {
1832
- let n = r.toCharPos();
1833
- return n === null ? new te(k.Broken, ue).wrap() : Q(e, n);
1834
- }).when(k.HbsPosition, k.CharPosition, (e, r) => {
1835
- let n = e.toCharPos();
1836
- return n === null ? new te(k.Broken, ue).wrap() : Q(n, r);
1837
- }).when(Tr, it, (e) => new te(e.kind, ue).wrap()).when(it, Tr, (e, r) => new te(r.kind, ue).wrap()));
1838
- var fe = "BROKEN";
1839
- var Ue = class t3 {
1840
- static forHbsPos(e, r) {
1841
- return new de(e, r, null).wrap();
1842
- }
1843
- static broken(e = pe) {
1844
- return new lt(k.Broken, e).wrap();
1845
- }
1846
- constructor(e) {
1847
- this.data = e;
1848
- }
1849
- get offset() {
1850
- let e = this.data.toCharPos();
1851
- return e === null ? null : e.offset;
1852
- }
1853
- eql(e) {
1854
- return wi(this.data, e.data);
1855
- }
1856
- until(e) {
1857
- return Q(this.data, e.data);
1858
- }
1859
- move(e) {
1860
- let r = this.data.toCharPos();
1861
- if (r === null) return t3.broken();
1862
- {
1863
- let n = r.offset + e;
1864
- return r.source.check(n) ? new Ne(r.source, n).wrap() : t3.broken();
1865
- }
1866
- }
1867
- collapsed() {
1868
- return Q(this.data, this.data);
1869
- }
1870
- toJSON() {
1871
- return this.data.toJSON();
1872
- }
1873
- };
1874
- var Ne = class {
1875
- constructor(e, r) {
1876
- __publicField(this, "kind", k.CharPosition);
1877
- __publicField(this, "_locPos", null);
1878
- this.source = e, this.charPos = r;
1879
- }
1880
- toCharPos() {
1881
- return this;
1882
- }
1883
- toJSON() {
1884
- let e = this.toHbsPos();
1885
- return e === null ? pe : e.toJSON();
1886
- }
1887
- wrap() {
1888
- return new Ue(this);
1889
- }
1890
- get offset() {
1891
- return this.charPos;
1892
- }
1893
- toHbsPos() {
1894
- let e = this._locPos;
1895
- if (e === null) {
1896
- let r = this.source.hbsPosFor(this.charPos);
1897
- r === null ? this._locPos = e = fe : this._locPos = e = new de(this.source, r, this.charPos);
1898
- }
1899
- return e === fe ? null : e;
1900
- }
1901
- };
1902
- var de = class {
1903
- constructor(e, r, n = null) {
1904
- __publicField(this, "kind", k.HbsPosition);
1905
- __publicField(this, "_charPos");
1906
- this.source = e, this.hbsPos = r, this._charPos = n === null ? null : new Ne(e, n);
1907
- }
1908
- toCharPos() {
1909
- let e = this._charPos;
1910
- if (e === null) {
1911
- let r = this.source.charPosFor(this.hbsPos);
1912
- r === null ? this._charPos = e = fe : this._charPos = e = new Ne(this.source, r);
1913
- }
1914
- return e === fe ? null : e;
1915
- }
1916
- toJSON() {
1917
- return this.hbsPos;
1918
- }
1919
- wrap() {
1920
- return new Ue(this);
1921
- }
1922
- toHbsPos() {
1923
- return this;
1924
- }
1925
- };
1926
- var lt = class {
1927
- constructor(e, r) {
1928
- this.kind = e, this.pos = r;
1929
- }
1930
- toCharPos() {
1931
- return null;
1932
- }
1933
- toJSON() {
1934
- return this.pos;
1935
- }
1936
- wrap() {
1937
- return new Ue(this);
1938
- }
1939
- get offset() {
1940
- return null;
1941
- }
1942
- };
1943
- var wi = Hn((t5) => t5.when(k.HbsPosition, k.HbsPosition, ({ hbsPos: e }, { hbsPos: r }) => e.column === r.column && e.line === r.line).when(k.CharPosition, k.CharPosition, ({ charPos: e }, { charPos: r }) => e === r).when(k.CharPosition, k.HbsPosition, ({ offset: e }, r) => {
1944
- var n;
1945
- return e === ((n = r.toCharPos()) == null ? void 0 : n.offset);
1946
- }).when(k.HbsPosition, k.CharPosition, (e, { offset: r }) => {
1947
- var n;
1948
- return ((n = e.toCharPos()) == null ? void 0 : n.offset) === r;
1949
- }).when(it, it, () => false));
1950
- var Te = class t4 {
1951
- static from(e, r = {}) {
1952
- var n;
1953
- return new t4(e, (n = r.meta) == null ? void 0 : n.moduleName);
1954
- }
1955
- constructor(e, r = "an unknown module") {
1956
- this.source = e, this.module = r;
1957
- }
1958
- check(e) {
1959
- return e >= 0 && e <= this.source.length;
1960
- }
1961
- slice(e, r) {
1962
- return this.source.slice(e, r);
1963
- }
1964
- offsetFor(e, r) {
1965
- return Ue.forHbsPos(this, { line: e, column: r });
1966
- }
1967
- spanFor({ start: e, end: r }) {
1968
- return O.forHbsLoc(this, { start: { line: e.line, column: e.column }, end: { line: r.line, column: r.column } });
1969
- }
1970
- hbsPosFor(e) {
1971
- let r = 0, n = 0;
1972
- if (e > this.source.length) return null;
1973
- for (; ; ) {
1974
- let s = this.source.indexOf(`
1975
- `, n);
1976
- if (e <= s || s === -1) return { line: r + 1, column: e - n };
1977
- r += 1, n = s + 1;
1978
- }
1979
- }
1980
- charPosFor(e) {
1981
- let { line: r, column: n } = e, i = this.source.length, a = 0, o = 0;
1982
- for (; o < i; ) {
1983
- let c = this.source.indexOf(`
1984
- `, o);
1985
- if (c === -1 && (c = this.source.length), a === r - 1) {
1986
- if (o + n > c) return c;
1987
- if (false) {
1988
- let p = this.hbsPosFor(o + n);
1989
- w(p !== null, "the returned offset failed to round-trip"), w(p.line === r, "the round-tripped line didn't match the original line"), w(p.column === n, "the round-tripped column didn't match the original column");
1990
- }
1991
- return o + n;
1992
- } else {
1993
- if (c === -1) return 0;
1994
- a += 1, o = c + 1;
1995
- }
1996
- }
1997
- return i;
1998
- }
1999
- };
2000
- function S(t5, e) {
2001
- let { module: r, loc: n } = e, { line: s, column: i } = n.start, a = e.asString(), o = a ? `
2002
-
2003
- |
2004
- | ${a.split(`
2005
- `).join(`
2006
- | `)}
2007
- |
2008
-
2009
- ` : "", c = new Error(`${t5}: ${o}(error occurred in '${r}' @ line ${s} : column ${i})`);
2010
- return c.name = "SyntaxError", c.location = e, c.code = a, c;
2011
- }
2012
- var ki = { Template: ["body"], Block: ["body"], MustacheStatement: ["path", "params", "hash"], BlockStatement: ["path", "params", "hash", "program", "inverse"], ElementModifierStatement: ["path", "params", "hash"], CommentStatement: [], MustacheCommentStatement: [], ElementNode: ["attributes", "modifiers", "children", "comments"], AttrNode: ["value"], TextNode: [], ConcatStatement: ["parts"], SubExpression: ["path", "params", "hash"], PathExpression: [], StringLiteral: [], BooleanLiteral: [], NumberLiteral: [], NullLiteral: [], UndefinedLiteral: [], Hash: ["pairs"], HashPair: ["value"] };
2013
- var Or = function() {
2014
- t5.prototype = Object.create(Error.prototype), t5.prototype.constructor = t5;
2015
- function t5(e, r, n, s) {
2016
- let i = Error.call(this, e);
2017
- this.key = s, this.message = e, this.node = r, this.parent = n, i.stack && (this.stack = i.stack);
2018
- }
2019
- return t5;
2020
- }();
2021
- function Bn(t5, e, r) {
2022
- return new Or("Cannot remove a node unless it is part of an array", t5, e, r);
2023
- }
2024
- function Ti(t5, e, r) {
2025
- return new Or("Cannot replace a node with multiple nodes unless it is part of an array", t5, e, r);
2026
- }
2027
- function In(t5, e) {
2028
- return new Or("Replacing and removing in key handlers is not yet supported.", t5, null, e);
2029
- }
2030
- var Fe = class {
2031
- constructor(e, r = null, n = null) {
2032
- __publicField(this, "node");
2033
- __publicField(this, "parent");
2034
- __publicField(this, "parentKey");
2035
- this.node = e, this.parent = r, this.parentKey = n;
2036
- }
2037
- get parentNode() {
2038
- return this.parent ? this.parent.node : null;
2039
- }
2040
- parents() {
2041
- return { [Symbol.iterator]: () => new Pr(this) };
2042
- }
2043
- };
2044
- var Pr = class {
2045
- constructor(e) {
2046
- __publicField(this, "path");
2047
- this.path = e;
2048
- }
2049
- next() {
2050
- return this.path.parent ? (this.path = this.path.parent, { done: false, value: this.path }) : { done: true, value: null };
2051
- }
2052
- };
2053
- function Vn(t5) {
2054
- return typeof t5 == "function" ? t5 : t5.enter;
2055
- }
2056
- function Un(t5) {
2057
- if (typeof t5 != "function") return t5.exit;
2058
- }
2059
- function Ni(t5, e) {
2060
- let r = typeof t5 != "function" ? t5.keys : void 0;
2061
- if (r === void 0) return;
2062
- let n = r[e];
2063
- return n !== void 0 ? n : r.All;
2064
- }
2065
- function vi(t5, e) {
2066
- if (t5.Program && (e === "Template" && !t5.Template || e === "Block" && !t5.Block)) return F(`The 'Program' visitor node is deprecated. Use 'Template' or 'Block' instead (node was '${e}') `), t5.Program;
2067
- let r = t5[e];
2068
- return r !== void 0 ? r : t5.All;
2069
- }
2070
- function Ot(t5, e) {
2071
- let { node: r, parent: n, parentKey: s } = e, i = vi(t5, r.type), a, o;
2072
- i !== void 0 && (a = Vn(i), o = Un(i));
2073
- let c;
2074
- if (a !== void 0 && (c = a(r, e)), c != null) if (JSON.stringify(r) === JSON.stringify(c)) c = void 0;
2075
- else {
2076
- if (Array.isArray(c)) return Fn(t5, c, n, s), c;
2077
- {
2078
- let p = new Fe(c, n, s);
2079
- return Ot(t5, p) || c;
2080
- }
2081
- }
2082
- if (c === void 0) {
2083
- let p = ki[r.type];
2084
- for (let h = 0; h < p.length; h++) {
2085
- let d = p[h];
2086
- Pi(t5, i, e, d);
2087
- }
2088
- o !== void 0 && (c = o(r, e));
2089
- }
2090
- return c;
2091
- }
2092
- function Ai(t5, e) {
2093
- return t5[e];
2094
- }
2095
- function Rn(t5, e, r) {
2096
- t5[e] = r;
2097
- }
2098
- function Pi(t5, e, r, n) {
2099
- let { node: s } = r, i = Ai(s, n);
2100
- if (!i) return;
2101
- let a, o;
2102
- if (e !== void 0) {
2103
- let c = Ni(e, n);
2104
- c !== void 0 && (a = Vn(c), o = Un(c));
2105
- }
2106
- if (a !== void 0 && a(s, n) !== void 0) throw In(s, n);
2107
- if (Array.isArray(i)) Fn(t5, i, r, n);
2108
- else {
2109
- let c = new Fe(i, r, n), p = Ot(t5, c);
2110
- p !== void 0 && xi(s, n, i, p);
2111
- }
2112
- if (o !== void 0 && o(s, n) !== void 0) throw In(s, n);
2113
- }
2114
- function Fn(t5, e, r, n) {
2115
- for (let s = 0; s < e.length; s++) {
2116
- let i = kt(e[s]), a = new Fe(i, r, n), o = Ot(t5, a);
2117
- o !== void 0 && (s += Ci(e, s, o) - 1);
2118
- }
2119
- }
2120
- function xi(t5, e, r, n) {
2121
- if (n === null) throw Bn(r, t5, e);
2122
- if (Array.isArray(n)) if (n.length === 1) Rn(t5, e, n[0]);
2123
- else throw n.length === 0 ? Bn(r, t5, e) : Ti(r, t5, e);
2124
- else Rn(t5, e, n);
2125
- }
2126
- function Ci(t5, e, r) {
2127
- return r === null ? (t5.splice(e, 1), 0) : Array.isArray(r) ? (t5.splice(e, 1, ...r), r.length) : (t5.splice(e, 1, r), 1);
2128
- }
2129
- function Li(t5, e) {
2130
- let r = new Fe(t5);
2131
- Ot(e, r);
2132
- }
2133
- function _i(t5) {
2134
- switch (t5.type) {
2135
- case "Block":
2136
- case "Template":
2137
- return t5.body;
2138
- case "ElementNode":
2139
- return t5.children;
2140
- }
2141
- }
2142
- function Ve(t5, e) {
2143
- _i(t5).push(e);
2144
- }
2145
- function Mn(t5) {
2146
- return t5.type === "StringLiteral" || t5.type === "BooleanLiteral" || t5.type === "NumberLiteral" || t5.type === "NullLiteral" || t5.type === "UndefinedLiteral";
2147
- }
2148
- function Di(t5) {
2149
- return t5.type === "UndefinedLiteral" ? "undefined" : JSON.stringify(t5.value);
2150
- }
2151
- var br;
2152
- function yr() {
2153
- return br || (br = new Te("", "(synthetic)")), br;
2154
- }
2155
- function Oi(t5, e = [], r = ct([]), n = false, s, i) {
2156
- return f.mustache({ path: he(t5), params: e, hash: r, trusting: n, strip: i, loc: A(s || null) });
2157
- }
2158
- function Bi(t5, e, r, n, s = null, i, a, o, c) {
2159
- let p, h = null;
2160
- return n.type === "Template" ? (F("b.program is deprecated. Use b.blockItself instead."), p = f.blockItself({ params: Gn(n.blockParams), body: n.body, loc: n.loc })) : p = n, (s == null ? void 0 : s.type) === "Template" ? (F("b.program is deprecated. Use b.blockItself instead."), w(s.blockParams.length === 0, "{{else}} block cannot have block params"), h = f.blockItself({ params: [], body: s.body, loc: s.loc })) : h = s, f.block({ path: he(t5), params: e || [], hash: r || ct([]), defaultBlock: p, elseBlock: h, loc: A(i || null), openStrip: a, inverseStrip: o, closeStrip: c });
2161
- }
2162
- function Ii(t5, e, r, n) {
2163
- return f.elementModifier({ path: he(t5), params: e || [], hash: r || ct([]), loc: A(n || null) });
2164
- }
2165
- function Ri(t5, e) {
2166
- return f.comment({ value: t5, loc: A(e || null) });
2167
- }
2168
- function qi(t5, e) {
2169
- return f.mustacheComment({ value: t5, loc: A(e || null) });
2170
- }
2171
- function Hi(t5, e) {
2172
- if (!we(t5)) throw new Error("b.concat requires at least one part");
2173
- return f.concat({ parts: t5, loc: A(e || null) });
2174
- }
2175
- function Vi(t5, e = {}) {
2176
- let { attrs: r, blockParams: n, modifiers: s, comments: i, children: a, openTag: o, closeTag: c, loc: p } = e, h, d;
2177
- typeof t5 == "string" ? t5.endsWith("/") ? (h = he(t5.slice(0, -1)), d = true) : h = he(t5) : "type" in t5 ? (w(t5.type === "PathExpression", `Invalid tag type ${t5.type}`), h = t5) : "path" in t5 ? (w(t5.path.type === "PathExpression", `Invalid tag type ${t5.path.type}`), h = t5.path, d = t5.selfClosing) : (h = he(t5.name), d = t5.selfClosing), d && w(c == null, "Cannot build a self-closing tag with a closeTag source location");
2178
- let N = n == null ? void 0 : n.map((T) => typeof T == "string" ? zn(T) : T), g = null;
2179
- return c ? g = A(c || null) : c === void 0 && (g = d || yi(h.original) ? null : A(null)), f.element({ path: h, selfClosing: d || false, attributes: r || [], params: N || [], modifiers: s || [], comments: i || [], children: a || [], openTag: A(o || null), closeTag: g, loc: A(p || null) });
2180
- }
2181
- function Ui(t5, e, r) {
2182
- return f.attr({ name: t5, value: e, loc: A(r || null) });
2183
- }
2184
- function Fi(t5 = "", e) {
2185
- return f.text({ chars: t5, loc: A(e || null) });
2186
- }
2187
- function Mi(t5, e = [], r = ct([]), n) {
2188
- return f.sexpr({ path: he(t5), params: e, hash: r, loc: A(n || null) });
2189
- }
2190
- function zi(t5, e) {
2191
- let [r, ...n] = qe(t5.split(".")), s = f.head({ original: r, loc: A(e || null) });
2192
- return f.path({ head: s, tail: n, loc: A(e || null) });
2193
- }
2194
- function Gi(t5) {
2195
- return f.this({ loc: A(t5 || null) });
2196
- }
2197
- function Yi(t5, e) {
2198
- return f.atName({ name: t5, loc: A(e || null) });
2199
- }
2200
- function zn(t5, e) {
2201
- return f.var({ name: t5, loc: A(e || null) });
2202
- }
2203
- function Ki(t5, e) {
2204
- return f.head({ original: t5, loc: A(e || null) });
2205
- }
2206
- function Wi(t5, e = [], r) {
2207
- return f.path({ head: t5, tail: e, loc: A(r || null) });
2208
- }
2209
- function he(t5, e) {
2210
- let r = A(e || null);
2211
- if (typeof t5 != "string") {
2212
- if ("type" in t5) return t5;
2213
- {
2214
- w(t5.head.indexOf(".") === -1, "builder.path({ head, tail }) should not be called with a head with dots in it");
2215
- let { head: i, tail: a } = t5;
2216
- return f.path({ head: f.head({ original: i, loc: r.sliceStartChars({ chars: i.length }) }), tail: a, loc: A(e || null) });
2217
- }
2218
- }
2219
- let { head: n, tail: s } = zi(t5, r);
2220
- return f.path({ head: n, tail: s, loc: r });
2221
- }
2222
- function _t(t5, e, r) {
2223
- return f.literal({ type: t5, value: e, loc: A(r || null) });
2224
- }
2225
- function ct(t5 = [], e) {
2226
- return f.hash({ pairs: t5, loc: A(e || null) });
2227
- }
2228
- function $i(t5, e, r) {
2229
- return f.pair({ key: t5, value: e, loc: A(r || null) });
2230
- }
2231
- function ji(t5, e, r) {
2232
- return F("b.program is deprecated. Use b.template or b.blockItself instead."), e && e.length ? Yn(t5, e, false, r) : Kn(t5, [], r);
2233
- }
2234
- function Gn(t5) {
2235
- return t5.map((e) => typeof e == "string" ? f.var({ name: e, loc: O.synthetic(e) }) : e);
2236
- }
2237
- function Yn(t5 = [], e = [], r = false, n) {
2238
- return f.blockItself({ body: t5, params: Gn(e), chained: r, loc: A(n || null) });
2239
- }
2240
- function Kn(t5 = [], e = [], r) {
2241
- return f.template({ body: t5, blockParams: e, loc: A(r || null) });
2242
- }
2243
- function Qi(t5, e) {
2244
- return f.pos({ line: t5, column: e });
2245
- }
2246
- function A(...t5) {
2247
- if (t5.length === 1) {
2248
- let e = t5[0];
2249
- return e && typeof e == "object" ? O.forHbsLoc(yr(), e) : O.forHbsLoc(yr(), Ei);
2250
- } else {
2251
- let [e, r, n, s, i] = t5, a = i ? new Te("", i) : yr();
2252
- return O.forHbsLoc(a, { start: { line: e, column: r }, end: { line: n || e, column: s || r } });
2253
- }
2254
- }
2255
- var Xi = { mustache: Oi, block: Bi, comment: Ri, mustacheComment: qi, element: Vi, elementModifier: Ii, attr: Ui, text: Fi, sexpr: Mi, concat: Hi, hash: ct, pair: $i, literal: _t, program: ji, blockItself: Yn, template: Kn, loc: A, pos: Qi, path: he, fullPath: Wi, head: Ki, at: Yi, var: zn, this: Gi, string: Er("StringLiteral"), boolean: Er("BooleanLiteral"), number: Er("NumberLiteral"), undefined() {
2256
- return _t("UndefinedLiteral", void 0);
2257
- }, null() {
2258
- return _t("NullLiteral", null);
2259
- } };
2260
- function Er(t5) {
2261
- return function(e, r) {
2262
- return _t(t5, e, r);
2263
- };
2264
- }
2265
- function Ji({ path: t5, params: e, hash: r, trusting: n, strip: s, loc: i }) {
2266
- let a = { type: "MustacheStatement", path: t5, params: e, hash: r, trusting: n, strip: s, loc: i };
2267
- return Object.defineProperty(a, "escaped", { enumerable: false, get() {
2268
- return F("The escaped property on mustache nodes is deprecated, use trusting instead"), !this.trusting;
2269
- }, set(o) {
2270
- F("The escaped property on mustache nodes is deprecated, use trusting instead"), this.trusting = !o;
2271
- } }), a;
2272
- }
2273
- function Zi({ head: t5, tail: e, loc: r }) {
2274
- let n = { type: "PathExpression", head: t5, tail: e, get original() {
2275
- return [this.head.original, ...this.tail].join(".");
2276
- }, set original(s) {
2277
- let [i, ...a] = qe(s.split("."));
2278
- this.head = Xi.head(i, this.head.loc), this.tail = a;
2279
- }, loc: r };
2280
- return Object.defineProperty(n, "parts", { enumerable: false, get() {
2281
- F("The parts property on path nodes is deprecated, use head and tail instead");
2282
- let s = qe(this.original.split("."));
2283
- return s[0] === "this" ? s.shift() : s[0].startsWith("@") && (s[0] = s[0].slice(1)), Object.freeze(s);
2284
- }, set(s) {
2285
- var a;
2286
- F("The parts property on mustache nodes is deprecated, use head and tail instead");
2287
- let i = [...s];
2288
- i[0] !== "this" && !((a = i[0]) != null && a.startsWith("@")) && (this.head.type === "ThisHead" ? i.unshift("this") : this.head.type === "AtHead" && (i[0] = `@${i[0]}`)), this.original = i.join(".");
2289
- } }), Object.defineProperty(n, "this", { enumerable: false, get() {
2290
- return F("The this property on path nodes is deprecated, use head.type instead"), this.head.type === "ThisHead";
2291
- } }), Object.defineProperty(n, "data", { enumerable: false, get() {
2292
- return F("The data property on path nodes is deprecated, use head.type instead"), this.head.type === "AtHead";
2293
- } }), n;
2294
- }
2295
- function ea({ type: t5, value: e, loc: r }) {
2296
- let n = { type: t5, value: e, loc: r };
2297
- return Object.defineProperty(n, "original", { enumerable: false, get() {
2298
- return F("The original property on literal nodes is deprecated, use value instead"), this.value;
2299
- }, set(s) {
2300
- F("The original property on literal nodes is deprecated, use value instead"), this.value = s;
2301
- } }), n;
2302
- }
2303
- var Lt = { close: false, open: false };
2304
- var xr = class {
2305
- pos({ line: e, column: r }) {
2306
- return { line: e, column: r };
2307
- }
2308
- blockItself({ body: e, params: r, chained: n = false, loc: s }) {
2309
- return { type: "Block", body: e, params: r, get blockParams() {
2310
- return this.params.map((i) => i.name);
2311
- }, set blockParams(i) {
2312
- this.params = i.map((a) => f.var({ name: a, loc: O.synthetic(a) }));
2313
- }, chained: n, loc: s };
2314
- }
2315
- template({ body: e, blockParams: r, loc: n }) {
2316
- return { type: "Template", body: e, blockParams: r, loc: n };
2317
- }
2318
- mustache({ path: e, params: r, hash: n, trusting: s, loc: i, strip: a = Lt }) {
2319
- return Ji({ path: e, params: r, hash: n, trusting: s, strip: a, loc: i });
2320
- }
2321
- block({ path: e, params: r, hash: n, defaultBlock: s, elseBlock: i = null, loc: a, openStrip: o = Lt, inverseStrip: c = Lt, closeStrip: p = Lt }) {
2322
- return { type: "BlockStatement", path: e, params: r, hash: n, program: s, inverse: i, loc: a, openStrip: o, inverseStrip: c, closeStrip: p };
2323
- }
2324
- comment({ value: e, loc: r }) {
2325
- return { type: "CommentStatement", value: e, loc: r };
2326
- }
2327
- mustacheComment({ value: e, loc: r }) {
2328
- return { type: "MustacheCommentStatement", value: e, loc: r };
2329
- }
2330
- concat({ parts: e, loc: r }) {
2331
- return { type: "ConcatStatement", parts: e, loc: r };
2332
- }
2333
- element({ path: e, selfClosing: r, attributes: n, modifiers: s, params: i, comments: a, children: o, openTag: c, closeTag: p, loc: h }) {
2334
- let d = r;
2335
- return { type: "ElementNode", path: e, attributes: n, modifiers: s, params: i, comments: a, children: o, openTag: c, closeTag: p, loc: h, get tag() {
2336
- return this.path.original;
2337
- }, set tag(N) {
2338
- this.path.original = N;
2339
- }, get blockParams() {
2340
- return this.params.map((N) => N.name);
2341
- }, set blockParams(N) {
2342
- this.params = N.map((g) => f.var({ name: g, loc: O.synthetic(g) }));
2343
- }, get selfClosing() {
2344
- return d;
2345
- }, set selfClosing(N) {
2346
- d = N, N ? this.closeTag = null : this.closeTag = O.synthetic(`</${this.tag}>`);
2347
- } };
2348
- }
2349
- elementModifier({ path: e, params: r, hash: n, loc: s }) {
2350
- return { type: "ElementModifierStatement", path: e, params: r, hash: n, loc: s };
2351
- }
2352
- attr({ name: e, value: r, loc: n }) {
2353
- return { type: "AttrNode", name: e, value: r, loc: n };
2354
- }
2355
- text({ chars: e, loc: r }) {
2356
- return { type: "TextNode", chars: e, loc: r };
2357
- }
2358
- sexpr({ path: e, params: r, hash: n, loc: s }) {
2359
- return { type: "SubExpression", path: e, params: r, hash: n, loc: s };
2360
- }
2361
- path({ head: e, tail: r, loc: n }) {
2362
- return Zi({ head: e, tail: r, loc: n });
2363
- }
2364
- head({ original: e, loc: r }) {
2365
- return e === "this" ? this.this({ loc: r }) : e[0] === "@" ? this.atName({ name: e, loc: r }) : this.var({ name: e, loc: r });
2366
- }
2367
- this({ loc: e }) {
2368
- return { type: "ThisHead", get original() {
2369
- return "this";
2370
- }, loc: e };
2371
- }
2372
- atName({ name: e, loc: r }) {
2373
- let n = "", s = { type: "AtHead", get name() {
2374
- return n;
2375
- }, set name(i) {
2376
- w(i[0] === "@", "call builders.at() with a string that starts with '@'"), w(i.indexOf(".") === -1, "builder.at() should not be called with a name with dots in it"), n = i;
2377
- }, get original() {
2378
- return this.name;
2379
- }, set original(i) {
2380
- this.name = i;
2381
- }, loc: r };
2382
- return s.name = e, s;
2383
- }
2384
- var({ name: e, loc: r }) {
2385
- let n = "", s = { type: "VarHead", get name() {
2386
- return n;
2387
- }, set name(i) {
2388
- w(i !== "this", "You called builders.var() with 'this'. Call builders.this instead"), w(i[0] !== "@", `You called builders.var() with '${e}'. Call builders.at('${e}') instead`), w(i.indexOf(".") === -1, "builder.var() should not be called with a name with dots in it"), n = i;
2389
- }, get original() {
2390
- return this.name;
2391
- }, set original(i) {
2392
- this.name = i;
2393
- }, loc: r };
2394
- return s.name = e, s;
2395
- }
2396
- hash({ pairs: e, loc: r }) {
2397
- return { type: "Hash", pairs: e, loc: r };
2398
- }
2399
- pair({ key: e, value: r, loc: n }) {
2400
- return { type: "HashPair", key: e, value: r, loc: n };
2401
- }
2402
- literal({ type: e, value: r, loc: n }) {
2403
- return ea({ type: e, value: r, loc: n });
2404
- }
2405
- };
2406
- var f = new xr();
2407
- var Cr = class {
2408
- constructor(e, r = new dr(Dn), n = "precompile") {
2409
- __publicField(this, "elementStack", []);
2410
- __publicField(this, "lines");
2411
- __publicField(this, "source");
2412
- __publicField(this, "currentAttribute", null);
2413
- __publicField(this, "currentNode", null);
2414
- __publicField(this, "tokenizer");
2415
- this.source = e, this.lines = e.source.split(/\r\n?|\n/u), this.tokenizer = new mr(this, r, n);
2416
- }
2417
- offset() {
2418
- let { line: e, column: r } = this.tokenizer;
2419
- return this.source.offsetFor(e, r);
2420
- }
2421
- pos({ line: e, column: r }) {
2422
- return this.source.offsetFor(e, r);
2423
- }
2424
- finish(e) {
2425
- return ar({}, e, { loc: e.start.until(this.offset()) });
2426
- }
2427
- get currentAttr() {
2428
- return Tn(this.currentAttribute, "expected attribute");
2429
- }
2430
- get currentTag() {
2431
- let e = this.currentNode;
2432
- return w(e && (e.type === "StartTag" || e.type === "EndTag"), "expected tag"), e;
2433
- }
2434
- get currentStartTag() {
2435
- let e = this.currentNode;
2436
- return w(e && e.type === "StartTag", "expected start tag"), e;
2437
- }
2438
- get currentEndTag() {
2439
- let e = this.currentNode;
2440
- return w(e && e.type === "EndTag", "expected end tag"), e;
2441
- }
2442
- get currentComment() {
2443
- let e = this.currentNode;
2444
- return w(e && e.type === "CommentStatement", "expected a comment"), e;
2445
- }
2446
- get currentData() {
2447
- let e = this.currentNode;
2448
- return w(e && e.type === "TextNode", "expected a text node"), e;
2449
- }
2450
- acceptNode(e) {
2451
- return this[e.type](e);
2452
- }
2453
- currentElement() {
2454
- return Nt(qe(this.elementStack));
2455
- }
2456
- sourceForNode(e, r) {
2457
- let n = e.loc.start.line - 1, s = n - 1, i = e.loc.start.column, a = [], o, c, p;
2458
- for (r ? (c = r.loc.end.line - 1, p = r.loc.end.column) : (c = e.loc.end.line - 1, p = e.loc.end.column); s < c; ) s++, o = kt(this.lines[s]), s === n ? n === c ? a.push(o.slice(i, p)) : a.push(o.slice(i)) : s === c ? a.push(o.slice(0, p)) : a.push(o);
2459
- return a.join(`
2460
- `);
2461
- }
2462
- };
2463
- var qn = "beforeAttributeName";
2464
- var ta = "attributeValueUnquoted";
2465
- var Lr = class extends Cr {
2466
- constructor() {
2467
- super(...arguments);
2468
- __publicField(this, "pendingError", null);
2469
- }
2470
- parse(e, r) {
2471
- var i;
2472
- let n = f.template({ body: [], blockParams: r, loc: this.source.spanFor(e.loc) }), s = this.parseProgram(n, e);
2473
- return (i = this.pendingError) == null || i.eof(s.loc.getEnd()), s;
2474
- }
2475
- Program(e, r) {
2476
- w(Array.isArray(r), "[BUG] Program in parser unexpectedly called without block params");
2477
- let n = f.blockItself({ body: [], params: r, chained: e.chained, loc: this.source.spanFor(e.loc) });
2478
- return this.parseProgram(n, e);
2479
- }
2480
- parseProgram(e, r) {
2481
- if (r.body.length === 0) return e;
2482
- let n;
2483
- try {
2484
- this.elementStack.push(e);
2485
- for (let s of r.body) this.acceptNode(s);
2486
- } finally {
2487
- n = this.elementStack.pop();
2488
- }
2489
- if (e !== n) {
2490
- if ((n == null ? void 0 : n.type) === "ElementNode") throw S(`Unclosed element \`${n.tag}\``, n.loc);
2491
- w(n !== void 0, "[BUG] empty parser elementStack"), w(false, `[BUG] mismatched parser elementStack node: ${e.type}`);
2492
- }
2493
- return e;
2494
- }
2495
- BlockStatement(e) {
2496
- var d;
2497
- if (this.tokenizer.state === "comment") {
2498
- this.appendToCommentData(this.sourceForNode(e));
2499
- return;
2500
- }
2501
- if (this.tokenizer.state !== "data" && this.tokenizer.state !== "beforeData") throw S("A block may only be used inside an HTML element or another block.", this.source.spanFor(e.loc));
2502
- let { path: r, params: n, hash: s } = Sr(this, e), i = this.source.spanFor(e.loc), a = [];
2503
- if ((d = e.program.blockParams) != null && d.length) {
2504
- let N = s.loc.collapse("end");
2505
- e.program.loc ? N = N.withEnd(this.source.spanFor(e.program.loc).getStart()) : e.program.body[0] ? N = N.withEnd(this.source.spanFor(e.program.body[0].loc).getStart()) : N = N.withEnd(i.getEnd());
2506
- let g = N.asString(), T = g.indexOf("|") + 1, x = g.indexOf("|", T);
2507
- for (let C of e.program.blockParams) {
2508
- let v, M;
2509
- T >= x ? v = -1 : v = g.indexOf(C, T), v === -1 || v + C.length > x ? (T = x, M = this.source.spanFor(st)) : (T = v, M = N.sliceStartChars({ skipStart: T, chars: C.length }), T += C.length), a.push(f.var({ name: C, loc: M }));
2510
- }
2511
- }
2512
- e.program.loc || (e.program.loc = st), e.inverse && !e.inverse.loc && (e.inverse.loc = st);
2513
- let o = this.Program(e.program, a), c = e.inverse ? this.Program(e.inverse, []) : null, p = f.block({ path: r, params: n, hash: s, defaultBlock: o, elseBlock: c, loc: this.source.spanFor(e.loc), openStrip: e.openStrip, inverseStrip: e.inverseStrip, closeStrip: e.closeStrip }), h = this.currentElement();
2514
- Ve(h, p);
2515
- }
2516
- MustacheStatement(e) {
2517
- var o;
2518
- (o = this.pendingError) == null || o.mustache(this.source.spanFor(e.loc));
2519
- let { tokenizer: r } = this;
2520
- if (r.state === "comment") {
2521
- this.appendToCommentData(this.sourceForNode(e));
2522
- return;
2523
- }
2524
- let n, { escaped: s, loc: i, strip: a } = e;
2525
- if ("original" in e.path && e.path.original === "...attributes") throw S("Illegal use of ...attributes", this.source.spanFor(e.loc));
2526
- if (Mn(e.path)) n = f.mustache({ path: this.acceptNode(e.path), params: [], hash: f.hash({ pairs: [], loc: this.source.spanFor(e.path.loc).collapse("end") }), trusting: !s, loc: this.source.spanFor(i), strip: a });
2527
- else {
2528
- let { path: c, params: p, hash: h } = Sr(this, e);
2529
- n = f.mustache({ path: c, params: p, hash: h, trusting: !s, loc: this.source.spanFor(i), strip: a });
2530
- }
2531
- switch (r.state) {
2532
- case "tagOpen":
2533
- case "tagName":
2534
- throw S("Cannot use mustaches in an elements tagname", n.loc);
2535
- case "beforeAttributeName":
2536
- wr(this.currentStartTag, n);
2537
- break;
2538
- case "attributeName":
2539
- case "afterAttributeName":
2540
- this.beginAttributeValue(false), this.finishAttributeValue(), wr(this.currentStartTag, n), r.transitionTo(qn);
2541
- break;
2542
- case "afterAttributeValueQuoted":
2543
- wr(this.currentStartTag, n), r.transitionTo(qn);
2544
- break;
2545
- case "beforeAttributeValue":
2546
- this.beginAttributeValue(false), this.appendDynamicAttributeValuePart(n), r.transitionTo(ta);
2547
- break;
2548
- case "attributeValueDoubleQuoted":
2549
- case "attributeValueSingleQuoted":
2550
- case "attributeValueUnquoted":
2551
- this.appendDynamicAttributeValuePart(n);
2552
- break;
2553
- default:
2554
- Ve(this.currentElement(), n);
2555
- }
2556
- return n;
2557
- }
2558
- appendDynamicAttributeValuePart(e) {
2559
- this.finalizeTextPart();
2560
- let r = this.currentAttr;
2561
- r.isDynamic = true, r.parts.push(e);
2562
- }
2563
- finalizeTextPart() {
2564
- let r = this.currentAttr.currentPart;
2565
- r !== null && (this.currentAttr.parts.push(r), this.startTextPart());
2566
- }
2567
- startTextPart() {
2568
- this.currentAttr.currentPart = null;
2569
- }
2570
- ContentStatement(e) {
2571
- na(this.tokenizer, e), this.tokenizer.tokenizePart(e.value), this.tokenizer.flushData();
2572
- }
2573
- CommentStatement(e) {
2574
- let { tokenizer: r } = this;
2575
- if (r.state === "comment") return this.appendToCommentData(this.sourceForNode(e)), null;
2576
- let { value: n, loc: s } = e, i = f.mustacheComment({ value: n, loc: this.source.spanFor(s) });
2577
- switch (r.state) {
2578
- case "beforeAttributeName":
2579
- case "afterAttributeName":
2580
- this.currentStartTag.comments.push(i);
2581
- break;
2582
- case "beforeData":
2583
- case "data":
2584
- Ve(this.currentElement(), i);
2585
- break;
2586
- default:
2587
- throw S(`Using a Handlebars comment when in the \`${r.state}\` state is not supported`, this.source.spanFor(e.loc));
2588
- }
2589
- return i;
2590
- }
2591
- PartialStatement(e) {
2592
- throw S("Handlebars partials are not supported", this.source.spanFor(e.loc));
2593
- }
2594
- PartialBlockStatement(e) {
2595
- throw S("Handlebars partial blocks are not supported", this.source.spanFor(e.loc));
2596
- }
2597
- Decorator(e) {
2598
- throw S("Handlebars decorators are not supported", this.source.spanFor(e.loc));
2599
- }
2600
- DecoratorBlock(e) {
2601
- throw S("Handlebars decorator blocks are not supported", this.source.spanFor(e.loc));
2602
- }
2603
- SubExpression(e) {
2604
- let { path: r, params: n, hash: s } = Sr(this, e);
2605
- return f.sexpr({ path: r, params: n, hash: s, loc: this.source.spanFor(e.loc) });
2606
- }
2607
- PathExpression(e) {
2608
- let { original: r } = e, n;
2609
- if (r.indexOf("/") !== -1) {
2610
- if (r.slice(0, 2) === "./") throw S('Using "./" is not supported in Glimmer and unnecessary', this.source.spanFor(e.loc));
2611
- if (r.slice(0, 3) === "../") throw S('Changing context using "../" is not supported in Glimmer', this.source.spanFor(e.loc));
2612
- if (r.indexOf(".") !== -1) throw S("Mixing '.' and '/' in paths is not supported in Glimmer; use only '.' to separate property paths", this.source.spanFor(e.loc));
2613
- n = [e.parts.join("/")];
2614
- } else {
2615
- if (r === ".") throw S("'.' is not a supported path in Glimmer; check for a path with a trailing '.'", this.source.spanFor(e.loc));
2616
- n = e.parts;
2617
- }
2618
- let s = false;
2619
- /^this(?:\..+)?$/u.test(r) && (s = true);
2620
- let i;
2621
- if (s) i = f.this({ loc: this.source.spanFor({ start: e.loc.start, end: { line: e.loc.start.line, column: e.loc.start.column + 4 } }) });
2622
- else if (e.data) {
2623
- let a = n.shift();
2624
- if (a === void 0) throw S("Attempted to parse a path expression, but it was not valid. Paths beginning with @ must start with a-z.", this.source.spanFor(e.loc));
2625
- i = f.atName({ name: `@${a}`, loc: this.source.spanFor({ start: e.loc.start, end: { line: e.loc.start.line, column: e.loc.start.column + a.length + 1 } }) });
2626
- } else {
2627
- let a = n.shift();
2628
- if (a === void 0) throw S("Attempted to parse a path expression, but it was not valid. Paths must start with a-z or A-Z.", this.source.spanFor(e.loc));
2629
- i = f.var({ name: a, loc: this.source.spanFor({ start: e.loc.start, end: { line: e.loc.start.line, column: e.loc.start.column + a.length } }) });
2630
- }
2631
- return f.path({ head: i, tail: n, loc: this.source.spanFor(e.loc) });
2632
- }
2633
- Hash(e) {
2634
- let r = e.pairs.map((n) => f.pair({ key: n.key, value: this.acceptNode(n.value), loc: this.source.spanFor(n.loc) }));
2635
- return f.hash({ pairs: r, loc: this.source.spanFor(e.loc) });
2636
- }
2637
- StringLiteral(e) {
2638
- return f.literal({ type: "StringLiteral", value: e.value, loc: this.source.spanFor(e.loc) });
2639
- }
2640
- BooleanLiteral(e) {
2641
- return f.literal({ type: "BooleanLiteral", value: e.value, loc: this.source.spanFor(e.loc) });
2642
- }
2643
- NumberLiteral(e) {
2644
- return f.literal({ type: "NumberLiteral", value: e.value, loc: this.source.spanFor(e.loc) });
2645
- }
2646
- UndefinedLiteral(e) {
2647
- return f.literal({ type: "UndefinedLiteral", value: void 0, loc: this.source.spanFor(e.loc) });
2648
- }
2649
- NullLiteral(e) {
2650
- return f.literal({ type: "NullLiteral", value: null, loc: this.source.spanFor(e.loc) });
2651
- }
2652
- };
2653
- function ra(t5, e) {
2654
- if (e === "") return { lines: t5.split(`
2655
- `).length - 1, columns: 0 };
2656
- let [r] = t5.split(e), n = r.split(/\n/u), s = n.length - 1;
2657
- return { lines: s, columns: kt(n[s]).length };
2658
- }
2659
- function na(t5, e) {
2660
- let r = e.loc.start.line, n = e.loc.start.column, s = ra(e.original, e.value);
2661
- r = r + s.lines, s.lines ? n = s.columns : n = n + s.columns, t5.line = r, t5.column = n;
2662
- }
2663
- function Sr(t5, e) {
2664
- let r;
2665
- switch (e.path.type) {
2666
- case "PathExpression":
2667
- r = t5.PathExpression(e.path);
2668
- break;
2669
- case "SubExpression":
2670
- r = t5.SubExpression(e.path);
2671
- break;
2672
- case "StringLiteral":
2673
- case "UndefinedLiteral":
2674
- case "NullLiteral":
2675
- case "NumberLiteral":
2676
- case "BooleanLiteral": {
2677
- let a;
2678
- throw e.path.type === "BooleanLiteral" ? a = e.path.original.toString() : e.path.type === "StringLiteral" ? a = `"${e.path.original}"` : e.path.type === "NullLiteral" ? a = "null" : e.path.type === "NumberLiteral" ? a = e.path.value.toString() : a = "undefined", S(`${e.path.type} "${e.path.type === "StringLiteral" ? e.path.original : a}" cannot be called as a sub-expression, replace (${a}) with ${a}`, t5.source.spanFor(e.path.loc));
2679
- }
2680
- }
2681
- let n = e.params ? e.params.map((a) => t5.acceptNode(a)) : [], s = we(n) ? Nt(n).loc : r.loc, i = e.hash ? t5.Hash(e.hash) : f.hash({ pairs: [], loc: t5.source.spanFor(s).collapse("end") });
2682
- return { path: r, params: n, hash: i };
2683
- }
2684
- function wr(t5, e) {
2685
- let { path: r, params: n, hash: s, loc: i } = e;
2686
- if (Mn(r)) {
2687
- let o = `{{${Di(r)}}}`, c = `<${t5.name} ... ${o} ...`;
2688
- throw S(`In ${c}, ${o} is not a valid modifier`, e.loc);
2689
- }
2690
- let a = f.elementModifier({ path: r, params: n, hash: s, loc: i });
2691
- t5.modifiers.push(a);
2692
- }
2693
- function He(t5) {
2694
- return /[\t\n\f ]/u.test(t5);
2695
- }
2696
- var _r = class extends Lr {
2697
- constructor() {
2698
- super(...arguments);
2699
- __publicField(this, "tagOpenLine", 0);
2700
- __publicField(this, "tagOpenColumn", 0);
2701
- }
2702
- reset() {
2703
- this.currentNode = null;
2704
- }
2705
- beginComment() {
2706
- this.currentNode = { type: "CommentStatement", value: "", start: this.source.offsetFor(this.tagOpenLine, this.tagOpenColumn) };
2707
- }
2708
- appendToCommentData(e) {
2709
- this.currentComment.value += e;
2710
- }
2711
- finishComment() {
2712
- Ve(this.currentElement(), f.comment(this.finish(this.currentComment)));
2713
- }
2714
- beginData() {
2715
- this.currentNode = { type: "TextNode", chars: "", start: this.offset() };
2716
- }
2717
- appendToData(e) {
2718
- this.currentData.chars += e;
2719
- }
2720
- finishData() {
2721
- Ve(this.currentElement(), f.text(this.finish(this.currentData)));
2722
- }
2723
- tagOpen() {
2724
- this.tagOpenLine = this.tokenizer.line, this.tagOpenColumn = this.tokenizer.column;
2725
- }
2726
- beginStartTag() {
2727
- this.currentNode = { type: "StartTag", name: "", nameStart: null, nameEnd: null, attributes: [], modifiers: [], comments: [], params: [], selfClosing: false, start: this.source.offsetFor(this.tagOpenLine, this.tagOpenColumn) };
2728
- }
2729
- beginEndTag() {
2730
- this.currentNode = { type: "EndTag", name: "", start: this.source.offsetFor(this.tagOpenLine, this.tagOpenColumn) };
2731
- }
2732
- finishTag() {
2733
- let e = this.finish(this.currentTag);
2734
- if (e.type === "StartTag") {
2735
- if (this.finishStartTag(), e.name === ":") throw S("Invalid named block named detected, you may have created a named block without a name, or you may have began your name with a number. Named blocks must have names that are at least one character long, and begin with a lower case letter", this.source.spanFor({ start: this.currentTag.start.toJSON(), end: this.offset().toJSON() }));
2736
- (kr.has(e.name) || e.selfClosing) && this.finishEndTag(true);
2737
- } else e.type === "EndTag" && this.finishEndTag(false);
2738
- }
2739
- finishStartTag() {
2740
- let { name: e, nameStart: r, nameEnd: n } = this.currentStartTag;
2741
- w(e !== "", "tag name cannot be empty"), w(r !== null, "nameStart unexpectedly null"), w(n !== null, "nameEnd unexpectedly null");
2742
- let s = r.until(n), [i, ...a] = qe(e.split(".")), o = f.path({ head: f.head({ original: i, loc: s.sliceStartChars({ chars: i.length }) }), tail: a, loc: s }), { attributes: c, modifiers: p, comments: h, params: d, selfClosing: N, loc: g } = this.finish(this.currentStartTag), T = f.element({ path: o, selfClosing: N, attributes: c, modifiers: p, comments: h, params: d, children: [], openTag: g, closeTag: N ? null : O.broken(), loc: g });
2743
- this.elementStack.push(T);
2744
- }
2745
- finishEndTag(e) {
2746
- let { start: r } = this.currentTag, n = this.finish(this.currentTag), s = this.elementStack.pop();
2747
- this.validateEndTag(n, s, e);
2748
- let i = this.currentElement();
2749
- e ? s.closeTag = null : s.selfClosing ? w(s.closeTag === null, "element.closeTag unexpectedly present") : s.closeTag = r.until(this.offset()), s.loc = s.loc.withEnd(this.offset()), Ve(i, f.element(s));
2750
- }
2751
- markTagAsSelfClosing() {
2752
- let e = this.currentTag;
2753
- if (e.type === "StartTag") e.selfClosing = true;
2754
- else throw S("Invalid end tag: closing tag must not be self-closing", this.source.spanFor({ start: e.start.toJSON(), end: this.offset().toJSON() }));
2755
- }
2756
- appendToTagName(e) {
2757
- let r = this.currentTag;
2758
- if (r.name += e, r.type === "StartTag") {
2759
- let n = this.offset();
2760
- r.nameStart === null && (w(r.nameEnd === null, "nameStart and nameEnd must both be null"), r.nameStart = n.move(-1)), r.nameEnd = n;
2761
- }
2762
- }
2763
- beginAttribute() {
2764
- let e = this.offset();
2765
- this.currentAttribute = { name: "", parts: [], currentPart: null, isQuoted: false, isDynamic: false, start: e, valueSpan: e.collapsed() };
2766
- }
2767
- appendToAttributeName(e) {
2768
- this.currentAttr.name += e, this.currentAttr.name === "as" && this.parsePossibleBlockParams();
2769
- }
2770
- beginAttributeValue(e) {
2771
- this.currentAttr.isQuoted = e, this.startTextPart(), this.currentAttr.valueSpan = this.offset().collapsed();
2772
- }
2773
- appendToAttributeValue(e) {
2774
- let r = this.currentAttr.parts, n = r[r.length - 1], s = this.currentAttr.currentPart;
2775
- if (s) s.chars += e, s.loc = s.loc.withEnd(this.offset());
2776
- else {
2777
- let i = this.offset();
2778
- e === `
2779
- ` ? i = n ? n.loc.getEnd() : this.currentAttr.valueSpan.getStart() : i = i.move(-1), this.currentAttr.currentPart = f.text({ chars: e, loc: i.collapsed() });
2780
- }
2781
- }
2782
- finishAttributeValue() {
2783
- this.finalizeTextPart();
2784
- let e = this.currentTag, r = this.offset();
2785
- if (e.type === "EndTag") throw S("Invalid end tag: closing tag must not have attributes", this.source.spanFor({ start: e.start.toJSON(), end: r.toJSON() }));
2786
- let { name: n, parts: s, start: i, isQuoted: a, isDynamic: o, valueSpan: c } = this.currentAttr;
2787
- if (n.startsWith("|") && s.length === 0 && !a && !o) throw S("Invalid block parameters syntax: block parameters must be preceded by the `as` keyword", i.until(i.move(n.length)));
2788
- let p = this.assembleAttributeValue(s, a, o, i.until(r));
2789
- p.loc = c.withEnd(r);
2790
- let h = f.attr({ name: n, value: p, loc: i.until(r) });
2791
- this.currentStartTag.attributes.push(h);
2792
- }
2793
- parsePossibleBlockParams() {
2794
- let e = "beforeAttributeName", r = "attributeName", n = "afterAttributeName", s = /[!"#%&'()*+./;<=>@[\\\]^`{|}~]/u;
2795
- w(this.tokenizer.state === r, "must be in TokenizerState.attributeName");
2796
- let i = this.currentStartTag, a = this.currentAttr, o = { state: "PossibleAs" }, c = { PossibleAs: (h) => {
2797
- if (w(o.state === "PossibleAs", "bug in block params parser"), He(h)) o = { state: "BeforeStartPipe" }, this.tokenizer.transitionTo(n), this.tokenizer.consume();
2798
- else {
2799
- if (h === "|") throw S('Invalid block parameters syntax: expecting at least one space character between "as" and "|"', a.start.until(this.offset().move(1)));
2800
- o = { state: "Done" };
2801
- }
2802
- }, BeforeStartPipe: (h) => {
2803
- w(o.state === "BeforeStartPipe", "bug in block params parser"), He(h) ? this.tokenizer.consume() : h === "|" ? (o = { state: "BeforeBlockParamName" }, this.tokenizer.transitionTo(e), this.tokenizer.consume()) : o = { state: "Done" };
2804
- }, BeforeBlockParamName: (h) => {
2805
- if (w(o.state === "BeforeBlockParamName", "bug in block params parser"), He(h)) this.tokenizer.consume();
2806
- else if (h === "") o = { state: "Done" }, this.pendingError = { mustache(d) {
2807
- throw S("Invalid block parameters syntax: mustaches cannot be used inside parameters list", d);
2808
- }, eof(d) {
2809
- throw S('Invalid block parameters syntax: expecting the tag to be closed with ">" or "/>" after parameters list', a.start.until(d));
2810
- } };
2811
- else if (h === "|") {
2812
- if (i.params.length === 0) throw S("Invalid block parameters syntax: empty parameters list, expecting at least one identifier", a.start.until(this.offset().move(1)));
2813
- o = { state: "AfterEndPipe" }, this.tokenizer.consume();
2814
- } else {
2815
- if (h === ">" || h === "/") throw S('Invalid block parameters syntax: incomplete parameters list, expecting "|" but the tag was closed prematurely', a.start.until(this.offset().move(1)));
2816
- o = { state: "BlockParamName", name: h, start: this.offset() }, this.tokenizer.consume();
2817
- }
2818
- }, BlockParamName: (h) => {
2819
- if (w(o.state === "BlockParamName", "bug in block params parser"), h === "") o = { state: "Done" }, this.pendingError = { mustache(d) {
2820
- throw S("Invalid block parameters syntax: mustaches cannot be used inside parameters list", d);
2821
- }, eof(d) {
2822
- throw S('Invalid block parameters syntax: expecting the tag to be closed with ">" or "/>" after parameters list', a.start.until(d));
2823
- } };
2824
- else if (h === "|" || He(h)) {
2825
- let d = o.start.until(this.offset());
2826
- if (o.name === "this" || s.test(o.name)) throw S(`Invalid block parameters syntax: invalid identifier name \`${o.name}\``, d);
2827
- i.params.push(f.var({ name: o.name, loc: d })), o = h === "|" ? { state: "AfterEndPipe" } : { state: "BeforeBlockParamName" }, this.tokenizer.consume();
2828
- } else {
2829
- if (h === ">" || h === "/") throw S('Invalid block parameters syntax: expecting "|" but the tag was closed prematurely', a.start.until(this.offset().move(1)));
2830
- o.name += h, this.tokenizer.consume();
2831
- }
2832
- }, AfterEndPipe: (h) => {
2833
- w(o.state === "AfterEndPipe", "bug in block params parser"), He(h) ? this.tokenizer.consume() : h === "" ? (o = { state: "Done" }, this.pendingError = { mustache(d) {
2834
- throw S("Invalid block parameters syntax: modifiers cannot follow parameters list", d);
2835
- }, eof(d) {
2836
- throw S('Invalid block parameters syntax: expecting the tag to be closed with ">" or "/>" after parameters list', a.start.until(d));
2837
- } }) : h === ">" || h === "/" ? o = { state: "Done" } : (o = { state: "Error", message: 'Invalid block parameters syntax: expecting the tag to be closed with ">" or "/>" after parameters list', start: this.offset() }, this.tokenizer.consume());
2838
- }, Error: (h) => {
2839
- if (w(o.state === "Error", "bug in block params parser"), h === "" || h === "/" || h === ">" || He(h)) throw S(o.message, o.start.until(this.offset()));
2840
- this.tokenizer.consume();
2841
- }, Done: () => {
2842
- w(false, "This should never be called");
2843
- } }, p;
2844
- do
2845
- p = this.tokenizer.peek(), c[o.state](p);
2846
- while (o.state !== "Done" && p !== "");
2847
- w(o.state === "Done", "bug in block params parser");
2848
- }
2849
- reportSyntaxError(e) {
2850
- throw S(e, this.offset().collapsed());
2851
- }
2852
- assembleConcatenatedValue(e) {
2853
- for (let s of e) if (s.type !== "MustacheStatement" && s.type !== "TextNode") throw S(`Unsupported node in quoted attribute value: ${s.type}`, s.loc);
2854
- Tt(e, "the concatenation parts of an element should not be empty");
2855
- let r = Nn(e), n = Nt(e);
2856
- return f.concat({ parts: e, loc: this.source.spanFor(r.loc).extend(this.source.spanFor(n.loc)) });
2857
- }
2858
- validateEndTag(e, r, n) {
2859
- if (kr.has(e.name) && !n) throw S(`<${e.name}> elements do not need end tags. You should remove it`, e.loc);
2860
- if (r.tag === void 0) throw S(`Closing tag </${e.name}> without an open tag`, e.loc);
2861
- if (r.tag !== e.name) throw S(`Closing tag </${e.name}> did not match last open tag <${r.tag}> (on line ${r.loc.startPosition.line})`, e.loc);
2862
- }
2863
- assembleAttributeValue(e, r, n, s) {
2864
- if (n) {
2865
- if (r) return this.assembleConcatenatedValue(e);
2866
- {
2867
- Tt(e);
2868
- let [i, a] = e;
2869
- if (a === void 0 || a.type === "TextNode" && a.chars === "/") return i;
2870
- throw S("An unquoted attribute value must be a string or a mustache, preceded by whitespace or a '=' character, and followed by whitespace, a '>' character, or '/>'", s);
2871
- }
2872
- } else return we(e) ? e[0] : f.text({ chars: "", loc: s });
2873
- }
2874
- };
2875
- var sa = {};
2876
- var Dr = class extends dr {
2877
- constructor() {
2878
- super({});
2879
- }
2880
- parse() {
2881
- }
2882
- };
2883
- function Wn(t5, e = {}) {
2884
- var _a;
2885
- var c, p, h;
2886
- let r = e.mode || "precompile", n, s;
2887
- typeof t5 == "string" ? (n = new Te(t5, (c = e.meta) == null ? void 0 : c.moduleName), r === "codemod" ? s = Ct(t5, e.parseOptions) : s = fr(t5, e.parseOptions)) : t5 instanceof Te ? (n = t5, r === "codemod" ? s = Ct(t5.source, e.parseOptions) : s = fr(t5.source, e.parseOptions)) : (n = new Te("", (p = e.meta) == null ? void 0 : p.moduleName), s = t5);
2888
- let i;
2889
- r === "codemod" && (i = new Dr());
2890
- let a = O.forCharPositions(n, 0, n.source.length);
2891
- s.loc = { source: "(program)", start: a.startPosition, end: a.endPosition };
2892
- let o = new _r(n, i, r).parse(s, (_a = e.locals) != null ? _a : []);
2893
- if ((h = e == null ? void 0 : e.plugins) != null && h.ast) for (let d of e.plugins.ast) {
2894
- let N = ar({}, e, { syntax: sa }, { plugins: void 0 }), g = d(N);
2895
- Li(o, g.visitor);
2896
- }
2897
- return o;
2898
- }
2899
- var Br = function(t5) {
2900
- return t5.Helper = "Helper", t5.Modifier = "Modifier", t5.Component = "Component", t5;
2901
- }({});
2902
- var tl = Br.Helper;
2903
- var rl = Br.Modifier;
2904
- var nl = Br.Component;
2905
- var Bt = `
2906
- `;
2907
- var $n = "\r";
2908
- var jn = function() {
2909
- function t5(e) {
2910
- this.length = e.length;
2911
- for (var r = [0], n = 0; n < e.length; ) switch (e[n]) {
2912
- case Bt:
2913
- n += Bt.length, r.push(n);
2914
- break;
2915
- case $n:
2916
- n += $n.length, e[n] === Bt && (n += Bt.length), r.push(n);
2917
- break;
2918
- default:
2919
- n++;
2920
- break;
2921
- }
2922
- this.offsets = r;
2923
- }
2924
- return t5.prototype.locationForIndex = function(e) {
2925
- if (e < 0 || e > this.length) return null;
2926
- for (var r = 0, n = this.offsets; n[r + 1] <= e; ) r++;
2927
- var s = e - n[r];
2928
- return { line: r, column: s };
2929
- }, t5.prototype.indexForLocation = function(e) {
2930
- var r = e.line, n = e.column;
2931
- return r < 0 || r >= this.offsets.length || n < 0 || n > this.lengthOfLine(r) ? null : this.offsets[r] + n;
2932
- }, t5.prototype.lengthOfLine = function(e) {
2933
- var r = this.offsets[e], n = e === this.offsets.length - 1 ? this.length : this.offsets[e + 1];
2934
- return n - r;
2935
- }, t5;
2936
- }();
2937
- function ia(t5, e) {
2938
- let r = new SyntaxError(t5 + " (" + e.loc.start.line + ":" + e.loc.start.column + ")");
2939
- return Object.assign(r, e);
2940
- }
2941
- var Qn = ia;
2942
- function aa(t5) {
2943
- var _a;
2944
- let e = (_a = t5.children) != null ? _a : t5.body;
2945
- if (e) for (let r = 0; r < e.length - 1; r++) e[r].type === "TextNode" && e[r + 1].type === "MustacheStatement" && (e[r].chars = e[r].chars.replace(/\\$/u, "\\\\"));
2946
- }
2947
- function oa(t5) {
2948
- let e = new jn(t5), r = ({ line: s, column: i }) => e.indexForLocation({ line: s - 1, column: i }), n = (s) => {
2949
- let { start: i, end: a } = s.loc;
2950
- i.offset = r(i), a.offset = r(a);
2951
- };
2952
- return () => ({ name: "prettierParsePlugin", visitor: { All(s) {
2953
- n(s), aa(s);
2954
- } } });
2955
- }
2956
- function la(t5) {
2957
- let e;
2958
- try {
2959
- e = Wn(t5, { mode: "codemod", plugins: { ast: [oa(t5)] } });
2960
- } catch (r) {
2961
- let n = ua(r);
2962
- if (n) {
2963
- let s = ca(r);
2964
- throw Qn(s, { loc: n, cause: r });
2965
- }
2966
- throw r;
2967
- }
2968
- return e;
2969
- }
2970
- function ca(t5) {
2971
- let { message: e } = t5, r = e.split(`
2972
- `);
2973
- return r.length >= 4 && /^Parse error on line \d+:$/u.test(r[0]) && /^-*\^$/u.test(oe(false, r, -2)) ? oe(false, r, -1) : r.length >= 4 && /:\s?$/u.test(r[0]) && /^\(error occurred in '.*?' @ line \d+ : column \d+\)$/u.test(oe(false, r, -1)) && r[1] === "" && oe(false, r, -2) === "" && r.slice(2, -2).every((n) => n.startsWith("|")) ? r[0].trim().slice(0, -1) : e;
2974
- }
2975
- function ua(t5) {
2976
- let { location: e, hash: r } = t5;
2977
- if (e) {
2978
- let { start: n, end: s } = e;
2979
- return typeof s.line != "number" ? { start: n } : e;
2980
- }
2981
- if (r) {
2982
- let { loc: { last_line: n, last_column: s } } = r;
2983
- return { start: { line: n, column: s + 1 } };
2984
- }
2985
- }
2986
- var ha = { parse: la, astFormat: "glimmer", locStart: Se, locEnd: tt };
2987
- var pa = { glimmer: En };
2988
- var bl = Rr;
2989
- export {
2990
- bl as default,
2991
- Sn as languages,
2992
- Ir as parsers,
2993
- pa as printers
2994
- };
2995
- //# sourceMappingURL=glimmer-PF2X22V2.mjs.map