1 | /**
|
---|
2 | * @license
|
---|
3 | * Copyright Google LLC All Rights Reserved.
|
---|
4 | *
|
---|
5 | * Use of this source code is governed by an MIT-style license that can be
|
---|
6 | * found in the LICENSE file at https://angular.io/license
|
---|
7 | */
|
---|
8 | (function (factory) {
|
---|
9 | if (typeof module === "object" && typeof module.exports === "object") {
|
---|
10 | var v = factory(require, exports);
|
---|
11 | if (v !== undefined) module.exports = v;
|
---|
12 | }
|
---|
13 | else if (typeof define === "function" && define.amd) {
|
---|
14 | define("@angular/compiler/src/render3/r3_ast", ["require", "exports", "tslib"], factory);
|
---|
15 | }
|
---|
16 | })(function (require, exports) {
|
---|
17 | "use strict";
|
---|
18 | Object.defineProperty(exports, "__esModule", { value: true });
|
---|
19 | exports.transformAll = exports.visitAll = exports.TransformVisitor = exports.RecursiveVisitor = exports.NullVisitor = exports.Icu = exports.Reference = exports.Variable = exports.Content = exports.Template = exports.Element = exports.BoundEvent = exports.BoundAttribute = exports.TextAttribute = exports.BoundText = exports.Text = exports.Comment = void 0;
|
---|
20 | var tslib_1 = require("tslib");
|
---|
21 | /**
|
---|
22 | * This is an R3 `Node`-like wrapper for a raw `html.Comment` node. We do not currently
|
---|
23 | * require the implementation of a visitor for Comments as they are only collected at
|
---|
24 | * the top-level of the R3 AST, and only if `Render3ParseOptions['collectCommentNodes']`
|
---|
25 | * is true.
|
---|
26 | */
|
---|
27 | var Comment = /** @class */ (function () {
|
---|
28 | function Comment(value, sourceSpan) {
|
---|
29 | this.value = value;
|
---|
30 | this.sourceSpan = sourceSpan;
|
---|
31 | }
|
---|
32 | Comment.prototype.visit = function (_visitor) {
|
---|
33 | throw new Error('visit() not implemented for Comment');
|
---|
34 | };
|
---|
35 | return Comment;
|
---|
36 | }());
|
---|
37 | exports.Comment = Comment;
|
---|
38 | var Text = /** @class */ (function () {
|
---|
39 | function Text(value, sourceSpan) {
|
---|
40 | this.value = value;
|
---|
41 | this.sourceSpan = sourceSpan;
|
---|
42 | }
|
---|
43 | Text.prototype.visit = function (visitor) {
|
---|
44 | return visitor.visitText(this);
|
---|
45 | };
|
---|
46 | return Text;
|
---|
47 | }());
|
---|
48 | exports.Text = Text;
|
---|
49 | var BoundText = /** @class */ (function () {
|
---|
50 | function BoundText(value, sourceSpan, i18n) {
|
---|
51 | this.value = value;
|
---|
52 | this.sourceSpan = sourceSpan;
|
---|
53 | this.i18n = i18n;
|
---|
54 | }
|
---|
55 | BoundText.prototype.visit = function (visitor) {
|
---|
56 | return visitor.visitBoundText(this);
|
---|
57 | };
|
---|
58 | return BoundText;
|
---|
59 | }());
|
---|
60 | exports.BoundText = BoundText;
|
---|
61 | /**
|
---|
62 | * Represents a text attribute in the template.
|
---|
63 | *
|
---|
64 | * `valueSpan` may not be present in cases where there is no value `<div a></div>`.
|
---|
65 | * `keySpan` may also not be present for synthetic attributes from ICU expansions.
|
---|
66 | */
|
---|
67 | var TextAttribute = /** @class */ (function () {
|
---|
68 | function TextAttribute(name, value, sourceSpan, keySpan, valueSpan, i18n) {
|
---|
69 | this.name = name;
|
---|
70 | this.value = value;
|
---|
71 | this.sourceSpan = sourceSpan;
|
---|
72 | this.keySpan = keySpan;
|
---|
73 | this.valueSpan = valueSpan;
|
---|
74 | this.i18n = i18n;
|
---|
75 | }
|
---|
76 | TextAttribute.prototype.visit = function (visitor) {
|
---|
77 | return visitor.visitTextAttribute(this);
|
---|
78 | };
|
---|
79 | return TextAttribute;
|
---|
80 | }());
|
---|
81 | exports.TextAttribute = TextAttribute;
|
---|
82 | var BoundAttribute = /** @class */ (function () {
|
---|
83 | function BoundAttribute(name, type, securityContext, value, unit, sourceSpan, keySpan, valueSpan, i18n) {
|
---|
84 | this.name = name;
|
---|
85 | this.type = type;
|
---|
86 | this.securityContext = securityContext;
|
---|
87 | this.value = value;
|
---|
88 | this.unit = unit;
|
---|
89 | this.sourceSpan = sourceSpan;
|
---|
90 | this.keySpan = keySpan;
|
---|
91 | this.valueSpan = valueSpan;
|
---|
92 | this.i18n = i18n;
|
---|
93 | }
|
---|
94 | BoundAttribute.fromBoundElementProperty = function (prop, i18n) {
|
---|
95 | if (prop.keySpan === undefined) {
|
---|
96 | throw new Error("Unexpected state: keySpan must be defined for bound attributes but was not for " + prop.name + ": " + prop.sourceSpan);
|
---|
97 | }
|
---|
98 | return new BoundAttribute(prop.name, prop.type, prop.securityContext, prop.value, prop.unit, prop.sourceSpan, prop.keySpan, prop.valueSpan, i18n);
|
---|
99 | };
|
---|
100 | BoundAttribute.prototype.visit = function (visitor) {
|
---|
101 | return visitor.visitBoundAttribute(this);
|
---|
102 | };
|
---|
103 | return BoundAttribute;
|
---|
104 | }());
|
---|
105 | exports.BoundAttribute = BoundAttribute;
|
---|
106 | var BoundEvent = /** @class */ (function () {
|
---|
107 | function BoundEvent(name, type, handler, target, phase, sourceSpan, handlerSpan, keySpan) {
|
---|
108 | this.name = name;
|
---|
109 | this.type = type;
|
---|
110 | this.handler = handler;
|
---|
111 | this.target = target;
|
---|
112 | this.phase = phase;
|
---|
113 | this.sourceSpan = sourceSpan;
|
---|
114 | this.handlerSpan = handlerSpan;
|
---|
115 | this.keySpan = keySpan;
|
---|
116 | }
|
---|
117 | BoundEvent.fromParsedEvent = function (event) {
|
---|
118 | var target = event.type === 0 /* Regular */ ? event.targetOrPhase : null;
|
---|
119 | var phase = event.type === 1 /* Animation */ ? event.targetOrPhase : null;
|
---|
120 | if (event.keySpan === undefined) {
|
---|
121 | throw new Error("Unexpected state: keySpan must be defined for bound event but was not for " + event.name + ": " + event.sourceSpan);
|
---|
122 | }
|
---|
123 | return new BoundEvent(event.name, event.type, event.handler, target, phase, event.sourceSpan, event.handlerSpan, event.keySpan);
|
---|
124 | };
|
---|
125 | BoundEvent.prototype.visit = function (visitor) {
|
---|
126 | return visitor.visitBoundEvent(this);
|
---|
127 | };
|
---|
128 | return BoundEvent;
|
---|
129 | }());
|
---|
130 | exports.BoundEvent = BoundEvent;
|
---|
131 | var Element = /** @class */ (function () {
|
---|
132 | function Element(name, attributes, inputs, outputs, children, references, sourceSpan, startSourceSpan, endSourceSpan, i18n) {
|
---|
133 | this.name = name;
|
---|
134 | this.attributes = attributes;
|
---|
135 | this.inputs = inputs;
|
---|
136 | this.outputs = outputs;
|
---|
137 | this.children = children;
|
---|
138 | this.references = references;
|
---|
139 | this.sourceSpan = sourceSpan;
|
---|
140 | this.startSourceSpan = startSourceSpan;
|
---|
141 | this.endSourceSpan = endSourceSpan;
|
---|
142 | this.i18n = i18n;
|
---|
143 | }
|
---|
144 | Element.prototype.visit = function (visitor) {
|
---|
145 | return visitor.visitElement(this);
|
---|
146 | };
|
---|
147 | return Element;
|
---|
148 | }());
|
---|
149 | exports.Element = Element;
|
---|
150 | var Template = /** @class */ (function () {
|
---|
151 | function Template(tagName, attributes, inputs, outputs, templateAttrs, children, references, variables, sourceSpan, startSourceSpan, endSourceSpan, i18n) {
|
---|
152 | this.tagName = tagName;
|
---|
153 | this.attributes = attributes;
|
---|
154 | this.inputs = inputs;
|
---|
155 | this.outputs = outputs;
|
---|
156 | this.templateAttrs = templateAttrs;
|
---|
157 | this.children = children;
|
---|
158 | this.references = references;
|
---|
159 | this.variables = variables;
|
---|
160 | this.sourceSpan = sourceSpan;
|
---|
161 | this.startSourceSpan = startSourceSpan;
|
---|
162 | this.endSourceSpan = endSourceSpan;
|
---|
163 | this.i18n = i18n;
|
---|
164 | }
|
---|
165 | Template.prototype.visit = function (visitor) {
|
---|
166 | return visitor.visitTemplate(this);
|
---|
167 | };
|
---|
168 | return Template;
|
---|
169 | }());
|
---|
170 | exports.Template = Template;
|
---|
171 | var Content = /** @class */ (function () {
|
---|
172 | function Content(selector, attributes, sourceSpan, i18n) {
|
---|
173 | this.selector = selector;
|
---|
174 | this.attributes = attributes;
|
---|
175 | this.sourceSpan = sourceSpan;
|
---|
176 | this.i18n = i18n;
|
---|
177 | this.name = 'ng-content';
|
---|
178 | }
|
---|
179 | Content.prototype.visit = function (visitor) {
|
---|
180 | return visitor.visitContent(this);
|
---|
181 | };
|
---|
182 | return Content;
|
---|
183 | }());
|
---|
184 | exports.Content = Content;
|
---|
185 | var Variable = /** @class */ (function () {
|
---|
186 | function Variable(name, value, sourceSpan, keySpan, valueSpan) {
|
---|
187 | this.name = name;
|
---|
188 | this.value = value;
|
---|
189 | this.sourceSpan = sourceSpan;
|
---|
190 | this.keySpan = keySpan;
|
---|
191 | this.valueSpan = valueSpan;
|
---|
192 | }
|
---|
193 | Variable.prototype.visit = function (visitor) {
|
---|
194 | return visitor.visitVariable(this);
|
---|
195 | };
|
---|
196 | return Variable;
|
---|
197 | }());
|
---|
198 | exports.Variable = Variable;
|
---|
199 | var Reference = /** @class */ (function () {
|
---|
200 | function Reference(name, value, sourceSpan, keySpan, valueSpan) {
|
---|
201 | this.name = name;
|
---|
202 | this.value = value;
|
---|
203 | this.sourceSpan = sourceSpan;
|
---|
204 | this.keySpan = keySpan;
|
---|
205 | this.valueSpan = valueSpan;
|
---|
206 | }
|
---|
207 | Reference.prototype.visit = function (visitor) {
|
---|
208 | return visitor.visitReference(this);
|
---|
209 | };
|
---|
210 | return Reference;
|
---|
211 | }());
|
---|
212 | exports.Reference = Reference;
|
---|
213 | var Icu = /** @class */ (function () {
|
---|
214 | function Icu(vars, placeholders, sourceSpan, i18n) {
|
---|
215 | this.vars = vars;
|
---|
216 | this.placeholders = placeholders;
|
---|
217 | this.sourceSpan = sourceSpan;
|
---|
218 | this.i18n = i18n;
|
---|
219 | }
|
---|
220 | Icu.prototype.visit = function (visitor) {
|
---|
221 | return visitor.visitIcu(this);
|
---|
222 | };
|
---|
223 | return Icu;
|
---|
224 | }());
|
---|
225 | exports.Icu = Icu;
|
---|
226 | var NullVisitor = /** @class */ (function () {
|
---|
227 | function NullVisitor() {
|
---|
228 | }
|
---|
229 | NullVisitor.prototype.visitElement = function (element) { };
|
---|
230 | NullVisitor.prototype.visitTemplate = function (template) { };
|
---|
231 | NullVisitor.prototype.visitContent = function (content) { };
|
---|
232 | NullVisitor.prototype.visitVariable = function (variable) { };
|
---|
233 | NullVisitor.prototype.visitReference = function (reference) { };
|
---|
234 | NullVisitor.prototype.visitTextAttribute = function (attribute) { };
|
---|
235 | NullVisitor.prototype.visitBoundAttribute = function (attribute) { };
|
---|
236 | NullVisitor.prototype.visitBoundEvent = function (attribute) { };
|
---|
237 | NullVisitor.prototype.visitText = function (text) { };
|
---|
238 | NullVisitor.prototype.visitBoundText = function (text) { };
|
---|
239 | NullVisitor.prototype.visitIcu = function (icu) { };
|
---|
240 | return NullVisitor;
|
---|
241 | }());
|
---|
242 | exports.NullVisitor = NullVisitor;
|
---|
243 | var RecursiveVisitor = /** @class */ (function () {
|
---|
244 | function RecursiveVisitor() {
|
---|
245 | }
|
---|
246 | RecursiveVisitor.prototype.visitElement = function (element) {
|
---|
247 | visitAll(this, element.attributes);
|
---|
248 | visitAll(this, element.inputs);
|
---|
249 | visitAll(this, element.outputs);
|
---|
250 | visitAll(this, element.children);
|
---|
251 | visitAll(this, element.references);
|
---|
252 | };
|
---|
253 | RecursiveVisitor.prototype.visitTemplate = function (template) {
|
---|
254 | visitAll(this, template.attributes);
|
---|
255 | visitAll(this, template.inputs);
|
---|
256 | visitAll(this, template.outputs);
|
---|
257 | visitAll(this, template.children);
|
---|
258 | visitAll(this, template.references);
|
---|
259 | visitAll(this, template.variables);
|
---|
260 | };
|
---|
261 | RecursiveVisitor.prototype.visitContent = function (content) { };
|
---|
262 | RecursiveVisitor.prototype.visitVariable = function (variable) { };
|
---|
263 | RecursiveVisitor.prototype.visitReference = function (reference) { };
|
---|
264 | RecursiveVisitor.prototype.visitTextAttribute = function (attribute) { };
|
---|
265 | RecursiveVisitor.prototype.visitBoundAttribute = function (attribute) { };
|
---|
266 | RecursiveVisitor.prototype.visitBoundEvent = function (attribute) { };
|
---|
267 | RecursiveVisitor.prototype.visitText = function (text) { };
|
---|
268 | RecursiveVisitor.prototype.visitBoundText = function (text) { };
|
---|
269 | RecursiveVisitor.prototype.visitIcu = function (icu) { };
|
---|
270 | return RecursiveVisitor;
|
---|
271 | }());
|
---|
272 | exports.RecursiveVisitor = RecursiveVisitor;
|
---|
273 | var TransformVisitor = /** @class */ (function () {
|
---|
274 | function TransformVisitor() {
|
---|
275 | }
|
---|
276 | TransformVisitor.prototype.visitElement = function (element) {
|
---|
277 | var newAttributes = transformAll(this, element.attributes);
|
---|
278 | var newInputs = transformAll(this, element.inputs);
|
---|
279 | var newOutputs = transformAll(this, element.outputs);
|
---|
280 | var newChildren = transformAll(this, element.children);
|
---|
281 | var newReferences = transformAll(this, element.references);
|
---|
282 | if (newAttributes != element.attributes || newInputs != element.inputs ||
|
---|
283 | newOutputs != element.outputs || newChildren != element.children ||
|
---|
284 | newReferences != element.references) {
|
---|
285 | return new Element(element.name, newAttributes, newInputs, newOutputs, newChildren, newReferences, element.sourceSpan, element.startSourceSpan, element.endSourceSpan);
|
---|
286 | }
|
---|
287 | return element;
|
---|
288 | };
|
---|
289 | TransformVisitor.prototype.visitTemplate = function (template) {
|
---|
290 | var newAttributes = transformAll(this, template.attributes);
|
---|
291 | var newInputs = transformAll(this, template.inputs);
|
---|
292 | var newOutputs = transformAll(this, template.outputs);
|
---|
293 | var newTemplateAttrs = transformAll(this, template.templateAttrs);
|
---|
294 | var newChildren = transformAll(this, template.children);
|
---|
295 | var newReferences = transformAll(this, template.references);
|
---|
296 | var newVariables = transformAll(this, template.variables);
|
---|
297 | if (newAttributes != template.attributes || newInputs != template.inputs ||
|
---|
298 | newOutputs != template.outputs || newTemplateAttrs != template.templateAttrs ||
|
---|
299 | newChildren != template.children || newReferences != template.references ||
|
---|
300 | newVariables != template.variables) {
|
---|
301 | return new Template(template.tagName, newAttributes, newInputs, newOutputs, newTemplateAttrs, newChildren, newReferences, newVariables, template.sourceSpan, template.startSourceSpan, template.endSourceSpan);
|
---|
302 | }
|
---|
303 | return template;
|
---|
304 | };
|
---|
305 | TransformVisitor.prototype.visitContent = function (content) {
|
---|
306 | return content;
|
---|
307 | };
|
---|
308 | TransformVisitor.prototype.visitVariable = function (variable) {
|
---|
309 | return variable;
|
---|
310 | };
|
---|
311 | TransformVisitor.prototype.visitReference = function (reference) {
|
---|
312 | return reference;
|
---|
313 | };
|
---|
314 | TransformVisitor.prototype.visitTextAttribute = function (attribute) {
|
---|
315 | return attribute;
|
---|
316 | };
|
---|
317 | TransformVisitor.prototype.visitBoundAttribute = function (attribute) {
|
---|
318 | return attribute;
|
---|
319 | };
|
---|
320 | TransformVisitor.prototype.visitBoundEvent = function (attribute) {
|
---|
321 | return attribute;
|
---|
322 | };
|
---|
323 | TransformVisitor.prototype.visitText = function (text) {
|
---|
324 | return text;
|
---|
325 | };
|
---|
326 | TransformVisitor.prototype.visitBoundText = function (text) {
|
---|
327 | return text;
|
---|
328 | };
|
---|
329 | TransformVisitor.prototype.visitIcu = function (icu) {
|
---|
330 | return icu;
|
---|
331 | };
|
---|
332 | return TransformVisitor;
|
---|
333 | }());
|
---|
334 | exports.TransformVisitor = TransformVisitor;
|
---|
335 | function visitAll(visitor, nodes) {
|
---|
336 | var e_1, _a, e_2, _b;
|
---|
337 | var result = [];
|
---|
338 | if (visitor.visit) {
|
---|
339 | try {
|
---|
340 | for (var nodes_1 = tslib_1.__values(nodes), nodes_1_1 = nodes_1.next(); !nodes_1_1.done; nodes_1_1 = nodes_1.next()) {
|
---|
341 | var node = nodes_1_1.value;
|
---|
342 | var newNode = visitor.visit(node) || node.visit(visitor);
|
---|
343 | }
|
---|
344 | }
|
---|
345 | catch (e_1_1) { e_1 = { error: e_1_1 }; }
|
---|
346 | finally {
|
---|
347 | try {
|
---|
348 | if (nodes_1_1 && !nodes_1_1.done && (_a = nodes_1.return)) _a.call(nodes_1);
|
---|
349 | }
|
---|
350 | finally { if (e_1) throw e_1.error; }
|
---|
351 | }
|
---|
352 | }
|
---|
353 | else {
|
---|
354 | try {
|
---|
355 | for (var nodes_2 = tslib_1.__values(nodes), nodes_2_1 = nodes_2.next(); !nodes_2_1.done; nodes_2_1 = nodes_2.next()) {
|
---|
356 | var node = nodes_2_1.value;
|
---|
357 | var newNode = node.visit(visitor);
|
---|
358 | if (newNode) {
|
---|
359 | result.push(newNode);
|
---|
360 | }
|
---|
361 | }
|
---|
362 | }
|
---|
363 | catch (e_2_1) { e_2 = { error: e_2_1 }; }
|
---|
364 | finally {
|
---|
365 | try {
|
---|
366 | if (nodes_2_1 && !nodes_2_1.done && (_b = nodes_2.return)) _b.call(nodes_2);
|
---|
367 | }
|
---|
368 | finally { if (e_2) throw e_2.error; }
|
---|
369 | }
|
---|
370 | }
|
---|
371 | return result;
|
---|
372 | }
|
---|
373 | exports.visitAll = visitAll;
|
---|
374 | function transformAll(visitor, nodes) {
|
---|
375 | var e_3, _a;
|
---|
376 | var result = [];
|
---|
377 | var changed = false;
|
---|
378 | try {
|
---|
379 | for (var nodes_3 = tslib_1.__values(nodes), nodes_3_1 = nodes_3.next(); !nodes_3_1.done; nodes_3_1 = nodes_3.next()) {
|
---|
380 | var node = nodes_3_1.value;
|
---|
381 | var newNode = node.visit(visitor);
|
---|
382 | if (newNode) {
|
---|
383 | result.push(newNode);
|
---|
384 | }
|
---|
385 | changed = changed || newNode != node;
|
---|
386 | }
|
---|
387 | }
|
---|
388 | catch (e_3_1) { e_3 = { error: e_3_1 }; }
|
---|
389 | finally {
|
---|
390 | try {
|
---|
391 | if (nodes_3_1 && !nodes_3_1.done && (_a = nodes_3.return)) _a.call(nodes_3);
|
---|
392 | }
|
---|
393 | finally { if (e_3) throw e_3.error; }
|
---|
394 | }
|
---|
395 | return changed ? result : nodes;
|
---|
396 | }
|
---|
397 | exports.transformAll = transformAll;
|
---|
398 | });
|
---|
399 | //# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoicjNfYXN0LmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiLi4vLi4vLi4vLi4vLi4vLi4vLi4vcGFja2FnZXMvY29tcGlsZXIvc3JjL3JlbmRlcjMvcjNfYXN0LnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ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