@angular/core 10.0.4 → 10.0.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/bundles/core-testing.umd.js +1 -1
- package/bundles/core-testing.umd.min.js +1 -1
- package/bundles/core-testing.umd.min.js.map +1 -1
- package/bundles/core.umd.js +200 -201
- package/bundles/core.umd.js.map +1 -1
- package/bundles/core.umd.min.js +124 -124
- package/bundles/core.umd.min.js.map +1 -1
- package/core.d.ts +125 -119
- package/core.metadata.json +1 -1
- package/esm2015/core.js +11 -10
- package/esm2015/src/core_render3_private_export.js +2 -2
- package/esm2015/src/metadata/directives.js +1 -1
- package/esm2015/src/render3/definition.js +3 -11
- package/esm2015/src/render3/di.js +3 -3
- package/esm2015/src/render3/di_setup.js +5 -5
- package/esm2015/src/render3/features/inherit_definition_feature.js +1 -11
- package/esm2015/src/render3/features/ng_onchanges_feature.js +32 -22
- package/esm2015/src/render3/hooks.js +27 -23
- package/esm2015/src/render3/index.js +3 -3
- package/esm2015/src/render3/instructions/element.js +4 -4
- package/esm2015/src/render3/instructions/host_property.js +3 -3
- package/esm2015/src/render3/instructions/listener.js +3 -3
- package/esm2015/src/render3/instructions/shared.js +15 -12
- package/esm2015/src/render3/interfaces/definition.js +1 -1
- package/esm2015/src/render3/interfaces/node.js +1 -1
- package/esm2015/src/render3/jit/environment.js +3 -3
- package/esm2015/src/render3/util/discovery_utils.js +2 -2
- package/esm2015/src/version.js +1 -1
- package/fesm2015/core.js +179 -181
- package/fesm2015/core.js.map +1 -1
- package/fesm2015/testing.js +1 -1
- package/package.json +1 -1
- package/src/r3_symbols.d.ts +1 -1
- package/testing/testing.d.ts +1 -1
- package/testing.d.ts +1 -1
package/bundles/core.umd.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* @license Angular v10.0.
|
|
2
|
+
* @license Angular v10.0.5
|
|
3
3
|
* (c) 2010-2020 Google LLC. https://angular.io/
|
|
4
4
|
* License: MIT
|
|
5
5
|
*/
|
|
@@ -1894,14 +1894,6 @@
|
|
|
1894
1894
|
inputs: null,
|
|
1895
1895
|
outputs: null,
|
|
1896
1896
|
exportAs: componentDefinition.exportAs || null,
|
|
1897
|
-
onChanges: null,
|
|
1898
|
-
onInit: typePrototype.ngOnInit || null,
|
|
1899
|
-
doCheck: typePrototype.ngDoCheck || null,
|
|
1900
|
-
afterContentInit: typePrototype.ngAfterContentInit || null,
|
|
1901
|
-
afterContentChecked: typePrototype.ngAfterContentChecked || null,
|
|
1902
|
-
afterViewInit: typePrototype.ngAfterViewInit || null,
|
|
1903
|
-
afterViewChecked: typePrototype.ngAfterViewChecked || null,
|
|
1904
|
-
onDestroy: typePrototype.ngOnDestroy || null,
|
|
1905
1897
|
onPush: componentDefinition.changeDetection === exports.ChangeDetectionStrategy.OnPush,
|
|
1906
1898
|
directiveDefs: null,
|
|
1907
1899
|
pipeDefs: null,
|
|
@@ -1909,8 +1901,8 @@
|
|
|
1909
1901
|
viewQuery: componentDefinition.viewQuery || null,
|
|
1910
1902
|
features: componentDefinition.features || null,
|
|
1911
1903
|
data: componentDefinition.data || {},
|
|
1912
|
-
// TODO(misko): convert ViewEncapsulation into const enum so that it can be used
|
|
1913
|
-
// the next line. Also `None` should be 0 not 2.
|
|
1904
|
+
// TODO(misko): convert ViewEncapsulation into const enum so that it can be used
|
|
1905
|
+
// directly in the next line. Also `None` should be 0 not 2.
|
|
1914
1906
|
encapsulation: componentDefinition.encapsulation || exports.ViewEncapsulation.Emulated,
|
|
1915
1907
|
id: 'c',
|
|
1916
1908
|
styles: componentDefinition.styles || EMPTY_ARRAY,
|
|
@@ -2322,6 +2314,127 @@
|
|
|
2322
2314
|
}
|
|
2323
2315
|
}
|
|
2324
2316
|
|
|
2317
|
+
/**
|
|
2318
|
+
* @license
|
|
2319
|
+
* Copyright Google LLC All Rights Reserved.
|
|
2320
|
+
*
|
|
2321
|
+
* Use of this source code is governed by an MIT-style license that can be
|
|
2322
|
+
* found in the LICENSE file at https://angular.io/license
|
|
2323
|
+
*/
|
|
2324
|
+
/**
|
|
2325
|
+
* Represents a basic change from a previous to a new value for a single
|
|
2326
|
+
* property on a directive instance. Passed as a value in a
|
|
2327
|
+
* {@link SimpleChanges} object to the `ngOnChanges` hook.
|
|
2328
|
+
*
|
|
2329
|
+
* @see `OnChanges`
|
|
2330
|
+
*
|
|
2331
|
+
* @publicApi
|
|
2332
|
+
*/
|
|
2333
|
+
var SimpleChange = /** @class */ (function () {
|
|
2334
|
+
function SimpleChange(previousValue, currentValue, firstChange) {
|
|
2335
|
+
this.previousValue = previousValue;
|
|
2336
|
+
this.currentValue = currentValue;
|
|
2337
|
+
this.firstChange = firstChange;
|
|
2338
|
+
}
|
|
2339
|
+
/**
|
|
2340
|
+
* Check whether the new value is the first value assigned.
|
|
2341
|
+
*/
|
|
2342
|
+
SimpleChange.prototype.isFirstChange = function () {
|
|
2343
|
+
return this.firstChange;
|
|
2344
|
+
};
|
|
2345
|
+
return SimpleChange;
|
|
2346
|
+
}());
|
|
2347
|
+
|
|
2348
|
+
/**
|
|
2349
|
+
* @license
|
|
2350
|
+
* Copyright Google LLC All Rights Reserved.
|
|
2351
|
+
*
|
|
2352
|
+
* Use of this source code is governed by an MIT-style license that can be
|
|
2353
|
+
* found in the LICENSE file at https://angular.io/license
|
|
2354
|
+
*/
|
|
2355
|
+
/**
|
|
2356
|
+
* The NgOnChangesFeature decorates a component with support for the ngOnChanges
|
|
2357
|
+
* lifecycle hook, so it should be included in any component that implements
|
|
2358
|
+
* that hook.
|
|
2359
|
+
*
|
|
2360
|
+
* If the component or directive uses inheritance, the NgOnChangesFeature MUST
|
|
2361
|
+
* be included as a feature AFTER {@link InheritDefinitionFeature}, otherwise
|
|
2362
|
+
* inherited properties will not be propagated to the ngOnChanges lifecycle
|
|
2363
|
+
* hook.
|
|
2364
|
+
*
|
|
2365
|
+
* Example usage:
|
|
2366
|
+
*
|
|
2367
|
+
* ```
|
|
2368
|
+
* static ɵcmp = defineComponent({
|
|
2369
|
+
* ...
|
|
2370
|
+
* inputs: {name: 'publicName'},
|
|
2371
|
+
* features: [NgOnChangesFeature]
|
|
2372
|
+
* });
|
|
2373
|
+
* ```
|
|
2374
|
+
*
|
|
2375
|
+
* @codeGenApi
|
|
2376
|
+
*/
|
|
2377
|
+
function ɵɵNgOnChangesFeature() {
|
|
2378
|
+
return NgOnChangesFeatureImpl;
|
|
2379
|
+
}
|
|
2380
|
+
function NgOnChangesFeatureImpl(definition) {
|
|
2381
|
+
if (definition.type.prototype.ngOnChanges) {
|
|
2382
|
+
definition.setInput = ngOnChangesSetInput;
|
|
2383
|
+
}
|
|
2384
|
+
return rememberChangeHistoryAndInvokeOnChangesHook;
|
|
2385
|
+
}
|
|
2386
|
+
// This option ensures that the ngOnChanges lifecycle hook will be inherited
|
|
2387
|
+
// from superclasses (in InheritDefinitionFeature).
|
|
2388
|
+
/** @nocollapse */
|
|
2389
|
+
// tslint:disable-next-line:no-toplevel-property-access
|
|
2390
|
+
ɵɵNgOnChangesFeature.ngInherit = true;
|
|
2391
|
+
/**
|
|
2392
|
+
* This is a synthetic lifecycle hook which gets inserted into `TView.preOrderHooks` to simulate
|
|
2393
|
+
* `ngOnChanges`.
|
|
2394
|
+
*
|
|
2395
|
+
* The hook reads the `NgSimpleChangesStore` data from the component instance and if changes are
|
|
2396
|
+
* found it invokes `ngOnChanges` on the component instance.
|
|
2397
|
+
*
|
|
2398
|
+
* @param this Component instance. Because this function gets inserted into `TView.preOrderHooks`,
|
|
2399
|
+
* it is guaranteed to be called with component instance.
|
|
2400
|
+
*/
|
|
2401
|
+
function rememberChangeHistoryAndInvokeOnChangesHook() {
|
|
2402
|
+
var simpleChangesStore = getSimpleChangesStore(this);
|
|
2403
|
+
var current = simpleChangesStore === null || simpleChangesStore === void 0 ? void 0 : simpleChangesStore.current;
|
|
2404
|
+
if (current) {
|
|
2405
|
+
var previous = simpleChangesStore.previous;
|
|
2406
|
+
if (previous === EMPTY_OBJ) {
|
|
2407
|
+
simpleChangesStore.previous = current;
|
|
2408
|
+
}
|
|
2409
|
+
else {
|
|
2410
|
+
// New changes are copied to the previous store, so that we don't lose history for inputs
|
|
2411
|
+
// which were not changed this time
|
|
2412
|
+
for (var key in current) {
|
|
2413
|
+
previous[key] = current[key];
|
|
2414
|
+
}
|
|
2415
|
+
}
|
|
2416
|
+
simpleChangesStore.current = null;
|
|
2417
|
+
this.ngOnChanges(current);
|
|
2418
|
+
}
|
|
2419
|
+
}
|
|
2420
|
+
function ngOnChangesSetInput(instance, value, publicName, privateName) {
|
|
2421
|
+
var simpleChangesStore = getSimpleChangesStore(instance) ||
|
|
2422
|
+
setSimpleChangesStore(instance, { previous: EMPTY_OBJ, current: null });
|
|
2423
|
+
var current = simpleChangesStore.current || (simpleChangesStore.current = {});
|
|
2424
|
+
var previous = simpleChangesStore.previous;
|
|
2425
|
+
var declaredName = this.declaredInputs[publicName];
|
|
2426
|
+
var previousChange = previous[declaredName];
|
|
2427
|
+
current[declaredName] = new SimpleChange(previousChange && previousChange.currentValue, value, previous === EMPTY_OBJ);
|
|
2428
|
+
instance[privateName] = value;
|
|
2429
|
+
}
|
|
2430
|
+
var SIMPLE_CHANGES_STORE = '__ngSimpleChanges__';
|
|
2431
|
+
function getSimpleChangesStore(instance) {
|
|
2432
|
+
return instance[SIMPLE_CHANGES_STORE] || null;
|
|
2433
|
+
}
|
|
2434
|
+
function setSimpleChangesStore(instance, store) {
|
|
2435
|
+
return instance[SIMPLE_CHANGES_STORE] = store;
|
|
2436
|
+
}
|
|
2437
|
+
|
|
2325
2438
|
/**
|
|
2326
2439
|
* @license
|
|
2327
2440
|
* Copyright Google LLC All Rights Reserved.
|
|
@@ -3017,17 +3130,19 @@
|
|
|
3017
3130
|
*/
|
|
3018
3131
|
function registerPreOrderHooks(directiveIndex, directiveDef, tView) {
|
|
3019
3132
|
ngDevMode && assertFirstCreatePass(tView);
|
|
3020
|
-
var
|
|
3021
|
-
if (
|
|
3022
|
-
|
|
3023
|
-
(tView.
|
|
3133
|
+
var _a = directiveDef.type.prototype, ngOnChanges = _a.ngOnChanges, ngOnInit = _a.ngOnInit, ngDoCheck = _a.ngDoCheck;
|
|
3134
|
+
if (ngOnChanges) {
|
|
3135
|
+
var wrappedOnChanges = NgOnChangesFeatureImpl(directiveDef);
|
|
3136
|
+
(tView.preOrderHooks || (tView.preOrderHooks = [])).push(directiveIndex, wrappedOnChanges);
|
|
3137
|
+
(tView.preOrderCheckHooks || (tView.preOrderCheckHooks = []))
|
|
3138
|
+
.push(directiveIndex, wrappedOnChanges);
|
|
3024
3139
|
}
|
|
3025
|
-
if (
|
|
3026
|
-
(tView.preOrderHooks || (tView.preOrderHooks = [])).push(-directiveIndex,
|
|
3140
|
+
if (ngOnInit) {
|
|
3141
|
+
(tView.preOrderHooks || (tView.preOrderHooks = [])).push(0 - directiveIndex, ngOnInit);
|
|
3027
3142
|
}
|
|
3028
|
-
if (
|
|
3029
|
-
(tView.preOrderHooks || (tView.preOrderHooks = [])).push(directiveIndex,
|
|
3030
|
-
(tView.preOrderCheckHooks || (tView.preOrderCheckHooks = [])).push(directiveIndex,
|
|
3143
|
+
if (ngDoCheck) {
|
|
3144
|
+
(tView.preOrderHooks || (tView.preOrderHooks = [])).push(directiveIndex, ngDoCheck);
|
|
3145
|
+
(tView.preOrderCheckHooks || (tView.preOrderCheckHooks = [])).push(directiveIndex, ngDoCheck);
|
|
3031
3146
|
}
|
|
3032
3147
|
}
|
|
3033
3148
|
/**
|
|
@@ -3055,23 +3170,24 @@
|
|
|
3055
3170
|
// hooks for projected components and directives must be called *before* their hosts.
|
|
3056
3171
|
for (var i = tNode.directiveStart, end = tNode.directiveEnd; i < end; i++) {
|
|
3057
3172
|
var directiveDef = tView.data[i];
|
|
3058
|
-
|
|
3059
|
-
|
|
3173
|
+
var lifecycleHooks = directiveDef.type.prototype;
|
|
3174
|
+
var ngAfterContentInit = lifecycleHooks.ngAfterContentInit, ngAfterContentChecked = lifecycleHooks.ngAfterContentChecked, ngAfterViewInit = lifecycleHooks.ngAfterViewInit, ngAfterViewChecked = lifecycleHooks.ngAfterViewChecked, ngOnDestroy = lifecycleHooks.ngOnDestroy;
|
|
3175
|
+
if (ngAfterContentInit) {
|
|
3176
|
+
(tView.contentHooks || (tView.contentHooks = [])).push(-i, ngAfterContentInit);
|
|
3060
3177
|
}
|
|
3061
|
-
if (
|
|
3062
|
-
(tView.contentHooks || (tView.contentHooks = [])).push(i,
|
|
3063
|
-
(tView.contentCheckHooks || (tView.contentCheckHooks = []))
|
|
3064
|
-
.push(i, directiveDef.afterContentChecked);
|
|
3178
|
+
if (ngAfterContentChecked) {
|
|
3179
|
+
(tView.contentHooks || (tView.contentHooks = [])).push(i, ngAfterContentChecked);
|
|
3180
|
+
(tView.contentCheckHooks || (tView.contentCheckHooks = [])).push(i, ngAfterContentChecked);
|
|
3065
3181
|
}
|
|
3066
|
-
if (
|
|
3067
|
-
(tView.viewHooks || (tView.viewHooks = [])).push(-i,
|
|
3182
|
+
if (ngAfterViewInit) {
|
|
3183
|
+
(tView.viewHooks || (tView.viewHooks = [])).push(-i, ngAfterViewInit);
|
|
3068
3184
|
}
|
|
3069
|
-
if (
|
|
3070
|
-
(tView.viewHooks || (tView.viewHooks = [])).push(i,
|
|
3071
|
-
(tView.viewCheckHooks || (tView.viewCheckHooks = [])).push(i,
|
|
3185
|
+
if (ngAfterViewChecked) {
|
|
3186
|
+
(tView.viewHooks || (tView.viewHooks = [])).push(i, ngAfterViewChecked);
|
|
3187
|
+
(tView.viewCheckHooks || (tView.viewCheckHooks = [])).push(i, ngAfterViewChecked);
|
|
3072
3188
|
}
|
|
3073
|
-
if (
|
|
3074
|
-
(tView.destroyHooks || (tView.destroyHooks = [])).push(i,
|
|
3189
|
+
if (ngOnDestroy != null) {
|
|
3190
|
+
(tView.destroyHooks || (tView.destroyHooks = [])).push(i, ngOnDestroy);
|
|
3075
3191
|
}
|
|
3076
3192
|
}
|
|
3077
3193
|
}
|
|
@@ -4153,10 +4269,10 @@
|
|
|
4153
4269
|
function locateDirectiveOrProvider(tNode, tView, token, canAccessViewProviders, isHostSpecialCase) {
|
|
4154
4270
|
var nodeProviderIndexes = tNode.providerIndexes;
|
|
4155
4271
|
var tInjectables = tView.data;
|
|
4156
|
-
var injectablesStart = nodeProviderIndexes &
|
|
4272
|
+
var injectablesStart = nodeProviderIndexes & 1048575 /* ProvidersStartIndexMask */;
|
|
4157
4273
|
var directivesStart = tNode.directiveStart;
|
|
4158
4274
|
var directiveEnd = tNode.directiveEnd;
|
|
4159
|
-
var cptViewProvidersCount = nodeProviderIndexes >>
|
|
4275
|
+
var cptViewProvidersCount = nodeProviderIndexes >> 20 /* CptViewProvidersCountShift */;
|
|
4160
4276
|
var startingIndex = canAccessViewProviders ? injectablesStart : injectablesStart + cptViewProvidersCount;
|
|
4161
4277
|
// When the host special case applies, only the viewProviders and the component are visible
|
|
4162
4278
|
var endIndex = isHostSpecialCase ? injectablesStart + cptViewProvidersCount : directiveEnd;
|
|
@@ -7432,6 +7548,8 @@
|
|
|
7432
7548
|
else {
|
|
7433
7549
|
// If it's not a number, it's a host binding function that needs to be executed.
|
|
7434
7550
|
if (instruction !== null) {
|
|
7551
|
+
ngDevMode &&
|
|
7552
|
+
assertLessThan(currentDirectiveIndex, 1048576 /* CptViewProvidersCountShifter */, 'Reached the max number of host bindings');
|
|
7435
7553
|
setBindingRootForHostBindings(bindingRootIndex, currentDirectiveIndex);
|
|
7436
7554
|
var hostCtx = lView[currentDirectiveIndex];
|
|
7437
7555
|
instruction(2 /* Update */, hostCtx);
|
|
@@ -8195,7 +8313,7 @@
|
|
|
8195
8313
|
propName = mapPropName(propName);
|
|
8196
8314
|
if (ngDevMode) {
|
|
8197
8315
|
validateAgainstEventProperties(propName);
|
|
8198
|
-
if (!validateProperty(tView,
|
|
8316
|
+
if (!validateProperty(tView, element, propName, tNode)) {
|
|
8199
8317
|
// Return here since we only log warnings for unknown properties.
|
|
8200
8318
|
logUnknownPropertyError(propName, tNode);
|
|
8201
8319
|
return;
|
|
@@ -8213,10 +8331,10 @@
|
|
|
8213
8331
|
element[propName] = value;
|
|
8214
8332
|
}
|
|
8215
8333
|
}
|
|
8216
|
-
else if (tNode.type === 0 /* Container */) {
|
|
8334
|
+
else if (tNode.type === 0 /* Container */ || tNode.type === 4 /* ElementContainer */) {
|
|
8217
8335
|
// If the node is a container and the property didn't
|
|
8218
8336
|
// match any of the inputs or schemas we should throw.
|
|
8219
|
-
if (ngDevMode && !matchingSchemas(tView,
|
|
8337
|
+
if (ngDevMode && !matchingSchemas(tView, tNode.tagName)) {
|
|
8220
8338
|
logUnknownPropertyError(propName, tNode);
|
|
8221
8339
|
}
|
|
8222
8340
|
}
|
|
@@ -8270,7 +8388,7 @@
|
|
|
8270
8388
|
}
|
|
8271
8389
|
}
|
|
8272
8390
|
}
|
|
8273
|
-
function validateProperty(tView,
|
|
8391
|
+
function validateProperty(tView, element, propName, tNode) {
|
|
8274
8392
|
// If `schemas` is set to `null`, that's an indication that this Component was compiled in AOT
|
|
8275
8393
|
// mode where this check happens at compile time. In JIT mode, `schemas` is always present and
|
|
8276
8394
|
// defined as an array (as an empty array in case `schemas` field is not defined) and we should
|
|
@@ -8279,15 +8397,14 @@
|
|
|
8279
8397
|
return true;
|
|
8280
8398
|
// The property is considered valid if the element matches the schema, it exists on the element
|
|
8281
8399
|
// or it is synthetic, and we are in a browser context (web worker nodes should be skipped).
|
|
8282
|
-
if (matchingSchemas(tView,
|
|
8283
|
-
isAnimationProp(propName)) {
|
|
8400
|
+
if (matchingSchemas(tView, tNode.tagName) || propName in element || isAnimationProp(propName)) {
|
|
8284
8401
|
return true;
|
|
8285
8402
|
}
|
|
8286
8403
|
// Note: `typeof Node` returns 'function' in most browsers, but on IE it is 'object' so we
|
|
8287
8404
|
// need to account for both here, while being careful for `typeof null` also returning 'object'.
|
|
8288
8405
|
return typeof Node === 'undefined' || Node === null || !(element instanceof Node);
|
|
8289
8406
|
}
|
|
8290
|
-
function matchingSchemas(tView,
|
|
8407
|
+
function matchingSchemas(tView, tagName) {
|
|
8291
8408
|
var schemas = tView.schemas;
|
|
8292
8409
|
if (schemas !== null) {
|
|
8293
8410
|
for (var i = 0; i < schemas.length; i++) {
|
|
@@ -8367,16 +8484,18 @@
|
|
|
8367
8484
|
tNode.flags |= 8 /* hasContentQuery */;
|
|
8368
8485
|
if (def.hostBindings !== null || def.hostAttrs !== null || def.hostVars !== 0)
|
|
8369
8486
|
tNode.flags |= 128 /* hasHostBindings */;
|
|
8487
|
+
var lifeCycleHooks = def.type.prototype;
|
|
8370
8488
|
// Only push a node index into the preOrderHooks array if this is the first
|
|
8371
8489
|
// pre-order hook found on this node.
|
|
8372
|
-
if (!preOrderHooksFound &&
|
|
8490
|
+
if (!preOrderHooksFound &&
|
|
8491
|
+
(lifeCycleHooks.ngOnChanges || lifeCycleHooks.ngOnInit || lifeCycleHooks.ngDoCheck)) {
|
|
8373
8492
|
// We will push the actual hook function into this array later during dir instantiation.
|
|
8374
8493
|
// We cannot do it now because we must ensure hooks are registered in the same
|
|
8375
8494
|
// order that directives are created (i.e. injection order).
|
|
8376
8495
|
(tView.preOrderHooks || (tView.preOrderHooks = [])).push(tNode.index - HEADER_OFFSET);
|
|
8377
8496
|
preOrderHooksFound = true;
|
|
8378
8497
|
}
|
|
8379
|
-
if (!preOrderCheckHooksFound && (
|
|
8498
|
+
if (!preOrderCheckHooksFound && (lifeCycleHooks.ngOnChanges || lifeCycleHooks.ngDoCheck)) {
|
|
8380
8499
|
(tView.preOrderCheckHooks || (tView.preOrderCheckHooks = []))
|
|
8381
8500
|
.push(tNode.index - HEADER_OFFSET);
|
|
8382
8501
|
preOrderCheckHooksFound = true;
|
|
@@ -8516,7 +8635,7 @@
|
|
|
8516
8635
|
// requires non standard math arithmetic and it can prevent VM optimizations.
|
|
8517
8636
|
// `0-0` will always produce `0` and will not cause a potential deoptimization in VM.
|
|
8518
8637
|
var elementIndex = HEADER_OFFSET - tNode.index;
|
|
8519
|
-
var providerStartIndex = tNode.providerIndexes &
|
|
8638
|
+
var providerStartIndex = tNode.providerIndexes & 1048575 /* ProvidersStartIndexMask */;
|
|
8520
8639
|
var providerCount = tView.data.length - providerStartIndex;
|
|
8521
8640
|
(tView.expandoInstructions || (tView.expandoInstructions = []))
|
|
8522
8641
|
.push(elementIndex, providerCount, directiveCount);
|
|
@@ -14389,7 +14508,7 @@
|
|
|
14389
14508
|
var attrs = getConstant(tViewConsts, attrsIndex);
|
|
14390
14509
|
var tNode = getOrCreateTNode(tView, lView[T_HOST], index, 3 /* Element */, name, attrs);
|
|
14391
14510
|
var hasDirectives = resolveDirectives(tView, lView, tNode, getConstant(tViewConsts, localRefsIndex));
|
|
14392
|
-
ngDevMode && logUnknownElementError(tView,
|
|
14511
|
+
ngDevMode && logUnknownElementError(tView, native, tNode, hasDirectives);
|
|
14393
14512
|
if (tNode.attrs !== null) {
|
|
14394
14513
|
computeStaticStyling(tNode, tNode.attrs, false);
|
|
14395
14514
|
}
|
|
@@ -14504,7 +14623,7 @@
|
|
|
14504
14623
|
ɵɵelementStart(index, name, attrsIndex, localRefsIndex);
|
|
14505
14624
|
ɵɵelementEnd();
|
|
14506
14625
|
}
|
|
14507
|
-
function logUnknownElementError(tView,
|
|
14626
|
+
function logUnknownElementError(tView, element, tNode, hasDirectives) {
|
|
14508
14627
|
var schemas = tView.schemas;
|
|
14509
14628
|
// If `schemas` is set to `null`, that's an indication that this Component was compiled in AOT
|
|
14510
14629
|
// mode where this check happens at compile time. In JIT mode, `schemas` is always present and
|
|
@@ -14525,7 +14644,7 @@
|
|
|
14525
14644
|
element instanceof HTMLUnknownElement) ||
|
|
14526
14645
|
(typeof customElements !== 'undefined' && tagName.indexOf('-') > -1 &&
|
|
14527
14646
|
!customElements.get(tagName));
|
|
14528
|
-
if (isUnknown && !matchingSchemas(tView,
|
|
14647
|
+
if (isUnknown && !matchingSchemas(tView, tagName)) {
|
|
14529
14648
|
var message = "'" + tagName + "' is not a known element:\n";
|
|
14530
14649
|
message += "1. If '" + tagName + "' is an Angular component, then verify that it is part of this module.\n";
|
|
14531
14650
|
if (tagName && tagName.indexOf('-') > -1) {
|
|
@@ -14728,7 +14847,7 @@
|
|
|
14728
14847
|
*
|
|
14729
14848
|
* @codeGenApi
|
|
14730
14849
|
*/
|
|
14731
|
-
function
|
|
14850
|
+
function ɵɵsyntheticHostListener(eventName, listenerFn, useCapture, eventTargetResolver) {
|
|
14732
14851
|
if (useCapture === void 0) { useCapture = false; }
|
|
14733
14852
|
var tNode = getPreviousOrParentTNode();
|
|
14734
14853
|
var lView = getLView();
|
|
@@ -14736,7 +14855,7 @@
|
|
|
14736
14855
|
var currentDef = getCurrentDirectiveDef(tView.data);
|
|
14737
14856
|
var renderer = loadComponentRenderer(currentDef, tNode, lView);
|
|
14738
14857
|
listenerInternal(tView, lView, renderer, tNode, eventName, listenerFn, useCapture, eventTargetResolver);
|
|
14739
|
-
return
|
|
14858
|
+
return ɵɵsyntheticHostListener;
|
|
14740
14859
|
}
|
|
14741
14860
|
/**
|
|
14742
14861
|
* A utility function that checks if a given element has already an event handler registered for an
|
|
@@ -18354,7 +18473,7 @@
|
|
|
18354
18473
|
*
|
|
18355
18474
|
* @codeGenApi
|
|
18356
18475
|
*/
|
|
18357
|
-
function
|
|
18476
|
+
function ɵɵsyntheticHostProperty(propName, value, sanitizer) {
|
|
18358
18477
|
var lView = getLView();
|
|
18359
18478
|
var bindingIndex = nextBindingIndex();
|
|
18360
18479
|
if (bindingUpdated(lView, bindingIndex, value)) {
|
|
@@ -18365,7 +18484,7 @@
|
|
|
18365
18484
|
elementPropertyInternal(tView, tNode, lView, propName, value, renderer, sanitizer, true);
|
|
18366
18485
|
ngDevMode && storePropertyBindingMetadata(tView.data, tNode, propName, bindingIndex);
|
|
18367
18486
|
}
|
|
18368
|
-
return
|
|
18487
|
+
return ɵɵsyntheticHostProperty;
|
|
18369
18488
|
}
|
|
18370
18489
|
|
|
18371
18490
|
/**
|
|
@@ -18500,7 +18619,7 @@
|
|
|
18500
18619
|
var tView = lView[TVIEW];
|
|
18501
18620
|
var tNode = tView.data[context.nodeIndex];
|
|
18502
18621
|
var providerTokens = [];
|
|
18503
|
-
var startIndex = tNode.providerIndexes &
|
|
18622
|
+
var startIndex = tNode.providerIndexes & 1048575 /* ProvidersStartIndexMask */;
|
|
18504
18623
|
var endIndex = tNode.directiveEnd;
|
|
18505
18624
|
for (var i = startIndex; i < endIndex; i++) {
|
|
18506
18625
|
var value = tView.data[i];
|
|
@@ -19055,16 +19174,6 @@
|
|
|
19055
19174
|
var defData = definition.data;
|
|
19056
19175
|
defData.animation = (defData.animation || []).concat(superDef.data.animation);
|
|
19057
19176
|
}
|
|
19058
|
-
// Inherit hooks
|
|
19059
|
-
// Assume super class inheritance feature has already run.
|
|
19060
|
-
writeableDef.afterContentChecked =
|
|
19061
|
-
writeableDef.afterContentChecked || superDef.afterContentChecked;
|
|
19062
|
-
writeableDef.afterContentInit = definition.afterContentInit || superDef.afterContentInit;
|
|
19063
|
-
writeableDef.afterViewChecked = definition.afterViewChecked || superDef.afterViewChecked;
|
|
19064
|
-
writeableDef.afterViewInit = definition.afterViewInit || superDef.afterViewInit;
|
|
19065
|
-
writeableDef.doCheck = definition.doCheck || superDef.doCheck;
|
|
19066
|
-
writeableDef.onDestroy = definition.onDestroy || superDef.onDestroy;
|
|
19067
|
-
writeableDef.onInit = definition.onInit || superDef.onInit;
|
|
19068
19177
|
}
|
|
19069
19178
|
// Run parent features
|
|
19070
19179
|
var features = superDef.features;
|
|
@@ -19251,117 +19360,6 @@
|
|
|
19251
19360
|
}
|
|
19252
19361
|
}
|
|
19253
19362
|
|
|
19254
|
-
/**
|
|
19255
|
-
* @license
|
|
19256
|
-
* Copyright Google LLC All Rights Reserved.
|
|
19257
|
-
*
|
|
19258
|
-
* Use of this source code is governed by an MIT-style license that can be
|
|
19259
|
-
* found in the LICENSE file at https://angular.io/license
|
|
19260
|
-
*/
|
|
19261
|
-
/**
|
|
19262
|
-
* Represents a basic change from a previous to a new value for a single
|
|
19263
|
-
* property on a directive instance. Passed as a value in a
|
|
19264
|
-
* {@link SimpleChanges} object to the `ngOnChanges` hook.
|
|
19265
|
-
*
|
|
19266
|
-
* @see `OnChanges`
|
|
19267
|
-
*
|
|
19268
|
-
* @publicApi
|
|
19269
|
-
*/
|
|
19270
|
-
var SimpleChange = /** @class */ (function () {
|
|
19271
|
-
function SimpleChange(previousValue, currentValue, firstChange) {
|
|
19272
|
-
this.previousValue = previousValue;
|
|
19273
|
-
this.currentValue = currentValue;
|
|
19274
|
-
this.firstChange = firstChange;
|
|
19275
|
-
}
|
|
19276
|
-
/**
|
|
19277
|
-
* Check whether the new value is the first value assigned.
|
|
19278
|
-
*/
|
|
19279
|
-
SimpleChange.prototype.isFirstChange = function () {
|
|
19280
|
-
return this.firstChange;
|
|
19281
|
-
};
|
|
19282
|
-
return SimpleChange;
|
|
19283
|
-
}());
|
|
19284
|
-
|
|
19285
|
-
/**
|
|
19286
|
-
* @license
|
|
19287
|
-
* Copyright Google LLC All Rights Reserved.
|
|
19288
|
-
*
|
|
19289
|
-
* Use of this source code is governed by an MIT-style license that can be
|
|
19290
|
-
* found in the LICENSE file at https://angular.io/license
|
|
19291
|
-
*/
|
|
19292
|
-
var PRIVATE_PREFIX = '__ngOnChanges_';
|
|
19293
|
-
/**
|
|
19294
|
-
* The NgOnChangesFeature decorates a component with support for the ngOnChanges
|
|
19295
|
-
* lifecycle hook, so it should be included in any component that implements
|
|
19296
|
-
* that hook.
|
|
19297
|
-
*
|
|
19298
|
-
* If the component or directive uses inheritance, the NgOnChangesFeature MUST
|
|
19299
|
-
* be included as a feature AFTER {@link InheritDefinitionFeature}, otherwise
|
|
19300
|
-
* inherited properties will not be propagated to the ngOnChanges lifecycle
|
|
19301
|
-
* hook.
|
|
19302
|
-
*
|
|
19303
|
-
* Example usage:
|
|
19304
|
-
*
|
|
19305
|
-
* ```
|
|
19306
|
-
* static ɵcmp = defineComponent({
|
|
19307
|
-
* ...
|
|
19308
|
-
* inputs: {name: 'publicName'},
|
|
19309
|
-
* features: [NgOnChangesFeature]
|
|
19310
|
-
* });
|
|
19311
|
-
* ```
|
|
19312
|
-
*
|
|
19313
|
-
* @codeGenApi
|
|
19314
|
-
*/
|
|
19315
|
-
function ɵɵNgOnChangesFeature(definition) {
|
|
19316
|
-
if (definition.type.prototype.ngOnChanges) {
|
|
19317
|
-
definition.setInput = ngOnChangesSetInput;
|
|
19318
|
-
definition.onChanges = wrapOnChanges();
|
|
19319
|
-
}
|
|
19320
|
-
}
|
|
19321
|
-
// This option ensures that the ngOnChanges lifecycle hook will be inherited
|
|
19322
|
-
// from superclasses (in InheritDefinitionFeature).
|
|
19323
|
-
/** @nocollapse */
|
|
19324
|
-
// tslint:disable-next-line:no-toplevel-property-access
|
|
19325
|
-
ɵɵNgOnChangesFeature.ngInherit = true;
|
|
19326
|
-
function wrapOnChanges() {
|
|
19327
|
-
return function wrapOnChangesHook_inPreviousChangesStorage() {
|
|
19328
|
-
var simpleChangesStore = getSimpleChangesStore(this);
|
|
19329
|
-
var current = simpleChangesStore && simpleChangesStore.current;
|
|
19330
|
-
if (current) {
|
|
19331
|
-
var previous = simpleChangesStore.previous;
|
|
19332
|
-
if (previous === EMPTY_OBJ) {
|
|
19333
|
-
simpleChangesStore.previous = current;
|
|
19334
|
-
}
|
|
19335
|
-
else {
|
|
19336
|
-
// New changes are copied to the previous store, so that we don't lose history for inputs
|
|
19337
|
-
// which were not changed this time
|
|
19338
|
-
for (var key in current) {
|
|
19339
|
-
previous[key] = current[key];
|
|
19340
|
-
}
|
|
19341
|
-
}
|
|
19342
|
-
simpleChangesStore.current = null;
|
|
19343
|
-
this.ngOnChanges(current);
|
|
19344
|
-
}
|
|
19345
|
-
};
|
|
19346
|
-
}
|
|
19347
|
-
function ngOnChangesSetInput(instance, value, publicName, privateName) {
|
|
19348
|
-
var simpleChangesStore = getSimpleChangesStore(instance) ||
|
|
19349
|
-
setSimpleChangesStore(instance, { previous: EMPTY_OBJ, current: null });
|
|
19350
|
-
var current = simpleChangesStore.current || (simpleChangesStore.current = {});
|
|
19351
|
-
var previous = simpleChangesStore.previous;
|
|
19352
|
-
var declaredName = this.declaredInputs[publicName];
|
|
19353
|
-
var previousChange = previous[declaredName];
|
|
19354
|
-
current[declaredName] = new SimpleChange(previousChange && previousChange.currentValue, value, previous === EMPTY_OBJ);
|
|
19355
|
-
instance[privateName] = value;
|
|
19356
|
-
}
|
|
19357
|
-
var SIMPLE_CHANGES_STORE = '__ngSimpleChanges__';
|
|
19358
|
-
function getSimpleChangesStore(instance) {
|
|
19359
|
-
return instance[SIMPLE_CHANGES_STORE] || null;
|
|
19360
|
-
}
|
|
19361
|
-
function setSimpleChangesStore(instance, store) {
|
|
19362
|
-
return instance[SIMPLE_CHANGES_STORE] = store;
|
|
19363
|
-
}
|
|
19364
|
-
|
|
19365
19363
|
/**
|
|
19366
19364
|
* @license
|
|
19367
19365
|
* Copyright Google LLC All Rights Reserved.
|
|
@@ -19416,9 +19414,9 @@
|
|
|
19416
19414
|
var token = isTypeProvider(provider) ? provider : resolveForwardRef(provider.provide);
|
|
19417
19415
|
var providerFactory = providerToFactory(provider);
|
|
19418
19416
|
var tNode = getPreviousOrParentTNode();
|
|
19419
|
-
var beginIndex = tNode.providerIndexes &
|
|
19417
|
+
var beginIndex = tNode.providerIndexes & 1048575 /* ProvidersStartIndexMask */;
|
|
19420
19418
|
var endIndex = tNode.directiveStart;
|
|
19421
|
-
var cptViewProvidersCount = tNode.providerIndexes >>
|
|
19419
|
+
var cptViewProvidersCount = tNode.providerIndexes >> 20 /* CptViewProvidersCountShift */;
|
|
19422
19420
|
if (isTypeProvider(provider) || !provider.multi) {
|
|
19423
19421
|
// Single provider case: the factory is created and pushed immediately
|
|
19424
19422
|
var factory = new NodeInjectorFactory(providerFactory, isViewProvider, ɵɵdirectiveInject);
|
|
@@ -19430,7 +19428,7 @@
|
|
|
19430
19428
|
tNode.directiveStart++;
|
|
19431
19429
|
tNode.directiveEnd++;
|
|
19432
19430
|
if (isViewProvider) {
|
|
19433
|
-
tNode.providerIndexes +=
|
|
19431
|
+
tNode.providerIndexes += 1048576 /* CptViewProvidersCountShifter */;
|
|
19434
19432
|
}
|
|
19435
19433
|
lInjectablesBlueprint.push(factory);
|
|
19436
19434
|
lView.push(factory);
|
|
@@ -19480,7 +19478,7 @@
|
|
|
19480
19478
|
tNode.directiveStart++;
|
|
19481
19479
|
tNode.directiveEnd++;
|
|
19482
19480
|
if (isViewProvider) {
|
|
19483
|
-
tNode.providerIndexes +=
|
|
19481
|
+
tNode.providerIndexes += 1048576 /* CptViewProvidersCountShifter */;
|
|
19484
19482
|
}
|
|
19485
19483
|
lInjectablesBlueprint.push(factory);
|
|
19486
19484
|
lView.push(factory);
|
|
@@ -19916,7 +19914,7 @@
|
|
|
19916
19914
|
/**
|
|
19917
19915
|
* @publicApi
|
|
19918
19916
|
*/
|
|
19919
|
-
var VERSION = new Version('10.0.
|
|
19917
|
+
var VERSION = new Version('10.0.5');
|
|
19920
19918
|
|
|
19921
19919
|
/**
|
|
19922
19920
|
* @license
|
|
@@ -26044,8 +26042,8 @@
|
|
|
26044
26042
|
'ɵɵrestoreView': ɵɵrestoreView,
|
|
26045
26043
|
'ɵɵlistener': ɵɵlistener,
|
|
26046
26044
|
'ɵɵprojection': ɵɵprojection,
|
|
26047
|
-
'
|
|
26048
|
-
'
|
|
26045
|
+
'ɵɵsyntheticHostProperty': ɵɵsyntheticHostProperty,
|
|
26046
|
+
'ɵɵsyntheticHostListener': ɵɵsyntheticHostListener,
|
|
26049
26047
|
'ɵɵpipeBind1': ɵɵpipeBind1,
|
|
26050
26048
|
'ɵɵpipeBind2': ɵɵpipeBind2,
|
|
26051
26049
|
'ɵɵpipeBind3': ɵɵpipeBind3,
|
|
@@ -32475,21 +32473,22 @@
|
|
|
32475
32473
|
exports.ɵand = anchorDef;
|
|
32476
32474
|
exports.ɵangular_packages_core_core_a = isForwardRef;
|
|
32477
32475
|
exports.ɵangular_packages_core_core_b = injectInjectorOnly;
|
|
32478
|
-
exports.ɵangular_packages_core_core_ba =
|
|
32479
|
-
exports.ɵangular_packages_core_core_bb =
|
|
32480
|
-
exports.ɵangular_packages_core_core_bc =
|
|
32481
|
-
exports.ɵangular_packages_core_core_bd =
|
|
32482
|
-
exports.ɵ
|
|
32483
|
-
exports.ɵangular_packages_core_core_bg =
|
|
32484
|
-
exports.ɵangular_packages_core_core_bh =
|
|
32485
|
-
exports.ɵangular_packages_core_core_bi =
|
|
32486
|
-
exports.ɵangular_packages_core_core_bj =
|
|
32487
|
-
exports.ɵangular_packages_core_core_bk =
|
|
32488
|
-
exports.ɵangular_packages_core_core_bl =
|
|
32489
|
-
exports.ɵangular_packages_core_core_bm =
|
|
32490
|
-
exports.ɵangular_packages_core_core_bn =
|
|
32491
|
-
exports.ɵ
|
|
32492
|
-
exports.ɵangular_packages_core_core_bq =
|
|
32476
|
+
exports.ɵangular_packages_core_core_ba = instructionState;
|
|
32477
|
+
exports.ɵangular_packages_core_core_bb = getLView;
|
|
32478
|
+
exports.ɵangular_packages_core_core_bc = getPreviousOrParentTNode;
|
|
32479
|
+
exports.ɵangular_packages_core_core_bd = getBindingRoot;
|
|
32480
|
+
exports.ɵangular_packages_core_core_be = nextContextImpl;
|
|
32481
|
+
exports.ɵangular_packages_core_core_bg = pureFunction1Internal;
|
|
32482
|
+
exports.ɵangular_packages_core_core_bh = pureFunction2Internal;
|
|
32483
|
+
exports.ɵangular_packages_core_core_bi = pureFunction3Internal;
|
|
32484
|
+
exports.ɵangular_packages_core_core_bj = pureFunction4Internal;
|
|
32485
|
+
exports.ɵangular_packages_core_core_bk = pureFunctionVInternal;
|
|
32486
|
+
exports.ɵangular_packages_core_core_bl = getUrlSanitizer;
|
|
32487
|
+
exports.ɵangular_packages_core_core_bm = makeParamDecorator;
|
|
32488
|
+
exports.ɵangular_packages_core_core_bn = makePropDecorator;
|
|
32489
|
+
exports.ɵangular_packages_core_core_bo = getClosureSafeProperty;
|
|
32490
|
+
exports.ɵangular_packages_core_core_bq = noSideEffects;
|
|
32491
|
+
exports.ɵangular_packages_core_core_br = getRootContext;
|
|
32493
32492
|
exports.ɵangular_packages_core_core_c = NullInjector;
|
|
32494
32493
|
exports.ɵangular_packages_core_core_d = ReflectiveInjector_;
|
|
32495
32494
|
exports.ɵangular_packages_core_core_e = ReflectiveDependency;
|
|
@@ -32511,9 +32510,9 @@
|
|
|
32511
32510
|
exports.ɵangular_packages_core_core_u = USD_CURRENCY_CODE;
|
|
32512
32511
|
exports.ɵangular_packages_core_core_v = _def;
|
|
32513
32512
|
exports.ɵangular_packages_core_core_w = DebugContext;
|
|
32514
|
-
exports.ɵangular_packages_core_core_x =
|
|
32515
|
-
exports.ɵangular_packages_core_core_y =
|
|
32516
|
-
exports.ɵangular_packages_core_core_z =
|
|
32513
|
+
exports.ɵangular_packages_core_core_x = NgOnChangesFeatureImpl;
|
|
32514
|
+
exports.ɵangular_packages_core_core_y = SCHEDULER;
|
|
32515
|
+
exports.ɵangular_packages_core_core_z = injectAttributeImpl;
|
|
32517
32516
|
exports.ɵbypassSanitizationTrustHtml = bypassSanitizationTrustHtml;
|
|
32518
32517
|
exports.ɵbypassSanitizationTrustResourceUrl = bypassSanitizationTrustResourceUrl;
|
|
32519
32518
|
exports.ɵbypassSanitizationTrustScript = bypassSanitizationTrustScript;
|
|
@@ -32623,7 +32622,6 @@
|
|
|
32623
32622
|
exports.ɵɵclassMapInterpolate8 = ɵɵclassMapInterpolate8;
|
|
32624
32623
|
exports.ɵɵclassMapInterpolateV = ɵɵclassMapInterpolateV;
|
|
32625
32624
|
exports.ɵɵclassProp = ɵɵclassProp;
|
|
32626
|
-
exports.ɵɵcomponentHostSyntheticListener = ɵɵcomponentHostSyntheticListener;
|
|
32627
32625
|
exports.ɵɵcontentQuery = ɵɵcontentQuery;
|
|
32628
32626
|
exports.ɵɵdefineComponent = ɵɵdefineComponent;
|
|
32629
32627
|
exports.ɵɵdefineDirective = ɵɵdefineDirective;
|
|
@@ -32728,6 +32726,8 @@
|
|
|
32728
32726
|
exports.ɵɵstylePropInterpolate7 = ɵɵstylePropInterpolate7;
|
|
32729
32727
|
exports.ɵɵstylePropInterpolate8 = ɵɵstylePropInterpolate8;
|
|
32730
32728
|
exports.ɵɵstylePropInterpolateV = ɵɵstylePropInterpolateV;
|
|
32729
|
+
exports.ɵɵsyntheticHostListener = ɵɵsyntheticHostListener;
|
|
32730
|
+
exports.ɵɵsyntheticHostProperty = ɵɵsyntheticHostProperty;
|
|
32731
32731
|
exports.ɵɵtemplate = ɵɵtemplate;
|
|
32732
32732
|
exports.ɵɵtemplateRefExtractor = ɵɵtemplateRefExtractor;
|
|
32733
32733
|
exports.ɵɵtext = ɵɵtext;
|
|
@@ -32741,7 +32741,6 @@
|
|
|
32741
32741
|
exports.ɵɵtextInterpolate7 = ɵɵtextInterpolate7;
|
|
32742
32742
|
exports.ɵɵtextInterpolate8 = ɵɵtextInterpolate8;
|
|
32743
32743
|
exports.ɵɵtextInterpolateV = ɵɵtextInterpolateV;
|
|
32744
|
-
exports.ɵɵupdateSyntheticHostBinding = ɵɵupdateSyntheticHostBinding;
|
|
32745
32744
|
exports.ɵɵviewQuery = ɵɵviewQuery;
|
|
32746
32745
|
|
|
32747
32746
|
Object.defineProperty(exports, '__esModule', { value: true });
|