Update npm packages (73 packages including @jqhtml 2.3.36)
Update npm registry domain from privatenpm.hanson.xyz to npm.internal.hanson.xyz 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
15
node_modules/axios/lib/core/Axios.js
generated
vendored
15
node_modules/axios/lib/core/Axios.js
generated
vendored
@@ -1,6 +1,6 @@
|
||||
'use strict';
|
||||
|
||||
import utils from './../utils.js';
|
||||
import utils from '../utils.js';
|
||||
import buildURL from '../helpers/buildURL.js';
|
||||
import InterceptorManager from './InterceptorManager.js';
|
||||
import dispatchRequest from './dispatchRequest.js';
|
||||
@@ -8,6 +8,7 @@ import mergeConfig from './mergeConfig.js';
|
||||
import buildFullPath from './buildFullPath.js';
|
||||
import validator from '../helpers/validator.js';
|
||||
import AxiosHeaders from './AxiosHeaders.js';
|
||||
import transitionalDefaults from '../defaults/transitional.js';
|
||||
|
||||
const validators = validator.validators;
|
||||
|
||||
@@ -80,7 +81,8 @@ class Axios {
|
||||
validator.assertOptions(transitional, {
|
||||
silentJSONParsing: validators.transitional(validators.boolean),
|
||||
forcedJSONParsing: validators.transitional(validators.boolean),
|
||||
clarifyTimeoutError: validators.transitional(validators.boolean)
|
||||
clarifyTimeoutError: validators.transitional(validators.boolean),
|
||||
legacyInterceptorReqResOrdering: validators.transitional(validators.boolean)
|
||||
}, false);
|
||||
}
|
||||
|
||||
@@ -139,7 +141,14 @@ class Axios {
|
||||
|
||||
synchronousRequestInterceptors = synchronousRequestInterceptors && interceptor.synchronous;
|
||||
|
||||
requestInterceptorChain.unshift(interceptor.fulfilled, interceptor.rejected);
|
||||
const transitional = config.transitional || transitionalDefaults;
|
||||
const legacyInterceptorReqResOrdering = transitional && transitional.legacyInterceptorReqResOrdering;
|
||||
|
||||
if (legacyInterceptorReqResOrdering) {
|
||||
requestInterceptorChain.unshift(interceptor.fulfilled, interceptor.rejected);
|
||||
} else {
|
||||
requestInterceptorChain.push(interceptor.fulfilled, interceptor.rejected);
|
||||
}
|
||||
});
|
||||
|
||||
const responseInterceptorChain = [];
|
||||
|
||||
163
node_modules/axios/lib/core/AxiosError.js
generated
vendored
163
node_modules/axios/lib/core/AxiosError.js
generated
vendored
@@ -2,109 +2,72 @@
|
||||
|
||||
import utils from '../utils.js';
|
||||
|
||||
/**
|
||||
* Create an Error with the specified message, config, error code, request and response.
|
||||
*
|
||||
* @param {string} message The error message.
|
||||
* @param {string} [code] The error code (for example, 'ECONNABORTED').
|
||||
* @param {Object} [config] The config.
|
||||
* @param {Object} [request] The request.
|
||||
* @param {Object} [response] The response.
|
||||
*
|
||||
* @returns {Error} The created error.
|
||||
*/
|
||||
function AxiosError(message, code, config, request, response) {
|
||||
Error.call(this);
|
||||
class AxiosError extends Error {
|
||||
static from(error, code, config, request, response, customProps) {
|
||||
const axiosError = new AxiosError(error.message, code || error.code, config, request, response);
|
||||
axiosError.cause = error;
|
||||
axiosError.name = error.name;
|
||||
customProps && Object.assign(axiosError, customProps);
|
||||
return axiosError;
|
||||
}
|
||||
|
||||
if (Error.captureStackTrace) {
|
||||
Error.captureStackTrace(this, this.constructor);
|
||||
} else {
|
||||
this.stack = (new Error()).stack;
|
||||
}
|
||||
/**
|
||||
* Create an Error with the specified message, config, error code, request and response.
|
||||
*
|
||||
* @param {string} message The error message.
|
||||
* @param {string} [code] The error code (for example, 'ECONNABORTED').
|
||||
* @param {Object} [config] The config.
|
||||
* @param {Object} [request] The request.
|
||||
* @param {Object} [response] The response.
|
||||
*
|
||||
* @returns {Error} The created error.
|
||||
*/
|
||||
constructor(message, code, config, request, response) {
|
||||
super(message);
|
||||
this.name = 'AxiosError';
|
||||
this.isAxiosError = true;
|
||||
code && (this.code = code);
|
||||
config && (this.config = config);
|
||||
request && (this.request = request);
|
||||
if (response) {
|
||||
this.response = response;
|
||||
this.status = response.status;
|
||||
}
|
||||
}
|
||||
|
||||
this.message = message;
|
||||
this.name = 'AxiosError';
|
||||
code && (this.code = code);
|
||||
config && (this.config = config);
|
||||
request && (this.request = request);
|
||||
if (response) {
|
||||
this.response = response;
|
||||
this.status = response.status ? response.status : null;
|
||||
}
|
||||
toJSON() {
|
||||
return {
|
||||
// Standard
|
||||
message: this.message,
|
||||
name: this.name,
|
||||
// Microsoft
|
||||
description: this.description,
|
||||
number: this.number,
|
||||
// Mozilla
|
||||
fileName: this.fileName,
|
||||
lineNumber: this.lineNumber,
|
||||
columnNumber: this.columnNumber,
|
||||
stack: this.stack,
|
||||
// Axios
|
||||
config: utils.toJSONObject(this.config),
|
||||
code: this.code,
|
||||
status: this.status,
|
||||
};
|
||||
}
|
||||
}
|
||||
|
||||
utils.inherits(AxiosError, Error, {
|
||||
toJSON: function toJSON() {
|
||||
return {
|
||||
// Standard
|
||||
message: this.message,
|
||||
name: this.name,
|
||||
// Microsoft
|
||||
description: this.description,
|
||||
number: this.number,
|
||||
// Mozilla
|
||||
fileName: this.fileName,
|
||||
lineNumber: this.lineNumber,
|
||||
columnNumber: this.columnNumber,
|
||||
stack: this.stack,
|
||||
// Axios
|
||||
config: utils.toJSONObject(this.config),
|
||||
code: this.code,
|
||||
status: this.status
|
||||
};
|
||||
}
|
||||
});
|
||||
|
||||
const prototype = AxiosError.prototype;
|
||||
const descriptors = {};
|
||||
|
||||
[
|
||||
'ERR_BAD_OPTION_VALUE',
|
||||
'ERR_BAD_OPTION',
|
||||
'ECONNABORTED',
|
||||
'ETIMEDOUT',
|
||||
'ERR_NETWORK',
|
||||
'ERR_FR_TOO_MANY_REDIRECTS',
|
||||
'ERR_DEPRECATED',
|
||||
'ERR_BAD_RESPONSE',
|
||||
'ERR_BAD_REQUEST',
|
||||
'ERR_CANCELED',
|
||||
'ERR_NOT_SUPPORT',
|
||||
'ERR_INVALID_URL'
|
||||
// eslint-disable-next-line func-names
|
||||
].forEach(code => {
|
||||
descriptors[code] = {value: code};
|
||||
});
|
||||
|
||||
Object.defineProperties(AxiosError, descriptors);
|
||||
Object.defineProperty(prototype, 'isAxiosError', {value: true});
|
||||
|
||||
// eslint-disable-next-line func-names
|
||||
AxiosError.from = (error, code, config, request, response, customProps) => {
|
||||
const axiosError = Object.create(prototype);
|
||||
|
||||
utils.toFlatObject(error, axiosError, function filter(obj) {
|
||||
return obj !== Error.prototype;
|
||||
}, prop => {
|
||||
return prop !== 'isAxiosError';
|
||||
});
|
||||
|
||||
const msg = error && error.message ? error.message : 'Error';
|
||||
|
||||
// Prefer explicit code; otherwise copy the low-level error's code (e.g. ECONNREFUSED)
|
||||
const errCode = code == null && error ? error.code : code;
|
||||
AxiosError.call(axiosError, msg, errCode, config, request, response);
|
||||
|
||||
// Chain the original error on the standard field; non-enumerable to avoid JSON noise
|
||||
if (error && axiosError.cause == null) {
|
||||
Object.defineProperty(axiosError, 'cause', { value: error, configurable: true });
|
||||
}
|
||||
|
||||
axiosError.name = (error && error.name) || 'Error';
|
||||
|
||||
customProps && Object.assign(axiosError, customProps);
|
||||
|
||||
return axiosError;
|
||||
};
|
||||
// This can be changed to static properties as soon as the parser options in .eslint.cjs are updated.
|
||||
AxiosError.ERR_BAD_OPTION_VALUE = 'ERR_BAD_OPTION_VALUE';
|
||||
AxiosError.ERR_BAD_OPTION = 'ERR_BAD_OPTION';
|
||||
AxiosError.ECONNABORTED = 'ECONNABORTED';
|
||||
AxiosError.ETIMEDOUT = 'ETIMEDOUT';
|
||||
AxiosError.ERR_NETWORK = 'ERR_NETWORK';
|
||||
AxiosError.ERR_FR_TOO_MANY_REDIRECTS = 'ERR_FR_TOO_MANY_REDIRECTS';
|
||||
AxiosError.ERR_DEPRECATED = 'ERR_DEPRECATED';
|
||||
AxiosError.ERR_BAD_RESPONSE = 'ERR_BAD_RESPONSE';
|
||||
AxiosError.ERR_BAD_REQUEST = 'ERR_BAD_REQUEST';
|
||||
AxiosError.ERR_CANCELED = 'ERR_CANCELED';
|
||||
AxiosError.ERR_NOT_SUPPORT = 'ERR_NOT_SUPPORT';
|
||||
AxiosError.ERR_INVALID_URL = 'ERR_INVALID_URL';
|
||||
|
||||
export default AxiosError;
|
||||
|
||||
3
node_modules/axios/lib/core/InterceptorManager.js
generated
vendored
3
node_modules/axios/lib/core/InterceptorManager.js
generated
vendored
@@ -1,6 +1,6 @@
|
||||
'use strict';
|
||||
|
||||
import utils from './../utils.js';
|
||||
import utils from '../utils.js';
|
||||
|
||||
class InterceptorManager {
|
||||
constructor() {
|
||||
@@ -12,6 +12,7 @@ class InterceptorManager {
|
||||
*
|
||||
* @param {Function} fulfilled The function to handle `then` for a `Promise`
|
||||
* @param {Function} rejected The function to handle `reject` for a `Promise`
|
||||
* @param {Object} options The options for the interceptor, synchronous and runWhen
|
||||
*
|
||||
* @return {Number} An ID used to remove interceptor later
|
||||
*/
|
||||
|
||||
35
node_modules/axios/lib/core/mergeConfig.js
generated
vendored
35
node_modules/axios/lib/core/mergeConfig.js
generated
vendored
@@ -1,9 +1,10 @@
|
||||
'use strict';
|
||||
"use strict";
|
||||
|
||||
import utils from '../utils.js';
|
||||
import utils from "../utils.js";
|
||||
import AxiosHeaders from "./AxiosHeaders.js";
|
||||
|
||||
const headersToObject = (thing) => thing instanceof AxiosHeaders ? { ...thing } : thing;
|
||||
const headersToObject = (thing) =>
|
||||
thing instanceof AxiosHeaders ? { ...thing } : thing;
|
||||
|
||||
/**
|
||||
* Config-specific merge-function which creates a new config-object
|
||||
@@ -21,7 +22,7 @@ export default function mergeConfig(config1, config2) {
|
||||
|
||||
function getMergedValue(target, source, prop, caseless) {
|
||||
if (utils.isPlainObject(target) && utils.isPlainObject(source)) {
|
||||
return utils.merge.call({caseless}, target, source);
|
||||
return utils.merge.call({ caseless }, target, source);
|
||||
} else if (utils.isPlainObject(source)) {
|
||||
return utils.merge({}, source);
|
||||
} else if (utils.isArray(source)) {
|
||||
@@ -30,7 +31,6 @@ export default function mergeConfig(config1, config2) {
|
||||
return source;
|
||||
}
|
||||
|
||||
// eslint-disable-next-line consistent-return
|
||||
function mergeDeepProperties(a, b, prop, caseless) {
|
||||
if (!utils.isUndefined(b)) {
|
||||
return getMergedValue(a, b, prop, caseless);
|
||||
@@ -93,14 +93,27 @@ export default function mergeConfig(config1, config2) {
|
||||
socketPath: defaultToConfig2,
|
||||
responseEncoding: defaultToConfig2,
|
||||
validateStatus: mergeDirectKeys,
|
||||
headers: (a, b, prop) => mergeDeepProperties(headersToObject(a), headersToObject(b), prop, true)
|
||||
headers: (a, b, prop) =>
|
||||
mergeDeepProperties(headersToObject(a), headersToObject(b), prop, true),
|
||||
};
|
||||
|
||||
utils.forEach(Object.keys({...config1, ...config2}), function computeConfigValue(prop) {
|
||||
const merge = mergeMap[prop] || mergeDeepProperties;
|
||||
const configValue = merge(config1[prop], config2[prop], prop);
|
||||
(utils.isUndefined(configValue) && merge !== mergeDirectKeys) || (config[prop] = configValue);
|
||||
});
|
||||
utils.forEach(
|
||||
Object.keys({ ...config1, ...config2 }),
|
||||
function computeConfigValue(prop) {
|
||||
if (
|
||||
prop === "__proto__" ||
|
||||
prop === "constructor" ||
|
||||
prop === "prototype"
|
||||
)
|
||||
return;
|
||||
const merge = utils.hasOwnProp(mergeMap, prop)
|
||||
? mergeMap[prop]
|
||||
: mergeDeepProperties;
|
||||
const configValue = merge(config1[prop], config2[prop], prop);
|
||||
(utils.isUndefined(configValue) && merge !== mergeDirectKeys) ||
|
||||
(config[prop] = configValue);
|
||||
},
|
||||
);
|
||||
|
||||
return config;
|
||||
}
|
||||
|
||||
2
node_modules/axios/lib/core/transformData.js
generated
vendored
2
node_modules/axios/lib/core/transformData.js
generated
vendored
@@ -1,6 +1,6 @@
|
||||
'use strict';
|
||||
|
||||
import utils from './../utils.js';
|
||||
import utils from '../utils.js';
|
||||
import defaults from '../defaults/index.js';
|
||||
import AxiosHeaders from '../core/AxiosHeaders.js';
|
||||
|
||||
|
||||
Reference in New Issue
Block a user