@angular/common 16.1.0-next.2 → 16.1.0-next.3
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/esm2022/http/src/client.mjs +3 -3
- package/esm2022/http/src/interceptor.mjs +13 -7
- package/esm2022/http/src/jsonp.mjs +6 -6
- package/esm2022/http/src/module.mjs +12 -12
- package/esm2022/http/src/transfer_cache.mjs +4 -7
- package/esm2022/http/src/xhr.mjs +5 -41
- package/esm2022/http/src/xsrf.mjs +6 -6
- package/esm2022/http/testing/src/backend.mjs +3 -3
- package/esm2022/http/testing/src/module.mjs +4 -4
- package/esm2022/src/common_module.mjs +4 -4
- package/esm2022/src/directives/ng_class.mjs +3 -3
- package/esm2022/src/directives/ng_component_outlet.mjs +3 -3
- package/esm2022/src/directives/ng_for_of.mjs +3 -3
- package/esm2022/src/directives/ng_if.mjs +3 -3
- package/esm2022/src/directives/ng_optimized_image/lcp_image_observer.mjs +3 -3
- package/esm2022/src/directives/ng_optimized_image/ng_optimized_image.mjs +6 -6
- package/esm2022/src/directives/ng_optimized_image/preconnect_link_checker.mjs +3 -3
- package/esm2022/src/directives/ng_optimized_image/preload-link-creator.mjs +3 -3
- package/esm2022/src/directives/ng_plural.mjs +6 -6
- package/esm2022/src/directives/ng_style.mjs +3 -3
- package/esm2022/src/directives/ng_switch.mjs +9 -9
- package/esm2022/src/directives/ng_template_outlet.mjs +3 -3
- package/esm2022/src/i18n/localization.mjs +6 -6
- package/esm2022/src/location/hash_location_strategy.mjs +3 -3
- package/esm2022/src/location/location.mjs +3 -3
- package/esm2022/src/location/location_strategy.mjs +6 -6
- package/esm2022/src/location/platform_location.mjs +6 -6
- package/esm2022/src/pipes/async_pipe.mjs +16 -8
- package/esm2022/src/pipes/case_conversion_pipes.mjs +9 -9
- package/esm2022/src/pipes/date_pipe.mjs +3 -3
- package/esm2022/src/pipes/i18n_plural_pipe.mjs +3 -3
- package/esm2022/src/pipes/i18n_select_pipe.mjs +3 -3
- package/esm2022/src/pipes/json_pipe.mjs +3 -3
- package/esm2022/src/pipes/keyvalue_pipe.mjs +3 -3
- package/esm2022/src/pipes/number_pipe.mjs +9 -9
- package/esm2022/src/pipes/slice_pipe.mjs +3 -3
- package/esm2022/src/version.mjs +1 -1
- package/esm2022/testing/src/location_mock.mjs +3 -3
- package/esm2022/testing/src/mock_location_strategy.mjs +3 -3
- package/esm2022/testing/src/mock_platform_location.mjs +3 -3
- package/esm2022/upgrade/src/location_upgrade_module.mjs +4 -4
- package/fesm2022/common.mjs +128 -120
- package/fesm2022/common.mjs.map +1 -1
- package/fesm2022/http/testing.mjs +8 -8
- package/fesm2022/http.mjs +46 -80
- package/fesm2022/http.mjs.map +1 -1
- package/fesm2022/testing.mjs +10 -10
- package/fesm2022/upgrade.mjs +5 -5
- package/http/index.d.ts +2 -1
- package/http/testing/index.d.ts +1 -1
- package/index.d.ts +2 -2
- package/package.json +2 -2
- package/testing/index.d.ts +1 -1
- package/upgrade/index.d.ts +1 -1
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* @license Angular v16.1.0-next.
|
|
2
|
+
* @license Angular v16.1.0-next.3
|
|
3
3
|
* (c) 2010-2022 Google LLC. https://angular.io/
|
|
4
4
|
* License: MIT
|
|
5
5
|
*/
|
|
@@ -308,10 +308,10 @@ class HttpClientTestingBackend {
|
|
|
308
308
|
return `Match by function: ${matcher.name}`;
|
|
309
309
|
}
|
|
310
310
|
}
|
|
311
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.1.0-next.
|
|
312
|
-
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "16.1.0-next.
|
|
311
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.1.0-next.3", ngImport: i0, type: HttpClientTestingBackend, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
|
|
312
|
+
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "16.1.0-next.3", ngImport: i0, type: HttpClientTestingBackend }); }
|
|
313
313
|
}
|
|
314
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.1.0-next.
|
|
314
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.1.0-next.3", ngImport: i0, type: HttpClientTestingBackend, decorators: [{
|
|
315
315
|
type: Injectable
|
|
316
316
|
}] });
|
|
317
317
|
function describeRequest(testRequest) {
|
|
@@ -336,13 +336,13 @@ function provideHttpClientTesting() {
|
|
|
336
336
|
* @publicApi
|
|
337
337
|
*/
|
|
338
338
|
class HttpClientTestingModule {
|
|
339
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.1.0-next.
|
|
340
|
-
static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "16.1.0-next.
|
|
341
|
-
static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "16.1.0-next.
|
|
339
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.1.0-next.3", ngImport: i0, type: HttpClientTestingModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
|
|
340
|
+
static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "16.1.0-next.3", ngImport: i0, type: HttpClientTestingModule, imports: [HttpClientModule] }); }
|
|
341
|
+
static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "16.1.0-next.3", ngImport: i0, type: HttpClientTestingModule, providers: [
|
|
342
342
|
provideHttpClientTesting(),
|
|
343
343
|
], imports: [HttpClientModule] }); }
|
|
344
344
|
}
|
|
345
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.1.0-next.
|
|
345
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.1.0-next.3", ngImport: i0, type: HttpClientTestingModule, decorators: [{
|
|
346
346
|
type: NgModule,
|
|
347
347
|
args: [{
|
|
348
348
|
imports: [
|
package/fesm2022/http.mjs
CHANGED
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* @license Angular v16.1.0-next.
|
|
2
|
+
* @license Angular v16.1.0-next.3
|
|
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 { Injectable, InjectionToken, inject, Inject, ɵRuntimeError, PLATFORM_ID, makeEnvironmentProviders, NgModule, TransferState, makeStateKey, ɵENABLED_SSR_FEATURES, APP_BOOTSTRAP_LISTENER, ApplicationRef
|
|
8
|
+
import { Injectable, InjectionToken, inject, ɵInitialRenderPendingTasks, Inject, ɵRuntimeError, PLATFORM_ID, makeEnvironmentProviders, NgModule, TransferState, makeStateKey, ɵENABLED_SSR_FEATURES, APP_BOOTSTRAP_LISTENER, ApplicationRef } from '@angular/core';
|
|
9
9
|
import { of, Observable, from } from 'rxjs';
|
|
10
|
-
import { concatMap, filter, map, switchMap, tap, first } from 'rxjs/operators';
|
|
10
|
+
import { concatMap, filter, map, finalize, switchMap, tap, first } from 'rxjs/operators';
|
|
11
11
|
import * as i1 from '@angular/common';
|
|
12
12
|
import { DOCUMENT, ɵparseCookieValue } from '@angular/common';
|
|
13
13
|
|
|
@@ -1371,10 +1371,10 @@ class HttpClient {
|
|
|
1371
1371
|
put(url, body, options = {}) {
|
|
1372
1372
|
return this.request('PUT', url, addBody(options, body));
|
|
1373
1373
|
}
|
|
1374
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.1.0-next.
|
|
1375
|
-
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "16.1.0-next.
|
|
1374
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.1.0-next.3", ngImport: i0, type: HttpClient, deps: [{ token: HttpHandler }], target: i0.ɵɵFactoryTarget.Injectable }); }
|
|
1375
|
+
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "16.1.0-next.3", ngImport: i0, type: HttpClient }); }
|
|
1376
1376
|
}
|
|
1377
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.1.0-next.
|
|
1377
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.1.0-next.3", ngImport: i0, type: HttpClient, decorators: [{
|
|
1378
1378
|
type: Injectable
|
|
1379
1379
|
}], ctorParameters: function () { return [{ type: HttpHandler }]; } });
|
|
1380
1380
|
|
|
@@ -1429,7 +1429,9 @@ function legacyInterceptorFnFactory() {
|
|
|
1429
1429
|
// out.
|
|
1430
1430
|
chain = interceptors.reduceRight(adaptLegacyInterceptorToChain, interceptorChainEndFn);
|
|
1431
1431
|
}
|
|
1432
|
-
|
|
1432
|
+
const pendingTasks = inject(ɵInitialRenderPendingTasks);
|
|
1433
|
+
const taskId = pendingTasks.add();
|
|
1434
|
+
return chain(req, handler).pipe(finalize(() => pendingTasks.remove(taskId)));
|
|
1433
1435
|
};
|
|
1434
1436
|
}
|
|
1435
1437
|
class HttpInterceptorHandler extends HttpHandler {
|
|
@@ -1438,6 +1440,7 @@ class HttpInterceptorHandler extends HttpHandler {
|
|
|
1438
1440
|
this.backend = backend;
|
|
1439
1441
|
this.injector = injector;
|
|
1440
1442
|
this.chain = null;
|
|
1443
|
+
this.pendingTasks = inject(ɵInitialRenderPendingTasks);
|
|
1441
1444
|
}
|
|
1442
1445
|
handle(initialRequest) {
|
|
1443
1446
|
if (this.chain === null) {
|
|
@@ -1451,12 +1454,14 @@ class HttpInterceptorHandler extends HttpHandler {
|
|
|
1451
1454
|
// out.
|
|
1452
1455
|
this.chain = dedupedInterceptorFns.reduceRight((nextSequencedFn, interceptorFn) => chainedInterceptorFn(nextSequencedFn, interceptorFn, this.injector), interceptorChainEndFn);
|
|
1453
1456
|
}
|
|
1454
|
-
|
|
1457
|
+
const taskId = this.pendingTasks.add();
|
|
1458
|
+
return this.chain(initialRequest, downstreamRequest => this.backend.handle(downstreamRequest))
|
|
1459
|
+
.pipe(finalize(() => this.pendingTasks.remove(taskId)));
|
|
1455
1460
|
}
|
|
1456
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.1.0-next.
|
|
1457
|
-
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "16.1.0-next.
|
|
1461
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.1.0-next.3", ngImport: i0, type: HttpInterceptorHandler, deps: [{ token: HttpBackend }, { token: i0.EnvironmentInjector }], target: i0.ɵɵFactoryTarget.Injectable }); }
|
|
1462
|
+
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "16.1.0-next.3", ngImport: i0, type: HttpInterceptorHandler }); }
|
|
1458
1463
|
}
|
|
1459
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.1.0-next.
|
|
1464
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.1.0-next.3", ngImport: i0, type: HttpInterceptorHandler, decorators: [{
|
|
1460
1465
|
type: Injectable
|
|
1461
1466
|
}], ctorParameters: function () { return [{ type: HttpBackend }, { type: i0.EnvironmentInjector }]; } });
|
|
1462
1467
|
|
|
@@ -1658,10 +1663,10 @@ class JsonpClientBackend {
|
|
|
1658
1663
|
}
|
|
1659
1664
|
foreignDocument.adoptNode(script);
|
|
1660
1665
|
}
|
|
1661
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.1.0-next.
|
|
1662
|
-
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "16.1.0-next.
|
|
1666
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.1.0-next.3", ngImport: i0, type: JsonpClientBackend, deps: [{ token: JsonpCallbackContext }, { token: DOCUMENT }], target: i0.ɵɵFactoryTarget.Injectable }); }
|
|
1667
|
+
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "16.1.0-next.3", ngImport: i0, type: JsonpClientBackend }); }
|
|
1663
1668
|
}
|
|
1664
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.1.0-next.
|
|
1669
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.1.0-next.3", ngImport: i0, type: JsonpClientBackend, decorators: [{
|
|
1665
1670
|
type: Injectable
|
|
1666
1671
|
}], ctorParameters: function () { return [{ type: JsonpCallbackContext }, { type: undefined, decorators: [{
|
|
1667
1672
|
type: Inject,
|
|
@@ -1699,10 +1704,10 @@ class JsonpInterceptor {
|
|
|
1699
1704
|
intercept(initialRequest, next) {
|
|
1700
1705
|
return this.injector.runInContext(() => jsonpInterceptorFn(initialRequest, downstreamRequest => next.handle(downstreamRequest)));
|
|
1701
1706
|
}
|
|
1702
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.1.0-next.
|
|
1703
|
-
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "16.1.0-next.
|
|
1707
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.1.0-next.3", ngImport: i0, type: JsonpInterceptor, deps: [{ token: i0.EnvironmentInjector }], target: i0.ɵɵFactoryTarget.Injectable }); }
|
|
1708
|
+
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "16.1.0-next.3", ngImport: i0, type: JsonpInterceptor }); }
|
|
1704
1709
|
}
|
|
1705
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.1.0-next.
|
|
1710
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.1.0-next.3", ngImport: i0, type: JsonpInterceptor, decorators: [{
|
|
1706
1711
|
type: Injectable
|
|
1707
1712
|
}], ctorParameters: function () { return [{ type: i0.EnvironmentInjector }]; } });
|
|
1708
1713
|
|
|
@@ -1743,9 +1748,6 @@ class HttpXhrBackend {
|
|
|
1743
1748
|
throw new ɵRuntimeError(-2800 /* RuntimeErrorCode.MISSING_JSONP_MODULE */, (typeof ngDevMode === 'undefined' || ngDevMode) &&
|
|
1744
1749
|
`Cannot make a JSONP request without JSONP support. To fix the problem, either add the \`withJsonpSupport()\` call (if \`provideHttpClient()\` is used) or import the \`HttpClientJsonpModule\` in the root NgModule.`);
|
|
1745
1750
|
}
|
|
1746
|
-
// Schedule a macrotask. This will cause NgZone.isStable to be set to false,
|
|
1747
|
-
// Which delays server rendering until the request is completed.
|
|
1748
|
-
const macroTaskCanceller = createBackgroundMacroTask();
|
|
1749
1751
|
// Check whether this factory has a special function to load an XHR implementation
|
|
1750
1752
|
// for various non-browser environments. We currently limit it to only `ServerXhr`
|
|
1751
1753
|
// class, which needs to load an XHR implementation.
|
|
@@ -1895,8 +1897,6 @@ class HttpXhrBackend {
|
|
|
1895
1897
|
url: url || undefined,
|
|
1896
1898
|
});
|
|
1897
1899
|
observer.error(res);
|
|
1898
|
-
// Cancel the background macrotask.
|
|
1899
|
-
macroTaskCanceller();
|
|
1900
1900
|
};
|
|
1901
1901
|
// The sentHeaders flag tracks whether the HttpResponseHeaders event
|
|
1902
1902
|
// has been sent on the stream. This is necessary to track if progress
|
|
@@ -1961,28 +1961,17 @@ class HttpXhrBackend {
|
|
|
1961
1961
|
xhr.upload.addEventListener('progress', onUpProgress);
|
|
1962
1962
|
}
|
|
1963
1963
|
}
|
|
1964
|
-
/** Tear down logic to cancel the backround macrotask. */
|
|
1965
|
-
const onLoadEnd = () => macroTaskCanceller();
|
|
1966
|
-
xhr.addEventListener('loadend', onLoadEnd);
|
|
1967
1964
|
// Fire the request, and notify the event stream that it was fired.
|
|
1968
|
-
|
|
1969
|
-
xhr.send(reqBody);
|
|
1970
|
-
}
|
|
1971
|
-
catch (e) {
|
|
1972
|
-
onError(e);
|
|
1973
|
-
}
|
|
1965
|
+
xhr.send(reqBody);
|
|
1974
1966
|
observer.next({ type: HttpEventType.Sent });
|
|
1975
1967
|
// This is the return from the Observable function, which is the
|
|
1976
1968
|
// request cancellation handler.
|
|
1977
1969
|
return () => {
|
|
1978
1970
|
// On a cancellation, remove all registered event listeners.
|
|
1979
|
-
xhr.removeEventListener('loadend', onLoadEnd);
|
|
1980
1971
|
xhr.removeEventListener('error', onError);
|
|
1981
1972
|
xhr.removeEventListener('abort', onError);
|
|
1982
1973
|
xhr.removeEventListener('load', onLoad);
|
|
1983
1974
|
xhr.removeEventListener('timeout', onError);
|
|
1984
|
-
// Cancel the background macrotask.
|
|
1985
|
-
macroTaskCanceller();
|
|
1986
1975
|
if (req.reportProgress) {
|
|
1987
1976
|
xhr.removeEventListener('progress', onDownProgress);
|
|
1988
1977
|
if (reqBody !== null && xhr.upload) {
|
|
@@ -1997,32 +1986,12 @@ class HttpXhrBackend {
|
|
|
1997
1986
|
});
|
|
1998
1987
|
}));
|
|
1999
1988
|
}
|
|
2000
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.1.0-next.
|
|
2001
|
-
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "16.1.0-next.
|
|
1989
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.1.0-next.3", ngImport: i0, type: HttpXhrBackend, deps: [{ token: i1.XhrFactory }], target: i0.ɵɵFactoryTarget.Injectable }); }
|
|
1990
|
+
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "16.1.0-next.3", ngImport: i0, type: HttpXhrBackend }); }
|
|
2002
1991
|
}
|
|
2003
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.1.0-next.
|
|
1992
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.1.0-next.3", ngImport: i0, type: HttpXhrBackend, decorators: [{
|
|
2004
1993
|
type: Injectable
|
|
2005
1994
|
}], ctorParameters: function () { return [{ type: i1.XhrFactory }]; } });
|
|
2006
|
-
/**
|
|
2007
|
-
* A method that creates a background macrotask using Zone.js.
|
|
2008
|
-
*
|
|
2009
|
-
* This is so that Zone.js can intercept HTTP calls, this is important for server rendering,
|
|
2010
|
-
* as the application is only rendered once the application is stabilized, meaning there are pending
|
|
2011
|
-
* macro and micro tasks.
|
|
2012
|
-
*
|
|
2013
|
-
* @returns a callback method to cancel the macrotask.
|
|
2014
|
-
*/
|
|
2015
|
-
function createBackgroundMacroTask() {
|
|
2016
|
-
// We use Zone.js when it's defined as otherwise a `setTimeout` will leave open timers which
|
|
2017
|
-
// causes `fakeAsync` tests to fail.
|
|
2018
|
-
const noop = () => { };
|
|
2019
|
-
if (typeof Zone !== 'undefined') {
|
|
2020
|
-
const zoneCurrent = Zone.current;
|
|
2021
|
-
const task = zoneCurrent.scheduleMacroTask('httpMacroTask', noop, undefined, noop, noop);
|
|
2022
|
-
return () => zoneCurrent.cancelTask(task);
|
|
2023
|
-
}
|
|
2024
|
-
return noop;
|
|
2025
|
-
}
|
|
2026
1995
|
|
|
2027
1996
|
const XSRF_ENABLED = new InjectionToken('XSRF_ENABLED');
|
|
2028
1997
|
const XSRF_DEFAULT_COOKIE_NAME = 'XSRF-TOKEN';
|
|
@@ -2069,10 +2038,10 @@ class HttpXsrfCookieExtractor {
|
|
|
2069
2038
|
}
|
|
2070
2039
|
return this.lastToken;
|
|
2071
2040
|
}
|
|
2072
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.1.0-next.
|
|
2073
|
-
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "16.1.0-next.
|
|
2041
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.1.0-next.3", ngImport: i0, type: HttpXsrfCookieExtractor, deps: [{ token: DOCUMENT }, { token: PLATFORM_ID }, { token: XSRF_COOKIE_NAME }], target: i0.ɵɵFactoryTarget.Injectable }); }
|
|
2042
|
+
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "16.1.0-next.3", ngImport: i0, type: HttpXsrfCookieExtractor }); }
|
|
2074
2043
|
}
|
|
2075
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.1.0-next.
|
|
2044
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.1.0-next.3", ngImport: i0, type: HttpXsrfCookieExtractor, decorators: [{
|
|
2076
2045
|
type: Injectable
|
|
2077
2046
|
}], ctorParameters: function () { return [{ type: undefined, decorators: [{
|
|
2078
2047
|
type: Inject,
|
|
@@ -2112,10 +2081,10 @@ class HttpXsrfInterceptor {
|
|
|
2112
2081
|
intercept(initialRequest, next) {
|
|
2113
2082
|
return this.injector.runInContext(() => xsrfInterceptorFn(initialRequest, downstreamRequest => next.handle(downstreamRequest)));
|
|
2114
2083
|
}
|
|
2115
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.1.0-next.
|
|
2116
|
-
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "16.1.0-next.
|
|
2084
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.1.0-next.3", ngImport: i0, type: HttpXsrfInterceptor, deps: [{ token: i0.EnvironmentInjector }], target: i0.ɵɵFactoryTarget.Injectable }); }
|
|
2085
|
+
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "16.1.0-next.3", ngImport: i0, type: HttpXsrfInterceptor }); }
|
|
2117
2086
|
}
|
|
2118
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.1.0-next.
|
|
2087
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.1.0-next.3", ngImport: i0, type: HttpXsrfInterceptor, decorators: [{
|
|
2119
2088
|
type: Injectable
|
|
2120
2089
|
}], ctorParameters: function () { return [{ type: i0.EnvironmentInjector }]; } });
|
|
2121
2090
|
|
|
@@ -2347,9 +2316,9 @@ class HttpClientXsrfModule {
|
|
|
2347
2316
|
providers: withXsrfConfiguration(options).ɵproviders,
|
|
2348
2317
|
};
|
|
2349
2318
|
}
|
|
2350
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.1.0-next.
|
|
2351
|
-
static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "16.1.0-next.
|
|
2352
|
-
static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "16.1.0-next.
|
|
2319
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.1.0-next.3", ngImport: i0, type: HttpClientXsrfModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
|
|
2320
|
+
static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "16.1.0-next.3", ngImport: i0, type: HttpClientXsrfModule }); }
|
|
2321
|
+
static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "16.1.0-next.3", ngImport: i0, type: HttpClientXsrfModule, providers: [
|
|
2353
2322
|
HttpXsrfInterceptor,
|
|
2354
2323
|
{ provide: HTTP_INTERCEPTORS, useExisting: HttpXsrfInterceptor, multi: true },
|
|
2355
2324
|
{ provide: HttpXsrfTokenExtractor, useClass: HttpXsrfCookieExtractor },
|
|
@@ -2360,7 +2329,7 @@ class HttpClientXsrfModule {
|
|
|
2360
2329
|
{ provide: XSRF_ENABLED, useValue: true },
|
|
2361
2330
|
] }); }
|
|
2362
2331
|
}
|
|
2363
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.1.0-next.
|
|
2332
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.1.0-next.3", ngImport: i0, type: HttpClientXsrfModule, decorators: [{
|
|
2364
2333
|
type: NgModule,
|
|
2365
2334
|
args: [{
|
|
2366
2335
|
providers: [
|
|
@@ -2385,13 +2354,13 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.1.0-next.2",
|
|
|
2385
2354
|
* @publicApi
|
|
2386
2355
|
*/
|
|
2387
2356
|
class HttpClientModule {
|
|
2388
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.1.0-next.
|
|
2389
|
-
static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "16.1.0-next.
|
|
2390
|
-
static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "16.1.0-next.
|
|
2357
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.1.0-next.3", ngImport: i0, type: HttpClientModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
|
|
2358
|
+
static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "16.1.0-next.3", ngImport: i0, type: HttpClientModule }); }
|
|
2359
|
+
static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "16.1.0-next.3", ngImport: i0, type: HttpClientModule, providers: [
|
|
2391
2360
|
provideHttpClient(withInterceptorsFromDi()),
|
|
2392
2361
|
] }); }
|
|
2393
2362
|
}
|
|
2394
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.1.0-next.
|
|
2363
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.1.0-next.3", ngImport: i0, type: HttpClientModule, decorators: [{
|
|
2395
2364
|
type: NgModule,
|
|
2396
2365
|
args: [{
|
|
2397
2366
|
/**
|
|
@@ -2412,13 +2381,13 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.1.0-next.2",
|
|
|
2412
2381
|
* @publicApi
|
|
2413
2382
|
*/
|
|
2414
2383
|
class HttpClientJsonpModule {
|
|
2415
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.1.0-next.
|
|
2416
|
-
static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "16.1.0-next.
|
|
2417
|
-
static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "16.1.0-next.
|
|
2384
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.1.0-next.3", ngImport: i0, type: HttpClientJsonpModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
|
|
2385
|
+
static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "16.1.0-next.3", ngImport: i0, type: HttpClientJsonpModule }); }
|
|
2386
|
+
static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "16.1.0-next.3", ngImport: i0, type: HttpClientJsonpModule, providers: [
|
|
2418
2387
|
withJsonpSupport().ɵproviders,
|
|
2419
2388
|
] }); }
|
|
2420
2389
|
}
|
|
2421
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.1.0-next.
|
|
2390
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.1.0-next.3", ngImport: i0, type: HttpClientJsonpModule, decorators: [{
|
|
2422
2391
|
type: NgModule,
|
|
2423
2392
|
args: [{
|
|
2424
2393
|
providers: [
|
|
@@ -2543,15 +2512,12 @@ function withHttpTransferCache() {
|
|
|
2543
2512
|
useFactory: () => {
|
|
2544
2513
|
const appRef = inject(ApplicationRef);
|
|
2545
2514
|
const cacheState = inject(CACHE_STATE);
|
|
2546
|
-
const pendingTasks = inject(ɵInitialRenderPendingTasks);
|
|
2547
2515
|
return () => {
|
|
2548
|
-
|
|
2549
|
-
isStablePromise.then(() => pendingTasks.whenAllTasksComplete).then(() => {
|
|
2516
|
+
appRef.isStable.pipe(first((isStable) => isStable)).toPromise().then(() => {
|
|
2550
2517
|
cacheState.isCacheActive = false;
|
|
2551
2518
|
});
|
|
2552
2519
|
};
|
|
2553
|
-
}
|
|
2554
|
-
deps: [ApplicationRef, CACHE_STATE, ɵInitialRenderPendingTasks]
|
|
2520
|
+
}
|
|
2555
2521
|
}
|
|
2556
2522
|
];
|
|
2557
2523
|
}
|