apify-client 2.26.0 → 2.26.1-beta.1
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/dist/bundle.js +1109 -321
- package/dist/bundle.js.map +1 -1
- package/dist/resource_clients/actor_server.d.ts +3 -3
- package/dist/resource_clients/actor_server.js +12 -1
- package/package.json +2 -2
package/dist/bundle.js
CHANGED
|
@@ -14272,6 +14272,8 @@ const BUILD_NUMBER_PATTERN = /^(\d+)\.(\d+)\.(\d+)$/;
|
|
|
14272
14272
|
const authHeaders = {
|
|
14273
14273
|
Authorization: null
|
|
14274
14274
|
};
|
|
14275
|
+
// The fetch adapter adds a `User-Agent` of its own otherwise, which a browser lists in the CORS preflight.
|
|
14276
|
+
if (!(0,_utils__rspack_import_1.isNode)()) authHeaders['User-Agent'] = null;
|
|
14275
14277
|
if (this.apifyClient.token) authHeaders['X-Apify-Authorization'] = `Bearer ${this.apifyClient.token}`;
|
|
14276
14278
|
const requestHeaders = mergeHeaders(mergeHeaders(authHeaders, headers), parentRequestId === undefined ? undefined : {
|
|
14277
14279
|
'X-Actor-Request-ID': parentRequestId
|
|
@@ -14291,7 +14293,14 @@ const BUILD_NUMBER_PATTERN = /^(\d+)\.(\d+)\.(\d+)$/;
|
|
|
14291
14293
|
};
|
|
14292
14294
|
if (responseType === 'buffer') config.forceBuffer = true;
|
|
14293
14295
|
if (responseType === 'stream') config.responseType = 'stream';
|
|
14294
|
-
|
|
14296
|
+
// The browser follows the redirects of an XHR itself, while the fetch adapter honors `maxRedirects: 0`.
|
|
14297
|
+
if (!(0,_utils__rspack_import_1.isNode)()) config.adapter = 'fetch';
|
|
14298
|
+
const response = await this.httpClient.call(config);
|
|
14299
|
+
// `redirect: 'manual'` resolves to an opaque response with status 0 instead of the redirect.
|
|
14300
|
+
if (!(0,_utils__rspack_import_1.isNode)() && response.status === 0) {
|
|
14301
|
+
throw new Error(`${method} ${config.url} responded with a redirect, which the client does not follow.`);
|
|
14302
|
+
}
|
|
14303
|
+
return response;
|
|
14295
14304
|
}
|
|
14296
14305
|
/**
|
|
14297
14306
|
* Fetches the Actor, checks that it is a Server Actor, and caches its server URL.
|
|
@@ -18634,7 +18643,7 @@ function isStream(value) {
|
|
|
18634
18643
|
function getVersionData() {
|
|
18635
18644
|
if (true) {
|
|
18636
18645
|
return {
|
|
18637
|
-
version: "2.26.
|
|
18646
|
+
version: "2.26.1-beta.1"
|
|
18638
18647
|
};
|
|
18639
18648
|
}
|
|
18640
18649
|
// eslint-disable-next-line
|
|
@@ -22624,14 +22633,16 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
22624
22633
|
/* import */ var _utils_js__rspack_import_0 = __webpack_require__("Kv");
|
|
22625
22634
|
/* import */ var _core_AxiosError_js__rspack_import_2 = __webpack_require__("f");
|
|
22626
22635
|
/* import */ var _helpers_composeSignals_js__rspack_import_4 = __webpack_require__("oS");
|
|
22627
|
-
/* import */ var
|
|
22628
|
-
/* import */ var
|
|
22629
|
-
/* import */ var
|
|
22636
|
+
/* import */ var _helpers_trackStream_js__rspack_import_8 = __webpack_require__("M");
|
|
22637
|
+
/* import */ var _core_createMultipartBody_js__rspack_import_7 = __webpack_require__("vE");
|
|
22638
|
+
/* import */ var _core_AxiosHeaders_js__rspack_import_6 = __webpack_require__("Z");
|
|
22639
|
+
/* import */ var _helpers_progressEventReducer_js__rspack_import_9 = __webpack_require__("Qs");
|
|
22630
22640
|
/* import */ var _helpers_resolveConfig_js__rspack_import_3 = __webpack_require__("t");
|
|
22631
|
-
/* import */ var
|
|
22641
|
+
/* import */ var _core_settle_js__rspack_import_12 = __webpack_require__("iS");
|
|
22632
22642
|
/* import */ var _helpers_estimateDataURLDecodedBytes_js__rspack_import_5 = __webpack_require__("Ua");
|
|
22633
|
-
/* import */ var
|
|
22634
|
-
/* import */ var
|
|
22643
|
+
/* import */ var _env_data_js__rspack_import_10 = __webpack_require__("f6");
|
|
22644
|
+
/* import */ var _helpers_sanitizeHeaderValue_js__rspack_import_11 = __webpack_require__("A");
|
|
22645
|
+
|
|
22635
22646
|
|
|
22636
22647
|
|
|
22637
22648
|
|
|
@@ -22719,11 +22730,13 @@ const factory = (env) => {
|
|
|
22719
22730
|
{
|
|
22720
22731
|
Request: globalObject.Request,
|
|
22721
22732
|
Response: globalObject.Response,
|
|
22733
|
+
Blob: globalObject.Blob,
|
|
22722
22734
|
},
|
|
22723
22735
|
env
|
|
22724
22736
|
);
|
|
22725
22737
|
|
|
22726
|
-
const
|
|
22738
|
+
const envFetch = _utils_js__rspack_import_0["default"].hasOwnProp(env, 'fetch') ? env.fetch : undefined;
|
|
22739
|
+
const { Request, Response, Blob } = env;
|
|
22727
22740
|
const isFetchSupported = envFetch ? isFunction(envFetch) : typeof fetch === 'function';
|
|
22728
22741
|
const isRequestSupported = isFunction(Request);
|
|
22729
22742
|
const isResponseSupported = isFunction(Response);
|
|
@@ -22772,6 +22785,20 @@ const factory = (env) => {
|
|
|
22772
22785
|
isReadableStreamSupported &&
|
|
22773
22786
|
test(() => _utils_js__rspack_import_0["default"].isReadableStream(new Response('').body));
|
|
22774
22787
|
|
|
22788
|
+
// Some runtimes reject every explicit cache mode. Use own defaults for both
|
|
22789
|
+
// probes so unrelated polluted options cannot affect cache-mode detection.
|
|
22790
|
+
const requestDefaults = Object.assign(Object.create(null), DEFAULT_REQUEST_OPTIONS);
|
|
22791
|
+
|
|
22792
|
+
if (isRequestSupported && !test(() => new Request(_platform_index_js__rspack_import_1["default"].origin, requestDefaults))) {
|
|
22793
|
+
delete requestDefaults.cache;
|
|
22794
|
+
|
|
22795
|
+
// Only omit cache when that makes Request construction succeed. Otherwise
|
|
22796
|
+
// retain the explicit default that protects supporting runtimes from pollution.
|
|
22797
|
+
if (!test(() => new Request(_platform_index_js__rspack_import_1["default"].origin, requestDefaults))) {
|
|
22798
|
+
requestDefaults.cache = DEFAULT_REQUEST_OPTIONS.cache;
|
|
22799
|
+
}
|
|
22800
|
+
}
|
|
22801
|
+
|
|
22775
22802
|
const resolvers = {
|
|
22776
22803
|
stream: supportsResponseStream && ((res) => res.body),
|
|
22777
22804
|
};
|
|
@@ -22805,14 +22832,6 @@ const factory = (env) => {
|
|
|
22805
22832
|
return body.size;
|
|
22806
22833
|
}
|
|
22807
22834
|
|
|
22808
|
-
if (_utils_js__rspack_import_0["default"].isSpecCompliantForm(body)) {
|
|
22809
|
-
const _request = new Request(_platform_index_js__rspack_import_1["default"].origin, {
|
|
22810
|
-
method: 'POST',
|
|
22811
|
-
body,
|
|
22812
|
-
});
|
|
22813
|
-
return (await _request.arrayBuffer()).byteLength;
|
|
22814
|
-
}
|
|
22815
|
-
|
|
22816
22835
|
if (_utils_js__rspack_import_0["default"].isArrayBufferView(body) || _utils_js__rspack_import_0["default"].isArrayBuffer(body)) {
|
|
22817
22836
|
return body.byteLength;
|
|
22818
22837
|
}
|
|
@@ -22875,11 +22894,12 @@ const factory = (env) => {
|
|
|
22875
22894
|
|
|
22876
22895
|
let requestContentLength;
|
|
22877
22896
|
|
|
22878
|
-
//
|
|
22897
|
+
// AxiosErrors we raise while request or response bodies are being streamed. Captured
|
|
22879
22898
|
// by identity so the catch block can surface it directly, regardless of
|
|
22880
22899
|
// how the runtime wraps the resulting fetch rejection (undici exposes it
|
|
22881
22900
|
// as `err.cause`; some browsers drop the original error entirely).
|
|
22882
22901
|
let pendingBodyError = null;
|
|
22902
|
+
let pendingResponseError = null;
|
|
22883
22903
|
|
|
22884
22904
|
const maxBodyLengthError = () =>
|
|
22885
22905
|
new _core_AxiosError_js__rspack_import_2["default"](
|
|
@@ -22903,8 +22923,9 @@ const factory = (env) => {
|
|
|
22903
22923
|
};
|
|
22904
22924
|
}
|
|
22905
22925
|
|
|
22926
|
+
let parsedURL;
|
|
22906
22927
|
if (maybeWithAuthCredentials(url)) {
|
|
22907
|
-
|
|
22928
|
+
parsedURL = new URL(url, _platform_index_js__rspack_import_1["default"].origin);
|
|
22908
22929
|
|
|
22909
22930
|
if (!auth && (parsedURL.username || parsedURL.password)) {
|
|
22910
22931
|
const urlUsername = decodeURIComponentSafe(parsedURL.username);
|
|
@@ -22933,8 +22954,8 @@ const factory = (env) => {
|
|
|
22933
22954
|
// Enforce maxContentLength for data: URLs up-front so we never materialize
|
|
22934
22955
|
// an oversized payload. The HTTP adapter applies the same check (see http.js
|
|
22935
22956
|
// "if (protocol === 'data:')" branch).
|
|
22936
|
-
if (hasMaxContentLength &&
|
|
22937
|
-
const estimated = (0,_helpers_estimateDataURLDecodedBytes_js__rspack_import_5["default"])(
|
|
22957
|
+
if (hasMaxContentLength && parsedURL && parsedURL.protocol === 'data:') {
|
|
22958
|
+
const estimated = (0,_helpers_estimateDataURLDecodedBytes_js__rspack_import_5["default"])(parsedURL.href);
|
|
22938
22959
|
if (estimated > maxContentLength) {
|
|
22939
22960
|
throw new _core_AxiosError_js__rspack_import_2["default"](
|
|
22940
22961
|
'maxContentLength size of ' + maxContentLength + ' exceeded',
|
|
@@ -22945,6 +22966,38 @@ const factory = (env) => {
|
|
|
22945
22966
|
}
|
|
22946
22967
|
}
|
|
22947
22968
|
|
|
22969
|
+
const formContentType =
|
|
22970
|
+
_utils_js__rspack_import_0["default"].isSpecCompliantForm(data) && _core_AxiosHeaders_js__rspack_import_6["default"].from(own('headers')).getContentType();
|
|
22971
|
+
let formBoundary;
|
|
22972
|
+
if (
|
|
22973
|
+
_utils_js__rspack_import_0["default"].isString(formContentType) &&
|
|
22974
|
+
/^multipart\/form-data(?:\s*;|$)/i.test(formContentType.trim())
|
|
22975
|
+
) {
|
|
22976
|
+
const parameters = _core_AxiosHeaders_js__rspack_import_6["default"].parseParameters(formContentType);
|
|
22977
|
+
if (_utils_js__rspack_import_0["default"].hasOwnProp(parameters, 'boundary')) formBoundary = parameters.boundary;
|
|
22978
|
+
}
|
|
22979
|
+
|
|
22980
|
+
if (
|
|
22981
|
+
_utils_js__rspack_import_0["default"].isSpecCompliantForm(data) &&
|
|
22982
|
+
method !== 'get' &&
|
|
22983
|
+
method !== 'head' &&
|
|
22984
|
+
(hasMaxBodyLength ||
|
|
22985
|
+
(onUploadProgress && supportsRequestStream) ||
|
|
22986
|
+
formBoundary !== undefined)
|
|
22987
|
+
) {
|
|
22988
|
+
data = (0,_core_createMultipartBody_js__rspack_import_7["default"])(
|
|
22989
|
+
data,
|
|
22990
|
+
Blob,
|
|
22991
|
+
hasMaxBodyLength ? maxBodyLength : Infinity,
|
|
22992
|
+
maxBodyLengthError,
|
|
22993
|
+
formBoundary
|
|
22994
|
+
);
|
|
22995
|
+
// Blob.type lowercases its value, including a case-sensitive boundary.
|
|
22996
|
+
// Retain the caller's header when an explicit boundary was serialized.
|
|
22997
|
+
headers.setContentType(formBoundary === undefined ? data.type : formContentType);
|
|
22998
|
+
requestContentLength = data.size;
|
|
22999
|
+
}
|
|
23000
|
+
|
|
22948
23001
|
// Enforce maxBodyLength against known-size bodies before dispatch using
|
|
22949
23002
|
// the body's *actual* size — never a caller-declared Content-Length,
|
|
22950
23003
|
// which could under-report to slip an oversized body past the check.
|
|
@@ -22966,7 +23019,7 @@ const factory = (env) => {
|
|
|
22966
23019
|
hasMaxBodyLength && (_utils_js__rspack_import_0["default"].isReadableStream(data) || _utils_js__rspack_import_0["default"].isStream(data));
|
|
22967
23020
|
|
|
22968
23021
|
const trackRequestStream = (stream, onProgress, flush) =>
|
|
22969
|
-
(0,
|
|
23022
|
+
(0,_helpers_trackStream_js__rspack_import_8.trackStream)(
|
|
22970
23023
|
stream,
|
|
22971
23024
|
DEFAULT_CHUNK_SIZE,
|
|
22972
23025
|
(loadedBytes) => {
|
|
@@ -23010,9 +23063,9 @@ const factory = (env) => {
|
|
|
23010
23063
|
if (_request.body) {
|
|
23011
23064
|
const [onProgress, flush] =
|
|
23012
23065
|
(onUploadProgress &&
|
|
23013
|
-
(0,
|
|
23066
|
+
(0,_helpers_progressEventReducer_js__rspack_import_9.progressEventDecorator)(
|
|
23014
23067
|
requestContentLength,
|
|
23015
|
-
(0,
|
|
23068
|
+
(0,_helpers_progressEventReducer_js__rspack_import_9.progressEventReducer)((0,_helpers_progressEventReducer_js__rspack_import_9.asyncDecorator)(onUploadProgress))
|
|
23016
23069
|
)) ||
|
|
23017
23070
|
[];
|
|
23018
23071
|
|
|
@@ -23064,7 +23117,7 @@ const factory = (env) => {
|
|
|
23064
23117
|
}
|
|
23065
23118
|
|
|
23066
23119
|
// Set User-Agent header if not already set (fetch defaults to 'node' in Node.js)
|
|
23067
|
-
headers.set('User-Agent', 'axios/' +
|
|
23120
|
+
headers.set('User-Agent', 'axios/' + _env_data_js__rspack_import_10.VERSION, false);
|
|
23068
23121
|
|
|
23069
23122
|
const safeFetchOptions =
|
|
23070
23123
|
fetchOptions == null ? fetchOptions : Object.assign(Object.create(null), fetchOptions);
|
|
@@ -23083,14 +23136,14 @@ const factory = (env) => {
|
|
|
23083
23136
|
const resolvedOptions = Object.assign(Object.create(null), safeFetchOptions, {
|
|
23084
23137
|
signal: composedSignal,
|
|
23085
23138
|
method: method.toUpperCase(),
|
|
23086
|
-
headers: (0,
|
|
23139
|
+
headers: (0,_helpers_sanitizeHeaderValue_js__rspack_import_11.toByteStringHeaderObject)(headers.normalize()),
|
|
23087
23140
|
body: data,
|
|
23088
23141
|
duplex: 'half',
|
|
23089
23142
|
credentials: isCredentialsSupported ? withCredentials : undefined,
|
|
23090
23143
|
});
|
|
23091
23144
|
|
|
23092
23145
|
if (isRequestSupported) {
|
|
23093
|
-
_utils_js__rspack_import_0["default"].forEach(
|
|
23146
|
+
_utils_js__rspack_import_0["default"].forEach(requestDefaults, (value, key) => {
|
|
23094
23147
|
if (resolvedOptions[key] === undefined) {
|
|
23095
23148
|
resolvedOptions[key] = value;
|
|
23096
23149
|
}
|
|
@@ -23119,7 +23172,7 @@ const factory = (env) => {
|
|
|
23119
23172
|
? _fetch(request, safeFetchOptions)
|
|
23120
23173
|
: _fetch(url, resolvedOptions));
|
|
23121
23174
|
|
|
23122
|
-
const responseHeaders =
|
|
23175
|
+
const responseHeaders = _core_AxiosHeaders_js__rspack_import_6["default"].from(response.headers);
|
|
23123
23176
|
|
|
23124
23177
|
// Cheap pre-check: if the server honestly declares a content-length that
|
|
23125
23178
|
// already exceeds the cap, reject before we start streaming.
|
|
@@ -23153,9 +23206,9 @@ const factory = (env) => {
|
|
|
23153
23206
|
|
|
23154
23207
|
const [onProgress, flush] =
|
|
23155
23208
|
(onDownloadProgress &&
|
|
23156
|
-
(0,
|
|
23209
|
+
(0,_helpers_progressEventReducer_js__rspack_import_9.progressEventDecorator)(
|
|
23157
23210
|
responseContentLength,
|
|
23158
|
-
(0,
|
|
23211
|
+
(0,_helpers_progressEventReducer_js__rspack_import_9.progressEventReducer)((0,_helpers_progressEventReducer_js__rspack_import_9.asyncDecorator)(onDownloadProgress), true)
|
|
23159
23212
|
)) ||
|
|
23160
23213
|
[];
|
|
23161
23214
|
|
|
@@ -23164,19 +23217,19 @@ const factory = (env) => {
|
|
|
23164
23217
|
if (hasMaxContentLength) {
|
|
23165
23218
|
bytesRead = loadedBytes;
|
|
23166
23219
|
if (bytesRead > maxContentLength) {
|
|
23167
|
-
throw new _core_AxiosError_js__rspack_import_2["default"](
|
|
23220
|
+
throw (pendingResponseError = new _core_AxiosError_js__rspack_import_2["default"](
|
|
23168
23221
|
'maxContentLength size of ' + maxContentLength + ' exceeded',
|
|
23169
23222
|
_core_AxiosError_js__rspack_import_2["default"].ERR_BAD_RESPONSE,
|
|
23170
23223
|
config,
|
|
23171
23224
|
request
|
|
23172
|
-
);
|
|
23225
|
+
));
|
|
23173
23226
|
}
|
|
23174
23227
|
}
|
|
23175
23228
|
onProgress && onProgress(loadedBytes);
|
|
23176
23229
|
};
|
|
23177
23230
|
|
|
23178
23231
|
response = new Response(
|
|
23179
|
-
(0,
|
|
23232
|
+
(0,_helpers_trackStream_js__rspack_import_8.trackStream)(response.body, DEFAULT_CHUNK_SIZE, onChunkProgress, () => {
|
|
23180
23233
|
flush && flush();
|
|
23181
23234
|
unsubscribe && unsubscribe();
|
|
23182
23235
|
}),
|
|
@@ -23221,9 +23274,9 @@ const factory = (env) => {
|
|
|
23221
23274
|
!isStreamResponse && unsubscribe && unsubscribe();
|
|
23222
23275
|
|
|
23223
23276
|
return await new Promise((resolve, reject) => {
|
|
23224
|
-
(0,
|
|
23277
|
+
(0,_core_settle_js__rspack_import_12["default"])(resolve, reject, {
|
|
23225
23278
|
data: responseData,
|
|
23226
|
-
headers:
|
|
23279
|
+
headers: _core_AxiosHeaders_js__rspack_import_6["default"].from(response.headers),
|
|
23227
23280
|
status: response.status,
|
|
23228
23281
|
statusText: response.statusText,
|
|
23229
23282
|
config,
|
|
@@ -23255,7 +23308,7 @@ const factory = (env) => {
|
|
|
23255
23308
|
}
|
|
23256
23309
|
|
|
23257
23310
|
// Surface a maxBodyLength violation we raised while the request body was
|
|
23258
|
-
// being streamed.
|
|
23311
|
+
// being streamed. Keeping the original error (rather than reading
|
|
23259
23312
|
// `err.cause.isAxiosError`) keeps the error deterministic across runtimes
|
|
23260
23313
|
// and avoids both prototype-pollution reads and mis-attributing a foreign
|
|
23261
23314
|
// AxiosError that merely happened to land in `err.cause`.
|
|
@@ -23264,6 +23317,10 @@ const factory = (env) => {
|
|
|
23264
23317
|
throw pendingBodyError;
|
|
23265
23318
|
}
|
|
23266
23319
|
|
|
23320
|
+
if (pendingResponseError) {
|
|
23321
|
+
throw pendingResponseError;
|
|
23322
|
+
}
|
|
23323
|
+
|
|
23267
23324
|
// Re-throw AxiosErrors we raised synchronously (data: URL / content-length
|
|
23268
23325
|
// pre-checks, response size enforcement) without re-wrapping them.
|
|
23269
23326
|
if (err instanceof _core_AxiosError_js__rspack_import_2["default"]) {
|
|
@@ -23299,9 +23356,15 @@ const factory = (env) => {
|
|
|
23299
23356
|
const seedCache = new Map();
|
|
23300
23357
|
|
|
23301
23358
|
const getFetch = (config) => {
|
|
23302
|
-
|
|
23303
|
-
const
|
|
23304
|
-
|
|
23359
|
+
const env = Object.create(null);
|
|
23360
|
+
const configuredEnv = config && _utils_js__rspack_import_0["default"].hasOwnProp(config, 'env') && config.env;
|
|
23361
|
+
['fetch', 'Request', 'Response', 'Blob'].forEach((key) => {
|
|
23362
|
+
if (configuredEnv && _utils_js__rspack_import_0["default"].hasOwnProp(configuredEnv, key)) {
|
|
23363
|
+
env[key] = configuredEnv[key];
|
|
23364
|
+
}
|
|
23365
|
+
});
|
|
23366
|
+
const { fetch, Request, Response, Blob } = env;
|
|
23367
|
+
const seeds = [Request, Response, fetch, Blob];
|
|
23305
23368
|
|
|
23306
23369
|
let len = seeds.length,
|
|
23307
23370
|
i = len,
|
|
@@ -23335,18 +23398,20 @@ __webpack_require__.d(__webpack_exports__, {
|
|
|
23335
23398
|
"TV"(__unused_rspack___webpack_module__, __webpack_exports__, __webpack_require__) {
|
|
23336
23399
|
"use strict";
|
|
23337
23400
|
__webpack_require__.r(__webpack_exports__);
|
|
23338
|
-
/* import */ var
|
|
23339
|
-
/* import */ var
|
|
23340
|
-
/* import */ var
|
|
23341
|
-
/* import */ var
|
|
23342
|
-
/* import */ var
|
|
23343
|
-
/* import */ var
|
|
23344
|
-
/* import */ var
|
|
23345
|
-
/* import */ var
|
|
23346
|
-
/* import */ var
|
|
23347
|
-
/* import */ var
|
|
23348
|
-
/* import */ var
|
|
23349
|
-
/* import */ var
|
|
23401
|
+
/* import */ var _utils_js__rspack_import_1 = __webpack_require__("Kv");
|
|
23402
|
+
/* import */ var _core_settle_js__rspack_import_7 = __webpack_require__("iS");
|
|
23403
|
+
/* import */ var _defaults_transitional_js__rspack_import_8 = __webpack_require__("goR");
|
|
23404
|
+
/* import */ var _core_AxiosError_js__rspack_import_6 = __webpack_require__("f");
|
|
23405
|
+
/* import */ var _cancel_CanceledError_js__rspack_import_10 = __webpack_require__("mi");
|
|
23406
|
+
/* import */ var _helpers_normalizeURLForProtocolCheck_js__rspack_import_5 = __webpack_require__("Yv");
|
|
23407
|
+
/* import */ var _helpers_parseProtocol_js__rspack_import_4 = __webpack_require__("Ox");
|
|
23408
|
+
/* import */ var _platform_index_js__rspack_import_0 = __webpack_require__("nF");
|
|
23409
|
+
/* import */ var _core_AxiosHeaders_js__rspack_import_3 = __webpack_require__("Z");
|
|
23410
|
+
/* import */ var _helpers_cookies_js__rspack_import_12 = __webpack_require__("jD");
|
|
23411
|
+
/* import */ var _helpers_progressEventReducer_js__rspack_import_9 = __webpack_require__("Qs");
|
|
23412
|
+
/* import */ var _helpers_resolveConfig_js__rspack_import_2 = __webpack_require__("t");
|
|
23413
|
+
/* import */ var _helpers_sanitizeHeaderValue_js__rspack_import_11 = __webpack_require__("A");
|
|
23414
|
+
|
|
23350
23415
|
|
|
23351
23416
|
|
|
23352
23417
|
|
|
@@ -23365,17 +23430,60 @@ const isXHRAdapterSupported = typeof XMLHttpRequest !== 'undefined';
|
|
|
23365
23430
|
/* export default */ __webpack_exports__["default"] = (isXHRAdapterSupported &&
|
|
23366
23431
|
function (config) {
|
|
23367
23432
|
return new Promise(function dispatchXhrRequest(resolve, reject) {
|
|
23368
|
-
|
|
23433
|
+
let useAsyncXsrf;
|
|
23434
|
+
try {
|
|
23435
|
+
const store =
|
|
23436
|
+
_platform_index_js__rspack_import_0["default"].hasStandardBrowserEnv && typeof window !== 'undefined' && window.cookieStore;
|
|
23437
|
+
useAsyncXsrf = store && _utils_js__rspack_import_1["default"].isFunction(store.get);
|
|
23438
|
+
} catch (e) {
|
|
23439
|
+
// A restricted Cookie Store getter must retain the synchronous fallback.
|
|
23440
|
+
}
|
|
23441
|
+
let xsrfCookieName;
|
|
23442
|
+
const _config = (0,_helpers_resolveConfig_js__rspack_import_2["default"])(
|
|
23443
|
+
config,
|
|
23444
|
+
useAsyncXsrf
|
|
23445
|
+
? (name) => {
|
|
23446
|
+
xsrfCookieName = name;
|
|
23447
|
+
return null;
|
|
23448
|
+
}
|
|
23449
|
+
: undefined
|
|
23450
|
+
);
|
|
23369
23451
|
let requestData = _config.data;
|
|
23370
|
-
const requestHeaders =
|
|
23452
|
+
const requestHeaders = _core_AxiosHeaders_js__rspack_import_3["default"].from(_config.headers).normalize();
|
|
23371
23453
|
let { responseType, onUploadProgress, onDownloadProgress } = _config;
|
|
23372
23454
|
let onCanceled;
|
|
23455
|
+
let timeoutId;
|
|
23373
23456
|
let uploadThrottled, downloadThrottled;
|
|
23374
23457
|
let flushUpload, flushDownload, flushDownloadWithEvent;
|
|
23375
23458
|
|
|
23376
23459
|
function done() {
|
|
23377
|
-
|
|
23378
|
-
|
|
23460
|
+
clearTimeout(timeoutId);
|
|
23461
|
+
// A final progress callback must not prevent the remaining cleanup.
|
|
23462
|
+
// Report errors asynchronously, as onloadend and the throttle timer do.
|
|
23463
|
+
try {
|
|
23464
|
+
flushUpload && flushUpload(); // flush events
|
|
23465
|
+
} catch (err) {
|
|
23466
|
+
setTimeout(() => {
|
|
23467
|
+
throw err;
|
|
23468
|
+
});
|
|
23469
|
+
}
|
|
23470
|
+
try {
|
|
23471
|
+
flushDownload && flushDownload(); // flush events
|
|
23472
|
+
} catch (err) {
|
|
23473
|
+
setTimeout(() => {
|
|
23474
|
+
throw err;
|
|
23475
|
+
});
|
|
23476
|
+
}
|
|
23477
|
+
|
|
23478
|
+
// A flush can synchronously cancel the request and reenter done().
|
|
23479
|
+
// In that case the inner call has already detached these listeners.
|
|
23480
|
+
if (request) {
|
|
23481
|
+
downloadThrottled && request.removeEventListener('progress', downloadThrottled);
|
|
23482
|
+
if (request.upload) {
|
|
23483
|
+
uploadThrottled && request.upload.removeEventListener('progress', uploadThrottled);
|
|
23484
|
+
flushUpload && request.upload.removeEventListener('loadend', flushUpload);
|
|
23485
|
+
}
|
|
23486
|
+
}
|
|
23379
23487
|
|
|
23380
23488
|
_config.cancelToken && _config.cancelToken.unsubscribe(onCanceled);
|
|
23381
23489
|
|
|
@@ -23404,11 +23512,11 @@ const isXHRAdapterSupported = typeof XMLHttpRequest !== 'undefined';
|
|
|
23404
23512
|
// by responseURL where implemented.
|
|
23405
23513
|
if (
|
|
23406
23514
|
request.status === 0 &&
|
|
23407
|
-
((0,
|
|
23408
|
-
(0,
|
|
23515
|
+
((0,_helpers_parseProtocol_js__rspack_import_4["default"])((0,_helpers_normalizeURLForProtocolCheck_js__rspack_import_5["default"])(_config.url)) ||
|
|
23516
|
+
(0,_helpers_parseProtocol_js__rspack_import_4["default"])(_platform_index_js__rspack_import_0["default"].origin)) !== 'file' &&
|
|
23409
23517
|
!(request.responseURL && request.responseURL.startsWith('file:'))
|
|
23410
23518
|
) {
|
|
23411
|
-
reject(new
|
|
23519
|
+
reject(new _core_AxiosError_js__rspack_import_6["default"]('Request aborted', _core_AxiosError_js__rspack_import_6["default"].ECONNABORTED, config, request));
|
|
23412
23520
|
done();
|
|
23413
23521
|
|
|
23414
23522
|
// Clean up request
|
|
@@ -23439,7 +23547,7 @@ const isXHRAdapterSupported = typeof XMLHttpRequest !== 'undefined';
|
|
|
23439
23547
|
}
|
|
23440
23548
|
|
|
23441
23549
|
// Prepare the response
|
|
23442
|
-
const responseHeaders =
|
|
23550
|
+
const responseHeaders = _core_AxiosHeaders_js__rspack_import_3["default"].from(
|
|
23443
23551
|
'getAllResponseHeaders' in request && request.getAllResponseHeaders()
|
|
23444
23552
|
);
|
|
23445
23553
|
const responseData =
|
|
@@ -23455,7 +23563,7 @@ const isXHRAdapterSupported = typeof XMLHttpRequest !== 'undefined';
|
|
|
23455
23563
|
request,
|
|
23456
23564
|
};
|
|
23457
23565
|
|
|
23458
|
-
(0,
|
|
23566
|
+
(0,_core_settle_js__rspack_import_7["default"])(
|
|
23459
23567
|
function _resolve(value) {
|
|
23460
23568
|
resolve(value);
|
|
23461
23569
|
done();
|
|
@@ -23503,7 +23611,7 @@ const isXHRAdapterSupported = typeof XMLHttpRequest !== 'undefined';
|
|
|
23503
23611
|
return;
|
|
23504
23612
|
}
|
|
23505
23613
|
|
|
23506
|
-
reject(new
|
|
23614
|
+
reject(new _core_AxiosError_js__rspack_import_6["default"]('Request aborted', _core_AxiosError_js__rspack_import_6["default"].ECONNABORTED, config, request));
|
|
23507
23615
|
done();
|
|
23508
23616
|
|
|
23509
23617
|
// Clean up request
|
|
@@ -23516,7 +23624,7 @@ const isXHRAdapterSupported = typeof XMLHttpRequest !== 'undefined';
|
|
|
23516
23624
|
// (message may be empty; when present, surface it)
|
|
23517
23625
|
// See https://developer.mozilla.org/docs/Web/API/XMLHttpRequest/error_event
|
|
23518
23626
|
const msg = event && event.message ? event.message : 'Network Error';
|
|
23519
|
-
const err = new
|
|
23627
|
+
const err = new _core_AxiosError_js__rspack_import_6["default"](msg, _core_AxiosError_js__rspack_import_6["default"].ERR_NETWORK, config, request);
|
|
23520
23628
|
// attach the underlying event for consumers who want details
|
|
23521
23629
|
err.event = event || null;
|
|
23522
23630
|
reject(err);
|
|
@@ -23526,17 +23634,18 @@ const isXHRAdapterSupported = typeof XMLHttpRequest !== 'undefined';
|
|
|
23526
23634
|
|
|
23527
23635
|
// Handle timeout
|
|
23528
23636
|
request.ontimeout = function handleTimeout() {
|
|
23637
|
+
if (!request) return;
|
|
23529
23638
|
let timeoutErrorMessage = _config.timeout
|
|
23530
23639
|
? 'timeout of ' + _config.timeout + 'ms exceeded'
|
|
23531
23640
|
: 'timeout exceeded';
|
|
23532
|
-
const transitional = _config.transitional ||
|
|
23641
|
+
const transitional = _config.transitional || _defaults_transitional_js__rspack_import_8["default"];
|
|
23533
23642
|
if (_config.timeoutErrorMessage) {
|
|
23534
23643
|
timeoutErrorMessage = _config.timeoutErrorMessage;
|
|
23535
23644
|
}
|
|
23536
23645
|
reject(
|
|
23537
|
-
new
|
|
23646
|
+
new _core_AxiosError_js__rspack_import_6["default"](
|
|
23538
23647
|
timeoutErrorMessage,
|
|
23539
|
-
transitional.clarifyTimeoutError ?
|
|
23648
|
+
transitional.clarifyTimeoutError ? _core_AxiosError_js__rspack_import_6["default"].ETIMEDOUT : _core_AxiosError_js__rspack_import_6["default"].ECONNABORTED,
|
|
23540
23649
|
config,
|
|
23541
23650
|
request
|
|
23542
23651
|
)
|
|
@@ -23550,15 +23659,8 @@ const isXHRAdapterSupported = typeof XMLHttpRequest !== 'undefined';
|
|
|
23550
23659
|
// Remove Content-Type if data is undefined
|
|
23551
23660
|
requestData === undefined && requestHeaders.setContentType(null);
|
|
23552
23661
|
|
|
23553
|
-
// Add headers to the request
|
|
23554
|
-
if ('setRequestHeader' in request) {
|
|
23555
|
-
_utils_js__rspack_import_8["default"].forEach((0,_helpers_sanitizeHeaderValue_js__rspack_import_9.toByteStringHeaderObject)(requestHeaders), function setRequestHeader(val, key) {
|
|
23556
|
-
request.setRequestHeader(key, val);
|
|
23557
|
-
});
|
|
23558
|
-
}
|
|
23559
|
-
|
|
23560
23662
|
// Add withCredentials to request if needed
|
|
23561
|
-
if (!
|
|
23663
|
+
if (!_utils_js__rspack_import_1["default"].isUndefined(_config.withCredentials)) {
|
|
23562
23664
|
request.withCredentials = !!_config.withCredentials;
|
|
23563
23665
|
}
|
|
23564
23666
|
|
|
@@ -23569,7 +23671,7 @@ const isXHRAdapterSupported = typeof XMLHttpRequest !== 'undefined';
|
|
|
23569
23671
|
|
|
23570
23672
|
// Handle progress if needed
|
|
23571
23673
|
if (onDownloadProgress) {
|
|
23572
|
-
[downloadThrottled, flushDownload, flushDownloadWithEvent] = (0,
|
|
23674
|
+
[downloadThrottled, flushDownload, flushDownloadWithEvent] = (0,_helpers_progressEventReducer_js__rspack_import_9.progressEventReducer)(
|
|
23573
23675
|
onDownloadProgress,
|
|
23574
23676
|
true
|
|
23575
23677
|
);
|
|
@@ -23578,7 +23680,7 @@ const isXHRAdapterSupported = typeof XMLHttpRequest !== 'undefined';
|
|
|
23578
23680
|
|
|
23579
23681
|
// Not all browsers support upload events
|
|
23580
23682
|
if (onUploadProgress && request.upload) {
|
|
23581
|
-
[uploadThrottled, flushUpload] = (0,
|
|
23683
|
+
[uploadThrottled, flushUpload] = (0,_helpers_progressEventReducer_js__rspack_import_9.progressEventReducer)(onUploadProgress);
|
|
23582
23684
|
|
|
23583
23685
|
request.upload.addEventListener('progress', uploadThrottled);
|
|
23584
23686
|
|
|
@@ -23592,13 +23694,15 @@ const isXHRAdapterSupported = typeof XMLHttpRequest !== 'undefined';
|
|
|
23592
23694
|
if (!request) {
|
|
23593
23695
|
return;
|
|
23594
23696
|
}
|
|
23595
|
-
reject(!cancel || cancel.type ? new
|
|
23596
|
-
request
|
|
23697
|
+
reject(!cancel || cancel.type ? new _cancel_CanceledError_js__rspack_import_10["default"](null, config, request) : cancel);
|
|
23698
|
+
const xhr = request;
|
|
23597
23699
|
done();
|
|
23598
23700
|
request = null;
|
|
23701
|
+
xhr.abort();
|
|
23599
23702
|
};
|
|
23600
23703
|
|
|
23601
23704
|
_config.cancelToken && _config.cancelToken.subscribe(onCanceled);
|
|
23705
|
+
if (!request) return;
|
|
23602
23706
|
if (_config.signal) {
|
|
23603
23707
|
_config.signal.aborted
|
|
23604
23708
|
? onCanceled()
|
|
@@ -23606,13 +23710,15 @@ const isXHRAdapterSupported = typeof XMLHttpRequest !== 'undefined';
|
|
|
23606
23710
|
}
|
|
23607
23711
|
}
|
|
23608
23712
|
|
|
23609
|
-
|
|
23713
|
+
if (!request) return;
|
|
23714
|
+
|
|
23715
|
+
const protocol = (0,_helpers_parseProtocol_js__rspack_import_4["default"])(_config.url);
|
|
23610
23716
|
|
|
23611
|
-
if (protocol && !
|
|
23717
|
+
if (protocol && !_platform_index_js__rspack_import_0["default"].protocols.includes(protocol)) {
|
|
23612
23718
|
reject(
|
|
23613
|
-
new
|
|
23719
|
+
new _core_AxiosError_js__rspack_import_6["default"](
|
|
23614
23720
|
'Unsupported protocol ' + protocol + ':',
|
|
23615
|
-
|
|
23721
|
+
_core_AxiosError_js__rspack_import_6["default"].ERR_BAD_REQUEST,
|
|
23616
23722
|
config
|
|
23617
23723
|
)
|
|
23618
23724
|
);
|
|
@@ -23620,8 +23726,72 @@ const isXHRAdapterSupported = typeof XMLHttpRequest !== 'undefined';
|
|
|
23620
23726
|
return;
|
|
23621
23727
|
}
|
|
23622
23728
|
|
|
23623
|
-
|
|
23624
|
-
|
|
23729
|
+
const sendRequest = () => {
|
|
23730
|
+
if (!request) return;
|
|
23731
|
+
// Apply headers after an asynchronous XSRF read so existing headers are
|
|
23732
|
+
// replaced through AxiosHeaders rather than appended by the native XHR.
|
|
23733
|
+
if ('setRequestHeader' in request) {
|
|
23734
|
+
_utils_js__rspack_import_1["default"].forEach(
|
|
23735
|
+
(0,_helpers_sanitizeHeaderValue_js__rspack_import_11.toByteStringHeaderObject)(requestHeaders),
|
|
23736
|
+
function setRequestHeader(val, key) {
|
|
23737
|
+
request.setRequestHeader(key, val);
|
|
23738
|
+
}
|
|
23739
|
+
);
|
|
23740
|
+
}
|
|
23741
|
+
request.send(requestData || null);
|
|
23742
|
+
};
|
|
23743
|
+
|
|
23744
|
+
if (xsrfCookieName) {
|
|
23745
|
+
// Native XHR timeout starts at send(). Cover cookie preparation and the
|
|
23746
|
+
// subsequent request with the same budget and existing timeout handler.
|
|
23747
|
+
const now =
|
|
23748
|
+
typeof performance !== 'undefined' && _utils_js__rspack_import_1["default"].isFunction(performance.now)
|
|
23749
|
+
? () => performance.now()
|
|
23750
|
+
: Date.now;
|
|
23751
|
+
const deadline = request.timeout > 0 ? now() + Number(request.timeout) : undefined;
|
|
23752
|
+
const abortOnTimeout = () => {
|
|
23753
|
+
if (!request) return;
|
|
23754
|
+
const xhr = request;
|
|
23755
|
+
xhr.ontimeout();
|
|
23756
|
+
xhr.abort();
|
|
23757
|
+
};
|
|
23758
|
+
if (deadline !== undefined) {
|
|
23759
|
+
const scheduleTimeout = () => {
|
|
23760
|
+
const remaining = deadline - now();
|
|
23761
|
+
if (remaining > 0) {
|
|
23762
|
+
// Browser timers overflow above the signed 32-bit delay limit.
|
|
23763
|
+
timeoutId = setTimeout(scheduleTimeout, Math.min(remaining, 0x7fffffff));
|
|
23764
|
+
} else {
|
|
23765
|
+
abortOnTimeout();
|
|
23766
|
+
}
|
|
23767
|
+
};
|
|
23768
|
+
scheduleTimeout();
|
|
23769
|
+
}
|
|
23770
|
+
|
|
23771
|
+
_helpers_cookies_js__rspack_import_12["default"].readAsync(xsrfCookieName)
|
|
23772
|
+
.then((value) => {
|
|
23773
|
+
if (!request) return;
|
|
23774
|
+
// Promise callbacks may run before an overdue timer after a busy task.
|
|
23775
|
+
if (deadline !== undefined && now() >= deadline) {
|
|
23776
|
+
abortOnTimeout();
|
|
23777
|
+
return;
|
|
23778
|
+
}
|
|
23779
|
+
if (value) {
|
|
23780
|
+
const headerName =
|
|
23781
|
+
_utils_js__rspack_import_1["default"].hasOwnProp(_config, 'xsrfHeaderName') && _config.xsrfHeaderName;
|
|
23782
|
+
requestHeaders.set(headerName, value);
|
|
23783
|
+
}
|
|
23784
|
+
sendRequest();
|
|
23785
|
+
})
|
|
23786
|
+
.catch((error) => {
|
|
23787
|
+
if (!request) return;
|
|
23788
|
+
reject(_core_AxiosError_js__rspack_import_6["default"].from(error, null, config, request));
|
|
23789
|
+
done();
|
|
23790
|
+
request = null;
|
|
23791
|
+
});
|
|
23792
|
+
} else {
|
|
23793
|
+
sendRequest();
|
|
23794
|
+
}
|
|
23625
23795
|
});
|
|
23626
23796
|
});
|
|
23627
23797
|
|
|
@@ -23928,16 +24098,18 @@ __webpack_require__.d(__webpack_exports__, {
|
|
|
23928
24098
|
"FS"(__unused_rspack___webpack_module__, __webpack_exports__, __webpack_require__) {
|
|
23929
24099
|
"use strict";
|
|
23930
24100
|
__webpack_require__.r(__webpack_exports__);
|
|
23931
|
-
/* import */ var
|
|
23932
|
-
/* import */ var
|
|
23933
|
-
/* import */ var
|
|
23934
|
-
/* import */ var
|
|
23935
|
-
/* import */ var
|
|
23936
|
-
/* import */ var
|
|
23937
|
-
/* import */ var
|
|
24101
|
+
/* import */ var _utils_js__rspack_import_1 = __webpack_require__("Kv");
|
|
24102
|
+
/* import */ var _helpers_buildURL_js__rspack_import_10 = __webpack_require__("Tw");
|
|
24103
|
+
/* import */ var _InterceptorManager_js__rspack_import_3 = __webpack_require__("jR");
|
|
24104
|
+
/* import */ var _dispatchRequest_js__rspack_import_8 = __webpack_require__("Gd");
|
|
24105
|
+
/* import */ var _mergeConfig_js__rspack_import_5 = __webpack_require__("yf");
|
|
24106
|
+
/* import */ var _buildFullPath_js__rspack_import_9 = __webpack_require__("zE");
|
|
24107
|
+
/* import */ var _methodList_js__rspack_import_6 = __webpack_require__("Y");
|
|
23938
24108
|
/* import */ var _helpers_validator_js__rspack_import_0 = __webpack_require__("ig");
|
|
23939
|
-
/* import */ var
|
|
23940
|
-
/* import */ var
|
|
24109
|
+
/* import */ var _AxiosHeaders_js__rspack_import_2 = __webpack_require__("Z");
|
|
24110
|
+
/* import */ var _defaults_transitional_js__rspack_import_7 = __webpack_require__("goR");
|
|
24111
|
+
/* import */ var _AxiosError_js__rspack_import_4 = __webpack_require__("f");
|
|
24112
|
+
|
|
23941
24113
|
|
|
23942
24114
|
|
|
23943
24115
|
|
|
@@ -23953,6 +24125,37 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
23953
24125
|
|
|
23954
24126
|
const validators = _helpers_validator_js__rspack_import_0["default"].validators;
|
|
23955
24127
|
|
|
24128
|
+
// Recognize header maps without consuming objects intended as literal values.
|
|
24129
|
+
// AxiosHeaders from other builds share a brand and header-container interface,
|
|
24130
|
+
// but not constructor identity. A tag and toJSON alone can describe a literal.
|
|
24131
|
+
const isHeadersBucket = (value) => {
|
|
24132
|
+
if (value == null || _utils_js__rspack_import_1["default"].isPlainObject(value) || value instanceof _AxiosHeaders_js__rspack_import_2["default"]) {
|
|
24133
|
+
return true;
|
|
24134
|
+
}
|
|
24135
|
+
|
|
24136
|
+
try {
|
|
24137
|
+
return (
|
|
24138
|
+
_utils_js__rspack_import_1["default"].isObject(value) &&
|
|
24139
|
+
_utils_js__rspack_import_1["default"].getSafeProp(value, Symbol.toStringTag) === 'AxiosHeaders' &&
|
|
24140
|
+
[
|
|
24141
|
+
'toJSON',
|
|
24142
|
+
'set',
|
|
24143
|
+
'get',
|
|
24144
|
+
'has',
|
|
24145
|
+
'delete',
|
|
24146
|
+
'clear',
|
|
24147
|
+
'normalize',
|
|
24148
|
+
'concat',
|
|
24149
|
+
'toString',
|
|
24150
|
+
Symbol.iterator,
|
|
24151
|
+
].every((method) => _utils_js__rspack_import_1["default"].isFunction(_utils_js__rspack_import_1["default"].getSafeProp(value, method)))
|
|
24152
|
+
);
|
|
24153
|
+
} catch (e) {
|
|
24154
|
+
// A failed optional brand probe must not prevent literal header serialization.
|
|
24155
|
+
return false;
|
|
24156
|
+
}
|
|
24157
|
+
};
|
|
24158
|
+
|
|
23956
24159
|
/**
|
|
23957
24160
|
* Create a new instance of Axios
|
|
23958
24161
|
*
|
|
@@ -23964,8 +24167,8 @@ class Axios {
|
|
|
23964
24167
|
constructor(instanceConfig) {
|
|
23965
24168
|
this.defaults = instanceConfig || {};
|
|
23966
24169
|
this.interceptors = {
|
|
23967
|
-
request: new
|
|
23968
|
-
response: new
|
|
24170
|
+
request: new _InterceptorManager_js__rspack_import_3["default"](),
|
|
24171
|
+
response: new _InterceptorManager_js__rspack_import_3["default"](),
|
|
23969
24172
|
};
|
|
23970
24173
|
}
|
|
23971
24174
|
|
|
@@ -23999,16 +24202,26 @@ class Axios {
|
|
|
23999
24202
|
|
|
24000
24203
|
if (!err.stack) {
|
|
24001
24204
|
err.stack = stack;
|
|
24002
|
-
// match without the 2 top stack lines
|
|
24003
24205
|
} else if (stack) {
|
|
24206
|
+
// Match a common suffix after the 2 top frames when available,
|
|
24207
|
+
// otherwise compare the full reconstructed stack.
|
|
24004
24208
|
const firstNewlineIndex = stack.indexOf('\n');
|
|
24005
24209
|
const secondNewlineIndex =
|
|
24006
24210
|
firstNewlineIndex === -1 ? -1 : stack.indexOf('\n', firstNewlineIndex + 1);
|
|
24007
|
-
const
|
|
24008
|
-
secondNewlineIndex === -1 ?
|
|
24009
|
-
|
|
24010
|
-
|
|
24011
|
-
|
|
24211
|
+
const duplicateCheckSuffix =
|
|
24212
|
+
secondNewlineIndex === -1 ? stack : stack.slice(secondNewlineIndex + 1);
|
|
24213
|
+
|
|
24214
|
+
// `AxiosError.from()` may have already inlined the wrapped error's
|
|
24215
|
+
// stack under a `Caused by:` marker. Keep the reconstructed caller
|
|
24216
|
+
// frames ahead of that marker so stack-only reporters do not read
|
|
24217
|
+
// them as part of the low-level cause.
|
|
24218
|
+
const currentStack = String(err.stack);
|
|
24219
|
+
const causeIndex = (0,_AxiosError_js__rspack_import_4.getCauseStackIndex)(err, currentStack);
|
|
24220
|
+
const stackHead = causeIndex === -1 ? currentStack : currentStack.slice(0, causeIndex);
|
|
24221
|
+
const causeSection = causeIndex === -1 ? '' : currentStack.slice(causeIndex);
|
|
24222
|
+
|
|
24223
|
+
if (!stackHead.endsWith(duplicateCheckSuffix)) {
|
|
24224
|
+
err.stack = stackHead + '\n' + stack + causeSection;
|
|
24012
24225
|
}
|
|
24013
24226
|
}
|
|
24014
24227
|
} catch (e) {
|
|
@@ -24030,7 +24243,7 @@ class Axios {
|
|
|
24030
24243
|
config = configOrUrl || {};
|
|
24031
24244
|
}
|
|
24032
24245
|
|
|
24033
|
-
config = (0,
|
|
24246
|
+
config = (0,_mergeConfig_js__rspack_import_5["default"])(this.defaults, config);
|
|
24034
24247
|
|
|
24035
24248
|
const { transitional, paramsSerializer, headers } = config;
|
|
24036
24249
|
|
|
@@ -24044,13 +24257,14 @@ class Axios {
|
|
|
24044
24257
|
legacyInterceptorReqResOrdering: validators.transitional(validators.boolean),
|
|
24045
24258
|
advertiseZstdAcceptEncoding: validators.transitional(validators.boolean),
|
|
24046
24259
|
validateStatusUndefinedResolves: validators.transitional(validators.boolean),
|
|
24260
|
+
encodeBasicAuthUsername: validators.transitional(validators.boolean),
|
|
24047
24261
|
},
|
|
24048
24262
|
false
|
|
24049
24263
|
);
|
|
24050
24264
|
}
|
|
24051
24265
|
|
|
24052
24266
|
if (paramsSerializer != null) {
|
|
24053
|
-
if (
|
|
24267
|
+
if (_utils_js__rspack_import_1["default"].isFunction(paramsSerializer)) {
|
|
24054
24268
|
config.paramsSerializer = {
|
|
24055
24269
|
serialize: paramsSerializer,
|
|
24056
24270
|
};
|
|
@@ -24069,7 +24283,10 @@ class Axios {
|
|
|
24069
24283
|
// Set config.allowAbsoluteUrls
|
|
24070
24284
|
if (config.allowAbsoluteUrls !== undefined) {
|
|
24071
24285
|
// do nothing
|
|
24072
|
-
} else if (
|
|
24286
|
+
} else if (
|
|
24287
|
+
_utils_js__rspack_import_1["default"].hasOwnProp(this.defaults, 'allowAbsoluteUrls') &&
|
|
24288
|
+
this.defaults.allowAbsoluteUrls !== undefined
|
|
24289
|
+
) {
|
|
24073
24290
|
config.allowAbsoluteUrls = this.defaults.allowAbsoluteUrls;
|
|
24074
24291
|
} else {
|
|
24075
24292
|
config.allowAbsoluteUrls = true;
|
|
@@ -24086,20 +24303,29 @@ class Axios {
|
|
|
24086
24303
|
|
|
24087
24304
|
// Set config.method
|
|
24088
24305
|
config.method = (
|
|
24089
|
-
|
|
24090
|
-
|
|
24306
|
+
_utils_js__rspack_import_1["default"].getSafeProp(config, 'method') ||
|
|
24307
|
+
_utils_js__rspack_import_1["default"].getSafeProp(this.defaults, 'method') ||
|
|
24091
24308
|
'get'
|
|
24092
24309
|
).toLowerCase();
|
|
24093
24310
|
|
|
24094
|
-
// Flatten headers
|
|
24095
|
-
|
|
24311
|
+
// Flatten header defaults without consuming literal method-named headers.
|
|
24312
|
+
const commonHeaders = _utils_js__rspack_import_1["default"].getSafeProp(headers, 'common');
|
|
24313
|
+
const methodHeaders = _utils_js__rspack_import_1["default"].getSafeProp(headers, config.method);
|
|
24314
|
+
const contextHeaders =
|
|
24315
|
+
headers &&
|
|
24316
|
+
_utils_js__rspack_import_1["default"].merge(
|
|
24317
|
+
isHeadersBucket(commonHeaders) ? commonHeaders : undefined,
|
|
24318
|
+
isHeadersBucket(methodHeaders) ? methodHeaders : undefined
|
|
24319
|
+
);
|
|
24096
24320
|
|
|
24097
24321
|
headers &&
|
|
24098
|
-
|
|
24099
|
-
|
|
24322
|
+
_utils_js__rspack_import_1["default"].forEach(_methodList_js__rspack_import_6["default"].concat('common'), (method) => {
|
|
24323
|
+
if (isHeadersBucket(_utils_js__rspack_import_1["default"].getSafeProp(headers, method))) {
|
|
24324
|
+
delete headers[method];
|
|
24325
|
+
}
|
|
24100
24326
|
});
|
|
24101
24327
|
|
|
24102
|
-
config.headers =
|
|
24328
|
+
config.headers = _AxiosHeaders_js__rspack_import_2["default"].concat(contextHeaders, headers);
|
|
24103
24329
|
|
|
24104
24330
|
// filter out skipped interceptors
|
|
24105
24331
|
const requestInterceptorChain = [];
|
|
@@ -24111,7 +24337,7 @@ class Axios {
|
|
|
24111
24337
|
|
|
24112
24338
|
synchronousRequestInterceptors = synchronousRequestInterceptors && interceptor.synchronous;
|
|
24113
24339
|
|
|
24114
|
-
const transitional = config.transitional ||
|
|
24340
|
+
const transitional = config.transitional || _defaults_transitional_js__rspack_import_7["default"];
|
|
24115
24341
|
const legacyInterceptorReqResOrdering =
|
|
24116
24342
|
transitional && transitional.legacyInterceptorReqResOrdering;
|
|
24117
24343
|
|
|
@@ -24132,7 +24358,7 @@ class Axios {
|
|
|
24132
24358
|
let len;
|
|
24133
24359
|
|
|
24134
24360
|
if (!synchronousRequestInterceptors) {
|
|
24135
|
-
const chain = [
|
|
24361
|
+
const chain = [_dispatchRequest_js__rspack_import_8["default"].bind(this), undefined];
|
|
24136
24362
|
chain.unshift(...requestInterceptorChain);
|
|
24137
24363
|
chain.push(...responseInterceptorChain);
|
|
24138
24364
|
len = chain.length;
|
|
@@ -24164,9 +24390,9 @@ class Axios {
|
|
|
24164
24390
|
try {
|
|
24165
24391
|
const rejectedResult = onRejected.call(this, error);
|
|
24166
24392
|
|
|
24167
|
-
if (
|
|
24393
|
+
if (_utils_js__rspack_import_1["default"].isThenable(rejectedResult)) {
|
|
24168
24394
|
promise = Promise.resolve(rejectedResult).then(() =>
|
|
24169
|
-
|
|
24395
|
+
_dispatchRequest_js__rspack_import_8["default"].call(this, newConfig)
|
|
24170
24396
|
);
|
|
24171
24397
|
}
|
|
24172
24398
|
} catch (rejectedError) {
|
|
@@ -24179,7 +24405,7 @@ class Axios {
|
|
|
24179
24405
|
|
|
24180
24406
|
if (!promise) {
|
|
24181
24407
|
try {
|
|
24182
|
-
promise =
|
|
24408
|
+
promise = _dispatchRequest_js__rspack_import_8["default"].call(this, newConfig);
|
|
24183
24409
|
} catch (error) {
|
|
24184
24410
|
promise = Promise.reject(error);
|
|
24185
24411
|
}
|
|
@@ -24196,31 +24422,31 @@ class Axios {
|
|
|
24196
24422
|
}
|
|
24197
24423
|
|
|
24198
24424
|
getUri(config) {
|
|
24199
|
-
config = (0,
|
|
24200
|
-
const fullPath = (0,
|
|
24201
|
-
return (0,
|
|
24425
|
+
config = (0,_mergeConfig_js__rspack_import_5["default"])(this.defaults, config);
|
|
24426
|
+
const fullPath = (0,_buildFullPath_js__rspack_import_9["default"])(config.baseURL, config.url, config.allowAbsoluteUrls, config);
|
|
24427
|
+
return (0,_helpers_buildURL_js__rspack_import_10["default"])(fullPath, config.params, config.paramsSerializer);
|
|
24202
24428
|
}
|
|
24203
24429
|
}
|
|
24204
24430
|
|
|
24205
24431
|
// Provide aliases for supported request methods
|
|
24206
|
-
|
|
24432
|
+
_utils_js__rspack_import_1["default"].forEach(['delete', 'get', 'head', 'options'], function forEachMethodNoData(method) {
|
|
24207
24433
|
/*eslint func-names:0*/
|
|
24208
|
-
Axios.prototype[method] = function (url, config) {
|
|
24434
|
+
Axios.prototype[method] = async function (url, config) {
|
|
24209
24435
|
return this.request(
|
|
24210
|
-
(0,
|
|
24436
|
+
(0,_mergeConfig_js__rspack_import_5["default"])(config || {}, {
|
|
24211
24437
|
method,
|
|
24212
24438
|
url,
|
|
24213
|
-
data: config &&
|
|
24439
|
+
data: config && _utils_js__rspack_import_1["default"].hasOwnProp(config, 'data') ? config.data : undefined,
|
|
24214
24440
|
})
|
|
24215
24441
|
);
|
|
24216
24442
|
};
|
|
24217
24443
|
});
|
|
24218
24444
|
|
|
24219
|
-
|
|
24445
|
+
_utils_js__rspack_import_1["default"].forEach(['post', 'put', 'patch', 'query'], function forEachMethodWithData(method) {
|
|
24220
24446
|
function generateHTTPMethod(isForm) {
|
|
24221
|
-
return function httpMethod(url, data, config) {
|
|
24447
|
+
return async function httpMethod(url, data, config) {
|
|
24222
24448
|
return this.request(
|
|
24223
|
-
(0,
|
|
24449
|
+
(0,_mergeConfig_js__rspack_import_5["default"])(config || {}, {
|
|
24224
24450
|
method,
|
|
24225
24451
|
headers: isForm
|
|
24226
24452
|
? {
|
|
@@ -24349,6 +24575,61 @@ function aggregateErrorMessage(error) {
|
|
|
24349
24575
|
return message || error.name || 'AggregateError';
|
|
24350
24576
|
}
|
|
24351
24577
|
|
|
24578
|
+
// Shared with `Axios.prototype.request`, which splices the reconstructed
|
|
24579
|
+
// caller frames in ahead of this marker.
|
|
24580
|
+
const CAUSED_BY_SEPARATOR = '\nCaused by: ';
|
|
24581
|
+
const $causeStack = Symbol('causeStack');
|
|
24582
|
+
|
|
24583
|
+
// Match the section we appended, not marker-like text in an error message or
|
|
24584
|
+
// a replacement stack supplied by the caller. Do not re-read the cause's stack.
|
|
24585
|
+
function getCauseStackIndex(error, stack) {
|
|
24586
|
+
const causeStack = _utils_js__rspack_import_0["default"].hasOwnProp(error, $causeStack) && error[$causeStack];
|
|
24587
|
+
|
|
24588
|
+
return causeStack && stack.endsWith(causeStack) ? stack.length - causeStack.length : -1;
|
|
24589
|
+
}
|
|
24590
|
+
|
|
24591
|
+
/**
|
|
24592
|
+
* Append the stack of a wrapped error to `target.stack`.
|
|
24593
|
+
*
|
|
24594
|
+
* `cause` already exposes the original error for tooling that walks the standard
|
|
24595
|
+
* cause chain, but many error reporters read `stack` and nothing else. Inlining
|
|
24596
|
+
* the wrapped stack there means those reporters surface the underlying failure
|
|
24597
|
+
* instead of the axios frames that normalized it (see #6670).
|
|
24598
|
+
*
|
|
24599
|
+
* Every read is defensive: a custom `Error.prepareStackTrace` hook, a runtime
|
|
24600
|
+
* without stack support, or a replaced `stack` property can leave the value
|
|
24601
|
+
* missing, non-string, or read-only, and normalizing an error must not throw
|
|
24602
|
+
* because of that.
|
|
24603
|
+
*
|
|
24604
|
+
* @param {Error} target The AxiosError being built.
|
|
24605
|
+
* @param {Error} source The error being wrapped.
|
|
24606
|
+
*
|
|
24607
|
+
* @returns {void}
|
|
24608
|
+
*/
|
|
24609
|
+
function appendCauseStack(target, source) {
|
|
24610
|
+
try {
|
|
24611
|
+
const sourceStack = source && source.stack;
|
|
24612
|
+
|
|
24613
|
+
if (typeof sourceStack !== 'string' || !sourceStack) {
|
|
24614
|
+
return;
|
|
24615
|
+
}
|
|
24616
|
+
|
|
24617
|
+
const targetStack = target.stack;
|
|
24618
|
+
|
|
24619
|
+
if (typeof targetStack !== 'string' || !targetStack) {
|
|
24620
|
+
return;
|
|
24621
|
+
}
|
|
24622
|
+
|
|
24623
|
+
// Each call to `from()` creates a fresh target. Re-wrapping includes the
|
|
24624
|
+
// previous stack verbatim, adding one cause section per wrap.
|
|
24625
|
+
const causeStack = CAUSED_BY_SEPARATOR + sourceStack;
|
|
24626
|
+
target.stack = targetStack + causeStack;
|
|
24627
|
+
Object.defineProperty(target, $causeStack, { __proto__: null, value: causeStack });
|
|
24628
|
+
} catch (e) {
|
|
24629
|
+
// Ignore failures from custom stack hooks or un-writable stack properties.
|
|
24630
|
+
}
|
|
24631
|
+
}
|
|
24632
|
+
|
|
24352
24633
|
class AxiosError extends Error {
|
|
24353
24634
|
static from(error, code, config, request, response, customProps) {
|
|
24354
24635
|
// `AggregateError` (thrown by Node on dual-stack/Happy-Eyeballs connection
|
|
@@ -24375,6 +24656,10 @@ class AxiosError extends Error {
|
|
|
24375
24656
|
});
|
|
24376
24657
|
axiosError.name = error.name;
|
|
24377
24658
|
|
|
24659
|
+
// Inline the wrapped stack for reporters that read only `stack`; the `cause`
|
|
24660
|
+
// property above already covers cause-aware tooling.
|
|
24661
|
+
appendCauseStack(axiosError, error);
|
|
24662
|
+
|
|
24378
24663
|
// Preserve status from the original error if not already set from response
|
|
24379
24664
|
if (error.status != null && axiosError.status == null) {
|
|
24380
24665
|
axiosError.status = error.status;
|
|
@@ -24473,7 +24758,9 @@ AxiosError.ERR_FORM_DATA_DEPTH_EXCEEDED = 'ERR_FORM_DATA_DEPTH_EXCEEDED';
|
|
|
24473
24758
|
/* export default */ __webpack_exports__["default"] = (AxiosError);
|
|
24474
24759
|
|
|
24475
24760
|
__webpack_require__.d(__webpack_exports__, {
|
|
24761
|
+
getCauseStackIndex: () => (getCauseStackIndex)
|
|
24476
24762
|
}, {
|
|
24763
|
+
CAUSED_BY_SEPARATOR: CAUSED_BY_SEPARATOR,
|
|
24477
24764
|
REDACTED: REDACTED
|
|
24478
24765
|
});
|
|
24479
24766
|
|
|
@@ -24637,9 +24924,22 @@ function parseParameters(value) {
|
|
|
24637
24924
|
|
|
24638
24925
|
const isValidHeaderName = (str) => /^[-_a-zA-Z0-9^`|~,!#$%&'*+.]+$/.test(str.trim());
|
|
24639
24926
|
|
|
24927
|
+
// `__proto__` is a valid field name, and the one name the uppercase mapping at
|
|
24928
|
+
// the bottom of this file cannot reach: it is inherited from Object.prototype
|
|
24929
|
+
// instead of being declared on AxiosHeaders.prototype, so `self.__proto__ = v`
|
|
24930
|
+
// runs the inherited setter. That silently discards the header, and an array
|
|
24931
|
+
// value replaces the instance prototype, taking every method with it.
|
|
24932
|
+
// Store it under the same kind of case variant that mapping uses for `set` and
|
|
24933
|
+
// `constructor`. Header lookup is caseless, so it reads back under either
|
|
24934
|
+
// spelling, and no own `__proto__` slot is ever created for a later
|
|
24935
|
+
// `Object.assign` to copy onto a plain object through the same setter.
|
|
24936
|
+
const PROTO_HEADER_SLOT = '__Proto__';
|
|
24937
|
+
|
|
24938
|
+
const headerSlot = (name) => (name === '__proto__' ? PROTO_HEADER_SLOT : name);
|
|
24939
|
+
|
|
24640
24940
|
function matchHeaderValue(context, value, header, filter, isHeaderNameFilter) {
|
|
24641
24941
|
if (_utils_js__rspack_import_0["default"].isFunction(filter)) {
|
|
24642
|
-
return filter.call(
|
|
24942
|
+
return filter.call(context, value, header);
|
|
24643
24943
|
}
|
|
24644
24944
|
|
|
24645
24945
|
if (isHeaderNameFilter) {
|
|
@@ -24705,7 +25005,7 @@ class AxiosHeaders {
|
|
|
24705
25005
|
_rewrite === true ||
|
|
24706
25006
|
(_rewrite === undefined && self[key] !== false)
|
|
24707
25007
|
) {
|
|
24708
|
-
self[key || _header] = normalizeValue(_value);
|
|
25008
|
+
self[headerSlot(key || _header)] = normalizeValue(_value);
|
|
24709
25009
|
}
|
|
24710
25010
|
}
|
|
24711
25011
|
|
|
@@ -24834,7 +25134,7 @@ class AxiosHeaders {
|
|
|
24834
25134
|
|
|
24835
25135
|
normalize(format) {
|
|
24836
25136
|
const self = this;
|
|
24837
|
-
const headers =
|
|
25137
|
+
const headers = Object.create(null);
|
|
24838
25138
|
|
|
24839
25139
|
_utils_js__rspack_import_0["default"].forEach(this, (value, header) => {
|
|
24840
25140
|
const key = _utils_js__rspack_import_0["default"].findKey(headers, header);
|
|
@@ -24845,7 +25145,7 @@ class AxiosHeaders {
|
|
|
24845
25145
|
return;
|
|
24846
25146
|
}
|
|
24847
25147
|
|
|
24848
|
-
const normalized = format ? formatHeader(header) : String(header).trim();
|
|
25148
|
+
const normalized = headerSlot(format ? formatHeader(header) : String(header).trim());
|
|
24849
25149
|
|
|
24850
25150
|
if (normalized !== header) {
|
|
24851
25151
|
delete self[header];
|
|
@@ -24989,6 +25289,16 @@ function trimHandlers(handlers) {
|
|
|
24989
25289
|
}
|
|
24990
25290
|
}
|
|
24991
25291
|
|
|
25292
|
+
// Preserve the array-key coercion used before IDs were stored in a Map, without
|
|
25293
|
+
// treating null, empty strings, or noncanonical numeric strings as ID zero.
|
|
25294
|
+
function normalizeHandlerId(id) {
|
|
25295
|
+
if (typeof id === 'string' && id !== '' && String(Number(id)) === id) {
|
|
25296
|
+
return Number(id);
|
|
25297
|
+
}
|
|
25298
|
+
|
|
25299
|
+
return id;
|
|
25300
|
+
}
|
|
25301
|
+
|
|
24992
25302
|
function syncHandlerEntries(manager, internals) {
|
|
24993
25303
|
const handlers = manager.handlers;
|
|
24994
25304
|
const length = countHandlers(handlers);
|
|
@@ -25071,10 +25381,11 @@ class InterceptorManager {
|
|
|
25071
25381
|
|
|
25072
25382
|
syncHandlerEntries(this, internals);
|
|
25073
25383
|
|
|
25074
|
-
const
|
|
25384
|
+
const handlerId = normalizeHandlerId(id);
|
|
25385
|
+
const entry = internals.handlerEntries.get(handlerId);
|
|
25075
25386
|
|
|
25076
25387
|
if (entry) {
|
|
25077
|
-
internals.handlerEntries.delete(
|
|
25388
|
+
internals.handlerEntries.delete(handlerId);
|
|
25078
25389
|
|
|
25079
25390
|
// Ignore IDs invalidated by clear or direct replacement of handlers.
|
|
25080
25391
|
if (this.handlers[entry.index] !== entry.handler) {
|
|
@@ -25139,6 +25450,67 @@ class InterceptorManager {
|
|
|
25139
25450
|
/* export default */ __webpack_exports__["default"] = (InterceptorManager);
|
|
25140
25451
|
|
|
25141
25452
|
|
|
25453
|
+
},
|
|
25454
|
+
"xN"(__unused_rspack___webpack_module__, __webpack_exports__, __webpack_require__) {
|
|
25455
|
+
"use strict";
|
|
25456
|
+
__webpack_require__.r(__webpack_exports__);
|
|
25457
|
+
/* import */ var _utils_js__rspack_import_0 = __webpack_require__("Kv");
|
|
25458
|
+
/* import */ var _AxiosError_js__rspack_import_1 = __webpack_require__("f");
|
|
25459
|
+
|
|
25460
|
+
|
|
25461
|
+
|
|
25462
|
+
|
|
25463
|
+
|
|
25464
|
+
function assertParamsAcyclic(params) {
|
|
25465
|
+
const pending = [{ value: params }];
|
|
25466
|
+
const active = new WeakSet();
|
|
25467
|
+
const visited = new WeakSet();
|
|
25468
|
+
|
|
25469
|
+
while (pending.length) {
|
|
25470
|
+
const { value, done } = pending.pop();
|
|
25471
|
+
if (!_utils_js__rspack_import_0["default"].isPlainObject(value) && !_utils_js__rspack_import_0["default"].isArray(value)) continue;
|
|
25472
|
+
if (done) {
|
|
25473
|
+
active.delete(value);
|
|
25474
|
+
continue;
|
|
25475
|
+
}
|
|
25476
|
+
if (active.has(value)) {
|
|
25477
|
+
throw new _AxiosError_js__rspack_import_1["default"](
|
|
25478
|
+
'Circular reference detected in params',
|
|
25479
|
+
_AxiosError_js__rspack_import_1["default"].ERR_BAD_OPTION_VALUE
|
|
25480
|
+
);
|
|
25481
|
+
}
|
|
25482
|
+
if (visited.has(value)) continue;
|
|
25483
|
+
visited.add(value);
|
|
25484
|
+
active.add(value);
|
|
25485
|
+
pending.push({ value, done: true });
|
|
25486
|
+
|
|
25487
|
+
const keys = Object.keys(value);
|
|
25488
|
+
if (Object.getOwnPropertySymbols && Object.getOwnPropertyDescriptor) {
|
|
25489
|
+
Object.getOwnPropertySymbols(value).forEach((key) => {
|
|
25490
|
+
const descriptor = Object.getOwnPropertyDescriptor(value, key);
|
|
25491
|
+
if (descriptor && descriptor.enumerable) keys.push(key);
|
|
25492
|
+
});
|
|
25493
|
+
}
|
|
25494
|
+
// Shallow array elements retain fields filtered during plain-object merges.
|
|
25495
|
+
// Inspect reserved data properties without evaluating their accessors.
|
|
25496
|
+
keys.forEach((key) => {
|
|
25497
|
+
if (key === '__proto__' || key === 'constructor' || key === 'prototype') {
|
|
25498
|
+
const descriptor = Object.getOwnPropertyDescriptor(value, key);
|
|
25499
|
+
if (descriptor && _utils_js__rspack_import_0["default"].hasOwnProp(descriptor, 'value')) {
|
|
25500
|
+
pending.push({ value: descriptor.value });
|
|
25501
|
+
}
|
|
25502
|
+
} else {
|
|
25503
|
+
pending.push({ value: value[key] });
|
|
25504
|
+
}
|
|
25505
|
+
});
|
|
25506
|
+
}
|
|
25507
|
+
}
|
|
25508
|
+
|
|
25509
|
+
__webpack_require__.d(__webpack_exports__, {
|
|
25510
|
+
"default": () => (assertParamsAcyclic)
|
|
25511
|
+
});
|
|
25512
|
+
|
|
25513
|
+
|
|
25142
25514
|
},
|
|
25143
25515
|
"zE"(__unused_rspack___webpack_module__, __webpack_exports__, __webpack_require__) {
|
|
25144
25516
|
"use strict";
|
|
@@ -25229,6 +25601,57 @@ __webpack_require__.d(__webpack_exports__, {
|
|
|
25229
25601
|
});
|
|
25230
25602
|
|
|
25231
25603
|
|
|
25604
|
+
},
|
|
25605
|
+
"vE"(__unused_rspack___webpack_module__, __webpack_exports__, __webpack_require__) {
|
|
25606
|
+
"use strict";
|
|
25607
|
+
__webpack_require__.r(__webpack_exports__);
|
|
25608
|
+
/* import */ var _utils_js__rspack_import_0 = __webpack_require__("Kv");
|
|
25609
|
+
/* import */ var _platform_index_js__rspack_import_2 = __webpack_require__("nF");
|
|
25610
|
+
/* import */ var _AxiosError_js__rspack_import_1 = __webpack_require__("f");
|
|
25611
|
+
/* import */ var _helpers_formDataToBlob_js__rspack_import_3 = __webpack_require__("D");
|
|
25612
|
+
|
|
25613
|
+
|
|
25614
|
+
|
|
25615
|
+
|
|
25616
|
+
|
|
25617
|
+
function createMultipartBody(form, Blob, limit, limitError, boundary) {
|
|
25618
|
+
// Report missing Blob support before trying to select a random source.
|
|
25619
|
+
if (!_utils_js__rspack_import_0["default"].isFunction(Blob)) {
|
|
25620
|
+
throw new _AxiosError_js__rspack_import_1["default"]('Blob is not supported', _AxiosError_js__rspack_import_1["default"].ERR_NOT_SUPPORT);
|
|
25621
|
+
}
|
|
25622
|
+
|
|
25623
|
+
if (boundary === undefined) {
|
|
25624
|
+
if (_utils_js__rspack_import_0["default"].isFunction(_platform_index_js__rspack_import_2["default"].generateString)) {
|
|
25625
|
+
boundary = 'axios-' + _platform_index_js__rspack_import_2["default"].generateString(36, '0123456789abcdef');
|
|
25626
|
+
} else {
|
|
25627
|
+
const crypto = _utils_js__rspack_import_0["default"].global.crypto;
|
|
25628
|
+
if (!crypto || !_utils_js__rspack_import_0["default"].isFunction(crypto.getRandomValues)) {
|
|
25629
|
+
throw new _AxiosError_js__rspack_import_1["default"]('Random byte generation is not supported', _AxiosError_js__rspack_import_1["default"].ERR_NOT_SUPPORT);
|
|
25630
|
+
}
|
|
25631
|
+
const random = new Uint8Array(18);
|
|
25632
|
+
crypto.getRandomValues(random);
|
|
25633
|
+
boundary =
|
|
25634
|
+
'axios-' + Array.from(random, (value) => ('0' + value.toString(16)).slice(-2)).join('');
|
|
25635
|
+
}
|
|
25636
|
+
}
|
|
25637
|
+
|
|
25638
|
+
try {
|
|
25639
|
+
return (0,_helpers_formDataToBlob_js__rspack_import_3["default"])(form, Blob, limit, limitError, boundary);
|
|
25640
|
+
} catch (error) {
|
|
25641
|
+
if (error instanceof _helpers_formDataToBlob_js__rspack_import_3.FormDataError) {
|
|
25642
|
+
const code =
|
|
25643
|
+
error.reason === 'boundary' ? _AxiosError_js__rspack_import_1["default"].ERR_BAD_OPTION_VALUE : _AxiosError_js__rspack_import_1["default"].ERR_BAD_REQUEST;
|
|
25644
|
+
throw new _AxiosError_js__rspack_import_1["default"](error.message, code);
|
|
25645
|
+
}
|
|
25646
|
+
throw error;
|
|
25647
|
+
}
|
|
25648
|
+
}
|
|
25649
|
+
|
|
25650
|
+
__webpack_require__.d(__webpack_exports__, {
|
|
25651
|
+
"default": () => (createMultipartBody)
|
|
25652
|
+
});
|
|
25653
|
+
|
|
25654
|
+
|
|
25232
25655
|
},
|
|
25233
25656
|
"Gd"(__unused_rspack___webpack_module__, __webpack_exports__, __webpack_require__) {
|
|
25234
25657
|
"use strict";
|
|
@@ -25267,6 +25690,37 @@ function throwIfCancellationRequested(config) {
|
|
|
25267
25690
|
}
|
|
25268
25691
|
}
|
|
25269
25692
|
|
|
25693
|
+
/**
|
|
25694
|
+
* Resolve the clock used to time adapter execution.
|
|
25695
|
+
*
|
|
25696
|
+
* Prefers the monotonic `performance.now()` so wall-clock adjustments do not
|
|
25697
|
+
* skew the measurement, and so frameworks that forbid reading the current
|
|
25698
|
+
* time during prerendering (e.g. Next.js Cache Components) accept it. Falls
|
|
25699
|
+
* back to `Date.now()` in runtimes without the High Resolution Time API.
|
|
25700
|
+
*
|
|
25701
|
+
* @returns {() => number} Millisecond clock
|
|
25702
|
+
*/
|
|
25703
|
+
function resolveClock() {
|
|
25704
|
+
return typeof performance !== 'undefined' && _utils_js__rspack_import_1["default"].isFunction(performance.now)
|
|
25705
|
+
? () => performance.now()
|
|
25706
|
+
: Date.now;
|
|
25707
|
+
}
|
|
25708
|
+
|
|
25709
|
+
/**
|
|
25710
|
+
* Whole milliseconds elapsed since `start`, floored at zero.
|
|
25711
|
+
*
|
|
25712
|
+
* Rounded so the value stays an integer as with `Date.now()`. The fallback
|
|
25713
|
+
* wall clock can move backwards mid-request, so the result is clamped.
|
|
25714
|
+
*
|
|
25715
|
+
* @param {() => number} now Clock returned by `resolveClock()`
|
|
25716
|
+
* @param {number} start Timestamp read from `now`
|
|
25717
|
+
*
|
|
25718
|
+
* @returns {number} Non-negative elapsed milliseconds
|
|
25719
|
+
*/
|
|
25720
|
+
function elapsedSince(now, start) {
|
|
25721
|
+
return Math.max(0, Math.round(now() - start));
|
|
25722
|
+
}
|
|
25723
|
+
|
|
25270
25724
|
/**
|
|
25271
25725
|
* Dispatch a request to the server using the configured adapter.
|
|
25272
25726
|
*
|
|
@@ -25293,10 +25747,15 @@ function dispatchRequest(_config) {
|
|
|
25293
25747
|
|
|
25294
25748
|
const adapter = _adapters_adapters_js__rspack_import_4["default"].getAdapter(config.adapter || _defaults_index_js__rspack_import_5["default"].adapter, config);
|
|
25295
25749
|
|
|
25750
|
+
const now = resolveClock();
|
|
25751
|
+
const start = now();
|
|
25752
|
+
|
|
25296
25753
|
return adapter(config).then(
|
|
25297
25754
|
function onAdapterResolution(response) {
|
|
25298
25755
|
throwIfCancellationRequested(config);
|
|
25299
25756
|
|
|
25757
|
+
response.duration = elapsedSince(now, start);
|
|
25758
|
+
|
|
25300
25759
|
// Expose the current response on config so that transformResponse can
|
|
25301
25760
|
// attach it to any AxiosError it throws (e.g. on JSON parse failure).
|
|
25302
25761
|
// We clean it up afterwards to avoid polluting the config object.
|
|
@@ -25317,6 +25776,7 @@ function dispatchRequest(_config) {
|
|
|
25317
25776
|
|
|
25318
25777
|
// Transform response data
|
|
25319
25778
|
if (reason && reason.response) {
|
|
25779
|
+
reason.response.duration = elapsedSince(now, start);
|
|
25320
25780
|
config.response = reason.response;
|
|
25321
25781
|
try {
|
|
25322
25782
|
reason.response.data = _transformData_js__rspack_import_3["default"].call(
|
|
@@ -25347,6 +25807,8 @@ __webpack_require__.d(__webpack_exports__, {
|
|
|
25347
25807
|
__webpack_require__.r(__webpack_exports__);
|
|
25348
25808
|
/* import */ var _utils_js__rspack_import_1 = __webpack_require__("Kv");
|
|
25349
25809
|
/* import */ var _AxiosHeaders_js__rspack_import_0 = __webpack_require__("Z");
|
|
25810
|
+
/* import */ var _assertParamsAcyclic_js__rspack_import_2 = __webpack_require__("xN");
|
|
25811
|
+
|
|
25350
25812
|
|
|
25351
25813
|
|
|
25352
25814
|
|
|
@@ -25357,14 +25819,184 @@ const headersToObject = (thing) => (thing instanceof _AxiosHeaders_js__rspack_im
|
|
|
25357
25819
|
const ownEnumerableKeys = (thing) => {
|
|
25358
25820
|
if (Object.getOwnPropertySymbols && Object.getOwnPropertyDescriptor) {
|
|
25359
25821
|
return Object.keys(thing).concat(
|
|
25360
|
-
Object.getOwnPropertySymbols(thing).filter(
|
|
25361
|
-
|
|
25362
|
-
|
|
25822
|
+
Object.getOwnPropertySymbols(thing).filter((symbol) => {
|
|
25823
|
+
const descriptor = Object.getOwnPropertyDescriptor(thing, symbol);
|
|
25824
|
+
return descriptor && descriptor.enumerable;
|
|
25825
|
+
})
|
|
25363
25826
|
);
|
|
25364
25827
|
}
|
|
25365
25828
|
return Object.keys(thing);
|
|
25366
25829
|
};
|
|
25367
25830
|
|
|
25831
|
+
// Copy params without recursive merges so the serializer remains responsible
|
|
25832
|
+
// for its depth policy. Only visit defaults that contribute to the result.
|
|
25833
|
+
function mergeParams(a, b) {
|
|
25834
|
+
const pending = [];
|
|
25835
|
+
const copies = new WeakMap();
|
|
25836
|
+
const empty = {};
|
|
25837
|
+
|
|
25838
|
+
function copy(target, source) {
|
|
25839
|
+
if (!_utils_js__rspack_import_1["default"].isPlainObject(source)) {
|
|
25840
|
+
return _utils_js__rspack_import_1["default"].isArray(source) ? source.slice() : source;
|
|
25841
|
+
}
|
|
25842
|
+
|
|
25843
|
+
const base = _utils_js__rspack_import_1["default"].isPlainObject(target) ? target : empty;
|
|
25844
|
+
let bases = copies.get(source);
|
|
25845
|
+
if (!bases) {
|
|
25846
|
+
bases = new WeakMap();
|
|
25847
|
+
copies.set(source, bases);
|
|
25848
|
+
}
|
|
25849
|
+
if (bases.has(base)) return bases.get(base);
|
|
25850
|
+
|
|
25851
|
+
const result = {};
|
|
25852
|
+
bases.set(base, result);
|
|
25853
|
+
pending.push({ base, source, result });
|
|
25854
|
+
return result;
|
|
25855
|
+
}
|
|
25856
|
+
|
|
25857
|
+
const result = _utils_js__rspack_import_1["default"].isUndefined(b) ? copy(undefined, a) : copy(a, b);
|
|
25858
|
+
while (pending.length) {
|
|
25859
|
+
const { base, source, result: target } = pending.pop();
|
|
25860
|
+
const baseKeys = new Set(ownEnumerableKeys(base));
|
|
25861
|
+
const sourceKeys = new Set(ownEnumerableKeys(source));
|
|
25862
|
+
const keys = new Set([...baseKeys, ...sourceKeys]);
|
|
25863
|
+
|
|
25864
|
+
keys.forEach((key) => {
|
|
25865
|
+
if (key === '__proto__' || key === 'constructor' || key === 'prototype') return;
|
|
25866
|
+
const hasSource = sourceKeys.has(key);
|
|
25867
|
+
const value = hasSource ? source[key] : undefined;
|
|
25868
|
+
const previous =
|
|
25869
|
+
(!hasSource || _utils_js__rspack_import_1["default"].isPlainObject(value)) && baseKeys.has(key) ? base[key] : undefined;
|
|
25870
|
+
target[key] = hasSource ? copy(previous, value) : copy(undefined, previous);
|
|
25871
|
+
});
|
|
25872
|
+
}
|
|
25873
|
+
|
|
25874
|
+
(0,_assertParamsAcyclic_js__rspack_import_2["default"])(result);
|
|
25875
|
+
return result;
|
|
25876
|
+
}
|
|
25877
|
+
|
|
25878
|
+
function getMergedValue(target, source, prop, caseless) {
|
|
25879
|
+
if (_utils_js__rspack_import_1["default"].isPlainObject(target) && _utils_js__rspack_import_1["default"].isPlainObject(source)) {
|
|
25880
|
+
return _utils_js__rspack_import_1["default"].merge.call({ caseless }, target, source);
|
|
25881
|
+
} else if (_utils_js__rspack_import_1["default"].isPlainObject(source)) {
|
|
25882
|
+
return _utils_js__rspack_import_1["default"].merge({}, source);
|
|
25883
|
+
} else if (_utils_js__rspack_import_1["default"].isArray(source)) {
|
|
25884
|
+
return source.slice();
|
|
25885
|
+
}
|
|
25886
|
+
return source;
|
|
25887
|
+
}
|
|
25888
|
+
|
|
25889
|
+
function mergeDeepProperties(a, b, prop, caseless) {
|
|
25890
|
+
if (!_utils_js__rspack_import_1["default"].isUndefined(b)) {
|
|
25891
|
+
return getMergedValue(a, b, prop, caseless);
|
|
25892
|
+
} else if (!_utils_js__rspack_import_1["default"].isUndefined(a)) {
|
|
25893
|
+
return getMergedValue(undefined, a, prop, caseless);
|
|
25894
|
+
}
|
|
25895
|
+
}
|
|
25896
|
+
|
|
25897
|
+
// eslint-disable-next-line consistent-return
|
|
25898
|
+
function valueFromConfig2(a, b) {
|
|
25899
|
+
if (!_utils_js__rspack_import_1["default"].isUndefined(b)) {
|
|
25900
|
+
return getMergedValue(undefined, b);
|
|
25901
|
+
}
|
|
25902
|
+
}
|
|
25903
|
+
|
|
25904
|
+
// eslint-disable-next-line consistent-return
|
|
25905
|
+
function defaultToConfig2(a, b) {
|
|
25906
|
+
if (!_utils_js__rspack_import_1["default"].isUndefined(b)) {
|
|
25907
|
+
return getMergedValue(undefined, b);
|
|
25908
|
+
} else if (!_utils_js__rspack_import_1["default"].isUndefined(a)) {
|
|
25909
|
+
return getMergedValue(undefined, a);
|
|
25910
|
+
}
|
|
25911
|
+
}
|
|
25912
|
+
|
|
25913
|
+
function getMergedTransitionalOption(config1, config2, prop) {
|
|
25914
|
+
const transitional2 = _utils_js__rspack_import_1["default"].hasOwnProp(config2, 'transitional')
|
|
25915
|
+
? config2.transitional
|
|
25916
|
+
: undefined;
|
|
25917
|
+
|
|
25918
|
+
if (!_utils_js__rspack_import_1["default"].isUndefined(transitional2)) {
|
|
25919
|
+
if (_utils_js__rspack_import_1["default"].isPlainObject(transitional2)) {
|
|
25920
|
+
if (_utils_js__rspack_import_1["default"].hasOwnProp(transitional2, prop)) {
|
|
25921
|
+
return transitional2[prop];
|
|
25922
|
+
}
|
|
25923
|
+
} else {
|
|
25924
|
+
return undefined;
|
|
25925
|
+
}
|
|
25926
|
+
}
|
|
25927
|
+
|
|
25928
|
+
const transitional1 = _utils_js__rspack_import_1["default"].hasOwnProp(config1, 'transitional')
|
|
25929
|
+
? config1.transitional
|
|
25930
|
+
: undefined;
|
|
25931
|
+
|
|
25932
|
+
if (_utils_js__rspack_import_1["default"].isPlainObject(transitional1) && _utils_js__rspack_import_1["default"].hasOwnProp(transitional1, prop)) {
|
|
25933
|
+
return transitional1[prop];
|
|
25934
|
+
}
|
|
25935
|
+
|
|
25936
|
+
return undefined;
|
|
25937
|
+
}
|
|
25938
|
+
|
|
25939
|
+
// eslint-disable-next-line consistent-return
|
|
25940
|
+
function mergeDirectKeys(a, b, prop, config1, config2) {
|
|
25941
|
+
if (_utils_js__rspack_import_1["default"].hasOwnProp(config2, prop)) {
|
|
25942
|
+
return getMergedValue(a, b);
|
|
25943
|
+
} else if (_utils_js__rspack_import_1["default"].hasOwnProp(config1, prop)) {
|
|
25944
|
+
return getMergedValue(undefined, a);
|
|
25945
|
+
}
|
|
25946
|
+
}
|
|
25947
|
+
|
|
25948
|
+
function mergeHeaders(a, b, prop) {
|
|
25949
|
+
return mergeDeepProperties(headersToObject(a), headersToObject(b), prop, true);
|
|
25950
|
+
}
|
|
25951
|
+
|
|
25952
|
+
// Null-proto, frozen descriptor so a polluted Object.prototype.get cannot turn
|
|
25953
|
+
// this data descriptor into an accessor descriptor on the way in.
|
|
25954
|
+
// defineProperty only reads it, so one shared instance serves every call.
|
|
25955
|
+
const hasOwnPropertyDescriptor = Object.freeze({
|
|
25956
|
+
__proto__: null,
|
|
25957
|
+
value: Object.prototype.hasOwnProperty,
|
|
25958
|
+
enumerable: false,
|
|
25959
|
+
writable: true,
|
|
25960
|
+
configurable: true,
|
|
25961
|
+
});
|
|
25962
|
+
|
|
25963
|
+
// The strategy table and the strategies above are stateless, so they are
|
|
25964
|
+
// built once at module load instead of on every call: mergeConfig runs at
|
|
25965
|
+
// most twice per request (once from a method alias, once from `_request`).
|
|
25966
|
+
const mergeMap = {
|
|
25967
|
+
url: valueFromConfig2,
|
|
25968
|
+
method: valueFromConfig2,
|
|
25969
|
+
data: valueFromConfig2,
|
|
25970
|
+
baseURL: defaultToConfig2,
|
|
25971
|
+
transformRequest: defaultToConfig2,
|
|
25972
|
+
transformResponse: defaultToConfig2,
|
|
25973
|
+
params: mergeParams,
|
|
25974
|
+
paramsSerializer: defaultToConfig2,
|
|
25975
|
+
timeout: defaultToConfig2,
|
|
25976
|
+
timeoutErrorMessage: defaultToConfig2,
|
|
25977
|
+
withCredentials: defaultToConfig2,
|
|
25978
|
+
withXSRFToken: defaultToConfig2,
|
|
25979
|
+
adapter: defaultToConfig2,
|
|
25980
|
+
responseType: defaultToConfig2,
|
|
25981
|
+
xsrfCookieName: defaultToConfig2,
|
|
25982
|
+
xsrfHeaderName: defaultToConfig2,
|
|
25983
|
+
onUploadProgress: defaultToConfig2,
|
|
25984
|
+
onDownloadProgress: defaultToConfig2,
|
|
25985
|
+
decompress: defaultToConfig2,
|
|
25986
|
+
maxContentLength: defaultToConfig2,
|
|
25987
|
+
maxBodyLength: defaultToConfig2,
|
|
25988
|
+
beforeRedirect: defaultToConfig2,
|
|
25989
|
+
transport: defaultToConfig2,
|
|
25990
|
+
httpAgent: defaultToConfig2,
|
|
25991
|
+
httpsAgent: defaultToConfig2,
|
|
25992
|
+
cancelToken: defaultToConfig2,
|
|
25993
|
+
socketPath: defaultToConfig2,
|
|
25994
|
+
allowedSocketPaths: defaultToConfig2,
|
|
25995
|
+
responseEncoding: defaultToConfig2,
|
|
25996
|
+
validateStatus: mergeDirectKeys,
|
|
25997
|
+
headers: mergeHeaders,
|
|
25998
|
+
};
|
|
25999
|
+
|
|
25368
26000
|
/**
|
|
25369
26001
|
* Config-specific merge-function which creates a new config-object
|
|
25370
26002
|
* by merging two configuration objects together.
|
|
@@ -25384,133 +26016,25 @@ function mergeConfig(config1, config2) {
|
|
|
25384
26016
|
// `hasOwnProperty` is restored as a non-enumerable own slot to preserve
|
|
25385
26017
|
// ergonomics for user code that relies on it.
|
|
25386
26018
|
const config = Object.create(null);
|
|
25387
|
-
Object.defineProperty(config, 'hasOwnProperty',
|
|
25388
|
-
// Null-proto descriptor so a polluted Object.prototype.get cannot turn
|
|
25389
|
-
// this data descriptor into an accessor descriptor on the way in.
|
|
25390
|
-
__proto__: null,
|
|
25391
|
-
value: Object.prototype.hasOwnProperty,
|
|
25392
|
-
enumerable: false,
|
|
25393
|
-
writable: true,
|
|
25394
|
-
configurable: true,
|
|
25395
|
-
});
|
|
25396
|
-
|
|
25397
|
-
function getMergedValue(target, source, prop, caseless) {
|
|
25398
|
-
if (_utils_js__rspack_import_1["default"].isPlainObject(target) && _utils_js__rspack_import_1["default"].isPlainObject(source)) {
|
|
25399
|
-
return _utils_js__rspack_import_1["default"].merge.call({ caseless }, target, source);
|
|
25400
|
-
} else if (_utils_js__rspack_import_1["default"].isPlainObject(source)) {
|
|
25401
|
-
return _utils_js__rspack_import_1["default"].merge({}, source);
|
|
25402
|
-
} else if (_utils_js__rspack_import_1["default"].isArray(source)) {
|
|
25403
|
-
return source.slice();
|
|
25404
|
-
}
|
|
25405
|
-
return source;
|
|
25406
|
-
}
|
|
26019
|
+
Object.defineProperty(config, 'hasOwnProperty', hasOwnPropertyDescriptor);
|
|
25407
26020
|
|
|
25408
|
-
|
|
25409
|
-
if (!_utils_js__rspack_import_1["default"].isUndefined(b)) {
|
|
25410
|
-
return getMergedValue(a, b, prop, caseless);
|
|
25411
|
-
} else if (!_utils_js__rspack_import_1["default"].isUndefined(a)) {
|
|
25412
|
-
return getMergedValue(undefined, a, prop, caseless);
|
|
25413
|
-
}
|
|
25414
|
-
}
|
|
25415
|
-
|
|
25416
|
-
// eslint-disable-next-line consistent-return
|
|
25417
|
-
function valueFromConfig2(a, b) {
|
|
25418
|
-
if (!_utils_js__rspack_import_1["default"].isUndefined(b)) {
|
|
25419
|
-
return getMergedValue(undefined, b);
|
|
25420
|
-
}
|
|
25421
|
-
}
|
|
26021
|
+
const keys = ownEnumerableKeys({ ...config1, ...config2 });
|
|
25422
26022
|
|
|
25423
|
-
|
|
25424
|
-
|
|
25425
|
-
if (
|
|
25426
|
-
return getMergedValue(undefined, b);
|
|
25427
|
-
} else if (!_utils_js__rspack_import_1["default"].isUndefined(a)) {
|
|
25428
|
-
return getMergedValue(undefined, a);
|
|
25429
|
-
}
|
|
25430
|
-
}
|
|
25431
|
-
|
|
25432
|
-
function getMergedTransitionalOption(prop) {
|
|
25433
|
-
const transitional2 = _utils_js__rspack_import_1["default"].hasOwnProp(config2, 'transitional')
|
|
25434
|
-
? config2.transitional
|
|
25435
|
-
: undefined;
|
|
25436
|
-
|
|
25437
|
-
if (!_utils_js__rspack_import_1["default"].isUndefined(transitional2)) {
|
|
25438
|
-
if (_utils_js__rspack_import_1["default"].isPlainObject(transitional2)) {
|
|
25439
|
-
if (_utils_js__rspack_import_1["default"].hasOwnProp(transitional2, prop)) {
|
|
25440
|
-
return transitional2[prop];
|
|
25441
|
-
}
|
|
25442
|
-
} else {
|
|
25443
|
-
return undefined;
|
|
25444
|
-
}
|
|
25445
|
-
}
|
|
25446
|
-
|
|
25447
|
-
const transitional1 = _utils_js__rspack_import_1["default"].hasOwnProp(config1, 'transitional')
|
|
25448
|
-
? config1.transitional
|
|
25449
|
-
: undefined;
|
|
25450
|
-
|
|
25451
|
-
if (_utils_js__rspack_import_1["default"].isPlainObject(transitional1) && _utils_js__rspack_import_1["default"].hasOwnProp(transitional1, prop)) {
|
|
25452
|
-
return transitional1[prop];
|
|
25453
|
-
}
|
|
25454
|
-
|
|
25455
|
-
return undefined;
|
|
25456
|
-
}
|
|
25457
|
-
|
|
25458
|
-
// eslint-disable-next-line consistent-return
|
|
25459
|
-
function mergeDirectKeys(a, b, prop) {
|
|
25460
|
-
if (_utils_js__rspack_import_1["default"].hasOwnProp(config2, prop)) {
|
|
25461
|
-
return getMergedValue(a, b);
|
|
25462
|
-
} else if (_utils_js__rspack_import_1["default"].hasOwnProp(config1, prop)) {
|
|
25463
|
-
return getMergedValue(undefined, a);
|
|
25464
|
-
}
|
|
25465
|
-
}
|
|
25466
|
-
|
|
25467
|
-
const mergeMap = {
|
|
25468
|
-
url: valueFromConfig2,
|
|
25469
|
-
method: valueFromConfig2,
|
|
25470
|
-
data: valueFromConfig2,
|
|
25471
|
-
baseURL: defaultToConfig2,
|
|
25472
|
-
transformRequest: defaultToConfig2,
|
|
25473
|
-
transformResponse: defaultToConfig2,
|
|
25474
|
-
paramsSerializer: defaultToConfig2,
|
|
25475
|
-
timeout: defaultToConfig2,
|
|
25476
|
-
timeoutErrorMessage: defaultToConfig2,
|
|
25477
|
-
withCredentials: defaultToConfig2,
|
|
25478
|
-
withXSRFToken: defaultToConfig2,
|
|
25479
|
-
adapter: defaultToConfig2,
|
|
25480
|
-
responseType: defaultToConfig2,
|
|
25481
|
-
xsrfCookieName: defaultToConfig2,
|
|
25482
|
-
xsrfHeaderName: defaultToConfig2,
|
|
25483
|
-
onUploadProgress: defaultToConfig2,
|
|
25484
|
-
onDownloadProgress: defaultToConfig2,
|
|
25485
|
-
decompress: defaultToConfig2,
|
|
25486
|
-
maxContentLength: defaultToConfig2,
|
|
25487
|
-
maxBodyLength: defaultToConfig2,
|
|
25488
|
-
beforeRedirect: defaultToConfig2,
|
|
25489
|
-
transport: defaultToConfig2,
|
|
25490
|
-
httpAgent: defaultToConfig2,
|
|
25491
|
-
httpsAgent: defaultToConfig2,
|
|
25492
|
-
cancelToken: defaultToConfig2,
|
|
25493
|
-
socketPath: defaultToConfig2,
|
|
25494
|
-
allowedSocketPaths: defaultToConfig2,
|
|
25495
|
-
responseEncoding: defaultToConfig2,
|
|
25496
|
-
validateStatus: mergeDirectKeys,
|
|
25497
|
-
headers: (a, b, prop) =>
|
|
25498
|
-
mergeDeepProperties(headersToObject(a), headersToObject(b), prop, true),
|
|
25499
|
-
};
|
|
25500
|
-
|
|
25501
|
-
_utils_js__rspack_import_1["default"].forEach(ownEnumerableKeys({ ...config1, ...config2 }), function computeConfigValue(prop) {
|
|
25502
|
-
if (prop === '__proto__' || prop === 'constructor' || prop === 'prototype') return;
|
|
26023
|
+
for (let i = 0, len = keys.length; i < len; i++) {
|
|
26024
|
+
const prop = keys[i];
|
|
26025
|
+
if (prop === '__proto__' || prop === 'constructor' || prop === 'prototype') continue;
|
|
25503
26026
|
const merge = _utils_js__rspack_import_1["default"].hasOwnProp(mergeMap, prop) ? mergeMap[prop] : mergeDeepProperties;
|
|
25504
26027
|
const a = _utils_js__rspack_import_1["default"].hasOwnProp(config1, prop) ? config1[prop] : undefined;
|
|
25505
26028
|
const b = _utils_js__rspack_import_1["default"].hasOwnProp(config2, prop) ? config2[prop] : undefined;
|
|
25506
|
-
const configValue =
|
|
26029
|
+
const configValue =
|
|
26030
|
+
merge === mergeDirectKeys ? merge(a, b, prop, config1, config2) : merge(a, b, prop);
|
|
25507
26031
|
(_utils_js__rspack_import_1["default"].isUndefined(configValue) && merge !== mergeDirectKeys) || (config[prop] = configValue);
|
|
25508
|
-
}
|
|
26032
|
+
}
|
|
25509
26033
|
|
|
25510
26034
|
if (
|
|
25511
26035
|
_utils_js__rspack_import_1["default"].hasOwnProp(config2, 'validateStatus') &&
|
|
25512
26036
|
_utils_js__rspack_import_1["default"].isUndefined(config2.validateStatus) &&
|
|
25513
|
-
getMergedTransitionalOption('validateStatusUndefinedResolves') === false
|
|
26037
|
+
getMergedTransitionalOption(config1, config2, 'validateStatusUndefinedResolves') === false
|
|
25514
26038
|
) {
|
|
25515
26039
|
if (_utils_js__rspack_import_1["default"].hasOwnProp(config1, 'validateStatus')) {
|
|
25516
26040
|
config.validateStatus = getMergedValue(undefined, config1.validateStatus);
|
|
@@ -25871,6 +26395,7 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
25871
26395
|
legacyInterceptorReqResOrdering: true,
|
|
25872
26396
|
advertiseZstdAcceptEncoding: false,
|
|
25873
26397
|
validateStatusUndefinedResolves: true,
|
|
26398
|
+
encodeBasicAuthUsername: false,
|
|
25874
26399
|
});
|
|
25875
26400
|
|
|
25876
26401
|
|
|
@@ -25878,7 +26403,7 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
25878
26403
|
"f6"(__unused_rspack___webpack_module__, __webpack_exports__, __webpack_require__) {
|
|
25879
26404
|
"use strict";
|
|
25880
26405
|
__webpack_require__.r(__webpack_exports__);
|
|
25881
|
-
const VERSION = "1.
|
|
26406
|
+
const VERSION = "1.21.1";
|
|
25882
26407
|
__webpack_require__.d(__webpack_exports__, {
|
|
25883
26408
|
}, {
|
|
25884
26409
|
VERSION: VERSION
|
|
@@ -26227,12 +26752,15 @@ const composeSignals = (signals, timeout) => {
|
|
|
26227
26752
|
}, timeout);
|
|
26228
26753
|
|
|
26229
26754
|
const unsubscribe = () => {
|
|
26230
|
-
if (!signals) {
|
|
26755
|
+
if (!signals) {
|
|
26756
|
+
return;
|
|
26757
|
+
}
|
|
26231
26758
|
timer && clearTimeout(timer);
|
|
26232
26759
|
timer = null;
|
|
26233
26760
|
signals.forEach((signal) => {
|
|
26234
|
-
signal
|
|
26235
|
-
|
|
26761
|
+
const unsubscribeSignal = _utils_js__rspack_import_2["default"].getSafeProp(signal, 'unsubscribe');
|
|
26762
|
+
_utils_js__rspack_import_2["default"].isFunction(unsubscribeSignal)
|
|
26763
|
+
? unsubscribeSignal.call(signal, onabort)
|
|
26236
26764
|
: signal.removeEventListener('abort', onabort);
|
|
26237
26765
|
});
|
|
26238
26766
|
signals = null;
|
|
@@ -26270,6 +26798,14 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
26270
26798
|
|
|
26271
26799
|
|
|
26272
26800
|
|
|
26801
|
+
const decodeCookieValue = (value) => {
|
|
26802
|
+
try {
|
|
26803
|
+
return decodeURIComponent(value);
|
|
26804
|
+
} catch (e) {
|
|
26805
|
+
return value;
|
|
26806
|
+
}
|
|
26807
|
+
};
|
|
26808
|
+
|
|
26273
26809
|
/* export default */ __webpack_exports__["default"] = (_platform_index_js__rspack_import_0["default"].hasStandardBrowserEnv
|
|
26274
26810
|
? // Standard browser envs support document.cookie
|
|
26275
26811
|
{
|
|
@@ -26299,26 +26835,39 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
26299
26835
|
|
|
26300
26836
|
read(name) {
|
|
26301
26837
|
if (typeof document === 'undefined') return null;
|
|
26838
|
+
const cookieString = document.cookie;
|
|
26839
|
+
if (!cookieString) return null;
|
|
26302
26840
|
// Match name=value by splitting on the semicolon separator instead of building a
|
|
26303
26841
|
// RegExp from `name` — interpolating an unescaped string into a RegExp would let
|
|
26304
26842
|
// metacharacters (e.g. `.+?` in an attacker-influenced cookie name) cause ReDoS or
|
|
26305
26843
|
// match the wrong cookie. Browsers may serialize cookie pairs as either ";" or
|
|
26306
26844
|
// "; ", so ignore optional whitespace before each cookie name.
|
|
26307
|
-
const cookies =
|
|
26845
|
+
const cookies = cookieString.split(';');
|
|
26308
26846
|
for (let i = 0; i < cookies.length; i++) {
|
|
26309
26847
|
const cookie = cookies[i].replace(/^\s+/, '');
|
|
26310
26848
|
const eq = cookie.indexOf('=');
|
|
26311
26849
|
if (eq !== -1 && cookie.slice(0, eq) === name) {
|
|
26312
|
-
|
|
26313
|
-
return decodeURIComponent(cookie.slice(eq + 1));
|
|
26314
|
-
} catch (e) {
|
|
26315
|
-
return cookie.slice(eq + 1);
|
|
26316
|
-
}
|
|
26850
|
+
return decodeCookieValue(cookie.slice(eq + 1));
|
|
26317
26851
|
}
|
|
26318
26852
|
}
|
|
26319
26853
|
return null;
|
|
26320
26854
|
},
|
|
26321
26855
|
|
|
26856
|
+
async readAsync(name) {
|
|
26857
|
+
try {
|
|
26858
|
+
const store = typeof window !== 'undefined' && window.cookieStore;
|
|
26859
|
+
if (store && _utils_js__rspack_import_1["default"].isFunction(store.get)) {
|
|
26860
|
+
const cookie = await store.get(name);
|
|
26861
|
+
// Both APIs expose stored bytes; preserve Axios's existing URI decoding.
|
|
26862
|
+
return cookie ? decodeCookieValue(cookie.value) : null;
|
|
26863
|
+
}
|
|
26864
|
+
} catch (e) {
|
|
26865
|
+
// Restricted or unavailable storage retains the synchronous fallback.
|
|
26866
|
+
}
|
|
26867
|
+
|
|
26868
|
+
return this.read(name);
|
|
26869
|
+
},
|
|
26870
|
+
|
|
26322
26871
|
remove(name) {
|
|
26323
26872
|
this.write(name, '', Date.now() - 86400000, '/');
|
|
26324
26873
|
},
|
|
@@ -26329,6 +26878,9 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
26329
26878
|
read() {
|
|
26330
26879
|
return null;
|
|
26331
26880
|
},
|
|
26881
|
+
async readAsync() {
|
|
26882
|
+
return null;
|
|
26883
|
+
},
|
|
26332
26884
|
remove() {},
|
|
26333
26885
|
});
|
|
26334
26886
|
|
|
@@ -26341,7 +26893,7 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
26341
26893
|
* Estimate data: URL byte lengths *without* allocating large buffers.
|
|
26342
26894
|
* - Fetch percent-decodes a base64 body before decoding it.
|
|
26343
26895
|
* - Node's Buffer.from(body, 'base64') sizes its backing allocation from the
|
|
26344
|
-
*
|
|
26896
|
+
* percent-decoded body, including ignored characters and content after padding.
|
|
26345
26897
|
* - Non-base64 data is percent-decoded and then encoded as UTF-8.
|
|
26346
26898
|
*/
|
|
26347
26899
|
const isHexDigit = (charCode) =>
|
|
@@ -26389,6 +26941,31 @@ const estimateBase64BufferAllocation = (body) => {
|
|
|
26389
26941
|
return Math.floor(((len - padding) * 3) / 4);
|
|
26390
26942
|
};
|
|
26391
26943
|
|
|
26944
|
+
const estimatePercentDecodedBase64BufferAllocation = (body) => {
|
|
26945
|
+
// Ordinary Base64 needs only its length and trailing padding.
|
|
26946
|
+
if (body.indexOf('%') === -1) {
|
|
26947
|
+
return estimateBase64BufferAllocation(body);
|
|
26948
|
+
}
|
|
26949
|
+
|
|
26950
|
+
let length = 0;
|
|
26951
|
+
let previous = 0;
|
|
26952
|
+
let last = 0;
|
|
26953
|
+
|
|
26954
|
+
for (let i = 0, len = body.length; i < len; i++) {
|
|
26955
|
+
let code = body.charCodeAt(i);
|
|
26956
|
+
if (code === 37 /* '%' */ && isPercentEncodedByte(body, i, len)) {
|
|
26957
|
+
code = hexValue(body.charCodeAt(i + 1)) * 16 + hexValue(body.charCodeAt(i + 2));
|
|
26958
|
+
i += 2;
|
|
26959
|
+
}
|
|
26960
|
+
length++;
|
|
26961
|
+
previous = last;
|
|
26962
|
+
last = code;
|
|
26963
|
+
}
|
|
26964
|
+
|
|
26965
|
+
const padding = last === 61 ? (previous === 61 ? 2 : 1) : 0;
|
|
26966
|
+
return Math.floor(((length - padding) * 3) / 4);
|
|
26967
|
+
};
|
|
26968
|
+
|
|
26392
26969
|
const estimatePercentDecodedBase64Bytes = (body) => {
|
|
26393
26970
|
const len = body.length;
|
|
26394
26971
|
let significant = 0;
|
|
@@ -26434,16 +27011,16 @@ const estimatePercentDecodedBase64Bytes = (body) => {
|
|
|
26434
27011
|
return base64Bytes(significant);
|
|
26435
27012
|
};
|
|
26436
27013
|
|
|
26437
|
-
const estimateDataURLBytes = (url, estimateBase64) => {
|
|
27014
|
+
const estimateDataURLBytes = (url, estimateBase64, base64Pattern) => {
|
|
26438
27015
|
if (!url || typeof url !== 'string') return 0;
|
|
26439
|
-
if (
|
|
27016
|
+
if (!/^data:/i.test(url)) return 0;
|
|
26440
27017
|
|
|
26441
27018
|
const comma = url.indexOf(',');
|
|
26442
27019
|
if (comma < 0) return 0;
|
|
26443
27020
|
|
|
26444
27021
|
const meta = url.slice(5, comma);
|
|
26445
27022
|
const body = url.slice(comma + 1);
|
|
26446
|
-
const isBase64 =
|
|
27023
|
+
const isBase64 = base64Pattern.test(meta);
|
|
26447
27024
|
|
|
26448
27025
|
if (isBase64) {
|
|
26449
27026
|
return estimateBase64(body);
|
|
@@ -26490,18 +27067,20 @@ function estimateDataURLDecodedBytes(url) {
|
|
|
26490
27067
|
|
|
26491
27068
|
return estimateDataURLBytes(
|
|
26492
27069
|
fragmentIndex === -1 ? url : url.slice(0, fragmentIndex),
|
|
26493
|
-
estimatePercentDecodedBase64Bytes
|
|
27070
|
+
estimatePercentDecodedBase64Bytes,
|
|
27071
|
+
/; *base64[\t\n\f\r ]*$/i
|
|
26494
27072
|
);
|
|
26495
27073
|
}
|
|
26496
27074
|
|
|
26497
27075
|
/**
|
|
26498
|
-
* Estimate the Buffer backing allocation used
|
|
27076
|
+
* Estimate the Buffer backing allocation used after Node's percent-decoding step.
|
|
26499
27077
|
*
|
|
26500
27078
|
* @param {string} url
|
|
26501
27079
|
* @returns {number}
|
|
26502
27080
|
*/
|
|
26503
27081
|
function estimateDataURLBufferAllocation(url) {
|
|
26504
|
-
|
|
27082
|
+
// Match fromDataURI's case-insensitive protocol and encoding suffix.
|
|
27083
|
+
return estimateDataURLBytes(url, estimatePercentDecodedBase64BufferAllocation, /;base64$/i);
|
|
26505
27084
|
}
|
|
26506
27085
|
|
|
26507
27086
|
__webpack_require__.d(__webpack_exports__, {
|
|
@@ -26510,6 +27089,131 @@ __webpack_require__.d(__webpack_exports__, {
|
|
|
26510
27089
|
});
|
|
26511
27090
|
|
|
26512
27091
|
|
|
27092
|
+
},
|
|
27093
|
+
"D"(__unused_rspack___webpack_module__, __webpack_exports__, __webpack_require__) {
|
|
27094
|
+
"use strict";
|
|
27095
|
+
__webpack_require__.r(__webpack_exports__);
|
|
27096
|
+
/* import */ var _utils_js__rspack_import_0 = __webpack_require__("Kv");
|
|
27097
|
+
|
|
27098
|
+
|
|
27099
|
+
const CRLF = '\r\n';
|
|
27100
|
+
const normalizeLines = (value) => String(value).replace(/\r\n|\r|\n/g, CRLF);
|
|
27101
|
+
const escapeName = (value) =>
|
|
27102
|
+
String(value).replace(/[\r\n"]/g, (char) =>
|
|
27103
|
+
char === '\r' ? '%0D' : char === '\n' ? '%0A' : '%22'
|
|
27104
|
+
);
|
|
27105
|
+
|
|
27106
|
+
// Count UTF-8 bytes without allocating an encoded copy of a field. FormData
|
|
27107
|
+
// string values normalize line endings; Blob/File contents remain unchanged.
|
|
27108
|
+
const stringBytes = (value, normalize) => {
|
|
27109
|
+
let length = 0;
|
|
27110
|
+
for (let i = 0; i < value.length; i++) {
|
|
27111
|
+
const code = value.charCodeAt(i);
|
|
27112
|
+
if (normalize && (code === 13 || code === 10)) {
|
|
27113
|
+
if (code === 13 && value.charCodeAt(i + 1) === 10) i++;
|
|
27114
|
+
length += 2;
|
|
27115
|
+
} else if (code < 0x80) {
|
|
27116
|
+
length++;
|
|
27117
|
+
} else if (code < 0x800) {
|
|
27118
|
+
length += 2;
|
|
27119
|
+
} else if (
|
|
27120
|
+
code >= 0xd800 &&
|
|
27121
|
+
code <= 0xdbff &&
|
|
27122
|
+
value.charCodeAt(i + 1) >= 0xdc00 &&
|
|
27123
|
+
value.charCodeAt(i + 1) <= 0xdfff
|
|
27124
|
+
) {
|
|
27125
|
+
length += 4;
|
|
27126
|
+
i++;
|
|
27127
|
+
} else {
|
|
27128
|
+
length += 3;
|
|
27129
|
+
}
|
|
27130
|
+
}
|
|
27131
|
+
return length;
|
|
27132
|
+
};
|
|
27133
|
+
|
|
27134
|
+
// Describe serialization failures independently of any request library.
|
|
27135
|
+
class FormDataError extends TypeError {
|
|
27136
|
+
constructor(message, reason) {
|
|
27137
|
+
super(message);
|
|
27138
|
+
this.name = 'FormDataError';
|
|
27139
|
+
this.reason = reason;
|
|
27140
|
+
}
|
|
27141
|
+
}
|
|
27142
|
+
|
|
27143
|
+
// The caller supplies the boundary, Blob implementation, and limit error.
|
|
27144
|
+
function formDataToBlob(form, Blob, limit, limitError, boundary) {
|
|
27145
|
+
if (!_utils_js__rspack_import_0["default"].isFunction(Blob)) {
|
|
27146
|
+
throw new FormDataError('Blob is not supported', 'blob');
|
|
27147
|
+
}
|
|
27148
|
+
|
|
27149
|
+
if (
|
|
27150
|
+
!_utils_js__rspack_import_0["default"].isString(boundary) ||
|
|
27151
|
+
!/^[A-Za-z0-9'()+_,./:=? -]{1,70}$/.test(boundary) ||
|
|
27152
|
+
/ $/.test(boundary)
|
|
27153
|
+
) {
|
|
27154
|
+
throw new FormDataError('Invalid multipart boundary', 'boundary');
|
|
27155
|
+
}
|
|
27156
|
+
const footer = '--' + boundary + '--' + CRLF;
|
|
27157
|
+
let length = footer.length;
|
|
27158
|
+
const parts = [];
|
|
27159
|
+
const checkLength = (extra) => {
|
|
27160
|
+
if (length + extra > limit) throw limitError();
|
|
27161
|
+
};
|
|
27162
|
+
checkLength(0);
|
|
27163
|
+
|
|
27164
|
+
for (const [name, value] of form) {
|
|
27165
|
+
const isString = _utils_js__rspack_import_0["default"].isString(value);
|
|
27166
|
+
const valueLength = isString ? stringBytes(value, true) : value.size;
|
|
27167
|
+
if (!Number.isFinite(valueLength) || valueLength < 0) {
|
|
27168
|
+
throw new FormDataError('Unsupported FormData part size', 'part');
|
|
27169
|
+
}
|
|
27170
|
+
// Reject large values and names before building normalized header strings.
|
|
27171
|
+
checkLength(
|
|
27172
|
+
valueLength +
|
|
27173
|
+
stringBytes(name, true) +
|
|
27174
|
+
(!isString && value.name ? stringBytes(value.name, false) : 0) +
|
|
27175
|
+
(!isString && value.type ? stringBytes(value.type, false) : 0)
|
|
27176
|
+
);
|
|
27177
|
+
|
|
27178
|
+
let header =
|
|
27179
|
+
'--' +
|
|
27180
|
+
boundary +
|
|
27181
|
+
CRLF +
|
|
27182
|
+
'Content-Disposition: form-data; name="' +
|
|
27183
|
+
escapeName(normalizeLines(name)) +
|
|
27184
|
+
'"';
|
|
27185
|
+
if (!isString) {
|
|
27186
|
+
header +=
|
|
27187
|
+
'; filename="' +
|
|
27188
|
+
escapeName(_utils_js__rspack_import_0["default"].isString(value.name) ? value.name : 'blob') +
|
|
27189
|
+
'"' +
|
|
27190
|
+
CRLF +
|
|
27191
|
+
'Content-Type: ' +
|
|
27192
|
+
String(value.type || 'application/octet-stream').replace(/[\r\n]/g, '');
|
|
27193
|
+
}
|
|
27194
|
+
header += CRLF + CRLF;
|
|
27195
|
+
const partLength = stringBytes(header, false) + valueLength + CRLF.length;
|
|
27196
|
+
checkLength(partLength);
|
|
27197
|
+
length += partLength;
|
|
27198
|
+
parts.push({ header, value, isString });
|
|
27199
|
+
}
|
|
27200
|
+
|
|
27201
|
+
// Native Blob composition retains existing Blob/File data. No file is read
|
|
27202
|
+
// and no complete multipart ArrayBuffer is created to determine its length.
|
|
27203
|
+
const blobParts = [];
|
|
27204
|
+
for (const part of parts) {
|
|
27205
|
+
blobParts.push(part.header, part.isString ? normalizeLines(part.value) : part.value, CRLF);
|
|
27206
|
+
}
|
|
27207
|
+
blobParts.push(footer);
|
|
27208
|
+
return new Blob(blobParts, { type: 'multipart/form-data; boundary=' + boundary });
|
|
27209
|
+
}
|
|
27210
|
+
|
|
27211
|
+
__webpack_require__.d(__webpack_exports__, {
|
|
27212
|
+
FormDataError: () => (FormDataError),
|
|
27213
|
+
"default": () => (formDataToBlob)
|
|
27214
|
+
});
|
|
27215
|
+
|
|
27216
|
+
|
|
26513
27217
|
},
|
|
26514
27218
|
"Cj"(__unused_rspack___webpack_module__, __webpack_exports__, __webpack_require__) {
|
|
26515
27219
|
"use strict";
|
|
@@ -26584,6 +27288,29 @@ function arrayToObject(arr) {
|
|
|
26584
27288
|
return obj;
|
|
26585
27289
|
}
|
|
26586
27290
|
|
|
27291
|
+
function normalizeArray(value) {
|
|
27292
|
+
if (!_utils_js__rspack_import_2["default"].isArray(value)) return value;
|
|
27293
|
+
|
|
27294
|
+
const keys = Object.keys(value);
|
|
27295
|
+
return keys.length !== value.length || keys.some((key, index) => key !== String(index))
|
|
27296
|
+
? arrayToObject(value)
|
|
27297
|
+
: value;
|
|
27298
|
+
}
|
|
27299
|
+
|
|
27300
|
+
function normalizeArrays(obj) {
|
|
27301
|
+
const pending = [obj];
|
|
27302
|
+
while (pending.length) {
|
|
27303
|
+
const target = pending.pop();
|
|
27304
|
+
Object.keys(target).forEach((key) => {
|
|
27305
|
+
const value = (target[key] = normalizeArray(target[key]));
|
|
27306
|
+
if (_utils_js__rspack_import_2["default"].isArray(value) || _utils_js__rspack_import_2["default"].isPlainObject(value)) {
|
|
27307
|
+
pending.push(value);
|
|
27308
|
+
}
|
|
27309
|
+
});
|
|
27310
|
+
}
|
|
27311
|
+
return obj;
|
|
27312
|
+
}
|
|
27313
|
+
|
|
26587
27314
|
/**
|
|
26588
27315
|
* It takes a FormData object and returns a JavaScript object
|
|
26589
27316
|
*
|
|
@@ -26605,6 +27332,7 @@ function formDataToJSON(formData) {
|
|
|
26605
27332
|
|
|
26606
27333
|
if (isLast) {
|
|
26607
27334
|
if (_utils_js__rspack_import_2["default"].hasOwnProp(target, name)) {
|
|
27335
|
+
target[name] = normalizeArray(target[name]);
|
|
26608
27336
|
target[name] = _utils_js__rspack_import_2["default"].isArray(target[name])
|
|
26609
27337
|
? target[name].concat(value)
|
|
26610
27338
|
: [target[name], value];
|
|
@@ -26635,7 +27363,7 @@ function formDataToJSON(formData) {
|
|
|
26635
27363
|
buildPath(parsePropPath(name), value, obj, 0);
|
|
26636
27364
|
});
|
|
26637
27365
|
|
|
26638
|
-
return obj;
|
|
27366
|
+
return normalizeArrays(obj);
|
|
26639
27367
|
}
|
|
26640
27368
|
|
|
26641
27369
|
return null;
|
|
@@ -26706,18 +27434,13 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
26706
27434
|
|
|
26707
27435
|
|
|
26708
27436
|
/* export default */ __webpack_exports__["default"] = (_platform_index_js__rspack_import_0["default"].hasStandardBrowserEnv
|
|
26709
|
-
? ((origin
|
|
26710
|
-
url = new URL(url, _platform_index_js__rspack_import_0["default"].origin);
|
|
27437
|
+
? ((origin) => (url) => {
|
|
27438
|
+
url = new URL(url, document.baseURI || _platform_index_js__rspack_import_0["default"].origin);
|
|
26711
27439
|
|
|
26712
27440
|
return (
|
|
26713
|
-
origin.protocol === url.protocol &&
|
|
26714
|
-
origin.host === url.host &&
|
|
26715
|
-
(isMSIE || origin.port === url.port)
|
|
27441
|
+
origin.protocol === url.protocol && origin.host === url.host && origin.port === url.port
|
|
26716
27442
|
);
|
|
26717
|
-
})(
|
|
26718
|
-
new URL(_platform_index_js__rspack_import_0["default"].origin),
|
|
26719
|
-
_platform_index_js__rspack_import_0["default"].navigator && /(msie|trident)/i.test(_platform_index_js__rspack_import_0["default"].navigator.userAgent)
|
|
26720
|
-
)
|
|
27443
|
+
})(new URL(_platform_index_js__rspack_import_0["default"].origin))
|
|
26721
27444
|
: () => true);
|
|
26722
27445
|
|
|
26723
27446
|
|
|
@@ -26809,7 +27532,8 @@ const ignoreDuplicateOf = _utils_js__rspack_import_0["default"].toObjectSet([
|
|
|
26809
27532
|
* @returns {Object} Headers parsed into an object
|
|
26810
27533
|
*/
|
|
26811
27534
|
/* export default */ __webpack_exports__["default"] = ((rawHeaders) => {
|
|
26812
|
-
|
|
27535
|
+
// Header names are data, including __proto__; avoid inherited setters.
|
|
27536
|
+
const parsed = Object.create(null);
|
|
26813
27537
|
let key;
|
|
26814
27538
|
let val;
|
|
26815
27539
|
let i;
|
|
@@ -26849,7 +27573,7 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
26849
27573
|
|
|
26850
27574
|
function parseProtocol(url) {
|
|
26851
27575
|
const match = /^([-+\w]{1,25}):(?:\/\/)?/.exec(url);
|
|
26852
|
-
return (match && match[1]) || '';
|
|
27576
|
+
return (match && match[1].toLowerCase()) || '';
|
|
26853
27577
|
}
|
|
26854
27578
|
|
|
26855
27579
|
__webpack_require__.d(__webpack_exports__, {
|
|
@@ -26931,16 +27655,16 @@ __webpack_require__.d(__webpack_exports__, {
|
|
|
26931
27655
|
"t"(__unused_rspack___webpack_module__, __webpack_exports__, __webpack_require__) {
|
|
26932
27656
|
"use strict";
|
|
26933
27657
|
__webpack_require__.r(__webpack_exports__);
|
|
26934
|
-
/* import */ var
|
|
26935
|
-
/* import */ var
|
|
26936
|
-
/* import */ var
|
|
26937
|
-
/* import */ var
|
|
26938
|
-
/* import */ var
|
|
26939
|
-
/* import */ var
|
|
26940
|
-
/* import */ var
|
|
26941
|
-
/* import */ var
|
|
26942
|
-
/* import */ var
|
|
26943
|
-
/* import */ var
|
|
27658
|
+
/* import */ var _platform_index_js__rspack_import_7 = __webpack_require__("nF");
|
|
27659
|
+
/* import */ var _utils_js__rspack_import_2 = __webpack_require__("Kv");
|
|
27660
|
+
/* import */ var _core_AxiosError_js__rspack_import_6 = __webpack_require__("f");
|
|
27661
|
+
/* import */ var _isURLSameOrigin_js__rspack_import_9 = __webpack_require__("uS");
|
|
27662
|
+
/* import */ var _cookies_js__rspack_import_0 = __webpack_require__("jD");
|
|
27663
|
+
/* import */ var _core_buildFullPath_js__rspack_import_5 = __webpack_require__("zE");
|
|
27664
|
+
/* import */ var _core_mergeConfig_js__rspack_import_1 = __webpack_require__("yf");
|
|
27665
|
+
/* import */ var _core_AxiosHeaders_js__rspack_import_3 = __webpack_require__("Z");
|
|
27666
|
+
/* import */ var _core_setFormDataHeaders_js__rspack_import_8 = __webpack_require__("p8");
|
|
27667
|
+
/* import */ var _buildURL_js__rspack_import_4 = __webpack_require__("Tw");
|
|
26944
27668
|
|
|
26945
27669
|
|
|
26946
27670
|
|
|
@@ -26965,12 +27689,14 @@ const encodeUTF8 = (str) =>
|
|
|
26965
27689
|
String.fromCharCode(parseInt(hex, 16))
|
|
26966
27690
|
);
|
|
26967
27691
|
|
|
26968
|
-
|
|
26969
|
-
|
|
27692
|
+
const readCookie = (name) => _cookies_js__rspack_import_0["default"].read(name);
|
|
27693
|
+
|
|
27694
|
+
function resolveConfig(config, readXsrfCookie = readCookie) {
|
|
27695
|
+
const newConfig = (0,_core_mergeConfig_js__rspack_import_1["default"])({}, config);
|
|
26970
27696
|
|
|
26971
27697
|
// Read only own properties to prevent prototype pollution gadgets
|
|
26972
27698
|
// (e.g. Object.prototype.baseURL = 'https://evil.com').
|
|
26973
|
-
const own = (key) => (
|
|
27699
|
+
const own = (key) => (_utils_js__rspack_import_2["default"].hasOwnProp(newConfig, key) ? newConfig[key] : undefined);
|
|
26974
27700
|
|
|
26975
27701
|
const data = own('data');
|
|
26976
27702
|
let withXSRFToken = own('withXSRFToken');
|
|
@@ -26982,41 +27708,52 @@ function resolveConfig(config) {
|
|
|
26982
27708
|
const allowAbsoluteUrls = own('allowAbsoluteUrls');
|
|
26983
27709
|
const url = own('url');
|
|
26984
27710
|
|
|
26985
|
-
newConfig.headers = headers =
|
|
27711
|
+
newConfig.headers = headers = _core_AxiosHeaders_js__rspack_import_3["default"].from(headers);
|
|
26986
27712
|
|
|
26987
|
-
newConfig.url = (0,
|
|
26988
|
-
(0,
|
|
27713
|
+
newConfig.url = (0,_buildURL_js__rspack_import_4["default"])(
|
|
27714
|
+
(0,_core_buildFullPath_js__rspack_import_5["default"])(baseURL, url, allowAbsoluteUrls, newConfig),
|
|
26989
27715
|
own('params'),
|
|
26990
27716
|
own('paramsSerializer')
|
|
26991
27717
|
);
|
|
26992
27718
|
|
|
26993
27719
|
// HTTP basic authentication
|
|
26994
27720
|
if (auth) {
|
|
26995
|
-
const username =
|
|
26996
|
-
const password =
|
|
27721
|
+
const username = _utils_js__rspack_import_2["default"].getSafeProp(auth, 'username') || '';
|
|
27722
|
+
const password = _utils_js__rspack_import_2["default"].getSafeProp(auth, 'password') || '';
|
|
27723
|
+
const transitional = own('transitional');
|
|
27724
|
+
const encodeUsername =
|
|
27725
|
+
transitional &&
|
|
27726
|
+
_utils_js__rspack_import_2["default"].hasOwnProp(transitional, 'encodeBasicAuthUsername') &&
|
|
27727
|
+
transitional.encodeBasicAuthUsername === true;
|
|
26997
27728
|
|
|
26998
27729
|
try {
|
|
26999
27730
|
headers.set(
|
|
27000
27731
|
'Authorization',
|
|
27001
|
-
|
|
27732
|
+
// Preserve legacy username bytes unless the caller opts in to UTF-8.
|
|
27733
|
+
'Basic ' +
|
|
27734
|
+
btoa(
|
|
27735
|
+
(encodeUsername ? encodeUTF8(username) : username) +
|
|
27736
|
+
':' +
|
|
27737
|
+
(password ? encodeUTF8(password) : '')
|
|
27738
|
+
)
|
|
27002
27739
|
);
|
|
27003
27740
|
} catch (e) {
|
|
27004
|
-
throw
|
|
27741
|
+
throw _core_AxiosError_js__rspack_import_6["default"].from(e, _core_AxiosError_js__rspack_import_6["default"].ERR_BAD_OPTION_VALUE, config);
|
|
27005
27742
|
}
|
|
27006
27743
|
}
|
|
27007
27744
|
|
|
27008
|
-
if (
|
|
27009
|
-
const getHeaders =
|
|
27745
|
+
if (_utils_js__rspack_import_2["default"].isFormData(data)) {
|
|
27746
|
+
const getHeaders = _utils_js__rspack_import_2["default"].getSafeProp(data, 'getHeaders');
|
|
27010
27747
|
|
|
27011
27748
|
if (
|
|
27012
|
-
|
|
27013
|
-
|
|
27014
|
-
|
|
27749
|
+
_platform_index_js__rspack_import_7["default"].hasStandardBrowserEnv ||
|
|
27750
|
+
_platform_index_js__rspack_import_7["default"].hasStandardBrowserWebWorkerEnv ||
|
|
27751
|
+
_utils_js__rspack_import_2["default"].isReactNative(data)
|
|
27015
27752
|
) {
|
|
27016
27753
|
headers.setContentType(undefined); // browser/web worker/RN handles it
|
|
27017
|
-
} else if (
|
|
27754
|
+
} else if (_utils_js__rspack_import_2["default"].isFunction(getHeaders)) {
|
|
27018
27755
|
// Node.js FormData (like form-data package)
|
|
27019
|
-
(0,
|
|
27756
|
+
(0,_core_setFormDataHeaders_js__rspack_import_8["default"])(headers, getHeaders.call(data), own('formDataHeaderPolicy'));
|
|
27020
27757
|
}
|
|
27021
27758
|
}
|
|
27022
27759
|
|
|
@@ -27024,8 +27761,8 @@ function resolveConfig(config) {
|
|
|
27024
27761
|
// This is only done if running in a standard browser environment.
|
|
27025
27762
|
// Specifically not if we're in a web worker, or react-native.
|
|
27026
27763
|
|
|
27027
|
-
if (
|
|
27028
|
-
if (
|
|
27764
|
+
if (_platform_index_js__rspack_import_7["default"].hasStandardBrowserEnv) {
|
|
27765
|
+
if (_utils_js__rspack_import_2["default"].isFunction(withXSRFToken)) {
|
|
27029
27766
|
withXSRFToken = withXSRFToken(newConfig);
|
|
27030
27767
|
}
|
|
27031
27768
|
|
|
@@ -27033,10 +27770,10 @@ function resolveConfig(config) {
|
|
|
27033
27770
|
// and misconfigurations (e.g. "false") from short-circuiting the same-origin check and leaking
|
|
27034
27771
|
// the XSRF token cross-origin.
|
|
27035
27772
|
const shouldSendXSRF =
|
|
27036
|
-
withXSRFToken === true || (withXSRFToken == null && (0,
|
|
27773
|
+
withXSRFToken === true || (withXSRFToken == null && (0,_isURLSameOrigin_js__rspack_import_9["default"])(newConfig.url));
|
|
27037
27774
|
|
|
27038
27775
|
if (shouldSendXSRF) {
|
|
27039
|
-
const xsrfValue = xsrfHeaderName && xsrfCookieName &&
|
|
27776
|
+
const xsrfValue = xsrfHeaderName && xsrfCookieName && readXsrfCookie(xsrfCookieName);
|
|
27040
27777
|
|
|
27041
27778
|
if (xsrfValue) {
|
|
27042
27779
|
headers.set(xsrfHeaderName, xsrfValue);
|
|
@@ -28269,11 +29006,17 @@ const isPlainObject = (val) => {
|
|
|
28269
29006
|
const prototype = getPrototypeOf(val);
|
|
28270
29007
|
return (
|
|
28271
29008
|
(prototype === null || prototype === Object.prototype || getPrototypeOf(prototype) === null) &&
|
|
28272
|
-
// Treat
|
|
28273
|
-
//
|
|
28274
|
-
//
|
|
28275
|
-
|
|
28276
|
-
|
|
29009
|
+
// Treat own Symbol.toStringTag or Symbol.iterator members as evidence the
|
|
29010
|
+
// value is tagged/iterable, ignoring members reachable only through shared
|
|
29011
|
+
// or terminal prototype boundaries. This is exactly what
|
|
29012
|
+
// hasOwnInPrototypeChain(val, prop) computes here: every prototype admitted
|
|
29013
|
+
// above (null, Object.prototype, or a terminal null-prototype template) is
|
|
29014
|
+
// a boundary, so the walk never inspects anything but `val`'s own members,
|
|
29015
|
+
// and stops before even those when `val` is itself the boundary
|
|
29016
|
+
// Object.prototype. Checking that inline avoids allocating the walker's
|
|
29017
|
+
// `seen` list twice per call on the mergeConfig / merge hot path.
|
|
29018
|
+
(isPrototypeBoundary(val, prototype, true) ||
|
|
29019
|
+
(!hasOwnProperty(val, toStringTag) && !hasOwnProperty(val, iterator)))
|
|
28277
29020
|
);
|
|
28278
29021
|
};
|
|
28279
29022
|
|
|
@@ -28537,15 +29280,30 @@ const isContextDefined = (context) => !isUndefined(context) && context !== _glob
|
|
|
28537
29280
|
function merge(...objs) {
|
|
28538
29281
|
const { caseless, skipUndefined } = (isContextDefined(this) && this) || {};
|
|
28539
29282
|
const result = {};
|
|
29283
|
+
// Caseless lookup only applies to string keys — symbol keys are
|
|
29284
|
+
// identity-matched. Every string key that reaches `result` passes through
|
|
29285
|
+
// this index first, so it can never hold two case variants of one key and a
|
|
29286
|
+
// lowercase -> key map is exactly what findKey(result, key) would rescan
|
|
29287
|
+
// Object.keys(result) for on each assignment.
|
|
29288
|
+
const lowerCaseKeys = caseless ? Object.create(null) : null;
|
|
28540
29289
|
const assignValue = (val, key) => {
|
|
28541
29290
|
// Skip dangerous property names to prevent prototype pollution
|
|
28542
29291
|
if (key === '__proto__' || key === 'constructor' || key === 'prototype') {
|
|
28543
29292
|
return;
|
|
28544
29293
|
}
|
|
28545
29294
|
|
|
28546
|
-
|
|
28547
|
-
|
|
28548
|
-
|
|
29295
|
+
let targetKey = key;
|
|
29296
|
+
if (lowerCaseKeys && typeof key === 'string') {
|
|
29297
|
+
const lowerKey = key.toLowerCase();
|
|
29298
|
+
const knownKey = lowerCaseKeys[lowerKey];
|
|
29299
|
+
// A key recorded but absent from `result` was skipped by skipUndefined;
|
|
29300
|
+
// the later spelling wins then, as it does for findKey.
|
|
29301
|
+
if (knownKey !== undefined && hasOwnProperty(result, knownKey)) {
|
|
29302
|
+
targetKey = knownKey;
|
|
29303
|
+
} else {
|
|
29304
|
+
lowerCaseKeys[lowerKey] = key;
|
|
29305
|
+
}
|
|
29306
|
+
}
|
|
28549
29307
|
// Read via own-prop only — a bare `result[targetKey]` walks the prototype
|
|
28550
29308
|
// chain, so a polluted Object.prototype value could surface here and get
|
|
28551
29309
|
// copied into the merged result.
|
|
@@ -28569,7 +29327,7 @@ function merge(...objs) {
|
|
|
28569
29327
|
|
|
28570
29328
|
forEach(source, assignValue);
|
|
28571
29329
|
|
|
28572
|
-
if (typeof source !== 'object' || isArray(source)) {
|
|
29330
|
+
if (typeof source !== 'object' || isArray(source) || !Object.getOwnPropertySymbols) {
|
|
28573
29331
|
continue;
|
|
28574
29332
|
}
|
|
28575
29333
|
|
|
@@ -28728,7 +29486,37 @@ const toArray = (thing) => {
|
|
|
28728
29486
|
if (!thing) return null;
|
|
28729
29487
|
if (isArray(thing)) return thing;
|
|
28730
29488
|
let i = thing.length;
|
|
28731
|
-
if (!
|
|
29489
|
+
if (!Number.isSafeInteger(i) || i < 0 || i > 0xffffffff) return null;
|
|
29490
|
+
|
|
29491
|
+
// Bound the copy by actual indexed properties, including hidden and inherited
|
|
29492
|
+
// members of array-like collections, rather than by the declared length alone.
|
|
29493
|
+
const indexes = new Set();
|
|
29494
|
+
const seen = new Set();
|
|
29495
|
+
let source = thing;
|
|
29496
|
+
|
|
29497
|
+
while (source != null && indexes.size < i) {
|
|
29498
|
+
if (seen.has(source)) return null;
|
|
29499
|
+
seen.add(source);
|
|
29500
|
+
|
|
29501
|
+
const prototype = getPrototypeOf(source);
|
|
29502
|
+
if (isPrototypeBoundary(source, prototype, source === thing)) break;
|
|
29503
|
+
|
|
29504
|
+
Object.getOwnPropertyNames(source).forEach((key) => {
|
|
29505
|
+
const index = +key;
|
|
29506
|
+
if (
|
|
29507
|
+
Number.isInteger(index) &&
|
|
29508
|
+
index >= 0 &&
|
|
29509
|
+
index < i &&
|
|
29510
|
+
String(index) === key &&
|
|
29511
|
+
hasOwnProperty(source, key)
|
|
29512
|
+
) {
|
|
29513
|
+
indexes.add(index);
|
|
29514
|
+
}
|
|
29515
|
+
});
|
|
29516
|
+
source = prototype;
|
|
29517
|
+
}
|
|
29518
|
+
|
|
29519
|
+
if (indexes.size !== i) return null;
|
|
28732
29520
|
const arr = new Array(i);
|
|
28733
29521
|
while (i-- > 0) {
|
|
28734
29522
|
arr[i] = thing[i];
|