@kubb/core 4.3.1 → 4.4.0

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 (128) hide show
  1. package/dist/{URLPath-BYceu_vY.js → URLPath-Bpc_OJmh.js} +2 -3
  2. package/dist/{URLPath-BYceu_vY.js.map → URLPath-Bpc_OJmh.js.map} +1 -1
  3. package/dist/{URLPath-8WVzHBnA.cjs → URLPath-Bu6Wkco7.cjs} +6 -7
  4. package/dist/{URLPath-8WVzHBnA.cjs.map → URLPath-Bu6Wkco7.cjs.map} +1 -1
  5. package/dist/{chunk-CZg_9w7l.cjs → chunk-CUT6urMc.cjs} +0 -23
  6. package/dist/{fs-RSVoUw3S.cjs → fs-CM7ohZSu.cjs} +2 -2
  7. package/dist/{fs-RSVoUw3S.cjs.map → fs-CM7ohZSu.cjs.map} +1 -1
  8. package/dist/fs.cjs +2 -2
  9. package/dist/fs.d.ts +1 -1
  10. package/dist/hooks.cjs +6 -6
  11. package/dist/hooks.cjs.map +1 -1
  12. package/dist/hooks.d.cts +1 -1
  13. package/dist/hooks.d.ts +4 -4
  14. package/dist/hooks.js +1 -1
  15. package/dist/hooks.js.map +1 -1
  16. package/dist/{index-BTe91LHd.d.ts → index-DdO15F70.d.ts} +2 -3
  17. package/dist/index.cjs +46 -53
  18. package/dist/index.cjs.map +1 -1
  19. package/dist/index.d.cts +15 -11
  20. package/dist/index.d.ts +18 -14
  21. package/dist/index.js +40 -48
  22. package/dist/index.js.map +1 -1
  23. package/dist/{logger-BXL0YCrv.cjs → logger-C7JFdYpj.cjs} +4 -4
  24. package/dist/{logger-BXL0YCrv.cjs.map → logger-C7JFdYpj.cjs.map} +1 -1
  25. package/dist/{logger-BA-za85-.d.ts → logger-D_jvWsUF.d.ts} +1 -1
  26. package/dist/{logger-CDxSrFkR.js → logger-khF_Lft4.js} +2 -2
  27. package/dist/{logger-CDxSrFkR.js.map → logger-khF_Lft4.js.map} +1 -1
  28. package/dist/logger.cjs +2 -2
  29. package/dist/logger.d.ts +1 -1
  30. package/dist/logger.js +1 -1
  31. package/dist/{prompt-DBVnG4Me.js → prompt-CIpZjUDy.js} +1 -1
  32. package/dist/{prompt-DBVnG4Me.js.map → prompt-CIpZjUDy.js.map} +1 -1
  33. package/dist/{prompt-DgONOpPH.cjs → prompt-CgJLZzbf.cjs} +2 -2
  34. package/dist/{prompt-DgONOpPH.cjs.map → prompt-CgJLZzbf.cjs.map} +1 -1
  35. package/dist/transformers-BN5jfIAt.js +339 -0
  36. package/dist/transformers-BN5jfIAt.js.map +1 -0
  37. package/dist/transformers-BpnIvSiH.cjs +443 -0
  38. package/dist/transformers-BpnIvSiH.cjs.map +1 -0
  39. package/dist/transformers.cjs +7 -6
  40. package/dist/transformers.js +1 -3
  41. package/dist/{types-DPeNK0FO.d.ts → types-CCUiy4jG.d.ts} +43 -45
  42. package/dist/{types-BzI9JlV8.d.ts → types-ClXc6HFo.d.ts} +1 -1
  43. package/dist/{types-DNxlynJr.d.cts → types-EV6-sImo.d.cts} +40 -42
  44. package/dist/utils.cjs +7 -7
  45. package/dist/utils.cjs.map +1 -1
  46. package/dist/utils.d.ts +1 -1
  47. package/dist/utils.js +4 -6
  48. package/dist/utils.js.map +1 -1
  49. package/dist/{write-BJfM7G1_.cjs → write-BsFt8M9e.cjs} +2 -2
  50. package/dist/{write-BJfM7G1_.cjs.map → write-BsFt8M9e.cjs.map} +1 -1
  51. package/package.json +8 -14
  52. package/src/PluginManager.ts +3 -7
  53. package/src/build.ts +37 -41
  54. package/src/hooks/useMode.ts +1 -1
  55. package/src/hooks/usePlugin.ts +1 -1
  56. package/src/hooks/usePluginManager.ts +1 -1
  57. package/src/plugin.ts +10 -5
  58. package/src/types.ts +2 -1
  59. package/dist/acorn-BAVXZMtK.cjs +0 -5082
  60. package/dist/acorn-BAVXZMtK.cjs.map +0 -1
  61. package/dist/acorn-D-VhIOLw.js +0 -5080
  62. package/dist/acorn-D-VhIOLw.js.map +0 -1
  63. package/dist/angular-Bp0XO9db.cjs +0 -3631
  64. package/dist/angular-Bp0XO9db.cjs.map +0 -1
  65. package/dist/angular-Czhp4eq5.js +0 -3629
  66. package/dist/angular-Czhp4eq5.js.map +0 -1
  67. package/dist/babel-DCR_B4Qn.js +0 -10033
  68. package/dist/babel-DCR_B4Qn.js.map +0 -1
  69. package/dist/babel-NI0v59ga.cjs +0 -10035
  70. package/dist/babel-NI0v59ga.cjs.map +0 -1
  71. package/dist/casing-BSeq_teY.js +0 -100
  72. package/dist/casing-BSeq_teY.js.map +0 -1
  73. package/dist/casing-CP-9GGdK.cjs +0 -112
  74. package/dist/casing-CP-9GGdK.cjs.map +0 -1
  75. package/dist/chunk-1SJ2vVWa.js +0 -35
  76. package/dist/estree-C3BZPlpU.cjs +0 -6930
  77. package/dist/estree-C3BZPlpU.cjs.map +0 -1
  78. package/dist/estree-DU2NummP.js +0 -6926
  79. package/dist/estree-DU2NummP.js.map +0 -1
  80. package/dist/flow-CWUBUkoi.cjs +0 -52252
  81. package/dist/flow-CWUBUkoi.cjs.map +0 -1
  82. package/dist/flow-JiEbweKj.js +0 -52250
  83. package/dist/flow-JiEbweKj.js.map +0 -1
  84. package/dist/glimmer-CX9OqG1j.cjs +0 -7275
  85. package/dist/glimmer-CX9OqG1j.cjs.map +0 -1
  86. package/dist/glimmer-t9nWn9aE.js +0 -7271
  87. package/dist/glimmer-t9nWn9aE.js.map +0 -1
  88. package/dist/graphql-DjErlIi5.js +0 -1897
  89. package/dist/graphql-DjErlIi5.js.map +0 -1
  90. package/dist/graphql-GOxQAKxM.cjs +0 -1902
  91. package/dist/graphql-GOxQAKxM.cjs.map +0 -1
  92. package/dist/html-CWrdYAhQ.cjs +0 -6560
  93. package/dist/html-CWrdYAhQ.cjs.map +0 -1
  94. package/dist/html-_apcbx34.js +0 -6555
  95. package/dist/html-_apcbx34.js.map +0 -1
  96. package/dist/markdown-ckUc3Q6q.js +0 -6750
  97. package/dist/markdown-ckUc3Q6q.js.map +0 -1
  98. package/dist/markdown-pzqiRmft.cjs +0 -6755
  99. package/dist/markdown-pzqiRmft.cjs.map +0 -1
  100. package/dist/meriyah-BjnGqpUs.js +0 -8928
  101. package/dist/meriyah-BjnGqpUs.js.map +0 -1
  102. package/dist/meriyah-D_x7itbT.cjs +0 -8930
  103. package/dist/meriyah-D_x7itbT.cjs.map +0 -1
  104. package/dist/mocks.cjs +0 -16830
  105. package/dist/mocks.cjs.map +0 -1
  106. package/dist/mocks.d.cts +0 -13
  107. package/dist/mocks.d.ts +0 -13
  108. package/dist/mocks.js +0 -16818
  109. package/dist/mocks.js.map +0 -1
  110. package/dist/postcss-B_c2wbFu.cjs +0 -6689
  111. package/dist/postcss-B_c2wbFu.cjs.map +0 -1
  112. package/dist/postcss-v7BP6SZ-.js +0 -6684
  113. package/dist/postcss-v7BP6SZ-.js.map +0 -1
  114. package/dist/transformers-BH0KLJJP.cjs +0 -804
  115. package/dist/transformers-BH0KLJJP.cjs.map +0 -1
  116. package/dist/transformers-DzHGqYO2.js +0 -702
  117. package/dist/transformers-DzHGqYO2.js.map +0 -1
  118. package/dist/typescript-6kMN6Wqz.cjs +0 -23014
  119. package/dist/typescript-6kMN6Wqz.cjs.map +0 -1
  120. package/dist/typescript-B_IBfKSe.js +0 -23002
  121. package/dist/typescript-B_IBfKSe.js.map +0 -1
  122. package/dist/typescript-C5hce4HG.cjs +0 -4
  123. package/dist/typescript-Cas1XcNz.js +0 -3
  124. package/dist/yaml-BfWM_B73.js +0 -5209
  125. package/dist/yaml-BfWM_B73.js.map +0 -1
  126. package/dist/yaml-DZs6MhV1.cjs +0 -5215
  127. package/dist/yaml-DZs6MhV1.cjs.map +0 -1
  128. package/src/mocks/index.ts +0 -82
@@ -1,3631 +0,0 @@
1
-
2
- //#region ../../node_modules/.pnpm/prettier@3.6.2/node_modules/prettier/plugins/angular.mjs
3
- var qs = Object.defineProperty;
4
- var tn = (n) => {
5
- throw TypeError(n);
6
- };
7
- var nn = (n, e) => {
8
- for (var t in e) qs(n, t, {
9
- get: e[t],
10
- enumerable: !0
11
- });
12
- };
13
- var dt = (n, e, t) => e.has(n) || tn("Cannot " + t);
14
- var L = (n, e, t) => (dt(n, e, "read from private field"), t ? t.call(n) : e.get(n)), V = (n, e, t) => e.has(n) ? tn("Cannot add the same private member more than once") : e instanceof WeakSet ? e.add(n) : e.set(n, t), te = (n, e, t, s) => (dt(n, e, "write to private field"), s ? s.call(n, t) : e.set(n, t), t), c = (n, e, t) => (dt(n, e, "access private method"), t);
15
- var Zt = {};
16
- nn(Zt, { parsers: () => Kt });
17
- var Kt = {};
18
- nn(Kt, {
19
- __ng_action: () => Jr,
20
- __ng_binding: () => Yr,
21
- __ng_directive: () => Kr,
22
- __ng_interpolation: () => Qr
23
- });
24
- var sn;
25
- (function(n) {
26
- n[n.Emulated = 0] = "Emulated", n[n.None = 2] = "None", n[n.ShadowDom = 3] = "ShadowDom";
27
- })(sn || (sn = {}));
28
- var rn;
29
- (function(n) {
30
- n[n.OnPush = 0] = "OnPush", n[n.Default = 1] = "Default";
31
- })(rn || (rn = {}));
32
- var on;
33
- (function(n) {
34
- n[n.None = 0] = "None", n[n.SignalBased = 1] = "SignalBased", n[n.HasDecoratorInputTransform = 2] = "HasDecoratorInputTransform";
35
- })(on || (on = {}));
36
- var D;
37
- (function(n) {
38
- n[n.NONE = 0] = "NONE", n[n.HTML = 1] = "HTML", n[n.STYLE = 2] = "STYLE", n[n.SCRIPT = 3] = "SCRIPT", n[n.URL = 4] = "URL", n[n.RESOURCE_URL = 5] = "RESOURCE_URL";
39
- })(D || (D = {}));
40
- var an;
41
- (function(n) {
42
- n[n.Error = 0] = "Error", n[n.Warning = 1] = "Warning", n[n.Ignore = 2] = "Ignore";
43
- })(an || (an = {}));
44
- var ln;
45
- (function(n) {
46
- n[n.Directive = 0] = "Directive", n[n.Component = 1] = "Component", n[n.Injectable = 2] = "Injectable", n[n.Pipe = 3] = "Pipe", n[n.NgModule = 4] = "NgModule";
47
- })(ln || (ln = {}));
48
- var cn;
49
- (function(n) {
50
- n[n.Directive = 0] = "Directive", n[n.Pipe = 1] = "Pipe", n[n.NgModule = 2] = "NgModule";
51
- })(cn || (cn = {}));
52
- var un;
53
- (function(n) {
54
- n[n.Emulated = 0] = "Emulated", n[n.None = 2] = "None", n[n.ShadowDom = 3] = "ShadowDom";
55
- })(un || (un = {}));
56
- var pn;
57
- (function(n) {
58
- n[n.Little = 0] = "Little", n[n.Big = 1] = "Big";
59
- })(pn || (pn = {}));
60
- var hn;
61
- (function(n) {
62
- n[n.None = 0] = "None", n[n.Const = 1] = "Const";
63
- })(hn || (hn = {}));
64
- var fn;
65
- (function(n) {
66
- n[n.Dynamic = 0] = "Dynamic", n[n.Bool = 1] = "Bool", n[n.String = 2] = "String", n[n.Int = 3] = "Int", n[n.Number = 4] = "Number", n[n.Function = 5] = "Function", n[n.Inferred = 6] = "Inferred", n[n.None = 7] = "None";
67
- })(fn || (fn = {}));
68
- var js = void 0;
69
- var dn;
70
- (function(n) {
71
- n[n.Minus = 0] = "Minus", n[n.Plus = 1] = "Plus";
72
- })(dn || (dn = {}));
73
- var _;
74
- (function(n) {
75
- n[n.Equals = 0] = "Equals", n[n.NotEquals = 1] = "NotEquals", n[n.Identical = 2] = "Identical", n[n.NotIdentical = 3] = "NotIdentical", n[n.Minus = 4] = "Minus", n[n.Plus = 5] = "Plus", n[n.Divide = 6] = "Divide", n[n.Multiply = 7] = "Multiply", n[n.Modulo = 8] = "Modulo", n[n.And = 9] = "And", n[n.Or = 10] = "Or", n[n.BitwiseOr = 11] = "BitwiseOr", n[n.BitwiseAnd = 12] = "BitwiseAnd", n[n.Lower = 13] = "Lower", n[n.LowerEquals = 14] = "LowerEquals", n[n.Bigger = 15] = "Bigger", n[n.BiggerEquals = 16] = "BiggerEquals", n[n.NullishCoalesce = 17] = "NullishCoalesce", n[n.Exponentiation = 18] = "Exponentiation", n[n.In = 19] = "In";
76
- })(_ || (_ = {}));
77
- function zs(n, e) {
78
- return n == null || e == null ? n == e : n.isEquivalent(e);
79
- }
80
- function Gs(n, e, t) {
81
- let s = n.length;
82
- if (s !== e.length) return !1;
83
- for (let r = 0; r < s; r++) if (!t(n[r], e[r])) return !1;
84
- return !0;
85
- }
86
- function ct(n, e) {
87
- return Gs(n, e, (t, s) => t.isEquivalent(s));
88
- }
89
- var b = class {
90
- type;
91
- sourceSpan;
92
- constructor(e, t) {
93
- this.type = e || null, this.sourceSpan = t || null;
94
- }
95
- prop(e, t) {
96
- return new _t(this, e, null, t);
97
- }
98
- key(e, t, s) {
99
- return new Ct(this, e, t, s);
100
- }
101
- callFn(e, t, s) {
102
- return new xt(this, e, null, t, s);
103
- }
104
- instantiate(e, t, s) {
105
- return new St(this, e, t, s);
106
- }
107
- conditional(e, t = null, s) {
108
- return new yt(this, e, t, null, s);
109
- }
110
- equals(e, t) {
111
- return new C(_.Equals, this, e, null, t);
112
- }
113
- notEquals(e, t) {
114
- return new C(_.NotEquals, this, e, null, t);
115
- }
116
- identical(e, t) {
117
- return new C(_.Identical, this, e, null, t);
118
- }
119
- notIdentical(e, t) {
120
- return new C(_.NotIdentical, this, e, null, t);
121
- }
122
- minus(e, t) {
123
- return new C(_.Minus, this, e, null, t);
124
- }
125
- plus(e, t) {
126
- return new C(_.Plus, this, e, null, t);
127
- }
128
- divide(e, t) {
129
- return new C(_.Divide, this, e, null, t);
130
- }
131
- multiply(e, t) {
132
- return new C(_.Multiply, this, e, null, t);
133
- }
134
- modulo(e, t) {
135
- return new C(_.Modulo, this, e, null, t);
136
- }
137
- power(e, t) {
138
- return new C(_.Exponentiation, this, e, null, t);
139
- }
140
- and(e, t) {
141
- return new C(_.And, this, e, null, t);
142
- }
143
- bitwiseOr(e, t) {
144
- return new C(_.BitwiseOr, this, e, null, t);
145
- }
146
- bitwiseAnd(e, t) {
147
- return new C(_.BitwiseAnd, this, e, null, t);
148
- }
149
- or(e, t) {
150
- return new C(_.Or, this, e, null, t);
151
- }
152
- lower(e, t) {
153
- return new C(_.Lower, this, e, null, t);
154
- }
155
- lowerEquals(e, t) {
156
- return new C(_.LowerEquals, this, e, null, t);
157
- }
158
- bigger(e, t) {
159
- return new C(_.Bigger, this, e, null, t);
160
- }
161
- biggerEquals(e, t) {
162
- return new C(_.BiggerEquals, this, e, null, t);
163
- }
164
- isBlank(e) {
165
- return this.equals(TYPED_NULL_EXPR, e);
166
- }
167
- nullishCoalesce(e, t) {
168
- return new C(_.NullishCoalesce, this, e, null, t);
169
- }
170
- toStmt() {
171
- return new It(this, null);
172
- }
173
- }, st = class n extends b {
174
- name;
175
- constructor(e, t, s) {
176
- super(t, s), this.name = e;
177
- }
178
- isEquivalent(e) {
179
- return e instanceof n && this.name === e.name;
180
- }
181
- isConstant() {
182
- return !1;
183
- }
184
- visitExpression(e, t) {
185
- return e.visitReadVarExpr(this, t);
186
- }
187
- clone() {
188
- return new n(this.name, this.type, this.sourceSpan);
189
- }
190
- set(e) {
191
- return new gt(this.name, e, null, this.sourceSpan);
192
- }
193
- }, mt = class n extends b {
194
- expr;
195
- constructor(e, t, s) {
196
- super(t, s), this.expr = e;
197
- }
198
- visitExpression(e, t) {
199
- return e.visitTypeofExpr(this, t);
200
- }
201
- isEquivalent(e) {
202
- return e instanceof n && e.expr.isEquivalent(this.expr);
203
- }
204
- isConstant() {
205
- return this.expr.isConstant();
206
- }
207
- clone() {
208
- return new n(this.expr.clone());
209
- }
210
- };
211
- var gt = class n extends b {
212
- name;
213
- value;
214
- constructor(e, t, s, r) {
215
- super(s || t.type, r), this.name = e, this.value = t;
216
- }
217
- isEquivalent(e) {
218
- return e instanceof n && this.name === e.name && this.value.isEquivalent(e.value);
219
- }
220
- isConstant() {
221
- return !1;
222
- }
223
- visitExpression(e, t) {
224
- return e.visitWriteVarExpr(this, t);
225
- }
226
- clone() {
227
- return new n(this.name, this.value.clone(), this.type, this.sourceSpan);
228
- }
229
- toDeclStmt(e, t) {
230
- return new bt(this.name, this.value, e, t, this.sourceSpan);
231
- }
232
- toConstDecl() {
233
- return this.toDeclStmt(js, Ae.Final);
234
- }
235
- }, vt = class n extends b {
236
- receiver;
237
- index;
238
- value;
239
- constructor(e, t, s, r, i) {
240
- super(r || s.type, i), this.receiver = e, this.index = t, this.value = s;
241
- }
242
- isEquivalent(e) {
243
- return e instanceof n && this.receiver.isEquivalent(e.receiver) && this.index.isEquivalent(e.index) && this.value.isEquivalent(e.value);
244
- }
245
- isConstant() {
246
- return !1;
247
- }
248
- visitExpression(e, t) {
249
- return e.visitWriteKeyExpr(this, t);
250
- }
251
- clone() {
252
- return new n(this.receiver.clone(), this.index.clone(), this.value.clone(), this.type, this.sourceSpan);
253
- }
254
- }, wt = class n extends b {
255
- receiver;
256
- name;
257
- value;
258
- constructor(e, t, s, r, i) {
259
- super(r || s.type, i), this.receiver = e, this.name = t, this.value = s;
260
- }
261
- isEquivalent(e) {
262
- return e instanceof n && this.receiver.isEquivalent(e.receiver) && this.name === e.name && this.value.isEquivalent(e.value);
263
- }
264
- isConstant() {
265
- return !1;
266
- }
267
- visitExpression(e, t) {
268
- return e.visitWritePropExpr(this, t);
269
- }
270
- clone() {
271
- return new n(this.receiver.clone(), this.name, this.value.clone(), this.type, this.sourceSpan);
272
- }
273
- }, xt = class n extends b {
274
- fn;
275
- args;
276
- pure;
277
- constructor(e, t, s, r, i = !1) {
278
- super(s, r), this.fn = e, this.args = t, this.pure = i;
279
- }
280
- get receiver() {
281
- return this.fn;
282
- }
283
- isEquivalent(e) {
284
- return e instanceof n && this.fn.isEquivalent(e.fn) && ct(this.args, e.args) && this.pure === e.pure;
285
- }
286
- isConstant() {
287
- return !1;
288
- }
289
- visitExpression(e, t) {
290
- return e.visitInvokeFunctionExpr(this, t);
291
- }
292
- clone() {
293
- return new n(this.fn.clone(), this.args.map((e) => e.clone()), this.type, this.sourceSpan, this.pure);
294
- }
295
- };
296
- var St = class n extends b {
297
- classExpr;
298
- args;
299
- constructor(e, t, s, r) {
300
- super(s, r), this.classExpr = e, this.args = t;
301
- }
302
- isEquivalent(e) {
303
- return e instanceof n && this.classExpr.isEquivalent(e.classExpr) && ct(this.args, e.args);
304
- }
305
- isConstant() {
306
- return !1;
307
- }
308
- visitExpression(e, t) {
309
- return e.visitInstantiateExpr(this, t);
310
- }
311
- clone() {
312
- return new n(this.classExpr.clone(), this.args.map((e) => e.clone()), this.type, this.sourceSpan);
313
- }
314
- }, rt = class n extends b {
315
- value;
316
- constructor(e, t, s) {
317
- super(t, s), this.value = e;
318
- }
319
- isEquivalent(e) {
320
- return e instanceof n && this.value === e.value;
321
- }
322
- isConstant() {
323
- return !0;
324
- }
325
- visitExpression(e, t) {
326
- return e.visitLiteralExpr(this, t);
327
- }
328
- clone() {
329
- return new n(this.value, this.type, this.sourceSpan);
330
- }
331
- };
332
- var Et = class n extends b {
333
- value;
334
- typeParams;
335
- constructor(e, t, s = null, r) {
336
- super(t, r), this.value = e, this.typeParams = s;
337
- }
338
- isEquivalent(e) {
339
- return e instanceof n && this.value.name === e.value.name && this.value.moduleName === e.value.moduleName;
340
- }
341
- isConstant() {
342
- return !1;
343
- }
344
- visitExpression(e, t) {
345
- return e.visitExternalExpr(this, t);
346
- }
347
- clone() {
348
- return new n(this.value, this.type, this.typeParams, this.sourceSpan);
349
- }
350
- };
351
- var yt = class n extends b {
352
- condition;
353
- falseCase;
354
- trueCase;
355
- constructor(e, t, s = null, r, i) {
356
- super(r || t.type, i), this.condition = e, this.falseCase = s, this.trueCase = t;
357
- }
358
- isEquivalent(e) {
359
- return e instanceof n && this.condition.isEquivalent(e.condition) && this.trueCase.isEquivalent(e.trueCase) && zs(this.falseCase, e.falseCase);
360
- }
361
- isConstant() {
362
- return !1;
363
- }
364
- visitExpression(e, t) {
365
- return e.visitConditionalExpr(this, t);
366
- }
367
- clone() {
368
- var e;
369
- return new n(this.condition.clone(), this.trueCase.clone(), (e = this.falseCase) == null ? void 0 : e.clone(), this.type, this.sourceSpan);
370
- }
371
- };
372
- var C = class n extends b {
373
- operator;
374
- rhs;
375
- lhs;
376
- constructor(e, t, s, r, i) {
377
- super(r || t.type, i), this.operator = e, this.rhs = s, this.lhs = t;
378
- }
379
- isEquivalent(e) {
380
- return e instanceof n && this.operator === e.operator && this.lhs.isEquivalent(e.lhs) && this.rhs.isEquivalent(e.rhs);
381
- }
382
- isConstant() {
383
- return !1;
384
- }
385
- visitExpression(e, t) {
386
- return e.visitBinaryOperatorExpr(this, t);
387
- }
388
- clone() {
389
- return new n(this.operator, this.lhs.clone(), this.rhs.clone(), this.type, this.sourceSpan);
390
- }
391
- }, _t = class n extends b {
392
- receiver;
393
- name;
394
- constructor(e, t, s, r) {
395
- super(s, r), this.receiver = e, this.name = t;
396
- }
397
- get index() {
398
- return this.name;
399
- }
400
- isEquivalent(e) {
401
- return e instanceof n && this.receiver.isEquivalent(e.receiver) && this.name === e.name;
402
- }
403
- isConstant() {
404
- return !1;
405
- }
406
- visitExpression(e, t) {
407
- return e.visitReadPropExpr(this, t);
408
- }
409
- set(e) {
410
- return new wt(this.receiver, this.name, e, null, this.sourceSpan);
411
- }
412
- clone() {
413
- return new n(this.receiver.clone(), this.name, this.type, this.sourceSpan);
414
- }
415
- }, Ct = class n extends b {
416
- receiver;
417
- index;
418
- constructor(e, t, s, r) {
419
- super(s, r), this.receiver = e, this.index = t;
420
- }
421
- isEquivalent(e) {
422
- return e instanceof n && this.receiver.isEquivalent(e.receiver) && this.index.isEquivalent(e.index);
423
- }
424
- isConstant() {
425
- return !1;
426
- }
427
- visitExpression(e, t) {
428
- return e.visitReadKeyExpr(this, t);
429
- }
430
- set(e) {
431
- return new vt(this.receiver, this.index, e, null, this.sourceSpan);
432
- }
433
- clone() {
434
- return new n(this.receiver.clone(), this.index.clone(), this.type, this.sourceSpan);
435
- }
436
- }, Tt = class n extends b {
437
- entries;
438
- constructor(e, t, s) {
439
- super(t, s), this.entries = e;
440
- }
441
- isConstant() {
442
- return this.entries.every((e) => e.isConstant());
443
- }
444
- isEquivalent(e) {
445
- return e instanceof n && ct(this.entries, e.entries);
446
- }
447
- visitExpression(e, t) {
448
- return e.visitLiteralArrayExpr(this, t);
449
- }
450
- clone() {
451
- return new n(this.entries.map((e) => e.clone()), this.type, this.sourceSpan);
452
- }
453
- };
454
- var kt = class n extends b {
455
- entries;
456
- valueType = null;
457
- constructor(e, t, s) {
458
- super(t, s), this.entries = e, t && (this.valueType = t.valueType);
459
- }
460
- isEquivalent(e) {
461
- return e instanceof n && ct(this.entries, e.entries);
462
- }
463
- isConstant() {
464
- return this.entries.every((e) => e.value.isConstant());
465
- }
466
- visitExpression(e, t) {
467
- return e.visitLiteralMapExpr(this, t);
468
- }
469
- clone() {
470
- return new n(this.entries.map((t) => t.clone()), this.type, this.sourceSpan);
471
- }
472
- };
473
- var Ae;
474
- (function(n) {
475
- n[n.None = 0] = "None", n[n.Final = 1] = "Final", n[n.Private = 2] = "Private", n[n.Exported = 4] = "Exported", n[n.Static = 8] = "Static";
476
- })(Ae || (Ae = {}));
477
- var it = class {
478
- modifiers;
479
- sourceSpan;
480
- leadingComments;
481
- constructor(e = Ae.None, t = null, s) {
482
- this.modifiers = e, this.sourceSpan = t, this.leadingComments = s;
483
- }
484
- hasModifier(e) {
485
- return (this.modifiers & e) !== 0;
486
- }
487
- addLeadingComment(e) {
488
- this.leadingComments = this.leadingComments ?? [], this.leadingComments.push(e);
489
- }
490
- }, bt = class n extends it {
491
- name;
492
- value;
493
- type;
494
- constructor(e, t, s, r, i, a) {
495
- super(r, i, a), this.name = e, this.value = t, this.type = s || t && t.type || null;
496
- }
497
- isEquivalent(e) {
498
- return e instanceof n && this.name === e.name && (this.value ? !!e.value && this.value.isEquivalent(e.value) : !e.value);
499
- }
500
- visitStatement(e, t) {
501
- return e.visitDeclareVarStmt(this, t);
502
- }
503
- };
504
- var It = class n extends it {
505
- expr;
506
- constructor(e, t, s) {
507
- super(Ae.None, t, s), this.expr = e;
508
- }
509
- isEquivalent(e) {
510
- return e instanceof n && this.expr.isEquivalent(e.expr);
511
- }
512
- visitStatement(e, t) {
513
- return e.visitExpressionStmt(this, t);
514
- }
515
- };
516
- function Xs(n, e, t) {
517
- return new st(n, e, t);
518
- }
519
- Xs("<unknown>");
520
- (class n {
521
- static INSTANCE = new n();
522
- keyOf(e) {
523
- if (e instanceof rt && typeof e.value == "string") return `"${e.value}"`;
524
- if (e instanceof rt) return String(e.value);
525
- if (e instanceof Tt) {
526
- let t = [];
527
- for (let s of e.entries) t.push(this.keyOf(s));
528
- return `[${t.join(",")}]`;
529
- } else if (e instanceof kt) {
530
- let t = [];
531
- for (let s of e.entries) {
532
- let r = s.key;
533
- s.quoted && (r = `"${r}"`), t.push(r + ":" + this.keyOf(s.value));
534
- }
535
- return `{${t.join(",")}}`;
536
- } else {
537
- if (e instanceof Et) return `import("${e.value.moduleName}", ${e.value.name})`;
538
- if (e instanceof st) return `read(${e.name})`;
539
- if (e instanceof mt) return `typeof(${this.keyOf(e.expr)})`;
540
- throw new Error(`${this.constructor.name} does not handle expressions of type ${e.constructor.name}`);
541
- }
542
- }
543
- });
544
- var o = "@angular/core", p = class {
545
- static NEW_METHOD = "factory";
546
- static TRANSFORM_METHOD = "transform";
547
- static PATCH_DEPS = "patchedDeps";
548
- static core = {
549
- name: null,
550
- moduleName: o
551
- };
552
- static namespaceHTML = {
553
- name: "ɵɵnamespaceHTML",
554
- moduleName: o
555
- };
556
- static namespaceMathML = {
557
- name: "ɵɵnamespaceMathML",
558
- moduleName: o
559
- };
560
- static namespaceSVG = {
561
- name: "ɵɵnamespaceSVG",
562
- moduleName: o
563
- };
564
- static element = {
565
- name: "ɵɵelement",
566
- moduleName: o
567
- };
568
- static elementStart = {
569
- name: "ɵɵelementStart",
570
- moduleName: o
571
- };
572
- static elementEnd = {
573
- name: "ɵɵelementEnd",
574
- moduleName: o
575
- };
576
- static advance = {
577
- name: "ɵɵadvance",
578
- moduleName: o
579
- };
580
- static syntheticHostProperty = {
581
- name: "ɵɵsyntheticHostProperty",
582
- moduleName: o
583
- };
584
- static syntheticHostListener = {
585
- name: "ɵɵsyntheticHostListener",
586
- moduleName: o
587
- };
588
- static attribute = {
589
- name: "ɵɵattribute",
590
- moduleName: o
591
- };
592
- static classProp = {
593
- name: "ɵɵclassProp",
594
- moduleName: o
595
- };
596
- static elementContainerStart = {
597
- name: "ɵɵelementContainerStart",
598
- moduleName: o
599
- };
600
- static elementContainerEnd = {
601
- name: "ɵɵelementContainerEnd",
602
- moduleName: o
603
- };
604
- static elementContainer = {
605
- name: "ɵɵelementContainer",
606
- moduleName: o
607
- };
608
- static styleMap = {
609
- name: "ɵɵstyleMap",
610
- moduleName: o
611
- };
612
- static classMap = {
613
- name: "ɵɵclassMap",
614
- moduleName: o
615
- };
616
- static styleProp = {
617
- name: "ɵɵstyleProp",
618
- moduleName: o
619
- };
620
- static interpolate = {
621
- name: "ɵɵinterpolate",
622
- moduleName: o
623
- };
624
- static interpolate1 = {
625
- name: "ɵɵinterpolate1",
626
- moduleName: o
627
- };
628
- static interpolate2 = {
629
- name: "ɵɵinterpolate2",
630
- moduleName: o
631
- };
632
- static interpolate3 = {
633
- name: "ɵɵinterpolate3",
634
- moduleName: o
635
- };
636
- static interpolate4 = {
637
- name: "ɵɵinterpolate4",
638
- moduleName: o
639
- };
640
- static interpolate5 = {
641
- name: "ɵɵinterpolate5",
642
- moduleName: o
643
- };
644
- static interpolate6 = {
645
- name: "ɵɵinterpolate6",
646
- moduleName: o
647
- };
648
- static interpolate7 = {
649
- name: "ɵɵinterpolate7",
650
- moduleName: o
651
- };
652
- static interpolate8 = {
653
- name: "ɵɵinterpolate8",
654
- moduleName: o
655
- };
656
- static interpolateV = {
657
- name: "ɵɵinterpolateV",
658
- moduleName: o
659
- };
660
- static nextContext = {
661
- name: "ɵɵnextContext",
662
- moduleName: o
663
- };
664
- static resetView = {
665
- name: "ɵɵresetView",
666
- moduleName: o
667
- };
668
- static templateCreate = {
669
- name: "ɵɵtemplate",
670
- moduleName: o
671
- };
672
- static defer = {
673
- name: "ɵɵdefer",
674
- moduleName: o
675
- };
676
- static deferWhen = {
677
- name: "ɵɵdeferWhen",
678
- moduleName: o
679
- };
680
- static deferOnIdle = {
681
- name: "ɵɵdeferOnIdle",
682
- moduleName: o
683
- };
684
- static deferOnImmediate = {
685
- name: "ɵɵdeferOnImmediate",
686
- moduleName: o
687
- };
688
- static deferOnTimer = {
689
- name: "ɵɵdeferOnTimer",
690
- moduleName: o
691
- };
692
- static deferOnHover = {
693
- name: "ɵɵdeferOnHover",
694
- moduleName: o
695
- };
696
- static deferOnInteraction = {
697
- name: "ɵɵdeferOnInteraction",
698
- moduleName: o
699
- };
700
- static deferOnViewport = {
701
- name: "ɵɵdeferOnViewport",
702
- moduleName: o
703
- };
704
- static deferPrefetchWhen = {
705
- name: "ɵɵdeferPrefetchWhen",
706
- moduleName: o
707
- };
708
- static deferPrefetchOnIdle = {
709
- name: "ɵɵdeferPrefetchOnIdle",
710
- moduleName: o
711
- };
712
- static deferPrefetchOnImmediate = {
713
- name: "ɵɵdeferPrefetchOnImmediate",
714
- moduleName: o
715
- };
716
- static deferPrefetchOnTimer = {
717
- name: "ɵɵdeferPrefetchOnTimer",
718
- moduleName: o
719
- };
720
- static deferPrefetchOnHover = {
721
- name: "ɵɵdeferPrefetchOnHover",
722
- moduleName: o
723
- };
724
- static deferPrefetchOnInteraction = {
725
- name: "ɵɵdeferPrefetchOnInteraction",
726
- moduleName: o
727
- };
728
- static deferPrefetchOnViewport = {
729
- name: "ɵɵdeferPrefetchOnViewport",
730
- moduleName: o
731
- };
732
- static deferHydrateWhen = {
733
- name: "ɵɵdeferHydrateWhen",
734
- moduleName: o
735
- };
736
- static deferHydrateNever = {
737
- name: "ɵɵdeferHydrateNever",
738
- moduleName: o
739
- };
740
- static deferHydrateOnIdle = {
741
- name: "ɵɵdeferHydrateOnIdle",
742
- moduleName: o
743
- };
744
- static deferHydrateOnImmediate = {
745
- name: "ɵɵdeferHydrateOnImmediate",
746
- moduleName: o
747
- };
748
- static deferHydrateOnTimer = {
749
- name: "ɵɵdeferHydrateOnTimer",
750
- moduleName: o
751
- };
752
- static deferHydrateOnHover = {
753
- name: "ɵɵdeferHydrateOnHover",
754
- moduleName: o
755
- };
756
- static deferHydrateOnInteraction = {
757
- name: "ɵɵdeferHydrateOnInteraction",
758
- moduleName: o
759
- };
760
- static deferHydrateOnViewport = {
761
- name: "ɵɵdeferHydrateOnViewport",
762
- moduleName: o
763
- };
764
- static deferEnableTimerScheduling = {
765
- name: "ɵɵdeferEnableTimerScheduling",
766
- moduleName: o
767
- };
768
- static conditionalCreate = {
769
- name: "ɵɵconditionalCreate",
770
- moduleName: o
771
- };
772
- static conditionalBranchCreate = {
773
- name: "ɵɵconditionalBranchCreate",
774
- moduleName: o
775
- };
776
- static conditional = {
777
- name: "ɵɵconditional",
778
- moduleName: o
779
- };
780
- static repeater = {
781
- name: "ɵɵrepeater",
782
- moduleName: o
783
- };
784
- static repeaterCreate = {
785
- name: "ɵɵrepeaterCreate",
786
- moduleName: o
787
- };
788
- static repeaterTrackByIndex = {
789
- name: "ɵɵrepeaterTrackByIndex",
790
- moduleName: o
791
- };
792
- static repeaterTrackByIdentity = {
793
- name: "ɵɵrepeaterTrackByIdentity",
794
- moduleName: o
795
- };
796
- static componentInstance = {
797
- name: "ɵɵcomponentInstance",
798
- moduleName: o
799
- };
800
- static text = {
801
- name: "ɵɵtext",
802
- moduleName: o
803
- };
804
- static enableBindings = {
805
- name: "ɵɵenableBindings",
806
- moduleName: o
807
- };
808
- static disableBindings = {
809
- name: "ɵɵdisableBindings",
810
- moduleName: o
811
- };
812
- static getCurrentView = {
813
- name: "ɵɵgetCurrentView",
814
- moduleName: o
815
- };
816
- static textInterpolate = {
817
- name: "ɵɵtextInterpolate",
818
- moduleName: o
819
- };
820
- static textInterpolate1 = {
821
- name: "ɵɵtextInterpolate1",
822
- moduleName: o
823
- };
824
- static textInterpolate2 = {
825
- name: "ɵɵtextInterpolate2",
826
- moduleName: o
827
- };
828
- static textInterpolate3 = {
829
- name: "ɵɵtextInterpolate3",
830
- moduleName: o
831
- };
832
- static textInterpolate4 = {
833
- name: "ɵɵtextInterpolate4",
834
- moduleName: o
835
- };
836
- static textInterpolate5 = {
837
- name: "ɵɵtextInterpolate5",
838
- moduleName: o
839
- };
840
- static textInterpolate6 = {
841
- name: "ɵɵtextInterpolate6",
842
- moduleName: o
843
- };
844
- static textInterpolate7 = {
845
- name: "ɵɵtextInterpolate7",
846
- moduleName: o
847
- };
848
- static textInterpolate8 = {
849
- name: "ɵɵtextInterpolate8",
850
- moduleName: o
851
- };
852
- static textInterpolateV = {
853
- name: "ɵɵtextInterpolateV",
854
- moduleName: o
855
- };
856
- static restoreView = {
857
- name: "ɵɵrestoreView",
858
- moduleName: o
859
- };
860
- static pureFunction0 = {
861
- name: "ɵɵpureFunction0",
862
- moduleName: o
863
- };
864
- static pureFunction1 = {
865
- name: "ɵɵpureFunction1",
866
- moduleName: o
867
- };
868
- static pureFunction2 = {
869
- name: "ɵɵpureFunction2",
870
- moduleName: o
871
- };
872
- static pureFunction3 = {
873
- name: "ɵɵpureFunction3",
874
- moduleName: o
875
- };
876
- static pureFunction4 = {
877
- name: "ɵɵpureFunction4",
878
- moduleName: o
879
- };
880
- static pureFunction5 = {
881
- name: "ɵɵpureFunction5",
882
- moduleName: o
883
- };
884
- static pureFunction6 = {
885
- name: "ɵɵpureFunction6",
886
- moduleName: o
887
- };
888
- static pureFunction7 = {
889
- name: "ɵɵpureFunction7",
890
- moduleName: o
891
- };
892
- static pureFunction8 = {
893
- name: "ɵɵpureFunction8",
894
- moduleName: o
895
- };
896
- static pureFunctionV = {
897
- name: "ɵɵpureFunctionV",
898
- moduleName: o
899
- };
900
- static pipeBind1 = {
901
- name: "ɵɵpipeBind1",
902
- moduleName: o
903
- };
904
- static pipeBind2 = {
905
- name: "ɵɵpipeBind2",
906
- moduleName: o
907
- };
908
- static pipeBind3 = {
909
- name: "ɵɵpipeBind3",
910
- moduleName: o
911
- };
912
- static pipeBind4 = {
913
- name: "ɵɵpipeBind4",
914
- moduleName: o
915
- };
916
- static pipeBindV = {
917
- name: "ɵɵpipeBindV",
918
- moduleName: o
919
- };
920
- static domProperty = {
921
- name: "ɵɵdomProperty",
922
- moduleName: o
923
- };
924
- static property = {
925
- name: "ɵɵproperty",
926
- moduleName: o
927
- };
928
- static i18n = {
929
- name: "ɵɵi18n",
930
- moduleName: o
931
- };
932
- static i18nAttributes = {
933
- name: "ɵɵi18nAttributes",
934
- moduleName: o
935
- };
936
- static i18nExp = {
937
- name: "ɵɵi18nExp",
938
- moduleName: o
939
- };
940
- static i18nStart = {
941
- name: "ɵɵi18nStart",
942
- moduleName: o
943
- };
944
- static i18nEnd = {
945
- name: "ɵɵi18nEnd",
946
- moduleName: o
947
- };
948
- static i18nApply = {
949
- name: "ɵɵi18nApply",
950
- moduleName: o
951
- };
952
- static i18nPostprocess = {
953
- name: "ɵɵi18nPostprocess",
954
- moduleName: o
955
- };
956
- static pipe = {
957
- name: "ɵɵpipe",
958
- moduleName: o
959
- };
960
- static projection = {
961
- name: "ɵɵprojection",
962
- moduleName: o
963
- };
964
- static projectionDef = {
965
- name: "ɵɵprojectionDef",
966
- moduleName: o
967
- };
968
- static reference = {
969
- name: "ɵɵreference",
970
- moduleName: o
971
- };
972
- static inject = {
973
- name: "ɵɵinject",
974
- moduleName: o
975
- };
976
- static injectAttribute = {
977
- name: "ɵɵinjectAttribute",
978
- moduleName: o
979
- };
980
- static directiveInject = {
981
- name: "ɵɵdirectiveInject",
982
- moduleName: o
983
- };
984
- static invalidFactory = {
985
- name: "ɵɵinvalidFactory",
986
- moduleName: o
987
- };
988
- static invalidFactoryDep = {
989
- name: "ɵɵinvalidFactoryDep",
990
- moduleName: o
991
- };
992
- static templateRefExtractor = {
993
- name: "ɵɵtemplateRefExtractor",
994
- moduleName: o
995
- };
996
- static forwardRef = {
997
- name: "forwardRef",
998
- moduleName: o
999
- };
1000
- static resolveForwardRef = {
1001
- name: "resolveForwardRef",
1002
- moduleName: o
1003
- };
1004
- static replaceMetadata = {
1005
- name: "ɵɵreplaceMetadata",
1006
- moduleName: o
1007
- };
1008
- static getReplaceMetadataURL = {
1009
- name: "ɵɵgetReplaceMetadataURL",
1010
- moduleName: o
1011
- };
1012
- static ɵɵdefineInjectable = {
1013
- name: "ɵɵdefineInjectable",
1014
- moduleName: o
1015
- };
1016
- static declareInjectable = {
1017
- name: "ɵɵngDeclareInjectable",
1018
- moduleName: o
1019
- };
1020
- static InjectableDeclaration = {
1021
- name: "ɵɵInjectableDeclaration",
1022
- moduleName: o
1023
- };
1024
- static resolveWindow = {
1025
- name: "ɵɵresolveWindow",
1026
- moduleName: o
1027
- };
1028
- static resolveDocument = {
1029
- name: "ɵɵresolveDocument",
1030
- moduleName: o
1031
- };
1032
- static resolveBody = {
1033
- name: "ɵɵresolveBody",
1034
- moduleName: o
1035
- };
1036
- static getComponentDepsFactory = {
1037
- name: "ɵɵgetComponentDepsFactory",
1038
- moduleName: o
1039
- };
1040
- static defineComponent = {
1041
- name: "ɵɵdefineComponent",
1042
- moduleName: o
1043
- };
1044
- static declareComponent = {
1045
- name: "ɵɵngDeclareComponent",
1046
- moduleName: o
1047
- };
1048
- static setComponentScope = {
1049
- name: "ɵɵsetComponentScope",
1050
- moduleName: o
1051
- };
1052
- static ChangeDetectionStrategy = {
1053
- name: "ChangeDetectionStrategy",
1054
- moduleName: o
1055
- };
1056
- static ViewEncapsulation = {
1057
- name: "ViewEncapsulation",
1058
- moduleName: o
1059
- };
1060
- static ComponentDeclaration = {
1061
- name: "ɵɵComponentDeclaration",
1062
- moduleName: o
1063
- };
1064
- static FactoryDeclaration = {
1065
- name: "ɵɵFactoryDeclaration",
1066
- moduleName: o
1067
- };
1068
- static declareFactory = {
1069
- name: "ɵɵngDeclareFactory",
1070
- moduleName: o
1071
- };
1072
- static FactoryTarget = {
1073
- name: "ɵɵFactoryTarget",
1074
- moduleName: o
1075
- };
1076
- static defineDirective = {
1077
- name: "ɵɵdefineDirective",
1078
- moduleName: o
1079
- };
1080
- static declareDirective = {
1081
- name: "ɵɵngDeclareDirective",
1082
- moduleName: o
1083
- };
1084
- static DirectiveDeclaration = {
1085
- name: "ɵɵDirectiveDeclaration",
1086
- moduleName: o
1087
- };
1088
- static InjectorDef = {
1089
- name: "ɵɵInjectorDef",
1090
- moduleName: o
1091
- };
1092
- static InjectorDeclaration = {
1093
- name: "ɵɵInjectorDeclaration",
1094
- moduleName: o
1095
- };
1096
- static defineInjector = {
1097
- name: "ɵɵdefineInjector",
1098
- moduleName: o
1099
- };
1100
- static declareInjector = {
1101
- name: "ɵɵngDeclareInjector",
1102
- moduleName: o
1103
- };
1104
- static NgModuleDeclaration = {
1105
- name: "ɵɵNgModuleDeclaration",
1106
- moduleName: o
1107
- };
1108
- static ModuleWithProviders = {
1109
- name: "ModuleWithProviders",
1110
- moduleName: o
1111
- };
1112
- static defineNgModule = {
1113
- name: "ɵɵdefineNgModule",
1114
- moduleName: o
1115
- };
1116
- static declareNgModule = {
1117
- name: "ɵɵngDeclareNgModule",
1118
- moduleName: o
1119
- };
1120
- static setNgModuleScope = {
1121
- name: "ɵɵsetNgModuleScope",
1122
- moduleName: o
1123
- };
1124
- static registerNgModuleType = {
1125
- name: "ɵɵregisterNgModuleType",
1126
- moduleName: o
1127
- };
1128
- static PipeDeclaration = {
1129
- name: "ɵɵPipeDeclaration",
1130
- moduleName: o
1131
- };
1132
- static definePipe = {
1133
- name: "ɵɵdefinePipe",
1134
- moduleName: o
1135
- };
1136
- static declarePipe = {
1137
- name: "ɵɵngDeclarePipe",
1138
- moduleName: o
1139
- };
1140
- static declareClassMetadata = {
1141
- name: "ɵɵngDeclareClassMetadata",
1142
- moduleName: o
1143
- };
1144
- static declareClassMetadataAsync = {
1145
- name: "ɵɵngDeclareClassMetadataAsync",
1146
- moduleName: o
1147
- };
1148
- static setClassMetadata = {
1149
- name: "ɵsetClassMetadata",
1150
- moduleName: o
1151
- };
1152
- static setClassMetadataAsync = {
1153
- name: "ɵsetClassMetadataAsync",
1154
- moduleName: o
1155
- };
1156
- static setClassDebugInfo = {
1157
- name: "ɵsetClassDebugInfo",
1158
- moduleName: o
1159
- };
1160
- static queryRefresh = {
1161
- name: "ɵɵqueryRefresh",
1162
- moduleName: o
1163
- };
1164
- static viewQuery = {
1165
- name: "ɵɵviewQuery",
1166
- moduleName: o
1167
- };
1168
- static loadQuery = {
1169
- name: "ɵɵloadQuery",
1170
- moduleName: o
1171
- };
1172
- static contentQuery = {
1173
- name: "ɵɵcontentQuery",
1174
- moduleName: o
1175
- };
1176
- static viewQuerySignal = {
1177
- name: "ɵɵviewQuerySignal",
1178
- moduleName: o
1179
- };
1180
- static contentQuerySignal = {
1181
- name: "ɵɵcontentQuerySignal",
1182
- moduleName: o
1183
- };
1184
- static queryAdvance = {
1185
- name: "ɵɵqueryAdvance",
1186
- moduleName: o
1187
- };
1188
- static twoWayProperty = {
1189
- name: "ɵɵtwoWayProperty",
1190
- moduleName: o
1191
- };
1192
- static twoWayBindingSet = {
1193
- name: "ɵɵtwoWayBindingSet",
1194
- moduleName: o
1195
- };
1196
- static twoWayListener = {
1197
- name: "ɵɵtwoWayListener",
1198
- moduleName: o
1199
- };
1200
- static declareLet = {
1201
- name: "ɵɵdeclareLet",
1202
- moduleName: o
1203
- };
1204
- static storeLet = {
1205
- name: "ɵɵstoreLet",
1206
- moduleName: o
1207
- };
1208
- static readContextLet = {
1209
- name: "ɵɵreadContextLet",
1210
- moduleName: o
1211
- };
1212
- static attachSourceLocations = {
1213
- name: "ɵɵattachSourceLocations",
1214
- moduleName: o
1215
- };
1216
- static NgOnChangesFeature = {
1217
- name: "ɵɵNgOnChangesFeature",
1218
- moduleName: o
1219
- };
1220
- static InheritDefinitionFeature = {
1221
- name: "ɵɵInheritDefinitionFeature",
1222
- moduleName: o
1223
- };
1224
- static CopyDefinitionFeature = {
1225
- name: "ɵɵCopyDefinitionFeature",
1226
- moduleName: o
1227
- };
1228
- static ProvidersFeature = {
1229
- name: "ɵɵProvidersFeature",
1230
- moduleName: o
1231
- };
1232
- static HostDirectivesFeature = {
1233
- name: "ɵɵHostDirectivesFeature",
1234
- moduleName: o
1235
- };
1236
- static ExternalStylesFeature = {
1237
- name: "ɵɵExternalStylesFeature",
1238
- moduleName: o
1239
- };
1240
- static listener = {
1241
- name: "ɵɵlistener",
1242
- moduleName: o
1243
- };
1244
- static getInheritedFactory = {
1245
- name: "ɵɵgetInheritedFactory",
1246
- moduleName: o
1247
- };
1248
- static sanitizeHtml = {
1249
- name: "ɵɵsanitizeHtml",
1250
- moduleName: o
1251
- };
1252
- static sanitizeStyle = {
1253
- name: "ɵɵsanitizeStyle",
1254
- moduleName: o
1255
- };
1256
- static sanitizeResourceUrl = {
1257
- name: "ɵɵsanitizeResourceUrl",
1258
- moduleName: o
1259
- };
1260
- static sanitizeScript = {
1261
- name: "ɵɵsanitizeScript",
1262
- moduleName: o
1263
- };
1264
- static sanitizeUrl = {
1265
- name: "ɵɵsanitizeUrl",
1266
- moduleName: o
1267
- };
1268
- static sanitizeUrlOrResourceUrl = {
1269
- name: "ɵɵsanitizeUrlOrResourceUrl",
1270
- moduleName: o
1271
- };
1272
- static trustConstantHtml = {
1273
- name: "ɵɵtrustConstantHtml",
1274
- moduleName: o
1275
- };
1276
- static trustConstantResourceUrl = {
1277
- name: "ɵɵtrustConstantResourceUrl",
1278
- moduleName: o
1279
- };
1280
- static validateIframeAttribute = {
1281
- name: "ɵɵvalidateIframeAttribute",
1282
- moduleName: o
1283
- };
1284
- static InputSignalBrandWriteType = {
1285
- name: "ɵINPUT_SIGNAL_BRAND_WRITE_TYPE",
1286
- moduleName: o
1287
- };
1288
- static UnwrapDirectiveSignalInputs = {
1289
- name: "ɵUnwrapDirectiveSignalInputs",
1290
- moduleName: o
1291
- };
1292
- static unwrapWritableSignal = {
1293
- name: "ɵunwrapWritableSignal",
1294
- moduleName: o
1295
- };
1296
- };
1297
- var Nt = class {
1298
- full;
1299
- major;
1300
- minor;
1301
- patch;
1302
- constructor(e) {
1303
- this.full = e;
1304
- let t = e.split(".");
1305
- this.major = t[0], this.minor = t[1], this.patch = t.slice(2).join(".");
1306
- }
1307
- };
1308
- var gn;
1309
- (function(n) {
1310
- n[n.Class = 0] = "Class", n[n.Function = 1] = "Function";
1311
- })(gn || (gn = {}));
1312
- var Pe = class {
1313
- input;
1314
- errLocation;
1315
- ctxLocation;
1316
- message;
1317
- constructor(e, t, s, r) {
1318
- this.input = t, this.errLocation = s, this.ctxLocation = r, this.message = `Parser Error: ${e} ${s} [${t}] in ${r}`;
1319
- }
1320
- }, J = class {
1321
- start;
1322
- end;
1323
- constructor(e, t) {
1324
- this.start = e, this.end = t;
1325
- }
1326
- toAbsolute(e) {
1327
- return new O(e + this.start, e + this.end);
1328
- }
1329
- }, S = class {
1330
- span;
1331
- sourceSpan;
1332
- constructor(e, t) {
1333
- this.span = e, this.sourceSpan = t;
1334
- }
1335
- toString() {
1336
- return "AST";
1337
- }
1338
- }, ae = class extends S {
1339
- nameSpan;
1340
- constructor(e, t, s) {
1341
- super(e, t), this.nameSpan = s;
1342
- }
1343
- }, P = class extends S {
1344
- visit(e, t = null) {}
1345
- }, Y = class extends S {
1346
- visit(e, t = null) {
1347
- return e.visitImplicitReceiver(this, t);
1348
- }
1349
- }, At = class extends Y {
1350
- visit(e, t = null) {
1351
- var s;
1352
- return (s = e.visitThisReceiver) == null ? void 0 : s.call(e, this, t);
1353
- }
1354
- }, Le = class extends S {
1355
- expressions;
1356
- constructor(e, t, s) {
1357
- super(e, t), this.expressions = s;
1358
- }
1359
- visit(e, t = null) {
1360
- return e.visitChain(this, t);
1361
- }
1362
- }, Me = class extends S {
1363
- condition;
1364
- trueExp;
1365
- falseExp;
1366
- constructor(e, t, s, r, i) {
1367
- super(e, t), this.condition = s, this.trueExp = r, this.falseExp = i;
1368
- }
1369
- visit(e, t = null) {
1370
- return e.visitConditional(this, t);
1371
- }
1372
- }, le = class extends ae {
1373
- receiver;
1374
- name;
1375
- constructor(e, t, s, r, i) {
1376
- super(e, t, s), this.receiver = r, this.name = i;
1377
- }
1378
- visit(e, t = null) {
1379
- return e.visitPropertyRead(this, t);
1380
- }
1381
- }, $e = class extends ae {
1382
- receiver;
1383
- name;
1384
- value;
1385
- constructor(e, t, s, r, i, a) {
1386
- super(e, t, s), this.receiver = r, this.name = i, this.value = a;
1387
- }
1388
- visit(e, t = null) {
1389
- return e.visitPropertyWrite(this, t);
1390
- }
1391
- }, ce = class extends ae {
1392
- receiver;
1393
- name;
1394
- constructor(e, t, s, r, i) {
1395
- super(e, t, s), this.receiver = r, this.name = i;
1396
- }
1397
- visit(e, t = null) {
1398
- return e.visitSafePropertyRead(this, t);
1399
- }
1400
- }, Re = class extends S {
1401
- receiver;
1402
- key;
1403
- constructor(e, t, s, r) {
1404
- super(e, t), this.receiver = s, this.key = r;
1405
- }
1406
- visit(e, t = null) {
1407
- return e.visitKeyedRead(this, t);
1408
- }
1409
- }, ue = class extends S {
1410
- receiver;
1411
- key;
1412
- constructor(e, t, s, r) {
1413
- super(e, t), this.receiver = s, this.key = r;
1414
- }
1415
- visit(e, t = null) {
1416
- return e.visitSafeKeyedRead(this, t);
1417
- }
1418
- }, De = class extends S {
1419
- receiver;
1420
- key;
1421
- value;
1422
- constructor(e, t, s, r, i) {
1423
- super(e, t), this.receiver = s, this.key = r, this.value = i;
1424
- }
1425
- visit(e, t = null) {
1426
- return e.visitKeyedWrite(this, t);
1427
- }
1428
- }, Be = class extends ae {
1429
- exp;
1430
- name;
1431
- args;
1432
- constructor(e, t, s, r, i, a) {
1433
- super(e, t, a), this.exp = s, this.name = r, this.args = i;
1434
- }
1435
- visit(e, t = null) {
1436
- return e.visitPipe(this, t);
1437
- }
1438
- }, I = class extends S {
1439
- value;
1440
- constructor(e, t, s) {
1441
- super(e, t), this.value = s;
1442
- }
1443
- visit(e, t = null) {
1444
- return e.visitLiteralPrimitive(this, t);
1445
- }
1446
- }, Oe = class extends S {
1447
- expressions;
1448
- constructor(e, t, s) {
1449
- super(e, t), this.expressions = s;
1450
- }
1451
- visit(e, t = null) {
1452
- return e.visitLiteralArray(this, t);
1453
- }
1454
- }, Fe = class extends S {
1455
- keys;
1456
- values;
1457
- constructor(e, t, s, r) {
1458
- super(e, t), this.keys = s, this.values = r;
1459
- }
1460
- visit(e, t = null) {
1461
- return e.visitLiteralMap(this, t);
1462
- }
1463
- }, Vt = class extends S {
1464
- strings;
1465
- expressions;
1466
- constructor(e, t, s, r) {
1467
- super(e, t), this.strings = s, this.expressions = r;
1468
- }
1469
- visit(e, t = null) {
1470
- return e.visitInterpolation(this, t);
1471
- }
1472
- }, A = class extends S {
1473
- operation;
1474
- left;
1475
- right;
1476
- constructor(e, t, s, r, i) {
1477
- super(e, t), this.operation = s, this.left = r, this.right = i;
1478
- }
1479
- visit(e, t = null) {
1480
- return e.visitBinary(this, t);
1481
- }
1482
- }, X = class n extends A {
1483
- operator;
1484
- expr;
1485
- left = null;
1486
- right = null;
1487
- operation = null;
1488
- static createMinus(e, t, s) {
1489
- return new n(e, t, "-", s, "-", new I(e, t, 0), s);
1490
- }
1491
- static createPlus(e, t, s) {
1492
- return new n(e, t, "+", s, "-", s, new I(e, t, 0));
1493
- }
1494
- constructor(e, t, s, r, i, a, l) {
1495
- super(e, t, i, a, l), this.operator = s, this.expr = r;
1496
- }
1497
- visit(e, t = null) {
1498
- return e.visitUnary !== void 0 ? e.visitUnary(this, t) : e.visitBinary(this, t);
1499
- }
1500
- }, Q = class extends S {
1501
- expression;
1502
- constructor(e, t, s) {
1503
- super(e, t), this.expression = s;
1504
- }
1505
- visit(e, t = null) {
1506
- return e.visitPrefixNot(this, t);
1507
- }
1508
- }, K = class extends S {
1509
- expression;
1510
- constructor(e, t, s) {
1511
- super(e, t), this.expression = s;
1512
- }
1513
- visit(e, t = null) {
1514
- return e.visitTypeofExpression(this, t);
1515
- }
1516
- }, Z = class extends S {
1517
- expression;
1518
- constructor(e, t, s) {
1519
- super(e, t), this.expression = s;
1520
- }
1521
- visit(e, t = null) {
1522
- return e.visitVoidExpression(this, t);
1523
- }
1524
- }, Ve = class extends S {
1525
- expression;
1526
- constructor(e, t, s) {
1527
- super(e, t), this.expression = s;
1528
- }
1529
- visit(e, t = null) {
1530
- return e.visitNonNullAssert(this, t);
1531
- }
1532
- }, Ue = class extends S {
1533
- receiver;
1534
- args;
1535
- argumentSpan;
1536
- constructor(e, t, s, r, i) {
1537
- super(e, t), this.receiver = s, this.args = r, this.argumentSpan = i;
1538
- }
1539
- visit(e, t = null) {
1540
- return e.visitCall(this, t);
1541
- }
1542
- }, pe = class extends S {
1543
- receiver;
1544
- args;
1545
- argumentSpan;
1546
- constructor(e, t, s, r, i) {
1547
- super(e, t), this.receiver = s, this.args = r, this.argumentSpan = i;
1548
- }
1549
- visit(e, t = null) {
1550
- return e.visitSafeCall(this, t);
1551
- }
1552
- }, he = class extends S {
1553
- tag;
1554
- template;
1555
- constructor(e, t, s, r) {
1556
- super(e, t), this.tag = s, this.template = r;
1557
- }
1558
- visit(e, t) {
1559
- return e.visitTaggedTemplateLiteral(this, t);
1560
- }
1561
- }, fe = class extends S {
1562
- elements;
1563
- expressions;
1564
- constructor(e, t, s, r) {
1565
- super(e, t), this.elements = s, this.expressions = r;
1566
- }
1567
- visit(e, t) {
1568
- return e.visitTemplateLiteral(this, t);
1569
- }
1570
- }, de = class extends S {
1571
- text;
1572
- constructor(e, t, s) {
1573
- super(e, t), this.text = s;
1574
- }
1575
- visit(e, t) {
1576
- return e.visitTemplateLiteralElement(this, t);
1577
- }
1578
- }, He = class extends S {
1579
- expression;
1580
- constructor(e, t, s) {
1581
- super(e, t), this.expression = s;
1582
- }
1583
- visit(e, t) {
1584
- return e.visitParenthesizedExpression(this, t);
1585
- }
1586
- }, O = class {
1587
- start;
1588
- end;
1589
- constructor(e, t) {
1590
- this.start = e, this.end = t;
1591
- }
1592
- }, W = class extends S {
1593
- ast;
1594
- source;
1595
- location;
1596
- errors;
1597
- constructor(e, t, s, r, i) {
1598
- super(new J(0, t === null ? 0 : t.length), new O(r, t === null ? r : r + t.length)), this.ast = e, this.source = t, this.location = s, this.errors = i;
1599
- }
1600
- visit(e, t = null) {
1601
- return e.visitASTWithSource ? e.visitASTWithSource(this, t) : this.ast.visit(e, t);
1602
- }
1603
- toString() {
1604
- return `${this.source} in ${this.location}`;
1605
- }
1606
- }, me = class {
1607
- sourceSpan;
1608
- key;
1609
- value;
1610
- constructor(e, t, s) {
1611
- this.sourceSpan = e, this.key = t, this.value = s;
1612
- }
1613
- }, We = class {
1614
- sourceSpan;
1615
- key;
1616
- value;
1617
- constructor(e, t, s) {
1618
- this.sourceSpan = e, this.key = t, this.value = s;
1619
- }
1620
- }, Pt = class {
1621
- visit(e, t) {
1622
- e.visit(this, t);
1623
- }
1624
- visitUnary(e, t) {
1625
- this.visit(e.expr, t);
1626
- }
1627
- visitBinary(e, t) {
1628
- this.visit(e.left, t), this.visit(e.right, t);
1629
- }
1630
- visitChain(e, t) {
1631
- this.visitAll(e.expressions, t);
1632
- }
1633
- visitConditional(e, t) {
1634
- this.visit(e.condition, t), this.visit(e.trueExp, t), this.visit(e.falseExp, t);
1635
- }
1636
- visitPipe(e, t) {
1637
- this.visit(e.exp, t), this.visitAll(e.args, t);
1638
- }
1639
- visitImplicitReceiver(e, t) {}
1640
- visitThisReceiver(e, t) {}
1641
- visitInterpolation(e, t) {
1642
- this.visitAll(e.expressions, t);
1643
- }
1644
- visitKeyedRead(e, t) {
1645
- this.visit(e.receiver, t), this.visit(e.key, t);
1646
- }
1647
- visitKeyedWrite(e, t) {
1648
- this.visit(e.receiver, t), this.visit(e.key, t), this.visit(e.value, t);
1649
- }
1650
- visitLiteralArray(e, t) {
1651
- this.visitAll(e.expressions, t);
1652
- }
1653
- visitLiteralMap(e, t) {
1654
- this.visitAll(e.values, t);
1655
- }
1656
- visitLiteralPrimitive(e, t) {}
1657
- visitPrefixNot(e, t) {
1658
- this.visit(e.expression, t);
1659
- }
1660
- visitTypeofExpression(e, t) {
1661
- this.visit(e.expression, t);
1662
- }
1663
- visitVoidExpression(e, t) {
1664
- this.visit(e.expression, t);
1665
- }
1666
- visitNonNullAssert(e, t) {
1667
- this.visit(e.expression, t);
1668
- }
1669
- visitPropertyRead(e, t) {
1670
- this.visit(e.receiver, t);
1671
- }
1672
- visitPropertyWrite(e, t) {
1673
- this.visit(e.receiver, t), this.visit(e.value, t);
1674
- }
1675
- visitSafePropertyRead(e, t) {
1676
- this.visit(e.receiver, t);
1677
- }
1678
- visitSafeKeyedRead(e, t) {
1679
- this.visit(e.receiver, t), this.visit(e.key, t);
1680
- }
1681
- visitCall(e, t) {
1682
- this.visit(e.receiver, t), this.visitAll(e.args, t);
1683
- }
1684
- visitSafeCall(e, t) {
1685
- this.visit(e.receiver, t), this.visitAll(e.args, t);
1686
- }
1687
- visitTemplateLiteral(e, t) {
1688
- for (let s = 0; s < e.elements.length; s++) {
1689
- this.visit(e.elements[s], t);
1690
- let r = s < e.expressions.length ? e.expressions[s] : null;
1691
- r !== null && this.visit(r, t);
1692
- }
1693
- }
1694
- visitTemplateLiteralElement(e, t) {}
1695
- visitTaggedTemplateLiteral(e, t) {
1696
- this.visit(e.tag, t), this.visit(e.template, t);
1697
- }
1698
- visitParenthesizedExpression(e, t) {
1699
- this.visit(e.expression, t);
1700
- }
1701
- visitAll(e, t) {
1702
- for (let s of e) this.visit(s, t);
1703
- }
1704
- };
1705
- var vn;
1706
- (function(n) {
1707
- n[n.DEFAULT = 0] = "DEFAULT", n[n.LITERAL_ATTR = 1] = "LITERAL_ATTR", n[n.ANIMATION = 2] = "ANIMATION", n[n.TWO_WAY = 3] = "TWO_WAY";
1708
- })(vn || (vn = {}));
1709
- var wn;
1710
- (function(n) {
1711
- n[n.Regular = 0] = "Regular", n[n.Animation = 1] = "Animation", n[n.TwoWay = 2] = "TwoWay";
1712
- })(wn || (wn = {}));
1713
- var U;
1714
- (function(n) {
1715
- n[n.Property = 0] = "Property", n[n.Attribute = 1] = "Attribute", n[n.Class = 2] = "Class", n[n.Style = 3] = "Style", n[n.Animation = 4] = "Animation", n[n.TwoWay = 5] = "TwoWay";
1716
- })(U || (U = {}));
1717
- var xn;
1718
- (function(n) {
1719
- n[n.RAW_TEXT = 0] = "RAW_TEXT", n[n.ESCAPABLE_RAW_TEXT = 1] = "ESCAPABLE_RAW_TEXT", n[n.PARSABLE_DATA = 2] = "PARSABLE_DATA";
1720
- })(xn || (xn = {}));
1721
- var Js = [
1722
- /@/,
1723
- /^\s*$/,
1724
- /[<>]/,
1725
- /^[{}]$/,
1726
- /&(#|[a-z])/i,
1727
- /^\/\//
1728
- ];
1729
- function Ys(n, e) {
1730
- if (e != null && !(Array.isArray(e) && e.length == 2)) throw new Error(`Expected '${n}' to be an array, [start, end].`);
1731
- if (e != null) {
1732
- let t = e[0], s = e[1];
1733
- Js.forEach((r) => {
1734
- if (r.test(t) || r.test(s)) throw new Error(`['${t}', '${s}'] contains unusable interpolation symbol.`);
1735
- });
1736
- }
1737
- }
1738
- var ne = new class n {
1739
- start;
1740
- end;
1741
- static fromArray(e) {
1742
- return e ? (Ys("interpolation", e), new n(e[0], e[1])) : ne;
1743
- }
1744
- constructor(e, t) {
1745
- this.start = e, this.end = t;
1746
- }
1747
- }("{{", "}}");
1748
- var Qe = 0;
1749
- var Kn = 9, Qs = 10, Ks = 11, Zs = 12, er = 13, Zn = 32, tr = 33, es = 34, nr = 35, Ut = 36, sr = 37, Sn = 38, ts = 39, tt = 40, se = 41, En = 42, ns = 43, Ce = 44, ss = 45, re = 46, Mt = 47, ie = 58, Te = 59, rr = 60, Ke = 61, ir = 62, yn = 63, or = 48;
1750
- var ar = 57, rs = 65, lr = 69;
1751
- var is = 90, nt = 91, _n = 92, ke = 93, cr = 94, Ht = 95, os = 97;
1752
- var ur = 101, pr = 102, hr = 110, fr = 114, dr = 116, mr = 117, gr = 118;
1753
- var as = 122, ot = 123, Cn = 124, be = 125, ls = 160;
1754
- var $t = 96;
1755
- function vr(n) {
1756
- return n >= Kn && n <= Zn || n == ls;
1757
- }
1758
- function z(n) {
1759
- return or <= n && n <= ar;
1760
- }
1761
- function wr(n) {
1762
- return n >= os && n <= as || n >= rs && n <= is;
1763
- }
1764
- function Tn(n) {
1765
- return n === ts || n === es || n === $t;
1766
- }
1767
- var kn;
1768
- (function(n) {
1769
- n[n.WARNING = 0] = "WARNING", n[n.ERROR = 1] = "ERROR";
1770
- })(kn || (kn = {}));
1771
- var bn;
1772
- (function(n) {
1773
- n[n.Inline = 0] = "Inline", n[n.SideEffect = 1] = "SideEffect", n[n.Omit = 2] = "Omit";
1774
- })(bn || (bn = {}));
1775
- var In;
1776
- (function(n) {
1777
- n[n.Global = 0] = "Global", n[n.Local = 1] = "Local";
1778
- })(In || (In = {}));
1779
- var Nn;
1780
- (function(n) {
1781
- n[n.Directive = 0] = "Directive", n[n.Pipe = 1] = "Pipe", n[n.NgModule = 2] = "NgModule";
1782
- })(Nn || (Nn = {}));
1783
- var xr = "(:(where|is)\\()?", cs = "-shadowcsshost", Sr = "-shadowcsscontext", us = "(?:\\(((?:\\([^)(]*\\)|[^)(]*)+?)\\))";
1784
- new RegExp(cs + us + "?([^,{]*)", "gim");
1785
- var ps = Sr + us + "?([^{]*)";
1786
- new RegExp(`${xr}(${ps})`, "gim");
1787
- var Er = cs + "-no-combinator";
1788
- new RegExp(`${Er}(?![^(]*\\))`, "g");
1789
- new RegExp(`(\\s*(?:%COMMENT%\\s*)*)([^;\\{\\}]+?)(\\s*)((?:{%BLOCK%}?\\s*;?)|(?:\\s*;))`, "g");
1790
- var d;
1791
- (function(n) {
1792
- n[n.ListEnd = 0] = "ListEnd", n[n.Statement = 1] = "Statement", n[n.Variable = 2] = "Variable", n[n.ElementStart = 3] = "ElementStart", n[n.Element = 4] = "Element", n[n.Template = 5] = "Template", n[n.ElementEnd = 6] = "ElementEnd", n[n.ContainerStart = 7] = "ContainerStart", n[n.Container = 8] = "Container", n[n.ContainerEnd = 9] = "ContainerEnd", n[n.DisableBindings = 10] = "DisableBindings", n[n.ConditionalCreate = 11] = "ConditionalCreate", n[n.ConditionalBranchCreate = 12] = "ConditionalBranchCreate", n[n.Conditional = 13] = "Conditional", n[n.EnableBindings = 14] = "EnableBindings", n[n.Text = 15] = "Text", n[n.Listener = 16] = "Listener", n[n.InterpolateText = 17] = "InterpolateText", n[n.Binding = 18] = "Binding", n[n.Property = 19] = "Property", n[n.StyleProp = 20] = "StyleProp", n[n.ClassProp = 21] = "ClassProp", n[n.StyleMap = 22] = "StyleMap", n[n.ClassMap = 23] = "ClassMap", n[n.Advance = 24] = "Advance", n[n.Pipe = 25] = "Pipe", n[n.Attribute = 26] = "Attribute", n[n.ExtractedAttribute = 27] = "ExtractedAttribute", n[n.Defer = 28] = "Defer", n[n.DeferOn = 29] = "DeferOn", n[n.DeferWhen = 30] = "DeferWhen", n[n.I18nMessage = 31] = "I18nMessage", n[n.DomProperty = 32] = "DomProperty", n[n.Namespace = 33] = "Namespace", n[n.ProjectionDef = 34] = "ProjectionDef", n[n.Projection = 35] = "Projection", n[n.RepeaterCreate = 36] = "RepeaterCreate", n[n.Repeater = 37] = "Repeater", n[n.TwoWayProperty = 38] = "TwoWayProperty", n[n.TwoWayListener = 39] = "TwoWayListener", n[n.DeclareLet = 40] = "DeclareLet", n[n.StoreLet = 41] = "StoreLet", n[n.I18nStart = 42] = "I18nStart", n[n.I18n = 43] = "I18n", n[n.I18nEnd = 44] = "I18nEnd", n[n.I18nExpression = 45] = "I18nExpression", n[n.I18nApply = 46] = "I18nApply", n[n.IcuStart = 47] = "IcuStart", n[n.IcuEnd = 48] = "IcuEnd", n[n.IcuPlaceholder = 49] = "IcuPlaceholder", n[n.I18nContext = 50] = "I18nContext", n[n.I18nAttributes = 51] = "I18nAttributes", n[n.SourceLocation = 52] = "SourceLocation";
1793
- })(d || (d = {}));
1794
- var ge;
1795
- (function(n) {
1796
- n[n.LexicalRead = 0] = "LexicalRead", n[n.Context = 1] = "Context", n[n.TrackContext = 2] = "TrackContext", n[n.ReadVariable = 3] = "ReadVariable", n[n.NextContext = 4] = "NextContext", n[n.Reference = 5] = "Reference", n[n.StoreLet = 6] = "StoreLet", n[n.ContextLetReference = 7] = "ContextLetReference", n[n.GetCurrentView = 8] = "GetCurrentView", n[n.RestoreView = 9] = "RestoreView", n[n.ResetView = 10] = "ResetView", n[n.PureFunctionExpr = 11] = "PureFunctionExpr", n[n.PureFunctionParameterExpr = 12] = "PureFunctionParameterExpr", n[n.PipeBinding = 13] = "PipeBinding", n[n.PipeBindingVariadic = 14] = "PipeBindingVariadic", n[n.SafePropertyRead = 15] = "SafePropertyRead", n[n.SafeKeyedRead = 16] = "SafeKeyedRead", n[n.SafeInvokeFunction = 17] = "SafeInvokeFunction", n[n.SafeTernaryExpr = 18] = "SafeTernaryExpr", n[n.EmptyExpr = 19] = "EmptyExpr", n[n.AssignTemporaryExpr = 20] = "AssignTemporaryExpr", n[n.ReadTemporaryExpr = 21] = "ReadTemporaryExpr", n[n.SlotLiteralExpr = 22] = "SlotLiteralExpr", n[n.ConditionalCase = 23] = "ConditionalCase", n[n.ConstCollected = 24] = "ConstCollected", n[n.TwoWayBindingSet = 25] = "TwoWayBindingSet";
1797
- })(ge || (ge = {}));
1798
- var An;
1799
- (function(n) {
1800
- n[n.None = 0] = "None", n[n.AlwaysInline = 1] = "AlwaysInline";
1801
- })(An || (An = {}));
1802
- var Pn;
1803
- (function(n) {
1804
- n[n.Context = 0] = "Context", n[n.Identifier = 1] = "Identifier", n[n.SavedView = 2] = "SavedView", n[n.Alias = 3] = "Alias";
1805
- })(Pn || (Pn = {}));
1806
- var Ln;
1807
- (function(n) {
1808
- n[n.Normal = 0] = "Normal", n[n.TemplateDefinitionBuilder = 1] = "TemplateDefinitionBuilder";
1809
- })(Ln || (Ln = {}));
1810
- var H;
1811
- (function(n) {
1812
- n[n.Attribute = 0] = "Attribute", n[n.ClassName = 1] = "ClassName", n[n.StyleProperty = 2] = "StyleProperty", n[n.Property = 3] = "Property", n[n.Template = 4] = "Template", n[n.I18n = 5] = "I18n", n[n.Animation = 6] = "Animation", n[n.TwoWayProperty = 7] = "TwoWayProperty";
1813
- })(H || (H = {}));
1814
- var Mn;
1815
- (function(n) {
1816
- n[n.Creation = 0] = "Creation", n[n.Postproccessing = 1] = "Postproccessing";
1817
- })(Mn || (Mn = {}));
1818
- var $n;
1819
- (function(n) {
1820
- n[n.I18nText = 0] = "I18nText", n[n.I18nAttribute = 1] = "I18nAttribute";
1821
- })($n || ($n = {}));
1822
- var Rn;
1823
- (function(n) {
1824
- n[n.None = 0] = "None", n[n.ElementTag = 1] = "ElementTag", n[n.TemplateTag = 2] = "TemplateTag", n[n.OpenTag = 4] = "OpenTag", n[n.CloseTag = 8] = "CloseTag", n[n.ExpressionIndex = 16] = "ExpressionIndex";
1825
- })(Rn || (Rn = {}));
1826
- var Dn;
1827
- (function(n) {
1828
- n[n.HTML = 0] = "HTML", n[n.SVG = 1] = "SVG", n[n.Math = 2] = "Math";
1829
- })(Dn || (Dn = {}));
1830
- var Bn;
1831
- (function(n) {
1832
- n[n.Idle = 0] = "Idle", n[n.Immediate = 1] = "Immediate", n[n.Timer = 2] = "Timer", n[n.Hover = 3] = "Hover", n[n.Interaction = 4] = "Interaction", n[n.Viewport = 5] = "Viewport", n[n.Never = 6] = "Never";
1833
- })(Bn || (Bn = {}));
1834
- var On;
1835
- (function(n) {
1836
- n[n.RootI18n = 0] = "RootI18n", n[n.Icu = 1] = "Icu", n[n.Attr = 2] = "Attr";
1837
- })(On || (On = {}));
1838
- var Fn;
1839
- (function(n) {
1840
- n[n.NgTemplate = 0] = "NgTemplate", n[n.Structural = 1] = "Structural", n[n.Block = 2] = "Block";
1841
- })(Fn || (Fn = {}));
1842
- var at = class {
1843
- strings;
1844
- expressions;
1845
- i18nPlaceholders;
1846
- constructor(e, t, s) {
1847
- if (this.strings = e, this.expressions = t, this.i18nPlaceholders = s, s.length !== 0 && s.length !== t.length) throw new Error(`Expected ${t.length} placeholders to match interpolation expression count, but got ${s.length}`);
1848
- }
1849
- };
1850
- var Rt;
1851
- (function(n) {
1852
- n[n.None = 0] = "None", n[n.InChildOperation = 1] = "InChildOperation";
1853
- })(Rt || (Rt = {}));
1854
- new Set([
1855
- d.Element,
1856
- d.ElementStart,
1857
- d.Container,
1858
- d.ContainerStart,
1859
- d.Template,
1860
- d.RepeaterCreate,
1861
- d.ConditionalCreate,
1862
- d.ConditionalBranchCreate
1863
- ]);
1864
- var qn;
1865
- (function(n) {
1866
- n[n.Tmpl = 0] = "Tmpl", n[n.Host = 1] = "Host", n[n.Both = 2] = "Both";
1867
- })(qn || (qn = {}));
1868
- new Map([
1869
- [p.attribute, p.attribute],
1870
- [p.classProp, p.classProp],
1871
- [p.element, p.element],
1872
- [p.elementContainer, p.elementContainer],
1873
- [p.elementContainerEnd, p.elementContainerEnd],
1874
- [p.elementContainerStart, p.elementContainerStart],
1875
- [p.elementEnd, p.elementEnd],
1876
- [p.elementStart, p.elementStart],
1877
- [p.domProperty, p.domProperty],
1878
- [p.i18nExp, p.i18nExp],
1879
- [p.listener, p.listener],
1880
- [p.listener, p.listener],
1881
- [p.property, p.property],
1882
- [p.styleProp, p.styleProp],
1883
- [p.syntheticHostListener, p.syntheticHostListener],
1884
- [p.syntheticHostProperty, p.syntheticHostProperty],
1885
- [p.templateCreate, p.templateCreate],
1886
- [p.twoWayProperty, p.twoWayProperty],
1887
- [p.twoWayListener, p.twoWayListener],
1888
- [p.declareLet, p.declareLet],
1889
- [p.conditionalCreate, p.conditionalBranchCreate],
1890
- [p.conditionalBranchCreate, p.conditionalBranchCreate]
1891
- ]);
1892
- Object.freeze([]);
1893
- new Map([
1894
- [d.ElementEnd, [d.ElementStart, d.Element]],
1895
- [d.ContainerEnd, [d.ContainerStart, d.Container]],
1896
- [d.I18nEnd, [d.I18nStart, d.I18n]]
1897
- ]);
1898
- new Set([d.Pipe]);
1899
- var kr = {};
1900
- kr.ngsp = "";
1901
- var jn;
1902
- (function(n) {
1903
- n.HEX = "hexadecimal", n.DEC = "decimal";
1904
- })(jn || (jn = {}));
1905
- var ds = ` \f
1906
- \r \v\u1680\u180E\u2000-\u200A\u2028\u2029\u202F\u205F\u3000\uFEFF`;
1907
- `${ds}`;
1908
- new RegExp(`[${ds}]{2,}`, "g");
1909
- var m;
1910
- (function(n) {
1911
- n[n.Character = 0] = "Character", n[n.Identifier = 1] = "Identifier", n[n.PrivateIdentifier = 2] = "PrivateIdentifier", n[n.Keyword = 3] = "Keyword", n[n.String = 4] = "String", n[n.Operator = 5] = "Operator", n[n.Number = 6] = "Number", n[n.Error = 7] = "Error";
1912
- })(m || (m = {}));
1913
- var q;
1914
- (function(n) {
1915
- n[n.Plain = 0] = "Plain", n[n.TemplateLiteralPart = 1] = "TemplateLiteralPart", n[n.TemplateLiteralEnd = 2] = "TemplateLiteralEnd";
1916
- })(q || (q = {}));
1917
- var Ir = [
1918
- "var",
1919
- "let",
1920
- "as",
1921
- "null",
1922
- "undefined",
1923
- "true",
1924
- "false",
1925
- "if",
1926
- "else",
1927
- "this",
1928
- "typeof",
1929
- "void",
1930
- "in"
1931
- ], qe = class {
1932
- tokenize(e) {
1933
- return new Dt(e).scan();
1934
- }
1935
- }, M = class {
1936
- index;
1937
- end;
1938
- type;
1939
- numValue;
1940
- strValue;
1941
- constructor(e, t, s, r, i) {
1942
- this.index = e, this.end = t, this.type = s, this.numValue = r, this.strValue = i;
1943
- }
1944
- isCharacter(e) {
1945
- return this.type === m.Character && this.numValue === e;
1946
- }
1947
- isNumber() {
1948
- return this.type === m.Number;
1949
- }
1950
- isString() {
1951
- return this.type === m.String;
1952
- }
1953
- isOperator(e) {
1954
- return this.type === m.Operator && this.strValue === e;
1955
- }
1956
- isIdentifier() {
1957
- return this.type === m.Identifier;
1958
- }
1959
- isPrivateIdentifier() {
1960
- return this.type === m.PrivateIdentifier;
1961
- }
1962
- isKeyword() {
1963
- return this.type === m.Keyword;
1964
- }
1965
- isKeywordLet() {
1966
- return this.type === m.Keyword && this.strValue === "let";
1967
- }
1968
- isKeywordAs() {
1969
- return this.type === m.Keyword && this.strValue === "as";
1970
- }
1971
- isKeywordNull() {
1972
- return this.type === m.Keyword && this.strValue === "null";
1973
- }
1974
- isKeywordUndefined() {
1975
- return this.type === m.Keyword && this.strValue === "undefined";
1976
- }
1977
- isKeywordTrue() {
1978
- return this.type === m.Keyword && this.strValue === "true";
1979
- }
1980
- isKeywordFalse() {
1981
- return this.type === m.Keyword && this.strValue === "false";
1982
- }
1983
- isKeywordThis() {
1984
- return this.type === m.Keyword && this.strValue === "this";
1985
- }
1986
- isKeywordTypeof() {
1987
- return this.type === m.Keyword && this.strValue === "typeof";
1988
- }
1989
- isKeywordVoid() {
1990
- return this.type === m.Keyword && this.strValue === "void";
1991
- }
1992
- isKeywordIn() {
1993
- return this.type === m.Keyword && this.strValue === "in";
1994
- }
1995
- isError() {
1996
- return this.type === m.Error;
1997
- }
1998
- toNumber() {
1999
- return this.type === m.Number ? this.numValue : -1;
2000
- }
2001
- isTemplateLiteralPart() {
2002
- return this.isString() && this.kind === q.TemplateLiteralPart;
2003
- }
2004
- isTemplateLiteralEnd() {
2005
- return this.isString() && this.kind === q.TemplateLiteralEnd;
2006
- }
2007
- isTemplateLiteralInterpolationStart() {
2008
- return this.isOperator("${");
2009
- }
2010
- isTemplateLiteralInterpolationEnd() {
2011
- return this.isOperator("}");
2012
- }
2013
- toString() {
2014
- switch (this.type) {
2015
- case m.Character:
2016
- case m.Identifier:
2017
- case m.Keyword:
2018
- case m.Operator:
2019
- case m.PrivateIdentifier:
2020
- case m.String:
2021
- case m.Error: return this.strValue;
2022
- case m.Number: return this.numValue.toString();
2023
- default: return null;
2024
- }
2025
- }
2026
- }, Ie = class extends M {
2027
- kind;
2028
- constructor(e, t, s, r) {
2029
- super(e, t, m.String, 0, s), this.kind = r;
2030
- }
2031
- };
2032
- function Ze(n, e, t) {
2033
- return new M(n, e, m.Character, t, String.fromCharCode(t));
2034
- }
2035
- function Nr(n, e, t) {
2036
- return new M(n, e, m.Identifier, 0, t);
2037
- }
2038
- function Ar(n, e, t) {
2039
- return new M(n, e, m.PrivateIdentifier, 0, t);
2040
- }
2041
- function Pr(n, e, t) {
2042
- return new M(n, e, m.Keyword, 0, t);
2043
- }
2044
- function _e(n, e, t) {
2045
- return new M(n, e, m.Operator, 0, t);
2046
- }
2047
- function Lr(n, e, t) {
2048
- return new M(n, e, m.Number, t, "");
2049
- }
2050
- function Mr(n, e, t) {
2051
- return new M(n, e, m.Error, 0, t);
2052
- }
2053
- var et = new M(-1, -1, m.Character, 0, ""), Dt = class {
2054
- input;
2055
- tokens = [];
2056
- length;
2057
- peek = 0;
2058
- index = -1;
2059
- braceStack = [];
2060
- constructor(e) {
2061
- this.input = e, this.length = e.length, this.advance();
2062
- }
2063
- scan() {
2064
- let e = this.scanToken();
2065
- for (; e !== null;) this.tokens.push(e), e = this.scanToken();
2066
- return this.tokens;
2067
- }
2068
- advance() {
2069
- this.peek = ++this.index >= this.length ? Qe : this.input.charCodeAt(this.index);
2070
- }
2071
- scanToken() {
2072
- let e = this.input, t = this.length, s = this.peek, r = this.index;
2073
- for (; s <= Zn;) if (++r >= t) {
2074
- s = Qe;
2075
- break;
2076
- } else s = e.charCodeAt(r);
2077
- if (this.peek = s, this.index = r, r >= t) return null;
2078
- if (zn(s)) return this.scanIdentifier();
2079
- if (z(s)) return this.scanNumber(r);
2080
- let i = r;
2081
- switch (s) {
2082
- case re: return this.advance(), z(this.peek) ? this.scanNumber(i) : Ze(i, this.index, re);
2083
- case tt:
2084
- case se:
2085
- case nt:
2086
- case ke:
2087
- case Ce:
2088
- case ie:
2089
- case Te: return this.scanCharacter(i, s);
2090
- case ot: return this.scanOpenBrace(i, s);
2091
- case be: return this.scanCloseBrace(i, s);
2092
- case ts:
2093
- case es: return this.scanString();
2094
- case $t: return this.advance(), this.scanTemplateLiteralPart(i);
2095
- case nr: return this.scanPrivateIdentifier();
2096
- case ns:
2097
- case ss:
2098
- case Mt:
2099
- case sr:
2100
- case cr: return this.scanOperator(i, String.fromCharCode(s));
2101
- case En: return this.scanComplexOperator(i, "*", En, "*");
2102
- case yn: return this.scanQuestion(i);
2103
- case rr:
2104
- case ir: return this.scanComplexOperator(i, String.fromCharCode(s), Ke, "=");
2105
- case tr:
2106
- case Ke: return this.scanComplexOperator(i, String.fromCharCode(s), Ke, "=", Ke, "=");
2107
- case Sn: return this.scanComplexOperator(i, "&", Sn, "&");
2108
- case Cn: return this.scanComplexOperator(i, "|", Cn, "|");
2109
- case ls:
2110
- for (; vr(this.peek);) this.advance();
2111
- return this.scanToken();
2112
- }
2113
- return this.advance(), this.error(`Unexpected character [${String.fromCharCode(s)}]`, 0);
2114
- }
2115
- scanCharacter(e, t) {
2116
- return this.advance(), Ze(e, this.index, t);
2117
- }
2118
- scanOperator(e, t) {
2119
- return this.advance(), _e(e, this.index, t);
2120
- }
2121
- scanOpenBrace(e, t) {
2122
- return this.braceStack.push("expression"), this.advance(), Ze(e, this.index, t);
2123
- }
2124
- scanCloseBrace(e, t) {
2125
- return this.advance(), this.braceStack.pop() === "interpolation" ? (this.tokens.push(_e(e, this.index, "}")), this.scanTemplateLiteralPart(this.index)) : Ze(e, this.index, t);
2126
- }
2127
- scanComplexOperator(e, t, s, r, i, a) {
2128
- this.advance();
2129
- let l = t;
2130
- return this.peek == s && (this.advance(), l += r), i != null && this.peek == i && (this.advance(), l += a), _e(e, this.index, l);
2131
- }
2132
- scanIdentifier() {
2133
- let e = this.index;
2134
- for (this.advance(); Gn(this.peek);) this.advance();
2135
- let t = this.input.substring(e, this.index);
2136
- return Ir.indexOf(t) > -1 ? Pr(e, this.index, t) : Nr(e, this.index, t);
2137
- }
2138
- scanPrivateIdentifier() {
2139
- let e = this.index;
2140
- if (this.advance(), !zn(this.peek)) return this.error("Invalid character [#]", -1);
2141
- for (; Gn(this.peek);) this.advance();
2142
- let t = this.input.substring(e, this.index);
2143
- return Ar(e, this.index, t);
2144
- }
2145
- scanNumber(e) {
2146
- let t = this.index === e, s = !1;
2147
- for (this.advance();;) {
2148
- if (!z(this.peek)) if (this.peek === Ht) {
2149
- if (!z(this.input.charCodeAt(this.index - 1)) || !z(this.input.charCodeAt(this.index + 1))) return this.error("Invalid numeric separator", 0);
2150
- s = !0;
2151
- } else if (this.peek === re) t = !1;
2152
- else if ($r(this.peek)) {
2153
- if (this.advance(), Rr(this.peek) && this.advance(), !z(this.peek)) return this.error("Invalid exponent", -1);
2154
- t = !1;
2155
- } else break;
2156
- this.advance();
2157
- }
2158
- let r = this.input.substring(e, this.index);
2159
- s && (r = r.replace(/_/g, ""));
2160
- let i = t ? Br(r) : parseFloat(r);
2161
- return Lr(e, this.index, i);
2162
- }
2163
- scanString() {
2164
- let e = this.index, t = this.peek;
2165
- this.advance();
2166
- let s = "", r = this.index, i = this.input;
2167
- for (; this.peek != t;) if (this.peek == _n) {
2168
- let l = this.scanStringBackslash(s, r);
2169
- if (typeof l != "string") return l;
2170
- s = l, r = this.index;
2171
- } else {
2172
- if (this.peek == Qe) return this.error("Unterminated quote", 0);
2173
- this.advance();
2174
- }
2175
- let a = i.substring(r, this.index);
2176
- return this.advance(), new Ie(e, this.index, s + a, q.Plain);
2177
- }
2178
- scanQuestion(e) {
2179
- this.advance();
2180
- let t = "?";
2181
- return (this.peek === yn || this.peek === re) && (t += this.peek === re ? "." : "?", this.advance()), _e(e, this.index, t);
2182
- }
2183
- scanTemplateLiteralPart(e) {
2184
- let t = "", s = this.index;
2185
- for (; this.peek !== $t;) if (this.peek === _n) {
2186
- let i = this.scanStringBackslash(t, s);
2187
- if (typeof i != "string") return i;
2188
- t = i, s = this.index;
2189
- } else if (this.peek === Ut) {
2190
- let i = this.index;
2191
- if (this.advance(), this.peek === ot) return this.braceStack.push("interpolation"), this.tokens.push(new Ie(e, i, t + this.input.substring(s, i), q.TemplateLiteralPart)), this.advance(), _e(i, this.index, this.input.substring(i, this.index));
2192
- } else {
2193
- if (this.peek === Qe) return this.error("Unterminated template literal", 0);
2194
- this.advance();
2195
- }
2196
- let r = this.input.substring(s, this.index);
2197
- return this.advance(), new Ie(e, this.index, t + r, q.TemplateLiteralEnd);
2198
- }
2199
- error(e, t) {
2200
- let s = this.index + t;
2201
- return Mr(s, this.index, `Lexer Error: ${e} at column ${s} in expression [${this.input}]`);
2202
- }
2203
- scanStringBackslash(e, t) {
2204
- e += this.input.substring(t, this.index);
2205
- let s;
2206
- if (this.advance(), this.peek === mr) {
2207
- let r = this.input.substring(this.index + 1, this.index + 5);
2208
- if (/^[0-9a-f]+$/i.test(r)) s = parseInt(r, 16);
2209
- else return this.error(`Invalid unicode escape [\\u${r}]`, 0);
2210
- for (let i = 0; i < 5; i++) this.advance();
2211
- } else s = Dr(this.peek), this.advance();
2212
- return e += String.fromCharCode(s), e;
2213
- }
2214
- };
2215
- function zn(n) {
2216
- return os <= n && n <= as || rs <= n && n <= is || n == Ht || n == Ut;
2217
- }
2218
- function Gn(n) {
2219
- return wr(n) || z(n) || n == Ht || n == Ut;
2220
- }
2221
- function $r(n) {
2222
- return n == ur || n == lr;
2223
- }
2224
- function Rr(n) {
2225
- return n == ss || n == ns;
2226
- }
2227
- function Dr(n) {
2228
- switch (n) {
2229
- case hr: return Qs;
2230
- case pr: return Zs;
2231
- case fr: return er;
2232
- case dr: return Kn;
2233
- case gr: return Ks;
2234
- default: return n;
2235
- }
2236
- }
2237
- function Br(n) {
2238
- let e = parseInt(n);
2239
- if (isNaN(e)) throw new Error("Invalid integer literal when parsing " + n);
2240
- return e;
2241
- }
2242
- var Bt = class {
2243
- strings;
2244
- expressions;
2245
- offsets;
2246
- constructor(e, t, s) {
2247
- this.strings = e, this.expressions = t, this.offsets = s;
2248
- }
2249
- }, Ot = class {
2250
- templateBindings;
2251
- warnings;
2252
- errors;
2253
- constructor(e, t, s) {
2254
- this.templateBindings = e, this.warnings = t, this.errors = s;
2255
- }
2256
- }, we = class {
2257
- _lexer;
2258
- errors = [];
2259
- constructor(e) {
2260
- this._lexer = e;
2261
- }
2262
- parseAction(e, t, s, r = ne) {
2263
- this._checkNoInterpolation(e, t, r);
2264
- let i = this._stripComments(e);
2265
- return new W(new G(e, t, s, this._lexer.tokenize(i), 1, this.errors, 0).parseChain(), e, t, s, this.errors);
2266
- }
2267
- parseBinding(e, t, s, r = ne) {
2268
- return new W(this._parseBindingAst(e, t, s, r), e, t, s, this.errors);
2269
- }
2270
- checkSimpleExpression(e) {
2271
- let t = new Ft();
2272
- return e.visit(t), t.errors;
2273
- }
2274
- parseSimpleBinding(e, t, s, r = ne) {
2275
- let i = this._parseBindingAst(e, t, s, r), a = this.checkSimpleExpression(i);
2276
- return a.length > 0 && this._reportError(`Host binding expression cannot contain ${a.join(" ")}`, e, t), new W(i, e, t, s, this.errors);
2277
- }
2278
- _reportError(e, t, s, r) {
2279
- this.errors.push(new Pe(e, t, s, r));
2280
- }
2281
- _parseBindingAst(e, t, s, r) {
2282
- this._checkNoInterpolation(e, t, r);
2283
- let i = this._stripComments(e);
2284
- return new G(e, t, s, this._lexer.tokenize(i), 0, this.errors, 0).parseChain();
2285
- }
2286
- parseTemplateBindings(e, t, s, r, i) {
2287
- return new G(t, s, i, this._lexer.tokenize(t), 0, this.errors, 0).parseTemplateBindings({
2288
- source: e,
2289
- span: new O(r, r + e.length)
2290
- });
2291
- }
2292
- parseInterpolation(e, t, s, r, i = ne) {
2293
- let { strings: a, expressions: l, offsets: h } = this.splitInterpolation(e, t, r, i);
2294
- if (l.length === 0) return null;
2295
- let f = [];
2296
- for (let v = 0; v < l.length; ++v) {
2297
- let E = l[v].text, y = this._stripComments(E), k = new G(e, t, s, this._lexer.tokenize(y), 0, this.errors, h[v]).parseChain();
2298
- f.push(k);
2299
- }
2300
- return this.createInterpolationAst(a.map((v) => v.text), f, e, t, s);
2301
- }
2302
- parseInterpolationExpression(e, t, s) {
2303
- let r = this._stripComments(e), a = new G(e, t, s, this._lexer.tokenize(r), 0, this.errors, 0).parseChain();
2304
- return this.createInterpolationAst(["", ""], [a], e, t, s);
2305
- }
2306
- createInterpolationAst(e, t, s, r, i) {
2307
- let a = new J(0, s.length);
2308
- return new W(new Vt(a, a.toAbsolute(i), e, t), s, r, i, this.errors);
2309
- }
2310
- splitInterpolation(e, t, s, r = ne) {
2311
- let i = [], a = [], l = [], h = s ? Or(s) : null, f = 0, v = !1, E = !1, { start: y, end: T } = r;
2312
- for (; f < e.length;) if (v) {
2313
- let k = f, F = k + y.length, Ee = this._getInterpolationEndIndex(e, T, F);
2314
- if (Ee === -1) {
2315
- v = !1, E = !0;
2316
- break;
2317
- }
2318
- let ye = Ee + T.length, j = e.substring(F, Ee);
2319
- j.trim().length === 0 && this._reportError("Blank expressions are not allowed in interpolated strings", e, `at column ${f} in`, t), a.push({
2320
- text: j,
2321
- start: k,
2322
- end: ye
2323
- });
2324
- let Ws = ((h == null ? void 0 : h.get(k)) ?? k) + y.length;
2325
- l.push(Ws), f = ye, v = !1;
2326
- } else {
2327
- let k = f;
2328
- f = e.indexOf(y, f), f === -1 && (f = e.length);
2329
- let F = e.substring(k, f);
2330
- i.push({
2331
- text: F,
2332
- start: k,
2333
- end: f
2334
- }), v = !0;
2335
- }
2336
- if (!v) if (E) {
2337
- let k = i[i.length - 1];
2338
- k.text += e.substring(f), k.end = e.length;
2339
- } else i.push({
2340
- text: e.substring(f),
2341
- start: f,
2342
- end: e.length
2343
- });
2344
- return new Bt(i, a, l);
2345
- }
2346
- wrapLiteralPrimitive(e, t, s) {
2347
- let r = new J(0, e == null ? 0 : e.length);
2348
- return new W(new I(r, r.toAbsolute(s), e), e, t, s, this.errors);
2349
- }
2350
- _stripComments(e) {
2351
- let t = this._commentStart(e);
2352
- return t != null ? e.substring(0, t) : e;
2353
- }
2354
- _commentStart(e) {
2355
- let t = null;
2356
- for (let s = 0; s < e.length - 1; s++) {
2357
- let r = e.charCodeAt(s), i = e.charCodeAt(s + 1);
2358
- if (r === Mt && i == Mt && t == null) return s;
2359
- t === r ? t = null : t == null && Tn(r) && (t = r);
2360
- }
2361
- return null;
2362
- }
2363
- _checkNoInterpolation(e, t, { start: s, end: r }) {
2364
- let i = -1, a = -1;
2365
- for (let l of this._forEachUnquotedChar(e, 0)) if (i === -1) e.startsWith(s) && (i = l);
2366
- else if (a = this._getInterpolationEndIndex(e, r, l), a > -1) break;
2367
- i > -1 && a > -1 && this._reportError(`Got interpolation (${s}${r}) where expression was expected`, e, `at column ${i} in`, t);
2368
- }
2369
- _getInterpolationEndIndex(e, t, s) {
2370
- for (let r of this._forEachUnquotedChar(e, s)) {
2371
- if (e.startsWith(t, r)) return r;
2372
- if (e.startsWith("//", r)) return e.indexOf(t, r);
2373
- }
2374
- return -1;
2375
- }
2376
- *_forEachUnquotedChar(e, t) {
2377
- let s = null, r = 0;
2378
- for (let i = t; i < e.length; i++) {
2379
- let a = e[i];
2380
- Tn(e.charCodeAt(i)) && (s === null || s === a) && r % 2 === 0 ? s = s === null ? a : null : s === null && (yield i), r = a === "\\" ? r + 1 : 0;
2381
- }
2382
- }
2383
- }, oe;
2384
- (function(n) {
2385
- n[n.None = 0] = "None", n[n.Writable = 1] = "Writable";
2386
- })(oe || (oe = {}));
2387
- var G = class {
2388
- input;
2389
- location;
2390
- absoluteOffset;
2391
- tokens;
2392
- parseFlags;
2393
- errors;
2394
- offset;
2395
- rparensExpected = 0;
2396
- rbracketsExpected = 0;
2397
- rbracesExpected = 0;
2398
- context = oe.None;
2399
- sourceSpanCache = /* @__PURE__ */ new Map();
2400
- index = 0;
2401
- constructor(e, t, s, r, i, a, l) {
2402
- this.input = e, this.location = t, this.absoluteOffset = s, this.tokens = r, this.parseFlags = i, this.errors = a, this.offset = l;
2403
- }
2404
- peek(e) {
2405
- let t = this.index + e;
2406
- return t < this.tokens.length ? this.tokens[t] : et;
2407
- }
2408
- get next() {
2409
- return this.peek(0);
2410
- }
2411
- get atEOF() {
2412
- return this.index >= this.tokens.length;
2413
- }
2414
- get inputIndex() {
2415
- return this.atEOF ? this.currentEndIndex : this.next.index + this.offset;
2416
- }
2417
- get currentEndIndex() {
2418
- return this.index > 0 ? this.peek(-1).end + this.offset : this.tokens.length === 0 ? this.input.length + this.offset : this.next.index + this.offset;
2419
- }
2420
- get currentAbsoluteOffset() {
2421
- return this.absoluteOffset + this.inputIndex;
2422
- }
2423
- span(e, t) {
2424
- let s = this.currentEndIndex;
2425
- if (t !== void 0 && t > this.currentEndIndex && (s = t), e > s) {
2426
- let r = s;
2427
- s = e, e = r;
2428
- }
2429
- return new J(e, s);
2430
- }
2431
- sourceSpan(e, t) {
2432
- let s = `${e}@${this.inputIndex}:${t}`;
2433
- return this.sourceSpanCache.has(s) || this.sourceSpanCache.set(s, this.span(e, t).toAbsolute(this.absoluteOffset)), this.sourceSpanCache.get(s);
2434
- }
2435
- advance() {
2436
- this.index++;
2437
- }
2438
- withContext(e, t) {
2439
- this.context |= e;
2440
- let s = t();
2441
- return this.context ^= e, s;
2442
- }
2443
- consumeOptionalCharacter(e) {
2444
- return this.next.isCharacter(e) ? (this.advance(), !0) : !1;
2445
- }
2446
- peekKeywordLet() {
2447
- return this.next.isKeywordLet();
2448
- }
2449
- peekKeywordAs() {
2450
- return this.next.isKeywordAs();
2451
- }
2452
- expectCharacter(e) {
2453
- this.consumeOptionalCharacter(e) || this.error(`Missing expected ${String.fromCharCode(e)}`);
2454
- }
2455
- consumeOptionalOperator(e) {
2456
- return this.next.isOperator(e) ? (this.advance(), !0) : !1;
2457
- }
2458
- expectOperator(e) {
2459
- this.consumeOptionalOperator(e) || this.error(`Missing expected operator ${e}`);
2460
- }
2461
- prettyPrintToken(e) {
2462
- return e === et ? "end of input" : `token ${e}`;
2463
- }
2464
- expectIdentifierOrKeyword() {
2465
- let e = this.next;
2466
- return !e.isIdentifier() && !e.isKeyword() ? (e.isPrivateIdentifier() ? this._reportErrorForPrivateIdentifier(e, "expected identifier or keyword") : this.error(`Unexpected ${this.prettyPrintToken(e)}, expected identifier or keyword`), null) : (this.advance(), e.toString());
2467
- }
2468
- expectIdentifierOrKeywordOrString() {
2469
- let e = this.next;
2470
- return !e.isIdentifier() && !e.isKeyword() && !e.isString() ? (e.isPrivateIdentifier() ? this._reportErrorForPrivateIdentifier(e, "expected identifier, keyword or string") : this.error(`Unexpected ${this.prettyPrintToken(e)}, expected identifier, keyword, or string`), "") : (this.advance(), e.toString());
2471
- }
2472
- parseChain() {
2473
- let e = [], t = this.inputIndex;
2474
- for (; this.index < this.tokens.length;) {
2475
- let s = this.parsePipe();
2476
- if (e.push(s), this.consumeOptionalCharacter(Te)) for (this.parseFlags & 1 || this.error("Binding expression cannot contain chained expression"); this.consumeOptionalCharacter(Te););
2477
- else if (this.index < this.tokens.length) {
2478
- let r = this.index;
2479
- if (this.error(`Unexpected token '${this.next}'`), this.index === r) break;
2480
- }
2481
- }
2482
- if (e.length === 0) {
2483
- let s = this.offset, r = this.offset + this.input.length;
2484
- return new P(this.span(s, r), this.sourceSpan(s, r));
2485
- }
2486
- return e.length == 1 ? e[0] : new Le(this.span(t), this.sourceSpan(t), e);
2487
- }
2488
- parsePipe() {
2489
- let e = this.inputIndex, t = this.parseExpression();
2490
- if (this.consumeOptionalOperator("|")) {
2491
- this.parseFlags & 1 && this.error("Cannot have a pipe in an action expression");
2492
- do {
2493
- let s = this.inputIndex, r = this.expectIdentifierOrKeyword(), i, a;
2494
- r !== null ? i = this.sourceSpan(s) : (r = "", a = this.next.index !== -1 ? this.next.index : this.input.length + this.offset, i = new J(a, a).toAbsolute(this.absoluteOffset));
2495
- let l = [];
2496
- for (; this.consumeOptionalCharacter(ie);) l.push(this.parseExpression());
2497
- t = new Be(this.span(e), this.sourceSpan(e, a), t, r, l, i);
2498
- } while (this.consumeOptionalOperator("|"));
2499
- }
2500
- return t;
2501
- }
2502
- parseExpression() {
2503
- return this.parseConditional();
2504
- }
2505
- parseConditional() {
2506
- let e = this.inputIndex, t = this.parseLogicalOr();
2507
- if (this.consumeOptionalOperator("?")) {
2508
- let s = this.parsePipe(), r;
2509
- if (this.consumeOptionalCharacter(ie)) r = this.parsePipe();
2510
- else {
2511
- let i = this.inputIndex, a = this.input.substring(e, i);
2512
- this.error(`Conditional expression ${a} requires all 3 expressions`), r = new P(this.span(e), this.sourceSpan(e));
2513
- }
2514
- return new Me(this.span(e), this.sourceSpan(e), t, s, r);
2515
- } else return t;
2516
- }
2517
- parseLogicalOr() {
2518
- let e = this.inputIndex, t = this.parseLogicalAnd();
2519
- for (; this.consumeOptionalOperator("||");) {
2520
- let s = this.parseLogicalAnd();
2521
- t = new A(this.span(e), this.sourceSpan(e), "||", t, s);
2522
- }
2523
- return t;
2524
- }
2525
- parseLogicalAnd() {
2526
- let e = this.inputIndex, t = this.parseNullishCoalescing();
2527
- for (; this.consumeOptionalOperator("&&");) {
2528
- let s = this.parseNullishCoalescing();
2529
- t = new A(this.span(e), this.sourceSpan(e), "&&", t, s);
2530
- }
2531
- return t;
2532
- }
2533
- parseNullishCoalescing() {
2534
- let e = this.inputIndex, t = this.parseEquality();
2535
- for (; this.consumeOptionalOperator("??");) {
2536
- let s = this.parseEquality();
2537
- t = new A(this.span(e), this.sourceSpan(e), "??", t, s);
2538
- }
2539
- return t;
2540
- }
2541
- parseEquality() {
2542
- let e = this.inputIndex, t = this.parseRelational();
2543
- for (; this.next.type == m.Operator;) {
2544
- let s = this.next.strValue;
2545
- switch (s) {
2546
- case "==":
2547
- case "===":
2548
- case "!=":
2549
- case "!==":
2550
- this.advance();
2551
- let r = this.parseRelational();
2552
- t = new A(this.span(e), this.sourceSpan(e), s, t, r);
2553
- continue;
2554
- }
2555
- break;
2556
- }
2557
- return t;
2558
- }
2559
- parseRelational() {
2560
- let e = this.inputIndex, t = this.parseAdditive();
2561
- for (; this.next.type == m.Operator || this.next.isKeywordIn;) {
2562
- let s = this.next.strValue;
2563
- switch (s) {
2564
- case "<":
2565
- case ">":
2566
- case "<=":
2567
- case ">=":
2568
- case "in":
2569
- this.advance();
2570
- let r = this.parseAdditive();
2571
- t = new A(this.span(e), this.sourceSpan(e), s, t, r);
2572
- continue;
2573
- }
2574
- break;
2575
- }
2576
- return t;
2577
- }
2578
- parseAdditive() {
2579
- let e = this.inputIndex, t = this.parseMultiplicative();
2580
- for (; this.next.type == m.Operator;) {
2581
- let s = this.next.strValue;
2582
- switch (s) {
2583
- case "+":
2584
- case "-":
2585
- this.advance();
2586
- let r = this.parseMultiplicative();
2587
- t = new A(this.span(e), this.sourceSpan(e), s, t, r);
2588
- continue;
2589
- }
2590
- break;
2591
- }
2592
- return t;
2593
- }
2594
- parseMultiplicative() {
2595
- let e = this.inputIndex, t = this.parseExponentiation();
2596
- for (; this.next.type == m.Operator;) {
2597
- let s = this.next.strValue;
2598
- switch (s) {
2599
- case "*":
2600
- case "%":
2601
- case "/":
2602
- this.advance();
2603
- let r = this.parseExponentiation();
2604
- t = new A(this.span(e), this.sourceSpan(e), s, t, r);
2605
- continue;
2606
- }
2607
- break;
2608
- }
2609
- return t;
2610
- }
2611
- parseExponentiation() {
2612
- let e = this.inputIndex, t = this.parsePrefix();
2613
- for (; this.next.type == m.Operator && this.next.strValue === "**";) {
2614
- (t instanceof X || t instanceof Q || t instanceof K || t instanceof Z) && this.error("Unary operator used immediately before exponentiation expression. Parenthesis must be used to disambiguate operator precedence"), this.advance();
2615
- let s = this.parseExponentiation();
2616
- t = new A(this.span(e), this.sourceSpan(e), "**", t, s);
2617
- }
2618
- return t;
2619
- }
2620
- parsePrefix() {
2621
- if (this.next.type == m.Operator) {
2622
- let e = this.inputIndex, t = this.next.strValue, s;
2623
- switch (t) {
2624
- case "+": return this.advance(), s = this.parsePrefix(), X.createPlus(this.span(e), this.sourceSpan(e), s);
2625
- case "-": return this.advance(), s = this.parsePrefix(), X.createMinus(this.span(e), this.sourceSpan(e), s);
2626
- case "!": return this.advance(), s = this.parsePrefix(), new Q(this.span(e), this.sourceSpan(e), s);
2627
- }
2628
- } else if (this.next.isKeywordTypeof()) {
2629
- this.advance();
2630
- let e = this.inputIndex, t = this.parsePrefix();
2631
- return new K(this.span(e), this.sourceSpan(e), t);
2632
- } else if (this.next.isKeywordVoid()) {
2633
- this.advance();
2634
- let e = this.inputIndex, t = this.parsePrefix();
2635
- return new Z(this.span(e), this.sourceSpan(e), t);
2636
- }
2637
- return this.parseCallChain();
2638
- }
2639
- parseCallChain() {
2640
- let e = this.inputIndex, t = this.parsePrimary();
2641
- for (;;) if (this.consumeOptionalCharacter(re)) t = this.parseAccessMember(t, e, !1);
2642
- else if (this.consumeOptionalOperator("?.")) this.consumeOptionalCharacter(tt) ? t = this.parseCall(t, e, !0) : t = this.consumeOptionalCharacter(nt) ? this.parseKeyedReadOrWrite(t, e, !0) : this.parseAccessMember(t, e, !0);
2643
- else if (this.consumeOptionalCharacter(nt)) t = this.parseKeyedReadOrWrite(t, e, !1);
2644
- else if (this.consumeOptionalCharacter(tt)) t = this.parseCall(t, e, !1);
2645
- else if (this.consumeOptionalOperator("!")) t = new Ve(this.span(e), this.sourceSpan(e), t);
2646
- else if (this.next.isTemplateLiteralEnd()) t = this.parseNoInterpolationTaggedTemplateLiteral(t, e);
2647
- else if (this.next.isTemplateLiteralPart()) t = this.parseTaggedTemplateLiteral(t, e);
2648
- else return t;
2649
- }
2650
- parsePrimary() {
2651
- let e = this.inputIndex;
2652
- if (this.consumeOptionalCharacter(tt)) {
2653
- this.rparensExpected++;
2654
- let t = this.parsePipe();
2655
- return this.consumeOptionalCharacter(se) || (this.error("Missing closing parentheses"), this.consumeOptionalCharacter(se)), this.rparensExpected--, new He(this.span(e), this.sourceSpan(e), t);
2656
- } else {
2657
- if (this.next.isKeywordNull()) return this.advance(), new I(this.span(e), this.sourceSpan(e), null);
2658
- if (this.next.isKeywordUndefined()) return this.advance(), new I(this.span(e), this.sourceSpan(e), void 0);
2659
- if (this.next.isKeywordTrue()) return this.advance(), new I(this.span(e), this.sourceSpan(e), !0);
2660
- if (this.next.isKeywordFalse()) return this.advance(), new I(this.span(e), this.sourceSpan(e), !1);
2661
- if (this.next.isKeywordIn()) return this.advance(), new I(this.span(e), this.sourceSpan(e), "in");
2662
- if (this.next.isKeywordThis()) return this.advance(), new At(this.span(e), this.sourceSpan(e));
2663
- if (this.consumeOptionalCharacter(nt)) {
2664
- this.rbracketsExpected++;
2665
- let t = this.parseExpressionList(ke);
2666
- return this.rbracketsExpected--, this.expectCharacter(ke), new Oe(this.span(e), this.sourceSpan(e), t);
2667
- } else {
2668
- if (this.next.isCharacter(ot)) return this.parseLiteralMap();
2669
- if (this.next.isIdentifier()) return this.parseAccessMember(new Y(this.span(e), this.sourceSpan(e)), e, !1);
2670
- if (this.next.isNumber()) {
2671
- let t = this.next.toNumber();
2672
- return this.advance(), new I(this.span(e), this.sourceSpan(e), t);
2673
- } else {
2674
- if (this.next.isTemplateLiteralEnd()) return this.parseNoInterpolationTemplateLiteral();
2675
- if (this.next.isTemplateLiteralPart()) return this.parseTemplateLiteral();
2676
- if (this.next.isString() && this.next.kind === q.Plain) {
2677
- let t = this.next.toString();
2678
- return this.advance(), new I(this.span(e), this.sourceSpan(e), t);
2679
- } else return this.next.isPrivateIdentifier() ? (this._reportErrorForPrivateIdentifier(this.next, null), new P(this.span(e), this.sourceSpan(e))) : this.index >= this.tokens.length ? (this.error(`Unexpected end of expression: ${this.input}`), new P(this.span(e), this.sourceSpan(e))) : (this.error(`Unexpected token ${this.next}`), new P(this.span(e), this.sourceSpan(e)));
2680
- }
2681
- }
2682
- }
2683
- }
2684
- parseExpressionList(e) {
2685
- let t = [];
2686
- do
2687
- if (!this.next.isCharacter(e)) t.push(this.parsePipe());
2688
- else break;
2689
- while (this.consumeOptionalCharacter(Ce));
2690
- return t;
2691
- }
2692
- parseLiteralMap() {
2693
- let e = [], t = [], s = this.inputIndex;
2694
- if (this.expectCharacter(ot), !this.consumeOptionalCharacter(be)) {
2695
- this.rbracesExpected++;
2696
- do {
2697
- let r = this.inputIndex, i = this.next.isString(), a = this.expectIdentifierOrKeywordOrString(), l = {
2698
- key: a,
2699
- quoted: i
2700
- };
2701
- if (e.push(l), i) this.expectCharacter(ie), t.push(this.parsePipe());
2702
- else if (this.consumeOptionalCharacter(ie)) t.push(this.parsePipe());
2703
- else {
2704
- l.isShorthandInitialized = !0;
2705
- let h = this.span(r), f = this.sourceSpan(r);
2706
- t.push(new le(h, f, f, new Y(h, f), a));
2707
- }
2708
- } while (this.consumeOptionalCharacter(Ce) && !this.next.isCharacter(be));
2709
- this.rbracesExpected--, this.expectCharacter(be);
2710
- }
2711
- return new Fe(this.span(s), this.sourceSpan(s), e, t);
2712
- }
2713
- parseAccessMember(e, t, s) {
2714
- let r = this.inputIndex, i = this.withContext(oe.Writable, () => {
2715
- let h = this.expectIdentifierOrKeyword() ?? "";
2716
- return h.length === 0 && this.error("Expected identifier for property access", e.span.end), h;
2717
- }), a = this.sourceSpan(r), l;
2718
- if (s) this.consumeOptionalOperator("=") ? (this.error("The '?.' operator cannot be used in the assignment"), l = new P(this.span(t), this.sourceSpan(t))) : l = new ce(this.span(t), this.sourceSpan(t), a, e, i);
2719
- else if (this.consumeOptionalOperator("=")) {
2720
- if (!(this.parseFlags & 1)) return this.error("Bindings cannot contain assignments"), new P(this.span(t), this.sourceSpan(t));
2721
- let h = this.parseConditional();
2722
- l = new $e(this.span(t), this.sourceSpan(t), a, e, i, h);
2723
- } else l = new le(this.span(t), this.sourceSpan(t), a, e, i);
2724
- return l;
2725
- }
2726
- parseCall(e, t, s) {
2727
- let r = this.inputIndex;
2728
- this.rparensExpected++;
2729
- let i = this.parseCallArguments(), a = this.span(r, this.inputIndex).toAbsolute(this.absoluteOffset);
2730
- this.expectCharacter(se), this.rparensExpected--;
2731
- let l = this.span(t), h = this.sourceSpan(t);
2732
- return s ? new pe(l, h, e, i, a) : new Ue(l, h, e, i, a);
2733
- }
2734
- parseCallArguments() {
2735
- if (this.next.isCharacter(se)) return [];
2736
- let e = [];
2737
- do
2738
- e.push(this.parsePipe());
2739
- while (this.consumeOptionalCharacter(Ce));
2740
- return e;
2741
- }
2742
- expectTemplateBindingKey() {
2743
- let e = "", t = !1, s = this.currentAbsoluteOffset;
2744
- do
2745
- e += this.expectIdentifierOrKeywordOrString(), t = this.consumeOptionalOperator("-"), t && (e += "-");
2746
- while (t);
2747
- return {
2748
- source: e,
2749
- span: new O(s, s + e.length)
2750
- };
2751
- }
2752
- parseTemplateBindings(e) {
2753
- let t = [];
2754
- for (t.push(...this.parseDirectiveKeywordBindings(e)); this.index < this.tokens.length;) {
2755
- let s = this.parseLetBinding();
2756
- if (s) t.push(s);
2757
- else {
2758
- let r = this.expectTemplateBindingKey(), i = this.parseAsBinding(r);
2759
- i ? t.push(i) : (r.source = e.source + r.source.charAt(0).toUpperCase() + r.source.substring(1), t.push(...this.parseDirectiveKeywordBindings(r)));
2760
- }
2761
- this.consumeStatementTerminator();
2762
- }
2763
- return new Ot(t, [], this.errors);
2764
- }
2765
- parseKeyedReadOrWrite(e, t, s) {
2766
- return this.withContext(oe.Writable, () => {
2767
- this.rbracketsExpected++;
2768
- let r = this.parsePipe();
2769
- if (r instanceof P && this.error("Key access cannot be empty"), this.rbracketsExpected--, this.expectCharacter(ke), this.consumeOptionalOperator("=")) if (s) this.error("The '?.' operator cannot be used in the assignment");
2770
- else {
2771
- let i = this.parseConditional();
2772
- return new De(this.span(t), this.sourceSpan(t), e, r, i);
2773
- }
2774
- else return s ? new ue(this.span(t), this.sourceSpan(t), e, r) : new Re(this.span(t), this.sourceSpan(t), e, r);
2775
- return new P(this.span(t), this.sourceSpan(t));
2776
- });
2777
- }
2778
- parseDirectiveKeywordBindings(e) {
2779
- let t = [];
2780
- this.consumeOptionalCharacter(ie);
2781
- let s = this.getDirectiveBoundTarget(), r = this.currentAbsoluteOffset, i = this.parseAsBinding(e);
2782
- i || (this.consumeStatementTerminator(), r = this.currentAbsoluteOffset);
2783
- let a = new O(e.span.start, r);
2784
- return t.push(new We(a, e, s)), i && t.push(i), t;
2785
- }
2786
- getDirectiveBoundTarget() {
2787
- if (this.next === et || this.peekKeywordAs() || this.peekKeywordLet()) return null;
2788
- let e = this.parsePipe(), { start: t, end: s } = e.span;
2789
- return new W(e, this.input.substring(t, s), this.location, this.absoluteOffset + t, this.errors);
2790
- }
2791
- parseAsBinding(e) {
2792
- if (!this.peekKeywordAs()) return null;
2793
- this.advance();
2794
- let t = this.expectTemplateBindingKey();
2795
- this.consumeStatementTerminator();
2796
- return new me(new O(e.span.start, this.currentAbsoluteOffset), t, e);
2797
- }
2798
- parseLetBinding() {
2799
- if (!this.peekKeywordLet()) return null;
2800
- let e = this.currentAbsoluteOffset;
2801
- this.advance();
2802
- let t = this.expectTemplateBindingKey(), s = null;
2803
- this.consumeOptionalOperator("=") && (s = this.expectTemplateBindingKey()), this.consumeStatementTerminator();
2804
- return new me(new O(e, this.currentAbsoluteOffset), t, s);
2805
- }
2806
- parseNoInterpolationTaggedTemplateLiteral(e, t) {
2807
- let s = this.parseNoInterpolationTemplateLiteral();
2808
- return new he(this.span(t), this.sourceSpan(t), e, s);
2809
- }
2810
- parseNoInterpolationTemplateLiteral() {
2811
- let e = this.next.strValue, t = this.inputIndex;
2812
- this.advance();
2813
- let s = this.span(t), r = this.sourceSpan(t);
2814
- return new fe(s, r, [new de(s, r, e)], []);
2815
- }
2816
- parseTaggedTemplateLiteral(e, t) {
2817
- let s = this.parseTemplateLiteral();
2818
- return new he(this.span(t), this.sourceSpan(t), e, s);
2819
- }
2820
- parseTemplateLiteral() {
2821
- let e = [], t = [], s = this.inputIndex;
2822
- for (; this.next !== et;) {
2823
- let r = this.next;
2824
- if (r.isTemplateLiteralPart() || r.isTemplateLiteralEnd()) {
2825
- let i = this.inputIndex;
2826
- if (this.advance(), e.push(new de(this.span(i), this.sourceSpan(i), r.strValue)), r.isTemplateLiteralEnd()) break;
2827
- } else if (r.isTemplateLiteralInterpolationStart()) {
2828
- this.advance();
2829
- let i = this.parsePipe();
2830
- i instanceof P ? this.error("Template literal interpolation cannot be empty") : t.push(i);
2831
- } else this.advance();
2832
- }
2833
- return new fe(this.span(s), this.sourceSpan(s), e, t);
2834
- }
2835
- consumeStatementTerminator() {
2836
- this.consumeOptionalCharacter(Te) || this.consumeOptionalCharacter(Ce);
2837
- }
2838
- error(e, t = null) {
2839
- this.errors.push(new Pe(e, this.input, this.locationText(t), this.location)), this.skip();
2840
- }
2841
- locationText(e = null) {
2842
- return e ??= this.index, e < this.tokens.length ? `at column ${this.tokens[e].index + 1} in` : "at the end of the expression";
2843
- }
2844
- _reportErrorForPrivateIdentifier(e, t) {
2845
- let s = `Private identifiers are not supported. Unexpected private identifier: ${e}`;
2846
- t !== null && (s += `, ${t}`), this.error(s);
2847
- }
2848
- skip() {
2849
- let e = this.next;
2850
- for (; this.index < this.tokens.length && !e.isCharacter(Te) && !e.isOperator("|") && (this.rparensExpected <= 0 || !e.isCharacter(se)) && (this.rbracesExpected <= 0 || !e.isCharacter(be)) && (this.rbracketsExpected <= 0 || !e.isCharacter(ke)) && (!(this.context & oe.Writable) || !e.isOperator("="));) this.next.isError() && this.errors.push(new Pe(this.next.toString(), this.input, this.locationText(), this.location)), this.advance(), e = this.next;
2851
- }
2852
- }, Ft = class extends Pt {
2853
- errors = [];
2854
- visitPipe() {
2855
- this.errors.push("pipes");
2856
- }
2857
- };
2858
- function Or(n) {
2859
- let e = /* @__PURE__ */ new Map(), t = 0, s = 0, r = 0;
2860
- for (; r < n.length;) {
2861
- let i = n[r];
2862
- if (i.type === 9) {
2863
- let [a, l] = i.parts;
2864
- t += l.length, s += a.length;
2865
- } else {
2866
- let a = i.parts.reduce((l, h) => l + h.length, 0);
2867
- s += a, t += a;
2868
- }
2869
- e.set(s, t), r++;
2870
- }
2871
- return e;
2872
- }
2873
- var Fr = new Map(Object.entries({
2874
- class: "className",
2875
- for: "htmlFor",
2876
- formaction: "formAction",
2877
- innerHtml: "innerHTML",
2878
- readonly: "readOnly",
2879
- tabindex: "tabIndex"
2880
- }));
2881
- Array.from(Fr).reduce((n, [e, t]) => (n.set(e, t), n), /* @__PURE__ */ new Map());
2882
- new we(new qe());
2883
- function B(n) {
2884
- return (e) => e.kind === n;
2885
- }
2886
- function Ne(n, e) {
2887
- return (t) => t.kind === n && e === t.expression instanceof at;
2888
- }
2889
- B(d.StyleMap), B(d.ClassMap), B(d.StyleProp), B(d.ClassProp), Ne(d.Attribute, !0), Ne(d.Property, !0), Ne(d.Attribute, !1);
2890
- Ne(d.DomProperty, !0), Ne(d.DomProperty, !1), B(d.Attribute), B(d.StyleMap), B(d.ClassMap), B(d.StyleProp), B(d.ClassProp);
2891
- new Set([
2892
- d.Listener,
2893
- d.TwoWayListener,
2894
- d.StyleMap,
2895
- d.ClassMap,
2896
- d.StyleProp,
2897
- d.ClassProp,
2898
- d.Property,
2899
- d.TwoWayProperty,
2900
- d.DomProperty,
2901
- d.Attribute
2902
- ]);
2903
- p.interpolate, p.interpolate1, p.interpolate2, p.interpolate3, p.interpolate4, p.interpolate5, p.interpolate6, p.interpolate7, p.interpolate8, p.interpolateV;
2904
- new Map([
2905
- ["window", p.resolveWindow],
2906
- ["document", p.resolveDocument],
2907
- ["body", p.resolveBody]
2908
- ]);
2909
- new Map([
2910
- [D.HTML, p.sanitizeHtml],
2911
- [D.RESOURCE_URL, p.sanitizeResourceUrl],
2912
- [D.SCRIPT, p.sanitizeScript],
2913
- [D.STYLE, p.sanitizeStyle],
2914
- [D.URL, p.sanitizeUrl]
2915
- ]);
2916
- new Map([[D.HTML, p.trustConstantHtml], [D.RESOURCE_URL, p.trustConstantResourceUrl]]);
2917
- var Xn;
2918
- (function(n) {
2919
- n[n.None = 0] = "None", n[n.ViewContextRead = 1] = "ViewContextRead", n[n.ViewContextWrite = 2] = "ViewContextWrite", n[n.SideEffectful = 4] = "SideEffectful";
2920
- })(Xn || (Xn = {}));
2921
- new Map([
2922
- [U.Property, H.Property],
2923
- [U.TwoWay, H.TwoWayProperty],
2924
- [U.Attribute, H.Attribute],
2925
- [U.Class, H.ClassName],
2926
- [U.Style, H.StyleProperty],
2927
- [U.Animation, H.Animation]
2928
- ]);
2929
- var Jn;
2930
- (function(n) {
2931
- n[n.NG_CONTENT = 0] = "NG_CONTENT", n[n.STYLE = 1] = "STYLE", n[n.STYLESHEET = 2] = "STYLESHEET", n[n.SCRIPT = 3] = "SCRIPT", n[n.OTHER = 4] = "OTHER";
2932
- })(Jn || (Jn = {}));
2933
- var Yn;
2934
- (function(n) {
2935
- n.IDLE = "idle", n.TIMER = "timer", n.INTERACTION = "interaction", n.IMMEDIATE = "immediate", n.HOVER = "hover", n.VIEWPORT = "viewport", n.NEVER = "never";
2936
- })(Yn || (Yn = {}));
2937
- var ms = "%COMP%";
2938
- `${ms}`;
2939
- `${ms}`;
2940
- var Qn;
2941
- (function(n) {
2942
- n[n.Extract = 0] = "Extract", n[n.Merge = 1] = "Merge";
2943
- })(Qn || (Qn = {}));
2944
- new Nt("20.0.5");
2945
- function gs({ start: n, end: e }, t) {
2946
- let s = n, r = e;
2947
- for (; r !== s && /\s/.test(t[r - 1]);) r--;
2948
- for (; s !== r && /\s/.test(t[s]);) s++;
2949
- return {
2950
- start: s,
2951
- end: r
2952
- };
2953
- }
2954
- function Hr({ start: n, end: e }, t) {
2955
- let s = n, r = e;
2956
- for (; r !== t.length && /\s/.test(t[r]);) r++;
2957
- for (; s !== 0 && /\s/.test(t[s - 1]);) s--;
2958
- return {
2959
- start: s,
2960
- end: r
2961
- };
2962
- }
2963
- function Wr(n, e) {
2964
- return e[n.start - 1] === "(" && e[n.end] === ")" ? {
2965
- start: n.start - 1,
2966
- end: n.end + 1
2967
- } : n;
2968
- }
2969
- function vs(n, e, t) {
2970
- let s = 0, r = {
2971
- start: n.start,
2972
- end: n.end
2973
- };
2974
- for (;;) {
2975
- let i = Hr(r, e), a = Wr(i, e);
2976
- if (i.start === a.start && i.end === a.end) break;
2977
- r.start = a.start, r.end = a.end, s++;
2978
- }
2979
- return {
2980
- hasParens: (t ? s - 1 : s) !== 0,
2981
- outerSpan: gs(t ? {
2982
- start: r.start + 1,
2983
- end: r.end - 1
2984
- } : r, e),
2985
- innerSpan: gs(n, e)
2986
- };
2987
- }
2988
- function ws(n) {
2989
- return typeof n == "string" ? (e) => e === n : (e) => n.test(e);
2990
- }
2991
- function xs(n, e, t) {
2992
- let s = ws(e);
2993
- for (let r = t; r >= 0; r--) {
2994
- let i = n[r];
2995
- if (s(i)) return r;
2996
- }
2997
- throw new Error(`Cannot find front char ${e} from index ${t} in ${JSON.stringify(n)}`);
2998
- }
2999
- function Ss(n, e, t) {
3000
- let s = ws(e);
3001
- for (let r = t; r < n.length; r++) {
3002
- let i = n[r];
3003
- if (s(i)) return r;
3004
- }
3005
- throw new Error(`Cannot find character ${e} from index ${t} in ${JSON.stringify(n)}`);
3006
- }
3007
- function Es(n) {
3008
- return n.slice(0, 1).toLowerCase() + n.slice(1);
3009
- }
3010
- function ze(n) {
3011
- let { start: e, end: t } = n;
3012
- return {
3013
- start: e,
3014
- end: t,
3015
- range: [e, t]
3016
- };
3017
- }
3018
- var qr = (n) => we.prototype._commentStart(n);
3019
- function jr(n, e) {
3020
- let t = e ? qr(n) : null;
3021
- if (t === null) return {
3022
- text: n,
3023
- comments: []
3024
- };
3025
- let s = {
3026
- type: "CommentLine",
3027
- value: n.slice(t + 2),
3028
- ...ze({
3029
- start: t,
3030
- end: n.length
3031
- })
3032
- };
3033
- return {
3034
- text: n.slice(0, t),
3035
- comments: [s]
3036
- };
3037
- }
3038
- function Ge(n, e = !0) {
3039
- return (t) => {
3040
- let r = new we(new qe()), { text: i, comments: a } = jr(t, e), l = n(i, r);
3041
- if (l.errors.length !== 0) {
3042
- let [{ message: h }] = l.errors;
3043
- throw new SyntaxError(h.replace(/^Parser Error: | at column \d+ in [^]*$/g, ""));
3044
- }
3045
- return {
3046
- result: l,
3047
- comments: a,
3048
- text: i
3049
- };
3050
- };
3051
- }
3052
- var ys = Ge((n, e) => e.parseBinding(n, "", 0));
3053
- Ge((n, e) => e.parseSimpleBinding(n, "", 0));
3054
- var _s = Ge((n, e) => e.parseAction(n, "", 0)), Cs = Ge((n, e) => e.parseInterpolationExpression(n, "", 0)), Ts = Ge((n, e) => e.parseTemplateBindings("", n, "", 0, 0), !1);
3055
- var Xr = (n, e, t) => {
3056
- if (!(n && e == null)) return Array.isArray(e) || typeof e == "string" ? e[t < 0 ? e.length + t : t] : e.at(t);
3057
- }, ut = Xr;
3058
- var qt = class {
3059
- text;
3060
- constructor(e) {
3061
- this.text = e;
3062
- }
3063
- getCharacterIndex(e, t) {
3064
- return Ss(this.text, e, t);
3065
- }
3066
- getCharacterLastIndex(e, t) {
3067
- return xs(this.text, e, t);
3068
- }
3069
- transformSpan(e, { stripSpaces: t = !1, hasParentParens: s = !1 } = {}) {
3070
- if (!t) return ze(e);
3071
- let { outerSpan: r, innerSpan: i, hasParens: a } = vs(e, this.text, s), l = ze(i);
3072
- return a && (l.extra = {
3073
- parenthesized: !0,
3074
- parenStart: r.start,
3075
- parenEnd: r.end
3076
- }), l;
3077
- }
3078
- createNode(e, { stripSpaces: t = !0, hasParentParens: s = !1 } = {}) {
3079
- let { type: r, start: i, end: a } = e, l = {
3080
- ...e,
3081
- ...this.transformSpan({
3082
- start: i,
3083
- end: a
3084
- }, {
3085
- stripSpaces: t,
3086
- hasParentParens: s
3087
- })
3088
- };
3089
- switch (r) {
3090
- case "NumericLiteral":
3091
- case "StringLiteral": {
3092
- let h = this.text.slice(l.start, l.end), { value: f } = l;
3093
- l.extra = {
3094
- ...l.extra,
3095
- raw: h,
3096
- rawValue: f
3097
- };
3098
- break;
3099
- }
3100
- case "ObjectProperty": {
3101
- let { shorthand: h } = l;
3102
- h && (l.extra = {
3103
- ...l.extra,
3104
- shorthand: h
3105
- });
3106
- break;
3107
- }
3108
- }
3109
- return l;
3110
- }
3111
- }, ks = qt;
3112
- function jt(n) {
3113
- var e;
3114
- return !!((e = n.extra) != null && e.parenthesized);
3115
- }
3116
- function $(n) {
3117
- return jt(n) ? n.extra.parenStart : n.start;
3118
- }
3119
- function R(n) {
3120
- return jt(n) ? n.extra.parenEnd : n.end;
3121
- }
3122
- function bs(n) {
3123
- return (n.type === "OptionalCallExpression" || n.type === "OptionalMemberExpression") && !jt(n);
3124
- }
3125
- function Is(n, e) {
3126
- let { start: t, end: s } = n.sourceSpan;
3127
- return t >= s || /^\s+$/.test(e.slice(t, s));
3128
- }
3129
- var Ye, xe, u, w, Xe, x, pt, Je = class extends ks {
3130
- constructor(t, s) {
3131
- super(s);
3132
- V(this, u);
3133
- V(this, Ye);
3134
- V(this, xe);
3135
- te(this, Ye, t), te(this, xe, s);
3136
- }
3137
- get node() {
3138
- return c(this, u, x).call(this, L(this, Ye));
3139
- }
3140
- transformNode(t) {
3141
- return c(this, u, pt).call(this, t);
3142
- }
3143
- };
3144
- Ye = /* @__PURE__ */ new WeakMap(), xe = /* @__PURE__ */ new WeakMap(), u = /* @__PURE__ */ new WeakSet(), w = function(t, { stripSpaces: s = !0, hasParentParens: r = !1 } = {}) {
3145
- return this.createNode(t, {
3146
- stripSpaces: s,
3147
- hasParentParens: r
3148
- });
3149
- }, Xe = function(t, s, { computed: r, optional: i, end: a = R(s), hasParentParens: l = !1 }) {
3150
- if (Is(t, L(this, xe)) || t.sourceSpan.start === s.start) return s;
3151
- let h = c(this, u, x).call(this, t), f = bs(h);
3152
- return c(this, u, w).call(this, {
3153
- type: i || f ? "OptionalMemberExpression" : "MemberExpression",
3154
- object: h,
3155
- property: s,
3156
- computed: r,
3157
- ...i ? { optional: !0 } : f ? { optional: !1 } : void 0,
3158
- start: $(h),
3159
- end: a
3160
- }, { hasParentParens: l });
3161
- }, x = function(t, s) {
3162
- return c(this, u, pt).call(this, t, s);
3163
- }, pt = function(t, s) {
3164
- let { isInParentParens: r } = {
3165
- isInParentParens: !1,
3166
- ...s
3167
- };
3168
- if (t instanceof Vt) {
3169
- let { expressions: i } = t;
3170
- if (i.length !== 1) throw new Error("Unexpected 'Interpolation'");
3171
- return c(this, u, x).call(this, i[0]);
3172
- }
3173
- if (t instanceof X) return c(this, u, w).call(this, {
3174
- type: "UnaryExpression",
3175
- prefix: !0,
3176
- argument: c(this, u, x).call(this, t.expr),
3177
- operator: t.operator,
3178
- ...t.sourceSpan
3179
- }, { hasParentParens: r });
3180
- if (t instanceof A) {
3181
- let { left: i, operation: a, right: l } = t, h = c(this, u, x).call(this, i), f = c(this, u, x).call(this, l), y = {
3182
- left: h,
3183
- right: f,
3184
- start: $(h),
3185
- end: R(f)
3186
- };
3187
- return a === "&&" || a === "||" || a === "??" ? c(this, u, w).call(this, {
3188
- ...y,
3189
- type: "LogicalExpression",
3190
- operator: a
3191
- }, { hasParentParens: r }) : c(this, u, w).call(this, {
3192
- ...y,
3193
- type: "BinaryExpression",
3194
- operator: a
3195
- }, { hasParentParens: r });
3196
- }
3197
- if (t instanceof Be) {
3198
- let { exp: i, name: a, args: l } = t, h = c(this, u, x).call(this, i), f = $(h), v = R(h), E = this.getCharacterIndex(/\S/, this.getCharacterIndex("|", v) + 1), y = c(this, u, w).call(this, {
3199
- type: "Identifier",
3200
- name: a,
3201
- start: E,
3202
- end: E + a.length
3203
- }), T = l.map((k) => c(this, u, x).call(this, k));
3204
- return c(this, u, w).call(this, {
3205
- type: "NGPipeExpression",
3206
- left: h,
3207
- right: y,
3208
- arguments: T,
3209
- start: f,
3210
- end: R(T.length === 0 ? y : ut(!1, T, -1))
3211
- }, { hasParentParens: r });
3212
- }
3213
- if (t instanceof Le) return c(this, u, w).call(this, {
3214
- type: "NGChainedExpression",
3215
- expressions: t.expressions.map((i) => c(this, u, x).call(this, i)),
3216
- ...t.sourceSpan
3217
- }, { hasParentParens: r });
3218
- if (t instanceof Me) {
3219
- let { condition: i, trueExp: a, falseExp: l } = t, h = c(this, u, x).call(this, i), f = c(this, u, x).call(this, a), v = c(this, u, x).call(this, l);
3220
- return c(this, u, w).call(this, {
3221
- type: "ConditionalExpression",
3222
- test: h,
3223
- consequent: f,
3224
- alternate: v,
3225
- start: $(h),
3226
- end: R(v)
3227
- }, { hasParentParens: r });
3228
- }
3229
- if (t instanceof P) return c(this, u, w).call(this, {
3230
- type: "NGEmptyExpression",
3231
- ...t.sourceSpan
3232
- }, { hasParentParens: r });
3233
- if (t instanceof Y) return c(this, u, w).call(this, {
3234
- type: "ThisExpression",
3235
- ...t.sourceSpan
3236
- }, { hasParentParens: r });
3237
- if (t instanceof Re || t instanceof ue) return c(this, u, Xe).call(this, t.receiver, c(this, u, x).call(this, t.key), {
3238
- computed: !0,
3239
- optional: t instanceof ue,
3240
- end: t.sourceSpan.end,
3241
- hasParentParens: r
3242
- });
3243
- if (t instanceof Oe) return c(this, u, w).call(this, {
3244
- type: "ArrayExpression",
3245
- elements: t.expressions.map((i) => c(this, u, x).call(this, i)),
3246
- ...t.sourceSpan
3247
- }, { hasParentParens: r });
3248
- if (t instanceof Fe) {
3249
- let { keys: i, values: a } = t, l = a.map((f) => c(this, u, x).call(this, f)), h = i.map(({ key: f, quoted: v }, E) => {
3250
- let y = l[E], T = $(y), k = R(y), F = this.getCharacterIndex(/\S/, E === 0 ? t.sourceSpan.start + 1 : this.getCharacterIndex(",", R(l[E - 1])) + 1), ye = {
3251
- start: F,
3252
- end: T === F ? k : this.getCharacterLastIndex(/\S/, this.getCharacterLastIndex(":", T - 1) - 1) + 1
3253
- }, j = v ? c(this, u, w).call(this, {
3254
- type: "StringLiteral",
3255
- value: f,
3256
- ...ye
3257
- }) : c(this, u, w).call(this, {
3258
- type: "Identifier",
3259
- name: f,
3260
- ...ye
3261
- }), en = j.end < j.start || F === T;
3262
- return c(this, u, w).call(this, {
3263
- type: "ObjectProperty",
3264
- key: j,
3265
- value: y,
3266
- shorthand: en,
3267
- computed: !1,
3268
- start: $(j),
3269
- end: k
3270
- });
3271
- });
3272
- return c(this, u, w).call(this, {
3273
- type: "ObjectExpression",
3274
- properties: h,
3275
- ...t.sourceSpan
3276
- }, { hasParentParens: r });
3277
- }
3278
- if (t instanceof I) {
3279
- let { value: i } = t;
3280
- switch (typeof i) {
3281
- case "boolean": return c(this, u, w).call(this, {
3282
- type: "BooleanLiteral",
3283
- value: i,
3284
- ...t.sourceSpan
3285
- }, { hasParentParens: r });
3286
- case "number": return c(this, u, w).call(this, {
3287
- type: "NumericLiteral",
3288
- value: i,
3289
- ...t.sourceSpan
3290
- }, { hasParentParens: r });
3291
- case "object": return c(this, u, w).call(this, {
3292
- type: "NullLiteral",
3293
- ...t.sourceSpan
3294
- }, { hasParentParens: r });
3295
- case "string": return c(this, u, w).call(this, {
3296
- type: "StringLiteral",
3297
- value: i,
3298
- ...t.sourceSpan
3299
- }, { hasParentParens: r });
3300
- case "undefined": return c(this, u, w).call(this, {
3301
- type: "Identifier",
3302
- name: "undefined",
3303
- ...t.sourceSpan
3304
- }, { hasParentParens: r });
3305
- default: throw new Error(`Unexpected LiteralPrimitive value type ${typeof i}`);
3306
- }
3307
- }
3308
- if (t instanceof Ue || t instanceof pe) {
3309
- let i = t instanceof pe, { receiver: a, args: l } = t, h = l.length === 1 ? [c(this, u, x).call(this, l[0], { isInParentParens: !0 })] : l.map((y) => c(this, u, x).call(this, y)), f = c(this, u, x).call(this, a), v = bs(f), E = i || v ? "OptionalCallExpression" : "CallExpression";
3310
- return c(this, u, w).call(this, {
3311
- type: E,
3312
- callee: f,
3313
- arguments: h,
3314
- ...E === "OptionalCallExpression" ? { optional: i } : void 0,
3315
- start: $(f),
3316
- end: t.sourceSpan.end
3317
- }, { hasParentParens: r });
3318
- }
3319
- if (t instanceof Ve) {
3320
- let i = c(this, u, x).call(this, t.expression);
3321
- return c(this, u, w).call(this, {
3322
- type: "TSNonNullExpression",
3323
- expression: i,
3324
- start: $(i),
3325
- end: t.sourceSpan.end
3326
- }, { hasParentParens: r });
3327
- }
3328
- if (t instanceof Q || t instanceof K || t instanceof Z) {
3329
- let i = t instanceof Q ? "!" : t instanceof K ? "typeof" : t instanceof Z ? "void" : void 0;
3330
- if (!i) throw new Error("Unexpected expression.");
3331
- let { start: a } = t.sourceSpan;
3332
- if (i === "typeof" || i === "void") {
3333
- let h = this.text.lastIndexOf(i, a);
3334
- if (h === -1) throw new Error(`Cannot find operator '${i}' from index ${a} in ${JSON.stringify(this.text)}`);
3335
- a = h;
3336
- }
3337
- let l = c(this, u, x).call(this, t.expression);
3338
- return c(this, u, w).call(this, {
3339
- type: "UnaryExpression",
3340
- prefix: !0,
3341
- operator: i,
3342
- argument: l,
3343
- start: a,
3344
- end: R(l)
3345
- }, { hasParentParens: r });
3346
- }
3347
- if (t instanceof le || t instanceof ce) {
3348
- let { receiver: i, name: a } = t, l = this.getCharacterLastIndex(/\S/, t.sourceSpan.end - 1) + 1, h = c(this, u, w).call(this, {
3349
- type: "Identifier",
3350
- name: a,
3351
- start: l - a.length,
3352
- end: l
3353
- }, Is(i, L(this, xe)) ? { hasParentParens: r } : {});
3354
- return c(this, u, Xe).call(this, i, h, {
3355
- computed: !1,
3356
- optional: t instanceof ce,
3357
- hasParentParens: r
3358
- });
3359
- }
3360
- if (t instanceof De) {
3361
- let i = c(this, u, x).call(this, t.key), a = c(this, u, x).call(this, t.value), l = c(this, u, Xe).call(this, t.receiver, i, {
3362
- computed: !0,
3363
- optional: !1,
3364
- end: this.getCharacterIndex("]", R(i)) + 1
3365
- });
3366
- return c(this, u, w).call(this, {
3367
- type: "AssignmentExpression",
3368
- left: l,
3369
- operator: "=",
3370
- right: a,
3371
- start: $(l),
3372
- end: R(a)
3373
- }, { hasParentParens: r });
3374
- }
3375
- if (t instanceof $e) {
3376
- let { receiver: i, name: a, value: l } = t, h = c(this, u, x).call(this, l), f = this.getCharacterLastIndex(/\S/, this.getCharacterLastIndex("=", $(h) - 1) - 1) + 1, v = c(this, u, w).call(this, {
3377
- type: "Identifier",
3378
- name: a,
3379
- start: f - a.length,
3380
- end: f
3381
- }), E = c(this, u, Xe).call(this, i, v, {
3382
- computed: !1,
3383
- optional: !1
3384
- });
3385
- return c(this, u, w).call(this, {
3386
- type: "AssignmentExpression",
3387
- left: E,
3388
- operator: "=",
3389
- right: h,
3390
- start: $(E),
3391
- end: R(h)
3392
- }, { hasParentParens: r });
3393
- }
3394
- if (t instanceof he) return c(this, u, w).call(this, {
3395
- type: "TaggedTemplateExpression",
3396
- tag: c(this, u, x).call(this, t.tag),
3397
- quasi: c(this, u, x).call(this, t.template),
3398
- ...t.sourceSpan
3399
- });
3400
- if (t instanceof fe) {
3401
- let { elements: i, expressions: a } = t;
3402
- return c(this, u, w).call(this, {
3403
- type: "TemplateLiteral",
3404
- quasis: i.map((l) => c(this, u, x).call(this, l, { parent: t })),
3405
- expressions: a.map((l) => c(this, u, x).call(this, l)),
3406
- ...t.sourceSpan
3407
- });
3408
- }
3409
- if (t instanceof de) {
3410
- let { elements: i } = s.parent, a = i.indexOf(t), l = a === 0, h = a === i.length - 1, f = t.sourceSpan.end - (h ? 1 : 0), v = t.sourceSpan.start + (l ? 1 : 0), E = this.text.slice(v, f);
3411
- return c(this, u, w).call(this, {
3412
- type: "TemplateElement",
3413
- value: {
3414
- cooked: t.text,
3415
- raw: E
3416
- },
3417
- start: v,
3418
- end: f,
3419
- tail: h
3420
- }, { stripSpaces: !1 });
3421
- }
3422
- if (t instanceof He) return c(this, u, pt).call(this, t.expression);
3423
- throw new Error(`Unexpected node type '${t.constructor.name}'`);
3424
- };
3425
- function Ns(n, e) {
3426
- return new Je(n, e).node;
3427
- }
3428
- function As(n) {
3429
- return n instanceof We;
3430
- }
3431
- function Ps(n) {
3432
- return n instanceof me;
3433
- }
3434
- var Se, ee, g, Ls, N, Gt, Xt, Jt, Ms, $s, Rs, Ds, zt = class extends Je {
3435
- constructor(t, s) {
3436
- super(void 0, s);
3437
- V(this, g);
3438
- V(this, Se);
3439
- V(this, ee);
3440
- te(this, Se, t), te(this, ee, s);
3441
- for (let r of t) c(this, g, Ms).call(this, r);
3442
- }
3443
- get expressions() {
3444
- return c(this, g, Rs).call(this);
3445
- }
3446
- };
3447
- Se = /* @__PURE__ */ new WeakMap(), ee = /* @__PURE__ */ new WeakMap(), g = /* @__PURE__ */ new WeakSet(), Ls = function() {
3448
- return L(this, Se)[0].key;
3449
- }, N = function(t, { stripSpaces: s = !0 } = {}) {
3450
- return this.createNode(t, { stripSpaces: s });
3451
- }, Gt = function(t) {
3452
- return this.transformNode(t);
3453
- }, Xt = function(t) {
3454
- return Es(t.slice(L(this, g, Ls).source.length));
3455
- }, Jt = function(t) {
3456
- let s = L(this, ee);
3457
- if (s[t.start] !== "\"" && s[t.start] !== "'") return;
3458
- let r = s[t.start], i = !1;
3459
- for (let a = t.start + 1; a < s.length; a++) switch (s[a]) {
3460
- case r: if (!i) {
3461
- t.end = a + 1;
3462
- return;
3463
- }
3464
- default:
3465
- i = !1;
3466
- break;
3467
- case "\\":
3468
- i = !i;
3469
- break;
3470
- }
3471
- }, Ms = function(t) {
3472
- c(this, g, Jt).call(this, t.key.span), Ps(t) && t.value && c(this, g, Jt).call(this, t.value.span);
3473
- }, $s = function(t) {
3474
- if (!t.value || t.value.source) return t.value;
3475
- let s = this.getCharacterIndex(/\S/, t.sourceSpan.start);
3476
- return {
3477
- source: "$implicit",
3478
- span: {
3479
- start: s,
3480
- end: s
3481
- }
3482
- };
3483
- }, Rs = function() {
3484
- let t = L(this, Se), [s] = t, r = L(this, ee).slice(s.sourceSpan.start, s.sourceSpan.end).trim().length === 0 ? t.slice(1) : t, i = [], a = null;
3485
- for (let [l, h] of r.entries()) {
3486
- if (a && As(a) && Ps(h) && h.value && h.value.source === a.key.source) {
3487
- let f = c(this, g, N).call(this, {
3488
- type: "NGMicrosyntaxKey",
3489
- name: h.key.source,
3490
- ...h.key.span
3491
- }), v = (T, k) => ({
3492
- ...T,
3493
- ...this.transformSpan({
3494
- start: T.start,
3495
- end: k
3496
- })
3497
- }), E = (T) => ({
3498
- ...v(T, f.end),
3499
- alias: f
3500
- }), y = i.pop();
3501
- if (y.type === "NGMicrosyntaxExpression") i.push(E(y));
3502
- else if (y.type === "NGMicrosyntaxKeyedExpression") {
3503
- let T = E(y.expression);
3504
- i.push(v({
3505
- ...y,
3506
- expression: T
3507
- }, T.end));
3508
- } else throw new Error(`Unexpected type ${y.type}`);
3509
- } else i.push(c(this, g, Ds).call(this, h, l));
3510
- a = h;
3511
- }
3512
- return c(this, g, N).call(this, {
3513
- type: "NGMicrosyntax",
3514
- body: i,
3515
- ...i.length === 0 ? t[0].sourceSpan : {
3516
- start: i[0].start,
3517
- end: ut(!1, i, -1).end
3518
- }
3519
- });
3520
- }, Ds = function(t, s) {
3521
- if (As(t)) {
3522
- let { key: r, value: i } = t;
3523
- return i ? s === 0 ? c(this, g, N).call(this, {
3524
- type: "NGMicrosyntaxExpression",
3525
- expression: c(this, g, Gt).call(this, i.ast),
3526
- alias: null,
3527
- ...i.sourceSpan
3528
- }) : c(this, g, N).call(this, {
3529
- type: "NGMicrosyntaxKeyedExpression",
3530
- key: c(this, g, N).call(this, {
3531
- type: "NGMicrosyntaxKey",
3532
- name: c(this, g, Xt).call(this, r.source),
3533
- ...r.span
3534
- }),
3535
- expression: c(this, g, N).call(this, {
3536
- type: "NGMicrosyntaxExpression",
3537
- expression: c(this, g, Gt).call(this, i.ast),
3538
- alias: null,
3539
- ...i.sourceSpan
3540
- }),
3541
- start: r.span.start,
3542
- end: i.sourceSpan.end
3543
- }) : c(this, g, N).call(this, {
3544
- type: "NGMicrosyntaxKey",
3545
- name: c(this, g, Xt).call(this, r.source),
3546
- ...r.span
3547
- });
3548
- } else {
3549
- let { key: r, sourceSpan: i } = t;
3550
- if (/^let\s$/.test(L(this, ee).slice(i.start, i.start + 4))) {
3551
- let { value: l } = t;
3552
- return c(this, g, N).call(this, {
3553
- type: "NGMicrosyntaxLet",
3554
- key: c(this, g, N).call(this, {
3555
- type: "NGMicrosyntaxKey",
3556
- name: r.source,
3557
- ...r.span
3558
- }),
3559
- value: l ? c(this, g, N).call(this, {
3560
- type: "NGMicrosyntaxKey",
3561
- name: l.source,
3562
- ...l.span
3563
- }) : null,
3564
- start: i.start,
3565
- end: l ? l.span.end : r.span.end
3566
- });
3567
- } else {
3568
- let l = c(this, g, $s).call(this, t);
3569
- return c(this, g, N).call(this, {
3570
- type: "NGMicrosyntaxAs",
3571
- key: c(this, g, N).call(this, {
3572
- type: "NGMicrosyntaxKey",
3573
- name: l.source,
3574
- ...l.span
3575
- }),
3576
- alias: c(this, g, N).call(this, {
3577
- type: "NGMicrosyntaxKey",
3578
- name: r.source,
3579
- ...r.span
3580
- }),
3581
- start: l.span.start,
3582
- end: r.span.end
3583
- });
3584
- }
3585
- }
3586
- };
3587
- function Bs(n, e) {
3588
- return new zt(n, e).expressions;
3589
- }
3590
- function ht({ result: { ast: n }, text: e, comments: t }) {
3591
- return Object.assign(Ns(n, e), { comments: t });
3592
- }
3593
- function Os({ result: { templateBindings: n }, text: e }) {
3594
- return Bs(n, e);
3595
- }
3596
- var Fs = (n) => ht(ys(n));
3597
- var Vs = (n) => ht(Cs(n)), Yt = (n) => ht(_s(n)), Us = (n) => Os(Ts(n));
3598
- function Qt(n) {
3599
- var s, r, i;
3600
- let e = ((s = n.range) == null ? void 0 : s[0]) ?? n.start, t = (i = ((r = n.declaration) == null ? void 0 : r.decorators) ?? n.decorators) == null ? void 0 : i[0];
3601
- return t ? Math.min(Qt(t), e) : e;
3602
- }
3603
- function Hs(n) {
3604
- var t;
3605
- return ((t = n.range) == null ? void 0 : t[1]) ?? n.end;
3606
- }
3607
- function ft(n) {
3608
- return {
3609
- astFormat: "estree",
3610
- parse(e) {
3611
- let t = n(e);
3612
- return {
3613
- type: "NGRoot",
3614
- node: n === Yt && t.type !== "NGChainedExpression" ? {
3615
- ...t,
3616
- type: "NGChainedExpression",
3617
- expressions: [t]
3618
- } : t
3619
- };
3620
- },
3621
- locStart: Qt,
3622
- locEnd: Hs
3623
- };
3624
- }
3625
- var Jr = ft(Yt), Yr = ft(Fs), Qr = ft(Vs), Kr = ft(Us);
3626
- var ho = Zt;
3627
-
3628
- //#endregion
3629
- exports.default = ho;
3630
- exports.parsers = Kt;
3631
- //# sourceMappingURL=angular-Bp0XO9db.cjs.map