@angular/core 8.0.0 → 8.0.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (40) hide show
  1. package/bundles/core-testing.umd.js +1 -1
  2. package/bundles/core-testing.umd.min.js +1 -1
  3. package/bundles/core-testing.umd.min.js.map +1 -1
  4. package/bundles/core.umd.js +51 -39
  5. package/bundles/core.umd.js.map +1 -1
  6. package/bundles/core.umd.min.js +74 -82
  7. package/bundles/core.umd.min.js.map +1 -1
  8. package/core.d.ts +17 -5
  9. package/core.metadata.json +1 -1
  10. package/esm2015/src/di/injectable.js +1 -1
  11. package/esm2015/src/render3/component_ref.js +2 -4
  12. package/esm2015/src/render3/index.js +1 -1
  13. package/esm2015/src/render3/instructions/all.js +2 -2
  14. package/esm2015/src/render3/instructions/projection.js +52 -13
  15. package/esm2015/src/render3/interfaces/projection.js +1 -1
  16. package/esm2015/src/render3/node_selector_matcher.js +2 -27
  17. package/esm2015/src/render3/styling/class_and_style_bindings.js +2 -2
  18. package/esm2015/src/version.js +1 -1
  19. package/esm5/src/di/injectable.js +1 -1
  20. package/esm5/src/render3/component_ref.js +2 -4
  21. package/esm5/src/render3/index.js +1 -1
  22. package/esm5/src/render3/instructions/projection.js +49 -14
  23. package/esm5/src/render3/interfaces/projection.js +1 -1
  24. package/esm5/src/render3/node_selector_matcher.js +2 -23
  25. package/esm5/src/render3/styling/class_and_style_bindings.js +2 -2
  26. package/esm5/src/version.js +1 -1
  27. package/fesm2015/core.js +54 -42
  28. package/fesm2015/core.js.map +1 -1
  29. package/fesm2015/testing.js +1 -1
  30. package/fesm5/core.js +51 -39
  31. package/fesm5/core.js.map +1 -1
  32. package/fesm5/testing.js +1 -1
  33. package/package.json +1 -1
  34. package/schematics/migrations/injectable-pipe/index.js +5 -2
  35. package/schematics/migrations/move-document/index.js +5 -2
  36. package/schematics/migrations/static-queries/index.js +5 -2
  37. package/schematics/migrations/template-var-assignment/index.js +6 -3
  38. package/src/r3_symbols.d.ts +1 -1
  39. package/testing/testing.d.ts +1 -1
  40. package/testing.d.ts +1 -1
@@ -23,5 +23,5 @@ export { Version };
23
23
  /**
24
24
  * @publicApi
25
25
  */
26
- export var VERSION = new Version('8.0.0');
26
+ export var VERSION = new Version('8.0.1');
27
27
  //# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoidmVyc2lvbi5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uLy4uLy4uLy4uLy4uLy4uLy4uLy4uL3BhY2thZ2VzL2NvcmUvc3JjL3ZlcnNpb24udHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IkFBQUE7Ozs7OztHQU1HO0FBRUg7Ozs7R0FJRztBQUNIO0lBS0UsaUJBQW1CLElBQVk7UUFBWixTQUFJLEdBQUosSUFBSSxDQUFRO1FBQzdCLElBQUksQ0FBQyxLQUFLLEdBQUcsSUFBSSxDQUFDLEtBQUssQ0FBQyxHQUFHLENBQUMsQ0FBQyxDQUFDLENBQUMsQ0FBQztRQUNoQyxJQUFJLENBQUMsS0FBSyxHQUFHLElBQUksQ0FBQyxLQUFLLENBQUMsR0FBRyxDQUFDLENBQUMsQ0FBQyxDQUFDLENBQUM7UUFDaEMsSUFBSSxDQUFDLEtBQUssR0FBRyxJQUFJLENBQUMsS0FBSyxDQUFDLEdBQUcsQ0FBQyxDQUFDLEtBQUssQ0FBQyxDQUFDLENBQUMsQ0FBQyxJQUFJLENBQUMsR0FBRyxDQUFDLENBQUM7SUFDbEQsQ0FBQztJQUNILGNBQUM7QUFBRCxDQUFDLEFBVkQsSUFVQzs7QUFFRDs7R0FFRztBQUNILE1BQU0sQ0FBQyxJQUFNLE9BQU8sR0FBRyxJQUFJLE9BQU8sQ0FBQyxtQkFBbUIsQ0FBQyxDQUFDIiwic291cmNlc0NvbnRlbnQiOlsiLyoqXG4gKiBAbGljZW5zZVxuICogQ29weXJpZ2h0IEdvb2dsZSBJbmMuIEFsbCBSaWdodHMgUmVzZXJ2ZWQuXG4gKlxuICogVXNlIG9mIHRoaXMgc291cmNlIGNvZGUgaXMgZ292ZXJuZWQgYnkgYW4gTUlULXN0eWxlIGxpY2Vuc2UgdGhhdCBjYW4gYmVcbiAqIGZvdW5kIGluIHRoZSBMSUNFTlNFIGZpbGUgYXQgaHR0cHM6Ly9hbmd1bGFyLmlvL2xpY2Vuc2VcbiAqL1xuXG4vKipcbiAqIEBkZXNjcmlwdGlvbiBSZXByZXNlbnRzIHRoZSB2ZXJzaW9uIG9mIEFuZ3VsYXJcbiAqXG4gKiBAcHVibGljQXBpXG4gKi9cbmV4cG9ydCBjbGFzcyBWZXJzaW9uIHtcbiAgcHVibGljIHJlYWRvbmx5IG1ham9yOiBzdHJpbmc7XG4gIHB1YmxpYyByZWFkb25seSBtaW5vcjogc3RyaW5nO1xuICBwdWJsaWMgcmVhZG9ubHkgcGF0Y2g6IHN0cmluZztcblxuICBjb25zdHJ1Y3RvcihwdWJsaWMgZnVsbDogc3RyaW5nKSB7XG4gICAgdGhpcy5tYWpvciA9IGZ1bGwuc3BsaXQoJy4nKVswXTtcbiAgICB0aGlzLm1pbm9yID0gZnVsbC5zcGxpdCgnLicpWzFdO1xuICAgIHRoaXMucGF0Y2ggPSBmdWxsLnNwbGl0KCcuJykuc2xpY2UoMikuam9pbignLicpO1xuICB9XG59XG5cbi8qKlxuICogQHB1YmxpY0FwaVxuICovXG5leHBvcnQgY29uc3QgVkVSU0lPTiA9IG5ldyBWZXJzaW9uKCcwLjAuMC1QTEFDRUhPTERFUicpO1xuIl19
package/fesm2015/core.js CHANGED
@@ -1,5 +1,5 @@
1
1
  /**
2
- * @license Angular v8.0.0
2
+ * @license Angular v8.0.1
3
3
  * (c) 2010-2019 Google LLC. https://angular.io/
4
4
  * License: MIT
5
5
  */
@@ -10999,7 +10999,7 @@ function getInitialStyleStringValue(context) {
10999
10999
  return styleString;
11000
11000
  }
11001
11001
  /**
11002
- * Returns the current cached mutli-value for a given directiveIndex within the provided context.
11002
+ * Returns the current cached multi-value for a given directiveIndex within the provided context.
11003
11003
  * @param {?} context
11004
11004
  * @param {?} entryIsClassBased
11005
11005
  * @param {?} directiveIndex
@@ -11483,31 +11483,6 @@ function getProjectAsAttrValue(tNode) {
11483
11483
  }
11484
11484
  return null;
11485
11485
  }
11486
- /**
11487
- * Checks a given node against matching projection selectors and returns
11488
- * selector index (or 0 if none matched).
11489
- *
11490
- * This function takes into account the parsed ngProjectAs selector from the node's attributes.
11491
- * If present, it will check whether the ngProjectAs selector matches any of the projection
11492
- * selectors.
11493
- * @param {?} tNode
11494
- * @param {?} selectors
11495
- * @return {?}
11496
- */
11497
- function matchingProjectionSelectorIndex(tNode, selectors) {
11498
- /** @type {?} */
11499
- const ngProjectAsAttrVal = getProjectAsAttrValue(tNode);
11500
- for (let i = 0; i < selectors.length; i++) {
11501
- // If we ran into an `ngProjectAs` attribute, we should match its parsed selector
11502
- // to the list of selectors, otherwise we fall back to matching against the node.
11503
- if (ngProjectAsAttrVal === null ?
11504
- isNodeMatchingSelectorList(tNode, selectors[i], /* isProjectionMode */ true) :
11505
- isSelectorInSelectorList(ngProjectAsAttrVal, selectors[i])) {
11506
- return i + 1; // first matching selector "captures" a given node
11507
- }
11508
- }
11509
- return 0;
11510
- }
11511
11486
  /**
11512
11487
  * @param {?} nodeAttrs
11513
11488
  * @return {?}
@@ -16134,6 +16109,41 @@ function ɵɵnextContext(level = 1) {
16134
16109
  * @fileoverview added by tsickle
16135
16110
  * @suppress {checkTypes,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
16136
16111
  */
16112
+ /**
16113
+ * Checks a given node against matching projection slots and returns the
16114
+ * determined slot index. Returns "null" if no slot matched the given node.
16115
+ *
16116
+ * This function takes into account the parsed ngProjectAs selector from the
16117
+ * node's attributes. If present, it will check whether the ngProjectAs selector
16118
+ * matches any of the projection slot selectors.
16119
+ * @param {?} tNode
16120
+ * @param {?} projectionSlots
16121
+ * @return {?}
16122
+ */
16123
+ function matchingProjectionSlotIndex(tNode, projectionSlots) {
16124
+ /** @type {?} */
16125
+ let wildcardNgContentIndex = null;
16126
+ /** @type {?} */
16127
+ const ngProjectAsAttrVal = getProjectAsAttrValue(tNode);
16128
+ for (let i = 0; i < projectionSlots.length; i++) {
16129
+ /** @type {?} */
16130
+ const slotValue = projectionSlots[i];
16131
+ // The last wildcard projection slot should match all nodes which aren't matching
16132
+ // any selector. This is necessary to be backwards compatible with view engine.
16133
+ if (slotValue === '*') {
16134
+ wildcardNgContentIndex = i;
16135
+ continue;
16136
+ }
16137
+ // If we ran into an `ngProjectAs` attribute, we should match its parsed selector
16138
+ // to the list of selectors, otherwise we fall back to matching against the node.
16139
+ if (ngProjectAsAttrVal === null ?
16140
+ isNodeMatchingSelectorList(tNode, slotValue, /* isProjectionMode */ true) :
16141
+ isSelectorInSelectorList(ngProjectAsAttrVal, slotValue)) {
16142
+ return i; // first matching selector "captures" a given node
16143
+ }
16144
+ }
16145
+ return wildcardNgContentIndex;
16146
+ }
16137
16147
  /**
16138
16148
  * Instruction to distribute projectable nodes among <ng-content> occurrences in a given template.
16139
16149
  * It takes all the selectors from the entire component's template and decides where
@@ -16153,32 +16163,36 @@ function ɵɵnextContext(level = 1) {
16153
16163
  * template author).
16154
16164
  *
16155
16165
  * \@codeGenApi
16156
- * @param {?=} selectors A collection of parsed CSS selectors
16166
+ * @param {?=} projectionSlots
16157
16167
  * @return {?}
16158
16168
  */
16159
- function ɵɵprojectionDef(selectors) {
16169
+ function ɵɵprojectionDef(projectionSlots) {
16160
16170
  /** @type {?} */
16161
16171
  const componentNode = (/** @type {?} */ (findComponentView(getLView())[T_HOST]));
16162
16172
  if (!componentNode.projection) {
16173
+ // If no explicit projection slots are defined, fall back to a single
16174
+ // projection slot with the wildcard selector.
16163
16175
  /** @type {?} */
16164
- const noOfNodeBuckets = selectors ? selectors.length + 1 : 1;
16176
+ const numProjectionSlots = projectionSlots ? projectionSlots.length : 1;
16165
16177
  /** @type {?} */
16166
16178
  const projectionHeads = componentNode.projection =
16167
- new Array(noOfNodeBuckets).fill(null);
16179
+ new Array(numProjectionSlots).fill(null);
16168
16180
  /** @type {?} */
16169
16181
  const tails = projectionHeads.slice();
16170
16182
  /** @type {?} */
16171
16183
  let componentChild = componentNode.child;
16172
16184
  while (componentChild !== null) {
16173
16185
  /** @type {?} */
16174
- const bucketIndex = selectors ? matchingProjectionSelectorIndex(componentChild, selectors) : 0;
16175
- if (tails[bucketIndex]) {
16176
- (/** @type {?} */ (tails[bucketIndex])).projectionNext = componentChild;
16177
- }
16178
- else {
16179
- projectionHeads[bucketIndex] = componentChild;
16186
+ const slotIndex = projectionSlots ? matchingProjectionSlotIndex(componentChild, projectionSlots) : 0;
16187
+ if (slotIndex !== null) {
16188
+ if (tails[slotIndex]) {
16189
+ (/** @type {?} */ (tails[slotIndex])).projectionNext = componentChild;
16190
+ }
16191
+ else {
16192
+ projectionHeads[slotIndex] = componentChild;
16193
+ }
16194
+ tails[slotIndex] = componentChild;
16180
16195
  }
16181
- tails[bucketIndex] = componentChild;
16182
16196
  componentChild = componentChild.next;
16183
16197
  }
16184
16198
  }
@@ -20510,7 +20524,7 @@ class Version {
20510
20524
  * \@publicApi
20511
20525
  * @type {?}
20512
20526
  */
20513
- const VERSION = new Version('8.0.0');
20527
+ const VERSION = new Version('8.0.1');
20514
20528
 
20515
20529
  /**
20516
20530
  * @fileoverview added by tsickle
@@ -25019,10 +25033,8 @@ class ComponentFactory$1 extends ComponentFactory {
25019
25033
  this.ngModule = ngModule;
25020
25034
  this.componentType = componentDef.type;
25021
25035
  this.selector = (/** @type {?} */ (componentDef.selectors[0][0]));
25022
- // The component definition does not include the wildcard ('*') selector in its list.
25023
- // It is implicitly expected as the first item in the projectable nodes array.
25024
25036
  this.ngContentSelectors =
25025
- componentDef.ngContentSelectors ? ['*', ...componentDef.ngContentSelectors] : [];
25037
+ componentDef.ngContentSelectors ? componentDef.ngContentSelectors : [];
25026
25038
  this.isBoundToModule = !!ngModule;
25027
25039
  }
25028
25040
  /**