@angular/router 15.0.0-next.4 → 15.0.0-next.5

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,11 +1,11 @@
1
1
  /**
2
- * @license Angular v15.0.0-next.4
2
+ * @license Angular v15.0.0-next.5
3
3
  * (c) 2010-2022 Google LLC. https://angular.io/
4
4
  * License: MIT
5
5
  */
6
6
 
7
7
  import * as i0 from '@angular/core';
8
- import { ɵisObservable, ɵisPromise, ɵRuntimeError, Injectable, EventEmitter, Directive, Attribute, Output, Component, createEnvironmentInjector, ɵisStandalone, ComponentFactoryResolver, ɵisInjectable, inject, InjectionToken, InjectFlags, NgModuleFactory, Injector, Compiler, NgModuleRef, ɵConsole, NgZone, ɵcoerceToBoolean, Input, HostListener, HostBinding, Optional, ContentChildren, APP_BOOTSTRAP_LISTENER, ApplicationRef, APP_INITIALIZER, ENVIRONMENT_INITIALIZER, NgProbeToken, SkipSelf, NgModule, Inject, Version } from '@angular/core';
8
+ import { ɵisObservable, ɵisPromise, ɵRuntimeError, Injectable, EventEmitter, inject, ViewContainerRef, ChangeDetectorRef, EnvironmentInjector, Directive, Input, Output, Component, createEnvironmentInjector, ɵisStandalone, ComponentFactoryResolver, ɵisInjectable, InjectionToken, InjectFlags, NgModuleFactory, Injector, Compiler, NgModuleRef, ɵConsole, NgZone, ɵcoerceToBoolean, ɵɵsanitizeUrlOrResourceUrl, Attribute, HostBinding, HostListener, Optional, ContentChildren, APP_BOOTSTRAP_LISTENER, ApplicationRef, APP_INITIALIZER, ENVIRONMENT_INITIALIZER, NgProbeToken, SkipSelf, NgModule, Inject, Version } from '@angular/core';
9
9
  import { from, of, BehaviorSubject, EmptyError, combineLatest, concat, defer, pipe, throwError, Observable, EMPTY, ConnectableObservable, Subject } from 'rxjs';
10
10
  import * as i3 from '@angular/common';
11
11
  import { Location, ViewportScroller, LOCATION_INITIALIZED, LocationStrategy, HashLocationStrategy, PathLocationStrategy } from '@angular/common';
@@ -461,9 +461,9 @@ function mapChildrenIntoArray(segment, fn) {
461
461
  */
462
462
  class UrlSerializer {
463
463
  }
464
- UrlSerializer.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.0.0-next.4", ngImport: i0, type: UrlSerializer, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
465
- UrlSerializer.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.0.0-next.4", ngImport: i0, type: UrlSerializer, providedIn: 'root', useFactory: () => new DefaultUrlSerializer() });
466
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.0-next.4", ngImport: i0, type: UrlSerializer, decorators: [{
464
+ UrlSerializer.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.0.0-next.5", ngImport: i0, type: UrlSerializer, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
465
+ UrlSerializer.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.0.0-next.5", ngImport: i0, type: UrlSerializer, providedIn: 'root', useFactory: () => new DefaultUrlSerializer() });
466
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.0-next.5", ngImport: i0, type: UrlSerializer, decorators: [{
467
467
  type: Injectable,
468
468
  args: [{ providedIn: 'root', useFactory: () => new DefaultUrlSerializer() }]
469
469
  }] });
@@ -2394,9 +2394,9 @@ class ChildrenOutletContexts {
2394
2394
  return this.contexts.get(childName) || null;
2395
2395
  }
2396
2396
  }
2397
- ChildrenOutletContexts.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.0.0-next.4", ngImport: i0, type: ChildrenOutletContexts, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
2398
- ChildrenOutletContexts.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.0.0-next.4", ngImport: i0, type: ChildrenOutletContexts, providedIn: 'root' });
2399
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.0-next.4", ngImport: i0, type: ChildrenOutletContexts, decorators: [{
2397
+ ChildrenOutletContexts.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.0.0-next.5", ngImport: i0, type: ChildrenOutletContexts, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
2398
+ ChildrenOutletContexts.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.0.0-next.5", ngImport: i0, type: ChildrenOutletContexts, providedIn: 'root' });
2399
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.0-next.5", ngImport: i0, type: ChildrenOutletContexts, decorators: [{
2400
2400
  type: Injectable,
2401
2401
  args: [{ providedIn: 'root' }]
2402
2402
  }] });
@@ -2461,13 +2461,15 @@ const NG_DEV_MODE$7 = typeof ngDevMode === 'undefined' || ngDevMode;
2461
2461
  * @publicApi
2462
2462
  */
2463
2463
  class RouterOutlet {
2464
- constructor(parentContexts, location, name, changeDetector, environmentInjector) {
2465
- this.parentContexts = parentContexts;
2466
- this.location = location;
2467
- this.changeDetector = changeDetector;
2468
- this.environmentInjector = environmentInjector;
2464
+ constructor() {
2469
2465
  this.activated = null;
2470
2466
  this._activatedRoute = null;
2467
+ /**
2468
+ * The name of the outlet
2469
+ *
2470
+ * @see [named outlets](guide/router-tutorial-toh#displaying-multiple-routes-in-named-outlets)
2471
+ */
2472
+ this.name = PRIMARY_OUTLET;
2471
2473
  this.activateEvents = new EventEmitter();
2472
2474
  this.deactivateEvents = new EventEmitter();
2473
2475
  /**
@@ -2480,32 +2482,60 @@ class RouterOutlet {
2480
2482
  * subtree.
2481
2483
  */
2482
2484
  this.detachEvents = new EventEmitter();
2483
- this.name = name || PRIMARY_OUTLET;
2484
- parentContexts.onChildOutletCreated(this.name, this);
2485
+ this.parentContexts = inject(ChildrenOutletContexts);
2486
+ this.location = inject(ViewContainerRef);
2487
+ this.changeDetector = inject(ChangeDetectorRef);
2488
+ this.environmentInjector = inject(EnvironmentInjector);
2489
+ }
2490
+ /** @nodoc */
2491
+ ngOnChanges(changes) {
2492
+ if (changes['name']) {
2493
+ const { firstChange, previousValue } = changes['name'];
2494
+ if (firstChange) {
2495
+ // The first change is handled by ngOnInit. Because ngOnChanges doesn't get called when no
2496
+ // input is set at all, we need to centrally handle the first change there.
2497
+ return;
2498
+ }
2499
+ // unregister with the old name
2500
+ if (this.isTrackedInParentContexts(previousValue)) {
2501
+ this.deactivate();
2502
+ this.parentContexts.onChildOutletDestroyed(previousValue);
2503
+ }
2504
+ // register the new name
2505
+ this.initializeOutletWithName();
2506
+ }
2485
2507
  }
2486
2508
  /** @nodoc */
2487
2509
  ngOnDestroy() {
2488
- var _a;
2489
2510
  // Ensure that the registered outlet is this one before removing it on the context.
2490
- if (((_a = this.parentContexts.getContext(this.name)) === null || _a === void 0 ? void 0 : _a.outlet) === this) {
2511
+ if (this.isTrackedInParentContexts(this.name)) {
2491
2512
  this.parentContexts.onChildOutletDestroyed(this.name);
2492
2513
  }
2493
2514
  }
2515
+ isTrackedInParentContexts(outletName) {
2516
+ var _a;
2517
+ return ((_a = this.parentContexts.getContext(outletName)) === null || _a === void 0 ? void 0 : _a.outlet) === this;
2518
+ }
2494
2519
  /** @nodoc */
2495
2520
  ngOnInit() {
2496
- if (!this.activated) {
2497
- // If the outlet was not instantiated at the time the route got activated we need to populate
2498
- // the outlet when it is initialized (ie inside a NgIf)
2499
- const context = this.parentContexts.getContext(this.name);
2500
- if (context && context.route) {
2501
- if (context.attachRef) {
2502
- // `attachRef` is populated when there is an existing component to mount
2503
- this.attach(context.attachRef, context.route);
2504
- }
2505
- else {
2506
- // otherwise the component defined in the configuration is created
2507
- this.activateWith(context.route, context.injector);
2508
- }
2521
+ this.initializeOutletWithName();
2522
+ }
2523
+ initializeOutletWithName() {
2524
+ this.parentContexts.onChildOutletCreated(this.name, this);
2525
+ if (this.activated) {
2526
+ return;
2527
+ }
2528
+ // If the outlet was not instantiated at the time the route got activated we need to populate
2529
+ // the outlet when it is initialized (ie inside a NgIf)
2530
+ const context = this.parentContexts.getContext(this.name);
2531
+ if (context === null || context === void 0 ? void 0 : context.route) {
2532
+ if (context.attachRef) {
2533
+ // `attachRef` is populated when there is an existing component to mount
2534
+ this.attach(context.attachRef, context.route);
2535
+ }
2536
+ else {
2537
+ // otherwise the component defined in the configuration is created
2538
+ this.activateWith(context.route, context.injector);
2509
2539
  }
2510
2540
  }
2511
2541
  }
@@ -2587,21 +2617,18 @@ class RouterOutlet {
2587
2617
  this.activateEvents.emit(this.activated.instance);
2588
2618
  }
2589
2619
  }
2590
- RouterOutlet.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.0.0-next.4", ngImport: i0, type: RouterOutlet, deps: [{ token: ChildrenOutletContexts }, { token: i0.ViewContainerRef }, { token: 'name', attribute: true }, { token: i0.ChangeDetectorRef }, { token: i0.EnvironmentInjector }], target: i0.ɵɵFactoryTarget.Directive });
2591
- RouterOutlet.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "15.0.0-next.4", type: RouterOutlet, isStandalone: true, selector: "router-outlet", outputs: { activateEvents: "activate", deactivateEvents: "deactivate", attachEvents: "attach", detachEvents: "detach" }, exportAs: ["outlet"], ngImport: i0 });
2592
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.0-next.4", ngImport: i0, type: RouterOutlet, decorators: [{
2620
+ RouterOutlet.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.0.0-next.5", ngImport: i0, type: RouterOutlet, deps: [], target: i0.ɵɵFactoryTarget.Directive });
2621
+ RouterOutlet.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "15.0.0-next.5", type: RouterOutlet, isStandalone: true, selector: "router-outlet", inputs: { name: "name" }, outputs: { activateEvents: "activate", deactivateEvents: "deactivate", attachEvents: "attach", detachEvents: "detach" }, exportAs: ["outlet"], usesOnChanges: true, ngImport: i0 });
2622
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.0-next.5", ngImport: i0, type: RouterOutlet, decorators: [{
2593
2623
  type: Directive,
2594
2624
  args: [{
2595
2625
  selector: 'router-outlet',
2596
2626
  exportAs: 'outlet',
2597
2627
  standalone: true,
2598
2628
  }]
2599
- }], ctorParameters: function () {
2600
- return [{ type: ChildrenOutletContexts }, { type: i0.ViewContainerRef }, { type: undefined, decorators: [{
2601
- type: Attribute,
2602
- args: ['name']
2603
- }] }, { type: i0.ChangeDetectorRef }, { type: i0.EnvironmentInjector }];
2604
- }, propDecorators: { activateEvents: [{
2629
+ }], propDecorators: { name: [{
2630
+ type: Input
2631
+ }], activateEvents: [{
2605
2632
  type: Output,
2606
2633
  args: ['activate']
2607
2634
  }], deactivateEvents: [{
@@ -2652,9 +2679,9 @@ function isComponentFactoryResolver(item) {
2652
2679
  */
2653
2680
  class ɵEmptyOutletComponent {
2654
2681
  }
2655
- ɵEmptyOutletComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.0.0-next.4", ngImport: i0, type: ɵEmptyOutletComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
2656
- ɵEmptyOutletComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.0.0-next.4", type: ɵEmptyOutletComponent, isStandalone: true, selector: "ng-component", ngImport: i0, template: `<router-outlet></router-outlet>`, isInline: true, dependencies: [{ kind: "directive", type: RouterOutlet, selector: "router-outlet", outputs: ["activate", "deactivate", "attach", "detach"], exportAs: ["outlet"] }] });
2657
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.0-next.4", ngImport: i0, type: ɵEmptyOutletComponent, decorators: [{
2682
+ ɵEmptyOutletComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.0.0-next.5", ngImport: i0, type: ɵEmptyOutletComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
2683
+ ɵEmptyOutletComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.0.0-next.5", type: ɵEmptyOutletComponent, isStandalone: true, selector: "ng-component", ngImport: i0, template: `<router-outlet></router-outlet>`, isInline: true, dependencies: [{ kind: "directive", type: RouterOutlet, selector: "router-outlet", inputs: ["name"], outputs: ["activate", "deactivate", "attach", "detach"], exportAs: ["outlet"] }] });
2684
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.0-next.5", ngImport: i0, type: ɵEmptyOutletComponent, decorators: [{
2658
2685
  type: Component,
2659
2686
  args: [{
2660
2687
  template: `<router-outlet></router-outlet>`,
@@ -4356,9 +4383,9 @@ class TitleStrategy {
4356
4383
  return snapshot.data[RouteTitleKey];
4357
4384
  }
4358
4385
  }
4359
- TitleStrategy.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.0.0-next.4", ngImport: i0, type: TitleStrategy, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
4360
- TitleStrategy.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.0.0-next.4", ngImport: i0, type: TitleStrategy, providedIn: 'root', useFactory: () => inject(DefaultTitleStrategy) });
4361
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.0-next.4", ngImport: i0, type: TitleStrategy, decorators: [{
4386
+ TitleStrategy.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.0.0-next.5", ngImport: i0, type: TitleStrategy, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
4387
+ TitleStrategy.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.0.0-next.5", ngImport: i0, type: TitleStrategy, providedIn: 'root', useFactory: () => inject(DefaultTitleStrategy) });
4388
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.0-next.5", ngImport: i0, type: TitleStrategy, decorators: [{
4362
4389
  type: Injectable,
4363
4390
  args: [{ providedIn: 'root', useFactory: () => inject(DefaultTitleStrategy) }]
4364
4391
  }] });
@@ -4382,9 +4409,9 @@ class DefaultTitleStrategy extends TitleStrategy {
4382
4409
  }
4383
4410
  }
4384
4411
  }
4385
- DefaultTitleStrategy.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.0.0-next.4", ngImport: i0, type: DefaultTitleStrategy, deps: [{ token: i1.Title }], target: i0.ɵɵFactoryTarget.Injectable });
4386
- DefaultTitleStrategy.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.0.0-next.4", ngImport: i0, type: DefaultTitleStrategy, providedIn: 'root' });
4387
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.0-next.4", ngImport: i0, type: DefaultTitleStrategy, decorators: [{
4412
+ DefaultTitleStrategy.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.0.0-next.5", ngImport: i0, type: DefaultTitleStrategy, deps: [{ token: i1.Title }], target: i0.ɵɵFactoryTarget.Injectable });
4413
+ DefaultTitleStrategy.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.0.0-next.5", ngImport: i0, type: DefaultTitleStrategy, providedIn: 'root' });
4414
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.0-next.5", ngImport: i0, type: DefaultTitleStrategy, decorators: [{
4388
4415
  type: Injectable,
4389
4416
  args: [{ providedIn: 'root' }]
4390
4417
  }], ctorParameters: function () { return [{ type: i1.Title }]; } });
@@ -4484,6 +4511,17 @@ const ROUTER_CONFIGURATION = new InjectionToken(NG_DEV_MODE$4 ? 'router config'
4484
4511
  factory: () => ({}),
4485
4512
  });
4486
4513
 
4514
+ /**
4515
+ * @license
4516
+ * Copyright Google LLC All Rights Reserved.
4517
+ *
4518
+ * Use of this source code is governed by an MIT-style license that can be
4519
+ * found in the LICENSE file at https://angular.io/license
4520
+ */
4521
+ function deprecatedLoadChildrenString(injector, loadChildren) {
4522
+ return null;
4523
+ }
4524
+
4487
4525
  /**
4488
4526
  * @license
4489
4527
  * Copyright Google LLC All Rights Reserved.
@@ -4521,7 +4559,7 @@ class RouterConfigLoader {
4521
4559
  this.onLoadStartListener(route);
4522
4560
  }
4523
4561
  const loadRunner = wrapIntoObservable(route.loadComponent())
4524
- .pipe(tap(component => {
4562
+ .pipe(map(maybeUnwrapDefaultExport), tap(component => {
4525
4563
  var _a;
4526
4564
  if (this.onLoadEndListener) {
4527
4565
  this.onLoadEndListener(route);
@@ -4581,7 +4619,12 @@ class RouterConfigLoader {
4581
4619
  return loader;
4582
4620
  }
4583
4621
  loadModuleFactoryOrRoutes(loadChildren) {
4584
- return wrapIntoObservable(loadChildren()).pipe(mergeMap((t) => {
4622
+ const deprecatedResult = deprecatedLoadChildrenString(this.injector, loadChildren);
4623
+ if (deprecatedResult) {
4624
+ return deprecatedResult;
4625
+ }
4626
+ return wrapIntoObservable(loadChildren())
4627
+ .pipe(map(maybeUnwrapDefaultExport), mergeMap((t) => {
4585
4628
  if (t instanceof NgModuleFactory || Array.isArray(t)) {
4586
4629
  return of(t);
4587
4630
  }
@@ -4591,12 +4634,23 @@ class RouterConfigLoader {
4591
4634
  }));
4592
4635
  }
4593
4636
  }
4594
- RouterConfigLoader.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.0.0-next.4", ngImport: i0, type: RouterConfigLoader, deps: [{ token: i0.Injector }, { token: i0.Compiler }], target: i0.ɵɵFactoryTarget.Injectable });
4595
- RouterConfigLoader.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.0.0-next.4", ngImport: i0, type: RouterConfigLoader, providedIn: 'root' });
4596
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.0-next.4", ngImport: i0, type: RouterConfigLoader, decorators: [{
4637
+ RouterConfigLoader.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.0.0-next.5", ngImport: i0, type: RouterConfigLoader, deps: [{ token: i0.Injector }, { token: i0.Compiler }], target: i0.ɵɵFactoryTarget.Injectable });
4638
+ RouterConfigLoader.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.0.0-next.5", ngImport: i0, type: RouterConfigLoader, providedIn: 'root' });
4639
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.0-next.5", ngImport: i0, type: RouterConfigLoader, decorators: [{
4597
4640
  type: Injectable,
4598
4641
  args: [{ providedIn: 'root' }]
4599
4642
  }], ctorParameters: function () { return [{ type: i0.Injector }, { type: i0.Compiler }]; } });
4643
+ function isWrappedDefaultExport(value) {
4644
+ // We use `in` here with a string key `'default'`, because we expect `DefaultExport` objects to be
4645
+ // dynamically imported ES modules with a spec-mandated `default` key. Thus we don't expect that
4646
+ // `default` will be a renamed property.
4647
+ return value && typeof value === 'object' && 'default' in value;
4648
+ }
4649
+ function maybeUnwrapDefaultExport(input) {
4650
+ // As per `isWrappedDefaultExport`, the `default` key here is generated by the browser and not
4651
+ // subject to property renaming, so we reference it with bracket access.
4652
+ return isWrappedDefaultExport(input) ? input['default'] : input;
4653
+ }
4600
4654
 
4601
4655
  /**
4602
4656
  * @license
@@ -5618,9 +5672,9 @@ class Router {
5618
5672
  return { navigationId };
5619
5673
  }
5620
5674
  }
5621
- Router.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.0.0-next.4", ngImport: i0, type: Router, deps: "invalid", target: i0.ɵɵFactoryTarget.Injectable });
5622
- Router.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.0.0-next.4", ngImport: i0, type: Router, providedIn: 'root', useFactory: setupRouter });
5623
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.0-next.4", ngImport: i0, type: Router, decorators: [{
5675
+ Router.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.0.0-next.5", ngImport: i0, type: Router, deps: "invalid", target: i0.ɵɵFactoryTarget.Injectable });
5676
+ Router.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.0.0-next.5", ngImport: i0, type: Router, providedIn: 'root', useFactory: setupRouter });
5677
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.0-next.5", ngImport: i0, type: Router, decorators: [{
5624
5678
  type: Injectable,
5625
5679
  args: [{
5626
5680
  providedIn: 'root',
@@ -5737,19 +5791,36 @@ function isBrowserTriggeredNavigation(source) {
5737
5791
  * @publicApi
5738
5792
  */
5739
5793
  class RouterLink {
5740
- constructor(router, route, tabIndexAttribute, renderer, el) {
5794
+ constructor(router, route, tabIndexAttribute, renderer, el, locationStrategy) {
5741
5795
  this.router = router;
5742
5796
  this.route = route;
5743
5797
  this.tabIndexAttribute = tabIndexAttribute;
5744
5798
  this.renderer = renderer;
5745
5799
  this.el = el;
5800
+ this.locationStrategy = locationStrategy;
5746
5801
  this._preserveFragment = false;
5747
5802
  this._skipLocationChange = false;
5748
5803
  this._replaceUrl = false;
5804
+ /**
5805
+ * Represents an `href` attribute value applied to a host element,
5806
+ * when a host element is `<a>`. For other tags, the value is `null`.
5807
+ */
5808
+ this.href = null;
5749
5809
  this.commands = null;
5750
5810
  /** @internal */
5751
5811
  this.onChanges = new Subject();
5752
- this.setTabIndexIfNotOnNativeEl('0');
5812
+ const tagName = el.nativeElement.tagName;
5813
+ this.isAnchorElement = tagName === 'A' || tagName === 'AREA';
5814
+ if (this.isAnchorElement) {
5815
+ this.subscription = router.events.subscribe((s) => {
5816
+ if (s instanceof NavigationEnd) {
5817
+ this.updateHref();
5818
+ }
5819
+ });
5820
+ }
5821
+ else {
5822
+ this.setTabIndexIfNotOnNativeEl('0');
5823
+ }
5753
5824
  }
5754
5825
  /**
5755
5826
  * Passed to {@link Router#createUrlTree Router#createUrlTree} as part of the
@@ -5792,20 +5863,16 @@ class RouterLink {
5792
5863
  * instantiation.
5793
5864
  */
5794
5865
  setTabIndexIfNotOnNativeEl(newTabIndex) {
5795
- if (this.tabIndexAttribute != null /* both `null` and `undefined` */) {
5866
+ if (this.tabIndexAttribute != null /* both `null` and `undefined` */ || this.isAnchorElement) {
5796
5867
  return;
5797
5868
  }
5798
- const renderer = this.renderer;
5799
- const nativeElement = this.el.nativeElement;
5800
- if (newTabIndex !== null) {
5801
- renderer.setAttribute(nativeElement, 'tabindex', newTabIndex);
5802
- }
5803
- else {
5804
- renderer.removeAttribute(nativeElement, 'tabindex');
5805
- }
5869
+ this.applyAttributeValue('tabindex', newTabIndex);
5806
5870
  }
5807
5871
  /** @nodoc */
5808
5872
  ngOnChanges(changes) {
5873
+ if (this.isAnchorElement) {
5874
+ this.updateHref();
5875
+ }
5809
5876
  // This is subscribed to by `RouterLinkActive` so that it knows to update when there are changes
5810
5877
  // to the RouterLinks it's tracking.
5811
5878
  this.onChanges.next(this);
@@ -5828,17 +5895,63 @@ class RouterLink {
5828
5895
  }
5829
5896
  }
5830
5897
  /** @nodoc */
5831
- onClick() {
5898
+ onClick(button, ctrlKey, shiftKey, altKey, metaKey) {
5832
5899
  if (this.urlTree === null) {
5833
5900
  return true;
5834
5901
  }
5902
+ if (this.isAnchorElement) {
5903
+ if (button !== 0 || ctrlKey || shiftKey || altKey || metaKey) {
5904
+ return true;
5905
+ }
5906
+ if (typeof this.target === 'string' && this.target != '_self') {
5907
+ return true;
5908
+ }
5909
+ }
5835
5910
  const extras = {
5836
5911
  skipLocationChange: this.skipLocationChange,
5837
5912
  replaceUrl: this.replaceUrl,
5838
5913
  state: this.state,
5839
5914
  };
5840
5915
  this.router.navigateByUrl(this.urlTree, extras);
5841
- return true;
5916
+ // Return `false` for `<a>` elements to prevent default action
5917
+ // and cancel the native behavior, since the navigation is handled
5918
+ // by the Router.
5919
+ return !this.isAnchorElement;
5920
+ }
5921
+ /** @nodoc */
5922
+ ngOnDestroy() {
5923
+ var _a;
5924
+ (_a = this.subscription) === null || _a === void 0 ? void 0 : _a.unsubscribe();
5925
+ }
5926
+ updateHref() {
5927
+ var _a;
5928
+ this.href = this.urlTree !== null && this.locationStrategy ?
5929
+ (_a = this.locationStrategy) === null || _a === void 0 ? void 0 : _a.prepareExternalUrl(this.router.serializeUrl(this.urlTree)) :
5930
+ null;
5931
+ const sanitizedValue = this.href === null ?
5932
+ null :
5933
+ // This class represents a directive that can be added to both `<a>` elements,
5934
+ // as well as other elements. As a result, we can't define security context at
5935
+ // compile time. So the security context is deferred to runtime.
5936
+ // The `ɵɵsanitizeUrlOrResourceUrl` selects the necessary sanitizer function
5937
+ // based on the tag and property names. The logic mimics the one from
5938
+ // `packages/compiler/src/schema/dom_security_schema.ts`, which is used at compile time.
5939
+ //
5940
+ // Note: we should investigate whether we can switch to using `@HostBinding('attr.href')`
5941
+ // instead of applying a value via a renderer, after a final merge of the
5942
+ // `RouterLinkWithHref` directive.
5943
+ ɵɵsanitizeUrlOrResourceUrl(this.href, this.el.nativeElement.tagName.toLowerCase(), 'href');
5944
+ this.applyAttributeValue('href', sanitizedValue);
5945
+ }
5946
+ applyAttributeValue(attrName, attrValue) {
5947
+ const renderer = this.renderer;
5948
+ const nativeElement = this.el.nativeElement;
5949
+ if (attrValue !== null) {
5950
+ renderer.setAttribute(nativeElement, attrName, attrValue);
5951
+ }
5952
+ else {
5953
+ renderer.removeAttribute(nativeElement, attrName);
5954
+ }
5842
5955
  }
5843
5956
  get urlTree() {
5844
5957
  if (this.commands === null) {
@@ -5855,9 +5968,9 @@ class RouterLink {
5855
5968
  });
5856
5969
  }
5857
5970
  }
5858
- RouterLink.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.0.0-next.4", ngImport: i0, type: RouterLink, deps: [{ token: Router }, { token: ActivatedRoute }, { token: 'tabindex', attribute: true }, { token: i0.Renderer2 }, { token: i0.ElementRef }], target: i0.ɵɵFactoryTarget.Directive });
5859
- RouterLink.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "15.0.0-next.4", type: RouterLink, isStandalone: true, selector: ":not(a):not(area)[routerLink]", inputs: { queryParams: "queryParams", fragment: "fragment", queryParamsHandling: "queryParamsHandling", state: "state", relativeTo: "relativeTo", preserveFragment: "preserveFragment", skipLocationChange: "skipLocationChange", replaceUrl: "replaceUrl", routerLink: "routerLink" }, host: { listeners: { "click": "onClick()" } }, usesOnChanges: true, ngImport: i0 });
5860
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.0-next.4", ngImport: i0, type: RouterLink, decorators: [{
5971
+ RouterLink.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.0.0-next.5", ngImport: i0, type: RouterLink, deps: [{ token: Router }, { token: ActivatedRoute }, { token: 'tabindex', attribute: true }, { token: i0.Renderer2 }, { token: i0.ElementRef }, { token: i3.LocationStrategy }], target: i0.ɵɵFactoryTarget.Directive });
5972
+ RouterLink.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "15.0.0-next.5", type: RouterLink, isStandalone: true, selector: ":not(a):not(area)[routerLink]", inputs: { target: "target", queryParams: "queryParams", fragment: "fragment", queryParamsHandling: "queryParamsHandling", state: "state", relativeTo: "relativeTo", preserveFragment: "preserveFragment", skipLocationChange: "skipLocationChange", replaceUrl: "replaceUrl", routerLink: "routerLink" }, host: { listeners: { "click": "onClick($event.button,$event.ctrlKey,$event.shiftKey,$event.altKey,$event.metaKey)" }, properties: { "attr.target": "this.target" } }, usesOnChanges: true, ngImport: i0 });
5973
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.0-next.5", ngImport: i0, type: RouterLink, decorators: [{
5861
5974
  type: Directive,
5862
5975
  args: [{
5863
5976
  selector: ':not(a):not(area)[routerLink]',
@@ -5867,8 +5980,13 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.0-next.4",
5867
5980
  return [{ type: Router }, { type: ActivatedRoute }, { type: undefined, decorators: [{
5868
5981
  type: Attribute,
5869
5982
  args: ['tabindex']
5870
- }] }, { type: i0.Renderer2 }, { type: i0.ElementRef }];
5871
- }, propDecorators: { queryParams: [{
5983
+ }] }, { type: i0.Renderer2 }, { type: i0.ElementRef }, { type: i3.LocationStrategy }];
5984
+ }, propDecorators: { target: [{
5985
+ type: HostBinding,
5986
+ args: ['attr.target']
5987
+ }, {
5988
+ type: Input
5989
+ }], queryParams: [{
5872
5990
  type: Input
5873
5991
  }], fragment: [{
5874
5992
  type: Input
@@ -5888,7 +6006,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.0-next.4",
5888
6006
  type: Input
5889
6007
  }], onClick: [{
5890
6008
  type: HostListener,
5891
- args: ['click']
6009
+ args: ['click',
6010
+ ['$event.button', '$event.ctrlKey', '$event.shiftKey', '$event.altKey', '$event.metaKey']]
5892
6011
  }] } });
5893
6012
  /**
5894
6013
  * @description
@@ -5901,159 +6020,17 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.0-next.4",
5901
6020
  *
5902
6021
  * @publicApi
5903
6022
  */
5904
- class RouterLinkWithHref {
5905
- constructor(router, route, locationStrategy) {
5906
- this.router = router;
5907
- this.route = route;
5908
- this.locationStrategy = locationStrategy;
5909
- this._preserveFragment = false;
5910
- this._skipLocationChange = false;
5911
- this._replaceUrl = false;
5912
- this.commands = null;
5913
- // the url displayed on the anchor element.
5914
- // @HostBinding('attr.href') is used rather than @HostBinding() because it removes the
5915
- // href attribute when it becomes `null`.
5916
- this.href = null;
5917
- /** @internal */
5918
- this.onChanges = new Subject();
5919
- this.subscription = router.events.subscribe((s) => {
5920
- if (s instanceof NavigationEnd) {
5921
- this.updateTargetUrlAndHref();
5922
- }
5923
- });
5924
- }
5925
- /**
5926
- * Passed to {@link Router#createUrlTree Router#createUrlTree} as part of the
5927
- * `UrlCreationOptions`.
5928
- * @see {@link UrlCreationOptions#preserveFragment UrlCreationOptions#preserveFragment}
5929
- * @see {@link Router#createUrlTree Router#createUrlTree}
5930
- */
5931
- set preserveFragment(preserveFragment) {
5932
- this._preserveFragment = ɵcoerceToBoolean(preserveFragment);
5933
- }
5934
- get preserveFragment() {
5935
- return this._preserveFragment;
5936
- }
5937
- /**
5938
- * Passed to {@link Router#navigateByUrl Router#navigateByUrl} as part of the
5939
- * `NavigationBehaviorOptions`.
5940
- * @see {@link NavigationBehaviorOptions#skipLocationChange NavigationBehaviorOptions#skipLocationChange}
5941
- * @see {@link Router#navigateByUrl Router#navigateByUrl}
5942
- */
5943
- set skipLocationChange(skipLocationChange) {
5944
- this._skipLocationChange = ɵcoerceToBoolean(skipLocationChange);
5945
- }
5946
- get skipLocationChange() {
5947
- return this._skipLocationChange;
5948
- }
5949
- /**
5950
- * Passed to {@link Router#navigateByUrl Router#navigateByUrl} as part of the
5951
- * `NavigationBehaviorOptions`.
5952
- * @see {@link NavigationBehaviorOptions#replaceUrl NavigationBehaviorOptions#replaceUrl}
5953
- * @see {@link Router#navigateByUrl Router#navigateByUrl}
5954
- */
5955
- set replaceUrl(replaceUrl) {
5956
- this._replaceUrl = ɵcoerceToBoolean(replaceUrl);
5957
- }
5958
- get replaceUrl() {
5959
- return this._replaceUrl;
5960
- }
5961
- /**
5962
- * Commands to pass to {@link Router#createUrlTree Router#createUrlTree}.
5963
- * - **array**: commands to pass to {@link Router#createUrlTree Router#createUrlTree}.
5964
- * - **string**: shorthand for array of commands with just the string, i.e. `['/route']`
5965
- * - **null|undefined**: Disables the link by removing the `href`
5966
- * @see {@link Router#createUrlTree Router#createUrlTree}
5967
- */
5968
- set routerLink(commands) {
5969
- if (commands != null) {
5970
- this.commands = Array.isArray(commands) ? commands : [commands];
5971
- }
5972
- else {
5973
- this.commands = null;
5974
- }
5975
- }
5976
- /** @nodoc */
5977
- ngOnChanges(changes) {
5978
- this.updateTargetUrlAndHref();
5979
- this.onChanges.next(this);
5980
- }
5981
- /** @nodoc */
5982
- ngOnDestroy() {
5983
- this.subscription.unsubscribe();
5984
- }
5985
- /** @nodoc */
5986
- onClick(button, ctrlKey, shiftKey, altKey, metaKey) {
5987
- if (button !== 0 || ctrlKey || shiftKey || altKey || metaKey) {
5988
- return true;
5989
- }
5990
- if (typeof this.target === 'string' && this.target != '_self' || this.urlTree === null) {
5991
- return true;
5992
- }
5993
- const extras = {
5994
- skipLocationChange: this.skipLocationChange,
5995
- replaceUrl: this.replaceUrl,
5996
- state: this.state
5997
- };
5998
- this.router.navigateByUrl(this.urlTree, extras);
5999
- return false;
6000
- }
6001
- updateTargetUrlAndHref() {
6002
- this.href = this.urlTree !== null ?
6003
- this.locationStrategy.prepareExternalUrl(this.router.serializeUrl(this.urlTree)) :
6004
- null;
6005
- }
6006
- get urlTree() {
6007
- if (this.commands === null) {
6008
- return null;
6009
- }
6010
- return this.router.createUrlTree(this.commands, {
6011
- // If the `relativeTo` input is not defined, we want to use `this.route` by default.
6012
- // Otherwise, we should use the value provided by the user in the input.
6013
- relativeTo: this.relativeTo !== undefined ? this.relativeTo : this.route,
6014
- queryParams: this.queryParams,
6015
- fragment: this.fragment,
6016
- queryParamsHandling: this.queryParamsHandling,
6017
- preserveFragment: this.preserveFragment,
6018
- });
6019
- }
6023
+ class RouterLinkWithHref extends RouterLink {
6020
6024
  }
6021
- RouterLinkWithHref.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.0.0-next.4", ngImport: i0, type: RouterLinkWithHref, deps: [{ token: Router }, { token: ActivatedRoute }, { token: i3.LocationStrategy }], target: i0.ɵɵFactoryTarget.Directive });
6022
- RouterLinkWithHref.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "15.0.0-next.4", type: RouterLinkWithHref, isStandalone: true, selector: "a[routerLink],area[routerLink]", inputs: { target: "target", queryParams: "queryParams", fragment: "fragment", queryParamsHandling: "queryParamsHandling", state: "state", relativeTo: "relativeTo", preserveFragment: "preserveFragment", skipLocationChange: "skipLocationChange", replaceUrl: "replaceUrl", routerLink: "routerLink" }, host: { listeners: { "click": "onClick($event.button,$event.ctrlKey,$event.shiftKey,$event.altKey,$event.metaKey)" }, properties: { "attr.target": "this.target", "attr.href": "this.href" } }, usesOnChanges: true, ngImport: i0 });
6023
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.0-next.4", ngImport: i0, type: RouterLinkWithHref, decorators: [{
6025
+ RouterLinkWithHref.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.0.0-next.5", ngImport: i0, type: RouterLinkWithHref, deps: null, target: i0.ɵɵFactoryTarget.Directive });
6026
+ RouterLinkWithHref.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "15.0.0-next.5", type: RouterLinkWithHref, isStandalone: true, selector: "a[routerLink],area[routerLink]", usesInheritance: true, ngImport: i0 });
6027
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.0-next.5", ngImport: i0, type: RouterLinkWithHref, decorators: [{
6024
6028
  type: Directive,
6025
- args: [{ selector: 'a[routerLink],area[routerLink]', standalone: true }]
6026
- }], ctorParameters: function () { return [{ type: Router }, { type: ActivatedRoute }, { type: i3.LocationStrategy }]; }, propDecorators: { target: [{
6027
- type: HostBinding,
6028
- args: ['attr.target']
6029
- }, {
6030
- type: Input
6031
- }], queryParams: [{
6032
- type: Input
6033
- }], fragment: [{
6034
- type: Input
6035
- }], queryParamsHandling: [{
6036
- type: Input
6037
- }], state: [{
6038
- type: Input
6039
- }], relativeTo: [{
6040
- type: Input
6041
- }], href: [{
6042
- type: HostBinding,
6043
- args: ['attr.href']
6044
- }], preserveFragment: [{
6045
- type: Input
6046
- }], skipLocationChange: [{
6047
- type: Input
6048
- }], replaceUrl: [{
6049
- type: Input
6050
- }], routerLink: [{
6051
- type: Input
6052
- }], onClick: [{
6053
- type: HostListener,
6054
- args: ['click',
6055
- ['$event.button', '$event.ctrlKey', '$event.shiftKey', '$event.altKey', '$event.metaKey']]
6056
- }] } });
6029
+ args: [{
6030
+ selector: 'a[routerLink],area[routerLink]',
6031
+ standalone: true,
6032
+ }]
6033
+ }] });
6057
6034
 
6058
6035
  /**
6059
6036
  * @license
@@ -6247,9 +6224,9 @@ class RouterLinkActive {
6247
6224
  this.links.some(isActiveCheckFn) || this.linksWithHrefs.some(isActiveCheckFn);
6248
6225
  }
6249
6226
  }
6250
- RouterLinkActive.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.0.0-next.4", ngImport: i0, type: RouterLinkActive, deps: [{ token: Router }, { token: i0.ElementRef }, { token: i0.Renderer2 }, { token: i0.ChangeDetectorRef }, { token: RouterLink, optional: true }, { token: RouterLinkWithHref, optional: true }], target: i0.ɵɵFactoryTarget.Directive });
6251
- RouterLinkActive.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "15.0.0-next.4", type: RouterLinkActive, isStandalone: true, selector: "[routerLinkActive]", inputs: { routerLinkActiveOptions: "routerLinkActiveOptions", ariaCurrentWhenActive: "ariaCurrentWhenActive", routerLinkActive: "routerLinkActive" }, outputs: { isActiveChange: "isActiveChange" }, queries: [{ propertyName: "links", predicate: RouterLink, descendants: true }, { propertyName: "linksWithHrefs", predicate: RouterLinkWithHref, descendants: true }], exportAs: ["routerLinkActive"], usesOnChanges: true, ngImport: i0 });
6252
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.0-next.4", ngImport: i0, type: RouterLinkActive, decorators: [{
6227
+ RouterLinkActive.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.0.0-next.5", ngImport: i0, type: RouterLinkActive, deps: [{ token: Router }, { token: i0.ElementRef }, { token: i0.Renderer2 }, { token: i0.ChangeDetectorRef }, { token: RouterLink, optional: true }, { token: RouterLinkWithHref, optional: true }], target: i0.ɵɵFactoryTarget.Directive });
6228
+ RouterLinkActive.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "15.0.0-next.5", type: RouterLinkActive, isStandalone: true, selector: "[routerLinkActive]", inputs: { routerLinkActiveOptions: "routerLinkActiveOptions", ariaCurrentWhenActive: "ariaCurrentWhenActive", routerLinkActive: "routerLinkActive" }, outputs: { isActiveChange: "isActiveChange" }, queries: [{ propertyName: "links", predicate: RouterLink, descendants: true }, { propertyName: "linksWithHrefs", predicate: RouterLinkWithHref, descendants: true }], exportAs: ["routerLinkActive"], usesOnChanges: true, ngImport: i0 });
6229
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.0-next.5", ngImport: i0, type: RouterLinkActive, decorators: [{
6253
6230
  type: Directive,
6254
6231
  args: [{
6255
6232
  selector: '[routerLinkActive]',
@@ -6316,9 +6293,9 @@ class PreloadAllModules {
6316
6293
  return fn().pipe(catchError(() => of(null)));
6317
6294
  }
6318
6295
  }
6319
- PreloadAllModules.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.0.0-next.4", ngImport: i0, type: PreloadAllModules, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
6320
- PreloadAllModules.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.0.0-next.4", ngImport: i0, type: PreloadAllModules, providedIn: 'root' });
6321
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.0-next.4", ngImport: i0, type: PreloadAllModules, decorators: [{
6296
+ PreloadAllModules.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.0.0-next.5", ngImport: i0, type: PreloadAllModules, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
6297
+ PreloadAllModules.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.0.0-next.5", ngImport: i0, type: PreloadAllModules, providedIn: 'root' });
6298
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.0-next.5", ngImport: i0, type: PreloadAllModules, decorators: [{
6322
6299
  type: Injectable,
6323
6300
  args: [{ providedIn: 'root' }]
6324
6301
  }] });
@@ -6336,9 +6313,9 @@ class NoPreloading {
6336
6313
  return of(null);
6337
6314
  }
6338
6315
  }
6339
- NoPreloading.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.0.0-next.4", ngImport: i0, type: NoPreloading, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
6340
- NoPreloading.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.0.0-next.4", ngImport: i0, type: NoPreloading, providedIn: 'root' });
6341
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.0-next.4", ngImport: i0, type: NoPreloading, decorators: [{
6316
+ NoPreloading.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.0.0-next.5", ngImport: i0, type: NoPreloading, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
6317
+ NoPreloading.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.0.0-next.5", ngImport: i0, type: NoPreloading, providedIn: 'root' });
6318
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.0-next.5", ngImport: i0, type: NoPreloading, decorators: [{
6342
6319
  type: Injectable,
6343
6320
  args: [{ providedIn: 'root' }]
6344
6321
  }] });
@@ -6434,9 +6411,9 @@ class RouterPreloader {
6434
6411
  });
6435
6412
  }
6436
6413
  }
6437
- RouterPreloader.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.0.0-next.4", ngImport: i0, type: RouterPreloader, deps: [{ token: Router }, { token: i0.Compiler }, { token: i0.EnvironmentInjector }, { token: PreloadingStrategy }, { token: RouterConfigLoader }], target: i0.ɵɵFactoryTarget.Injectable });
6438
- RouterPreloader.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.0.0-next.4", ngImport: i0, type: RouterPreloader, providedIn: 'root' });
6439
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.0-next.4", ngImport: i0, type: RouterPreloader, decorators: [{
6414
+ RouterPreloader.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.0.0-next.5", ngImport: i0, type: RouterPreloader, deps: [{ token: Router }, { token: i0.Compiler }, { token: i0.EnvironmentInjector }, { token: PreloadingStrategy }, { token: RouterConfigLoader }], target: i0.ɵɵFactoryTarget.Injectable });
6415
+ RouterPreloader.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.0.0-next.5", ngImport: i0, type: RouterPreloader, providedIn: 'root' });
6416
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.0-next.5", ngImport: i0, type: RouterPreloader, decorators: [{
6440
6417
  type: Injectable,
6441
6418
  args: [{ providedIn: 'root' }]
6442
6419
  }], ctorParameters: function () { return [{ type: Router }, { type: i0.Compiler }, { type: i0.EnvironmentInjector }, { type: PreloadingStrategy }, { type: RouterConfigLoader }]; } });
@@ -6517,9 +6494,9 @@ class RouterScroller {
6517
6494
  }
6518
6495
  }
6519
6496
  }
6520
- RouterScroller.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.0.0-next.4", ngImport: i0, type: RouterScroller, deps: "invalid", target: i0.ɵɵFactoryTarget.Injectable });
6521
- RouterScroller.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.0.0-next.4", ngImport: i0, type: RouterScroller });
6522
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.0-next.4", ngImport: i0, type: RouterScroller, decorators: [{
6497
+ RouterScroller.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.0.0-next.5", ngImport: i0, type: RouterScroller, deps: "invalid", target: i0.ɵɵFactoryTarget.Injectable });
6498
+ RouterScroller.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.0.0-next.5", ngImport: i0, type: RouterScroller });
6499
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.0-next.5", ngImport: i0, type: RouterScroller, decorators: [{
6523
6500
  type: Injectable
6524
6501
  }], ctorParameters: function () { return [{ type: Router }, { type: i3.ViewportScroller }, { type: undefined }]; } });
6525
6502
 
@@ -7048,10 +7025,10 @@ class RouterModule {
7048
7025
  return { ngModule: RouterModule, providers: [provideRoutes(routes)] };
7049
7026
  }
7050
7027
  }
7051
- RouterModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.0.0-next.4", ngImport: i0, type: RouterModule, deps: [{ token: ROUTER_FORROOT_GUARD, optional: true }], target: i0.ɵɵFactoryTarget.NgModule });
7052
- RouterModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "15.0.0-next.4", ngImport: i0, type: RouterModule, imports: [RouterOutlet, RouterLink, RouterLinkWithHref, RouterLinkActive, ɵEmptyOutletComponent], exports: [RouterOutlet, RouterLink, RouterLinkWithHref, RouterLinkActive, ɵEmptyOutletComponent] });
7053
- RouterModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "15.0.0-next.4", ngImport: i0, type: RouterModule, imports: [ɵEmptyOutletComponent] });
7054
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.0-next.4", ngImport: i0, type: RouterModule, decorators: [{
7028
+ RouterModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.0.0-next.5", ngImport: i0, type: RouterModule, deps: [{ token: ROUTER_FORROOT_GUARD, optional: true }], target: i0.ɵɵFactoryTarget.NgModule });
7029
+ RouterModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "15.0.0-next.5", ngImport: i0, type: RouterModule, imports: [RouterOutlet, RouterLink, RouterLinkWithHref, RouterLinkActive, ɵEmptyOutletComponent], exports: [RouterOutlet, RouterLink, RouterLinkWithHref, RouterLinkActive, ɵEmptyOutletComponent] });
7030
+ RouterModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "15.0.0-next.5", ngImport: i0, type: RouterModule, imports: [ɵEmptyOutletComponent] });
7031
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.0-next.5", ngImport: i0, type: RouterModule, decorators: [{
7055
7032
  type: NgModule,
7056
7033
  args: [{
7057
7034
  imports: ROUTER_DIRECTIVES,
@@ -7137,7 +7114,7 @@ function provideRouterInitializer() {
7137
7114
  /**
7138
7115
  * @publicApi
7139
7116
  */
7140
- const VERSION = new Version('15.0.0-next.4');
7117
+ const VERSION = new Version('15.0.0-next.5');
7141
7118
 
7142
7119
  /**
7143
7120
  * @license