@angular/core 19.2.0-next.3 → 19.2.0-rc.0
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/fesm2022/core.mjs +973 -988
- package/fesm2022/core.mjs.map +1 -1
- package/fesm2022/primitives/event-dispatch.mjs +1 -1
- package/fesm2022/primitives/signals.mjs +5 -5
- package/fesm2022/primitives/signals.mjs.map +1 -1
- package/fesm2022/rxjs-interop.mjs +1 -1
- package/fesm2022/testing.mjs +4 -4
- package/index.d.ts +68 -35
- package/package.json +1 -1
- package/primitives/event-dispatch/index.d.ts +1 -1
- package/primitives/signals/index.d.ts +2 -2
- package/rxjs-interop/index.d.ts +1 -1
- package/schematics/bundles/apply_import_manager-a930fcf1.js +71 -0
- package/schematics/bundles/{checker-32db85a6.js → checker-2eecc677.js} +17 -16
- package/schematics/bundles/cleanup-unused-imports.js +16 -15
- package/schematics/bundles/{compiler_host-540e221c.js → compiler_host-c280a924.js} +2 -2
- package/schematics/bundles/control-flow-migration.js +3 -3
- package/schematics/bundles/explicit-standalone-flag.js +3 -3
- package/schematics/bundles/imports-abe29092.js +1 -1
- package/schematics/bundles/{index-d5020c9c.js → index-24a2ad1e.js} +9 -9
- package/schematics/bundles/{index-7ee8967e.js → index-3891dd55.js} +4 -4
- package/schematics/bundles/inject-migration.js +8 -7
- package/schematics/bundles/leading_space-d190b83b.js +1 -1
- package/schematics/bundles/{migrate_ts_type_references-26986908.js → migrate_ts_type_references-71b3a951.js} +20 -20
- package/schematics/bundles/{nodes-a9f0b985.js → ng_decorators-e699c081.js} +1 -14
- package/schematics/bundles/nodes-a535b2be.js +27 -0
- package/schematics/bundles/output-migration.js +21 -20
- package/schematics/bundles/pending-tasks.js +3 -3
- package/schematics/bundles/{program-507de2f1.js → program-24da9092.js} +90 -45
- package/schematics/bundles/{apply_import_manager-f4d044b2.js → project_paths-b073c4d6.js} +3 -57
- package/schematics/bundles/project_tsconfig_paths-e9ccccbf.js +1 -1
- package/schematics/bundles/property_name-7c8433f5.js +31 -0
- package/schematics/bundles/provide-initializer.js +3 -3
- package/schematics/bundles/route-lazy-loading.js +8 -12
- package/schematics/bundles/self-closing-tags-migration.js +448 -0
- package/schematics/bundles/signal-input-migration.js +20 -19
- package/schematics/bundles/signal-queries-migration.js +26 -25
- package/schematics/bundles/signals.js +7 -6
- package/schematics/bundles/standalone-migration.js +12 -11
- package/schematics/collection.json +6 -0
- package/schematics/ng-generate/self-closing-tags-migration/schema.json +14 -0
- package/testing/index.d.ts +1 -1
package/fesm2022/core.mjs
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* @license Angular v19.2.0-
|
|
2
|
+
* @license Angular v19.2.0-rc.0
|
|
3
3
|
* (c) 2010-2024 Google LLC. https://angular.io/
|
|
4
4
|
* License: MIT
|
|
5
5
|
*/
|
|
6
6
|
|
|
7
|
-
import { SIGNAL_NODE as SIGNAL_NODE$1, signalSetFn as signalSetFn$1, producerAccessed as producerAccessed$1, SIGNAL as SIGNAL$1, getActiveConsumer as getActiveConsumer$1, setActiveConsumer as setActiveConsumer$1, createSignal as createSignal$1, signalUpdateFn as signalUpdateFn$1, consumerDestroy as consumerDestroy$1, REACTIVE_NODE as REACTIVE_NODE$1, consumerBeforeComputation as consumerBeforeComputation$1, consumerAfterComputation as consumerAfterComputation$1, consumerPollProducersForChange as consumerPollProducersForChange$1, createComputed as createComputed$1, setThrowInvalidWriteToSignalError as setThrowInvalidWriteToSignalError$1,
|
|
7
|
+
import { SIGNAL_NODE as SIGNAL_NODE$1, signalSetFn as signalSetFn$1, producerAccessed as producerAccessed$1, SIGNAL as SIGNAL$1, getActiveConsumer as getActiveConsumer$1, setActiveConsumer as setActiveConsumer$1, createSignal as createSignal$1, signalUpdateFn as signalUpdateFn$1, consumerDestroy as consumerDestroy$1, REACTIVE_NODE as REACTIVE_NODE$1, consumerBeforeComputation as consumerBeforeComputation$1, consumerAfterComputation as consumerAfterComputation$1, consumerPollProducersForChange as consumerPollProducersForChange$1, createComputed as createComputed$1, setThrowInvalidWriteToSignalError as setThrowInvalidWriteToSignalError$1, createWatch as createWatch$1, isInNotificationPhase as isInNotificationPhase$1, createLinkedSignal as createLinkedSignal$1, linkedSignalSetFn as linkedSignalSetFn$1, linkedSignalUpdateFn as linkedSignalUpdateFn$1 } from '@angular/core/primitives/signals';
|
|
8
8
|
export { SIGNAL as ɵSIGNAL } from '@angular/core/primitives/signals';
|
|
9
9
|
import { BehaviorSubject, Subject, Subscription } from 'rxjs';
|
|
10
10
|
import { Attribute as Attribute$1, clearAppScopedEarlyEventContract, EventContract, EventContractContainer, getAppScopedQueuedEventInfos, EventDispatcher, registerDispatcher, isEarlyEventType, isCaptureEventType, EventPhase } from '@angular/core/primitives/event-dispatch';
|
|
@@ -350,23 +350,21 @@ function stringify(token) {
|
|
|
350
350
|
return token;
|
|
351
351
|
}
|
|
352
352
|
if (Array.isArray(token)) {
|
|
353
|
-
return
|
|
353
|
+
return `[${token.map(stringify).join(', ')}]`;
|
|
354
354
|
}
|
|
355
355
|
if (token == null) {
|
|
356
356
|
return '' + token;
|
|
357
357
|
}
|
|
358
|
-
|
|
359
|
-
|
|
358
|
+
const name = token.overriddenName || token.name;
|
|
359
|
+
if (name) {
|
|
360
|
+
return `${name}`;
|
|
360
361
|
}
|
|
361
|
-
|
|
362
|
-
|
|
362
|
+
const result = token.toString();
|
|
363
|
+
if (result == null) {
|
|
364
|
+
return '' + result;
|
|
363
365
|
}
|
|
364
|
-
const
|
|
365
|
-
|
|
366
|
-
return '' + res;
|
|
367
|
-
}
|
|
368
|
-
const newLineIndex = res.indexOf('\n');
|
|
369
|
-
return newLineIndex === -1 ? res : res.substring(0, newLineIndex);
|
|
366
|
+
const newLineIndex = result.indexOf('\n');
|
|
367
|
+
return newLineIndex >= 0 ? result.slice(0, newLineIndex) : result;
|
|
370
368
|
}
|
|
371
369
|
/**
|
|
372
370
|
* Concatenates two strings with separator, allocating new strings only when necessary.
|
|
@@ -8248,23 +8246,12 @@ function assertDomElement(value) {
|
|
|
8248
8246
|
function extractInputDebugMetadata(inputs) {
|
|
8249
8247
|
const res = {};
|
|
8250
8248
|
for (const key in inputs) {
|
|
8251
|
-
if (
|
|
8252
|
-
|
|
8253
|
-
|
|
8254
|
-
|
|
8255
|
-
|
|
8256
|
-
continue;
|
|
8257
|
-
}
|
|
8258
|
-
let minifiedName;
|
|
8259
|
-
if (Array.isArray(value)) {
|
|
8260
|
-
minifiedName = value[0];
|
|
8261
|
-
// flags are not used for now.
|
|
8262
|
-
// TODO: Consider exposing flag information in discovery.
|
|
8263
|
-
}
|
|
8264
|
-
else {
|
|
8265
|
-
minifiedName = value;
|
|
8249
|
+
if (inputs.hasOwnProperty(key)) {
|
|
8250
|
+
const value = inputs[key];
|
|
8251
|
+
if (value !== undefined) {
|
|
8252
|
+
res[key] = value[0];
|
|
8253
|
+
}
|
|
8266
8254
|
}
|
|
8267
|
-
res[key] = minifiedName;
|
|
8268
8255
|
}
|
|
8269
8256
|
return res;
|
|
8270
8257
|
}
|
|
@@ -12242,6 +12229,206 @@ function setupStaticAttributes(renderer, element, tNode) {
|
|
|
12242
12229
|
}
|
|
12243
12230
|
}
|
|
12244
12231
|
|
|
12232
|
+
/**
|
|
12233
|
+
* Creates a TView instance
|
|
12234
|
+
*
|
|
12235
|
+
* @param type Type of `TView`.
|
|
12236
|
+
* @param declTNode Declaration location of this `TView`.
|
|
12237
|
+
* @param templateFn Template function
|
|
12238
|
+
* @param decls The number of nodes, local refs, and pipes in this template
|
|
12239
|
+
* @param directives Registry of directives for this view
|
|
12240
|
+
* @param pipes Registry of pipes for this view
|
|
12241
|
+
* @param viewQuery View queries for this view
|
|
12242
|
+
* @param schemas Schemas for this view
|
|
12243
|
+
* @param consts Constants for this view
|
|
12244
|
+
*/
|
|
12245
|
+
function createTView(type, declTNode, templateFn, decls, vars, directives, pipes, viewQuery, schemas, constsOrFactory, ssrId) {
|
|
12246
|
+
ngDevMode && ngDevMode.tView++;
|
|
12247
|
+
const bindingStartIndex = HEADER_OFFSET + decls;
|
|
12248
|
+
// This length does not yet contain host bindings from child directives because at this point,
|
|
12249
|
+
// we don't know which directives are active on this template. As soon as a directive is matched
|
|
12250
|
+
// that has a host binding, we will update the blueprint with that def's hostVars count.
|
|
12251
|
+
const initialViewLength = bindingStartIndex + vars;
|
|
12252
|
+
const blueprint = createViewBlueprint(bindingStartIndex, initialViewLength);
|
|
12253
|
+
const consts = typeof constsOrFactory === 'function' ? constsOrFactory() : constsOrFactory;
|
|
12254
|
+
const tView = (blueprint[TVIEW] = {
|
|
12255
|
+
type: type,
|
|
12256
|
+
blueprint: blueprint,
|
|
12257
|
+
template: templateFn,
|
|
12258
|
+
queries: null,
|
|
12259
|
+
viewQuery: viewQuery,
|
|
12260
|
+
declTNode: declTNode,
|
|
12261
|
+
data: blueprint.slice().fill(null, bindingStartIndex),
|
|
12262
|
+
bindingStartIndex: bindingStartIndex,
|
|
12263
|
+
expandoStartIndex: initialViewLength,
|
|
12264
|
+
hostBindingOpCodes: null,
|
|
12265
|
+
firstCreatePass: true,
|
|
12266
|
+
firstUpdatePass: true,
|
|
12267
|
+
staticViewQueries: false,
|
|
12268
|
+
staticContentQueries: false,
|
|
12269
|
+
preOrderHooks: null,
|
|
12270
|
+
preOrderCheckHooks: null,
|
|
12271
|
+
contentHooks: null,
|
|
12272
|
+
contentCheckHooks: null,
|
|
12273
|
+
viewHooks: null,
|
|
12274
|
+
viewCheckHooks: null,
|
|
12275
|
+
destroyHooks: null,
|
|
12276
|
+
cleanup: null,
|
|
12277
|
+
contentQueries: null,
|
|
12278
|
+
components: null,
|
|
12279
|
+
directiveRegistry: typeof directives === 'function' ? directives() : directives,
|
|
12280
|
+
pipeRegistry: typeof pipes === 'function' ? pipes() : pipes,
|
|
12281
|
+
firstChild: null,
|
|
12282
|
+
schemas: schemas,
|
|
12283
|
+
consts: consts,
|
|
12284
|
+
incompleteFirstPass: false,
|
|
12285
|
+
ssrId,
|
|
12286
|
+
});
|
|
12287
|
+
if (ngDevMode) {
|
|
12288
|
+
// For performance reasons it is important that the tView retains the same shape during runtime.
|
|
12289
|
+
// (To make sure that all of the code is monomorphic.) For this reason we seal the object to
|
|
12290
|
+
// prevent class transitions.
|
|
12291
|
+
Object.seal(tView);
|
|
12292
|
+
}
|
|
12293
|
+
return tView;
|
|
12294
|
+
}
|
|
12295
|
+
function createViewBlueprint(bindingStartIndex, initialViewLength) {
|
|
12296
|
+
const blueprint = [];
|
|
12297
|
+
for (let i = 0; i < initialViewLength; i++) {
|
|
12298
|
+
blueprint.push(i < bindingStartIndex ? null : NO_CHANGE);
|
|
12299
|
+
}
|
|
12300
|
+
return blueprint;
|
|
12301
|
+
}
|
|
12302
|
+
/**
|
|
12303
|
+
* Gets TView from a template function or creates a new TView
|
|
12304
|
+
* if it doesn't already exist.
|
|
12305
|
+
*
|
|
12306
|
+
* @param def ComponentDef
|
|
12307
|
+
* @returns TView
|
|
12308
|
+
*/
|
|
12309
|
+
function getOrCreateComponentTView(def) {
|
|
12310
|
+
const tView = def.tView;
|
|
12311
|
+
// Create a TView if there isn't one, or recreate it if the first create pass didn't
|
|
12312
|
+
// complete successfully since we can't know for sure whether it's in a usable shape.
|
|
12313
|
+
if (tView === null || tView.incompleteFirstPass) {
|
|
12314
|
+
// Declaration node here is null since this function is called when we dynamically create a
|
|
12315
|
+
// component and hence there is no declaration.
|
|
12316
|
+
const declTNode = null;
|
|
12317
|
+
return (def.tView = createTView(1 /* TViewType.Component */, declTNode, def.template, def.decls, def.vars, def.directiveDefs, def.pipeDefs, def.viewQuery, def.schemas, def.consts, def.id));
|
|
12318
|
+
}
|
|
12319
|
+
return tView;
|
|
12320
|
+
}
|
|
12321
|
+
function createLView(parentLView, tView, context, flags, host, tHostNode, environment, renderer, injector, embeddedViewInjector, hydrationInfo) {
|
|
12322
|
+
const lView = tView.blueprint.slice();
|
|
12323
|
+
lView[HOST] = host;
|
|
12324
|
+
lView[FLAGS] =
|
|
12325
|
+
flags |
|
|
12326
|
+
4 /* LViewFlags.CreationMode */ |
|
|
12327
|
+
128 /* LViewFlags.Attached */ |
|
|
12328
|
+
8 /* LViewFlags.FirstLViewPass */ |
|
|
12329
|
+
64 /* LViewFlags.Dirty */ |
|
|
12330
|
+
1024 /* LViewFlags.RefreshView */;
|
|
12331
|
+
if (embeddedViewInjector !== null ||
|
|
12332
|
+
(parentLView && parentLView[FLAGS] & 2048 /* LViewFlags.HasEmbeddedViewInjector */)) {
|
|
12333
|
+
lView[FLAGS] |= 2048 /* LViewFlags.HasEmbeddedViewInjector */;
|
|
12334
|
+
}
|
|
12335
|
+
resetPreOrderHookFlags(lView);
|
|
12336
|
+
ngDevMode && tView.declTNode && parentLView && assertTNodeForLView(tView.declTNode, parentLView);
|
|
12337
|
+
lView[PARENT] = lView[DECLARATION_VIEW] = parentLView;
|
|
12338
|
+
lView[CONTEXT] = context;
|
|
12339
|
+
lView[ENVIRONMENT] = (environment || (parentLView && parentLView[ENVIRONMENT]));
|
|
12340
|
+
ngDevMode && assertDefined(lView[ENVIRONMENT], 'LViewEnvironment is required');
|
|
12341
|
+
lView[RENDERER] = (renderer || (parentLView && parentLView[RENDERER]));
|
|
12342
|
+
ngDevMode && assertDefined(lView[RENDERER], 'Renderer is required');
|
|
12343
|
+
lView[INJECTOR] = injector || (parentLView && parentLView[INJECTOR]) || null;
|
|
12344
|
+
lView[T_HOST] = tHostNode;
|
|
12345
|
+
lView[ID] = getUniqueLViewId();
|
|
12346
|
+
lView[HYDRATION] = hydrationInfo;
|
|
12347
|
+
lView[EMBEDDED_VIEW_INJECTOR] = embeddedViewInjector;
|
|
12348
|
+
ngDevMode &&
|
|
12349
|
+
assertEqual(tView.type == 2 /* TViewType.Embedded */ ? parentLView !== null : true, true, 'Embedded views must have parentLView');
|
|
12350
|
+
lView[DECLARATION_COMPONENT_VIEW] =
|
|
12351
|
+
tView.type == 2 /* TViewType.Embedded */ ? parentLView[DECLARATION_COMPONENT_VIEW] : lView;
|
|
12352
|
+
return lView;
|
|
12353
|
+
}
|
|
12354
|
+
function createComponentLView(lView, hostTNode, def) {
|
|
12355
|
+
const native = getNativeByTNode(hostTNode, lView);
|
|
12356
|
+
const tView = getOrCreateComponentTView(def);
|
|
12357
|
+
// Only component views should be added to the view tree directly. Embedded views are
|
|
12358
|
+
// accessed through their containers because they may be removed / re-added later.
|
|
12359
|
+
const rendererFactory = lView[ENVIRONMENT].rendererFactory;
|
|
12360
|
+
const componentView = addToEndOfViewTree(lView, createLView(lView, tView, null, getInitialLViewFlagsFromDef(def), native, hostTNode, null, rendererFactory.createRenderer(native, def), null, null, null));
|
|
12361
|
+
// Component view will always be created before any injected LContainers,
|
|
12362
|
+
// so this is a regular element, wrap it with the component view
|
|
12363
|
+
return (lView[hostTNode.index] = componentView);
|
|
12364
|
+
}
|
|
12365
|
+
/**
|
|
12366
|
+
* Gets the initial set of LView flags based on the component definition that the LView represents.
|
|
12367
|
+
* @param def Component definition from which to determine the flags.
|
|
12368
|
+
*/
|
|
12369
|
+
function getInitialLViewFlagsFromDef(def) {
|
|
12370
|
+
let flags = 16 /* LViewFlags.CheckAlways */;
|
|
12371
|
+
if (def.signals) {
|
|
12372
|
+
flags = 4096 /* LViewFlags.SignalView */;
|
|
12373
|
+
}
|
|
12374
|
+
else if (def.onPush) {
|
|
12375
|
+
flags = 64 /* LViewFlags.Dirty */;
|
|
12376
|
+
}
|
|
12377
|
+
return flags;
|
|
12378
|
+
}
|
|
12379
|
+
/**
|
|
12380
|
+
* When elements are created dynamically after a view blueprint is created (e.g. through
|
|
12381
|
+
* i18nApply()), we need to adjust the blueprint for future template passes.
|
|
12382
|
+
*
|
|
12383
|
+
* @param tView `TView` associated with `LView`
|
|
12384
|
+
* @param lView The `LView` containing the blueprint to adjust
|
|
12385
|
+
* @param numSlotsToAlloc The number of slots to alloc in the LView, should be >0
|
|
12386
|
+
* @param initialValue Initial value to store in blueprint
|
|
12387
|
+
*/
|
|
12388
|
+
function allocExpando(tView, lView, numSlotsToAlloc, initialValue) {
|
|
12389
|
+
if (numSlotsToAlloc === 0)
|
|
12390
|
+
return -1;
|
|
12391
|
+
if (ngDevMode) {
|
|
12392
|
+
assertFirstCreatePass(tView);
|
|
12393
|
+
assertSame(tView, lView[TVIEW], '`LView` must be associated with `TView`!');
|
|
12394
|
+
assertEqual(tView.data.length, lView.length, 'Expecting LView to be same size as TView');
|
|
12395
|
+
assertEqual(tView.data.length, tView.blueprint.length, 'Expecting Blueprint to be same size as TView');
|
|
12396
|
+
assertFirstUpdatePass(tView);
|
|
12397
|
+
}
|
|
12398
|
+
const allocIdx = lView.length;
|
|
12399
|
+
for (let i = 0; i < numSlotsToAlloc; i++) {
|
|
12400
|
+
lView.push(initialValue);
|
|
12401
|
+
tView.blueprint.push(initialValue);
|
|
12402
|
+
tView.data.push(null);
|
|
12403
|
+
}
|
|
12404
|
+
return allocIdx;
|
|
12405
|
+
}
|
|
12406
|
+
/**
|
|
12407
|
+
* Adds LView or LContainer to the end of the current view tree.
|
|
12408
|
+
*
|
|
12409
|
+
* This structure will be used to traverse through nested views to remove listeners
|
|
12410
|
+
* and call onDestroy callbacks.
|
|
12411
|
+
*
|
|
12412
|
+
* @param lView The view where LView or LContainer should be added
|
|
12413
|
+
* @param adjustedHostIndex Index of the view's host node in LView[], adjusted for header
|
|
12414
|
+
* @param lViewOrLContainer The LView or LContainer to add to the view tree
|
|
12415
|
+
* @returns The state passed in
|
|
12416
|
+
*/
|
|
12417
|
+
function addToEndOfViewTree(lView, lViewOrLContainer) {
|
|
12418
|
+
// TODO(benlesh/misko): This implementation is incorrect, because it always adds the LContainer
|
|
12419
|
+
// to the end of the queue, which means if the developer retrieves the LContainers from RNodes out
|
|
12420
|
+
// of order, the change detection will run out of order, as the act of retrieving the the
|
|
12421
|
+
// LContainer from the RNode is what adds it to the queue.
|
|
12422
|
+
if (lView[CHILD_HEAD]) {
|
|
12423
|
+
lView[CHILD_TAIL][NEXT] = lViewOrLContainer;
|
|
12424
|
+
}
|
|
12425
|
+
else {
|
|
12426
|
+
lView[CHILD_HEAD] = lViewOrLContainer;
|
|
12427
|
+
}
|
|
12428
|
+
lView[CHILD_TAIL] = lViewOrLContainer;
|
|
12429
|
+
return lViewOrLContainer;
|
|
12430
|
+
}
|
|
12431
|
+
|
|
12245
12432
|
/**
|
|
12246
12433
|
* Advances to an element for later binding instructions.
|
|
12247
12434
|
*
|
|
@@ -12303,9 +12490,21 @@ var InputFlags;
|
|
|
12303
12490
|
InputFlags[InputFlags["HasDecoratorInputTransform"] = 2] = "HasDecoratorInputTransform";
|
|
12304
12491
|
})(InputFlags || (InputFlags = {}));
|
|
12305
12492
|
|
|
12306
|
-
function writeToDirectiveInput(def, instance, publicName,
|
|
12493
|
+
function writeToDirectiveInput(def, instance, publicName, value) {
|
|
12307
12494
|
const prevConsumer = setActiveConsumer$1(null);
|
|
12308
12495
|
try {
|
|
12496
|
+
if (ngDevMode) {
|
|
12497
|
+
if (!def.inputs.hasOwnProperty(publicName)) {
|
|
12498
|
+
throw new Error(`ASSERTION ERROR: Directive ${def.type.name} does not have an input with a public name of "${publicName}"`);
|
|
12499
|
+
}
|
|
12500
|
+
// Usually we resolve the directive instance using `LView[someIndex]` before writing to an
|
|
12501
|
+
// input, however if the read happens to early, the `LView[someIndex]` might actually be a
|
|
12502
|
+
// `NodeInjectorFactory`. Check for this specific case here since it can break in subtle ways.
|
|
12503
|
+
if (isFactory(instance)) {
|
|
12504
|
+
throw new Error(`ASSERTION ERROR: Cannot write input to factory for type ${def.type.name}. Directive has not been created yet.`);
|
|
12505
|
+
}
|
|
12506
|
+
}
|
|
12507
|
+
const [privateName, flags, transform] = def.inputs[publicName];
|
|
12309
12508
|
// If we know we are dealing with a signal input, we cache its reference
|
|
12310
12509
|
// in a tree-shakable way. The input signal node can then be used for
|
|
12311
12510
|
// value transform execution or actual value updates without introducing
|
|
@@ -12320,9 +12519,9 @@ function writeToDirectiveInput(def, instance, publicName, privateName, flags, va
|
|
|
12320
12519
|
if (inputSignalNode !== null && inputSignalNode.transformFn !== undefined) {
|
|
12321
12520
|
value = inputSignalNode.transformFn(value);
|
|
12322
12521
|
}
|
|
12323
|
-
|
|
12324
|
-
|
|
12325
|
-
value =
|
|
12522
|
+
else if (transform !== null) {
|
|
12523
|
+
// If there is a decorator input transform, run it.
|
|
12524
|
+
value = transform.call(instance, value);
|
|
12326
12525
|
}
|
|
12327
12526
|
if (def.setInput !== null) {
|
|
12328
12527
|
def.setInput(instance, inputSignalNode, value, publicName, privateName);
|
|
@@ -12336,39 +12535,6 @@ function writeToDirectiveInput(def, instance, publicName, privateName, flags, va
|
|
|
12336
12535
|
}
|
|
12337
12536
|
}
|
|
12338
12537
|
|
|
12339
|
-
function createLView(parentLView, tView, context, flags, host, tHostNode, environment, renderer, injector, embeddedViewInjector, hydrationInfo) {
|
|
12340
|
-
const lView = tView.blueprint.slice();
|
|
12341
|
-
lView[HOST] = host;
|
|
12342
|
-
lView[FLAGS] =
|
|
12343
|
-
flags |
|
|
12344
|
-
4 /* LViewFlags.CreationMode */ |
|
|
12345
|
-
128 /* LViewFlags.Attached */ |
|
|
12346
|
-
8 /* LViewFlags.FirstLViewPass */ |
|
|
12347
|
-
64 /* LViewFlags.Dirty */ |
|
|
12348
|
-
1024 /* LViewFlags.RefreshView */;
|
|
12349
|
-
if (embeddedViewInjector !== null ||
|
|
12350
|
-
(parentLView && parentLView[FLAGS] & 2048 /* LViewFlags.HasEmbeddedViewInjector */)) {
|
|
12351
|
-
lView[FLAGS] |= 2048 /* LViewFlags.HasEmbeddedViewInjector */;
|
|
12352
|
-
}
|
|
12353
|
-
resetPreOrderHookFlags(lView);
|
|
12354
|
-
ngDevMode && tView.declTNode && parentLView && assertTNodeForLView(tView.declTNode, parentLView);
|
|
12355
|
-
lView[PARENT] = lView[DECLARATION_VIEW] = parentLView;
|
|
12356
|
-
lView[CONTEXT] = context;
|
|
12357
|
-
lView[ENVIRONMENT] = (environment || (parentLView && parentLView[ENVIRONMENT]));
|
|
12358
|
-
ngDevMode && assertDefined(lView[ENVIRONMENT], 'LViewEnvironment is required');
|
|
12359
|
-
lView[RENDERER] = (renderer || (parentLView && parentLView[RENDERER]));
|
|
12360
|
-
ngDevMode && assertDefined(lView[RENDERER], 'Renderer is required');
|
|
12361
|
-
lView[INJECTOR] = injector || (parentLView && parentLView[INJECTOR]) || null;
|
|
12362
|
-
lView[T_HOST] = tHostNode;
|
|
12363
|
-
lView[ID] = getUniqueLViewId();
|
|
12364
|
-
lView[HYDRATION] = hydrationInfo;
|
|
12365
|
-
lView[EMBEDDED_VIEW_INJECTOR] = embeddedViewInjector;
|
|
12366
|
-
ngDevMode &&
|
|
12367
|
-
assertEqual(tView.type == 2 /* TViewType.Embedded */ ? parentLView !== null : true, true, 'Embedded views must have parentLView');
|
|
12368
|
-
lView[DECLARATION_COMPONENT_VIEW] =
|
|
12369
|
-
tView.type == 2 /* TViewType.Embedded */ ? parentLView[DECLARATION_COMPONENT_VIEW] : lView;
|
|
12370
|
-
return lView;
|
|
12371
|
-
}
|
|
12372
12538
|
function executeTemplate(tView, lView, templateFn, rf, context) {
|
|
12373
12539
|
const prevSelectedIndex = getSelectedIndex();
|
|
12374
12540
|
const isUpdatePhase = rf & 2 /* RenderFlags.Update */;
|
|
@@ -12428,95 +12594,6 @@ function saveResolvedLocalsInData(viewData, tNode, localRefExtractor = getNative
|
|
|
12428
12594
|
}
|
|
12429
12595
|
}
|
|
12430
12596
|
}
|
|
12431
|
-
/**
|
|
12432
|
-
* Gets TView from a template function or creates a new TView
|
|
12433
|
-
* if it doesn't already exist.
|
|
12434
|
-
*
|
|
12435
|
-
* @param def ComponentDef
|
|
12436
|
-
* @returns TView
|
|
12437
|
-
*/
|
|
12438
|
-
function getOrCreateComponentTView(def) {
|
|
12439
|
-
const tView = def.tView;
|
|
12440
|
-
// Create a TView if there isn't one, or recreate it if the first create pass didn't
|
|
12441
|
-
// complete successfully since we can't know for sure whether it's in a usable shape.
|
|
12442
|
-
if (tView === null || tView.incompleteFirstPass) {
|
|
12443
|
-
// Declaration node here is null since this function is called when we dynamically create a
|
|
12444
|
-
// component and hence there is no declaration.
|
|
12445
|
-
const declTNode = null;
|
|
12446
|
-
return (def.tView = createTView(1 /* TViewType.Component */, declTNode, def.template, def.decls, def.vars, def.directiveDefs, def.pipeDefs, def.viewQuery, def.schemas, def.consts, def.id));
|
|
12447
|
-
}
|
|
12448
|
-
return tView;
|
|
12449
|
-
}
|
|
12450
|
-
/**
|
|
12451
|
-
* Creates a TView instance
|
|
12452
|
-
*
|
|
12453
|
-
* @param type Type of `TView`.
|
|
12454
|
-
* @param declTNode Declaration location of this `TView`.
|
|
12455
|
-
* @param templateFn Template function
|
|
12456
|
-
* @param decls The number of nodes, local refs, and pipes in this template
|
|
12457
|
-
* @param directives Registry of directives for this view
|
|
12458
|
-
* @param pipes Registry of pipes for this view
|
|
12459
|
-
* @param viewQuery View queries for this view
|
|
12460
|
-
* @param schemas Schemas for this view
|
|
12461
|
-
* @param consts Constants for this view
|
|
12462
|
-
*/
|
|
12463
|
-
function createTView(type, declTNode, templateFn, decls, vars, directives, pipes, viewQuery, schemas, constsOrFactory, ssrId) {
|
|
12464
|
-
ngDevMode && ngDevMode.tView++;
|
|
12465
|
-
const bindingStartIndex = HEADER_OFFSET + decls;
|
|
12466
|
-
// This length does not yet contain host bindings from child directives because at this point,
|
|
12467
|
-
// we don't know which directives are active on this template. As soon as a directive is matched
|
|
12468
|
-
// that has a host binding, we will update the blueprint with that def's hostVars count.
|
|
12469
|
-
const initialViewLength = bindingStartIndex + vars;
|
|
12470
|
-
const blueprint = createViewBlueprint(bindingStartIndex, initialViewLength);
|
|
12471
|
-
const consts = typeof constsOrFactory === 'function' ? constsOrFactory() : constsOrFactory;
|
|
12472
|
-
const tView = (blueprint[TVIEW] = {
|
|
12473
|
-
type: type,
|
|
12474
|
-
blueprint: blueprint,
|
|
12475
|
-
template: templateFn,
|
|
12476
|
-
queries: null,
|
|
12477
|
-
viewQuery: viewQuery,
|
|
12478
|
-
declTNode: declTNode,
|
|
12479
|
-
data: blueprint.slice().fill(null, bindingStartIndex),
|
|
12480
|
-
bindingStartIndex: bindingStartIndex,
|
|
12481
|
-
expandoStartIndex: initialViewLength,
|
|
12482
|
-
hostBindingOpCodes: null,
|
|
12483
|
-
firstCreatePass: true,
|
|
12484
|
-
firstUpdatePass: true,
|
|
12485
|
-
staticViewQueries: false,
|
|
12486
|
-
staticContentQueries: false,
|
|
12487
|
-
preOrderHooks: null,
|
|
12488
|
-
preOrderCheckHooks: null,
|
|
12489
|
-
contentHooks: null,
|
|
12490
|
-
contentCheckHooks: null,
|
|
12491
|
-
viewHooks: null,
|
|
12492
|
-
viewCheckHooks: null,
|
|
12493
|
-
destroyHooks: null,
|
|
12494
|
-
cleanup: null,
|
|
12495
|
-
contentQueries: null,
|
|
12496
|
-
components: null,
|
|
12497
|
-
directiveRegistry: typeof directives === 'function' ? directives() : directives,
|
|
12498
|
-
pipeRegistry: typeof pipes === 'function' ? pipes() : pipes,
|
|
12499
|
-
firstChild: null,
|
|
12500
|
-
schemas: schemas,
|
|
12501
|
-
consts: consts,
|
|
12502
|
-
incompleteFirstPass: false,
|
|
12503
|
-
ssrId,
|
|
12504
|
-
});
|
|
12505
|
-
if (ngDevMode) {
|
|
12506
|
-
// For performance reasons it is important that the tView retains the same shape during runtime.
|
|
12507
|
-
// (To make sure that all of the code is monomorphic.) For this reason we seal the object to
|
|
12508
|
-
// prevent class transitions.
|
|
12509
|
-
Object.seal(tView);
|
|
12510
|
-
}
|
|
12511
|
-
return tView;
|
|
12512
|
-
}
|
|
12513
|
-
function createViewBlueprint(bindingStartIndex, initialViewLength) {
|
|
12514
|
-
const blueprint = [];
|
|
12515
|
-
for (let i = 0; i < initialViewLength; i++) {
|
|
12516
|
-
blueprint.push(i < bindingStartIndex ? null : NO_CHANGE);
|
|
12517
|
-
}
|
|
12518
|
-
return blueprint;
|
|
12519
|
-
}
|
|
12520
12597
|
/**
|
|
12521
12598
|
* Locates the host native element, used for bootstrapping existing nodes into rendering pipeline.
|
|
12522
12599
|
*
|
|
@@ -12608,7 +12685,6 @@ function mapPropName(name) {
|
|
|
12608
12685
|
}
|
|
12609
12686
|
function elementPropertyInternal(tView, tNode, lView, propName, value, renderer, sanitizer, nativeOnly) {
|
|
12610
12687
|
ngDevMode && assertNotSame(value, NO_CHANGE, 'Incoming value should never be NO_CHANGE.');
|
|
12611
|
-
const element = getNativeByTNode(tNode, lView);
|
|
12612
12688
|
let inputData = tNode.inputs;
|
|
12613
12689
|
let dataValue;
|
|
12614
12690
|
if (!nativeOnly && inputData != null && (dataValue = inputData[propName])) {
|
|
@@ -12616,10 +12692,11 @@ function elementPropertyInternal(tView, tNode, lView, propName, value, renderer,
|
|
|
12616
12692
|
if (isComponentHost(tNode))
|
|
12617
12693
|
markDirtyIfOnPush(lView, tNode.index);
|
|
12618
12694
|
if (ngDevMode) {
|
|
12619
|
-
setNgReflectProperties(lView,
|
|
12695
|
+
setNgReflectProperties(lView, tView, tNode, dataValue, value);
|
|
12620
12696
|
}
|
|
12621
12697
|
}
|
|
12622
12698
|
else if (tNode.type & 3 /* TNodeType.AnyRNode */) {
|
|
12699
|
+
const element = getNativeByTNode(tNode, lView);
|
|
12623
12700
|
propName = mapPropName(propName);
|
|
12624
12701
|
if (ngDevMode) {
|
|
12625
12702
|
validateAgainstEventProperties(propName);
|
|
@@ -12649,11 +12726,12 @@ function markDirtyIfOnPush(lView, viewIndex) {
|
|
|
12649
12726
|
childComponentLView[FLAGS] |= 64 /* LViewFlags.Dirty */;
|
|
12650
12727
|
}
|
|
12651
12728
|
}
|
|
12652
|
-
function setNgReflectProperty(lView,
|
|
12729
|
+
function setNgReflectProperty(lView, tNode, attrName, value) {
|
|
12730
|
+
const element = getNativeByTNode(tNode, lView);
|
|
12653
12731
|
const renderer = lView[RENDERER];
|
|
12654
12732
|
attrName = normalizeDebugBindingName(attrName);
|
|
12655
12733
|
const debugValue = normalizeDebugBindingValue(value);
|
|
12656
|
-
if (type & 3 /* TNodeType.AnyRNode */) {
|
|
12734
|
+
if (tNode.type & 3 /* TNodeType.AnyRNode */) {
|
|
12657
12735
|
if (value == null) {
|
|
12658
12736
|
renderer.removeAttribute(element, attrName);
|
|
12659
12737
|
}
|
|
@@ -12666,18 +12744,14 @@ function setNgReflectProperty(lView, element, type, attrName, value) {
|
|
|
12666
12744
|
renderer.setValue(element, textContent);
|
|
12667
12745
|
}
|
|
12668
12746
|
}
|
|
12669
|
-
function setNgReflectProperties(lView,
|
|
12670
|
-
if (type & (3 /* TNodeType.AnyRNode */ | 4 /* TNodeType.Container */)) {
|
|
12671
|
-
|
|
12672
|
-
|
|
12673
|
-
|
|
12674
|
-
|
|
12675
|
-
|
|
12676
|
-
|
|
12677
|
-
* we want to set the reflected property with the privateName: dataValue[i+1]
|
|
12678
|
-
*/
|
|
12679
|
-
for (let i = 0; i < dataValue.length; i += 3) {
|
|
12680
|
-
setNgReflectProperty(lView, element, type, dataValue[i + 1], value);
|
|
12747
|
+
function setNgReflectProperties(lView, tView, tNode, inputConfig, value) {
|
|
12748
|
+
if (tNode.type & (3 /* TNodeType.AnyRNode */ | 4 /* TNodeType.Container */)) {
|
|
12749
|
+
// Note: we set the private name of the input as the reflected property, not the public one.
|
|
12750
|
+
for (let i = 0; i < inputConfig.length; i += 2) {
|
|
12751
|
+
const index = inputConfig[i];
|
|
12752
|
+
const lookupName = inputConfig[i + 1];
|
|
12753
|
+
const def = tView.data[index];
|
|
12754
|
+
setNgReflectProperty(lView, tNode, def.inputs[lookupName][0], value);
|
|
12681
12755
|
}
|
|
12682
12756
|
}
|
|
12683
12757
|
}
|
|
@@ -12774,31 +12848,6 @@ function findDirectiveDefMatches(tView, tNode) {
|
|
|
12774
12848
|
}
|
|
12775
12849
|
return matches;
|
|
12776
12850
|
}
|
|
12777
|
-
/**
|
|
12778
|
-
* Gets the initial set of LView flags based on the component definition that the LView represents.
|
|
12779
|
-
* @param def Component definition from which to determine the flags.
|
|
12780
|
-
*/
|
|
12781
|
-
function getInitialLViewFlagsFromDef(def) {
|
|
12782
|
-
let flags = 16 /* LViewFlags.CheckAlways */;
|
|
12783
|
-
if (def.signals) {
|
|
12784
|
-
flags = 4096 /* LViewFlags.SignalView */;
|
|
12785
|
-
}
|
|
12786
|
-
else if (def.onPush) {
|
|
12787
|
-
flags = 64 /* LViewFlags.Dirty */;
|
|
12788
|
-
}
|
|
12789
|
-
return flags;
|
|
12790
|
-
}
|
|
12791
|
-
function createComponentLView(lView, hostTNode, def) {
|
|
12792
|
-
const native = getNativeByTNode(hostTNode, lView);
|
|
12793
|
-
const tView = getOrCreateComponentTView(def);
|
|
12794
|
-
// Only component views should be added to the view tree directly. Embedded views are
|
|
12795
|
-
// accessed through their containers because they may be removed / re-added later.
|
|
12796
|
-
const rendererFactory = lView[ENVIRONMENT].rendererFactory;
|
|
12797
|
-
const componentView = addToEndOfViewTree(lView, createLView(lView, tView, null, getInitialLViewFlagsFromDef(def), native, hostTNode, null, rendererFactory.createRenderer(native, def), null, null, null));
|
|
12798
|
-
// Component view will always be created before any injected LContainers,
|
|
12799
|
-
// so this is a regular element, wrap it with the component view
|
|
12800
|
-
return (lView[hostTNode.index] = componentView);
|
|
12801
|
-
}
|
|
12802
12851
|
function elementAttributeInternal(tNode, lView, name, value, sanitizer, namespace) {
|
|
12803
12852
|
if (ngDevMode) {
|
|
12804
12853
|
assertNotSame(value, NO_CHANGE, 'Incoming value should never be NO_CHANGE.');
|
|
@@ -12832,75 +12881,16 @@ function setElementAttribute(renderer, element, namespace, tagName, name, value,
|
|
|
12832
12881
|
function setInputsFromAttrs(lView, directiveIndex, instance, def, tNode, initialInputData) {
|
|
12833
12882
|
const initialInputs = initialInputData[directiveIndex];
|
|
12834
12883
|
if (initialInputs !== null) {
|
|
12835
|
-
for (let i = 0; i < initialInputs.length;) {
|
|
12836
|
-
const
|
|
12837
|
-
const
|
|
12838
|
-
|
|
12839
|
-
const value = initialInputs[i++];
|
|
12840
|
-
writeToDirectiveInput(def, instance, publicName, privateName, flags, value);
|
|
12884
|
+
for (let i = 0; i < initialInputs.length; i += 2) {
|
|
12885
|
+
const lookupName = initialInputs[i];
|
|
12886
|
+
const value = initialInputs[i + 1];
|
|
12887
|
+
writeToDirectiveInput(def, instance, lookupName, value);
|
|
12841
12888
|
if (ngDevMode) {
|
|
12842
|
-
|
|
12843
|
-
setNgReflectProperty(lView, nativeElement, tNode.type, privateName, value);
|
|
12889
|
+
setNgReflectProperty(lView, tNode, def.inputs[lookupName][0], value);
|
|
12844
12890
|
}
|
|
12845
12891
|
}
|
|
12846
12892
|
}
|
|
12847
12893
|
}
|
|
12848
|
-
//////////////////////////
|
|
12849
|
-
//// ViewContainer & View
|
|
12850
|
-
//////////////////////////
|
|
12851
|
-
/**
|
|
12852
|
-
* Creates a LContainer, either from a container instruction, or for a ViewContainerRef.
|
|
12853
|
-
*
|
|
12854
|
-
* @param hostNative The host element for the LContainer
|
|
12855
|
-
* @param hostTNode The host TNode for the LContainer
|
|
12856
|
-
* @param currentView The parent view of the LContainer
|
|
12857
|
-
* @param native The native comment element
|
|
12858
|
-
* @param isForViewContainerRef Optional a flag indicating the ViewContainerRef case
|
|
12859
|
-
* @returns LContainer
|
|
12860
|
-
*/
|
|
12861
|
-
function createLContainer(hostNative, currentView, native, tNode) {
|
|
12862
|
-
ngDevMode && assertLView(currentView);
|
|
12863
|
-
const lContainer = [
|
|
12864
|
-
hostNative, // host native
|
|
12865
|
-
true, // Boolean `true` in this position signifies that this is an `LContainer`
|
|
12866
|
-
0, // flags
|
|
12867
|
-
currentView, // parent
|
|
12868
|
-
null, // next
|
|
12869
|
-
tNode, // t_host
|
|
12870
|
-
null, // dehydrated views
|
|
12871
|
-
native, // native,
|
|
12872
|
-
null, // view refs
|
|
12873
|
-
null, // moved views
|
|
12874
|
-
];
|
|
12875
|
-
ngDevMode &&
|
|
12876
|
-
assertEqual(lContainer.length, CONTAINER_HEADER_OFFSET, 'Should allocate correct number of slots for LContainer header.');
|
|
12877
|
-
return lContainer;
|
|
12878
|
-
}
|
|
12879
|
-
/**
|
|
12880
|
-
* Adds LView or LContainer to the end of the current view tree.
|
|
12881
|
-
*
|
|
12882
|
-
* This structure will be used to traverse through nested views to remove listeners
|
|
12883
|
-
* and call onDestroy callbacks.
|
|
12884
|
-
*
|
|
12885
|
-
* @param lView The view where LView or LContainer should be added
|
|
12886
|
-
* @param adjustedHostIndex Index of the view's host node in LView[], adjusted for header
|
|
12887
|
-
* @param lViewOrLContainer The LView or LContainer to add to the view tree
|
|
12888
|
-
* @returns The state passed in
|
|
12889
|
-
*/
|
|
12890
|
-
function addToEndOfViewTree(lView, lViewOrLContainer) {
|
|
12891
|
-
// TODO(benlesh/misko): This implementation is incorrect, because it always adds the LContainer
|
|
12892
|
-
// to the end of the queue, which means if the developer retrieves the LContainers from RNodes out
|
|
12893
|
-
// of order, the change detection will run out of order, as the act of retrieving the the
|
|
12894
|
-
// LContainer from the RNode is what adds it to the queue.
|
|
12895
|
-
if (lView[CHILD_HEAD]) {
|
|
12896
|
-
lView[CHILD_TAIL][NEXT] = lViewOrLContainer;
|
|
12897
|
-
}
|
|
12898
|
-
else {
|
|
12899
|
-
lView[CHILD_HEAD] = lViewOrLContainer;
|
|
12900
|
-
}
|
|
12901
|
-
lView[CHILD_TAIL] = lViewOrLContainer;
|
|
12902
|
-
return lViewOrLContainer;
|
|
12903
|
-
}
|
|
12904
12894
|
///////////////////////////////
|
|
12905
12895
|
//// Bindings & interpolations
|
|
12906
12896
|
///////////////////////////////
|
|
@@ -12974,14 +12964,13 @@ function handleError(lView, error) {
|
|
|
12974
12964
|
* @param value Value to set.
|
|
12975
12965
|
*/
|
|
12976
12966
|
function setInputsForProperty(tView, lView, inputs, publicName, value) {
|
|
12977
|
-
for (let i = 0; i < inputs.length;) {
|
|
12978
|
-
const index = inputs[i
|
|
12979
|
-
const privateName = inputs[i++];
|
|
12980
|
-
const flags = inputs[i++];
|
|
12981
|
-
const instance = lView[index];
|
|
12967
|
+
for (let i = 0; i < inputs.length; i += 2) {
|
|
12968
|
+
const index = inputs[i];
|
|
12982
12969
|
ngDevMode && assertIndexInRange(lView, index);
|
|
12970
|
+
const privateName = inputs[i + 1];
|
|
12971
|
+
const instance = lView[index];
|
|
12983
12972
|
const def = tView.data[index];
|
|
12984
|
-
writeToDirectiveInput(def, instance,
|
|
12973
|
+
writeToDirectiveInput(def, instance, privateName, value);
|
|
12985
12974
|
}
|
|
12986
12975
|
}
|
|
12987
12976
|
|
|
@@ -13103,24 +13092,41 @@ function renderChildComponents(hostLView, components) {
|
|
|
13103
13092
|
}
|
|
13104
13093
|
}
|
|
13105
13094
|
|
|
13095
|
+
function createAndRenderEmbeddedLView(declarationLView, templateTNode, context, options) {
|
|
13096
|
+
const prevConsumer = setActiveConsumer$1(null);
|
|
13097
|
+
try {
|
|
13098
|
+
const embeddedTView = templateTNode.tView;
|
|
13099
|
+
ngDevMode && assertDefined(embeddedTView, 'TView must be defined for a template node.');
|
|
13100
|
+
ngDevMode && assertTNodeForLView(templateTNode, declarationLView);
|
|
13101
|
+
// Embedded views follow the change detection strategy of the view they're declared in.
|
|
13102
|
+
const isSignalView = declarationLView[FLAGS] & 4096 /* LViewFlags.SignalView */;
|
|
13103
|
+
const viewFlags = isSignalView ? 4096 /* LViewFlags.SignalView */ : 16 /* LViewFlags.CheckAlways */;
|
|
13104
|
+
const embeddedLView = createLView(declarationLView, embeddedTView, context, viewFlags, null, templateTNode, null, null, options?.injector ?? null, options?.embeddedViewInjector ?? null, options?.dehydratedView ?? null);
|
|
13105
|
+
const declarationLContainer = declarationLView[templateTNode.index];
|
|
13106
|
+
ngDevMode && assertLContainer(declarationLContainer);
|
|
13107
|
+
embeddedLView[DECLARATION_LCONTAINER] = declarationLContainer;
|
|
13108
|
+
const declarationViewLQueries = declarationLView[QUERIES];
|
|
13109
|
+
if (declarationViewLQueries !== null) {
|
|
13110
|
+
embeddedLView[QUERIES] = declarationViewLQueries.createEmbeddedView(embeddedTView);
|
|
13111
|
+
}
|
|
13112
|
+
// execute creation mode of a view
|
|
13113
|
+
renderView(embeddedTView, embeddedLView, context);
|
|
13114
|
+
return embeddedLView;
|
|
13115
|
+
}
|
|
13116
|
+
finally {
|
|
13117
|
+
setActiveConsumer$1(prevConsumer);
|
|
13118
|
+
}
|
|
13119
|
+
}
|
|
13106
13120
|
/**
|
|
13107
|
-
*
|
|
13108
|
-
*
|
|
13121
|
+
* Returns whether an elements that belong to a view should be
|
|
13122
|
+
* inserted into the DOM. For client-only cases, DOM elements are
|
|
13123
|
+
* always inserted. For hydration cases, we check whether serialized
|
|
13124
|
+
* info is available for a view and the view is not in a "skip hydration"
|
|
13125
|
+
* block (in which case view contents was re-created, thus needing insertion).
|
|
13109
13126
|
*/
|
|
13110
|
-
|
|
13111
|
-
(
|
|
13112
|
-
|
|
13113
|
-
// `node_manipulation.ts` Currently doing the import cause resolution order to change and fails
|
|
13114
|
-
// the tests. The work around is to have hard coded value in `node_manipulation.ts` for now.
|
|
13115
|
-
/**
|
|
13116
|
-
* Marks a style as important.
|
|
13117
|
-
*/
|
|
13118
|
-
RendererStyleFlags2[RendererStyleFlags2["Important"] = 1] = "Important";
|
|
13119
|
-
/**
|
|
13120
|
-
* Marks a style as using dash case naming (this-is-dash-case).
|
|
13121
|
-
*/
|
|
13122
|
-
RendererStyleFlags2[RendererStyleFlags2["DashCase"] = 2] = "DashCase";
|
|
13123
|
-
})(RendererStyleFlags2 || (RendererStyleFlags2 = {}));
|
|
13127
|
+
function shouldAddViewToDom(tNode, dehydratedView) {
|
|
13128
|
+
return (!dehydratedView || dehydratedView.firstChild === null || hasInSkipHydrationBlockFlag(tNode));
|
|
13129
|
+
}
|
|
13124
13130
|
|
|
13125
13131
|
let _icuContainerIterate;
|
|
13126
13132
|
/**
|
|
@@ -13143,6 +13149,25 @@ function ensureIcuContainerVisitorLoaded(loader) {
|
|
|
13143
13149
|
}
|
|
13144
13150
|
}
|
|
13145
13151
|
|
|
13152
|
+
/**
|
|
13153
|
+
* Flags for renderer-specific style modifiers.
|
|
13154
|
+
* @publicApi
|
|
13155
|
+
*/
|
|
13156
|
+
var RendererStyleFlags2;
|
|
13157
|
+
(function (RendererStyleFlags2) {
|
|
13158
|
+
// TODO(misko): This needs to be refactored into a separate file so that it can be imported from
|
|
13159
|
+
// `node_manipulation.ts` Currently doing the import cause resolution order to change and fails
|
|
13160
|
+
// the tests. The work around is to have hard coded value in `node_manipulation.ts` for now.
|
|
13161
|
+
/**
|
|
13162
|
+
* Marks a style as important.
|
|
13163
|
+
*/
|
|
13164
|
+
RendererStyleFlags2[RendererStyleFlags2["Important"] = 1] = "Important";
|
|
13165
|
+
/**
|
|
13166
|
+
* Marks a style as using dash case naming (this-is-dash-case).
|
|
13167
|
+
*/
|
|
13168
|
+
RendererStyleFlags2[RendererStyleFlags2["DashCase"] = 2] = "DashCase";
|
|
13169
|
+
})(RendererStyleFlags2 || (RendererStyleFlags2 = {}));
|
|
13170
|
+
|
|
13146
13171
|
/**
|
|
13147
13172
|
* Checks whether a TNode is considered detached, i.e. not present in the
|
|
13148
13173
|
* translated i18n template. We should not attempt hydration for such nodes
|
|
@@ -13297,83 +13322,6 @@ function destroyViewTree(rootView) {
|
|
|
13297
13322
|
lViewOrLContainer = next;
|
|
13298
13323
|
}
|
|
13299
13324
|
}
|
|
13300
|
-
/**
|
|
13301
|
-
* Inserts a view into a container.
|
|
13302
|
-
*
|
|
13303
|
-
* This adds the view to the container's array of active views in the correct
|
|
13304
|
-
* position. It also adds the view's elements to the DOM if the container isn't a
|
|
13305
|
-
* root node of another view (in that case, the view's elements will be added when
|
|
13306
|
-
* the container's parent view is added later).
|
|
13307
|
-
*
|
|
13308
|
-
* @param tView The `TView' of the `LView` to insert
|
|
13309
|
-
* @param lView The view to insert
|
|
13310
|
-
* @param lContainer The container into which the view should be inserted
|
|
13311
|
-
* @param index Which index in the container to insert the child view into
|
|
13312
|
-
*/
|
|
13313
|
-
function insertView(tView, lView, lContainer, index) {
|
|
13314
|
-
ngDevMode && assertLView(lView);
|
|
13315
|
-
ngDevMode && assertLContainer(lContainer);
|
|
13316
|
-
const indexInContainer = CONTAINER_HEADER_OFFSET + index;
|
|
13317
|
-
const containerLength = lContainer.length;
|
|
13318
|
-
if (index > 0) {
|
|
13319
|
-
// This is a new view, we need to add it to the children.
|
|
13320
|
-
lContainer[indexInContainer - 1][NEXT] = lView;
|
|
13321
|
-
}
|
|
13322
|
-
if (index < containerLength - CONTAINER_HEADER_OFFSET) {
|
|
13323
|
-
lView[NEXT] = lContainer[indexInContainer];
|
|
13324
|
-
addToArray(lContainer, CONTAINER_HEADER_OFFSET + index, lView);
|
|
13325
|
-
}
|
|
13326
|
-
else {
|
|
13327
|
-
lContainer.push(lView);
|
|
13328
|
-
lView[NEXT] = null;
|
|
13329
|
-
}
|
|
13330
|
-
lView[PARENT] = lContainer;
|
|
13331
|
-
// track views where declaration and insertion points are different
|
|
13332
|
-
const declarationLContainer = lView[DECLARATION_LCONTAINER];
|
|
13333
|
-
if (declarationLContainer !== null && lContainer !== declarationLContainer) {
|
|
13334
|
-
trackMovedView(declarationLContainer, lView);
|
|
13335
|
-
}
|
|
13336
|
-
// notify query that a new view has been added
|
|
13337
|
-
const lQueries = lView[QUERIES];
|
|
13338
|
-
if (lQueries !== null) {
|
|
13339
|
-
lQueries.insertView(tView);
|
|
13340
|
-
}
|
|
13341
|
-
updateAncestorTraversalFlagsOnAttach(lView);
|
|
13342
|
-
// Sets the attached flag
|
|
13343
|
-
lView[FLAGS] |= 128 /* LViewFlags.Attached */;
|
|
13344
|
-
}
|
|
13345
|
-
/**
|
|
13346
|
-
* Track views created from the declaration container (TemplateRef) and inserted into a
|
|
13347
|
-
* different LContainer or attached directly to ApplicationRef.
|
|
13348
|
-
*/
|
|
13349
|
-
function trackMovedView(declarationContainer, lView) {
|
|
13350
|
-
ngDevMode && assertDefined(lView, 'LView required');
|
|
13351
|
-
ngDevMode && assertLContainer(declarationContainer);
|
|
13352
|
-
const movedViews = declarationContainer[MOVED_VIEWS];
|
|
13353
|
-
const parent = lView[PARENT];
|
|
13354
|
-
ngDevMode && assertDefined(parent, 'missing parent');
|
|
13355
|
-
if (isLView(parent)) {
|
|
13356
|
-
declarationContainer[FLAGS] |= 2 /* LContainerFlags.HasTransplantedViews */;
|
|
13357
|
-
}
|
|
13358
|
-
else {
|
|
13359
|
-
const insertedComponentLView = parent[PARENT][DECLARATION_COMPONENT_VIEW];
|
|
13360
|
-
ngDevMode && assertDefined(insertedComponentLView, 'Missing insertedComponentLView');
|
|
13361
|
-
const declaredComponentLView = lView[DECLARATION_COMPONENT_VIEW];
|
|
13362
|
-
ngDevMode && assertDefined(declaredComponentLView, 'Missing declaredComponentLView');
|
|
13363
|
-
if (declaredComponentLView !== insertedComponentLView) {
|
|
13364
|
-
// At this point the declaration-component is not same as insertion-component; this means that
|
|
13365
|
-
// this is a transplanted view. Mark the declared lView as having transplanted views so that
|
|
13366
|
-
// those views can participate in CD.
|
|
13367
|
-
declarationContainer[FLAGS] |= 2 /* LContainerFlags.HasTransplantedViews */;
|
|
13368
|
-
}
|
|
13369
|
-
}
|
|
13370
|
-
if (movedViews === null) {
|
|
13371
|
-
declarationContainer[MOVED_VIEWS] = [lView];
|
|
13372
|
-
}
|
|
13373
|
-
else {
|
|
13374
|
-
movedViews.push(lView);
|
|
13375
|
-
}
|
|
13376
|
-
}
|
|
13377
13325
|
function detachMovedView(declarationContainer, lView) {
|
|
13378
13326
|
ngDevMode && assertLContainer(declarationContainer);
|
|
13379
13327
|
ngDevMode &&
|
|
@@ -13382,43 +13330,6 @@ function detachMovedView(declarationContainer, lView) {
|
|
|
13382
13330
|
const declarationViewIndex = movedViews.indexOf(lView);
|
|
13383
13331
|
movedViews.splice(declarationViewIndex, 1);
|
|
13384
13332
|
}
|
|
13385
|
-
/**
|
|
13386
|
-
* Detaches a view from a container.
|
|
13387
|
-
*
|
|
13388
|
-
* This method removes the view from the container's array of active views. It also
|
|
13389
|
-
* removes the view's elements from the DOM.
|
|
13390
|
-
*
|
|
13391
|
-
* @param lContainer The container from which to detach a view
|
|
13392
|
-
* @param removeIndex The index of the view to detach
|
|
13393
|
-
* @returns Detached LView instance.
|
|
13394
|
-
*/
|
|
13395
|
-
function detachView(lContainer, removeIndex) {
|
|
13396
|
-
if (lContainer.length <= CONTAINER_HEADER_OFFSET)
|
|
13397
|
-
return;
|
|
13398
|
-
const indexInContainer = CONTAINER_HEADER_OFFSET + removeIndex;
|
|
13399
|
-
const viewToDetach = lContainer[indexInContainer];
|
|
13400
|
-
if (viewToDetach) {
|
|
13401
|
-
const declarationLContainer = viewToDetach[DECLARATION_LCONTAINER];
|
|
13402
|
-
if (declarationLContainer !== null && declarationLContainer !== lContainer) {
|
|
13403
|
-
detachMovedView(declarationLContainer, viewToDetach);
|
|
13404
|
-
}
|
|
13405
|
-
if (removeIndex > 0) {
|
|
13406
|
-
lContainer[indexInContainer - 1][NEXT] = viewToDetach[NEXT];
|
|
13407
|
-
}
|
|
13408
|
-
const removedLView = removeFromArray(lContainer, CONTAINER_HEADER_OFFSET + removeIndex);
|
|
13409
|
-
removeViewFromDOM(viewToDetach[TVIEW], viewToDetach);
|
|
13410
|
-
// notify query that a view has been removed
|
|
13411
|
-
const lQueries = removedLView[QUERIES];
|
|
13412
|
-
if (lQueries !== null) {
|
|
13413
|
-
lQueries.detachView(removedLView[TVIEW]);
|
|
13414
|
-
}
|
|
13415
|
-
viewToDetach[PARENT] = null;
|
|
13416
|
-
viewToDetach[NEXT] = null;
|
|
13417
|
-
// Unsets the attached flag
|
|
13418
|
-
viewToDetach[FLAGS] &= ~128 /* LViewFlags.Attached */;
|
|
13419
|
-
}
|
|
13420
|
-
return viewToDetach;
|
|
13421
|
-
}
|
|
13422
13333
|
/**
|
|
13423
13334
|
* A standalone function which destroys an LView,
|
|
13424
13335
|
* conducting clean up (e.g. removing listeners, calling onDestroys).
|
|
@@ -13985,80 +13896,6 @@ function applyStyling(renderer, isClassBased, rNode, prop, value) {
|
|
|
13985
13896
|
}
|
|
13986
13897
|
}
|
|
13987
13898
|
|
|
13988
|
-
function createAndRenderEmbeddedLView(declarationLView, templateTNode, context, options) {
|
|
13989
|
-
const prevConsumer = setActiveConsumer$1(null);
|
|
13990
|
-
try {
|
|
13991
|
-
const embeddedTView = templateTNode.tView;
|
|
13992
|
-
ngDevMode && assertDefined(embeddedTView, 'TView must be defined for a template node.');
|
|
13993
|
-
ngDevMode && assertTNodeForLView(templateTNode, declarationLView);
|
|
13994
|
-
// Embedded views follow the change detection strategy of the view they're declared in.
|
|
13995
|
-
const isSignalView = declarationLView[FLAGS] & 4096 /* LViewFlags.SignalView */;
|
|
13996
|
-
const viewFlags = isSignalView ? 4096 /* LViewFlags.SignalView */ : 16 /* LViewFlags.CheckAlways */;
|
|
13997
|
-
const embeddedLView = createLView(declarationLView, embeddedTView, context, viewFlags, null, templateTNode, null, null, options?.injector ?? null, options?.embeddedViewInjector ?? null, options?.dehydratedView ?? null);
|
|
13998
|
-
const declarationLContainer = declarationLView[templateTNode.index];
|
|
13999
|
-
ngDevMode && assertLContainer(declarationLContainer);
|
|
14000
|
-
embeddedLView[DECLARATION_LCONTAINER] = declarationLContainer;
|
|
14001
|
-
const declarationViewLQueries = declarationLView[QUERIES];
|
|
14002
|
-
if (declarationViewLQueries !== null) {
|
|
14003
|
-
embeddedLView[QUERIES] = declarationViewLQueries.createEmbeddedView(embeddedTView);
|
|
14004
|
-
}
|
|
14005
|
-
// execute creation mode of a view
|
|
14006
|
-
renderView(embeddedTView, embeddedLView, context);
|
|
14007
|
-
return embeddedLView;
|
|
14008
|
-
}
|
|
14009
|
-
finally {
|
|
14010
|
-
setActiveConsumer$1(prevConsumer);
|
|
14011
|
-
}
|
|
14012
|
-
}
|
|
14013
|
-
function getLViewFromLContainer(lContainer, index) {
|
|
14014
|
-
const adjustedIndex = CONTAINER_HEADER_OFFSET + index;
|
|
14015
|
-
// avoid reading past the array boundaries
|
|
14016
|
-
if (adjustedIndex < lContainer.length) {
|
|
14017
|
-
const lView = lContainer[adjustedIndex];
|
|
14018
|
-
ngDevMode && assertLView(lView);
|
|
14019
|
-
return lView;
|
|
14020
|
-
}
|
|
14021
|
-
return undefined;
|
|
14022
|
-
}
|
|
14023
|
-
/**
|
|
14024
|
-
* Returns whether an elements that belong to a view should be
|
|
14025
|
-
* inserted into the DOM. For client-only cases, DOM elements are
|
|
14026
|
-
* always inserted. For hydration cases, we check whether serialized
|
|
14027
|
-
* info is available for a view and the view is not in a "skip hydration"
|
|
14028
|
-
* block (in which case view contents was re-created, thus needing insertion).
|
|
14029
|
-
*/
|
|
14030
|
-
function shouldAddViewToDom(tNode, dehydratedView) {
|
|
14031
|
-
return (!dehydratedView || dehydratedView.firstChild === null || hasInSkipHydrationBlockFlag(tNode));
|
|
14032
|
-
}
|
|
14033
|
-
function addLViewToLContainer(lContainer, lView, index, addToDOM = true) {
|
|
14034
|
-
const tView = lView[TVIEW];
|
|
14035
|
-
// Insert into the view tree so the new view can be change-detected
|
|
14036
|
-
insertView(tView, lView, lContainer, index);
|
|
14037
|
-
// Insert elements that belong to this view into the DOM tree
|
|
14038
|
-
if (addToDOM) {
|
|
14039
|
-
const beforeNode = getBeforeNodeForView(index, lContainer);
|
|
14040
|
-
const renderer = lView[RENDERER];
|
|
14041
|
-
const parentRNode = renderer.parentNode(lContainer[NATIVE]);
|
|
14042
|
-
if (parentRNode !== null) {
|
|
14043
|
-
addViewToDOM(tView, lContainer[T_HOST], renderer, lView, parentRNode, beforeNode);
|
|
14044
|
-
}
|
|
14045
|
-
}
|
|
14046
|
-
// When in hydration mode, reset the pointer to the first child in
|
|
14047
|
-
// the dehydrated view. This indicates that the view was hydrated and
|
|
14048
|
-
// further attaching/detaching should work with this view as normal.
|
|
14049
|
-
const hydrationInfo = lView[HYDRATION];
|
|
14050
|
-
if (hydrationInfo !== null && hydrationInfo.firstChild !== null) {
|
|
14051
|
-
hydrationInfo.firstChild = null;
|
|
14052
|
-
}
|
|
14053
|
-
}
|
|
14054
|
-
function removeLViewFromLContainer(lContainer, index) {
|
|
14055
|
-
const lView = detachView(lContainer, index);
|
|
14056
|
-
if (lView !== undefined) {
|
|
14057
|
-
destroyLView(lView[TVIEW], lView);
|
|
14058
|
-
}
|
|
14059
|
-
return lView;
|
|
14060
|
-
}
|
|
14061
|
-
|
|
14062
13899
|
function collectNativeNodes(tView, lView, tNode, result, isProjection = false) {
|
|
14063
13900
|
while (tNode !== null) {
|
|
14064
13901
|
// Let declarations don't have corresponding DOM nodes so we skip over them.
|
|
@@ -14697,6 +14534,187 @@ function markViewDirty(lView, source) {
|
|
|
14697
14534
|
return null;
|
|
14698
14535
|
}
|
|
14699
14536
|
|
|
14537
|
+
/**
|
|
14538
|
+
* Creates a LContainer, either from a container instruction, or for a ViewContainerRef.
|
|
14539
|
+
*
|
|
14540
|
+
* @param hostNative The host element for the LContainer
|
|
14541
|
+
* @param hostTNode The host TNode for the LContainer
|
|
14542
|
+
* @param currentView The parent view of the LContainer
|
|
14543
|
+
* @param native The native comment element
|
|
14544
|
+
* @param isForViewContainerRef Optional a flag indicating the ViewContainerRef case
|
|
14545
|
+
* @returns LContainer
|
|
14546
|
+
*/
|
|
14547
|
+
function createLContainer(hostNative, currentView, native, tNode) {
|
|
14548
|
+
ngDevMode && assertLView(currentView);
|
|
14549
|
+
const lContainer = [
|
|
14550
|
+
hostNative, // host native
|
|
14551
|
+
true, // Boolean `true` in this position signifies that this is an `LContainer`
|
|
14552
|
+
0, // flags
|
|
14553
|
+
currentView, // parent
|
|
14554
|
+
null, // next
|
|
14555
|
+
tNode, // t_host
|
|
14556
|
+
null, // dehydrated views
|
|
14557
|
+
native, // native,
|
|
14558
|
+
null, // view refs
|
|
14559
|
+
null, // moved views
|
|
14560
|
+
];
|
|
14561
|
+
ngDevMode &&
|
|
14562
|
+
assertEqual(lContainer.length, CONTAINER_HEADER_OFFSET, 'Should allocate correct number of slots for LContainer header.');
|
|
14563
|
+
return lContainer;
|
|
14564
|
+
}
|
|
14565
|
+
function getLViewFromLContainer(lContainer, index) {
|
|
14566
|
+
const adjustedIndex = CONTAINER_HEADER_OFFSET + index;
|
|
14567
|
+
// avoid reading past the array boundaries
|
|
14568
|
+
if (adjustedIndex < lContainer.length) {
|
|
14569
|
+
const lView = lContainer[adjustedIndex];
|
|
14570
|
+
ngDevMode && assertLView(lView);
|
|
14571
|
+
return lView;
|
|
14572
|
+
}
|
|
14573
|
+
return undefined;
|
|
14574
|
+
}
|
|
14575
|
+
function addLViewToLContainer(lContainer, lView, index, addToDOM = true) {
|
|
14576
|
+
const tView = lView[TVIEW];
|
|
14577
|
+
// Insert into the view tree so the new view can be change-detected
|
|
14578
|
+
insertView(tView, lView, lContainer, index);
|
|
14579
|
+
// Insert elements that belong to this view into the DOM tree
|
|
14580
|
+
if (addToDOM) {
|
|
14581
|
+
const beforeNode = getBeforeNodeForView(index, lContainer);
|
|
14582
|
+
const renderer = lView[RENDERER];
|
|
14583
|
+
const parentRNode = renderer.parentNode(lContainer[NATIVE]);
|
|
14584
|
+
if (parentRNode !== null) {
|
|
14585
|
+
addViewToDOM(tView, lContainer[T_HOST], renderer, lView, parentRNode, beforeNode);
|
|
14586
|
+
}
|
|
14587
|
+
}
|
|
14588
|
+
// When in hydration mode, reset the pointer to the first child in
|
|
14589
|
+
// the dehydrated view. This indicates that the view was hydrated and
|
|
14590
|
+
// further attaching/detaching should work with this view as normal.
|
|
14591
|
+
const hydrationInfo = lView[HYDRATION];
|
|
14592
|
+
if (hydrationInfo !== null && hydrationInfo.firstChild !== null) {
|
|
14593
|
+
hydrationInfo.firstChild = null;
|
|
14594
|
+
}
|
|
14595
|
+
}
|
|
14596
|
+
function removeLViewFromLContainer(lContainer, index) {
|
|
14597
|
+
const lView = detachView(lContainer, index);
|
|
14598
|
+
if (lView !== undefined) {
|
|
14599
|
+
destroyLView(lView[TVIEW], lView);
|
|
14600
|
+
}
|
|
14601
|
+
return lView;
|
|
14602
|
+
}
|
|
14603
|
+
/**
|
|
14604
|
+
* Detaches a view from a container.
|
|
14605
|
+
*
|
|
14606
|
+
* This method removes the view from the container's array of active views. It also
|
|
14607
|
+
* removes the view's elements from the DOM.
|
|
14608
|
+
*
|
|
14609
|
+
* @param lContainer The container from which to detach a view
|
|
14610
|
+
* @param removeIndex The index of the view to detach
|
|
14611
|
+
* @returns Detached LView instance.
|
|
14612
|
+
*/
|
|
14613
|
+
function detachView(lContainer, removeIndex) {
|
|
14614
|
+
if (lContainer.length <= CONTAINER_HEADER_OFFSET)
|
|
14615
|
+
return;
|
|
14616
|
+
const indexInContainer = CONTAINER_HEADER_OFFSET + removeIndex;
|
|
14617
|
+
const viewToDetach = lContainer[indexInContainer];
|
|
14618
|
+
if (viewToDetach) {
|
|
14619
|
+
const declarationLContainer = viewToDetach[DECLARATION_LCONTAINER];
|
|
14620
|
+
if (declarationLContainer !== null && declarationLContainer !== lContainer) {
|
|
14621
|
+
detachMovedView(declarationLContainer, viewToDetach);
|
|
14622
|
+
}
|
|
14623
|
+
if (removeIndex > 0) {
|
|
14624
|
+
lContainer[indexInContainer - 1][NEXT] = viewToDetach[NEXT];
|
|
14625
|
+
}
|
|
14626
|
+
const removedLView = removeFromArray(lContainer, CONTAINER_HEADER_OFFSET + removeIndex);
|
|
14627
|
+
removeViewFromDOM(viewToDetach[TVIEW], viewToDetach);
|
|
14628
|
+
// notify query that a view has been removed
|
|
14629
|
+
const lQueries = removedLView[QUERIES];
|
|
14630
|
+
if (lQueries !== null) {
|
|
14631
|
+
lQueries.detachView(removedLView[TVIEW]);
|
|
14632
|
+
}
|
|
14633
|
+
viewToDetach[PARENT] = null;
|
|
14634
|
+
viewToDetach[NEXT] = null;
|
|
14635
|
+
// Unsets the attached flag
|
|
14636
|
+
viewToDetach[FLAGS] &= ~128 /* LViewFlags.Attached */;
|
|
14637
|
+
}
|
|
14638
|
+
return viewToDetach;
|
|
14639
|
+
}
|
|
14640
|
+
/**
|
|
14641
|
+
* Inserts a view into a container.
|
|
14642
|
+
*
|
|
14643
|
+
* This adds the view to the container's array of active views in the correct
|
|
14644
|
+
* position. It also adds the view's elements to the DOM if the container isn't a
|
|
14645
|
+
* root node of another view (in that case, the view's elements will be added when
|
|
14646
|
+
* the container's parent view is added later).
|
|
14647
|
+
*
|
|
14648
|
+
* @param tView The `TView' of the `LView` to insert
|
|
14649
|
+
* @param lView The view to insert
|
|
14650
|
+
* @param lContainer The container into which the view should be inserted
|
|
14651
|
+
* @param index Which index in the container to insert the child view into
|
|
14652
|
+
*/
|
|
14653
|
+
function insertView(tView, lView, lContainer, index) {
|
|
14654
|
+
ngDevMode && assertLView(lView);
|
|
14655
|
+
ngDevMode && assertLContainer(lContainer);
|
|
14656
|
+
const indexInContainer = CONTAINER_HEADER_OFFSET + index;
|
|
14657
|
+
const containerLength = lContainer.length;
|
|
14658
|
+
if (index > 0) {
|
|
14659
|
+
// This is a new view, we need to add it to the children.
|
|
14660
|
+
lContainer[indexInContainer - 1][NEXT] = lView;
|
|
14661
|
+
}
|
|
14662
|
+
if (index < containerLength - CONTAINER_HEADER_OFFSET) {
|
|
14663
|
+
lView[NEXT] = lContainer[indexInContainer];
|
|
14664
|
+
addToArray(lContainer, CONTAINER_HEADER_OFFSET + index, lView);
|
|
14665
|
+
}
|
|
14666
|
+
else {
|
|
14667
|
+
lContainer.push(lView);
|
|
14668
|
+
lView[NEXT] = null;
|
|
14669
|
+
}
|
|
14670
|
+
lView[PARENT] = lContainer;
|
|
14671
|
+
// track views where declaration and insertion points are different
|
|
14672
|
+
const declarationLContainer = lView[DECLARATION_LCONTAINER];
|
|
14673
|
+
if (declarationLContainer !== null && lContainer !== declarationLContainer) {
|
|
14674
|
+
trackMovedView(declarationLContainer, lView);
|
|
14675
|
+
}
|
|
14676
|
+
// notify query that a new view has been added
|
|
14677
|
+
const lQueries = lView[QUERIES];
|
|
14678
|
+
if (lQueries !== null) {
|
|
14679
|
+
lQueries.insertView(tView);
|
|
14680
|
+
}
|
|
14681
|
+
updateAncestorTraversalFlagsOnAttach(lView);
|
|
14682
|
+
// Sets the attached flag
|
|
14683
|
+
lView[FLAGS] |= 128 /* LViewFlags.Attached */;
|
|
14684
|
+
}
|
|
14685
|
+
/**
|
|
14686
|
+
* Track views created from the declaration container (TemplateRef) and inserted into a
|
|
14687
|
+
* different LContainer or attached directly to ApplicationRef.
|
|
14688
|
+
*/
|
|
14689
|
+
function trackMovedView(declarationContainer, lView) {
|
|
14690
|
+
ngDevMode && assertDefined(lView, 'LView required');
|
|
14691
|
+
ngDevMode && assertLContainer(declarationContainer);
|
|
14692
|
+
const movedViews = declarationContainer[MOVED_VIEWS];
|
|
14693
|
+
const parent = lView[PARENT];
|
|
14694
|
+
ngDevMode && assertDefined(parent, 'missing parent');
|
|
14695
|
+
if (isLView(parent)) {
|
|
14696
|
+
declarationContainer[FLAGS] |= 2 /* LContainerFlags.HasTransplantedViews */;
|
|
14697
|
+
}
|
|
14698
|
+
else {
|
|
14699
|
+
const insertedComponentLView = parent[PARENT][DECLARATION_COMPONENT_VIEW];
|
|
14700
|
+
ngDevMode && assertDefined(insertedComponentLView, 'Missing insertedComponentLView');
|
|
14701
|
+
const declaredComponentLView = lView[DECLARATION_COMPONENT_VIEW];
|
|
14702
|
+
ngDevMode && assertDefined(declaredComponentLView, 'Missing declaredComponentLView');
|
|
14703
|
+
if (declaredComponentLView !== insertedComponentLView) {
|
|
14704
|
+
// At this point the declaration-component is not same as insertion-component; this means that
|
|
14705
|
+
// this is a transplanted view. Mark the declared lView as having transplanted views so that
|
|
14706
|
+
// those views can participate in CD.
|
|
14707
|
+
declarationContainer[FLAGS] |= 2 /* LContainerFlags.HasTransplantedViews */;
|
|
14708
|
+
}
|
|
14709
|
+
}
|
|
14710
|
+
if (movedViews === null) {
|
|
14711
|
+
declarationContainer[MOVED_VIEWS] = [lView];
|
|
14712
|
+
}
|
|
14713
|
+
else {
|
|
14714
|
+
movedViews.push(lView);
|
|
14715
|
+
}
|
|
14716
|
+
}
|
|
14717
|
+
|
|
14700
14718
|
class ViewRef$1 {
|
|
14701
14719
|
_lView;
|
|
14702
14720
|
_cdRefInjectingView;
|
|
@@ -17431,34 +17449,6 @@ function ɵɵinvalidFactory() {
|
|
|
17431
17449
|
throw new Error(msg);
|
|
17432
17450
|
}
|
|
17433
17451
|
|
|
17434
|
-
/**
|
|
17435
|
-
* When elements are created dynamically after a view blueprint is created (e.g. through
|
|
17436
|
-
* i18nApply()), we need to adjust the blueprint for future template passes.
|
|
17437
|
-
*
|
|
17438
|
-
* @param tView `TView` associated with `LView`
|
|
17439
|
-
* @param lView The `LView` containing the blueprint to adjust
|
|
17440
|
-
* @param numSlotsToAlloc The number of slots to alloc in the LView, should be >0
|
|
17441
|
-
* @param initialValue Initial value to store in blueprint
|
|
17442
|
-
*/
|
|
17443
|
-
function allocExpando(tView, lView, numSlotsToAlloc, initialValue) {
|
|
17444
|
-
if (numSlotsToAlloc === 0)
|
|
17445
|
-
return -1;
|
|
17446
|
-
if (ngDevMode) {
|
|
17447
|
-
assertFirstCreatePass(tView);
|
|
17448
|
-
assertSame(tView, lView[TVIEW], '`LView` must be associated with `TView`!');
|
|
17449
|
-
assertEqual(tView.data.length, lView.length, 'Expecting LView to be same size as TView');
|
|
17450
|
-
assertEqual(tView.data.length, tView.blueprint.length, 'Expecting Blueprint to be same size as TView');
|
|
17451
|
-
assertFirstUpdatePass(tView);
|
|
17452
|
-
}
|
|
17453
|
-
const allocIdx = lView.length;
|
|
17454
|
-
for (let i = 0; i < numSlotsToAlloc; i++) {
|
|
17455
|
-
lView.push(initialValue);
|
|
17456
|
-
tView.blueprint.push(initialValue);
|
|
17457
|
-
tView.data.push(null);
|
|
17458
|
-
}
|
|
17459
|
-
return allocIdx;
|
|
17460
|
-
}
|
|
17461
|
-
|
|
17462
17452
|
/**
|
|
17463
17453
|
* Resolve the matched directives on a node.
|
|
17464
17454
|
*/
|
|
@@ -17641,17 +17631,6 @@ function captureNodeBindings(mode, aliasMap, directiveIndex, bindingsResult, hos
|
|
|
17641
17631
|
continue;
|
|
17642
17632
|
}
|
|
17643
17633
|
bindingsResult ??= {};
|
|
17644
|
-
let internalName;
|
|
17645
|
-
let inputFlags = InputFlags.None;
|
|
17646
|
-
// For inputs, the value might be an array capturing additional
|
|
17647
|
-
// input flags.
|
|
17648
|
-
if (Array.isArray(value)) {
|
|
17649
|
-
internalName = value[0];
|
|
17650
|
-
inputFlags = value[1];
|
|
17651
|
-
}
|
|
17652
|
-
else {
|
|
17653
|
-
internalName = value;
|
|
17654
|
-
}
|
|
17655
17634
|
// If there are no host directive mappings, we want to remap using the alias map from the
|
|
17656
17635
|
// definition itself. If there is an alias map, it has two functions:
|
|
17657
17636
|
// 1. It serves as an allowlist of bindings that are exposed by the host directives. Only the
|
|
@@ -17668,24 +17647,20 @@ function captureNodeBindings(mode, aliasMap, directiveIndex, bindingsResult, hos
|
|
|
17668
17647
|
finalPublicName = hostDirectiveAliasMap[publicName];
|
|
17669
17648
|
}
|
|
17670
17649
|
if (mode === 0 /* CaptureNodeBindingMode.Inputs */) {
|
|
17671
|
-
addPropertyBinding(bindingsResult, directiveIndex, finalPublicName,
|
|
17650
|
+
addPropertyBinding(bindingsResult, directiveIndex, finalPublicName, publicName);
|
|
17672
17651
|
}
|
|
17673
17652
|
else {
|
|
17674
|
-
addPropertyBinding(bindingsResult, directiveIndex, finalPublicName,
|
|
17653
|
+
addPropertyBinding(bindingsResult, directiveIndex, finalPublicName, value);
|
|
17675
17654
|
}
|
|
17676
17655
|
}
|
|
17677
17656
|
return bindingsResult;
|
|
17678
17657
|
}
|
|
17679
|
-
function addPropertyBinding(bindings, directiveIndex, publicName,
|
|
17680
|
-
let values;
|
|
17658
|
+
function addPropertyBinding(bindings, directiveIndex, publicName, lookupName) {
|
|
17681
17659
|
if (bindings.hasOwnProperty(publicName)) {
|
|
17682
|
-
|
|
17660
|
+
bindings[publicName].push(directiveIndex, lookupName);
|
|
17683
17661
|
}
|
|
17684
17662
|
else {
|
|
17685
|
-
|
|
17686
|
-
}
|
|
17687
|
-
if (inputFlags !== undefined) {
|
|
17688
|
-
values.push(inputFlags);
|
|
17663
|
+
bindings[publicName] = [directiveIndex, lookupName];
|
|
17689
17664
|
}
|
|
17690
17665
|
}
|
|
17691
17666
|
/**
|
|
@@ -17722,15 +17697,14 @@ function generateInitialInputs(inputs, directiveIndex, attrs) {
|
|
|
17722
17697
|
if (typeof attrName === 'number')
|
|
17723
17698
|
break;
|
|
17724
17699
|
if (inputs.hasOwnProperty(attrName)) {
|
|
17725
|
-
if (inputsToStore === null)
|
|
17726
|
-
inputsToStore = [];
|
|
17727
17700
|
// Find the input's public name from the input store. Note that we can be found easier
|
|
17728
17701
|
// through the directive def, but we want to do it using the inputs store so that it can
|
|
17729
17702
|
// account for host directive aliases.
|
|
17730
17703
|
const inputConfig = inputs[attrName];
|
|
17731
|
-
for (let j = 0; j < inputConfig.length; j +=
|
|
17704
|
+
for (let j = 0; j < inputConfig.length; j += 2) {
|
|
17732
17705
|
if (inputConfig[j] === directiveIndex) {
|
|
17733
|
-
inputsToStore
|
|
17706
|
+
inputsToStore ??= [];
|
|
17707
|
+
inputsToStore.push(inputConfig[j + 1], attrs[i + 1]);
|
|
17734
17708
|
// A directive can't have multiple inputs with the same name so we can break here.
|
|
17735
17709
|
break;
|
|
17736
17710
|
}
|
|
@@ -17899,34 +17873,22 @@ class ComponentFactoryResolver extends ComponentFactoryResolver$1 {
|
|
|
17899
17873
|
return new ComponentFactory(componentDef, this.ngModule);
|
|
17900
17874
|
}
|
|
17901
17875
|
}
|
|
17902
|
-
function
|
|
17903
|
-
|
|
17904
|
-
|
|
17905
|
-
|
|
17906
|
-
|
|
17907
|
-
|
|
17908
|
-
|
|
17909
|
-
|
|
17910
|
-
|
|
17911
|
-
|
|
17912
|
-
const isArray = Array.isArray(value);
|
|
17913
|
-
const propName = isArray ? value[0] : value;
|
|
17914
|
-
const flags = isArray ? value[1] : InputFlags.None;
|
|
17915
|
-
if (isInputMap) {
|
|
17916
|
-
array.push({
|
|
17917
|
-
propName: propName,
|
|
17918
|
-
templateName: publicName,
|
|
17919
|
-
isSignal: (flags & InputFlags.SignalBased) !== 0,
|
|
17920
|
-
});
|
|
17921
|
-
}
|
|
17922
|
-
else {
|
|
17923
|
-
array.push({
|
|
17924
|
-
propName: propName,
|
|
17925
|
-
templateName: publicName,
|
|
17926
|
-
});
|
|
17876
|
+
function toInputRefArray(map) {
|
|
17877
|
+
return Object.keys(map).map((name) => {
|
|
17878
|
+
const [propName, flags, transform] = map[name];
|
|
17879
|
+
const inputData = {
|
|
17880
|
+
propName: propName,
|
|
17881
|
+
templateName: name,
|
|
17882
|
+
isSignal: (flags & InputFlags.SignalBased) !== 0,
|
|
17883
|
+
};
|
|
17884
|
+
if (transform) {
|
|
17885
|
+
inputData.transform = transform;
|
|
17927
17886
|
}
|
|
17928
|
-
|
|
17929
|
-
|
|
17887
|
+
return inputData;
|
|
17888
|
+
});
|
|
17889
|
+
}
|
|
17890
|
+
function toOutputRefArray(map) {
|
|
17891
|
+
return Object.keys(map).map((name) => ({ propName: map[name], templateName: name }));
|
|
17930
17892
|
}
|
|
17931
17893
|
function verifyNotAnOrphanComponent(componentDef) {
|
|
17932
17894
|
// TODO(pk): create assert that verifies ngDevMode
|
|
@@ -17985,20 +17947,10 @@ class ComponentFactory extends ComponentFactory$1 {
|
|
|
17985
17947
|
ngContentSelectors;
|
|
17986
17948
|
isBoundToModule;
|
|
17987
17949
|
get inputs() {
|
|
17988
|
-
|
|
17989
|
-
const inputTransforms = componentDef.inputTransforms;
|
|
17990
|
-
const refArray = toRefArray(componentDef.inputs, true);
|
|
17991
|
-
if (inputTransforms !== null) {
|
|
17992
|
-
for (const input of refArray) {
|
|
17993
|
-
if (inputTransforms.hasOwnProperty(input.propName)) {
|
|
17994
|
-
input.transform = inputTransforms[input.propName];
|
|
17995
|
-
}
|
|
17996
|
-
}
|
|
17997
|
-
}
|
|
17998
|
-
return refArray;
|
|
17950
|
+
return toInputRefArray(this.componentDef.inputs);
|
|
17999
17951
|
}
|
|
18000
17952
|
get outputs() {
|
|
18001
|
-
return
|
|
17953
|
+
return toOutputRefArray(this.componentDef.outputs);
|
|
18002
17954
|
}
|
|
18003
17955
|
/**
|
|
18004
17956
|
* @param componentDef The component definition.
|
|
@@ -18020,7 +17972,7 @@ class ComponentFactory extends ComponentFactory$1 {
|
|
|
18020
17972
|
const cmpDef = this.componentDef;
|
|
18021
17973
|
ngDevMode && verifyNotAnOrphanComponent(cmpDef);
|
|
18022
17974
|
const tAttributes = rootSelectorOrNode
|
|
18023
|
-
? ['ng-version', '19.2.0-
|
|
17975
|
+
? ['ng-version', '19.2.0-rc.0']
|
|
18024
17976
|
: // Extract attributes and classes from the first selector only to match VE behavior.
|
|
18025
17977
|
extractAttrsAndClassesFromSelector(this.componentDef.selectors[0]);
|
|
18026
17978
|
// Create the root view. Uses empty TView and ContentTemplate.
|
|
@@ -19893,7 +19845,74 @@ function ɵɵdefineNgModule(def) {
|
|
|
19893
19845
|
return res;
|
|
19894
19846
|
});
|
|
19895
19847
|
}
|
|
19896
|
-
|
|
19848
|
+
/**
|
|
19849
|
+
* Converts binding objects from the `DirectiveDefinition` into more efficient
|
|
19850
|
+
* lookup dictionaries that are optimized for the framework runtime.
|
|
19851
|
+
*
|
|
19852
|
+
* This function converts inputs or output directive information into new objects
|
|
19853
|
+
* where the public name conveniently maps to the minified internal field name.
|
|
19854
|
+
*
|
|
19855
|
+
* For inputs, the input flags are additionally persisted into the new data structure,
|
|
19856
|
+
* so that those can be quickly retrieved when needed.
|
|
19857
|
+
*
|
|
19858
|
+
* e.g. for
|
|
19859
|
+
*
|
|
19860
|
+
* ```ts
|
|
19861
|
+
* class Comp {
|
|
19862
|
+
* @Input()
|
|
19863
|
+
* propName1: string;
|
|
19864
|
+
*
|
|
19865
|
+
* @Input('publicName2')
|
|
19866
|
+
* declaredPropName2: number;
|
|
19867
|
+
*
|
|
19868
|
+
* inputSignal = input(3);
|
|
19869
|
+
* }
|
|
19870
|
+
* ```
|
|
19871
|
+
*
|
|
19872
|
+
* will be serialized as
|
|
19873
|
+
*
|
|
19874
|
+
* ```ts
|
|
19875
|
+
* {
|
|
19876
|
+
* propName1: 'propName1',
|
|
19877
|
+
* declaredPropName2: ['publicName2', 'declaredPropName2'],
|
|
19878
|
+
* inputSignal: [InputFlags.SignalBased, 'inputSignal'],
|
|
19879
|
+
* }
|
|
19880
|
+
* ```
|
|
19881
|
+
*
|
|
19882
|
+
* which is than translated by the minifier as:
|
|
19883
|
+
*
|
|
19884
|
+
* ```ts
|
|
19885
|
+
* {
|
|
19886
|
+
* minifiedPropName1: 'propName1',
|
|
19887
|
+
* minifiedPropName2: ['publicName2', 'declaredPropName2'],
|
|
19888
|
+
* minifiedInputSignal: [InputFlags.SignalBased, 'inputSignal'],
|
|
19889
|
+
* }
|
|
19890
|
+
* ```
|
|
19891
|
+
*
|
|
19892
|
+
* becomes: (public name => minifiedName + isSignal if needed)
|
|
19893
|
+
*
|
|
19894
|
+
* ```ts
|
|
19895
|
+
* {
|
|
19896
|
+
* 'propName1': 'minifiedPropName1',
|
|
19897
|
+
* 'publicName2': 'minifiedPropName2',
|
|
19898
|
+
* 'inputSignal': ['minifiedInputSignal', InputFlags.SignalBased],
|
|
19899
|
+
* }
|
|
19900
|
+
* ```
|
|
19901
|
+
*
|
|
19902
|
+
* Optionally the function can take `declaredInputs` which will result
|
|
19903
|
+
* in: (public name => declared name)
|
|
19904
|
+
*
|
|
19905
|
+
* ```ts
|
|
19906
|
+
* {
|
|
19907
|
+
* 'propName1': 'propName1',
|
|
19908
|
+
* 'publicName2': 'declaredPropName2',
|
|
19909
|
+
* 'inputSignal': 'inputSignal',
|
|
19910
|
+
* }
|
|
19911
|
+
* ```
|
|
19912
|
+
*
|
|
19913
|
+
|
|
19914
|
+
*/
|
|
19915
|
+
function parseAndConvertInputsForDefinition(obj, declaredInputs) {
|
|
19897
19916
|
if (obj == null)
|
|
19898
19917
|
return EMPTY_OBJ;
|
|
19899
19918
|
const newLookup = {};
|
|
@@ -19902,26 +19921,33 @@ function parseAndConvertBindingsForDefinition(obj, declaredInputs) {
|
|
|
19902
19921
|
const value = obj[minifiedKey];
|
|
19903
19922
|
let publicName;
|
|
19904
19923
|
let declaredName;
|
|
19905
|
-
let inputFlags
|
|
19924
|
+
let inputFlags;
|
|
19925
|
+
let transform;
|
|
19906
19926
|
if (Array.isArray(value)) {
|
|
19907
19927
|
inputFlags = value[0];
|
|
19908
19928
|
publicName = value[1];
|
|
19909
19929
|
declaredName = value[2] ?? publicName; // declared name might not be set to save bytes.
|
|
19930
|
+
transform = value[3] || null;
|
|
19910
19931
|
}
|
|
19911
19932
|
else {
|
|
19912
19933
|
publicName = value;
|
|
19913
19934
|
declaredName = value;
|
|
19935
|
+
inputFlags = InputFlags.None;
|
|
19936
|
+
transform = null;
|
|
19914
19937
|
}
|
|
19915
|
-
|
|
19916
|
-
|
|
19917
|
-
|
|
19918
|
-
|
|
19919
|
-
|
|
19920
|
-
|
|
19921
|
-
|
|
19922
|
-
|
|
19923
|
-
|
|
19924
|
-
|
|
19938
|
+
newLookup[publicName] = [minifiedKey, inputFlags, transform];
|
|
19939
|
+
declaredInputs[publicName] = declaredName;
|
|
19940
|
+
}
|
|
19941
|
+
}
|
|
19942
|
+
return newLookup;
|
|
19943
|
+
}
|
|
19944
|
+
function parseAndConvertOutputsForDefinition(obj) {
|
|
19945
|
+
if (obj == null)
|
|
19946
|
+
return EMPTY_OBJ;
|
|
19947
|
+
const newLookup = {};
|
|
19948
|
+
for (const minifiedKey in obj) {
|
|
19949
|
+
if (obj.hasOwnProperty(minifiedKey)) {
|
|
19950
|
+
newLookup[obj[minifiedKey]] = minifiedKey;
|
|
19925
19951
|
}
|
|
19926
19952
|
}
|
|
19927
19953
|
return newLookup;
|
|
@@ -19986,7 +20012,6 @@ function getNgDirectiveDef(directiveDefinition) {
|
|
|
19986
20012
|
hostAttrs: directiveDefinition.hostAttrs || null,
|
|
19987
20013
|
contentQueries: directiveDefinition.contentQueries || null,
|
|
19988
20014
|
declaredInputs: declaredInputs,
|
|
19989
|
-
inputTransforms: null,
|
|
19990
20015
|
inputConfig: directiveDefinition.inputs || EMPTY_OBJ,
|
|
19991
20016
|
exportAs: directiveDefinition.exportAs || null,
|
|
19992
20017
|
standalone: directiveDefinition.standalone ?? true,
|
|
@@ -19997,8 +20022,8 @@ function getNgDirectiveDef(directiveDefinition) {
|
|
|
19997
20022
|
setInput: null,
|
|
19998
20023
|
findHostDirectiveDefs: null,
|
|
19999
20024
|
hostDirectives: null,
|
|
20000
|
-
inputs:
|
|
20001
|
-
outputs:
|
|
20025
|
+
inputs: parseAndConvertInputsForDefinition(directiveDefinition.inputs, declaredInputs),
|
|
20026
|
+
outputs: parseAndConvertOutputsForDefinition(directiveDefinition.outputs),
|
|
20002
20027
|
debugInfo: null,
|
|
20003
20028
|
};
|
|
20004
20029
|
}
|
|
@@ -20127,7 +20152,6 @@ function ɵɵInheritDefinitionFeature(definition) {
|
|
|
20127
20152
|
// would've justified object creation. Unwrap them if necessary.
|
|
20128
20153
|
const writeableDef = definition;
|
|
20129
20154
|
writeableDef.inputs = maybeUnwrapEmpty(definition.inputs);
|
|
20130
|
-
writeableDef.inputTransforms = maybeUnwrapEmpty(definition.inputTransforms);
|
|
20131
20155
|
writeableDef.declaredInputs = maybeUnwrapEmpty(definition.declaredInputs);
|
|
20132
20156
|
writeableDef.outputs = maybeUnwrapEmpty(definition.outputs);
|
|
20133
20157
|
// Merge hostBindings
|
|
@@ -20184,23 +20208,9 @@ function mergeInputsWithTransforms(target, source) {
|
|
|
20184
20208
|
continue;
|
|
20185
20209
|
}
|
|
20186
20210
|
const value = source.inputs[key];
|
|
20187
|
-
if (value
|
|
20188
|
-
|
|
20189
|
-
|
|
20190
|
-
target.inputs[key] = value;
|
|
20191
|
-
target.declaredInputs[key] = source.declaredInputs[key];
|
|
20192
|
-
// If the input is inherited, and we have a transform for it, we also inherit it.
|
|
20193
|
-
// Note that transforms should not be inherited if the input has its own metadata
|
|
20194
|
-
// in the `source` directive itself already (i.e. the input is re-declared/overridden).
|
|
20195
|
-
if (source.inputTransforms !== null) {
|
|
20196
|
-
// Note: transforms are stored with their minified names.
|
|
20197
|
-
// Perf: only access the minified name when there are source transforms.
|
|
20198
|
-
const minifiedName = Array.isArray(value) ? value[0] : value;
|
|
20199
|
-
if (!source.inputTransforms.hasOwnProperty(minifiedName)) {
|
|
20200
|
-
continue;
|
|
20201
|
-
}
|
|
20202
|
-
target.inputTransforms ??= {};
|
|
20203
|
-
target.inputTransforms[minifiedName] = source.inputTransforms[minifiedName];
|
|
20211
|
+
if (value !== undefined) {
|
|
20212
|
+
target.inputs[key] = value;
|
|
20213
|
+
target.declaredInputs[key] = source.declaredInputs[key];
|
|
20204
20214
|
}
|
|
20205
20215
|
}
|
|
20206
20216
|
}
|
|
@@ -20514,30 +20524,6 @@ function validateMappings(bindingType, def, hostDirectiveBindings) {
|
|
|
20514
20524
|
}
|
|
20515
20525
|
}
|
|
20516
20526
|
|
|
20517
|
-
/**
|
|
20518
|
-
* Decorates the directive definition with support for input transform functions.
|
|
20519
|
-
*
|
|
20520
|
-
* If the directive uses inheritance, the feature should be included before the
|
|
20521
|
-
* `InheritDefinitionFeature` to ensure that the `inputTransforms` field is populated.
|
|
20522
|
-
*
|
|
20523
|
-
* @codeGenApi
|
|
20524
|
-
*/
|
|
20525
|
-
function ɵɵInputTransformsFeature(definition) {
|
|
20526
|
-
const inputs = definition.inputConfig;
|
|
20527
|
-
const inputTransforms = {};
|
|
20528
|
-
for (const minifiedKey in inputs) {
|
|
20529
|
-
if (inputs.hasOwnProperty(minifiedKey)) {
|
|
20530
|
-
// Note: the private names are used for the keys, rather than the public ones, because public
|
|
20531
|
-
// names can be re-aliased in host directives which would invalidate the lookup.
|
|
20532
|
-
const value = inputs[minifiedKey];
|
|
20533
|
-
if (Array.isArray(value) && value[3]) {
|
|
20534
|
-
inputTransforms[minifiedKey] = value[3];
|
|
20535
|
-
}
|
|
20536
|
-
}
|
|
20537
|
-
}
|
|
20538
|
-
definition.inputTransforms = inputTransforms;
|
|
20539
|
-
}
|
|
20540
|
-
|
|
20541
20527
|
function isIterable(obj) {
|
|
20542
20528
|
return obj !== null && typeof obj === 'object' && obj[Symbol.iterator] !== undefined;
|
|
20543
20529
|
}
|
|
@@ -33654,7 +33640,6 @@ const angularCoreEnv = (() => ({
|
|
|
33654
33640
|
'ɵɵProvidersFeature': ɵɵProvidersFeature,
|
|
33655
33641
|
'ɵɵCopyDefinitionFeature': ɵɵCopyDefinitionFeature,
|
|
33656
33642
|
'ɵɵInheritDefinitionFeature': ɵɵInheritDefinitionFeature,
|
|
33657
|
-
'ɵɵInputTransformsFeature': ɵɵInputTransformsFeature,
|
|
33658
33643
|
'ɵɵExternalStylesFeature': ɵɵExternalStylesFeature,
|
|
33659
33644
|
'ɵɵnextContext': ɵɵnextContext,
|
|
33660
33645
|
'ɵɵnamespaceHTML': ɵɵnamespaceHTML,
|
|
@@ -34993,7 +34978,7 @@ class Version {
|
|
|
34993
34978
|
/**
|
|
34994
34979
|
* @publicApi
|
|
34995
34980
|
*/
|
|
34996
|
-
const VERSION = new Version('19.2.0-
|
|
34981
|
+
const VERSION = new Version('19.2.0-rc.0');
|
|
34997
34982
|
|
|
34998
34983
|
/**
|
|
34999
34984
|
* Combination of NgModuleFactory and ComponentFactories.
|
|
@@ -38840,8 +38825,8 @@ function defaultThrowError() {
|
|
|
38840
38825
|
throw new Error();
|
|
38841
38826
|
}
|
|
38842
38827
|
let throwInvalidWriteToSignalErrorFn = defaultThrowError;
|
|
38843
|
-
function throwInvalidWriteToSignalError() {
|
|
38844
|
-
throwInvalidWriteToSignalErrorFn();
|
|
38828
|
+
function throwInvalidWriteToSignalError(node) {
|
|
38829
|
+
throwInvalidWriteToSignalErrorFn(node);
|
|
38845
38830
|
}
|
|
38846
38831
|
function setThrowInvalidWriteToSignalError(fn) {
|
|
38847
38832
|
throwInvalidWriteToSignalErrorFn = fn;
|
|
@@ -38878,7 +38863,7 @@ function signalGetFn() {
|
|
|
38878
38863
|
}
|
|
38879
38864
|
function signalSetFn(node, newValue) {
|
|
38880
38865
|
if (!producerUpdatesAllowed()) {
|
|
38881
|
-
throwInvalidWriteToSignalError();
|
|
38866
|
+
throwInvalidWriteToSignalError(node);
|
|
38882
38867
|
}
|
|
38883
38868
|
if (!node.equal(node.value, newValue)) {
|
|
38884
38869
|
node.value = newValue;
|
|
@@ -38887,7 +38872,7 @@ function signalSetFn(node, newValue) {
|
|
|
38887
38872
|
}
|
|
38888
38873
|
function signalUpdateFn(node, updater) {
|
|
38889
38874
|
if (!producerUpdatesAllowed()) {
|
|
38890
|
-
throwInvalidWriteToSignalError();
|
|
38875
|
+
throwInvalidWriteToSignalError(node);
|
|
38891
38876
|
}
|
|
38892
38877
|
signalSetFn(node, updater(node.value));
|
|
38893
38878
|
}
|
|
@@ -40423,176 +40408,21 @@ function disableProfiling() {
|
|
|
40423
40408
|
enablePerfLogging = false;
|
|
40424
40409
|
}
|
|
40425
40410
|
|
|
40426
|
-
/*!
|
|
40427
|
-
* @license
|
|
40428
|
-
* Copyright Google LLC All Rights Reserved.
|
|
40429
|
-
*
|
|
40430
|
-
* Use of this source code is governed by an MIT-style license that can be
|
|
40431
|
-
* found in the LICENSE file at https://angular.dev/license
|
|
40432
|
-
*/
|
|
40433
40411
|
/**
|
|
40434
|
-
*
|
|
40435
|
-
*
|
|
40436
|
-
* consumer of the function is responsible for resolving the minified name to its original name.
|
|
40437
|
-
* @param node Node from which to start the search.
|
|
40412
|
+
* Execute an arbitrary function in a non-reactive (non-tracking) context. The executed function
|
|
40413
|
+
* can, optionally, return a value.
|
|
40438
40414
|
*/
|
|
40439
|
-
function
|
|
40440
|
-
|
|
40441
|
-
|
|
40442
|
-
|
|
40443
|
-
|
|
40444
|
-
|
|
40445
|
-
const current = lView[i];
|
|
40446
|
-
if ((!isLView(current) && !isLContainer(current)) || current[HOST] !== currentNode) {
|
|
40447
|
-
continue;
|
|
40448
|
-
}
|
|
40449
|
-
const tView = lView[TVIEW];
|
|
40450
|
-
const tNode = getTNode(tView, i);
|
|
40451
|
-
if (isComponentHost(tNode)) {
|
|
40452
|
-
const def = tView.data[tNode.directiveStart + tNode.componentOffset];
|
|
40453
|
-
const name = def.debugInfo?.className || def.type.name;
|
|
40454
|
-
// Note: the name may be an empty string if the class name is
|
|
40455
|
-
// dropped due to minification. In such cases keep going up the tree.
|
|
40456
|
-
if (name) {
|
|
40457
|
-
return name;
|
|
40458
|
-
}
|
|
40459
|
-
else {
|
|
40460
|
-
break;
|
|
40461
|
-
}
|
|
40462
|
-
}
|
|
40463
|
-
}
|
|
40464
|
-
}
|
|
40465
|
-
currentNode = currentNode.parentNode;
|
|
40415
|
+
function untracked(nonReactiveReadsFn) {
|
|
40416
|
+
const prevConsumer = setActiveConsumer$1(null);
|
|
40417
|
+
// We are not trying to catch any particular errors here, just making sure that the consumers
|
|
40418
|
+
// stack is restored in case of errors.
|
|
40419
|
+
try {
|
|
40420
|
+
return nonReactiveReadsFn();
|
|
40466
40421
|
}
|
|
40467
|
-
|
|
40468
|
-
|
|
40469
|
-
|
|
40470
|
-
/**
|
|
40471
|
-
* Compiles a partial directive declaration object into a full directive definition object.
|
|
40472
|
-
*
|
|
40473
|
-
* @codeGenApi
|
|
40474
|
-
*/
|
|
40475
|
-
function ɵɵngDeclareDirective(decl) {
|
|
40476
|
-
const compiler = getCompilerFacade({
|
|
40477
|
-
usage: 1 /* JitCompilerUsage.PartialDeclaration */,
|
|
40478
|
-
kind: 'directive',
|
|
40479
|
-
type: decl.type,
|
|
40480
|
-
});
|
|
40481
|
-
return compiler.compileDirectiveDeclaration(angularCoreEnv, `ng:///${decl.type.name}/ɵfac.js`, decl);
|
|
40482
|
-
}
|
|
40483
|
-
/**
|
|
40484
|
-
* Evaluates the class metadata declaration.
|
|
40485
|
-
*
|
|
40486
|
-
* @codeGenApi
|
|
40487
|
-
*/
|
|
40488
|
-
function ɵɵngDeclareClassMetadata(decl) {
|
|
40489
|
-
setClassMetadata(decl.type, decl.decorators, decl.ctorParameters ?? null, decl.propDecorators ?? null);
|
|
40490
|
-
}
|
|
40491
|
-
/**
|
|
40492
|
-
* Evaluates the class metadata of a component that contains deferred blocks.
|
|
40493
|
-
*
|
|
40494
|
-
* @codeGenApi
|
|
40495
|
-
*/
|
|
40496
|
-
function ɵɵngDeclareClassMetadataAsync(decl) {
|
|
40497
|
-
setClassMetadataAsync(decl.type, decl.resolveDeferredDeps, (...types) => {
|
|
40498
|
-
const meta = decl.resolveMetadata(...types);
|
|
40499
|
-
setClassMetadata(decl.type, meta.decorators, meta.ctorParameters, meta.propDecorators);
|
|
40500
|
-
});
|
|
40501
|
-
}
|
|
40502
|
-
/**
|
|
40503
|
-
* Compiles a partial component declaration object into a full component definition object.
|
|
40504
|
-
*
|
|
40505
|
-
* @codeGenApi
|
|
40506
|
-
*/
|
|
40507
|
-
function ɵɵngDeclareComponent(decl) {
|
|
40508
|
-
const compiler = getCompilerFacade({
|
|
40509
|
-
usage: 1 /* JitCompilerUsage.PartialDeclaration */,
|
|
40510
|
-
kind: 'component',
|
|
40511
|
-
type: decl.type,
|
|
40512
|
-
});
|
|
40513
|
-
return compiler.compileComponentDeclaration(angularCoreEnv, `ng:///${decl.type.name}/ɵcmp.js`, decl);
|
|
40514
|
-
}
|
|
40515
|
-
/**
|
|
40516
|
-
* Compiles a partial pipe declaration object into a full pipe definition object.
|
|
40517
|
-
*
|
|
40518
|
-
* @codeGenApi
|
|
40519
|
-
*/
|
|
40520
|
-
function ɵɵngDeclareFactory(decl) {
|
|
40521
|
-
const compiler = getCompilerFacade({
|
|
40522
|
-
usage: 1 /* JitCompilerUsage.PartialDeclaration */,
|
|
40523
|
-
kind: getFactoryKind(decl.target),
|
|
40524
|
-
type: decl.type,
|
|
40525
|
-
});
|
|
40526
|
-
return compiler.compileFactoryDeclaration(angularCoreEnv, `ng:///${decl.type.name}/ɵfac.js`, decl);
|
|
40527
|
-
}
|
|
40528
|
-
function getFactoryKind(target) {
|
|
40529
|
-
switch (target) {
|
|
40530
|
-
case FactoryTarget.Directive:
|
|
40531
|
-
return 'directive';
|
|
40532
|
-
case FactoryTarget.Component:
|
|
40533
|
-
return 'component';
|
|
40534
|
-
case FactoryTarget.Injectable:
|
|
40535
|
-
return 'injectable';
|
|
40536
|
-
case FactoryTarget.Pipe:
|
|
40537
|
-
return 'pipe';
|
|
40538
|
-
case FactoryTarget.NgModule:
|
|
40539
|
-
return 'NgModule';
|
|
40422
|
+
finally {
|
|
40423
|
+
setActiveConsumer$1(prevConsumer);
|
|
40540
40424
|
}
|
|
40541
40425
|
}
|
|
40542
|
-
/**
|
|
40543
|
-
* Compiles a partial injectable declaration object into a full injectable definition object.
|
|
40544
|
-
*
|
|
40545
|
-
* @codeGenApi
|
|
40546
|
-
*/
|
|
40547
|
-
function ɵɵngDeclareInjectable(decl) {
|
|
40548
|
-
const compiler = getCompilerFacade({
|
|
40549
|
-
usage: 1 /* JitCompilerUsage.PartialDeclaration */,
|
|
40550
|
-
kind: 'injectable',
|
|
40551
|
-
type: decl.type,
|
|
40552
|
-
});
|
|
40553
|
-
return compiler.compileInjectableDeclaration(angularCoreEnv, `ng:///${decl.type.name}/ɵprov.js`, decl);
|
|
40554
|
-
}
|
|
40555
|
-
/**
|
|
40556
|
-
* Compiles a partial injector declaration object into a full injector definition object.
|
|
40557
|
-
*
|
|
40558
|
-
* @codeGenApi
|
|
40559
|
-
*/
|
|
40560
|
-
function ɵɵngDeclareInjector(decl) {
|
|
40561
|
-
const compiler = getCompilerFacade({
|
|
40562
|
-
usage: 1 /* JitCompilerUsage.PartialDeclaration */,
|
|
40563
|
-
kind: 'NgModule',
|
|
40564
|
-
type: decl.type,
|
|
40565
|
-
});
|
|
40566
|
-
return compiler.compileInjectorDeclaration(angularCoreEnv, `ng:///${decl.type.name}/ɵinj.js`, decl);
|
|
40567
|
-
}
|
|
40568
|
-
/**
|
|
40569
|
-
* Compiles a partial NgModule declaration object into a full NgModule definition object.
|
|
40570
|
-
*
|
|
40571
|
-
* @codeGenApi
|
|
40572
|
-
*/
|
|
40573
|
-
function ɵɵngDeclareNgModule(decl) {
|
|
40574
|
-
const compiler = getCompilerFacade({
|
|
40575
|
-
usage: 1 /* JitCompilerUsage.PartialDeclaration */,
|
|
40576
|
-
kind: 'NgModule',
|
|
40577
|
-
type: decl.type,
|
|
40578
|
-
});
|
|
40579
|
-
return compiler.compileNgModuleDeclaration(angularCoreEnv, `ng:///${decl.type.name}/ɵmod.js`, decl);
|
|
40580
|
-
}
|
|
40581
|
-
/**
|
|
40582
|
-
* Compiles a partial pipe declaration object into a full pipe definition object.
|
|
40583
|
-
*
|
|
40584
|
-
* @codeGenApi
|
|
40585
|
-
*/
|
|
40586
|
-
function ɵɵngDeclarePipe(decl) {
|
|
40587
|
-
const compiler = getCompilerFacade({
|
|
40588
|
-
usage: 1 /* JitCompilerUsage.PartialDeclaration */,
|
|
40589
|
-
kind: 'pipe',
|
|
40590
|
-
type: decl.type,
|
|
40591
|
-
});
|
|
40592
|
-
return compiler.compilePipeDeclaration(angularCoreEnv, `ng:///${decl.type.name}/ɵpipe.js`, decl);
|
|
40593
|
-
}
|
|
40594
|
-
|
|
40595
|
-
// we reexport these symbols just so that they are retained during the dead code elimination
|
|
40596
40426
|
|
|
40597
40427
|
/**
|
|
40598
40428
|
* Create a computed `Signal` which derives a reactive value from an expression.
|
|
@@ -40610,46 +40440,6 @@ function computed(computation, options) {
|
|
|
40610
40440
|
return getter;
|
|
40611
40441
|
}
|
|
40612
40442
|
|
|
40613
|
-
const identityFn = (v) => v;
|
|
40614
|
-
function linkedSignal(optionsOrComputation, options) {
|
|
40615
|
-
performanceMarkFeature('NgSignals');
|
|
40616
|
-
if (typeof optionsOrComputation === 'function') {
|
|
40617
|
-
const getter = createLinkedSignal$1(optionsOrComputation, (identityFn), options?.equal);
|
|
40618
|
-
return upgradeLinkedSignalGetter(getter);
|
|
40619
|
-
}
|
|
40620
|
-
else {
|
|
40621
|
-
const getter = createLinkedSignal$1(optionsOrComputation.source, optionsOrComputation.computation, optionsOrComputation.equal);
|
|
40622
|
-
return upgradeLinkedSignalGetter(getter);
|
|
40623
|
-
}
|
|
40624
|
-
}
|
|
40625
|
-
function upgradeLinkedSignalGetter(getter) {
|
|
40626
|
-
if (ngDevMode) {
|
|
40627
|
-
getter.toString = () => `[LinkedSignal: ${getter()}]`;
|
|
40628
|
-
}
|
|
40629
|
-
const node = getter[SIGNAL$1];
|
|
40630
|
-
const upgradedGetter = getter;
|
|
40631
|
-
upgradedGetter.set = (newValue) => linkedSignalSetFn$1(node, newValue);
|
|
40632
|
-
upgradedGetter.update = (updateFn) => linkedSignalUpdateFn$1(node, updateFn);
|
|
40633
|
-
upgradedGetter.asReadonly = signalAsReadonlyFn.bind(getter);
|
|
40634
|
-
return upgradedGetter;
|
|
40635
|
-
}
|
|
40636
|
-
|
|
40637
|
-
/**
|
|
40638
|
-
* Execute an arbitrary function in a non-reactive (non-tracking) context. The executed function
|
|
40639
|
-
* can, optionally, return a value.
|
|
40640
|
-
*/
|
|
40641
|
-
function untracked(nonReactiveReadsFn) {
|
|
40642
|
-
const prevConsumer = setActiveConsumer$1(null);
|
|
40643
|
-
// We are not trying to catch any particular errors here, just making sure that the consumers
|
|
40644
|
-
// stack is restored in case of errors.
|
|
40645
|
-
try {
|
|
40646
|
-
return nonReactiveReadsFn();
|
|
40647
|
-
}
|
|
40648
|
-
finally {
|
|
40649
|
-
setActiveConsumer$1(prevConsumer);
|
|
40650
|
-
}
|
|
40651
|
-
}
|
|
40652
|
-
|
|
40653
40443
|
/**
|
|
40654
40444
|
* Controls whether effects use the legacy `microtaskEffect` by default.
|
|
40655
40445
|
*/
|
|
@@ -40963,163 +40753,6 @@ function createRootEffect(fn, scheduler, notifier) {
|
|
|
40963
40753
|
return node;
|
|
40964
40754
|
}
|
|
40965
40755
|
|
|
40966
|
-
const NOT_SET = Symbol('NOT_SET');
|
|
40967
|
-
const EMPTY_CLEANUP_SET = new Set();
|
|
40968
|
-
const AFTER_RENDER_PHASE_EFFECT_NODE = /* @__PURE__ */ (() => ({
|
|
40969
|
-
...SIGNAL_NODE$1,
|
|
40970
|
-
consumerIsAlwaysLive: true,
|
|
40971
|
-
consumerAllowSignalWrites: true,
|
|
40972
|
-
value: NOT_SET,
|
|
40973
|
-
cleanup: null,
|
|
40974
|
-
/** Called when the effect becomes dirty */
|
|
40975
|
-
consumerMarkedDirty() {
|
|
40976
|
-
if (this.sequence.impl.executing) {
|
|
40977
|
-
// If hooks are in the middle of executing, then it matters whether this node has yet been
|
|
40978
|
-
// executed within its sequence. If not, then we don't want to notify the scheduler since
|
|
40979
|
-
// this node will be reached naturally.
|
|
40980
|
-
if (this.sequence.lastPhase === null || this.sequence.lastPhase < this.phase) {
|
|
40981
|
-
return;
|
|
40982
|
-
}
|
|
40983
|
-
// If during the execution of a later phase an earlier phase became dirty, then we should not
|
|
40984
|
-
// run any further phases until the earlier one reruns.
|
|
40985
|
-
this.sequence.erroredOrDestroyed = true;
|
|
40986
|
-
}
|
|
40987
|
-
// Either hooks are not running, or we're marking a node dirty that has already run within its
|
|
40988
|
-
// sequence.
|
|
40989
|
-
this.sequence.scheduler.notify(7 /* NotificationSource.RenderHook */);
|
|
40990
|
-
},
|
|
40991
|
-
phaseFn(previousValue) {
|
|
40992
|
-
this.sequence.lastPhase = this.phase;
|
|
40993
|
-
if (!this.dirty) {
|
|
40994
|
-
return this.signal;
|
|
40995
|
-
}
|
|
40996
|
-
this.dirty = false;
|
|
40997
|
-
if (this.value !== NOT_SET && !consumerPollProducersForChange$1(this)) {
|
|
40998
|
-
// None of our producers report a change since the last time they were read, so no
|
|
40999
|
-
// recomputation of our value is necessary.
|
|
41000
|
-
return this.signal;
|
|
41001
|
-
}
|
|
41002
|
-
// Run any needed cleanup functions.
|
|
41003
|
-
try {
|
|
41004
|
-
for (const cleanupFn of this.cleanup ?? EMPTY_CLEANUP_SET) {
|
|
41005
|
-
cleanupFn();
|
|
41006
|
-
}
|
|
41007
|
-
}
|
|
41008
|
-
finally {
|
|
41009
|
-
// Even if a cleanup function errors, ensure it's cleared.
|
|
41010
|
-
this.cleanup?.clear();
|
|
41011
|
-
}
|
|
41012
|
-
// Prepare to call the user's effect callback. If there was a previous phase, then it gave us
|
|
41013
|
-
// its value as a `Signal`, otherwise `previousValue` will be `undefined`.
|
|
41014
|
-
const args = [];
|
|
41015
|
-
if (previousValue !== undefined) {
|
|
41016
|
-
args.push(previousValue);
|
|
41017
|
-
}
|
|
41018
|
-
args.push(this.registerCleanupFn);
|
|
41019
|
-
// Call the user's callback in our reactive context.
|
|
41020
|
-
const prevConsumer = consumerBeforeComputation$1(this);
|
|
41021
|
-
let newValue;
|
|
41022
|
-
try {
|
|
41023
|
-
newValue = this.userFn.apply(null, args);
|
|
41024
|
-
}
|
|
41025
|
-
finally {
|
|
41026
|
-
consumerAfterComputation$1(this, prevConsumer);
|
|
41027
|
-
}
|
|
41028
|
-
if (this.value === NOT_SET || !this.equal(this.value, newValue)) {
|
|
41029
|
-
this.value = newValue;
|
|
41030
|
-
this.version++;
|
|
41031
|
-
}
|
|
41032
|
-
return this.signal;
|
|
41033
|
-
},
|
|
41034
|
-
}))();
|
|
41035
|
-
/**
|
|
41036
|
-
* An `AfterRenderSequence` that manages an `afterRenderEffect`'s phase effects.
|
|
41037
|
-
*/
|
|
41038
|
-
class AfterRenderEffectSequence extends AfterRenderSequence {
|
|
41039
|
-
scheduler;
|
|
41040
|
-
/**
|
|
41041
|
-
* While this sequence is executing, this tracks the last phase which was called by the
|
|
41042
|
-
* `afterRender` machinery.
|
|
41043
|
-
*
|
|
41044
|
-
* When a phase effect is marked dirty, this is used to determine whether it's already run or not.
|
|
41045
|
-
*/
|
|
41046
|
-
lastPhase = null;
|
|
41047
|
-
/**
|
|
41048
|
-
* The reactive nodes for each phase, if a phase effect is defined for that phase.
|
|
41049
|
-
*
|
|
41050
|
-
* These are initialized to `undefined` but set in the constructor.
|
|
41051
|
-
*/
|
|
41052
|
-
nodes = [undefined, undefined, undefined, undefined];
|
|
41053
|
-
constructor(impl, effectHooks, view, scheduler, destroyRef, snapshot = null) {
|
|
41054
|
-
// Note that we also initialize the underlying `AfterRenderSequence` hooks to `undefined` and
|
|
41055
|
-
// populate them as we create reactive nodes below.
|
|
41056
|
-
super(impl, [undefined, undefined, undefined, undefined], view, false, destroyRef, snapshot);
|
|
41057
|
-
this.scheduler = scheduler;
|
|
41058
|
-
// Setup a reactive node for each phase.
|
|
41059
|
-
for (const phase of AFTER_RENDER_PHASES) {
|
|
41060
|
-
const effectHook = effectHooks[phase];
|
|
41061
|
-
if (effectHook === undefined) {
|
|
41062
|
-
continue;
|
|
41063
|
-
}
|
|
41064
|
-
const node = Object.create(AFTER_RENDER_PHASE_EFFECT_NODE);
|
|
41065
|
-
node.sequence = this;
|
|
41066
|
-
node.phase = phase;
|
|
41067
|
-
node.userFn = effectHook;
|
|
41068
|
-
node.dirty = true;
|
|
41069
|
-
node.signal = (() => {
|
|
41070
|
-
producerAccessed$1(node);
|
|
41071
|
-
return node.value;
|
|
41072
|
-
});
|
|
41073
|
-
node.signal[SIGNAL$1] = node;
|
|
41074
|
-
node.registerCleanupFn = (fn) => (node.cleanup ??= new Set()).add(fn);
|
|
41075
|
-
this.nodes[phase] = node;
|
|
41076
|
-
// Install the upstream hook which runs the `phaseFn` for this phase.
|
|
41077
|
-
this.hooks[phase] = (value) => node.phaseFn(value);
|
|
41078
|
-
}
|
|
41079
|
-
}
|
|
41080
|
-
afterRun() {
|
|
41081
|
-
super.afterRun();
|
|
41082
|
-
// We're done running this sequence, so reset `lastPhase`.
|
|
41083
|
-
this.lastPhase = null;
|
|
41084
|
-
}
|
|
41085
|
-
destroy() {
|
|
41086
|
-
super.destroy();
|
|
41087
|
-
// Run the cleanup functions for each node.
|
|
41088
|
-
for (const node of this.nodes) {
|
|
41089
|
-
for (const fn of node?.cleanup ?? EMPTY_CLEANUP_SET) {
|
|
41090
|
-
fn();
|
|
41091
|
-
}
|
|
41092
|
-
}
|
|
41093
|
-
}
|
|
41094
|
-
}
|
|
41095
|
-
/**
|
|
41096
|
-
* @experimental
|
|
41097
|
-
*/
|
|
41098
|
-
function afterRenderEffect(callbackOrSpec, options) {
|
|
41099
|
-
ngDevMode &&
|
|
41100
|
-
assertNotInReactiveContext(afterRenderEffect, 'Call `afterRenderEffect` outside of a reactive context. For example, create the render ' +
|
|
41101
|
-
'effect inside the component constructor`.');
|
|
41102
|
-
!options?.injector && assertInInjectionContext(afterRenderEffect);
|
|
41103
|
-
if (typeof ngServerMode !== 'undefined' && ngServerMode) {
|
|
41104
|
-
return NOOP_AFTER_RENDER_REF;
|
|
41105
|
-
}
|
|
41106
|
-
const injector = options?.injector ?? inject(Injector);
|
|
41107
|
-
const scheduler = injector.get(ChangeDetectionScheduler);
|
|
41108
|
-
const manager = injector.get(AfterRenderManager);
|
|
41109
|
-
const tracing = injector.get(TracingService, null, { optional: true });
|
|
41110
|
-
manager.impl ??= injector.get(AfterRenderImpl);
|
|
41111
|
-
let spec = callbackOrSpec;
|
|
41112
|
-
if (typeof spec === 'function') {
|
|
41113
|
-
spec = { mixedReadWrite: callbackOrSpec };
|
|
41114
|
-
}
|
|
41115
|
-
const viewContext = injector.get(ViewContext, null, { optional: true });
|
|
41116
|
-
const sequence = new AfterRenderEffectSequence(manager.impl, [spec.earlyRead, spec.write, spec.mixedReadWrite, spec.read], viewContext?.view, scheduler, injector.get(DestroyRef), tracing?.snapshot(null));
|
|
41117
|
-
manager.impl.register(sequence);
|
|
41118
|
-
return sequence;
|
|
41119
|
-
}
|
|
41120
|
-
|
|
41121
|
-
// This file exists to allow the set of reactivity exports to be modified in g3, as these APIs are
|
|
41122
|
-
|
|
41123
40756
|
/**
|
|
41124
40757
|
* Status of a `Resource`.
|
|
41125
40758
|
*
|
|
@@ -41161,6 +40794,30 @@ var ResourceStatus;
|
|
|
41161
40794
|
ResourceStatus[ResourceStatus["Local"] = 5] = "Local";
|
|
41162
40795
|
})(ResourceStatus || (ResourceStatus = {}));
|
|
41163
40796
|
|
|
40797
|
+
const identityFn = (v) => v;
|
|
40798
|
+
function linkedSignal(optionsOrComputation, options) {
|
|
40799
|
+
performanceMarkFeature('NgSignals');
|
|
40800
|
+
if (typeof optionsOrComputation === 'function') {
|
|
40801
|
+
const getter = createLinkedSignal$1(optionsOrComputation, (identityFn), options?.equal);
|
|
40802
|
+
return upgradeLinkedSignalGetter(getter);
|
|
40803
|
+
}
|
|
40804
|
+
else {
|
|
40805
|
+
const getter = createLinkedSignal$1(optionsOrComputation.source, optionsOrComputation.computation, optionsOrComputation.equal);
|
|
40806
|
+
return upgradeLinkedSignalGetter(getter);
|
|
40807
|
+
}
|
|
40808
|
+
}
|
|
40809
|
+
function upgradeLinkedSignalGetter(getter) {
|
|
40810
|
+
if (ngDevMode) {
|
|
40811
|
+
getter.toString = () => `[LinkedSignal: ${getter()}]`;
|
|
40812
|
+
}
|
|
40813
|
+
const node = getter[SIGNAL$1];
|
|
40814
|
+
const upgradedGetter = getter;
|
|
40815
|
+
upgradedGetter.set = (newValue) => linkedSignalSetFn$1(node, newValue);
|
|
40816
|
+
upgradedGetter.update = (updateFn) => linkedSignalUpdateFn$1(node, updateFn);
|
|
40817
|
+
upgradedGetter.asReadonly = signalAsReadonlyFn.bind(getter);
|
|
40818
|
+
return upgradedGetter;
|
|
40819
|
+
}
|
|
40820
|
+
|
|
41164
40821
|
function resource(options) {
|
|
41165
40822
|
options?.injector || assertInInjectionContext(resource);
|
|
41166
40823
|
const request = (options.request ?? (() => null));
|
|
@@ -41429,6 +41086,334 @@ function isResolved(state) {
|
|
|
41429
41086
|
return state.error === undefined;
|
|
41430
41087
|
}
|
|
41431
41088
|
|
|
41089
|
+
/*!
|
|
41090
|
+
* @license
|
|
41091
|
+
* Copyright Google LLC All Rights Reserved.
|
|
41092
|
+
*
|
|
41093
|
+
* Use of this source code is governed by an MIT-style license that can be
|
|
41094
|
+
* found in the LICENSE file at https://angular.dev/license
|
|
41095
|
+
*/
|
|
41096
|
+
/**
|
|
41097
|
+
* Gets the class name of the closest component to a node.
|
|
41098
|
+
* Warning! this function will return minified names if the name of the component is minified. The
|
|
41099
|
+
* consumer of the function is responsible for resolving the minified name to its original name.
|
|
41100
|
+
* @param node Node from which to start the search.
|
|
41101
|
+
*/
|
|
41102
|
+
function getClosestComponentName(node) {
|
|
41103
|
+
let currentNode = node;
|
|
41104
|
+
while (currentNode) {
|
|
41105
|
+
const lView = readPatchedLView(currentNode);
|
|
41106
|
+
if (lView !== null) {
|
|
41107
|
+
for (let i = HEADER_OFFSET; i < lView.length; i++) {
|
|
41108
|
+
const current = lView[i];
|
|
41109
|
+
if ((!isLView(current) && !isLContainer(current)) || current[HOST] !== currentNode) {
|
|
41110
|
+
continue;
|
|
41111
|
+
}
|
|
41112
|
+
const tView = lView[TVIEW];
|
|
41113
|
+
const tNode = getTNode(tView, i);
|
|
41114
|
+
if (isComponentHost(tNode)) {
|
|
41115
|
+
const def = tView.data[tNode.directiveStart + tNode.componentOffset];
|
|
41116
|
+
const name = def.debugInfo?.className || def.type.name;
|
|
41117
|
+
// Note: the name may be an empty string if the class name is
|
|
41118
|
+
// dropped due to minification. In such cases keep going up the tree.
|
|
41119
|
+
if (name) {
|
|
41120
|
+
return name;
|
|
41121
|
+
}
|
|
41122
|
+
else {
|
|
41123
|
+
break;
|
|
41124
|
+
}
|
|
41125
|
+
}
|
|
41126
|
+
}
|
|
41127
|
+
}
|
|
41128
|
+
currentNode = currentNode.parentNode;
|
|
41129
|
+
}
|
|
41130
|
+
return null;
|
|
41131
|
+
}
|
|
41132
|
+
|
|
41133
|
+
/**
|
|
41134
|
+
* Compiles a partial directive declaration object into a full directive definition object.
|
|
41135
|
+
*
|
|
41136
|
+
* @codeGenApi
|
|
41137
|
+
*/
|
|
41138
|
+
function ɵɵngDeclareDirective(decl) {
|
|
41139
|
+
const compiler = getCompilerFacade({
|
|
41140
|
+
usage: 1 /* JitCompilerUsage.PartialDeclaration */,
|
|
41141
|
+
kind: 'directive',
|
|
41142
|
+
type: decl.type,
|
|
41143
|
+
});
|
|
41144
|
+
return compiler.compileDirectiveDeclaration(angularCoreEnv, `ng:///${decl.type.name}/ɵfac.js`, decl);
|
|
41145
|
+
}
|
|
41146
|
+
/**
|
|
41147
|
+
* Evaluates the class metadata declaration.
|
|
41148
|
+
*
|
|
41149
|
+
* @codeGenApi
|
|
41150
|
+
*/
|
|
41151
|
+
function ɵɵngDeclareClassMetadata(decl) {
|
|
41152
|
+
setClassMetadata(decl.type, decl.decorators, decl.ctorParameters ?? null, decl.propDecorators ?? null);
|
|
41153
|
+
}
|
|
41154
|
+
/**
|
|
41155
|
+
* Evaluates the class metadata of a component that contains deferred blocks.
|
|
41156
|
+
*
|
|
41157
|
+
* @codeGenApi
|
|
41158
|
+
*/
|
|
41159
|
+
function ɵɵngDeclareClassMetadataAsync(decl) {
|
|
41160
|
+
setClassMetadataAsync(decl.type, decl.resolveDeferredDeps, (...types) => {
|
|
41161
|
+
const meta = decl.resolveMetadata(...types);
|
|
41162
|
+
setClassMetadata(decl.type, meta.decorators, meta.ctorParameters, meta.propDecorators);
|
|
41163
|
+
});
|
|
41164
|
+
}
|
|
41165
|
+
/**
|
|
41166
|
+
* Compiles a partial component declaration object into a full component definition object.
|
|
41167
|
+
*
|
|
41168
|
+
* @codeGenApi
|
|
41169
|
+
*/
|
|
41170
|
+
function ɵɵngDeclareComponent(decl) {
|
|
41171
|
+
const compiler = getCompilerFacade({
|
|
41172
|
+
usage: 1 /* JitCompilerUsage.PartialDeclaration */,
|
|
41173
|
+
kind: 'component',
|
|
41174
|
+
type: decl.type,
|
|
41175
|
+
});
|
|
41176
|
+
return compiler.compileComponentDeclaration(angularCoreEnv, `ng:///${decl.type.name}/ɵcmp.js`, decl);
|
|
41177
|
+
}
|
|
41178
|
+
/**
|
|
41179
|
+
* Compiles a partial pipe declaration object into a full pipe definition object.
|
|
41180
|
+
*
|
|
41181
|
+
* @codeGenApi
|
|
41182
|
+
*/
|
|
41183
|
+
function ɵɵngDeclareFactory(decl) {
|
|
41184
|
+
const compiler = getCompilerFacade({
|
|
41185
|
+
usage: 1 /* JitCompilerUsage.PartialDeclaration */,
|
|
41186
|
+
kind: getFactoryKind(decl.target),
|
|
41187
|
+
type: decl.type,
|
|
41188
|
+
});
|
|
41189
|
+
return compiler.compileFactoryDeclaration(angularCoreEnv, `ng:///${decl.type.name}/ɵfac.js`, decl);
|
|
41190
|
+
}
|
|
41191
|
+
function getFactoryKind(target) {
|
|
41192
|
+
switch (target) {
|
|
41193
|
+
case FactoryTarget.Directive:
|
|
41194
|
+
return 'directive';
|
|
41195
|
+
case FactoryTarget.Component:
|
|
41196
|
+
return 'component';
|
|
41197
|
+
case FactoryTarget.Injectable:
|
|
41198
|
+
return 'injectable';
|
|
41199
|
+
case FactoryTarget.Pipe:
|
|
41200
|
+
return 'pipe';
|
|
41201
|
+
case FactoryTarget.NgModule:
|
|
41202
|
+
return 'NgModule';
|
|
41203
|
+
}
|
|
41204
|
+
}
|
|
41205
|
+
/**
|
|
41206
|
+
* Compiles a partial injectable declaration object into a full injectable definition object.
|
|
41207
|
+
*
|
|
41208
|
+
* @codeGenApi
|
|
41209
|
+
*/
|
|
41210
|
+
function ɵɵngDeclareInjectable(decl) {
|
|
41211
|
+
const compiler = getCompilerFacade({
|
|
41212
|
+
usage: 1 /* JitCompilerUsage.PartialDeclaration */,
|
|
41213
|
+
kind: 'injectable',
|
|
41214
|
+
type: decl.type,
|
|
41215
|
+
});
|
|
41216
|
+
return compiler.compileInjectableDeclaration(angularCoreEnv, `ng:///${decl.type.name}/ɵprov.js`, decl);
|
|
41217
|
+
}
|
|
41218
|
+
/**
|
|
41219
|
+
* Compiles a partial injector declaration object into a full injector definition object.
|
|
41220
|
+
*
|
|
41221
|
+
* @codeGenApi
|
|
41222
|
+
*/
|
|
41223
|
+
function ɵɵngDeclareInjector(decl) {
|
|
41224
|
+
const compiler = getCompilerFacade({
|
|
41225
|
+
usage: 1 /* JitCompilerUsage.PartialDeclaration */,
|
|
41226
|
+
kind: 'NgModule',
|
|
41227
|
+
type: decl.type,
|
|
41228
|
+
});
|
|
41229
|
+
return compiler.compileInjectorDeclaration(angularCoreEnv, `ng:///${decl.type.name}/ɵinj.js`, decl);
|
|
41230
|
+
}
|
|
41231
|
+
/**
|
|
41232
|
+
* Compiles a partial NgModule declaration object into a full NgModule definition object.
|
|
41233
|
+
*
|
|
41234
|
+
* @codeGenApi
|
|
41235
|
+
*/
|
|
41236
|
+
function ɵɵngDeclareNgModule(decl) {
|
|
41237
|
+
const compiler = getCompilerFacade({
|
|
41238
|
+
usage: 1 /* JitCompilerUsage.PartialDeclaration */,
|
|
41239
|
+
kind: 'NgModule',
|
|
41240
|
+
type: decl.type,
|
|
41241
|
+
});
|
|
41242
|
+
return compiler.compileNgModuleDeclaration(angularCoreEnv, `ng:///${decl.type.name}/ɵmod.js`, decl);
|
|
41243
|
+
}
|
|
41244
|
+
/**
|
|
41245
|
+
* Compiles a partial pipe declaration object into a full pipe definition object.
|
|
41246
|
+
*
|
|
41247
|
+
* @codeGenApi
|
|
41248
|
+
*/
|
|
41249
|
+
function ɵɵngDeclarePipe(decl) {
|
|
41250
|
+
const compiler = getCompilerFacade({
|
|
41251
|
+
usage: 1 /* JitCompilerUsage.PartialDeclaration */,
|
|
41252
|
+
kind: 'pipe',
|
|
41253
|
+
type: decl.type,
|
|
41254
|
+
});
|
|
41255
|
+
return compiler.compilePipeDeclaration(angularCoreEnv, `ng:///${decl.type.name}/ɵpipe.js`, decl);
|
|
41256
|
+
}
|
|
41257
|
+
|
|
41258
|
+
// we reexport these symbols just so that they are retained during the dead code elimination
|
|
41259
|
+
|
|
41260
|
+
const NOT_SET = Symbol('NOT_SET');
|
|
41261
|
+
const EMPTY_CLEANUP_SET = new Set();
|
|
41262
|
+
const AFTER_RENDER_PHASE_EFFECT_NODE = /* @__PURE__ */ (() => ({
|
|
41263
|
+
...SIGNAL_NODE$1,
|
|
41264
|
+
consumerIsAlwaysLive: true,
|
|
41265
|
+
consumerAllowSignalWrites: true,
|
|
41266
|
+
value: NOT_SET,
|
|
41267
|
+
cleanup: null,
|
|
41268
|
+
/** Called when the effect becomes dirty */
|
|
41269
|
+
consumerMarkedDirty() {
|
|
41270
|
+
if (this.sequence.impl.executing) {
|
|
41271
|
+
// If hooks are in the middle of executing, then it matters whether this node has yet been
|
|
41272
|
+
// executed within its sequence. If not, then we don't want to notify the scheduler since
|
|
41273
|
+
// this node will be reached naturally.
|
|
41274
|
+
if (this.sequence.lastPhase === null || this.sequence.lastPhase < this.phase) {
|
|
41275
|
+
return;
|
|
41276
|
+
}
|
|
41277
|
+
// If during the execution of a later phase an earlier phase became dirty, then we should not
|
|
41278
|
+
// run any further phases until the earlier one reruns.
|
|
41279
|
+
this.sequence.erroredOrDestroyed = true;
|
|
41280
|
+
}
|
|
41281
|
+
// Either hooks are not running, or we're marking a node dirty that has already run within its
|
|
41282
|
+
// sequence.
|
|
41283
|
+
this.sequence.scheduler.notify(7 /* NotificationSource.RenderHook */);
|
|
41284
|
+
},
|
|
41285
|
+
phaseFn(previousValue) {
|
|
41286
|
+
this.sequence.lastPhase = this.phase;
|
|
41287
|
+
if (!this.dirty) {
|
|
41288
|
+
return this.signal;
|
|
41289
|
+
}
|
|
41290
|
+
this.dirty = false;
|
|
41291
|
+
if (this.value !== NOT_SET && !consumerPollProducersForChange$1(this)) {
|
|
41292
|
+
// None of our producers report a change since the last time they were read, so no
|
|
41293
|
+
// recomputation of our value is necessary.
|
|
41294
|
+
return this.signal;
|
|
41295
|
+
}
|
|
41296
|
+
// Run any needed cleanup functions.
|
|
41297
|
+
try {
|
|
41298
|
+
for (const cleanupFn of this.cleanup ?? EMPTY_CLEANUP_SET) {
|
|
41299
|
+
cleanupFn();
|
|
41300
|
+
}
|
|
41301
|
+
}
|
|
41302
|
+
finally {
|
|
41303
|
+
// Even if a cleanup function errors, ensure it's cleared.
|
|
41304
|
+
this.cleanup?.clear();
|
|
41305
|
+
}
|
|
41306
|
+
// Prepare to call the user's effect callback. If there was a previous phase, then it gave us
|
|
41307
|
+
// its value as a `Signal`, otherwise `previousValue` will be `undefined`.
|
|
41308
|
+
const args = [];
|
|
41309
|
+
if (previousValue !== undefined) {
|
|
41310
|
+
args.push(previousValue);
|
|
41311
|
+
}
|
|
41312
|
+
args.push(this.registerCleanupFn);
|
|
41313
|
+
// Call the user's callback in our reactive context.
|
|
41314
|
+
const prevConsumer = consumerBeforeComputation$1(this);
|
|
41315
|
+
let newValue;
|
|
41316
|
+
try {
|
|
41317
|
+
newValue = this.userFn.apply(null, args);
|
|
41318
|
+
}
|
|
41319
|
+
finally {
|
|
41320
|
+
consumerAfterComputation$1(this, prevConsumer);
|
|
41321
|
+
}
|
|
41322
|
+
if (this.value === NOT_SET || !this.equal(this.value, newValue)) {
|
|
41323
|
+
this.value = newValue;
|
|
41324
|
+
this.version++;
|
|
41325
|
+
}
|
|
41326
|
+
return this.signal;
|
|
41327
|
+
},
|
|
41328
|
+
}))();
|
|
41329
|
+
/**
|
|
41330
|
+
* An `AfterRenderSequence` that manages an `afterRenderEffect`'s phase effects.
|
|
41331
|
+
*/
|
|
41332
|
+
class AfterRenderEffectSequence extends AfterRenderSequence {
|
|
41333
|
+
scheduler;
|
|
41334
|
+
/**
|
|
41335
|
+
* While this sequence is executing, this tracks the last phase which was called by the
|
|
41336
|
+
* `afterRender` machinery.
|
|
41337
|
+
*
|
|
41338
|
+
* When a phase effect is marked dirty, this is used to determine whether it's already run or not.
|
|
41339
|
+
*/
|
|
41340
|
+
lastPhase = null;
|
|
41341
|
+
/**
|
|
41342
|
+
* The reactive nodes for each phase, if a phase effect is defined for that phase.
|
|
41343
|
+
*
|
|
41344
|
+
* These are initialized to `undefined` but set in the constructor.
|
|
41345
|
+
*/
|
|
41346
|
+
nodes = [undefined, undefined, undefined, undefined];
|
|
41347
|
+
constructor(impl, effectHooks, view, scheduler, destroyRef, snapshot = null) {
|
|
41348
|
+
// Note that we also initialize the underlying `AfterRenderSequence` hooks to `undefined` and
|
|
41349
|
+
// populate them as we create reactive nodes below.
|
|
41350
|
+
super(impl, [undefined, undefined, undefined, undefined], view, false, destroyRef, snapshot);
|
|
41351
|
+
this.scheduler = scheduler;
|
|
41352
|
+
// Setup a reactive node for each phase.
|
|
41353
|
+
for (const phase of AFTER_RENDER_PHASES) {
|
|
41354
|
+
const effectHook = effectHooks[phase];
|
|
41355
|
+
if (effectHook === undefined) {
|
|
41356
|
+
continue;
|
|
41357
|
+
}
|
|
41358
|
+
const node = Object.create(AFTER_RENDER_PHASE_EFFECT_NODE);
|
|
41359
|
+
node.sequence = this;
|
|
41360
|
+
node.phase = phase;
|
|
41361
|
+
node.userFn = effectHook;
|
|
41362
|
+
node.dirty = true;
|
|
41363
|
+
node.signal = (() => {
|
|
41364
|
+
producerAccessed$1(node);
|
|
41365
|
+
return node.value;
|
|
41366
|
+
});
|
|
41367
|
+
node.signal[SIGNAL$1] = node;
|
|
41368
|
+
node.registerCleanupFn = (fn) => (node.cleanup ??= new Set()).add(fn);
|
|
41369
|
+
this.nodes[phase] = node;
|
|
41370
|
+
// Install the upstream hook which runs the `phaseFn` for this phase.
|
|
41371
|
+
this.hooks[phase] = (value) => node.phaseFn(value);
|
|
41372
|
+
}
|
|
41373
|
+
}
|
|
41374
|
+
afterRun() {
|
|
41375
|
+
super.afterRun();
|
|
41376
|
+
// We're done running this sequence, so reset `lastPhase`.
|
|
41377
|
+
this.lastPhase = null;
|
|
41378
|
+
}
|
|
41379
|
+
destroy() {
|
|
41380
|
+
super.destroy();
|
|
41381
|
+
// Run the cleanup functions for each node.
|
|
41382
|
+
for (const node of this.nodes) {
|
|
41383
|
+
for (const fn of node?.cleanup ?? EMPTY_CLEANUP_SET) {
|
|
41384
|
+
fn();
|
|
41385
|
+
}
|
|
41386
|
+
}
|
|
41387
|
+
}
|
|
41388
|
+
}
|
|
41389
|
+
/**
|
|
41390
|
+
* @experimental
|
|
41391
|
+
*/
|
|
41392
|
+
function afterRenderEffect(callbackOrSpec, options) {
|
|
41393
|
+
ngDevMode &&
|
|
41394
|
+
assertNotInReactiveContext(afterRenderEffect, 'Call `afterRenderEffect` outside of a reactive context. For example, create the render ' +
|
|
41395
|
+
'effect inside the component constructor`.');
|
|
41396
|
+
!options?.injector && assertInInjectionContext(afterRenderEffect);
|
|
41397
|
+
if (typeof ngServerMode !== 'undefined' && ngServerMode) {
|
|
41398
|
+
return NOOP_AFTER_RENDER_REF;
|
|
41399
|
+
}
|
|
41400
|
+
const injector = options?.injector ?? inject(Injector);
|
|
41401
|
+
const scheduler = injector.get(ChangeDetectionScheduler);
|
|
41402
|
+
const manager = injector.get(AfterRenderManager);
|
|
41403
|
+
const tracing = injector.get(TracingService, null, { optional: true });
|
|
41404
|
+
manager.impl ??= injector.get(AfterRenderImpl);
|
|
41405
|
+
let spec = callbackOrSpec;
|
|
41406
|
+
if (typeof spec === 'function') {
|
|
41407
|
+
spec = { mixedReadWrite: callbackOrSpec };
|
|
41408
|
+
}
|
|
41409
|
+
const viewContext = injector.get(ViewContext, null, { optional: true });
|
|
41410
|
+
const sequence = new AfterRenderEffectSequence(manager.impl, [spec.earlyRead, spec.write, spec.mixedReadWrite, spec.read], viewContext?.view, scheduler, injector.get(DestroyRef), tracing?.snapshot(null));
|
|
41411
|
+
manager.impl.register(sequence);
|
|
41412
|
+
return sequence;
|
|
41413
|
+
}
|
|
41414
|
+
|
|
41415
|
+
// This file exists to allow the set of reactivity exports to be modified in g3, as these APIs are
|
|
41416
|
+
|
|
41432
41417
|
/**
|
|
41433
41418
|
* Creates a `ComponentRef` instance based on provided component type and a set of options.
|
|
41434
41419
|
*
|
|
@@ -41675,5 +41660,5 @@ if (typeof ngDevMode !== 'undefined' && ngDevMode) {
|
|
|
41675
41660
|
* Generated bundle index. Do not edit.
|
|
41676
41661
|
*/
|
|
41677
41662
|
|
|
41678
|
-
export { ANIMATION_MODULE_TYPE, APP_BOOTSTRAP_LISTENER, APP_ID, APP_INITIALIZER, AfterRenderPhase, ApplicationInitStatus, ApplicationModule, ApplicationRef, Attribute, COMPILER_OPTIONS, CSP_NONCE, CUSTOM_ELEMENTS_SCHEMA, ChangeDetectionStrategy, ChangeDetectorRef, Compiler, CompilerFactory, Component, ComponentFactory$1 as ComponentFactory, ComponentFactoryResolver$1 as ComponentFactoryResolver, ComponentRef$1 as ComponentRef, ContentChild, ContentChildren, DEFAULT_CURRENCY_CODE, DebugElement, DebugEventListener, DebugNode, DefaultIterableDiffer, DestroyRef, Directive, ENVIRONMENT_INITIALIZER, ElementRef, EmbeddedViewRef, EnvironmentInjector, ErrorHandler, EventEmitter, HOST_TAG_NAME, Host, HostAttributeToken, HostBinding, HostListener, INJECTOR$1 as INJECTOR, Inject, InjectFlags, Injectable, InjectionToken, Injector, Input, IterableDiffers, KeyValueDiffers, LOCALE_ID, MissingTranslationStrategy, ModuleWithComponentFactories, NO_ERRORS_SCHEMA, NgModule, NgModuleFactory$1 as NgModuleFactory, NgModuleRef$1 as NgModuleRef, NgProbeToken, NgZone, Optional, Output, OutputEmitterRef, PACKAGE_ROOT_URL, PLATFORM_ID, PLATFORM_INITIALIZER, PendingTasks, Pipe, PlatformRef, Query, QueryList, REQUEST, REQUEST_CONTEXT, RESPONSE_INIT, Renderer2, RendererFactory2, RendererStyleFlags2, ResourceStatus, Sanitizer, SecurityContext, Self, SimpleChange, SkipSelf, TRANSLATIONS, TRANSLATIONS_FORMAT, TemplateRef, Testability, TestabilityRegistry, TransferState, Type, VERSION, Version, ViewChild, ViewChildren, ViewContainerRef, ViewEncapsulation, ViewRef, afterNextRender, afterRender, afterRenderEffect, asNativeElements, assertInInjectionContext, assertNotInReactiveContext, assertPlatform, booleanAttribute, computed, contentChild, contentChildren, createComponent, createEnvironmentInjector, createNgModule, createNgModuleRef, createPlatform, createPlatformFactory, defineInjectable, destroyPlatform, effect, enableProdMode, forwardRef, getDebugNode, getModuleFactory, getNgModuleById, getPlatform, importProvidersFrom, inject, input, isDevMode, isSignal, isStandalone, linkedSignal, makeEnvironmentProviders, makeStateKey, mergeApplicationConfig, model, numberAttribute, output, platformCore, provideAppInitializer, provideEnvironmentInitializer, provideExperimentalCheckNoChangesForDebug, provideExperimentalZonelessChangeDetection, providePlatformInitializer, provideZoneChangeDetection, reflectComponentType, resolveForwardRef, resource, runInInjectionContext, setTestabilityGetter, signal, untracked, viewChild, viewChildren, ALLOW_MULTIPLE_PLATFORMS as ɵALLOW_MULTIPLE_PLATFORMS, AfterRenderManager as ɵAfterRenderManager, CONTAINER_HEADER_OFFSET as ɵCONTAINER_HEADER_OFFSET, ChangeDetectionScheduler as ɵChangeDetectionScheduler, ChangeDetectionSchedulerImpl as ɵChangeDetectionSchedulerImpl, ComponentFactory$1 as ɵComponentFactory, Console as ɵConsole, DEFAULT_LOCALE_ID as ɵDEFAULT_LOCALE_ID, DEFER_BLOCK_CONFIG as ɵDEFER_BLOCK_CONFIG, DEFER_BLOCK_DEPENDENCY_INTERCEPTOR as ɵDEFER_BLOCK_DEPENDENCY_INTERCEPTOR, DeferBlockBehavior as ɵDeferBlockBehavior, DeferBlockState as ɵDeferBlockState, ENABLE_ROOT_COMPONENT_BOOTSTRAP as ɵENABLE_ROOT_COMPONENT_BOOTSTRAP, EffectScheduler as ɵEffectScheduler, IMAGE_CONFIG as ɵIMAGE_CONFIG, IMAGE_CONFIG_DEFAULTS as ɵIMAGE_CONFIG_DEFAULTS, INJECTOR_SCOPE as ɵINJECTOR_SCOPE, ɵINPUT_SIGNAL_BRAND_WRITE_TYPE, INTERNAL_APPLICATION_ERROR_HANDLER as ɵINTERNAL_APPLICATION_ERROR_HANDLER, IS_HYDRATION_DOM_REUSE_ENABLED as ɵIS_HYDRATION_DOM_REUSE_ENABLED, IS_INCREMENTAL_HYDRATION_ENABLED as ɵIS_INCREMENTAL_HYDRATION_ENABLED, JSACTION_EVENT_CONTRACT as ɵJSACTION_EVENT_CONTRACT, LContext as ɵLContext, LocaleDataIndex as ɵLocaleDataIndex, MicrotaskEffectScheduler as ɵMicrotaskEffectScheduler, NG_COMP_DEF as ɵNG_COMP_DEF, NG_DIR_DEF as ɵNG_DIR_DEF, NG_ELEMENT_ID as ɵNG_ELEMENT_ID, NG_INJ_DEF as ɵNG_INJ_DEF, NG_MOD_DEF as ɵNG_MOD_DEF, NG_PIPE_DEF as ɵNG_PIPE_DEF, NG_PROV_DEF as ɵNG_PROV_DEF, NOT_FOUND_CHECK_ONLY_ELEMENT_INJECTOR as ɵNOT_FOUND_CHECK_ONLY_ELEMENT_INJECTOR, NO_CHANGE as ɵNO_CHANGE, NgModuleFactory as ɵNgModuleFactory, NoopNgZone as ɵNoopNgZone, PERFORMANCE_MARK_PREFIX as ɵPERFORMANCE_MARK_PREFIX, PROVIDED_NG_ZONE as ɵPROVIDED_NG_ZONE, PendingTasksInternal as ɵPendingTasksInternal, ReflectionCapabilities as ɵReflectionCapabilities, ComponentFactory as ɵRender3ComponentFactory, ComponentRef as ɵRender3ComponentRef, NgModuleRef as ɵRender3NgModuleRef, RuntimeError as ɵRuntimeError, SSR_CONTENT_INTEGRITY_MARKER as ɵSSR_CONTENT_INTEGRITY_MARKER, TESTABILITY as ɵTESTABILITY, TESTABILITY_GETTER as ɵTESTABILITY_GETTER, TracingAction as ɵTracingAction, TracingService as ɵTracingService, USE_RUNTIME_DEPS_TRACKER_FOR_JIT as ɵUSE_RUNTIME_DEPS_TRACKER_FOR_JIT, ViewRef$1 as ɵViewRef, XSS_SECURITY_URL as ɵXSS_SECURITY_URL, ZONELESS_ENABLED as ɵZONELESS_ENABLED, _sanitizeHtml as ɵ_sanitizeHtml, _sanitizeUrl as ɵ_sanitizeUrl, allowSanitizationBypassAndThrow as ɵallowSanitizationBypassAndThrow, annotateForHydration as ɵannotateForHydration, bypassSanitizationTrustHtml as ɵbypassSanitizationTrustHtml, bypassSanitizationTrustResourceUrl as ɵbypassSanitizationTrustResourceUrl, bypassSanitizationTrustScript as ɵbypassSanitizationTrustScript, bypassSanitizationTrustStyle as ɵbypassSanitizationTrustStyle, bypassSanitizationTrustUrl as ɵbypassSanitizationTrustUrl, clearResolutionOfComponentResourcesQueue as ɵclearResolutionOfComponentResourcesQueue, compileComponent as ɵcompileComponent, compileDirective as ɵcompileDirective, compileNgModule as ɵcompileNgModule, compileNgModuleDefs as ɵcompileNgModuleDefs, compileNgModuleFactory as ɵcompileNgModuleFactory, compilePipe as ɵcompilePipe, convertToBitFlags as ɵconvertToBitFlags, createInjector as ɵcreateInjector, defaultIterableDiffers as ɵdefaultIterableDiffers, defaultKeyValueDiffers as ɵdefaultKeyValueDiffers, depsTracker as ɵdepsTracker, detectChangesInViewIfRequired as ɵdetectChangesInViewIfRequired, devModeEqual as ɵdevModeEqual, disableProfiling as ɵdisableProfiling, enableProfiling as ɵenableProfiling, findLocaleData as ɵfindLocaleData, flushModuleScopingQueueAsMuchAsPossible as ɵflushModuleScopingQueueAsMuchAsPossible, formatRuntimeError as ɵformatRuntimeError, generateStandaloneInDeclarationsError as ɵgenerateStandaloneInDeclarationsError, getAsyncClassMetadataFn as ɵgetAsyncClassMetadataFn, getClosestComponentName as ɵgetClosestComponentName, getDebugNode as ɵgetDebugNode, getDeferBlocks$1 as ɵgetDeferBlocks, getDirectives as ɵgetDirectives, getHostElement as ɵgetHostElement, getInjectableDef as ɵgetInjectableDef, getLContext as ɵgetLContext, getLocaleCurrencyCode as ɵgetLocaleCurrencyCode, getLocalePluralCase as ɵgetLocalePluralCase, getOutputDestroyRef as ɵgetOutputDestroyRef, getSanitizationBypassType as ɵgetSanitizationBypassType, ɵgetUnknownElementStrictMode, ɵgetUnknownPropertyStrictMode, _global as ɵglobal, injectChangeDetectorRef as ɵinjectChangeDetectorRef, internalCreateApplication as ɵinternalCreateApplication, internalProvideZoneChangeDetection as ɵinternalProvideZoneChangeDetection, isBoundToModule as ɵisBoundToModule, isComponentDefPendingResolution as ɵisComponentDefPendingResolution, isEnvironmentProviders as ɵisEnvironmentProviders, isInjectable as ɵisInjectable, isNgModule as ɵisNgModule, isPromise as ɵisPromise, isSubscribable as ɵisSubscribable, microtaskEffect as ɵmicrotaskEffect, noSideEffects as ɵnoSideEffects, patchComponentDefWithScope as ɵpatchComponentDefWithScope, performanceMarkFeature as ɵperformanceMarkFeature, publishExternalGlobalUtil as ɵpublishExternalGlobalUtil, readHydrationInfo as ɵreadHydrationInfo, registerLocaleData as ɵregisterLocaleData, renderDeferBlockState as ɵrenderDeferBlockState, resetCompiledComponents as ɵresetCompiledComponents, resetJitOptions as ɵresetJitOptions, resolveComponentResources as ɵresolveComponentResources, restoreComponentResolutionQueue as ɵrestoreComponentResolutionQueue, setAllowDuplicateNgModuleIdsForTest as ɵsetAllowDuplicateNgModuleIdsForTest, setAlternateWeakRefImpl as ɵsetAlternateWeakRefImpl, ɵsetClassDebugInfo, setClassMetadata as ɵsetClassMetadata, setClassMetadataAsync as ɵsetClassMetadataAsync, setCurrentInjector as ɵsetCurrentInjector, setDocument as ɵsetDocument, setInjectorProfilerContext as ɵsetInjectorProfilerContext, setLocaleId as ɵsetLocaleId, ɵsetUnknownElementStrictMode, ɵsetUnknownPropertyStrictMode, startMeasuring as ɵstartMeasuring, stopMeasuring as ɵstopMeasuring, store as ɵstore, stringify as ɵstringify, transitiveScopesFor as ɵtransitiveScopesFor, triggerResourceLoading as ɵtriggerResourceLoading, truncateMiddle as ɵtruncateMiddle, unregisterAllLocaleData as ɵunregisterLocaleData, unwrapSafeValue as ɵunwrapSafeValue, ɵunwrapWritableSignal, withDomHydration as ɵwithDomHydration, withEventReplay as ɵwithEventReplay, withI18nSupport as ɵwithI18nSupport, withIncrementalHydration as ɵwithIncrementalHydration, ɵɵCopyDefinitionFeature, ɵɵExternalStylesFeature, FactoryTarget as ɵɵFactoryTarget, ɵɵHostDirectivesFeature, ɵɵInheritDefinitionFeature, ɵɵInputTransformsFeature, ɵɵNgOnChangesFeature, ɵɵProvidersFeature, ɵɵadvance, ɵɵattachSourceLocations, ɵɵattribute, ɵɵattributeInterpolate1, ɵɵattributeInterpolate2, ɵɵattributeInterpolate3, ɵɵattributeInterpolate4, ɵɵattributeInterpolate5, ɵɵattributeInterpolate6, ɵɵattributeInterpolate7, ɵɵattributeInterpolate8, ɵɵattributeInterpolateV, ɵɵclassMap, ɵɵclassMapInterpolate1, ɵɵclassMapInterpolate2, ɵɵclassMapInterpolate3, ɵɵclassMapInterpolate4, ɵɵclassMapInterpolate5, ɵɵclassMapInterpolate6, ɵɵclassMapInterpolate7, ɵɵclassMapInterpolate8, ɵɵclassMapInterpolateV, ɵɵclassProp, ɵɵcomponentInstance, ɵɵconditional, ɵɵcontentQuery, ɵɵcontentQuerySignal, ɵɵdeclareLet, ɵɵdefer, ɵɵdeferEnableTimerScheduling, ɵɵdeferHydrateNever, ɵɵdeferHydrateOnHover, ɵɵdeferHydrateOnIdle, ɵɵdeferHydrateOnImmediate, ɵɵdeferHydrateOnInteraction, ɵɵdeferHydrateOnTimer, ɵɵdeferHydrateOnViewport, ɵɵdeferHydrateWhen, ɵɵdeferOnHover, ɵɵdeferOnIdle, ɵɵdeferOnImmediate, ɵɵdeferOnInteraction, ɵɵdeferOnTimer, ɵɵdeferOnViewport, ɵɵdeferPrefetchOnHover, ɵɵdeferPrefetchOnIdle, ɵɵdeferPrefetchOnImmediate, ɵɵdeferPrefetchOnInteraction, ɵɵdeferPrefetchOnTimer, ɵɵdeferPrefetchOnViewport, ɵɵdeferPrefetchWhen, ɵɵdeferWhen, ɵɵdefineComponent, ɵɵdefineDirective, ɵɵdefineInjectable, ɵɵdefineInjector, ɵɵdefineNgModule, ɵɵdefinePipe, ɵɵdirectiveInject, ɵɵdisableBindings, ɵɵelement, ɵɵelementContainer, ɵɵelementContainerEnd, ɵɵelementContainerStart, ɵɵelementEnd, ɵɵelementStart, ɵɵenableBindings, ɵɵgetComponentDepsFactory, ɵɵgetCurrentView, ɵɵgetInheritedFactory, ɵɵhostProperty, ɵɵi18n, ɵɵi18nApply, ɵɵi18nAttributes, ɵɵi18nEnd, ɵɵi18nExp, ɵɵi18nPostprocess, ɵɵi18nStart, ɵɵinject, ɵɵinjectAttribute, ɵɵinvalidFactory, ɵɵinvalidFactoryDep, ɵɵlistener, ɵɵloadQuery, ɵɵnamespaceHTML, ɵɵnamespaceMathML, ɵɵnamespaceSVG, ɵɵnextContext, ɵɵngDeclareClassMetadata, ɵɵngDeclareClassMetadataAsync, ɵɵngDeclareComponent, ɵɵngDeclareDirective, ɵɵngDeclareFactory, ɵɵngDeclareInjectable, ɵɵngDeclareInjector, ɵɵngDeclareNgModule, ɵɵngDeclarePipe, ɵɵpipe, ɵɵpipeBind1, ɵɵpipeBind2, ɵɵpipeBind3, ɵɵpipeBind4, ɵɵpipeBindV, ɵɵprojection, ɵɵprojectionDef, ɵɵproperty, ɵɵpropertyInterpolate, ɵɵpropertyInterpolate1, ɵɵpropertyInterpolate2, ɵɵpropertyInterpolate3, ɵɵpropertyInterpolate4, ɵɵpropertyInterpolate5, ɵɵpropertyInterpolate6, ɵɵpropertyInterpolate7, ɵɵpropertyInterpolate8, ɵɵpropertyInterpolateV, ɵɵpureFunction0, ɵɵpureFunction1, ɵɵpureFunction2, ɵɵpureFunction3, ɵɵpureFunction4, ɵɵpureFunction5, ɵɵpureFunction6, ɵɵpureFunction7, ɵɵpureFunction8, ɵɵpureFunctionV, ɵɵqueryAdvance, ɵɵqueryRefresh, ɵɵreadContextLet, ɵɵreference, registerNgModuleType as ɵɵregisterNgModuleType, ɵɵrepeater, ɵɵrepeaterCreate, ɵɵrepeaterTrackByIdentity, ɵɵrepeaterTrackByIndex, ɵɵreplaceMetadata, ɵɵresetView, ɵɵresolveBody, ɵɵresolveDocument, ɵɵresolveWindow, ɵɵrestoreView, ɵɵsanitizeHtml, ɵɵsanitizeResourceUrl, ɵɵsanitizeScript, ɵɵsanitizeStyle, ɵɵsanitizeUrl, ɵɵsanitizeUrlOrResourceUrl, ɵɵsetComponentScope, ɵɵsetNgModuleScope, ɵɵstoreLet, ɵɵstyleMap, ɵɵstyleMapInterpolate1, ɵɵstyleMapInterpolate2, ɵɵstyleMapInterpolate3, ɵɵstyleMapInterpolate4, ɵɵstyleMapInterpolate5, ɵɵstyleMapInterpolate6, ɵɵstyleMapInterpolate7, ɵɵstyleMapInterpolate8, ɵɵstyleMapInterpolateV, ɵɵstyleProp, ɵɵstylePropInterpolate1, ɵɵstylePropInterpolate2, ɵɵstylePropInterpolate3, ɵɵstylePropInterpolate4, ɵɵstylePropInterpolate5, ɵɵstylePropInterpolate6, ɵɵstylePropInterpolate7, ɵɵstylePropInterpolate8, ɵɵstylePropInterpolateV, ɵɵsyntheticHostListener, ɵɵsyntheticHostProperty, ɵɵtemplate, ɵɵtemplateRefExtractor, ɵɵtext, ɵɵtextInterpolate, ɵɵtextInterpolate1, ɵɵtextInterpolate2, ɵɵtextInterpolate3, ɵɵtextInterpolate4, ɵɵtextInterpolate5, ɵɵtextInterpolate6, ɵɵtextInterpolate7, ɵɵtextInterpolate8, ɵɵtextInterpolateV, ɵɵtrustConstantHtml, ɵɵtrustConstantResourceUrl, ɵɵtwoWayBindingSet, ɵɵtwoWayListener, ɵɵtwoWayProperty, ɵɵvalidateIframeAttribute, ɵɵviewQuery, ɵɵviewQuerySignal };
|
|
41663
|
+
export { ANIMATION_MODULE_TYPE, APP_BOOTSTRAP_LISTENER, APP_ID, APP_INITIALIZER, AfterRenderPhase, ApplicationInitStatus, ApplicationModule, ApplicationRef, Attribute, COMPILER_OPTIONS, CSP_NONCE, CUSTOM_ELEMENTS_SCHEMA, ChangeDetectionStrategy, ChangeDetectorRef, Compiler, CompilerFactory, Component, ComponentFactory$1 as ComponentFactory, ComponentFactoryResolver$1 as ComponentFactoryResolver, ComponentRef$1 as ComponentRef, ContentChild, ContentChildren, DEFAULT_CURRENCY_CODE, DebugElement, DebugEventListener, DebugNode, DefaultIterableDiffer, DestroyRef, Directive, ENVIRONMENT_INITIALIZER, ElementRef, EmbeddedViewRef, EnvironmentInjector, ErrorHandler, EventEmitter, HOST_TAG_NAME, Host, HostAttributeToken, HostBinding, HostListener, INJECTOR$1 as INJECTOR, Inject, InjectFlags, Injectable, InjectionToken, Injector, Input, IterableDiffers, KeyValueDiffers, LOCALE_ID, MissingTranslationStrategy, ModuleWithComponentFactories, NO_ERRORS_SCHEMA, NgModule, NgModuleFactory$1 as NgModuleFactory, NgModuleRef$1 as NgModuleRef, NgProbeToken, NgZone, Optional, Output, OutputEmitterRef, PACKAGE_ROOT_URL, PLATFORM_ID, PLATFORM_INITIALIZER, PendingTasks, Pipe, PlatformRef, Query, QueryList, REQUEST, REQUEST_CONTEXT, RESPONSE_INIT, Renderer2, RendererFactory2, RendererStyleFlags2, ResourceStatus, Sanitizer, SecurityContext, Self, SimpleChange, SkipSelf, TRANSLATIONS, TRANSLATIONS_FORMAT, TemplateRef, Testability, TestabilityRegistry, TransferState, Type, VERSION, Version, ViewChild, ViewChildren, ViewContainerRef, ViewEncapsulation, ViewRef, afterNextRender, afterRender, afterRenderEffect, asNativeElements, assertInInjectionContext, assertNotInReactiveContext, assertPlatform, booleanAttribute, computed, contentChild, contentChildren, createComponent, createEnvironmentInjector, createNgModule, createNgModuleRef, createPlatform, createPlatformFactory, defineInjectable, destroyPlatform, effect, enableProdMode, forwardRef, getDebugNode, getModuleFactory, getNgModuleById, getPlatform, importProvidersFrom, inject, input, isDevMode, isSignal, isStandalone, linkedSignal, makeEnvironmentProviders, makeStateKey, mergeApplicationConfig, model, numberAttribute, output, platformCore, provideAppInitializer, provideEnvironmentInitializer, provideExperimentalCheckNoChangesForDebug, provideExperimentalZonelessChangeDetection, providePlatformInitializer, provideZoneChangeDetection, reflectComponentType, resolveForwardRef, resource, runInInjectionContext, setTestabilityGetter, signal, untracked, viewChild, viewChildren, ALLOW_MULTIPLE_PLATFORMS as ɵALLOW_MULTIPLE_PLATFORMS, AfterRenderManager as ɵAfterRenderManager, CONTAINER_HEADER_OFFSET as ɵCONTAINER_HEADER_OFFSET, ChangeDetectionScheduler as ɵChangeDetectionScheduler, ChangeDetectionSchedulerImpl as ɵChangeDetectionSchedulerImpl, ComponentFactory$1 as ɵComponentFactory, Console as ɵConsole, DEFAULT_LOCALE_ID as ɵDEFAULT_LOCALE_ID, DEFER_BLOCK_CONFIG as ɵDEFER_BLOCK_CONFIG, DEFER_BLOCK_DEPENDENCY_INTERCEPTOR as ɵDEFER_BLOCK_DEPENDENCY_INTERCEPTOR, DeferBlockBehavior as ɵDeferBlockBehavior, DeferBlockState as ɵDeferBlockState, ENABLE_ROOT_COMPONENT_BOOTSTRAP as ɵENABLE_ROOT_COMPONENT_BOOTSTRAP, EffectScheduler as ɵEffectScheduler, IMAGE_CONFIG as ɵIMAGE_CONFIG, IMAGE_CONFIG_DEFAULTS as ɵIMAGE_CONFIG_DEFAULTS, INJECTOR_SCOPE as ɵINJECTOR_SCOPE, ɵINPUT_SIGNAL_BRAND_WRITE_TYPE, INTERNAL_APPLICATION_ERROR_HANDLER as ɵINTERNAL_APPLICATION_ERROR_HANDLER, IS_HYDRATION_DOM_REUSE_ENABLED as ɵIS_HYDRATION_DOM_REUSE_ENABLED, IS_INCREMENTAL_HYDRATION_ENABLED as ɵIS_INCREMENTAL_HYDRATION_ENABLED, JSACTION_EVENT_CONTRACT as ɵJSACTION_EVENT_CONTRACT, LContext as ɵLContext, LocaleDataIndex as ɵLocaleDataIndex, MicrotaskEffectScheduler as ɵMicrotaskEffectScheduler, NG_COMP_DEF as ɵNG_COMP_DEF, NG_DIR_DEF as ɵNG_DIR_DEF, NG_ELEMENT_ID as ɵNG_ELEMENT_ID, NG_INJ_DEF as ɵNG_INJ_DEF, NG_MOD_DEF as ɵNG_MOD_DEF, NG_PIPE_DEF as ɵNG_PIPE_DEF, NG_PROV_DEF as ɵNG_PROV_DEF, NOT_FOUND_CHECK_ONLY_ELEMENT_INJECTOR as ɵNOT_FOUND_CHECK_ONLY_ELEMENT_INJECTOR, NO_CHANGE as ɵNO_CHANGE, NgModuleFactory as ɵNgModuleFactory, NoopNgZone as ɵNoopNgZone, PERFORMANCE_MARK_PREFIX as ɵPERFORMANCE_MARK_PREFIX, PROVIDED_NG_ZONE as ɵPROVIDED_NG_ZONE, PendingTasksInternal as ɵPendingTasksInternal, ReflectionCapabilities as ɵReflectionCapabilities, ComponentFactory as ɵRender3ComponentFactory, ComponentRef as ɵRender3ComponentRef, NgModuleRef as ɵRender3NgModuleRef, ResourceImpl as ɵResourceImpl, RuntimeError as ɵRuntimeError, SSR_CONTENT_INTEGRITY_MARKER as ɵSSR_CONTENT_INTEGRITY_MARKER, TESTABILITY as ɵTESTABILITY, TESTABILITY_GETTER as ɵTESTABILITY_GETTER, TracingAction as ɵTracingAction, TracingService as ɵTracingService, USE_RUNTIME_DEPS_TRACKER_FOR_JIT as ɵUSE_RUNTIME_DEPS_TRACKER_FOR_JIT, ViewRef$1 as ɵViewRef, XSS_SECURITY_URL as ɵXSS_SECURITY_URL, ZONELESS_ENABLED as ɵZONELESS_ENABLED, _sanitizeHtml as ɵ_sanitizeHtml, _sanitizeUrl as ɵ_sanitizeUrl, allowSanitizationBypassAndThrow as ɵallowSanitizationBypassAndThrow, annotateForHydration as ɵannotateForHydration, bypassSanitizationTrustHtml as ɵbypassSanitizationTrustHtml, bypassSanitizationTrustResourceUrl as ɵbypassSanitizationTrustResourceUrl, bypassSanitizationTrustScript as ɵbypassSanitizationTrustScript, bypassSanitizationTrustStyle as ɵbypassSanitizationTrustStyle, bypassSanitizationTrustUrl as ɵbypassSanitizationTrustUrl, clearResolutionOfComponentResourcesQueue as ɵclearResolutionOfComponentResourcesQueue, compileComponent as ɵcompileComponent, compileDirective as ɵcompileDirective, compileNgModule as ɵcompileNgModule, compileNgModuleDefs as ɵcompileNgModuleDefs, compileNgModuleFactory as ɵcompileNgModuleFactory, compilePipe as ɵcompilePipe, convertToBitFlags as ɵconvertToBitFlags, createInjector as ɵcreateInjector, defaultIterableDiffers as ɵdefaultIterableDiffers, defaultKeyValueDiffers as ɵdefaultKeyValueDiffers, depsTracker as ɵdepsTracker, detectChangesInViewIfRequired as ɵdetectChangesInViewIfRequired, devModeEqual as ɵdevModeEqual, disableProfiling as ɵdisableProfiling, enableProfiling as ɵenableProfiling, findLocaleData as ɵfindLocaleData, flushModuleScopingQueueAsMuchAsPossible as ɵflushModuleScopingQueueAsMuchAsPossible, formatRuntimeError as ɵformatRuntimeError, generateStandaloneInDeclarationsError as ɵgenerateStandaloneInDeclarationsError, getAsyncClassMetadataFn as ɵgetAsyncClassMetadataFn, getClosestComponentName as ɵgetClosestComponentName, getDebugNode as ɵgetDebugNode, getDeferBlocks$1 as ɵgetDeferBlocks, getDirectives as ɵgetDirectives, getHostElement as ɵgetHostElement, getInjectableDef as ɵgetInjectableDef, getLContext as ɵgetLContext, getLocaleCurrencyCode as ɵgetLocaleCurrencyCode, getLocalePluralCase as ɵgetLocalePluralCase, getOutputDestroyRef as ɵgetOutputDestroyRef, getSanitizationBypassType as ɵgetSanitizationBypassType, ɵgetUnknownElementStrictMode, ɵgetUnknownPropertyStrictMode, _global as ɵglobal, injectChangeDetectorRef as ɵinjectChangeDetectorRef, internalCreateApplication as ɵinternalCreateApplication, internalProvideZoneChangeDetection as ɵinternalProvideZoneChangeDetection, isBoundToModule as ɵisBoundToModule, isComponentDefPendingResolution as ɵisComponentDefPendingResolution, isEnvironmentProviders as ɵisEnvironmentProviders, isInjectable as ɵisInjectable, isNgModule as ɵisNgModule, isPromise as ɵisPromise, isSubscribable as ɵisSubscribable, microtaskEffect as ɵmicrotaskEffect, noSideEffects as ɵnoSideEffects, patchComponentDefWithScope as ɵpatchComponentDefWithScope, performanceMarkFeature as ɵperformanceMarkFeature, publishExternalGlobalUtil as ɵpublishExternalGlobalUtil, readHydrationInfo as ɵreadHydrationInfo, registerLocaleData as ɵregisterLocaleData, renderDeferBlockState as ɵrenderDeferBlockState, resetCompiledComponents as ɵresetCompiledComponents, resetJitOptions as ɵresetJitOptions, resolveComponentResources as ɵresolveComponentResources, restoreComponentResolutionQueue as ɵrestoreComponentResolutionQueue, setAllowDuplicateNgModuleIdsForTest as ɵsetAllowDuplicateNgModuleIdsForTest, setAlternateWeakRefImpl as ɵsetAlternateWeakRefImpl, ɵsetClassDebugInfo, setClassMetadata as ɵsetClassMetadata, setClassMetadataAsync as ɵsetClassMetadataAsync, setCurrentInjector as ɵsetCurrentInjector, setDocument as ɵsetDocument, setInjectorProfilerContext as ɵsetInjectorProfilerContext, setLocaleId as ɵsetLocaleId, ɵsetUnknownElementStrictMode, ɵsetUnknownPropertyStrictMode, startMeasuring as ɵstartMeasuring, stopMeasuring as ɵstopMeasuring, store as ɵstore, stringify as ɵstringify, transitiveScopesFor as ɵtransitiveScopesFor, triggerResourceLoading as ɵtriggerResourceLoading, truncateMiddle as ɵtruncateMiddle, unregisterAllLocaleData as ɵunregisterLocaleData, unwrapSafeValue as ɵunwrapSafeValue, ɵunwrapWritableSignal, withDomHydration as ɵwithDomHydration, withEventReplay as ɵwithEventReplay, withI18nSupport as ɵwithI18nSupport, withIncrementalHydration as ɵwithIncrementalHydration, ɵɵCopyDefinitionFeature, ɵɵExternalStylesFeature, FactoryTarget as ɵɵFactoryTarget, ɵɵHostDirectivesFeature, ɵɵInheritDefinitionFeature, ɵɵNgOnChangesFeature, ɵɵProvidersFeature, ɵɵadvance, ɵɵattachSourceLocations, ɵɵattribute, ɵɵattributeInterpolate1, ɵɵattributeInterpolate2, ɵɵattributeInterpolate3, ɵɵattributeInterpolate4, ɵɵattributeInterpolate5, ɵɵattributeInterpolate6, ɵɵattributeInterpolate7, ɵɵattributeInterpolate8, ɵɵattributeInterpolateV, ɵɵclassMap, ɵɵclassMapInterpolate1, ɵɵclassMapInterpolate2, ɵɵclassMapInterpolate3, ɵɵclassMapInterpolate4, ɵɵclassMapInterpolate5, ɵɵclassMapInterpolate6, ɵɵclassMapInterpolate7, ɵɵclassMapInterpolate8, ɵɵclassMapInterpolateV, ɵɵclassProp, ɵɵcomponentInstance, ɵɵconditional, ɵɵcontentQuery, ɵɵcontentQuerySignal, ɵɵdeclareLet, ɵɵdefer, ɵɵdeferEnableTimerScheduling, ɵɵdeferHydrateNever, ɵɵdeferHydrateOnHover, ɵɵdeferHydrateOnIdle, ɵɵdeferHydrateOnImmediate, ɵɵdeferHydrateOnInteraction, ɵɵdeferHydrateOnTimer, ɵɵdeferHydrateOnViewport, ɵɵdeferHydrateWhen, ɵɵdeferOnHover, ɵɵdeferOnIdle, ɵɵdeferOnImmediate, ɵɵdeferOnInteraction, ɵɵdeferOnTimer, ɵɵdeferOnViewport, ɵɵdeferPrefetchOnHover, ɵɵdeferPrefetchOnIdle, ɵɵdeferPrefetchOnImmediate, ɵɵdeferPrefetchOnInteraction, ɵɵdeferPrefetchOnTimer, ɵɵdeferPrefetchOnViewport, ɵɵdeferPrefetchWhen, ɵɵdeferWhen, ɵɵdefineComponent, ɵɵdefineDirective, ɵɵdefineInjectable, ɵɵdefineInjector, ɵɵdefineNgModule, ɵɵdefinePipe, ɵɵdirectiveInject, ɵɵdisableBindings, ɵɵelement, ɵɵelementContainer, ɵɵelementContainerEnd, ɵɵelementContainerStart, ɵɵelementEnd, ɵɵelementStart, ɵɵenableBindings, ɵɵgetComponentDepsFactory, ɵɵgetCurrentView, ɵɵgetInheritedFactory, ɵɵhostProperty, ɵɵi18n, ɵɵi18nApply, ɵɵi18nAttributes, ɵɵi18nEnd, ɵɵi18nExp, ɵɵi18nPostprocess, ɵɵi18nStart, ɵɵinject, ɵɵinjectAttribute, ɵɵinvalidFactory, ɵɵinvalidFactoryDep, ɵɵlistener, ɵɵloadQuery, ɵɵnamespaceHTML, ɵɵnamespaceMathML, ɵɵnamespaceSVG, ɵɵnextContext, ɵɵngDeclareClassMetadata, ɵɵngDeclareClassMetadataAsync, ɵɵngDeclareComponent, ɵɵngDeclareDirective, ɵɵngDeclareFactory, ɵɵngDeclareInjectable, ɵɵngDeclareInjector, ɵɵngDeclareNgModule, ɵɵngDeclarePipe, ɵɵpipe, ɵɵpipeBind1, ɵɵpipeBind2, ɵɵpipeBind3, ɵɵpipeBind4, ɵɵpipeBindV, ɵɵprojection, ɵɵprojectionDef, ɵɵproperty, ɵɵpropertyInterpolate, ɵɵpropertyInterpolate1, ɵɵpropertyInterpolate2, ɵɵpropertyInterpolate3, ɵɵpropertyInterpolate4, ɵɵpropertyInterpolate5, ɵɵpropertyInterpolate6, ɵɵpropertyInterpolate7, ɵɵpropertyInterpolate8, ɵɵpropertyInterpolateV, ɵɵpureFunction0, ɵɵpureFunction1, ɵɵpureFunction2, ɵɵpureFunction3, ɵɵpureFunction4, ɵɵpureFunction5, ɵɵpureFunction6, ɵɵpureFunction7, ɵɵpureFunction8, ɵɵpureFunctionV, ɵɵqueryAdvance, ɵɵqueryRefresh, ɵɵreadContextLet, ɵɵreference, registerNgModuleType as ɵɵregisterNgModuleType, ɵɵrepeater, ɵɵrepeaterCreate, ɵɵrepeaterTrackByIdentity, ɵɵrepeaterTrackByIndex, ɵɵreplaceMetadata, ɵɵresetView, ɵɵresolveBody, ɵɵresolveDocument, ɵɵresolveWindow, ɵɵrestoreView, ɵɵsanitizeHtml, ɵɵsanitizeResourceUrl, ɵɵsanitizeScript, ɵɵsanitizeStyle, ɵɵsanitizeUrl, ɵɵsanitizeUrlOrResourceUrl, ɵɵsetComponentScope, ɵɵsetNgModuleScope, ɵɵstoreLet, ɵɵstyleMap, ɵɵstyleMapInterpolate1, ɵɵstyleMapInterpolate2, ɵɵstyleMapInterpolate3, ɵɵstyleMapInterpolate4, ɵɵstyleMapInterpolate5, ɵɵstyleMapInterpolate6, ɵɵstyleMapInterpolate7, ɵɵstyleMapInterpolate8, ɵɵstyleMapInterpolateV, ɵɵstyleProp, ɵɵstylePropInterpolate1, ɵɵstylePropInterpolate2, ɵɵstylePropInterpolate3, ɵɵstylePropInterpolate4, ɵɵstylePropInterpolate5, ɵɵstylePropInterpolate6, ɵɵstylePropInterpolate7, ɵɵstylePropInterpolate8, ɵɵstylePropInterpolateV, ɵɵsyntheticHostListener, ɵɵsyntheticHostProperty, ɵɵtemplate, ɵɵtemplateRefExtractor, ɵɵtext, ɵɵtextInterpolate, ɵɵtextInterpolate1, ɵɵtextInterpolate2, ɵɵtextInterpolate3, ɵɵtextInterpolate4, ɵɵtextInterpolate5, ɵɵtextInterpolate6, ɵɵtextInterpolate7, ɵɵtextInterpolate8, ɵɵtextInterpolateV, ɵɵtrustConstantHtml, ɵɵtrustConstantResourceUrl, ɵɵtwoWayBindingSet, ɵɵtwoWayListener, ɵɵtwoWayProperty, ɵɵvalidateIframeAttribute, ɵɵviewQuery, ɵɵviewQuerySignal };
|
|
41679
41664
|
//# sourceMappingURL=core.mjs.map
|