refactor(ivy): migrate ɵɵ prefix back to Δ (#30362)
Now that issues are resolved with Closure compiler, we can move back to our desired prefix of `Δ`. PR Close #30362
This commit is contained in:
parent
dbb150a9bd
commit
cf86ed7b29
|
@ -1,11 +1,11 @@
|
|||
# Deprecated APIs and Features
|
||||
|
||||
Angular strives to balance innovation and stability.
|
||||
Sometimes, APIs and features become obsolete and need to be removed or replaced so that Angular can stay current with new best practices, changing dependencies, or changes in the (web) platform itself.
|
||||
Angular strives to balance innovation and stability.
|
||||
Sometimes, APIs and features become obsolete and need to be removed or replaced so that Angular can stay current with new best practices, changing dependencies, or changes in the (web) platform itself.
|
||||
|
||||
To make these transitions as easy as possible, we deprecate APIs and features for a period of time before removing them. This gives you time to update your apps to the latest APIs and best practices.
|
||||
|
||||
This guide contains a summary of all Angular APIs and features that are currently deprecated.
|
||||
This guide contains a summary of all Angular APIs and features that are currently deprecated.
|
||||
|
||||
|
||||
<div class="alert is-helpful">
|
||||
|
@ -13,7 +13,7 @@ This guide contains a summary of all Angular APIs and features that are currentl
|
|||
|
||||
Features and APIs that were deprecated in v6 or earlier are candidates for removal in version 9 or any later major version. For information about Angular's deprecation and removal practices, see [Angular Release Practices](guide/releases#deprecation-practices "Angular Release Practices: Deprecation practices").
|
||||
|
||||
For step-by-step instructions on how to update to the latest Angular release, use the interactive update guide at [update.angular.io](https://update.angular.io).
|
||||
For step-by-step instructions on how to update to the latest Angular release, use the interactive update guide at [update.angular.io](https://update.angular.io).
|
||||
|
||||
</div>
|
||||
|
||||
|
@ -21,7 +21,7 @@ For step-by-step instructions on how to update to the latest Angular release, us
|
|||
|
||||
## Deprecated APIs
|
||||
|
||||
This section contains a complete list all of the currently-deprecated APIs, with details to help you plan your migration to a replacement.
|
||||
This section contains a complete list all of the currently-deprecated APIs, with details to help you plan your migration to a replacement.
|
||||
|
||||
|
||||
<div class="alert is-helpful">
|
||||
|
@ -49,16 +49,16 @@ Tip: In the [API reference section](api) of this doc site, deprecated APIs are i
|
|||
|
||||
| API | Replacement | Deprecation announced | Notes |
|
||||
| --- | ----------- | --------------------- | ----- |
|
||||
| [`CollectionChangeRecord`](api/core/CollectionChangeRecord) | [`IterableChangeRecord`](api/core/IterableChangeRecord) | v4 | none |
|
||||
| [`CollectionChangeRecord`](api/core/CollectionChangeRecord) | [`IterableChangeRecord`](api/core/IterableChangeRecord) | v4 | none |
|
||||
| [`DefaultIterableDiffer`](api/core/DefaultIterableDiffer) | n/a | v4 | Not part of public API. |
|
||||
| [`defineInjectable`](api/core/defineInjectable) | `ɵɵdefineInjectable` | v8 | Used only in generated code. No source code should depend on this API. |
|
||||
| [`inject`](api/core/inject) | `ɵɵinject` | v8 | Used only in generated code. No source code should depend on this API. |
|
||||
| [`ReflectiveInjector`](api/core/ReflectiveInjector) | [`Injector.create`](api/core/Injector#create) | v5 | See [`ReflectiveInjector`](#reflectiveinjector) |
|
||||
| [`defineInjectable`](api/core/defineInjectable) | `ΔdefineInjectable` | v8 | Used only in generated code. No source code should depend on this API. |
|
||||
| [`inject`](api/core/inject) | `Δinject` | v8 | Used only in generated code. No source code should depend on this API. |
|
||||
| [`ReflectiveInjector`](api/core/ReflectiveInjector) | [`Injector.create`](api/core/Injector#create) | v5 | See [`ReflectiveInjector`](#reflectiveinjector) |
|
||||
| [`ReflectiveKey`](api/core/ReflectiveKey) | none | v5 | none |
|
||||
| [`RenderComponentType`](api/core/RenderComponentType) | [`RendererType2`](api/core/RendererType2) and [`Renderer2`](api/core/Renderer2) | v4 | none |
|
||||
| [`Renderer`](api/core/Renderer) | [`Renderer2`](api/core/Renderer2) | v4 | none |
|
||||
| [`RootRenderer`](api/core/RootRenderer) | [`RendererFactory2`](api/core/RendererFactory2) | v4 | none |
|
||||
| [`ViewEncapsulation.Native`](api/core/ViewEncapsulation#Native) | [`ViewEncapsulation.ShadowDom`](api/core/ViewEncapsulation#ShadowDom) | v6 | Use the native encapsulation mechanism of the renderer. See [view.ts](https://github.com/angular/angular/blob/3e992e18ebf51d6036818f26c3d77b52d3ec48eb/packages/core/src/metadata/view.ts#L32).
|
||||
| [`RenderComponentType`](api/core/RenderComponentType) | [`RendererType2`](api/core/RendererType2) and [`Renderer2`](api/core/Renderer2) | v4 | none |
|
||||
| [`Renderer`](api/core/Renderer) | [`Renderer2`](api/core/Renderer2) | v4 | none |
|
||||
| [`RootRenderer`](api/core/RootRenderer) | [`RendererFactory2`](api/core/RendererFactory2) | v4 | none |
|
||||
| [`ViewEncapsulation.Native`](api/core/ViewEncapsulation#Native) | [`ViewEncapsulation.ShadowDom`](api/core/ViewEncapsulation#ShadowDom) | v6 | Use the native encapsulation mechanism of the renderer. See [view.ts](https://github.com/angular/angular/blob/3e992e18ebf51d6036818f26c3d77b52d3ec48eb/packages/core/src/metadata/view.ts#L32).
|
||||
|
||||
#### @angular/core/testing
|
||||
|
||||
|
@ -72,7 +72,7 @@ Tip: In the [API reference section](api) of this doc site, deprecated APIs are i
|
|||
|
||||
| API | Replacement | Deprecation announced | Notes |
|
||||
| --- | ----------- | --------------------- | ----- |
|
||||
| [`NgFormSelectorWarning`](api/forms/NgFormSelectorWarning) | n/a | v6 | See [ngForm](#ngform). |
|
||||
| [`NgFormSelectorWarning`](api/forms/NgFormSelectorWarning) | n/a | v6 | See [ngForm](#ngform). |
|
||||
|
||||
|
||||
#### @angular/router
|
||||
|
@ -93,15 +93,15 @@ Tip: In the [API reference section](api) of this doc site, deprecated APIs are i
|
|||
|
||||
| API | Replacement | Deprecation announced | Notes |
|
||||
| --- | ----------- | --------------------- | ----- |
|
||||
| [`getAngularLib`](api/upgrade/static/getAngularLib) | [`getAngularJSGlobal`](api/upgrade/static/getAngularJSGlobal) | v5 | See [Upgrading from AngularJS](guide/upgrade). |
|
||||
[`setAngularLib`](api/upgrade/static/setAngularLib) | [`setAngularJSGlobal`](api/upgrade/static/setAngularJSGlobal) | v5 | See [Upgrading from AngularJS](guide/upgrade). |
|
||||
| [`getAngularLib`](api/upgrade/static/getAngularLib) | [`getAngularJSGlobal`](api/upgrade/static/getAngularJSGlobal) | v5 | See [Upgrading from AngularJS](guide/upgrade). |
|
||||
[`setAngularLib`](api/upgrade/static/setAngularLib) | [`setAngularJSGlobal`](api/upgrade/static/setAngularJSGlobal) | v5 | See [Upgrading from AngularJS](guide/upgrade). |
|
||||
|
||||
|
||||
|
||||
{@a deprecated-features}
|
||||
## Deprecated features
|
||||
|
||||
This section lists all of the currently-deprecated features, which includes template syntax, configuration options, and any other deprecations not listed in the [Deprecated APIs](#deprecated-apis) section above. It also includes deprecated API usage scenarios or API combinations, to augment the information above.
|
||||
This section lists all of the currently-deprecated features, which includes template syntax, configuration options, and any other deprecations not listed in the [Deprecated APIs](#deprecated-apis) section above. It also includes deprecated API usage scenarios or API combinations, to augment the information above.
|
||||
|
||||
|
||||
|
||||
|
@ -111,20 +111,20 @@ This section lists all of the currently-deprecated features, which includes temp
|
|||
The shadow-piercing descendant combinator is deprecated and support is being removed from major browsers and tools. As such, in v4 we deprecated support in Angular for all 3 of `/deep/`, `>>>` and `::ng-deep`. Until removal, `::ng-deep` is preferred for broader compatibility with the tools.
|
||||
|
||||
For more information, see [/deep/, >>>, and ::ng-deep](guide/component-styles#deprecated-deep--and-ng-deep "Component Styles guide, Deprecated deep and ngdeep")
|
||||
in the Component Styles guide.
|
||||
in the Component Styles guide.
|
||||
|
||||
|
||||
{@a template-tag}
|
||||
### <template> tag
|
||||
|
||||
The `<template>` tag was deprecated in v4 to avoid colliding with the DOM's element of the same name (such as when using web components). Use `<ng-template>` instead. For more information, see the [Ahead-of-Time Compilation](guide/aot-compiler#enablelegacytemplate) guide.
|
||||
The `<template>` tag was deprecated in v4 to avoid colliding with the DOM's element of the same name (such as when using web components). Use `<ng-template>` instead. For more information, see the [Ahead-of-Time Compilation](guide/aot-compiler#enablelegacytemplate) guide.
|
||||
|
||||
|
||||
|
||||
{@a ngform}
|
||||
### ngForm element selector
|
||||
|
||||
Support for using `ngForm` element selector was deprecated in v6.
|
||||
Support for using `ngForm` element selector was deprecated in v6.
|
||||
It has been deprecated to be consistent with other core Angular selectors, which are typically written in kebab-case.
|
||||
|
||||
Deprecated:
|
||||
|
@ -133,13 +133,13 @@ Deprecated:
|
|||
<ngForm #myForm="ngForm">
|
||||
```
|
||||
|
||||
Replacement:
|
||||
Replacement:
|
||||
|
||||
```
|
||||
<ng-form #myForm="ngForm">
|
||||
```
|
||||
|
||||
The [`NgFormSelectorWarning`](api/forms/NgFormSelectorWarning) directive is solely used to display warnings when the deprecated `ngForm` selector is used.
|
||||
The [`NgFormSelectorWarning`](api/forms/NgFormSelectorWarning) directive is solely used to display warnings when the deprecated `ngForm` selector is used.
|
||||
|
||||
|
||||
{@a ngmodel-reactive}
|
||||
|
@ -147,23 +147,23 @@ The [`NgFormSelectorWarning`](api/forms/NgFormSelectorWarning) directive is sole
|
|||
|
||||
Support for using the `ngModel` input property and `ngModelChange` event with reactive form directives was deprecated in version 6.
|
||||
|
||||
For more information, see the usage notes for [`FormControlDirective`](api/forms/FormControlDirective#use-with-ngmodel) and [`FormControlName`](api/forms/FormControlName#use-with-ngmodel).
|
||||
For more information, see the usage notes for [`FormControlDirective`](api/forms/FormControlDirective#use-with-ngmodel) and [`FormControlName`](api/forms/FormControlName#use-with-ngmodel).
|
||||
|
||||
|
||||
{@a sw-versionedfiles}
|
||||
### Service worker versionedFiles
|
||||
|
||||
In the service worker configuration file `ngsw-config.json`, `versionedFiles` and `files` have the same behavior. As of v6, `versionedFiles` is deprecated; use `files` instead.
|
||||
In the service worker configuration file `ngsw-config.json`, `versionedFiles` and `files` have the same behavior. As of v6, `versionedFiles` is deprecated; use `files` instead.
|
||||
|
||||
For more information, see [Service Worker Configuration](guide/service-worker-config#assetgroups).
|
||||
For more information, see [Service Worker Configuration](guide/service-worker-config#assetgroups).
|
||||
|
||||
|
||||
{@a reflectiveinjector}
|
||||
### ReflectiveInjector
|
||||
|
||||
In v5, Angular replaced the `ReflectiveInjector` with the `StaticInjector`. The injector no longer requires the Reflect polyfill, reducing application size for most developers.
|
||||
In v5, Angular replaced the `ReflectiveInjector` with the `StaticInjector`. The injector no longer requires the Reflect polyfill, reducing application size for most developers.
|
||||
|
||||
Before:
|
||||
Before:
|
||||
|
||||
```
|
||||
ReflectiveInjector.resolveAndCreate(providers);
|
||||
|
@ -178,18 +178,18 @@ Injector.create({providers});
|
|||
{@a i18n-pipes}
|
||||
### Pipes using Intl API
|
||||
|
||||
<!--
|
||||
<!--
|
||||
From https://blog.angular.io/version-5-0-0-of-angular-now-available-37e414935ced
|
||||
-->
|
||||
|
||||
Angular used to rely on the browser to provide number, date, and currency formatting using browser i18n APIs. This practice meant that most apps needed to use a polyfill, users were seeing inconsistent results across browsers, and common formats (such as the currency pipe) didn’t match developer expectations out of the box.
|
||||
|
||||
In version 4.3, Angular introduced new number, date, and currency pipes that increase standardization across browsers and eliminate the need for i18n polyfills. These pipes use the Unicode Common Locale Data Repository (CLDR) instead of the JS Intl API to provide extensive locale support.
|
||||
In version 4.3, Angular introduced new number, date, and currency pipes that increase standardization across browsers and eliminate the need for i18n polyfills. These pipes use the Unicode Common Locale Data Repository (CLDR) instead of the JS Intl API to provide extensive locale support.
|
||||
|
||||
In version 5.0.0, Angular updated its standard pipes to use the CLRD implementation.
|
||||
At that time, Angular also added [`DeprecatedI18NPipesModule`](api/common/DeprecatedI18NPipesModule) and related APIs to provide limited-time access to the old behavior. If you need to use these `Deprecated*` pipes, see [Angular change log](https://github.com/angular/angular/blob/master/CHANGELOG.md#i18n-pipes) and the [Date Formats mappings](https://docs.google.com/spreadsheets/d/12iygt-_cakNP1VO7MV9g4lq9NsxVWG4tSfc98HpHb0k/edit#gid=0 "Date Formats Google sheet").
|
||||
In version 5.0.0, Angular updated its standard pipes to use the CLRD implementation.
|
||||
At that time, Angular also added [`DeprecatedI18NPipesModule`](api/common/DeprecatedI18NPipesModule) and related APIs to provide limited-time access to the old behavior. If you need to use these `Deprecated*` pipes, see [Angular change log](https://github.com/angular/angular/blob/master/CHANGELOG.md#i18n-pipes) and the [Date Formats mappings](https://docs.google.com/spreadsheets/d/12iygt-_cakNP1VO7MV9g4lq9NsxVWG4tSfc98HpHb0k/edit#gid=0 "Date Formats Google sheet").
|
||||
|
||||
Reminder: If you use these `Deprecated*` pipes, you should migrate to the current APIs listed above as soon as possible. These deprecated APIs are candidates for removal in the next major release.
|
||||
Reminder: If you use these `Deprecated*` pipes, you should migrate to the current APIs listed above as soon as possible. These deprecated APIs are candidates for removal in the next major release.
|
||||
|
||||
|
||||
{@a loadChildren}
|
||||
|
@ -199,7 +199,7 @@ When Angular first introduced lazy routes, there wasn't browser support for dyna
|
|||
|
||||
In v8, the string syntax for the [`loadChildren`](api/router/LoadChildren) route specification was deprecated, in favor of new syntax that uses `import()` syntax.
|
||||
|
||||
Before:
|
||||
Before:
|
||||
|
||||
```
|
||||
const routes: Routes = [{
|
||||
|
@ -209,12 +209,12 @@ const routes: Routes = [{
|
|||
}];
|
||||
```
|
||||
|
||||
After:
|
||||
After:
|
||||
|
||||
```
|
||||
const routes: Routes = [{
|
||||
path: 'lazy',
|
||||
// The new import() syntax
|
||||
// The new import() syntax
|
||||
loadChildren: () => import('./lazy/lazy.module').then(m => m.LazyModule)
|
||||
}];
|
||||
```
|
||||
|
@ -223,7 +223,7 @@ const routes: Routes = [{
|
|||
<div class="alert is-helpful">
|
||||
|
||||
|
||||
**v8 update**: When you update to version 8, the [`ng update`](cli/update) command performs the transformation automatically. Prior to version 7, the `import()` syntax only works in JIT mode (with view engine).
|
||||
**v8 update**: When you update to version 8, the [`ng update`](cli/update) command performs the transformation automatically. Prior to version 7, the `import()` syntax only works in JIT mode (with view engine).
|
||||
|
||||
|
||||
</div>
|
||||
|
@ -240,13 +240,13 @@ const routes: Routes = [{
|
|||
| `params` | `paramMap` |
|
||||
| `queryParams` | `queryParamMap` |
|
||||
|
||||
For more information see the [Router guide](guide/router#activated-route).
|
||||
For more information see the [Router guide](guide/router#activated-route).
|
||||
|
||||
|
||||
{@a removed}
|
||||
## Removed APIs
|
||||
|
||||
The following APIs have been removed starting with version 8.0.0:
|
||||
The following APIs have been removed starting with version 8.0.0:
|
||||
|
||||
| Package | API | Replacement | Notes |
|
||||
| ------- | -------------- | ----------- | ----- |
|
||||
|
@ -260,24 +260,24 @@ The following APIs have been removed starting with version 8.0.0:
|
|||
{@a http}
|
||||
### @angular/http
|
||||
|
||||
<!--
|
||||
Deprecation announced in version 5
|
||||
https://blog.angular.io/version-5-0-0-of-angular-now-available-37e414935ced)
|
||||
<!--
|
||||
Deprecation announced in version 5
|
||||
https://blog.angular.io/version-5-0-0-of-angular-now-available-37e414935ced)
|
||||
-->
|
||||
|
||||
|
||||
The entire [`@angular/http`](http://v7.angular.io/api/http) package has been removed. Use [`@angular/common/http`](api/common/http) instead.
|
||||
The entire [`@angular/http`](http://v7.angular.io/api/http) package has been removed. Use [`@angular/common/http`](api/common/http) instead.
|
||||
|
||||
The new API is a smaller, easier, and more powerful way to make HTTP requests in Angular.
|
||||
The new API simplifies the default ergonomics: There is no need to map by invoking the `.json()` method.
|
||||
It also supports typed return values and interceptors.
|
||||
The new API is a smaller, easier, and more powerful way to make HTTP requests in Angular.
|
||||
The new API simplifies the default ergonomics: There is no need to map by invoking the `.json()` method.
|
||||
It also supports typed return values and interceptors.
|
||||
|
||||
To update your apps:
|
||||
* Replace `HttpModule` with [`HttpClientModule`](api/common/http/HttpClientModule) (from [`@angular/common/http`](api/common/http)) in each of your modules.
|
||||
* Replace the `Http` service with the [`HttpClient`](api/common/http/HttpClient) service.
|
||||
* Remove any `map(res => res.json())` calls. They are no longer needed.
|
||||
* Remove any `map(res => res.json())` calls. They are no longer needed.
|
||||
|
||||
For more information about using `@angular/common/http`, see the [HttpClient guide](guide/http "HTTP Client guide").
|
||||
For more information about using `@angular/common/http`, see the [HttpClient guide](guide/http "HTTP Client guide").
|
||||
|
||||
|
||||
| `@angular/http` | Closest replacement in `@angular/common/http` |
|
||||
|
|
|
@ -74,7 +74,7 @@ module.exports = new Package('angular-api', [basePackage, typeScriptPackage])
|
|||
|
||||
// API files are typescript
|
||||
readTypeScriptModules.basePath = API_SOURCE_PATH;
|
||||
readTypeScriptModules.ignoreExportsMatching = [/^_|^ɵɵ|^VERSION$/];
|
||||
readTypeScriptModules.ignoreExportsMatching = [/^_|^Δ|^VERSION$/];
|
||||
readTypeScriptModules.hidePrivateMembers = true;
|
||||
|
||||
// NOTE: This list should be in sync with tools/public_api_guard/BUILD.bazel
|
||||
|
|
|
@ -37,7 +37,7 @@ We explicitly don't consider the following to be our public API surface:
|
|||
|
||||
- any file/import paths within our package except for the `/`, `/testing` and `/bundles/*` and other documented package entry-points.
|
||||
- constructors of injectable classes (services and directives) - please use DI to obtain instances of these classes
|
||||
- any class members or symbols marked as `private`, or prefixed with underscore (`_`), [barred latin o](https://en.wikipedia.org/wiki/%C6%9F) (`ɵ`), and [double barred latin o](https://en.wikipedia.org/wiki/%C6%9F) (`ɵɵ`).
|
||||
- any class members or symbols marked as `private`, or prefixed with underscore (`_`), [barred latin o](https://en.wikipedia.org/wiki/%C6%9F) (`ɵ`), and [greek delta](https://en.wikipedia.org/wiki/Delta_(letter)) (`Δ`).
|
||||
- extending any of our classes unless the support for this is specifically documented in the API docs
|
||||
- the contents and API surface of the code generated by Angular's compiler (with one notable exception: the existence and name of `NgModuleFactory` instances exported from generated code is guaranteed)
|
||||
|
||||
|
|
|
@ -40,25 +40,25 @@ if [[ $? != 0 ]]; then exit 1; fi
|
|||
if [[ $? != 0 ]]; then exit 1; fi
|
||||
|
||||
# Did it compile @angular/core/ApplicationModule correctly?
|
||||
grep "ApplicationModule.ngModuleDef = ɵɵdefineNgModule" node_modules/@angular/core/fesm2015/core.js
|
||||
grep "ApplicationModule.ngModuleDef = ΔdefineNgModule" node_modules/@angular/core/fesm2015/core.js
|
||||
if [[ $? != 0 ]]; then exit 1; fi
|
||||
grep "ApplicationModule.ngModuleDef = ɵɵdefineNgModule" node_modules/@angular/core/fesm5/core.js
|
||||
grep "ApplicationModule.ngModuleDef = ΔdefineNgModule" node_modules/@angular/core/fesm5/core.js
|
||||
if [[ $? != 0 ]]; then exit 1; fi
|
||||
grep "ApplicationModule.ngModuleDef = ɵngcc0.ɵɵdefineNgModule" node_modules/@angular/core/esm2015/src/application_module.js
|
||||
grep "ApplicationModule.ngModuleDef = ɵngcc0.ΔdefineNgModule" node_modules/@angular/core/esm2015/src/application_module.js
|
||||
if [[ $? != 0 ]]; then exit 1; fi
|
||||
grep "ApplicationModule.ngModuleDef = ɵngcc0.ɵɵdefineNgModule" node_modules/@angular/core/esm5/src/application_module.js
|
||||
grep "ApplicationModule.ngModuleDef = ɵngcc0.ΔdefineNgModule" node_modules/@angular/core/esm5/src/application_module.js
|
||||
if [[ $? != 0 ]]; then exit 1; fi
|
||||
|
||||
# Did it transform @angular/core typing files correctly?
|
||||
grep "import [*] as ɵngcc0 from './src/r3_symbols';" node_modules/@angular/core/core.d.ts
|
||||
if [[ $? != 0 ]]; then exit 1; fi
|
||||
grep "static ngInjectorDef: ɵngcc0.ɵɵInjectorDef<ApplicationModule>;" node_modules/@angular/core/core.d.ts
|
||||
grep "static ngInjectorDef: ɵngcc0.ΔInjectorDef<ApplicationModule>;" node_modules/@angular/core/core.d.ts
|
||||
if [[ $? != 0 ]]; then exit 1; fi
|
||||
|
||||
# Did it generate a base factory call for synthesized constructors correctly?
|
||||
grep "const ɵMatTable_BaseFactory = ɵngcc0.ɵɵgetInheritedFactory(MatTable);" node_modules/@angular/material/esm2015/table.js
|
||||
grep "const ɵMatTable_BaseFactory = ɵngcc0.ΔgetInheritedFactory(MatTable);" node_modules/@angular/material/esm2015/table.js
|
||||
if [[ $? != 0 ]]; then exit 1; fi
|
||||
grep "const ɵMatTable_BaseFactory = ɵngcc0.ɵɵgetInheritedFactory(MatTable);" node_modules/@angular/material/esm5/table.es5.js
|
||||
grep "const ɵMatTable_BaseFactory = ɵngcc0.ΔgetInheritedFactory(MatTable);" node_modules/@angular/material/esm5/table.es5.js
|
||||
if [[ $? != 0 ]]; then exit 1; fi
|
||||
|
||||
# Can it be safely run again (as a noop)?
|
||||
|
|
|
@ -6,7 +6,7 @@
|
|||
* found in the LICENSE file at https://angular.io/license
|
||||
*/
|
||||
|
||||
import {ɵRenderFlags, ɵrenderComponent as renderComponent, ɵɵcontainer, ɵɵcontainerRefreshEnd, ɵɵcontainerRefreshStart, ɵɵdefineComponent, ɵɵelementEnd, ɵɵelementStart, ɵɵembeddedViewEnd, ɵɵembeddedViewStart, ɵɵinterpolation1, ɵɵselect, ɵɵstyleProp, ɵɵstyling, ɵɵtext, ɵɵtextBinding} from '@angular/core';
|
||||
import {ɵRenderFlags, ɵrenderComponent as renderComponent, Δcontainer, ΔcontainerRefreshEnd, ΔcontainerRefreshStart, ΔdefineComponent, ΔelementEnd, ΔelementStart, ΔembeddedViewEnd, ΔembeddedViewStart, Δinterpolation1, Δselect, ΔstyleProp, Δstyling, Δtext, ΔtextBinding} from '@angular/core';
|
||||
|
||||
import {bindAction, profile} from '../../util';
|
||||
import {createDom, destroyDom, detectChanges} from '../render3/tree';
|
||||
|
@ -18,7 +18,7 @@ export class TreeFunction {
|
|||
data: TreeNode = emptyTree;
|
||||
|
||||
/** @nocollapse */
|
||||
static ngComponentDef = ɵɵdefineComponent({
|
||||
static ngComponentDef = ΔdefineComponent({
|
||||
type: TreeFunction,
|
||||
selectors: [['tree']],
|
||||
consts: 5,
|
||||
|
@ -35,41 +35,41 @@ export class TreeFunction {
|
|||
const c1 = ['background-color'];
|
||||
export function TreeTpl(rf: ɵRenderFlags, ctx: TreeNode) {
|
||||
if (rf & ɵRenderFlags.Create) {
|
||||
ɵɵelementStart(0, 'tree');
|
||||
ΔelementStart(0, 'tree');
|
||||
{
|
||||
ɵɵelementStart(1, 'span');
|
||||
ɵɵstyling(null, c1);
|
||||
{ ɵɵtext(2); }
|
||||
ɵɵelementEnd();
|
||||
ɵɵcontainer(3);
|
||||
ɵɵcontainer(4);
|
||||
ΔelementStart(1, 'span');
|
||||
Δstyling(null, c1);
|
||||
{ Δtext(2); }
|
||||
ΔelementEnd();
|
||||
Δcontainer(3);
|
||||
Δcontainer(4);
|
||||
}
|
||||
ɵɵelementEnd();
|
||||
ΔelementEnd();
|
||||
}
|
||||
if (rf & ɵRenderFlags.Update) {
|
||||
ɵɵselect(1);
|
||||
ɵɵstyleProp(0, ctx.depth % 2 ? '' : 'grey');
|
||||
ɵɵstyling();
|
||||
ɵɵselect(2);
|
||||
ɵɵtextBinding(2, ɵɵinterpolation1(' ', ctx.value, ' '));
|
||||
ɵɵcontainerRefreshStart(3);
|
||||
Δselect(1);
|
||||
ΔstyleProp(0, ctx.depth % 2 ? '' : 'grey');
|
||||
Δstyling();
|
||||
Δselect(2);
|
||||
ΔtextBinding(2, Δinterpolation1(' ', ctx.value, ' '));
|
||||
ΔcontainerRefreshStart(3);
|
||||
{
|
||||
if (ctx.left != null) {
|
||||
let rf0 = ɵɵembeddedViewStart(0, 5, 1);
|
||||
let rf0 = ΔembeddedViewStart(0, 5, 1);
|
||||
{ TreeTpl(rf0, ctx.left); }
|
||||
ɵɵembeddedViewEnd();
|
||||
ΔembeddedViewEnd();
|
||||
}
|
||||
}
|
||||
ɵɵcontainerRefreshEnd();
|
||||
ɵɵcontainerRefreshStart(4);
|
||||
ΔcontainerRefreshEnd();
|
||||
ΔcontainerRefreshStart(4);
|
||||
{
|
||||
if (ctx.right != null) {
|
||||
let rf0 = ɵɵembeddedViewStart(0, 5, 1);
|
||||
let rf0 = ΔembeddedViewStart(0, 5, 1);
|
||||
{ TreeTpl(rf0, ctx.right); }
|
||||
ɵɵembeddedViewEnd();
|
||||
ΔembeddedViewEnd();
|
||||
}
|
||||
}
|
||||
ɵɵcontainerRefreshEnd();
|
||||
ΔcontainerRefreshEnd();
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -5,7 +5,7 @@
|
|||
* 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
|
||||
*/
|
||||
import {Directive, DoCheck, Input, ɵRenderFlags, ɵɵclassMap, ɵɵdefineDirective, ɵɵstyling, ɵɵstylingApply} from '@angular/core';
|
||||
import {Directive, DoCheck, Input, ɵRenderFlags, ΔclassMap, ΔdefineDirective, Δstyling, ΔstylingApply} from '@angular/core';
|
||||
|
||||
import {NgClassImpl, NgClassImplProvider} from './ng_class_impl';
|
||||
|
||||
|
@ -29,17 +29,17 @@ export const ngClassDirectiveDef__PRE_R3__ = undefined;
|
|||
// used when the VE is not present (note the directive will
|
||||
// never be instantiated normally because it is apart of a
|
||||
// base class)
|
||||
export const ngClassDirectiveDef__POST_R3__ = ɵɵdefineDirective({
|
||||
export const ngClassDirectiveDef__POST_R3__ = ΔdefineDirective({
|
||||
type: function() {} as any,
|
||||
selectors: null as any,
|
||||
factory: () => {},
|
||||
hostBindings: function(rf: ɵRenderFlags, ctx: any, elIndex: number) {
|
||||
if (rf & ɵRenderFlags.Create) {
|
||||
ɵɵstyling();
|
||||
Δstyling();
|
||||
}
|
||||
if (rf & ɵRenderFlags.Update) {
|
||||
ɵɵclassMap(ctx.getValue());
|
||||
ɵɵstylingApply();
|
||||
ΔclassMap(ctx.getValue());
|
||||
ΔstylingApply();
|
||||
}
|
||||
}
|
||||
});
|
||||
|
|
|
@ -5,7 +5,7 @@
|
|||
* 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
|
||||
*/
|
||||
import {Directive, DoCheck, Input, ɵRenderFlags, ɵɵdefineDirective, ɵɵstyleMap, ɵɵstyling, ɵɵstylingApply} from '@angular/core';
|
||||
import {Directive, DoCheck, Input, ɵRenderFlags, ΔdefineDirective, ΔstyleMap, Δstyling, ΔstylingApply} from '@angular/core';
|
||||
|
||||
import {NgStyleImpl, NgStyleImplProvider} from './ng_style_impl';
|
||||
|
||||
|
@ -29,17 +29,17 @@ export const ngStyleDirectiveDef__PRE_R3__ = undefined;
|
|||
// used when the VE is not present (note the directive will
|
||||
// never be instantiated normally because it is apart of a
|
||||
// base class)
|
||||
export const ngStyleDirectiveDef__POST_R3__ = ɵɵdefineDirective({
|
||||
export const ngStyleDirectiveDef__POST_R3__ = ΔdefineDirective({
|
||||
type: function() {} as any,
|
||||
selectors: null as any,
|
||||
factory: () => {},
|
||||
hostBindings: function(rf: ɵRenderFlags, ctx: any, elIndex: number) {
|
||||
if (rf & ɵRenderFlags.Create) {
|
||||
ɵɵstyling();
|
||||
Δstyling();
|
||||
}
|
||||
if (rf & ɵRenderFlags.Update) {
|
||||
ɵɵstyleMap(ctx.getValue());
|
||||
ɵɵstylingApply();
|
||||
ΔstyleMap(ctx.getValue());
|
||||
ΔstylingApply();
|
||||
}
|
||||
}
|
||||
});
|
||||
|
|
|
@ -6,7 +6,7 @@
|
|||
* found in the LICENSE file at https://angular.io/license
|
||||
*/
|
||||
|
||||
import {ErrorHandler, ɵɵdefineInjectable, ɵɵinject} from '@angular/core';
|
||||
import {ErrorHandler, ΔdefineInjectable, Δinject} from '@angular/core';
|
||||
|
||||
import {DOCUMENT} from './dom_tokens';
|
||||
|
||||
|
@ -21,9 +21,9 @@ export abstract class ViewportScroller {
|
|||
// De-sugared tree-shakable injection
|
||||
// See #23917
|
||||
/** @nocollapse */
|
||||
static ngInjectableDef = ɵɵdefineInjectable({
|
||||
static ngInjectableDef = ΔdefineInjectable({
|
||||
providedIn: 'root',
|
||||
factory: () => new BrowserViewportScroller(ɵɵinject(DOCUMENT), window, ɵɵinject(ErrorHandler))
|
||||
factory: () => new BrowserViewportScroller(Δinject(DOCUMENT), window, Δinject(ErrorHandler))
|
||||
});
|
||||
|
||||
/**
|
||||
|
|
|
@ -160,11 +160,11 @@ describe('Renderer', () => {
|
|||
const addDefinitionsSpy = renderer.addDefinitions as jasmine.Spy;
|
||||
expect(addDefinitionsSpy.calls.first().args[2])
|
||||
.toEqual(
|
||||
`A.ngComponentDef = ɵngcc0.ɵɵdefineComponent({ type: A, selectors: [["a"]], factory: function A_Factory(t) { return new (t || A)(); }, consts: 1, vars: 1, template: function A_Template(rf, ctx) { if (rf & 1) {
|
||||
ɵngcc0.ɵɵtext(0);
|
||||
`A.ngComponentDef = ɵngcc0.ΔdefineComponent({ type: A, selectors: [["a"]], factory: function A_Factory(t) { return new (t || A)(); }, consts: 1, vars: 1, template: function A_Template(rf, ctx) { if (rf & 1) {
|
||||
ɵngcc0.Δtext(0);
|
||||
} if (rf & 2) {
|
||||
ɵngcc0.ɵɵselect(0);
|
||||
ɵngcc0.ɵɵtextBinding(0, ɵngcc0.ɵɵinterpolation1("", ctx.person.name, ""));
|
||||
ɵngcc0.Δselect(0);
|
||||
ɵngcc0.ΔtextBinding(0, ɵngcc0.Δinterpolation1("", ctx.person.name, ""));
|
||||
} }, encapsulation: 2 });
|
||||
/*@__PURE__*/ ɵngcc0.ɵsetClassMetadata(A, [{
|
||||
type: Component,
|
||||
|
@ -205,7 +205,7 @@ describe('Renderer', () => {
|
|||
}));
|
||||
expect(addDefinitionsSpy.calls.first().args[2])
|
||||
.toEqual(
|
||||
`A.ngDirectiveDef = ɵngcc0.ɵɵdefineDirective({ type: A, selectors: [["", "a", ""]], factory: function A_Factory(t) { return new (t || A)(); } });
|
||||
`A.ngDirectiveDef = ɵngcc0.ΔdefineDirective({ type: A, selectors: [["", "a", ""]], factory: function A_Factory(t) { return new (t || A)(); } });
|
||||
/*@__PURE__*/ ɵngcc0.ɵsetClassMetadata(A, [{
|
||||
type: Directive,
|
||||
args: [{ selector: '[a]' }]
|
||||
|
@ -339,7 +339,7 @@ describe('Renderer', () => {
|
|||
const typingsFile = result.find(f => f.path === '/typings/file.d.ts') !;
|
||||
expect(typingsFile.contents)
|
||||
.toContain(
|
||||
'foo(x: number): number;\n static ngDirectiveDef: ɵngcc0.ɵɵDirectiveDefWithMeta');
|
||||
'foo(x: number): number;\n static ngDirectiveDef: ɵngcc0.ΔDirectiveDefWithMeta');
|
||||
});
|
||||
|
||||
it('should render imports into typings files', () => {
|
||||
|
|
|
@ -423,7 +423,7 @@ export class MetadataBundler {
|
|||
result[key] = this.convertFunction(moduleName, value);
|
||||
} else if (isMetadataSymbolicCallExpression(value)) {
|
||||
// Class members can also contain static members that call a function with module
|
||||
// references. e.g. "static ngInjectableDef = ɵɵdefineInjectable(..)". We also need to
|
||||
// references. e.g. "static ngInjectableDef = ΔdefineInjectable(..)". We also need to
|
||||
// convert these module references because otherwise these resolve to non-existent files.
|
||||
result[key] = this.convertValue(moduleName, value);
|
||||
} else {
|
||||
|
|
|
@ -48,15 +48,15 @@ export class NoopImportRewriter implements ImportRewriter {
|
|||
* which they're exported from r3_symbols.
|
||||
*/
|
||||
const CORE_SUPPORTED_SYMBOLS = new Map<string, string>([
|
||||
['ɵɵdefineInjectable', 'ɵɵdefineInjectable'],
|
||||
['ɵɵdefineInjector', 'ɵɵdefineInjector'],
|
||||
['ɵɵdefineNgModule', 'ɵɵdefineNgModule'],
|
||||
['ɵɵsetNgModuleScope', 'ɵɵsetNgModuleScope'],
|
||||
['ɵɵinject', 'ɵɵinject'],
|
||||
['ΔdefineInjectable', 'ΔdefineInjectable'],
|
||||
['ΔdefineInjector', 'ΔdefineInjector'],
|
||||
['ΔdefineNgModule', 'ΔdefineNgModule'],
|
||||
['ΔsetNgModuleScope', 'ΔsetNgModuleScope'],
|
||||
['Δinject', 'Δinject'],
|
||||
['ɵsetClassMetadata', 'setClassMetadata'],
|
||||
['ɵɵInjectableDef', 'ɵɵInjectableDef'],
|
||||
['ɵɵInjectorDef', 'ɵɵInjectorDef'],
|
||||
['ɵɵNgModuleDefWithMeta', 'ɵɵNgModuleDefWithMeta'],
|
||||
['ΔInjectableDef', 'ΔInjectableDef'],
|
||||
['ΔInjectorDef', 'ΔInjectorDef'],
|
||||
['ΔNgModuleDefWithMeta', 'ΔNgModuleDefWithMeta'],
|
||||
['ɵNgModuleFactory', 'NgModuleFactory'],
|
||||
]);
|
||||
|
||||
|
|
|
@ -14,7 +14,7 @@ import * as ts from 'typescript';
|
|||
import {NgtscProgram} from '../../src/ngtsc/program';
|
||||
|
||||
|
||||
const IDENTIFIER = /[A-Za-z_$ɵ][A-Za-z0-9_$]*/;
|
||||
const IDENTIFIER = /[A-Za-z_$ɵΔ][A-Za-z0-9_$]*/;
|
||||
const OPERATOR =
|
||||
/!|\?|%|\*|\/|\^|&&?|\|\|?|\(|\)|\{|\}|\[|\]|:|;|<=?|>=?|={1,3}|!==?|=>|\+\+?|--?|@|,|\.|\.\.\./;
|
||||
const STRING = /'[^']*'|"[^"]*"|`[\s\S]*?`/;
|
||||
|
|
|
@ -140,7 +140,7 @@ describe('mock_compiler', () => {
|
|||
expectEmit(
|
||||
result.source, `
|
||||
// TODO: this comment should not be taken into account
|
||||
$r3$.ɵɵtext(0, "Hello!");
|
||||
$r3$.Δtext(0, "Hello!");
|
||||
// TODO: this comment should not be taken into account
|
||||
`,
|
||||
'todo comments should be ignored');
|
||||
|
|
File diff suppressed because it is too large
Load Diff
|
@ -39,13 +39,13 @@ describe('compiler compliance: bindings', () => {
|
|||
const template = `
|
||||
template:function MyComponent_Template(rf, $ctx$){
|
||||
if (rf & 1) {
|
||||
$i0$.ɵɵelementStart(0, "div");
|
||||
$i0$.ɵɵtext(1);
|
||||
$i0$.ɵɵelementEnd();
|
||||
$i0$.ΔelementStart(0, "div");
|
||||
$i0$.Δtext(1);
|
||||
$i0$.ΔelementEnd();
|
||||
}
|
||||
if (rf & 2) {
|
||||
$r3$.ɵɵselect(1);
|
||||
$i0$.ɵɵtextBinding(1, $i0$.ɵɵinterpolation1("Hello ", $ctx$.name, ""));
|
||||
$r3$.Δselect(1);
|
||||
$i0$.ΔtextBinding(1, $i0$.Δinterpolation1("Hello ", $ctx$.name, ""));
|
||||
}
|
||||
}`;
|
||||
const result = compile(files, angularFiles);
|
||||
|
@ -78,11 +78,11 @@ describe('compiler compliance: bindings', () => {
|
|||
…
|
||||
template:function MyComponent_Template(rf, $ctx$){
|
||||
if (rf & 1) {
|
||||
$i0$.ɵɵelement(0, "a", $e0_attrs$);
|
||||
$i0$.Δelement(0, "a", $e0_attrs$);
|
||||
}
|
||||
if (rf & 2) {
|
||||
$i0$.ɵɵselect(0);
|
||||
$i0$.ɵɵproperty("title", $ctx$.title);
|
||||
$i0$.Δselect(0);
|
||||
$i0$.Δproperty("title", $ctx$.title);
|
||||
}
|
||||
}`;
|
||||
const result = compile(files, angularFiles);
|
||||
|
@ -113,11 +113,11 @@ describe('compiler compliance: bindings', () => {
|
|||
…
|
||||
template:function MyComponent_Template(rf, $ctx$){
|
||||
if (rf & 1) {
|
||||
$i0$.ɵɵelement(0, "a", $e0_attrs$);
|
||||
$i0$.Δelement(0, "a", $e0_attrs$);
|
||||
}
|
||||
if (rf & 2) {
|
||||
$i0$.ɵɵselect(0);
|
||||
$i0$.ɵɵpropertyInterpolate1("title", "Hello ", $ctx$.name, "");
|
||||
$i0$.Δselect(0);
|
||||
$i0$.ΔpropertyInterpolate1("title", "Hello ", $ctx$.name, "");
|
||||
}
|
||||
}`;
|
||||
const result = compile(files, angularFiles);
|
||||
|
@ -138,7 +138,7 @@ describe('compiler compliance: bindings', () => {
|
|||
}
|
||||
};
|
||||
const result = compile(files, angularFiles);
|
||||
expect(result.source).not.toContain('i0.ɵɵelementProperty');
|
||||
expect(result.source).not.toContain('i0.ΔelementProperty');
|
||||
});
|
||||
|
||||
it('should not remap property names whose names do not correspond to their attribute names',
|
||||
|
@ -170,11 +170,11 @@ describe('compiler compliance: bindings', () => {
|
|||
|
||||
function MyComponent_Template(rf, ctx) {
|
||||
if (rf & 1) {
|
||||
$i0$.ɵɵelement(0, "label", _c0);
|
||||
$i0$.Δelement(0, "label", _c0);
|
||||
}
|
||||
if (rf & 2) {
|
||||
$i0$.ɵɵselect(0);
|
||||
$i0$.ɵɵproperty("for", ctx.forValue);
|
||||
$i0$.Δselect(0);
|
||||
$i0$.Δproperty("for", ctx.forValue);
|
||||
}
|
||||
}`;
|
||||
|
||||
|
@ -204,16 +204,16 @@ describe('compiler compliance: bindings', () => {
|
|||
};
|
||||
|
||||
const HostBindingDirDeclaration = `
|
||||
HostBindingDir.ngDirectiveDef = $r3$.ɵɵdefineDirective({
|
||||
HostBindingDir.ngDirectiveDef = $r3$.ΔdefineDirective({
|
||||
type: HostBindingDir,
|
||||
selectors: [["", "hostBindingDir", ""]],
|
||||
factory: function HostBindingDir_Factory(t) { return new (t || HostBindingDir)(); },
|
||||
hostBindings: function HostBindingDir_HostBindings(rf, ctx, elIndex) {
|
||||
if (rf & 1) {
|
||||
$r3$.ɵɵallocHostVars(1);
|
||||
$r3$.ΔallocHostVars(1);
|
||||
}
|
||||
if (rf & 2) {
|
||||
$r3$.ɵɵproperty("id", ctx.dirId, null, true);
|
||||
$r3$.Δproperty("id", ctx.dirId, null, true);
|
||||
}
|
||||
}
|
||||
});
|
||||
|
@ -251,16 +251,16 @@ describe('compiler compliance: bindings', () => {
|
|||
const HostBindingCompDeclaration = `
|
||||
const $ff$ = function ($v$) { return ["red", $v$]; };
|
||||
…
|
||||
HostBindingComp.ngComponentDef = $r3$.ɵɵdefineComponent({
|
||||
HostBindingComp.ngComponentDef = $r3$.ΔdefineComponent({
|
||||
type: HostBindingComp,
|
||||
selectors: [["host-binding-comp"]],
|
||||
factory: function HostBindingComp_Factory(t) { return new (t || HostBindingComp)(); },
|
||||
hostBindings: function HostBindingComp_HostBindings(rf, ctx, elIndex) {
|
||||
if (rf & 1) {
|
||||
$r3$.ɵɵallocHostVars(3);
|
||||
$r3$.ΔallocHostVars(3);
|
||||
}
|
||||
if (rf & 2) {
|
||||
$r3$.ɵɵproperty("id", $r3$.ɵɵpureFunction1(1, $ff$, ctx.id), null, true);
|
||||
$r3$.Δproperty("id", $r3$.ΔpureFunction1(1, $ff$, ctx.id), null, true);
|
||||
}
|
||||
},
|
||||
consts: 0,
|
||||
|
@ -299,16 +299,16 @@ describe('compiler compliance: bindings', () => {
|
|||
};
|
||||
|
||||
const HostAttributeDirDeclaration = `
|
||||
HostAttributeDir.ngDirectiveDef = $r3$.ɵɵdefineDirective({
|
||||
HostAttributeDir.ngDirectiveDef = $r3$.ΔdefineDirective({
|
||||
type: HostAttributeDir,
|
||||
selectors: [["", "hostAttributeDir", ""]],
|
||||
factory: function HostAttributeDir_Factory(t) { return new (t || HostAttributeDir)(); },
|
||||
hostBindings: function HostAttributeDir_HostBindings(rf, ctx, elIndex) {
|
||||
if (rf & 1) {
|
||||
$r3$.ɵɵallocHostVars(1);
|
||||
$r3$.ΔallocHostVars(1);
|
||||
}
|
||||
if (rf & 2) {
|
||||
$r3$.ɵɵelementAttribute(elIndex, "required", $r3$.ɵɵbind(ctx.required));
|
||||
$r3$.ΔelementAttribute(elIndex, "required", $r3$.Δbind(ctx.required));
|
||||
}
|
||||
}
|
||||
});
|
||||
|
@ -344,13 +344,13 @@ describe('compiler compliance: bindings', () => {
|
|||
const HostAttributeDirDeclaration = `
|
||||
const $c0$ = ["aria-label", "label"];
|
||||
…
|
||||
HostAttributeDir.ngDirectiveDef = $r3$.ɵɵdefineDirective({
|
||||
HostAttributeDir.ngDirectiveDef = $r3$.ΔdefineDirective({
|
||||
type: HostAttributeDir,
|
||||
selectors: [["", "hostAttributeDir", ""]],
|
||||
factory: function HostAttributeDir_Factory(t) { return new (t || HostAttributeDir)(); },
|
||||
hostBindings: function HostAttributeDir_HostBindings(rf, ctx, elIndex) {
|
||||
if (rf & 1) {
|
||||
$r3$.ɵɵelementHostAttrs($c0$);
|
||||
$r3$.ΔelementHostAttrs($c0$);
|
||||
}
|
||||
}
|
||||
});
|
||||
|
@ -402,25 +402,25 @@ describe('compiler compliance: bindings', () => {
|
|||
const $c0$ = ["title", "hello there from component", ${AttributeMarker.Styles}, "opacity", "1"];
|
||||
const $c1$ = ["title", "hello there from directive", ${AttributeMarker.Classes}, "one", "two", ${AttributeMarker.Styles}, "width", "200px", "height", "500px"];
|
||||
…
|
||||
HostAttributeComp.ngComponentDef = $r3$.ɵɵdefineComponent({
|
||||
HostAttributeComp.ngComponentDef = $r3$.ΔdefineComponent({
|
||||
type: HostAttributeComp,
|
||||
selectors: [["my-host-attribute-component"]],
|
||||
factory: function HostAttributeComp_Factory(t) { return new (t || HostAttributeComp)(); },
|
||||
hostBindings: function HostAttributeComp_HostBindings(rf, ctx, elIndex) {
|
||||
if (rf & 1) {
|
||||
$r3$.ɵɵelementHostAttrs($c0$);
|
||||
$r3$.ΔelementHostAttrs($c0$);
|
||||
…
|
||||
}
|
||||
…
|
||||
}
|
||||
…
|
||||
HostAttributeDir.ngDirectiveDef = $r3$.ɵɵdefineDirective({
|
||||
HostAttributeDir.ngDirectiveDef = $r3$.ΔdefineDirective({
|
||||
type: HostAttributeDir,
|
||||
selectors: [["", "hostAttributeDir", ""]],
|
||||
factory: function HostAttributeDir_Factory(t) { return new (t || HostAttributeDir)(); },
|
||||
hostBindings: function HostAttributeDir_HostBindings(rf, ctx, elIndex) {
|
||||
if (rf & 1) {
|
||||
$r3$.ɵɵelementHostAttrs($c1$);
|
||||
$r3$.ΔelementHostAttrs($c1$);
|
||||
…
|
||||
}
|
||||
…
|
||||
|
@ -469,26 +469,26 @@ describe('compiler compliance: bindings', () => {
|
|||
const template = `
|
||||
…
|
||||
if (rf & 2) {
|
||||
i0.ɵɵselect(0);
|
||||
i0.ɵɵpropertyInterpolateV("title", ["a", ctx.one, "b", ctx.two, "c", ctx.three, "d", ctx.four, "e", ctx.five, "f", ctx.six, "g", ctx.seven, "h", ctx.eight, "i", ctx.nine, "j"]);
|
||||
i0.ɵɵselect(1);
|
||||
i0.ɵɵpropertyInterpolate8("title", "a", ctx.one, "b", ctx.two, "c", ctx.three, "d", ctx.four, "e", ctx.five, "f", ctx.six, "g", ctx.seven, "h", ctx.eight, "i");
|
||||
i0.ɵɵselect(2);
|
||||
i0.ɵɵpropertyInterpolate7("title", "a", ctx.one, "b", ctx.two, "c", ctx.three, "d", ctx.four, "e", ctx.five, "f", ctx.six, "g", ctx.seven, "h");
|
||||
i0.ɵɵselect(3);
|
||||
i0.ɵɵpropertyInterpolate6("title", "a", ctx.one, "b", ctx.two, "c", ctx.three, "d", ctx.four, "e", ctx.five, "f", ctx.six, "g");
|
||||
i0.ɵɵselect(4);
|
||||
i0.ɵɵpropertyInterpolate5("title", "a", ctx.one, "b", ctx.two, "c", ctx.three, "d", ctx.four, "e", ctx.five, "f");
|
||||
i0.ɵɵselect(5);
|
||||
i0.ɵɵpropertyInterpolate4("title", "a", ctx.one, "b", ctx.two, "c", ctx.three, "d", ctx.four, "e");
|
||||
i0.ɵɵselect(6);
|
||||
i0.ɵɵpropertyInterpolate3("title", "a", ctx.one, "b", ctx.two, "c", ctx.three, "d");
|
||||
i0.ɵɵselect(7);
|
||||
i0.ɵɵpropertyInterpolate2("title", "a", ctx.one, "b", ctx.two, "c");
|
||||
i0.ɵɵselect(8);
|
||||
i0.ɵɵpropertyInterpolate1("title", "a", ctx.one, "b");
|
||||
i0.ɵɵselect(9);
|
||||
i0.ɵɵpropertyInterpolate("title", ctx.one);
|
||||
i0.Δselect(0);
|
||||
i0.ΔpropertyInterpolateV("title", ["a", ctx.one, "b", ctx.two, "c", ctx.three, "d", ctx.four, "e", ctx.five, "f", ctx.six, "g", ctx.seven, "h", ctx.eight, "i", ctx.nine, "j"]);
|
||||
i0.Δselect(1);
|
||||
i0.ΔpropertyInterpolate8("title", "a", ctx.one, "b", ctx.two, "c", ctx.three, "d", ctx.four, "e", ctx.five, "f", ctx.six, "g", ctx.seven, "h", ctx.eight, "i");
|
||||
i0.Δselect(2);
|
||||
i0.ΔpropertyInterpolate7("title", "a", ctx.one, "b", ctx.two, "c", ctx.three, "d", ctx.four, "e", ctx.five, "f", ctx.six, "g", ctx.seven, "h");
|
||||
i0.Δselect(3);
|
||||
i0.ΔpropertyInterpolate6("title", "a", ctx.one, "b", ctx.two, "c", ctx.three, "d", ctx.four, "e", ctx.five, "f", ctx.six, "g");
|
||||
i0.Δselect(4);
|
||||
i0.ΔpropertyInterpolate5("title", "a", ctx.one, "b", ctx.two, "c", ctx.three, "d", ctx.four, "e", ctx.five, "f");
|
||||
i0.Δselect(5);
|
||||
i0.ΔpropertyInterpolate4("title", "a", ctx.one, "b", ctx.two, "c", ctx.three, "d", ctx.four, "e");
|
||||
i0.Δselect(6);
|
||||
i0.ΔpropertyInterpolate3("title", "a", ctx.one, "b", ctx.two, "c", ctx.three, "d");
|
||||
i0.Δselect(7);
|
||||
i0.ΔpropertyInterpolate2("title", "a", ctx.one, "b", ctx.two, "c");
|
||||
i0.Δselect(8);
|
||||
i0.ΔpropertyInterpolate1("title", "a", ctx.one, "b");
|
||||
i0.Δselect(9);
|
||||
i0.ΔpropertyInterpolate("title", ctx.one);
|
||||
}
|
||||
…
|
||||
`;
|
||||
|
@ -510,19 +510,19 @@ describe('compiler compliance: bindings', () => {
|
|||
…
|
||||
template:function MyComponent_Template(rf, $ctx$){
|
||||
if (rf & 1) {
|
||||
$i0$.ɵɵelementStart(0, "b", $_c0$, $_c1$);
|
||||
$i0$.ɵɵdisableBindings();
|
||||
$i0$.ɵɵelementStart(2, "i");
|
||||
$i0$.ɵɵtext(3, "Hello {{ name }}!");
|
||||
$i0$.ɵɵelementEnd();
|
||||
$i0$.ɵɵenableBindings();
|
||||
$i0$.ɵɵelementEnd();
|
||||
$i0$.ɵɵtext(4);
|
||||
$i0$.ΔelementStart(0, "b", $_c0$, $_c1$);
|
||||
$i0$.ΔdisableBindings();
|
||||
$i0$.ΔelementStart(2, "i");
|
||||
$i0$.Δtext(3, "Hello {{ name }}!");
|
||||
$i0$.ΔelementEnd();
|
||||
$i0$.ΔenableBindings();
|
||||
$i0$.ΔelementEnd();
|
||||
$i0$.Δtext(4);
|
||||
}
|
||||
if (rf & 2) {
|
||||
const $_r0$ = $i0$.ɵɵreference(1);
|
||||
$r3$.ɵɵselect(4);
|
||||
$i0$.ɵɵtextBinding(4, $i0$.ɵɵinterpolation1(" ", $_r0$.id, " "));
|
||||
const $_r0$ = $i0$.Δreference(1);
|
||||
$r3$.Δselect(4);
|
||||
$i0$.ΔtextBinding(4, $i0$.Δinterpolation1(" ", $_r0$.id, " "));
|
||||
}
|
||||
}
|
||||
`;
|
||||
|
@ -542,12 +542,12 @@ describe('compiler compliance: bindings', () => {
|
|||
…
|
||||
template:function MyComponent_Template(rf, $ctx$){
|
||||
if (rf & 1) {
|
||||
$i0$.ɵɵelementStart(0, "div");
|
||||
$i0$.ɵɵdisableBindings();
|
||||
$i0$.ɵɵelement(1, "input", $_c0$);
|
||||
$i0$.ɵɵtext(2, " {{ myInput.value }} ");
|
||||
$i0$.ɵɵenableBindings();
|
||||
$i0$.ɵɵelementEnd();
|
||||
$i0$.ΔelementStart(0, "div");
|
||||
$i0$.ΔdisableBindings();
|
||||
$i0$.Δelement(1, "input", $_c0$);
|
||||
$i0$.Δtext(2, " {{ myInput.value }} ");
|
||||
$i0$.ΔenableBindings();
|
||||
$i0$.ΔelementEnd();
|
||||
}
|
||||
`;
|
||||
const result = compile(files, angularFiles);
|
||||
|
@ -566,11 +566,11 @@ describe('compiler compliance: bindings', () => {
|
|||
…
|
||||
template:function MyComponent_Template(rf, $ctx$){
|
||||
if (rf & 1) {
|
||||
$i0$.ɵɵelementStart(0, "div");
|
||||
$i0$.ɵɵdisableBindings();
|
||||
$i0$.ɵɵelement(1, "div", $_c0$);
|
||||
$i0$.ɵɵenableBindings();
|
||||
$i0$.ɵɵelementEnd();
|
||||
$i0$.ΔelementStart(0, "div");
|
||||
$i0$.ΔdisableBindings();
|
||||
$i0$.Δelement(1, "div", $_c0$);
|
||||
$i0$.ΔenableBindings();
|
||||
$i0$.ΔelementEnd();
|
||||
}
|
||||
`;
|
||||
const result = compile(files, angularFiles);
|
||||
|
@ -585,7 +585,7 @@ describe('compiler compliance: bindings', () => {
|
|||
const template = `
|
||||
template:function MyComponent_Template(rf, $ctx$){
|
||||
if (rf & 1) {
|
||||
$i0$.ɵɵelement(0, "div");
|
||||
$i0$.Δelement(0, "div");
|
||||
}
|
||||
}
|
||||
`;
|
||||
|
|
|
@ -50,13 +50,13 @@ describe('compiler compliance: dependency injection', () => {
|
|||
const factory = `
|
||||
factory: function MyComponent_Factory(t) {
|
||||
return new (t || MyComponent)(
|
||||
$r3$.ɵɵinjectAttribute('name'),
|
||||
$r3$.ɵɵdirectiveInject(MyService),
|
||||
$r3$.ɵɵdirectiveInject(MyService, 1),
|
||||
$r3$.ɵɵdirectiveInject(MyService, 2),
|
||||
$r3$.ɵɵdirectiveInject(MyService, 4),
|
||||
$r3$.ɵɵdirectiveInject(MyService, 8),
|
||||
$r3$.ɵɵdirectiveInject(MyService, 10)
|
||||
$r3$.ΔinjectAttribute('name'),
|
||||
$r3$.ΔdirectiveInject(MyService),
|
||||
$r3$.ΔdirectiveInject(MyService, 1),
|
||||
$r3$.ΔdirectiveInject(MyService, 2),
|
||||
$r3$.ΔdirectiveInject(MyService, 4),
|
||||
$r3$.ΔdirectiveInject(MyService, 8),
|
||||
$r3$.ΔdirectiveInject(MyService, 10)
|
||||
);
|
||||
}`;
|
||||
|
||||
|
|
|
@ -38,7 +38,7 @@ describe('compiler compliance: directives', () => {
|
|||
|
||||
// MyComponent definition should be:
|
||||
const MyComponentDefinition = `
|
||||
MyComponent.ngComponentDef = $r3$.ɵɵdefineComponent({
|
||||
MyComponent.ngComponentDef = $r3$.ΔdefineComponent({
|
||||
type: MyComponent,
|
||||
selectors: [["my-component"]],
|
||||
factory: function MyComponent_Factory(t) { return new (t || MyComponent)(); },
|
||||
|
@ -46,7 +46,7 @@ describe('compiler compliance: directives', () => {
|
|||
vars: 0,
|
||||
template: function MyComponent_Template(rf, ctx) {
|
||||
if (rf & 1) {
|
||||
$r3$.ɵɵelement(0, "div");
|
||||
$r3$.Δelement(0, "div");
|
||||
}
|
||||
},
|
||||
encapsulation: 2
|
||||
|
@ -84,7 +84,7 @@ describe('compiler compliance: directives', () => {
|
|||
|
||||
// MyComponent definition should be:
|
||||
const MyComponentDefinition = `
|
||||
MyComponent.ngComponentDef = $r3$.ɵɵdefineComponent({
|
||||
MyComponent.ngComponentDef = $r3$.ΔdefineComponent({
|
||||
type: MyComponent,
|
||||
selectors: [["my-component"]],
|
||||
factory: function MyComponent_Factory(t) { return new (t || MyComponent)(); },
|
||||
|
@ -92,7 +92,7 @@ describe('compiler compliance: directives', () => {
|
|||
vars: 0,
|
||||
template: function MyComponent_Template(rf, ctx) {
|
||||
if (rf & 1) {
|
||||
$r3$.ɵɵelement(0, "div");
|
||||
$r3$.Δelement(0, "div");
|
||||
}
|
||||
},
|
||||
encapsulation: 2
|
||||
|
@ -132,15 +132,15 @@ describe('compiler compliance: directives', () => {
|
|||
…
|
||||
const _c0 = [${AttributeMarker.Bindings}, "someDirective"];
|
||||
…
|
||||
MyComponent.ngComponentDef = $r3$.ɵɵdefineComponent({
|
||||
MyComponent.ngComponentDef = $r3$.ΔdefineComponent({
|
||||
…
|
||||
template: function MyComponent_Template(rf, ctx) {
|
||||
if (rf & 1) {
|
||||
$r3$.ɵɵelement(0, "div", _c0);
|
||||
$r3$.Δelement(0, "div", _c0);
|
||||
}
|
||||
if (rf & 2) {
|
||||
$r3$.ɵɵselect(0);
|
||||
$r3$.ɵɵproperty("someDirective", true);
|
||||
$r3$.Δselect(0);
|
||||
$r3$.Δproperty("someDirective", true);
|
||||
}
|
||||
},
|
||||
…
|
||||
|
@ -187,15 +187,15 @@ describe('compiler compliance: directives', () => {
|
|||
const $_c0$ = ["directiveA", ""];
|
||||
function MyComponent_ng_template_0_Template(rf, ctx) {
|
||||
if (rf & 1) {
|
||||
$r3$.ɵɵtext(0, "Some content");
|
||||
$r3$.Δtext(0, "Some content");
|
||||
}
|
||||
}
|
||||
…
|
||||
MyComponent.ngComponentDef = $r3$.ɵɵdefineComponent({
|
||||
MyComponent.ngComponentDef = $r3$.ΔdefineComponent({
|
||||
…
|
||||
template: function MyComponent_Template(rf, ctx) {
|
||||
if (rf & 1) {
|
||||
$r3$.ɵɵtemplate(0, MyComponent_ng_template_0_Template, 1, 0, "ng-template", $_c0$);
|
||||
$r3$.Δtemplate(0, MyComponent_ng_template_0_Template, 1, 0, "ng-template", $_c0$);
|
||||
}
|
||||
},
|
||||
…
|
||||
|
@ -241,21 +241,21 @@ describe('compiler compliance: directives', () => {
|
|||
const $_c1$ = ["directiveA", ""];
|
||||
function MyComponent_ng_container_0_Template(rf, ctx) {
|
||||
if (rf & 1) {
|
||||
$r3$.ɵɵelementContainerStart(0, $_c1$);
|
||||
$r3$.ɵɵtext(1, "Some content");
|
||||
$r3$.ɵɵelementContainerEnd();
|
||||
$r3$.ΔelementContainerStart(0, $_c1$);
|
||||
$r3$.Δtext(1, "Some content");
|
||||
$r3$.ΔelementContainerEnd();
|
||||
}
|
||||
}
|
||||
…
|
||||
MyComponent.ngComponentDef = $r3$.ɵɵdefineComponent({
|
||||
MyComponent.ngComponentDef = $r3$.ΔdefineComponent({
|
||||
…
|
||||
template: function MyComponent_Template(rf, ctx) {
|
||||
if (rf & 1) {
|
||||
$r3$.ɵɵtemplate(0, MyComponent_ng_container_0_Template, 2, 0, "ng-container", $_c0$);
|
||||
$r3$.Δtemplate(0, MyComponent_ng_container_0_Template, 2, 0, "ng-container", $_c0$);
|
||||
}
|
||||
if (rf & 2) {
|
||||
$r3$.ɵɵselect(0);
|
||||
$r3$.ɵɵproperty("ngIf", ctx.showing);
|
||||
$r3$.Δselect(0);
|
||||
$r3$.Δproperty("ngIf", ctx.showing);
|
||||
}
|
||||
},
|
||||
…
|
||||
|
@ -295,15 +295,15 @@ describe('compiler compliance: directives', () => {
|
|||
…
|
||||
const $c0_a0$ = [${AttributeMarker.Bindings}, "someDirective"];
|
||||
…
|
||||
MyComponent.ngComponentDef = $r3$.ɵɵdefineComponent({
|
||||
MyComponent.ngComponentDef = $r3$.ΔdefineComponent({
|
||||
…
|
||||
template: function MyComponent_Template(rf, ctx) {
|
||||
if (rf & 1) {
|
||||
$r3$.ɵɵtemplate(0, MyComponent_ng_template_0_Template, 0, 0, "ng-template", $c0_a0$);
|
||||
$r3$.Δtemplate(0, MyComponent_ng_template_0_Template, 0, 0, "ng-template", $c0_a0$);
|
||||
}
|
||||
if (rf & 2) {
|
||||
$r3$.ɵɵselect(0);
|
||||
$r3$.ɵɵproperty("someDirective", true);
|
||||
$r3$.Δselect(0);
|
||||
$r3$.Δproperty("someDirective", true);
|
||||
}
|
||||
},
|
||||
…
|
||||
|
@ -344,11 +344,11 @@ describe('compiler compliance: directives', () => {
|
|||
…
|
||||
const $c0_a0$ = [${AttributeMarker.Template}, "someDirective"];
|
||||
…
|
||||
MyComponent.ngComponentDef = $r3$.ɵɵdefineComponent({
|
||||
MyComponent.ngComponentDef = $r3$.ΔdefineComponent({
|
||||
…
|
||||
template: function MyComponent_Template(rf, ctx) {
|
||||
if (rf & 1) {
|
||||
$r3$.ɵɵtemplate(0, MyComponent_div_0_Template, 1, 0, "div", $c0_a0$);
|
||||
$r3$.Δtemplate(0, MyComponent_div_0_Template, 1, 0, "div", $c0_a0$);
|
||||
}
|
||||
},
|
||||
…
|
||||
|
@ -393,13 +393,13 @@ describe('compiler compliance: directives', () => {
|
|||
…
|
||||
const $c0_a0$ = [${AttributeMarker.Bindings}, "someDirective"];
|
||||
…
|
||||
MyComponent.ngComponentDef = $r3$.ɵɵdefineComponent({
|
||||
MyComponent.ngComponentDef = $r3$.ΔdefineComponent({
|
||||
…
|
||||
template: function MyComponent_Template(rf, ctx) {
|
||||
if (rf & 1) {
|
||||
$r3$.ɵɵelementStart(0, "div", $c0_a0$);
|
||||
$r3$.ɵɵlistener("someDirective", function MyComponent_Template_div_someDirective_0_listener($event) { return ctx.noop(); });
|
||||
$r3$.ɵɵelementEnd();
|
||||
$r3$.ΔelementStart(0, "div", $c0_a0$);
|
||||
$r3$.Δlistener("someDirective", function MyComponent_Template_div_someDirective_0_listener($event) { return ctx.noop(); });
|
||||
$r3$.ΔelementEnd();
|
||||
}
|
||||
},
|
||||
…
|
||||
|
|
File diff suppressed because it is too large
Load Diff
|
@ -52,7 +52,7 @@ describe('compiler compliance: listen()', () => {
|
|||
};
|
||||
|
||||
const componentDef = `
|
||||
MyComponent.ngComponentDef = IDENT.ɵɵdefineComponent({
|
||||
MyComponent.ngComponentDef = IDENT.ΔdefineComponent({
|
||||
…
|
||||
inputs:{
|
||||
componentInput: "componentInput",
|
||||
|
@ -66,7 +66,7 @@ describe('compiler compliance: listen()', () => {
|
|||
});`;
|
||||
|
||||
const directiveDef = `
|
||||
MyDirective.ngDirectiveDef = IDENT.ɵɵdefineDirective({
|
||||
MyDirective.ngDirectiveDef = IDENT.ΔdefineDirective({
|
||||
…
|
||||
inputs:{
|
||||
directiveInput: "directiveInput",
|
||||
|
|
|
@ -45,12 +45,12 @@ describe('compiler compliance: listen()', () => {
|
|||
…
|
||||
template: function MyComponent_Template(rf, ctx) {
|
||||
if (rf & 1) {
|
||||
$r3$.ɵɵelementStart(0, "div", $e0_attrs$);
|
||||
$r3$.ɵɵlistener("click", function MyComponent_Template_div_click_0_listener($event) {
|
||||
$r3$.ΔelementStart(0, "div", $e0_attrs$);
|
||||
$r3$.Δlistener("click", function MyComponent_Template_div_click_0_listener($event) {
|
||||
ctx.onClick($event);
|
||||
return (1 == 2);
|
||||
});
|
||||
$r3$.ɵɵelementEnd();
|
||||
$r3$.ΔelementEnd();
|
||||
}
|
||||
}
|
||||
`;
|
||||
|
@ -91,11 +91,11 @@ describe('compiler compliance: listen()', () => {
|
|||
…
|
||||
template: function MyComponent_Template(rf, ctx) {
|
||||
if (rf & 1) {
|
||||
$r3$.ɵɵelementStart(0, "my-app", $e0_attrs$);
|
||||
$r3$.ɵɵlistener("click", function MyComponent_Template_my_app_click_0_listener($event) {
|
||||
$r3$.ΔelementStart(0, "my-app", $e0_attrs$);
|
||||
$r3$.Δlistener("click", function MyComponent_Template_my_app_click_0_listener($event) {
|
||||
return ctx.onClick($event);
|
||||
});
|
||||
$r3$.ɵɵelementEnd();
|
||||
$r3$.ΔelementEnd();
|
||||
}
|
||||
}
|
||||
`;
|
||||
|
@ -138,33 +138,33 @@ describe('compiler compliance: listen()', () => {
|
|||
|
||||
function MyComponent_div_0_Template(rf, ctx) {
|
||||
if (rf & 1) {
|
||||
const $s$ = $r3$.ɵɵgetCurrentView();
|
||||
$r3$.ɵɵelementStart(0, "div");
|
||||
$r3$.ɵɵelementStart(1, "div", $e_attrs$);
|
||||
$r3$.ɵɵlistener("click", function MyComponent_div_0_Template_div_click_1_listener($event) {
|
||||
$r3$.ɵɵrestoreView($s$);
|
||||
const $comp$ = $r3$.ɵɵnextContext();
|
||||
const $s$ = $r3$.ΔgetCurrentView();
|
||||
$r3$.ΔelementStart(0, "div");
|
||||
$r3$.ΔelementStart(1, "div", $e_attrs$);
|
||||
$r3$.Δlistener("click", function MyComponent_div_0_Template_div_click_1_listener($event) {
|
||||
$r3$.ΔrestoreView($s$);
|
||||
const $comp$ = $r3$.ΔnextContext();
|
||||
return $comp$.onClick($comp$.foo);
|
||||
});
|
||||
$r3$.ɵɵelementEnd();
|
||||
$r3$.ɵɵelementStart(2, "button", $e_attrs$);
|
||||
$r3$.ɵɵlistener("click", function MyComponent_div_0_Template_button_click_2_listener($event) {
|
||||
$r3$.ɵɵrestoreView($s$);
|
||||
const $comp2$ = $r3$.ɵɵnextContext();
|
||||
$r3$.ΔelementEnd();
|
||||
$r3$.ΔelementStart(2, "button", $e_attrs$);
|
||||
$r3$.Δlistener("click", function MyComponent_div_0_Template_button_click_2_listener($event) {
|
||||
$r3$.ΔrestoreView($s$);
|
||||
const $comp2$ = $r3$.ΔnextContext();
|
||||
return $comp2$.onClick2($comp2$.bar);
|
||||
});
|
||||
$r3$.ɵɵelementEnd();
|
||||
$r3$.ɵɵelementEnd();
|
||||
$r3$.ΔelementEnd();
|
||||
$r3$.ΔelementEnd();
|
||||
}
|
||||
}
|
||||
// ...
|
||||
template: function MyComponent_Template(rf, ctx) {
|
||||
if (rf & 1) {
|
||||
$r3$.ɵɵtemplate(0, MyComponent_div_0_Template, 3, 0, "div", $c0$);
|
||||
$r3$.Δtemplate(0, MyComponent_div_0_Template, 3, 0, "div", $c0$);
|
||||
}
|
||||
if (rf & 2) {
|
||||
$i0$.ɵɵselect(0);
|
||||
$i0$.ɵɵproperty("ngIf", ctx.showing);
|
||||
$i0$.Δselect(0);
|
||||
$i0$.Δproperty("ngIf", ctx.showing);
|
||||
}
|
||||
}
|
||||
`;
|
||||
|
@ -199,7 +199,7 @@ describe('compiler compliance: listen()', () => {
|
|||
const $e0_attrs$ = [${AttributeMarker.Bindings}, "click"];
|
||||
const $e2_refs$ = ["user", ""];
|
||||
…
|
||||
MyComponent.ngComponentDef = $r3$.ɵɵdefineComponent({
|
||||
MyComponent.ngComponentDef = $r3$.ΔdefineComponent({
|
||||
type: MyComponent,
|
||||
selectors: [["my-component"]],
|
||||
factory: function MyComponent_Factory(t) { return new (t || MyComponent)(); },
|
||||
|
@ -207,16 +207,16 @@ describe('compiler compliance: listen()', () => {
|
|||
vars: 0,
|
||||
template: function MyComponent_Template(rf, ctx) {
|
||||
if (rf & 1) {
|
||||
const $s$ = $r3$.ɵɵgetCurrentView();
|
||||
$r3$.ɵɵelementStart(0, "button", $e0_attrs$);
|
||||
$r3$.ɵɵlistener("click", function MyComponent_Template_button_click_0_listener($event) {
|
||||
$r3$.ɵɵrestoreView($s$);
|
||||
const $user$ = $r3$.ɵɵreference(3);
|
||||
const $s$ = $r3$.ΔgetCurrentView();
|
||||
$r3$.ΔelementStart(0, "button", $e0_attrs$);
|
||||
$r3$.Δlistener("click", function MyComponent_Template_button_click_0_listener($event) {
|
||||
$r3$.ΔrestoreView($s$);
|
||||
const $user$ = $r3$.Δreference(3);
|
||||
return ctx.onClick($user$.value);
|
||||
});
|
||||
$r3$.ɵɵtext(1, "Save");
|
||||
$r3$.ɵɵelementEnd();
|
||||
$r3$.ɵɵelement(2, "input", null, $e2_refs$);
|
||||
$r3$.Δtext(1, "Save");
|
||||
$r3$.ΔelementEnd();
|
||||
$r3$.Δelement(2, "input", null, $e2_refs$);
|
||||
}
|
||||
},
|
||||
encapsulation: 2
|
||||
|
|
|
@ -46,7 +46,7 @@ describe('compiler compliance: providers', () => {
|
|||
const result = compile(files, angularFiles);
|
||||
expectEmit(
|
||||
result.source,
|
||||
'features: [i0.ɵɵProvidersFeature([GreeterEN, {provide: Greeter, useClass: GreeterEN}], [GreeterEN])],',
|
||||
'features: [i0.ΔProvidersFeature([GreeterEN, {provide: Greeter, useClass: GreeterEN}], [GreeterEN])],',
|
||||
'Incorrect features');
|
||||
});
|
||||
|
||||
|
@ -79,7 +79,7 @@ describe('compiler compliance: providers', () => {
|
|||
const result = compile(files, angularFiles);
|
||||
expectEmit(
|
||||
result.source,
|
||||
'features: [i0.ɵɵProvidersFeature([GreeterEN, {provide: Greeter, useClass: GreeterEN}])],',
|
||||
'features: [i0.ΔProvidersFeature([GreeterEN, {provide: Greeter, useClass: GreeterEN}])],',
|
||||
'Incorrect features');
|
||||
});
|
||||
|
||||
|
@ -111,7 +111,7 @@ describe('compiler compliance: providers', () => {
|
|||
|
||||
const result = compile(files, angularFiles);
|
||||
expectEmit(
|
||||
result.source, 'features: [i0.ɵɵProvidersFeature([], [GreeterEN])],', 'Incorrect features');
|
||||
result.source, 'features: [i0.ΔProvidersFeature([], [GreeterEN])],', 'Incorrect features');
|
||||
});
|
||||
|
||||
it('should not emit the ProvidersFeature feature when no providers', () => {
|
||||
|
|
|
@ -113,7 +113,7 @@ describe('r3_view_compiler', () => {
|
|||
};
|
||||
|
||||
const bV_call =
|
||||
`$r3$.ɵɵinterpolationV([" ",ctx.list[0]," ",ctx.list[1]," ",ctx.list[2]," ",ctx.list[3],
|
||||
`$r3$.ΔinterpolationV([" ",ctx.list[0]," ",ctx.list[1]," ",ctx.list[2]," ",ctx.list[3],
|
||||
" ",ctx.list[4]," ",ctx.list[5]," ",ctx.list[6]," ",ctx.list[7]," ",ctx.list[8],
|
||||
" "])`;
|
||||
const result = compile(files, angularFiles);
|
||||
|
@ -143,12 +143,12 @@ describe('r3_view_compiler', () => {
|
|||
const template = `
|
||||
template: function MyApp_Template(rf, ctx) {
|
||||
if (rf & 1) {
|
||||
$i0$.ɵɵelement(0, "div");
|
||||
$i0$.Δelement(0, "div");
|
||||
}
|
||||
if (rf & 2) {
|
||||
$i0$.ɵɵselect(0);
|
||||
$i0$.ɵɵproperty("@attr", …);
|
||||
$i0$.ɵɵproperty("@binding", …);
|
||||
$i0$.Δselect(0);
|
||||
$i0$.Δproperty("@attr", …);
|
||||
$i0$.Δproperty("@binding", …);
|
||||
}
|
||||
}`;
|
||||
const result = compile(files, angularFiles);
|
||||
|
@ -176,10 +176,10 @@ describe('r3_view_compiler', () => {
|
|||
const template = `
|
||||
template: function MyApp_Template(rf, ctx) {
|
||||
if (rf & 1) {
|
||||
$i0$.ɵɵelementStart(0, "div");
|
||||
$i0$.ΔelementStart(0, "div");
|
||||
…
|
||||
$i0$.ɵɵselect(0);
|
||||
$i0$.ɵɵproperty("@mySelector", …);
|
||||
$i0$.Δselect(0);
|
||||
$i0$.Δproperty("@mySelector", …);
|
||||
}
|
||||
}`;
|
||||
const result = compile(files, angularFiles);
|
||||
|
|
|
@ -95,7 +95,7 @@ describe('compiler compliance: styling', () => {
|
|||
};
|
||||
|
||||
const template = `
|
||||
MyComponent.ngComponentDef = $r3$.ɵɵdefineComponent({
|
||||
MyComponent.ngComponentDef = $r3$.ΔdefineComponent({
|
||||
…
|
||||
styles: ["div.cool { color: blue; }", ":host.nice p { color: gold; }"],
|
||||
encapsulation: 1
|
||||
|
@ -128,7 +128,7 @@ describe('compiler compliance: styling', () => {
|
|||
};
|
||||
|
||||
const template = `
|
||||
MyComponent.ngComponentDef = $r3$.ɵɵdefineComponent({
|
||||
MyComponent.ngComponentDef = $r3$.ΔdefineComponent({
|
||||
type: MyComponent,
|
||||
selectors:[["my-component"]],
|
||||
factory:function MyComponent_Factory(t){
|
||||
|
@ -170,7 +170,7 @@ describe('compiler compliance: styling', () => {
|
|||
};
|
||||
|
||||
const template = `
|
||||
MyComponent.ngComponentDef = $r3$.ɵɵdefineComponent({
|
||||
MyComponent.ngComponentDef = $r3$.ΔdefineComponent({
|
||||
type: MyComponent,
|
||||
selectors:[["my-component"]],
|
||||
factory:function MyComponent_Factory(t){
|
||||
|
@ -215,23 +215,23 @@ describe('compiler compliance: styling', () => {
|
|||
|
||||
const template = `
|
||||
…
|
||||
MyComponent.ngComponentDef = $r3$.ɵɵdefineComponent({
|
||||
MyComponent.ngComponentDef = $r3$.ΔdefineComponent({
|
||||
…
|
||||
consts: 3,
|
||||
vars: 3,
|
||||
template: function MyComponent_Template(rf, $ctx$) {
|
||||
if (rf & 1) {
|
||||
$r3$.ɵɵelement(0, "div");
|
||||
$r3$.ɵɵelement(1, "div");
|
||||
$r3$.ɵɵelement(2, "div");
|
||||
$r3$.Δelement(0, "div");
|
||||
$r3$.Δelement(1, "div");
|
||||
$r3$.Δelement(2, "div");
|
||||
}
|
||||
if (rf & 2) {
|
||||
$r3$.ɵɵselect(0);
|
||||
$r3$.ɵɵproperty("@foo", ctx.exp);
|
||||
$r3$.ɵɵselect(1);
|
||||
$r3$.ɵɵproperty("@bar", undefined);
|
||||
$r3$.ɵɵselect(2);
|
||||
$r3$.ɵɵproperty("@baz", undefined);
|
||||
$r3$.Δselect(0);
|
||||
$r3$.Δproperty("@foo", ctx.exp);
|
||||
$r3$.Δselect(1);
|
||||
$r3$.Δproperty("@bar", undefined);
|
||||
$r3$.Δselect(2);
|
||||
$r3$.Δproperty("@baz", undefined);
|
||||
}
|
||||
},
|
||||
encapsulation: 2
|
||||
|
@ -277,19 +277,19 @@ describe('compiler compliance: styling', () => {
|
|||
|
||||
const template = `
|
||||
…
|
||||
MyComponent.ngComponentDef = $r3$.ɵɵdefineComponent({
|
||||
MyComponent.ngComponentDef = $r3$.ΔdefineComponent({
|
||||
…
|
||||
consts: 1,
|
||||
vars: 1,
|
||||
template: function MyComponent_Template(rf, ctx) {
|
||||
if (rf & 1) {
|
||||
$r3$.ɵɵelementStart(0, "div");
|
||||
$r3$.ɵɵlistener("@myAnimation.start", function MyComponent_Template_div_animation_myAnimation_start_0_listener($event) { return ctx.onStart($event); });
|
||||
$r3$.ɵɵlistener("@myAnimation.done", function MyComponent_Template_div_animation_myAnimation_done_0_listener($event) { return ctx.onDone($event); });
|
||||
$r3$.ɵɵelementEnd();
|
||||
$r3$.ΔelementStart(0, "div");
|
||||
$r3$.Δlistener("@myAnimation.start", function MyComponent_Template_div_animation_myAnimation_start_0_listener($event) { return ctx.onStart($event); });
|
||||
$r3$.Δlistener("@myAnimation.done", function MyComponent_Template_div_animation_myAnimation_done_0_listener($event) { return ctx.onDone($event); });
|
||||
$r3$.ΔelementEnd();
|
||||
} if (rf & 2) {
|
||||
$r3$.ɵɵselect(0);
|
||||
$r3$.ɵɵproperty("@myAnimation", ctx.exp);
|
||||
$r3$.Δselect(0);
|
||||
$r3$.Δproperty("@myAnimation", ctx.exp);
|
||||
}
|
||||
},
|
||||
encapsulation: 2,
|
||||
|
@ -340,15 +340,15 @@ describe('compiler compliance: styling', () => {
|
|||
};
|
||||
|
||||
const template = `
|
||||
MyAnimDir.ngDirectiveDef = $r3$.ɵɵdefineDirective({
|
||||
MyAnimDir.ngDirectiveDef = $r3$.ΔdefineDirective({
|
||||
…
|
||||
hostBindings: function MyAnimDir_HostBindings(rf, ctx, elIndex) {
|
||||
if (rf & 1) {
|
||||
$r3$.ɵɵallocHostVars(1);
|
||||
$r3$.ɵɵcomponentHostSyntheticListener("@myAnim.start", function MyAnimDir_animation_myAnim_start_HostBindingHandler($event) { return ctx.onStart(); });
|
||||
$r3$.ɵɵcomponentHostSyntheticListener("@myAnim.done", function MyAnimDir_animation_myAnim_done_HostBindingHandler($event) { return ctx.onDone(); });
|
||||
$r3$.ΔallocHostVars(1);
|
||||
$r3$.ΔcomponentHostSyntheticListener("@myAnim.start", function MyAnimDir_animation_myAnim_start_HostBindingHandler($event) { return ctx.onStart(); });
|
||||
$r3$.ΔcomponentHostSyntheticListener("@myAnim.done", function MyAnimDir_animation_myAnim_done_HostBindingHandler($event) { return ctx.onDone(); });
|
||||
} if (rf & 2) {
|
||||
$r3$.ɵɵcomponentHostSyntheticProperty(elIndex, "@myAnim", $r3$.ɵɵbind(ctx.myAnimState), null, true);
|
||||
$r3$.ΔcomponentHostSyntheticProperty(elIndex, "@myAnim", $r3$.Δbind(ctx.myAnimState), null, true);
|
||||
}
|
||||
}
|
||||
…
|
||||
|
@ -384,14 +384,14 @@ describe('compiler compliance: styling', () => {
|
|||
const template = `
|
||||
template: function MyComponent_Template(rf, $ctx$) {
|
||||
if (rf & 1) {
|
||||
$r3$.ɵɵelementStart(0, "div");
|
||||
$r3$.ɵɵstyling(null, null, $r3$.ɵɵdefaultStyleSanitizer);
|
||||
$r3$.ɵɵelementEnd();
|
||||
$r3$.ΔelementStart(0, "div");
|
||||
$r3$.Δstyling(null, null, $r3$.ΔdefaultStyleSanitizer);
|
||||
$r3$.ΔelementEnd();
|
||||
}
|
||||
if (rf & 2) {
|
||||
$r3$.ɵɵselect(0);
|
||||
$r3$.ɵɵstyleMap($ctx$.myStyleExp);
|
||||
$r3$.ɵɵstylingApply();
|
||||
$r3$.Δselect(0);
|
||||
$r3$.ΔstyleMap($ctx$.myStyleExp);
|
||||
$r3$.ΔstylingApply();
|
||||
}
|
||||
}
|
||||
`;
|
||||
|
@ -450,14 +450,14 @@ describe('compiler compliance: styling', () => {
|
|||
vars: 1,
|
||||
template: function MyComponentWithInterpolation_Template(rf, $ctx$) {
|
||||
if (rf & 1) {
|
||||
$r3$.ɵɵelementStart(0, "div");
|
||||
$r3$.ɵɵstyling();
|
||||
$r3$.ɵɵelementEnd();
|
||||
$r3$.ΔelementStart(0, "div");
|
||||
$r3$.Δstyling();
|
||||
$r3$.ΔelementEnd();
|
||||
}
|
||||
if (rf & 2) {
|
||||
$r3$.ɵɵselect(0);
|
||||
$r3$.ɵɵclassMap($r3$.ɵɵinterpolation1("foo foo-", $ctx$.fooId, ""));
|
||||
$r3$.ɵɵstylingApply();
|
||||
$r3$.Δselect(0);
|
||||
$r3$.ΔclassMap($r3$.Δinterpolation1("foo foo-", $ctx$.fooId, ""));
|
||||
$r3$.ΔstylingApply();
|
||||
}
|
||||
}
|
||||
…
|
||||
|
@ -465,14 +465,14 @@ describe('compiler compliance: styling', () => {
|
|||
vars: 2,
|
||||
template: function MyComponentWithMuchosInterpolation_Template(rf, $ctx$) {
|
||||
if (rf & 1) {
|
||||
$r3$.ɵɵelementStart(0, "div");
|
||||
$r3$.ɵɵstyling();
|
||||
$r3$.ɵɵelementEnd();
|
||||
$r3$.ΔelementStart(0, "div");
|
||||
$r3$.Δstyling();
|
||||
$r3$.ΔelementEnd();
|
||||
}
|
||||
if (rf & 2) {
|
||||
$r3$.ɵɵselect(0);
|
||||
$r3$.ɵɵclassMap($r3$.ɵɵinterpolation2("foo foo-", $ctx$.fooId, "-", $ctx$.fooUsername, ""));
|
||||
$r3$.ɵɵstylingApply();
|
||||
$r3$.Δselect(0);
|
||||
$r3$.ΔclassMap($r3$.Δinterpolation2("foo foo-", $ctx$.fooId, "-", $ctx$.fooUsername, ""));
|
||||
$r3$.ΔstylingApply();
|
||||
}
|
||||
}
|
||||
…
|
||||
|
@ -480,14 +480,14 @@ describe('compiler compliance: styling', () => {
|
|||
vars: 0,
|
||||
template: function MyComponentWithoutInterpolation_Template(rf, $ctx$) {
|
||||
if (rf & 1) {
|
||||
$r3$.ɵɵelementStart(0, "div");
|
||||
$r3$.ɵɵstyling();
|
||||
$r3$.ɵɵelementEnd();
|
||||
$r3$.ΔelementStart(0, "div");
|
||||
$r3$.Δstyling();
|
||||
$r3$.ΔelementEnd();
|
||||
}
|
||||
if (rf & 2) {
|
||||
$r3$.ɵɵselect(0);
|
||||
$r3$.ɵɵclassMap($ctx$.exp);
|
||||
$r3$.ɵɵstylingApply();
|
||||
$r3$.Δselect(0);
|
||||
$r3$.ΔclassMap($ctx$.exp);
|
||||
$r3$.ΔstylingApply();
|
||||
}
|
||||
}
|
||||
`;
|
||||
|
@ -527,7 +527,7 @@ describe('compiler compliance: styling', () => {
|
|||
const $_c0$ = [${AttributeMarker.Styles}, "opacity", "1", ${AttributeMarker.Bindings}, "style"];
|
||||
const $_c1$ = ["width", "height"];
|
||||
…
|
||||
MyComponent.ngComponentDef = $r3$.ɵɵdefineComponent({
|
||||
MyComponent.ngComponentDef = $r3$.ΔdefineComponent({
|
||||
type: MyComponent,
|
||||
selectors:[["my-component"]],
|
||||
factory:function MyComponent_Factory(t){
|
||||
|
@ -537,17 +537,17 @@ describe('compiler compliance: styling', () => {
|
|||
vars: 1,
|
||||
template: function MyComponent_Template(rf, $ctx$) {
|
||||
if (rf & 1) {
|
||||
$r3$.ɵɵelementStart(0, "div", $_c0$);
|
||||
$r3$.ɵɵstyling(null, $_c1$, $r3$.ɵɵdefaultStyleSanitizer);
|
||||
$r3$.ɵɵelementEnd();
|
||||
$r3$.ΔelementStart(0, "div", $_c0$);
|
||||
$r3$.Δstyling(null, $_c1$, $r3$.ΔdefaultStyleSanitizer);
|
||||
$r3$.ΔelementEnd();
|
||||
}
|
||||
if (rf & 2) {
|
||||
$r3$.ɵɵselect(0);
|
||||
$r3$.ɵɵstyleMap($ctx$.myStyleExp);
|
||||
$r3$.ɵɵstyleProp(0, $ctx$.myWidth);
|
||||
$r3$.ɵɵstyleProp(1, $ctx$.myHeight);
|
||||
$r3$.ɵɵstylingApply();
|
||||
$r3$.ɵɵelementAttribute(0, "style", $r3$.ɵɵbind("border-width: 10px"), $r3$.ɵɵsanitizeStyle);
|
||||
$r3$.Δselect(0);
|
||||
$r3$.ΔstyleMap($ctx$.myStyleExp);
|
||||
$r3$.ΔstyleProp(0, $ctx$.myWidth);
|
||||
$r3$.ΔstyleProp(1, $ctx$.myHeight);
|
||||
$r3$.ΔstylingApply();
|
||||
$r3$.ΔelementAttribute(0, "style", $r3$.Δbind("border-width: 10px"), $r3$.ΔsanitizeStyle);
|
||||
}
|
||||
},
|
||||
encapsulation: 2
|
||||
|
@ -587,7 +587,7 @@ describe('compiler compliance: styling', () => {
|
|||
}
|
||||
}
|
||||
|
||||
MyComponent.ngComponentDef = $r3$.ɵɵdefineComponent({
|
||||
MyComponent.ngComponentDef = $r3$.ΔdefineComponent({
|
||||
type: MyComponent,
|
||||
selectors: [["my-component"]],
|
||||
factory: function MyComponent_Factory(t) {
|
||||
|
@ -597,14 +597,14 @@ describe('compiler compliance: styling', () => {
|
|||
vars: 0,
|
||||
template: function MyComponent_Template(rf, ctx) {
|
||||
if (rf & 1) {
|
||||
$r3$.ɵɵelementStart(0, "div");
|
||||
$r3$.ɵɵstyling(null, _c0, $r3$.ɵɵdefaultStyleSanitizer);
|
||||
$r3$.ɵɵelementEnd();
|
||||
$r3$.ΔelementStart(0, "div");
|
||||
$r3$.Δstyling(null, _c0, $r3$.ΔdefaultStyleSanitizer);
|
||||
$r3$.ΔelementEnd();
|
||||
}
|
||||
if (rf & 2) {
|
||||
$r3$.ɵɵselect(0);
|
||||
$r3$.ɵɵstyleProp(0, ctx.myImage);
|
||||
$r3$.ɵɵstylingApply();
|
||||
$r3$.Δselect(0);
|
||||
$r3$.ΔstyleProp(0, ctx.myImage);
|
||||
$r3$.ΔstylingApply();
|
||||
}
|
||||
},
|
||||
encapsulation: 2
|
||||
|
@ -639,14 +639,14 @@ describe('compiler compliance: styling', () => {
|
|||
…
|
||||
template: function MyComponent_Template(rf, ctx) {
|
||||
if (rf & 1) {
|
||||
$r3$.ɵɵelementStart(0, "div");
|
||||
$r3$.ɵɵstyling(null, _c0);
|
||||
$r3$.ɵɵelementEnd();
|
||||
$r3$.ΔelementStart(0, "div");
|
||||
$r3$.Δstyling(null, _c0);
|
||||
$r3$.ΔelementEnd();
|
||||
}
|
||||
if (rf & 2) {
|
||||
$r3$.ɵɵselect(0);
|
||||
$r3$.ɵɵstyleProp(0, 12, "px");
|
||||
$r3$.ɵɵstylingApply();
|
||||
$r3$.Δselect(0);
|
||||
$r3$.ΔstyleProp(0, 12, "px");
|
||||
$r3$.ΔstylingApply();
|
||||
}
|
||||
}
|
||||
`;
|
||||
|
@ -705,14 +705,14 @@ describe('compiler compliance: styling', () => {
|
|||
const template = `
|
||||
template: function MyComponent_Template(rf, $ctx$) {
|
||||
if (rf & 1) {
|
||||
$r3$.ɵɵelementStart(0, "div");
|
||||
$r3$.ɵɵstyling();
|
||||
$r3$.ɵɵelementEnd();
|
||||
$r3$.ΔelementStart(0, "div");
|
||||
$r3$.Δstyling();
|
||||
$r3$.ΔelementEnd();
|
||||
}
|
||||
if (rf & 2) {
|
||||
$r3$.ɵɵselect(0);
|
||||
$r3$.ɵɵclassMap($ctx$.myClassExp);
|
||||
$r3$.ɵɵstylingApply();
|
||||
$r3$.Δselect(0);
|
||||
$r3$.ΔclassMap($ctx$.myClassExp);
|
||||
$r3$.ΔstylingApply();
|
||||
}
|
||||
}
|
||||
`;
|
||||
|
@ -752,7 +752,7 @@ describe('compiler compliance: styling', () => {
|
|||
const $e0_attrs$ = [${AttributeMarker.Classes}, "grape", ${AttributeMarker.Bindings}, "class"];
|
||||
const $e0_bindings$ = ["apple", "orange"];
|
||||
…
|
||||
MyComponent.ngComponentDef = $r3$.ɵɵdefineComponent({
|
||||
MyComponent.ngComponentDef = $r3$.ΔdefineComponent({
|
||||
type: MyComponent,
|
||||
selectors:[["my-component"]],
|
||||
factory:function MyComponent_Factory(t){
|
||||
|
@ -762,17 +762,17 @@ describe('compiler compliance: styling', () => {
|
|||
vars: 1,
|
||||
template: function MyComponent_Template(rf, $ctx$) {
|
||||
if (rf & 1) {
|
||||
$r3$.ɵɵelementStart(0, "div", $e0_attrs$);
|
||||
$r3$.ɵɵstyling($e0_bindings$);
|
||||
$r3$.ɵɵelementEnd();
|
||||
$r3$.ΔelementStart(0, "div", $e0_attrs$);
|
||||
$r3$.Δstyling($e0_bindings$);
|
||||
$r3$.ΔelementEnd();
|
||||
}
|
||||
if (rf & 2) {
|
||||
$r3$.ɵɵselect(0);
|
||||
$r3$.ɵɵclassMap($ctx$.myClassExp);
|
||||
$r3$.ɵɵclassProp(0, $ctx$.yesToApple);
|
||||
$r3$.ɵɵclassProp(1, $ctx$.yesToOrange);
|
||||
$r3$.ɵɵstylingApply();
|
||||
$r3$.ɵɵelementAttribute(0, "class", $r3$.ɵɵbind("banana"));
|
||||
$r3$.Δselect(0);
|
||||
$r3$.ΔclassMap($ctx$.myClassExp);
|
||||
$r3$.ΔclassProp(0, $ctx$.yesToApple);
|
||||
$r3$.ΔclassProp(1, $ctx$.yesToOrange);
|
||||
$r3$.ΔstylingApply();
|
||||
$r3$.ΔelementAttribute(0, "class", $r3$.Δbind("banana"));
|
||||
}
|
||||
},
|
||||
encapsulation: 2
|
||||
|
@ -808,7 +808,7 @@ describe('compiler compliance: styling', () => {
|
|||
const template = `
|
||||
const $e0_attrs$ = [${AttributeMarker.Classes}, "foo", ${AttributeMarker.Styles}, "width", "100px", ${AttributeMarker.Bindings}, "class", "style"];
|
||||
…
|
||||
MyComponent.ngComponentDef = $r3$.ɵɵdefineComponent({
|
||||
MyComponent.ngComponentDef = $r3$.ΔdefineComponent({
|
||||
type: MyComponent,
|
||||
selectors:[["my-component"]],
|
||||
factory:function MyComponent_Factory(t){
|
||||
|
@ -818,12 +818,12 @@ describe('compiler compliance: styling', () => {
|
|||
vars: 2,
|
||||
template: function MyComponent_Template(rf, $ctx$) {
|
||||
if (rf & 1) {
|
||||
$r3$.ɵɵelement(0, "div", $e0_attrs$);
|
||||
$r3$.Δelement(0, "div", $e0_attrs$);
|
||||
}
|
||||
if (rf & 2) {
|
||||
$r3$.ɵɵselect(0);
|
||||
$r3$.ɵɵelementAttribute(0, "class", $r3$.ɵɵbind("round"));
|
||||
$r3$.ɵɵelementAttribute(0, "style", $r3$.ɵɵbind("height:100px"), $r3$.ɵɵsanitizeStyle);
|
||||
$r3$.Δselect(0);
|
||||
$r3$.ΔelementAttribute(0, "class", $r3$.Δbind("round"));
|
||||
$r3$.ΔelementAttribute(0, "style", $r3$.Δbind("height:100px"), $r3$.ΔsanitizeStyle);
|
||||
}
|
||||
},
|
||||
encapsulation: 2
|
||||
|
@ -884,15 +884,15 @@ describe('compiler compliance: styling', () => {
|
|||
const template = `
|
||||
template: function MyComponent_Template(rf, $ctx$) {
|
||||
if (rf & 1) {
|
||||
$r3$.ɵɵelementStart(0, "div");
|
||||
$r3$.ɵɵstyling(null, null, $r3$.ɵɵdefaultStyleSanitizer);
|
||||
$r3$.ɵɵelementEnd();
|
||||
$r3$.ΔelementStart(0, "div");
|
||||
$r3$.Δstyling(null, null, $r3$.ΔdefaultStyleSanitizer);
|
||||
$r3$.ΔelementEnd();
|
||||
}
|
||||
if (rf & 2) {
|
||||
$r3$.ɵɵselect(0);
|
||||
$r3$.ɵɵstyleMap($ctx$.myStyleExp);
|
||||
$r3$.ɵɵclassMap($ctx$.myClassExp);
|
||||
$r3$.ɵɵstylingApply();
|
||||
$r3$.Δselect(0);
|
||||
$r3$.ΔstyleMap($ctx$.myStyleExp);
|
||||
$r3$.ΔclassMap($ctx$.myClassExp);
|
||||
$r3$.ΔstylingApply();
|
||||
}
|
||||
}
|
||||
`;
|
||||
|
@ -926,17 +926,17 @@ describe('compiler compliance: styling', () => {
|
|||
const template = `
|
||||
template: function MyComponent_Template(rf, $ctx$) {
|
||||
if (rf & 1) {
|
||||
$r3$.ɵɵelementStart(0, "div");
|
||||
$r3$.ɵɵstyling(null, null, $r3$.ɵɵdefaultStyleSanitizer);
|
||||
$r3$.ɵɵpipe(1, "stylePipe");
|
||||
$r3$.ɵɵpipe(2, "classPipe");
|
||||
$r3$.ɵɵelementEnd();
|
||||
$r3$.ΔelementStart(0, "div");
|
||||
$r3$.Δstyling(null, null, $r3$.ΔdefaultStyleSanitizer);
|
||||
$r3$.Δpipe(1, "stylePipe");
|
||||
$r3$.Δpipe(2, "classPipe");
|
||||
$r3$.ΔelementEnd();
|
||||
}
|
||||
if (rf & 2) {
|
||||
$r3$.ɵɵselect(0);
|
||||
$r3$.ɵɵstyleMap($r3$.ɵɵpipeBind1(1, 0, $ctx$.myStyleExp));
|
||||
$r3$.ɵɵclassMap($r3$.ɵɵpipeBind1(2, 2, $ctx$.myClassExp));
|
||||
$r3$.ɵɵstylingApply();
|
||||
$r3$.Δselect(0);
|
||||
$r3$.ΔstyleMap($r3$.ΔpipeBind1(1, 0, $ctx$.myStyleExp));
|
||||
$r3$.ΔclassMap($r3$.ΔpipeBind1(2, 2, $ctx$.myClassExp));
|
||||
$r3$.ΔstylingApply();
|
||||
}
|
||||
}
|
||||
`;
|
||||
|
@ -981,25 +981,25 @@ describe('compiler compliance: styling', () => {
|
|||
…
|
||||
template: function MyComponent_Template(rf, $ctx$) {
|
||||
if (rf & 1) {
|
||||
$r3$.ɵɵelementStart(0, "div");
|
||||
$r3$.ɵɵstyling($e0_classBindings$, $e0_styleBindings$, $r3$.ɵɵdefaultStyleSanitizer);
|
||||
$r3$.ɵɵpipe(1, "pipe");
|
||||
$r3$.ɵɵpipe(2, "pipe");
|
||||
$r3$.ɵɵpipe(3, "pipe");
|
||||
$r3$.ɵɵpipe(4, "pipe");
|
||||
$r3$.ɵɵtext(5);
|
||||
$r3$.ɵɵelementEnd();
|
||||
$r3$.ΔelementStart(0, "div");
|
||||
$r3$.Δstyling($e0_classBindings$, $e0_styleBindings$, $r3$.ΔdefaultStyleSanitizer);
|
||||
$r3$.Δpipe(1, "pipe");
|
||||
$r3$.Δpipe(2, "pipe");
|
||||
$r3$.Δpipe(3, "pipe");
|
||||
$r3$.Δpipe(4, "pipe");
|
||||
$r3$.Δtext(5);
|
||||
$r3$.ΔelementEnd();
|
||||
}
|
||||
if (rf & 2) {
|
||||
$r3$.ɵɵselect(0);
|
||||
$r3$.ɵɵstyleMap($r3$.ɵɵpipeBind2(1, 1, $ctx$.myStyleExp, 1000));
|
||||
$r3$.ɵɵclassMap($e2_styling$);
|
||||
$r3$.ɵɵstyleProp(0, $r3$.ɵɵpipeBind2(2, 4, $ctx$.barExp, 3000));
|
||||
$r3$.ɵɵstyleProp(1, $r3$.ɵɵpipeBind2(3, 7, $ctx$.bazExp, 4000));
|
||||
$r3$.ɵɵclassProp(0, $r3$.ɵɵpipeBind2(4, 10, $ctx$.fooExp, 2000));
|
||||
$r3$.ɵɵstylingApply();
|
||||
$r3$.ɵɵselect(5);
|
||||
$r3$.ɵɵtextBinding(5, $r3$.ɵɵinterpolation1(" ", $ctx$.item, ""));
|
||||
$r3$.Δselect(0);
|
||||
$r3$.ΔstyleMap($r3$.ΔpipeBind2(1, 1, $ctx$.myStyleExp, 1000));
|
||||
$r3$.ΔclassMap($e2_styling$);
|
||||
$r3$.ΔstyleProp(0, $r3$.ΔpipeBind2(2, 4, $ctx$.barExp, 3000));
|
||||
$r3$.ΔstyleProp(1, $r3$.ΔpipeBind2(3, 7, $ctx$.bazExp, 4000));
|
||||
$r3$.ΔclassProp(0, $r3$.ΔpipeBind2(4, 10, $ctx$.fooExp, 2000));
|
||||
$r3$.ΔstylingApply();
|
||||
$r3$.Δselect(5);
|
||||
$r3$.ΔtextBinding(5, $r3$.Δinterpolation1(" ", $ctx$.item, ""));
|
||||
}
|
||||
}
|
||||
`;
|
||||
|
@ -1041,18 +1041,18 @@ describe('compiler compliance: styling', () => {
|
|||
template: function MyComponent_Template(rf, $ctx$) {
|
||||
…
|
||||
if (rf & 2) {
|
||||
$r3$.ɵɵselect(0);
|
||||
$r3$.ɵɵstyleProp(0, $ctx$.w1);
|
||||
$r3$.ɵɵstylingApply();
|
||||
$r3$.ɵɵselect(1);
|
||||
$r3$.ɵɵstyleProp(0, $ctx$.h1);
|
||||
$r3$.ɵɵstylingApply();
|
||||
$r3$.ɵɵselect(2);
|
||||
$r3$.ɵɵclassProp(0, $ctx$.a1);
|
||||
$r3$.ɵɵstylingApply();
|
||||
$r3$.ɵɵselect(3);
|
||||
$r3$.ɵɵclassProp(0, $ctx$.r1);
|
||||
$r3$.ɵɵstylingApply();
|
||||
$r3$.Δselect(0);
|
||||
$r3$.ΔstyleProp(0, $ctx$.w1);
|
||||
$r3$.ΔstylingApply();
|
||||
$r3$.Δselect(1);
|
||||
$r3$.ΔstyleProp(0, $ctx$.h1);
|
||||
$r3$.ΔstylingApply();
|
||||
$r3$.Δselect(2);
|
||||
$r3$.ΔclassProp(0, $ctx$.a1);
|
||||
$r3$.ΔstylingApply();
|
||||
$r3$.Δselect(3);
|
||||
$r3$.ΔclassProp(0, $ctx$.r1);
|
||||
$r3$.ΔstylingApply();
|
||||
}
|
||||
}
|
||||
`;
|
||||
|
@ -1104,15 +1104,15 @@ describe('compiler compliance: styling', () => {
|
|||
…
|
||||
hostBindings: function MyComponent_HostBindings(rf, ctx, elIndex) {
|
||||
if (rf & 1) {
|
||||
$r3$.ɵɵelementHostAttrs($e0_attrs$);
|
||||
$r3$.ɵɵstyling($e0_classBindings$, $e0_styleBindings$, $r3$.ɵɵdefaultStyleSanitizer);
|
||||
$r3$.ΔelementHostAttrs($e0_attrs$);
|
||||
$r3$.Δstyling($e0_classBindings$, $e0_styleBindings$, $r3$.ΔdefaultStyleSanitizer);
|
||||
}
|
||||
if (rf & 2) {
|
||||
$r3$.ɵɵstyleMap(ctx.myStyle);
|
||||
$r3$.ɵɵclassMap(ctx.myClass);
|
||||
$r3$.ɵɵstyleProp(0, ctx.myColorProp);
|
||||
$r3$.ɵɵclassProp(0, ctx.myFooClass);
|
||||
$r3$.ɵɵstylingApply();
|
||||
$r3$.ΔstyleMap(ctx.myStyle);
|
||||
$r3$.ΔclassMap(ctx.myClass);
|
||||
$r3$.ΔstyleProp(0, ctx.myColorProp);
|
||||
$r3$.ΔclassProp(0, ctx.myFooClass);
|
||||
$r3$.ΔstylingApply();
|
||||
}
|
||||
},
|
||||
consts: 0,
|
||||
|
@ -1166,16 +1166,16 @@ describe('compiler compliance: styling', () => {
|
|||
…
|
||||
hostBindings: function MyComponent_HostBindings(rf, ctx, elIndex) {
|
||||
if (rf & 1) {
|
||||
$r3$.ɵɵstyling(_c0, _c1, $r3$.ɵɵdefaultStyleSanitizer);
|
||||
$r3$.Δstyling(_c0, _c1, $r3$.ΔdefaultStyleSanitizer);
|
||||
}
|
||||
if (rf & 2) {
|
||||
$r3$.ɵɵstyleMap(ctx.myStyle);
|
||||
$r3$.ɵɵclassMap(ctx.myClasses);
|
||||
$r3$.ɵɵstyleProp(0, ctx.myHeightProp, "pt");
|
||||
$r3$.ɵɵstyleProp(1, ctx.myWidthProp);
|
||||
$r3$.ɵɵclassProp(0, ctx.myBarClass);
|
||||
$r3$.ɵɵclassProp(1, ctx.myFooClass);
|
||||
$r3$.ɵɵstylingApply();
|
||||
$r3$.ΔstyleMap(ctx.myStyle);
|
||||
$r3$.ΔclassMap(ctx.myClasses);
|
||||
$r3$.ΔstyleProp(0, ctx.myHeightProp, "pt");
|
||||
$r3$.ΔstyleProp(1, ctx.myWidthProp);
|
||||
$r3$.ΔclassProp(0, ctx.myBarClass);
|
||||
$r3$.ΔclassProp(1, ctx.myFooClass);
|
||||
$r3$.ΔstylingApply();
|
||||
}
|
||||
},
|
||||
consts: 0,
|
||||
|
@ -1229,17 +1229,17 @@ describe('compiler compliance: styling', () => {
|
|||
…
|
||||
function MyComponent_Template(rf, ctx) {
|
||||
if (rf & 1) {
|
||||
$r3$.ɵɵelementStart(0, "div");
|
||||
$r3$.ɵɵstyling(_c2, _c3, $r3$.ɵɵdefaultStyleSanitizer);
|
||||
$r3$.ɵɵelementEnd();
|
||||
$r3$.ΔelementStart(0, "div");
|
||||
$r3$.Δstyling(_c2, _c3, $r3$.ΔdefaultStyleSanitizer);
|
||||
$r3$.ΔelementEnd();
|
||||
}
|
||||
if (rf & 2) {
|
||||
$r3$.ɵɵselect(0);
|
||||
$r3$.ɵɵstyleMap(ctx.myStyleExp);
|
||||
$r3$.ɵɵclassMap(ctx.myClassExp);
|
||||
$r3$.ɵɵstyleProp(0, ctx.myHeightExp, null, true);
|
||||
$r3$.ɵɵclassProp(0, ctx.myBarClassExp, true);
|
||||
$r3$.ɵɵstylingApply();
|
||||
$r3$.Δselect(0);
|
||||
$r3$.ΔstyleMap(ctx.myStyleExp);
|
||||
$r3$.ΔclassMap(ctx.myClassExp);
|
||||
$r3$.ΔstyleProp(0, ctx.myHeightExp, null, true);
|
||||
$r3$.ΔclassProp(0, ctx.myBarClassExp, true);
|
||||
$r3$.ΔstylingApply();
|
||||
}
|
||||
},
|
||||
`;
|
||||
|
@ -1250,14 +1250,14 @@ describe('compiler compliance: styling', () => {
|
|||
…
|
||||
hostBindings: function MyComponent_HostBindings(rf, ctx, elIndex) {
|
||||
if (rf & 1) {
|
||||
$r3$.ɵɵstyling(_c0, _c1, $r3$.ɵɵdefaultStyleSanitizer);
|
||||
$r3$.Δstyling(_c0, _c1, $r3$.ΔdefaultStyleSanitizer);
|
||||
}
|
||||
if (rf & 2) {
|
||||
$r3$.ɵɵstyleMap(ctx.myStyleExp);
|
||||
$r3$.ɵɵclassMap(ctx.myClassExp);
|
||||
$r3$.ɵɵstyleProp(0, ctx.myWidthExp, null, true);
|
||||
$r3$.ɵɵclassProp(0, ctx.myFooClassExp, true);
|
||||
$r3$.ɵɵstylingApply();
|
||||
$r3$.ΔstyleMap(ctx.myStyleExp);
|
||||
$r3$.ΔclassMap(ctx.myClassExp);
|
||||
$r3$.ΔstyleProp(0, ctx.myWidthExp, null, true);
|
||||
$r3$.ΔclassProp(0, ctx.myFooClassExp, true);
|
||||
$r3$.ΔstylingApply();
|
||||
}
|
||||
},
|
||||
`;
|
||||
|
@ -1319,33 +1319,33 @@ describe('compiler compliance: styling', () => {
|
|||
…
|
||||
function ClassDirective_HostBindings(rf, ctx, elIndex) {
|
||||
if (rf & 1) {
|
||||
$r3$.ɵɵstyling();
|
||||
$r3$.Δstyling();
|
||||
}
|
||||
if (rf & 2) {
|
||||
$r3$.ɵɵclassMap(ctx.myClassMap);
|
||||
$r3$.ɵɵstylingApply();
|
||||
$r3$.ΔclassMap(ctx.myClassMap);
|
||||
$r3$.ΔstylingApply();
|
||||
}
|
||||
}
|
||||
…
|
||||
function WidthDirective_HostBindings(rf, ctx, elIndex) {
|
||||
if (rf & 1) {
|
||||
$r3$.ɵɵstyling($widthDir_classes$, $widthDir_styles$);
|
||||
$r3$.Δstyling($widthDir_classes$, $widthDir_styles$);
|
||||
}
|
||||
if (rf & 2) {
|
||||
$r3$.ɵɵstyleProp(0, ctx.myWidth);
|
||||
$r3$.ɵɵclassProp(0, ctx.myFooClass);
|
||||
$r3$.ɵɵstylingApply();
|
||||
$r3$.ΔstyleProp(0, ctx.myWidth);
|
||||
$r3$.ΔclassProp(0, ctx.myFooClass);
|
||||
$r3$.ΔstylingApply();
|
||||
}
|
||||
}
|
||||
…
|
||||
function HeightDirective_HostBindings(rf, ctx, elIndex) {
|
||||
if (rf & 1) {
|
||||
$r3$.ɵɵstyling($heightDir_classes$, $heightDir_styles$);
|
||||
$r3$.Δstyling($heightDir_classes$, $heightDir_styles$);
|
||||
}
|
||||
if (rf & 2) {
|
||||
$r3$.ɵɵstyleProp(0, ctx.myHeight);
|
||||
$r3$.ɵɵclassProp(0, ctx.myBarClass);
|
||||
$r3$.ɵɵstylingApply();
|
||||
$r3$.ΔstyleProp(0, ctx.myHeight);
|
||||
$r3$.ΔclassProp(0, ctx.myBarClass);
|
||||
$r3$.ΔstylingApply();
|
||||
}
|
||||
}
|
||||
…
|
||||
|
@ -1399,16 +1399,16 @@ describe('compiler compliance: styling', () => {
|
|||
…
|
||||
hostBindings: function MyComponent_HostBindings(rf, ctx, elIndex) {
|
||||
if (rf & 1) {
|
||||
$r3$.ɵɵallocHostVars(2);
|
||||
$r3$.ɵɵelementHostAttrs($_c0$);
|
||||
$r3$.ɵɵstyling(null, null, $r3$.ɵɵdefaultStyleSanitizer);
|
||||
$r3$.ΔallocHostVars(2);
|
||||
$r3$.ΔelementHostAttrs($_c0$);
|
||||
$r3$.Δstyling(null, null, $r3$.ΔdefaultStyleSanitizer);
|
||||
}
|
||||
if (rf & 2) {
|
||||
$r3$.ɵɵproperty("id", ctx.id, null, true);
|
||||
$r3$.ɵɵproperty("title", ctx.title, null, true);
|
||||
$r3$.ɵɵstyleMap(ctx.myStyle);
|
||||
$r3$.ɵɵclassMap(ctx.myClass);
|
||||
$r3$.ɵɵstylingApply();
|
||||
$r3$.Δproperty("id", ctx.id, null, true);
|
||||
$r3$.Δproperty("title", ctx.title, null, true);
|
||||
$r3$.ΔstyleMap(ctx.myStyle);
|
||||
$r3$.ΔclassMap(ctx.myClass);
|
||||
$r3$.ΔstylingApply();
|
||||
}
|
||||
}
|
||||
`;
|
||||
|
@ -1447,15 +1447,15 @@ describe('compiler compliance: styling', () => {
|
|||
…
|
||||
hostBindings: function WidthDirective_HostBindings(rf, ctx, elIndex) {
|
||||
if (rf & 1) {
|
||||
$r3$.ɵɵallocHostVars(2);
|
||||
$r3$.ɵɵstyling($_c0$, $_c1$);
|
||||
$r3$.ΔallocHostVars(2);
|
||||
$r3$.Δstyling($_c0$, $_c1$);
|
||||
}
|
||||
if (rf & 2) {
|
||||
$r3$.ɵɵproperty("id", ctx.id, null, true);
|
||||
$r3$.ɵɵproperty("title", ctx.title, null, true);
|
||||
$r3$.ɵɵstyleProp(0, ctx.myWidth);
|
||||
$r3$.ɵɵclassProp(0, ctx.myFooClass);
|
||||
$r3$.ɵɵstylingApply();
|
||||
$r3$.Δproperty("id", ctx.id, null, true);
|
||||
$r3$.Δproperty("title", ctx.title, null, true);
|
||||
$r3$.ΔstyleProp(0, ctx.myWidth);
|
||||
$r3$.ΔclassProp(0, ctx.myFooClass);
|
||||
$r3$.ΔstylingApply();
|
||||
}
|
||||
}
|
||||
`;
|
||||
|
|
|
@ -56,65 +56,65 @@ describe('compiler compliance: template', () => {
|
|||
function MyComponent_ul_0_li_1_div_1_Template(rf, ctx) {
|
||||
|
||||
if (rf & 1) {
|
||||
const $s$ = $i0$.ɵɵgetCurrentView();
|
||||
$i0$.ɵɵelementStart(0, "div", $c2$);
|
||||
$i0$.ɵɵlistener("click", function MyComponent_ul_0_li_1_div_1_Template_div_click_0_listener($event){
|
||||
$i0$.ɵɵrestoreView($s$);
|
||||
const $s$ = $i0$.ΔgetCurrentView();
|
||||
$i0$.ΔelementStart(0, "div", $c2$);
|
||||
$i0$.Δlistener("click", function MyComponent_ul_0_li_1_div_1_Template_div_click_0_listener($event){
|
||||
$i0$.ΔrestoreView($s$);
|
||||
const $inner$ = ctx.$implicit;
|
||||
const $middle$ = $i0$.ɵɵnextContext().$implicit;
|
||||
const $outer$ = $i0$.ɵɵnextContext().$implicit;
|
||||
const $myComp$ = $i0$.ɵɵnextContext();
|
||||
const $middle$ = $i0$.ΔnextContext().$implicit;
|
||||
const $outer$ = $i0$.ΔnextContext().$implicit;
|
||||
const $myComp$ = $i0$.ΔnextContext();
|
||||
return $myComp$.onClick($outer$, $middle$, $inner$);
|
||||
});
|
||||
$i0$.ɵɵtext(1);
|
||||
$i0$.ɵɵelementEnd();
|
||||
$i0$.Δtext(1);
|
||||
$i0$.ΔelementEnd();
|
||||
}
|
||||
|
||||
if (rf & 2) {
|
||||
const $inner1$ = ctx.$implicit;
|
||||
const $middle1$ = $i0$.ɵɵnextContext().$implicit;
|
||||
const $outer1$ = $i0$.ɵɵnextContext().$implicit;
|
||||
const $myComp1$ = $i0$.ɵɵnextContext();
|
||||
$i0$.ɵɵselect(0);
|
||||
$i0$.ɵɵproperty("title", $myComp1$.format($outer1$, $middle1$, $inner1$, $myComp1$.component));
|
||||
$r3$.ɵɵselect(1);
|
||||
$i0$.ɵɵtextBinding(1, $i0$.ɵɵinterpolation1(" ", $myComp1$.format($outer1$, $middle1$, $inner1$, $myComp1$.component), " "));
|
||||
const $middle1$ = $i0$.ΔnextContext().$implicit;
|
||||
const $outer1$ = $i0$.ΔnextContext().$implicit;
|
||||
const $myComp1$ = $i0$.ΔnextContext();
|
||||
$i0$.Δselect(0);
|
||||
$i0$.Δproperty("title", $myComp1$.format($outer1$, $middle1$, $inner1$, $myComp1$.component));
|
||||
$r3$.Δselect(1);
|
||||
$i0$.ΔtextBinding(1, $i0$.Δinterpolation1(" ", $myComp1$.format($outer1$, $middle1$, $inner1$, $myComp1$.component), " "));
|
||||
}
|
||||
}
|
||||
|
||||
function MyComponent_ul_0_li_1_Template(rf, ctx) {
|
||||
if (rf & 1) {
|
||||
$i0$.ɵɵelementStart(0, "li");
|
||||
$i0$.ɵɵtemplate(1, MyComponent_ul_0_li_1_div_1_Template, 2, 2, "div", $c1$);
|
||||
$i0$.ɵɵelementEnd();
|
||||
$i0$.ΔelementStart(0, "li");
|
||||
$i0$.Δtemplate(1, MyComponent_ul_0_li_1_div_1_Template, 2, 2, "div", $c1$);
|
||||
$i0$.ΔelementEnd();
|
||||
}
|
||||
if (rf & 2) {
|
||||
const $myComp2$ = $i0$.ɵɵnextContext(2);
|
||||
$r3$.ɵɵselect(1);
|
||||
$i0$.ɵɵproperty("ngForOf", $myComp2$.items);
|
||||
const $myComp2$ = $i0$.ΔnextContext(2);
|
||||
$r3$.Δselect(1);
|
||||
$i0$.Δproperty("ngForOf", $myComp2$.items);
|
||||
}
|
||||
}
|
||||
|
||||
function MyComponent_ul_0_Template(rf, ctx) {
|
||||
if (rf & 1) {
|
||||
$i0$.ɵɵelementStart(0, "ul");
|
||||
$i0$.ɵɵtemplate(1, MyComponent_ul_0_li_1_Template, 2, 1, "li", $c0$);
|
||||
$i0$.ɵɵelementEnd();
|
||||
$i0$.ΔelementStart(0, "ul");
|
||||
$i0$.Δtemplate(1, MyComponent_ul_0_li_1_Template, 2, 1, "li", $c0$);
|
||||
$i0$.ΔelementEnd();
|
||||
}
|
||||
if (rf & 2) {
|
||||
const $outer2$ = ctx.$implicit;
|
||||
$r3$.ɵɵselect(1);
|
||||
$i0$.ɵɵproperty("ngForOf", $outer2$.items);
|
||||
$r3$.Δselect(1);
|
||||
$i0$.Δproperty("ngForOf", $outer2$.items);
|
||||
}
|
||||
}
|
||||
// ...
|
||||
template:function MyComponent_Template(rf, ctx){
|
||||
if (rf & 1) {
|
||||
$i0$.ɵɵtemplate(0, MyComponent_ul_0_Template, 2, 1, "ul", $c0$);
|
||||
$i0$.Δtemplate(0, MyComponent_ul_0_Template, 2, 1, "ul", $c0$);
|
||||
}
|
||||
if (rf & 2) {
|
||||
$i0$.ɵɵselect(0);
|
||||
$i0$.ɵɵproperty("ngForOf", ctx.items);
|
||||
$i0$.Δselect(0);
|
||||
$i0$.Δproperty("ngForOf", ctx.items);
|
||||
}
|
||||
}`;
|
||||
|
||||
|
@ -152,26 +152,26 @@ describe('compiler compliance: template', () => {
|
|||
|
||||
function MyComponent_div_0_Template(rf, ctx) {
|
||||
if (rf & 1) {
|
||||
const $s$ = $r3$.ɵɵgetCurrentView();
|
||||
$r3$.ɵɵelementStart(0, "div", $e_attrs$);
|
||||
$r3$.ɵɵlistener("click", function MyComponent_div_0_Template_div_click_0_listener($event) {
|
||||
$r3$.ɵɵrestoreView($s$);
|
||||
const $s$ = $r3$.ΔgetCurrentView();
|
||||
$r3$.ΔelementStart(0, "div", $e_attrs$);
|
||||
$r3$.Δlistener("click", function MyComponent_div_0_Template_div_click_0_listener($event) {
|
||||
$r3$.ΔrestoreView($s$);
|
||||
const $d$ = ctx.$implicit;
|
||||
const $i$ = ctx.index;
|
||||
const $comp$ = $r3$.ɵɵnextContext();
|
||||
const $comp$ = $r3$.ΔnextContext();
|
||||
return $comp$._handleClick($d$, $i$);
|
||||
});
|
||||
$r3$.ɵɵelementEnd();
|
||||
$r3$.ΔelementEnd();
|
||||
}
|
||||
}
|
||||
// ...
|
||||
template: function MyComponent_Template(rf, ctx) {
|
||||
if (rf & 1) {
|
||||
$r3$.ɵɵtemplate(0, MyComponent_div_0_Template, 1, 0, "div", $t0_attrs$);
|
||||
$r3$.Δtemplate(0, MyComponent_div_0_Template, 1, 0, "div", $t0_attrs$);
|
||||
}
|
||||
if (rf & 2) {
|
||||
$r3$.ɵɵselect(0);
|
||||
$r3$.ɵɵproperty("ngForOf", ctx._data);
|
||||
$r3$.Δselect(0);
|
||||
$r3$.Δproperty("ngForOf", ctx._data);
|
||||
}
|
||||
}
|
||||
`;
|
||||
|
@ -207,25 +207,25 @@ describe('compiler compliance: template', () => {
|
|||
|
||||
function MyComponent_span_0_Template(rf, ctx) {
|
||||
if (rf & 1) {
|
||||
$i0$.ɵɵelementStart(0, "span");
|
||||
$i0$.ɵɵtext(1);
|
||||
$i0$.ɵɵelementEnd();
|
||||
$i0$.ΔelementStart(0, "span");
|
||||
$i0$.Δtext(1);
|
||||
$i0$.ΔelementEnd();
|
||||
}
|
||||
if (rf & 2) {
|
||||
const $item$ = ctx.$implicit;
|
||||
const $i$ = ctx.index;
|
||||
$r3$.ɵɵselect(1);
|
||||
$i0$.ɵɵtextBinding(1, $i0$.ɵɵinterpolation2(" ", $i$, " - ", $item$, " "));
|
||||
$r3$.Δselect(1);
|
||||
$i0$.ΔtextBinding(1, $i0$.Δinterpolation2(" ", $i$, " - ", $item$, " "));
|
||||
}
|
||||
}
|
||||
// ...
|
||||
template:function MyComponent_Template(rf, ctx){
|
||||
if (rf & 1) {
|
||||
$i0$.ɵɵtemplate(0, MyComponent_span_0_Template, 2, 2, "span", _c0);
|
||||
$i0$.Δtemplate(0, MyComponent_span_0_Template, 2, 2, "span", _c0);
|
||||
}
|
||||
if (rf & 2) {
|
||||
$i0$.ɵɵselect(0);
|
||||
$i0$.ɵɵproperty("ngForOf", ctx.items);
|
||||
$i0$.Δselect(0);
|
||||
$i0$.Δproperty("ngForOf", ctx.items);
|
||||
}
|
||||
}`;
|
||||
|
||||
|
@ -263,40 +263,40 @@ describe('compiler compliance: template', () => {
|
|||
|
||||
function MyComponent_div_0_span_1_Template(rf, ctx) {
|
||||
if (rf & 1) {
|
||||
$i0$.ɵɵelementStart(0, "span");
|
||||
$i0$.ɵɵtext(1);
|
||||
$i0$.ɵɵelementEnd();
|
||||
$i0$.ΔelementStart(0, "span");
|
||||
$i0$.Δtext(1);
|
||||
$i0$.ΔelementEnd();
|
||||
}
|
||||
if (rf & 2) {
|
||||
const $div$ = $i0$.ɵɵnextContext();
|
||||
const $div$ = $i0$.ΔnextContext();
|
||||
const $i$ = $div$.index;
|
||||
const $item$ = $div$.$implicit;
|
||||
$r3$.ɵɵselect(1);
|
||||
$i0$.ɵɵtextBinding(1, $i0$.ɵɵinterpolation2(" ", $i$, " - ", $item$, " "));
|
||||
$r3$.Δselect(1);
|
||||
$i0$.ΔtextBinding(1, $i0$.Δinterpolation2(" ", $i$, " - ", $item$, " "));
|
||||
}
|
||||
}
|
||||
|
||||
function MyComponent_div_0_Template(rf, ctx) {
|
||||
if (rf & 1) {
|
||||
$i0$.ɵɵelementStart(0, "div");
|
||||
$i0$.ɵɵtemplate(1, MyComponent_div_0_span_1_Template, 2, 2, "span", $c1$);
|
||||
$i0$.ɵɵelementEnd();
|
||||
$i0$.ΔelementStart(0, "div");
|
||||
$i0$.Δtemplate(1, MyComponent_div_0_span_1_Template, 2, 2, "span", $c1$);
|
||||
$i0$.ΔelementEnd();
|
||||
}
|
||||
if (rf & 2) {
|
||||
const $app$ = $i0$.ɵɵnextContext();
|
||||
$r3$.ɵɵselect(1);
|
||||
$i0$.ɵɵproperty("ngIf", $app$.showing);
|
||||
const $app$ = $i0$.ΔnextContext();
|
||||
$r3$.Δselect(1);
|
||||
$i0$.Δproperty("ngIf", $app$.showing);
|
||||
}
|
||||
}
|
||||
|
||||
// ...
|
||||
template:function MyComponent_Template(rf, ctx){
|
||||
if (rf & 1) {
|
||||
$i0$.ɵɵtemplate(0, MyComponent_div_0_Template, 2, 1, "div", $c0$);
|
||||
$i0$.Δtemplate(0, MyComponent_div_0_Template, 2, 1, "div", $c0$);
|
||||
}
|
||||
if (rf & 2) {
|
||||
$i0$.ɵɵselect(0);
|
||||
$i0$.ɵɵproperty("ngForOf", ctx.items);
|
||||
$i0$.Δselect(0);
|
||||
$i0$.Δproperty("ngForOf", ctx.items);
|
||||
}
|
||||
}`;
|
||||
|
||||
|
@ -335,51 +335,51 @@ describe('compiler compliance: template', () => {
|
|||
const $c0$ = [${AttributeMarker.Template}, "ngFor", "ngForOf"];
|
||||
function MyComponent_div_0_div_1_div_1_Template(rf, ctx) {
|
||||
if (rf & 1) {
|
||||
$i0$.ɵɵelementStart(0, "div");
|
||||
$i0$.ɵɵtext(1);
|
||||
$i0$.ɵɵelementEnd();
|
||||
$i0$.ΔelementStart(0, "div");
|
||||
$i0$.Δtext(1);
|
||||
$i0$.ΔelementEnd();
|
||||
}
|
||||
if (rf & 2) {
|
||||
const $middle$ = $i0$.ɵɵnextContext().$implicit;
|
||||
const $myComp$ = $i0$.ɵɵnextContext(2);
|
||||
$r3$.ɵɵselect(1);
|
||||
$i0$.ɵɵtextBinding(1, $i0$.ɵɵinterpolation2(" ", $middle$.value, " - ", $myComp$.name, " "));
|
||||
const $middle$ = $i0$.ΔnextContext().$implicit;
|
||||
const $myComp$ = $i0$.ΔnextContext(2);
|
||||
$r3$.Δselect(1);
|
||||
$i0$.ΔtextBinding(1, $i0$.Δinterpolation2(" ", $middle$.value, " - ", $myComp$.name, " "));
|
||||
}
|
||||
}
|
||||
|
||||
function MyComponent_div_0_div_1_Template(rf, ctx) {
|
||||
if (rf & 1) {
|
||||
$i0$.ɵɵelementStart(0, "div");
|
||||
$i0$.ɵɵtemplate(1, MyComponent_div_0_div_1_div_1_Template, 2, 2, "div", $c0$);
|
||||
$i0$.ɵɵelementEnd();
|
||||
$i0$.ΔelementStart(0, "div");
|
||||
$i0$.Δtemplate(1, MyComponent_div_0_div_1_div_1_Template, 2, 2, "div", $c0$);
|
||||
$i0$.ΔelementEnd();
|
||||
}
|
||||
if (rf & 2) {
|
||||
const $middle$ = ctx.$implicit;
|
||||
$r3$.ɵɵselect(1);
|
||||
$i0$.ɵɵproperty("ngForOf", $middle$.items);
|
||||
$r3$.Δselect(1);
|
||||
$i0$.Δproperty("ngForOf", $middle$.items);
|
||||
}
|
||||
}
|
||||
|
||||
function MyComponent_div_0_Template(rf, ctx) {
|
||||
if (rf & 1) {
|
||||
$i0$.ɵɵelementStart(0, "div");
|
||||
$i0$.ɵɵtemplate(1, MyComponent_div_0_div_1_Template, 2, 1, "div", $c0$);
|
||||
$i0$.ɵɵelementEnd();
|
||||
$i0$.ΔelementStart(0, "div");
|
||||
$i0$.Δtemplate(1, MyComponent_div_0_div_1_Template, 2, 1, "div", $c0$);
|
||||
$i0$.ΔelementEnd();
|
||||
}
|
||||
if (rf & 2) {
|
||||
const $outer$ = ctx.$implicit;
|
||||
$r3$.ɵɵselect(1);
|
||||
$i0$.ɵɵproperty("ngForOf", $outer$.items);
|
||||
$r3$.Δselect(1);
|
||||
$i0$.Δproperty("ngForOf", $outer$.items);
|
||||
}
|
||||
}
|
||||
// ...
|
||||
template:function MyComponent_Template(rf, ctx){
|
||||
if (rf & 1) {
|
||||
$i0$.ɵɵtemplate(0, MyComponent_div_0_Template, 2, 1, "div", $c0$);
|
||||
$i0$.Δtemplate(0, MyComponent_div_0_Template, 2, 1, "div", $c0$);
|
||||
}
|
||||
if (rf & 2) {
|
||||
$i0$.ɵɵselect(0);
|
||||
$i0$.ɵɵproperty("ngForOf", ctx.items);
|
||||
$i0$.Δselect(0);
|
||||
$i0$.Δproperty("ngForOf", ctx.items);
|
||||
}
|
||||
}`;
|
||||
|
||||
|
@ -414,7 +414,7 @@ describe('compiler compliance: template', () => {
|
|||
|
||||
function MyComponent_ng_template_0_Template(rf, ctx) {
|
||||
if (rf & 1) {
|
||||
$i0$.ɵɵtext(0, " some-content ");
|
||||
$i0$.Δtext(0, " some-content ");
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -422,11 +422,11 @@ describe('compiler compliance: template', () => {
|
|||
|
||||
template: function MyComponent_Template(rf, ctx) {
|
||||
if (rf & 1) {
|
||||
$i0$.ɵɵtemplate(0, MyComponent_ng_template_0_Template, 1, 0, "ng-template", $c0$);
|
||||
$i0$.Δtemplate(0, MyComponent_ng_template_0_Template, 1, 0, "ng-template", $c0$);
|
||||
}
|
||||
if (rf & 2) {
|
||||
$i0$.ɵɵselect(0);
|
||||
$i0$.ɵɵproperty("boundAttr", ctx.b);
|
||||
$i0$.Δselect(0);
|
||||
$i0$.Δproperty("boundAttr", ctx.b);
|
||||
}
|
||||
}`;
|
||||
|
||||
|
@ -459,7 +459,7 @@ describe('compiler compliance: template', () => {
|
|||
|
||||
function MyComponent_ng_template_0_Template(rf, ctx) {
|
||||
if (rf & 1) {
|
||||
$i0$.ɵɵtext(0, "some-content");
|
||||
$i0$.Δtext(0, "some-content");
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -467,7 +467,7 @@ describe('compiler compliance: template', () => {
|
|||
|
||||
template: function MyComponent_Template(rf, ctx) {
|
||||
if (rf & 1) {
|
||||
$i0$.ɵɵtemplate(0, MyComponent_ng_template_0_Template, 1, 0, "ng-template", null, $t0_refs$, $i0$.ɵɵtemplateRefExtractor);
|
||||
$i0$.Δtemplate(0, MyComponent_ng_template_0_Template, 1, 0, "ng-template", null, $t0_refs$, $i0$.ΔtemplateRefExtractor);
|
||||
}
|
||||
}`;
|
||||
|
||||
|
@ -504,8 +504,8 @@ describe('compiler compliance: template', () => {
|
|||
|
||||
template: function MyComponent_Template(rf, ctx) {
|
||||
if (rf & 1) {
|
||||
$i0$.ɵɵtemplate(0, MyComponent_ng_template_0_Template, 0, 0, "ng-template", $t0_attrs$);
|
||||
$i0$.ɵɵlistener("outDirective", function MyComponent_Template_ng_template_outDirective_0_listener($event) { return $event.doSth(); });
|
||||
$i0$.Δtemplate(0, MyComponent_ng_template_0_Template, 0, 0, "ng-template", $t0_attrs$);
|
||||
$i0$.Δlistener("outDirective", function MyComponent_Template_ng_template_outDirective_0_listener($event) { return $event.doSth(); });
|
||||
}
|
||||
}`;
|
||||
|
||||
|
@ -607,7 +607,7 @@ describe('compiler compliance: template', () => {
|
|||
export class AComponent {
|
||||
show = true;
|
||||
}
|
||||
|
||||
|
||||
@Component({
|
||||
selector: 'b-component',
|
||||
template: \`
|
||||
|
@ -705,7 +705,7 @@ describe('compiler compliance: template', () => {
|
|||
|
||||
function MyComponent_div_0_Template(rf, ctx) {
|
||||
if (rf & 1) {
|
||||
$i0$.ɵɵelement(0, "div");
|
||||
$i0$.Δelement(0, "div");
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -713,11 +713,11 @@ describe('compiler compliance: template', () => {
|
|||
|
||||
template: function MyComponent_Template(rf, ctx) {
|
||||
if (rf & 1) {
|
||||
$i0$.ɵɵtemplate(0, MyComponent_div_0_Template, 1, 0, "div", $c0$);
|
||||
$i0$.ɵɵpipe(1, "pipe");
|
||||
$i0$.Δtemplate(0, MyComponent_div_0_Template, 1, 0, "div", $c0$);
|
||||
$i0$.Δpipe(1, "pipe");
|
||||
} if (rf & 2) {
|
||||
$i0$.ɵɵselect(0);
|
||||
$i0$.ɵɵproperty("ngIf", $i0$.ɵɵpipeBind1(1, 1, ctx.val));
|
||||
$i0$.Δselect(0);
|
||||
$i0$.Δproperty("ngIf", $i0$.ΔpipeBind1(1, 1, ctx.val));
|
||||
}
|
||||
}`;
|
||||
|
||||
|
|
|
@ -2113,7 +2113,7 @@ describe('ngc transformer command-line', () => {
|
|||
})
|
||||
export class Service {}
|
||||
`);
|
||||
expect(source).toMatch(/ngInjectableDef = .+\.ɵɵdefineInjectable\(/);
|
||||
expect(source).toMatch(/ngInjectableDef = .+\.ΔdefineInjectable\(/);
|
||||
expect(source).toMatch(/ngInjectableDef.*token: Service/);
|
||||
expect(source).toMatch(/ngInjectableDef.*providedIn: .+\.Module/);
|
||||
});
|
||||
|
@ -2169,7 +2169,7 @@ describe('ngc transformer command-line', () => {
|
|||
})
|
||||
export class Service {}
|
||||
`);
|
||||
expect(source).toMatch(/ngInjectableDef.*return ..\.ɵɵinject\(Existing\)/);
|
||||
expect(source).toMatch(/ngInjectableDef.*return ..\.Δinject\(Existing\)/);
|
||||
});
|
||||
|
||||
it('compiles a useFactory InjectableDef with optional dep', () => {
|
||||
|
@ -2189,7 +2189,7 @@ describe('ngc transformer command-line', () => {
|
|||
constructor(e: Existing|null) {}
|
||||
}
|
||||
`);
|
||||
expect(source).toMatch(/ngInjectableDef.*return ..\(..\.ɵɵinject\(Existing, 8\)/);
|
||||
expect(source).toMatch(/ngInjectableDef.*return ..\(..\.Δinject\(Existing, 8\)/);
|
||||
});
|
||||
|
||||
it('compiles a useFactory InjectableDef with skip-self dep', () => {
|
||||
|
@ -2209,7 +2209,7 @@ describe('ngc transformer command-line', () => {
|
|||
constructor(e: Existing) {}
|
||||
}
|
||||
`);
|
||||
expect(source).toMatch(/ngInjectableDef.*return ..\(..\.ɵɵinject\(Existing, 4\)/);
|
||||
expect(source).toMatch(/ngInjectableDef.*return ..\(..\.Δinject\(Existing, 4\)/);
|
||||
});
|
||||
|
||||
it('compiles a service that depends on a token', () => {
|
||||
|
@ -2226,7 +2226,7 @@ describe('ngc transformer command-line', () => {
|
|||
constructor(@Inject(TOKEN) value: boolean) {}
|
||||
}
|
||||
`);
|
||||
expect(source).toMatch(/ngInjectableDef = .+\.ɵɵdefineInjectable\(/);
|
||||
expect(source).toMatch(/ngInjectableDef = .+\.ΔdefineInjectable\(/);
|
||||
expect(source).toMatch(/ngInjectableDef.*token: Service/);
|
||||
expect(source).toMatch(/ngInjectableDef.*providedIn: .+\.Module/);
|
||||
});
|
||||
|
@ -2253,7 +2253,7 @@ describe('ngc transformer command-line', () => {
|
|||
constructor(@Inject(TOKEN) token: any) {}
|
||||
}
|
||||
`);
|
||||
expect(source).toMatch(/new Service\(i0\.ɵɵinject\(exports\.TOKEN\)\);/);
|
||||
expect(source).toMatch(/new Service\(i0\.Δinject\(exports\.TOKEN\)\);/);
|
||||
});
|
||||
});
|
||||
|
||||
|
|
|
@ -62,9 +62,9 @@ export function forwardRef<T>(fn: () => T): T {
|
|||
|
||||
export interface SimpleChanges { [propName: string]: any; }
|
||||
|
||||
export type ɵɵNgModuleDefWithMeta<ModuleT, DeclarationsT, ImportsT, ExportsT> = any;
|
||||
export type ɵɵDirectiveDefWithMeta<DirT, SelectorT, ExportAsT, InputsT, OutputsT, QueriesT> = any;
|
||||
export type ɵɵPipeDefWithMeta<PipeT, NameT> = any;
|
||||
export type ΔNgModuleDefWithMeta<ModuleT, DeclarationsT, ImportsT, ExportsT> = any;
|
||||
export type ΔDirectiveDefWithMeta<DirT, SelectorT, ExportAsT, InputsT, OutputsT, QueriesT> = any;
|
||||
export type ΔPipeDefWithMeta<PipeT, NameT> = any;
|
||||
|
||||
export enum ViewEncapsulation {
|
||||
Emulated = 0,
|
||||
|
|
|
@ -18,13 +18,12 @@ const varRegExp = (name: string): RegExp => new RegExp(`var \\w+ = \\[\"${name}\
|
|||
|
||||
const viewQueryRegExp = (descend: boolean, ref?: string): RegExp => {
|
||||
const maybeRef = ref ? `${ref}` : `null`;
|
||||
return new RegExp(`i0\\.\u0275\u0275viewQuery\\(\\w+, ${descend}, ${maybeRef}\\)`);
|
||||
return new RegExp(`i0\\.ΔviewQuery\\(\\w+, ${descend}, ${maybeRef}\\)`);
|
||||
};
|
||||
|
||||
const contentQueryRegExp = (predicate: string, descend: boolean, ref?: string): RegExp => {
|
||||
const maybeRef = ref ? `${ref}` : `null`;
|
||||
return new RegExp(
|
||||
`i0\\.\u0275\u0275contentQuery\\(dirIndex, ${predicate}, ${descend}, ${maybeRef}\\)`);
|
||||
return new RegExp(`i0\\.ΔcontentQuery\\(dirIndex, ${predicate}, ${descend}, ${maybeRef}\\)`);
|
||||
};
|
||||
|
||||
const setClassMetadataRegExp = (expectedType: string): RegExp =>
|
||||
|
@ -57,8 +56,8 @@ describe('ngtsc behavioral tests', () => {
|
|||
expect(jsContents).toContain('Service.ngInjectableDef =');
|
||||
expect(jsContents).not.toContain('__decorate');
|
||||
const dtsContents = env.getContents('test.d.ts');
|
||||
expect(dtsContents).toContain('static ngInjectableDef: i0.\u0275\u0275InjectableDef<Dep>;');
|
||||
expect(dtsContents).toContain('static ngInjectableDef: i0.\u0275\u0275InjectableDef<Service>;');
|
||||
expect(dtsContents).toContain('static ngInjectableDef: i0.ΔInjectableDef<Dep>;');
|
||||
expect(dtsContents).toContain('static ngInjectableDef: i0.ΔInjectableDef<Service>;');
|
||||
});
|
||||
|
||||
it('should compile Injectables with a generic service', () => {
|
||||
|
@ -76,8 +75,7 @@ describe('ngtsc behavioral tests', () => {
|
|||
const jsContents = env.getContents('test.js');
|
||||
expect(jsContents).toContain('Store.ngInjectableDef =');
|
||||
const dtsContents = env.getContents('test.d.ts');
|
||||
expect(dtsContents)
|
||||
.toContain('static ngInjectableDef: i0.\u0275\u0275InjectableDef<Store<any>>;');
|
||||
expect(dtsContents).toContain('static ngInjectableDef: i0.ΔInjectableDef<Store<any>>;');
|
||||
});
|
||||
|
||||
it('should compile Injectables with providedIn without errors', () => {
|
||||
|
@ -101,12 +99,11 @@ describe('ngtsc behavioral tests', () => {
|
|||
expect(jsContents).toContain('Dep.ngInjectableDef =');
|
||||
expect(jsContents).toContain('Service.ngInjectableDef =');
|
||||
expect(jsContents)
|
||||
.toContain(
|
||||
'return new (t || Service)(i0.\u0275\u0275inject(Dep)); }, providedIn: \'root\' });');
|
||||
.toContain('return new (t || Service)(i0.Δinject(Dep)); }, providedIn: \'root\' });');
|
||||
expect(jsContents).not.toContain('__decorate');
|
||||
const dtsContents = env.getContents('test.d.ts');
|
||||
expect(dtsContents).toContain('static ngInjectableDef: i0.\u0275\u0275InjectableDef<Dep>;');
|
||||
expect(dtsContents).toContain('static ngInjectableDef: i0.\u0275\u0275InjectableDef<Service>;');
|
||||
expect(dtsContents).toContain('static ngInjectableDef: i0.ΔInjectableDef<Dep>;');
|
||||
expect(dtsContents).toContain('static ngInjectableDef: i0.ΔInjectableDef<Service>;');
|
||||
});
|
||||
|
||||
it('should compile Injectables with providedIn and factory without errors', () => {
|
||||
|
@ -131,7 +128,7 @@ describe('ngtsc behavioral tests', () => {
|
|||
expect(jsContents).toContain('return r; }, providedIn: \'root\' });');
|
||||
expect(jsContents).not.toContain('__decorate');
|
||||
const dtsContents = env.getContents('test.d.ts');
|
||||
expect(dtsContents).toContain('static ngInjectableDef: i0.\u0275\u0275InjectableDef<Service>;');
|
||||
expect(dtsContents).toContain('static ngInjectableDef: i0.ΔInjectableDef<Service>;');
|
||||
});
|
||||
|
||||
it('should compile Injectables with providedIn and factory with deps without errors', () => {
|
||||
|
@ -154,14 +151,13 @@ describe('ngtsc behavioral tests', () => {
|
|||
const jsContents = env.getContents('test.js');
|
||||
expect(jsContents).toContain('Service.ngInjectableDef =');
|
||||
expect(jsContents).toContain('factory: function Service_Factory(t) { var r = null; if (t) {');
|
||||
expect(jsContents).toContain('(r = new t(i0.\u0275\u0275inject(Dep)));');
|
||||
expect(jsContents).toContain('(r = new t(i0.Δinject(Dep)));');
|
||||
expect(jsContents)
|
||||
.toContain(
|
||||
'(r = (function (dep) { return new Service(dep); })(i0.\u0275\u0275inject(Dep)));');
|
||||
.toContain('(r = (function (dep) { return new Service(dep); })(i0.Δinject(Dep)));');
|
||||
expect(jsContents).toContain('return r; }, providedIn: \'root\' });');
|
||||
expect(jsContents).not.toContain('__decorate');
|
||||
const dtsContents = env.getContents('test.d.ts');
|
||||
expect(dtsContents).toContain('static ngInjectableDef: i0.\u0275\u0275InjectableDef<Service>;');
|
||||
expect(dtsContents).toContain('static ngInjectableDef: i0.ΔInjectableDef<Service>;');
|
||||
});
|
||||
|
||||
it('should compile @Injectable with an @Optional dependency', () => {
|
||||
|
@ -197,13 +193,13 @@ describe('ngtsc behavioral tests', () => {
|
|||
env.driveMain();
|
||||
|
||||
const jsContents = env.getContents('test.js');
|
||||
expect(jsContents).toContain('TestCmp.ngComponentDef = i0.\u0275\u0275defineComponent');
|
||||
expect(jsContents).toContain('TestCmp.ngComponentDef = i0.ΔdefineComponent');
|
||||
expect(jsContents).not.toContain('__decorate');
|
||||
|
||||
const dtsContents = env.getContents('test.d.ts');
|
||||
expect(dtsContents)
|
||||
.toContain(
|
||||
'static ngComponentDef: i0.\u0275\u0275ComponentDefWithMeta<TestCmp, "test-cmp", never, {}, {}, never>');
|
||||
'static ngComponentDef: i0.ΔComponentDefWithMeta<TestCmp, "test-cmp", never, {}, {}, never>');
|
||||
});
|
||||
|
||||
it('should compile Components (dynamic inline template) without errors', () => {
|
||||
|
@ -221,13 +217,13 @@ describe('ngtsc behavioral tests', () => {
|
|||
env.driveMain();
|
||||
|
||||
const jsContents = env.getContents('test.js');
|
||||
expect(jsContents).toContain('TestCmp.ngComponentDef = i0.\u0275\u0275defineComponent');
|
||||
expect(jsContents).toContain('TestCmp.ngComponentDef = i0.ΔdefineComponent');
|
||||
expect(jsContents).not.toContain('__decorate');
|
||||
|
||||
const dtsContents = env.getContents('test.d.ts');
|
||||
expect(dtsContents)
|
||||
.toContain(
|
||||
'static ngComponentDef: i0.\u0275\u0275ComponentDefWithMeta<TestCmp, "test-cmp", never, {}, {}, never>');
|
||||
'static ngComponentDef: i0.ΔComponentDefWithMeta<TestCmp, "test-cmp", never, {}, {}, never>');
|
||||
});
|
||||
|
||||
it('should compile Components (function call inline template) without errors', () => {
|
||||
|
@ -248,13 +244,13 @@ describe('ngtsc behavioral tests', () => {
|
|||
env.driveMain();
|
||||
|
||||
const jsContents = env.getContents('test.js');
|
||||
expect(jsContents).toContain('TestCmp.ngComponentDef = i0.\u0275\u0275defineComponent');
|
||||
expect(jsContents).toContain('TestCmp.ngComponentDef = i0.ΔdefineComponent');
|
||||
expect(jsContents).not.toContain('__decorate');
|
||||
|
||||
const dtsContents = env.getContents('test.d.ts');
|
||||
expect(dtsContents)
|
||||
.toContain(
|
||||
'static ngComponentDef: i0.\u0275\u0275ComponentDefWithMeta<TestCmp, "test-cmp", never, {}, {}, never>');
|
||||
'static ngComponentDef: i0.ΔComponentDefWithMeta<TestCmp, "test-cmp", never, {}, {}, never>');
|
||||
});
|
||||
|
||||
it('should compile Components (external template) without errors', () => {
|
||||
|
@ -355,14 +351,13 @@ describe('ngtsc behavioral tests', () => {
|
|||
env.driveMain();
|
||||
|
||||
const jsContents = env.getContents('test.js');
|
||||
expect(jsContents).toContain('TestBase.ngBaseDef = i0.\u0275\u0275defineBase');
|
||||
expect(jsContents).toContain('TestComponent.ngComponentDef = i0.\u0275\u0275defineComponent');
|
||||
expect(jsContents).toContain('TestDirective.ngDirectiveDef = i0.\u0275\u0275defineDirective');
|
||||
expect(jsContents).toContain('TestPipe.ngPipeDef = i0.\u0275\u0275definePipe');
|
||||
expect(jsContents)
|
||||
.toContain('TestInjectable.ngInjectableDef = i0.\u0275\u0275defineInjectable');
|
||||
expect(jsContents).toContain('MyModule.ngModuleDef = i0.\u0275\u0275defineNgModule');
|
||||
expect(jsContents).toContain('MyModule.ngInjectorDef = i0.\u0275\u0275defineInjector');
|
||||
expect(jsContents).toContain('TestBase.ngBaseDef = i0.ΔdefineBase');
|
||||
expect(jsContents).toContain('TestComponent.ngComponentDef = i0.ΔdefineComponent');
|
||||
expect(jsContents).toContain('TestDirective.ngDirectiveDef = i0.ΔdefineDirective');
|
||||
expect(jsContents).toContain('TestPipe.ngPipeDef = i0.ΔdefinePipe');
|
||||
expect(jsContents).toContain('TestInjectable.ngInjectableDef = i0.ΔdefineInjectable');
|
||||
expect(jsContents).toContain('MyModule.ngModuleDef = i0.ΔdefineNgModule');
|
||||
expect(jsContents).toContain('MyModule.ngInjectorDef = i0.ΔdefineInjector');
|
||||
expect(jsContents).toContain('inputs: { input: "input" }');
|
||||
expect(jsContents).toContain('outputs: { output: "output" }');
|
||||
});
|
||||
|
@ -447,42 +442,39 @@ describe('ngtsc behavioral tests', () => {
|
|||
env.driveMain();
|
||||
|
||||
const jsContents = env.getContents('test.js');
|
||||
expect(jsContents).toContain('i0.ΔdefineNgModule({ type: TestModule, bootstrap: [TestCmp] });');
|
||||
expect(jsContents)
|
||||
.toContain('i0.\u0275\u0275defineNgModule({ type: TestModule, bootstrap: [TestCmp] });');
|
||||
.toContain('/*@__PURE__*/ i0.ΔsetNgModuleScope(TestModule, { declarations: [TestCmp] });');
|
||||
expect(jsContents)
|
||||
.toContain(
|
||||
'/*@__PURE__*/ i0.\u0275\u0275setNgModuleScope(TestModule, { declarations: [TestCmp] });');
|
||||
expect(jsContents)
|
||||
.toContain(
|
||||
'i0.\u0275\u0275defineInjector({ factory: ' +
|
||||
'i0.ΔdefineInjector({ factory: ' +
|
||||
'function TestModule_Factory(t) { return new (t || TestModule)(); } });');
|
||||
|
||||
const dtsContents = env.getContents('test.d.ts');
|
||||
expect(dtsContents)
|
||||
.toContain(
|
||||
'static ngComponentDef: i0.\u0275\u0275ComponentDefWithMeta<TestCmp, "test-cmp", never, {}, {}, never>');
|
||||
'static ngComponentDef: i0.ΔComponentDefWithMeta<TestCmp, "test-cmp", never, {}, {}, never>');
|
||||
expect(dtsContents)
|
||||
.toContain(
|
||||
'static ngModuleDef: i0.\u0275\u0275NgModuleDefWithMeta<TestModule, [typeof TestCmp], never, never>');
|
||||
'static ngModuleDef: i0.ΔNgModuleDefWithMeta<TestModule, [typeof TestCmp], never, never>');
|
||||
expect(dtsContents).not.toContain('__decorate');
|
||||
});
|
||||
|
||||
it('should not emit a \u0275\u0275setNgModuleScope call when no scope metadata is present',
|
||||
() => {
|
||||
env.tsconfig();
|
||||
env.write('test.ts', `
|
||||
it('should not emit a ΔsetNgModuleScope call when no scope metadata is present', () => {
|
||||
env.tsconfig();
|
||||
env.write('test.ts', `
|
||||
import {NgModule} from '@angular/core';
|
||||
|
||||
@NgModule({})
|
||||
export class TestModule {}
|
||||
`);
|
||||
|
||||
env.driveMain();
|
||||
env.driveMain();
|
||||
|
||||
const jsContents = env.getContents('test.js');
|
||||
expect(jsContents).toContain('i0.\u0275\u0275defineNgModule({ type: TestModule });');
|
||||
expect(jsContents).not.toContain('\u0275\u0275setNgModuleScope(TestModule,');
|
||||
});
|
||||
const jsContents = env.getContents('test.js');
|
||||
expect(jsContents).toContain('i0.ΔdefineNgModule({ type: TestModule });');
|
||||
expect(jsContents).not.toContain('ΔsetNgModuleScope(TestModule,');
|
||||
});
|
||||
|
||||
it('should emit the id when the module\'s id is a string', () => {
|
||||
env.tsconfig();
|
||||
|
@ -496,7 +488,7 @@ describe('ngtsc behavioral tests', () => {
|
|||
env.driveMain();
|
||||
|
||||
const jsContents = env.getContents('test.js');
|
||||
expect(jsContents).toContain(`i0.\u0275\u0275defineNgModule({ type: TestModule, id: 'test' })`);
|
||||
expect(jsContents).toContain(`i0.ΔdefineNgModule({ type: TestModule, id: 'test' })`);
|
||||
});
|
||||
|
||||
it('should emit the id when the module\'s id is defined as `module.id`', () => {
|
||||
|
@ -514,8 +506,7 @@ describe('ngtsc behavioral tests', () => {
|
|||
env.driveMain();
|
||||
|
||||
const jsContents = env.getContents('test.js');
|
||||
expect(jsContents)
|
||||
.toContain('i0.\u0275\u0275defineNgModule({ type: TestModule, id: module.id })');
|
||||
expect(jsContents).toContain('i0.ΔdefineNgModule({ type: TestModule, id: module.id })');
|
||||
});
|
||||
|
||||
it('should filter out directives and pipes from module exports in the injector def', () => {
|
||||
|
@ -556,15 +547,15 @@ describe('ngtsc behavioral tests', () => {
|
|||
export class Comp {}
|
||||
`);
|
||||
env.write('node_modules/@angular/router/index.d.ts', `
|
||||
import {\u0275\u0275ComponentDefWithMeta, ModuleWithProviders, \u0275\u0275NgModuleDefWithMeta} from '@angular/core';
|
||||
import {ΔComponentDefWithMeta, ModuleWithProviders, ΔNgModuleDefWithMeta} from '@angular/core';
|
||||
|
||||
export declare class RouterComp {
|
||||
static ngComponentDef: \u0275\u0275ComponentDefWithMeta<RouterComp, "lib-cmp", never, {}, {}, never>
|
||||
static ngComponentDef: ΔComponentDefWithMeta<RouterComp, "lib-cmp", never, {}, {}, never>
|
||||
}
|
||||
|
||||
declare class RouterModule {
|
||||
static forRoot(): ModuleWithProviders<RouterModule>;
|
||||
static ngModuleDef: \u0275\u0275NgModuleDefWithMeta<RouterModule, [typeof RouterComp], never, [typeof RouterComp]>;
|
||||
static ngModuleDef: ΔNgModuleDefWithMeta<RouterModule, [typeof RouterComp], never, [typeof RouterComp]>;
|
||||
}
|
||||
`);
|
||||
|
||||
|
@ -573,7 +564,7 @@ describe('ngtsc behavioral tests', () => {
|
|||
const jsContents = env.getContents('test.js');
|
||||
expect(jsContents)
|
||||
.toContain(
|
||||
'i0.\u0275\u0275defineInjector({ factory: function TestModule_Factory(t) ' +
|
||||
'i0.ΔdefineInjector({ factory: function TestModule_Factory(t) ' +
|
||||
'{ return new (t || TestModule)(); }, imports: [[OtherModule, RouterModule.forRoot()],' +
|
||||
'\n OtherModule,\n RouterModule] });');
|
||||
});
|
||||
|
@ -605,18 +596,18 @@ describe('ngtsc behavioral tests', () => {
|
|||
env.driveMain();
|
||||
|
||||
const jsContents = env.getContents('test.js');
|
||||
expect(jsContents).toContain('i0.\u0275\u0275defineNgModule({ type: TestModule });');
|
||||
expect(jsContents).toContain('i0.ΔdefineNgModule({ type: TestModule });');
|
||||
expect(jsContents)
|
||||
.toContain(
|
||||
`TestModule.ngInjectorDef = i0.\u0275\u0275defineInjector({ factory: ` +
|
||||
`TestModule.ngInjectorDef = i0.ΔdefineInjector({ factory: ` +
|
||||
`function TestModule_Factory(t) { return new (t || TestModule)(); }, providers: [{ provide: ` +
|
||||
`Token, useValue: 'test' }], imports: [[OtherModule]] });`);
|
||||
|
||||
const dtsContents = env.getContents('test.d.ts');
|
||||
expect(dtsContents)
|
||||
.toContain(
|
||||
'static ngModuleDef: i0.\u0275\u0275NgModuleDefWithMeta<TestModule, [typeof TestCmp], [typeof OtherModule], never>');
|
||||
expect(dtsContents).toContain('static ngInjectorDef: i0.\u0275\u0275InjectorDef');
|
||||
'static ngModuleDef: i0.ΔNgModuleDefWithMeta<TestModule, [typeof TestCmp], [typeof OtherModule], never>');
|
||||
expect(dtsContents).toContain('static ngInjectorDef: i0.ΔInjectorDef');
|
||||
});
|
||||
|
||||
it('should compile NgModules with factory providers without errors', () => {
|
||||
|
@ -646,18 +637,18 @@ describe('ngtsc behavioral tests', () => {
|
|||
env.driveMain();
|
||||
|
||||
const jsContents = env.getContents('test.js');
|
||||
expect(jsContents).toContain('i0.\u0275\u0275defineNgModule({ type: TestModule });');
|
||||
expect(jsContents).toContain('i0.ΔdefineNgModule({ type: TestModule });');
|
||||
expect(jsContents)
|
||||
.toContain(
|
||||
`TestModule.ngInjectorDef = i0.\u0275\u0275defineInjector({ factory: ` +
|
||||
`TestModule.ngInjectorDef = i0.ΔdefineInjector({ factory: ` +
|
||||
`function TestModule_Factory(t) { return new (t || TestModule)(); }, providers: [{ provide: ` +
|
||||
`Token, useFactory: function () { return new Token(); } }], imports: [[OtherModule]] });`);
|
||||
|
||||
const dtsContents = env.getContents('test.d.ts');
|
||||
expect(dtsContents)
|
||||
.toContain(
|
||||
'static ngModuleDef: i0.\u0275\u0275NgModuleDefWithMeta<TestModule, [typeof TestCmp], [typeof OtherModule], never>');
|
||||
expect(dtsContents).toContain('static ngInjectorDef: i0.\u0275\u0275InjectorDef');
|
||||
'static ngModuleDef: i0.ΔNgModuleDefWithMeta<TestModule, [typeof TestCmp], [typeof OtherModule], never>');
|
||||
expect(dtsContents).toContain('static ngInjectorDef: i0.ΔInjectorDef');
|
||||
});
|
||||
|
||||
it('should compile NgModules with factory providers and deps without errors', () => {
|
||||
|
@ -691,18 +682,18 @@ describe('ngtsc behavioral tests', () => {
|
|||
env.driveMain();
|
||||
|
||||
const jsContents = env.getContents('test.js');
|
||||
expect(jsContents).toContain('i0.\u0275\u0275defineNgModule({ type: TestModule });');
|
||||
expect(jsContents).toContain('i0.ΔdefineNgModule({ type: TestModule });');
|
||||
expect(jsContents)
|
||||
.toContain(
|
||||
`TestModule.ngInjectorDef = i0.\u0275\u0275defineInjector({ factory: ` +
|
||||
`TestModule.ngInjectorDef = i0.ΔdefineInjector({ factory: ` +
|
||||
`function TestModule_Factory(t) { return new (t || TestModule)(); }, providers: [{ provide: ` +
|
||||
`Token, useFactory: function (dep) { return new Token(dep); }, deps: [Dep] }], imports: [[OtherModule]] });`);
|
||||
|
||||
const dtsContents = env.getContents('test.d.ts');
|
||||
expect(dtsContents)
|
||||
.toContain(
|
||||
'static ngModuleDef: i0.\u0275\u0275NgModuleDefWithMeta<TestModule, [typeof TestCmp], [typeof OtherModule], never>');
|
||||
expect(dtsContents).toContain('static ngInjectorDef: i0.\u0275\u0275InjectorDef');
|
||||
'static ngModuleDef: i0.ΔNgModuleDefWithMeta<TestModule, [typeof TestCmp], [typeof OtherModule], never>');
|
||||
expect(dtsContents).toContain('static ngInjectorDef: i0.ΔInjectorDef');
|
||||
});
|
||||
|
||||
it('should compile NgModules with references to local components', () => {
|
||||
|
@ -863,10 +854,9 @@ describe('ngtsc behavioral tests', () => {
|
|||
|
||||
expect(jsContents)
|
||||
.toContain(
|
||||
'TestPipe.ngPipeDef = i0.\u0275\u0275definePipe({ name: "test-pipe", type: TestPipe, ' +
|
||||
'TestPipe.ngPipeDef = i0.ΔdefinePipe({ name: "test-pipe", type: TestPipe, ' +
|
||||
'factory: function TestPipe_Factory(t) { return new (t || TestPipe)(); }, pure: false })');
|
||||
expect(dtsContents)
|
||||
.toContain('static ngPipeDef: i0.\u0275\u0275PipeDefWithMeta<TestPipe, "test-pipe">;');
|
||||
expect(dtsContents).toContain('static ngPipeDef: i0.ΔPipeDefWithMeta<TestPipe, "test-pipe">;');
|
||||
});
|
||||
|
||||
it('should compile pure Pipes without errors', () => {
|
||||
|
@ -887,10 +877,9 @@ describe('ngtsc behavioral tests', () => {
|
|||
|
||||
expect(jsContents)
|
||||
.toContain(
|
||||
'TestPipe.ngPipeDef = i0.\u0275\u0275definePipe({ name: "test-pipe", type: TestPipe, ' +
|
||||
'TestPipe.ngPipeDef = i0.ΔdefinePipe({ name: "test-pipe", type: TestPipe, ' +
|
||||
'factory: function TestPipe_Factory(t) { return new (t || TestPipe)(); }, pure: true })');
|
||||
expect(dtsContents)
|
||||
.toContain('static ngPipeDef: i0.\u0275\u0275PipeDefWithMeta<TestPipe, "test-pipe">;');
|
||||
expect(dtsContents).toContain('static ngPipeDef: i0.ΔPipeDefWithMeta<TestPipe, "test-pipe">;');
|
||||
});
|
||||
|
||||
it('should compile Pipes with dependencies', () => {
|
||||
|
@ -912,8 +901,7 @@ describe('ngtsc behavioral tests', () => {
|
|||
env.driveMain();
|
||||
|
||||
const jsContents = env.getContents('test.js');
|
||||
expect(jsContents)
|
||||
.toContain('return new (t || TestPipe)(i0.\u0275\u0275directiveInject(Dep));');
|
||||
expect(jsContents).toContain('return new (t || TestPipe)(i0.ΔdirectiveInject(Dep));');
|
||||
});
|
||||
|
||||
it('should compile Pipes with generic types', () => {
|
||||
|
@ -933,7 +921,7 @@ describe('ngtsc behavioral tests', () => {
|
|||
expect(jsContents).toContain('TestPipe.ngPipeDef =');
|
||||
const dtsContents = env.getContents('test.d.ts');
|
||||
expect(dtsContents)
|
||||
.toContain('static ngPipeDef: i0.\u0275\u0275PipeDefWithMeta<TestPipe<any>, "test-pipe">;');
|
||||
.toContain('static ngPipeDef: i0.ΔPipeDefWithMeta<TestPipe<any>, "test-pipe">;');
|
||||
});
|
||||
|
||||
it('should include @Pipes in @NgModule scopes', () => {
|
||||
|
@ -959,7 +947,7 @@ describe('ngtsc behavioral tests', () => {
|
|||
const dtsContents = env.getContents('test.d.ts');
|
||||
expect(dtsContents)
|
||||
.toContain(
|
||||
'i0.\u0275\u0275NgModuleDefWithMeta<TestModule, [typeof TestPipe, typeof TestCmp], never, never>');
|
||||
'i0.ΔNgModuleDefWithMeta<TestModule, [typeof TestPipe, typeof TestCmp], never, never>');
|
||||
});
|
||||
|
||||
describe('empty and missing selectors', () => {
|
||||
|
@ -1074,7 +1062,7 @@ describe('ngtsc behavioral tests', () => {
|
|||
expect(dtsContents).toContain('ComponentDefWithMeta<TestCmp');
|
||||
expect(dtsContents).toContain('DirectiveDefWithMeta<TestDir');
|
||||
expect(dtsContents).toContain('PipeDefWithMeta<TestPipe');
|
||||
expect(dtsContents).toContain('\u0275\u0275NgModuleDefWithMeta<TestNgModule');
|
||||
expect(dtsContents).toContain('ΔNgModuleDefWithMeta<TestNgModule');
|
||||
|
||||
// Validate that each class's .d.ts declaration also has an injectable definition.
|
||||
expect(dtsContents).toContain('InjectableDef<TestCmp');
|
||||
|
@ -1299,7 +1287,7 @@ describe('ngtsc behavioral tests', () => {
|
|||
`);
|
||||
|
||||
env.driveMain();
|
||||
expect(env.getContents('test.js')).toContain('i0.\u0275\u0275pureFunction1');
|
||||
expect(env.getContents('test.js')).toContain('i0.ΔpureFunction1');
|
||||
});
|
||||
|
||||
it('should compile array literals inside function arguments', () => {
|
||||
|
@ -1321,7 +1309,7 @@ describe('ngtsc behavioral tests', () => {
|
|||
`);
|
||||
|
||||
env.driveMain();
|
||||
expect(env.getContents('test.js')).toContain('i0.\u0275\u0275pureFunction1');
|
||||
expect(env.getContents('test.js')).toContain('i0.ΔpureFunction1');
|
||||
});
|
||||
});
|
||||
|
||||
|
@ -1337,11 +1325,11 @@ describe('ngtsc behavioral tests', () => {
|
|||
`);
|
||||
|
||||
env.write('node_modules/router/index.d.ts', `
|
||||
import {ModuleWithProviders, \u0275\u0275NgModuleDefWithMeta} from '@angular/core';
|
||||
import {ModuleWithProviders, ΔNgModuleDefWithMeta} from '@angular/core';
|
||||
|
||||
declare class RouterModule {
|
||||
static forRoot(): ModuleWithProviders<RouterModule>;
|
||||
static ngModuleDef: \u0275\u0275NgModuleDefWithMeta<RouterModule, never, never, never>;
|
||||
static ngModuleDef: ΔNgModuleDefWithMeta<RouterModule, never, never, never>;
|
||||
}
|
||||
`);
|
||||
|
||||
|
@ -1353,8 +1341,7 @@ describe('ngtsc behavioral tests', () => {
|
|||
const dtsContents = env.getContents('test.d.ts');
|
||||
expect(dtsContents).toContain(`import * as i1 from "router";`);
|
||||
expect(dtsContents)
|
||||
.toContain(
|
||||
'i0.\u0275\u0275NgModuleDefWithMeta<TestModule, never, [typeof i1.RouterModule], never>');
|
||||
.toContain('i0.ΔNgModuleDefWithMeta<TestModule, never, [typeof i1.RouterModule], never>');
|
||||
});
|
||||
|
||||
it('should extract the generic type if it is provided as qualified type name', () => {
|
||||
|
@ -1379,9 +1366,9 @@ describe('ngtsc behavioral tests', () => {
|
|||
`);
|
||||
|
||||
env.write('node_modules/router/internal.d.ts', `
|
||||
import {\u0275\u0275NgModuleDefWithMeta} from '@angular/core';
|
||||
import {ΔNgModuleDefWithMeta} from '@angular/core';
|
||||
export declare class InternalRouterModule {
|
||||
static ngModuleDef: \u0275\u0275NgModuleDefWithMeta<InternalRouterModule, never, never, never>;
|
||||
static ngModuleDef: ΔNgModuleDefWithMeta<InternalRouterModule, never, never, never>;
|
||||
}
|
||||
`);
|
||||
|
||||
|
@ -1394,18 +1381,18 @@ describe('ngtsc behavioral tests', () => {
|
|||
expect(dtsContents).toContain(`import * as i1 from "router";`);
|
||||
expect(dtsContents)
|
||||
.toContain(
|
||||
'i0.\u0275\u0275NgModuleDefWithMeta<TestModule, never, [typeof i1.InternalRouterModule], never>');
|
||||
'i0.ΔNgModuleDefWithMeta<TestModule, never, [typeof i1.InternalRouterModule], never>');
|
||||
});
|
||||
|
||||
it('should not reference a constant with a ModuleWithProviders value in ngModuleDef imports',
|
||||
() => {
|
||||
env.tsconfig();
|
||||
env.write('dep.d.ts', `
|
||||
import {ModuleWithProviders, \u0275\u0275NgModuleDefWithMeta as \u0275\u0275NgModuleDefWithMeta} from '@angular/core';
|
||||
import {ModuleWithProviders, ΔNgModuleDefWithMeta as ΔNgModuleDefWithMeta} from '@angular/core';
|
||||
|
||||
export declare class DepModule {
|
||||
static forRoot(arg1: any, arg2: any): ModuleWithProviders<DepModule>;
|
||||
static ngModuleDef: \u0275\u0275NgModuleDefWithMeta<DepModule, never, never, never>;
|
||||
static ngModuleDef: ΔNgModuleDefWithMeta<DepModule, never, never, never>;
|
||||
}
|
||||
`);
|
||||
env.write('test.ts', `
|
||||
|
@ -1440,13 +1427,13 @@ describe('ngtsc behavioral tests', () => {
|
|||
`);
|
||||
|
||||
env.write('node_modules/router/index.d.ts', `
|
||||
import {ModuleWithProviders, \u0275\u0275NgModuleDefWithMeta} from '@angular/core';
|
||||
import {ModuleWithProviders, ΔNgModuleDefWithMeta} from '@angular/core';
|
||||
|
||||
export interface MyType extends ModuleWithProviders {}
|
||||
|
||||
declare class RouterModule {
|
||||
static forRoot(): (MyType)&{ngModule:RouterModule};
|
||||
static ngModuleDef: \u0275\u0275NgModuleDefWithMeta<RouterModule, never, never, never>;
|
||||
static ngModuleDef: ΔNgModuleDefWithMeta<RouterModule, never, never, never>;
|
||||
}
|
||||
`);
|
||||
|
||||
|
@ -1459,7 +1446,7 @@ describe('ngtsc behavioral tests', () => {
|
|||
expect(dtsContents).toContain(`import * as i1 from "router";`);
|
||||
expect(dtsContents)
|
||||
.toContain(
|
||||
'i0.\u0275\u0275NgModuleDefWithMeta<TestModule, never, [typeof i1.RouterModule], never>');
|
||||
'i0.ΔNgModuleDefWithMeta<TestModule, never, [typeof i1.RouterModule], never>');
|
||||
});
|
||||
|
||||
it('should unwrap a namespace imported ModuleWithProviders function if a generic type is provided for it',
|
||||
|
@ -1479,7 +1466,7 @@ describe('ngtsc behavioral tests', () => {
|
|||
|
||||
declare class RouterModule {
|
||||
static forRoot(): core.ModuleWithProviders<RouterModule>;
|
||||
static ngModuleDef: \u0275\u0275NgModuleDefWithMeta<RouterModule, never, never, never>;
|
||||
static ngModuleDef: ΔNgModuleDefWithMeta<RouterModule, never, never, never>;
|
||||
}
|
||||
`);
|
||||
|
||||
|
@ -1492,7 +1479,7 @@ describe('ngtsc behavioral tests', () => {
|
|||
expect(dtsContents).toContain(`import * as i1 from "router";`);
|
||||
expect(dtsContents)
|
||||
.toContain(
|
||||
'i0.\u0275\u0275NgModuleDefWithMeta<TestModule, never, [typeof i1.RouterModule], never>');
|
||||
'i0.ΔNgModuleDefWithMeta<TestModule, never, [typeof i1.RouterModule], never>');
|
||||
});
|
||||
|
||||
it('should inject special types according to the metadata', () => {
|
||||
|
@ -1530,7 +1517,7 @@ describe('ngtsc behavioral tests', () => {
|
|||
const jsContents = env.getContents('test.js');
|
||||
expect(jsContents)
|
||||
.toContain(
|
||||
`factory: function FooCmp_Factory(t) { return new (t || FooCmp)(i0.\u0275\u0275injectAttribute("test"), i0.\u0275\u0275directiveInject(i0.ChangeDetectorRef), i0.\u0275\u0275directiveInject(i0.ElementRef), i0.\u0275\u0275directiveInject(i0.Injector), i0.\u0275\u0275directiveInject(i0.Renderer2), i0.\u0275\u0275directiveInject(i0.TemplateRef), i0.\u0275\u0275directiveInject(i0.ViewContainerRef)); }`);
|
||||
`factory: function FooCmp_Factory(t) { return new (t || FooCmp)(i0.ΔinjectAttribute("test"), i0.ΔdirectiveInject(i0.ChangeDetectorRef), i0.ΔdirectiveInject(i0.ElementRef), i0.ΔdirectiveInject(i0.Injector), i0.ΔdirectiveInject(i0.Renderer2), i0.ΔdirectiveInject(i0.TemplateRef), i0.ΔdirectiveInject(i0.ViewContainerRef)); }`);
|
||||
});
|
||||
|
||||
it('should generate queries for components', () => {
|
||||
|
@ -1560,9 +1547,9 @@ describe('ngtsc behavioral tests', () => {
|
|||
expect(jsContents).toMatch(varRegExp('test1'));
|
||||
expect(jsContents).toMatch(varRegExp('test2'));
|
||||
expect(jsContents).toMatch(varRegExp('accessor'));
|
||||
// match `i0.\u0275\u0275contentQuery(dirIndex, _c1, true, TemplateRef)`
|
||||
// match `i0.ΔcontentQuery(dirIndex, _c1, true, TemplateRef)`
|
||||
expect(jsContents).toMatch(contentQueryRegExp('\\w+', true, 'TemplateRef'));
|
||||
// match `i0.\u0275\u0275viewQuery(_c2, true, null)`
|
||||
// match `i0.ΔviewQuery(_c2, true, null)`
|
||||
expect(jsContents).toMatch(viewQueryRegExp(true));
|
||||
});
|
||||
|
||||
|
@ -1592,10 +1579,10 @@ describe('ngtsc behavioral tests', () => {
|
|||
expect(jsContents).toMatch(varRegExp('test1'));
|
||||
expect(jsContents).toMatch(varRegExp('test2'));
|
||||
expect(jsContents).toMatch(varRegExp('accessor'));
|
||||
// match `i0.\u0275\u0275contentQuery(dirIndex, _c1, true, TemplateRef)`
|
||||
// match `i0.ΔcontentQuery(dirIndex, _c1, true, TemplateRef)`
|
||||
expect(jsContents).toMatch(contentQueryRegExp('\\w+', true, 'TemplateRef'));
|
||||
|
||||
// match `i0.\u0275\u0275viewQuery(_c2, true, null)`
|
||||
// match `i0.ΔviewQuery(_c2, true, null)`
|
||||
// Note that while ViewQuery doesn't necessarily make sense on a directive, because it doesn't
|
||||
// have a view, we still need to handle it because a component could extend the directive.
|
||||
expect(jsContents).toMatch(viewQueryRegExp(true));
|
||||
|
@ -1621,11 +1608,11 @@ describe('ngtsc behavioral tests', () => {
|
|||
|
||||
env.driveMain();
|
||||
const jsContents = env.getContents('test.js');
|
||||
// match `i0.\u0275\u0275contentQuery(dirIndex, TemplateRef, true, null)`
|
||||
// match `i0.ΔcontentQuery(dirIndex, TemplateRef, true, null)`
|
||||
expect(jsContents).toMatch(contentQueryRegExp('TemplateRef', true));
|
||||
// match `i0.\u0275\u0275contentQuery(dirIndex, ViewContainerRef, true, null)`
|
||||
// match `i0.ΔcontentQuery(dirIndex, ViewContainerRef, true, null)`
|
||||
expect(jsContents).toMatch(contentQueryRegExp('ViewContainerRef', true));
|
||||
// match `i0.\u0275\u0275contentQuery(dirIndex, _c0, true, null)`
|
||||
// match `i0.ΔcontentQuery(dirIndex, _c0, true, null)`
|
||||
expect(jsContents).toContain('_c0 = ["parens"];');
|
||||
expect(jsContents).toMatch(contentQueryRegExp('_c0', true));
|
||||
});
|
||||
|
@ -1675,9 +1662,9 @@ describe('ngtsc behavioral tests', () => {
|
|||
const hostBindingsFn = `
|
||||
hostBindings: function FooCmp_HostBindings(rf, ctx, elIndex) {
|
||||
if (rf & 1) {
|
||||
i0.\u0275\u0275listener("click", function FooCmp_click_HostBindingHandler($event) { return ctx.onClick(); });
|
||||
i0.\u0275\u0275listener("click", function FooCmp_click_HostBindingHandler($event) { return ctx.onDocumentClick($event.target); }, false, i0.\u0275\u0275resolveDocument);
|
||||
i0.\u0275\u0275listener("scroll", function FooCmp_scroll_HostBindingHandler($event) { return ctx.onWindowScroll(); }, false, i0.\u0275\u0275resolveWindow);
|
||||
i0.Δlistener("click", function FooCmp_click_HostBindingHandler($event) { return ctx.onClick(); });
|
||||
i0.Δlistener("click", function FooCmp_click_HostBindingHandler($event) { return ctx.onDocumentClick($event.target); }, false, i0.ΔresolveDocument);
|
||||
i0.Δlistener("scroll", function FooCmp_scroll_HostBindingHandler($event) { return ctx.onWindowScroll(); }, false, i0.ΔresolveWindow);
|
||||
}
|
||||
}
|
||||
`;
|
||||
|
@ -1773,17 +1760,17 @@ describe('ngtsc behavioral tests', () => {
|
|||
const hostBindingsFn = `
|
||||
hostBindings: function FooCmp_HostBindings(rf, ctx, elIndex) {
|
||||
if (rf & 1) {
|
||||
i0.\u0275\u0275allocHostVars(2);
|
||||
i0.\u0275\u0275listener("click", function FooCmp_click_HostBindingHandler($event) { return ctx.onClick($event); });
|
||||
i0.\u0275\u0275listener("click", function FooCmp_click_HostBindingHandler($event) { return ctx.onBodyClick($event); }, false, i0.\u0275\u0275resolveBody);
|
||||
i0.\u0275\u0275listener("change", function FooCmp_change_HostBindingHandler($event) { return ctx.onChange(ctx.arg1, ctx.arg2, ctx.arg3); });
|
||||
i0.\u0275\u0275styling(_c0);
|
||||
i0.ΔallocHostVars(2);
|
||||
i0.Δlistener("click", function FooCmp_click_HostBindingHandler($event) { return ctx.onClick($event); });
|
||||
i0.Δlistener("click", function FooCmp_click_HostBindingHandler($event) { return ctx.onBodyClick($event); }, false, i0.ΔresolveBody);
|
||||
i0.Δlistener("change", function FooCmp_change_HostBindingHandler($event) { return ctx.onChange(ctx.arg1, ctx.arg2, ctx.arg3); });
|
||||
i0.Δstyling(_c0);
|
||||
}
|
||||
if (rf & 2) {
|
||||
i0.\u0275\u0275elementAttribute(elIndex, "hello", i0.\u0275\u0275bind(ctx.foo));
|
||||
i0.\u0275\u0275property("prop", ctx.bar, null, true);
|
||||
i0.\u0275\u0275classProp(0, ctx.someClass);
|
||||
i0.\u0275\u0275stylingApply();
|
||||
i0.ΔelementAttribute(elIndex, "hello", i0.Δbind(ctx.foo));
|
||||
i0.Δproperty("prop", ctx.bar, null, true);
|
||||
i0.ΔclassProp(0, ctx.someClass);
|
||||
i0.ΔstylingApply();
|
||||
}
|
||||
}
|
||||
`;
|
||||
|
@ -1812,7 +1799,7 @@ describe('ngtsc behavioral tests', () => {
|
|||
`);
|
||||
env.driveMain();
|
||||
const jsContents = env.getContents('test.js');
|
||||
expect(jsContents).toContain('i0.\u0275\u0275elementHostAttrs(["test", test])');
|
||||
expect(jsContents).toContain('i0.ΔelementHostAttrs(["test", test])');
|
||||
});
|
||||
|
||||
it('should accept enum values as host bindings', () => {
|
||||
|
@ -1837,7 +1824,7 @@ describe('ngtsc behavioral tests', () => {
|
|||
`);
|
||||
|
||||
env.driveMain();
|
||||
expect(env.getContents('test.js')).toContain('"hello", i0.\u0275\u0275bind(ctx.foo)');
|
||||
expect(env.getContents('test.js')).toContain('"hello", i0.Δbind(ctx.foo)');
|
||||
});
|
||||
|
||||
it('should generate host listeners for directives within hostBindings section', () => {
|
||||
|
@ -1859,7 +1846,7 @@ describe('ngtsc behavioral tests', () => {
|
|||
const hostBindingsFn = `
|
||||
hostBindings: function Dir_HostBindings(rf, ctx, elIndex) {
|
||||
if (rf & 1) {
|
||||
i0.\u0275\u0275listener("change", function Dir_change_HostBindingHandler($event) { return ctx.onChange(ctx.arg); });
|
||||
i0.Δlistener("change", function Dir_change_HostBindingHandler($event) { return ctx.onChange(ctx.arg); });
|
||||
}
|
||||
}
|
||||
`;
|
||||
|
@ -2054,7 +2041,7 @@ describe('ngtsc behavioral tests', () => {
|
|||
`);
|
||||
env.driveMain();
|
||||
const jsContents = env.getContents('test.js');
|
||||
expect(jsContents).not.toContain('i0.\u0275\u0275elementProperty');
|
||||
expect(jsContents).not.toContain('i0.ΔelementProperty');
|
||||
});
|
||||
|
||||
it('should correctly recognize local symbols', () => {
|
||||
|
@ -2309,10 +2296,8 @@ describe('ngtsc behavioral tests', () => {
|
|||
const jsContents = env.getContents('test.js');
|
||||
|
||||
expect(jsContents)
|
||||
.toContain(
|
||||
'function Base_Factory(t) { return new (t || Base)(i0.\u0275\u0275inject(Dep)); }');
|
||||
expect(jsContents)
|
||||
.toContain('var \u0275Child_BaseFactory = i0.\u0275\u0275getInheritedFactory(Child)');
|
||||
.toContain('function Base_Factory(t) { return new (t || Base)(i0.Δinject(Dep)); }');
|
||||
expect(jsContents).toContain('var \u0275Child_BaseFactory = i0.ΔgetInheritedFactory(Child)');
|
||||
expect(jsContents)
|
||||
.toContain('function Child_Factory(t) { return \u0275Child_BaseFactory((t || Child)); }');
|
||||
expect(jsContents)
|
||||
|
@ -2337,8 +2322,7 @@ describe('ngtsc behavioral tests', () => {
|
|||
env.driveMain();
|
||||
const jsContents = env.getContents('test.js');
|
||||
|
||||
expect(jsContents)
|
||||
.toContain('var \u0275Dir_BaseFactory = i0.\u0275\u0275getInheritedFactory(Dir)');
|
||||
expect(jsContents).toContain('var \u0275Dir_BaseFactory = i0.ΔgetInheritedFactory(Dir)');
|
||||
});
|
||||
|
||||
it('should wrap "directives" in component metadata in a closure when forward references are present',
|
||||
|
@ -2479,8 +2463,8 @@ describe('ngtsc behavioral tests', () => {
|
|||
const jsContents = trim(env.getContents('test.js'));
|
||||
expect(jsContents).toContain(`import Default from './types';`);
|
||||
expect(jsContents).toContain(`import * as i1 from "./types";`);
|
||||
expect(jsContents).toContain('i0.\u0275\u0275directiveInject(Default)');
|
||||
expect(jsContents).toContain('i0.\u0275\u0275directiveInject(i1.Other)');
|
||||
expect(jsContents).toContain('i0.ΔdirectiveInject(Default)');
|
||||
expect(jsContents).toContain('i0.ΔdirectiveInject(i1.Other)');
|
||||
expect(jsContents).toMatch(setClassMetadataRegExp('type: Default'));
|
||||
expect(jsContents).toMatch(setClassMetadataRegExp('type: i1.Other'));
|
||||
});
|
||||
|
@ -2591,8 +2575,8 @@ describe('ngtsc behavioral tests', () => {
|
|||
const jsContents = env.getContents('test.js');
|
||||
expect(jsContents)
|
||||
.toMatch(
|
||||
/i\d\.\u0275\u0275setComponentScope\(NormalComponent,\s+\[NormalComponent,\s+CyclicComponent\],\s+\[\]\)/);
|
||||
expect(jsContents).not.toContain('/*__PURE__*/ i0.\u0275\u0275setComponentScope');
|
||||
/i\d\.ΔsetComponentScope\(NormalComponent,\s+\[NormalComponent,\s+CyclicComponent\],\s+\[\]\)/);
|
||||
expect(jsContents).not.toContain('/*__PURE__*/ i0.ΔsetComponentScope');
|
||||
});
|
||||
|
||||
it('should detect a cycle added entirely during compilation', () => {
|
||||
|
@ -2783,14 +2767,14 @@ describe('ngtsc behavioral tests', () => {
|
|||
it('should not emit multiple references to the same directive', () => {
|
||||
env.tsconfig();
|
||||
env.write('node_modules/external/index.d.ts', `
|
||||
import {\u0275\u0275DirectiveDefWithMeta, \u0275\u0275NgModuleDefWithMeta} from '@angular/core';
|
||||
import {ΔDirectiveDefWithMeta, ΔNgModuleDefWithMeta} from '@angular/core';
|
||||
|
||||
export declare class ExternalDir {
|
||||
static ngDirectiveDef: \u0275\u0275DirectiveDefWithMeta<ExternalDir, '[test]', never, never, never, never>;
|
||||
static ngDirectiveDef: ΔDirectiveDefWithMeta<ExternalDir, '[test]', never, never, never, never>;
|
||||
}
|
||||
|
||||
export declare class ExternalModule {
|
||||
static ngModuleDef: \u0275\u0275NgModuleDefWithMeta<ExternalModule, [typeof ExternalDir], never, [typeof ExternalDir]>;
|
||||
static ngModuleDef: ΔNgModuleDefWithMeta<ExternalModule, [typeof ExternalDir], never, [typeof ExternalDir]>;
|
||||
}
|
||||
`);
|
||||
env.write('test.ts', `
|
||||
|
@ -2819,19 +2803,19 @@ describe('ngtsc behavioral tests', () => {
|
|||
it('should import directives by their external name', () => {
|
||||
env.tsconfig();
|
||||
env.write('node_modules/external/index.d.ts', `
|
||||
import {\u0275\u0275DirectiveDefWithMeta, \u0275\u0275NgModuleDefWithMeta} from '@angular/core';
|
||||
import {ΔDirectiveDefWithMeta, ΔNgModuleDefWithMeta} from '@angular/core';
|
||||
import {InternalDir} from './internal';
|
||||
|
||||
export {InternalDir as ExternalDir} from './internal';
|
||||
|
||||
export declare class ExternalModule {
|
||||
static ngModuleDef: \u0275\u0275NgModuleDefWithMeta<ExternalModule, [typeof InternalDir], never, [typeof InternalDir]>;
|
||||
static ngModuleDef: ΔNgModuleDefWithMeta<ExternalModule, [typeof InternalDir], never, [typeof InternalDir]>;
|
||||
}
|
||||
`);
|
||||
env.write('node_modules/external/internal.d.ts', `
|
||||
|
||||
export declare class InternalDir {
|
||||
static ngDirectiveDef: \u0275\u0275DirectiveDefWithMeta<InternalDir, '[test]', never, never, never, never>;
|
||||
static ngDirectiveDef: ΔDirectiveDefWithMeta<InternalDir, '[test]', never, never, never, never>;
|
||||
}
|
||||
`);
|
||||
env.write('test.ts', `
|
||||
|
@ -3040,14 +3024,14 @@ describe('ngtsc behavioral tests', () => {
|
|||
export class Module {}
|
||||
`);
|
||||
env.write('node_modules/external/index.d.ts', `
|
||||
import {\u0275\u0275DirectiveDefWithMeta, \u0275\u0275NgModuleDefWithMeta} from '@angular/core';
|
||||
import {ΔDirectiveDefWithMeta, ΔNgModuleDefWithMeta} from '@angular/core';
|
||||
|
||||
export declare class ExternalDir {
|
||||
static ngDirectiveDef: \u0275\u0275DirectiveDefWithMeta<ExternalDir, '[test]', never, never, never, never>;
|
||||
static ngDirectiveDef: ΔDirectiveDefWithMeta<ExternalDir, '[test]', never, never, never, never>;
|
||||
}
|
||||
|
||||
export declare class ExternalModule {
|
||||
static ngModuleDef: \u0275\u0275NgModuleDefWithMeta<ExternalModule, [typeof ExternalDir], never, [typeof ExternalDir]>;
|
||||
static ngModuleDef: ΔNgModuleDefWithMeta<ExternalModule, [typeof ExternalDir], never, [typeof ExternalDir]>;
|
||||
}
|
||||
`);
|
||||
|
||||
|
@ -3227,15 +3211,15 @@ describe('ngtsc behavioral tests', () => {
|
|||
const hostBindingsFn = `
|
||||
hostBindings: function UnsafeAttrsDirective_HostBindings(rf, ctx, elIndex) {
|
||||
if (rf & 1) {
|
||||
i0.\u0275\u0275allocHostVars(6);
|
||||
i0.ΔallocHostVars(6);
|
||||
}
|
||||
if (rf & 2) {
|
||||
i0.\u0275\u0275elementAttribute(elIndex, "href", i0.\u0275\u0275bind(ctx.attrHref), i0.\u0275\u0275sanitizeUrlOrResourceUrl);
|
||||
i0.\u0275\u0275elementAttribute(elIndex, "src", i0.\u0275\u0275bind(ctx.attrSrc), i0.\u0275\u0275sanitizeUrlOrResourceUrl);
|
||||
i0.\u0275\u0275elementAttribute(elIndex, "action", i0.\u0275\u0275bind(ctx.attrAction), i0.\u0275\u0275sanitizeUrl);
|
||||
i0.\u0275\u0275elementAttribute(elIndex, "profile", i0.\u0275\u0275bind(ctx.attrProfile), i0.\u0275\u0275sanitizeResourceUrl);
|
||||
i0.\u0275\u0275elementAttribute(elIndex, "innerHTML", i0.\u0275\u0275bind(ctx.attrInnerHTML), i0.\u0275\u0275sanitizeHtml);
|
||||
i0.\u0275\u0275elementAttribute(elIndex, "title", i0.\u0275\u0275bind(ctx.attrSafeTitle));
|
||||
i0.ΔelementAttribute(elIndex, "href", i0.Δbind(ctx.attrHref), i0.ΔsanitizeUrlOrResourceUrl);
|
||||
i0.ΔelementAttribute(elIndex, "src", i0.Δbind(ctx.attrSrc), i0.ΔsanitizeUrlOrResourceUrl);
|
||||
i0.ΔelementAttribute(elIndex, "action", i0.Δbind(ctx.attrAction), i0.ΔsanitizeUrl);
|
||||
i0.ΔelementAttribute(elIndex, "profile", i0.Δbind(ctx.attrProfile), i0.ΔsanitizeResourceUrl);
|
||||
i0.ΔelementAttribute(elIndex, "innerHTML", i0.Δbind(ctx.attrInnerHTML), i0.ΔsanitizeHtml);
|
||||
i0.ΔelementAttribute(elIndex, "title", i0.Δbind(ctx.attrSafeTitle));
|
||||
}
|
||||
}
|
||||
`;
|
||||
|
@ -3282,15 +3266,15 @@ describe('ngtsc behavioral tests', () => {
|
|||
const hostBindingsFn = `
|
||||
hostBindings: function UnsafePropsDirective_HostBindings(rf, ctx, elIndex) {
|
||||
if (rf & 1) {
|
||||
i0.\u0275\u0275allocHostVars(6);
|
||||
i0.ΔallocHostVars(6);
|
||||
}
|
||||
if (rf & 2) {
|
||||
i0.\u0275\u0275property("href", ctx.propHref, i0.\u0275\u0275sanitizeUrlOrResourceUrl, true);
|
||||
i0.\u0275\u0275property("src", ctx.propSrc, i0.\u0275\u0275sanitizeUrlOrResourceUrl, true);
|
||||
i0.\u0275\u0275property("action", ctx.propAction, i0.\u0275\u0275sanitizeUrl, true);
|
||||
i0.\u0275\u0275property("profile", ctx.propProfile, i0.\u0275\u0275sanitizeResourceUrl, true);
|
||||
i0.\u0275\u0275property("innerHTML", ctx.propInnerHTML, i0.\u0275\u0275sanitizeHtml, true);
|
||||
i0.\u0275\u0275property("title", ctx.propSafeTitle, null, true);
|
||||
i0.Δproperty("href", ctx.propHref, i0.ΔsanitizeUrlOrResourceUrl, true);
|
||||
i0.Δproperty("src", ctx.propSrc, i0.ΔsanitizeUrlOrResourceUrl, true);
|
||||
i0.Δproperty("action", ctx.propAction, i0.ΔsanitizeUrl, true);
|
||||
i0.Δproperty("profile", ctx.propProfile, i0.ΔsanitizeResourceUrl, true);
|
||||
i0.Δproperty("innerHTML", ctx.propInnerHTML, i0.ΔsanitizeHtml, true);
|
||||
i0.Δproperty("title", ctx.propSafeTitle, null, true);
|
||||
}
|
||||
}
|
||||
`;
|
||||
|
@ -3322,15 +3306,15 @@ describe('ngtsc behavioral tests', () => {
|
|||
const hostBindingsFn = `
|
||||
hostBindings: function FooCmp_HostBindings(rf, ctx, elIndex) {
|
||||
if (rf & 1) {
|
||||
i0.\u0275\u0275allocHostVars(6);
|
||||
i0.ΔallocHostVars(6);
|
||||
}
|
||||
if (rf & 2) {
|
||||
i0.\u0275\u0275property("src", ctx.srcProp, null, true);
|
||||
i0.\u0275\u0275property("href", ctx.hrefProp, null, true);
|
||||
i0.\u0275\u0275property("title", ctx.titleProp, null, true);
|
||||
i0.\u0275\u0275elementAttribute(elIndex, "src", i0.\u0275\u0275bind(ctx.srcAttr));
|
||||
i0.\u0275\u0275elementAttribute(elIndex, "href", i0.\u0275\u0275bind(ctx.hrefAttr));
|
||||
i0.\u0275\u0275elementAttribute(elIndex, "title", i0.\u0275\u0275bind(ctx.titleAttr));
|
||||
i0.Δproperty("src", ctx.srcProp, null, true);
|
||||
i0.Δproperty("href", ctx.hrefProp, null, true);
|
||||
i0.Δproperty("title", ctx.titleProp, null, true);
|
||||
i0.ΔelementAttribute(elIndex, "src", i0.Δbind(ctx.srcAttr));
|
||||
i0.ΔelementAttribute(elIndex, "href", i0.Δbind(ctx.hrefAttr));
|
||||
i0.ΔelementAttribute(elIndex, "title", i0.Δbind(ctx.titleAttr));
|
||||
}
|
||||
}
|
||||
`;
|
||||
|
@ -3360,13 +3344,13 @@ describe('ngtsc behavioral tests', () => {
|
|||
beforeEach(() => {
|
||||
env.tsconfig();
|
||||
env.write('node_modules/@angular/router/index.d.ts', `
|
||||
import {ModuleWithProviders, \u0275\u0275NgModuleDefWithMeta as \u0275\u0275NgModuleDefWithMeta} from '@angular/core';
|
||||
import {ModuleWithProviders, ΔNgModuleDefWithMeta as ΔNgModuleDefWithMeta} from '@angular/core';
|
||||
|
||||
export declare var ROUTES;
|
||||
export declare class RouterModule {
|
||||
static forRoot(arg1: any, arg2: any): ModuleWithProviders<RouterModule>;
|
||||
static forChild(arg1: any): ModuleWithProviders<RouterModule>;
|
||||
static ngModuleDef: \u0275\u0275NgModuleDefWithMeta<RouterModule, never, never, never>;
|
||||
static ngModuleDef: ΔNgModuleDefWithMeta<RouterModule, never, never, never>;
|
||||
}
|
||||
`);
|
||||
});
|
||||
|
@ -3996,24 +3980,24 @@ export const Foo = Foo__PRE_R3__;
|
|||
|
||||
// 'alpha' declares the directive which will ultimately be imported.
|
||||
env.write('alpha.d.ts', `
|
||||
import {\u0275\u0275DirectiveDefWithMeta, \u0275\u0275NgModuleDefWithMeta} from '@angular/core';
|
||||
import {ΔDirectiveDefWithMeta, ΔNgModuleDefWithMeta} from '@angular/core';
|
||||
|
||||
export declare class ExternalDir {
|
||||
static ngDirectiveDef: \u0275\u0275DirectiveDefWithMeta<ExternalDir, '[test]', never, never, never, never>;
|
||||
static ngDirectiveDef: ΔDirectiveDefWithMeta<ExternalDir, '[test]', never, never, never, never>;
|
||||
}
|
||||
|
||||
export declare class AlphaModule {
|
||||
static ngModuleDef: \u0275\u0275NgModuleDefWithMeta<AlphaModule, [typeof ExternalDir], never, [typeof ExternalDir]>;
|
||||
static ngModuleDef: ΔNgModuleDefWithMeta<AlphaModule, [typeof ExternalDir], never, [typeof ExternalDir]>;
|
||||
}
|
||||
`);
|
||||
|
||||
// 'beta' re-exports AlphaModule from alpha.
|
||||
env.write('beta.d.ts', `
|
||||
import {\u0275\u0275NgModuleDefWithMeta} from '@angular/core';
|
||||
import {ΔNgModuleDefWithMeta} from '@angular/core';
|
||||
import {AlphaModule} from './alpha';
|
||||
|
||||
export declare class BetaModule {
|
||||
static ngModuleDef: \u0275\u0275NgModuleDefWithMeta<AlphaModule, never, never, [typeof AlphaModule]>;
|
||||
static ngModuleDef: ΔNgModuleDefWithMeta<AlphaModule, never, never, [typeof AlphaModule]>;
|
||||
}
|
||||
`);
|
||||
|
||||
|
@ -4045,26 +4029,26 @@ export const Foo = Foo__PRE_R3__;
|
|||
it('should write alias ES2015 exports for NgModule exported directives', () => {
|
||||
env.tsconfig({'_useHostForImportGeneration': true});
|
||||
env.write('external.d.ts', `
|
||||
import {\u0275\u0275DirectiveDefWithMeta, \u0275\u0275NgModuleDefWithMeta} from '@angular/core';
|
||||
import {ΔDirectiveDefWithMeta, ΔNgModuleDefWithMeta} from '@angular/core';
|
||||
import {LibModule} from './lib';
|
||||
|
||||
export declare class ExternalDir {
|
||||
static ngDirectiveDef: \u0275\u0275DirectiveDefWithMeta<ExternalDir, '[test]', never, never, never, never>;
|
||||
static ngDirectiveDef: ΔDirectiveDefWithMeta<ExternalDir, '[test]', never, never, never, never>;
|
||||
}
|
||||
|
||||
export declare class ExternalModule {
|
||||
static ngModuleDef: \u0275\u0275NgModuleDefWithMeta<ExternalModule, [typeof ExternalDir], never, [typeof ExternalDir, typeof LibModule]>;
|
||||
static ngModuleDef: ΔNgModuleDefWithMeta<ExternalModule, [typeof ExternalDir], never, [typeof ExternalDir, typeof LibModule]>;
|
||||
}
|
||||
`);
|
||||
env.write('lib.d.ts', `
|
||||
import {\u0275\u0275DirectiveDefWithMeta, \u0275\u0275NgModuleDefWithMeta} from '@angular/core';
|
||||
import {ΔDirectiveDefWithMeta, ΔNgModuleDefWithMeta} from '@angular/core';
|
||||
|
||||
export declare class LibDir {
|
||||
static ngDirectiveDef: \u0275\u0275DirectiveDefWithMeta<LibDir, '[lib]', never, never, never, never>;
|
||||
static ngDirectiveDef: ΔDirectiveDefWithMeta<LibDir, '[lib]', never, never, never, never>;
|
||||
}
|
||||
|
||||
export declare class LibModule {
|
||||
static ngModuleDef: \u0275\u0275NgModuleDefWithMeta<LibModule, [typeof LibDir], never, [typeof LibDir]>;
|
||||
static ngModuleDef: ΔNgModuleDefWithMeta<LibModule, [typeof LibDir], never, [typeof LibDir]>;
|
||||
}
|
||||
`);
|
||||
env.write('foo.ts', `
|
||||
|
|
|
@ -36,15 +36,15 @@ describe('ngtsc module scopes', () => {
|
|||
env.driveMain();
|
||||
|
||||
const jsContents = env.getContents('test.js');
|
||||
expect(jsContents).toContain('i0.ɵɵdefineNgModule({ type: TestModule });');
|
||||
expect(jsContents).toContain('i0.ΔdefineNgModule({ type: TestModule });');
|
||||
expect(jsContents)
|
||||
.toContain(
|
||||
'/*@__PURE__*/ i0.ɵɵsetNgModuleScope(TestModule, { imports: [OtherModule] });');
|
||||
'/*@__PURE__*/ i0.ΔsetNgModuleScope(TestModule, { imports: [OtherModule] });');
|
||||
|
||||
const dtsContents = env.getContents('test.d.ts');
|
||||
expect(dtsContents)
|
||||
.toContain(
|
||||
'static ngModuleDef: i0.ɵɵNgModuleDefWithMeta<TestModule, never, [typeof OtherModule], never>');
|
||||
'static ngModuleDef: i0.ΔNgModuleDefWithMeta<TestModule, never, [typeof OtherModule], never>');
|
||||
});
|
||||
|
||||
it('should produce an error when an invalid class is imported', () => {
|
||||
|
@ -98,15 +98,15 @@ describe('ngtsc module scopes', () => {
|
|||
env.driveMain();
|
||||
|
||||
const jsContents = env.getContents('test.js');
|
||||
expect(jsContents).toContain('i0.ɵɵdefineNgModule({ type: TestModule });');
|
||||
expect(jsContents).toContain('i0.ΔdefineNgModule({ type: TestModule });');
|
||||
expect(jsContents)
|
||||
.toContain(
|
||||
'/*@__PURE__*/ i0.ɵɵsetNgModuleScope(TestModule, { exports: [OtherModule] });');
|
||||
'/*@__PURE__*/ i0.ΔsetNgModuleScope(TestModule, { exports: [OtherModule] });');
|
||||
|
||||
const dtsContents = env.getContents('test.d.ts');
|
||||
expect(dtsContents)
|
||||
.toContain(
|
||||
'static ngModuleDef: i0.ɵɵNgModuleDefWithMeta<TestModule, never, never, [typeof OtherModule]>');
|
||||
'static ngModuleDef: i0.ΔNgModuleDefWithMeta<TestModule, never, never, [typeof OtherModule]>');
|
||||
});
|
||||
|
||||
it('should produce an error when a non-NgModule class is exported', () => {
|
||||
|
|
|
@ -23,17 +23,17 @@ describe('template source-mapping', () => {
|
|||
it('should map simple element with content', () => {
|
||||
const mappings = compileAndMap('<h1>Heading 1</h1>');
|
||||
expect(mappings).toContain(
|
||||
{source: '<h1>', generated: 'i0.ɵɵelementStart(0, "h1")', sourceUrl: '../test.ts'});
|
||||
{source: '<h1>', generated: 'i0.ΔelementStart(0, "h1")', sourceUrl: '../test.ts'});
|
||||
expect(mappings).toContain(
|
||||
{source: 'Heading 1', generated: 'i0.ɵɵtext(1, "Heading 1")', sourceUrl: '../test.ts'});
|
||||
{source: 'Heading 1', generated: 'i0.Δtext(1, "Heading 1")', sourceUrl: '../test.ts'});
|
||||
expect(mappings).toContain(
|
||||
{source: '</h1>', generated: 'i0.ɵɵelementEnd()', sourceUrl: '../test.ts'});
|
||||
{source: '</h1>', generated: 'i0.ΔelementEnd()', sourceUrl: '../test.ts'});
|
||||
});
|
||||
|
||||
it('should map void element', () => {
|
||||
const mappings = compileAndMap('<hr>');
|
||||
expect(mappings).toContain(
|
||||
{source: '<hr>', generated: 'i0.ɵɵelement(0, "hr")', sourceUrl: '../test.ts'});
|
||||
{source: '<hr>', generated: 'i0.Δelement(0, "hr")', sourceUrl: '../test.ts'});
|
||||
});
|
||||
});
|
||||
|
||||
|
@ -41,40 +41,40 @@ describe('template source-mapping', () => {
|
|||
it('should map a mix of interpolated and static content', () => {
|
||||
const mappings = compileAndMap('<h3>Hello {{ name }}</h3>');
|
||||
expect(mappings).toContain(
|
||||
{source: '<h3>', generated: 'i0.ɵɵelementStart(0, "h3")', sourceUrl: '../test.ts'});
|
||||
{source: '<h3>', generated: 'i0.ΔelementStart(0, "h3")', sourceUrl: '../test.ts'});
|
||||
expect(mappings).toContain({
|
||||
source: 'Hello {{ name }}',
|
||||
generated: 'i0.ɵɵtextBinding(1, i0.ɵɵinterpolation1("Hello ", ctx.name, ""))',
|
||||
generated: 'i0.ΔtextBinding(1, i0.Δinterpolation1("Hello ", ctx.name, ""))',
|
||||
sourceUrl: '../test.ts'
|
||||
});
|
||||
expect(mappings).toContain(
|
||||
{source: '</h3>', generated: 'i0.ɵɵelementEnd()', sourceUrl: '../test.ts'});
|
||||
{source: '</h3>', generated: 'i0.ΔelementEnd()', sourceUrl: '../test.ts'});
|
||||
});
|
||||
|
||||
it('should map a complex interpolated expression', () => {
|
||||
const mappings = compileAndMap('<h2>{{ greeting + " " + name }}</h2>');
|
||||
expect(mappings).toContain(
|
||||
{source: '<h2>', generated: 'i0.ɵɵelementStart(0, "h2")', sourceUrl: '../test.ts'});
|
||||
{source: '<h2>', generated: 'i0.ΔelementStart(0, "h2")', sourceUrl: '../test.ts'});
|
||||
expect(mappings).toContain({
|
||||
source: '{{ greeting + " " + name }}',
|
||||
generated:
|
||||
'i0.ɵɵtextBinding(1, i0.ɵɵinterpolation1("", ((ctx.greeting + " ") + ctx.name), ""))',
|
||||
'i0.ΔtextBinding(1, i0.Δinterpolation1("", ((ctx.greeting + " ") + ctx.name), ""))',
|
||||
sourceUrl: '../test.ts'
|
||||
});
|
||||
expect(mappings).toContain(
|
||||
{source: '</h2>', generated: 'i0.ɵɵelementEnd()', sourceUrl: '../test.ts'});
|
||||
{source: '</h2>', generated: 'i0.ΔelementEnd()', sourceUrl: '../test.ts'});
|
||||
});
|
||||
|
||||
it('should map interpolated properties', () => {
|
||||
const mappings = compileAndMap('<div id="{{name}}"></div>');
|
||||
expect(mappings).toContain({
|
||||
source: '<div id="{{name}}"></div>',
|
||||
generated: 'i0.ɵɵelement(0, "div", _c0)',
|
||||
generated: 'i0.Δelement(0, "div", _c0)',
|
||||
sourceUrl: '../test.ts'
|
||||
});
|
||||
expect(mappings).toContain({
|
||||
source: 'id="{{name}}"',
|
||||
generated: 'i0.ɵɵpropertyInterpolate("id", ctx.name)',
|
||||
generated: 'i0.ΔpropertyInterpolate("id", ctx.name)',
|
||||
sourceUrl: '../test.ts'
|
||||
});
|
||||
});
|
||||
|
@ -82,15 +82,15 @@ describe('template source-mapping', () => {
|
|||
it('should map interpolation with pipe', () => {
|
||||
const mappings = compileAndMap('<div>{{200.3 | percent : 2 }}</div>');
|
||||
expect(mappings).toContain(
|
||||
{source: '<div>', generated: 'i0.ɵɵelementStart(0, "div")', sourceUrl: '../test.ts'});
|
||||
{source: '<div>', generated: 'i0.ΔelementStart(0, "div")', sourceUrl: '../test.ts'});
|
||||
expect(mappings).toContain({
|
||||
source: '{{200.3 | percent : 2 }}',
|
||||
generated:
|
||||
'i0.ɵɵtextBinding(1, i0.ɵɵinterpolation1("", i0.ɵɵpipeBind2(2, 1, 200.3, 2), ""))',
|
||||
'i0.ΔtextBinding(1, i0.Δinterpolation1("", i0.ΔpipeBind2(2, 1, 200.3, 2), ""))',
|
||||
sourceUrl: '../test.ts'
|
||||
});
|
||||
expect(mappings).toContain(
|
||||
{source: '</div>', generated: 'i0.ɵɵelementEnd()', sourceUrl: '../test.ts'});
|
||||
{source: '</div>', generated: 'i0.ΔelementEnd()', sourceUrl: '../test.ts'});
|
||||
});
|
||||
});
|
||||
|
||||
|
@ -99,12 +99,12 @@ describe('template source-mapping', () => {
|
|||
const mappings = compileAndMap('<div [attr]="name"></div>');
|
||||
expect(mappings).toContain({
|
||||
source: '<div [attr]="name"></div>',
|
||||
generated: 'i0.ɵɵelement(0, "div", _c0)',
|
||||
generated: 'i0.Δelement(0, "div", _c0)',
|
||||
sourceUrl: '../test.ts'
|
||||
});
|
||||
expect(mappings).toContain({
|
||||
source: '[attr]="name"',
|
||||
generated: 'i0.ɵɵproperty("attr", ctx.name)',
|
||||
generated: 'i0.Δproperty("attr", ctx.name)',
|
||||
sourceUrl: '../test.ts'
|
||||
});
|
||||
});
|
||||
|
@ -114,12 +114,12 @@ describe('template source-mapping', () => {
|
|||
|
||||
expect(mappings).toContain({
|
||||
source: '<div [attr]="greeting + name"></div>',
|
||||
generated: 'i0.ɵɵelement(0, "div", _c0)',
|
||||
generated: 'i0.Δelement(0, "div", _c0)',
|
||||
sourceUrl: '../test.ts'
|
||||
});
|
||||
expect(mappings).toContain({
|
||||
source: '[attr]="greeting + name"',
|
||||
generated: 'i0.ɵɵproperty("attr", (ctx.greeting + ctx.name))',
|
||||
generated: 'i0.Δproperty("attr", (ctx.greeting + ctx.name))',
|
||||
sourceUrl: '../test.ts'
|
||||
});
|
||||
});
|
||||
|
@ -128,12 +128,12 @@ describe('template source-mapping', () => {
|
|||
const mappings = compileAndMap('<div bind-attr="name"></div>');
|
||||
expect(mappings).toContain({
|
||||
source: '<div bind-attr="name"></div>',
|
||||
generated: 'i0.ɵɵelement(0, "div", _c0)',
|
||||
generated: 'i0.Δelement(0, "div", _c0)',
|
||||
sourceUrl: '../test.ts'
|
||||
});
|
||||
expect(mappings).toContain({
|
||||
source: 'bind-attr="name"',
|
||||
generated: 'i0.ɵɵproperty("attr", ctx.name)',
|
||||
generated: 'i0.Δproperty("attr", ctx.name)',
|
||||
sourceUrl: '../test.ts'
|
||||
});
|
||||
});
|
||||
|
@ -142,15 +142,15 @@ describe('template source-mapping', () => {
|
|||
const mappings = compileAndMap('<button (click)="doSomething()">Do it</button>');
|
||||
expect(mappings).toContain({
|
||||
source: '<button (click)="doSomething()">',
|
||||
generated: 'i0.ɵɵelementStart(0, "button", _c0)',
|
||||
generated: 'i0.ΔelementStart(0, "button", _c0)',
|
||||
sourceUrl: '../test.ts'
|
||||
});
|
||||
expect(mappings).toContain(
|
||||
{source: 'Do it', generated: 'i0.ɵɵtext(1, "Do it")', sourceUrl: '../test.ts'});
|
||||
{source: 'Do it', generated: 'i0.Δtext(1, "Do it")', sourceUrl: '../test.ts'});
|
||||
expect(mappings).toContain(
|
||||
{source: 'doSomething()', generated: 'ctx.doSomething()', sourceUrl: '../test.ts'});
|
||||
expect(mappings).toContain(
|
||||
{source: '</button>', generated: 'i0.ɵɵelementEnd()', sourceUrl: '../test.ts'});
|
||||
{source: '</button>', generated: 'i0.ΔelementEnd()', sourceUrl: '../test.ts'});
|
||||
});
|
||||
|
||||
it('should map a complex output binding expression', () => {
|
||||
|
@ -158,11 +158,11 @@ describe('template source-mapping', () => {
|
|||
compileAndMap(`<button (click)="items.push('item' + items.length)">Add Item</button>`);
|
||||
expect(mappings).toContain({
|
||||
source: `<button (click)="items.push('item' + items.length)">`,
|
||||
generated: 'i0.ɵɵelementStart(0, "button", _c0)',
|
||||
generated: 'i0.ΔelementStart(0, "button", _c0)',
|
||||
sourceUrl: '../test.ts'
|
||||
});
|
||||
expect(mappings).toContain(
|
||||
{source: 'Add Item', generated: 'i0.ɵɵtext(1, "Add Item")', sourceUrl: '../test.ts'});
|
||||
{source: 'Add Item', generated: 'i0.Δtext(1, "Add Item")', sourceUrl: '../test.ts'});
|
||||
expect(mappings).toContain(
|
||||
{source: 'items.push(', generated: 'ctx.items.push((', sourceUrl: '../test.ts'});
|
||||
expect(mappings).toContain(
|
||||
|
@ -173,41 +173,41 @@ describe('template source-mapping', () => {
|
|||
sourceUrl: '../test.ts'
|
||||
});
|
||||
expect(mappings).toContain(
|
||||
{source: '</button>', generated: 'i0.ɵɵelementEnd()', sourceUrl: '../test.ts'});
|
||||
{source: '</button>', generated: 'i0.ΔelementEnd()', sourceUrl: '../test.ts'});
|
||||
});
|
||||
|
||||
it('should map a longhand output binding expression', () => {
|
||||
const mappings = compileAndMap('<button on-click="doSomething()">Do it</button>');
|
||||
expect(mappings).toContain({
|
||||
source: '<button on-click="doSomething()">',
|
||||
generated: 'i0.ɵɵelementStart(0, "button", _c0)',
|
||||
generated: 'i0.ΔelementStart(0, "button", _c0)',
|
||||
sourceUrl: '../test.ts'
|
||||
});
|
||||
expect(mappings).toContain(
|
||||
{source: 'Do it', generated: 'i0.ɵɵtext(1, "Do it")', sourceUrl: '../test.ts'});
|
||||
{source: 'Do it', generated: 'i0.Δtext(1, "Do it")', sourceUrl: '../test.ts'});
|
||||
expect(mappings).toContain(
|
||||
{source: 'doSomething()', generated: 'ctx.doSomething()', sourceUrl: '../test.ts'});
|
||||
expect(mappings).toContain(
|
||||
{source: '</button>', generated: 'i0.ɵɵelementEnd()', sourceUrl: '../test.ts'});
|
||||
{source: '</button>', generated: 'i0.ΔelementEnd()', sourceUrl: '../test.ts'});
|
||||
});
|
||||
|
||||
it('should map a two-way binding expression', () => {
|
||||
const mappings = compileAndMap('Name: <input [(ngModel)]="name">');
|
||||
expect(mappings).toContain({
|
||||
source: '<input [(ngModel)]="name">',
|
||||
generated: 'i0.ɵɵelementStart(1, "input", _c0)',
|
||||
generated: 'i0.ΔelementStart(1, "input", _c0)',
|
||||
sourceUrl: '../test.ts'
|
||||
});
|
||||
// TODO: improve mappings here
|
||||
expect(mappings).toContain({
|
||||
source: '[(ngModel)]="name"',
|
||||
generated:
|
||||
'i0.ɵɵlistener("ngModelChange", function TestCmp_Template_input_ngModelChange_1_listener($event) { return ctx.name = $event; })',
|
||||
'i0.Δlistener("ngModelChange", function TestCmp_Template_input_ngModelChange_1_listener($event) { return ctx.name = $event; })',
|
||||
sourceUrl: '../test.ts'
|
||||
});
|
||||
expect(mappings).toContain({
|
||||
source: '<input [(ngModel)]="name">',
|
||||
generated: 'i0.ɵɵelementEnd()',
|
||||
generated: 'i0.ΔelementEnd()',
|
||||
sourceUrl: '../test.ts'
|
||||
});
|
||||
});
|
||||
|
@ -216,19 +216,19 @@ describe('template source-mapping', () => {
|
|||
const mappings = compileAndMap('Name: <input bindon-ngModel="name">');
|
||||
expect(mappings).toContain({
|
||||
source: '<input bindon-ngModel="name">',
|
||||
generated: 'i0.ɵɵelementStart(1, "input", _c0)',
|
||||
generated: 'i0.ΔelementStart(1, "input", _c0)',
|
||||
sourceUrl: '../test.ts'
|
||||
});
|
||||
// TODO: improve mappings here
|
||||
expect(mappings).toContain({
|
||||
source: 'bindon-ngModel="name"',
|
||||
generated:
|
||||
'i0.ɵɵlistener("ngModelChange", function TestCmp_Template_input_ngModelChange_1_listener($event) { return ctx.name = $event; })',
|
||||
'i0.Δlistener("ngModelChange", function TestCmp_Template_input_ngModelChange_1_listener($event) { return ctx.name = $event; })',
|
||||
sourceUrl: '../test.ts'
|
||||
});
|
||||
expect(mappings).toContain({
|
||||
source: '<input bindon-ngModel="name">',
|
||||
generated: 'i0.ɵɵelementEnd()',
|
||||
generated: 'i0.ΔelementEnd()',
|
||||
sourceUrl: '../test.ts'
|
||||
});
|
||||
});
|
||||
|
@ -237,17 +237,17 @@ describe('template source-mapping', () => {
|
|||
const mappings = compileAndMap('<div [class.initial]="isInitial">Message</div>');
|
||||
expect(mappings).toContain({
|
||||
source: '<div [class.initial]="isInitial">',
|
||||
generated: 'i0.ɵɵelementStart(0, "div")',
|
||||
generated: 'i0.ΔelementStart(0, "div")',
|
||||
sourceUrl: '../test.ts'
|
||||
});
|
||||
|
||||
// TODO: Add better mappings for binding
|
||||
|
||||
expect(mappings).toContain(
|
||||
{source: 'Message', generated: 'i0.ɵɵtext(1, "Message")', sourceUrl: '../test.ts'});
|
||||
{source: 'Message', generated: 'i0.Δtext(1, "Message")', sourceUrl: '../test.ts'});
|
||||
|
||||
expect(mappings).toContain(
|
||||
{source: '</div>', generated: 'i0.ɵɵelementEnd()', sourceUrl: '../test.ts'});
|
||||
{source: '</div>', generated: 'i0.ΔelementEnd()', sourceUrl: '../test.ts'});
|
||||
});
|
||||
});
|
||||
|
||||
|
@ -257,20 +257,20 @@ describe('template source-mapping', () => {
|
|||
|
||||
expect(mappings).toContain({
|
||||
source: '<div *ngIf="showMessage()">',
|
||||
generated: 'i0.ɵɵelementStart(0, "div")',
|
||||
generated: 'i0.ΔelementStart(0, "div")',
|
||||
sourceUrl: '../test.ts'
|
||||
});
|
||||
|
||||
// TODO - map the bindings better
|
||||
|
||||
expect(mappings).toContain(
|
||||
{source: '</div>', generated: 'i0.ɵɵelementEnd()', sourceUrl: '../test.ts'});
|
||||
{source: '</div>', generated: 'i0.ΔelementEnd()', sourceUrl: '../test.ts'});
|
||||
|
||||
// TODO: the `ctx_r...` appears to be dependent upon previous tests!!!
|
||||
|
||||
// expect(mappings).toContain({
|
||||
// source: '{{ name }}',
|
||||
// generated: 'i0.ɵɵtextBinding(1, i0.ɵɵinterpolation1("", ctx_r0.name, ""))',
|
||||
// generated: 'i0.ΔtextBinding(1, i0.Δinterpolation1("", ctx_r0.name, ""))',
|
||||
// sourceUrl: '../test.ts'
|
||||
// });
|
||||
});
|
||||
|
@ -283,18 +283,18 @@ describe('template source-mapping', () => {
|
|||
`</ng-template>`);
|
||||
|
||||
expect(mappings).toContain(
|
||||
{source: '<div>', generated: 'i0.ɵɵelementStart(0, "div")', sourceUrl: '../test.ts'});
|
||||
{source: '<div>', generated: 'i0.ΔelementStart(0, "div")', sourceUrl: '../test.ts'});
|
||||
|
||||
// TODO - map the bindings better
|
||||
|
||||
expect(mappings).toContain(
|
||||
{source: '</div>', generated: 'i0.ɵɵelementEnd()', sourceUrl: '../test.ts'});
|
||||
{source: '</div>', generated: 'i0.ΔelementEnd()', sourceUrl: '../test.ts'});
|
||||
|
||||
// TODO: the `ctx_r...` appears to be dependent upon previous tests!!!
|
||||
|
||||
// expect(mappings).toContain({
|
||||
// source: '{{ name }}',
|
||||
// generated: 'i0.ɵɵtextBinding(1, i0.ɵɵinterpolation1("", ctx_r0.name, ""))',
|
||||
// generated: 'i0.ΔtextBinding(1, i0.Δinterpolation1("", ctx_r0.name, ""))',
|
||||
// sourceUrl: '../test.ts'
|
||||
// });
|
||||
});
|
||||
|
@ -305,14 +305,14 @@ describe('template source-mapping', () => {
|
|||
|
||||
expect(mappings).toContain({
|
||||
source: '<div *ngFor="let item of items; index as i; trackBy: trackByFn">',
|
||||
generated: 'i0.ɵɵelementStart(0, "div")',
|
||||
generated: 'i0.ΔelementStart(0, "div")',
|
||||
sourceUrl: '../test.ts'
|
||||
});
|
||||
|
||||
// TODO - map the bindings better
|
||||
|
||||
expect(mappings).toContain(
|
||||
{source: '</div>', generated: 'i0.ɵɵelementEnd()', sourceUrl: '../test.ts'});
|
||||
{source: '</div>', generated: 'i0.ΔelementEnd()', sourceUrl: '../test.ts'});
|
||||
|
||||
});
|
||||
|
||||
|
@ -331,20 +331,20 @@ describe('template source-mapping', () => {
|
|||
`<div><ng-content></ng-content></div>`);
|
||||
|
||||
expect(mappings).toContain(
|
||||
{source: '<h3>', generated: 'i0.ɵɵelementStart(0, "h3")', sourceUrl: '../test.ts'});
|
||||
{source: '<h3>', generated: 'i0.ΔelementStart(0, "h3")', sourceUrl: '../test.ts'});
|
||||
expect(mappings).toContain({
|
||||
source: '<ng-content select="title">',
|
||||
generated: 'i0.ɵɵprojection(1, 1)',
|
||||
generated: 'i0.Δprojection(1, 1)',
|
||||
sourceUrl: '../test.ts'
|
||||
});
|
||||
expect(mappings).toContain(
|
||||
{source: '</h3>', generated: 'i0.ɵɵelementEnd()', sourceUrl: '../test.ts'});
|
||||
{source: '</h3>', generated: 'i0.ΔelementEnd()', sourceUrl: '../test.ts'});
|
||||
expect(mappings).toContain(
|
||||
{source: '<div>', generated: 'i0.ɵɵelementStart(2, "div")', sourceUrl: '../test.ts'});
|
||||
{source: '<div>', generated: 'i0.ΔelementStart(2, "div")', sourceUrl: '../test.ts'});
|
||||
expect(mappings).toContain(
|
||||
{source: '<ng-content>', generated: 'i0.ɵɵprojection(3)', sourceUrl: '../test.ts'});
|
||||
{source: '<ng-content>', generated: 'i0.Δprojection(3)', sourceUrl: '../test.ts'});
|
||||
expect(mappings).toContain(
|
||||
{source: '</div>', generated: 'i0.ɵɵelementEnd()', sourceUrl: '../test.ts'});
|
||||
{source: '</div>', generated: 'i0.ΔelementEnd()', sourceUrl: '../test.ts'});
|
||||
});
|
||||
});
|
||||
|
||||
|
@ -353,24 +353,24 @@ describe('template source-mapping', () => {
|
|||
|
||||
// Creation mode
|
||||
expect(mappings).toContain(
|
||||
{generated: 'i0.ɵɵelementStart(0, "div")', source: '<div>', sourceUrl: '../test.ts'});
|
||||
{generated: 'i0.ΔelementStart(0, "div")', source: '<div>', sourceUrl: '../test.ts'});
|
||||
expect(mappings).toContain({
|
||||
generated: 'i0.ɵɵtext(1, "this is a test")',
|
||||
generated: 'i0.Δtext(1, "this is a test")',
|
||||
source: 'this is a test',
|
||||
sourceUrl: '../test.ts'
|
||||
});
|
||||
expect(mappings).toContain(
|
||||
{generated: 'i0.ɵɵelementEnd()', source: '</div>', sourceUrl: '../test.ts'});
|
||||
{generated: 'i0.ΔelementEnd()', source: '</div>', sourceUrl: '../test.ts'});
|
||||
expect(mappings).toContain(
|
||||
{generated: 'i0.ɵɵelementStart(2, "div")', source: '<div>', sourceUrl: '../test.ts'});
|
||||
{generated: 'i0.ΔelementStart(2, "div")', source: '<div>', sourceUrl: '../test.ts'});
|
||||
expect(mappings).toContain(
|
||||
{generated: 'i0.ɵɵtext(3)', source: '{{ 1 + 2 }}', sourceUrl: '../test.ts'});
|
||||
{generated: 'i0.Δtext(3)', source: '{{ 1 + 2 }}', sourceUrl: '../test.ts'});
|
||||
expect(mappings).toContain(
|
||||
{generated: 'i0.ɵɵelementEnd()', source: '</div>', sourceUrl: '../test.ts'});
|
||||
{generated: 'i0.ΔelementEnd()', source: '</div>', sourceUrl: '../test.ts'});
|
||||
|
||||
// Update mode
|
||||
expect(mappings).toContain({
|
||||
generated: 'i0.ɵɵtextBinding(3, i0.ɵɵinterpolation1("", (1 + 2), ""))',
|
||||
generated: 'i0.ΔtextBinding(3, i0.Δinterpolation1("", (1 + 2), ""))',
|
||||
source: '{{ 1 + 2 }}',
|
||||
sourceUrl: '../test.ts'
|
||||
});
|
||||
|
@ -381,24 +381,24 @@ describe('template source-mapping', () => {
|
|||
|
||||
// Creation mode
|
||||
expect(mappings).toContain(
|
||||
{generated: 'i0.ɵɵelementStart(0, "div")', source: '<div>', sourceUrl: '../test.ts'});
|
||||
{generated: 'i0.ΔelementStart(0, "div")', source: '<div>', sourceUrl: '../test.ts'});
|
||||
expect(mappings).toContain({
|
||||
generated: 'i0.ɵɵtext(1, "this is a test")',
|
||||
generated: 'i0.Δtext(1, "this is a test")',
|
||||
source: 'this is a test',
|
||||
sourceUrl: '../test.ts'
|
||||
});
|
||||
expect(mappings).toContain(
|
||||
{generated: 'i0.ɵɵelementEnd()', source: '</div>', sourceUrl: '../test.ts'});
|
||||
{generated: 'i0.ΔelementEnd()', source: '</div>', sourceUrl: '../test.ts'});
|
||||
expect(mappings).toContain(
|
||||
{generated: 'i0.ɵɵelementStart(2, "div")', source: '<div>', sourceUrl: '../test.ts'});
|
||||
{generated: 'i0.ΔelementStart(2, "div")', source: '<div>', sourceUrl: '../test.ts'});
|
||||
expect(mappings).toContain(
|
||||
{generated: 'i0.ɵɵtext(3)', source: '{{ 1 + 2 }}', sourceUrl: '../test.ts'});
|
||||
{generated: 'i0.Δtext(3)', source: '{{ 1 + 2 }}', sourceUrl: '../test.ts'});
|
||||
expect(mappings).toContain(
|
||||
{generated: 'i0.ɵɵelementEnd()', source: '</div>', sourceUrl: '../test.ts'});
|
||||
{generated: 'i0.ΔelementEnd()', source: '</div>', sourceUrl: '../test.ts'});
|
||||
|
||||
// Update mode
|
||||
expect(mappings).toContain({
|
||||
generated: 'i0.ɵɵtextBinding(3, i0.ɵɵinterpolation1("", (1 + 2), ""))',
|
||||
generated: 'i0.ΔtextBinding(3, i0.Δinterpolation1("", (1 + 2), ""))',
|
||||
source: '{{ 1 + 2 }}',
|
||||
sourceUrl: '../test.ts'
|
||||
});
|
||||
|
@ -410,7 +410,7 @@ describe('template source-mapping', () => {
|
|||
const mappings = compileAndMap('<div class=\\"some-class\\">this is a test</div>');
|
||||
|
||||
expect(mappings).toContain({
|
||||
generated: 'i0.ɵɵelementStart(0, "div", _c0)',
|
||||
generated: 'i0.ΔelementStart(0, "div", _c0)',
|
||||
source: '<div class=\\"some-class\\">',
|
||||
sourceUrl: '../test.ts'
|
||||
});
|
||||
|
@ -429,30 +429,30 @@ describe('template source-mapping', () => {
|
|||
|
||||
// Creation mode
|
||||
expect(mappings).toContain({
|
||||
generated: 'i0.ɵɵelementStart(0, "div")',
|
||||
generated: 'i0.ΔelementStart(0, "div")',
|
||||
source: '<div>',
|
||||
sourceUrl: '../dir/test.html'
|
||||
});
|
||||
expect(mappings).toContain({
|
||||
generated: 'i0.ɵɵtext(1, "this is a test")',
|
||||
generated: 'i0.Δtext(1, "this is a test")',
|
||||
source: 'this is a test',
|
||||
sourceUrl: '../dir/test.html'
|
||||
});
|
||||
expect(mappings).toContain(
|
||||
{generated: 'i0.ɵɵelementEnd()', source: '</div>', sourceUrl: '../dir/test.html'});
|
||||
{generated: 'i0.ΔelementEnd()', source: '</div>', sourceUrl: '../dir/test.html'});
|
||||
expect(mappings).toContain({
|
||||
generated: 'i0.ɵɵelementStart(2, "div")',
|
||||
generated: 'i0.ΔelementStart(2, "div")',
|
||||
source: '<div>',
|
||||
sourceUrl: '../dir/test.html'
|
||||
});
|
||||
expect(mappings).toContain(
|
||||
{generated: 'i0.ɵɵtext(3)', source: '{{ 1 + 2 }}', sourceUrl: '../dir/test.html'});
|
||||
{generated: 'i0.Δtext(3)', source: '{{ 1 + 2 }}', sourceUrl: '../dir/test.html'});
|
||||
expect(mappings).toContain(
|
||||
{generated: 'i0.ɵɵelementEnd()', source: '</div>', sourceUrl: '../dir/test.html'});
|
||||
{generated: 'i0.ΔelementEnd()', source: '</div>', sourceUrl: '../dir/test.html'});
|
||||
|
||||
// Update mode
|
||||
expect(mappings).toContain({
|
||||
generated: 'i0.ɵɵtextBinding(3, i0.ɵɵinterpolation1("", (1 + 2), ""))',
|
||||
generated: 'i0.ΔtextBinding(3, i0.Δinterpolation1("", (1 + 2), ""))',
|
||||
source: '{{ 1 + 2 }}',
|
||||
sourceUrl: '../dir/test.html'
|
||||
});
|
||||
|
@ -464,39 +464,39 @@ describe('template source-mapping', () => {
|
|||
|
||||
// Creation mode
|
||||
expect(mappings).toContain({
|
||||
generated: 'i0.ɵɵelementStart(0, "div")',
|
||||
generated: 'i0.ΔelementStart(0, "div")',
|
||||
source: '<div>',
|
||||
sourceUrl: '../extraRootDir/test.html'
|
||||
});
|
||||
expect(mappings).toContain({
|
||||
generated: 'i0.ɵɵtext(1, "this is a test")',
|
||||
generated: 'i0.Δtext(1, "this is a test")',
|
||||
source: 'this is a test',
|
||||
sourceUrl: '../extraRootDir/test.html'
|
||||
});
|
||||
expect(mappings).toContain({
|
||||
generated: 'i0.ɵɵelementEnd()',
|
||||
generated: 'i0.ΔelementEnd()',
|
||||
source: '</div>',
|
||||
sourceUrl: '../extraRootDir/test.html'
|
||||
});
|
||||
expect(mappings).toContain({
|
||||
generated: 'i0.ɵɵelementStart(2, "div")',
|
||||
generated: 'i0.ΔelementStart(2, "div")',
|
||||
source: '<div>',
|
||||
sourceUrl: '../extraRootDir/test.html'
|
||||
});
|
||||
expect(mappings).toContain({
|
||||
generated: 'i0.ɵɵtext(3)',
|
||||
generated: 'i0.Δtext(3)',
|
||||
source: '{{ 1 + 2 }}',
|
||||
sourceUrl: '../extraRootDir/test.html'
|
||||
});
|
||||
expect(mappings).toContain({
|
||||
generated: 'i0.ɵɵelementEnd()',
|
||||
generated: 'i0.ΔelementEnd()',
|
||||
source: '</div>',
|
||||
sourceUrl: '../extraRootDir/test.html'
|
||||
});
|
||||
|
||||
// Update mode
|
||||
expect(mappings).toContain({
|
||||
generated: 'i0.ɵɵtextBinding(3, i0.ɵɵinterpolation1("", (1 + 2), ""))',
|
||||
generated: 'i0.ΔtextBinding(3, i0.Δinterpolation1("", (1 + 2), ""))',
|
||||
source: '{{ 1 + 2 }}',
|
||||
sourceUrl: '../extraRootDir/test.html'
|
||||
});
|
||||
|
|
|
@ -34,17 +34,17 @@ export declare class IndexPipe {
|
|||
export declare class NgForOf<T> {
|
||||
ngForOf: T[];
|
||||
static ngTemplateContextGuard<T>(dir: NgForOf<T>, ctx: any): ctx is NgForOfContext<T>;
|
||||
static ngDirectiveDef: i0.ɵɵDirectiveDefWithMeta<NgForOf<any>, '[ngFor][ngForOf]', never, {'ngForOf': 'ngForOf'}, {}, never>;
|
||||
static ngDirectiveDef: i0.ΔDirectiveDefWithMeta<NgForOf<any>, '[ngFor][ngForOf]', never, {'ngForOf': 'ngForOf'}, {}, never>;
|
||||
}
|
||||
|
||||
export declare class NgIf {
|
||||
ngIf: any;
|
||||
static ngTemplateGuard_ngIf<E>(dir: NgIf, expr: E): expr is NonNullable<E>
|
||||
static ngDirectiveDef: i0.ɵɵDirectiveDefWithMeta<NgForOf<any>, '[ngIf]', never, {'ngIf': 'ngIf'}, {}, never>;
|
||||
static ngDirectiveDef: i0.ΔDirectiveDefWithMeta<NgForOf<any>, '[ngIf]', never, {'ngIf': 'ngIf'}, {}, never>;
|
||||
}
|
||||
|
||||
export declare class CommonModule {
|
||||
static ngModuleDef: i0.ɵɵNgModuleDefWithMeta<CommonModule, [typeof NgIf, typeof NgForOf, typeof IndexPipe], never, [typeof NgIf, typeof NgForOf, typeof IndexPipe]>;
|
||||
static ngModuleDef: i0.ΔNgModuleDefWithMeta<CommonModule, [typeof NgIf, typeof NgForOf, typeof IndexPipe], never, [typeof NgIf, typeof NgForOf, typeof IndexPipe]>;
|
||||
}
|
||||
`);
|
||||
}
|
||||
|
|
|
@ -81,18 +81,18 @@ In `ngtsc` this is instead emitted as,
|
|||
```js
|
||||
const i0 = require("@angular/core");
|
||||
class GreetComponent {}
|
||||
GreetComponent.ngComponentDef = i0.ɵɵdefineComponent({
|
||||
GreetComponent.ngComponentDef = i0.ΔdefineComponent({
|
||||
type: GreetComponent,
|
||||
tag: 'greet',
|
||||
factory: () => new GreetComponent(),
|
||||
template: function (rf, ctx) {
|
||||
if (rf & RenderFlags.Create) {
|
||||
i0.ɵɵelementStart(0, 'div');
|
||||
i0.ɵɵtext(1);
|
||||
i0.ɵɵelementEnd();
|
||||
i0.ΔelementStart(0, 'div');
|
||||
i0.Δtext(1);
|
||||
i0.ΔelementEnd();
|
||||
}
|
||||
if (rf & RenderFlags.Update) {
|
||||
i0.ɵɵtextBinding(1, i0.ɵɵinterpolation1('Hello ', ctx.name, '!'));
|
||||
i0.ΔtextBinding(1, i0.Δinterpolation1('Hello ', ctx.name, '!'));
|
||||
}
|
||||
}
|
||||
});
|
||||
|
|
|
@ -161,7 +161,7 @@ export class MyComponent {
|
|||
```js
|
||||
export class MyComponent {
|
||||
name: string;
|
||||
static ngComponentDef = ɵɵdefineComponent({...});
|
||||
static ngComponentDef = ΔdefineComponent({...});
|
||||
}
|
||||
```
|
||||
|
||||
|
@ -213,7 +213,7 @@ export class MyDirective {
|
|||
constructor() {
|
||||
this.dirId = 'some id';
|
||||
}
|
||||
static ngDirectiveDef = ɵɵdefineDirective({...});
|
||||
static ngDirectiveDef = ΔdefineDirective({...});
|
||||
}
|
||||
```
|
||||
|
||||
|
@ -256,7 +256,7 @@ export class MyPipe implements PipeTransform {
|
|||
```js
|
||||
export class MyPipe {
|
||||
transform(...) ...
|
||||
static ngPipeDef = ɵɵdefinePipe({...});
|
||||
static ngPipeDef = ΔdefinePipe({...});
|
||||
}
|
||||
```
|
||||
|
||||
|
@ -329,7 +329,7 @@ export class MyModule {}
|
|||
*my.module.js*
|
||||
```js
|
||||
export class MyModule {
|
||||
static ngInjectorDef = ɵɵdefineInjector(...);
|
||||
static ngInjectorDef = ΔdefineInjector(...);
|
||||
}
|
||||
```
|
||||
|
||||
|
@ -389,7 +389,7 @@ manually written as:
|
|||
|
||||
```ts
|
||||
export class MyModule {
|
||||
static ngInjectorDef = ɵɵdefineInjector({
|
||||
static ngInjectorDef = ΔdefineInjector({
|
||||
providers: [{
|
||||
provide: Service, useClass: ServiceImpl
|
||||
}],
|
||||
|
@ -411,7 +411,7 @@ export class MyModule {
|
|||
}
|
||||
```
|
||||
|
||||
except for the call to `ɵɵdefineInjector` would generate a `{ __symbolic: 'error' }`
|
||||
except for the call to `ΔdefineInjector` would generate a `{ __symbolic: 'error' }`
|
||||
value which is ignored by the ivy compiler. This allows the system to ignore
|
||||
the difference between manually and mechanically created module definitions.
|
||||
|
||||
|
@ -440,7 +440,7 @@ properties by including a `// @__BUILD_OPTIMIZER_REMOVE_` comment:
|
|||
|
||||
```ts
|
||||
export class MyModule {
|
||||
static ngInjectorDef = ɵɵdefineInjector({
|
||||
static ngInjectorDef = ΔdefineInjector({
|
||||
providers: [{
|
||||
provide: Service, useClass: ServiceImpl
|
||||
}],
|
||||
|
|
|
@ -62,11 +62,11 @@ export class Identifiers {
|
|||
moduleName: CORE,
|
||||
|
||||
};
|
||||
static inject: o.ExternalReference = {name: 'ɵɵinject', moduleName: CORE};
|
||||
static inject: o.ExternalReference = {name: 'Δinject', moduleName: CORE};
|
||||
static INJECTOR: o.ExternalReference = {name: 'INJECTOR', moduleName: CORE};
|
||||
static Injector: o.ExternalReference = {name: 'Injector', moduleName: CORE};
|
||||
static ɵɵdefineInjectable: o.ExternalReference = {name: 'ɵɵdefineInjectable', moduleName: CORE};
|
||||
static InjectableDef: o.ExternalReference = {name: 'ɵɵInjectableDef', moduleName: CORE};
|
||||
static ΔdefineInjectable: o.ExternalReference = {name: 'ΔdefineInjectable', moduleName: CORE};
|
||||
static InjectableDef: o.ExternalReference = {name: 'ΔInjectableDef', moduleName: CORE};
|
||||
static ViewEncapsulation: o.ExternalReference = {
|
||||
name: 'ViewEncapsulation',
|
||||
moduleName: CORE,
|
||||
|
|
|
@ -116,7 +116,7 @@ export class InjectableCompiler {
|
|||
mapEntry('token', ctx.importExpr(injectable.type.reference)),
|
||||
mapEntry('providedIn', providedIn),
|
||||
];
|
||||
return o.importExpr(Identifiers.ɵɵdefineInjectable).callFn([o.literalMap(def)]);
|
||||
return o.importExpr(Identifiers.ΔdefineInjectable).callFn([o.literalMap(def)]);
|
||||
}
|
||||
|
||||
compile(injectable: CompileInjectableMetadata, ctx: OutputContext): void {
|
||||
|
|
|
@ -100,7 +100,7 @@ export function compileInjectable(meta: R3InjectableMetadata): InjectableDef {
|
|||
const token = meta.type;
|
||||
const providedIn = meta.providedIn;
|
||||
|
||||
const expression = o.importExpr(Identifiers.ɵɵdefineInjectable).callFn([mapToMapExpression(
|
||||
const expression = o.importExpr(Identifiers.ΔdefineInjectable).callFn([mapToMapExpression(
|
||||
{token, factory: result.factory, providedIn})]);
|
||||
const type = new o.ExpressionType(o.importExpr(
|
||||
Identifiers.InjectableDef, [typeWithParameters(meta.type, meta.typeArgumentCount)]));
|
||||
|
|
|
@ -17,237 +17,237 @@ export class Identifiers {
|
|||
static PATCH_DEPS = 'patchedDeps';
|
||||
|
||||
/* Instructions */
|
||||
static namespaceHTML: o.ExternalReference = {name: 'ɵɵnamespaceHTML', moduleName: CORE};
|
||||
static namespaceHTML: o.ExternalReference = {name: 'ΔnamespaceHTML', moduleName: CORE};
|
||||
|
||||
static namespaceMathML: o.ExternalReference = {name: 'ɵɵnamespaceMathML', moduleName: CORE};
|
||||
static namespaceMathML: o.ExternalReference = {name: 'ΔnamespaceMathML', moduleName: CORE};
|
||||
|
||||
static namespaceSVG: o.ExternalReference = {name: 'ɵɵnamespaceSVG', moduleName: CORE};
|
||||
static namespaceSVG: o.ExternalReference = {name: 'ΔnamespaceSVG', moduleName: CORE};
|
||||
|
||||
static element: o.ExternalReference = {name: 'ɵɵelement', moduleName: CORE};
|
||||
static element: o.ExternalReference = {name: 'Δelement', moduleName: CORE};
|
||||
|
||||
static elementStart: o.ExternalReference = {name: 'ɵɵelementStart', moduleName: CORE};
|
||||
static elementStart: o.ExternalReference = {name: 'ΔelementStart', moduleName: CORE};
|
||||
|
||||
static elementEnd: o.ExternalReference = {name: 'ɵɵelementEnd', moduleName: CORE};
|
||||
static elementEnd: o.ExternalReference = {name: 'ΔelementEnd', moduleName: CORE};
|
||||
|
||||
static elementProperty: o.ExternalReference = {name: 'ɵɵelementProperty', moduleName: CORE};
|
||||
static elementProperty: o.ExternalReference = {name: 'ΔelementProperty', moduleName: CORE};
|
||||
|
||||
static select: o.ExternalReference = {name: 'ɵɵselect', moduleName: CORE};
|
||||
static select: o.ExternalReference = {name: 'Δselect', moduleName: CORE};
|
||||
|
||||
static componentHostSyntheticProperty:
|
||||
o.ExternalReference = {name: 'ɵɵcomponentHostSyntheticProperty', moduleName: CORE};
|
||||
o.ExternalReference = {name: 'ΔcomponentHostSyntheticProperty', moduleName: CORE};
|
||||
|
||||
static componentHostSyntheticListener:
|
||||
o.ExternalReference = {name: 'ɵɵcomponentHostSyntheticListener', moduleName: CORE};
|
||||
o.ExternalReference = {name: 'ΔcomponentHostSyntheticListener', moduleName: CORE};
|
||||
|
||||
static elementAttribute: o.ExternalReference = {name: 'ɵɵelementAttribute', moduleName: CORE};
|
||||
static elementAttribute: o.ExternalReference = {name: 'ΔelementAttribute', moduleName: CORE};
|
||||
|
||||
static classProp: o.ExternalReference = {name: 'ɵɵclassProp', moduleName: CORE};
|
||||
static classProp: o.ExternalReference = {name: 'ΔclassProp', moduleName: CORE};
|
||||
|
||||
static elementContainerStart:
|
||||
o.ExternalReference = {name: 'ɵɵelementContainerStart', moduleName: CORE};
|
||||
o.ExternalReference = {name: 'ΔelementContainerStart', moduleName: CORE};
|
||||
|
||||
static elementContainerEnd:
|
||||
o.ExternalReference = {name: 'ɵɵelementContainerEnd', moduleName: CORE};
|
||||
o.ExternalReference = {name: 'ΔelementContainerEnd', moduleName: CORE};
|
||||
|
||||
static styling: o.ExternalReference = {name: 'ɵɵstyling', moduleName: CORE};
|
||||
static styling: o.ExternalReference = {name: 'Δstyling', moduleName: CORE};
|
||||
|
||||
static styleMap: o.ExternalReference = {name: 'ɵɵstyleMap', moduleName: CORE};
|
||||
static styleMap: o.ExternalReference = {name: 'ΔstyleMap', moduleName: CORE};
|
||||
|
||||
static classMap: o.ExternalReference = {name: 'ɵɵclassMap', moduleName: CORE};
|
||||
static classMap: o.ExternalReference = {name: 'ΔclassMap', moduleName: CORE};
|
||||
|
||||
static styleProp: o.ExternalReference = {name: 'ɵɵstyleProp', moduleName: CORE};
|
||||
static styleProp: o.ExternalReference = {name: 'ΔstyleProp', moduleName: CORE};
|
||||
|
||||
static stylingApply: o.ExternalReference = {name: 'ɵɵstylingApply', moduleName: CORE};
|
||||
static stylingApply: o.ExternalReference = {name: 'ΔstylingApply', moduleName: CORE};
|
||||
|
||||
static elementHostAttrs: o.ExternalReference = {name: 'ɵɵelementHostAttrs', moduleName: CORE};
|
||||
static elementHostAttrs: o.ExternalReference = {name: 'ΔelementHostAttrs', moduleName: CORE};
|
||||
|
||||
static containerCreate: o.ExternalReference = {name: 'ɵɵcontainer', moduleName: CORE};
|
||||
static containerCreate: o.ExternalReference = {name: 'Δcontainer', moduleName: CORE};
|
||||
|
||||
static nextContext: o.ExternalReference = {name: 'ɵɵnextContext', moduleName: CORE};
|
||||
static nextContext: o.ExternalReference = {name: 'ΔnextContext', moduleName: CORE};
|
||||
|
||||
static templateCreate: o.ExternalReference = {name: 'ɵɵtemplate', moduleName: CORE};
|
||||
static templateCreate: o.ExternalReference = {name: 'Δtemplate', moduleName: CORE};
|
||||
|
||||
static text: o.ExternalReference = {name: 'ɵɵtext', moduleName: CORE};
|
||||
static text: o.ExternalReference = {name: 'Δtext', moduleName: CORE};
|
||||
|
||||
static textBinding: o.ExternalReference = {name: 'ɵɵtextBinding', moduleName: CORE};
|
||||
static textBinding: o.ExternalReference = {name: 'ΔtextBinding', moduleName: CORE};
|
||||
|
||||
static bind: o.ExternalReference = {name: 'ɵɵbind', moduleName: CORE};
|
||||
static bind: o.ExternalReference = {name: 'Δbind', moduleName: CORE};
|
||||
|
||||
static enableBindings: o.ExternalReference = {name: 'ɵɵenableBindings', moduleName: CORE};
|
||||
static enableBindings: o.ExternalReference = {name: 'ΔenableBindings', moduleName: CORE};
|
||||
|
||||
static disableBindings: o.ExternalReference = {name: 'ɵɵdisableBindings', moduleName: CORE};
|
||||
static disableBindings: o.ExternalReference = {name: 'ΔdisableBindings', moduleName: CORE};
|
||||
|
||||
static allocHostVars: o.ExternalReference = {name: 'ɵɵallocHostVars', moduleName: CORE};
|
||||
static allocHostVars: o.ExternalReference = {name: 'ΔallocHostVars', moduleName: CORE};
|
||||
|
||||
static getCurrentView: o.ExternalReference = {name: 'ɵɵgetCurrentView', moduleName: CORE};
|
||||
static getCurrentView: o.ExternalReference = {name: 'ΔgetCurrentView', moduleName: CORE};
|
||||
|
||||
static restoreView: o.ExternalReference = {name: 'ɵɵrestoreView', moduleName: CORE};
|
||||
static restoreView: o.ExternalReference = {name: 'ΔrestoreView', moduleName: CORE};
|
||||
|
||||
static interpolation1: o.ExternalReference = {name: 'ɵɵinterpolation1', moduleName: CORE};
|
||||
static interpolation2: o.ExternalReference = {name: 'ɵɵinterpolation2', moduleName: CORE};
|
||||
static interpolation3: o.ExternalReference = {name: 'ɵɵinterpolation3', moduleName: CORE};
|
||||
static interpolation4: o.ExternalReference = {name: 'ɵɵinterpolation4', moduleName: CORE};
|
||||
static interpolation5: o.ExternalReference = {name: 'ɵɵinterpolation5', moduleName: CORE};
|
||||
static interpolation6: o.ExternalReference = {name: 'ɵɵinterpolation6', moduleName: CORE};
|
||||
static interpolation7: o.ExternalReference = {name: 'ɵɵinterpolation7', moduleName: CORE};
|
||||
static interpolation8: o.ExternalReference = {name: 'ɵɵinterpolation8', moduleName: CORE};
|
||||
static interpolationV: o.ExternalReference = {name: 'ɵɵinterpolationV', moduleName: CORE};
|
||||
static interpolation1: o.ExternalReference = {name: 'Δinterpolation1', moduleName: CORE};
|
||||
static interpolation2: o.ExternalReference = {name: 'Δinterpolation2', moduleName: CORE};
|
||||
static interpolation3: o.ExternalReference = {name: 'Δinterpolation3', moduleName: CORE};
|
||||
static interpolation4: o.ExternalReference = {name: 'Δinterpolation4', moduleName: CORE};
|
||||
static interpolation5: o.ExternalReference = {name: 'Δinterpolation5', moduleName: CORE};
|
||||
static interpolation6: o.ExternalReference = {name: 'Δinterpolation6', moduleName: CORE};
|
||||
static interpolation7: o.ExternalReference = {name: 'Δinterpolation7', moduleName: CORE};
|
||||
static interpolation8: o.ExternalReference = {name: 'Δinterpolation8', moduleName: CORE};
|
||||
static interpolationV: o.ExternalReference = {name: 'ΔinterpolationV', moduleName: CORE};
|
||||
|
||||
static pureFunction0: o.ExternalReference = {name: 'ɵɵpureFunction0', moduleName: CORE};
|
||||
static pureFunction1: o.ExternalReference = {name: 'ɵɵpureFunction1', moduleName: CORE};
|
||||
static pureFunction2: o.ExternalReference = {name: 'ɵɵpureFunction2', moduleName: CORE};
|
||||
static pureFunction3: o.ExternalReference = {name: 'ɵɵpureFunction3', moduleName: CORE};
|
||||
static pureFunction4: o.ExternalReference = {name: 'ɵɵpureFunction4', moduleName: CORE};
|
||||
static pureFunction5: o.ExternalReference = {name: 'ɵɵpureFunction5', moduleName: CORE};
|
||||
static pureFunction6: o.ExternalReference = {name: 'ɵɵpureFunction6', moduleName: CORE};
|
||||
static pureFunction7: o.ExternalReference = {name: 'ɵɵpureFunction7', moduleName: CORE};
|
||||
static pureFunction8: o.ExternalReference = {name: 'ɵɵpureFunction8', moduleName: CORE};
|
||||
static pureFunctionV: o.ExternalReference = {name: 'ɵɵpureFunctionV', moduleName: CORE};
|
||||
static pureFunction0: o.ExternalReference = {name: 'ΔpureFunction0', moduleName: CORE};
|
||||
static pureFunction1: o.ExternalReference = {name: 'ΔpureFunction1', moduleName: CORE};
|
||||
static pureFunction2: o.ExternalReference = {name: 'ΔpureFunction2', moduleName: CORE};
|
||||
static pureFunction3: o.ExternalReference = {name: 'ΔpureFunction3', moduleName: CORE};
|
||||
static pureFunction4: o.ExternalReference = {name: 'ΔpureFunction4', moduleName: CORE};
|
||||
static pureFunction5: o.ExternalReference = {name: 'ΔpureFunction5', moduleName: CORE};
|
||||
static pureFunction6: o.ExternalReference = {name: 'ΔpureFunction6', moduleName: CORE};
|
||||
static pureFunction7: o.ExternalReference = {name: 'ΔpureFunction7', moduleName: CORE};
|
||||
static pureFunction8: o.ExternalReference = {name: 'ΔpureFunction8', moduleName: CORE};
|
||||
static pureFunctionV: o.ExternalReference = {name: 'ΔpureFunctionV', moduleName: CORE};
|
||||
|
||||
static pipeBind1: o.ExternalReference = {name: 'ɵɵpipeBind1', moduleName: CORE};
|
||||
static pipeBind2: o.ExternalReference = {name: 'ɵɵpipeBind2', moduleName: CORE};
|
||||
static pipeBind3: o.ExternalReference = {name: 'ɵɵpipeBind3', moduleName: CORE};
|
||||
static pipeBind4: o.ExternalReference = {name: 'ɵɵpipeBind4', moduleName: CORE};
|
||||
static pipeBindV: o.ExternalReference = {name: 'ɵɵpipeBindV', moduleName: CORE};
|
||||
static pipeBind1: o.ExternalReference = {name: 'ΔpipeBind1', moduleName: CORE};
|
||||
static pipeBind2: o.ExternalReference = {name: 'ΔpipeBind2', moduleName: CORE};
|
||||
static pipeBind3: o.ExternalReference = {name: 'ΔpipeBind3', moduleName: CORE};
|
||||
static pipeBind4: o.ExternalReference = {name: 'ΔpipeBind4', moduleName: CORE};
|
||||
static pipeBindV: o.ExternalReference = {name: 'ΔpipeBindV', moduleName: CORE};
|
||||
|
||||
static property: o.ExternalReference = {name: 'ɵɵproperty', moduleName: CORE};
|
||||
static property: o.ExternalReference = {name: 'Δproperty', moduleName: CORE};
|
||||
|
||||
static propertyInterpolate:
|
||||
o.ExternalReference = {name: 'ɵɵpropertyInterpolate', moduleName: CORE};
|
||||
o.ExternalReference = {name: 'ΔpropertyInterpolate', moduleName: CORE};
|
||||
static propertyInterpolate1:
|
||||
o.ExternalReference = {name: 'ɵɵpropertyInterpolate1', moduleName: CORE};
|
||||
o.ExternalReference = {name: 'ΔpropertyInterpolate1', moduleName: CORE};
|
||||
static propertyInterpolate2:
|
||||
o.ExternalReference = {name: 'ɵɵpropertyInterpolate2', moduleName: CORE};
|
||||
o.ExternalReference = {name: 'ΔpropertyInterpolate2', moduleName: CORE};
|
||||
static propertyInterpolate3:
|
||||
o.ExternalReference = {name: 'ɵɵpropertyInterpolate3', moduleName: CORE};
|
||||
o.ExternalReference = {name: 'ΔpropertyInterpolate3', moduleName: CORE};
|
||||
static propertyInterpolate4:
|
||||
o.ExternalReference = {name: 'ɵɵpropertyInterpolate4', moduleName: CORE};
|
||||
o.ExternalReference = {name: 'ΔpropertyInterpolate4', moduleName: CORE};
|
||||
static propertyInterpolate5:
|
||||
o.ExternalReference = {name: 'ɵɵpropertyInterpolate5', moduleName: CORE};
|
||||
o.ExternalReference = {name: 'ΔpropertyInterpolate5', moduleName: CORE};
|
||||
static propertyInterpolate6:
|
||||
o.ExternalReference = {name: 'ɵɵpropertyInterpolate6', moduleName: CORE};
|
||||
o.ExternalReference = {name: 'ΔpropertyInterpolate6', moduleName: CORE};
|
||||
static propertyInterpolate7:
|
||||
o.ExternalReference = {name: 'ɵɵpropertyInterpolate7', moduleName: CORE};
|
||||
o.ExternalReference = {name: 'ΔpropertyInterpolate7', moduleName: CORE};
|
||||
static propertyInterpolate8:
|
||||
o.ExternalReference = {name: 'ɵɵpropertyInterpolate8', moduleName: CORE};
|
||||
o.ExternalReference = {name: 'ΔpropertyInterpolate8', moduleName: CORE};
|
||||
static propertyInterpolateV:
|
||||
o.ExternalReference = {name: 'ɵɵpropertyInterpolateV', moduleName: CORE};
|
||||
o.ExternalReference = {name: 'ΔpropertyInterpolateV', moduleName: CORE};
|
||||
|
||||
static i18n: o.ExternalReference = {name: 'ɵɵi18n', moduleName: CORE};
|
||||
static i18nAttributes: o.ExternalReference = {name: 'ɵɵi18nAttributes', moduleName: CORE};
|
||||
static i18nExp: o.ExternalReference = {name: 'ɵɵi18nExp', moduleName: CORE};
|
||||
static i18nStart: o.ExternalReference = {name: 'ɵɵi18nStart', moduleName: CORE};
|
||||
static i18nEnd: o.ExternalReference = {name: 'ɵɵi18nEnd', moduleName: CORE};
|
||||
static i18nApply: o.ExternalReference = {name: 'ɵɵi18nApply', moduleName: CORE};
|
||||
static i18nPostprocess: o.ExternalReference = {name: 'ɵɵi18nPostprocess', moduleName: CORE};
|
||||
static i18nLocalize: o.ExternalReference = {name: 'ɵɵi18nLocalize', moduleName: CORE};
|
||||
static i18n: o.ExternalReference = {name: 'Δi18n', moduleName: CORE};
|
||||
static i18nAttributes: o.ExternalReference = {name: 'Δi18nAttributes', moduleName: CORE};
|
||||
static i18nExp: o.ExternalReference = {name: 'Δi18nExp', moduleName: CORE};
|
||||
static i18nStart: o.ExternalReference = {name: 'Δi18nStart', moduleName: CORE};
|
||||
static i18nEnd: o.ExternalReference = {name: 'Δi18nEnd', moduleName: CORE};
|
||||
static i18nApply: o.ExternalReference = {name: 'Δi18nApply', moduleName: CORE};
|
||||
static i18nPostprocess: o.ExternalReference = {name: 'Δi18nPostprocess', moduleName: CORE};
|
||||
static i18nLocalize: o.ExternalReference = {name: 'Δi18nLocalize', moduleName: CORE};
|
||||
|
||||
static load: o.ExternalReference = {name: 'ɵɵload', moduleName: CORE};
|
||||
static load: o.ExternalReference = {name: 'Δload', moduleName: CORE};
|
||||
|
||||
static pipe: o.ExternalReference = {name: 'ɵɵpipe', moduleName: CORE};
|
||||
static pipe: o.ExternalReference = {name: 'Δpipe', moduleName: CORE};
|
||||
|
||||
static projection: o.ExternalReference = {name: 'ɵɵprojection', moduleName: CORE};
|
||||
static projectionDef: o.ExternalReference = {name: 'ɵɵprojectionDef', moduleName: CORE};
|
||||
static projection: o.ExternalReference = {name: 'Δprojection', moduleName: CORE};
|
||||
static projectionDef: o.ExternalReference = {name: 'ΔprojectionDef', moduleName: CORE};
|
||||
|
||||
static reference: o.ExternalReference = {name: 'ɵɵreference', moduleName: CORE};
|
||||
static reference: o.ExternalReference = {name: 'Δreference', moduleName: CORE};
|
||||
|
||||
static inject: o.ExternalReference = {name: 'ɵɵinject', moduleName: CORE};
|
||||
static inject: o.ExternalReference = {name: 'Δinject', moduleName: CORE};
|
||||
|
||||
static injectAttribute: o.ExternalReference = {name: 'ɵɵinjectAttribute', moduleName: CORE};
|
||||
static injectAttribute: o.ExternalReference = {name: 'ΔinjectAttribute', moduleName: CORE};
|
||||
|
||||
static directiveInject: o.ExternalReference = {name: 'ɵɵdirectiveInject', moduleName: CORE};
|
||||
static directiveInject: o.ExternalReference = {name: 'ΔdirectiveInject', moduleName: CORE};
|
||||
|
||||
static templateRefExtractor:
|
||||
o.ExternalReference = {name: 'ɵɵtemplateRefExtractor', moduleName: CORE};
|
||||
o.ExternalReference = {name: 'ΔtemplateRefExtractor', moduleName: CORE};
|
||||
|
||||
static resolveWindow: o.ExternalReference = {name: 'ɵɵresolveWindow', moduleName: CORE};
|
||||
static resolveDocument: o.ExternalReference = {name: 'ɵɵresolveDocument', moduleName: CORE};
|
||||
static resolveBody: o.ExternalReference = {name: 'ɵɵresolveBody', moduleName: CORE};
|
||||
static resolveWindow: o.ExternalReference = {name: 'ΔresolveWindow', moduleName: CORE};
|
||||
static resolveDocument: o.ExternalReference = {name: 'ΔresolveDocument', moduleName: CORE};
|
||||
static resolveBody: o.ExternalReference = {name: 'ΔresolveBody', moduleName: CORE};
|
||||
|
||||
static defineBase: o.ExternalReference = {name: 'ɵɵdefineBase', moduleName: CORE};
|
||||
static defineBase: o.ExternalReference = {name: 'ΔdefineBase', moduleName: CORE};
|
||||
|
||||
static BaseDef: o.ExternalReference = {
|
||||
name: 'ɵɵBaseDef',
|
||||
name: 'ΔBaseDef',
|
||||
moduleName: CORE,
|
||||
};
|
||||
|
||||
static defineComponent: o.ExternalReference = {name: 'ɵɵdefineComponent', moduleName: CORE};
|
||||
static defineComponent: o.ExternalReference = {name: 'ΔdefineComponent', moduleName: CORE};
|
||||
|
||||
static setComponentScope: o.ExternalReference = {name: 'ɵɵsetComponentScope', moduleName: CORE};
|
||||
static setComponentScope: o.ExternalReference = {name: 'ΔsetComponentScope', moduleName: CORE};
|
||||
|
||||
static ComponentDefWithMeta: o.ExternalReference = {
|
||||
name: 'ɵɵComponentDefWithMeta',
|
||||
name: 'ΔComponentDefWithMeta',
|
||||
moduleName: CORE,
|
||||
};
|
||||
|
||||
static defineDirective: o.ExternalReference = {
|
||||
name: 'ɵɵdefineDirective',
|
||||
name: 'ΔdefineDirective',
|
||||
moduleName: CORE,
|
||||
};
|
||||
|
||||
static DirectiveDefWithMeta: o.ExternalReference = {
|
||||
name: 'ɵɵDirectiveDefWithMeta',
|
||||
name: 'ΔDirectiveDefWithMeta',
|
||||
moduleName: CORE,
|
||||
};
|
||||
|
||||
static InjectorDef: o.ExternalReference = {
|
||||
name: 'ɵɵInjectorDef',
|
||||
name: 'ΔInjectorDef',
|
||||
moduleName: CORE,
|
||||
};
|
||||
|
||||
static defineInjector: o.ExternalReference = {
|
||||
name: 'ɵɵdefineInjector',
|
||||
name: 'ΔdefineInjector',
|
||||
moduleName: CORE,
|
||||
};
|
||||
|
||||
static NgModuleDefWithMeta: o.ExternalReference = {
|
||||
name: 'ɵɵNgModuleDefWithMeta',
|
||||
name: 'ΔNgModuleDefWithMeta',
|
||||
moduleName: CORE,
|
||||
};
|
||||
|
||||
static defineNgModule: o.ExternalReference = {name: 'ɵɵdefineNgModule', moduleName: CORE};
|
||||
static setNgModuleScope: o.ExternalReference = {name: 'ɵɵsetNgModuleScope', moduleName: CORE};
|
||||
static defineNgModule: o.ExternalReference = {name: 'ΔdefineNgModule', moduleName: CORE};
|
||||
static setNgModuleScope: o.ExternalReference = {name: 'ΔsetNgModuleScope', moduleName: CORE};
|
||||
|
||||
static PipeDefWithMeta: o.ExternalReference = {name: 'ɵɵPipeDefWithMeta', moduleName: CORE};
|
||||
static PipeDefWithMeta: o.ExternalReference = {name: 'ΔPipeDefWithMeta', moduleName: CORE};
|
||||
|
||||
static definePipe: o.ExternalReference = {name: 'ɵɵdefinePipe', moduleName: CORE};
|
||||
static definePipe: o.ExternalReference = {name: 'ΔdefinePipe', moduleName: CORE};
|
||||
|
||||
static queryRefresh: o.ExternalReference = {name: 'ɵɵqueryRefresh', moduleName: CORE};
|
||||
static viewQuery: o.ExternalReference = {name: 'ɵɵviewQuery', moduleName: CORE};
|
||||
static staticViewQuery: o.ExternalReference = {name: 'ɵɵstaticViewQuery', moduleName: CORE};
|
||||
static staticContentQuery: o.ExternalReference = {name: 'ɵɵstaticContentQuery', moduleName: CORE};
|
||||
static loadViewQuery: o.ExternalReference = {name: 'ɵɵloadViewQuery', moduleName: CORE};
|
||||
static contentQuery: o.ExternalReference = {name: 'ɵɵcontentQuery', moduleName: CORE};
|
||||
static loadContentQuery: o.ExternalReference = {name: 'ɵɵloadContentQuery', moduleName: CORE};
|
||||
static queryRefresh: o.ExternalReference = {name: 'ΔqueryRefresh', moduleName: CORE};
|
||||
static viewQuery: o.ExternalReference = {name: 'ΔviewQuery', moduleName: CORE};
|
||||
static staticViewQuery: o.ExternalReference = {name: 'ΔstaticViewQuery', moduleName: CORE};
|
||||
static staticContentQuery: o.ExternalReference = {name: 'ΔstaticContentQuery', moduleName: CORE};
|
||||
static loadViewQuery: o.ExternalReference = {name: 'ΔloadViewQuery', moduleName: CORE};
|
||||
static contentQuery: o.ExternalReference = {name: 'ΔcontentQuery', moduleName: CORE};
|
||||
static loadContentQuery: o.ExternalReference = {name: 'ΔloadContentQuery', moduleName: CORE};
|
||||
|
||||
static NgOnChangesFeature: o.ExternalReference = {name: 'ɵɵNgOnChangesFeature', moduleName: CORE};
|
||||
static NgOnChangesFeature: o.ExternalReference = {name: 'ΔNgOnChangesFeature', moduleName: CORE};
|
||||
|
||||
static InheritDefinitionFeature:
|
||||
o.ExternalReference = {name: 'ɵɵInheritDefinitionFeature', moduleName: CORE};
|
||||
o.ExternalReference = {name: 'ΔInheritDefinitionFeature', moduleName: CORE};
|
||||
|
||||
static ProvidersFeature: o.ExternalReference = {name: 'ɵɵProvidersFeature', moduleName: CORE};
|
||||
static ProvidersFeature: o.ExternalReference = {name: 'ΔProvidersFeature', moduleName: CORE};
|
||||
|
||||
static listener: o.ExternalReference = {name: 'ɵɵlistener', moduleName: CORE};
|
||||
static listener: o.ExternalReference = {name: 'Δlistener', moduleName: CORE};
|
||||
|
||||
static getFactoryOf: o.ExternalReference = {
|
||||
name: 'ɵɵgetFactoryOf',
|
||||
name: 'ΔgetFactoryOf',
|
||||
moduleName: CORE,
|
||||
};
|
||||
|
||||
static getInheritedFactory: o.ExternalReference = {
|
||||
name: 'ɵɵgetInheritedFactory',
|
||||
name: 'ΔgetInheritedFactory',
|
||||
moduleName: CORE,
|
||||
};
|
||||
|
||||
// sanitization-related functions
|
||||
static sanitizeHtml: o.ExternalReference = {name: 'ɵɵsanitizeHtml', moduleName: CORE};
|
||||
static sanitizeStyle: o.ExternalReference = {name: 'ɵɵsanitizeStyle', moduleName: CORE};
|
||||
static sanitizeHtml: o.ExternalReference = {name: 'ΔsanitizeHtml', moduleName: CORE};
|
||||
static sanitizeStyle: o.ExternalReference = {name: 'ΔsanitizeStyle', moduleName: CORE};
|
||||
static defaultStyleSanitizer:
|
||||
o.ExternalReference = {name: 'ɵɵdefaultStyleSanitizer', moduleName: CORE};
|
||||
o.ExternalReference = {name: 'ΔdefaultStyleSanitizer', moduleName: CORE};
|
||||
static sanitizeResourceUrl:
|
||||
o.ExternalReference = {name: 'ɵɵsanitizeResourceUrl', moduleName: CORE};
|
||||
static sanitizeScript: o.ExternalReference = {name: 'ɵɵsanitizeScript', moduleName: CORE};
|
||||
static sanitizeUrl: o.ExternalReference = {name: 'ɵɵsanitizeUrl', moduleName: CORE};
|
||||
o.ExternalReference = {name: 'ΔsanitizeResourceUrl', moduleName: CORE};
|
||||
static sanitizeScript: o.ExternalReference = {name: 'ΔsanitizeScript', moduleName: CORE};
|
||||
static sanitizeUrl: o.ExternalReference = {name: 'ΔsanitizeUrl', moduleName: CORE};
|
||||
static sanitizeUrlOrResourceUrl:
|
||||
o.ExternalReference = {name: 'ɵɵsanitizeUrlOrResourceUrl', moduleName: CORE};
|
||||
o.ExternalReference = {name: 'ΔsanitizeUrlOrResourceUrl', moduleName: CORE};
|
||||
}
|
||||
|
|
|
@ -107,7 +107,7 @@ export function compileNgModule(meta: R3NgModuleMetadata): R3NgModuleDef {
|
|||
}
|
||||
|
||||
// If requested to emit scope information inline, pass the declarations, imports and exports to
|
||||
// the `ɵɵdefineNgModule` call. The JIT compilation uses this.
|
||||
// the `ΔdefineNgModule` call. The JIT compilation uses this.
|
||||
if (emitInline) {
|
||||
if (declarations.length) {
|
||||
definitionMap.declarations = refsToArray(declarations, containsForwardDecls);
|
||||
|
@ -122,7 +122,7 @@ export function compileNgModule(meta: R3NgModuleMetadata): R3NgModuleDef {
|
|||
}
|
||||
}
|
||||
|
||||
// If not emitting inline, the scope information is not passed into `ɵɵdefineNgModule` as it would
|
||||
// If not emitting inline, the scope information is not passed into `ΔdefineNgModule` as it would
|
||||
// prevent tree-shaking of the declarations, imports and exports references.
|
||||
else {
|
||||
const setNgModuleScopeCall = generateSetNgModuleScopeCall(meta);
|
||||
|
@ -150,7 +150,7 @@ export function compileNgModule(meta: R3NgModuleMetadata): R3NgModuleDef {
|
|||
}
|
||||
|
||||
/**
|
||||
* Generates a function call to `ɵɵsetNgModuleScope` with all necessary information so that the
|
||||
* Generates a function call to `ΔsetNgModuleScope` with all necessary information so that the
|
||||
* transitive module scope can be computed during runtime in JIT mode. This call is marked pure
|
||||
* such that the references to declarations, imports and exports may be elided causing these
|
||||
* symbols to become tree-shakeable.
|
||||
|
|
|
@ -874,7 +874,7 @@ export class TemplateDefinitionBuilder implements t.Visitor<void>, LocalResolver
|
|||
return trimTrailingNulls(parameters);
|
||||
});
|
||||
|
||||
// handle property bindings e.g. ɵɵproperty('ngForOf', ctx.items), et al;
|
||||
// handle property bindings e.g. Δproperty('ngForOf', ctx.items), et al;
|
||||
const context = o.variable(CONTEXT_NAME);
|
||||
this.templatePropertyBindings(template, templateIndex, context, template.templateAttrs);
|
||||
|
||||
|
|
|
@ -6,7 +6,7 @@
|
|||
* found in the LICENSE file at https://angular.io/license
|
||||
*/
|
||||
|
||||
import {ɵɵdefineInjectable} from '../../di/interface/defs';
|
||||
import {ΔdefineInjectable} from '../../di/interface/defs';
|
||||
import {StaticProvider} from '../../di/interface/provider';
|
||||
import {Optional, SkipSelf} from '../../di/metadata';
|
||||
import {DefaultIterableDifferFactory} from '../differs/default_iterable_differ';
|
||||
|
@ -143,7 +143,7 @@ export interface IterableDifferFactory {
|
|||
*/
|
||||
export class IterableDiffers {
|
||||
/** @nocollapse */
|
||||
static ngInjectableDef = ɵɵdefineInjectable({
|
||||
static ngInjectableDef = ΔdefineInjectable({
|
||||
providedIn: 'root',
|
||||
factory: () => new IterableDiffers([new DefaultIterableDifferFactory()])
|
||||
});
|
||||
|
|
|
@ -6,7 +6,7 @@
|
|||
* found in the LICENSE file at https://angular.io/license
|
||||
*/
|
||||
|
||||
import {Optional, SkipSelf, StaticProvider, ɵɵdefineInjectable} from '../../di';
|
||||
import {Optional, SkipSelf, StaticProvider, ΔdefineInjectable} from '../../di';
|
||||
import {DefaultKeyValueDifferFactory} from './default_keyvalue_differ';
|
||||
|
||||
|
||||
|
@ -118,7 +118,7 @@ export interface KeyValueDifferFactory {
|
|||
*/
|
||||
export class KeyValueDiffers {
|
||||
/** @nocollapse */
|
||||
static ngInjectableDef = ɵɵdefineInjectable({
|
||||
static ngInjectableDef = ΔdefineInjectable({
|
||||
providedIn: 'root',
|
||||
factory: () => new KeyValueDiffers([new DefaultKeyValueDifferFactory()])
|
||||
});
|
||||
|
|
|
@ -13,8 +13,8 @@ export {devModeEqual as ɵdevModeEqual} from './change_detection/change_detectio
|
|||
export {isListLikeIterable as ɵisListLikeIterable} from './change_detection/change_detection_util';
|
||||
export {ChangeDetectorStatus as ɵChangeDetectorStatus, isDefaultChangeDetectionStrategy as ɵisDefaultChangeDetectionStrategy} from './change_detection/constants';
|
||||
export {Console as ɵConsole} from './console';
|
||||
export {inject, setCurrentInjector as ɵsetCurrentInjector, ɵɵinject} from './di/injector_compatibility';
|
||||
export {getInjectableDef as ɵgetInjectableDef, ɵɵInjectableDef as ɵɵInjectableDef, ɵɵInjectorDef} from './di/interface/defs';
|
||||
export {inject, setCurrentInjector as ɵsetCurrentInjector, Δinject} from './di/injector_compatibility';
|
||||
export {getInjectableDef as ɵgetInjectableDef, ΔInjectableDef as ΔInjectableDef, ΔInjectorDef} from './di/interface/defs';
|
||||
export {APP_ROOT as ɵAPP_ROOT} from './di/scope';
|
||||
export {ivyEnabled as ɵivyEnabled} from './ivy_switch';
|
||||
export {ComponentFactory as ɵComponentFactory} from './linker/component_factory';
|
||||
|
|
|
@ -8,11 +8,11 @@
|
|||
|
||||
// clang-format off
|
||||
export {
|
||||
ɵɵdefineBase,
|
||||
ɵɵdefineComponent,
|
||||
ɵɵdefineDirective,
|
||||
ɵɵdefinePipe,
|
||||
ɵɵdefineNgModule,
|
||||
ΔdefineBase,
|
||||
ΔdefineComponent,
|
||||
ΔdefineDirective,
|
||||
ΔdefinePipe,
|
||||
ΔdefineNgModule,
|
||||
detectChanges as ɵdetectChanges,
|
||||
renderComponent as ɵrenderComponent,
|
||||
AttributeMarker as ɵAttributeMarker,
|
||||
|
@ -21,16 +21,16 @@ export {
|
|||
ComponentRef as ɵRender3ComponentRef,
|
||||
DirectiveType as ɵDirectiveType,
|
||||
RenderFlags as ɵRenderFlags,
|
||||
ɵɵdirectiveInject,
|
||||
ɵɵinjectAttribute,
|
||||
ɵɵgetFactoryOf,
|
||||
ɵɵgetInheritedFactory,
|
||||
ɵɵsetComponentScope,
|
||||
ɵɵsetNgModuleScope,
|
||||
ɵɵtemplateRefExtractor,
|
||||
ɵɵProvidersFeature,
|
||||
ɵɵInheritDefinitionFeature,
|
||||
ɵɵNgOnChangesFeature,
|
||||
ΔdirectiveInject,
|
||||
ΔinjectAttribute,
|
||||
ΔgetFactoryOf,
|
||||
ΔgetInheritedFactory,
|
||||
ΔsetComponentScope,
|
||||
ΔsetNgModuleScope,
|
||||
ΔtemplateRefExtractor,
|
||||
ΔProvidersFeature,
|
||||
ΔInheritDefinitionFeature,
|
||||
ΔNgOnChangesFeature,
|
||||
LifecycleHooksFeature as ɵLifecycleHooksFeature,
|
||||
NgModuleType as ɵNgModuleType,
|
||||
NgModuleRef as ɵRender3NgModuleRef,
|
||||
|
@ -38,114 +38,114 @@ export {
|
|||
markDirty as ɵmarkDirty,
|
||||
NgModuleFactory as ɵNgModuleFactory,
|
||||
NO_CHANGE as ɵNO_CHANGE,
|
||||
ɵɵcontainer,
|
||||
ɵɵnextContext,
|
||||
ɵɵelementStart,
|
||||
ɵɵnamespaceHTML,
|
||||
ɵɵnamespaceMathML,
|
||||
ɵɵnamespaceSVG,
|
||||
ɵɵelement,
|
||||
ɵɵlistener,
|
||||
ɵɵtext,
|
||||
ɵɵembeddedViewStart,
|
||||
ɵɵprojection,
|
||||
ɵɵbind,
|
||||
ɵɵinterpolation1,
|
||||
ɵɵinterpolation2,
|
||||
ɵɵinterpolation3,
|
||||
ɵɵinterpolation4,
|
||||
ɵɵinterpolation5,
|
||||
ɵɵinterpolation6,
|
||||
ɵɵinterpolation7,
|
||||
ɵɵinterpolation8,
|
||||
ɵɵinterpolationV,
|
||||
ɵɵpipeBind1,
|
||||
ɵɵpipeBind2,
|
||||
ɵɵpipeBind3,
|
||||
ɵɵpipeBind4,
|
||||
ɵɵpipeBindV,
|
||||
ɵɵpureFunction0,
|
||||
ɵɵpureFunction1,
|
||||
ɵɵpureFunction2,
|
||||
ɵɵpureFunction3,
|
||||
ɵɵpureFunction4,
|
||||
ɵɵpureFunction5,
|
||||
ɵɵpureFunction6,
|
||||
ɵɵpureFunction7,
|
||||
ɵɵpureFunction8,
|
||||
ɵɵpureFunctionV,
|
||||
ɵɵgetCurrentView,
|
||||
Δcontainer,
|
||||
ΔnextContext,
|
||||
ΔelementStart,
|
||||
ΔnamespaceHTML,
|
||||
ΔnamespaceMathML,
|
||||
ΔnamespaceSVG,
|
||||
Δelement,
|
||||
Δlistener,
|
||||
Δtext,
|
||||
ΔembeddedViewStart,
|
||||
Δprojection,
|
||||
Δbind,
|
||||
Δinterpolation1,
|
||||
Δinterpolation2,
|
||||
Δinterpolation3,
|
||||
Δinterpolation4,
|
||||
Δinterpolation5,
|
||||
Δinterpolation6,
|
||||
Δinterpolation7,
|
||||
Δinterpolation8,
|
||||
ΔinterpolationV,
|
||||
ΔpipeBind1,
|
||||
ΔpipeBind2,
|
||||
ΔpipeBind3,
|
||||
ΔpipeBind4,
|
||||
ΔpipeBindV,
|
||||
ΔpureFunction0,
|
||||
ΔpureFunction1,
|
||||
ΔpureFunction2,
|
||||
ΔpureFunction3,
|
||||
ΔpureFunction4,
|
||||
ΔpureFunction5,
|
||||
ΔpureFunction6,
|
||||
ΔpureFunction7,
|
||||
ΔpureFunction8,
|
||||
ΔpureFunctionV,
|
||||
ΔgetCurrentView,
|
||||
getDirectives as ɵgetDirectives,
|
||||
getHostElement as ɵgetHostElement,
|
||||
ɵɵrestoreView,
|
||||
ɵɵcontainerRefreshStart,
|
||||
ɵɵcontainerRefreshEnd,
|
||||
ɵɵqueryRefresh,
|
||||
ɵɵviewQuery,
|
||||
ɵɵstaticViewQuery,
|
||||
ɵɵstaticContentQuery,
|
||||
ɵɵloadViewQuery,
|
||||
ɵɵcontentQuery,
|
||||
ɵɵloadContentQuery,
|
||||
ɵɵelementEnd,
|
||||
ɵɵelementProperty,
|
||||
ɵɵproperty,
|
||||
ɵɵpropertyInterpolate,
|
||||
ɵɵpropertyInterpolate1,
|
||||
ɵɵpropertyInterpolate2,
|
||||
ɵɵpropertyInterpolate3,
|
||||
ɵɵpropertyInterpolate4,
|
||||
ɵɵpropertyInterpolate5,
|
||||
ɵɵpropertyInterpolate6,
|
||||
ɵɵpropertyInterpolate7,
|
||||
ɵɵpropertyInterpolate8,
|
||||
ɵɵpropertyInterpolateV,
|
||||
ɵɵcomponentHostSyntheticProperty,
|
||||
ɵɵcomponentHostSyntheticListener,
|
||||
ɵɵprojectionDef,
|
||||
ɵɵreference,
|
||||
ɵɵenableBindings,
|
||||
ɵɵdisableBindings,
|
||||
ɵɵallocHostVars,
|
||||
ɵɵelementAttribute,
|
||||
ɵɵelementContainerStart,
|
||||
ɵɵelementContainerEnd,
|
||||
ɵɵstyling,
|
||||
ɵɵstyleMap,
|
||||
ɵɵclassMap,
|
||||
ɵɵstyleProp,
|
||||
ɵɵstylingApply,
|
||||
ɵɵclassProp,
|
||||
ɵɵelementHostAttrs,
|
||||
ΔrestoreView,
|
||||
ΔcontainerRefreshStart,
|
||||
ΔcontainerRefreshEnd,
|
||||
ΔqueryRefresh,
|
||||
ΔviewQuery,
|
||||
ΔstaticViewQuery,
|
||||
ΔstaticContentQuery,
|
||||
ΔloadViewQuery,
|
||||
ΔcontentQuery,
|
||||
ΔloadContentQuery,
|
||||
ΔelementEnd,
|
||||
ΔelementProperty,
|
||||
Δproperty,
|
||||
ΔpropertyInterpolate,
|
||||
ΔpropertyInterpolate1,
|
||||
ΔpropertyInterpolate2,
|
||||
ΔpropertyInterpolate3,
|
||||
ΔpropertyInterpolate4,
|
||||
ΔpropertyInterpolate5,
|
||||
ΔpropertyInterpolate6,
|
||||
ΔpropertyInterpolate7,
|
||||
ΔpropertyInterpolate8,
|
||||
ΔpropertyInterpolateV,
|
||||
ΔcomponentHostSyntheticProperty,
|
||||
ΔcomponentHostSyntheticListener,
|
||||
ΔprojectionDef,
|
||||
Δreference,
|
||||
ΔenableBindings,
|
||||
ΔdisableBindings,
|
||||
ΔallocHostVars,
|
||||
ΔelementAttribute,
|
||||
ΔelementContainerStart,
|
||||
ΔelementContainerEnd,
|
||||
Δstyling,
|
||||
ΔstyleMap,
|
||||
ΔclassMap,
|
||||
ΔstyleProp,
|
||||
ΔstylingApply,
|
||||
ΔclassProp,
|
||||
ΔelementHostAttrs,
|
||||
|
||||
ɵɵselect,
|
||||
ɵɵtextBinding,
|
||||
ɵɵtemplate,
|
||||
ɵɵembeddedViewEnd,
|
||||
Δselect,
|
||||
ΔtextBinding,
|
||||
Δtemplate,
|
||||
ΔembeddedViewEnd,
|
||||
store as ɵstore,
|
||||
ɵɵload,
|
||||
ɵɵpipe,
|
||||
ɵɵBaseDef,
|
||||
Δload,
|
||||
Δpipe,
|
||||
ΔBaseDef,
|
||||
ComponentDef as ɵComponentDef,
|
||||
ɵɵComponentDefWithMeta,
|
||||
ΔComponentDefWithMeta,
|
||||
DirectiveDef as ɵDirectiveDef,
|
||||
ɵɵDirectiveDefWithMeta,
|
||||
ΔDirectiveDefWithMeta,
|
||||
PipeDef as ɵPipeDef,
|
||||
ɵɵPipeDefWithMeta,
|
||||
ΔPipeDefWithMeta,
|
||||
whenRendered as ɵwhenRendered,
|
||||
ɵɵi18n,
|
||||
ɵɵi18nAttributes,
|
||||
ɵɵi18nExp,
|
||||
ɵɵi18nStart,
|
||||
ɵɵi18nEnd,
|
||||
ɵɵi18nApply,
|
||||
ɵɵi18nPostprocess,
|
||||
Δi18n,
|
||||
Δi18nAttributes,
|
||||
Δi18nExp,
|
||||
Δi18nStart,
|
||||
Δi18nEnd,
|
||||
Δi18nApply,
|
||||
Δi18nPostprocess,
|
||||
i18nConfigureLocalize as ɵi18nConfigureLocalize,
|
||||
ɵɵi18nLocalize,
|
||||
Δi18nLocalize,
|
||||
setClassMetadata as ɵsetClassMetadata,
|
||||
ɵɵresolveWindow,
|
||||
ɵɵresolveDocument,
|
||||
ɵɵresolveBody,
|
||||
ΔresolveWindow,
|
||||
ΔresolveDocument,
|
||||
ΔresolveBody,
|
||||
} from './render3/index';
|
||||
|
||||
|
||||
|
@ -167,18 +167,18 @@ export {
|
|||
|
||||
export {
|
||||
NgModuleDef as ɵNgModuleDef,
|
||||
ɵɵNgModuleDefWithMeta,
|
||||
ΔNgModuleDefWithMeta,
|
||||
NgModuleTransitiveScopes as ɵNgModuleTransitiveScopes,
|
||||
} from './metadata/ng_module';
|
||||
|
||||
export {
|
||||
ɵɵsanitizeHtml,
|
||||
ɵɵsanitizeStyle,
|
||||
ɵɵdefaultStyleSanitizer,
|
||||
ɵɵsanitizeScript,
|
||||
ɵɵsanitizeUrl,
|
||||
ɵɵsanitizeResourceUrl,
|
||||
ɵɵsanitizeUrlOrResourceUrl,
|
||||
ΔsanitizeHtml,
|
||||
ΔsanitizeStyle,
|
||||
ΔdefaultStyleSanitizer,
|
||||
ΔsanitizeScript,
|
||||
ΔsanitizeUrl,
|
||||
ΔsanitizeResourceUrl,
|
||||
ΔsanitizeUrlOrResourceUrl,
|
||||
} from './sanitization/sanitization';
|
||||
|
||||
export {
|
||||
|
|
|
@ -14,11 +14,11 @@
|
|||
|
||||
export * from './metadata';
|
||||
export {InjectFlags} from './interface/injector';
|
||||
export {ɵɵdefineInjectable, defineInjectable, ɵɵdefineInjector, InjectableType, InjectorType} from './interface/defs';
|
||||
export {ΔdefineInjectable, defineInjectable, ΔdefineInjector, InjectableType, InjectorType} from './interface/defs';
|
||||
export {forwardRef, resolveForwardRef, ForwardRefFn} from './forward_ref';
|
||||
export {Injectable, InjectableDecorator, InjectableProvider} from './injectable';
|
||||
export {Injector} from './injector';
|
||||
export {ɵɵinject, inject, INJECTOR} from './injector_compatibility';
|
||||
export {Δinject, inject, INJECTOR} from './injector_compatibility';
|
||||
export {ReflectiveInjector} from './reflective_injector';
|
||||
export {StaticProvider, ValueProvider, ConstructorSansProvider, ExistingProvider, FactoryProvider, Provider, TypeProvider, ClassProvider} from './interface/provider';
|
||||
export {ResolvedReflectiveFactory, ResolvedReflectiveProvider} from './reflective_provider';
|
||||
|
|
|
@ -9,7 +9,7 @@
|
|||
import {Type} from '../interface/type';
|
||||
import {TypeDecorator, makeDecorator} from '../util/decorators';
|
||||
|
||||
import {InjectableType, getInjectableDef, ɵɵInjectableDef, ɵɵdefineInjectable} from './interface/defs';
|
||||
import {InjectableType, getInjectableDef, ΔInjectableDef, ΔdefineInjectable} from './interface/defs';
|
||||
import {ClassSansProvider, ConstructorSansProvider, ExistingSansProvider, FactorySansProvider, StaticClassSansProvider, ValueSansProvider} from './interface/provider';
|
||||
import {compileInjectable as render3CompileInjectable} from './jit/injectable';
|
||||
import {convertInjectableProviderToFactory} from './util';
|
||||
|
@ -80,7 +80,7 @@ export const Injectable: InjectableDecorator = makeDecorator(
|
|||
*
|
||||
* @publicApi
|
||||
*/
|
||||
export interface InjectableType<T> extends Type<T> { ngInjectableDef: ɵɵInjectableDef<T>; }
|
||||
export interface InjectableType<T> extends Type<T> { ngInjectableDef: ΔInjectableDef<T>; }
|
||||
|
||||
/**
|
||||
* Supports @Injectable() in JIT mode for Render2.
|
||||
|
@ -89,7 +89,7 @@ function render2CompileInjectable(
|
|||
injectableType: InjectableType<any>,
|
||||
options: {providedIn?: Type<any>| 'root' | null} & InjectableProvider): void {
|
||||
if (options && options.providedIn !== undefined && !getInjectableDef(injectableType)) {
|
||||
injectableType.ngInjectableDef = ɵɵdefineInjectable({
|
||||
injectableType.ngInjectableDef = ΔdefineInjectable({
|
||||
providedIn: options.providedIn,
|
||||
factory: convertInjectableProviderToFactory(injectableType, options),
|
||||
});
|
||||
|
|
|
@ -8,7 +8,7 @@
|
|||
|
||||
import {Type} from '../interface/type';
|
||||
|
||||
import {ɵɵdefineInjectable} from './interface/defs';
|
||||
import {ΔdefineInjectable} from './interface/defs';
|
||||
|
||||
/**
|
||||
* Creates a token that can be used in a DI Provider.
|
||||
|
@ -67,7 +67,7 @@ export class InjectionToken<T> {
|
|||
// We are using it to assign `-1` which is used to identify `Injector`.
|
||||
(this as any).__NG_ELEMENT_ID__ = options;
|
||||
} else if (options !== undefined) {
|
||||
this.ngInjectableDef = ɵɵdefineInjectable({
|
||||
this.ngInjectableDef = ΔdefineInjectable({
|
||||
providedIn: options.providedIn || 'root',
|
||||
factory: options.factory,
|
||||
});
|
||||
|
|
|
@ -11,8 +11,8 @@ import {stringify} from '../util/stringify';
|
|||
|
||||
import {resolveForwardRef} from './forward_ref';
|
||||
import {InjectionToken} from './injection_token';
|
||||
import {INJECTOR, NG_TEMP_TOKEN_PATH, NullInjector, THROW_IF_NOT_FOUND, USE_VALUE, catchInjectorError, formatError, ɵɵinject} from './injector_compatibility';
|
||||
import {ɵɵdefineInjectable} from './interface/defs';
|
||||
import {INJECTOR, NG_TEMP_TOKEN_PATH, NullInjector, THROW_IF_NOT_FOUND, USE_VALUE, catchInjectorError, formatError, Δinject} from './injector_compatibility';
|
||||
import {ΔdefineInjectable} from './interface/defs';
|
||||
import {InjectFlags} from './interface/injector';
|
||||
import {ConstructorProvider, ExistingProvider, FactoryProvider, StaticClassProvider, StaticProvider, ValueProvider} from './interface/provider';
|
||||
import {Inject, Optional, Self, SkipSelf} from './metadata';
|
||||
|
@ -88,9 +88,9 @@ export abstract class Injector {
|
|||
}
|
||||
|
||||
/** @nocollapse */
|
||||
static ngInjectableDef = ɵɵdefineInjectable({
|
||||
static ngInjectableDef = ΔdefineInjectable({
|
||||
providedIn: 'any' as any,
|
||||
factory: () => ɵɵinject(INJECTOR),
|
||||
factory: () => Δinject(INJECTOR),
|
||||
});
|
||||
|
||||
/**
|
||||
|
|
|
@ -13,7 +13,7 @@ import {stringify} from '../util/stringify';
|
|||
import {resolveForwardRef} from './forward_ref';
|
||||
import {InjectionToken} from './injection_token';
|
||||
import {Injector} from './injector';
|
||||
import {getInjectableDef, ɵɵInjectableDef} from './interface/defs';
|
||||
import {getInjectableDef, ΔInjectableDef} from './interface/defs';
|
||||
import {InjectFlags} from './interface/injector';
|
||||
import {ValueProvider} from './interface/provider';
|
||||
import {Inject, Optional, Self, SkipSelf} from './metadata';
|
||||
|
@ -107,10 +107,9 @@ export function injectInjectorOnly<T>(
|
|||
* @see inject
|
||||
* @codeGenApi
|
||||
*/
|
||||
export function ɵɵinject<T>(token: Type<T>| InjectionToken<T>): T;
|
||||
export function ɵɵinject<T>(token: Type<T>| InjectionToken<T>, flags?: InjectFlags): T|null;
|
||||
export function ɵɵinject<T>(token: Type<T>| InjectionToken<T>, flags = InjectFlags.Default): T|
|
||||
null {
|
||||
export function Δinject<T>(token: Type<T>| InjectionToken<T>): T;
|
||||
export function Δinject<T>(token: Type<T>| InjectionToken<T>, flags?: InjectFlags): T|null;
|
||||
export function Δinject<T>(token: Type<T>| InjectionToken<T>, flags = InjectFlags.Default): T|null {
|
||||
return (_injectImplementation || injectInjectorOnly)(token, flags);
|
||||
}
|
||||
|
||||
|
@ -138,7 +137,7 @@ export function ɵɵinject<T>(token: Type<T>| InjectionToken<T>, flags = InjectF
|
|||
*
|
||||
* @publicApi
|
||||
*/
|
||||
export const inject = ɵɵinject;
|
||||
export const inject = Δinject;
|
||||
|
||||
/**
|
||||
* Injects `root` tokens in limp mode.
|
||||
|
@ -149,7 +148,7 @@ export const inject = ɵɵinject;
|
|||
*/
|
||||
export function injectRootLimpMode<T>(
|
||||
token: Type<T>| InjectionToken<T>, notFoundValue: T | undefined, flags: InjectFlags): T|null {
|
||||
const injectableDef: ɵɵInjectableDef<T>|null = getInjectableDef(token);
|
||||
const injectableDef: ΔInjectableDef<T>|null = getInjectableDef(token);
|
||||
if (injectableDef && injectableDef.providedIn == 'root') {
|
||||
return injectableDef.value === undefined ? injectableDef.value = injectableDef.factory() :
|
||||
injectableDef.value;
|
||||
|
@ -186,9 +185,9 @@ export function injectArgs(types: (Type<any>| InjectionToken<any>| any[])[]): an
|
|||
}
|
||||
}
|
||||
|
||||
args.push(ɵɵinject(type !, flags));
|
||||
args.push(Δinject(type !, flags));
|
||||
} else {
|
||||
args.push(ɵɵinject(arg));
|
||||
args.push(Δinject(arg));
|
||||
}
|
||||
}
|
||||
return args;
|
||||
|
|
|
@ -26,7 +26,7 @@ import {ClassProvider, ConstructorProvider, ExistingProvider, FactoryProvider, S
|
|||
*
|
||||
* @publicApi
|
||||
*/
|
||||
export interface ɵɵInjectableDef<T> {
|
||||
export interface ΔInjectableDef<T> {
|
||||
/**
|
||||
* Specifies that the given type belongs to a particular injector:
|
||||
* - `InjectorType` such as `NgModule`,
|
||||
|
@ -60,7 +60,7 @@ export interface ɵɵInjectableDef<T> {
|
|||
*
|
||||
* @publicApi
|
||||
*/
|
||||
export interface ɵɵInjectorDef<T> {
|
||||
export interface ΔInjectorDef<T> {
|
||||
factory: () => T;
|
||||
|
||||
// TODO(alxhub): Narrow down the type here once decorators properly change the return type of the
|
||||
|
@ -131,21 +131,21 @@ export interface InjectorTypeWithProviders<T> {
|
|||
*
|
||||
* @publicApi
|
||||
*/
|
||||
export function ɵɵdefineInjectable<T>(opts: {
|
||||
export function ΔdefineInjectable<T>(opts: {
|
||||
providedIn?: Type<any>| 'root' | 'any' | null,
|
||||
factory: () => T,
|
||||
}): never {
|
||||
return ({
|
||||
providedIn: opts.providedIn as any || null, factory: opts.factory, value: undefined,
|
||||
} as ɵɵInjectableDef<T>) as never;
|
||||
} as ΔInjectableDef<T>) as never;
|
||||
}
|
||||
|
||||
/**
|
||||
* @deprecated in v8, delete after v10. This API should be used only be generated code, and that
|
||||
* code should now use ɵɵdefineInjectable instead.
|
||||
* code should now use ΔdefineInjectable instead.
|
||||
* @publicApi
|
||||
*/
|
||||
export const defineInjectable = ɵɵdefineInjectable;
|
||||
export const defineInjectable = ΔdefineInjectable;
|
||||
|
||||
/**
|
||||
* Construct an `InjectorDef` which configures an injector.
|
||||
|
@ -167,11 +167,11 @@ export const defineInjectable = ɵɵdefineInjectable;
|
|||
*
|
||||
* @publicApi
|
||||
*/
|
||||
export function ɵɵdefineInjector(options: {factory: () => any, providers?: any[], imports?: any[]}):
|
||||
export function ΔdefineInjector(options: {factory: () => any, providers?: any[], imports?: any[]}):
|
||||
never {
|
||||
return ({
|
||||
factory: options.factory, providers: options.providers || [], imports: options.imports || [],
|
||||
} as ɵɵInjectorDef<any>) as never;
|
||||
} as ΔInjectorDef<any>) as never;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -179,7 +179,7 @@ export function ɵɵdefineInjector(options: {factory: () => any, providers?: any
|
|||
*
|
||||
* @param type type which may have `ngInjectableDef`
|
||||
*/
|
||||
export function getInjectableDef<T>(type: any): ɵɵInjectableDef<T>|null {
|
||||
export function getInjectableDef<T>(type: any): ΔInjectableDef<T>|null {
|
||||
return type && type.hasOwnProperty(NG_INJECTABLE_DEF) ? (type as any)[NG_INJECTABLE_DEF] : null;
|
||||
}
|
||||
|
||||
|
@ -188,7 +188,7 @@ export function getInjectableDef<T>(type: any): ɵɵInjectableDef<T>|null {
|
|||
*
|
||||
* @param type type which may have `ngInjectorDef`
|
||||
*/
|
||||
export function getInjectorDef<T>(type: any): ɵɵInjectorDef<T>|null {
|
||||
export function getInjectorDef<T>(type: any): ΔInjectorDef<T>|null {
|
||||
return type && type.hasOwnProperty(NG_INJECTOR_DEF) ? (type as any)[NG_INJECTOR_DEF] : null;
|
||||
}
|
||||
|
||||
|
|
|
@ -7,8 +7,8 @@
|
|||
*/
|
||||
|
||||
import {Type} from '../../interface/type';
|
||||
import {ɵɵinject} from '../injector_compatibility';
|
||||
import {getInjectableDef, getInjectorDef, ɵɵdefineInjectable, ɵɵdefineInjector} from '../interface/defs';
|
||||
import {Δinject} from '../injector_compatibility';
|
||||
import {getInjectableDef, getInjectorDef, ΔdefineInjectable, ΔdefineInjector} from '../interface/defs';
|
||||
|
||||
|
||||
|
||||
|
@ -18,10 +18,10 @@ import {getInjectableDef, getInjectorDef, ɵɵdefineInjectable, ɵɵdefineInject
|
|||
* This should be kept up to date with the public exports of @angular/core.
|
||||
*/
|
||||
export const angularCoreDiEnv: {[name: string]: Function} = {
|
||||
'ɵɵdefineInjectable': ɵɵdefineInjectable,
|
||||
'ɵɵdefineInjector': ɵɵdefineInjector,
|
||||
'ɵɵinject': ɵɵinject,
|
||||
'ɵɵgetFactoryOf': getFactoryOf,
|
||||
'ΔdefineInjectable': ΔdefineInjectable,
|
||||
'ΔdefineInjector': ΔdefineInjector,
|
||||
'Δinject': Δinject,
|
||||
'ΔgetFactoryOf': getFactoryOf,
|
||||
};
|
||||
|
||||
function getFactoryOf<T>(type: Type<any>): ((type: Type<T>| null) => T)|null {
|
||||
|
|
|
@ -14,8 +14,8 @@ import {stringify} from '../util/stringify';
|
|||
import {resolveForwardRef} from './forward_ref';
|
||||
import {InjectionToken} from './injection_token';
|
||||
import {Injector} from './injector';
|
||||
import {INJECTOR, NG_TEMP_TOKEN_PATH, NullInjector, THROW_IF_NOT_FOUND, USE_VALUE, catchInjectorError, injectArgs, setCurrentInjector, ɵɵinject} from './injector_compatibility';
|
||||
import {InjectableType, InjectorType, InjectorTypeWithProviders, getInjectableDef, getInjectorDef, ɵɵInjectableDef} from './interface/defs';
|
||||
import {INJECTOR, NG_TEMP_TOKEN_PATH, NullInjector, THROW_IF_NOT_FOUND, USE_VALUE, catchInjectorError, injectArgs, setCurrentInjector, Δinject} from './injector_compatibility';
|
||||
import {InjectableType, InjectorType, InjectorTypeWithProviders, getInjectableDef, getInjectorDef, ΔInjectableDef} from './interface/defs';
|
||||
import {InjectFlags} from './interface/injector';
|
||||
import {ClassProvider, ConstructorProvider, ExistingProvider, FactoryProvider, StaticClassProvider, StaticProvider, TypeProvider, ValueProvider} from './interface/provider';
|
||||
import {APP_ROOT} from './scope';
|
||||
|
@ -366,7 +366,7 @@ export class R3Injector {
|
|||
return record.value as T;
|
||||
}
|
||||
|
||||
private injectableDefInScope(def: ɵɵInjectableDef<any>): boolean {
|
||||
private injectableDefInScope(def: ΔInjectableDef<any>): boolean {
|
||||
if (!def.providedIn) {
|
||||
return false;
|
||||
} else if (typeof def.providedIn === 'string') {
|
||||
|
@ -423,7 +423,7 @@ export function providerToFactory(
|
|||
if (isValueProvider(provider)) {
|
||||
factory = () => resolveForwardRef(provider.useValue);
|
||||
} else if (isExistingProvider(provider)) {
|
||||
factory = () => ɵɵinject(resolveForwardRef(provider.useExisting));
|
||||
factory = () => Δinject(resolveForwardRef(provider.useExisting));
|
||||
} else if (isFactoryProvider(provider)) {
|
||||
factory = () => provider.useFactory(...injectArgs(provider.deps || []));
|
||||
} else {
|
||||
|
|
|
@ -10,7 +10,7 @@ import {Type} from '../interface/type';
|
|||
import {ReflectionCapabilities} from '../reflection/reflection_capabilities';
|
||||
import {getClosureSafeProperty} from '../util/property';
|
||||
|
||||
import {injectArgs, ɵɵinject} from './injector_compatibility';
|
||||
import {injectArgs, Δinject} from './injector_compatibility';
|
||||
import {ClassSansProvider, ConstructorSansProvider, ExistingSansProvider, FactorySansProvider, StaticClassSansProvider, ValueProvider, ValueSansProvider} from './interface/provider';
|
||||
|
||||
const USE_VALUE =
|
||||
|
@ -32,7 +32,7 @@ export function convertInjectableProviderToFactory(
|
|||
return () => valueProvider.useValue;
|
||||
} else if ((provider as ExistingSansProvider).useExisting) {
|
||||
const existingProvider = (provider as ExistingSansProvider);
|
||||
return () => ɵɵinject(existingProvider.useExisting);
|
||||
return () => Δinject(existingProvider.useExisting);
|
||||
} else if ((provider as FactorySansProvider).useFactory) {
|
||||
const factoryProvider = (provider as FactorySansProvider);
|
||||
return () => factoryProvider.useFactory(...injectArgs(factoryProvider.deps || EMPTY_ARRAY));
|
||||
|
|
|
@ -7,7 +7,7 @@
|
|||
*/
|
||||
|
||||
import {ApplicationRef} from '../application_ref';
|
||||
import {InjectorType, ɵɵdefineInjector} from '../di/interface/defs';
|
||||
import {InjectorType, ΔdefineInjector} from '../di/interface/defs';
|
||||
import {Provider} from '../di/interface/provider';
|
||||
import {convertInjectableProviderToFactory} from '../di/util';
|
||||
import {Type} from '../interface/type';
|
||||
|
@ -35,7 +35,7 @@ export interface NgModuleTransitiveScopes {
|
|||
/**
|
||||
* @publicApi
|
||||
*/
|
||||
export type ɵɵNgModuleDefWithMeta<T, Declarations, Imports, Exports> = NgModuleDef<T>;
|
||||
export type ΔNgModuleDefWithMeta<T, Declarations, Imports, Exports> = NgModuleDef<T>;
|
||||
|
||||
/**
|
||||
* Runtime link information for NgModules.
|
||||
|
@ -43,7 +43,7 @@ export type ɵɵNgModuleDefWithMeta<T, Declarations, Imports, Exports> = NgModul
|
|||
* This is the internal data structure used by the runtime to assemble components, directives,
|
||||
* pipes, and injectors.
|
||||
*
|
||||
* NOTE: Always use `ɵɵdefineNgModule` function to create this object,
|
||||
* NOTE: Always use `ΔdefineNgModule` function to create this object,
|
||||
* never create the object directly since the shape of this object
|
||||
* can change between versions.
|
||||
*/
|
||||
|
@ -350,7 +350,7 @@ function preR3NgModuleCompile(moduleType: InjectorType<any>, metadata: NgModule)
|
|||
imports = [...imports, metadata.exports];
|
||||
}
|
||||
|
||||
moduleType.ngInjectorDef = ɵɵdefineInjector({
|
||||
moduleType.ngInjectorDef = ΔdefineInjector({
|
||||
factory: convertInjectableProviderToFactory(moduleType, {useClass: moduleType}),
|
||||
providers: metadata && metadata.providers,
|
||||
imports: imports,
|
||||
|
|
|
@ -21,10 +21,10 @@
|
|||
* The below symbols are used for @Injectable and @NgModule compilation.
|
||||
*/
|
||||
|
||||
export {ɵɵinject} from './di/injector_compatibility';
|
||||
export {ɵɵInjectableDef, ɵɵInjectorDef, ɵɵdefineInjectable, ɵɵdefineInjector} from './di/interface/defs';
|
||||
export {NgModuleDef, ɵɵNgModuleDefWithMeta} from './metadata/ng_module';
|
||||
export {ɵɵdefineNgModule} from './render3/definition';
|
||||
export {Δinject} from './di/injector_compatibility';
|
||||
export {ΔInjectableDef, ΔInjectorDef, ΔdefineInjectable, ΔdefineInjector} from './di/interface/defs';
|
||||
export {NgModuleDef, ΔNgModuleDefWithMeta} from './metadata/ng_module';
|
||||
export {ΔdefineNgModule} from './render3/definition';
|
||||
export {setClassMetadata} from './render3/metadata';
|
||||
export {NgModuleFactory} from './render3/ng_module_ref';
|
||||
|
||||
|
|
|
@ -1,11 +1,11 @@
|
|||
# Code Gen API
|
||||
|
||||
### Prefix ɵɵ
|
||||
### Prefix Δ
|
||||
|
||||
Ivy exports a number of functions prefixed with `ɵɵ`, for example `ɵɵelementStart`, or `ɵɵinject`, et al. These functions are part of API required for code generation by the Angular compiler. These functions are called by generated code, and they must be publicly exposed in order to be consumed by this generated code. **They are not meant for developer consumption**. The reason they are prefixed with `ɵɵ` is not only to identify them as different from other functions, but also to make them not show up at the top of IDE code completion in environments such as Visual Studio code.
|
||||
Ivy exports a number of functions prefixed with `Δ`, for example `ΔelementStart`, or `Δinject`, et al. These functions are part of API required for code generation by the Angular compiler. These functions are called by generated code, and they must be publicly exposed in order to be consumed by this generated code. **They are not meant for developer consumption**. The reason they are prefixed with `Δ` is not only to identify them as different from other functions, but also to make them not show up at the top of IDE code completion in environments such as Visual Studio code.
|
||||
|
||||
|
||||
### Guidance
|
||||
|
||||
- Do not use `ɵɵ` functions directly. They are meant to be used in generated code.
|
||||
- Do not create new `ɵɵ` functions, it's not a convention that Angular consumes, and it is liable to confuse other developers into thinking consuming Angular's `ɵɵ` functions is a good pattern to follow.
|
||||
- Do not use `Δ` functions directly. They are meant to be used in generated code.
|
||||
- Do not create new `Δ` functions, it's not a convention that Angular consumes, and it is liable to confuse other developers into thinking consuming Angular's `Δ` functions is a good pattern to follow.
|
||||
|
|
|
@ -10,8 +10,8 @@ We currently expect Ivy to remain behind the flag until it's feature complete an
|
|||
|
||||
The work can be divided into three categories:
|
||||
- `@angular/compiler-cli`: TypeScript transformer pipeline which includes two command line tools:
|
||||
- `ngtsc`: (Angular TypeScript Compiler) Angular compiler which strips out `@Component` (and friends) and replaces it with `ɵɵdefineComponent` (and friends).
|
||||
- `ngcc`: (Angular Compatibility Compiler) NPM upgrade compiler which reads the `STORING_METADATA_IN_D.TS.json` files and `.js` files and adds `ɵɵdefineComponent` (and friends) into the `node_module`. This in effect converts a pre-ivy module into ivy module.
|
||||
- `ngtsc`: (Angular TypeScript Compiler) Angular compiler which strips out `@Component` (and friends) and replaces it with `ΔdefineComponent` (and friends).
|
||||
- `ngcc`: (Angular Compatibility Compiler) NPM upgrade compiler which reads the `STORING_METADATA_IN_D.TS.json` files and `.js` files and adds `ΔdefineComponent` (and friends) into the `node_module`. This in effect converts a pre-ivy module into ivy module.
|
||||
- `@angular/compiler`: Ivy Compiler which converts decorator into ivy
|
||||
- `@angular/core`: Decorators which can be patched with `@angular/compiler`.
|
||||
|
||||
|
@ -20,7 +20,7 @@ The work can be divided into three categories:
|
|||
### `ngtsc` TSC compiler transformer
|
||||
|
||||
TSC transformer which removes and converts `@Pipe`, `@Component`, `@Directive` and `@NgModule`
|
||||
to the corresponding `ɵɵdefinePipe`, `ɵɵdefineComponent`, `ɵɵdefineDirective` and `ɵɵdefineInjector`.
|
||||
to the corresponding `ΔdefinePipe`, `ΔdefineComponent`, `ΔdefineDirective` and `ΔdefineInjector`.
|
||||
|
||||
- ✅ Basic setup of the transformer into `tsc`
|
||||
- ✅ Can read STORING_METADATA_IN_D.TS from `.d.ts` (see: [STORING_METADATA_IN_D.TS.md](./STORING_METADATA_IN_D.TS.md))
|
||||
|
@ -40,19 +40,19 @@ A tool which "upgrades" `node_module` compiled with non-ivy `ngc` into ivy compl
|
|||
|
||||
## `@angular/compiler` changes
|
||||
|
||||
- ✅ Component compilation: Translates `@Component` => `ɵɵdefineComponent`
|
||||
- ✅ Component compilation: Translates `@Component` => `ΔdefineComponent`
|
||||
- ✅ `TemplateCompiler` (current known as `ViewCompiler`)
|
||||
- ✅ `StyleCompiler`
|
||||
- ✅ `PipeCompiler`: Translates `@Pipe` => `ɵɵdefinePipe`
|
||||
- ✅ `DirectiveCompiler`: Translates `@Directive` => `ɵɵdefineDirective`
|
||||
- ✅ `InjectableCompiler`: Translates `@Injectable` => `ɵɵdefineInjectable`
|
||||
- ✅ `NgModuleCompiler`: Translates `@NgModule` => `ɵɵdefineInjector` (and `ɵɵdefineNgModule` only in jit)
|
||||
- ✅ `PipeCompiler`: Translates `@Pipe` => `ΔdefinePipe`
|
||||
- ✅ `DirectiveCompiler`: Translates `@Directive` => `ΔdefineDirective`
|
||||
- ✅ `InjectableCompiler`: Translates `@Injectable` => `ΔdefineInjectable`
|
||||
- ✅ `NgModuleCompiler`: Translates `@NgModule` => `ΔdefineInjector` (and `ΔdefineNgModule` only in jit)
|
||||
- ❌ Documentation
|
||||
|
||||
|
||||
## `@angular/core` changes
|
||||
|
||||
The goal is for the `@Component` (and friends) to be the compiler of template. Since decorators are functions which execute during parsing of the `.js` file, the decorator can compile the template into Ivy. The AoT compiler's job is to remove the `@Component` and replace it with call to `ɵɵdefineComponent`.
|
||||
The goal is for the `@Component` (and friends) to be the compiler of template. Since decorators are functions which execute during parsing of the `.js` file, the decorator can compile the template into Ivy. The AoT compiler's job is to remove the `@Component` and replace it with call to `ΔdefineComponent`.
|
||||
|
||||
- ✅ `@angular/compiler` can patch itself onto:
|
||||
- ✅ `@Injectable`
|
||||
|
@ -70,13 +70,13 @@ The goal is for the `@Component` (and friends) to be the compiler of template. S
|
|||
## Decorators
|
||||
| Annotation | `defineXXX()` | Run time | Spec | Compiler |
|
||||
| -------------------- | ------------------------------ | ------- | -------- | -------- |
|
||||
| `@Component` | ✅ `ɵɵdefineComponent()` | ✅ | ✅ | ✅ |
|
||||
| `@Directive` | ✅ `ɵɵdefineDirective()` | ✅ | ✅ | ✅ |
|
||||
| `@Directive` | ✅ `ɵɵdefineBase()` | ✅ | ✅ | ✅ |
|
||||
| `@Pipe` | ✅ `ɵɵdefinePipe()` | ✅ | ✅ | ✅ |
|
||||
| `@Injectable` | ✅ `ɵɵdefineInjectable()` | ✅ | ✅ | ✅ |
|
||||
| `@NgModule` | ✅ `ɵɵdefineInjector()` | ✅ | ✅ | ✅ |
|
||||
| `@ConfigureInjector` | ✅ `ɵɵdefineInjector()` | ❌ | ❌ | ❌ |
|
||||
| `@Component` | ✅ `ΔdefineComponent()` | ✅ | ✅ | ✅ |
|
||||
| `@Directive` | ✅ `ΔdefineDirective()` | ✅ | ✅ | ✅ |
|
||||
| `@Directive` | ✅ `ΔdefineBase()` | ✅ | ✅ | ✅ |
|
||||
| `@Pipe` | ✅ `ΔdefinePipe()` | ✅ | ✅ | ✅ |
|
||||
| `@Injectable` | ✅ `ΔdefineInjectable()` | ✅ | ✅ | ✅ |
|
||||
| `@NgModule` | ✅ `ΔdefineInjector()` | ✅ | ✅ | ✅ |
|
||||
| `@ConfigureInjector` | ✅ `ΔdefineInjector()` | ❌ | ❌ | ❌ |
|
||||
|
||||
|
||||
|
||||
|
|
|
@ -13,7 +13,7 @@ Here is an abbreviated example of breakage of tree-shake-ability.
|
|||
})
|
||||
export class TooltipDirective {
|
||||
// ngtsc generates this:
|
||||
static ngDirectiveDef = ɵɵdefineDirective(...);
|
||||
static ngDirectiveDef = ΔdefineDirective(...);
|
||||
}
|
||||
|
||||
@Component({
|
||||
|
@ -22,7 +22,7 @@ export class TooltipDirective {
|
|||
})
|
||||
class MyAppComponent {
|
||||
// ngtsc generates this:
|
||||
static ngDirectiveDef = ɵɵdefineComponent({
|
||||
static ngDirectiveDef = ΔdefineComponent({
|
||||
...
|
||||
directives: [
|
||||
// BREAKS TREE-SHAKING!!!
|
||||
|
@ -41,7 +41,7 @@ class MyAppComponent {
|
|||
})
|
||||
class MyAppModule {
|
||||
// ngtsc generates this:
|
||||
static ngDirectiveDef = ɵɵdefineNgModule(...);
|
||||
static ngDirectiveDef = ΔdefineNgModule(...);
|
||||
}
|
||||
```
|
||||
|
||||
|
|
|
@ -36,18 +36,18 @@ The size of the `CONSTS` section is declared in the property `consts` of the com
|
|||
})
|
||||
class MyApp {
|
||||
|
||||
static ngComponentDef = ɵɵdefineComponent({
|
||||
static ngComponentDef = ΔdefineComponent({
|
||||
...,
|
||||
consts: 5,
|
||||
template: function(rf: RenderFlags, ctx: MyApp) {
|
||||
if (rf & RenderFlags.Create) {
|
||||
ɵɵelementStart(0, 'div');
|
||||
ɵɵtext(1, 'Hello ');
|
||||
ɵɵelementStart(2, 'b');
|
||||
ɵɵtext(3, 'World');
|
||||
ɵɵelementEnd();
|
||||
ɵɵtext(4, '!');
|
||||
ɵɵelementEnd();
|
||||
ΔelementStart(0, 'div');
|
||||
Δtext(1, 'Hello ');
|
||||
ΔelementStart(2, 'b');
|
||||
Δtext(3, 'World');
|
||||
ΔelementEnd();
|
||||
Δtext(4, '!');
|
||||
ΔelementEnd();
|
||||
}
|
||||
...
|
||||
}
|
||||
|
@ -87,19 +87,19 @@ The size of the `VARS `section is declared in the property `vars` of the compone
|
|||
class MyApp {
|
||||
name = 'World';
|
||||
|
||||
static ngComponentDef = ɵɵdefineComponent({
|
||||
static ngComponentDef = ΔdefineComponent({
|
||||
...,
|
||||
consts: 2, // Two DOM Elements.
|
||||
vars: 2, // Two bindings.
|
||||
template: function(rf: RenderFlags, ctx: MyApp) {
|
||||
if (rf & RenderFlags.Create) {
|
||||
ɵɵelementStart(0, 'div');
|
||||
ɵɵtext(1);
|
||||
ɵɵelementEnd();
|
||||
ΔelementStart(0, 'div');
|
||||
Δtext(1);
|
||||
ΔelementEnd();
|
||||
}
|
||||
if (rf & RenderFlags.Update) {
|
||||
ɵɵelementProperty(0, 'title', ɵɵbind(ctx.name));
|
||||
ɵɵtextBinding(1, ɵɵinterpolation1('Hello ', ctx.name, '!'));
|
||||
ΔelementProperty(0, 'title', Δbind(ctx.name));
|
||||
ΔtextBinding(1, Δinterpolation1('Hello ', ctx.name, '!'));
|
||||
}
|
||||
...
|
||||
}
|
||||
|
@ -139,12 +139,12 @@ Examples include:
|
|||
})
|
||||
class MyApp {
|
||||
|
||||
static ngComponentDef = ɵɵdefineComponent({
|
||||
static ngComponentDef = ΔdefineComponent({
|
||||
...,
|
||||
consts: 1,
|
||||
template: function(rf: RenderFlags, ctx: MyApp) {
|
||||
if (rf & RenderFlags.Create) {
|
||||
ɵɵelement(0, 'child', ['tooltip', null]);
|
||||
Δelement(0, 'child', ['tooltip', null]);
|
||||
}
|
||||
...
|
||||
},
|
||||
|
@ -159,7 +159,7 @@ class MyApp {
|
|||
})
|
||||
class Child {
|
||||
@HostBinding('tooltip') hostTitle = 'Hello World!';
|
||||
static ngComponentDef = ɵɵdefineComponent({
|
||||
static ngComponentDef = ΔdefineComponent({
|
||||
...
|
||||
hostVars: 1
|
||||
});
|
||||
|
@ -171,7 +171,7 @@ class Child {
|
|||
})
|
||||
class Tooltip {
|
||||
@HostBinding('title') hostTitle = 'greeting';
|
||||
static ngDirectiveDef = ɵɵdefineDirective({
|
||||
static ngDirectiveDef = ΔdefineDirective({
|
||||
...
|
||||
hostVars: 1
|
||||
});
|
||||
|
@ -273,12 +273,12 @@ Injection tokens are sorted into three sections:
|
|||
})
|
||||
class MyApp {
|
||||
|
||||
static ngComponentDef = ɵɵdefineComponent({
|
||||
static ngComponentDef = ΔdefineComponent({
|
||||
...,
|
||||
consts: 1,
|
||||
template: function(rf: RenderFlags, ctx: MyApp) {
|
||||
if (rf & RenderFlags.Create) {
|
||||
ɵɵelement(0, 'child');
|
||||
Δelement(0, 'child');
|
||||
}
|
||||
...
|
||||
},
|
||||
|
@ -301,7 +301,7 @@ class MyApp {
|
|||
})
|
||||
class Child {
|
||||
construction(injector: Injector) {}
|
||||
static ngComponentDef = ɵɵdefineComponent({
|
||||
static ngComponentDef = ΔdefineComponent({
|
||||
...
|
||||
features: [
|
||||
ProvidesFeature(
|
||||
|
|
|
@ -9,7 +9,7 @@
|
|||
import {ChangeDetectorRef as ViewEngine_ChangeDetectorRef} from '../change_detection/change_detector_ref';
|
||||
import {InjectionToken} from '../di/injection_token';
|
||||
import {Injector} from '../di/injector';
|
||||
import {ɵɵinject} from '../di/injector_compatibility';
|
||||
import {Δinject} from '../di/injector_compatibility';
|
||||
import {InjectFlags} from '../di/interface/injector';
|
||||
import {Type} from '../interface/type';
|
||||
import {ComponentFactory as viewEngine_ComponentFactory, ComponentRef as viewEngine_ComponentRef} from '../linker/component_factory';
|
||||
|
@ -66,7 +66,7 @@ function toRefArray(map: {[key: string]: string}): {propName: string; templateNa
|
|||
*/
|
||||
export const ROOT_CONTEXT = new InjectionToken<RootContext>(
|
||||
'ROOT_CONTEXT_TOKEN',
|
||||
{providedIn: 'root', factory: () => createRootContext(ɵɵinject(SCHEDULER))});
|
||||
{providedIn: 'root', factory: () => createRootContext(Δinject(SCHEDULER))});
|
||||
|
||||
/**
|
||||
* A change detection scheduler token for {@link RootContext}. This token is the default value used
|
||||
|
|
|
@ -9,7 +9,7 @@
|
|||
import '../util/ng_dev_mode';
|
||||
|
||||
import {ChangeDetectionStrategy} from '../change_detection/constants';
|
||||
import {NG_INJECTABLE_DEF, ɵɵdefineInjectable} from '../di/interface/defs';
|
||||
import {NG_INJECTABLE_DEF, ΔdefineInjectable} from '../di/interface/defs';
|
||||
import {Mutable, Type} from '../interface/type';
|
||||
import {NgModuleDef} from '../metadata/ng_module';
|
||||
import {SchemaMetadata} from '../metadata/schema';
|
||||
|
@ -19,7 +19,7 @@ import {stringify} from '../util/stringify';
|
|||
|
||||
import {EMPTY_ARRAY, EMPTY_OBJ} from './empty';
|
||||
import {NG_BASE_DEF, NG_COMPONENT_DEF, NG_DIRECTIVE_DEF, NG_MODULE_DEF, NG_PIPE_DEF} from './fields';
|
||||
import {ComponentDef, ComponentDefFeature, ComponentTemplate, ComponentType, ContentQueriesFunction, DirectiveDef, DirectiveDefFeature, DirectiveType, DirectiveTypesOrFactory, FactoryFn, HostBindingsFunction, PipeDef, PipeType, PipeTypesOrFactory, ViewQueriesFunction, ɵɵBaseDef} from './interfaces/definition';
|
||||
import {ComponentDef, ComponentDefFeature, ComponentTemplate, ComponentType, ContentQueriesFunction, DirectiveDef, DirectiveDefFeature, DirectiveType, DirectiveTypesOrFactory, FactoryFn, HostBindingsFunction, PipeDef, PipeType, PipeTypesOrFactory, ViewQueriesFunction, ΔBaseDef} from './interfaces/definition';
|
||||
// while SelectorFlags is unused here, it's required so that types don't get resolved lazily
|
||||
// see: https://github.com/Microsoft/web-build-tools/issues/1050
|
||||
import {CssSelectorList, SelectorFlags} from './interfaces/projection';
|
||||
|
@ -42,7 +42,7 @@ let _renderCompCount = 0;
|
|||
* ```
|
||||
* @codeGenApi
|
||||
*/
|
||||
export function ɵɵdefineComponent<T>(componentDefinition: {
|
||||
export function ΔdefineComponent<T>(componentDefinition: {
|
||||
/**
|
||||
* Directive type, needed to configure the injector.
|
||||
*/
|
||||
|
@ -308,7 +308,7 @@ export function ɵɵdefineComponent<T>(componentDefinition: {
|
|||
// be retrieved through the node injector, so this isn't a problem.
|
||||
if (!type.hasOwnProperty(NG_INJECTABLE_DEF)) {
|
||||
(type as any)[NG_INJECTABLE_DEF] =
|
||||
ɵɵdefineInjectable<T>({factory: componentDefinition.factory as() => T});
|
||||
ΔdefineInjectable<T>({factory: componentDefinition.factory as() => T});
|
||||
}
|
||||
}) as never;
|
||||
|
||||
|
@ -318,7 +318,7 @@ export function ɵɵdefineComponent<T>(componentDefinition: {
|
|||
/**
|
||||
* @codeGenApi
|
||||
*/
|
||||
export function ɵɵsetComponentScope(
|
||||
export function ΔsetComponentScope(
|
||||
type: ComponentType<any>, directives: Type<any>[], pipes: Type<any>[]): void {
|
||||
const def = (type.ngComponentDef as ComponentDef<any>);
|
||||
def.directiveDefs = () => directives.map(extractDirectiveDef);
|
||||
|
@ -345,7 +345,7 @@ export function extractPipeDef(type: PipeType<any>): PipeDef<any> {
|
|||
/**
|
||||
* @codeGenApi
|
||||
*/
|
||||
export function ɵɵdefineNgModule<T>(def: {
|
||||
export function ΔdefineNgModule<T>(def: {
|
||||
/** Token representing the module. Used by DI. */
|
||||
type: T;
|
||||
|
||||
|
@ -393,7 +393,7 @@ export function ɵɵdefineNgModule<T>(def: {
|
|||
*
|
||||
* @codeGenApi
|
||||
*/
|
||||
export function ɵɵsetNgModuleScope(type: any, scope: {
|
||||
export function ΔsetNgModuleScope(type: any, scope: {
|
||||
/** List of components, directives, and pipes declared by this module. */
|
||||
declarations?: Type<any>[] | (() => Type<any>[]);
|
||||
|
||||
|
@ -497,7 +497,7 @@ function invertObject<T>(
|
|||
* # Example
|
||||
* ```ts
|
||||
* class ShouldBeInherited {
|
||||
* static ngBaseDef = ɵɵdefineBase({
|
||||
* static ngBaseDef = ΔdefineBase({
|
||||
* ...
|
||||
* })
|
||||
* }
|
||||
|
@ -507,7 +507,7 @@ function invertObject<T>(
|
|||
*
|
||||
* @codeGenApi
|
||||
*/
|
||||
export function ɵɵdefineBase<T>(baseDefinition: {
|
||||
export function ΔdefineBase<T>(baseDefinition: {
|
||||
/**
|
||||
* A map of input names.
|
||||
*
|
||||
|
@ -580,7 +580,7 @@ export function ɵɵdefineBase<T>(baseDefinition: {
|
|||
* Function executed by the parent template to allow children to apply host bindings.
|
||||
*/
|
||||
hostBindings?: HostBindingsFunction<T>;
|
||||
}): ɵɵBaseDef<T> {
|
||||
}): ΔBaseDef<T> {
|
||||
const declaredInputs: {[P in keyof T]: string} = {} as any;
|
||||
return {
|
||||
inputs: invertObject<T>(baseDefinition.inputs as any, declaredInputs),
|
||||
|
@ -600,7 +600,7 @@ export function ɵɵdefineBase<T>(baseDefinition: {
|
|||
* class MyDirective {
|
||||
* // Generated by Angular Template Compiler
|
||||
* // [Symbol] syntax will not be supported by TypeScript until v2.7
|
||||
* static ngDirectiveDef = ɵɵdefineDirective({
|
||||
* static ngDirectiveDef = ΔdefineDirective({
|
||||
* ...
|
||||
* });
|
||||
* }
|
||||
|
@ -608,7 +608,7 @@ export function ɵɵdefineBase<T>(baseDefinition: {
|
|||
*
|
||||
* @codeGenApi
|
||||
*/
|
||||
export const ɵɵdefineDirective = ɵɵdefineComponent as any as<T>(directiveDefinition: {
|
||||
export const ΔdefineDirective = ΔdefineComponent as any as<T>(directiveDefinition: {
|
||||
/**
|
||||
* Directive type, needed to configure the injector.
|
||||
*/
|
||||
|
@ -726,7 +726,7 @@ export const ɵɵdefineDirective = ɵɵdefineComponent as any as<T>(directiveDef
|
|||
*
|
||||
* @codeGenApi
|
||||
*/
|
||||
export function ɵɵdefinePipe<T>(pipeDef: {
|
||||
export function ΔdefinePipe<T>(pipeDef: {
|
||||
/** Name of the pipe. Used for matching pipes in template to pipe defs. */
|
||||
name: string,
|
||||
|
||||
|
@ -765,7 +765,7 @@ export function getPipeDef<T>(type: any): PipeDef<T>|null {
|
|||
return (type as any)[NG_PIPE_DEF] || null;
|
||||
}
|
||||
|
||||
export function getBaseDef<T>(type: any): ɵɵBaseDef<T>|null {
|
||||
export function getBaseDef<T>(type: any): ΔBaseDef<T>|null {
|
||||
return (type as any)[NG_BASE_DEF] || null;
|
||||
}
|
||||
|
||||
|
|
|
@ -637,7 +637,7 @@ export class NodeInjector implements Injector {
|
|||
/**
|
||||
* @codeGenApi
|
||||
*/
|
||||
export function ɵɵgetFactoryOf<T>(type: Type<any>): ((type: Type<T>| null) => T)|null {
|
||||
export function ΔgetFactoryOf<T>(type: Type<any>): ((type: Type<T>| null) => T)|null {
|
||||
const typeAny = type as any;
|
||||
const def = getComponentDef<T>(typeAny) || getDirectiveDef<T>(typeAny) ||
|
||||
getPipeDef<T>(typeAny) || getInjectableDef<T>(typeAny) || getInjectorDef<T>(typeAny);
|
||||
|
@ -650,9 +650,9 @@ export function ɵɵgetFactoryOf<T>(type: Type<any>): ((type: Type<T>| null) =>
|
|||
/**
|
||||
* @codeGenApi
|
||||
*/
|
||||
export function ɵɵgetInheritedFactory<T>(type: Type<any>): (type: Type<T>) => T {
|
||||
export function ΔgetInheritedFactory<T>(type: Type<any>): (type: Type<T>) => T {
|
||||
const proto = Object.getPrototypeOf(type.prototype).constructor as Type<any>;
|
||||
const factory = ɵɵgetFactoryOf<T>(proto);
|
||||
const factory = ΔgetFactoryOf<T>(proto);
|
||||
if (factory !== null) {
|
||||
return factory;
|
||||
} else {
|
||||
|
|
|
@ -12,7 +12,7 @@ import {ClassProvider, Provider} from '../di/interface/provider';
|
|||
import {isClassProvider, isTypeProvider, providerToFactory} from '../di/r3_injector';
|
||||
|
||||
import {diPublicInInjector, getNodeInjectable, getOrCreateNodeInjectorForNode} from './di';
|
||||
import {ɵɵdirectiveInject} from './instructions/all';
|
||||
import {ΔdirectiveInject} from './instructions/all';
|
||||
import {DirectiveDef} from './interfaces/definition';
|
||||
import {NodeInjectorFactory} from './interfaces/injector';
|
||||
import {TContainerNode, TElementContainerNode, TElementNode, TNodeProviderIndexes} from './interfaces/node';
|
||||
|
@ -93,7 +93,7 @@ function resolveProvider(
|
|||
|
||||
if (isTypeProvider(provider) || !provider.multi) {
|
||||
// Single provider case: the factory is created and pushed immediately
|
||||
const factory = new NodeInjectorFactory(providerFactory, isViewProvider, ɵɵdirectiveInject);
|
||||
const factory = new NodeInjectorFactory(providerFactory, isViewProvider, ΔdirectiveInject);
|
||||
const existingFactoryIndex = indexOf(
|
||||
token, tInjectables, isViewProvider ? beginIndex : beginIndex + cptViewProvidersCount,
|
||||
endIndex);
|
||||
|
@ -255,7 +255,7 @@ function multiFactory(
|
|||
this: NodeInjectorFactory, _: null, tData: TData, lData: LView, tNode: TElementNode) => any,
|
||||
index: number, isViewProvider: boolean, isComponent: boolean,
|
||||
f: () => any): NodeInjectorFactory {
|
||||
const factory = new NodeInjectorFactory(factoryFn, isViewProvider, ɵɵdirectiveInject);
|
||||
const factory = new NodeInjectorFactory(factoryFn, isViewProvider, ΔdirectiveInject);
|
||||
factory.multi = [];
|
||||
factory.index = index;
|
||||
factory.componentProviders = 0;
|
||||
|
|
|
@ -13,7 +13,7 @@ import {ComponentDef, ContentQueriesFunction, DirectiveDef, DirectiveDefFeature,
|
|||
import {adjustActiveDirectiveSuperClassDepthPosition} from '../state';
|
||||
import {isComponentDef} from '../util/view_utils';
|
||||
|
||||
import {ɵɵNgOnChangesFeature} from './ng_onchanges_feature';
|
||||
import {ΔNgOnChangesFeature} from './ng_onchanges_feature';
|
||||
|
||||
function getSuperType(type: Type<any>): Type<any>&
|
||||
{ngComponentDef?: ComponentDef<any>, ngDirectiveDef?: DirectiveDef<any>} {
|
||||
|
@ -26,7 +26,7 @@ function getSuperType(type: Type<any>): Type<any>&
|
|||
*
|
||||
* @codeGenApi
|
||||
*/
|
||||
export function ɵɵInheritDefinitionFeature(definition: DirectiveDef<any>| ComponentDef<any>): void {
|
||||
export function ΔInheritDefinitionFeature(definition: DirectiveDef<any>| ComponentDef<any>): void {
|
||||
let superType = getSuperType(definition.type);
|
||||
|
||||
while (superType) {
|
||||
|
@ -117,7 +117,7 @@ export function ɵɵInheritDefinitionFeature(definition: DirectiveDef<any>| Comp
|
|||
definition.onInit = definition.onInit || superPrototype.ngOnInit;
|
||||
|
||||
if (superPrototype.ngOnChanges) {
|
||||
ɵɵNgOnChangesFeature()(definition);
|
||||
ΔNgOnChangesFeature()(definition);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -41,7 +41,7 @@ type OnChangesExpando = OnChanges & {
|
|||
*
|
||||
* @codeGenApi
|
||||
*/
|
||||
export function ɵɵNgOnChangesFeature<T>(): DirectiveDefFeature {
|
||||
export function ΔNgOnChangesFeature<T>(): DirectiveDefFeature {
|
||||
// This option ensures that the ngOnChanges lifecycle hook will be inherited
|
||||
// from superclasses (in InheritDefinitionFeature).
|
||||
(NgOnChangesFeatureImpl as DirectiveDefFeature).ngInherit = true;
|
||||
|
|
|
@ -39,7 +39,7 @@ import {DirectiveDef} from '../interfaces/definition';
|
|||
*
|
||||
* @codeGenApi
|
||||
*/
|
||||
export function ɵɵProvidersFeature<T>(providers: Provider[], viewProviders: Provider[] = []) {
|
||||
export function ΔProvidersFeature<T>(providers: Provider[], viewProviders: Provider[] = []) {
|
||||
return (definition: DirectiveDef<T>) => {
|
||||
definition.providersResolver =
|
||||
(def: DirectiveDef<T>, processProvidersFn?: ProcessProvidersFunction) => {
|
||||
|
|
|
@ -16,7 +16,7 @@ import {assertDefined, assertEqual, assertGreaterThan} from '../util/assert';
|
|||
|
||||
import {attachPatchData} from './context_discovery';
|
||||
import {attachI18nOpCodesDebug} from './debug';
|
||||
import {ɵɵelementAttribute, ɵɵload, ɵɵtextBinding} from './instructions/all';
|
||||
import {ΔelementAttribute, Δload, ΔtextBinding} from './instructions/all';
|
||||
import {allocExpando, createNodeAtIndex} from './instructions/shared';
|
||||
import {LContainer, NATIVE} from './interfaces/container';
|
||||
import {COMMENT_MARKER, ELEMENT_MARKER, I18nMutateOpCode, I18nMutateOpCodes, I18nUpdateOpCode, I18nUpdateOpCodes, IcuType, TI18n, TIcu} from './interfaces/i18n';
|
||||
|
@ -351,7 +351,7 @@ const parentIndexStack: number[] = [];
|
|||
*
|
||||
* @codeGenApi
|
||||
*/
|
||||
export function ɵɵi18nStart(index: number, message: string, subTemplateIndex?: number): void {
|
||||
export function Δi18nStart(index: number, message: string, subTemplateIndex?: number): void {
|
||||
const tView = getLView()[TVIEW];
|
||||
ngDevMode && assertDefined(tView, `tView should be defined`);
|
||||
i18nIndexStack[++i18nIndexStackPointer] = index;
|
||||
|
@ -538,7 +538,7 @@ function appendI18nNode(tNode: TNode, parentTNode: TNode, previousTNode: TNode |
|
|||
*
|
||||
* @codeGenApi
|
||||
*/
|
||||
export function ɵɵi18nPostprocess(
|
||||
export function Δi18nPostprocess(
|
||||
message: string, replacements: {[key: string]: (string | string[])} = {}): string {
|
||||
/**
|
||||
* Step 1: resolve all multi-value placeholders like [<EFBFBD>#5<EFBFBD>|<EFBFBD>*1:1<EFBFBD><EFBFBD>#2:1<EFBFBD>|<EFBFBD>#4:1<EFBFBD>]
|
||||
|
@ -634,7 +634,7 @@ export function ɵɵi18nPostprocess(
|
|||
*
|
||||
* @codeGenApi
|
||||
*/
|
||||
export function ɵɵi18nEnd(): void {
|
||||
export function Δi18nEnd(): void {
|
||||
const tView = getLView()[TVIEW];
|
||||
ngDevMode && assertDefined(tView, `tView should be defined`);
|
||||
i18nEndFirstPass(tView);
|
||||
|
@ -742,7 +742,7 @@ function readCreateOpCodes(
|
|||
const elementNodeIndex = opCode >>> I18nMutateOpCode.SHIFT_REF;
|
||||
const attrName = createOpCodes[++i] as string;
|
||||
const attrValue = createOpCodes[++i] as string;
|
||||
ɵɵelementAttribute(elementNodeIndex, attrName, attrValue);
|
||||
ΔelementAttribute(elementNodeIndex, attrName, attrValue);
|
||||
break;
|
||||
default:
|
||||
throw new Error(`Unable to determine the type of mutate operation for "${opCode}"`);
|
||||
|
@ -819,10 +819,10 @@ function readUpdateOpCodes(
|
|||
case I18nUpdateOpCode.Attr:
|
||||
const attrName = updateOpCodes[++j] as string;
|
||||
const sanitizeFn = updateOpCodes[++j] as SanitizerFn | null;
|
||||
ɵɵelementAttribute(nodeIndex, attrName, value, sanitizeFn);
|
||||
ΔelementAttribute(nodeIndex, attrName, value, sanitizeFn);
|
||||
break;
|
||||
case I18nUpdateOpCode.Text:
|
||||
ɵɵtextBinding(nodeIndex, value);
|
||||
ΔtextBinding(nodeIndex, value);
|
||||
break;
|
||||
case I18nUpdateOpCode.IcuSwitch:
|
||||
tIcuIndex = updateOpCodes[++j] as number;
|
||||
|
@ -886,7 +886,7 @@ function removeNode(index: number, viewData: LView) {
|
|||
nativeRemoveNode(viewData[RENDERER], removedPhRNode);
|
||||
}
|
||||
|
||||
const slotValue = ɵɵload(index) as RElement | RComment | LContainer | StylingContext;
|
||||
const slotValue = Δload(index) as RElement | RComment | LContainer | StylingContext;
|
||||
if (isLContainer(slotValue)) {
|
||||
const lContainer = slotValue as LContainer;
|
||||
if (removedPhTNode.type !== TNodeType.Container) {
|
||||
|
@ -923,9 +923,9 @@ function removeNode(index: number, viewData: LView) {
|
|||
*
|
||||
* @codeGenApi
|
||||
*/
|
||||
export function ɵɵi18n(index: number, message: string, subTemplateIndex?: number): void {
|
||||
ɵɵi18nStart(index, message, subTemplateIndex);
|
||||
ɵɵi18nEnd();
|
||||
export function Δi18n(index: number, message: string, subTemplateIndex?: number): void {
|
||||
Δi18nStart(index, message, subTemplateIndex);
|
||||
Δi18nEnd();
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -936,7 +936,7 @@ export function ɵɵi18n(index: number, message: string, subTemplateIndex?: numb
|
|||
*
|
||||
* @codeGenApi
|
||||
*/
|
||||
export function ɵɵi18nAttributes(index: number, values: string[]): void {
|
||||
export function Δi18nAttributes(index: number, values: string[]): void {
|
||||
const tView = getLView()[TVIEW];
|
||||
ngDevMode && assertDefined(tView, `tView should be defined`);
|
||||
if (tView.firstTemplatePass && tView.data[index + HEADER_OFFSET] === null) {
|
||||
|
@ -968,7 +968,7 @@ function i18nAttributesFirstPass(tView: TView, index: number, values: string[])
|
|||
addAllToArray(
|
||||
generateBindingUpdateOpCodes(value, previousElementIndex, attrName), updateOpCodes);
|
||||
} else {
|
||||
ɵɵelementAttribute(previousElementIndex, attrName, value);
|
||||
ΔelementAttribute(previousElementIndex, attrName, value);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -988,7 +988,7 @@ let shiftsCounter = 0;
|
|||
*
|
||||
* @codeGenApi
|
||||
*/
|
||||
export function ɵɵi18nExp<T>(expression: T | NO_CHANGE): void {
|
||||
export function Δi18nExp<T>(expression: T | NO_CHANGE): void {
|
||||
if (expression !== NO_CHANGE) {
|
||||
changeMask = changeMask | (1 << shiftsCounter);
|
||||
}
|
||||
|
@ -1003,7 +1003,7 @@ export function ɵɵi18nExp<T>(expression: T | NO_CHANGE): void {
|
|||
*
|
||||
* @codeGenApi
|
||||
*/
|
||||
export function ɵɵi18nApply(index: number) {
|
||||
export function Δi18nApply(index: number) {
|
||||
if (shiftsCounter) {
|
||||
const lView = getLView();
|
||||
const tView = lView[TVIEW];
|
||||
|
@ -1633,7 +1633,7 @@ const LOCALIZE_PH_REGEXP = /\{\$(.*?)\}/g;
|
|||
* @publicApi
|
||||
* @deprecated this method is temporary & should not be used as it will be removed soon
|
||||
*/
|
||||
export function ɵɵi18nLocalize(input: string, placeholders: {[key: string]: string} = {}) {
|
||||
export function Δi18nLocalize(input: string, placeholders: {[key: string]: string} = {}) {
|
||||
if (typeof TRANSLATIONS[input] !== 'undefined') { // to account for empty string
|
||||
input = TRANSLATIONS[input];
|
||||
}
|
||||
|
|
|
@ -6,115 +6,115 @@
|
|||
* found in the LICENSE file at https://angular.io/license
|
||||
*/
|
||||
import {LifecycleHooksFeature, renderComponent, whenRendered} from './component';
|
||||
import {ɵɵdefineBase, ɵɵdefineComponent, ɵɵdefineDirective, ɵɵdefineNgModule, ɵɵdefinePipe, ɵɵsetComponentScope, ɵɵsetNgModuleScope} from './definition';
|
||||
import {ɵɵInheritDefinitionFeature} from './features/inherit_definition_feature';
|
||||
import {ɵɵNgOnChangesFeature} from './features/ng_onchanges_feature';
|
||||
import {ɵɵProvidersFeature} from './features/providers_feature';
|
||||
import {ComponentDef, ComponentTemplate, ComponentType, DirectiveDef, DirectiveDefFlags, DirectiveType, PipeDef, ɵɵBaseDef, ɵɵComponentDefWithMeta, ɵɵDirectiveDefWithMeta, ɵɵPipeDefWithMeta} from './interfaces/definition';
|
||||
import {ΔdefineBase, ΔdefineComponent, ΔdefineDirective, ΔdefineNgModule, ΔdefinePipe, ΔsetComponentScope, ΔsetNgModuleScope} from './definition';
|
||||
import {ΔInheritDefinitionFeature} from './features/inherit_definition_feature';
|
||||
import {ΔNgOnChangesFeature} from './features/ng_onchanges_feature';
|
||||
import {ΔProvidersFeature} from './features/providers_feature';
|
||||
import {ComponentDef, ComponentTemplate, ComponentType, DirectiveDef, DirectiveDefFlags, DirectiveType, PipeDef, ΔBaseDef, ΔComponentDefWithMeta, ΔDirectiveDefWithMeta, ΔPipeDefWithMeta} from './interfaces/definition';
|
||||
import {getComponent, getDirectives, getHostElement, getRenderedText} from './util/discovery_utils';
|
||||
|
||||
export {ComponentFactory, ComponentFactoryResolver, ComponentRef, injectComponentFactoryResolver} from './component_ref';
|
||||
export {ɵɵgetFactoryOf, ɵɵgetInheritedFactory} from './di';
|
||||
export {ΔgetFactoryOf, ΔgetInheritedFactory} from './di';
|
||||
// clang-format off
|
||||
export {
|
||||
detectChanges,
|
||||
markDirty,
|
||||
store,
|
||||
tick,
|
||||
ɵɵallocHostVars,
|
||||
ɵɵbind,
|
||||
ɵɵclassMap,
|
||||
ɵɵclassProp,
|
||||
ɵɵcomponentHostSyntheticListener,
|
||||
ɵɵcomponentHostSyntheticProperty,
|
||||
ΔallocHostVars,
|
||||
Δbind,
|
||||
ΔclassMap,
|
||||
ΔclassProp,
|
||||
ΔcomponentHostSyntheticListener,
|
||||
ΔcomponentHostSyntheticProperty,
|
||||
|
||||
ɵɵcontainer,
|
||||
ɵɵcontainerRefreshEnd,
|
||||
ɵɵcontainerRefreshStart,
|
||||
Δcontainer,
|
||||
ΔcontainerRefreshEnd,
|
||||
ΔcontainerRefreshStart,
|
||||
|
||||
ɵɵdirectiveInject,
|
||||
ΔdirectiveInject,
|
||||
|
||||
ɵɵelement,
|
||||
ɵɵelementAttribute,
|
||||
ɵɵelementContainerEnd,
|
||||
Δelement,
|
||||
ΔelementAttribute,
|
||||
ΔelementContainerEnd,
|
||||
|
||||
ɵɵelementContainerStart,
|
||||
ɵɵelementEnd,
|
||||
ΔelementContainerStart,
|
||||
ΔelementEnd,
|
||||
|
||||
ɵɵelementHostAttrs,
|
||||
ɵɵelementProperty,
|
||||
ɵɵelementStart,
|
||||
ɵɵembeddedViewEnd,
|
||||
ΔelementHostAttrs,
|
||||
ΔelementProperty,
|
||||
ΔelementStart,
|
||||
ΔembeddedViewEnd,
|
||||
|
||||
ɵɵembeddedViewStart,
|
||||
ΔembeddedViewStart,
|
||||
|
||||
ɵɵgetCurrentView,
|
||||
ɵɵinjectAttribute,
|
||||
ΔgetCurrentView,
|
||||
ΔinjectAttribute,
|
||||
|
||||
ɵɵinterpolation1,
|
||||
ɵɵinterpolation2,
|
||||
ɵɵinterpolation3,
|
||||
ɵɵinterpolation4,
|
||||
ɵɵinterpolation5,
|
||||
ɵɵinterpolation6,
|
||||
ɵɵinterpolation7,
|
||||
ɵɵinterpolation8,
|
||||
ɵɵinterpolationV,
|
||||
Δinterpolation1,
|
||||
Δinterpolation2,
|
||||
Δinterpolation3,
|
||||
Δinterpolation4,
|
||||
Δinterpolation5,
|
||||
Δinterpolation6,
|
||||
Δinterpolation7,
|
||||
Δinterpolation8,
|
||||
ΔinterpolationV,
|
||||
|
||||
ɵɵlistener,
|
||||
ɵɵload,
|
||||
Δlistener,
|
||||
Δload,
|
||||
|
||||
ɵɵnamespaceHTML,
|
||||
ɵɵnamespaceMathML,
|
||||
ɵɵnamespaceSVG,
|
||||
ΔnamespaceHTML,
|
||||
ΔnamespaceMathML,
|
||||
ΔnamespaceSVG,
|
||||
|
||||
ɵɵnextContext,
|
||||
ΔnextContext,
|
||||
|
||||
ɵɵprojection,
|
||||
ɵɵprojectionDef,
|
||||
ɵɵproperty,
|
||||
ɵɵpropertyInterpolate,
|
||||
ɵɵpropertyInterpolate1,
|
||||
ɵɵpropertyInterpolate2,
|
||||
ɵɵpropertyInterpolate3,
|
||||
ɵɵpropertyInterpolate4,
|
||||
ɵɵpropertyInterpolate5,
|
||||
ɵɵpropertyInterpolate6,
|
||||
ɵɵpropertyInterpolate7,
|
||||
ɵɵpropertyInterpolate8,
|
||||
ɵɵpropertyInterpolateV,
|
||||
Δprojection,
|
||||
ΔprojectionDef,
|
||||
Δproperty,
|
||||
ΔpropertyInterpolate,
|
||||
ΔpropertyInterpolate1,
|
||||
ΔpropertyInterpolate2,
|
||||
ΔpropertyInterpolate3,
|
||||
ΔpropertyInterpolate4,
|
||||
ΔpropertyInterpolate5,
|
||||
ΔpropertyInterpolate6,
|
||||
ΔpropertyInterpolate7,
|
||||
ΔpropertyInterpolate8,
|
||||
ΔpropertyInterpolateV,
|
||||
|
||||
ɵɵreference,
|
||||
Δreference,
|
||||
|
||||
ɵɵselect,
|
||||
ɵɵstyleMap,
|
||||
ɵɵstyleProp,
|
||||
ɵɵstyling,
|
||||
ɵɵstylingApply,
|
||||
ɵɵtemplate,
|
||||
Δselect,
|
||||
ΔstyleMap,
|
||||
ΔstyleProp,
|
||||
Δstyling,
|
||||
ΔstylingApply,
|
||||
Δtemplate,
|
||||
|
||||
ɵɵtext,
|
||||
ɵɵtextBinding} from './instructions/all';
|
||||
Δtext,
|
||||
ΔtextBinding} from './instructions/all';
|
||||
export {RenderFlags} from './interfaces/definition';
|
||||
export {CssSelectorList} from './interfaces/projection';
|
||||
|
||||
export {
|
||||
ɵɵrestoreView,
|
||||
ΔrestoreView,
|
||||
|
||||
ɵɵenableBindings,
|
||||
ɵɵdisableBindings,
|
||||
ΔenableBindings,
|
||||
ΔdisableBindings,
|
||||
} from './state';
|
||||
|
||||
export {
|
||||
ɵɵi18n,
|
||||
ɵɵi18nAttributes,
|
||||
ɵɵi18nExp,
|
||||
ɵɵi18nStart,
|
||||
ɵɵi18nEnd,
|
||||
ɵɵi18nApply,
|
||||
ɵɵi18nPostprocess,
|
||||
Δi18n,
|
||||
Δi18nAttributes,
|
||||
Δi18nExp,
|
||||
Δi18nStart,
|
||||
Δi18nEnd,
|
||||
Δi18nApply,
|
||||
Δi18nPostprocess,
|
||||
i18nConfigureLocalize,
|
||||
ɵɵi18nLocalize,
|
||||
Δi18nLocalize,
|
||||
} from './i18n';
|
||||
|
||||
export {NgModuleFactory, NgModuleRef, NgModuleType} from './ng_module_ref';
|
||||
|
@ -128,71 +128,71 @@ export {
|
|||
} from './metadata';
|
||||
|
||||
export {
|
||||
ɵɵpipe,
|
||||
ɵɵpipeBind1,
|
||||
ɵɵpipeBind2,
|
||||
ɵɵpipeBind3,
|
||||
ɵɵpipeBind4,
|
||||
ɵɵpipeBindV,
|
||||
Δpipe,
|
||||
ΔpipeBind1,
|
||||
ΔpipeBind2,
|
||||
ΔpipeBind3,
|
||||
ΔpipeBind4,
|
||||
ΔpipeBindV,
|
||||
} from './pipe';
|
||||
|
||||
export {
|
||||
ɵɵqueryRefresh,
|
||||
ɵɵviewQuery,
|
||||
ɵɵstaticViewQuery,
|
||||
ɵɵloadViewQuery,
|
||||
ɵɵcontentQuery,
|
||||
ɵɵloadContentQuery,
|
||||
ɵɵstaticContentQuery
|
||||
ΔqueryRefresh,
|
||||
ΔviewQuery,
|
||||
ΔstaticViewQuery,
|
||||
ΔloadViewQuery,
|
||||
ΔcontentQuery,
|
||||
ΔloadContentQuery,
|
||||
ΔstaticContentQuery
|
||||
} from './query';
|
||||
|
||||
export {
|
||||
ɵɵpureFunction0,
|
||||
ɵɵpureFunction1,
|
||||
ɵɵpureFunction2,
|
||||
ɵɵpureFunction3,
|
||||
ɵɵpureFunction4,
|
||||
ɵɵpureFunction5,
|
||||
ɵɵpureFunction6,
|
||||
ɵɵpureFunction7,
|
||||
ɵɵpureFunction8,
|
||||
ɵɵpureFunctionV,
|
||||
ΔpureFunction0,
|
||||
ΔpureFunction1,
|
||||
ΔpureFunction2,
|
||||
ΔpureFunction3,
|
||||
ΔpureFunction4,
|
||||
ΔpureFunction5,
|
||||
ΔpureFunction6,
|
||||
ΔpureFunction7,
|
||||
ΔpureFunction8,
|
||||
ΔpureFunctionV,
|
||||
} from './pure_function';
|
||||
|
||||
export {ɵɵtemplateRefExtractor} from './view_engine_compatibility_prebound';
|
||||
export {ΔtemplateRefExtractor} from './view_engine_compatibility_prebound';
|
||||
|
||||
export {ɵɵresolveWindow, ɵɵresolveDocument, ɵɵresolveBody} from './util/misc_utils';
|
||||
export {ΔresolveWindow, ΔresolveDocument, ΔresolveBody} from './util/misc_utils';
|
||||
|
||||
// clang-format on
|
||||
|
||||
export {
|
||||
ɵɵBaseDef,
|
||||
ΔBaseDef,
|
||||
ComponentDef,
|
||||
ɵɵComponentDefWithMeta,
|
||||
ΔComponentDefWithMeta,
|
||||
ComponentTemplate,
|
||||
ComponentType,
|
||||
DirectiveDef,
|
||||
DirectiveDefFlags,
|
||||
ɵɵDirectiveDefWithMeta,
|
||||
ΔDirectiveDefWithMeta,
|
||||
DirectiveType,
|
||||
ɵɵNgOnChangesFeature,
|
||||
ɵɵInheritDefinitionFeature,
|
||||
ɵɵProvidersFeature,
|
||||
ΔNgOnChangesFeature,
|
||||
ΔInheritDefinitionFeature,
|
||||
ΔProvidersFeature,
|
||||
PipeDef,
|
||||
ɵɵPipeDefWithMeta,
|
||||
ΔPipeDefWithMeta,
|
||||
LifecycleHooksFeature,
|
||||
ɵɵdefineComponent,
|
||||
ɵɵdefineDirective,
|
||||
ɵɵdefineNgModule,
|
||||
ɵɵdefineBase,
|
||||
ɵɵdefinePipe,
|
||||
ΔdefineComponent,
|
||||
ΔdefineDirective,
|
||||
ΔdefineNgModule,
|
||||
ΔdefineBase,
|
||||
ΔdefinePipe,
|
||||
getHostElement,
|
||||
getComponent,
|
||||
getDirectives,
|
||||
getRenderedText,
|
||||
renderComponent,
|
||||
ɵɵsetComponentScope,
|
||||
ɵɵsetNgModuleScope,
|
||||
ΔsetComponentScope,
|
||||
ΔsetNgModuleScope,
|
||||
whenRendered,
|
||||
};
|
||||
|
||||
|
|
|
@ -19,7 +19,7 @@ import {NO_CHANGE} from '../tokens';
|
|||
*
|
||||
* @codeGenApi
|
||||
*/
|
||||
export function ɵɵallocHostVars(count: number): void {
|
||||
export function ΔallocHostVars(count: number): void {
|
||||
const lView = getLView();
|
||||
const tView = lView[TVIEW];
|
||||
if (!tView.firstTemplatePass) return;
|
||||
|
|
|
@ -30,7 +30,7 @@ import {addToViewTree, createDirectivesAndLocals, createLContainer, createNodeAt
|
|||
*
|
||||
* @codeGenApi
|
||||
*/
|
||||
export function ɵɵcontainer(index: number): void {
|
||||
export function Δcontainer(index: number): void {
|
||||
const tNode = containerInternal(index, null, null);
|
||||
const lView = getLView();
|
||||
if (lView[TVIEW].firstTemplatePass) {
|
||||
|
@ -59,7 +59,7 @@ export function ɵɵcontainer(index: number): void {
|
|||
*
|
||||
* @codeGenApi
|
||||
*/
|
||||
export function ɵɵtemplate(
|
||||
export function Δtemplate(
|
||||
index: number, templateFn: ComponentTemplate<any>| null, consts: number, vars: number,
|
||||
tagName?: string | null, attrs?: TAttributes | null, localRefs?: string[] | null,
|
||||
localRefExtractor?: LocalRefExtractor) {
|
||||
|
@ -87,7 +87,7 @@ export function ɵɵtemplate(
|
|||
*
|
||||
* @codeGenApi
|
||||
*/
|
||||
export function ɵɵcontainerRefreshStart(index: number): void {
|
||||
export function ΔcontainerRefreshStart(index: number): void {
|
||||
const lView = getLView();
|
||||
const tView = lView[TVIEW];
|
||||
let previousOrParentTNode = loadInternal(tView.data, index) as TNode;
|
||||
|
@ -110,7 +110,7 @@ export function ɵɵcontainerRefreshStart(index: number): void {
|
|||
*
|
||||
* @codeGenApi
|
||||
*/
|
||||
export function ɵɵcontainerRefreshEnd(): void {
|
||||
export function ΔcontainerRefreshEnd(): void {
|
||||
let previousOrParentTNode = getPreviousOrParentTNode();
|
||||
if (getIsParent()) {
|
||||
setIsParent(false);
|
||||
|
|
|
@ -6,7 +6,7 @@
|
|||
* found in the LICENSE file at https://angular.io/license
|
||||
*/
|
||||
import {InjectFlags, InjectionToken, resolveForwardRef} from '../../di';
|
||||
import {ɵɵinject} from '../../di/injector_compatibility';
|
||||
import {Δinject} from '../../di/injector_compatibility';
|
||||
import {Type} from '../../interface/type';
|
||||
import {getOrCreateInjectable, injectAttributeImpl} from '../di';
|
||||
import {TContainerNode, TElementContainerNode, TElementNode} from '../interfaces/node';
|
||||
|
@ -24,9 +24,9 @@ import {getLView, getPreviousOrParentTNode} from '../state';
|
|||
* class SomeDirective {
|
||||
* constructor(directive: DirectiveA) {}
|
||||
*
|
||||
* static ngDirectiveDef = ɵɵdefineDirective({
|
||||
* static ngDirectiveDef = ΔdefineDirective({
|
||||
* type: SomeDirective,
|
||||
* factory: () => new SomeDirective(ɵɵdirectiveInject(DirectiveA))
|
||||
* factory: () => new SomeDirective(ΔdirectiveInject(DirectiveA))
|
||||
* });
|
||||
* }
|
||||
* ```
|
||||
|
@ -36,15 +36,15 @@ import {getLView, getPreviousOrParentTNode} from '../state';
|
|||
*
|
||||
* @codeGenApi
|
||||
*/
|
||||
export function ɵɵdirectiveInject<T>(token: Type<T>| InjectionToken<T>): T;
|
||||
export function ɵɵdirectiveInject<T>(token: Type<T>| InjectionToken<T>, flags: InjectFlags): T;
|
||||
export function ɵɵdirectiveInject<T>(
|
||||
export function ΔdirectiveInject<T>(token: Type<T>| InjectionToken<T>): T;
|
||||
export function ΔdirectiveInject<T>(token: Type<T>| InjectionToken<T>, flags: InjectFlags): T;
|
||||
export function ΔdirectiveInject<T>(
|
||||
token: Type<T>| InjectionToken<T>, flags = InjectFlags.Default): T|null {
|
||||
token = resolveForwardRef(token);
|
||||
const lView = getLView();
|
||||
// Fall back to inject() if view hasn't been created. This situation can happen in tests
|
||||
// if inject utilities are used before bootstrapping.
|
||||
if (lView == null) return ɵɵinject(token, flags);
|
||||
if (lView == null) return Δinject(token, flags);
|
||||
|
||||
return getOrCreateInjectable<T>(
|
||||
getPreviousOrParentTNode() as TElementNode | TContainerNode | TElementContainerNode, lView,
|
||||
|
@ -56,6 +56,6 @@ export function ɵɵdirectiveInject<T>(
|
|||
*
|
||||
* @codeGenApi
|
||||
*/
|
||||
export function ɵɵinjectAttribute(attrNameToInject: string): string|null {
|
||||
export function ΔinjectAttribute(attrNameToInject: string): string|null {
|
||||
return injectAttributeImpl(getPreviousOrParentTNode(), attrNameToInject);
|
||||
}
|
||||
|
|
|
@ -44,7 +44,7 @@ import {getActiveDirectiveStylingIndex} from './styling';
|
|||
*
|
||||
* @codeGenApi
|
||||
*/
|
||||
export function ɵɵelementStart(
|
||||
export function ΔelementStart(
|
||||
index: number, name: string, attrs?: TAttributes | null, localRefs?: string[] | null): void {
|
||||
const lView = getLView();
|
||||
const tView = lView[TVIEW];
|
||||
|
@ -129,7 +129,7 @@ export function ɵɵelementStart(
|
|||
*
|
||||
* @codeGenApi
|
||||
*/
|
||||
export function ɵɵelementEnd(): void {
|
||||
export function ΔelementEnd(): void {
|
||||
let previousOrParentTNode = getPreviousOrParentTNode();
|
||||
if (getIsParent()) {
|
||||
setIsParent(false);
|
||||
|
@ -183,10 +183,10 @@ export function ɵɵelementEnd(): void {
|
|||
*
|
||||
* @codeGenApi
|
||||
*/
|
||||
export function ɵɵelement(
|
||||
export function Δelement(
|
||||
index: number, name: string, attrs?: TAttributes | null, localRefs?: string[] | null): void {
|
||||
ɵɵelementStart(index, name, attrs, localRefs);
|
||||
ɵɵelementEnd();
|
||||
ΔelementStart(index, name, attrs, localRefs);
|
||||
ΔelementEnd();
|
||||
}
|
||||
|
||||
|
||||
|
@ -202,7 +202,7 @@ export function ɵɵelement(
|
|||
*
|
||||
* @codeGenApi
|
||||
*/
|
||||
export function ɵɵelementAttribute(
|
||||
export function ΔelementAttribute(
|
||||
index: number, name: string, value: any, sanitizer?: SanitizerFn | null,
|
||||
namespace?: string): void {
|
||||
if (value !== NO_CHANGE) {
|
||||
|
@ -270,7 +270,7 @@ export function ɵɵelementAttribute(
|
|||
*
|
||||
* @codeGenApi
|
||||
*/
|
||||
export function ɵɵelementHostAttrs(attrs: TAttributes) {
|
||||
export function ΔelementHostAttrs(attrs: TAttributes) {
|
||||
const hostElementIndex = getSelectedIndex();
|
||||
const lView = getLView();
|
||||
const tNode = getTNode(hostElementIndex, lView);
|
||||
|
|
|
@ -31,7 +31,7 @@ import {createDirectivesAndLocals, createNodeAtIndex, executeContentQueries, set
|
|||
*
|
||||
* @codeGenApi
|
||||
*/
|
||||
export function ɵɵelementContainerStart(
|
||||
export function ΔelementContainerStart(
|
||||
index: number, attrs?: TAttributes | null, localRefs?: string[] | null): void {
|
||||
const lView = getLView();
|
||||
const tView = lView[TVIEW];
|
||||
|
@ -72,7 +72,7 @@ export function ɵɵelementContainerStart(
|
|||
*
|
||||
* @codeGenApi
|
||||
*/
|
||||
export function ɵɵelementContainerEnd(): void {
|
||||
export function ΔelementContainerEnd(): void {
|
||||
let previousOrParentTNode = getPreviousOrParentTNode();
|
||||
const lView = getLView();
|
||||
const tView = lView[TVIEW];
|
||||
|
|
|
@ -26,8 +26,7 @@ import {assignTViewNodeToLView, createLView, createTView, refreshDescendantViews
|
|||
*
|
||||
* @codeGenApi
|
||||
*/
|
||||
export function ɵɵembeddedViewStart(
|
||||
viewBlockId: number, consts: number, vars: number): RenderFlags {
|
||||
export function ΔembeddedViewStart(viewBlockId: number, consts: number, vars: number): RenderFlags {
|
||||
const lView = getLView();
|
||||
const previousOrParentTNode = getPreviousOrParentTNode();
|
||||
// The previous node can be a view node if we are processing an inline for loop
|
||||
|
@ -128,7 +127,7 @@ function scanForView(lContainer: LContainer, startIdx: number, viewBlockId: numb
|
|||
*
|
||||
* @codeGenApi
|
||||
*/
|
||||
export function ɵɵembeddedViewEnd(): void {
|
||||
export function ΔembeddedViewEnd(): void {
|
||||
const lView = getLView();
|
||||
const viewHost = lView[T_HOST];
|
||||
|
||||
|
|
|
@ -17,6 +17,6 @@ import {getLView} from '../state';
|
|||
*
|
||||
* @codeGenApi
|
||||
*/
|
||||
export function ɵɵgetCurrentView(): OpaqueViewState {
|
||||
export function ΔgetCurrentView(): OpaqueViewState {
|
||||
return getLView() as any as OpaqueViewState;
|
||||
}
|
||||
|
|
|
@ -31,7 +31,7 @@ import {BindingDirection, generatePropertyAliases, getCleanup, handleError, load
|
|||
*
|
||||
* @codeGenApi
|
||||
*/
|
||||
export function ɵɵlistener(
|
||||
export function Δlistener(
|
||||
eventName: string, listenerFn: (e?: any) => any, useCapture = false,
|
||||
eventTargetResolver?: GlobalTargetResolver): void {
|
||||
listenerInternal(eventName, listenerFn, useCapture, eventTargetResolver);
|
||||
|
@ -58,7 +58,7 @@ export function ɵɵlistener(
|
|||
*
|
||||
* @codeGenApi
|
||||
*/
|
||||
export function ɵɵcomponentHostSyntheticListener<T>(
|
||||
export function ΔcomponentHostSyntheticListener<T>(
|
||||
eventName: string, listenerFn: (e?: any) => any, useCapture = false,
|
||||
eventTargetResolver?: GlobalTargetResolver): void {
|
||||
listenerInternal(eventName, listenerFn, useCapture, eventTargetResolver, loadComponentRenderer);
|
||||
|
|
|
@ -6,4 +6,4 @@
|
|||
* found in the LICENSE file at https://angular.io/license
|
||||
*/
|
||||
|
||||
export {ɵɵnamespaceHTML, ɵɵnamespaceMathML, ɵɵnamespaceSVG} from '../state';
|
||||
export {ΔnamespaceHTML, ΔnamespaceMathML, ΔnamespaceSVG} from '../state';
|
||||
|
|
|
@ -19,6 +19,6 @@ import {nextContextImpl} from '../state';
|
|||
*
|
||||
* @codeGenApi
|
||||
*/
|
||||
export function ɵɵnextContext<T = any>(level: number = 1): T {
|
||||
export function ΔnextContext<T = any>(level: number = 1): T {
|
||||
return nextContextImpl(level);
|
||||
}
|
||||
|
|
|
@ -39,7 +39,7 @@ import {createNodeAtIndex} from './shared';
|
|||
*
|
||||
* @codeGenApi
|
||||
*/
|
||||
export function ɵɵprojectionDef(selectors?: CssSelectorList[]): void {
|
||||
export function ΔprojectionDef(selectors?: CssSelectorList[]): void {
|
||||
const componentNode = findComponentView(getLView())[T_HOST] as TElementNode;
|
||||
|
||||
if (!componentNode.projection) {
|
||||
|
@ -78,7 +78,7 @@ export function ɵɵprojectionDef(selectors?: CssSelectorList[]): void {
|
|||
*
|
||||
* @codeGenApi
|
||||
*/
|
||||
export function ɵɵprojection(
|
||||
export function Δprojection(
|
||||
nodeIndex: number, selectorIndex: number = 0, attrs?: TAttributes): void {
|
||||
const lView = getLView();
|
||||
const tProjectionNode =
|
||||
|
|
|
@ -35,16 +35,16 @@ import {TsickleIssue1009, elementPropertyInternal, loadComponentRenderer, storeB
|
|||
*
|
||||
* @codeGenApi
|
||||
*/
|
||||
export function ɵɵproperty<T>(
|
||||
export function Δproperty<T>(
|
||||
propName: string, value: T, sanitizer?: SanitizerFn | null,
|
||||
nativeOnly?: boolean): TsickleIssue1009 {
|
||||
const index = getSelectedIndex();
|
||||
ngDevMode && assertNotEqual(index, -1, 'selected index cannot be -1');
|
||||
const bindReconciledValue = ɵɵbind(value);
|
||||
const bindReconciledValue = Δbind(value);
|
||||
if (bindReconciledValue !== NO_CHANGE) {
|
||||
elementPropertyInternal(index, propName, bindReconciledValue, sanitizer, nativeOnly);
|
||||
}
|
||||
return ɵɵproperty;
|
||||
return Δproperty;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -54,7 +54,7 @@ export function ɵɵproperty<T>(
|
|||
*
|
||||
* @codeGenApi
|
||||
*/
|
||||
export function ɵɵbind<T>(value: T): T|NO_CHANGE {
|
||||
export function Δbind<T>(value: T): T|NO_CHANGE {
|
||||
const lView = getLView();
|
||||
const bindingIndex = lView[BINDING_INDEX]++;
|
||||
storeBindingMetadata(lView);
|
||||
|
@ -79,7 +79,7 @@ export function ɵɵbind<T>(value: T): T|NO_CHANGE {
|
|||
*
|
||||
* @codeGenApi
|
||||
*/
|
||||
export function ɵɵelementProperty<T>(
|
||||
export function ΔelementProperty<T>(
|
||||
index: number, propName: string, value: T | NO_CHANGE, sanitizer?: SanitizerFn | null,
|
||||
nativeOnly?: boolean): void {
|
||||
if (value !== NO_CHANGE) {
|
||||
|
@ -110,7 +110,7 @@ export function ɵɵelementProperty<T>(
|
|||
*
|
||||
* @codeGenApi
|
||||
*/
|
||||
export function ɵɵcomponentHostSyntheticProperty<T>(
|
||||
export function ΔcomponentHostSyntheticProperty<T>(
|
||||
index: number, propName: string, value: T | NO_CHANGE, sanitizer?: SanitizerFn | null,
|
||||
nativeOnly?: boolean) {
|
||||
if (value !== NO_CHANGE) {
|
||||
|
|
|
@ -31,7 +31,7 @@ import {TsickleIssue1009, elementPropertyInternal, storeBindingMetadata} from '.
|
|||
*
|
||||
* @codeGenApi
|
||||
*/
|
||||
export function ɵɵinterpolationV(values: any[]): string|NO_CHANGE {
|
||||
export function ΔinterpolationV(values: any[]): string|NO_CHANGE {
|
||||
ngDevMode && assertLessThan(2, values.length, 'should have at least 3 values');
|
||||
ngDevMode && assertEqual(values.length % 2, 1, 'should have an odd number of values');
|
||||
let different = false;
|
||||
|
@ -76,7 +76,7 @@ export function ɵɵinterpolationV(values: any[]): string|NO_CHANGE {
|
|||
*
|
||||
* @codeGenApi
|
||||
*/
|
||||
export function ɵɵinterpolation1(prefix: string, v0: any, suffix: string): string|NO_CHANGE {
|
||||
export function Δinterpolation1(prefix: string, v0: any, suffix: string): string|NO_CHANGE {
|
||||
const lView = getLView();
|
||||
const different = bindingUpdated(lView, lView[BINDING_INDEX]++, v0);
|
||||
storeBindingMetadata(lView, prefix, suffix);
|
||||
|
@ -88,7 +88,7 @@ export function ɵɵinterpolation1(prefix: string, v0: any, suffix: string): str
|
|||
*
|
||||
* @codeGenApi
|
||||
*/
|
||||
export function ɵɵinterpolation2(
|
||||
export function Δinterpolation2(
|
||||
prefix: string, v0: any, i0: string, v1: any, suffix: string): string|NO_CHANGE {
|
||||
const lView = getLView();
|
||||
const bindingIndex = lView[BINDING_INDEX];
|
||||
|
@ -109,7 +109,7 @@ export function ɵɵinterpolation2(
|
|||
*
|
||||
* @codeGenApi
|
||||
*/
|
||||
export function ɵɵinterpolation3(
|
||||
export function Δinterpolation3(
|
||||
prefix: string, v0: any, i0: string, v1: any, i1: string, v2: any, suffix: string): string|
|
||||
NO_CHANGE {
|
||||
const lView = getLView();
|
||||
|
@ -135,7 +135,7 @@ export function ɵɵinterpolation3(
|
|||
*
|
||||
* @codeGenApi
|
||||
*/
|
||||
export function ɵɵinterpolation4(
|
||||
export function Δinterpolation4(
|
||||
prefix: string, v0: any, i0: string, v1: any, i1: string, v2: any, i2: string, v3: any,
|
||||
suffix: string): string|NO_CHANGE {
|
||||
const lView = getLView();
|
||||
|
@ -163,7 +163,7 @@ export function ɵɵinterpolation4(
|
|||
*
|
||||
* @codeGenApi
|
||||
*/
|
||||
export function ɵɵinterpolation5(
|
||||
export function Δinterpolation5(
|
||||
prefix: string, v0: any, i0: string, v1: any, i1: string, v2: any, i2: string, v3: any,
|
||||
i3: string, v4: any, suffix: string): string|NO_CHANGE {
|
||||
const lView = getLView();
|
||||
|
@ -193,7 +193,7 @@ export function ɵɵinterpolation5(
|
|||
*
|
||||
* @codeGenApi
|
||||
*/
|
||||
export function ɵɵinterpolation6(
|
||||
export function Δinterpolation6(
|
||||
prefix: string, v0: any, i0: string, v1: any, i1: string, v2: any, i2: string, v3: any,
|
||||
i3: string, v4: any, i4: string, v5: any, suffix: string): string|NO_CHANGE {
|
||||
const lView = getLView();
|
||||
|
@ -224,7 +224,7 @@ export function ɵɵinterpolation6(
|
|||
*
|
||||
* @codeGenApi
|
||||
*/
|
||||
export function ɵɵinterpolation7(
|
||||
export function Δinterpolation7(
|
||||
prefix: string, v0: any, i0: string, v1: any, i1: string, v2: any, i2: string, v3: any,
|
||||
i3: string, v4: any, i4: string, v5: any, i5: string, v6: any, suffix: string): string|
|
||||
NO_CHANGE {
|
||||
|
@ -258,7 +258,7 @@ export function ɵɵinterpolation7(
|
|||
*
|
||||
* @codeGenApi
|
||||
*/
|
||||
export function ɵɵinterpolation8(
|
||||
export function Δinterpolation8(
|
||||
prefix: string, v0: any, i0: string, v1: any, i1: string, v2: any, i2: string, v3: any,
|
||||
i3: string, v4: any, i4: string, v5: any, i5: string, v6: any, i6: string, v7: any,
|
||||
suffix: string): string|NO_CHANGE {
|
||||
|
@ -306,7 +306,7 @@ export function ɵɵinterpolation8(
|
|||
* Its compiled representation is::
|
||||
*
|
||||
* ```ts
|
||||
* ɵɵpropertyInterpolate('title', v0);
|
||||
* ΔpropertyInterpolate('title', v0);
|
||||
* ```
|
||||
*
|
||||
* If the property name also exists as an input property on one of the element's directives,
|
||||
|
@ -321,10 +321,10 @@ export function ɵɵinterpolation8(
|
|||
* @returns itself, so that it may be chained.
|
||||
* @codeGenApi
|
||||
*/
|
||||
export function ɵɵpropertyInterpolate(
|
||||
export function ΔpropertyInterpolate(
|
||||
propName: string, v0: any, sanitizer?: SanitizerFn): TsickleIssue1009 {
|
||||
ɵɵpropertyInterpolate1(propName, '', v0, '', sanitizer);
|
||||
return ɵɵpropertyInterpolate;
|
||||
ΔpropertyInterpolate1(propName, '', v0, '', sanitizer);
|
||||
return ΔpropertyInterpolate;
|
||||
}
|
||||
|
||||
|
||||
|
@ -341,7 +341,7 @@ export function ɵɵpropertyInterpolate(
|
|||
* Its compiled representation is::
|
||||
*
|
||||
* ```ts
|
||||
* ɵɵpropertyInterpolate1('title', 'prefix', v0, 'suffix');
|
||||
* ΔpropertyInterpolate1('title', 'prefix', v0, 'suffix');
|
||||
* ```
|
||||
*
|
||||
* If the property name also exists as an input property on one of the element's directives,
|
||||
|
@ -356,15 +356,15 @@ export function ɵɵpropertyInterpolate(
|
|||
* @returns itself, so that it may be chained.
|
||||
* @codeGenApi
|
||||
*/
|
||||
export function ɵɵpropertyInterpolate1(
|
||||
export function ΔpropertyInterpolate1(
|
||||
propName: string, prefix: string, v0: any, suffix: string,
|
||||
sanitizer?: SanitizerFn): TsickleIssue1009 {
|
||||
const index = getSelectedIndex();
|
||||
const interpolatedValue = ɵɵinterpolation1(prefix, v0, suffix);
|
||||
const interpolatedValue = Δinterpolation1(prefix, v0, suffix);
|
||||
if (interpolatedValue !== NO_CHANGE) {
|
||||
elementPropertyInternal(index, propName, interpolatedValue, sanitizer);
|
||||
}
|
||||
return ɵɵpropertyInterpolate1;
|
||||
return ΔpropertyInterpolate1;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -380,7 +380,7 @@ export function ɵɵpropertyInterpolate1(
|
|||
* Its compiled representation is::
|
||||
*
|
||||
* ```ts
|
||||
* ɵɵpropertyInterpolate2('title', 'prefix', v0, '-', v1, 'suffix');
|
||||
* ΔpropertyInterpolate2('title', 'prefix', v0, '-', v1, 'suffix');
|
||||
* ```
|
||||
*
|
||||
* If the property name also exists as an input property on one of the element's directives,
|
||||
|
@ -397,15 +397,15 @@ export function ɵɵpropertyInterpolate1(
|
|||
* @returns itself, so that it may be chained.
|
||||
* @codeGenApi
|
||||
*/
|
||||
export function ɵɵpropertyInterpolate2(
|
||||
export function ΔpropertyInterpolate2(
|
||||
propName: string, prefix: string, v0: any, i0: string, v1: any, suffix: string,
|
||||
sanitizer?: SanitizerFn): TsickleIssue1009 {
|
||||
const index = getSelectedIndex();
|
||||
const interpolatedValue = ɵɵinterpolation2(prefix, v0, i0, v1, suffix);
|
||||
const interpolatedValue = Δinterpolation2(prefix, v0, i0, v1, suffix);
|
||||
if (interpolatedValue !== NO_CHANGE) {
|
||||
elementPropertyInternal(index, propName, interpolatedValue, sanitizer);
|
||||
}
|
||||
return ɵɵpropertyInterpolate2;
|
||||
return ΔpropertyInterpolate2;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -421,7 +421,7 @@ export function ɵɵpropertyInterpolate2(
|
|||
* Its compiled representation is::
|
||||
*
|
||||
* ```ts
|
||||
* ɵɵpropertyInterpolate3(
|
||||
* ΔpropertyInterpolate3(
|
||||
* 'title', 'prefix', v0, '-', v1, '-', v2, 'suffix');
|
||||
* ```
|
||||
*
|
||||
|
@ -441,15 +441,15 @@ export function ɵɵpropertyInterpolate2(
|
|||
* @returns itself, so that it may be chained.
|
||||
* @codeGenApi
|
||||
*/
|
||||
export function ɵɵpropertyInterpolate3(
|
||||
export function ΔpropertyInterpolate3(
|
||||
propName: string, prefix: string, v0: any, i0: string, v1: any, i1: string, v2: any,
|
||||
suffix: string, sanitizer?: SanitizerFn): TsickleIssue1009 {
|
||||
const index = getSelectedIndex();
|
||||
const interpolatedValue = ɵɵinterpolation3(prefix, v0, i0, v1, i1, v2, suffix);
|
||||
const interpolatedValue = Δinterpolation3(prefix, v0, i0, v1, i1, v2, suffix);
|
||||
if (interpolatedValue !== NO_CHANGE) {
|
||||
elementPropertyInternal(index, propName, interpolatedValue, sanitizer);
|
||||
}
|
||||
return ɵɵpropertyInterpolate3;
|
||||
return ΔpropertyInterpolate3;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -465,7 +465,7 @@ export function ɵɵpropertyInterpolate3(
|
|||
* Its compiled representation is::
|
||||
*
|
||||
* ```ts
|
||||
* ɵɵpropertyInterpolate4(
|
||||
* ΔpropertyInterpolate4(
|
||||
* 'title', 'prefix', v0, '-', v1, '-', v2, '-', v3, 'suffix');
|
||||
* ```
|
||||
*
|
||||
|
@ -487,15 +487,15 @@ export function ɵɵpropertyInterpolate3(
|
|||
* @returns itself, so that it may be chained.
|
||||
* @codeGenApi
|
||||
*/
|
||||
export function ɵɵpropertyInterpolate4(
|
||||
export function ΔpropertyInterpolate4(
|
||||
propName: string, prefix: string, v0: any, i0: string, v1: any, i1: string, v2: any, i2: string,
|
||||
v3: any, suffix: string, sanitizer?: SanitizerFn): TsickleIssue1009 {
|
||||
const index = getSelectedIndex();
|
||||
const interpolatedValue = ɵɵinterpolation4(prefix, v0, i0, v1, i1, v2, i2, v3, suffix);
|
||||
const interpolatedValue = Δinterpolation4(prefix, v0, i0, v1, i1, v2, i2, v3, suffix);
|
||||
if (interpolatedValue !== NO_CHANGE) {
|
||||
elementPropertyInternal(index, propName, interpolatedValue, sanitizer);
|
||||
}
|
||||
return ɵɵpropertyInterpolate4;
|
||||
return ΔpropertyInterpolate4;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -511,7 +511,7 @@ export function ɵɵpropertyInterpolate4(
|
|||
* Its compiled representation is::
|
||||
*
|
||||
* ```ts
|
||||
* ɵɵpropertyInterpolate5(
|
||||
* ΔpropertyInterpolate5(
|
||||
* 'title', 'prefix', v0, '-', v1, '-', v2, '-', v3, '-', v4, 'suffix');
|
||||
* ```
|
||||
*
|
||||
|
@ -535,15 +535,15 @@ export function ɵɵpropertyInterpolate4(
|
|||
* @returns itself, so that it may be chained.
|
||||
* @codeGenApi
|
||||
*/
|
||||
export function ɵɵpropertyInterpolate5(
|
||||
export function ΔpropertyInterpolate5(
|
||||
propName: string, prefix: string, v0: any, i0: string, v1: any, i1: string, v2: any, i2: string,
|
||||
v3: any, i3: string, v4: any, suffix: string, sanitizer?: SanitizerFn): TsickleIssue1009 {
|
||||
const index = getSelectedIndex();
|
||||
const interpolatedValue = ɵɵinterpolation5(prefix, v0, i0, v1, i1, v2, i2, v3, i3, v4, suffix);
|
||||
const interpolatedValue = Δinterpolation5(prefix, v0, i0, v1, i1, v2, i2, v3, i3, v4, suffix);
|
||||
if (interpolatedValue !== NO_CHANGE) {
|
||||
elementPropertyInternal(index, propName, interpolatedValue, sanitizer);
|
||||
}
|
||||
return ɵɵpropertyInterpolate5;
|
||||
return ΔpropertyInterpolate5;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -559,7 +559,7 @@ export function ɵɵpropertyInterpolate5(
|
|||
* Its compiled representation is::
|
||||
*
|
||||
* ```ts
|
||||
* ɵɵpropertyInterpolate6(
|
||||
* ΔpropertyInterpolate6(
|
||||
* 'title', 'prefix', v0, '-', v1, '-', v2, '-', v3, '-', v4, '-', v5, 'suffix');
|
||||
* ```
|
||||
*
|
||||
|
@ -585,17 +585,17 @@ export function ɵɵpropertyInterpolate5(
|
|||
* @returns itself, so that it may be chained.
|
||||
* @codeGenApi
|
||||
*/
|
||||
export function ɵɵpropertyInterpolate6(
|
||||
export function ΔpropertyInterpolate6(
|
||||
propName: string, prefix: string, v0: any, i0: string, v1: any, i1: string, v2: any, i2: string,
|
||||
v3: any, i3: string, v4: any, i4: string, v5: any, suffix: string,
|
||||
sanitizer?: SanitizerFn): TsickleIssue1009 {
|
||||
const index = getSelectedIndex();
|
||||
const interpolatedValue =
|
||||
ɵɵinterpolation6(prefix, v0, i0, v1, i1, v2, i2, v3, i3, v4, i4, v5, suffix);
|
||||
Δinterpolation6(prefix, v0, i0, v1, i1, v2, i2, v3, i3, v4, i4, v5, suffix);
|
||||
if (interpolatedValue !== NO_CHANGE) {
|
||||
elementPropertyInternal(index, propName, interpolatedValue, sanitizer);
|
||||
}
|
||||
return ɵɵpropertyInterpolate6;
|
||||
return ΔpropertyInterpolate6;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -611,7 +611,7 @@ export function ɵɵpropertyInterpolate6(
|
|||
* Its compiled representation is::
|
||||
*
|
||||
* ```ts
|
||||
* ɵɵpropertyInterpolate7(
|
||||
* ΔpropertyInterpolate7(
|
||||
* 'title', 'prefix', v0, '-', v1, '-', v2, '-', v3, '-', v4, '-', v5, '-', v6, 'suffix');
|
||||
* ```
|
||||
*
|
||||
|
@ -639,17 +639,17 @@ export function ɵɵpropertyInterpolate6(
|
|||
* @returns itself, so that it may be chained.
|
||||
* @codeGenApi
|
||||
*/
|
||||
export function ɵɵpropertyInterpolate7(
|
||||
export function ΔpropertyInterpolate7(
|
||||
propName: string, prefix: string, v0: any, i0: string, v1: any, i1: string, v2: any, i2: string,
|
||||
v3: any, i3: string, v4: any, i4: string, v5: any, i5: string, v6: any, suffix: string,
|
||||
sanitizer?: SanitizerFn): TsickleIssue1009 {
|
||||
const index = getSelectedIndex();
|
||||
const interpolatedValue =
|
||||
ɵɵinterpolation7(prefix, v0, i0, v1, i1, v2, i2, v3, i3, v4, i4, v5, i5, v6, suffix);
|
||||
Δinterpolation7(prefix, v0, i0, v1, i1, v2, i2, v3, i3, v4, i4, v5, i5, v6, suffix);
|
||||
if (interpolatedValue !== NO_CHANGE) {
|
||||
elementPropertyInternal(index, propName, interpolatedValue, sanitizer);
|
||||
}
|
||||
return ɵɵpropertyInterpolate7;
|
||||
return ΔpropertyInterpolate7;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -665,7 +665,7 @@ export function ɵɵpropertyInterpolate7(
|
|||
* Its compiled representation is::
|
||||
*
|
||||
* ```ts
|
||||
* ɵɵpropertyInterpolate8(
|
||||
* ΔpropertyInterpolate8(
|
||||
* 'title', 'prefix', v0, '-', v1, '-', v2, '-', v3, '-', v4, '-', v5, '-', v6, '-', v7, 'suffix');
|
||||
* ```
|
||||
*
|
||||
|
@ -695,17 +695,17 @@ export function ɵɵpropertyInterpolate7(
|
|||
* @returns itself, so that it may be chained.
|
||||
* @codeGenApi
|
||||
*/
|
||||
export function ɵɵpropertyInterpolate8(
|
||||
export function ΔpropertyInterpolate8(
|
||||
propName: string, prefix: string, v0: any, i0: string, v1: any, i1: string, v2: any, i2: string,
|
||||
v3: any, i3: string, v4: any, i4: string, v5: any, i5: string, v6: any, i6: string, v7: any,
|
||||
suffix: string, sanitizer?: SanitizerFn): TsickleIssue1009 {
|
||||
const index = getSelectedIndex();
|
||||
const interpolatedValue =
|
||||
ɵɵinterpolation8(prefix, v0, i0, v1, i1, v2, i2, v3, i3, v4, i4, v5, i5, v6, i6, v7, suffix);
|
||||
Δinterpolation8(prefix, v0, i0, v1, i1, v2, i2, v3, i3, v4, i4, v5, i5, v6, i6, v7, suffix);
|
||||
if (interpolatedValue !== NO_CHANGE) {
|
||||
elementPropertyInternal(index, propName, interpolatedValue, sanitizer);
|
||||
}
|
||||
return ɵɵpropertyInterpolate8;
|
||||
return ΔpropertyInterpolate8;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -721,7 +721,7 @@ export function ɵɵpropertyInterpolate8(
|
|||
* Its compiled representation is::
|
||||
*
|
||||
* ```ts
|
||||
* ɵɵpropertyInterpolateV(
|
||||
* ΔpropertyInterpolateV(
|
||||
* 'title', ['prefix', v0, '-', v1, '-', v2, '-', v3, '-', v4, '-', v5, '-', v6, '-', v7, '-', v9,
|
||||
* 'suffix']);
|
||||
* ```
|
||||
|
@ -738,13 +738,13 @@ export function ɵɵpropertyInterpolate8(
|
|||
* @returns itself, so that it may be chained.
|
||||
* @codeGenApi
|
||||
*/
|
||||
export function ɵɵpropertyInterpolateV(
|
||||
export function ΔpropertyInterpolateV(
|
||||
propName: string, values: any[], sanitizer?: SanitizerFn): TsickleIssue1009 {
|
||||
const index = getSelectedIndex();
|
||||
|
||||
const interpolatedValue = ɵɵinterpolationV(values);
|
||||
const interpolatedValue = ΔinterpolationV(values);
|
||||
if (interpolatedValue !== NO_CHANGE) {
|
||||
elementPropertyInternal(index, propName, interpolatedValue, sanitizer);
|
||||
}
|
||||
return ɵɵpropertyInterpolateV;
|
||||
return ΔpropertyInterpolateV;
|
||||
}
|
||||
|
|
|
@ -31,7 +31,7 @@ import {getCheckNoChangesMode, getLView, setSelectedIndex} from '../state';
|
|||
*
|
||||
* @codeGenApi
|
||||
*/
|
||||
export function ɵɵselect(index: number): void {
|
||||
export function Δselect(index: number): void {
|
||||
ngDevMode && assertGreaterThan(index, -1, 'Invalid index');
|
||||
ngDevMode &&
|
||||
assertLessThan(
|
||||
|
@ -44,6 +44,6 @@ export function ɵɵselect(index: number): void {
|
|||
// We must set the selected index *after* running the hooks, because hooks may have side-effects
|
||||
// that cause other template functions to run, thus updating the selected index, which is global
|
||||
// state. If we run `setSelectedIndex` *before* we run the hooks, in some cases the selected index
|
||||
// will be altered by the time we leave the `ɵɵselect` instruction.
|
||||
// will be altered by the time we leave the `Δselect` instruction.
|
||||
setSelectedIndex(index);
|
||||
}
|
||||
|
|
|
@ -30,7 +30,7 @@ import {StylingContext} from '../interfaces/styling';
|
|||
import {BINDING_INDEX, CHILD_HEAD, CHILD_TAIL, CLEANUP, CONTEXT, DECLARATION_VIEW, ExpandoInstructions, FLAGS, HEADER_OFFSET, HOST, INJECTOR, InitPhaseState, LView, LViewFlags, NEXT, PARENT, QUERIES, RENDERER, RENDERER_FACTORY, RootContext, RootContextFlags, SANITIZER, TData, TVIEW, TView, T_HOST} from '../interfaces/view';
|
||||
import {assertNodeOfPossibleTypes, assertNodeType} from '../node_assert';
|
||||
import {isNodeMatchingSelectorList} from '../node_selector_matcher';
|
||||
import {enterView, getBindingsEnabled, getCheckNoChangesMode, getIsParent, getLView, getNamespace, getPreviousOrParentTNode, getSelectedIndex, incrementActiveDirectiveId, isCreationMode, leaveView, resetComponentState, setActiveHostElement, setBindingRoot, setCheckNoChangesMode, setCurrentDirectiveDef, setCurrentQueryIndex, setIsParent, setPreviousOrParentTNode, setSelectedIndex, ɵɵnamespaceHTML} from '../state';
|
||||
import {enterView, getBindingsEnabled, getCheckNoChangesMode, getIsParent, getLView, getNamespace, getPreviousOrParentTNode, getSelectedIndex, incrementActiveDirectiveId, isCreationMode, leaveView, resetComponentState, setActiveHostElement, setBindingRoot, setCheckNoChangesMode, setCurrentDirectiveDef, setCurrentQueryIndex, setIsParent, setPreviousOrParentTNode, setSelectedIndex, ΔnamespaceHTML} from '../state';
|
||||
import {initializeStaticContext as initializeStaticStylingContext} from '../styling/class_and_style_bindings';
|
||||
import {ANIMATION_PROP_PREFIX, isAnimationProp} from '../styling/util';
|
||||
import {NO_CHANGE} from '../tokens';
|
||||
|
@ -484,7 +484,7 @@ function renderComponentOrTemplate<T>(
|
|||
}
|
||||
|
||||
function executeTemplate<T>(templateFn: ComponentTemplate<T>, rf: RenderFlags, context: T) {
|
||||
ɵɵnamespaceHTML();
|
||||
ΔnamespaceHTML();
|
||||
const prevSelectedIndex = getSelectedIndex();
|
||||
try {
|
||||
setActiveHostElement(null);
|
||||
|
|
|
@ -33,7 +33,7 @@ export function store<T>(index: number, value: T): void {
|
|||
*
|
||||
* @codeGenApi
|
||||
*/
|
||||
export function ɵɵreference<T>(index: number) {
|
||||
export function Δreference<T>(index: number) {
|
||||
const contextLView = getContextLView();
|
||||
return loadInternal<T>(contextLView, index);
|
||||
}
|
||||
|
@ -43,6 +43,6 @@ export function ɵɵreference<T>(index: number) {
|
|||
*
|
||||
* @codeGenApi
|
||||
*/
|
||||
export function ɵɵload<T>(index: number): T {
|
||||
export function Δload<T>(index: number): T {
|
||||
return loadInternal<T>(getLView(), index);
|
||||
}
|
||||
|
|
|
@ -63,7 +63,7 @@ import {scheduleTick, setInputsForProperty} from './shared';
|
|||
*
|
||||
* @codeGenApi
|
||||
*/
|
||||
export function ɵɵstyling(
|
||||
export function Δstyling(
|
||||
classBindingNames?: string[] | null, styleBindingNames?: string[] | null,
|
||||
styleSanitizer?: StyleSanitizeFn | null): void {
|
||||
const tNode = getPreviousOrParentTNode();
|
||||
|
@ -133,7 +133,7 @@ function initstyling(
|
|||
*
|
||||
* @codeGenApi
|
||||
*/
|
||||
export function ɵɵstyleProp(
|
||||
export function ΔstyleProp(
|
||||
styleIndex: number, value: string | number | String | PlayerFactory | null,
|
||||
suffix?: string | null, forceOverride?: boolean): void {
|
||||
const index = getSelectedIndex();
|
||||
|
@ -190,7 +190,7 @@ function resolveStylePropValue(
|
|||
*
|
||||
* @codeGenApi
|
||||
*/
|
||||
export function ɵɵclassProp(
|
||||
export function ΔclassProp(
|
||||
classIndex: number, value: boolean | PlayerFactory, forceOverride?: boolean): void {
|
||||
const index = getSelectedIndex();
|
||||
const input = (value instanceof BoundPlayerFactory) ?
|
||||
|
@ -234,7 +234,7 @@ function booleanOrNull(value: any): boolean|null {
|
|||
*
|
||||
* @codeGenApi
|
||||
*/
|
||||
export function ɵɵstyleMap(styles: {[styleName: string]: any} | NO_CHANGE | null): void {
|
||||
export function ΔstyleMap(styles: {[styleName: string]: any} | NO_CHANGE | null): void {
|
||||
const index = getSelectedIndex();
|
||||
const lView = getLView();
|
||||
const stylingContext = getStylingContext(index, lView);
|
||||
|
@ -278,7 +278,7 @@ export function ɵɵstyleMap(styles: {[styleName: string]: any} | NO_CHANGE | nu
|
|||
*
|
||||
* @codeGenApi
|
||||
*/
|
||||
export function ɵɵclassMap(classes: {[styleName: string]: any} | NO_CHANGE | string | null): void {
|
||||
export function ΔclassMap(classes: {[styleName: string]: any} | NO_CHANGE | string | null): void {
|
||||
const index = getSelectedIndex();
|
||||
const lView = getLView();
|
||||
const stylingContext = getStylingContext(index, lView);
|
||||
|
@ -311,7 +311,7 @@ export function ɵɵclassMap(classes: {[styleName: string]: any} | NO_CHANGE | s
|
|||
*
|
||||
* @codeGenApi
|
||||
*/
|
||||
export function ɵɵstylingApply(): void {
|
||||
export function ΔstylingApply(): void {
|
||||
const index = getSelectedIndex();
|
||||
const directiveStylingIndex =
|
||||
getActiveDirectiveStylingIndex() || DEFAULT_TEMPLATE_DIRECTIVE_INDEX;
|
||||
|
|
|
@ -24,7 +24,7 @@ import {createNodeAtIndex} from './shared';
|
|||
*
|
||||
* @codeGenApi
|
||||
*/
|
||||
export function ɵɵtext(index: number, value?: any): void {
|
||||
export function Δtext(index: number, value?: any): void {
|
||||
const lView = getLView();
|
||||
ngDevMode && assertEqual(
|
||||
lView[BINDING_INDEX], lView[TVIEW].bindingStartIndex,
|
||||
|
@ -47,7 +47,7 @@ export function ɵɵtext(index: number, value?: any): void {
|
|||
*
|
||||
* @codeGenApi
|
||||
*/
|
||||
export function ɵɵtextBinding<T>(index: number, value: T | NO_CHANGE): void {
|
||||
export function ΔtextBinding<T>(index: number, value: T | NO_CHANGE): void {
|
||||
if (value !== NO_CHANGE) {
|
||||
const lView = getLView();
|
||||
ngDevMode && assertDataInRange(lView, index + HEADER_OFFSET);
|
||||
|
|
|
@ -88,7 +88,7 @@ export interface PipeType<T> extends Type<T> { ngPipeDef: never; }
|
|||
/**
|
||||
* @codeGenApi
|
||||
*/
|
||||
export type ɵɵDirectiveDefWithMeta<
|
||||
export type ΔDirectiveDefWithMeta<
|
||||
T, Selector extends string, ExportAs extends string[], InputMap extends{[key: string]: string},
|
||||
OutputMap extends{[key: string]: string}, QueryFields extends string[]> = DirectiveDef<T>;
|
||||
|
||||
|
@ -103,7 +103,7 @@ export type ɵɵDirectiveDefWithMeta<
|
|||
*
|
||||
* @codeGenApi
|
||||
*/
|
||||
export interface ɵɵBaseDef<T> {
|
||||
export interface ΔBaseDef<T> {
|
||||
/**
|
||||
* A dictionary mapping the inputs' minified property names to their public API names, which
|
||||
* are their aliases if any, or their original unminified property names
|
||||
|
@ -156,7 +156,7 @@ export interface ɵɵBaseDef<T> {
|
|||
*
|
||||
* See: {@link defineDirective}
|
||||
*/
|
||||
export interface DirectiveDef<T> extends ɵɵBaseDef<T> {
|
||||
export interface DirectiveDef<T> extends ΔBaseDef<T> {
|
||||
/** Token representing the directive. Used by DI. */
|
||||
type: Type<T>;
|
||||
|
||||
|
@ -202,7 +202,7 @@ export interface DirectiveDef<T> extends ɵɵBaseDef<T> {
|
|||
/**
|
||||
* @codeGenApi
|
||||
*/
|
||||
export type ɵɵComponentDefWithMeta<
|
||||
export type ΔComponentDefWithMeta<
|
||||
T, Selector extends String, ExportAs extends string[], InputMap extends{[key: string]: string},
|
||||
OutputMap extends{[key: string]: string}, QueryFields extends string[]> = ComponentDef<T>;
|
||||
|
||||
|
@ -349,7 +349,7 @@ export interface PipeDef<T> {
|
|||
/**
|
||||
* @codeGenApi
|
||||
*/
|
||||
export type ɵɵPipeDefWithMeta<T, Name extends string> = PipeDef<T>;
|
||||
export type ΔPipeDefWithMeta<T, Name extends string> = PipeDef<T>;
|
||||
|
||||
export interface DirectiveDefFeature {
|
||||
<T>(directiveDef: DirectiveDef<T>): void;
|
||||
|
|
|
@ -6,8 +6,8 @@
|
|||
* found in the LICENSE file at https://angular.io/license
|
||||
*/
|
||||
|
||||
import {ɵɵdefineInjectable, ɵɵdefineInjector,} from '../../di/interface/defs';
|
||||
import {ɵɵinject} from '../../di/injector_compatibility';
|
||||
import {ΔdefineInjectable, ΔdefineInjector,} from '../../di/interface/defs';
|
||||
import {Δinject} from '../../di/injector_compatibility';
|
||||
import * as r3 from '../index';
|
||||
import * as sanitization from '../../sanitization/sanitization';
|
||||
|
||||
|
@ -18,124 +18,124 @@ import * as sanitization from '../../sanitization/sanitization';
|
|||
* This should be kept up to date with the public exports of @angular/core.
|
||||
*/
|
||||
export const angularCoreEnv: {[name: string]: Function} = {
|
||||
'ɵɵdefineBase': r3.ɵɵdefineBase,
|
||||
'ɵɵdefineComponent': r3.ɵɵdefineComponent,
|
||||
'ɵɵdefineDirective': r3.ɵɵdefineDirective,
|
||||
'ɵɵdefineInjectable': ɵɵdefineInjectable,
|
||||
'ɵɵdefineInjector': ɵɵdefineInjector,
|
||||
'ɵɵdefineNgModule': r3.ɵɵdefineNgModule,
|
||||
'ɵɵdefinePipe': r3.ɵɵdefinePipe,
|
||||
'ɵɵdirectiveInject': r3.ɵɵdirectiveInject,
|
||||
'ɵɵgetFactoryOf': r3.ɵɵgetFactoryOf,
|
||||
'ɵɵgetInheritedFactory': r3.ɵɵgetInheritedFactory,
|
||||
'ɵɵinject': ɵɵinject,
|
||||
'ɵɵinjectAttribute': r3.ɵɵinjectAttribute,
|
||||
'ɵɵtemplateRefExtractor': r3.ɵɵtemplateRefExtractor,
|
||||
'ɵɵNgOnChangesFeature': r3.ɵɵNgOnChangesFeature,
|
||||
'ɵɵProvidersFeature': r3.ɵɵProvidersFeature,
|
||||
'ɵɵInheritDefinitionFeature': r3.ɵɵInheritDefinitionFeature,
|
||||
'ɵɵelementAttribute': r3.ɵɵelementAttribute,
|
||||
'ɵɵbind': r3.ɵɵbind,
|
||||
'ɵɵcontainer': r3.ɵɵcontainer,
|
||||
'ɵɵnextContext': r3.ɵɵnextContext,
|
||||
'ɵɵcontainerRefreshStart': r3.ɵɵcontainerRefreshStart,
|
||||
'ɵɵcontainerRefreshEnd': r3.ɵɵcontainerRefreshEnd,
|
||||
'ɵɵnamespaceHTML': r3.ɵɵnamespaceHTML,
|
||||
'ɵɵnamespaceMathML': r3.ɵɵnamespaceMathML,
|
||||
'ɵɵnamespaceSVG': r3.ɵɵnamespaceSVG,
|
||||
'ɵɵenableBindings': r3.ɵɵenableBindings,
|
||||
'ɵɵdisableBindings': r3.ɵɵdisableBindings,
|
||||
'ɵɵallocHostVars': r3.ɵɵallocHostVars,
|
||||
'ɵɵelementStart': r3.ɵɵelementStart,
|
||||
'ɵɵelementEnd': r3.ɵɵelementEnd,
|
||||
'ɵɵelement': r3.ɵɵelement,
|
||||
'ɵɵelementContainerStart': r3.ɵɵelementContainerStart,
|
||||
'ɵɵelementContainerEnd': r3.ɵɵelementContainerEnd,
|
||||
'ɵɵpureFunction0': r3.ɵɵpureFunction0,
|
||||
'ɵɵpureFunction1': r3.ɵɵpureFunction1,
|
||||
'ɵɵpureFunction2': r3.ɵɵpureFunction2,
|
||||
'ɵɵpureFunction3': r3.ɵɵpureFunction3,
|
||||
'ɵɵpureFunction4': r3.ɵɵpureFunction4,
|
||||
'ɵɵpureFunction5': r3.ɵɵpureFunction5,
|
||||
'ɵɵpureFunction6': r3.ɵɵpureFunction6,
|
||||
'ɵɵpureFunction7': r3.ɵɵpureFunction7,
|
||||
'ɵɵpureFunction8': r3.ɵɵpureFunction8,
|
||||
'ɵɵpureFunctionV': r3.ɵɵpureFunctionV,
|
||||
'ɵɵgetCurrentView': r3.ɵɵgetCurrentView,
|
||||
'ɵɵrestoreView': r3.ɵɵrestoreView,
|
||||
'ɵɵinterpolation1': r3.ɵɵinterpolation1,
|
||||
'ɵɵinterpolation2': r3.ɵɵinterpolation2,
|
||||
'ɵɵinterpolation3': r3.ɵɵinterpolation3,
|
||||
'ɵɵinterpolation4': r3.ɵɵinterpolation4,
|
||||
'ɵɵinterpolation5': r3.ɵɵinterpolation5,
|
||||
'ɵɵinterpolation6': r3.ɵɵinterpolation6,
|
||||
'ɵɵinterpolation7': r3.ɵɵinterpolation7,
|
||||
'ɵɵinterpolation8': r3.ɵɵinterpolation8,
|
||||
'ɵɵinterpolationV': r3.ɵɵinterpolationV,
|
||||
'ɵɵlistener': r3.ɵɵlistener,
|
||||
'ɵɵload': r3.ɵɵload,
|
||||
'ɵɵprojection': r3.ɵɵprojection,
|
||||
'ɵɵelementProperty': r3.ɵɵelementProperty,
|
||||
'ɵɵcomponentHostSyntheticProperty': r3.ɵɵcomponentHostSyntheticProperty,
|
||||
'ɵɵcomponentHostSyntheticListener': r3.ɵɵcomponentHostSyntheticListener,
|
||||
'ɵɵpipeBind1': r3.ɵɵpipeBind1,
|
||||
'ɵɵpipeBind2': r3.ɵɵpipeBind2,
|
||||
'ɵɵpipeBind3': r3.ɵɵpipeBind3,
|
||||
'ɵɵpipeBind4': r3.ɵɵpipeBind4,
|
||||
'ɵɵpipeBindV': r3.ɵɵpipeBindV,
|
||||
'ɵɵprojectionDef': r3.ɵɵprojectionDef,
|
||||
'ɵɵproperty': r3.ɵɵproperty,
|
||||
'ɵɵpropertyInterpolate': r3.ɵɵpropertyInterpolate,
|
||||
'ɵɵpropertyInterpolate1': r3.ɵɵpropertyInterpolate1,
|
||||
'ɵɵpropertyInterpolate2': r3.ɵɵpropertyInterpolate2,
|
||||
'ɵɵpropertyInterpolate3': r3.ɵɵpropertyInterpolate3,
|
||||
'ɵɵpropertyInterpolate4': r3.ɵɵpropertyInterpolate4,
|
||||
'ɵɵpropertyInterpolate5': r3.ɵɵpropertyInterpolate5,
|
||||
'ɵɵpropertyInterpolate6': r3.ɵɵpropertyInterpolate6,
|
||||
'ɵɵpropertyInterpolate7': r3.ɵɵpropertyInterpolate7,
|
||||
'ɵɵpropertyInterpolate8': r3.ɵɵpropertyInterpolate8,
|
||||
'ɵɵpropertyInterpolateV': r3.ɵɵpropertyInterpolateV,
|
||||
'ɵɵpipe': r3.ɵɵpipe,
|
||||
'ɵɵqueryRefresh': r3.ɵɵqueryRefresh,
|
||||
'ɵɵviewQuery': r3.ɵɵviewQuery,
|
||||
'ɵɵstaticViewQuery': r3.ɵɵstaticViewQuery,
|
||||
'ɵɵstaticContentQuery': r3.ɵɵstaticContentQuery,
|
||||
'ɵɵloadViewQuery': r3.ɵɵloadViewQuery,
|
||||
'ɵɵcontentQuery': r3.ɵɵcontentQuery,
|
||||
'ɵɵloadContentQuery': r3.ɵɵloadContentQuery,
|
||||
'ɵɵreference': r3.ɵɵreference,
|
||||
'ɵɵelementHostAttrs': r3.ɵɵelementHostAttrs,
|
||||
'ɵɵclassMap': r3.ɵɵclassMap,
|
||||
'ɵɵstyling': r3.ɵɵstyling,
|
||||
'ɵɵstyleMap': r3.ɵɵstyleMap,
|
||||
'ɵɵstyleProp': r3.ɵɵstyleProp,
|
||||
'ɵɵstylingApply': r3.ɵɵstylingApply,
|
||||
'ɵɵclassProp': r3.ɵɵclassProp,
|
||||
'ɵɵselect': r3.ɵɵselect,
|
||||
'ɵɵtemplate': r3.ɵɵtemplate,
|
||||
'ɵɵtext': r3.ɵɵtext,
|
||||
'ɵɵtextBinding': r3.ɵɵtextBinding,
|
||||
'ɵɵembeddedViewStart': r3.ɵɵembeddedViewStart,
|
||||
'ɵɵembeddedViewEnd': r3.ɵɵembeddedViewEnd,
|
||||
'ɵɵi18n': r3.ɵɵi18n,
|
||||
'ɵɵi18nAttributes': r3.ɵɵi18nAttributes,
|
||||
'ɵɵi18nExp': r3.ɵɵi18nExp,
|
||||
'ɵɵi18nStart': r3.ɵɵi18nStart,
|
||||
'ɵɵi18nEnd': r3.ɵɵi18nEnd,
|
||||
'ɵɵi18nApply': r3.ɵɵi18nApply,
|
||||
'ɵɵi18nPostprocess': r3.ɵɵi18nPostprocess,
|
||||
'ɵɵi18nLocalize': r3.ɵɵi18nLocalize,
|
||||
'ɵɵresolveWindow': r3.ɵɵresolveWindow,
|
||||
'ɵɵresolveDocument': r3.ɵɵresolveDocument,
|
||||
'ɵɵresolveBody': r3.ɵɵresolveBody,
|
||||
'ɵɵsetComponentScope': r3.ɵɵsetComponentScope,
|
||||
'ɵɵsetNgModuleScope': r3.ɵɵsetNgModuleScope,
|
||||
'ΔdefineBase': r3.ΔdefineBase,
|
||||
'ΔdefineComponent': r3.ΔdefineComponent,
|
||||
'ΔdefineDirective': r3.ΔdefineDirective,
|
||||
'ΔdefineInjectable': ΔdefineInjectable,
|
||||
'ΔdefineInjector': ΔdefineInjector,
|
||||
'ΔdefineNgModule': r3.ΔdefineNgModule,
|
||||
'ΔdefinePipe': r3.ΔdefinePipe,
|
||||
'ΔdirectiveInject': r3.ΔdirectiveInject,
|
||||
'ΔgetFactoryOf': r3.ΔgetFactoryOf,
|
||||
'ΔgetInheritedFactory': r3.ΔgetInheritedFactory,
|
||||
'Δinject': Δinject,
|
||||
'ΔinjectAttribute': r3.ΔinjectAttribute,
|
||||
'ΔtemplateRefExtractor': r3.ΔtemplateRefExtractor,
|
||||
'ΔNgOnChangesFeature': r3.ΔNgOnChangesFeature,
|
||||
'ΔProvidersFeature': r3.ΔProvidersFeature,
|
||||
'ΔInheritDefinitionFeature': r3.ΔInheritDefinitionFeature,
|
||||
'ΔelementAttribute': r3.ΔelementAttribute,
|
||||
'Δbind': r3.Δbind,
|
||||
'Δcontainer': r3.Δcontainer,
|
||||
'ΔnextContext': r3.ΔnextContext,
|
||||
'ΔcontainerRefreshStart': r3.ΔcontainerRefreshStart,
|
||||
'ΔcontainerRefreshEnd': r3.ΔcontainerRefreshEnd,
|
||||
'ΔnamespaceHTML': r3.ΔnamespaceHTML,
|
||||
'ΔnamespaceMathML': r3.ΔnamespaceMathML,
|
||||
'ΔnamespaceSVG': r3.ΔnamespaceSVG,
|
||||
'ΔenableBindings': r3.ΔenableBindings,
|
||||
'ΔdisableBindings': r3.ΔdisableBindings,
|
||||
'ΔallocHostVars': r3.ΔallocHostVars,
|
||||
'ΔelementStart': r3.ΔelementStart,
|
||||
'ΔelementEnd': r3.ΔelementEnd,
|
||||
'Δelement': r3.Δelement,
|
||||
'ΔelementContainerStart': r3.ΔelementContainerStart,
|
||||
'ΔelementContainerEnd': r3.ΔelementContainerEnd,
|
||||
'ΔpureFunction0': r3.ΔpureFunction0,
|
||||
'ΔpureFunction1': r3.ΔpureFunction1,
|
||||
'ΔpureFunction2': r3.ΔpureFunction2,
|
||||
'ΔpureFunction3': r3.ΔpureFunction3,
|
||||
'ΔpureFunction4': r3.ΔpureFunction4,
|
||||
'ΔpureFunction5': r3.ΔpureFunction5,
|
||||
'ΔpureFunction6': r3.ΔpureFunction6,
|
||||
'ΔpureFunction7': r3.ΔpureFunction7,
|
||||
'ΔpureFunction8': r3.ΔpureFunction8,
|
||||
'ΔpureFunctionV': r3.ΔpureFunctionV,
|
||||
'ΔgetCurrentView': r3.ΔgetCurrentView,
|
||||
'ΔrestoreView': r3.ΔrestoreView,
|
||||
'Δinterpolation1': r3.Δinterpolation1,
|
||||
'Δinterpolation2': r3.Δinterpolation2,
|
||||
'Δinterpolation3': r3.Δinterpolation3,
|
||||
'Δinterpolation4': r3.Δinterpolation4,
|
||||
'Δinterpolation5': r3.Δinterpolation5,
|
||||
'Δinterpolation6': r3.Δinterpolation6,
|
||||
'Δinterpolation7': r3.Δinterpolation7,
|
||||
'Δinterpolation8': r3.Δinterpolation8,
|
||||
'ΔinterpolationV': r3.ΔinterpolationV,
|
||||
'Δlistener': r3.Δlistener,
|
||||
'Δload': r3.Δload,
|
||||
'Δprojection': r3.Δprojection,
|
||||
'ΔelementProperty': r3.ΔelementProperty,
|
||||
'ΔcomponentHostSyntheticProperty': r3.ΔcomponentHostSyntheticProperty,
|
||||
'ΔcomponentHostSyntheticListener': r3.ΔcomponentHostSyntheticListener,
|
||||
'ΔpipeBind1': r3.ΔpipeBind1,
|
||||
'ΔpipeBind2': r3.ΔpipeBind2,
|
||||
'ΔpipeBind3': r3.ΔpipeBind3,
|
||||
'ΔpipeBind4': r3.ΔpipeBind4,
|
||||
'ΔpipeBindV': r3.ΔpipeBindV,
|
||||
'ΔprojectionDef': r3.ΔprojectionDef,
|
||||
'Δproperty': r3.Δproperty,
|
||||
'ΔpropertyInterpolate': r3.ΔpropertyInterpolate,
|
||||
'ΔpropertyInterpolate1': r3.ΔpropertyInterpolate1,
|
||||
'ΔpropertyInterpolate2': r3.ΔpropertyInterpolate2,
|
||||
'ΔpropertyInterpolate3': r3.ΔpropertyInterpolate3,
|
||||
'ΔpropertyInterpolate4': r3.ΔpropertyInterpolate4,
|
||||
'ΔpropertyInterpolate5': r3.ΔpropertyInterpolate5,
|
||||
'ΔpropertyInterpolate6': r3.ΔpropertyInterpolate6,
|
||||
'ΔpropertyInterpolate7': r3.ΔpropertyInterpolate7,
|
||||
'ΔpropertyInterpolate8': r3.ΔpropertyInterpolate8,
|
||||
'ΔpropertyInterpolateV': r3.ΔpropertyInterpolateV,
|
||||
'Δpipe': r3.Δpipe,
|
||||
'ΔqueryRefresh': r3.ΔqueryRefresh,
|
||||
'ΔviewQuery': r3.ΔviewQuery,
|
||||
'ΔstaticViewQuery': r3.ΔstaticViewQuery,
|
||||
'ΔstaticContentQuery': r3.ΔstaticContentQuery,
|
||||
'ΔloadViewQuery': r3.ΔloadViewQuery,
|
||||
'ΔcontentQuery': r3.ΔcontentQuery,
|
||||
'ΔloadContentQuery': r3.ΔloadContentQuery,
|
||||
'Δreference': r3.Δreference,
|
||||
'ΔelementHostAttrs': r3.ΔelementHostAttrs,
|
||||
'ΔclassMap': r3.ΔclassMap,
|
||||
'Δstyling': r3.Δstyling,
|
||||
'ΔstyleMap': r3.ΔstyleMap,
|
||||
'ΔstyleProp': r3.ΔstyleProp,
|
||||
'ΔstylingApply': r3.ΔstylingApply,
|
||||
'ΔclassProp': r3.ΔclassProp,
|
||||
'Δselect': r3.Δselect,
|
||||
'Δtemplate': r3.Δtemplate,
|
||||
'Δtext': r3.Δtext,
|
||||
'ΔtextBinding': r3.ΔtextBinding,
|
||||
'ΔembeddedViewStart': r3.ΔembeddedViewStart,
|
||||
'ΔembeddedViewEnd': r3.ΔembeddedViewEnd,
|
||||
'Δi18n': r3.Δi18n,
|
||||
'Δi18nAttributes': r3.Δi18nAttributes,
|
||||
'Δi18nExp': r3.Δi18nExp,
|
||||
'Δi18nStart': r3.Δi18nStart,
|
||||
'Δi18nEnd': r3.Δi18nEnd,
|
||||
'Δi18nApply': r3.Δi18nApply,
|
||||
'Δi18nPostprocess': r3.Δi18nPostprocess,
|
||||
'Δi18nLocalize': r3.Δi18nLocalize,
|
||||
'ΔresolveWindow': r3.ΔresolveWindow,
|
||||
'ΔresolveDocument': r3.ΔresolveDocument,
|
||||
'ΔresolveBody': r3.ΔresolveBody,
|
||||
'ΔsetComponentScope': r3.ΔsetComponentScope,
|
||||
'ΔsetNgModuleScope': r3.ΔsetNgModuleScope,
|
||||
|
||||
'ɵɵsanitizeHtml': sanitization.ɵɵsanitizeHtml,
|
||||
'ɵɵsanitizeStyle': sanitization.ɵɵsanitizeStyle,
|
||||
'ɵɵdefaultStyleSanitizer': sanitization.ɵɵdefaultStyleSanitizer,
|
||||
'ɵɵsanitizeResourceUrl': sanitization.ɵɵsanitizeResourceUrl,
|
||||
'ɵɵsanitizeScript': sanitization.ɵɵsanitizeScript,
|
||||
'ɵɵsanitizeUrl': sanitization.ɵɵsanitizeUrl,
|
||||
'ɵɵsanitizeUrlOrResourceUrl': sanitization.ɵɵsanitizeUrlOrResourceUrl,
|
||||
'ΔsanitizeHtml': sanitization.ΔsanitizeHtml,
|
||||
'ΔsanitizeStyle': sanitization.ΔsanitizeStyle,
|
||||
'ΔdefaultStyleSanitizer': sanitization.ΔdefaultStyleSanitizer,
|
||||
'ΔsanitizeResourceUrl': sanitization.ΔsanitizeResourceUrl,
|
||||
'ΔsanitizeScript': sanitization.ΔsanitizeScript,
|
||||
'ΔsanitizeUrl': sanitization.ΔsanitizeUrl,
|
||||
'ΔsanitizeUrlOrResourceUrl': sanitization.ΔsanitizeUrlOrResourceUrl,
|
||||
};
|
||||
|
|
|
@ -9,10 +9,10 @@
|
|||
import {WrappedValue} from '../change_detection/change_detection_util';
|
||||
import {PipeTransform} from '../change_detection/pipe_transform';
|
||||
|
||||
import {store, ɵɵload} from './instructions/all';
|
||||
import {store, Δload} from './instructions/all';
|
||||
import {PipeDef, PipeDefList} from './interfaces/definition';
|
||||
import {BINDING_INDEX, HEADER_OFFSET, TVIEW} from './interfaces/view';
|
||||
import {ɵɵpureFunction1, ɵɵpureFunction2, ɵɵpureFunction3, ɵɵpureFunction4, ɵɵpureFunctionV} from './pure_function';
|
||||
import {ΔpureFunction1, ΔpureFunction2, ΔpureFunction3, ΔpureFunction4, ΔpureFunctionV} from './pure_function';
|
||||
import {getLView} from './state';
|
||||
import {NO_CHANGE} from './tokens';
|
||||
|
||||
|
@ -27,7 +27,7 @@ import {NO_CHANGE} from './tokens';
|
|||
*
|
||||
* @codeGenApi
|
||||
*/
|
||||
export function ɵɵpipe(index: number, pipeName: string): any {
|
||||
export function Δpipe(index: number, pipeName: string): any {
|
||||
const tView = getLView()[TVIEW];
|
||||
let pipeDef: PipeDef<any>;
|
||||
const adjustedIndex = index + HEADER_OFFSET;
|
||||
|
@ -81,10 +81,10 @@ function getPipeDef(name: string, registry: PipeDefList | null): PipeDef<any> {
|
|||
*
|
||||
* @codeGenApi
|
||||
*/
|
||||
export function ɵɵpipeBind1(index: number, slotOffset: number, v1: any): any {
|
||||
const pipeInstance = ɵɵload<PipeTransform>(index);
|
||||
export function ΔpipeBind1(index: number, slotOffset: number, v1: any): any {
|
||||
const pipeInstance = Δload<PipeTransform>(index);
|
||||
return unwrapValue(
|
||||
isPure(index) ? ɵɵpureFunction1(slotOffset, pipeInstance.transform, v1, pipeInstance) :
|
||||
isPure(index) ? ΔpureFunction1(slotOffset, pipeInstance.transform, v1, pipeInstance) :
|
||||
pipeInstance.transform(v1));
|
||||
}
|
||||
|
||||
|
@ -101,10 +101,10 @@ export function ɵɵpipeBind1(index: number, slotOffset: number, v1: any): any {
|
|||
*
|
||||
* @codeGenApi
|
||||
*/
|
||||
export function ɵɵpipeBind2(index: number, slotOffset: number, v1: any, v2: any): any {
|
||||
const pipeInstance = ɵɵload<PipeTransform>(index);
|
||||
export function ΔpipeBind2(index: number, slotOffset: number, v1: any, v2: any): any {
|
||||
const pipeInstance = Δload<PipeTransform>(index);
|
||||
return unwrapValue(
|
||||
isPure(index) ? ɵɵpureFunction2(slotOffset, pipeInstance.transform, v1, v2, pipeInstance) :
|
||||
isPure(index) ? ΔpureFunction2(slotOffset, pipeInstance.transform, v1, v2, pipeInstance) :
|
||||
pipeInstance.transform(v1, v2));
|
||||
}
|
||||
|
||||
|
@ -122,12 +122,11 @@ export function ɵɵpipeBind2(index: number, slotOffset: number, v1: any, v2: an
|
|||
*
|
||||
* @codeGenApi
|
||||
*/
|
||||
export function ɵɵpipeBind3(index: number, slotOffset: number, v1: any, v2: any, v3: any): any {
|
||||
const pipeInstance = ɵɵload<PipeTransform>(index);
|
||||
export function ΔpipeBind3(index: number, slotOffset: number, v1: any, v2: any, v3: any): any {
|
||||
const pipeInstance = Δload<PipeTransform>(index);
|
||||
return unwrapValue(
|
||||
isPure(index) ?
|
||||
ɵɵpureFunction3(slotOffset, pipeInstance.transform, v1, v2, v3, pipeInstance) :
|
||||
pipeInstance.transform(v1, v2, v3));
|
||||
isPure(index) ? ΔpureFunction3(slotOffset, pipeInstance.transform, v1, v2, v3, pipeInstance) :
|
||||
pipeInstance.transform(v1, v2, v3));
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -145,12 +144,12 @@ export function ɵɵpipeBind3(index: number, slotOffset: number, v1: any, v2: an
|
|||
*
|
||||
* @codeGenApi
|
||||
*/
|
||||
export function ɵɵpipeBind4(
|
||||
export function ΔpipeBind4(
|
||||
index: number, slotOffset: number, v1: any, v2: any, v3: any, v4: any): any {
|
||||
const pipeInstance = ɵɵload<PipeTransform>(index);
|
||||
const pipeInstance = Δload<PipeTransform>(index);
|
||||
return unwrapValue(
|
||||
isPure(index) ?
|
||||
ɵɵpureFunction4(slotOffset, pipeInstance.transform, v1, v2, v3, v4, pipeInstance) :
|
||||
ΔpureFunction4(slotOffset, pipeInstance.transform, v1, v2, v3, v4, pipeInstance) :
|
||||
pipeInstance.transform(v1, v2, v3, v4));
|
||||
}
|
||||
|
||||
|
@ -166,10 +165,10 @@ export function ɵɵpipeBind4(
|
|||
*
|
||||
* @codeGenApi
|
||||
*/
|
||||
export function ɵɵpipeBindV(index: number, slotOffset: number, values: any[]): any {
|
||||
const pipeInstance = ɵɵload<PipeTransform>(index);
|
||||
export function ΔpipeBindV(index: number, slotOffset: number, values: any[]): any {
|
||||
const pipeInstance = Δload<PipeTransform>(index);
|
||||
return unwrapValue(
|
||||
isPure(index) ? ɵɵpureFunctionV(slotOffset, pipeInstance.transform, values, pipeInstance) :
|
||||
isPure(index) ? ΔpureFunctionV(slotOffset, pipeInstance.transform, values, pipeInstance) :
|
||||
pipeInstance.transform.apply(pipeInstance, values));
|
||||
}
|
||||
|
||||
|
|
|
@ -40,7 +40,7 @@ import {getBindingRoot, getLView, isCreationMode} from './state';
|
|||
*
|
||||
* @codeGenApi
|
||||
*/
|
||||
export function ɵɵpureFunction0<T>(slotOffset: number, pureFn: () => T, thisArg?: any): T {
|
||||
export function ΔpureFunction0<T>(slotOffset: number, pureFn: () => T, thisArg?: any): T {
|
||||
// TODO(kara): use bindingRoot instead of bindingStartIndex when implementing host bindings
|
||||
const bindingIndex = getBindingRoot() + slotOffset;
|
||||
const lView = getLView();
|
||||
|
@ -61,7 +61,7 @@ export function ɵɵpureFunction0<T>(slotOffset: number, pureFn: () => T, thisAr
|
|||
*
|
||||
* @codeGenApi
|
||||
*/
|
||||
export function ɵɵpureFunction1(
|
||||
export function ΔpureFunction1(
|
||||
slotOffset: number, pureFn: (v: any) => any, exp: any, thisArg?: any): any {
|
||||
// TODO(kara): use bindingRoot instead of bindingStartIndex when implementing host bindings
|
||||
const lView = getLView();
|
||||
|
@ -84,7 +84,7 @@ export function ɵɵpureFunction1(
|
|||
*
|
||||
* @codeGenApi
|
||||
*/
|
||||
export function ɵɵpureFunction2(
|
||||
export function ΔpureFunction2(
|
||||
slotOffset: number, pureFn: (v1: any, v2: any) => any, exp1: any, exp2: any,
|
||||
thisArg?: any): any {
|
||||
// TODO(kara): use bindingRoot instead of bindingStartIndex when implementing host bindings
|
||||
|
@ -111,7 +111,7 @@ export function ɵɵpureFunction2(
|
|||
*
|
||||
* @codeGenApi
|
||||
*/
|
||||
export function ɵɵpureFunction3(
|
||||
export function ΔpureFunction3(
|
||||
slotOffset: number, pureFn: (v1: any, v2: any, v3: any) => any, exp1: any, exp2: any, exp3: any,
|
||||
thisArg?: any): any {
|
||||
// TODO(kara): use bindingRoot instead of bindingStartIndex when implementing host bindings
|
||||
|
@ -139,7 +139,7 @@ export function ɵɵpureFunction3(
|
|||
*
|
||||
* @codeGenApi
|
||||
*/
|
||||
export function ɵɵpureFunction4(
|
||||
export function ΔpureFunction4(
|
||||
slotOffset: number, pureFn: (v1: any, v2: any, v3: any, v4: any) => any, exp1: any, exp2: any,
|
||||
exp3: any, exp4: any, thisArg?: any): any {
|
||||
// TODO(kara): use bindingRoot instead of bindingStartIndex when implementing host bindings
|
||||
|
@ -168,7 +168,7 @@ export function ɵɵpureFunction4(
|
|||
*
|
||||
* @codeGenApi
|
||||
*/
|
||||
export function ɵɵpureFunction5(
|
||||
export function ΔpureFunction5(
|
||||
slotOffset: number, pureFn: (v1: any, v2: any, v3: any, v4: any, v5: any) => any, exp1: any,
|
||||
exp2: any, exp3: any, exp4: any, exp5: any, thisArg?: any): any {
|
||||
// TODO(kara): use bindingRoot instead of bindingStartIndex when implementing host bindings
|
||||
|
@ -199,7 +199,7 @@ export function ɵɵpureFunction5(
|
|||
*
|
||||
* @codeGenApi
|
||||
*/
|
||||
export function ɵɵpureFunction6(
|
||||
export function ΔpureFunction6(
|
||||
slotOffset: number, pureFn: (v1: any, v2: any, v3: any, v4: any, v5: any, v6: any) => any,
|
||||
exp1: any, exp2: any, exp3: any, exp4: any, exp5: any, exp6: any, thisArg?: any): any {
|
||||
// TODO(kara): use bindingRoot instead of bindingStartIndex when implementing host bindings
|
||||
|
@ -232,7 +232,7 @@ export function ɵɵpureFunction6(
|
|||
*
|
||||
* @codeGenApi
|
||||
*/
|
||||
export function ɵɵpureFunction7(
|
||||
export function ΔpureFunction7(
|
||||
slotOffset: number,
|
||||
pureFn: (v1: any, v2: any, v3: any, v4: any, v5: any, v6: any, v7: any) => any, exp1: any,
|
||||
exp2: any, exp3: any, exp4: any, exp5: any, exp6: any, exp7: any, thisArg?: any): any {
|
||||
|
@ -267,7 +267,7 @@ export function ɵɵpureFunction7(
|
|||
*
|
||||
* @codeGenApi
|
||||
*/
|
||||
export function ɵɵpureFunction8(
|
||||
export function ΔpureFunction8(
|
||||
slotOffset: number,
|
||||
pureFn: (v1: any, v2: any, v3: any, v4: any, v5: any, v6: any, v7: any, v8: any) => any,
|
||||
exp1: any, exp2: any, exp3: any, exp4: any, exp5: any, exp6: any, exp7: any, exp8: any,
|
||||
|
@ -299,7 +299,7 @@ export function ɵɵpureFunction8(
|
|||
*
|
||||
* @codeGenApi
|
||||
*/
|
||||
export function ɵɵpureFunctionV(
|
||||
export function ΔpureFunctionV(
|
||||
slotOffset: number, pureFn: (...v: any[]) => any, exps: any[], thisArg?: any): any {
|
||||
// TODO(kara): use bindingRoot instead of bindingStartIndex when implementing host bindings
|
||||
let bindingIndex = getBindingRoot() + slotOffset;
|
||||
|
|
|
@ -18,7 +18,7 @@ import {assertDataInRange, assertDefined, assertEqual} from '../util/assert';
|
|||
import {assertPreviousIsParent} from './assert';
|
||||
import {getNodeInjectable, locateDirectiveOrProvider} from './di';
|
||||
import {NG_ELEMENT_ID} from './fields';
|
||||
import {store, ɵɵload} from './instructions/all';
|
||||
import {store, Δload} from './instructions/all';
|
||||
import {storeCleanupWithContext} from './instructions/shared';
|
||||
import {unusedValueExportToPlacateAjd as unused1} from './interfaces/definition';
|
||||
import {unusedValueExportToPlacateAjd as unused2} from './interfaces/injector';
|
||||
|
@ -391,7 +391,7 @@ export function query<T>(
|
|||
*
|
||||
* @codeGenApi
|
||||
*/
|
||||
export function ɵɵqueryRefresh(queryList: QueryList<any>): boolean {
|
||||
export function ΔqueryRefresh(queryList: QueryList<any>): boolean {
|
||||
const queryListImpl = (queryList as any as QueryList_<any>);
|
||||
const creationMode = isCreationMode();
|
||||
|
||||
|
@ -413,10 +413,10 @@ export function ɵɵqueryRefresh(queryList: QueryList<any>): boolean {
|
|||
*
|
||||
* @codeGenApi
|
||||
*/
|
||||
export function ɵɵstaticViewQuery<T>(
|
||||
export function ΔstaticViewQuery<T>(
|
||||
// TODO(FW-486): "read" should be an AbstractType
|
||||
predicate: Type<any>| string[], descend: boolean, read: any): void {
|
||||
const queryList = ɵɵviewQuery(predicate, descend, read) as QueryList_<T>;
|
||||
const queryList = ΔviewQuery(predicate, descend, read) as QueryList_<T>;
|
||||
const tView = getLView()[TVIEW];
|
||||
queryList._static = true;
|
||||
if (!tView.staticViewQueries) {
|
||||
|
@ -434,7 +434,7 @@ export function ɵɵstaticViewQuery<T>(
|
|||
*
|
||||
* @codeGenApi
|
||||
*/
|
||||
export function ɵɵviewQuery<T>(
|
||||
export function ΔviewQuery<T>(
|
||||
// TODO(FW-486): "read" should be an AbstractType
|
||||
predicate: Type<any>| string[], descend: boolean, read: any): QueryList<T> {
|
||||
const lView = getLView();
|
||||
|
@ -454,10 +454,10 @@ export function ɵɵviewQuery<T>(
|
|||
*
|
||||
* @codeGenApi
|
||||
*/
|
||||
export function ɵɵloadViewQuery<T>(): T {
|
||||
export function ΔloadViewQuery<T>(): T {
|
||||
const index = getCurrentQueryIndex();
|
||||
setCurrentQueryIndex(index + 1);
|
||||
return ɵɵload<T>(index - HEADER_OFFSET);
|
||||
return Δload<T>(index - HEADER_OFFSET);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -472,7 +472,7 @@ export function ɵɵloadViewQuery<T>(): T {
|
|||
*
|
||||
* @codeGenApi
|
||||
*/
|
||||
export function ɵɵcontentQuery<T>(
|
||||
export function ΔcontentQuery<T>(
|
||||
directiveIndex: number, predicate: Type<any>| string[], descend: boolean,
|
||||
// TODO(FW-486): "read" should be an AbstractType
|
||||
read: any): QueryList<T> {
|
||||
|
@ -503,11 +503,11 @@ export function ɵɵcontentQuery<T>(
|
|||
*
|
||||
* @codeGenApi
|
||||
*/
|
||||
export function ɵɵstaticContentQuery<T>(
|
||||
export function ΔstaticContentQuery<T>(
|
||||
directiveIndex: number, predicate: Type<any>| string[], descend: boolean,
|
||||
// TODO(FW-486): "read" should be an AbstractType
|
||||
read: any): void {
|
||||
const queryList = ɵɵcontentQuery(directiveIndex, predicate, descend, read) as QueryList_<T>;
|
||||
const queryList = ΔcontentQuery(directiveIndex, predicate, descend, read) as QueryList_<T>;
|
||||
const tView = getLView()[TVIEW];
|
||||
queryList._static = true;
|
||||
if (!tView.staticContentQueries) {
|
||||
|
@ -519,7 +519,7 @@ export function ɵɵstaticContentQuery<T>(
|
|||
*
|
||||
* @codeGenApi
|
||||
*/
|
||||
export function ɵɵloadContentQuery<T>(): QueryList<T> {
|
||||
export function ΔloadContentQuery<T>(): QueryList<T> {
|
||||
const lView = getLView();
|
||||
ngDevMode &&
|
||||
assertDefined(
|
||||
|
|
|
@ -83,17 +83,17 @@ export function getBindingsEnabled(): boolean {
|
|||
* Should match component / directive.
|
||||
* </my-comp>
|
||||
* <div ngNonBindable>
|
||||
* <!-- ɵɵdisableBindings() -->
|
||||
* <!-- ΔdisableBindings() -->
|
||||
* <my-comp my-directive>
|
||||
* Should not match component / directive because we are in ngNonBindable.
|
||||
* </my-comp>
|
||||
* <!-- ɵɵenableBindings() -->
|
||||
* <!-- ΔenableBindings() -->
|
||||
* </div>
|
||||
* ```
|
||||
*
|
||||
* @codeGenApi
|
||||
*/
|
||||
export function ɵɵenableBindings(): void {
|
||||
export function ΔenableBindings(): void {
|
||||
bindingsEnabled = true;
|
||||
}
|
||||
|
||||
|
@ -106,17 +106,17 @@ export function ɵɵenableBindings(): void {
|
|||
* Should match component / directive.
|
||||
* </my-comp>
|
||||
* <div ngNonBindable>
|
||||
* <!-- ɵɵdisableBindings() -->
|
||||
* <!-- ΔdisableBindings() -->
|
||||
* <my-comp my-directive>
|
||||
* Should not match component / directive because we are in ngNonBindable.
|
||||
* </my-comp>
|
||||
* <!-- ɵɵenableBindings() -->
|
||||
* <!-- ΔenableBindings() -->
|
||||
* </div>
|
||||
* ```
|
||||
*
|
||||
* @codeGenApi
|
||||
*/
|
||||
export function ɵɵdisableBindings(): void {
|
||||
export function ΔdisableBindings(): void {
|
||||
bindingsEnabled = false;
|
||||
}
|
||||
|
||||
|
@ -270,7 +270,7 @@ export function getActiveDirectiveSuperClassDepth() {
|
|||
*
|
||||
* @codeGenApi
|
||||
*/
|
||||
export function ɵɵrestoreView(viewToRestore: OpaqueViewState) {
|
||||
export function ΔrestoreView(viewToRestore: OpaqueViewState) {
|
||||
contextLView = viewToRestore as any as LView;
|
||||
}
|
||||
|
||||
|
@ -495,7 +495,7 @@ let _currentNamespace: string|null = null;
|
|||
*
|
||||
* @codeGenApi
|
||||
*/
|
||||
export function ɵɵnamespaceSVG() {
|
||||
export function ΔnamespaceSVG() {
|
||||
_currentNamespace = 'http://www.w3.org/2000/svg';
|
||||
}
|
||||
|
||||
|
@ -504,7 +504,7 @@ export function ɵɵnamespaceSVG() {
|
|||
*
|
||||
* @codeGenApi
|
||||
*/
|
||||
export function ɵɵnamespaceMathML() {
|
||||
export function ΔnamespaceMathML() {
|
||||
_currentNamespace = 'http://www.w3.org/1998/MathML/';
|
||||
}
|
||||
|
||||
|
@ -514,7 +514,7 @@ export function ɵɵnamespaceMathML() {
|
|||
*
|
||||
* @codeGenApi
|
||||
*/
|
||||
export function ɵɵnamespaceHTML() {
|
||||
export function ΔnamespaceHTML() {
|
||||
_currentNamespace = null;
|
||||
}
|
||||
|
||||
|
|
|
@ -56,7 +56,7 @@ export const defaultScheduler =
|
|||
*
|
||||
* @codeGenApi
|
||||
*/
|
||||
export function ɵɵresolveWindow(element: RElement & {ownerDocument: Document}) {
|
||||
export function ΔresolveWindow(element: RElement & {ownerDocument: Document}) {
|
||||
return {name: 'window', target: element.ownerDocument.defaultView};
|
||||
}
|
||||
|
||||
|
@ -64,7 +64,7 @@ export function ɵɵresolveWindow(element: RElement & {ownerDocument: Document})
|
|||
*
|
||||
* @codeGenApi
|
||||
*/
|
||||
export function ɵɵresolveDocument(element: RElement & {ownerDocument: Document}) {
|
||||
export function ΔresolveDocument(element: RElement & {ownerDocument: Document}) {
|
||||
return {name: 'document', target: element.ownerDocument};
|
||||
}
|
||||
|
||||
|
@ -72,7 +72,7 @@ export function ɵɵresolveDocument(element: RElement & {ownerDocument: Document
|
|||
*
|
||||
* @codeGenApi
|
||||
*/
|
||||
export function ɵɵresolveBody(element: RElement & {ownerDocument: Document}) {
|
||||
export function ΔresolveBody(element: RElement & {ownerDocument: Document}) {
|
||||
return {name: 'body', target: element.ownerDocument.body};
|
||||
}
|
||||
|
||||
|
|
|
@ -22,6 +22,6 @@ import {createTemplateRef} from './view_engine_compatibility';
|
|||
*
|
||||
* @codeGenApi
|
||||
*/
|
||||
export function ɵɵtemplateRefExtractor(tNode: TNode, currentView: LView) {
|
||||
export function ΔtemplateRefExtractor(tNode: TNode, currentView: LView) {
|
||||
return createTemplateRef(ViewEngine_TemplateRef, ViewEngine_ElementRef, tNode, currentView);
|
||||
}
|
||||
|
|
|
@ -33,7 +33,7 @@ import {_sanitizeUrl as _sanitizeUrl} from './url_sanitizer';
|
|||
*
|
||||
* @publicApi
|
||||
*/
|
||||
export function ɵɵsanitizeHtml(unsafeHtml: any): string {
|
||||
export function ΔsanitizeHtml(unsafeHtml: any): string {
|
||||
const sanitizer = getSanitizer();
|
||||
if (sanitizer) {
|
||||
return sanitizer.sanitize(SecurityContext.HTML, unsafeHtml) || '';
|
||||
|
@ -59,7 +59,7 @@ export function ɵɵsanitizeHtml(unsafeHtml: any): string {
|
|||
*
|
||||
* @publicApi
|
||||
*/
|
||||
export function ɵɵsanitizeStyle(unsafeStyle: any): string {
|
||||
export function ΔsanitizeStyle(unsafeStyle: any): string {
|
||||
const sanitizer = getSanitizer();
|
||||
if (sanitizer) {
|
||||
return sanitizer.sanitize(SecurityContext.STYLE, unsafeStyle) || '';
|
||||
|
@ -86,7 +86,7 @@ export function ɵɵsanitizeStyle(unsafeStyle: any): string {
|
|||
*
|
||||
* @publicApi
|
||||
*/
|
||||
export function ɵɵsanitizeUrl(unsafeUrl: any): string {
|
||||
export function ΔsanitizeUrl(unsafeUrl: any): string {
|
||||
const sanitizer = getSanitizer();
|
||||
if (sanitizer) {
|
||||
return sanitizer.sanitize(SecurityContext.URL, unsafeUrl) || '';
|
||||
|
@ -108,7 +108,7 @@ export function ɵɵsanitizeUrl(unsafeUrl: any): string {
|
|||
*
|
||||
* @publicApi
|
||||
*/
|
||||
export function ɵɵsanitizeResourceUrl(unsafeResourceUrl: any): string {
|
||||
export function ΔsanitizeResourceUrl(unsafeResourceUrl: any): string {
|
||||
const sanitizer = getSanitizer();
|
||||
if (sanitizer) {
|
||||
return sanitizer.sanitize(SecurityContext.RESOURCE_URL, unsafeResourceUrl) || '';
|
||||
|
@ -131,7 +131,7 @@ export function ɵɵsanitizeResourceUrl(unsafeResourceUrl: any): string {
|
|||
*
|
||||
* @publicApi
|
||||
*/
|
||||
export function ɵɵsanitizeScript(unsafeScript: any): string {
|
||||
export function ΔsanitizeScript(unsafeScript: any): string {
|
||||
const sanitizer = getSanitizer();
|
||||
if (sanitizer) {
|
||||
return sanitizer.sanitize(SecurityContext.SCRIPT, unsafeScript) || '';
|
||||
|
@ -153,9 +153,9 @@ export function getUrlSanitizer(tag: string, prop: string) {
|
|||
if ((prop === 'src' && (tag === 'embed' || tag === 'frame' || tag === 'iframe' ||
|
||||
tag === 'media' || tag === 'script')) ||
|
||||
(prop === 'href' && (tag === 'base' || tag === 'link'))) {
|
||||
return ɵɵsanitizeResourceUrl;
|
||||
return ΔsanitizeResourceUrl;
|
||||
}
|
||||
return ɵɵsanitizeUrl;
|
||||
return ΔsanitizeUrl;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -173,7 +173,7 @@ export function getUrlSanitizer(tag: string, prop: string) {
|
|||
*
|
||||
* @publicApi
|
||||
*/
|
||||
export function ɵɵsanitizeUrlOrResourceUrl(unsafeUrl: any, tag: string, prop: string): any {
|
||||
export function ΔsanitizeUrlOrResourceUrl(unsafeUrl: any, tag: string, prop: string): any {
|
||||
return getUrlSanitizer(tag, prop)(unsafeUrl);
|
||||
}
|
||||
|
||||
|
@ -183,13 +183,13 @@ export function ɵɵsanitizeUrlOrResourceUrl(unsafeUrl: any, tag: string, prop:
|
|||
*
|
||||
* @publicApi
|
||||
*/
|
||||
export const ɵɵdefaultStyleSanitizer = (function(prop: string, value?: string): string | boolean {
|
||||
export const ΔdefaultStyleSanitizer = (function(prop: string, value?: string): string | boolean {
|
||||
if (value === undefined) {
|
||||
return prop === 'background-image' || prop === 'background' || prop === 'border-image' ||
|
||||
prop === 'filter' || prop === 'list-style' || prop === 'list-style-image';
|
||||
}
|
||||
|
||||
return ɵɵsanitizeStyle(value);
|
||||
return ΔsanitizeStyle(value);
|
||||
} as StyleSanitizeFn);
|
||||
|
||||
export function validateAgainstEventProperties(name: string) {
|
||||
|
|
|
@ -9,7 +9,7 @@
|
|||
import {resolveForwardRef} from '../di/forward_ref';
|
||||
import {Injector} from '../di/injector';
|
||||
import {INJECTOR, setCurrentInjector} from '../di/injector_compatibility';
|
||||
import {getInjectableDef, ɵɵInjectableDef} from '../di/interface/defs';
|
||||
import {getInjectableDef, ΔInjectableDef} from '../di/interface/defs';
|
||||
import {APP_ROOT} from '../di/scope';
|
||||
import {NgModuleRef} from '../linker/ng_module_factory';
|
||||
import {stringify} from '../util/stringify';
|
||||
|
@ -98,7 +98,7 @@ export function resolveNgModuleDep(
|
|||
return data;
|
||||
}
|
||||
const providerDef = data._def.providersByKey[tokenKey];
|
||||
let injectableDef: ɵɵInjectableDef<any>|null;
|
||||
let injectableDef: ΔInjectableDef<any>|null;
|
||||
if (providerDef) {
|
||||
let providerInstance = data._providers[providerDef.index];
|
||||
if (providerInstance === undefined) {
|
||||
|
@ -132,7 +132,7 @@ function moduleTransitivelyPresent(ngModule: NgModuleData, scope: any): boolean
|
|||
return ngModule._def.modules.indexOf(scope) > -1;
|
||||
}
|
||||
|
||||
function targetsModule(ngModule: NgModuleData, def: ɵɵInjectableDef<any>): boolean {
|
||||
function targetsModule(ngModule: NgModuleData, def: ΔInjectableDef<any>): boolean {
|
||||
return def.providedIn != null && (moduleTransitivelyPresent(ngModule, def.providedIn) ||
|
||||
def.providedIn === 'root' && ngModule._def.isRoot);
|
||||
}
|
||||
|
|
|
@ -9,7 +9,7 @@
|
|||
import {DebugElement__PRE_R3__, DebugEventListener, DebugNode__PRE_R3__, getDebugNode, indexDebugNode, removeDebugNodeFromIndex} from '../debug/debug_node';
|
||||
import {Injector} from '../di';
|
||||
import {InjectableType} from '../di/injectable';
|
||||
import {getInjectableDef, ɵɵInjectableDef} from '../di/interface/defs';
|
||||
import {getInjectableDef, ΔInjectableDef} from '../di/interface/defs';
|
||||
import {ErrorHandler} from '../error_handler';
|
||||
import {Type} from '../interface/type';
|
||||
import {ComponentFactory} from '../linker/component_factory';
|
||||
|
@ -170,7 +170,7 @@ const viewDefOverrides = new Map<any, ViewDefinition>();
|
|||
|
||||
function debugOverrideProvider(override: ProviderOverride) {
|
||||
providerOverrides.set(override.token, override);
|
||||
let injectableDef: ɵɵInjectableDef<any>|null;
|
||||
let injectableDef: ΔInjectableDef<any>|null;
|
||||
if (typeof override.token === 'function' && (injectableDef = getInjectableDef(override.token)) &&
|
||||
typeof injectableDef.providedIn === 'function') {
|
||||
providerOverridesWithScope.set(override.token as InjectableType<any>, override);
|
||||
|
|
|
@ -690,33 +690,33 @@
|
|||
"name": "viewAttachedToChangeDetector"
|
||||
},
|
||||
{
|
||||
"name": "ɵɵdefineComponent"
|
||||
"name": "ΔdefineComponent"
|
||||
},
|
||||
{
|
||||
"name": "ɵɵdefineInjectable"
|
||||
"name": "ΔdefineInjectable"
|
||||
},
|
||||
{
|
||||
"name": "ɵɵdefineInjector"
|
||||
"name": "ΔdefineInjector"
|
||||
},
|
||||
{
|
||||
"name": "ɵɵdefineNgModule"
|
||||
"name": "ΔdefineNgModule"
|
||||
},
|
||||
{
|
||||
"name": "ɵɵelement"
|
||||
"name": "Δelement"
|
||||
},
|
||||
{
|
||||
"name": "ɵɵelementEnd"
|
||||
"name": "ΔelementEnd"
|
||||
},
|
||||
{
|
||||
"name": "ɵɵelementStart"
|
||||
"name": "ΔelementStart"
|
||||
},
|
||||
{
|
||||
"name": "ɵɵnamespaceHTML"
|
||||
"name": "ΔnamespaceHTML"
|
||||
},
|
||||
{
|
||||
"name": "ɵɵsetComponentScope"
|
||||
"name": "ΔsetComponentScope"
|
||||
},
|
||||
{
|
||||
"name": "ɵɵtext"
|
||||
"name": "Δtext"
|
||||
}
|
||||
]
|
|
@ -501,15 +501,15 @@
|
|||
"name": "viewAttachedToChangeDetector"
|
||||
},
|
||||
{
|
||||
"name": "ɵɵdefineComponent"
|
||||
"name": "ΔdefineComponent"
|
||||
},
|
||||
{
|
||||
"name": "ɵɵdefineInjectable"
|
||||
"name": "ΔdefineInjectable"
|
||||
},
|
||||
{
|
||||
"name": "ɵɵnamespaceHTML"
|
||||
"name": "ΔnamespaceHTML"
|
||||
},
|
||||
{
|
||||
"name": "ɵɵtext"
|
||||
"name": "Δtext"
|
||||
}
|
||||
]
|
|
@ -195,12 +195,12 @@
|
|||
"name": "throwMixedMultiProviderError"
|
||||
},
|
||||
{
|
||||
"name": "ɵɵdefineInjectable"
|
||||
"name": "ΔdefineInjectable"
|
||||
},
|
||||
{
|
||||
"name": "ɵɵdefineInjector"
|
||||
"name": "ΔdefineInjector"
|
||||
},
|
||||
{
|
||||
"name": "ɵɵinject"
|
||||
"name": "Δinject"
|
||||
}
|
||||
]
|
|
@ -6,17 +6,17 @@
|
|||
* found in the LICENSE file at https://angular.io/license
|
||||
*/
|
||||
|
||||
import {Injector, ɵcreateInjector as createInjector, ɵɵdefineInjectable, ɵɵdefineInjector} from '@angular/core';
|
||||
import {Injector, ɵcreateInjector as createInjector, ΔdefineInjectable, ΔdefineInjector} from '@angular/core';
|
||||
|
||||
export class RootService {
|
||||
static ngInjectableDef = ɵɵdefineInjectable({
|
||||
static ngInjectableDef = ΔdefineInjectable({
|
||||
providedIn: 'root',
|
||||
factory: () => new RootService(),
|
||||
});
|
||||
}
|
||||
|
||||
export class ScopedService {
|
||||
static ngInjectableDef = ɵɵdefineInjectable({
|
||||
static ngInjectableDef = ΔdefineInjectable({
|
||||
providedIn: null,
|
||||
factory: () => new ScopedService(),
|
||||
});
|
||||
|
@ -28,7 +28,7 @@ export class ScopedService {
|
|||
}
|
||||
|
||||
export class DefinedInjector {
|
||||
static ngInjectorDef = ɵɵdefineInjector({
|
||||
static ngInjectorDef = ΔdefineInjector({
|
||||
factory: () => new DefinedInjector(),
|
||||
providers: [ScopedService],
|
||||
});
|
||||
|
|
|
@ -1362,72 +1362,72 @@
|
|||
"name": "wrapListener"
|
||||
},
|
||||
{
|
||||
"name": "ɵɵbind"
|
||||
"name": "Δbind"
|
||||
},
|
||||
{
|
||||
"name": "ɵɵclassProp"
|
||||
"name": "ΔclassProp"
|
||||
},
|
||||
{
|
||||
"name": "ɵɵdefineComponent"
|
||||
"name": "ΔdefineComponent"
|
||||
},
|
||||
{
|
||||
"name": "ɵɵdefineDirective"
|
||||
"name": "ΔdefineDirective"
|
||||
},
|
||||
{
|
||||
"name": "ɵɵdefineInjectable"
|
||||
"name": "ΔdefineInjectable"
|
||||
},
|
||||
{
|
||||
"name": "ɵɵdirectiveInject"
|
||||
"name": "ΔdirectiveInject"
|
||||
},
|
||||
{
|
||||
"name": "ɵɵelementEnd"
|
||||
"name": "ΔelementEnd"
|
||||
},
|
||||
{
|
||||
"name": "ɵɵelementStart"
|
||||
"name": "ΔelementStart"
|
||||
},
|
||||
{
|
||||
"name": "ɵɵgetCurrentView"
|
||||
"name": "ΔgetCurrentView"
|
||||
},
|
||||
{
|
||||
"name": "ɵɵinject"
|
||||
"name": "Δinject"
|
||||
},
|
||||
{
|
||||
"name": "ɵɵinterpolation1"
|
||||
"name": "Δinterpolation1"
|
||||
},
|
||||
{
|
||||
"name": "ɵɵlistener"
|
||||
"name": "Δlistener"
|
||||
},
|
||||
{
|
||||
"name": "ɵɵnamespaceHTML"
|
||||
"name": "ΔnamespaceHTML"
|
||||
},
|
||||
{
|
||||
"name": "ɵɵnextContext"
|
||||
"name": "ΔnextContext"
|
||||
},
|
||||
{
|
||||
"name": "ɵɵproperty"
|
||||
"name": "Δproperty"
|
||||
},
|
||||
{
|
||||
"name": "ɵɵreference"
|
||||
"name": "Δreference"
|
||||
},
|
||||
{
|
||||
"name": "ɵɵrestoreView"
|
||||
"name": "ΔrestoreView"
|
||||
},
|
||||
{
|
||||
"name": "ɵɵselect"
|
||||
"name": "Δselect"
|
||||
},
|
||||
{
|
||||
"name": "ɵɵstyling"
|
||||
"name": "Δstyling"
|
||||
},
|
||||
{
|
||||
"name": "ɵɵstylingApply"
|
||||
"name": "ΔstylingApply"
|
||||
},
|
||||
{
|
||||
"name": "ɵɵtemplate"
|
||||
"name": "Δtemplate"
|
||||
},
|
||||
{
|
||||
"name": "ɵɵtext"
|
||||
"name": "Δtext"
|
||||
},
|
||||
{
|
||||
"name": "ɵɵtextBinding"
|
||||
"name": "ΔtextBinding"
|
||||
}
|
||||
]
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue