@angular/router 15.1.0-next.0 → 15.1.0-next.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (39) hide show
  1. package/esm2020/src/components/empty_outlet.mjs +3 -3
  2. package/esm2020/src/deprecated_load_children.mjs +3 -1
  3. package/esm2020/src/directives/router_link.mjs +3 -3
  4. package/esm2020/src/directives/router_link_active.mjs +3 -3
  5. package/esm2020/src/directives/router_outlet.mjs +3 -3
  6. package/esm2020/src/index.mjs +1 -1
  7. package/esm2020/src/models.mjs +1 -1
  8. package/esm2020/src/navigation_transition.mjs +145 -84
  9. package/esm2020/src/page_title_strategy.mjs +6 -6
  10. package/esm2020/src/private_export.mjs +1 -2
  11. package/esm2020/src/provide_router.mjs +6 -7
  12. package/esm2020/src/route_reuse_strategy.mjs +6 -6
  13. package/esm2020/src/router.mjs +58 -165
  14. package/esm2020/src/router_config.mjs +1 -1
  15. package/esm2020/src/router_config_loader.mjs +3 -3
  16. package/esm2020/src/router_module.mjs +11 -9
  17. package/esm2020/src/router_outlet_context.mjs +3 -3
  18. package/esm2020/src/router_preloader.mjs +9 -9
  19. package/esm2020/src/router_scroller.mjs +20 -21
  20. package/esm2020/src/router_state.mjs +7 -7
  21. package/esm2020/src/url_handling_strategy.mjs +6 -6
  22. package/esm2020/src/url_tree.mjs +4 -4
  23. package/esm2020/src/utils/config.mjs +2 -2
  24. package/esm2020/src/version.mjs +1 -1
  25. package/esm2020/testing/src/router_testing_module.mjs +56 -17
  26. package/fesm2015/router.mjs +428 -471
  27. package/fesm2015/router.mjs.map +1 -1
  28. package/fesm2015/testing.mjs +56 -17
  29. package/fesm2015/testing.mjs.map +1 -1
  30. package/fesm2015/upgrade.mjs +1 -1
  31. package/fesm2020/router.mjs +419 -467
  32. package/fesm2020/router.mjs.map +1 -1
  33. package/fesm2020/testing.mjs +56 -17
  34. package/fesm2020/testing.mjs.map +1 -1
  35. package/fesm2020/upgrade.mjs +1 -1
  36. package/index.d.ts +76 -58
  37. package/package.json +4 -4
  38. package/testing/index.d.ts +1 -1
  39. package/upgrade/index.d.ts +1 -1
@@ -1,13 +1,14 @@
1
1
  /**
2
- * @license Angular v15.1.0-next.0
2
+ * @license Angular v15.1.0-next.2
3
3
  * (c) 2010-2022 Google LLC. https://angular.io/
4
4
  * License: MIT
5
5
  */
6
6
 
7
+ import { Location } from '@angular/common';
7
8
  import { provideLocationMocks } from '@angular/common/testing';
8
9
  import * as i0 from '@angular/core';
9
- import { NgModule } from '@angular/core';
10
- import { Router, ɵflatten, ɵassignExtraOptionsToRouter, ROUTES, ROUTER_CONFIGURATION, RouterModule, ɵROUTER_PROVIDERS, ɵwithPreloading, NoPreloading } from '@angular/router';
10
+ import { inject, Compiler, Injector, NgModule } from '@angular/core';
11
+ import { UrlSerializer, ChildrenOutletContexts, ROUTES, UrlHandlingStrategy, ROUTER_CONFIGURATION, RouteReuseStrategy, TitleStrategy, Router, RouterModule, ɵROUTER_PROVIDERS, ɵwithPreloading, NoPreloading } from '@angular/router';
11
12
 
12
13
  /**
13
14
  * @license
@@ -19,11 +20,22 @@ import { Router, ɵflatten, ɵassignExtraOptionsToRouter, ROUTES, ROUTER_CONFIGU
19
20
  // This file exists to easily patch the SpyNgModuleFactoryLoader into g3
20
21
  const EXTRA_ROUTER_TESTING_PROVIDERS = [];
21
22
 
23
+ /**
24
+ * @license
25
+ * Copyright Google LLC All Rights Reserved.
26
+ *
27
+ * Use of this source code is governed by an MIT-style license that can be
28
+ * found in the LICENSE file at https://angular.io/license
29
+ */
22
30
  function isUrlHandlingStrategy(opts) {
23
31
  // This property check is needed because UrlHandlingStrategy is an interface and doesn't exist at
24
32
  // runtime.
25
33
  return 'shouldProcessUrl' in opts;
26
34
  }
35
+ function throwInvalidConfigError(parameter) {
36
+ throw new Error(`Parameter ${parameter} does not match the one available in the injector. ` +
37
+ '`setupTestingRouter` is meant to be used as a factory function with dependencies coming from DI.');
38
+ }
27
39
  /**
28
40
  * Router setup factory function used for testing.
29
41
  *
@@ -31,25 +43,52 @@ function isUrlHandlingStrategy(opts) {
31
43
  * @deprecated Use `provideRouter` or `RouterTestingModule` instead.
32
44
  */
33
45
  function setupTestingRouter(urlSerializer, contexts, location, compiler, injector, routes, opts, urlHandlingStrategy, routeReuseStrategy, titleStrategy) {
34
- const router = new Router(null, urlSerializer, contexts, location, injector, compiler, ɵflatten(routes));
46
+ // Note: The checks below are to detect misconfigured providers and invalid uses of
47
+ // `setupTestingRouter`. This function is not used internally (neither in router code or anywhere
48
+ // in g3). It appears this function was exposed as publicApi by mistake and should not be used
49
+ // externally either. However, if it is, the documented intent is to be used as a factory function
50
+ // and parameter values should always match what's available in DI.
51
+ if (urlSerializer !== inject(UrlSerializer)) {
52
+ throwInvalidConfigError('urlSerializer');
53
+ }
54
+ if (contexts !== inject(ChildrenOutletContexts)) {
55
+ throwInvalidConfigError('contexts');
56
+ }
57
+ if (location !== inject(Location)) {
58
+ throwInvalidConfigError('location');
59
+ }
60
+ if (compiler !== inject(Compiler)) {
61
+ throwInvalidConfigError('compiler');
62
+ }
63
+ if (injector !== inject(Injector)) {
64
+ throwInvalidConfigError('injector');
65
+ }
66
+ if (routes !== inject(ROUTES)) {
67
+ throwInvalidConfigError('routes');
68
+ }
35
69
  if (opts) {
36
70
  // Handle deprecated argument ordering.
37
71
  if (isUrlHandlingStrategy(opts)) {
38
- router.urlHandlingStrategy = opts;
72
+ if (opts !== inject(UrlHandlingStrategy)) {
73
+ throwInvalidConfigError('opts (UrlHandlingStrategy)');
74
+ }
39
75
  }
40
76
  else {
41
- // Handle ExtraOptions
42
- ɵassignExtraOptionsToRouter(opts, router);
77
+ if (opts !== inject(ROUTER_CONFIGURATION)) {
78
+ throwInvalidConfigError('opts (ROUTER_CONFIGURATION)');
79
+ }
43
80
  }
44
81
  }
45
- if (urlHandlingStrategy) {
46
- router.urlHandlingStrategy = urlHandlingStrategy;
82
+ if (urlHandlingStrategy !== inject(UrlHandlingStrategy)) {
83
+ throwInvalidConfigError('urlHandlingStrategy');
84
+ }
85
+ if (routeReuseStrategy !== inject(RouteReuseStrategy)) {
86
+ throwInvalidConfigError('routeReuseStrategy');
47
87
  }
48
- if (routeReuseStrategy) {
49
- router.routeReuseStrategy = routeReuseStrategy;
88
+ if (titleStrategy !== inject(TitleStrategy)) {
89
+ throwInvalidConfigError('titleStrategy');
50
90
  }
51
- router.titleStrategy = titleStrategy;
52
- return router;
91
+ return new Router();
53
92
  }
54
93
  /**
55
94
  * @description
@@ -87,16 +126,16 @@ class RouterTestingModule {
87
126
  };
88
127
  }
89
128
  }
90
- RouterTestingModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.1.0-next.0", ngImport: i0, type: RouterTestingModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
91
- RouterTestingModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "15.1.0-next.0", ngImport: i0, type: RouterTestingModule, exports: [RouterModule] });
92
- RouterTestingModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "15.1.0-next.0", ngImport: i0, type: RouterTestingModule, providers: [
129
+ RouterTestingModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.1.0-next.2", ngImport: i0, type: RouterTestingModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
130
+ RouterTestingModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "15.1.0-next.2", ngImport: i0, type: RouterTestingModule, exports: [RouterModule] });
131
+ RouterTestingModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "15.1.0-next.2", ngImport: i0, type: RouterTestingModule, providers: [
93
132
  ɵROUTER_PROVIDERS,
94
133
  EXTRA_ROUTER_TESTING_PROVIDERS,
95
134
  provideLocationMocks(),
96
135
  ɵwithPreloading(NoPreloading).ɵproviders,
97
136
  { provide: ROUTES, multi: true, useValue: [] },
98
137
  ], imports: [RouterModule] });
99
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.1.0-next.0", ngImport: i0, type: RouterTestingModule, decorators: [{
138
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.1.0-next.2", ngImport: i0, type: RouterTestingModule, decorators: [{
100
139
  type: NgModule,
101
140
  args: [{
102
141
  exports: [RouterModule],
@@ -1 +1 @@
1
- {"version":3,"file":"testing.mjs","sources":["../../../../../../packages/router/testing/src/extra_router_testing_providers.ts","../../../../../../packages/router/testing/src/router_testing_module.ts","../../../../../../packages/router/testing/src/spy_ng_module_factory_loader.ts","../../../../../../packages/router/testing/src/testing.ts","../../../../../../packages/router/testing/public_api.ts","../../../../../../packages/router/testing/index.ts","../../../../../../packages/router/testing/testing.ts"],"sourcesContent":["/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.io/license\n */\n\n// This file exists to easily patch the SpyNgModuleFactoryLoader into g3\nexport const EXTRA_ROUTER_TESTING_PROVIDERS = [];\n","/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.io/license\n */\n\nimport {Location} from '@angular/common';\nimport {provideLocationMocks} from '@angular/common/testing';\nimport {Compiler, Injector, ModuleWithProviders, NgModule, Optional} from '@angular/core';\nimport {ChildrenOutletContexts, ExtraOptions, NoPreloading, Route, Router, ROUTER_CONFIGURATION, RouteReuseStrategy, RouterModule, ROUTES, Routes, TitleStrategy, UrlHandlingStrategy, UrlSerializer, ɵassignExtraOptionsToRouter as assignExtraOptionsToRouter, ɵflatten as flatten, ɵROUTER_PROVIDERS as ROUTER_PROVIDERS, ɵwithPreloading as withPreloading} from '@angular/router';\n\nimport {EXTRA_ROUTER_TESTING_PROVIDERS} from './extra_router_testing_providers';\n\nfunction isUrlHandlingStrategy(opts: ExtraOptions|\n UrlHandlingStrategy): opts is UrlHandlingStrategy {\n // This property check is needed because UrlHandlingStrategy is an interface and doesn't exist at\n // runtime.\n return 'shouldProcessUrl' in opts;\n}\n\n/**\n * Router setup factory function used for testing.\n *\n * @publicApi\n * @deprecated Use `provideRouter` or `RouterTestingModule` instead.\n */\nexport function setupTestingRouter(\n urlSerializer: UrlSerializer, contexts: ChildrenOutletContexts, location: Location,\n compiler: Compiler, injector: Injector, routes: Route[][],\n opts?: ExtraOptions|UrlHandlingStrategy|null, urlHandlingStrategy?: UrlHandlingStrategy,\n routeReuseStrategy?: RouteReuseStrategy, titleStrategy?: TitleStrategy) {\n const router =\n new Router(null!, urlSerializer, contexts, location, injector, compiler, flatten(routes));\n if (opts) {\n // Handle deprecated argument ordering.\n if (isUrlHandlingStrategy(opts)) {\n router.urlHandlingStrategy = opts;\n } else {\n // Handle ExtraOptions\n assignExtraOptionsToRouter(opts, router);\n }\n }\n\n if (urlHandlingStrategy) {\n router.urlHandlingStrategy = urlHandlingStrategy;\n }\n\n if (routeReuseStrategy) {\n router.routeReuseStrategy = routeReuseStrategy;\n }\n\n router.titleStrategy = titleStrategy;\n\n return router;\n}\n\n/**\n * @description\n *\n * Sets up the router to be used for testing.\n *\n * The modules sets up the router to be used for testing.\n * It provides spy implementations of `Location` and `LocationStrategy`.\n *\n * @usageNotes\n * ### Example\n *\n * ```\n * beforeEach(() => {\n * TestBed.configureTestingModule({\n * imports: [\n * RouterTestingModule.withRoutes(\n * [{path: '', component: BlankCmp}, {path: 'simple', component: SimpleCmp}]\n * )\n * ]\n * });\n * });\n * ```\n *\n * @publicApi\n */\n@NgModule({\n exports: [RouterModule],\n providers: [\n ROUTER_PROVIDERS,\n EXTRA_ROUTER_TESTING_PROVIDERS,\n provideLocationMocks(),\n withPreloading(NoPreloading).ɵproviders,\n {provide: ROUTES, multi: true, useValue: []},\n ]\n})\nexport class RouterTestingModule {\n static withRoutes(routes: Routes, config?: ExtraOptions):\n ModuleWithProviders<RouterTestingModule> {\n return {\n ngModule: RouterTestingModule,\n providers: [\n {provide: ROUTES, multi: true, useValue: routes},\n {provide: ROUTER_CONFIGURATION, useValue: config ? config : {}},\n ]\n };\n }\n}\n","/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.io/license\n */\n\n// This file exists for easily patching SpyNgModuleFactoryLoader in g3\nexport default {};\n","/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.io/license\n */\n\n/**\n * @module\n * @description\n * Entry point for all public APIs of the router/testing package.\n */\nexport * from './router_testing_module';\nexport * from './spy_ng_module_factory_loader';\n","/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.io/license\n */\n\n/**\n * @module\n * @description\n * Entry point for all public APIs of this package.\n */\nexport * from './src/testing';\n\n// This file only reexports content of the `src` folder. Keep it that way.\n","/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.io/license\n */\n\n// This file is not used to build this module. It is only used during editing\n// by the TypeScript language service and during build for verification. `ngc`\n// replaces this file with production index.ts when it rewrites private symbol\n// names.\n\nexport * from './public_api';\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":["flatten","assignExtraOptionsToRouter","ROUTER_PROVIDERS","withPreloading"],"mappings":";;;;;;;;;;;AAAA;;;;;;AAMG;AAEH;AACO,MAAM,8BAA8B,GAAG,EAAE;;ACMhD,SAAS,qBAAqB,CAAC,IACmB,EAAA;;;IAGhD,OAAO,kBAAkB,IAAI,IAAI,CAAC;AACpC,CAAC;AAED;;;;;AAKG;AACG,SAAU,kBAAkB,CAC9B,aAA4B,EAAE,QAAgC,EAAE,QAAkB,EAClF,QAAkB,EAAE,QAAkB,EAAE,MAAiB,EACzD,IAA4C,EAAE,mBAAyC,EACvF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A,GAAA,EAAA,CAAA,mBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,mBAAA,EAAA,QAAA,EAAA,EAAA,EAAA,IAAA,EAAA,mBAAmB,YATpB,YAAY,CAAA,EAAA,CAAA,CAAA;AASX,mBAAA,CAAA,IAAA,GAAA,EAAA,CAAA,mBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,mBAAA,EAAA,QAAA,EAAA,EAAA,EAAA,IAAA,EAAA,mBAAmB,EARnB,SAAA,EAAA;QACTC,iBAAgB;QAChB,8BAA8B;AAC9B,QAAA,oBAAoB,EAAE;AACtB,QAAAC,eAAc,CAAC,YAAY,CAAC,CAAC,UAAU;QACvC,EAAC,OAAO,EAAE,MAAM,EAAE,KAAK,EAAE,IAAI,EAAE,QAAQ,EAAE,EAAE,EAAC;AAC7C,KAAA,EAAA,OAAA,EAAA,CAPS,YAAY,CAAA,EAAA,CAAA,CAAA;sGASX,mBAAmB,EAAA,UAAA,EAAA,CAAA;kBAV/B,QAAQ;AAAC,YAAA,IAAA,EAAA,CAAA;oBACR,OAAO,EAAE,CAAC,YAAY,CAAC;AACvB,oBAAA,SAAS,EAAE;wBACTD,iBAAgB;wBAChB,8BAA8B;AAC9B,wBAAA,oBAAoB,EAAE;AACtB,wBAAAC,eAAc,CAAC,YAAY,CAAC,CAAC,UAAU;wBACvC,EAAC,OAAO,EAAE,MAAM,EAAE,KAAK,EAAE,IAAI,EAAE,QAAQ,EAAE,EAAE,EAAC;AAC7C,qBAAA;AACF,iBAAA,CAAA;;;AC5FD;;;;;;AAMG;AAEH;AACA,mCAAe,EAAE;;ACTjB;;;;;;AAMG;;ACNH;;;;;;AAMG;AASH;;ACfA;;;;;;AAMG;;ACNH;;AAEG;;;;"}
1
+ {"version":3,"file":"testing.mjs","sources":["../../../../../../packages/router/testing/src/extra_router_testing_providers.ts","../../../../../../packages/router/testing/src/router_testing_module.ts","../../../../../../packages/router/testing/src/spy_ng_module_factory_loader.ts","../../../../../../packages/router/testing/src/testing.ts","../../../../../../packages/router/testing/public_api.ts","../../../../../../packages/router/testing/index.ts","../../../../../../packages/router/testing/testing.ts"],"sourcesContent":["/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.io/license\n */\n\n// This file exists to easily patch the SpyNgModuleFactoryLoader into g3\nexport const EXTRA_ROUTER_TESTING_PROVIDERS = [];\n","/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.io/license\n */\n\nimport {Location} from '@angular/common';\nimport {provideLocationMocks} from '@angular/common/testing';\nimport {Compiler, inject, Injector, ModuleWithProviders, NgModule} from '@angular/core';\nimport {ChildrenOutletContexts, ExtraOptions, NoPreloading, Route, Router, ROUTER_CONFIGURATION, RouteReuseStrategy, RouterModule, ROUTES, Routes, TitleStrategy, UrlHandlingStrategy, UrlSerializer, ɵflatten as flatten, ɵROUTER_PROVIDERS as ROUTER_PROVIDERS, ɵwithPreloading as withPreloading} from '@angular/router';\n\nimport {EXTRA_ROUTER_TESTING_PROVIDERS} from './extra_router_testing_providers';\n\nfunction isUrlHandlingStrategy(opts: ExtraOptions|\n UrlHandlingStrategy): opts is UrlHandlingStrategy {\n // This property check is needed because UrlHandlingStrategy is an interface and doesn't exist at\n // runtime.\n return 'shouldProcessUrl' in opts;\n}\n\nfunction throwInvalidConfigError(parameter: string): never {\n throw new Error(\n `Parameter ${parameter} does not match the one available in the injector. ` +\n '`setupTestingRouter` is meant to be used as a factory function with dependencies coming from DI.');\n}\n\n/**\n * Router setup factory function used for testing.\n *\n * @publicApi\n * @deprecated Use `provideRouter` or `RouterTestingModule` instead.\n */\nexport function setupTestingRouter(\n urlSerializer: UrlSerializer, contexts: ChildrenOutletContexts, location: Location,\n compiler: Compiler, injector: Injector, routes: Route[][],\n opts?: ExtraOptions|UrlHandlingStrategy|null, urlHandlingStrategy?: UrlHandlingStrategy,\n routeReuseStrategy?: RouteReuseStrategy, titleStrategy?: TitleStrategy) {\n // Note: The checks below are to detect misconfigured providers and invalid uses of\n // `setupTestingRouter`. This function is not used internally (neither in router code or anywhere\n // in g3). It appears this function was exposed as publicApi by mistake and should not be used\n // externally either. However, if it is, the documented intent is to be used as a factory function\n // and parameter values should always match what's available in DI.\n if (urlSerializer !== inject(UrlSerializer)) {\n throwInvalidConfigError('urlSerializer');\n }\n if (contexts !== inject(ChildrenOutletContexts)) {\n throwInvalidConfigError('contexts');\n }\n if (location !== inject(Location)) {\n throwInvalidConfigError('location');\n }\n if (compiler !== inject(Compiler)) {\n throwInvalidConfigError('compiler');\n }\n if (injector !== inject(Injector)) {\n throwInvalidConfigError('injector');\n }\n if (routes !== inject(ROUTES)) {\n throwInvalidConfigError('routes');\n }\n if (opts) {\n // Handle deprecated argument ordering.\n if (isUrlHandlingStrategy(opts)) {\n if (opts !== inject(UrlHandlingStrategy)) {\n throwInvalidConfigError('opts (UrlHandlingStrategy)');\n }\n } else {\n if (opts !== inject(ROUTER_CONFIGURATION)) {\n throwInvalidConfigError('opts (ROUTER_CONFIGURATION)');\n }\n }\n }\n\n if (urlHandlingStrategy !== inject(UrlHandlingStrategy)) {\n throwInvalidConfigError('urlHandlingStrategy');\n }\n\n if (routeReuseStrategy !== inject(RouteReuseStrategy)) {\n throwInvalidConfigError('routeReuseStrategy');\n }\n\n if (titleStrategy !== inject(TitleStrategy)) {\n throwInvalidConfigError('titleStrategy');\n }\n\n return new Router();\n}\n\n/**\n * @description\n *\n * Sets up the router to be used for testing.\n *\n * The modules sets up the router to be used for testing.\n * It provides spy implementations of `Location` and `LocationStrategy`.\n *\n * @usageNotes\n * ### Example\n *\n * ```\n * beforeEach(() => {\n * TestBed.configureTestingModule({\n * imports: [\n * RouterTestingModule.withRoutes(\n * [{path: '', component: BlankCmp}, {path: 'simple', component: SimpleCmp}]\n * )\n * ]\n * });\n * });\n * ```\n *\n * @publicApi\n */\n@NgModule({\n exports: [RouterModule],\n providers: [\n ROUTER_PROVIDERS,\n EXTRA_ROUTER_TESTING_PROVIDERS,\n provideLocationMocks(),\n withPreloading(NoPreloading).ɵproviders,\n {provide: ROUTES, multi: true, useValue: []},\n ]\n})\nexport class RouterTestingModule {\n static withRoutes(routes: Routes, config?: ExtraOptions):\n ModuleWithProviders<RouterTestingModule> {\n return {\n ngModule: RouterTestingModule,\n providers: [\n {provide: ROUTES, multi: true, useValue: routes},\n {provide: ROUTER_CONFIGURATION, useValue: config ? config : {}},\n ]\n };\n }\n}\n","/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.io/license\n */\n\n// This file exists for easily patching SpyNgModuleFactoryLoader in g3\nexport default {};\n","/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.io/license\n */\n\n/**\n * @module\n * @description\n * Entry point for all public APIs of the router/testing package.\n */\nexport * from './router_testing_module';\nexport * from './spy_ng_module_factory_loader';\n","/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.io/license\n */\n\n/**\n * @module\n * @description\n * Entry point for all public APIs of this package.\n */\nexport * from './src/testing';\n\n// This file only reexports content of the `src` folder. Keep it that way.\n","/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.io/license\n */\n\n// This file is not used to build this module. It is only used during editing\n// by the TypeScript language service and during build for verification. `ngc`\n// replaces this file with production index.ts when it rewrites private symbol\n// names.\n\nexport * from './public_api';\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":["ROUTER_PROVIDERS","withPreloading"],"mappings":";;;;;;;;;;;;AAAA;;;;;;AAMG;AAEH;AACO,MAAM,8BAA8B,GAAG,EA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1
1
  /**
2
- * @license Angular v15.1.0-next.0
2
+ * @license Angular v15.1.0-next.2
3
3
  * (c) 2010-2022 Google LLC. https://angular.io/
4
4
  * License: MIT
5
5
  */
@@ -17,7 +17,6 @@ import { EventEmitter } from '@angular/core';
17
17
  import * as i0 from '@angular/core';
18
18
  import { InjectionToken } from '@angular/core';
19
19
  import { Injector } from '@angular/core';
20
- import { Location as Location_2 } from '@angular/common';
21
20
  import { LocationStrategy } from '@angular/common';
22
21
  import { ModuleWithProviders } from '@angular/core';
23
22
  import { NgModuleFactory } from '@angular/core';
@@ -580,6 +579,7 @@ export declare type CanDeactivateFn<T> = (component: T, currentRoute: ActivatedR
580
579
  * ```
581
580
  *
582
581
  * @publicApi
582
+ * @deprecated Use `CanMatch` instead
583
583
  */
584
584
  export declare interface CanLoad {
585
585
  canLoad(route: Route, segments: UrlSegment[]): Observable<boolean | UrlTree> | Promise<boolean | UrlTree> | boolean | UrlTree;
@@ -591,6 +591,8 @@ export declare interface CanLoad {
591
591
  * @publicApi
592
592
  * @see `CanLoad`
593
593
  * @see `Route`
594
+ * @see `CanMatchFn`
595
+ * @deprecated Use `Route.canMatch` and `CanMatchFn` instead
594
596
  */
595
597
  export declare type CanLoadFn = (route: Route, segments: UrlSegment[]) => Observable<boolean | UrlTree> | Promise<boolean | UrlTree> | boolean | UrlTree;
596
598
 
@@ -1313,7 +1315,7 @@ export declare interface IsActiveMatchOptions {
1313
1315
  * @see `LoadChildrenCallback`
1314
1316
  * @publicApi
1315
1317
  */
1316
- export declare type LoadChildren = LoadChildrenCallback | ɵDeprecatedLoadChildren;
1318
+ export declare type LoadChildren = LoadChildrenCallback;
1317
1319
 
1318
1320
  /**
1319
1321
  *
@@ -1435,6 +1437,16 @@ export declare interface Navigation {
1435
1437
  * @publicApi
1436
1438
  */
1437
1439
  export declare interface NavigationBehaviorOptions {
1440
+ /**
1441
+ * How to handle a navigation request to the current URL.
1442
+ *
1443
+ * This value is a subset of the options available in `OnSameUrlNavigation` and
1444
+ * will take precedence over the default value set for the `Router`.
1445
+ *
1446
+ * @see `OnSameUrlNavigation`
1447
+ * @see `RouterConfigOptions`
1448
+ */
1449
+ onSameUrlNavigation?: Extract<OnSameUrlNavigation, 'reload'>;
1438
1450
  /**
1439
1451
  * When true, navigates without pushing a new state into history.
1440
1452
  *
@@ -1761,6 +1773,32 @@ export declare class NoPreloading implements PreloadingStrategy {
1761
1773
  static ɵprov: i0.ɵɵInjectableDeclaration<NoPreloading>;
1762
1774
  }
1763
1775
 
1776
+ /**
1777
+ * How to handle a navigation request to the current URL. One of:
1778
+ *
1779
+ * - `'ignore'` : The router ignores the request it is the same as the current state.
1780
+ * - `'reload'` : The router processes the URL even if it is not different from the current state.
1781
+ * One example of when you might want this option is if a `canMatch` guard depends on
1782
+ * application state and initially rejects navigation to a route. After fixing the state, you want
1783
+ * to re-navigate to the same URL so the route with the `canMatch` guard can activate.
1784
+ *
1785
+ * Note that this only configures whether the Route reprocesses the URL and triggers related
1786
+ * action and events like redirects, guards, and resolvers. By default, the router re-uses a
1787
+ * component instance when it re-navigates to the same component type without visiting a different
1788
+ * component first. This behavior is configured by the `RouteReuseStrategy`. In order to reload
1789
+ * routed components on same url navigation, you need to set `onSameUrlNavigation` to `'reload'`
1790
+ * _and_ provide a `RouteReuseStrategy` which returns `false` for `shouldReuseRoute`. Additionally,
1791
+ * resolvers and most guards for routes do not run unless the path or path params changed
1792
+ * (configured by `runGuardsAndResolvers`).
1793
+ *
1794
+ * @publicApi
1795
+ * @see RouteReuseStrategy
1796
+ * @see RunGuardsAndResolvers
1797
+ * @see NavigationBehaviorOptions
1798
+ * @see RouterConfigOptions
1799
+ */
1800
+ export declare type OnSameUrlNavigation = 'reload' | 'ignore';
1801
+
1764
1802
  /**
1765
1803
  * Store contextual information about a `RouterOutlet`
1766
1804
  *
@@ -2466,6 +2504,7 @@ export declare interface Route {
2466
2504
  *
2467
2505
  * When using a function rather than DI tokens, the function can call `inject` to get any required
2468
2506
  * dependencies. This `inject` call must be done in a synchronous context.
2507
+ * @deprecated Use `canMatch` instead
2469
2508
  */
2470
2509
  canLoad?: Array<CanLoadFn | any>;
2471
2510
  /**
@@ -2487,11 +2526,19 @@ export declare interface Route {
2487
2526
  */
2488
2527
  loadChildren?: LoadChildren;
2489
2528
  /**
2490
- * Defines when guards and resolvers will be run. One of
2491
- * - `paramsOrQueryParamsChange` : Run when query parameters change.
2529
+ * A policy for when to run guards and resolvers on a route.
2530
+ *
2531
+ * Guards and/or resolvers will always run when a route is activated or deactivated. When a route
2532
+ * is unchanged, the default behavior is the same as `paramsChange`.
2533
+ *
2534
+ * `paramsChange` : Rerun the guards and resolvers when path or
2535
+ * path param changes. This does not include query parameters. This option is the default.
2492
2536
  * - `always` : Run on every execution.
2493
- * By default, guards and resolvers run only when the matrix
2494
- * parameters of the route change.
2537
+ * - `pathParamsChange` : Rerun guards and resolvers when the path params
2538
+ * change. This does not compare matrix or query parameters.
2539
+ * - `paramsOrQueryParamsChange` : Run when path, matrix, or query parameters change.
2540
+ * - `pathParamsOrQueryParamsChange` : Rerun guards and resolvers when the path params
2541
+ * change or query params have changed. This does not include matrix parameters.
2495
2542
  *
2496
2543
  * @see RunGuardsAndResolvers
2497
2544
  */
@@ -2554,10 +2601,9 @@ export declare class RouteConfigLoadStart {
2554
2601
  * @publicApi
2555
2602
  */
2556
2603
  export declare class Router {
2557
- config: Routes;
2558
- private navigations;
2559
2604
  private disposed;
2560
2605
  private locationSubscription?;
2606
+ private get navigationId();
2561
2607
  /**
2562
2608
  * The id of the currently active page in the router.
2563
2609
  * Updated to the transition's target id on a successful navigation.
@@ -2576,13 +2622,14 @@ export declare class Router {
2576
2622
  private console;
2577
2623
  private isNgZoneEnabled;
2578
2624
  /**
2579
- * An event stream for routing events in this NgModule.
2625
+ * An event stream for routing events.
2580
2626
  */
2581
- readonly events: Observable<Event_2>;
2627
+ get events(): Observable<Event_2>;
2582
2628
  /**
2583
2629
  * The current state of routing in this NgModule.
2584
2630
  */
2585
2631
  readonly routerState: RouterState;
2632
+ private options;
2586
2633
  /**
2587
2634
  * A handler for navigation errors in this NgModule.
2588
2635
  *
@@ -2629,24 +2676,15 @@ export declare class Router {
2629
2676
  */
2630
2677
  titleStrategy?: TitleStrategy;
2631
2678
  /**
2632
- * How to handle a navigation request to the current URL. One of:
2679
+ * How to handle a navigation request to the current URL.
2633
2680
  *
2634
- * - `'ignore'` : The router ignores the request.
2635
- * - `'reload'` : The router reloads the URL. Use to implement a "refresh" feature.
2636
- *
2637
- * Note that this only configures whether the Route reprocesses the URL and triggers related
2638
- * action and events like redirects, guards, and resolvers. By default, the router re-uses a
2639
- * component instance when it re-navigates to the same component type without visiting a different
2640
- * component first. This behavior is configured by the `RouteReuseStrategy`. In order to reload
2641
- * routed components on same url navigation, you need to set `onSameUrlNavigation` to `'reload'`
2642
- * _and_ provide a `RouteReuseStrategy` which returns `false` for `shouldReuseRoute`.
2643
2681
  *
2644
2682
  * @deprecated Configure this through `provideRouter` or `RouterModule.forRoot` instead.
2645
2683
  * @see `withRouterConfig`
2646
2684
  * @see `provideRouter`
2647
2685
  * @see `RouterModule`
2648
2686
  */
2649
- onSameUrlNavigation: 'reload' | 'ignore';
2687
+ onSameUrlNavigation: OnSameUrlNavigation;
2650
2688
  /**
2651
2689
  * How to merge parameters, data, resolved data, and title from parent to child
2652
2690
  * routes. One of:
@@ -2702,20 +2740,11 @@ export declare class Router {
2702
2740
  * @see `RouterModule`
2703
2741
  */
2704
2742
  canceledNavigationResolution: 'replace' | 'computed';
2743
+ config: Routes;
2705
2744
  private readonly navigationTransitions;
2706
- /**
2707
- * Creates the router service.
2708
- */
2709
- constructor(
2710
- /** @internal */
2711
- rootComponentType: Type<any> | null,
2712
- /** @internal */
2713
- urlSerializer: UrlSerializer,
2714
- /** @internal */
2715
- rootContexts: ChildrenOutletContexts,
2716
- /** @internal */
2717
- location: Location_2, injector: Injector, compiler: Compiler, config: Routes);
2718
- private setTransition;
2745
+ private readonly urlSerializer;
2746
+ private readonly location;
2747
+ constructor();
2719
2748
  /**
2720
2749
  * Sets up the location change listener and performs the initial navigation.
2721
2750
  */
@@ -2880,7 +2909,6 @@ export declare class Router {
2880
2909
  */
2881
2910
  isActive(url: string | UrlTree, matchOptions: IsActiveMatchOptions): boolean;
2882
2911
  private removeEmptyProps;
2883
- private processNavigations;
2884
2912
  private resetState;
2885
2913
  private resetUrlToCurrentUrlTree;
2886
2914
  private generateNgRouterState;
@@ -2947,13 +2975,13 @@ export declare interface RouterConfigOptions {
2947
2975
  */
2948
2976
  canceledNavigationResolution?: 'replace' | 'computed';
2949
2977
  /**
2950
- * Define what the router should do if it receives a navigation request to the current URL.
2951
- * Default is `ignore`, which causes the router ignores the navigation.
2952
- * This can disable features such as a "refresh" button.
2953
- * Use this option to configure the behavior when navigating to the
2954
- * current URL. Default is 'ignore'.
2978
+ * Configures the default for handling a navigation request to the current URL.
2979
+ *
2980
+ * If unset, the `Router` will use `'ignore'`.
2981
+ *
2982
+ * @see `OnSameUrlNavigation`
2955
2983
  */
2956
- onSameUrlNavigation?: 'reload' | 'ignore';
2984
+ onSameUrlNavigation?: OnSameUrlNavigation;
2957
2985
  /**
2958
2986
  * Defines how the router merges parameters, data, and resolved data from parent to child
2959
2987
  * routes. By default ('emptyOnly'), inherits parent parameters only for
@@ -3964,7 +3992,7 @@ export declare interface UrlCreationOptions {
3964
3992
  * constructor(private router: Router, private route: ActivatedRoute) {}
3965
3993
  *
3966
3994
  * go() {
3967
- * this.router.navigate(['../list'], { relativeTo: this.route });
3995
+ * router.navigate(['../list'], { relativeTo: this.route });
3968
3996
  * }
3969
3997
  * }
3970
3998
  * ```
@@ -3978,7 +4006,7 @@ export declare interface UrlCreationOptions {
3978
4006
  *
3979
4007
  * ```
3980
4008
  * // Navigate to /results?page=1
3981
- * this.router.navigate(['/results'], { queryParams: { page: 1 } });
4009
+ * router.navigate(['/results'], { queryParams: { page: 1 } });
3982
4010
  * ```
3983
4011
  */
3984
4012
  queryParams?: Params | null;
@@ -3987,7 +4015,7 @@ export declare interface UrlCreationOptions {
3987
4015
  *
3988
4016
  * ```
3989
4017
  * // Navigate to /results#top
3990
- * this.router.navigate(['/results'], { fragment: 'top' });
4018
+ * router.navigate(['/results'], { fragment: 'top' });
3991
4019
  * ```
3992
4020
  */
3993
4021
  fragment?: string;
@@ -4000,13 +4028,13 @@ export declare interface UrlCreationOptions {
4000
4028
  * The "preserve" option discards any new query params:
4001
4029
  * ```
4002
4030
  * // from /view1?page=1 to/view2?page=1
4003
- * this.router.navigate(['/view2'], { queryParams: { page: 2 }, queryParamsHandling: "preserve"
4031
+ * router.navigate(['/view2'], { queryParams: { page: 2 }, queryParamsHandling: "preserve"
4004
4032
  * });
4005
4033
  * ```
4006
4034
  * The "merge" option appends new query params to the params from the current URL:
4007
4035
  * ```
4008
4036
  * // from /view1?page=1 to/view2?page=1&otherKey=2
4009
- * this.router.navigate(['/view2'], { queryParams: { otherKey: 2 }, queryParamsHandling: "merge"
4037
+ * router.navigate(['/view2'], { queryParams: { otherKey: 2 }, queryParamsHandling: "merge"
4010
4038
  * });
4011
4039
  * ```
4012
4040
  * In case of a key collision between current parameters and those in the `queryParams` object,
@@ -4019,7 +4047,7 @@ export declare interface UrlCreationOptions {
4019
4047
  *
4020
4048
  * ```
4021
4049
  * // Preserve fragment from /results#top to /view#top
4022
- * this.router.navigate(['/view'], { preserveFragment: true });
4050
+ * router.navigate(['/view'], { preserveFragment: true });
4023
4051
  * ```
4024
4052
  */
4025
4053
  preserveFragment?: boolean;
@@ -4415,16 +4443,6 @@ export { withPreloading as ɵwithPreloading }
4415
4443
  */
4416
4444
  export declare function withRouterConfig(options: RouterConfigOptions): RouterConfigurationFeature;
4417
4445
 
4418
- export declare function ɵassignExtraOptionsToRouter(opts: ExtraOptions, router: Router): void;
4419
-
4420
- /**
4421
- * Deprecated `loadChildren` value types.
4422
- *
4423
- * @publicApi
4424
- * @deprecated represents the deprecated type side of `LoadChildren`.
4425
- */
4426
- export declare type ɵDeprecatedLoadChildren = never;
4427
-
4428
4446
  /**
4429
4447
  * This component is used internally within the router to be a placeholder when an empty
4430
4448
  * router-outlet is needed. For example, with a config such as:
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@angular/router",
3
- "version": "15.1.0-next.0",
3
+ "version": "15.1.0-next.2",
4
4
  "description": "Angular - the routing library",
5
5
  "keywords": [
6
6
  "angular",
@@ -24,9 +24,9 @@
24
24
  "tslib": "^2.3.0"
25
25
  },
26
26
  "peerDependencies": {
27
- "@angular/core": "15.1.0-next.0",
28
- "@angular/common": "15.1.0-next.0",
29
- "@angular/platform-browser": "15.1.0-next.0",
27
+ "@angular/core": "15.1.0-next.2",
28
+ "@angular/common": "15.1.0-next.2",
29
+ "@angular/platform-browser": "15.1.0-next.2",
30
30
  "rxjs": "^6.5.3 || ^7.4.0"
31
31
  },
32
32
  "ng-update": {
@@ -1,5 +1,5 @@
1
1
  /**
2
- * @license Angular v15.1.0-next.0
2
+ * @license Angular v15.1.0-next.2
3
3
  * (c) 2010-2022 Google LLC. https://angular.io/
4
4
  * License: MIT
5
5
  */
@@ -1,5 +1,5 @@
1
1
  /**
2
- * @license Angular v15.1.0-next.0
2
+ * @license Angular v15.1.0-next.2
3
3
  * (c) 2010-2022 Google LLC. https://angular.io/
4
4
  * License: MIT
5
5
  */