@angular/router 15.0.0-next.3 → 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.
- package/esm2020/src/components/empty_outlet.mjs +3 -3
- package/esm2020/src/deprecated_load_children.mjs +11 -0
- package/esm2020/src/directives/router_link.mjs +92 -171
- package/esm2020/src/directives/router_link_active.mjs +3 -3
- package/esm2020/src/directives/router_outlet.mjs +59 -31
- package/esm2020/src/index.mjs +1 -1
- package/esm2020/src/models.mjs +1 -1
- package/esm2020/src/page_title_strategy.mjs +6 -6
- package/esm2020/src/private_export.mjs +1 -1
- package/esm2020/src/router.mjs +3 -3
- package/esm2020/src/router_config_loader.mjs +23 -6
- package/esm2020/src/router_module.mjs +4 -4
- package/esm2020/src/router_outlet_context.mjs +3 -3
- package/esm2020/src/router_preloader.mjs +9 -9
- package/esm2020/src/router_scroller.mjs +3 -3
- package/esm2020/src/router_state.mjs +7 -3
- package/esm2020/src/url_tree.mjs +3 -3
- package/esm2020/src/version.mjs +1 -1
- package/esm2020/testing/src/router_testing_module.mjs +4 -4
- package/fesm2015/router.mjs +230 -249
- package/fesm2015/router.mjs.map +1 -1
- package/fesm2015/testing.mjs +5 -5
- package/fesm2015/upgrade.mjs +1 -1
- package/fesm2020/router.mjs +225 -244
- package/fesm2020/router.mjs.map +1 -1
- package/fesm2020/testing.mjs +5 -5
- package/fesm2020/upgrade.mjs +1 -1
- package/index.d.ts +77 -112
- package/package.json +4 -4
- package/testing/index.d.ts +1 -1
- package/upgrade/index.d.ts +1 -1
package/fesm2020/router.mjs
CHANGED
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* @license Angular v15.0.0-next.
|
|
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,
|
|
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.
|
|
465
|
-
UrlSerializer.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.0.0-next.
|
|
466
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.0-next.
|
|
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
|
}] });
|
|
@@ -2093,14 +2093,18 @@ class ActivatedRouteSnapshot {
|
|
|
2093
2093
|
this.data = data;
|
|
2094
2094
|
this.outlet = outlet;
|
|
2095
2095
|
this.component = component;
|
|
2096
|
-
/** The resolved route title */
|
|
2097
|
-
this.title = this.data?.[RouteTitleKey];
|
|
2098
2096
|
this.routeConfig = routeConfig;
|
|
2099
2097
|
this._urlSegment = urlSegment;
|
|
2100
2098
|
this._lastPathIndex = lastPathIndex;
|
|
2101
2099
|
this._correctedLastPathIndex = correctedLastPathIndex ?? lastPathIndex;
|
|
2102
2100
|
this._resolve = resolve;
|
|
2103
2101
|
}
|
|
2102
|
+
/** The resolved route title */
|
|
2103
|
+
get title() {
|
|
2104
|
+
// Note: This _must_ be a getter because the data is mutated in the resolvers. Title will not be
|
|
2105
|
+
// available at the time of class instantiation.
|
|
2106
|
+
return this.data?.[RouteTitleKey];
|
|
2107
|
+
}
|
|
2104
2108
|
/** The root of the router state */
|
|
2105
2109
|
get root() {
|
|
2106
2110
|
return this._routerState.root;
|
|
@@ -2384,9 +2388,9 @@ class ChildrenOutletContexts {
|
|
|
2384
2388
|
return this.contexts.get(childName) || null;
|
|
2385
2389
|
}
|
|
2386
2390
|
}
|
|
2387
|
-
ChildrenOutletContexts.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.0.0-next.
|
|
2388
|
-
ChildrenOutletContexts.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.0.0-next.
|
|
2389
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.0-next.
|
|
2391
|
+
ChildrenOutletContexts.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.0.0-next.5", ngImport: i0, type: ChildrenOutletContexts, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
|
|
2392
|
+
ChildrenOutletContexts.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.0.0-next.5", ngImport: i0, type: ChildrenOutletContexts, providedIn: 'root' });
|
|
2393
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.0-next.5", ngImport: i0, type: ChildrenOutletContexts, decorators: [{
|
|
2390
2394
|
type: Injectable,
|
|
2391
2395
|
args: [{ providedIn: 'root' }]
|
|
2392
2396
|
}] });
|
|
@@ -2451,13 +2455,15 @@ const NG_DEV_MODE$7 = typeof ngDevMode === 'undefined' || ngDevMode;
|
|
|
2451
2455
|
* @publicApi
|
|
2452
2456
|
*/
|
|
2453
2457
|
class RouterOutlet {
|
|
2454
|
-
constructor(
|
|
2455
|
-
this.parentContexts = parentContexts;
|
|
2456
|
-
this.location = location;
|
|
2457
|
-
this.changeDetector = changeDetector;
|
|
2458
|
-
this.environmentInjector = environmentInjector;
|
|
2458
|
+
constructor() {
|
|
2459
2459
|
this.activated = null;
|
|
2460
2460
|
this._activatedRoute = null;
|
|
2461
|
+
/**
|
|
2462
|
+
* The name of the outlet
|
|
2463
|
+
*
|
|
2464
|
+
* @see [named outlets](guide/router-tutorial-toh#displaying-multiple-routes-in-named-outlets)
|
|
2465
|
+
*/
|
|
2466
|
+
this.name = PRIMARY_OUTLET;
|
|
2461
2467
|
this.activateEvents = new EventEmitter();
|
|
2462
2468
|
this.deactivateEvents = new EventEmitter();
|
|
2463
2469
|
/**
|
|
@@ -2470,31 +2476,59 @@ class RouterOutlet {
|
|
|
2470
2476
|
* subtree.
|
|
2471
2477
|
*/
|
|
2472
2478
|
this.detachEvents = new EventEmitter();
|
|
2473
|
-
this.
|
|
2474
|
-
|
|
2479
|
+
this.parentContexts = inject(ChildrenOutletContexts);
|
|
2480
|
+
this.location = inject(ViewContainerRef);
|
|
2481
|
+
this.changeDetector = inject(ChangeDetectorRef);
|
|
2482
|
+
this.environmentInjector = inject(EnvironmentInjector);
|
|
2483
|
+
}
|
|
2484
|
+
/** @nodoc */
|
|
2485
|
+
ngOnChanges(changes) {
|
|
2486
|
+
if (changes['name']) {
|
|
2487
|
+
const { firstChange, previousValue } = changes['name'];
|
|
2488
|
+
if (firstChange) {
|
|
2489
|
+
// The first change is handled by ngOnInit. Because ngOnChanges doesn't get called when no
|
|
2490
|
+
// input is set at all, we need to centrally handle the first change there.
|
|
2491
|
+
return;
|
|
2492
|
+
}
|
|
2493
|
+
// unregister with the old name
|
|
2494
|
+
if (this.isTrackedInParentContexts(previousValue)) {
|
|
2495
|
+
this.deactivate();
|
|
2496
|
+
this.parentContexts.onChildOutletDestroyed(previousValue);
|
|
2497
|
+
}
|
|
2498
|
+
// register the new name
|
|
2499
|
+
this.initializeOutletWithName();
|
|
2500
|
+
}
|
|
2475
2501
|
}
|
|
2476
2502
|
/** @nodoc */
|
|
2477
2503
|
ngOnDestroy() {
|
|
2478
2504
|
// Ensure that the registered outlet is this one before removing it on the context.
|
|
2479
|
-
if (this.
|
|
2505
|
+
if (this.isTrackedInParentContexts(this.name)) {
|
|
2480
2506
|
this.parentContexts.onChildOutletDestroyed(this.name);
|
|
2481
2507
|
}
|
|
2482
2508
|
}
|
|
2509
|
+
isTrackedInParentContexts(outletName) {
|
|
2510
|
+
return this.parentContexts.getContext(outletName)?.outlet === this;
|
|
2511
|
+
}
|
|
2483
2512
|
/** @nodoc */
|
|
2484
2513
|
ngOnInit() {
|
|
2485
|
-
|
|
2486
|
-
|
|
2487
|
-
|
|
2488
|
-
|
|
2489
|
-
|
|
2490
|
-
|
|
2491
|
-
|
|
2492
|
-
|
|
2493
|
-
|
|
2494
|
-
|
|
2495
|
-
|
|
2496
|
-
|
|
2497
|
-
|
|
2514
|
+
this.initializeOutletWithName();
|
|
2515
|
+
}
|
|
2516
|
+
initializeOutletWithName() {
|
|
2517
|
+
this.parentContexts.onChildOutletCreated(this.name, this);
|
|
2518
|
+
if (this.activated) {
|
|
2519
|
+
return;
|
|
2520
|
+
}
|
|
2521
|
+
// If the outlet was not instantiated at the time the route got activated we need to populate
|
|
2522
|
+
// the outlet when it is initialized (ie inside a NgIf)
|
|
2523
|
+
const context = this.parentContexts.getContext(this.name);
|
|
2524
|
+
if (context?.route) {
|
|
2525
|
+
if (context.attachRef) {
|
|
2526
|
+
// `attachRef` is populated when there is an existing component to mount
|
|
2527
|
+
this.attach(context.attachRef, context.route);
|
|
2528
|
+
}
|
|
2529
|
+
else {
|
|
2530
|
+
// otherwise the component defined in the configuration is created
|
|
2531
|
+
this.activateWith(context.route, context.injector);
|
|
2498
2532
|
}
|
|
2499
2533
|
}
|
|
2500
2534
|
}
|
|
@@ -2576,19 +2610,18 @@ class RouterOutlet {
|
|
|
2576
2610
|
this.activateEvents.emit(this.activated.instance);
|
|
2577
2611
|
}
|
|
2578
2612
|
}
|
|
2579
|
-
RouterOutlet.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.0.0-next.
|
|
2580
|
-
RouterOutlet.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "15.0.0-next.
|
|
2581
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.0-next.
|
|
2613
|
+
RouterOutlet.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.0.0-next.5", ngImport: i0, type: RouterOutlet, deps: [], target: i0.ɵɵFactoryTarget.Directive });
|
|
2614
|
+
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 });
|
|
2615
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.0-next.5", ngImport: i0, type: RouterOutlet, decorators: [{
|
|
2582
2616
|
type: Directive,
|
|
2583
2617
|
args: [{
|
|
2584
2618
|
selector: 'router-outlet',
|
|
2585
2619
|
exportAs: 'outlet',
|
|
2586
2620
|
standalone: true,
|
|
2587
2621
|
}]
|
|
2588
|
-
}],
|
|
2589
|
-
|
|
2590
|
-
|
|
2591
|
-
}] }, { type: i0.ChangeDetectorRef }, { type: i0.EnvironmentInjector }]; }, propDecorators: { activateEvents: [{
|
|
2622
|
+
}], propDecorators: { name: [{
|
|
2623
|
+
type: Input
|
|
2624
|
+
}], activateEvents: [{
|
|
2592
2625
|
type: Output,
|
|
2593
2626
|
args: ['activate']
|
|
2594
2627
|
}], deactivateEvents: [{
|
|
@@ -2639,9 +2672,9 @@ function isComponentFactoryResolver(item) {
|
|
|
2639
2672
|
*/
|
|
2640
2673
|
class ɵEmptyOutletComponent {
|
|
2641
2674
|
}
|
|
2642
|
-
ɵEmptyOutletComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.0.0-next.
|
|
2643
|
-
ɵEmptyOutletComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.0.0-next.
|
|
2644
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.0-next.
|
|
2675
|
+
ɵEmptyOutletComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.0.0-next.5", ngImport: i0, type: ɵEmptyOutletComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
2676
|
+
ɵ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"] }] });
|
|
2677
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.0-next.5", ngImport: i0, type: ɵEmptyOutletComponent, decorators: [{
|
|
2645
2678
|
type: Component,
|
|
2646
2679
|
args: [{
|
|
2647
2680
|
template: `<router-outlet></router-outlet>`,
|
|
@@ -4327,9 +4360,9 @@ class TitleStrategy {
|
|
|
4327
4360
|
return snapshot.data[RouteTitleKey];
|
|
4328
4361
|
}
|
|
4329
4362
|
}
|
|
4330
|
-
TitleStrategy.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.0.0-next.
|
|
4331
|
-
TitleStrategy.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.0.0-next.
|
|
4332
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.0-next.
|
|
4363
|
+
TitleStrategy.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.0.0-next.5", ngImport: i0, type: TitleStrategy, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
|
|
4364
|
+
TitleStrategy.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.0.0-next.5", ngImport: i0, type: TitleStrategy, providedIn: 'root', useFactory: () => inject(DefaultTitleStrategy) });
|
|
4365
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.0-next.5", ngImport: i0, type: TitleStrategy, decorators: [{
|
|
4333
4366
|
type: Injectable,
|
|
4334
4367
|
args: [{ providedIn: 'root', useFactory: () => inject(DefaultTitleStrategy) }]
|
|
4335
4368
|
}] });
|
|
@@ -4353,9 +4386,9 @@ class DefaultTitleStrategy extends TitleStrategy {
|
|
|
4353
4386
|
}
|
|
4354
4387
|
}
|
|
4355
4388
|
}
|
|
4356
|
-
DefaultTitleStrategy.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.0.0-next.
|
|
4357
|
-
DefaultTitleStrategy.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.0.0-next.
|
|
4358
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.0-next.
|
|
4389
|
+
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 });
|
|
4390
|
+
DefaultTitleStrategy.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.0.0-next.5", ngImport: i0, type: DefaultTitleStrategy, providedIn: 'root' });
|
|
4391
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.0-next.5", ngImport: i0, type: DefaultTitleStrategy, decorators: [{
|
|
4359
4392
|
type: Injectable,
|
|
4360
4393
|
args: [{ providedIn: 'root' }]
|
|
4361
4394
|
}], ctorParameters: function () { return [{ type: i1.Title }]; } });
|
|
@@ -4455,6 +4488,17 @@ const ROUTER_CONFIGURATION = new InjectionToken(NG_DEV_MODE$4 ? 'router config'
|
|
|
4455
4488
|
factory: () => ({}),
|
|
4456
4489
|
});
|
|
4457
4490
|
|
|
4491
|
+
/**
|
|
4492
|
+
* @license
|
|
4493
|
+
* Copyright Google LLC All Rights Reserved.
|
|
4494
|
+
*
|
|
4495
|
+
* Use of this source code is governed by an MIT-style license that can be
|
|
4496
|
+
* found in the LICENSE file at https://angular.io/license
|
|
4497
|
+
*/
|
|
4498
|
+
function deprecatedLoadChildrenString(injector, loadChildren) {
|
|
4499
|
+
return null;
|
|
4500
|
+
}
|
|
4501
|
+
|
|
4458
4502
|
/**
|
|
4459
4503
|
* @license
|
|
4460
4504
|
* Copyright Google LLC All Rights Reserved.
|
|
@@ -4492,7 +4536,7 @@ class RouterConfigLoader {
|
|
|
4492
4536
|
this.onLoadStartListener(route);
|
|
4493
4537
|
}
|
|
4494
4538
|
const loadRunner = wrapIntoObservable(route.loadComponent())
|
|
4495
|
-
.pipe(tap(component => {
|
|
4539
|
+
.pipe(map(maybeUnwrapDefaultExport), tap(component => {
|
|
4496
4540
|
if (this.onLoadEndListener) {
|
|
4497
4541
|
this.onLoadEndListener(route);
|
|
4498
4542
|
}
|
|
@@ -4551,7 +4595,12 @@ class RouterConfigLoader {
|
|
|
4551
4595
|
return loader;
|
|
4552
4596
|
}
|
|
4553
4597
|
loadModuleFactoryOrRoutes(loadChildren) {
|
|
4554
|
-
|
|
4598
|
+
const deprecatedResult = deprecatedLoadChildrenString(this.injector, loadChildren);
|
|
4599
|
+
if (deprecatedResult) {
|
|
4600
|
+
return deprecatedResult;
|
|
4601
|
+
}
|
|
4602
|
+
return wrapIntoObservable(loadChildren())
|
|
4603
|
+
.pipe(map(maybeUnwrapDefaultExport), mergeMap((t) => {
|
|
4555
4604
|
if (t instanceof NgModuleFactory || Array.isArray(t)) {
|
|
4556
4605
|
return of(t);
|
|
4557
4606
|
}
|
|
@@ -4561,12 +4610,23 @@ class RouterConfigLoader {
|
|
|
4561
4610
|
}));
|
|
4562
4611
|
}
|
|
4563
4612
|
}
|
|
4564
|
-
RouterConfigLoader.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.0.0-next.
|
|
4565
|
-
RouterConfigLoader.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.0.0-next.
|
|
4566
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.0-next.
|
|
4613
|
+
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 });
|
|
4614
|
+
RouterConfigLoader.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.0.0-next.5", ngImport: i0, type: RouterConfigLoader, providedIn: 'root' });
|
|
4615
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.0-next.5", ngImport: i0, type: RouterConfigLoader, decorators: [{
|
|
4567
4616
|
type: Injectable,
|
|
4568
4617
|
args: [{ providedIn: 'root' }]
|
|
4569
4618
|
}], ctorParameters: function () { return [{ type: i0.Injector }, { type: i0.Compiler }]; } });
|
|
4619
|
+
function isWrappedDefaultExport(value) {
|
|
4620
|
+
// We use `in` here with a string key `'default'`, because we expect `DefaultExport` objects to be
|
|
4621
|
+
// dynamically imported ES modules with a spec-mandated `default` key. Thus we don't expect that
|
|
4622
|
+
// `default` will be a renamed property.
|
|
4623
|
+
return value && typeof value === 'object' && 'default' in value;
|
|
4624
|
+
}
|
|
4625
|
+
function maybeUnwrapDefaultExport(input) {
|
|
4626
|
+
// As per `isWrappedDefaultExport`, the `default` key here is generated by the browser and not
|
|
4627
|
+
// subject to property renaming, so we reference it with bracket access.
|
|
4628
|
+
return isWrappedDefaultExport(input) ? input['default'] : input;
|
|
4629
|
+
}
|
|
4570
4630
|
|
|
4571
4631
|
/**
|
|
4572
4632
|
* @license
|
|
@@ -5591,9 +5651,9 @@ class Router {
|
|
|
5591
5651
|
return { navigationId };
|
|
5592
5652
|
}
|
|
5593
5653
|
}
|
|
5594
|
-
Router.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.0.0-next.
|
|
5595
|
-
Router.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.0.0-next.
|
|
5596
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.0-next.
|
|
5654
|
+
Router.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.0.0-next.5", ngImport: i0, type: Router, deps: "invalid", target: i0.ɵɵFactoryTarget.Injectable });
|
|
5655
|
+
Router.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.0.0-next.5", ngImport: i0, type: Router, providedIn: 'root', useFactory: setupRouter });
|
|
5656
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.0-next.5", ngImport: i0, type: Router, decorators: [{
|
|
5597
5657
|
type: Injectable,
|
|
5598
5658
|
args: [{
|
|
5599
5659
|
providedIn: 'root',
|
|
@@ -5717,19 +5777,36 @@ function isBrowserTriggeredNavigation(source) {
|
|
|
5717
5777
|
* @publicApi
|
|
5718
5778
|
*/
|
|
5719
5779
|
class RouterLink {
|
|
5720
|
-
constructor(router, route, tabIndexAttribute, renderer, el) {
|
|
5780
|
+
constructor(router, route, tabIndexAttribute, renderer, el, locationStrategy) {
|
|
5721
5781
|
this.router = router;
|
|
5722
5782
|
this.route = route;
|
|
5723
5783
|
this.tabIndexAttribute = tabIndexAttribute;
|
|
5724
5784
|
this.renderer = renderer;
|
|
5725
5785
|
this.el = el;
|
|
5786
|
+
this.locationStrategy = locationStrategy;
|
|
5726
5787
|
this._preserveFragment = false;
|
|
5727
5788
|
this._skipLocationChange = false;
|
|
5728
5789
|
this._replaceUrl = false;
|
|
5790
|
+
/**
|
|
5791
|
+
* Represents an `href` attribute value applied to a host element,
|
|
5792
|
+
* when a host element is `<a>`. For other tags, the value is `null`.
|
|
5793
|
+
*/
|
|
5794
|
+
this.href = null;
|
|
5729
5795
|
this.commands = null;
|
|
5730
5796
|
/** @internal */
|
|
5731
5797
|
this.onChanges = new Subject();
|
|
5732
|
-
|
|
5798
|
+
const tagName = el.nativeElement.tagName;
|
|
5799
|
+
this.isAnchorElement = tagName === 'A' || tagName === 'AREA';
|
|
5800
|
+
if (this.isAnchorElement) {
|
|
5801
|
+
this.subscription = router.events.subscribe((s) => {
|
|
5802
|
+
if (s instanceof NavigationEnd) {
|
|
5803
|
+
this.updateHref();
|
|
5804
|
+
}
|
|
5805
|
+
});
|
|
5806
|
+
}
|
|
5807
|
+
else {
|
|
5808
|
+
this.setTabIndexIfNotOnNativeEl('0');
|
|
5809
|
+
}
|
|
5733
5810
|
}
|
|
5734
5811
|
/**
|
|
5735
5812
|
* Passed to {@link Router#createUrlTree Router#createUrlTree} as part of the
|
|
@@ -5772,20 +5849,16 @@ class RouterLink {
|
|
|
5772
5849
|
* instantiation.
|
|
5773
5850
|
*/
|
|
5774
5851
|
setTabIndexIfNotOnNativeEl(newTabIndex) {
|
|
5775
|
-
if (this.tabIndexAttribute != null /* both `null` and `undefined` */) {
|
|
5852
|
+
if (this.tabIndexAttribute != null /* both `null` and `undefined` */ || this.isAnchorElement) {
|
|
5776
5853
|
return;
|
|
5777
5854
|
}
|
|
5778
|
-
|
|
5779
|
-
const nativeElement = this.el.nativeElement;
|
|
5780
|
-
if (newTabIndex !== null) {
|
|
5781
|
-
renderer.setAttribute(nativeElement, 'tabindex', newTabIndex);
|
|
5782
|
-
}
|
|
5783
|
-
else {
|
|
5784
|
-
renderer.removeAttribute(nativeElement, 'tabindex');
|
|
5785
|
-
}
|
|
5855
|
+
this.applyAttributeValue('tabindex', newTabIndex);
|
|
5786
5856
|
}
|
|
5787
5857
|
/** @nodoc */
|
|
5788
5858
|
ngOnChanges(changes) {
|
|
5859
|
+
if (this.isAnchorElement) {
|
|
5860
|
+
this.updateHref();
|
|
5861
|
+
}
|
|
5789
5862
|
// This is subscribed to by `RouterLinkActive` so that it knows to update when there are changes
|
|
5790
5863
|
// to the RouterLinks it's tracking.
|
|
5791
5864
|
this.onChanges.next(this);
|
|
@@ -5808,17 +5881,61 @@ class RouterLink {
|
|
|
5808
5881
|
}
|
|
5809
5882
|
}
|
|
5810
5883
|
/** @nodoc */
|
|
5811
|
-
onClick() {
|
|
5884
|
+
onClick(button, ctrlKey, shiftKey, altKey, metaKey) {
|
|
5812
5885
|
if (this.urlTree === null) {
|
|
5813
5886
|
return true;
|
|
5814
5887
|
}
|
|
5888
|
+
if (this.isAnchorElement) {
|
|
5889
|
+
if (button !== 0 || ctrlKey || shiftKey || altKey || metaKey) {
|
|
5890
|
+
return true;
|
|
5891
|
+
}
|
|
5892
|
+
if (typeof this.target === 'string' && this.target != '_self') {
|
|
5893
|
+
return true;
|
|
5894
|
+
}
|
|
5895
|
+
}
|
|
5815
5896
|
const extras = {
|
|
5816
5897
|
skipLocationChange: this.skipLocationChange,
|
|
5817
5898
|
replaceUrl: this.replaceUrl,
|
|
5818
5899
|
state: this.state,
|
|
5819
5900
|
};
|
|
5820
5901
|
this.router.navigateByUrl(this.urlTree, extras);
|
|
5821
|
-
|
|
5902
|
+
// Return `false` for `<a>` elements to prevent default action
|
|
5903
|
+
// and cancel the native behavior, since the navigation is handled
|
|
5904
|
+
// by the Router.
|
|
5905
|
+
return !this.isAnchorElement;
|
|
5906
|
+
}
|
|
5907
|
+
/** @nodoc */
|
|
5908
|
+
ngOnDestroy() {
|
|
5909
|
+
this.subscription?.unsubscribe();
|
|
5910
|
+
}
|
|
5911
|
+
updateHref() {
|
|
5912
|
+
this.href = this.urlTree !== null && this.locationStrategy ?
|
|
5913
|
+
this.locationStrategy?.prepareExternalUrl(this.router.serializeUrl(this.urlTree)) :
|
|
5914
|
+
null;
|
|
5915
|
+
const sanitizedValue = this.href === null ?
|
|
5916
|
+
null :
|
|
5917
|
+
// This class represents a directive that can be added to both `<a>` elements,
|
|
5918
|
+
// as well as other elements. As a result, we can't define security context at
|
|
5919
|
+
// compile time. So the security context is deferred to runtime.
|
|
5920
|
+
// The `ɵɵsanitizeUrlOrResourceUrl` selects the necessary sanitizer function
|
|
5921
|
+
// based on the tag and property names. The logic mimics the one from
|
|
5922
|
+
// `packages/compiler/src/schema/dom_security_schema.ts`, which is used at compile time.
|
|
5923
|
+
//
|
|
5924
|
+
// Note: we should investigate whether we can switch to using `@HostBinding('attr.href')`
|
|
5925
|
+
// instead of applying a value via a renderer, after a final merge of the
|
|
5926
|
+
// `RouterLinkWithHref` directive.
|
|
5927
|
+
ɵɵsanitizeUrlOrResourceUrl(this.href, this.el.nativeElement.tagName.toLowerCase(), 'href');
|
|
5928
|
+
this.applyAttributeValue('href', sanitizedValue);
|
|
5929
|
+
}
|
|
5930
|
+
applyAttributeValue(attrName, attrValue) {
|
|
5931
|
+
const renderer = this.renderer;
|
|
5932
|
+
const nativeElement = this.el.nativeElement;
|
|
5933
|
+
if (attrValue !== null) {
|
|
5934
|
+
renderer.setAttribute(nativeElement, attrName, attrValue);
|
|
5935
|
+
}
|
|
5936
|
+
else {
|
|
5937
|
+
renderer.removeAttribute(nativeElement, attrName);
|
|
5938
|
+
}
|
|
5822
5939
|
}
|
|
5823
5940
|
get urlTree() {
|
|
5824
5941
|
if (this.commands === null) {
|
|
@@ -5835,9 +5952,9 @@ class RouterLink {
|
|
|
5835
5952
|
});
|
|
5836
5953
|
}
|
|
5837
5954
|
}
|
|
5838
|
-
RouterLink.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.0.0-next.
|
|
5839
|
-
RouterLink.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "15.0.0-next.
|
|
5840
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.0-next.
|
|
5955
|
+
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 });
|
|
5956
|
+
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 });
|
|
5957
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.0-next.5", ngImport: i0, type: RouterLink, decorators: [{
|
|
5841
5958
|
type: Directive,
|
|
5842
5959
|
args: [{
|
|
5843
5960
|
selector: ':not(a):not(area)[routerLink]',
|
|
@@ -5846,7 +5963,12 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.0-next.3",
|
|
|
5846
5963
|
}], ctorParameters: function () { return [{ type: Router }, { type: ActivatedRoute }, { type: undefined, decorators: [{
|
|
5847
5964
|
type: Attribute,
|
|
5848
5965
|
args: ['tabindex']
|
|
5849
|
-
}] }, { type: i0.Renderer2 }, { type: i0.ElementRef }]; }, propDecorators: {
|
|
5966
|
+
}] }, { type: i0.Renderer2 }, { type: i0.ElementRef }, { type: i3.LocationStrategy }]; }, propDecorators: { target: [{
|
|
5967
|
+
type: HostBinding,
|
|
5968
|
+
args: ['attr.target']
|
|
5969
|
+
}, {
|
|
5970
|
+
type: Input
|
|
5971
|
+
}], queryParams: [{
|
|
5850
5972
|
type: Input
|
|
5851
5973
|
}], fragment: [{
|
|
5852
5974
|
type: Input
|
|
@@ -5866,7 +5988,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.0-next.3",
|
|
|
5866
5988
|
type: Input
|
|
5867
5989
|
}], onClick: [{
|
|
5868
5990
|
type: HostListener,
|
|
5869
|
-
args: ['click'
|
|
5991
|
+
args: ['click',
|
|
5992
|
+
['$event.button', '$event.ctrlKey', '$event.shiftKey', '$event.altKey', '$event.metaKey']]
|
|
5870
5993
|
}] } });
|
|
5871
5994
|
/**
|
|
5872
5995
|
* @description
|
|
@@ -5879,159 +6002,17 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.0-next.3",
|
|
|
5879
6002
|
*
|
|
5880
6003
|
* @publicApi
|
|
5881
6004
|
*/
|
|
5882
|
-
class RouterLinkWithHref {
|
|
5883
|
-
constructor(router, route, locationStrategy) {
|
|
5884
|
-
this.router = router;
|
|
5885
|
-
this.route = route;
|
|
5886
|
-
this.locationStrategy = locationStrategy;
|
|
5887
|
-
this._preserveFragment = false;
|
|
5888
|
-
this._skipLocationChange = false;
|
|
5889
|
-
this._replaceUrl = false;
|
|
5890
|
-
this.commands = null;
|
|
5891
|
-
// the url displayed on the anchor element.
|
|
5892
|
-
// @HostBinding('attr.href') is used rather than @HostBinding() because it removes the
|
|
5893
|
-
// href attribute when it becomes `null`.
|
|
5894
|
-
this.href = null;
|
|
5895
|
-
/** @internal */
|
|
5896
|
-
this.onChanges = new Subject();
|
|
5897
|
-
this.subscription = router.events.subscribe((s) => {
|
|
5898
|
-
if (s instanceof NavigationEnd) {
|
|
5899
|
-
this.updateTargetUrlAndHref();
|
|
5900
|
-
}
|
|
5901
|
-
});
|
|
5902
|
-
}
|
|
5903
|
-
/**
|
|
5904
|
-
* Passed to {@link Router#createUrlTree Router#createUrlTree} as part of the
|
|
5905
|
-
* `UrlCreationOptions`.
|
|
5906
|
-
* @see {@link UrlCreationOptions#preserveFragment UrlCreationOptions#preserveFragment}
|
|
5907
|
-
* @see {@link Router#createUrlTree Router#createUrlTree}
|
|
5908
|
-
*/
|
|
5909
|
-
set preserveFragment(preserveFragment) {
|
|
5910
|
-
this._preserveFragment = ɵcoerceToBoolean(preserveFragment);
|
|
5911
|
-
}
|
|
5912
|
-
get preserveFragment() {
|
|
5913
|
-
return this._preserveFragment;
|
|
5914
|
-
}
|
|
5915
|
-
/**
|
|
5916
|
-
* Passed to {@link Router#navigateByUrl Router#navigateByUrl} as part of the
|
|
5917
|
-
* `NavigationBehaviorOptions`.
|
|
5918
|
-
* @see {@link NavigationBehaviorOptions#skipLocationChange NavigationBehaviorOptions#skipLocationChange}
|
|
5919
|
-
* @see {@link Router#navigateByUrl Router#navigateByUrl}
|
|
5920
|
-
*/
|
|
5921
|
-
set skipLocationChange(skipLocationChange) {
|
|
5922
|
-
this._skipLocationChange = ɵcoerceToBoolean(skipLocationChange);
|
|
5923
|
-
}
|
|
5924
|
-
get skipLocationChange() {
|
|
5925
|
-
return this._skipLocationChange;
|
|
5926
|
-
}
|
|
5927
|
-
/**
|
|
5928
|
-
* Passed to {@link Router#navigateByUrl Router#navigateByUrl} as part of the
|
|
5929
|
-
* `NavigationBehaviorOptions`.
|
|
5930
|
-
* @see {@link NavigationBehaviorOptions#replaceUrl NavigationBehaviorOptions#replaceUrl}
|
|
5931
|
-
* @see {@link Router#navigateByUrl Router#navigateByUrl}
|
|
5932
|
-
*/
|
|
5933
|
-
set replaceUrl(replaceUrl) {
|
|
5934
|
-
this._replaceUrl = ɵcoerceToBoolean(replaceUrl);
|
|
5935
|
-
}
|
|
5936
|
-
get replaceUrl() {
|
|
5937
|
-
return this._replaceUrl;
|
|
5938
|
-
}
|
|
5939
|
-
/**
|
|
5940
|
-
* Commands to pass to {@link Router#createUrlTree Router#createUrlTree}.
|
|
5941
|
-
* - **array**: commands to pass to {@link Router#createUrlTree Router#createUrlTree}.
|
|
5942
|
-
* - **string**: shorthand for array of commands with just the string, i.e. `['/route']`
|
|
5943
|
-
* - **null|undefined**: Disables the link by removing the `href`
|
|
5944
|
-
* @see {@link Router#createUrlTree Router#createUrlTree}
|
|
5945
|
-
*/
|
|
5946
|
-
set routerLink(commands) {
|
|
5947
|
-
if (commands != null) {
|
|
5948
|
-
this.commands = Array.isArray(commands) ? commands : [commands];
|
|
5949
|
-
}
|
|
5950
|
-
else {
|
|
5951
|
-
this.commands = null;
|
|
5952
|
-
}
|
|
5953
|
-
}
|
|
5954
|
-
/** @nodoc */
|
|
5955
|
-
ngOnChanges(changes) {
|
|
5956
|
-
this.updateTargetUrlAndHref();
|
|
5957
|
-
this.onChanges.next(this);
|
|
5958
|
-
}
|
|
5959
|
-
/** @nodoc */
|
|
5960
|
-
ngOnDestroy() {
|
|
5961
|
-
this.subscription.unsubscribe();
|
|
5962
|
-
}
|
|
5963
|
-
/** @nodoc */
|
|
5964
|
-
onClick(button, ctrlKey, shiftKey, altKey, metaKey) {
|
|
5965
|
-
if (button !== 0 || ctrlKey || shiftKey || altKey || metaKey) {
|
|
5966
|
-
return true;
|
|
5967
|
-
}
|
|
5968
|
-
if (typeof this.target === 'string' && this.target != '_self' || this.urlTree === null) {
|
|
5969
|
-
return true;
|
|
5970
|
-
}
|
|
5971
|
-
const extras = {
|
|
5972
|
-
skipLocationChange: this.skipLocationChange,
|
|
5973
|
-
replaceUrl: this.replaceUrl,
|
|
5974
|
-
state: this.state
|
|
5975
|
-
};
|
|
5976
|
-
this.router.navigateByUrl(this.urlTree, extras);
|
|
5977
|
-
return false;
|
|
5978
|
-
}
|
|
5979
|
-
updateTargetUrlAndHref() {
|
|
5980
|
-
this.href = this.urlTree !== null ?
|
|
5981
|
-
this.locationStrategy.prepareExternalUrl(this.router.serializeUrl(this.urlTree)) :
|
|
5982
|
-
null;
|
|
5983
|
-
}
|
|
5984
|
-
get urlTree() {
|
|
5985
|
-
if (this.commands === null) {
|
|
5986
|
-
return null;
|
|
5987
|
-
}
|
|
5988
|
-
return this.router.createUrlTree(this.commands, {
|
|
5989
|
-
// If the `relativeTo` input is not defined, we want to use `this.route` by default.
|
|
5990
|
-
// Otherwise, we should use the value provided by the user in the input.
|
|
5991
|
-
relativeTo: this.relativeTo !== undefined ? this.relativeTo : this.route,
|
|
5992
|
-
queryParams: this.queryParams,
|
|
5993
|
-
fragment: this.fragment,
|
|
5994
|
-
queryParamsHandling: this.queryParamsHandling,
|
|
5995
|
-
preserveFragment: this.preserveFragment,
|
|
5996
|
-
});
|
|
5997
|
-
}
|
|
6005
|
+
class RouterLinkWithHref extends RouterLink {
|
|
5998
6006
|
}
|
|
5999
|
-
RouterLinkWithHref.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.0.0-next.
|
|
6000
|
-
RouterLinkWithHref.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "15.0.0-next.
|
|
6001
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.0-next.
|
|
6007
|
+
RouterLinkWithHref.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.0.0-next.5", ngImport: i0, type: RouterLinkWithHref, deps: null, target: i0.ɵɵFactoryTarget.Directive });
|
|
6008
|
+
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 });
|
|
6009
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.0-next.5", ngImport: i0, type: RouterLinkWithHref, decorators: [{
|
|
6002
6010
|
type: Directive,
|
|
6003
|
-
args: [{
|
|
6004
|
-
|
|
6005
|
-
|
|
6006
|
-
|
|
6007
|
-
|
|
6008
|
-
type: Input
|
|
6009
|
-
}], queryParams: [{
|
|
6010
|
-
type: Input
|
|
6011
|
-
}], fragment: [{
|
|
6012
|
-
type: Input
|
|
6013
|
-
}], queryParamsHandling: [{
|
|
6014
|
-
type: Input
|
|
6015
|
-
}], state: [{
|
|
6016
|
-
type: Input
|
|
6017
|
-
}], relativeTo: [{
|
|
6018
|
-
type: Input
|
|
6019
|
-
}], href: [{
|
|
6020
|
-
type: HostBinding,
|
|
6021
|
-
args: ['attr.href']
|
|
6022
|
-
}], preserveFragment: [{
|
|
6023
|
-
type: Input
|
|
6024
|
-
}], skipLocationChange: [{
|
|
6025
|
-
type: Input
|
|
6026
|
-
}], replaceUrl: [{
|
|
6027
|
-
type: Input
|
|
6028
|
-
}], routerLink: [{
|
|
6029
|
-
type: Input
|
|
6030
|
-
}], onClick: [{
|
|
6031
|
-
type: HostListener,
|
|
6032
|
-
args: ['click',
|
|
6033
|
-
['$event.button', '$event.ctrlKey', '$event.shiftKey', '$event.altKey', '$event.metaKey']]
|
|
6034
|
-
}] } });
|
|
6011
|
+
args: [{
|
|
6012
|
+
selector: 'a[routerLink],area[routerLink]',
|
|
6013
|
+
standalone: true,
|
|
6014
|
+
}]
|
|
6015
|
+
}] });
|
|
6035
6016
|
|
|
6036
6017
|
/**
|
|
6037
6018
|
* @license
|
|
@@ -6223,9 +6204,9 @@ class RouterLinkActive {
|
|
|
6223
6204
|
this.links.some(isActiveCheckFn) || this.linksWithHrefs.some(isActiveCheckFn);
|
|
6224
6205
|
}
|
|
6225
6206
|
}
|
|
6226
|
-
RouterLinkActive.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.0.0-next.
|
|
6227
|
-
RouterLinkActive.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "15.0.0-next.
|
|
6228
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.0-next.
|
|
6207
|
+
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 });
|
|
6208
|
+
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 });
|
|
6209
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.0-next.5", ngImport: i0, type: RouterLinkActive, decorators: [{
|
|
6229
6210
|
type: Directive,
|
|
6230
6211
|
args: [{
|
|
6231
6212
|
selector: '[routerLinkActive]',
|
|
@@ -6290,9 +6271,9 @@ class PreloadAllModules {
|
|
|
6290
6271
|
return fn().pipe(catchError(() => of(null)));
|
|
6291
6272
|
}
|
|
6292
6273
|
}
|
|
6293
|
-
PreloadAllModules.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.0.0-next.
|
|
6294
|
-
PreloadAllModules.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.0.0-next.
|
|
6295
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.0-next.
|
|
6274
|
+
PreloadAllModules.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.0.0-next.5", ngImport: i0, type: PreloadAllModules, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
|
|
6275
|
+
PreloadAllModules.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.0.0-next.5", ngImport: i0, type: PreloadAllModules, providedIn: 'root' });
|
|
6276
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.0-next.5", ngImport: i0, type: PreloadAllModules, decorators: [{
|
|
6296
6277
|
type: Injectable,
|
|
6297
6278
|
args: [{ providedIn: 'root' }]
|
|
6298
6279
|
}] });
|
|
@@ -6310,9 +6291,9 @@ class NoPreloading {
|
|
|
6310
6291
|
return of(null);
|
|
6311
6292
|
}
|
|
6312
6293
|
}
|
|
6313
|
-
NoPreloading.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.0.0-next.
|
|
6314
|
-
NoPreloading.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.0.0-next.
|
|
6315
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.0-next.
|
|
6294
|
+
NoPreloading.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.0.0-next.5", ngImport: i0, type: NoPreloading, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
|
|
6295
|
+
NoPreloading.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.0.0-next.5", ngImport: i0, type: NoPreloading, providedIn: 'root' });
|
|
6296
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.0-next.5", ngImport: i0, type: NoPreloading, decorators: [{
|
|
6316
6297
|
type: Injectable,
|
|
6317
6298
|
args: [{ providedIn: 'root' }]
|
|
6318
6299
|
}] });
|
|
@@ -6406,9 +6387,9 @@ class RouterPreloader {
|
|
|
6406
6387
|
});
|
|
6407
6388
|
}
|
|
6408
6389
|
}
|
|
6409
|
-
RouterPreloader.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.0.0-next.
|
|
6410
|
-
RouterPreloader.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.0.0-next.
|
|
6411
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.0-next.
|
|
6390
|
+
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 });
|
|
6391
|
+
RouterPreloader.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.0.0-next.5", ngImport: i0, type: RouterPreloader, providedIn: 'root' });
|
|
6392
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.0-next.5", ngImport: i0, type: RouterPreloader, decorators: [{
|
|
6412
6393
|
type: Injectable,
|
|
6413
6394
|
args: [{ providedIn: 'root' }]
|
|
6414
6395
|
}], ctorParameters: function () { return [{ type: Router }, { type: i0.Compiler }, { type: i0.EnvironmentInjector }, { type: PreloadingStrategy }, { type: RouterConfigLoader }]; } });
|
|
@@ -6496,9 +6477,9 @@ class RouterScroller {
|
|
|
6496
6477
|
}
|
|
6497
6478
|
}
|
|
6498
6479
|
}
|
|
6499
|
-
RouterScroller.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.0.0-next.
|
|
6500
|
-
RouterScroller.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.0.0-next.
|
|
6501
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.0-next.
|
|
6480
|
+
RouterScroller.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.0.0-next.5", ngImport: i0, type: RouterScroller, deps: "invalid", target: i0.ɵɵFactoryTarget.Injectable });
|
|
6481
|
+
RouterScroller.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.0.0-next.5", ngImport: i0, type: RouterScroller });
|
|
6482
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.0-next.5", ngImport: i0, type: RouterScroller, decorators: [{
|
|
6502
6483
|
type: Injectable
|
|
6503
6484
|
}], ctorParameters: function () { return [{ type: Router }, { type: i3.ViewportScroller }, { type: undefined }]; } });
|
|
6504
6485
|
|
|
@@ -7025,10 +7006,10 @@ class RouterModule {
|
|
|
7025
7006
|
return { ngModule: RouterModule, providers: [provideRoutes(routes)] };
|
|
7026
7007
|
}
|
|
7027
7008
|
}
|
|
7028
|
-
RouterModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.0.0-next.
|
|
7029
|
-
RouterModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "15.0.0-next.
|
|
7030
|
-
RouterModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "15.0.0-next.
|
|
7031
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.0-next.
|
|
7009
|
+
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 });
|
|
7010
|
+
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] });
|
|
7011
|
+
RouterModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "15.0.0-next.5", ngImport: i0, type: RouterModule, imports: [ɵEmptyOutletComponent] });
|
|
7012
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.0-next.5", ngImport: i0, type: RouterModule, decorators: [{
|
|
7032
7013
|
type: NgModule,
|
|
7033
7014
|
args: [{
|
|
7034
7015
|
imports: ROUTER_DIRECTIVES,
|
|
@@ -7112,7 +7093,7 @@ function provideRouterInitializer() {
|
|
|
7112
7093
|
/**
|
|
7113
7094
|
* @publicApi
|
|
7114
7095
|
*/
|
|
7115
|
-
const VERSION = new Version('15.0.0-next.
|
|
7096
|
+
const VERSION = new Version('15.0.0-next.5');
|
|
7116
7097
|
|
|
7117
7098
|
/**
|
|
7118
7099
|
* @license
|