| 
									
										
										
										
											2016-06-23 09:47:54 -07:00
										 |  |  | /** | 
					
						
							|  |  |  |  * @license | 
					
						
							|  |  |  |  * Copyright Google Inc. All Rights Reserved. | 
					
						
							|  |  |  |  * | 
					
						
							|  |  |  |  * Use of this source code is governed by an MIT-style license that can be | 
					
						
							|  |  |  |  * found in the LICENSE file at https://angular.io/license
 | 
					
						
							|  |  |  |  */ | 
					
						
							|  |  |  | 
 | 
					
						
							| 
									
										
										
										
											2016-11-10 14:07:30 -08:00
										 |  |  | import {Component, Injectable, ViewEncapsulation} from '@angular/core'; | 
					
						
							| 
									
										
										
										
											2016-07-21 13:56:58 -07:00
										 |  |  | 
 | 
					
						
							| 
									
										
										
										
											2016-11-10 14:07:30 -08:00
										 |  |  | import {CompileAnimationEntryMetadata, CompileDirectiveMetadata, CompileStylesheetMetadata, CompileTemplateMetadata, CompileTypeMetadata} from './compile_metadata'; | 
					
						
							| 
									
										
										
										
											2016-05-26 16:43:15 -07:00
										 |  |  | import {CompilerConfig} from './config'; | 
					
						
							| 
									
										
										
										
											2016-11-10 14:07:30 -08:00
										 |  |  | import {isBlank, isPresent, stringify} from './facade/lang'; | 
					
						
							| 
									
										
										
										
											2016-08-01 12:19:09 -07:00
										 |  |  | import * as html from './ml_parser/ast'; | 
					
						
							|  |  |  | import {HtmlParser} from './ml_parser/html_parser'; | 
					
						
							|  |  |  | import {InterpolationConfig} from './ml_parser/interpolation_config'; | 
					
						
							| 
									
										
										
										
											2016-08-17 09:24:44 -07:00
										 |  |  | import {ResourceLoader} from './resource_loader'; | 
					
						
							| 
									
										
										
										
											2016-06-24 08:46:43 -07:00
										 |  |  | import {extractStyleUrls, isStyleUrlResolvable} from './style_url_resolver'; | 
					
						
							| 
									
										
										
										
											2016-07-21 11:41:25 -07:00
										 |  |  | import {PreparsedElementType, preparseElement} from './template_parser/template_preparser'; | 
					
						
							| 
									
										
										
										
											2016-06-24 08:46:43 -07:00
										 |  |  | import {UrlResolver} from './url_resolver'; | 
					
						
							| 
									
										
										
										
											2016-06-28 09:54:42 -07:00
										 |  |  | import {SyncAsyncResult} from './util'; | 
					
						
							| 
									
										
										
										
											2015-08-25 15:36:02 -07:00
										 |  |  | 
 | 
					
						
							| 
									
										
										
										
											2016-11-10 14:07:30 -08:00
										 |  |  | export interface PrenormalizedTemplateMetadata { | 
					
						
							|  |  |  |   componentType: any; | 
					
						
							|  |  |  |   moduleUrl: string; | 
					
						
							|  |  |  |   template?: string; | 
					
						
							|  |  |  |   templateUrl?: string; | 
					
						
							|  |  |  |   styles?: string[]; | 
					
						
							|  |  |  |   styleUrls?: string[]; | 
					
						
							|  |  |  |   interpolation?: [string, string]; | 
					
						
							|  |  |  |   encapsulation?: ViewEncapsulation; | 
					
						
							|  |  |  |   animations?: CompileAnimationEntryMetadata[]; | 
					
						
							|  |  |  | } | 
					
						
							|  |  |  | 
 | 
					
						
							| 
									
										
										
										
											2015-09-14 15:59:09 -07:00
										 |  |  | @Injectable() | 
					
						
							| 
									
										
										
										
											2016-01-06 14:13:44 -08:00
										 |  |  | export class DirectiveNormalizer { | 
					
						
							| 
									
										
										
										
											2016-08-17 09:24:44 -07:00
										 |  |  |   private _resourceLoaderCache = new Map<string, Promise<string>>(); | 
					
						
							| 
									
										
										
										
											2016-06-24 08:46:43 -07:00
										 |  |  | 
 | 
					
						
							| 
									
										
										
										
											2016-06-08 16:38:52 -07:00
										 |  |  |   constructor( | 
					
						
							| 
									
										
										
										
											2016-08-17 09:24:44 -07:00
										 |  |  |       private _resourceLoader: ResourceLoader, private _urlResolver: UrlResolver, | 
					
						
							|  |  |  |       private _htmlParser: HtmlParser, private _config: CompilerConfig) {} | 
					
						
							| 
									
										
										
										
											2015-08-25 15:36:02 -07:00
										 |  |  | 
 | 
					
						
							| 
									
										
										
										
											2016-08-17 09:24:44 -07:00
										 |  |  |   clearCache() { this._resourceLoaderCache.clear(); } | 
					
						
							| 
									
										
										
										
											2016-06-24 08:46:43 -07:00
										 |  |  | 
 | 
					
						
							|  |  |  |   clearCacheFor(normalizedDirective: CompileDirectiveMetadata) { | 
					
						
							|  |  |  |     if (!normalizedDirective.isComponent) { | 
					
						
							|  |  |  |       return; | 
					
						
							|  |  |  |     } | 
					
						
							| 
									
										
										
										
											2016-08-17 09:24:44 -07:00
										 |  |  |     this._resourceLoaderCache.delete(normalizedDirective.template.templateUrl); | 
					
						
							| 
									
										
										
										
											2016-06-24 08:46:43 -07:00
										 |  |  |     normalizedDirective.template.externalStylesheets.forEach( | 
					
						
							| 
									
										
										
										
											2016-08-17 09:24:44 -07:00
										 |  |  |         (stylesheet) => { this._resourceLoaderCache.delete(stylesheet.moduleUrl); }); | 
					
						
							| 
									
										
										
										
											2016-06-24 08:46:43 -07:00
										 |  |  |   } | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  |   private _fetch(url: string): Promise<string> { | 
					
						
							| 
									
										
										
										
											2016-11-12 14:08:58 +01:00
										 |  |  |     let result = this._resourceLoaderCache.get(url); | 
					
						
							| 
									
										
										
										
											2016-06-24 08:46:43 -07:00
										 |  |  |     if (!result) { | 
					
						
							| 
									
										
										
										
											2016-08-17 09:24:44 -07:00
										 |  |  |       result = this._resourceLoader.get(url); | 
					
						
							|  |  |  |       this._resourceLoaderCache.set(url, result); | 
					
						
							| 
									
										
										
										
											2016-06-24 08:46:43 -07:00
										 |  |  |     } | 
					
						
							|  |  |  |     return result; | 
					
						
							|  |  |  |   } | 
					
						
							|  |  |  | 
 | 
					
						
							| 
									
										
										
										
											2016-11-10 14:07:30 -08:00
										 |  |  |   normalizeTemplate(prenormData: PrenormalizedTemplateMetadata): | 
					
						
							|  |  |  |       SyncAsyncResult<CompileTemplateMetadata> { | 
					
						
							| 
									
										
										
										
											2016-06-24 08:46:43 -07:00
										 |  |  |     let normalizedTemplateSync: CompileTemplateMetadata = null; | 
					
						
							|  |  |  |     let normalizedTemplateAsync: Promise<CompileTemplateMetadata>; | 
					
						
							| 
									
										
										
										
											2016-11-10 14:07:30 -08:00
										 |  |  |     if (isPresent(prenormData.template)) { | 
					
						
							|  |  |  |       normalizedTemplateSync = this.normalizeTemplateSync(prenormData); | 
					
						
							| 
									
										
										
										
											2016-06-24 08:46:43 -07:00
										 |  |  |       normalizedTemplateAsync = Promise.resolve(normalizedTemplateSync); | 
					
						
							| 
									
										
										
										
											2016-11-10 14:07:30 -08:00
										 |  |  |     } else if (prenormData.templateUrl) { | 
					
						
							|  |  |  |       normalizedTemplateAsync = this.normalizeTemplateAsync(prenormData); | 
					
						
							| 
									
										
										
										
											2016-06-24 08:46:43 -07:00
										 |  |  |     } else { | 
					
						
							| 
									
										
										
										
											2016-11-10 14:07:30 -08:00
										 |  |  |       throw new Error( | 
					
						
							|  |  |  |           `No template specified for component ${stringify(prenormData.componentType)}`); | 
					
						
							| 
									
										
										
										
											2016-06-24 08:46:43 -07:00
										 |  |  |     } | 
					
						
							| 
									
										
										
										
											2016-11-10 14:07:30 -08:00
										 |  |  | 
 | 
					
						
							| 
									
										
										
										
											2016-06-24 08:46:43 -07:00
										 |  |  |     if (normalizedTemplateSync && normalizedTemplateSync.styleUrls.length === 0) { | 
					
						
							|  |  |  |       // sync case
 | 
					
						
							| 
									
										
										
										
											2016-11-10 14:07:30 -08:00
										 |  |  |       return new SyncAsyncResult(normalizedTemplateSync); | 
					
						
							| 
									
										
										
										
											2016-06-24 08:46:43 -07:00
										 |  |  |     } else { | 
					
						
							|  |  |  |       // async case
 | 
					
						
							| 
									
										
										
										
											2016-06-28 09:54:42 -07:00
										 |  |  |       return new SyncAsyncResult( | 
					
						
							| 
									
										
										
										
											2016-11-10 14:07:30 -08:00
										 |  |  |           null, normalizedTemplateAsync.then( | 
					
						
							|  |  |  |                     (normalizedTemplate) => this.normalizeExternalStylesheets(normalizedTemplate))); | 
					
						
							| 
									
										
										
										
											2016-06-24 08:46:43 -07:00
										 |  |  |     } | 
					
						
							|  |  |  |   } | 
					
						
							|  |  |  | 
 | 
					
						
							| 
									
										
										
										
											2016-11-10 14:07:30 -08:00
										 |  |  |   normalizeTemplateSync(prenomData: PrenormalizedTemplateMetadata): CompileTemplateMetadata { | 
					
						
							|  |  |  |     return this.normalizeLoadedTemplate(prenomData, prenomData.template, prenomData.moduleUrl); | 
					
						
							| 
									
										
										
										
											2016-01-06 14:13:44 -08:00
										 |  |  |   } | 
					
						
							|  |  |  | 
 | 
					
						
							| 
									
										
										
										
											2016-11-10 14:07:30 -08:00
										 |  |  |   normalizeTemplateAsync(prenomData: PrenormalizedTemplateMetadata): | 
					
						
							| 
									
										
										
										
											2016-06-08 16:38:52 -07:00
										 |  |  |       Promise<CompileTemplateMetadata> { | 
					
						
							| 
									
										
										
										
											2016-11-12 14:08:58 +01:00
										 |  |  |     const templateUrl = this._urlResolver.resolve(prenomData.moduleUrl, prenomData.templateUrl); | 
					
						
							| 
									
										
										
										
											2016-06-24 08:46:43 -07:00
										 |  |  |     return this._fetch(templateUrl) | 
					
						
							| 
									
										
										
										
											2016-11-10 14:07:30 -08:00
										 |  |  |         .then((value) => this.normalizeLoadedTemplate(prenomData, value, templateUrl)); | 
					
						
							| 
									
										
										
										
											2015-08-25 15:36:02 -07:00
										 |  |  |   } | 
					
						
							|  |  |  | 
 | 
					
						
							| 
									
										
										
										
											2016-06-08 16:38:52 -07:00
										 |  |  |   normalizeLoadedTemplate( | 
					
						
							| 
									
										
										
										
											2016-11-10 14:07:30 -08:00
										 |  |  |       prenomData: PrenormalizedTemplateMetadata, template: string, | 
					
						
							| 
									
										
										
										
											2016-06-08 16:38:52 -07:00
										 |  |  |       templateAbsUrl: string): CompileTemplateMetadata { | 
					
						
							| 
									
										
										
										
											2016-11-10 14:07:30 -08:00
										 |  |  |     const interpolationConfig = InterpolationConfig.fromArray(prenomData.interpolation); | 
					
						
							|  |  |  |     const rootNodesAndErrors = this._htmlParser.parse( | 
					
						
							|  |  |  |         template, stringify(prenomData.componentType), false, interpolationConfig); | 
					
						
							| 
									
										
										
										
											2015-10-07 09:34:21 -07:00
										 |  |  |     if (rootNodesAndErrors.errors.length > 0) { | 
					
						
							| 
									
										
										
										
											2016-07-09 10:12:39 -07:00
										 |  |  |       const errorString = rootNodesAndErrors.errors.join('\n'); | 
					
						
							| 
									
										
										
										
											2016-08-25 00:50:16 -07:00
										 |  |  |       throw new Error(`Template parse errors:\n${errorString}`); | 
					
						
							| 
									
										
										
										
											2015-10-07 09:34:21 -07:00
										 |  |  |     } | 
					
						
							| 
									
										
										
										
											2016-07-09 10:12:39 -07:00
										 |  |  |     const templateMetadataStyles = this.normalizeStylesheet(new CompileStylesheetMetadata({ | 
					
						
							| 
									
										
										
										
											2016-11-10 14:07:30 -08:00
										 |  |  |       styles: prenomData.styles, | 
					
						
							|  |  |  |       styleUrls: prenomData.styleUrls, | 
					
						
							|  |  |  |       moduleUrl: prenomData.moduleUrl | 
					
						
							| 
									
										
										
										
											2016-06-24 08:46:43 -07:00
										 |  |  |     })); | 
					
						
							| 
									
										
										
										
											2015-10-07 09:34:21 -07:00
										 |  |  | 
 | 
					
						
							| 
									
										
										
										
											2016-07-09 10:12:39 -07:00
										 |  |  |     const visitor = new TemplatePreparseVisitor(); | 
					
						
							| 
									
										
										
										
											2016-07-21 13:56:58 -07:00
										 |  |  |     html.visitAll(visitor, rootNodesAndErrors.rootNodes); | 
					
						
							| 
									
										
										
										
											2016-07-09 10:12:39 -07:00
										 |  |  |     const templateStyles = this.normalizeStylesheet(new CompileStylesheetMetadata( | 
					
						
							| 
									
										
										
										
											2016-06-24 08:46:43 -07:00
										 |  |  |         {styles: visitor.styles, styleUrls: visitor.styleUrls, moduleUrl: templateAbsUrl})); | 
					
						
							| 
									
										
										
										
											2015-09-14 15:59:09 -07:00
										 |  |  | 
 | 
					
						
							| 
									
										
										
										
											2016-11-10 14:07:30 -08:00
										 |  |  |     let encapsulation = prenomData.encapsulation; | 
					
						
							| 
									
										
										
										
											2016-04-03 08:34:44 +09:00
										 |  |  |     if (isBlank(encapsulation)) { | 
					
						
							|  |  |  |       encapsulation = this._config.defaultEncapsulation; | 
					
						
							|  |  |  |     } | 
					
						
							| 
									
										
										
										
											2016-09-20 14:14:57 -07:00
										 |  |  | 
 | 
					
						
							|  |  |  |     const styles = templateMetadataStyles.styles.concat(templateStyles.styles); | 
					
						
							|  |  |  |     const styleUrls = templateMetadataStyles.styleUrls.concat(templateStyles.styleUrls); | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  |     if (encapsulation === ViewEncapsulation.Emulated && styles.length === 0 && | 
					
						
							|  |  |  |         styleUrls.length === 0) { | 
					
						
							| 
									
										
										
										
											2015-09-18 10:33:23 -07:00
										 |  |  |       encapsulation = ViewEncapsulation.None; | 
					
						
							|  |  |  |     } | 
					
						
							| 
									
										
										
										
											2016-09-20 14:14:57 -07:00
										 |  |  | 
 | 
					
						
							| 
									
										
										
										
											2015-09-18 10:33:23 -07:00
										 |  |  |     return new CompileTemplateMetadata({ | 
					
						
							| 
									
										
										
										
											2016-06-22 17:25:42 -07:00
										 |  |  |       encapsulation, | 
					
						
							| 
									
										
										
										
											2016-09-20 14:14:57 -07:00
										 |  |  |       template, | 
					
						
							|  |  |  |       templateUrl: templateAbsUrl, styles, styleUrls, | 
					
						
							| 
									
										
										
										
											2016-05-25 12:46:22 -07:00
										 |  |  |       ngContentSelectors: visitor.ngContentSelectors, | 
					
						
							| 
									
										
										
										
											2016-11-10 14:07:30 -08:00
										 |  |  |       animations: prenomData.animations, | 
					
						
							|  |  |  |       interpolation: prenomData.interpolation, | 
					
						
							| 
									
										
										
										
											2015-08-25 15:36:02 -07:00
										 |  |  |     }); | 
					
						
							|  |  |  |   } | 
					
						
							| 
									
										
										
										
											2016-06-24 08:46:43 -07:00
										 |  |  | 
 | 
					
						
							|  |  |  |   normalizeExternalStylesheets(templateMeta: CompileTemplateMetadata): | 
					
						
							|  |  |  |       Promise<CompileTemplateMetadata> { | 
					
						
							|  |  |  |     return this._loadMissingExternalStylesheets(templateMeta.styleUrls) | 
					
						
							|  |  |  |         .then((externalStylesheets) => new CompileTemplateMetadata({ | 
					
						
							|  |  |  |                 encapsulation: templateMeta.encapsulation, | 
					
						
							|  |  |  |                 template: templateMeta.template, | 
					
						
							|  |  |  |                 templateUrl: templateMeta.templateUrl, | 
					
						
							|  |  |  |                 styles: templateMeta.styles, | 
					
						
							|  |  |  |                 styleUrls: templateMeta.styleUrls, | 
					
						
							|  |  |  |                 externalStylesheets: externalStylesheets, | 
					
						
							|  |  |  |                 ngContentSelectors: templateMeta.ngContentSelectors, | 
					
						
							|  |  |  |                 animations: templateMeta.animations, | 
					
						
							|  |  |  |                 interpolation: templateMeta.interpolation | 
					
						
							|  |  |  |               })); | 
					
						
							|  |  |  |   } | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  |   private _loadMissingExternalStylesheets( | 
					
						
							|  |  |  |       styleUrls: string[], | 
					
						
							|  |  |  |       loadedStylesheets: | 
					
						
							|  |  |  |           Map<string, CompileStylesheetMetadata> = new Map<string, CompileStylesheetMetadata>()): | 
					
						
							|  |  |  |       Promise<CompileStylesheetMetadata[]> { | 
					
						
							|  |  |  |     return Promise | 
					
						
							|  |  |  |         .all(styleUrls.filter((styleUrl) => !loadedStylesheets.has(styleUrl)) | 
					
						
							|  |  |  |                  .map(styleUrl => this._fetch(styleUrl).then((loadedStyle) => { | 
					
						
							| 
									
										
										
										
											2016-11-12 14:08:58 +01:00
										 |  |  |                    const stylesheet = this.normalizeStylesheet( | 
					
						
							| 
									
										
										
										
											2016-06-24 08:46:43 -07:00
										 |  |  |                        new CompileStylesheetMetadata({styles: [loadedStyle], moduleUrl: styleUrl})); | 
					
						
							|  |  |  |                    loadedStylesheets.set(styleUrl, stylesheet); | 
					
						
							|  |  |  |                    return this._loadMissingExternalStylesheets( | 
					
						
							|  |  |  |                        stylesheet.styleUrls, loadedStylesheets); | 
					
						
							|  |  |  |                  }))) | 
					
						
							| 
									
										
										
										
											2016-11-03 16:58:27 -07:00
										 |  |  |         .then((_) => Array.from(loadedStylesheets.values())); | 
					
						
							| 
									
										
										
										
											2016-06-24 08:46:43 -07:00
										 |  |  |   } | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  |   normalizeStylesheet(stylesheet: CompileStylesheetMetadata): CompileStylesheetMetadata { | 
					
						
							| 
									
										
										
										
											2016-11-12 14:08:58 +01:00
										 |  |  |     const allStyleUrls = stylesheet.styleUrls.filter(isStyleUrlResolvable) | 
					
						
							|  |  |  |                              .map(url => this._urlResolver.resolve(stylesheet.moduleUrl, url)); | 
					
						
							| 
									
										
										
										
											2016-06-24 08:46:43 -07:00
										 |  |  | 
 | 
					
						
							| 
									
										
										
										
											2016-11-12 14:08:58 +01:00
										 |  |  |     const allStyles = stylesheet.styles.map(style => { | 
					
						
							|  |  |  |       const styleWithImports = extractStyleUrls(this._urlResolver, stylesheet.moduleUrl, style); | 
					
						
							| 
									
										
										
										
											2016-06-24 08:46:43 -07:00
										 |  |  |       allStyleUrls.push(...styleWithImports.styleUrls); | 
					
						
							|  |  |  |       return styleWithImports.style; | 
					
						
							|  |  |  |     }); | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  |     return new CompileStylesheetMetadata( | 
					
						
							|  |  |  |         {styles: allStyles, styleUrls: allStyleUrls, moduleUrl: stylesheet.moduleUrl}); | 
					
						
							|  |  |  |   } | 
					
						
							| 
									
										
										
										
											2015-08-25 15:36:02 -07:00
										 |  |  | } | 
					
						
							|  |  |  | 
 | 
					
						
							| 
									
										
										
										
											2016-07-21 13:56:58 -07:00
										 |  |  | class TemplatePreparseVisitor implements html.Visitor { | 
					
						
							| 
									
										
										
										
											2015-08-25 15:36:02 -07:00
										 |  |  |   ngContentSelectors: string[] = []; | 
					
						
							|  |  |  |   styles: string[] = []; | 
					
						
							|  |  |  |   styleUrls: string[] = []; | 
					
						
							| 
									
										
										
										
											2015-09-18 10:33:23 -07:00
										 |  |  |   ngNonBindableStackCount: number = 0; | 
					
						
							| 
									
										
										
										
											2015-08-25 15:36:02 -07:00
										 |  |  | 
 | 
					
						
							| 
									
										
										
										
											2016-07-21 13:56:58 -07:00
										 |  |  |   visitElement(ast: html.Element, context: any): any { | 
					
						
							| 
									
										
										
										
											2016-11-12 14:08:58 +01:00
										 |  |  |     const preparsedElement = preparseElement(ast); | 
					
						
							| 
									
										
										
										
											2015-09-18 10:33:23 -07:00
										 |  |  |     switch (preparsedElement.type) { | 
					
						
							|  |  |  |       case PreparsedElementType.NG_CONTENT: | 
					
						
							| 
									
										
										
										
											2015-09-18 10:33:23 -07:00
										 |  |  |         if (this.ngNonBindableStackCount === 0) { | 
					
						
							|  |  |  |           this.ngContentSelectors.push(preparsedElement.selectAttr); | 
					
						
							|  |  |  |         } | 
					
						
							| 
									
										
										
										
											2015-09-18 10:33:23 -07:00
										 |  |  |         break; | 
					
						
							|  |  |  |       case PreparsedElementType.STYLE: | 
					
						
							| 
									
										
										
										
											2016-11-12 14:08:58 +01:00
										 |  |  |         let textContent = ''; | 
					
						
							| 
									
										
										
										
											2015-09-18 10:33:23 -07:00
										 |  |  |         ast.children.forEach(child => { | 
					
						
							| 
									
										
										
										
											2016-07-21 13:56:58 -07:00
										 |  |  |           if (child instanceof html.Text) { | 
					
						
							| 
									
										
										
										
											2016-07-13 11:01:32 -07:00
										 |  |  |             textContent += child.value; | 
					
						
							| 
									
										
										
										
											2015-09-18 10:33:23 -07:00
										 |  |  |           } | 
					
						
							|  |  |  |         }); | 
					
						
							|  |  |  |         this.styles.push(textContent); | 
					
						
							|  |  |  |         break; | 
					
						
							|  |  |  |       case PreparsedElementType.STYLESHEET: | 
					
						
							|  |  |  |         this.styleUrls.push(preparsedElement.hrefAttr); | 
					
						
							|  |  |  |         break; | 
					
						
							| 
									
										
										
										
											2016-01-25 17:57:29 -08:00
										 |  |  |       default: | 
					
						
							|  |  |  |         break; | 
					
						
							| 
									
										
										
										
											2015-08-25 15:36:02 -07:00
										 |  |  |     } | 
					
						
							| 
									
										
										
										
											2015-09-18 10:33:23 -07:00
										 |  |  |     if (preparsedElement.nonBindable) { | 
					
						
							|  |  |  |       this.ngNonBindableStackCount++; | 
					
						
							|  |  |  |     } | 
					
						
							| 
									
										
										
										
											2016-07-21 13:56:58 -07:00
										 |  |  |     html.visitAll(this, ast.children); | 
					
						
							| 
									
										
										
										
											2015-09-18 10:33:23 -07:00
										 |  |  |     if (preparsedElement.nonBindable) { | 
					
						
							|  |  |  |       this.ngNonBindableStackCount--; | 
					
						
							| 
									
										
										
										
											2015-08-25 15:36:02 -07:00
										 |  |  |     } | 
					
						
							| 
									
										
										
										
											2015-09-18 10:33:23 -07:00
										 |  |  |     return null; | 
					
						
							| 
									
										
										
										
											2015-08-25 15:36:02 -07:00
										 |  |  |   } | 
					
						
							| 
									
										
										
										
											2016-08-11 21:00:35 -07:00
										 |  |  | 
 | 
					
						
							| 
									
										
										
										
											2016-07-21 13:56:58 -07:00
										 |  |  |   visitComment(ast: html.Comment, context: any): any { return null; } | 
					
						
							|  |  |  |   visitAttribute(ast: html.Attribute, context: any): any { return null; } | 
					
						
							|  |  |  |   visitText(ast: html.Text, context: any): any { return null; } | 
					
						
							|  |  |  |   visitExpansion(ast: html.Expansion, context: any): any { return null; } | 
					
						
							|  |  |  |   visitExpansionCase(ast: html.ExpansionCase, context: any): any { return null; } | 
					
						
							| 
									
										
										
										
											2015-08-25 15:36:02 -07:00
										 |  |  | } |