@angular/router 7.2.11 → 7.2.15

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,5 +1,5 @@
1
1
  /**
2
- * @license Angular v7.2.11
2
+ * @license Angular v7.2.15
3
3
  * (c) 2010-2019 Google LLC. https://angular.io/
4
4
  * License: MIT
5
5
  */
@@ -1,5 +1,5 @@
1
1
  /**
2
- * @license Angular v7.2.11
2
+ * @license Angular v7.2.15
3
3
  * (c) 2010-2019 Google LLC. https://angular.io/
4
4
  * License: MIT
5
5
  */
package/fesm5/router.js CHANGED
@@ -1,5 +1,5 @@
1
1
  /**
2
- * @license Angular v7.2.11
2
+ * @license Angular v7.2.15
3
3
  * (c) 2010-2019 Google LLC. https://angular.io/
4
4
  * License: MIT
5
5
  */
@@ -1489,10 +1489,10 @@ function createEmptyStateSnapshot(urlTree, rootComponent) {
1489
1489
  * @Component({...})
1490
1490
  * class MyComponent {
1491
1491
  * constructor(route: ActivatedRoute) {
1492
- * const id: Observable<string> = route.params.map(p => p.id);
1493
- * const url: Observable<string> = route.url.map(segments => segments.join(''));
1492
+ * const id: Observable<string> = route.params.pipe(map(p => p.id));
1493
+ * const url: Observable<string> = route.url.pipe(map(segments => segments.join('')));
1494
1494
  * // route.data includes both `data` and `resolve`
1495
- * const user = route.data.map(d => d.user);
1495
+ * const user = route.data.pipe(map(d => d.user));
1496
1496
  * }
1497
1497
  * }
1498
1498
  * ```
@@ -3816,23 +3816,23 @@ var Router = /** @class */ (function () {
3816
3816
  return transitions.pipe(filter(function (t) { return t.id !== 0; }),
3817
3817
  // Extract URL
3818
3818
  map(function (t) { return (__assign({}, t, { extractedUrl: _this.urlHandlingStrategy.extract(t.rawUrl) })); }),
3819
- // Store the Navigation object
3820
- tap(function (t) {
3821
- _this.currentNavigation = {
3822
- id: t.id,
3823
- initialUrl: t.currentRawUrl,
3824
- extractedUrl: t.extractedUrl,
3825
- trigger: t.source,
3826
- extras: t.extras,
3827
- previousNavigation: _this.lastSuccessfulNavigation ? __assign({}, _this.lastSuccessfulNavigation, { previousNavigation: null }) :
3828
- null
3829
- };
3830
- }),
3831
3819
  // Using switchMap so we cancel executing navigations when a new one comes in
3832
3820
  switchMap(function (t) {
3833
3821
  var completed = false;
3834
3822
  var errored = false;
3835
- return of(t).pipe(switchMap(function (t) {
3823
+ return of(t).pipe(
3824
+ // Store the Navigation object
3825
+ tap(function (t) {
3826
+ _this.currentNavigation = {
3827
+ id: t.id,
3828
+ initialUrl: t.currentRawUrl,
3829
+ extractedUrl: t.extractedUrl,
3830
+ trigger: t.source,
3831
+ extras: t.extras,
3832
+ previousNavigation: _this.lastSuccessfulNavigation ? __assign({}, _this.lastSuccessfulNavigation, { previousNavigation: null }) :
3833
+ null
3834
+ };
3835
+ }), switchMap(function (t) {
3836
3836
  var urlTransition = !_this.navigated || t.extractedUrl.toString() !== _this.browserUrlTree.toString();
3837
3837
  var processCurrentUrl = (_this.onSameUrlNavigation === 'reload' ? true : urlTransition) &&
3838
3838
  _this.urlHandlingStrategy.shouldProcessUrl(t.rawUrl);
@@ -5457,18 +5457,32 @@ var RouterModule = /** @class */ (function () {
5457
5457
  * Creates a module with all the router providers and directives. It also optionally sets up an
5458
5458
  * application listener to perform an initial navigation.
5459
5459
  *
5460
- * Options (see `ExtraOptions`):
5461
- * * `enableTracing` makes the router log all its internal events to the console.
5462
- * * `useHash` enables the location strategy that uses the URL fragment instead of the history
5460
+ * Configuration Options:
5461
+ *
5462
+ * * `enableTracing` Toggles whether the router should log all navigation events to the console.
5463
+ * * `useHash` Enables the location strategy that uses the URL fragment instead of the history
5463
5464
  * API.
5464
- * * `initialNavigation` disables the initial navigation.
5465
- * * `errorHandler` provides a custom error handler.
5466
- * * `preloadingStrategy` configures a preloading strategy (see `PreloadAllModules`).
5467
- * * `onSameUrlNavigation` configures how the router handles navigation to the current URL. See
5468
- * `ExtraOptions` for more details.
5469
- * * `paramsInheritanceStrategy` defines how the router merges params, data and resolved data
5470
- * from parent to child routes.
5471
- */
5465
+ * * `initialNavigation` Disables the initial navigation.
5466
+ * * `errorHandler` Defines a custom error handler for failed navigations.
5467
+ * * `preloadingStrategy` Configures a preloading strategy. See `PreloadAllModules`.
5468
+ * * `onSameUrlNavigation` Define what the router should do if it receives a navigation request to
5469
+ * the current URL.
5470
+ * * `scrollPositionRestoration` Configures if the scroll position needs to be restored when
5471
+ * navigating back.
5472
+ * * `anchorScrolling` Configures if the router should scroll to the element when the url has a
5473
+ * fragment.
5474
+ * * `scrollOffset` Configures the scroll offset the router will use when scrolling to an element.
5475
+ * * `paramsInheritanceStrategy` Defines how the router merges params, data and resolved data from
5476
+ * parent to child routes.
5477
+ * * `malformedUriErrorHandler` Defines a custom malformed uri error handler function. This
5478
+ * handler is invoked when encodedURI contains invalid character sequences.
5479
+ * * `urlUpdateStrategy` Defines when the router updates the browser URL. The default behavior is
5480
+ * to update after successful navigation.
5481
+ * * `relativeLinkResolution` Enables the correct relative link resolution in components with
5482
+ * empty paths.
5483
+ *
5484
+ * See `ExtraOptions` for more details about the above options.
5485
+ */
5472
5486
  RouterModule.forRoot = function (routes, config) {
5473
5487
  return {
5474
5488
  ngModule: RouterModule_1,
@@ -5726,7 +5740,7 @@ function provideRouterInitializer() {
5726
5740
  /**
5727
5741
  * @publicApi
5728
5742
  */
5729
- var VERSION = new Version('7.2.11');
5743
+ var VERSION = new Version('7.2.15');
5730
5744
 
5731
5745
  /**
5732
5746
  * @license