@angular/core 9.1.6 → 9.1.7

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 (42) 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 +2 -230
  5. package/bundles/core.umd.js.map +1 -1
  6. package/bundles/core.umd.min.js +126 -133
  7. package/bundles/core.umd.min.js.map +1 -1
  8. package/core.d.ts +3 -62
  9. package/core.metadata.json +1 -1
  10. package/esm2015/index.js +2 -2
  11. package/esm2015/public_api.js +2 -2
  12. package/esm2015/src/core.js +2 -2
  13. package/esm2015/src/core_render3_private_export.js +2 -2
  14. package/esm2015/src/render3/assert.js +1 -8
  15. package/esm2015/src/render3/index.js +2 -2
  16. package/esm2015/src/render3/instructions/all.js +2 -3
  17. package/esm2015/src/render3/instructions/template.js +100 -0
  18. package/esm2015/src/render3/interfaces/container.js +1 -6
  19. package/esm2015/src/render3/jit/environment.js +1 -6
  20. package/esm2015/src/version.js +1 -1
  21. package/esm5/src/core_render3_private_export.js +2 -2
  22. package/esm5/src/render3/assert.js +1 -4
  23. package/esm5/src/render3/index.js +2 -2
  24. package/esm5/src/render3/instructions/all.js +2 -3
  25. package/esm5/src/render3/instructions/template.js +73 -0
  26. package/esm5/src/render3/interfaces/container.js +1 -1
  27. package/esm5/src/render3/jit/environment.js +1 -6
  28. package/esm5/src/version.js +1 -1
  29. package/fesm2015/core.js +4 -280
  30. package/fesm2015/core.js.map +1 -1
  31. package/fesm2015/testing.js +1 -1
  32. package/fesm5/core.js +3 -226
  33. package/fesm5/core.js.map +1 -1
  34. package/fesm5/testing.js +1 -1
  35. package/package.json +1 -1
  36. package/src/r3_symbols.d.ts +1 -1
  37. package/testing/testing.d.ts +1 -1
  38. package/testing.d.ts +1 -1
  39. package/esm2015/src/render3/instructions/container.js +0 -227
  40. package/esm2015/src/render3/instructions/embedded_view.js +0 -151
  41. package/esm5/src/render3/instructions/container.js +0 -173
  42. package/esm5/src/render3/instructions/embedded_view.js +0 -127
@@ -1,5 +1,5 @@
1
1
  /**
2
- * @license Angular v9.1.6
2
+ * @license Angular v9.1.7
3
3
  * (c) 2010-2020 Google LLC. https://angular.io/
4
4
  * License: MIT
5
5
  */
@@ -2219,9 +2219,6 @@
2219
2219
  arr = lView;
2220
2220
  assertEqual(arr.length, index, "index " + index + " expected to be at the end of arr (length " + arr.length + ")");
2221
2221
  }
2222
- function assertLContainerOrUndefined(value) {
2223
- value && assertEqual(isLContainer(value), true, 'Expecting LContainer or undefined or null');
2224
- }
2225
2222
  function assertLContainer(value) {
2226
2223
  assertDefined(value, 'LContainer must be defined');
2227
2224
  assertEqual(isLContainer(value), true, 'Expecting LContainer');
@@ -14450,26 +14447,6 @@
14450
14447
  * Use of this source code is governed by an MIT-style license that can be
14451
14448
  * found in the LICENSE file at https://angular.io/license
14452
14449
  */
14453
- /**
14454
- * Creates an LContainer for inline views, e.g.
14455
- *
14456
- * % if (showing) {
14457
- * <div></div>
14458
- * % }
14459
- *
14460
- * @param index The index of the container in the data array
14461
- *
14462
- * @codeGenApi
14463
- */
14464
- function ɵɵcontainer(index) {
14465
- var lView = getLView();
14466
- var tView = getTView();
14467
- var tNode = containerInternal(tView, lView, index, null, null);
14468
- if (tView.firstCreatePass) {
14469
- tNode.tViews = [];
14470
- }
14471
- setIsNotParent();
14472
- }
14473
14450
  function templateFirstCreatePass(index, tView, lView, templateFn, decls, vars, tagName, attrsIndex, localRefsIndex) {
14474
14451
  ngDevMode && assertFirstCreatePass(tView);
14475
14452
  ngDevMode && ngDevMode.firstCreatePass++;
@@ -14526,83 +14503,6 @@
14526
14503
  saveResolvedLocalsInData(lView, tNode, localRefExtractor);
14527
14504
  }
14528
14505
  }
14529
- /**
14530
- * Sets a container up to receive views.
14531
- *
14532
- * @param index The index of the container in the data array
14533
- *
14534
- * @codeGenApi
14535
- */
14536
- function ɵɵcontainerRefreshStart(index) {
14537
- var lView = getLView();
14538
- var tView = getTView();
14539
- var previousOrParentTNode = load(tView.data, index);
14540
- ngDevMode && assertNodeType(previousOrParentTNode, 0 /* Container */);
14541
- setPreviousOrParentTNode(previousOrParentTNode, true);
14542
- lView[index + HEADER_OFFSET][ACTIVE_INDEX] = 0;
14543
- // We need to execute init hooks here so ngOnInit hooks are called in top level views
14544
- // before they are called in embedded views (for backwards compatibility).
14545
- if (!getCheckNoChangesMode()) {
14546
- var hooksInitPhaseCompleted = (lView[FLAGS] & 3 /* InitPhaseStateMask */) === 3 /* InitPhaseCompleted */;
14547
- if (hooksInitPhaseCompleted) {
14548
- var preOrderCheckHooks = tView.preOrderCheckHooks;
14549
- if (preOrderCheckHooks !== null) {
14550
- executeCheckHooks(lView, preOrderCheckHooks, null);
14551
- }
14552
- }
14553
- else {
14554
- var preOrderHooks = tView.preOrderHooks;
14555
- if (preOrderHooks !== null) {
14556
- executeInitAndCheckHooks(lView, preOrderHooks, 0 /* OnInitHooksToBeRun */, null);
14557
- }
14558
- incrementInitPhaseFlags(lView, 0 /* OnInitHooksToBeRun */);
14559
- }
14560
- }
14561
- }
14562
- /**
14563
- * Marks the end of the LContainer.
14564
- *
14565
- * Marking the end of LContainer is the time when to child views get inserted or removed.
14566
- *
14567
- * @codeGenApi
14568
- */
14569
- function ɵɵcontainerRefreshEnd() {
14570
- var previousOrParentTNode = getPreviousOrParentTNode();
14571
- if (getIsParent()) {
14572
- setIsNotParent();
14573
- }
14574
- else {
14575
- ngDevMode && assertNodeType(previousOrParentTNode, 2 /* View */);
14576
- ngDevMode && assertHasParent(previousOrParentTNode);
14577
- previousOrParentTNode = previousOrParentTNode.parent;
14578
- setPreviousOrParentTNode(previousOrParentTNode, false);
14579
- }
14580
- ngDevMode && assertNodeType(previousOrParentTNode, 0 /* Container */);
14581
- var lContainer = getLView()[previousOrParentTNode.index];
14582
- var nextIndex = getLContainerActiveIndex(lContainer);
14583
- // remove extra views at the end of the container
14584
- while (nextIndex < lContainer.length - CONTAINER_HEADER_OFFSET) {
14585
- removeView(lContainer, nextIndex);
14586
- }
14587
- }
14588
- function containerInternal(tView, lView, nodeIndex, tagName, attrs) {
14589
- ngDevMode &&
14590
- assertEqual(getBindingIndex(), tView.bindingStartIndex, 'container nodes should be created before any bindings');
14591
- var adjustedIndex = nodeIndex + HEADER_OFFSET;
14592
- ngDevMode && assertDataInRange(lView, nodeIndex + HEADER_OFFSET);
14593
- ngDevMode && ngDevMode.rendererCreateComment++;
14594
- var comment = lView[adjustedIndex] =
14595
- lView[RENDERER].createComment(ngDevMode ? 'container' : '');
14596
- var tNode = getOrCreateTNode(tView, lView[T_HOST], nodeIndex, 0 /* Container */, tagName, attrs);
14597
- var lContainer = lView[adjustedIndex] = createLContainer(comment, lView, comment, tNode);
14598
- appendChild(tView, lView, comment, tNode);
14599
- attachPatchData(comment, lView);
14600
- // Containers are added to the current view tree instead of their embedded views
14601
- // because views can be removed and re-inserted.
14602
- addToViewTree(lView, lContainer);
14603
- ngDevMode && assertNodeType(getPreviousOrParentTNode(), 0 /* Container */);
14604
- return tNode;
14605
- }
14606
14506
 
14607
14507
  /**
14608
14508
  * @license
@@ -14989,124 +14889,6 @@
14989
14889
  ɵɵelementContainerEnd();
14990
14890
  }
14991
14891
 
14992
- /**
14993
- * @license
14994
- * Copyright Google Inc. All Rights Reserved.
14995
- *
14996
- * Use of this source code is governed by an MIT-style license that can be
14997
- * found in the LICENSE file at https://angular.io/license
14998
- */
14999
- /**
15000
- * Marks the start of an embedded view.
15001
- *
15002
- * @param viewBlockId The ID of this view
15003
- * @return boolean Whether or not this view is in creation mode
15004
- *
15005
- * @codeGenApi
15006
- */
15007
- function ɵɵembeddedViewStart(viewBlockId, decls, vars) {
15008
- var lView = getLView();
15009
- var previousOrParentTNode = getPreviousOrParentTNode();
15010
- // The previous node can be a view node if we are processing an inline for loop
15011
- var containerTNode = previousOrParentTNode.type === 2 /* View */ ?
15012
- previousOrParentTNode.parent :
15013
- previousOrParentTNode;
15014
- var lContainer = lView[containerTNode.index];
15015
- ngDevMode && assertNodeType(containerTNode, 0 /* Container */);
15016
- var viewToRender = scanForView(lContainer, getLContainerActiveIndex(lContainer), viewBlockId);
15017
- if (viewToRender) {
15018
- setIsParent();
15019
- enterView(viewToRender, viewToRender[TVIEW].node);
15020
- }
15021
- else {
15022
- // When we create a new LView, we always reset the state of the instructions.
15023
- viewToRender = createLView(lView, getOrCreateEmbeddedTView(viewBlockId, decls, vars, containerTNode), null, 16 /* CheckAlways */, null, null);
15024
- var tParentNode = getIsParent() ? previousOrParentTNode :
15025
- previousOrParentTNode && previousOrParentTNode.parent;
15026
- assignTViewNodeToLView(viewToRender[TVIEW], tParentNode, viewBlockId, viewToRender);
15027
- enterView(viewToRender, viewToRender[TVIEW].node);
15028
- }
15029
- if (lContainer) {
15030
- if (isCreationMode(viewToRender)) {
15031
- // it is a new view, insert it into collection of views for a given container
15032
- insertView(viewToRender[TVIEW], viewToRender, lContainer, getLContainerActiveIndex(lContainer));
15033
- }
15034
- lContainer[ACTIVE_INDEX] += 2 /* INCREMENT */;
15035
- }
15036
- return isCreationMode(viewToRender) ? 1 /* Create */ | 2 /* Update */ :
15037
- 2 /* Update */;
15038
- }
15039
- /**
15040
- * Initialize the TView (e.g. static data) for the active embedded view.
15041
- *
15042
- * Each embedded view block must create or retrieve its own TView. Otherwise, the embedded view's
15043
- * static data for a particular node would overwrite the static data for a node in the view above
15044
- * it with the same index (since it's in the same template).
15045
- *
15046
- * @param viewIndex The index of the TView in TNode.tViews
15047
- * @param decls The number of nodes, local refs, and pipes in this template
15048
- * @param vars The number of bindings and pure function bindings in this template
15049
- * @param container The parent container in which to look for the view's static data
15050
- * @returns TView
15051
- */
15052
- function getOrCreateEmbeddedTView(viewIndex, decls, vars, parent) {
15053
- var tView = getLView()[TVIEW];
15054
- ngDevMode && assertNodeType(parent, 0 /* Container */);
15055
- var containerTViews = parent.tViews;
15056
- ngDevMode && assertDefined(containerTViews, 'TView expected');
15057
- ngDevMode && assertEqual(Array.isArray(containerTViews), true, 'TViews should be in an array');
15058
- if (viewIndex >= containerTViews.length || containerTViews[viewIndex] == null) {
15059
- containerTViews[viewIndex] = createTView(2 /* Embedded */, viewIndex, null, decls, vars, tView.directiveRegistry, tView.pipeRegistry, null, null, tView.consts);
15060
- }
15061
- return containerTViews[viewIndex];
15062
- }
15063
- /**
15064
- * Looks for a view with a given view block id inside a provided LContainer.
15065
- * Removes views that need to be deleted in the process.
15066
- *
15067
- * @param lContainer to search for views
15068
- * @param startIdx starting index in the views array to search from
15069
- * @param viewBlockId exact view block id to look for
15070
- */
15071
- function scanForView(lContainer, startIdx, viewBlockId) {
15072
- for (var i = startIdx + CONTAINER_HEADER_OFFSET; i < lContainer.length; i++) {
15073
- var viewAtPositionId = lContainer[i][TVIEW].id;
15074
- if (viewAtPositionId === viewBlockId) {
15075
- return lContainer[i];
15076
- }
15077
- else if (viewAtPositionId < viewBlockId) {
15078
- // found a view that should not be at this position - remove
15079
- removeView(lContainer, i - CONTAINER_HEADER_OFFSET);
15080
- }
15081
- else {
15082
- // found a view with id greater than the one we are searching for
15083
- // which means that required view doesn't exist and can't be found at
15084
- // later positions in the views array - stop the searchdef.cont here
15085
- break;
15086
- }
15087
- }
15088
- return null;
15089
- }
15090
- /**
15091
- * Marks the end of an embedded view.
15092
- *
15093
- * @codeGenApi
15094
- */
15095
- function ɵɵembeddedViewEnd() {
15096
- var lView = getLView();
15097
- var tView = getTView();
15098
- var viewHost = lView[T_HOST];
15099
- var context = lView[CONTEXT];
15100
- if (isCreationMode(lView)) {
15101
- renderView(tView, lView, context); // creation mode pass
15102
- }
15103
- refreshView(tView, lView, tView.template, context); // update mode pass
15104
- var lContainer = lView[PARENT];
15105
- ngDevMode && assertLContainerOrUndefined(lContainer);
15106
- leaveView();
15107
- setPreviousOrParentTNode(viewHost, false);
15108
- }
15109
-
15110
14892
  /**
15111
14893
  * Returns the current OpaqueViewState instance.
15112
14894
  *
@@ -20445,7 +20227,7 @@
20445
20227
  /**
20446
20228
  * @publicApi
20447
20229
  */
20448
- var VERSION = new Version('9.1.6');
20230
+ var VERSION = new Version('9.1.7');
20449
20231
 
20450
20232
  /**
20451
20233
  * @license
@@ -26677,10 +26459,7 @@
26677
26459
  'ɵɵProvidersFeature': ɵɵProvidersFeature,
26678
26460
  'ɵɵCopyDefinitionFeature': ɵɵCopyDefinitionFeature,
26679
26461
  'ɵɵInheritDefinitionFeature': ɵɵInheritDefinitionFeature,
26680
- 'ɵɵcontainer': ɵɵcontainer,
26681
26462
  'ɵɵnextContext': ɵɵnextContext,
26682
- 'ɵɵcontainerRefreshStart': ɵɵcontainerRefreshStart,
26683
- 'ɵɵcontainerRefreshEnd': ɵɵcontainerRefreshEnd,
26684
26463
  'ɵɵnamespaceHTML': ɵɵnamespaceHTML,
26685
26464
  'ɵɵnamespaceMathML': ɵɵnamespaceMathML,
26686
26465
  'ɵɵnamespaceSVG': ɵɵnamespaceSVG,
@@ -26780,8 +26559,6 @@
26780
26559
  'ɵɵtextInterpolate7': ɵɵtextInterpolate7,
26781
26560
  'ɵɵtextInterpolate8': ɵɵtextInterpolate8,
26782
26561
  'ɵɵtextInterpolateV': ɵɵtextInterpolateV,
26783
- 'ɵɵembeddedViewStart': ɵɵembeddedViewStart,
26784
- 'ɵɵembeddedViewEnd': ɵɵembeddedViewEnd,
26785
26562
  'ɵɵi18n': ɵɵi18n,
26786
26563
  'ɵɵi18nAttributes': ɵɵi18nAttributes,
26787
26564
  'ɵɵi18nExp': ɵɵi18nExp,
@@ -33329,9 +33106,6 @@
33329
33106
  exports.ɵɵclassMapInterpolateV = ɵɵclassMapInterpolateV;
33330
33107
  exports.ɵɵclassProp = ɵɵclassProp;
33331
33108
  exports.ɵɵcomponentHostSyntheticListener = ɵɵcomponentHostSyntheticListener;
33332
- exports.ɵɵcontainer = ɵɵcontainer;
33333
- exports.ɵɵcontainerRefreshEnd = ɵɵcontainerRefreshEnd;
33334
- exports.ɵɵcontainerRefreshStart = ɵɵcontainerRefreshStart;
33335
33109
  exports.ɵɵcontentQuery = ɵɵcontentQuery;
33336
33110
  exports.ɵɵdefaultStyleSanitizer = ɵɵdefaultStyleSanitizer;
33337
33111
  exports.ɵɵdefineComponent = ɵɵdefineComponent;
@@ -33348,8 +33122,6 @@
33348
33122
  exports.ɵɵelementContainerStart = ɵɵelementContainerStart;
33349
33123
  exports.ɵɵelementEnd = ɵɵelementEnd;
33350
33124
  exports.ɵɵelementStart = ɵɵelementStart;
33351
- exports.ɵɵembeddedViewEnd = ɵɵembeddedViewEnd;
33352
- exports.ɵɵembeddedViewStart = ɵɵembeddedViewStart;
33353
33125
  exports.ɵɵenableBindings = ɵɵenableBindings;
33354
33126
  exports.ɵɵgetCurrentView = ɵɵgetCurrentView;
33355
33127
  exports.ɵɵgetFactoryOf = ɵɵgetFactoryOf;