@angular/core 14.0.0-next.4 → 14.0.0-next.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/core.d.ts +32 -5
- package/esm2020/src/linker/template_ref.mjs +3 -3
- package/esm2020/src/linker/view_container_ref.mjs +12 -3
- package/esm2020/src/render3/component.mjs +3 -3
- package/esm2020/src/render3/component_ref.mjs +24 -18
- package/esm2020/src/render3/context_discovery.mjs +9 -3
- package/esm2020/src/render3/di.mjs +177 -97
- package/esm2020/src/render3/hooks.mjs +3 -3
- package/esm2020/src/render3/instructions/lview_debug.mjs +1 -1
- package/esm2020/src/render3/instructions/shared.mjs +11 -7
- package/esm2020/src/render3/interfaces/injector.mjs +1 -1
- package/esm2020/src/render3/interfaces/lview_tracking.mjs +8 -5
- package/esm2020/src/render3/interfaces/view.mjs +3 -2
- package/esm2020/src/version.mjs +1 -1
- package/esm2020/testing/src/logger.mjs +3 -3
- package/esm2020/testing/src/ng_zone_mock.mjs +3 -3
- package/fesm2015/core.mjs +245 -136
- package/fesm2015/core.mjs.map +1 -1
- package/fesm2015/testing.mjs +1 -1
- package/fesm2020/core.mjs +245 -136
- package/fesm2020/core.mjs.map +1 -1
- package/fesm2020/testing.mjs +1 -1
- package/package.json +1 -1
- package/testing/testing.d.ts +1 -1
|
@@ -147,7 +147,7 @@ export function incrementInitPhaseFlags(lView, initPhase) {
|
|
|
147
147
|
assertNotEqual(initPhase, 3 /* InitPhaseCompleted */, 'Init hooks phase should not be incremented after all init hooks have been run.');
|
|
148
148
|
let flags = lView[FLAGS];
|
|
149
149
|
if ((flags & 3 /* InitPhaseStateMask */) === initPhase) {
|
|
150
|
-
flags &=
|
|
150
|
+
flags &= 4095 /* IndexWithinInitPhaseReset */;
|
|
151
151
|
flags += 1 /* InitPhaseStateIncrementer */;
|
|
152
152
|
lView[FLAGS] = flags;
|
|
153
153
|
}
|
|
@@ -211,12 +211,12 @@ function callHook(currentView, initPhase, arr, i) {
|
|
|
211
211
|
const directiveIndex = isInitHook ? -arr[i] : arr[i];
|
|
212
212
|
const directive = currentView[directiveIndex];
|
|
213
213
|
if (isInitHook) {
|
|
214
|
-
const indexWithintInitPhase = currentView[FLAGS] >>
|
|
214
|
+
const indexWithintInitPhase = currentView[FLAGS] >> 12 /* IndexWithinInitPhaseShift */;
|
|
215
215
|
// The init phase state must be always checked here as it may have been recursively updated.
|
|
216
216
|
if (indexWithintInitPhase <
|
|
217
217
|
(currentView[PREORDER_HOOK_FLAGS] >> 16 /* NumberOfInitHooksCalledShift */) &&
|
|
218
218
|
(currentView[FLAGS] & 3 /* InitPhaseStateMask */) === initPhase) {
|
|
219
|
-
currentView[FLAGS] +=
|
|
219
|
+
currentView[FLAGS] += 4096 /* IndexWithinInitPhaseIncrementer */;
|
|
220
220
|
profiler(4 /* LifecycleHookStart */, directive, hook);
|
|
221
221
|
try {
|
|
222
222
|
hook.call(directive);
|
|
@@ -457,7 +457,7 @@ export class LViewDebug {
|
|
|
457
457
|
attached: !!(flags & 128 /* Attached */),
|
|
458
458
|
destroyed: !!(flags & 256 /* Destroyed */),
|
|
459
459
|
isRoot: !!(flags & 512 /* IsRoot */),
|
|
460
|
-
indexWithinInitPhase: flags >>
|
|
460
|
+
indexWithinInitPhase: flags >> 12 /* IndexWithinInitPhaseShift */,
|
|
461
461
|
};
|
|
462
462
|
}
|
|
463
463
|
get parent() {
|