24875 lines
830 KiB
JavaScript
24875 lines
830 KiB
JavaScript
(self["webpackChunkjc_web_im"] = self["webpackChunkjc_web_im"] || []).push([[504],{
|
|
|
|
/***/ 4:
|
|
/***/ (function(__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) {
|
|
|
|
"use strict";
|
|
/* harmony import */ var _env_data_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(7958);
|
|
/* harmony import */ var _core_AxiosError_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(956);
|
|
|
|
|
|
|
|
|
|
const validators = {};
|
|
|
|
// eslint-disable-next-line func-names
|
|
['object', 'boolean', 'number', 'function', 'string', 'symbol'].forEach((type, i) => {
|
|
validators[type] = function validator(thing) {
|
|
return typeof thing === type || 'a' + (i < 1 ? 'n ' : ' ') + type;
|
|
};
|
|
});
|
|
const deprecatedWarnings = {};
|
|
|
|
/**
|
|
* Transitional option validator
|
|
*
|
|
* @param {function|boolean?} validator - set to false if the transitional option has been removed
|
|
* @param {string?} version - deprecated version / removed since version
|
|
* @param {string?} message - some message with additional info
|
|
*
|
|
* @returns {function}
|
|
*/
|
|
validators.transitional = function transitional(validator, version, message) {
|
|
function formatMessage(opt, desc) {
|
|
return '[Axios v' + _env_data_js__WEBPACK_IMPORTED_MODULE_0__/* .VERSION */ .x + '] Transitional option \'' + opt + '\'' + desc + (message ? '. ' + message : '');
|
|
}
|
|
|
|
// eslint-disable-next-line func-names
|
|
return (value, opt, opts) => {
|
|
if (validator === false) {
|
|
throw new _core_AxiosError_js__WEBPACK_IMPORTED_MODULE_1__/* ["default"] */ .A(formatMessage(opt, ' has been removed' + (version ? ' in ' + version : '')), _core_AxiosError_js__WEBPACK_IMPORTED_MODULE_1__/* ["default"] */ .A.ERR_DEPRECATED);
|
|
}
|
|
if (version && !deprecatedWarnings[opt]) {
|
|
deprecatedWarnings[opt] = true;
|
|
// eslint-disable-next-line no-console
|
|
console.warn(formatMessage(opt, ' has been deprecated since v' + version + ' and will be removed in the near future'));
|
|
}
|
|
return validator ? validator(value, opt, opts) : true;
|
|
};
|
|
};
|
|
|
|
/**
|
|
* Assert object's properties type
|
|
*
|
|
* @param {object} options
|
|
* @param {object} schema
|
|
* @param {boolean?} allowUnknown
|
|
*
|
|
* @returns {object}
|
|
*/
|
|
|
|
function assertOptions(options, schema, allowUnknown) {
|
|
if (typeof options !== 'object') {
|
|
throw new _core_AxiosError_js__WEBPACK_IMPORTED_MODULE_1__/* ["default"] */ .A('options must be an object', _core_AxiosError_js__WEBPACK_IMPORTED_MODULE_1__/* ["default"] */ .A.ERR_BAD_OPTION_VALUE);
|
|
}
|
|
const keys = Object.keys(options);
|
|
let i = keys.length;
|
|
while (i-- > 0) {
|
|
const opt = keys[i];
|
|
const validator = schema[opt];
|
|
if (validator) {
|
|
const value = options[opt];
|
|
const result = value === undefined || validator(value, opt, options);
|
|
if (result !== true) {
|
|
throw new _core_AxiosError_js__WEBPACK_IMPORTED_MODULE_1__/* ["default"] */ .A('option ' + opt + ' must be ' + result, _core_AxiosError_js__WEBPACK_IMPORTED_MODULE_1__/* ["default"] */ .A.ERR_BAD_OPTION_VALUE);
|
|
}
|
|
continue;
|
|
}
|
|
if (allowUnknown !== true) {
|
|
throw new _core_AxiosError_js__WEBPACK_IMPORTED_MODULE_1__/* ["default"] */ .A('Unknown option ' + opt, _core_AxiosError_js__WEBPACK_IMPORTED_MODULE_1__/* ["default"] */ .A.ERR_BAD_OPTION);
|
|
}
|
|
}
|
|
}
|
|
/* harmony default export */ __webpack_exports__.A = ({
|
|
assertOptions,
|
|
validators
|
|
});
|
|
|
|
/***/ }),
|
|
|
|
/***/ 187:
|
|
/***/ (function(__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) {
|
|
|
|
"use strict";
|
|
/* harmony import */ var core_js_modules_esnext_iterator_constructor_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(7195);
|
|
/* harmony import */ var core_js_modules_esnext_iterator_for_each_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(680);
|
|
|
|
|
|
const HttpStatusCode = {
|
|
Continue: 100,
|
|
SwitchingProtocols: 101,
|
|
Processing: 102,
|
|
EarlyHints: 103,
|
|
Ok: 200,
|
|
Created: 201,
|
|
Accepted: 202,
|
|
NonAuthoritativeInformation: 203,
|
|
NoContent: 204,
|
|
ResetContent: 205,
|
|
PartialContent: 206,
|
|
MultiStatus: 207,
|
|
AlreadyReported: 208,
|
|
ImUsed: 226,
|
|
MultipleChoices: 300,
|
|
MovedPermanently: 301,
|
|
Found: 302,
|
|
SeeOther: 303,
|
|
NotModified: 304,
|
|
UseProxy: 305,
|
|
Unused: 306,
|
|
TemporaryRedirect: 307,
|
|
PermanentRedirect: 308,
|
|
BadRequest: 400,
|
|
Unauthorized: 401,
|
|
PaymentRequired: 402,
|
|
Forbidden: 403,
|
|
NotFound: 404,
|
|
MethodNotAllowed: 405,
|
|
NotAcceptable: 406,
|
|
ProxyAuthenticationRequired: 407,
|
|
RequestTimeout: 408,
|
|
Conflict: 409,
|
|
Gone: 410,
|
|
LengthRequired: 411,
|
|
PreconditionFailed: 412,
|
|
PayloadTooLarge: 413,
|
|
UriTooLong: 414,
|
|
UnsupportedMediaType: 415,
|
|
RangeNotSatisfiable: 416,
|
|
ExpectationFailed: 417,
|
|
ImATeapot: 418,
|
|
MisdirectedRequest: 421,
|
|
UnprocessableEntity: 422,
|
|
Locked: 423,
|
|
FailedDependency: 424,
|
|
TooEarly: 425,
|
|
UpgradeRequired: 426,
|
|
PreconditionRequired: 428,
|
|
TooManyRequests: 429,
|
|
RequestHeaderFieldsTooLarge: 431,
|
|
UnavailableForLegalReasons: 451,
|
|
InternalServerError: 500,
|
|
NotImplemented: 501,
|
|
BadGateway: 502,
|
|
ServiceUnavailable: 503,
|
|
GatewayTimeout: 504,
|
|
HttpVersionNotSupported: 505,
|
|
VariantAlsoNegotiates: 506,
|
|
InsufficientStorage: 507,
|
|
LoopDetected: 508,
|
|
NotExtended: 510,
|
|
NetworkAuthenticationRequired: 511
|
|
};
|
|
Object.entries(HttpStatusCode).forEach(([key, value]) => {
|
|
HttpStatusCode[value] = key;
|
|
});
|
|
/* harmony default export */ __webpack_exports__.A = (HttpStatusCode);
|
|
|
|
/***/ }),
|
|
|
|
/***/ 292:
|
|
/***/ (function(__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) {
|
|
|
|
"use strict";
|
|
/* harmony import */ var core_js_modules_esnext_iterator_constructor_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(7195);
|
|
/* harmony import */ var core_js_modules_esnext_iterator_for_each_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(680);
|
|
/* harmony import */ var core_js_modules_esnext_iterator_map_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(793);
|
|
/* harmony import */ var _utils_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(5813);
|
|
/* harmony import */ var _helpers_parseHeaders_js__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(1939);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
const $internals = Symbol('internals');
|
|
function normalizeHeader(header) {
|
|
return header && String(header).trim().toLowerCase();
|
|
}
|
|
function normalizeValue(value) {
|
|
if (value === false || value == null) {
|
|
return value;
|
|
}
|
|
return _utils_js__WEBPACK_IMPORTED_MODULE_3__/* ["default"] */ .A.isArray(value) ? value.map(normalizeValue) : String(value);
|
|
}
|
|
function parseTokens(str) {
|
|
const tokens = Object.create(null);
|
|
const tokensRE = /([^\s,;=]+)\s*(?:=\s*([^,;]+))?/g;
|
|
let match;
|
|
while (match = tokensRE.exec(str)) {
|
|
tokens[match[1]] = match[2];
|
|
}
|
|
return tokens;
|
|
}
|
|
const isValidHeaderName = str => /^[-_a-zA-Z0-9^`|~,!#$%&'*+.]+$/.test(str.trim());
|
|
function matchHeaderValue(context, value, header, filter, isHeaderNameFilter) {
|
|
if (_utils_js__WEBPACK_IMPORTED_MODULE_3__/* ["default"] */ .A.isFunction(filter)) {
|
|
return filter.call(this, value, header);
|
|
}
|
|
if (isHeaderNameFilter) {
|
|
value = header;
|
|
}
|
|
if (!_utils_js__WEBPACK_IMPORTED_MODULE_3__/* ["default"] */ .A.isString(value)) return;
|
|
if (_utils_js__WEBPACK_IMPORTED_MODULE_3__/* ["default"] */ .A.isString(filter)) {
|
|
return value.indexOf(filter) !== -1;
|
|
}
|
|
if (_utils_js__WEBPACK_IMPORTED_MODULE_3__/* ["default"] */ .A.isRegExp(filter)) {
|
|
return filter.test(value);
|
|
}
|
|
}
|
|
function formatHeader(header) {
|
|
return header.trim().toLowerCase().replace(/([a-z\d])(\w*)/g, (w, char, str) => {
|
|
return char.toUpperCase() + str;
|
|
});
|
|
}
|
|
function buildAccessors(obj, header) {
|
|
const accessorName = _utils_js__WEBPACK_IMPORTED_MODULE_3__/* ["default"] */ .A.toCamelCase(' ' + header);
|
|
['get', 'set', 'has'].forEach(methodName => {
|
|
Object.defineProperty(obj, methodName + accessorName, {
|
|
value: function (arg1, arg2, arg3) {
|
|
return this[methodName].call(this, header, arg1, arg2, arg3);
|
|
},
|
|
configurable: true
|
|
});
|
|
});
|
|
}
|
|
class AxiosHeaders {
|
|
constructor(headers) {
|
|
headers && this.set(headers);
|
|
}
|
|
set(header, valueOrRewrite, rewrite) {
|
|
const self = this;
|
|
function setHeader(_value, _header, _rewrite) {
|
|
const lHeader = normalizeHeader(_header);
|
|
if (!lHeader) {
|
|
throw new Error('header name must be a non-empty string');
|
|
}
|
|
const key = _utils_js__WEBPACK_IMPORTED_MODULE_3__/* ["default"] */ .A.findKey(self, lHeader);
|
|
if (!key || self[key] === undefined || _rewrite === true || _rewrite === undefined && self[key] !== false) {
|
|
self[key || _header] = normalizeValue(_value);
|
|
}
|
|
}
|
|
const setHeaders = (headers, _rewrite) => _utils_js__WEBPACK_IMPORTED_MODULE_3__/* ["default"] */ .A.forEach(headers, (_value, _header) => setHeader(_value, _header, _rewrite));
|
|
if (_utils_js__WEBPACK_IMPORTED_MODULE_3__/* ["default"] */ .A.isPlainObject(header) || header instanceof this.constructor) {
|
|
setHeaders(header, valueOrRewrite);
|
|
} else if (_utils_js__WEBPACK_IMPORTED_MODULE_3__/* ["default"] */ .A.isString(header) && (header = header.trim()) && !isValidHeaderName(header)) {
|
|
setHeaders((0,_helpers_parseHeaders_js__WEBPACK_IMPORTED_MODULE_4__/* ["default"] */ .A)(header), valueOrRewrite);
|
|
} else {
|
|
header != null && setHeader(valueOrRewrite, header, rewrite);
|
|
}
|
|
return this;
|
|
}
|
|
get(header, parser) {
|
|
header = normalizeHeader(header);
|
|
if (header) {
|
|
const key = _utils_js__WEBPACK_IMPORTED_MODULE_3__/* ["default"] */ .A.findKey(this, header);
|
|
if (key) {
|
|
const value = this[key];
|
|
if (!parser) {
|
|
return value;
|
|
}
|
|
if (parser === true) {
|
|
return parseTokens(value);
|
|
}
|
|
if (_utils_js__WEBPACK_IMPORTED_MODULE_3__/* ["default"] */ .A.isFunction(parser)) {
|
|
return parser.call(this, value, key);
|
|
}
|
|
if (_utils_js__WEBPACK_IMPORTED_MODULE_3__/* ["default"] */ .A.isRegExp(parser)) {
|
|
return parser.exec(value);
|
|
}
|
|
throw new TypeError('parser must be boolean|regexp|function');
|
|
}
|
|
}
|
|
}
|
|
has(header, matcher) {
|
|
header = normalizeHeader(header);
|
|
if (header) {
|
|
const key = _utils_js__WEBPACK_IMPORTED_MODULE_3__/* ["default"] */ .A.findKey(this, header);
|
|
return !!(key && this[key] !== undefined && (!matcher || matchHeaderValue(this, this[key], key, matcher)));
|
|
}
|
|
return false;
|
|
}
|
|
delete(header, matcher) {
|
|
const self = this;
|
|
let deleted = false;
|
|
function deleteHeader(_header) {
|
|
_header = normalizeHeader(_header);
|
|
if (_header) {
|
|
const key = _utils_js__WEBPACK_IMPORTED_MODULE_3__/* ["default"] */ .A.findKey(self, _header);
|
|
if (key && (!matcher || matchHeaderValue(self, self[key], key, matcher))) {
|
|
delete self[key];
|
|
deleted = true;
|
|
}
|
|
}
|
|
}
|
|
if (_utils_js__WEBPACK_IMPORTED_MODULE_3__/* ["default"] */ .A.isArray(header)) {
|
|
header.forEach(deleteHeader);
|
|
} else {
|
|
deleteHeader(header);
|
|
}
|
|
return deleted;
|
|
}
|
|
clear(matcher) {
|
|
const keys = Object.keys(this);
|
|
let i = keys.length;
|
|
let deleted = false;
|
|
while (i--) {
|
|
const key = keys[i];
|
|
if (!matcher || matchHeaderValue(this, this[key], key, matcher, true)) {
|
|
delete this[key];
|
|
deleted = true;
|
|
}
|
|
}
|
|
return deleted;
|
|
}
|
|
normalize(format) {
|
|
const self = this;
|
|
const headers = {};
|
|
_utils_js__WEBPACK_IMPORTED_MODULE_3__/* ["default"] */ .A.forEach(this, (value, header) => {
|
|
const key = _utils_js__WEBPACK_IMPORTED_MODULE_3__/* ["default"] */ .A.findKey(headers, header);
|
|
if (key) {
|
|
self[key] = normalizeValue(value);
|
|
delete self[header];
|
|
return;
|
|
}
|
|
const normalized = format ? formatHeader(header) : String(header).trim();
|
|
if (normalized !== header) {
|
|
delete self[header];
|
|
}
|
|
self[normalized] = normalizeValue(value);
|
|
headers[normalized] = true;
|
|
});
|
|
return this;
|
|
}
|
|
concat(...targets) {
|
|
return this.constructor.concat(this, ...targets);
|
|
}
|
|
toJSON(asStrings) {
|
|
const obj = Object.create(null);
|
|
_utils_js__WEBPACK_IMPORTED_MODULE_3__/* ["default"] */ .A.forEach(this, (value, header) => {
|
|
value != null && value !== false && (obj[header] = asStrings && _utils_js__WEBPACK_IMPORTED_MODULE_3__/* ["default"] */ .A.isArray(value) ? value.join(', ') : value);
|
|
});
|
|
return obj;
|
|
}
|
|
[Symbol.iterator]() {
|
|
return Object.entries(this.toJSON())[Symbol.iterator]();
|
|
}
|
|
toString() {
|
|
return Object.entries(this.toJSON()).map(([header, value]) => header + ': ' + value).join('\n');
|
|
}
|
|
get [Symbol.toStringTag]() {
|
|
return 'AxiosHeaders';
|
|
}
|
|
static from(thing) {
|
|
return thing instanceof this ? thing : new this(thing);
|
|
}
|
|
static concat(first, ...targets) {
|
|
const computed = new this(first);
|
|
targets.forEach(target => computed.set(target));
|
|
return computed;
|
|
}
|
|
static accessor(header) {
|
|
const internals = this[$internals] = this[$internals] = {
|
|
accessors: {}
|
|
};
|
|
const accessors = internals.accessors;
|
|
const prototype = this.prototype;
|
|
function defineAccessor(_header) {
|
|
const lHeader = normalizeHeader(_header);
|
|
if (!accessors[lHeader]) {
|
|
buildAccessors(prototype, _header);
|
|
accessors[lHeader] = true;
|
|
}
|
|
}
|
|
_utils_js__WEBPACK_IMPORTED_MODULE_3__/* ["default"] */ .A.isArray(header) ? header.forEach(defineAccessor) : defineAccessor(header);
|
|
return this;
|
|
}
|
|
}
|
|
AxiosHeaders.accessor(['Content-Type', 'Content-Length', 'Accept', 'Accept-Encoding', 'User-Agent', 'Authorization']);
|
|
|
|
// reserved names hotfix
|
|
_utils_js__WEBPACK_IMPORTED_MODULE_3__/* ["default"] */ .A.reduceDescriptors(AxiosHeaders.prototype, ({
|
|
value
|
|
}, key) => {
|
|
let mapped = key[0].toUpperCase() + key.slice(1); // map `set` => `Set`
|
|
return {
|
|
get: () => value,
|
|
set(headerValue) {
|
|
this[mapped] = headerValue;
|
|
}
|
|
};
|
|
});
|
|
_utils_js__WEBPACK_IMPORTED_MODULE_3__/* ["default"] */ .A.freezeMethods(AxiosHeaders);
|
|
/* harmony default export */ __webpack_exports__.A = (AxiosHeaders);
|
|
|
|
/***/ }),
|
|
|
|
/***/ 308:
|
|
/***/ (function(__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) {
|
|
|
|
"use strict";
|
|
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
/* harmony export */ A: function() { return /* binding */ mergeConfig; }
|
|
/* harmony export */ });
|
|
/* harmony import */ var core_js_modules_esnext_iterator_constructor_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(7195);
|
|
/* harmony import */ var core_js_modules_esnext_iterator_for_each_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(680);
|
|
/* harmony import */ var _utils_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(5813);
|
|
/* harmony import */ var _AxiosHeaders_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(292);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
const headersToObject = thing => thing instanceof _AxiosHeaders_js__WEBPACK_IMPORTED_MODULE_2__/* ["default"] */ .A ? thing.toJSON() : thing;
|
|
|
|
/**
|
|
* Config-specific merge-function which creates a new config-object
|
|
* by merging two configuration objects together.
|
|
*
|
|
* @param {Object} config1
|
|
* @param {Object} config2
|
|
*
|
|
* @returns {Object} New object resulting from merging config2 to config1
|
|
*/
|
|
function mergeConfig(config1, config2) {
|
|
// eslint-disable-next-line no-param-reassign
|
|
config2 = config2 || {};
|
|
const config = {};
|
|
function getMergedValue(target, source, caseless) {
|
|
if (_utils_js__WEBPACK_IMPORTED_MODULE_3__/* ["default"] */ .A.isPlainObject(target) && _utils_js__WEBPACK_IMPORTED_MODULE_3__/* ["default"] */ .A.isPlainObject(source)) {
|
|
return _utils_js__WEBPACK_IMPORTED_MODULE_3__/* ["default"] */ .A.merge.call({
|
|
caseless
|
|
}, target, source);
|
|
} else if (_utils_js__WEBPACK_IMPORTED_MODULE_3__/* ["default"] */ .A.isPlainObject(source)) {
|
|
return _utils_js__WEBPACK_IMPORTED_MODULE_3__/* ["default"] */ .A.merge({}, source);
|
|
} else if (_utils_js__WEBPACK_IMPORTED_MODULE_3__/* ["default"] */ .A.isArray(source)) {
|
|
return source.slice();
|
|
}
|
|
return source;
|
|
}
|
|
|
|
// eslint-disable-next-line consistent-return
|
|
function mergeDeepProperties(a, b, caseless) {
|
|
if (!_utils_js__WEBPACK_IMPORTED_MODULE_3__/* ["default"] */ .A.isUndefined(b)) {
|
|
return getMergedValue(a, b, caseless);
|
|
} else if (!_utils_js__WEBPACK_IMPORTED_MODULE_3__/* ["default"] */ .A.isUndefined(a)) {
|
|
return getMergedValue(undefined, a, caseless);
|
|
}
|
|
}
|
|
|
|
// eslint-disable-next-line consistent-return
|
|
function valueFromConfig2(a, b) {
|
|
if (!_utils_js__WEBPACK_IMPORTED_MODULE_3__/* ["default"] */ .A.isUndefined(b)) {
|
|
return getMergedValue(undefined, b);
|
|
}
|
|
}
|
|
|
|
// eslint-disable-next-line consistent-return
|
|
function defaultToConfig2(a, b) {
|
|
if (!_utils_js__WEBPACK_IMPORTED_MODULE_3__/* ["default"] */ .A.isUndefined(b)) {
|
|
return getMergedValue(undefined, b);
|
|
} else if (!_utils_js__WEBPACK_IMPORTED_MODULE_3__/* ["default"] */ .A.isUndefined(a)) {
|
|
return getMergedValue(undefined, a);
|
|
}
|
|
}
|
|
|
|
// eslint-disable-next-line consistent-return
|
|
function mergeDirectKeys(a, b, prop) {
|
|
if (prop in config2) {
|
|
return getMergedValue(a, b);
|
|
} else if (prop in config1) {
|
|
return getMergedValue(undefined, a);
|
|
}
|
|
}
|
|
const mergeMap = {
|
|
url: valueFromConfig2,
|
|
method: valueFromConfig2,
|
|
data: valueFromConfig2,
|
|
baseURL: defaultToConfig2,
|
|
transformRequest: defaultToConfig2,
|
|
transformResponse: defaultToConfig2,
|
|
paramsSerializer: defaultToConfig2,
|
|
timeout: defaultToConfig2,
|
|
timeoutMessage: defaultToConfig2,
|
|
withCredentials: defaultToConfig2,
|
|
withXSRFToken: defaultToConfig2,
|
|
adapter: defaultToConfig2,
|
|
responseType: defaultToConfig2,
|
|
xsrfCookieName: defaultToConfig2,
|
|
xsrfHeaderName: defaultToConfig2,
|
|
onUploadProgress: defaultToConfig2,
|
|
onDownloadProgress: defaultToConfig2,
|
|
decompress: defaultToConfig2,
|
|
maxContentLength: defaultToConfig2,
|
|
maxBodyLength: defaultToConfig2,
|
|
beforeRedirect: defaultToConfig2,
|
|
transport: defaultToConfig2,
|
|
httpAgent: defaultToConfig2,
|
|
httpsAgent: defaultToConfig2,
|
|
cancelToken: defaultToConfig2,
|
|
socketPath: defaultToConfig2,
|
|
responseEncoding: defaultToConfig2,
|
|
validateStatus: mergeDirectKeys,
|
|
headers: (a, b) => mergeDeepProperties(headersToObject(a), headersToObject(b), true)
|
|
};
|
|
_utils_js__WEBPACK_IMPORTED_MODULE_3__/* ["default"] */ .A.forEach(Object.keys(Object.assign({}, config1, config2)), function computeConfigValue(prop) {
|
|
const merge = mergeMap[prop] || mergeDeepProperties;
|
|
const configValue = merge(config1[prop], config2[prop], prop);
|
|
_utils_js__WEBPACK_IMPORTED_MODULE_3__/* ["default"] */ .A.isUndefined(configValue) && merge !== mergeDirectKeys || (config[prop] = configValue);
|
|
});
|
|
return config;
|
|
}
|
|
|
|
/***/ }),
|
|
|
|
/***/ 323:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var toPrimitive = __webpack_require__(8004);
|
|
|
|
var $TypeError = TypeError;
|
|
|
|
// `ToBigInt` abstract operation
|
|
// https://tc39.es/ecma262/#sec-tobigint
|
|
module.exports = function (argument) {
|
|
var prim = toPrimitive(argument, 'number');
|
|
if (typeof prim == 'number') throw new $TypeError("Can't convert number to bigint");
|
|
// eslint-disable-next-line es/no-bigint -- safe
|
|
return BigInt(prim);
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 429:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var DESCRIPTORS = __webpack_require__(4911);
|
|
var fails = __webpack_require__(4212);
|
|
|
|
// V8 ~ Chrome 36-
|
|
// https://bugs.chromium.org/p/v8/issues/detail?id=3334
|
|
module.exports = DESCRIPTORS && fails(function () {
|
|
// eslint-disable-next-line es/no-object-defineproperty -- required for testing
|
|
return Object.defineProperty(function () { /* empty */ }, 'prototype', {
|
|
value: 42,
|
|
writable: false
|
|
}).prototype !== 42;
|
|
});
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 448:
|
|
/***/ (function(module) {
|
|
|
|
"use strict";
|
|
|
|
// IE8- don't enum bug keys
|
|
module.exports = [
|
|
'constructor',
|
|
'hasOwnProperty',
|
|
'isPrototypeOf',
|
|
'propertyIsEnumerable',
|
|
'toLocaleString',
|
|
'toString',
|
|
'valueOf'
|
|
];
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 483:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var IS_NODE = __webpack_require__(5181);
|
|
|
|
module.exports = function (name) {
|
|
try {
|
|
// eslint-disable-next-line no-new-func -- safe
|
|
if (IS_NODE) return Function('return require("' + name + '")')();
|
|
} catch (error) { /* empty */ }
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 491:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var global = __webpack_require__(4074);
|
|
var userAgent = __webpack_require__(8027);
|
|
|
|
var process = global.process;
|
|
var Deno = global.Deno;
|
|
var versions = process && process.versions || Deno && Deno.version;
|
|
var v8 = versions && versions.v8;
|
|
var match, version;
|
|
|
|
if (v8) {
|
|
match = v8.split('.');
|
|
// in old Chrome, versions of V8 isn't V8 = Chrome / 10
|
|
// but their correct versions are not interesting for us
|
|
version = match[0] > 0 && match[0] < 4 ? 1 : +(match[0] + match[1]);
|
|
}
|
|
|
|
// BrowserFS NodeJS `process` polyfill incorrectly set `.v8` to `0.0`
|
|
// so check `userAgent` even if `.v8` exists, but 0
|
|
if (!version && userAgent) {
|
|
match = userAgent.match(/Edge\/(\d+)/);
|
|
if (!match || match[1] >= 74) {
|
|
match = userAgent.match(/Chrome\/(\d+)/);
|
|
if (match) version = +match[1];
|
|
}
|
|
}
|
|
|
|
module.exports = version;
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 640:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
/* eslint-disable no-proto -- safe */
|
|
var uncurryThisAccessor = __webpack_require__(2471);
|
|
var anObject = __webpack_require__(6696);
|
|
var aPossiblePrototype = __webpack_require__(9219);
|
|
|
|
// `Object.setPrototypeOf` method
|
|
// https://tc39.es/ecma262/#sec-object.setprototypeof
|
|
// Works with __proto__ only. Old v8 can't work with null proto objects.
|
|
// eslint-disable-next-line es/no-object-setprototypeof -- safe
|
|
module.exports = Object.setPrototypeOf || ('__proto__' in {} ? function () {
|
|
var CORRECT_SETTER = false;
|
|
var test = {};
|
|
var setter;
|
|
try {
|
|
setter = uncurryThisAccessor(Object.prototype, '__proto__', 'set');
|
|
setter(test, []);
|
|
CORRECT_SETTER = test instanceof Array;
|
|
} catch (error) { /* empty */ }
|
|
return function setPrototypeOf(O, proto) {
|
|
anObject(O);
|
|
aPossiblePrototype(proto);
|
|
if (CORRECT_SETTER) setter(O, proto);
|
|
else O.__proto__ = proto;
|
|
return O;
|
|
};
|
|
}() : undefined);
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 679:
|
|
/***/ (function(__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) {
|
|
|
|
"use strict";
|
|
/* harmony import */ var _utils_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(5813);
|
|
/* harmony import */ var _platform_index_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(8394);
|
|
|
|
|
|
|
|
|
|
/* harmony default export */ __webpack_exports__.A = (_platform_index_js__WEBPACK_IMPORTED_MODULE_0__/* ["default"] */ .A.hasStandardBrowserEnv ?
|
|
// Standard browser envs have full support of the APIs needed to test
|
|
// whether the request URL is of the same origin as current location.
|
|
function standardBrowserEnv() {
|
|
const msie = /(msie|trident)/i.test(navigator.userAgent);
|
|
const urlParsingNode = document.createElement('a');
|
|
let originURL;
|
|
|
|
/**
|
|
* Parse a URL to discover its components
|
|
*
|
|
* @param {String} url The URL to be parsed
|
|
* @returns {Object}
|
|
*/
|
|
function resolveURL(url) {
|
|
let href = url;
|
|
if (msie) {
|
|
// IE needs attribute set twice to normalize properties
|
|
urlParsingNode.setAttribute('href', href);
|
|
href = urlParsingNode.href;
|
|
}
|
|
urlParsingNode.setAttribute('href', href);
|
|
|
|
// urlParsingNode provides the UrlUtils interface - http://url.spec.whatwg.org/#urlutils
|
|
return {
|
|
href: urlParsingNode.href,
|
|
protocol: urlParsingNode.protocol ? urlParsingNode.protocol.replace(/:$/, '') : '',
|
|
host: urlParsingNode.host,
|
|
search: urlParsingNode.search ? urlParsingNode.search.replace(/^\?/, '') : '',
|
|
hash: urlParsingNode.hash ? urlParsingNode.hash.replace(/^#/, '') : '',
|
|
hostname: urlParsingNode.hostname,
|
|
port: urlParsingNode.port,
|
|
pathname: urlParsingNode.pathname.charAt(0) === '/' ? urlParsingNode.pathname : '/' + urlParsingNode.pathname
|
|
};
|
|
}
|
|
originURL = resolveURL(window.location.href);
|
|
|
|
/**
|
|
* Determine if a URL shares the same origin as the current location
|
|
*
|
|
* @param {String} requestURL The URL to test
|
|
* @returns {boolean} True if URL shares the same origin, otherwise false
|
|
*/
|
|
return function isURLSameOrigin(requestURL) {
|
|
const parsed = _utils_js__WEBPACK_IMPORTED_MODULE_1__/* ["default"] */ .A.isString(requestURL) ? resolveURL(requestURL) : requestURL;
|
|
return parsed.protocol === originURL.protocol && parsed.host === originURL.host;
|
|
};
|
|
}() :
|
|
// Non standard browser envs (web workers, react-native) lack needed support.
|
|
function nonStandardBrowserEnv() {
|
|
return function isURLSameOrigin() {
|
|
return true;
|
|
};
|
|
}());
|
|
|
|
/***/ }),
|
|
|
|
/***/ 680:
|
|
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var $ = __webpack_require__(8155);
|
|
var iterate = __webpack_require__(1663);
|
|
var aCallable = __webpack_require__(8951);
|
|
var anObject = __webpack_require__(6696);
|
|
var getIteratorDirect = __webpack_require__(8764);
|
|
|
|
// `Iterator.prototype.forEach` method
|
|
// https://github.com/tc39/proposal-iterator-helpers
|
|
$({ target: 'Iterator', proto: true, real: true }, {
|
|
forEach: function forEach(fn) {
|
|
anObject(this);
|
|
aCallable(fn);
|
|
var record = getIteratorDirect(this);
|
|
var counter = 0;
|
|
iterate(record, function (value) {
|
|
fn(value, counter++);
|
|
}, { IS_RECORD: true });
|
|
}
|
|
});
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 683:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var aSet = __webpack_require__(3991);
|
|
var SetHelpers = __webpack_require__(5057);
|
|
var size = __webpack_require__(903);
|
|
var getSetRecord = __webpack_require__(3108);
|
|
var iterateSet = __webpack_require__(2282);
|
|
var iterateSimple = __webpack_require__(6550);
|
|
|
|
var Set = SetHelpers.Set;
|
|
var add = SetHelpers.add;
|
|
var has = SetHelpers.has;
|
|
|
|
// `Set.prototype.intersection` method
|
|
// https://github.com/tc39/proposal-set-methods
|
|
module.exports = function intersection(other) {
|
|
var O = aSet(this);
|
|
var otherRec = getSetRecord(other);
|
|
var result = new Set();
|
|
|
|
if (size(O) > otherRec.size) {
|
|
iterateSimple(otherRec.getIterator(), function (e) {
|
|
if (has(O, e)) add(result, e);
|
|
});
|
|
} else {
|
|
iterateSet(O, function (e) {
|
|
if (otherRec.includes(e)) add(result, e);
|
|
});
|
|
}
|
|
|
|
return result;
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 793:
|
|
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var $ = __webpack_require__(8155);
|
|
var map = __webpack_require__(2344);
|
|
var IS_PURE = __webpack_require__(8072);
|
|
|
|
// `Iterator.prototype.map` method
|
|
// https://github.com/tc39/proposal-iterator-helpers
|
|
$({ target: 'Iterator', proto: true, real: true, forced: IS_PURE }, {
|
|
map: map
|
|
});
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 797:
|
|
/***/ (function(__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) {
|
|
|
|
"use strict";
|
|
/* harmony import */ var core_js_modules_esnext_iterator_constructor_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(7195);
|
|
/* harmony import */ var core_js_modules_esnext_iterator_map_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(793);
|
|
/* harmony import */ var _utils_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(5813);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
/**
|
|
* It takes a string like `foo[x][y][z]` and returns an array like `['foo', 'x', 'y', 'z']
|
|
*
|
|
* @param {string} name - The name of the property to get.
|
|
*
|
|
* @returns An array of strings.
|
|
*/
|
|
function parsePropPath(name) {
|
|
// foo[x][y][z]
|
|
// foo.x.y.z
|
|
// foo-x-y-z
|
|
// foo x y z
|
|
return _utils_js__WEBPACK_IMPORTED_MODULE_2__/* ["default"] */ .A.matchAll(/\w+|\[(\w*)]/g, name).map(match => {
|
|
return match[0] === '[]' ? '' : match[1] || match[0];
|
|
});
|
|
}
|
|
|
|
/**
|
|
* Convert an array to an object.
|
|
*
|
|
* @param {Array<any>} arr - The array to convert to an object.
|
|
*
|
|
* @returns An object with the same keys and values as the array.
|
|
*/
|
|
function arrayToObject(arr) {
|
|
const obj = {};
|
|
const keys = Object.keys(arr);
|
|
let i;
|
|
const len = keys.length;
|
|
let key;
|
|
for (i = 0; i < len; i++) {
|
|
key = keys[i];
|
|
obj[key] = arr[key];
|
|
}
|
|
return obj;
|
|
}
|
|
|
|
/**
|
|
* It takes a FormData object and returns a JavaScript object
|
|
*
|
|
* @param {string} formData The FormData object to convert to JSON.
|
|
*
|
|
* @returns {Object<string, any> | null} The converted object.
|
|
*/
|
|
function formDataToJSON(formData) {
|
|
function buildPath(path, value, target, index) {
|
|
let name = path[index++];
|
|
if (name === '__proto__') return true;
|
|
const isNumericKey = Number.isFinite(+name);
|
|
const isLast = index >= path.length;
|
|
name = !name && _utils_js__WEBPACK_IMPORTED_MODULE_2__/* ["default"] */ .A.isArray(target) ? target.length : name;
|
|
if (isLast) {
|
|
if (_utils_js__WEBPACK_IMPORTED_MODULE_2__/* ["default"] */ .A.hasOwnProp(target, name)) {
|
|
target[name] = [target[name], value];
|
|
} else {
|
|
target[name] = value;
|
|
}
|
|
return !isNumericKey;
|
|
}
|
|
if (!target[name] || !_utils_js__WEBPACK_IMPORTED_MODULE_2__/* ["default"] */ .A.isObject(target[name])) {
|
|
target[name] = [];
|
|
}
|
|
const result = buildPath(path, value, target[name], index);
|
|
if (result && _utils_js__WEBPACK_IMPORTED_MODULE_2__/* ["default"] */ .A.isArray(target[name])) {
|
|
target[name] = arrayToObject(target[name]);
|
|
}
|
|
return !isNumericKey;
|
|
}
|
|
if (_utils_js__WEBPACK_IMPORTED_MODULE_2__/* ["default"] */ .A.isFormData(formData) && _utils_js__WEBPACK_IMPORTED_MODULE_2__/* ["default"] */ .A.isFunction(formData.entries)) {
|
|
const obj = {};
|
|
_utils_js__WEBPACK_IMPORTED_MODULE_2__/* ["default"] */ .A.forEachEntry(formData, (name, value) => {
|
|
buildPath(parsePropPath(name), value, obj, 0);
|
|
});
|
|
return obj;
|
|
}
|
|
return null;
|
|
}
|
|
/* harmony default export */ __webpack_exports__.A = (formDataToJSON);
|
|
|
|
/***/ }),
|
|
|
|
/***/ 903:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var uncurryThisAccessor = __webpack_require__(2471);
|
|
var SetHelpers = __webpack_require__(5057);
|
|
|
|
module.exports = uncurryThisAccessor(SetHelpers.proto, 'size', 'get') || function (set) {
|
|
return set.size;
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 956:
|
|
/***/ (function(__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) {
|
|
|
|
"use strict";
|
|
/* harmony import */ var _utils_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(5813);
|
|
|
|
|
|
|
|
|
|
/**
|
|
* 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);
|
|
if (Error.captureStackTrace) {
|
|
Error.captureStackTrace(this, this.constructor);
|
|
} else {
|
|
this.stack = new Error().stack;
|
|
}
|
|
this.message = message;
|
|
this.name = 'AxiosError';
|
|
code && (this.code = code);
|
|
config && (this.config = config);
|
|
request && (this.request = request);
|
|
response && (this.response = response);
|
|
}
|
|
_utils_js__WEBPACK_IMPORTED_MODULE_0__/* ["default"] */ .A.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_js__WEBPACK_IMPORTED_MODULE_0__/* ["default"] */ .A.toJSONObject(this.config),
|
|
code: this.code,
|
|
status: this.response && this.response.status ? this.response.status : null
|
|
};
|
|
}
|
|
});
|
|
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_js__WEBPACK_IMPORTED_MODULE_0__/* ["default"] */ .A.toFlatObject(error, axiosError, function filter(obj) {
|
|
return obj !== Error.prototype;
|
|
}, prop => {
|
|
return prop !== 'isAxiosError';
|
|
});
|
|
AxiosError.call(axiosError, error.message, code, config, request, response);
|
|
axiosError.cause = error;
|
|
axiosError.name = error.name;
|
|
customProps && Object.assign(axiosError, customProps);
|
|
return axiosError;
|
|
};
|
|
/* harmony default export */ __webpack_exports__.A = (AxiosError);
|
|
|
|
/***/ }),
|
|
|
|
/***/ 978:
|
|
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var arrayToReversed = __webpack_require__(3495);
|
|
var ArrayBufferViewCore = __webpack_require__(4257);
|
|
|
|
var aTypedArray = ArrayBufferViewCore.aTypedArray;
|
|
var exportTypedArrayMethod = ArrayBufferViewCore.exportTypedArrayMethod;
|
|
var getTypedArrayConstructor = ArrayBufferViewCore.getTypedArrayConstructor;
|
|
|
|
// `%TypedArray%.prototype.toReversed` method
|
|
// https://tc39.es/ecma262/#sec-%typedarray%.prototype.toreversed
|
|
exportTypedArrayMethod('toReversed', function toReversed() {
|
|
return arrayToReversed(aTypedArray(this), getTypedArrayConstructor(this));
|
|
});
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 1028:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var fails = __webpack_require__(4212);
|
|
var isCallable = __webpack_require__(6450);
|
|
var isObject = __webpack_require__(1909);
|
|
var create = __webpack_require__(9891);
|
|
var getPrototypeOf = __webpack_require__(3148);
|
|
var defineBuiltIn = __webpack_require__(3647);
|
|
var wellKnownSymbol = __webpack_require__(9760);
|
|
var IS_PURE = __webpack_require__(8072);
|
|
|
|
var ITERATOR = wellKnownSymbol('iterator');
|
|
var BUGGY_SAFARI_ITERATORS = false;
|
|
|
|
// `%IteratorPrototype%` object
|
|
// https://tc39.es/ecma262/#sec-%iteratorprototype%-object
|
|
var IteratorPrototype, PrototypeOfArrayIteratorPrototype, arrayIterator;
|
|
|
|
/* eslint-disable es/no-array-prototype-keys -- safe */
|
|
if ([].keys) {
|
|
arrayIterator = [].keys();
|
|
// Safari 8 has buggy iterators w/o `next`
|
|
if (!('next' in arrayIterator)) BUGGY_SAFARI_ITERATORS = true;
|
|
else {
|
|
PrototypeOfArrayIteratorPrototype = getPrototypeOf(getPrototypeOf(arrayIterator));
|
|
if (PrototypeOfArrayIteratorPrototype !== Object.prototype) IteratorPrototype = PrototypeOfArrayIteratorPrototype;
|
|
}
|
|
}
|
|
|
|
var NEW_ITERATOR_PROTOTYPE = !isObject(IteratorPrototype) || fails(function () {
|
|
var test = {};
|
|
// FF44- legacy iterators case
|
|
return IteratorPrototype[ITERATOR].call(test) !== test;
|
|
});
|
|
|
|
if (NEW_ITERATOR_PROTOTYPE) IteratorPrototype = {};
|
|
else if (IS_PURE) IteratorPrototype = create(IteratorPrototype);
|
|
|
|
// `%IteratorPrototype%[@@iterator]()` method
|
|
// https://tc39.es/ecma262/#sec-%iteratorprototype%-@@iterator
|
|
if (!isCallable(IteratorPrototype[ITERATOR])) {
|
|
defineBuiltIn(IteratorPrototype, ITERATOR, function () {
|
|
return this;
|
|
});
|
|
}
|
|
|
|
module.exports = {
|
|
IteratorPrototype: IteratorPrototype,
|
|
BUGGY_SAFARI_ITERATORS: BUGGY_SAFARI_ITERATORS
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 1079:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var uncurryThis = __webpack_require__(1371);
|
|
|
|
var toString = uncurryThis({}.toString);
|
|
var stringSlice = uncurryThis(''.slice);
|
|
|
|
module.exports = function (it) {
|
|
return stringSlice(toString(it), 8, -1);
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 1252:
|
|
/***/ (function(__unused_webpack_module, exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var DESCRIPTORS = __webpack_require__(4911);
|
|
var V8_PROTOTYPE_DEFINE_BUG = __webpack_require__(429);
|
|
var definePropertyModule = __webpack_require__(8564);
|
|
var anObject = __webpack_require__(6696);
|
|
var toIndexedObject = __webpack_require__(5830);
|
|
var objectKeys = __webpack_require__(6915);
|
|
|
|
// `Object.defineProperties` method
|
|
// https://tc39.es/ecma262/#sec-object.defineproperties
|
|
// eslint-disable-next-line es/no-object-defineproperties -- safe
|
|
exports.f = DESCRIPTORS && !V8_PROTOTYPE_DEFINE_BUG ? Object.defineProperties : function defineProperties(O, Properties) {
|
|
anObject(O);
|
|
var props = toIndexedObject(Properties);
|
|
var keys = objectKeys(Properties);
|
|
var length = keys.length;
|
|
var index = 0;
|
|
var key;
|
|
while (length > index) definePropertyModule.f(O, key = keys[index++], props[key]);
|
|
return O;
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 1257:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var toIntegerOrInfinity = __webpack_require__(9106);
|
|
|
|
var max = Math.max;
|
|
var min = Math.min;
|
|
|
|
// Helper for a popular repeating case of the spec:
|
|
// Let integer be ? ToInteger(index).
|
|
// If integer < 0, let result be max((length + integer), 0); else let result be min(integer, length).
|
|
module.exports = function (index, length) {
|
|
var integer = toIntegerOrInfinity(index);
|
|
return integer < 0 ? max(integer + length, 0) : min(integer, length);
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 1258:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var requireObjectCoercible = __webpack_require__(2967);
|
|
|
|
var $Object = Object;
|
|
|
|
// `ToObject` abstract operation
|
|
// https://tc39.es/ecma262/#sec-toobject
|
|
module.exports = function (argument) {
|
|
return $Object(requireObjectCoercible(argument));
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 1298:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var call = __webpack_require__(4978);
|
|
var anObject = __webpack_require__(6696);
|
|
var getMethod = __webpack_require__(4863);
|
|
|
|
module.exports = function (iterator, kind, value) {
|
|
var innerResult, innerError;
|
|
anObject(iterator);
|
|
try {
|
|
innerResult = getMethod(iterator, 'return');
|
|
if (!innerResult) {
|
|
if (kind === 'throw') throw value;
|
|
return value;
|
|
}
|
|
innerResult = call(innerResult, iterator);
|
|
} catch (error) {
|
|
innerError = true;
|
|
innerResult = error;
|
|
}
|
|
if (kind === 'throw') throw value;
|
|
if (innerError) throw innerResult;
|
|
anObject(innerResult);
|
|
return value;
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 1320:
|
|
/***/ (function(__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) {
|
|
|
|
"use strict";
|
|
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
/* harmony export */ A: function() { return /* binding */ isAbsoluteURL; }
|
|
/* harmony export */ });
|
|
|
|
|
|
/**
|
|
* Determines whether the specified URL is absolute
|
|
*
|
|
* @param {string} url The URL to test
|
|
*
|
|
* @returns {boolean} True if the specified URL is absolute, otherwise false
|
|
*/
|
|
function isAbsoluteURL(url) {
|
|
// A URL is considered absolute if it begins with "<scheme>://" or "//" (protocol-relative URL).
|
|
// RFC 3986 defines scheme name as a sequence of characters beginning with a letter and followed
|
|
// by any combination of letters, digits, plus, period, or hyphen.
|
|
return /^([a-z][a-z\d+\-.]*:)?\/\//i.test(url);
|
|
}
|
|
|
|
/***/ }),
|
|
|
|
/***/ 1327:
|
|
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) {
|
|
|
|
"use strict";
|
|
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
/* harmony export */ $q: function() { return /* binding */ setupDevtoolsPlugin; }
|
|
/* harmony export */ });
|
|
/* harmony import */ var core_js_modules_es_array_push_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(5513);
|
|
/* harmony import */ var core_js_modules_es_array_push_js__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_array_push_js__WEBPACK_IMPORTED_MODULE_0__);
|
|
/* harmony import */ var _env_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(8184);
|
|
/* harmony import */ var _const_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(5172);
|
|
/* harmony import */ var _proxy_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(2779);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
function setupDevtoolsPlugin(pluginDescriptor, setupFn) {
|
|
const descriptor = pluginDescriptor;
|
|
const target = (0,_env_js__WEBPACK_IMPORTED_MODULE_1__/* .getTarget */ .EW)();
|
|
const hook = (0,_env_js__WEBPACK_IMPORTED_MODULE_1__/* .getDevtoolsGlobalHook */ .HH)();
|
|
const enableProxy = _env_js__WEBPACK_IMPORTED_MODULE_1__/* .isProxyAvailable */ .Cx && descriptor.enableEarlyProxy;
|
|
if (hook && (target.__VUE_DEVTOOLS_PLUGIN_API_AVAILABLE__ || !enableProxy)) {
|
|
hook.emit(_const_js__WEBPACK_IMPORTED_MODULE_2__/* .HOOK_SETUP */ .K, pluginDescriptor, setupFn);
|
|
} else {
|
|
const proxy = enableProxy ? new _proxy_js__WEBPACK_IMPORTED_MODULE_3__/* .ApiProxy */ .R(descriptor, hook) : null;
|
|
const list = target.__VUE_DEVTOOLS_PLUGINS__ = target.__VUE_DEVTOOLS_PLUGINS__ || [];
|
|
list.push({
|
|
pluginDescriptor: descriptor,
|
|
setupFn,
|
|
proxy
|
|
});
|
|
if (proxy) {
|
|
setupFn(proxy.proxiedTarget);
|
|
}
|
|
}
|
|
}
|
|
|
|
/***/ }),
|
|
|
|
/***/ 1341:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var lengthOfArrayLike = __webpack_require__(4231);
|
|
|
|
module.exports = function (Constructor, list, $length) {
|
|
var index = 0;
|
|
var length = arguments.length > 2 ? $length : lengthOfArrayLike(list);
|
|
var result = new Constructor(length);
|
|
while (length > index) result[index] = list[index++];
|
|
return result;
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 1371:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var NATIVE_BIND = __webpack_require__(8537);
|
|
|
|
var FunctionPrototype = Function.prototype;
|
|
var call = FunctionPrototype.call;
|
|
var uncurryThisWithBind = NATIVE_BIND && FunctionPrototype.bind.bind(call, call);
|
|
|
|
module.exports = NATIVE_BIND ? uncurryThisWithBind : function (fn) {
|
|
return function () {
|
|
return call.apply(fn, arguments);
|
|
};
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 1396:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var uncurryThis = __webpack_require__(1371);
|
|
var toObject = __webpack_require__(1258);
|
|
|
|
var hasOwnProperty = uncurryThis({}.hasOwnProperty);
|
|
|
|
// `HasOwnProperty` abstract operation
|
|
// https://tc39.es/ecma262/#sec-hasownproperty
|
|
// eslint-disable-next-line es/no-object-hasown -- safe
|
|
module.exports = Object.hasOwn || function hasOwn(it, key) {
|
|
return hasOwnProperty(toObject(it), key);
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 1422:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var toPrimitive = __webpack_require__(8004);
|
|
var isSymbol = __webpack_require__(3058);
|
|
|
|
// `ToPropertyKey` abstract operation
|
|
// https://tc39.es/ecma262/#sec-topropertykey
|
|
module.exports = function (argument) {
|
|
var key = toPrimitive(argument, 'string');
|
|
return isSymbol(key) ? key : key + '';
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 1476:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var isPrototypeOf = __webpack_require__(1856);
|
|
|
|
var $TypeError = TypeError;
|
|
|
|
module.exports = function (it, Prototype) {
|
|
if (isPrototypeOf(Prototype, it)) return it;
|
|
throw new $TypeError('Incorrect invocation');
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 1477:
|
|
/***/ (function(__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) {
|
|
|
|
"use strict";
|
|
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
/* harmony export */ A: function() { return /* binding */ combineURLs; }
|
|
/* harmony export */ });
|
|
|
|
|
|
/**
|
|
* Creates a new URL by combining the specified URLs
|
|
*
|
|
* @param {string} baseURL The base URL
|
|
* @param {string} relativeURL The relative URL
|
|
*
|
|
* @returns {string} The combined URL
|
|
*/
|
|
function combineURLs(baseURL, relativeURL) {
|
|
return relativeURL ? baseURL.replace(/\/?\/$/, '') + '/' + relativeURL.replace(/^\/+/, '') : baseURL;
|
|
}
|
|
|
|
/***/ }),
|
|
|
|
/***/ 1531:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var aSet = __webpack_require__(3991);
|
|
var SetHelpers = __webpack_require__(5057);
|
|
var clone = __webpack_require__(7289);
|
|
var getSetRecord = __webpack_require__(3108);
|
|
var iterateSimple = __webpack_require__(6550);
|
|
|
|
var add = SetHelpers.add;
|
|
var has = SetHelpers.has;
|
|
var remove = SetHelpers.remove;
|
|
|
|
// `Set.prototype.symmetricDifference` method
|
|
// https://github.com/tc39/proposal-set-methods
|
|
module.exports = function symmetricDifference(other) {
|
|
var O = aSet(this);
|
|
var keysIter = getSetRecord(other).getIterator();
|
|
var result = clone(O);
|
|
iterateSimple(keysIter, function (e) {
|
|
if (has(O, e)) remove(result, e);
|
|
else add(result, e);
|
|
});
|
|
return result;
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 1591:
|
|
/***/ (function(__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) {
|
|
|
|
"use strict";
|
|
/* harmony import */ var core_js_modules_esnext_iterator_constructor_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(7195);
|
|
/* harmony import */ var core_js_modules_esnext_iterator_filter_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(3741);
|
|
/* harmony import */ var core_js_modules_esnext_iterator_for_each_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(680);
|
|
/* harmony import */ var core_js_modules_esnext_iterator_map_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(793);
|
|
/* harmony import */ var core_js_modules_web_dom_exception_stack_js__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(6180);
|
|
/* harmony import */ var _utils_js__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(5813);
|
|
/* harmony import */ var _core_settle_js__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(6087);
|
|
/* harmony import */ var _helpers_cookies_js__WEBPACK_IMPORTED_MODULE_15__ = __webpack_require__(7229);
|
|
/* harmony import */ var _helpers_buildURL_js__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(9541);
|
|
/* harmony import */ var _core_buildFullPath_js__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(9008);
|
|
/* harmony import */ var _helpers_isURLSameOrigin_js__WEBPACK_IMPORTED_MODULE_14__ = __webpack_require__(679);
|
|
/* harmony import */ var _defaults_transitional_js__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(3773);
|
|
/* harmony import */ var _core_AxiosError_js__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(956);
|
|
/* harmony import */ var _cancel_CanceledError_js__WEBPACK_IMPORTED_MODULE_16__ = __webpack_require__(7080);
|
|
/* harmony import */ var _helpers_parseProtocol_js__WEBPACK_IMPORTED_MODULE_17__ = __webpack_require__(3009);
|
|
/* harmony import */ var _platform_index_js__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(8394);
|
|
/* harmony import */ var _core_AxiosHeaders_js__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(292);
|
|
/* harmony import */ var _helpers_speedometer_js__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(7727);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
function progressEventReducer(listener, isDownloadStream) {
|
|
let bytesNotified = 0;
|
|
const _speedometer = (0,_helpers_speedometer_js__WEBPACK_IMPORTED_MODULE_5__/* ["default"] */ .A)(50, 250);
|
|
return e => {
|
|
const loaded = e.loaded;
|
|
const total = e.lengthComputable ? e.total : undefined;
|
|
const progressBytes = loaded - bytesNotified;
|
|
const rate = _speedometer(progressBytes);
|
|
const inRange = loaded <= total;
|
|
bytesNotified = loaded;
|
|
const data = {
|
|
loaded,
|
|
total,
|
|
progress: total ? loaded / total : undefined,
|
|
bytes: progressBytes,
|
|
rate: rate ? rate : undefined,
|
|
estimated: rate && total && inRange ? (total - loaded) / rate : undefined,
|
|
event: e
|
|
};
|
|
data[isDownloadStream ? 'download' : 'upload'] = true;
|
|
listener(data);
|
|
};
|
|
}
|
|
const isXHRAdapterSupported = typeof XMLHttpRequest !== 'undefined';
|
|
/* harmony default export */ __webpack_exports__.A = (isXHRAdapterSupported && function (config) {
|
|
return new Promise(function dispatchXhrRequest(resolve, reject) {
|
|
let requestData = config.data;
|
|
const requestHeaders = _core_AxiosHeaders_js__WEBPACK_IMPORTED_MODULE_6__/* ["default"] */ .A.from(config.headers).normalize();
|
|
let {
|
|
responseType,
|
|
withXSRFToken
|
|
} = config;
|
|
let onCanceled;
|
|
function done() {
|
|
if (config.cancelToken) {
|
|
config.cancelToken.unsubscribe(onCanceled);
|
|
}
|
|
if (config.signal) {
|
|
config.signal.removeEventListener('abort', onCanceled);
|
|
}
|
|
}
|
|
let contentType;
|
|
if (_utils_js__WEBPACK_IMPORTED_MODULE_7__/* ["default"] */ .A.isFormData(requestData)) {
|
|
if (_platform_index_js__WEBPACK_IMPORTED_MODULE_8__/* ["default"] */ .A.hasStandardBrowserEnv || _platform_index_js__WEBPACK_IMPORTED_MODULE_8__/* ["default"] */ .A.hasStandardBrowserWebWorkerEnv) {
|
|
requestHeaders.setContentType(false); // Let the browser set it
|
|
} else if ((contentType = requestHeaders.getContentType()) !== false) {
|
|
// fix semicolon duplication issue for ReactNative FormData implementation
|
|
const [type, ...tokens] = contentType ? contentType.split(';').map(token => token.trim()).filter(Boolean) : [];
|
|
requestHeaders.setContentType([type || 'multipart/form-data', ...tokens].join('; '));
|
|
}
|
|
}
|
|
let request = new XMLHttpRequest();
|
|
|
|
// HTTP basic authentication
|
|
if (config.auth) {
|
|
const username = config.auth.username || '';
|
|
const password = config.auth.password ? unescape(encodeURIComponent(config.auth.password)) : '';
|
|
requestHeaders.set('Authorization', 'Basic ' + btoa(username + ':' + password));
|
|
}
|
|
const fullPath = (0,_core_buildFullPath_js__WEBPACK_IMPORTED_MODULE_9__/* ["default"] */ .A)(config.baseURL, config.url);
|
|
request.open(config.method.toUpperCase(), (0,_helpers_buildURL_js__WEBPACK_IMPORTED_MODULE_10__/* ["default"] */ .A)(fullPath, config.params, config.paramsSerializer), true);
|
|
|
|
// Set the request timeout in MS
|
|
request.timeout = config.timeout;
|
|
function onloadend() {
|
|
if (!request) {
|
|
return;
|
|
}
|
|
// Prepare the response
|
|
const responseHeaders = _core_AxiosHeaders_js__WEBPACK_IMPORTED_MODULE_6__/* ["default"] */ .A.from('getAllResponseHeaders' in request && request.getAllResponseHeaders());
|
|
const responseData = !responseType || responseType === 'text' || responseType === 'json' ? request.responseText : request.response;
|
|
const response = {
|
|
data: responseData,
|
|
status: request.status,
|
|
statusText: request.statusText,
|
|
headers: responseHeaders,
|
|
config,
|
|
request
|
|
};
|
|
(0,_core_settle_js__WEBPACK_IMPORTED_MODULE_11__/* ["default"] */ .A)(function _resolve(value) {
|
|
resolve(value);
|
|
done();
|
|
}, function _reject(err) {
|
|
reject(err);
|
|
done();
|
|
}, response);
|
|
|
|
// Clean up request
|
|
request = null;
|
|
}
|
|
if ('onloadend' in request) {
|
|
// Use onloadend if available
|
|
request.onloadend = onloadend;
|
|
} else {
|
|
// Listen for ready state to emulate onloadend
|
|
request.onreadystatechange = function handleLoad() {
|
|
if (!request || request.readyState !== 4) {
|
|
return;
|
|
}
|
|
|
|
// The request errored out and we didn't get a response, this will be
|
|
// handled by onerror instead
|
|
// With one exception: request that using file: protocol, most browsers
|
|
// will return status as 0 even though it's a successful request
|
|
if (request.status === 0 && !(request.responseURL && request.responseURL.indexOf('file:') === 0)) {
|
|
return;
|
|
}
|
|
// readystate handler is calling before onerror or ontimeout handlers,
|
|
// so we should call onloadend on the next 'tick'
|
|
setTimeout(onloadend);
|
|
};
|
|
}
|
|
|
|
// Handle browser request cancellation (as opposed to a manual cancellation)
|
|
request.onabort = function handleAbort() {
|
|
if (!request) {
|
|
return;
|
|
}
|
|
reject(new _core_AxiosError_js__WEBPACK_IMPORTED_MODULE_12__/* ["default"] */ .A('Request aborted', _core_AxiosError_js__WEBPACK_IMPORTED_MODULE_12__/* ["default"] */ .A.ECONNABORTED, config, request));
|
|
|
|
// Clean up request
|
|
request = null;
|
|
};
|
|
|
|
// Handle low level network errors
|
|
request.onerror = function handleError() {
|
|
// Real errors are hidden from us by the browser
|
|
// onerror should only fire if it's a network error
|
|
reject(new _core_AxiosError_js__WEBPACK_IMPORTED_MODULE_12__/* ["default"] */ .A('Network Error', _core_AxiosError_js__WEBPACK_IMPORTED_MODULE_12__/* ["default"] */ .A.ERR_NETWORK, config, request));
|
|
|
|
// Clean up request
|
|
request = null;
|
|
};
|
|
|
|
// Handle timeout
|
|
request.ontimeout = function handleTimeout() {
|
|
let timeoutErrorMessage = config.timeout ? 'timeout of ' + config.timeout + 'ms exceeded' : 'timeout exceeded';
|
|
const transitional = config.transitional || _defaults_transitional_js__WEBPACK_IMPORTED_MODULE_13__/* ["default"] */ .A;
|
|
if (config.timeoutErrorMessage) {
|
|
timeoutErrorMessage = config.timeoutErrorMessage;
|
|
}
|
|
reject(new _core_AxiosError_js__WEBPACK_IMPORTED_MODULE_12__/* ["default"] */ .A(timeoutErrorMessage, transitional.clarifyTimeoutError ? _core_AxiosError_js__WEBPACK_IMPORTED_MODULE_12__/* ["default"] */ .A.ETIMEDOUT : _core_AxiosError_js__WEBPACK_IMPORTED_MODULE_12__/* ["default"] */ .A.ECONNABORTED, config, request));
|
|
|
|
// Clean up request
|
|
request = null;
|
|
};
|
|
|
|
// Add xsrf header
|
|
// This is only done if running in a standard browser environment.
|
|
// Specifically not if we're in a web worker, or react-native.
|
|
if (_platform_index_js__WEBPACK_IMPORTED_MODULE_8__/* ["default"] */ .A.hasStandardBrowserEnv) {
|
|
withXSRFToken && _utils_js__WEBPACK_IMPORTED_MODULE_7__/* ["default"] */ .A.isFunction(withXSRFToken) && (withXSRFToken = withXSRFToken(config));
|
|
if (withXSRFToken || withXSRFToken !== false && (0,_helpers_isURLSameOrigin_js__WEBPACK_IMPORTED_MODULE_14__/* ["default"] */ .A)(fullPath)) {
|
|
// Add xsrf header
|
|
const xsrfValue = config.xsrfHeaderName && config.xsrfCookieName && _helpers_cookies_js__WEBPACK_IMPORTED_MODULE_15__/* ["default"] */ .A.read(config.xsrfCookieName);
|
|
if (xsrfValue) {
|
|
requestHeaders.set(config.xsrfHeaderName, xsrfValue);
|
|
}
|
|
}
|
|
}
|
|
|
|
// Remove Content-Type if data is undefined
|
|
requestData === undefined && requestHeaders.setContentType(null);
|
|
|
|
// Add headers to the request
|
|
if ('setRequestHeader' in request) {
|
|
_utils_js__WEBPACK_IMPORTED_MODULE_7__/* ["default"] */ .A.forEach(requestHeaders.toJSON(), function setRequestHeader(val, key) {
|
|
request.setRequestHeader(key, val);
|
|
});
|
|
}
|
|
|
|
// Add withCredentials to request if needed
|
|
if (!_utils_js__WEBPACK_IMPORTED_MODULE_7__/* ["default"] */ .A.isUndefined(config.withCredentials)) {
|
|
request.withCredentials = !!config.withCredentials;
|
|
}
|
|
|
|
// Add responseType to request if needed
|
|
if (responseType && responseType !== 'json') {
|
|
request.responseType = config.responseType;
|
|
}
|
|
|
|
// Handle progress if needed
|
|
if (typeof config.onDownloadProgress === 'function') {
|
|
request.addEventListener('progress', progressEventReducer(config.onDownloadProgress, true));
|
|
}
|
|
|
|
// Not all browsers support upload events
|
|
if (typeof config.onUploadProgress === 'function' && request.upload) {
|
|
request.upload.addEventListener('progress', progressEventReducer(config.onUploadProgress));
|
|
}
|
|
if (config.cancelToken || config.signal) {
|
|
// Handle cancellation
|
|
// eslint-disable-next-line func-names
|
|
onCanceled = cancel => {
|
|
if (!request) {
|
|
return;
|
|
}
|
|
reject(!cancel || cancel.type ? new _cancel_CanceledError_js__WEBPACK_IMPORTED_MODULE_16__/* ["default"] */ .A(null, config, request) : cancel);
|
|
request.abort();
|
|
request = null;
|
|
};
|
|
config.cancelToken && config.cancelToken.subscribe(onCanceled);
|
|
if (config.signal) {
|
|
config.signal.aborted ? onCanceled() : config.signal.addEventListener('abort', onCanceled);
|
|
}
|
|
}
|
|
const protocol = (0,_helpers_parseProtocol_js__WEBPACK_IMPORTED_MODULE_17__/* ["default"] */ .A)(fullPath);
|
|
if (protocol && _platform_index_js__WEBPACK_IMPORTED_MODULE_8__/* ["default"] */ .A.protocols.indexOf(protocol) === -1) {
|
|
reject(new _core_AxiosError_js__WEBPACK_IMPORTED_MODULE_12__/* ["default"] */ .A('Unsupported protocol ' + protocol + ':', _core_AxiosError_js__WEBPACK_IMPORTED_MODULE_12__/* ["default"] */ .A.ERR_BAD_REQUEST, config));
|
|
return;
|
|
}
|
|
|
|
// Send the request
|
|
request.send(requestData || null);
|
|
});
|
|
});
|
|
|
|
/***/ }),
|
|
|
|
/***/ 1663:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var bind = __webpack_require__(2719);
|
|
var call = __webpack_require__(4978);
|
|
var anObject = __webpack_require__(6696);
|
|
var tryToString = __webpack_require__(9240);
|
|
var isArrayIteratorMethod = __webpack_require__(2348);
|
|
var lengthOfArrayLike = __webpack_require__(4231);
|
|
var isPrototypeOf = __webpack_require__(1856);
|
|
var getIterator = __webpack_require__(9700);
|
|
var getIteratorMethod = __webpack_require__(7312);
|
|
var iteratorClose = __webpack_require__(1298);
|
|
|
|
var $TypeError = TypeError;
|
|
|
|
var Result = function (stopped, result) {
|
|
this.stopped = stopped;
|
|
this.result = result;
|
|
};
|
|
|
|
var ResultPrototype = Result.prototype;
|
|
|
|
module.exports = function (iterable, unboundFunction, options) {
|
|
var that = options && options.that;
|
|
var AS_ENTRIES = !!(options && options.AS_ENTRIES);
|
|
var IS_RECORD = !!(options && options.IS_RECORD);
|
|
var IS_ITERATOR = !!(options && options.IS_ITERATOR);
|
|
var INTERRUPTED = !!(options && options.INTERRUPTED);
|
|
var fn = bind(unboundFunction, that);
|
|
var iterator, iterFn, index, length, result, next, step;
|
|
|
|
var stop = function (condition) {
|
|
if (iterator) iteratorClose(iterator, 'normal', condition);
|
|
return new Result(true, condition);
|
|
};
|
|
|
|
var callFn = function (value) {
|
|
if (AS_ENTRIES) {
|
|
anObject(value);
|
|
return INTERRUPTED ? fn(value[0], value[1], stop) : fn(value[0], value[1]);
|
|
} return INTERRUPTED ? fn(value, stop) : fn(value);
|
|
};
|
|
|
|
if (IS_RECORD) {
|
|
iterator = iterable.iterator;
|
|
} else if (IS_ITERATOR) {
|
|
iterator = iterable;
|
|
} else {
|
|
iterFn = getIteratorMethod(iterable);
|
|
if (!iterFn) throw new $TypeError(tryToString(iterable) + ' is not iterable');
|
|
// optimisation for array iterators
|
|
if (isArrayIteratorMethod(iterFn)) {
|
|
for (index = 0, length = lengthOfArrayLike(iterable); length > index; index++) {
|
|
result = callFn(iterable[index]);
|
|
if (result && isPrototypeOf(ResultPrototype, result)) return result;
|
|
} return new Result(false);
|
|
}
|
|
iterator = getIterator(iterable, iterFn);
|
|
}
|
|
|
|
next = IS_RECORD ? iterable.next : iterator.next;
|
|
while (!(step = call(next, iterator)).done) {
|
|
try {
|
|
result = callFn(step.value);
|
|
} catch (error) {
|
|
iteratorClose(iterator, 'throw', error);
|
|
}
|
|
if (typeof result == 'object' && result && isPrototypeOf(ResultPrototype, result)) return result;
|
|
} return new Result(false);
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 1694:
|
|
/***/ (function(__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) {
|
|
|
|
"use strict";
|
|
/* harmony import */ var core_js_modules_es_array_push_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(5513);
|
|
/* harmony import */ var core_js_modules_esnext_iterator_constructor_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(7195);
|
|
/* harmony import */ var core_js_modules_esnext_iterator_for_each_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(680);
|
|
/* harmony import */ var _utils_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(5813);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
class InterceptorManager {
|
|
constructor() {
|
|
this.handlers = [];
|
|
}
|
|
|
|
/**
|
|
* Add a new interceptor to the stack
|
|
*
|
|
* @param {Function} fulfilled The function to handle `then` for a `Promise`
|
|
* @param {Function} rejected The function to handle `reject` for a `Promise`
|
|
*
|
|
* @return {Number} An ID used to remove interceptor later
|
|
*/
|
|
use(fulfilled, rejected, options) {
|
|
this.handlers.push({
|
|
fulfilled,
|
|
rejected,
|
|
synchronous: options ? options.synchronous : false,
|
|
runWhen: options ? options.runWhen : null
|
|
});
|
|
return this.handlers.length - 1;
|
|
}
|
|
|
|
/**
|
|
* Remove an interceptor from the stack
|
|
*
|
|
* @param {Number} id The ID that was returned by `use`
|
|
*
|
|
* @returns {Boolean} `true` if the interceptor was removed, `false` otherwise
|
|
*/
|
|
eject(id) {
|
|
if (this.handlers[id]) {
|
|
this.handlers[id] = null;
|
|
}
|
|
}
|
|
|
|
/**
|
|
* Clear all interceptors from the stack
|
|
*
|
|
* @returns {void}
|
|
*/
|
|
clear() {
|
|
if (this.handlers) {
|
|
this.handlers = [];
|
|
}
|
|
}
|
|
|
|
/**
|
|
* Iterate over all the registered interceptors
|
|
*
|
|
* This method is particularly useful for skipping over any
|
|
* interceptors that may have become `null` calling `eject`.
|
|
*
|
|
* @param {Function} fn The function to call for each interceptor
|
|
*
|
|
* @returns {void}
|
|
*/
|
|
forEach(fn) {
|
|
_utils_js__WEBPACK_IMPORTED_MODULE_3__/* ["default"] */ .A.forEach(this.handlers, function forEachHandler(h) {
|
|
if (h !== null) {
|
|
fn(h);
|
|
}
|
|
});
|
|
}
|
|
}
|
|
/* harmony default export */ __webpack_exports__.A = (InterceptorManager);
|
|
|
|
/***/ }),
|
|
|
|
/***/ 1842:
|
|
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var arrayWith = __webpack_require__(6122);
|
|
var ArrayBufferViewCore = __webpack_require__(4257);
|
|
var isBigIntArray = __webpack_require__(9830);
|
|
var toIntegerOrInfinity = __webpack_require__(9106);
|
|
var toBigInt = __webpack_require__(323);
|
|
|
|
var aTypedArray = ArrayBufferViewCore.aTypedArray;
|
|
var getTypedArrayConstructor = ArrayBufferViewCore.getTypedArrayConstructor;
|
|
var exportTypedArrayMethod = ArrayBufferViewCore.exportTypedArrayMethod;
|
|
|
|
var PROPER_ORDER = !!function () {
|
|
try {
|
|
// eslint-disable-next-line no-throw-literal, es/no-typed-arrays, es/no-array-prototype-with -- required for testing
|
|
new Int8Array(1)['with'](2, { valueOf: function () { throw 8; } });
|
|
} catch (error) {
|
|
// some early implementations, like WebKit, does not follow the final semantic
|
|
// https://github.com/tc39/proposal-change-array-by-copy/pull/86
|
|
return error === 8;
|
|
}
|
|
}();
|
|
|
|
// `%TypedArray%.prototype.with` method
|
|
// https://tc39.es/ecma262/#sec-%typedarray%.prototype.with
|
|
exportTypedArrayMethod('with', { 'with': function (index, value) {
|
|
var O = aTypedArray(this);
|
|
var relativeIndex = toIntegerOrInfinity(index);
|
|
var actualValue = isBigIntArray(O) ? toBigInt(value) : +value;
|
|
return arrayWith(O, getTypedArrayConstructor(O), relativeIndex, actualValue);
|
|
} }['with'], !PROPER_ORDER);
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 1856:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var uncurryThis = __webpack_require__(1371);
|
|
|
|
module.exports = uncurryThis({}.isPrototypeOf);
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 1857:
|
|
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) {
|
|
|
|
"use strict";
|
|
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
/* harmony export */ D$: function() { return /* binding */ withModifiers; },
|
|
/* harmony export */ Ef: function() { return /* binding */ createApp; },
|
|
/* harmony export */ Jo: function() { return /* binding */ vModelText; },
|
|
/* harmony export */ jR: function() { return /* binding */ withKeys; },
|
|
/* harmony export */ u1: function() { return /* binding */ vModelSelect; }
|
|
/* harmony export */ });
|
|
/* unused harmony exports Transition, TransitionGroup, VueElement, createSSRApp, defineCustomElement, defineSSRCustomElement, hydrate, initDirectivesForSSR, render, useCssModule, useCssVars, useHost, useShadowRoot, vModelCheckbox, vModelDynamic, vModelRadio, vShow */
|
|
/* harmony import */ var core_js_modules_es_array_push_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(5513);
|
|
/* harmony import */ var core_js_modules_es_array_push_js__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_array_push_js__WEBPACK_IMPORTED_MODULE_0__);
|
|
/* harmony import */ var core_js_modules_esnext_iterator_constructor_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(7195);
|
|
/* harmony import */ var core_js_modules_esnext_iterator_constructor_js__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_esnext_iterator_constructor_js__WEBPACK_IMPORTED_MODULE_1__);
|
|
/* harmony import */ var core_js_modules_esnext_iterator_filter_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(3741);
|
|
/* harmony import */ var core_js_modules_esnext_iterator_filter_js__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_esnext_iterator_filter_js__WEBPACK_IMPORTED_MODULE_2__);
|
|
/* harmony import */ var core_js_modules_esnext_iterator_for_each_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(680);
|
|
/* harmony import */ var core_js_modules_esnext_iterator_for_each_js__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_esnext_iterator_for_each_js__WEBPACK_IMPORTED_MODULE_3__);
|
|
/* harmony import */ var core_js_modules_esnext_iterator_map_js__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(793);
|
|
/* harmony import */ var core_js_modules_esnext_iterator_map_js__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_esnext_iterator_map_js__WEBPACK_IMPORTED_MODULE_4__);
|
|
/* harmony import */ var core_js_modules_esnext_iterator_some_js__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(6071);
|
|
/* harmony import */ var core_js_modules_esnext_iterator_some_js__WEBPACK_IMPORTED_MODULE_5___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_esnext_iterator_some_js__WEBPACK_IMPORTED_MODULE_5__);
|
|
/* harmony import */ var core_js_modules_esnext_set_difference_v2_js__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(8438);
|
|
/* harmony import */ var core_js_modules_esnext_set_difference_v2_js__WEBPACK_IMPORTED_MODULE_6___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_esnext_set_difference_v2_js__WEBPACK_IMPORTED_MODULE_6__);
|
|
/* harmony import */ var core_js_modules_esnext_set_intersection_v2_js__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(6768);
|
|
/* harmony import */ var core_js_modules_esnext_set_intersection_v2_js__WEBPACK_IMPORTED_MODULE_7___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_esnext_set_intersection_v2_js__WEBPACK_IMPORTED_MODULE_7__);
|
|
/* harmony import */ var core_js_modules_esnext_set_is_disjoint_from_v2_js__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(2409);
|
|
/* harmony import */ var core_js_modules_esnext_set_is_disjoint_from_v2_js__WEBPACK_IMPORTED_MODULE_8___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_esnext_set_is_disjoint_from_v2_js__WEBPACK_IMPORTED_MODULE_8__);
|
|
/* harmony import */ var core_js_modules_esnext_set_is_subset_of_v2_js__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(9488);
|
|
/* harmony import */ var core_js_modules_esnext_set_is_subset_of_v2_js__WEBPACK_IMPORTED_MODULE_9___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_esnext_set_is_subset_of_v2_js__WEBPACK_IMPORTED_MODULE_9__);
|
|
/* harmony import */ var core_js_modules_esnext_set_is_superset_of_v2_js__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(6591);
|
|
/* harmony import */ var core_js_modules_esnext_set_is_superset_of_v2_js__WEBPACK_IMPORTED_MODULE_10___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_esnext_set_is_superset_of_v2_js__WEBPACK_IMPORTED_MODULE_10__);
|
|
/* harmony import */ var core_js_modules_esnext_set_symmetric_difference_v2_js__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(5412);
|
|
/* harmony import */ var core_js_modules_esnext_set_symmetric_difference_v2_js__WEBPACK_IMPORTED_MODULE_11___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_esnext_set_symmetric_difference_v2_js__WEBPACK_IMPORTED_MODULE_11__);
|
|
/* harmony import */ var core_js_modules_esnext_set_union_v2_js__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(9214);
|
|
/* harmony import */ var core_js_modules_esnext_set_union_v2_js__WEBPACK_IMPORTED_MODULE_12___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_esnext_set_union_v2_js__WEBPACK_IMPORTED_MODULE_12__);
|
|
/* harmony import */ var _vue_runtime_core__WEBPACK_IMPORTED_MODULE_14__ = __webpack_require__(4187);
|
|
/* harmony import */ var _vue_runtime_core__WEBPACK_IMPORTED_MODULE_15__ = __webpack_require__(4546);
|
|
/* harmony import */ var _vue_runtime_core__WEBPACK_IMPORTED_MODULE_16__ = __webpack_require__(7987);
|
|
/* harmony import */ var _vue_shared__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(7153);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
/**
|
|
* @vue/runtime-dom v3.5.13
|
|
* (c) 2018-present Yuxi (Evan) You and Vue contributors
|
|
* @license MIT
|
|
**/
|
|
|
|
|
|
|
|
let policy = void 0;
|
|
const tt = typeof window !== "undefined" && window.trustedTypes;
|
|
if (tt) {
|
|
try {
|
|
policy = /* @__PURE__ */tt.createPolicy("vue", {
|
|
createHTML: val => val
|
|
});
|
|
} catch (e) {
|
|
false && 0;
|
|
}
|
|
}
|
|
const unsafeToTrustedHTML = policy ? val => policy.createHTML(val) : val => val;
|
|
const svgNS = "http://www.w3.org/2000/svg";
|
|
const mathmlNS = "http://www.w3.org/1998/Math/MathML";
|
|
const doc = typeof document !== "undefined" ? document : null;
|
|
const templateContainer = doc && /* @__PURE__ */doc.createElement("template");
|
|
const nodeOps = {
|
|
insert: (child, parent, anchor) => {
|
|
parent.insertBefore(child, anchor || null);
|
|
},
|
|
remove: child => {
|
|
const parent = child.parentNode;
|
|
if (parent) {
|
|
parent.removeChild(child);
|
|
}
|
|
},
|
|
createElement: (tag, namespace, is, props) => {
|
|
const el = namespace === "svg" ? doc.createElementNS(svgNS, tag) : namespace === "mathml" ? doc.createElementNS(mathmlNS, tag) : is ? doc.createElement(tag, {
|
|
is
|
|
}) : doc.createElement(tag);
|
|
if (tag === "select" && props && props.multiple != null) {
|
|
el.setAttribute("multiple", props.multiple);
|
|
}
|
|
return el;
|
|
},
|
|
createText: text => doc.createTextNode(text),
|
|
createComment: text => doc.createComment(text),
|
|
setText: (node, text) => {
|
|
node.nodeValue = text;
|
|
},
|
|
setElementText: (el, text) => {
|
|
el.textContent = text;
|
|
},
|
|
parentNode: node => node.parentNode,
|
|
nextSibling: node => node.nextSibling,
|
|
querySelector: selector => doc.querySelector(selector),
|
|
setScopeId(el, id) {
|
|
el.setAttribute(id, "");
|
|
},
|
|
// __UNSAFE__
|
|
// Reason: innerHTML.
|
|
// Static content here can only come from compiled templates.
|
|
// As long as the user only uses trusted templates, this is safe.
|
|
insertStaticContent(content, parent, anchor, namespace, start, end) {
|
|
const before = anchor ? anchor.previousSibling : parent.lastChild;
|
|
if (start && (start === end || start.nextSibling)) {
|
|
while (true) {
|
|
parent.insertBefore(start.cloneNode(true), anchor);
|
|
if (start === end || !(start = start.nextSibling)) break;
|
|
}
|
|
} else {
|
|
templateContainer.innerHTML = unsafeToTrustedHTML(namespace === "svg" ? `<svg>${content}</svg>` : namespace === "mathml" ? `<math>${content}</math>` : content);
|
|
const template = templateContainer.content;
|
|
if (namespace === "svg" || namespace === "mathml") {
|
|
const wrapper = template.firstChild;
|
|
while (wrapper.firstChild) {
|
|
template.appendChild(wrapper.firstChild);
|
|
}
|
|
template.removeChild(wrapper);
|
|
}
|
|
parent.insertBefore(template, anchor);
|
|
}
|
|
return [
|
|
// first
|
|
before ? before.nextSibling : parent.firstChild,
|
|
// last
|
|
anchor ? anchor.previousSibling : parent.lastChild];
|
|
}
|
|
};
|
|
const TRANSITION = "transition";
|
|
const ANIMATION = "animation";
|
|
const vtcKey = Symbol("_vtc");
|
|
const DOMTransitionPropsValidators = {
|
|
name: String,
|
|
type: String,
|
|
css: {
|
|
type: Boolean,
|
|
default: true
|
|
},
|
|
duration: [String, Number, Object],
|
|
enterFromClass: String,
|
|
enterActiveClass: String,
|
|
enterToClass: String,
|
|
appearFromClass: String,
|
|
appearActiveClass: String,
|
|
appearToClass: String,
|
|
leaveFromClass: String,
|
|
leaveActiveClass: String,
|
|
leaveToClass: String
|
|
};
|
|
const TransitionPropsValidators = /* @__PURE__ */(0,_vue_shared__WEBPACK_IMPORTED_MODULE_13__/* .extend */ .X$)({}, _vue_runtime_core__WEBPACK_IMPORTED_MODULE_14__/* .BaseTransitionPropsValidators */ .QP, DOMTransitionPropsValidators);
|
|
const decorate$1 = t => {
|
|
t.displayName = "Transition";
|
|
t.props = TransitionPropsValidators;
|
|
return t;
|
|
};
|
|
const Transition = /* @__PURE__ */(/* unused pure expression or super */ null && (decorate$1((props, {
|
|
slots
|
|
}) => h(BaseTransition, resolveTransitionProps(props), slots))));
|
|
const callHook = (hook, args = []) => {
|
|
if ((0,_vue_shared__WEBPACK_IMPORTED_MODULE_13__/* .isArray */ .cy)(hook)) {
|
|
hook.forEach(h2 => h2(...args));
|
|
} else if (hook) {
|
|
hook(...args);
|
|
}
|
|
};
|
|
const hasExplicitCallback = hook => {
|
|
return hook ? (0,_vue_shared__WEBPACK_IMPORTED_MODULE_13__/* .isArray */ .cy)(hook) ? hook.some(h2 => h2.length > 1) : hook.length > 1 : false;
|
|
};
|
|
function resolveTransitionProps(rawProps) {
|
|
const baseProps = {};
|
|
for (const key in rawProps) {
|
|
if (!(key in DOMTransitionPropsValidators)) {
|
|
baseProps[key] = rawProps[key];
|
|
}
|
|
}
|
|
if (rawProps.css === false) {
|
|
return baseProps;
|
|
}
|
|
const {
|
|
name = "v",
|
|
type,
|
|
duration,
|
|
enterFromClass = `${name}-enter-from`,
|
|
enterActiveClass = `${name}-enter-active`,
|
|
enterToClass = `${name}-enter-to`,
|
|
appearFromClass = enterFromClass,
|
|
appearActiveClass = enterActiveClass,
|
|
appearToClass = enterToClass,
|
|
leaveFromClass = `${name}-leave-from`,
|
|
leaveActiveClass = `${name}-leave-active`,
|
|
leaveToClass = `${name}-leave-to`
|
|
} = rawProps;
|
|
const durations = normalizeDuration(duration);
|
|
const enterDuration = durations && durations[0];
|
|
const leaveDuration = durations && durations[1];
|
|
const {
|
|
onBeforeEnter,
|
|
onEnter,
|
|
onEnterCancelled,
|
|
onLeave,
|
|
onLeaveCancelled,
|
|
onBeforeAppear = onBeforeEnter,
|
|
onAppear = onEnter,
|
|
onAppearCancelled = onEnterCancelled
|
|
} = baseProps;
|
|
const finishEnter = (el, isAppear, done, isCancelled) => {
|
|
el._enterCancelled = isCancelled;
|
|
removeTransitionClass(el, isAppear ? appearToClass : enterToClass);
|
|
removeTransitionClass(el, isAppear ? appearActiveClass : enterActiveClass);
|
|
done && done();
|
|
};
|
|
const finishLeave = (el, done) => {
|
|
el._isLeaving = false;
|
|
removeTransitionClass(el, leaveFromClass);
|
|
removeTransitionClass(el, leaveToClass);
|
|
removeTransitionClass(el, leaveActiveClass);
|
|
done && done();
|
|
};
|
|
const makeEnterHook = isAppear => {
|
|
return (el, done) => {
|
|
const hook = isAppear ? onAppear : onEnter;
|
|
const resolve = () => finishEnter(el, isAppear, done);
|
|
callHook(hook, [el, resolve]);
|
|
nextFrame(() => {
|
|
removeTransitionClass(el, isAppear ? appearFromClass : enterFromClass);
|
|
addTransitionClass(el, isAppear ? appearToClass : enterToClass);
|
|
if (!hasExplicitCallback(hook)) {
|
|
whenTransitionEnds(el, type, enterDuration, resolve);
|
|
}
|
|
});
|
|
};
|
|
};
|
|
return (0,_vue_shared__WEBPACK_IMPORTED_MODULE_13__/* .extend */ .X$)(baseProps, {
|
|
onBeforeEnter(el) {
|
|
callHook(onBeforeEnter, [el]);
|
|
addTransitionClass(el, enterFromClass);
|
|
addTransitionClass(el, enterActiveClass);
|
|
},
|
|
onBeforeAppear(el) {
|
|
callHook(onBeforeAppear, [el]);
|
|
addTransitionClass(el, appearFromClass);
|
|
addTransitionClass(el, appearActiveClass);
|
|
},
|
|
onEnter: makeEnterHook(false),
|
|
onAppear: makeEnterHook(true),
|
|
onLeave(el, done) {
|
|
el._isLeaving = true;
|
|
const resolve = () => finishLeave(el, done);
|
|
addTransitionClass(el, leaveFromClass);
|
|
if (!el._enterCancelled) {
|
|
forceReflow();
|
|
addTransitionClass(el, leaveActiveClass);
|
|
} else {
|
|
addTransitionClass(el, leaveActiveClass);
|
|
forceReflow();
|
|
}
|
|
nextFrame(() => {
|
|
if (!el._isLeaving) {
|
|
return;
|
|
}
|
|
removeTransitionClass(el, leaveFromClass);
|
|
addTransitionClass(el, leaveToClass);
|
|
if (!hasExplicitCallback(onLeave)) {
|
|
whenTransitionEnds(el, type, leaveDuration, resolve);
|
|
}
|
|
});
|
|
callHook(onLeave, [el, resolve]);
|
|
},
|
|
onEnterCancelled(el) {
|
|
finishEnter(el, false, void 0, true);
|
|
callHook(onEnterCancelled, [el]);
|
|
},
|
|
onAppearCancelled(el) {
|
|
finishEnter(el, true, void 0, true);
|
|
callHook(onAppearCancelled, [el]);
|
|
},
|
|
onLeaveCancelled(el) {
|
|
finishLeave(el);
|
|
callHook(onLeaveCancelled, [el]);
|
|
}
|
|
});
|
|
}
|
|
function normalizeDuration(duration) {
|
|
if (duration == null) {
|
|
return null;
|
|
} else if ((0,_vue_shared__WEBPACK_IMPORTED_MODULE_13__/* .isObject */ .Gv)(duration)) {
|
|
return [NumberOf(duration.enter), NumberOf(duration.leave)];
|
|
} else {
|
|
const n = NumberOf(duration);
|
|
return [n, n];
|
|
}
|
|
}
|
|
function NumberOf(val) {
|
|
const res = (0,_vue_shared__WEBPACK_IMPORTED_MODULE_13__/* .toNumber */ .Ro)(val);
|
|
if (false) {}
|
|
return res;
|
|
}
|
|
function addTransitionClass(el, cls) {
|
|
cls.split(/\s+/).forEach(c => c && el.classList.add(c));
|
|
(el[vtcKey] || (el[vtcKey] = /* @__PURE__ */new Set())).add(cls);
|
|
}
|
|
function removeTransitionClass(el, cls) {
|
|
cls.split(/\s+/).forEach(c => c && el.classList.remove(c));
|
|
const _vtc = el[vtcKey];
|
|
if (_vtc) {
|
|
_vtc.delete(cls);
|
|
if (!_vtc.size) {
|
|
el[vtcKey] = void 0;
|
|
}
|
|
}
|
|
}
|
|
function nextFrame(cb) {
|
|
requestAnimationFrame(() => {
|
|
requestAnimationFrame(cb);
|
|
});
|
|
}
|
|
let endId = 0;
|
|
function whenTransitionEnds(el, expectedType, explicitTimeout, resolve) {
|
|
const id = el._endId = ++endId;
|
|
const resolveIfNotStale = () => {
|
|
if (id === el._endId) {
|
|
resolve();
|
|
}
|
|
};
|
|
if (explicitTimeout != null) {
|
|
return setTimeout(resolveIfNotStale, explicitTimeout);
|
|
}
|
|
const {
|
|
type,
|
|
timeout,
|
|
propCount
|
|
} = getTransitionInfo(el, expectedType);
|
|
if (!type) {
|
|
return resolve();
|
|
}
|
|
const endEvent = type + "end";
|
|
let ended = 0;
|
|
const end = () => {
|
|
el.removeEventListener(endEvent, onEnd);
|
|
resolveIfNotStale();
|
|
};
|
|
const onEnd = e => {
|
|
if (e.target === el && ++ended >= propCount) {
|
|
end();
|
|
}
|
|
};
|
|
setTimeout(() => {
|
|
if (ended < propCount) {
|
|
end();
|
|
}
|
|
}, timeout + 1);
|
|
el.addEventListener(endEvent, onEnd);
|
|
}
|
|
function getTransitionInfo(el, expectedType) {
|
|
const styles = window.getComputedStyle(el);
|
|
const getStyleProperties = key => (styles[key] || "").split(", ");
|
|
const transitionDelays = getStyleProperties(`${TRANSITION}Delay`);
|
|
const transitionDurations = getStyleProperties(`${TRANSITION}Duration`);
|
|
const transitionTimeout = getTimeout(transitionDelays, transitionDurations);
|
|
const animationDelays = getStyleProperties(`${ANIMATION}Delay`);
|
|
const animationDurations = getStyleProperties(`${ANIMATION}Duration`);
|
|
const animationTimeout = getTimeout(animationDelays, animationDurations);
|
|
let type = null;
|
|
let timeout = 0;
|
|
let propCount = 0;
|
|
if (expectedType === TRANSITION) {
|
|
if (transitionTimeout > 0) {
|
|
type = TRANSITION;
|
|
timeout = transitionTimeout;
|
|
propCount = transitionDurations.length;
|
|
}
|
|
} else if (expectedType === ANIMATION) {
|
|
if (animationTimeout > 0) {
|
|
type = ANIMATION;
|
|
timeout = animationTimeout;
|
|
propCount = animationDurations.length;
|
|
}
|
|
} else {
|
|
timeout = Math.max(transitionTimeout, animationTimeout);
|
|
type = timeout > 0 ? transitionTimeout > animationTimeout ? TRANSITION : ANIMATION : null;
|
|
propCount = type ? type === TRANSITION ? transitionDurations.length : animationDurations.length : 0;
|
|
}
|
|
const hasTransform = type === TRANSITION && /\b(transform|all)(,|$)/.test(getStyleProperties(`${TRANSITION}Property`).toString());
|
|
return {
|
|
type,
|
|
timeout,
|
|
propCount,
|
|
hasTransform
|
|
};
|
|
}
|
|
function getTimeout(delays, durations) {
|
|
while (delays.length < durations.length) {
|
|
delays = delays.concat(delays);
|
|
}
|
|
return Math.max(...durations.map((d, i) => toMs(d) + toMs(delays[i])));
|
|
}
|
|
function toMs(s) {
|
|
if (s === "auto") return 0;
|
|
return Number(s.slice(0, -1).replace(",", ".")) * 1e3;
|
|
}
|
|
function forceReflow() {
|
|
return document.body.offsetHeight;
|
|
}
|
|
function patchClass(el, value, isSVG) {
|
|
const transitionClasses = el[vtcKey];
|
|
if (transitionClasses) {
|
|
value = (value ? [value, ...transitionClasses] : [...transitionClasses]).join(" ");
|
|
}
|
|
if (value == null) {
|
|
el.removeAttribute("class");
|
|
} else if (isSVG) {
|
|
el.setAttribute("class", value);
|
|
} else {
|
|
el.className = value;
|
|
}
|
|
}
|
|
const vShowOriginalDisplay = Symbol("_vod");
|
|
const vShowHidden = Symbol("_vsh");
|
|
const vShow = {
|
|
beforeMount(el, {
|
|
value
|
|
}, {
|
|
transition
|
|
}) {
|
|
el[vShowOriginalDisplay] = el.style.display === "none" ? "" : el.style.display;
|
|
if (transition && value) {
|
|
transition.beforeEnter(el);
|
|
} else {
|
|
setDisplay(el, value);
|
|
}
|
|
},
|
|
mounted(el, {
|
|
value
|
|
}, {
|
|
transition
|
|
}) {
|
|
if (transition && value) {
|
|
transition.enter(el);
|
|
}
|
|
},
|
|
updated(el, {
|
|
value,
|
|
oldValue
|
|
}, {
|
|
transition
|
|
}) {
|
|
if (!value === !oldValue) return;
|
|
if (transition) {
|
|
if (value) {
|
|
transition.beforeEnter(el);
|
|
setDisplay(el, true);
|
|
transition.enter(el);
|
|
} else {
|
|
transition.leave(el, () => {
|
|
setDisplay(el, false);
|
|
});
|
|
}
|
|
} else {
|
|
setDisplay(el, value);
|
|
}
|
|
},
|
|
beforeUnmount(el, {
|
|
value
|
|
}) {
|
|
setDisplay(el, value);
|
|
}
|
|
};
|
|
if (false) {}
|
|
function setDisplay(el, value) {
|
|
el.style.display = value ? el[vShowOriginalDisplay] : "none";
|
|
el[vShowHidden] = !value;
|
|
}
|
|
function initVShowForSSR() {
|
|
vShow.getSSRProps = ({
|
|
value
|
|
}) => {
|
|
if (!value) {
|
|
return {
|
|
style: {
|
|
display: "none"
|
|
}
|
|
};
|
|
}
|
|
};
|
|
}
|
|
const CSS_VAR_TEXT = Symbol( false ? 0 : "");
|
|
function useCssVars(getter) {
|
|
const instance = getCurrentInstance();
|
|
if (!instance) {
|
|
false && 0;
|
|
return;
|
|
}
|
|
const updateTeleports = instance.ut = (vars = getter(instance.proxy)) => {
|
|
Array.from(document.querySelectorAll(`[data-v-owner="${instance.uid}"]`)).forEach(node => setVarsOnNode(node, vars));
|
|
};
|
|
if (false) {}
|
|
const setVars = () => {
|
|
const vars = getter(instance.proxy);
|
|
if (instance.ce) {
|
|
setVarsOnNode(instance.ce, vars);
|
|
} else {
|
|
setVarsOnVNode(instance.subTree, vars);
|
|
}
|
|
updateTeleports(vars);
|
|
};
|
|
onBeforeUpdate(() => {
|
|
queuePostFlushCb(setVars);
|
|
});
|
|
onMounted(() => {
|
|
watch(setVars, NOOP, {
|
|
flush: "post"
|
|
});
|
|
const ob = new MutationObserver(setVars);
|
|
ob.observe(instance.subTree.el.parentNode, {
|
|
childList: true
|
|
});
|
|
onUnmounted(() => ob.disconnect());
|
|
});
|
|
}
|
|
function setVarsOnVNode(vnode, vars) {
|
|
if (vnode.shapeFlag & 128) {
|
|
const suspense = vnode.suspense;
|
|
vnode = suspense.activeBranch;
|
|
if (suspense.pendingBranch && !suspense.isHydrating) {
|
|
suspense.effects.push(() => {
|
|
setVarsOnVNode(suspense.activeBranch, vars);
|
|
});
|
|
}
|
|
}
|
|
while (vnode.component) {
|
|
vnode = vnode.component.subTree;
|
|
}
|
|
if (vnode.shapeFlag & 1 && vnode.el) {
|
|
setVarsOnNode(vnode.el, vars);
|
|
} else if (vnode.type === Fragment) {
|
|
vnode.children.forEach(c => setVarsOnVNode(c, vars));
|
|
} else if (vnode.type === Static) {
|
|
let {
|
|
el,
|
|
anchor
|
|
} = vnode;
|
|
while (el) {
|
|
setVarsOnNode(el, vars);
|
|
if (el === anchor) break;
|
|
el = el.nextSibling;
|
|
}
|
|
}
|
|
}
|
|
function setVarsOnNode(el, vars) {
|
|
if (el.nodeType === 1) {
|
|
const style = el.style;
|
|
let cssText = "";
|
|
for (const key in vars) {
|
|
style.setProperty(`--${key}`, vars[key]);
|
|
cssText += `--${key}: ${vars[key]};`;
|
|
}
|
|
style[CSS_VAR_TEXT] = cssText;
|
|
}
|
|
}
|
|
const displayRE = /(^|;)\s*display\s*:/;
|
|
function patchStyle(el, prev, next) {
|
|
const style = el.style;
|
|
const isCssString = (0,_vue_shared__WEBPACK_IMPORTED_MODULE_13__/* .isString */ .Kg)(next);
|
|
let hasControlledDisplay = false;
|
|
if (next && !isCssString) {
|
|
if (prev) {
|
|
if (!(0,_vue_shared__WEBPACK_IMPORTED_MODULE_13__/* .isString */ .Kg)(prev)) {
|
|
for (const key in prev) {
|
|
if (next[key] == null) {
|
|
setStyle(style, key, "");
|
|
}
|
|
}
|
|
} else {
|
|
for (const prevStyle of prev.split(";")) {
|
|
const key = prevStyle.slice(0, prevStyle.indexOf(":")).trim();
|
|
if (next[key] == null) {
|
|
setStyle(style, key, "");
|
|
}
|
|
}
|
|
}
|
|
}
|
|
for (const key in next) {
|
|
if (key === "display") {
|
|
hasControlledDisplay = true;
|
|
}
|
|
setStyle(style, key, next[key]);
|
|
}
|
|
} else {
|
|
if (isCssString) {
|
|
if (prev !== next) {
|
|
const cssVarText = style[CSS_VAR_TEXT];
|
|
if (cssVarText) {
|
|
next += ";" + cssVarText;
|
|
}
|
|
style.cssText = next;
|
|
hasControlledDisplay = displayRE.test(next);
|
|
}
|
|
} else if (prev) {
|
|
el.removeAttribute("style");
|
|
}
|
|
}
|
|
if (vShowOriginalDisplay in el) {
|
|
el[vShowOriginalDisplay] = hasControlledDisplay ? style.display : "";
|
|
if (el[vShowHidden]) {
|
|
style.display = "none";
|
|
}
|
|
}
|
|
}
|
|
const semicolonRE = /[^\\];\s*$/;
|
|
const importantRE = /\s*!important$/;
|
|
function setStyle(style, name, val) {
|
|
if ((0,_vue_shared__WEBPACK_IMPORTED_MODULE_13__/* .isArray */ .cy)(val)) {
|
|
val.forEach(v => setStyle(style, name, v));
|
|
} else {
|
|
if (val == null) val = "";
|
|
if (false) {}
|
|
if (name.startsWith("--")) {
|
|
style.setProperty(name, val);
|
|
} else {
|
|
const prefixed = autoPrefix(style, name);
|
|
if (importantRE.test(val)) {
|
|
style.setProperty((0,_vue_shared__WEBPACK_IMPORTED_MODULE_13__/* .hyphenate */ .Tg)(prefixed), val.replace(importantRE, ""), "important");
|
|
} else {
|
|
style[prefixed] = val;
|
|
}
|
|
}
|
|
}
|
|
}
|
|
const prefixes = ["Webkit", "Moz", "ms"];
|
|
const prefixCache = {};
|
|
function autoPrefix(style, rawName) {
|
|
const cached = prefixCache[rawName];
|
|
if (cached) {
|
|
return cached;
|
|
}
|
|
let name = (0,_vue_runtime_core__WEBPACK_IMPORTED_MODULE_15__/* .camelize */ .PT)(rawName);
|
|
if (name !== "filter" && name in style) {
|
|
return prefixCache[rawName] = name;
|
|
}
|
|
name = (0,_vue_shared__WEBPACK_IMPORTED_MODULE_13__/* .capitalize */ .ZH)(name);
|
|
for (let i = 0; i < prefixes.length; i++) {
|
|
const prefixed = prefixes[i] + name;
|
|
if (prefixed in style) {
|
|
return prefixCache[rawName] = prefixed;
|
|
}
|
|
}
|
|
return rawName;
|
|
}
|
|
const xlinkNS = "http://www.w3.org/1999/xlink";
|
|
function patchAttr(el, key, value, isSVG, instance, isBoolean = (0,_vue_shared__WEBPACK_IMPORTED_MODULE_13__/* .isSpecialBooleanAttr */ .J$)(key)) {
|
|
if (isSVG && key.startsWith("xlink:")) {
|
|
if (value == null) {
|
|
el.removeAttributeNS(xlinkNS, key.slice(6, key.length));
|
|
} else {
|
|
el.setAttributeNS(xlinkNS, key, value);
|
|
}
|
|
} else {
|
|
if (value == null || isBoolean && !(0,_vue_shared__WEBPACK_IMPORTED_MODULE_13__/* .includeBooleanAttr */ .Y2)(value)) {
|
|
el.removeAttribute(key);
|
|
} else {
|
|
el.setAttribute(key, isBoolean ? "" : (0,_vue_shared__WEBPACK_IMPORTED_MODULE_13__/* .isSymbol */ .Bm)(value) ? String(value) : value);
|
|
}
|
|
}
|
|
}
|
|
function patchDOMProp(el, key, value, parentComponent, attrName) {
|
|
if (key === "innerHTML" || key === "textContent") {
|
|
if (value != null) {
|
|
el[key] = key === "innerHTML" ? unsafeToTrustedHTML(value) : value;
|
|
}
|
|
return;
|
|
}
|
|
const tag = el.tagName;
|
|
if (key === "value" && tag !== "PROGRESS" &&
|
|
// custom elements may use _value internally
|
|
!tag.includes("-")) {
|
|
const oldValue = tag === "OPTION" ? el.getAttribute("value") || "" : el.value;
|
|
const newValue = value == null ?
|
|
// #11647: value should be set as empty string for null and undefined,
|
|
// but <input type="checkbox"> should be set as 'on'.
|
|
el.type === "checkbox" ? "on" : "" : String(value);
|
|
if (oldValue !== newValue || !("_value" in el)) {
|
|
el.value = newValue;
|
|
}
|
|
if (value == null) {
|
|
el.removeAttribute(key);
|
|
}
|
|
el._value = value;
|
|
return;
|
|
}
|
|
let needRemove = false;
|
|
if (value === "" || value == null) {
|
|
const type = typeof el[key];
|
|
if (type === "boolean") {
|
|
value = (0,_vue_shared__WEBPACK_IMPORTED_MODULE_13__/* .includeBooleanAttr */ .Y2)(value);
|
|
} else if (value == null && type === "string") {
|
|
value = "";
|
|
needRemove = true;
|
|
} else if (type === "number") {
|
|
value = 0;
|
|
needRemove = true;
|
|
}
|
|
}
|
|
try {
|
|
el[key] = value;
|
|
} catch (e) {
|
|
if (false) {}
|
|
}
|
|
needRemove && el.removeAttribute(attrName || key);
|
|
}
|
|
function addEventListener(el, event, handler, options) {
|
|
el.addEventListener(event, handler, options);
|
|
}
|
|
function removeEventListener(el, event, handler, options) {
|
|
el.removeEventListener(event, handler, options);
|
|
}
|
|
const veiKey = Symbol("_vei");
|
|
function patchEvent(el, rawName, prevValue, nextValue, instance = null) {
|
|
const invokers = el[veiKey] || (el[veiKey] = {});
|
|
const existingInvoker = invokers[rawName];
|
|
if (nextValue && existingInvoker) {
|
|
existingInvoker.value = false ? 0 : nextValue;
|
|
} else {
|
|
const [name, options] = parseName(rawName);
|
|
if (nextValue) {
|
|
const invoker = invokers[rawName] = createInvoker( false ? 0 : nextValue, instance);
|
|
addEventListener(el, name, invoker, options);
|
|
} else if (existingInvoker) {
|
|
removeEventListener(el, name, existingInvoker, options);
|
|
invokers[rawName] = void 0;
|
|
}
|
|
}
|
|
}
|
|
const optionsModifierRE = /(?:Once|Passive|Capture)$/;
|
|
function parseName(name) {
|
|
let options;
|
|
if (optionsModifierRE.test(name)) {
|
|
options = {};
|
|
let m;
|
|
while (m = name.match(optionsModifierRE)) {
|
|
name = name.slice(0, name.length - m[0].length);
|
|
options[m[0].toLowerCase()] = true;
|
|
}
|
|
}
|
|
const event = name[2] === ":" ? name.slice(3) : (0,_vue_shared__WEBPACK_IMPORTED_MODULE_13__/* .hyphenate */ .Tg)(name.slice(2));
|
|
return [event, options];
|
|
}
|
|
let cachedNow = 0;
|
|
const p = /* @__PURE__ */Promise.resolve();
|
|
const getNow = () => cachedNow || (p.then(() => cachedNow = 0), cachedNow = Date.now());
|
|
function createInvoker(initialValue, instance) {
|
|
const invoker = e => {
|
|
if (!e._vts) {
|
|
e._vts = Date.now();
|
|
} else if (e._vts <= invoker.attached) {
|
|
return;
|
|
}
|
|
(0,_vue_runtime_core__WEBPACK_IMPORTED_MODULE_14__/* .callWithAsyncErrorHandling */ .qL)(patchStopImmediatePropagation(e, invoker.value), instance, 5, [e]);
|
|
};
|
|
invoker.value = initialValue;
|
|
invoker.attached = getNow();
|
|
return invoker;
|
|
}
|
|
function sanitizeEventValue(value, propName) {
|
|
if (isFunction(value) || isArray(value)) {
|
|
return value;
|
|
}
|
|
warn(`Wrong type passed as event handler to ${propName} - did you forget @ or : in front of your prop?
|
|
Expected function or array of functions, received type ${typeof value}.`);
|
|
return NOOP;
|
|
}
|
|
function patchStopImmediatePropagation(e, value) {
|
|
if ((0,_vue_shared__WEBPACK_IMPORTED_MODULE_13__/* .isArray */ .cy)(value)) {
|
|
const originalStop = e.stopImmediatePropagation;
|
|
e.stopImmediatePropagation = () => {
|
|
originalStop.call(e);
|
|
e._stopped = true;
|
|
};
|
|
return value.map(fn => e2 => !e2._stopped && fn && fn(e2));
|
|
} else {
|
|
return value;
|
|
}
|
|
}
|
|
const isNativeOn = key => key.charCodeAt(0) === 111 && key.charCodeAt(1) === 110 &&
|
|
// lowercase letter
|
|
key.charCodeAt(2) > 96 && key.charCodeAt(2) < 123;
|
|
const patchProp = (el, key, prevValue, nextValue, namespace, parentComponent) => {
|
|
const isSVG = namespace === "svg";
|
|
if (key === "class") {
|
|
patchClass(el, nextValue, isSVG);
|
|
} else if (key === "style") {
|
|
patchStyle(el, prevValue, nextValue);
|
|
} else if ((0,_vue_shared__WEBPACK_IMPORTED_MODULE_13__/* .isOn */ .Mp)(key)) {
|
|
if (!(0,_vue_shared__WEBPACK_IMPORTED_MODULE_13__/* .isModelListener */ .CP)(key)) {
|
|
patchEvent(el, key, prevValue, nextValue, parentComponent);
|
|
}
|
|
} else if (key[0] === "." ? (key = key.slice(1), true) : key[0] === "^" ? (key = key.slice(1), false) : shouldSetAsProp(el, key, nextValue, isSVG)) {
|
|
patchDOMProp(el, key, nextValue);
|
|
if (!el.tagName.includes("-") && (key === "value" || key === "checked" || key === "selected")) {
|
|
patchAttr(el, key, nextValue, isSVG, parentComponent, key !== "value");
|
|
}
|
|
} else if (
|
|
// #11081 force set props for possible async custom element
|
|
el._isVueCE && (/[A-Z]/.test(key) || !(0,_vue_shared__WEBPACK_IMPORTED_MODULE_13__/* .isString */ .Kg)(nextValue))) {
|
|
patchDOMProp(el, (0,_vue_shared__WEBPACK_IMPORTED_MODULE_13__/* .camelize */ .PT)(key), nextValue, parentComponent, key);
|
|
} else {
|
|
if (key === "true-value") {
|
|
el._trueValue = nextValue;
|
|
} else if (key === "false-value") {
|
|
el._falseValue = nextValue;
|
|
}
|
|
patchAttr(el, key, nextValue, isSVG);
|
|
}
|
|
};
|
|
function shouldSetAsProp(el, key, value, isSVG) {
|
|
if (isSVG) {
|
|
if (key === "innerHTML" || key === "textContent") {
|
|
return true;
|
|
}
|
|
if (key in el && isNativeOn(key) && (0,_vue_shared__WEBPACK_IMPORTED_MODULE_13__/* .isFunction */ .Tn)(value)) {
|
|
return true;
|
|
}
|
|
return false;
|
|
}
|
|
if (key === "spellcheck" || key === "draggable" || key === "translate") {
|
|
return false;
|
|
}
|
|
if (key === "form") {
|
|
return false;
|
|
}
|
|
if (key === "list" && el.tagName === "INPUT") {
|
|
return false;
|
|
}
|
|
if (key === "type" && el.tagName === "TEXTAREA") {
|
|
return false;
|
|
}
|
|
if (key === "width" || key === "height") {
|
|
const tag = el.tagName;
|
|
if (tag === "IMG" || tag === "VIDEO" || tag === "CANVAS" || tag === "SOURCE") {
|
|
return false;
|
|
}
|
|
}
|
|
if (isNativeOn(key) && (0,_vue_shared__WEBPACK_IMPORTED_MODULE_13__/* .isString */ .Kg)(value)) {
|
|
return false;
|
|
}
|
|
return key in el;
|
|
}
|
|
const REMOVAL = {};
|
|
/*! #__NO_SIDE_EFFECTS__ */
|
|
// @__NO_SIDE_EFFECTS__
|
|
function defineCustomElement(options, extraOptions, _createApp) {
|
|
const Comp = defineComponent(options, extraOptions);
|
|
if (isPlainObject(Comp)) extend(Comp, extraOptions);
|
|
class VueCustomElement extends VueElement {
|
|
constructor(initialProps) {
|
|
super(Comp, initialProps, _createApp);
|
|
}
|
|
}
|
|
VueCustomElement.def = Comp;
|
|
return VueCustomElement;
|
|
}
|
|
/*! #__NO_SIDE_EFFECTS__ */
|
|
const defineSSRCustomElement = /* @__NO_SIDE_EFFECTS__ */(options, extraOptions) => {
|
|
return /* @__PURE__ */defineCustomElement(options, extraOptions, createSSRApp);
|
|
};
|
|
const BaseClass = typeof HTMLElement !== "undefined" ? HTMLElement : class {};
|
|
class VueElement extends BaseClass {
|
|
constructor(_def, _props = {}, _createApp = createApp) {
|
|
super();
|
|
this._def = _def;
|
|
this._props = _props;
|
|
this._createApp = _createApp;
|
|
this._isVueCE = true;
|
|
/**
|
|
* @internal
|
|
*/
|
|
this._instance = null;
|
|
/**
|
|
* @internal
|
|
*/
|
|
this._app = null;
|
|
/**
|
|
* @internal
|
|
*/
|
|
this._nonce = this._def.nonce;
|
|
this._connected = false;
|
|
this._resolved = false;
|
|
this._numberProps = null;
|
|
this._styleChildren = /* @__PURE__ */new WeakSet();
|
|
this._ob = null;
|
|
if (this.shadowRoot && _createApp !== createApp) {
|
|
this._root = this.shadowRoot;
|
|
} else {
|
|
if (false) {}
|
|
if (_def.shadowRoot !== false) {
|
|
this.attachShadow({
|
|
mode: "open"
|
|
});
|
|
this._root = this.shadowRoot;
|
|
} else {
|
|
this._root = this;
|
|
}
|
|
}
|
|
if (!this._def.__asyncLoader) {
|
|
this._resolveProps(this._def);
|
|
}
|
|
}
|
|
connectedCallback() {
|
|
if (!this.isConnected) return;
|
|
if (!this.shadowRoot) {
|
|
this._parseSlots();
|
|
}
|
|
this._connected = true;
|
|
let parent = this;
|
|
while (parent = parent && (parent.parentNode || parent.host)) {
|
|
if (parent instanceof VueElement) {
|
|
this._parent = parent;
|
|
break;
|
|
}
|
|
}
|
|
if (!this._instance) {
|
|
if (this._resolved) {
|
|
this._setParent();
|
|
this._update();
|
|
} else {
|
|
if (parent && parent._pendingResolve) {
|
|
this._pendingResolve = parent._pendingResolve.then(() => {
|
|
this._pendingResolve = void 0;
|
|
this._resolveDef();
|
|
});
|
|
} else {
|
|
this._resolveDef();
|
|
}
|
|
}
|
|
}
|
|
}
|
|
_setParent(parent = this._parent) {
|
|
if (parent) {
|
|
this._instance.parent = parent._instance;
|
|
this._instance.provides = parent._instance.provides;
|
|
}
|
|
}
|
|
disconnectedCallback() {
|
|
this._connected = false;
|
|
(0,_vue_runtime_core__WEBPACK_IMPORTED_MODULE_14__/* .nextTick */ .dY)(() => {
|
|
if (!this._connected) {
|
|
if (this._ob) {
|
|
this._ob.disconnect();
|
|
this._ob = null;
|
|
}
|
|
this._app && this._app.unmount();
|
|
if (this._instance) this._instance.ce = void 0;
|
|
this._app = this._instance = null;
|
|
}
|
|
});
|
|
}
|
|
/**
|
|
* resolve inner component definition (handle possible async component)
|
|
*/
|
|
_resolveDef() {
|
|
if (this._pendingResolve) {
|
|
return;
|
|
}
|
|
for (let i = 0; i < this.attributes.length; i++) {
|
|
this._setAttr(this.attributes[i].name);
|
|
}
|
|
this._ob = new MutationObserver(mutations => {
|
|
for (const m of mutations) {
|
|
this._setAttr(m.attributeName);
|
|
}
|
|
});
|
|
this._ob.observe(this, {
|
|
attributes: true
|
|
});
|
|
const resolve = (def, isAsync = false) => {
|
|
this._resolved = true;
|
|
this._pendingResolve = void 0;
|
|
const {
|
|
props,
|
|
styles
|
|
} = def;
|
|
let numberProps;
|
|
if (props && !(0,_vue_shared__WEBPACK_IMPORTED_MODULE_13__/* .isArray */ .cy)(props)) {
|
|
for (const key in props) {
|
|
const opt = props[key];
|
|
if (opt === Number || opt && opt.type === Number) {
|
|
if (key in this._props) {
|
|
this._props[key] = (0,_vue_shared__WEBPACK_IMPORTED_MODULE_13__/* .toNumber */ .Ro)(this._props[key]);
|
|
}
|
|
(numberProps || (numberProps = /* @__PURE__ */Object.create(null)))[(0,_vue_shared__WEBPACK_IMPORTED_MODULE_13__/* .camelize */ .PT)(key)] = true;
|
|
}
|
|
}
|
|
}
|
|
this._numberProps = numberProps;
|
|
if (isAsync) {
|
|
this._resolveProps(def);
|
|
}
|
|
if (this.shadowRoot) {
|
|
this._applyStyles(styles);
|
|
} else if (false) {}
|
|
this._mount(def);
|
|
};
|
|
const asyncDef = this._def.__asyncLoader;
|
|
if (asyncDef) {
|
|
this._pendingResolve = asyncDef().then(def => resolve(this._def = def, true));
|
|
} else {
|
|
resolve(this._def);
|
|
}
|
|
}
|
|
_mount(def) {
|
|
if (false) {}
|
|
this._app = this._createApp(def);
|
|
if (def.configureApp) {
|
|
def.configureApp(this._app);
|
|
}
|
|
this._app._ceVNode = this._createVNode();
|
|
this._app.mount(this._root);
|
|
const exposed = this._instance && this._instance.exposed;
|
|
if (!exposed) return;
|
|
for (const key in exposed) {
|
|
if (!(0,_vue_shared__WEBPACK_IMPORTED_MODULE_13__/* .hasOwn */ .$3)(this, key)) {
|
|
Object.defineProperty(this, key, {
|
|
// unwrap ref to be consistent with public instance behavior
|
|
get: () => (0,_vue_runtime_core__WEBPACK_IMPORTED_MODULE_16__/* .unref */ .R1)(exposed[key])
|
|
});
|
|
} else if (false) {}
|
|
}
|
|
}
|
|
_resolveProps(def) {
|
|
const {
|
|
props
|
|
} = def;
|
|
const declaredPropKeys = (0,_vue_shared__WEBPACK_IMPORTED_MODULE_13__/* .isArray */ .cy)(props) ? props : Object.keys(props || {});
|
|
for (const key of Object.keys(this)) {
|
|
if (key[0] !== "_" && declaredPropKeys.includes(key)) {
|
|
this._setProp(key, this[key]);
|
|
}
|
|
}
|
|
for (const key of declaredPropKeys.map(_vue_shared__WEBPACK_IMPORTED_MODULE_13__/* .camelize */ .PT)) {
|
|
Object.defineProperty(this, key, {
|
|
get() {
|
|
return this._getProp(key);
|
|
},
|
|
set(val) {
|
|
this._setProp(key, val, true, true);
|
|
}
|
|
});
|
|
}
|
|
}
|
|
_setAttr(key) {
|
|
if (key.startsWith("data-v-")) return;
|
|
const has = this.hasAttribute(key);
|
|
let value = has ? this.getAttribute(key) : REMOVAL;
|
|
const camelKey = (0,_vue_shared__WEBPACK_IMPORTED_MODULE_13__/* .camelize */ .PT)(key);
|
|
if (has && this._numberProps && this._numberProps[camelKey]) {
|
|
value = (0,_vue_shared__WEBPACK_IMPORTED_MODULE_13__/* .toNumber */ .Ro)(value);
|
|
}
|
|
this._setProp(camelKey, value, false, true);
|
|
}
|
|
/**
|
|
* @internal
|
|
*/
|
|
_getProp(key) {
|
|
return this._props[key];
|
|
}
|
|
/**
|
|
* @internal
|
|
*/
|
|
_setProp(key, val, shouldReflect = true, shouldUpdate = false) {
|
|
if (val !== this._props[key]) {
|
|
if (val === REMOVAL) {
|
|
delete this._props[key];
|
|
} else {
|
|
this._props[key] = val;
|
|
if (key === "key" && this._app) {
|
|
this._app._ceVNode.key = val;
|
|
}
|
|
}
|
|
if (shouldUpdate && this._instance) {
|
|
this._update();
|
|
}
|
|
if (shouldReflect) {
|
|
const ob = this._ob;
|
|
ob && ob.disconnect();
|
|
if (val === true) {
|
|
this.setAttribute((0,_vue_shared__WEBPACK_IMPORTED_MODULE_13__/* .hyphenate */ .Tg)(key), "");
|
|
} else if (typeof val === "string" || typeof val === "number") {
|
|
this.setAttribute((0,_vue_shared__WEBPACK_IMPORTED_MODULE_13__/* .hyphenate */ .Tg)(key), val + "");
|
|
} else if (!val) {
|
|
this.removeAttribute((0,_vue_shared__WEBPACK_IMPORTED_MODULE_13__/* .hyphenate */ .Tg)(key));
|
|
}
|
|
ob && ob.observe(this, {
|
|
attributes: true
|
|
});
|
|
}
|
|
}
|
|
}
|
|
_update() {
|
|
render(this._createVNode(), this._root);
|
|
}
|
|
_createVNode() {
|
|
const baseProps = {};
|
|
if (!this.shadowRoot) {
|
|
baseProps.onVnodeMounted = baseProps.onVnodeUpdated = this._renderSlots.bind(this);
|
|
}
|
|
const vnode = (0,_vue_runtime_core__WEBPACK_IMPORTED_MODULE_14__/* .createVNode */ .bF)(this._def, (0,_vue_shared__WEBPACK_IMPORTED_MODULE_13__/* .extend */ .X$)(baseProps, this._props));
|
|
if (!this._instance) {
|
|
vnode.ce = instance => {
|
|
this._instance = instance;
|
|
instance.ce = this;
|
|
instance.isCE = true;
|
|
if (false) {}
|
|
const dispatch = (event, args) => {
|
|
this.dispatchEvent(new CustomEvent(event, (0,_vue_shared__WEBPACK_IMPORTED_MODULE_13__/* .isPlainObject */ .Qd)(args[0]) ? (0,_vue_shared__WEBPACK_IMPORTED_MODULE_13__/* .extend */ .X$)({
|
|
detail: args
|
|
}, args[0]) : {
|
|
detail: args
|
|
}));
|
|
};
|
|
instance.emit = (event, ...args) => {
|
|
dispatch(event, args);
|
|
if ((0,_vue_shared__WEBPACK_IMPORTED_MODULE_13__/* .hyphenate */ .Tg)(event) !== event) {
|
|
dispatch((0,_vue_shared__WEBPACK_IMPORTED_MODULE_13__/* .hyphenate */ .Tg)(event), args);
|
|
}
|
|
};
|
|
this._setParent();
|
|
};
|
|
}
|
|
return vnode;
|
|
}
|
|
_applyStyles(styles, owner) {
|
|
if (!styles) return;
|
|
if (owner) {
|
|
if (owner === this._def || this._styleChildren.has(owner)) {
|
|
return;
|
|
}
|
|
this._styleChildren.add(owner);
|
|
}
|
|
const nonce = this._nonce;
|
|
for (let i = styles.length - 1; i >= 0; i--) {
|
|
const s = document.createElement("style");
|
|
if (nonce) s.setAttribute("nonce", nonce);
|
|
s.textContent = styles[i];
|
|
this.shadowRoot.prepend(s);
|
|
if (false) {}
|
|
}
|
|
}
|
|
/**
|
|
* Only called when shadowRoot is false
|
|
*/
|
|
_parseSlots() {
|
|
const slots = this._slots = {};
|
|
let n;
|
|
while (n = this.firstChild) {
|
|
const slotName = n.nodeType === 1 && n.getAttribute("slot") || "default";
|
|
(slots[slotName] || (slots[slotName] = [])).push(n);
|
|
this.removeChild(n);
|
|
}
|
|
}
|
|
/**
|
|
* Only called when shadowRoot is false
|
|
*/
|
|
_renderSlots() {
|
|
const outlets = (this._teleportTarget || this).querySelectorAll("slot");
|
|
const scopeId = this._instance.type.__scopeId;
|
|
for (let i = 0; i < outlets.length; i++) {
|
|
const o = outlets[i];
|
|
const slotName = o.getAttribute("name") || "default";
|
|
const content = this._slots[slotName];
|
|
const parent = o.parentNode;
|
|
if (content) {
|
|
for (const n of content) {
|
|
if (scopeId && n.nodeType === 1) {
|
|
const id = scopeId + "-s";
|
|
const walker = document.createTreeWalker(n, 1);
|
|
n.setAttribute(id, "");
|
|
let child;
|
|
while (child = walker.nextNode()) {
|
|
child.setAttribute(id, "");
|
|
}
|
|
}
|
|
parent.insertBefore(n, o);
|
|
}
|
|
} else {
|
|
while (o.firstChild) parent.insertBefore(o.firstChild, o);
|
|
}
|
|
parent.removeChild(o);
|
|
}
|
|
}
|
|
/**
|
|
* @internal
|
|
*/
|
|
_injectChildStyle(comp) {
|
|
this._applyStyles(comp.styles, comp);
|
|
}
|
|
/**
|
|
* @internal
|
|
*/
|
|
_removeChildStyle(comp) {
|
|
if (false) {}
|
|
}
|
|
}
|
|
function useHost(caller) {
|
|
const instance = getCurrentInstance();
|
|
const el = instance && instance.ce;
|
|
if (el) {
|
|
return el;
|
|
} else if (false) {}
|
|
return null;
|
|
}
|
|
function useShadowRoot() {
|
|
const el = false ? 0 : useHost();
|
|
return el && el.shadowRoot;
|
|
}
|
|
function useCssModule(name = "$style") {
|
|
{
|
|
const instance = getCurrentInstance();
|
|
if (!instance) {
|
|
false && 0;
|
|
return EMPTY_OBJ;
|
|
}
|
|
const modules = instance.type.__cssModules;
|
|
if (!modules) {
|
|
false && 0;
|
|
return EMPTY_OBJ;
|
|
}
|
|
const mod = modules[name];
|
|
if (!mod) {
|
|
false && 0;
|
|
return EMPTY_OBJ;
|
|
}
|
|
return mod;
|
|
}
|
|
}
|
|
const positionMap = /* @__PURE__ */new WeakMap();
|
|
const newPositionMap = /* @__PURE__ */new WeakMap();
|
|
const moveCbKey = Symbol("_moveCb");
|
|
const enterCbKey = Symbol("_enterCb");
|
|
const decorate = t => {
|
|
delete t.props.mode;
|
|
return t;
|
|
};
|
|
const TransitionGroupImpl = /* @__PURE__ */decorate({
|
|
name: "TransitionGroup",
|
|
props: /* @__PURE__ */(0,_vue_shared__WEBPACK_IMPORTED_MODULE_13__/* .extend */ .X$)({}, TransitionPropsValidators, {
|
|
tag: String,
|
|
moveClass: String
|
|
}),
|
|
setup(props, {
|
|
slots
|
|
}) {
|
|
const instance = (0,_vue_runtime_core__WEBPACK_IMPORTED_MODULE_14__/* .getCurrentInstance */ .nI)();
|
|
const state = (0,_vue_runtime_core__WEBPACK_IMPORTED_MODULE_14__/* .useTransitionState */ .Gy)();
|
|
let prevChildren;
|
|
let children;
|
|
(0,_vue_runtime_core__WEBPACK_IMPORTED_MODULE_14__/* .onUpdated */ .$u)(() => {
|
|
if (!prevChildren.length) {
|
|
return;
|
|
}
|
|
const moveClass = props.moveClass || `${props.name || "v"}-move`;
|
|
if (!hasCSSTransform(prevChildren[0].el, instance.vnode.el, moveClass)) {
|
|
return;
|
|
}
|
|
prevChildren.forEach(callPendingCbs);
|
|
prevChildren.forEach(recordPosition);
|
|
const movedChildren = prevChildren.filter(applyTranslation);
|
|
forceReflow();
|
|
movedChildren.forEach(c => {
|
|
const el = c.el;
|
|
const style = el.style;
|
|
addTransitionClass(el, moveClass);
|
|
style.transform = style.webkitTransform = style.transitionDuration = "";
|
|
const cb = el[moveCbKey] = e => {
|
|
if (e && e.target !== el) {
|
|
return;
|
|
}
|
|
if (!e || /transform$/.test(e.propertyName)) {
|
|
el.removeEventListener("transitionend", cb);
|
|
el[moveCbKey] = null;
|
|
removeTransitionClass(el, moveClass);
|
|
}
|
|
};
|
|
el.addEventListener("transitionend", cb);
|
|
});
|
|
});
|
|
return () => {
|
|
const rawProps = (0,_vue_runtime_core__WEBPACK_IMPORTED_MODULE_16__/* .toRaw */ .ux)(props);
|
|
const cssTransitionProps = resolveTransitionProps(rawProps);
|
|
let tag = rawProps.tag || _vue_runtime_core__WEBPACK_IMPORTED_MODULE_14__/* .Fragment */ .FK;
|
|
prevChildren = [];
|
|
if (children) {
|
|
for (let i = 0; i < children.length; i++) {
|
|
const child = children[i];
|
|
if (child.el && child.el instanceof Element) {
|
|
prevChildren.push(child);
|
|
(0,_vue_runtime_core__WEBPACK_IMPORTED_MODULE_14__/* .setTransitionHooks */ .MZ)(child, (0,_vue_runtime_core__WEBPACK_IMPORTED_MODULE_14__/* .resolveTransitionHooks */ .OW)(child, cssTransitionProps, state, instance));
|
|
positionMap.set(child, child.el.getBoundingClientRect());
|
|
}
|
|
}
|
|
}
|
|
children = slots.default ? (0,_vue_runtime_core__WEBPACK_IMPORTED_MODULE_14__/* .getTransitionRawChildren */ .Df)(slots.default()) : [];
|
|
for (let i = 0; i < children.length; i++) {
|
|
const child = children[i];
|
|
if (child.key != null) {
|
|
(0,_vue_runtime_core__WEBPACK_IMPORTED_MODULE_14__/* .setTransitionHooks */ .MZ)(child, (0,_vue_runtime_core__WEBPACK_IMPORTED_MODULE_14__/* .resolveTransitionHooks */ .OW)(child, cssTransitionProps, state, instance));
|
|
} else if (false) {}
|
|
}
|
|
return (0,_vue_runtime_core__WEBPACK_IMPORTED_MODULE_14__/* .createVNode */ .bF)(tag, null, children);
|
|
};
|
|
}
|
|
});
|
|
const TransitionGroup = (/* unused pure expression or super */ null && (TransitionGroupImpl));
|
|
function callPendingCbs(c) {
|
|
const el = c.el;
|
|
if (el[moveCbKey]) {
|
|
el[moveCbKey]();
|
|
}
|
|
if (el[enterCbKey]) {
|
|
el[enterCbKey]();
|
|
}
|
|
}
|
|
function recordPosition(c) {
|
|
newPositionMap.set(c, c.el.getBoundingClientRect());
|
|
}
|
|
function applyTranslation(c) {
|
|
const oldPos = positionMap.get(c);
|
|
const newPos = newPositionMap.get(c);
|
|
const dx = oldPos.left - newPos.left;
|
|
const dy = oldPos.top - newPos.top;
|
|
if (dx || dy) {
|
|
const s = c.el.style;
|
|
s.transform = s.webkitTransform = `translate(${dx}px,${dy}px)`;
|
|
s.transitionDuration = "0s";
|
|
return c;
|
|
}
|
|
}
|
|
function hasCSSTransform(el, root, moveClass) {
|
|
const clone = el.cloneNode();
|
|
const _vtc = el[vtcKey];
|
|
if (_vtc) {
|
|
_vtc.forEach(cls => {
|
|
cls.split(/\s+/).forEach(c => c && clone.classList.remove(c));
|
|
});
|
|
}
|
|
moveClass.split(/\s+/).forEach(c => c && clone.classList.add(c));
|
|
clone.style.display = "none";
|
|
const container = root.nodeType === 1 ? root : root.parentNode;
|
|
container.appendChild(clone);
|
|
const {
|
|
hasTransform
|
|
} = getTransitionInfo(clone);
|
|
container.removeChild(clone);
|
|
return hasTransform;
|
|
}
|
|
const getModelAssigner = vnode => {
|
|
const fn = vnode.props["onUpdate:modelValue"] || false;
|
|
return (0,_vue_shared__WEBPACK_IMPORTED_MODULE_13__/* .isArray */ .cy)(fn) ? value => (0,_vue_shared__WEBPACK_IMPORTED_MODULE_13__/* .invokeArrayFns */ .DY)(fn, value) : fn;
|
|
};
|
|
function onCompositionStart(e) {
|
|
e.target.composing = true;
|
|
}
|
|
function onCompositionEnd(e) {
|
|
const target = e.target;
|
|
if (target.composing) {
|
|
target.composing = false;
|
|
target.dispatchEvent(new Event("input"));
|
|
}
|
|
}
|
|
const assignKey = Symbol("_assign");
|
|
const vModelText = {
|
|
created(el, {
|
|
modifiers: {
|
|
lazy,
|
|
trim,
|
|
number
|
|
}
|
|
}, vnode) {
|
|
el[assignKey] = getModelAssigner(vnode);
|
|
const castToNumber = number || vnode.props && vnode.props.type === "number";
|
|
addEventListener(el, lazy ? "change" : "input", e => {
|
|
if (e.target.composing) return;
|
|
let domValue = el.value;
|
|
if (trim) {
|
|
domValue = domValue.trim();
|
|
}
|
|
if (castToNumber) {
|
|
domValue = (0,_vue_shared__WEBPACK_IMPORTED_MODULE_13__/* .looseToNumber */ .bB)(domValue);
|
|
}
|
|
el[assignKey](domValue);
|
|
});
|
|
if (trim) {
|
|
addEventListener(el, "change", () => {
|
|
el.value = el.value.trim();
|
|
});
|
|
}
|
|
if (!lazy) {
|
|
addEventListener(el, "compositionstart", onCompositionStart);
|
|
addEventListener(el, "compositionend", onCompositionEnd);
|
|
addEventListener(el, "change", onCompositionEnd);
|
|
}
|
|
},
|
|
// set value on mounted so it's after min/max for type="range"
|
|
mounted(el, {
|
|
value
|
|
}) {
|
|
el.value = value == null ? "" : value;
|
|
},
|
|
beforeUpdate(el, {
|
|
value,
|
|
oldValue,
|
|
modifiers: {
|
|
lazy,
|
|
trim,
|
|
number
|
|
}
|
|
}, vnode) {
|
|
el[assignKey] = getModelAssigner(vnode);
|
|
if (el.composing) return;
|
|
const elValue = (number || el.type === "number") && !/^0\d/.test(el.value) ? (0,_vue_shared__WEBPACK_IMPORTED_MODULE_13__/* .looseToNumber */ .bB)(el.value) : el.value;
|
|
const newValue = value == null ? "" : value;
|
|
if (elValue === newValue) {
|
|
return;
|
|
}
|
|
if (document.activeElement === el && el.type !== "range") {
|
|
if (lazy && value === oldValue) {
|
|
return;
|
|
}
|
|
if (trim && el.value.trim() === newValue) {
|
|
return;
|
|
}
|
|
}
|
|
el.value = newValue;
|
|
}
|
|
};
|
|
const vModelCheckbox = {
|
|
// #4096 array checkboxes need to be deep traversed
|
|
deep: true,
|
|
created(el, _, vnode) {
|
|
el[assignKey] = getModelAssigner(vnode);
|
|
addEventListener(el, "change", () => {
|
|
const modelValue = el._modelValue;
|
|
const elementValue = getValue(el);
|
|
const checked = el.checked;
|
|
const assign = el[assignKey];
|
|
if ((0,_vue_shared__WEBPACK_IMPORTED_MODULE_13__/* .isArray */ .cy)(modelValue)) {
|
|
const index = (0,_vue_shared__WEBPACK_IMPORTED_MODULE_13__/* .looseIndexOf */ .u3)(modelValue, elementValue);
|
|
const found = index !== -1;
|
|
if (checked && !found) {
|
|
assign(modelValue.concat(elementValue));
|
|
} else if (!checked && found) {
|
|
const filtered = [...modelValue];
|
|
filtered.splice(index, 1);
|
|
assign(filtered);
|
|
}
|
|
} else if ((0,_vue_shared__WEBPACK_IMPORTED_MODULE_13__/* .isSet */ .vM)(modelValue)) {
|
|
const cloned = new Set(modelValue);
|
|
if (checked) {
|
|
cloned.add(elementValue);
|
|
} else {
|
|
cloned.delete(elementValue);
|
|
}
|
|
assign(cloned);
|
|
} else {
|
|
assign(getCheckboxValue(el, checked));
|
|
}
|
|
});
|
|
},
|
|
// set initial checked on mount to wait for true-value/false-value
|
|
mounted: setChecked,
|
|
beforeUpdate(el, binding, vnode) {
|
|
el[assignKey] = getModelAssigner(vnode);
|
|
setChecked(el, binding, vnode);
|
|
}
|
|
};
|
|
function setChecked(el, {
|
|
value,
|
|
oldValue
|
|
}, vnode) {
|
|
el._modelValue = value;
|
|
let checked;
|
|
if ((0,_vue_shared__WEBPACK_IMPORTED_MODULE_13__/* .isArray */ .cy)(value)) {
|
|
checked = (0,_vue_shared__WEBPACK_IMPORTED_MODULE_13__/* .looseIndexOf */ .u3)(value, vnode.props.value) > -1;
|
|
} else if ((0,_vue_shared__WEBPACK_IMPORTED_MODULE_13__/* .isSet */ .vM)(value)) {
|
|
checked = value.has(vnode.props.value);
|
|
} else {
|
|
if (value === oldValue) return;
|
|
checked = (0,_vue_shared__WEBPACK_IMPORTED_MODULE_13__/* .looseEqual */ .BX)(value, getCheckboxValue(el, true));
|
|
}
|
|
if (el.checked !== checked) {
|
|
el.checked = checked;
|
|
}
|
|
}
|
|
const vModelRadio = {
|
|
created(el, {
|
|
value
|
|
}, vnode) {
|
|
el.checked = (0,_vue_shared__WEBPACK_IMPORTED_MODULE_13__/* .looseEqual */ .BX)(value, vnode.props.value);
|
|
el[assignKey] = getModelAssigner(vnode);
|
|
addEventListener(el, "change", () => {
|
|
el[assignKey](getValue(el));
|
|
});
|
|
},
|
|
beforeUpdate(el, {
|
|
value,
|
|
oldValue
|
|
}, vnode) {
|
|
el[assignKey] = getModelAssigner(vnode);
|
|
if (value !== oldValue) {
|
|
el.checked = (0,_vue_shared__WEBPACK_IMPORTED_MODULE_13__/* .looseEqual */ .BX)(value, vnode.props.value);
|
|
}
|
|
}
|
|
};
|
|
const vModelSelect = {
|
|
// <select multiple> value need to be deep traversed
|
|
deep: true,
|
|
created(el, {
|
|
value,
|
|
modifiers: {
|
|
number
|
|
}
|
|
}, vnode) {
|
|
const isSetModel = (0,_vue_shared__WEBPACK_IMPORTED_MODULE_13__/* .isSet */ .vM)(value);
|
|
addEventListener(el, "change", () => {
|
|
const selectedVal = Array.prototype.filter.call(el.options, o => o.selected).map(o => number ? (0,_vue_shared__WEBPACK_IMPORTED_MODULE_13__/* .looseToNumber */ .bB)(getValue(o)) : getValue(o));
|
|
el[assignKey](el.multiple ? isSetModel ? new Set(selectedVal) : selectedVal : selectedVal[0]);
|
|
el._assigning = true;
|
|
(0,_vue_runtime_core__WEBPACK_IMPORTED_MODULE_14__/* .nextTick */ .dY)(() => {
|
|
el._assigning = false;
|
|
});
|
|
});
|
|
el[assignKey] = getModelAssigner(vnode);
|
|
},
|
|
// set value in mounted & updated because <select> relies on its children
|
|
// <option>s.
|
|
mounted(el, {
|
|
value
|
|
}) {
|
|
setSelected(el, value);
|
|
},
|
|
beforeUpdate(el, _binding, vnode) {
|
|
el[assignKey] = getModelAssigner(vnode);
|
|
},
|
|
updated(el, {
|
|
value
|
|
}) {
|
|
if (!el._assigning) {
|
|
setSelected(el, value);
|
|
}
|
|
}
|
|
};
|
|
function setSelected(el, value) {
|
|
const isMultiple = el.multiple;
|
|
const isArrayValue = (0,_vue_shared__WEBPACK_IMPORTED_MODULE_13__/* .isArray */ .cy)(value);
|
|
if (isMultiple && !isArrayValue && !(0,_vue_shared__WEBPACK_IMPORTED_MODULE_13__/* .isSet */ .vM)(value)) {
|
|
false && 0;
|
|
return;
|
|
}
|
|
for (let i = 0, l = el.options.length; i < l; i++) {
|
|
const option = el.options[i];
|
|
const optionValue = getValue(option);
|
|
if (isMultiple) {
|
|
if (isArrayValue) {
|
|
const optionType = typeof optionValue;
|
|
if (optionType === "string" || optionType === "number") {
|
|
option.selected = value.some(v => String(v) === String(optionValue));
|
|
} else {
|
|
option.selected = (0,_vue_shared__WEBPACK_IMPORTED_MODULE_13__/* .looseIndexOf */ .u3)(value, optionValue) > -1;
|
|
}
|
|
} else {
|
|
option.selected = value.has(optionValue);
|
|
}
|
|
} else if ((0,_vue_shared__WEBPACK_IMPORTED_MODULE_13__/* .looseEqual */ .BX)(getValue(option), value)) {
|
|
if (el.selectedIndex !== i) el.selectedIndex = i;
|
|
return;
|
|
}
|
|
}
|
|
if (!isMultiple && el.selectedIndex !== -1) {
|
|
el.selectedIndex = -1;
|
|
}
|
|
}
|
|
function getValue(el) {
|
|
return "_value" in el ? el._value : el.value;
|
|
}
|
|
function getCheckboxValue(el, checked) {
|
|
const key = checked ? "_trueValue" : "_falseValue";
|
|
return key in el ? el[key] : checked;
|
|
}
|
|
const vModelDynamic = {
|
|
created(el, binding, vnode) {
|
|
callModelHook(el, binding, vnode, null, "created");
|
|
},
|
|
mounted(el, binding, vnode) {
|
|
callModelHook(el, binding, vnode, null, "mounted");
|
|
},
|
|
beforeUpdate(el, binding, vnode, prevVNode) {
|
|
callModelHook(el, binding, vnode, prevVNode, "beforeUpdate");
|
|
},
|
|
updated(el, binding, vnode, prevVNode) {
|
|
callModelHook(el, binding, vnode, prevVNode, "updated");
|
|
}
|
|
};
|
|
function resolveDynamicModel(tagName, type) {
|
|
switch (tagName) {
|
|
case "SELECT":
|
|
return vModelSelect;
|
|
case "TEXTAREA":
|
|
return vModelText;
|
|
default:
|
|
switch (type) {
|
|
case "checkbox":
|
|
return vModelCheckbox;
|
|
case "radio":
|
|
return vModelRadio;
|
|
default:
|
|
return vModelText;
|
|
}
|
|
}
|
|
}
|
|
function callModelHook(el, binding, vnode, prevVNode, hook) {
|
|
const modelToUse = resolveDynamicModel(el.tagName, vnode.props && vnode.props.type);
|
|
const fn = modelToUse[hook];
|
|
fn && fn(el, binding, vnode, prevVNode);
|
|
}
|
|
function initVModelForSSR() {
|
|
vModelText.getSSRProps = ({
|
|
value
|
|
}) => ({
|
|
value
|
|
});
|
|
vModelRadio.getSSRProps = ({
|
|
value
|
|
}, vnode) => {
|
|
if (vnode.props && looseEqual(vnode.props.value, value)) {
|
|
return {
|
|
checked: true
|
|
};
|
|
}
|
|
};
|
|
vModelCheckbox.getSSRProps = ({
|
|
value
|
|
}, vnode) => {
|
|
if (isArray(value)) {
|
|
if (vnode.props && looseIndexOf(value, vnode.props.value) > -1) {
|
|
return {
|
|
checked: true
|
|
};
|
|
}
|
|
} else if (isSet(value)) {
|
|
if (vnode.props && value.has(vnode.props.value)) {
|
|
return {
|
|
checked: true
|
|
};
|
|
}
|
|
} else if (value) {
|
|
return {
|
|
checked: true
|
|
};
|
|
}
|
|
};
|
|
vModelDynamic.getSSRProps = (binding, vnode) => {
|
|
if (typeof vnode.type !== "string") {
|
|
return;
|
|
}
|
|
const modelToUse = resolveDynamicModel(
|
|
// resolveDynamicModel expects an uppercase tag name, but vnode.type is lowercase
|
|
vnode.type.toUpperCase(), vnode.props && vnode.props.type);
|
|
if (modelToUse.getSSRProps) {
|
|
return modelToUse.getSSRProps(binding, vnode);
|
|
}
|
|
};
|
|
}
|
|
const systemModifiers = ["ctrl", "shift", "alt", "meta"];
|
|
const modifierGuards = {
|
|
stop: e => e.stopPropagation(),
|
|
prevent: e => e.preventDefault(),
|
|
self: e => e.target !== e.currentTarget,
|
|
ctrl: e => !e.ctrlKey,
|
|
shift: e => !e.shiftKey,
|
|
alt: e => !e.altKey,
|
|
meta: e => !e.metaKey,
|
|
left: e => "button" in e && e.button !== 0,
|
|
middle: e => "button" in e && e.button !== 1,
|
|
right: e => "button" in e && e.button !== 2,
|
|
exact: (e, modifiers) => systemModifiers.some(m => e[`${m}Key`] && !modifiers.includes(m))
|
|
};
|
|
const withModifiers = (fn, modifiers) => {
|
|
const cache = fn._withMods || (fn._withMods = {});
|
|
const cacheKey = modifiers.join(".");
|
|
return cache[cacheKey] || (cache[cacheKey] = (event, ...args) => {
|
|
for (let i = 0; i < modifiers.length; i++) {
|
|
const guard = modifierGuards[modifiers[i]];
|
|
if (guard && guard(event, modifiers)) return;
|
|
}
|
|
return fn(event, ...args);
|
|
});
|
|
};
|
|
const keyNames = {
|
|
esc: "escape",
|
|
space: " ",
|
|
up: "arrow-up",
|
|
left: "arrow-left",
|
|
right: "arrow-right",
|
|
down: "arrow-down",
|
|
delete: "backspace"
|
|
};
|
|
const withKeys = (fn, modifiers) => {
|
|
const cache = fn._withKeys || (fn._withKeys = {});
|
|
const cacheKey = modifiers.join(".");
|
|
return cache[cacheKey] || (cache[cacheKey] = event => {
|
|
if (!("key" in event)) {
|
|
return;
|
|
}
|
|
const eventKey = (0,_vue_shared__WEBPACK_IMPORTED_MODULE_13__/* .hyphenate */ .Tg)(event.key);
|
|
if (modifiers.some(k => k === eventKey || keyNames[k] === eventKey)) {
|
|
return fn(event);
|
|
}
|
|
});
|
|
};
|
|
const rendererOptions = /* @__PURE__ */(0,_vue_shared__WEBPACK_IMPORTED_MODULE_13__/* .extend */ .X$)({
|
|
patchProp
|
|
}, nodeOps);
|
|
let renderer;
|
|
let enabledHydration = false;
|
|
function ensureRenderer() {
|
|
return renderer || (renderer = (0,_vue_runtime_core__WEBPACK_IMPORTED_MODULE_14__/* .createRenderer */ .K9)(rendererOptions));
|
|
}
|
|
function ensureHydrationRenderer() {
|
|
renderer = enabledHydration ? renderer : createHydrationRenderer(rendererOptions);
|
|
enabledHydration = true;
|
|
return renderer;
|
|
}
|
|
const render = (...args) => {
|
|
ensureRenderer().render(...args);
|
|
};
|
|
const hydrate = (...args) => {
|
|
ensureHydrationRenderer().hydrate(...args);
|
|
};
|
|
const createApp = (...args) => {
|
|
const app = ensureRenderer().createApp(...args);
|
|
if (false) {}
|
|
const {
|
|
mount
|
|
} = app;
|
|
app.mount = containerOrSelector => {
|
|
const container = normalizeContainer(containerOrSelector);
|
|
if (!container) return;
|
|
const component = app._component;
|
|
if (!(0,_vue_shared__WEBPACK_IMPORTED_MODULE_13__/* .isFunction */ .Tn)(component) && !component.render && !component.template) {
|
|
component.template = container.innerHTML;
|
|
}
|
|
if (container.nodeType === 1) {
|
|
container.textContent = "";
|
|
}
|
|
const proxy = mount(container, false, resolveRootNamespace(container));
|
|
if (container instanceof Element) {
|
|
container.removeAttribute("v-cloak");
|
|
container.setAttribute("data-v-app", "");
|
|
}
|
|
return proxy;
|
|
};
|
|
return app;
|
|
};
|
|
const createSSRApp = (...args) => {
|
|
const app = ensureHydrationRenderer().createApp(...args);
|
|
if (false) {}
|
|
const {
|
|
mount
|
|
} = app;
|
|
app.mount = containerOrSelector => {
|
|
const container = normalizeContainer(containerOrSelector);
|
|
if (container) {
|
|
return mount(container, true, resolveRootNamespace(container));
|
|
}
|
|
};
|
|
return app;
|
|
};
|
|
function resolveRootNamespace(container) {
|
|
if (container instanceof SVGElement) {
|
|
return "svg";
|
|
}
|
|
if (typeof MathMLElement === "function" && container instanceof MathMLElement) {
|
|
return "mathml";
|
|
}
|
|
}
|
|
function injectNativeTagCheck(app) {
|
|
Object.defineProperty(app.config, "isNativeTag", {
|
|
value: tag => isHTMLTag(tag) || isSVGTag(tag) || isMathMLTag(tag),
|
|
writable: false
|
|
});
|
|
}
|
|
function injectCompilerOptionsCheck(app) {
|
|
if (isRuntimeOnly()) {
|
|
const isCustomElement = app.config.isCustomElement;
|
|
Object.defineProperty(app.config, "isCustomElement", {
|
|
get() {
|
|
return isCustomElement;
|
|
},
|
|
set() {
|
|
warn(`The \`isCustomElement\` config option is deprecated. Use \`compilerOptions.isCustomElement\` instead.`);
|
|
}
|
|
});
|
|
const compilerOptions = app.config.compilerOptions;
|
|
const msg = `The \`compilerOptions\` config option is only respected when using a build of Vue.js that includes the runtime compiler (aka "full build"). Since you are using the runtime-only build, \`compilerOptions\` must be passed to \`@vue/compiler-dom\` in the build setup instead.
|
|
- For vue-loader: pass it via vue-loader's \`compilerOptions\` loader option.
|
|
- For vue-cli: see https://cli.vuejs.org/guide/webpack.html#modifying-options-of-a-loader
|
|
- For vite: pass it via @vitejs/plugin-vue options. See https://github.com/vitejs/vite-plugin-vue/tree/main/packages/plugin-vue#example-for-passing-options-to-vuecompiler-sfc`;
|
|
Object.defineProperty(app.config, "compilerOptions", {
|
|
get() {
|
|
warn(msg);
|
|
return compilerOptions;
|
|
},
|
|
set() {
|
|
warn(msg);
|
|
}
|
|
});
|
|
}
|
|
}
|
|
function normalizeContainer(container) {
|
|
if ((0,_vue_shared__WEBPACK_IMPORTED_MODULE_13__/* .isString */ .Kg)(container)) {
|
|
const res = document.querySelector(container);
|
|
if (false) {}
|
|
return res;
|
|
}
|
|
if (false) {}
|
|
return container;
|
|
}
|
|
let ssrDirectiveInitialized = false;
|
|
const initDirectivesForSSR = () => {
|
|
if (!ssrDirectiveInitialized) {
|
|
ssrDirectiveInitialized = true;
|
|
initVModelForSSR();
|
|
initVShowForSSR();
|
|
}
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 1858:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var DESCRIPTORS = __webpack_require__(4911);
|
|
var isArray = __webpack_require__(4873);
|
|
|
|
var $TypeError = TypeError;
|
|
// eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe
|
|
var getOwnPropertyDescriptor = Object.getOwnPropertyDescriptor;
|
|
|
|
// Safari < 13 does not throw an error in this case
|
|
var SILENT_ON_NON_WRITABLE_LENGTH_SET = DESCRIPTORS && !function () {
|
|
// makes no sense without proper strict mode support
|
|
if (this !== undefined) return true;
|
|
try {
|
|
// eslint-disable-next-line es/no-object-defineproperty -- safe
|
|
Object.defineProperty([], 'length', { writable: false }).length = 1;
|
|
} catch (error) {
|
|
return error instanceof TypeError;
|
|
}
|
|
}();
|
|
|
|
module.exports = SILENT_ON_NON_WRITABLE_LENGTH_SET ? function (O, length) {
|
|
if (isArray(O) && !getOwnPropertyDescriptor(O, 'length').writable) {
|
|
throw new $TypeError('Cannot set read only .length');
|
|
} return O.length = length;
|
|
} : function (O, length) {
|
|
return O.length = length;
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 1909:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var isCallable = __webpack_require__(6450);
|
|
|
|
module.exports = function (it) {
|
|
return typeof it == 'object' ? it !== null : isCallable(it);
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 1939:
|
|
/***/ (function(__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) {
|
|
|
|
"use strict";
|
|
/* harmony import */ var core_js_modules_es_array_push_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(5513);
|
|
/* harmony import */ var core_js_modules_esnext_iterator_constructor_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(7195);
|
|
/* harmony import */ var core_js_modules_esnext_iterator_for_each_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(680);
|
|
/* harmony import */ var _utils_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(5813);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// RawAxiosHeaders whose duplicates are ignored by node
|
|
// c.f. https://nodejs.org/api/http.html#http_message_headers
|
|
const ignoreDuplicateOf = _utils_js__WEBPACK_IMPORTED_MODULE_3__/* ["default"] */ .A.toObjectSet(['age', 'authorization', 'content-length', 'content-type', 'etag', 'expires', 'from', 'host', 'if-modified-since', 'if-unmodified-since', 'last-modified', 'location', 'max-forwards', 'proxy-authorization', 'referer', 'retry-after', 'user-agent']);
|
|
|
|
/**
|
|
* Parse headers into an object
|
|
*
|
|
* ```
|
|
* Date: Wed, 27 Aug 2014 08:58:49 GMT
|
|
* Content-Type: application/json
|
|
* Connection: keep-alive
|
|
* Transfer-Encoding: chunked
|
|
* ```
|
|
*
|
|
* @param {String} rawHeaders Headers needing to be parsed
|
|
*
|
|
* @returns {Object} Headers parsed into an object
|
|
*/
|
|
/* harmony default export */ __webpack_exports__.A = (rawHeaders => {
|
|
const parsed = {};
|
|
let key;
|
|
let val;
|
|
let i;
|
|
rawHeaders && rawHeaders.split('\n').forEach(function parser(line) {
|
|
i = line.indexOf(':');
|
|
key = line.substring(0, i).trim().toLowerCase();
|
|
val = line.substring(i + 1).trim();
|
|
if (!key || parsed[key] && ignoreDuplicateOf[key]) {
|
|
return;
|
|
}
|
|
if (key === 'set-cookie') {
|
|
if (parsed[key]) {
|
|
parsed[key].push(val);
|
|
} else {
|
|
parsed[key] = [val];
|
|
}
|
|
} else {
|
|
parsed[key] = parsed[key] ? parsed[key] + ', ' + val : val;
|
|
}
|
|
});
|
|
return parsed;
|
|
});
|
|
|
|
/***/ }),
|
|
|
|
/***/ 1961:
|
|
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var $ = __webpack_require__(8155);
|
|
var $transfer = __webpack_require__(8056);
|
|
|
|
// `ArrayBuffer.prototype.transferToFixedLength` method
|
|
// https://tc39.es/proposal-arraybuffer-transfer/#sec-arraybuffer.prototype.transfertofixedlength
|
|
if ($transfer) $({ target: 'ArrayBuffer', proto: true }, {
|
|
transferToFixedLength: function transferToFixedLength() {
|
|
return $transfer(this, arguments.length ? arguments[0] : undefined, false);
|
|
}
|
|
});
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 2060:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var toIndexedObject = __webpack_require__(5830);
|
|
var toAbsoluteIndex = __webpack_require__(1257);
|
|
var lengthOfArrayLike = __webpack_require__(4231);
|
|
|
|
// `Array.prototype.{ indexOf, includes }` methods implementation
|
|
var createMethod = function (IS_INCLUDES) {
|
|
return function ($this, el, fromIndex) {
|
|
var O = toIndexedObject($this);
|
|
var length = lengthOfArrayLike(O);
|
|
if (length === 0) return !IS_INCLUDES && -1;
|
|
var index = toAbsoluteIndex(fromIndex, length);
|
|
var value;
|
|
// Array#includes uses SameValueZero equality algorithm
|
|
// eslint-disable-next-line no-self-compare -- NaN check
|
|
if (IS_INCLUDES && el !== el) while (length > index) {
|
|
value = O[index++];
|
|
// eslint-disable-next-line no-self-compare -- NaN check
|
|
if (value !== value) return true;
|
|
// Array#indexOf ignores holes, Array#includes - not
|
|
} else for (;length > index; index++) {
|
|
if ((IS_INCLUDES || index in O) && O[index] === el) return IS_INCLUDES || index || 0;
|
|
} return !IS_INCLUDES && -1;
|
|
};
|
|
};
|
|
|
|
module.exports = {
|
|
// `Array.prototype.includes` method
|
|
// https://tc39.es/ecma262/#sec-array.prototype.includes
|
|
includes: createMethod(true),
|
|
// `Array.prototype.indexOf` method
|
|
// https://tc39.es/ecma262/#sec-array.prototype.indexof
|
|
indexOf: createMethod(false)
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 2078:
|
|
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) {
|
|
|
|
"use strict";
|
|
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
/* harmony export */ M: function() { return /* binding */ now; }
|
|
/* harmony export */ });
|
|
/* unused harmony export isPerformanceSupported */
|
|
let supported;
|
|
let perf;
|
|
function isPerformanceSupported() {
|
|
var _a;
|
|
if (supported !== undefined) {
|
|
return supported;
|
|
}
|
|
if (typeof window !== 'undefined' && window.performance) {
|
|
supported = true;
|
|
perf = window.performance;
|
|
} else if (typeof globalThis !== 'undefined' && ((_a = globalThis.perf_hooks) === null || _a === void 0 ? void 0 : _a.performance)) {
|
|
supported = true;
|
|
perf = globalThis.perf_hooks.performance;
|
|
} else {
|
|
supported = false;
|
|
}
|
|
return supported;
|
|
}
|
|
function now() {
|
|
return isPerformanceSupported() ? perf.now() : Date.now();
|
|
}
|
|
|
|
/***/ }),
|
|
|
|
/***/ 2123:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var makeBuiltIn = __webpack_require__(4544);
|
|
var defineProperty = __webpack_require__(8564);
|
|
|
|
module.exports = function (target, name, descriptor) {
|
|
if (descriptor.get) makeBuiltIn(descriptor.get, name, { getter: true });
|
|
if (descriptor.set) makeBuiltIn(descriptor.set, name, { setter: true });
|
|
return defineProperty.f(target, name, descriptor);
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 2137:
|
|
/***/ (function(__unused_webpack_module, exports) {
|
|
|
|
/*! ieee754. BSD-3-Clause License. Feross Aboukhadijeh <https://feross.org/opensource> */
|
|
exports.read = function (buffer, offset, isLE, mLen, nBytes) {
|
|
var e, m;
|
|
var eLen = nBytes * 8 - mLen - 1;
|
|
var eMax = (1 << eLen) - 1;
|
|
var eBias = eMax >> 1;
|
|
var nBits = -7;
|
|
var i = isLE ? nBytes - 1 : 0;
|
|
var d = isLE ? -1 : 1;
|
|
var s = buffer[offset + i];
|
|
i += d;
|
|
e = s & (1 << -nBits) - 1;
|
|
s >>= -nBits;
|
|
nBits += eLen;
|
|
for (; nBits > 0; e = e * 256 + buffer[offset + i], i += d, nBits -= 8) {}
|
|
m = e & (1 << -nBits) - 1;
|
|
e >>= -nBits;
|
|
nBits += mLen;
|
|
for (; nBits > 0; m = m * 256 + buffer[offset + i], i += d, nBits -= 8) {}
|
|
if (e === 0) {
|
|
e = 1 - eBias;
|
|
} else if (e === eMax) {
|
|
return m ? NaN : (s ? -1 : 1) * Infinity;
|
|
} else {
|
|
m = m + Math.pow(2, mLen);
|
|
e = e - eBias;
|
|
}
|
|
return (s ? -1 : 1) * m * Math.pow(2, e - mLen);
|
|
};
|
|
exports.write = function (buffer, value, offset, isLE, mLen, nBytes) {
|
|
var e, m, c;
|
|
var eLen = nBytes * 8 - mLen - 1;
|
|
var eMax = (1 << eLen) - 1;
|
|
var eBias = eMax >> 1;
|
|
var rt = mLen === 23 ? Math.pow(2, -24) - Math.pow(2, -77) : 0;
|
|
var i = isLE ? 0 : nBytes - 1;
|
|
var d = isLE ? 1 : -1;
|
|
var s = value < 0 || value === 0 && 1 / value < 0 ? 1 : 0;
|
|
value = Math.abs(value);
|
|
if (isNaN(value) || value === Infinity) {
|
|
m = isNaN(value) ? 1 : 0;
|
|
e = eMax;
|
|
} else {
|
|
e = Math.floor(Math.log(value) / Math.LN2);
|
|
if (value * (c = Math.pow(2, -e)) < 1) {
|
|
e--;
|
|
c *= 2;
|
|
}
|
|
if (e + eBias >= 1) {
|
|
value += rt / c;
|
|
} else {
|
|
value += rt * Math.pow(2, 1 - eBias);
|
|
}
|
|
if (value * c >= 2) {
|
|
e++;
|
|
c /= 2;
|
|
}
|
|
if (e + eBias >= eMax) {
|
|
m = 0;
|
|
e = eMax;
|
|
} else if (e + eBias >= 1) {
|
|
m = (value * c - 1) * Math.pow(2, mLen);
|
|
e = e + eBias;
|
|
} else {
|
|
m = value * Math.pow(2, eBias - 1) * Math.pow(2, mLen);
|
|
e = 0;
|
|
}
|
|
}
|
|
for (; mLen >= 8; buffer[offset + i] = m & 0xff, i += d, m /= 256, mLen -= 8) {}
|
|
e = e << mLen | m;
|
|
eLen += mLen;
|
|
for (; eLen > 0; buffer[offset + i] = e & 0xff, i += d, e /= 256, eLen -= 8) {}
|
|
buffer[offset + i - d] |= s * 128;
|
|
};
|
|
|
|
/***/ }),
|
|
|
|
/***/ 2176:
|
|
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var $ = __webpack_require__(8155);
|
|
var iterate = __webpack_require__(1663);
|
|
var aCallable = __webpack_require__(8951);
|
|
var anObject = __webpack_require__(6696);
|
|
var getIteratorDirect = __webpack_require__(8764);
|
|
|
|
// `Iterator.prototype.every` method
|
|
// https://github.com/tc39/proposal-iterator-helpers
|
|
$({ target: 'Iterator', proto: true, real: true }, {
|
|
every: function every(predicate) {
|
|
anObject(this);
|
|
aCallable(predicate);
|
|
var record = getIteratorDirect(this);
|
|
var counter = 0;
|
|
return !iterate(record, function (value, stop) {
|
|
if (!predicate(value, counter++)) return stop();
|
|
}, { IS_RECORD: true, INTERRUPTED: true }).stopped;
|
|
}
|
|
});
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 2239:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var aSet = __webpack_require__(3991);
|
|
var add = (__webpack_require__(5057).add);
|
|
var clone = __webpack_require__(7289);
|
|
var getSetRecord = __webpack_require__(3108);
|
|
var iterateSimple = __webpack_require__(6550);
|
|
|
|
// `Set.prototype.union` method
|
|
// https://github.com/tc39/proposal-set-methods
|
|
module.exports = function union(other) {
|
|
var O = aSet(this);
|
|
var keysIter = getSetRecord(other).getIterator();
|
|
var result = clone(O);
|
|
iterateSimple(keysIter, function (it) {
|
|
add(result, it);
|
|
});
|
|
return result;
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 2271:
|
|
/***/ (function(__unused_webpack___webpack_module__, __webpack_exports__) {
|
|
|
|
"use strict";
|
|
|
|
|
|
/* harmony default export */ __webpack_exports__.A = (typeof Blob !== 'undefined' ? Blob : null);
|
|
|
|
/***/ }),
|
|
|
|
/***/ 2282:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var uncurryThis = __webpack_require__(1371);
|
|
var iterateSimple = __webpack_require__(6550);
|
|
var SetHelpers = __webpack_require__(5057);
|
|
|
|
var Set = SetHelpers.Set;
|
|
var SetPrototype = SetHelpers.proto;
|
|
var forEach = uncurryThis(SetPrototype.forEach);
|
|
var keys = uncurryThis(SetPrototype.keys);
|
|
var next = keys(new Set()).next;
|
|
|
|
module.exports = function (set, fn, interruptible) {
|
|
return interruptible ? iterateSimple({ iterator: keys(set), next: next }, fn) : forEach(set, fn);
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 2331:
|
|
/***/ (function(module) {
|
|
|
|
"use strict";
|
|
|
|
var $TypeError = TypeError;
|
|
|
|
module.exports = function (passed, required) {
|
|
if (passed < required) throw new $TypeError('Not enough arguments');
|
|
return passed;
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 2344:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var call = __webpack_require__(4978);
|
|
var aCallable = __webpack_require__(8951);
|
|
var anObject = __webpack_require__(6696);
|
|
var getIteratorDirect = __webpack_require__(8764);
|
|
var createIteratorProxy = __webpack_require__(7254);
|
|
var callWithSafeIterationClosing = __webpack_require__(5146);
|
|
|
|
var IteratorProxy = createIteratorProxy(function () {
|
|
var iterator = this.iterator;
|
|
var result = anObject(call(this.next, iterator));
|
|
var done = this.done = !!result.done;
|
|
if (!done) return callWithSafeIterationClosing(iterator, this.mapper, [result.value, this.counter++], true);
|
|
});
|
|
|
|
// `Iterator.prototype.map` method
|
|
// https://github.com/tc39/proposal-iterator-helpers
|
|
module.exports = function map(mapper) {
|
|
anObject(this);
|
|
aCallable(mapper);
|
|
return new IteratorProxy(getIteratorDirect(this), {
|
|
mapper: mapper
|
|
});
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 2346:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var isObject = __webpack_require__(1909);
|
|
|
|
module.exports = function (argument) {
|
|
return isObject(argument) || argument === null;
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 2348:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var wellKnownSymbol = __webpack_require__(9760);
|
|
var Iterators = __webpack_require__(9702);
|
|
|
|
var ITERATOR = wellKnownSymbol('iterator');
|
|
var ArrayPrototype = Array.prototype;
|
|
|
|
// check on default Array iterator
|
|
module.exports = function (it) {
|
|
return it !== undefined && (Iterators.Array === it || ArrayPrototype[ITERATOR] === it);
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 2370:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var shared = __webpack_require__(5904);
|
|
var uid = __webpack_require__(5675);
|
|
|
|
var keys = shared('keys');
|
|
|
|
module.exports = function (key) {
|
|
return keys[key] || (keys[key] = uid(key));
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 2409:
|
|
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var $ = __webpack_require__(8155);
|
|
var isDisjointFrom = __webpack_require__(7900);
|
|
var setMethodAcceptSetLike = __webpack_require__(5645);
|
|
|
|
// `Set.prototype.isDisjointFrom` method
|
|
// https://github.com/tc39/proposal-set-methods
|
|
$({ target: 'Set', proto: true, real: true, forced: !setMethodAcceptSetLike('isDisjointFrom') }, {
|
|
isDisjointFrom: isDisjointFrom
|
|
});
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 2471:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var uncurryThis = __webpack_require__(1371);
|
|
var aCallable = __webpack_require__(8951);
|
|
|
|
module.exports = function (object, key, method) {
|
|
try {
|
|
// eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe
|
|
return uncurryThis(aCallable(Object.getOwnPropertyDescriptor(object, key)[method]));
|
|
} catch (error) { /* empty */ }
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 2473:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var DESCRIPTORS = __webpack_require__(4911);
|
|
var hasOwn = __webpack_require__(1396);
|
|
|
|
var FunctionPrototype = Function.prototype;
|
|
// eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe
|
|
var getDescriptor = DESCRIPTORS && Object.getOwnPropertyDescriptor;
|
|
|
|
var EXISTS = hasOwn(FunctionPrototype, 'name');
|
|
// additional protection from minified / mangled / dropped function names
|
|
var PROPER = EXISTS && (function something() { /* empty */ }).name === 'something';
|
|
var CONFIGURABLE = EXISTS && (!DESCRIPTORS || (DESCRIPTORS && getDescriptor(FunctionPrototype, 'name').configurable));
|
|
|
|
module.exports = {
|
|
EXISTS: EXISTS,
|
|
PROPER: PROPER,
|
|
CONFIGURABLE: CONFIGURABLE
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 2602:
|
|
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var $ = __webpack_require__(8155);
|
|
var anObject = __webpack_require__(6696);
|
|
var iterate = __webpack_require__(1663);
|
|
var getIteratorDirect = __webpack_require__(8764);
|
|
|
|
var push = [].push;
|
|
|
|
// `Iterator.prototype.toArray` method
|
|
// https://github.com/tc39/proposal-iterator-helpers
|
|
$({ target: 'Iterator', proto: true, real: true }, {
|
|
toArray: function toArray() {
|
|
var result = [];
|
|
iterate(getIteratorDirect(anObject(this)), push, { that: result, IS_RECORD: true });
|
|
return result;
|
|
}
|
|
});
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 2607:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var uncurryThis = __webpack_require__(1371);
|
|
var isCallable = __webpack_require__(6450);
|
|
var store = __webpack_require__(4568);
|
|
|
|
var functionToString = uncurryThis(Function.toString);
|
|
|
|
// this helper broken in `[email protected]`, so we can't use `shared` helper
|
|
if (!isCallable(store.inspectSource)) {
|
|
store.inspectSource = function (it) {
|
|
return functionToString(it);
|
|
};
|
|
}
|
|
|
|
module.exports = store.inspectSource;
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 2624:
|
|
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var $ = __webpack_require__(8155);
|
|
var uncurryThis = __webpack_require__(1371);
|
|
var aCallable = __webpack_require__(8951);
|
|
var toIndexedObject = __webpack_require__(5830);
|
|
var arrayFromConstructorAndList = __webpack_require__(1341);
|
|
var getBuiltInPrototypeMethod = __webpack_require__(4091);
|
|
var addToUnscopables = __webpack_require__(3876);
|
|
|
|
var $Array = Array;
|
|
var sort = uncurryThis(getBuiltInPrototypeMethod('Array', 'sort'));
|
|
|
|
// `Array.prototype.toSorted` method
|
|
// https://tc39.es/ecma262/#sec-array.prototype.tosorted
|
|
$({ target: 'Array', proto: true }, {
|
|
toSorted: function toSorted(compareFn) {
|
|
if (compareFn !== undefined) aCallable(compareFn);
|
|
var O = toIndexedObject(this);
|
|
var A = arrayFromConstructorAndList($Array, O);
|
|
return sort(A, compareFn);
|
|
}
|
|
});
|
|
|
|
addToUnscopables('toSorted');
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 2634:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var aSet = __webpack_require__(3991);
|
|
var has = (__webpack_require__(5057).has);
|
|
var size = __webpack_require__(903);
|
|
var getSetRecord = __webpack_require__(3108);
|
|
var iterateSimple = __webpack_require__(6550);
|
|
var iteratorClose = __webpack_require__(1298);
|
|
|
|
// `Set.prototype.isSupersetOf` method
|
|
// https://tc39.github.io/proposal-set-methods/#Set.prototype.isSupersetOf
|
|
module.exports = function isSupersetOf(other) {
|
|
var O = aSet(this);
|
|
var otherRec = getSetRecord(other);
|
|
if (size(O) < otherRec.size) return false;
|
|
var iterator = otherRec.getIterator();
|
|
return iterateSimple(iterator, function (e) {
|
|
if (!has(O, e)) return iteratorClose(iterator, 'normal', false);
|
|
}) !== false;
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 2719:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var uncurryThis = __webpack_require__(3633);
|
|
var aCallable = __webpack_require__(8951);
|
|
var NATIVE_BIND = __webpack_require__(8537);
|
|
|
|
var bind = uncurryThis(uncurryThis.bind);
|
|
|
|
// optional / simple context binding
|
|
module.exports = function (fn, that) {
|
|
aCallable(fn);
|
|
return that === undefined ? fn : NATIVE_BIND ? bind(fn, that) : function (/* ...args */) {
|
|
return fn.apply(that, arguments);
|
|
};
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 2735:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var DESCRIPTORS = __webpack_require__(4911);
|
|
var definePropertyModule = __webpack_require__(8564);
|
|
var createPropertyDescriptor = __webpack_require__(5569);
|
|
|
|
module.exports = function (object, key, value) {
|
|
if (DESCRIPTORS) definePropertyModule.f(object, key, createPropertyDescriptor(0, value));
|
|
else object[key] = value;
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 2779:
|
|
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) {
|
|
|
|
"use strict";
|
|
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
/* harmony export */ R: function() { return /* binding */ ApiProxy; }
|
|
/* harmony export */ });
|
|
/* harmony import */ var core_js_modules_es_array_push_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(5513);
|
|
/* harmony import */ var core_js_modules_es_array_push_js__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_array_push_js__WEBPACK_IMPORTED_MODULE_0__);
|
|
/* harmony import */ var _const_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(5172);
|
|
/* harmony import */ var _time_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(2078);
|
|
|
|
|
|
|
|
class ApiProxy {
|
|
constructor(plugin, hook) {
|
|
this.target = null;
|
|
this.targetQueue = [];
|
|
this.onQueue = [];
|
|
this.plugin = plugin;
|
|
this.hook = hook;
|
|
const defaultSettings = {};
|
|
if (plugin.settings) {
|
|
for (const id in plugin.settings) {
|
|
const item = plugin.settings[id];
|
|
defaultSettings[id] = item.defaultValue;
|
|
}
|
|
}
|
|
const localSettingsSaveId = `__vue-devtools-plugin-settings__${plugin.id}`;
|
|
let currentSettings = Object.assign({}, defaultSettings);
|
|
try {
|
|
const raw = localStorage.getItem(localSettingsSaveId);
|
|
const data = JSON.parse(raw);
|
|
Object.assign(currentSettings, data);
|
|
} catch (e) {
|
|
// noop
|
|
}
|
|
this.fallbacks = {
|
|
getSettings() {
|
|
return currentSettings;
|
|
},
|
|
setSettings(value) {
|
|
try {
|
|
localStorage.setItem(localSettingsSaveId, JSON.stringify(value));
|
|
} catch (e) {
|
|
// noop
|
|
}
|
|
currentSettings = value;
|
|
},
|
|
now() {
|
|
return (0,_time_js__WEBPACK_IMPORTED_MODULE_1__/* .now */ .M)();
|
|
}
|
|
};
|
|
if (hook) {
|
|
hook.on(_const_js__WEBPACK_IMPORTED_MODULE_2__/* .HOOK_PLUGIN_SETTINGS_SET */ .N, (pluginId, value) => {
|
|
if (pluginId === this.plugin.id) {
|
|
this.fallbacks.setSettings(value);
|
|
}
|
|
});
|
|
}
|
|
this.proxiedOn = new Proxy({}, {
|
|
get: (_target, prop) => {
|
|
if (this.target) {
|
|
return this.target.on[prop];
|
|
} else {
|
|
return (...args) => {
|
|
this.onQueue.push({
|
|
method: prop,
|
|
args
|
|
});
|
|
};
|
|
}
|
|
}
|
|
});
|
|
this.proxiedTarget = new Proxy({}, {
|
|
get: (_target, prop) => {
|
|
if (this.target) {
|
|
return this.target[prop];
|
|
} else if (prop === 'on') {
|
|
return this.proxiedOn;
|
|
} else if (Object.keys(this.fallbacks).includes(prop)) {
|
|
return (...args) => {
|
|
this.targetQueue.push({
|
|
method: prop,
|
|
args,
|
|
resolve: () => {}
|
|
});
|
|
return this.fallbacks[prop](...args);
|
|
};
|
|
} else {
|
|
return (...args) => {
|
|
return new Promise(resolve => {
|
|
this.targetQueue.push({
|
|
method: prop,
|
|
args,
|
|
resolve
|
|
});
|
|
});
|
|
};
|
|
}
|
|
}
|
|
});
|
|
}
|
|
async setRealTarget(target) {
|
|
this.target = target;
|
|
for (const item of this.onQueue) {
|
|
this.target.on[item.method](...item.args);
|
|
}
|
|
for (const item of this.targetQueue) {
|
|
item.resolve(await this.target[item.method](...item.args));
|
|
}
|
|
}
|
|
}
|
|
|
|
/***/ }),
|
|
|
|
/***/ 2800:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var global = __webpack_require__(4074);
|
|
var tryNodeRequire = __webpack_require__(483);
|
|
var PROPER_STRUCTURED_CLONE_TRANSFER = __webpack_require__(3117);
|
|
|
|
var structuredClone = global.structuredClone;
|
|
var $ArrayBuffer = global.ArrayBuffer;
|
|
var $MessageChannel = global.MessageChannel;
|
|
var detach = false;
|
|
var WorkerThreads, channel, buffer, $detach;
|
|
|
|
if (PROPER_STRUCTURED_CLONE_TRANSFER) {
|
|
detach = function (transferable) {
|
|
structuredClone(transferable, { transfer: [transferable] });
|
|
};
|
|
} else if ($ArrayBuffer) try {
|
|
if (!$MessageChannel) {
|
|
WorkerThreads = tryNodeRequire('worker_threads');
|
|
if (WorkerThreads) $MessageChannel = WorkerThreads.MessageChannel;
|
|
}
|
|
|
|
if ($MessageChannel) {
|
|
channel = new $MessageChannel();
|
|
buffer = new $ArrayBuffer(2);
|
|
|
|
$detach = function (transferable) {
|
|
channel.port1.postMessage(null, [transferable]);
|
|
};
|
|
|
|
if (buffer.byteLength === 2) {
|
|
$detach(buffer);
|
|
if (buffer.byteLength === 0) detach = $detach;
|
|
}
|
|
}
|
|
} catch (error) { /* empty */ }
|
|
|
|
module.exports = detach;
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 2873:
|
|
/***/ (function(__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) {
|
|
|
|
"use strict";
|
|
/* harmony import */ var _classes_URLSearchParams_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(9205);
|
|
/* harmony import */ var _classes_FormData_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6406);
|
|
/* harmony import */ var _classes_Blob_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(2271);
|
|
|
|
|
|
|
|
/* harmony default export */ __webpack_exports__.A = ({
|
|
isBrowser: true,
|
|
classes: {
|
|
URLSearchParams: _classes_URLSearchParams_js__WEBPACK_IMPORTED_MODULE_0__/* ["default"] */ .A,
|
|
FormData: _classes_FormData_js__WEBPACK_IMPORTED_MODULE_1__/* ["default"] */ .A,
|
|
Blob: _classes_Blob_js__WEBPACK_IMPORTED_MODULE_2__/* ["default"] */ .A
|
|
},
|
|
protocols: ['http', 'https', 'file', 'blob', 'url', 'data']
|
|
});
|
|
|
|
/***/ }),
|
|
|
|
/***/ 2878:
|
|
/***/ (function(__unused_webpack_module, exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var DESCRIPTORS = __webpack_require__(4911);
|
|
var call = __webpack_require__(4978);
|
|
var propertyIsEnumerableModule = __webpack_require__(3574);
|
|
var createPropertyDescriptor = __webpack_require__(5569);
|
|
var toIndexedObject = __webpack_require__(5830);
|
|
var toPropertyKey = __webpack_require__(1422);
|
|
var hasOwn = __webpack_require__(1396);
|
|
var IE8_DOM_DEFINE = __webpack_require__(7144);
|
|
|
|
// eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe
|
|
var $getOwnPropertyDescriptor = Object.getOwnPropertyDescriptor;
|
|
|
|
// `Object.getOwnPropertyDescriptor` method
|
|
// https://tc39.es/ecma262/#sec-object.getownpropertydescriptor
|
|
exports.f = DESCRIPTORS ? $getOwnPropertyDescriptor : function getOwnPropertyDescriptor(O, P) {
|
|
O = toIndexedObject(O);
|
|
P = toPropertyKey(P);
|
|
if (IE8_DOM_DEFINE) try {
|
|
return $getOwnPropertyDescriptor(O, P);
|
|
} catch (error) { /* empty */ }
|
|
if (hasOwn(O, P)) return createPropertyDescriptor(!call(propertyIsEnumerableModule.f, O, P), O[P]);
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 2936:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var global = __webpack_require__(4074);
|
|
var isObject = __webpack_require__(1909);
|
|
|
|
var document = global.document;
|
|
// typeof document.createElement is 'object' in old IE
|
|
var EXISTS = isObject(document) && isObject(document.createElement);
|
|
|
|
module.exports = function (it) {
|
|
return EXISTS ? document.createElement(it) : {};
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 2952:
|
|
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var DESCRIPTORS = __webpack_require__(4911);
|
|
var defineBuiltInAccessor = __webpack_require__(2123);
|
|
var isDetached = __webpack_require__(4259);
|
|
|
|
var ArrayBufferPrototype = ArrayBuffer.prototype;
|
|
|
|
if (DESCRIPTORS && !('detached' in ArrayBufferPrototype)) {
|
|
defineBuiltInAccessor(ArrayBufferPrototype, 'detached', {
|
|
configurable: true,
|
|
get: function detached() {
|
|
return isDetached(this);
|
|
}
|
|
});
|
|
}
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 2967:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var isNullOrUndefined = __webpack_require__(5832);
|
|
|
|
var $TypeError = TypeError;
|
|
|
|
// `RequireObjectCoercible` abstract operation
|
|
// https://tc39.es/ecma262/#sec-requireobjectcoercible
|
|
module.exports = function (it) {
|
|
if (isNullOrUndefined(it)) throw new $TypeError("Can't call method on " + it);
|
|
return it;
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 3002:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var getBuiltIn = __webpack_require__(6054);
|
|
var uncurryThis = __webpack_require__(1371);
|
|
var getOwnPropertyNamesModule = __webpack_require__(3155);
|
|
var getOwnPropertySymbolsModule = __webpack_require__(6746);
|
|
var anObject = __webpack_require__(6696);
|
|
|
|
var concat = uncurryThis([].concat);
|
|
|
|
// all object keys, includes non-enumerable and symbols
|
|
module.exports = getBuiltIn('Reflect', 'ownKeys') || function ownKeys(it) {
|
|
var keys = getOwnPropertyNamesModule.f(anObject(it));
|
|
var getOwnPropertySymbols = getOwnPropertySymbolsModule.f;
|
|
return getOwnPropertySymbols ? concat(keys, getOwnPropertySymbols(it)) : keys;
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 3009:
|
|
/***/ (function(__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) {
|
|
|
|
"use strict";
|
|
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
/* harmony export */ A: function() { return /* binding */ parseProtocol; }
|
|
/* harmony export */ });
|
|
|
|
|
|
function parseProtocol(url) {
|
|
const match = /^([-+\w]{1,25})(:?\/\/|:)/.exec(url);
|
|
return match && match[1] || '';
|
|
}
|
|
|
|
/***/ }),
|
|
|
|
/***/ 3058:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var getBuiltIn = __webpack_require__(6054);
|
|
var isCallable = __webpack_require__(6450);
|
|
var isPrototypeOf = __webpack_require__(1856);
|
|
var USE_SYMBOL_AS_UID = __webpack_require__(3167);
|
|
|
|
var $Object = Object;
|
|
|
|
module.exports = USE_SYMBOL_AS_UID ? function (it) {
|
|
return typeof it == 'symbol';
|
|
} : function (it) {
|
|
var $Symbol = getBuiltIn('Symbol');
|
|
return isCallable($Symbol) && isPrototypeOf($Symbol.prototype, $Object(it));
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 3108:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var aCallable = __webpack_require__(8951);
|
|
var anObject = __webpack_require__(6696);
|
|
var call = __webpack_require__(4978);
|
|
var toIntegerOrInfinity = __webpack_require__(9106);
|
|
var getIteratorDirect = __webpack_require__(8764);
|
|
|
|
var INVALID_SIZE = 'Invalid size';
|
|
var $RangeError = RangeError;
|
|
var $TypeError = TypeError;
|
|
var max = Math.max;
|
|
|
|
var SetRecord = function (set, intSize) {
|
|
this.set = set;
|
|
this.size = max(intSize, 0);
|
|
this.has = aCallable(set.has);
|
|
this.keys = aCallable(set.keys);
|
|
};
|
|
|
|
SetRecord.prototype = {
|
|
getIterator: function () {
|
|
return getIteratorDirect(anObject(call(this.keys, this.set)));
|
|
},
|
|
includes: function (it) {
|
|
return call(this.has, this.set, it);
|
|
}
|
|
};
|
|
|
|
// `GetSetRecord` abstract operation
|
|
// https://tc39.es/proposal-set-methods/#sec-getsetrecord
|
|
module.exports = function (obj) {
|
|
anObject(obj);
|
|
var numSize = +obj.size;
|
|
// NOTE: If size is undefined, then numSize will be NaN
|
|
// eslint-disable-next-line no-self-compare -- NaN check
|
|
if (numSize !== numSize) throw new $TypeError(INVALID_SIZE);
|
|
var intSize = toIntegerOrInfinity(numSize);
|
|
if (intSize < 0) throw new $RangeError(INVALID_SIZE);
|
|
return new SetRecord(obj, intSize);
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 3117:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var global = __webpack_require__(4074);
|
|
var fails = __webpack_require__(4212);
|
|
var V8 = __webpack_require__(491);
|
|
var IS_BROWSER = __webpack_require__(3141);
|
|
var IS_DENO = __webpack_require__(4417);
|
|
var IS_NODE = __webpack_require__(5181);
|
|
|
|
var structuredClone = global.structuredClone;
|
|
|
|
module.exports = !!structuredClone && !fails(function () {
|
|
// prevent V8 ArrayBufferDetaching protector cell invalidation and performance degradation
|
|
// https://github.com/zloirock/core-js/issues/679
|
|
if ((IS_DENO && V8 > 92) || (IS_NODE && V8 > 94) || (IS_BROWSER && V8 > 97)) return false;
|
|
var buffer = new ArrayBuffer(8);
|
|
var clone = structuredClone(buffer, { transfer: [buffer] });
|
|
return buffer.byteLength !== 0 || clone.byteLength !== 8;
|
|
});
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 3141:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var IS_DENO = __webpack_require__(4417);
|
|
var IS_NODE = __webpack_require__(5181);
|
|
|
|
module.exports = !IS_DENO && !IS_NODE
|
|
&& typeof window == 'object'
|
|
&& typeof document == 'object';
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 3148:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var hasOwn = __webpack_require__(1396);
|
|
var isCallable = __webpack_require__(6450);
|
|
var toObject = __webpack_require__(1258);
|
|
var sharedKey = __webpack_require__(2370);
|
|
var CORRECT_PROTOTYPE_GETTER = __webpack_require__(3454);
|
|
|
|
var IE_PROTO = sharedKey('IE_PROTO');
|
|
var $Object = Object;
|
|
var ObjectPrototype = $Object.prototype;
|
|
|
|
// `Object.getPrototypeOf` method
|
|
// https://tc39.es/ecma262/#sec-object.getprototypeof
|
|
// eslint-disable-next-line es/no-object-getprototypeof -- safe
|
|
module.exports = CORRECT_PROTOTYPE_GETTER ? $Object.getPrototypeOf : function (O) {
|
|
var object = toObject(O);
|
|
if (hasOwn(object, IE_PROTO)) return object[IE_PROTO];
|
|
var constructor = object.constructor;
|
|
if (isCallable(constructor) && object instanceof constructor) {
|
|
return constructor.prototype;
|
|
} return object instanceof $Object ? ObjectPrototype : null;
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 3155:
|
|
/***/ (function(__unused_webpack_module, exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var internalObjectKeys = __webpack_require__(6701);
|
|
var enumBugKeys = __webpack_require__(448);
|
|
|
|
var hiddenKeys = enumBugKeys.concat('length', 'prototype');
|
|
|
|
// `Object.getOwnPropertyNames` method
|
|
// https://tc39.es/ecma262/#sec-object.getownpropertynames
|
|
// eslint-disable-next-line es/no-object-getownpropertynames -- safe
|
|
exports.f = Object.getOwnPropertyNames || function getOwnPropertyNames(O) {
|
|
return internalObjectKeys(O, hiddenKeys);
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 3167:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
/* eslint-disable es/no-symbol -- required for testing */
|
|
var NATIVE_SYMBOL = __webpack_require__(9566);
|
|
|
|
module.exports = NATIVE_SYMBOL
|
|
&& !Symbol.sham
|
|
&& typeof Symbol.iterator == 'symbol';
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 3179:
|
|
/***/ (function(__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) {
|
|
|
|
"use strict";
|
|
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
/* harmony export */ LER: function() { return /* binding */ isVue2; },
|
|
/* harmony export */ hZp: function() { return /* binding */ set; }
|
|
/* harmony export */ });
|
|
/* unused harmony exports del, Vue2, isVue3, install */
|
|
|
|
var isVue2 = false;
|
|
var isVue3 = true;
|
|
var Vue2 = (/* unused pure expression or super */ null && (undefined));
|
|
function install() {}
|
|
function set(target, key, val) {
|
|
if (Array.isArray(target)) {
|
|
target.length = Math.max(target.length, key);
|
|
target.splice(key, 1, val);
|
|
return val;
|
|
}
|
|
target[key] = val;
|
|
return val;
|
|
}
|
|
function del(target, key) {
|
|
if (Array.isArray(target)) {
|
|
target.splice(key, 1);
|
|
return;
|
|
}
|
|
delete target[key];
|
|
}
|
|
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 3337:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var toIntegerOrInfinity = __webpack_require__(9106);
|
|
|
|
var min = Math.min;
|
|
|
|
// `ToLength` abstract operation
|
|
// https://tc39.es/ecma262/#sec-tolength
|
|
module.exports = function (argument) {
|
|
var len = toIntegerOrInfinity(argument);
|
|
return len > 0 ? min(len, 0x1FFFFFFFFFFFFF) : 0; // 2 ** 53 - 1 == 9007199254740991
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 3425:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var toIntegerOrInfinity = __webpack_require__(9106);
|
|
var toLength = __webpack_require__(3337);
|
|
|
|
var $RangeError = RangeError;
|
|
|
|
// `ToIndex` abstract operation
|
|
// https://tc39.es/ecma262/#sec-toindex
|
|
module.exports = function (it) {
|
|
if (it === undefined) return 0;
|
|
var number = toIntegerOrInfinity(it);
|
|
var length = toLength(number);
|
|
if (number !== length) throw new $RangeError('Wrong length or index');
|
|
return length;
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 3444:
|
|
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var global = __webpack_require__(4074);
|
|
var DESCRIPTORS = __webpack_require__(4911);
|
|
var defineBuiltInAccessor = __webpack_require__(2123);
|
|
var regExpFlags = __webpack_require__(8414);
|
|
var fails = __webpack_require__(4212);
|
|
|
|
// babel-minify and Closure Compiler transpiles RegExp('.', 'd') -> /./d and it causes SyntaxError
|
|
var RegExp = global.RegExp;
|
|
var RegExpPrototype = RegExp.prototype;
|
|
|
|
var FORCED = DESCRIPTORS && fails(function () {
|
|
var INDICES_SUPPORT = true;
|
|
try {
|
|
RegExp('.', 'd');
|
|
} catch (error) {
|
|
INDICES_SUPPORT = false;
|
|
}
|
|
|
|
var O = {};
|
|
// modern V8 bug
|
|
var calls = '';
|
|
var expected = INDICES_SUPPORT ? 'dgimsy' : 'gimsy';
|
|
|
|
var addGetter = function (key, chr) {
|
|
// eslint-disable-next-line es/no-object-defineproperty -- safe
|
|
Object.defineProperty(O, key, { get: function () {
|
|
calls += chr;
|
|
return true;
|
|
} });
|
|
};
|
|
|
|
var pairs = {
|
|
dotAll: 's',
|
|
global: 'g',
|
|
ignoreCase: 'i',
|
|
multiline: 'm',
|
|
sticky: 'y'
|
|
};
|
|
|
|
if (INDICES_SUPPORT) pairs.hasIndices = 'd';
|
|
|
|
for (var key in pairs) addGetter(key, pairs[key]);
|
|
|
|
// eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe
|
|
var result = Object.getOwnPropertyDescriptor(RegExpPrototype, 'flags').get.call(O);
|
|
|
|
return result !== expected || calls !== expected;
|
|
});
|
|
|
|
// `RegExp.prototype.flags` getter
|
|
// https://tc39.es/ecma262/#sec-get-regexp.prototype.flags
|
|
if (FORCED) defineBuiltInAccessor(RegExpPrototype, 'flags', {
|
|
configurable: true,
|
|
get: regExpFlags
|
|
});
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 3454:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var fails = __webpack_require__(4212);
|
|
|
|
module.exports = !fails(function () {
|
|
function F() { /* empty */ }
|
|
F.prototype.constructor = null;
|
|
// eslint-disable-next-line es/no-object-getprototypeof -- required for testing
|
|
return Object.getPrototypeOf(new F()) !== F.prototype;
|
|
});
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 3495:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var lengthOfArrayLike = __webpack_require__(4231);
|
|
|
|
// https://tc39.es/proposal-change-array-by-copy/#sec-array.prototype.toReversed
|
|
// https://tc39.es/proposal-change-array-by-copy/#sec-%typedarray%.prototype.toReversed
|
|
module.exports = function (O, C) {
|
|
var len = lengthOfArrayLike(O);
|
|
var A = new C(len);
|
|
var k = 0;
|
|
for (; k < len; k++) A[k] = O[len - k - 1];
|
|
return A;
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 3574:
|
|
/***/ (function(__unused_webpack_module, exports) {
|
|
|
|
"use strict";
|
|
|
|
var $propertyIsEnumerable = {}.propertyIsEnumerable;
|
|
// eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe
|
|
var getOwnPropertyDescriptor = Object.getOwnPropertyDescriptor;
|
|
|
|
// Nashorn ~ JDK8 bug
|
|
var NASHORN_BUG = getOwnPropertyDescriptor && !$propertyIsEnumerable.call({ 1: 2 }, 1);
|
|
|
|
// `Object.prototype.propertyIsEnumerable` method implementation
|
|
// https://tc39.es/ecma262/#sec-object.prototype.propertyisenumerable
|
|
exports.f = NASHORN_BUG ? function propertyIsEnumerable(V) {
|
|
var descriptor = getOwnPropertyDescriptor(this, V);
|
|
return !!descriptor && descriptor.enumerable;
|
|
} : $propertyIsEnumerable;
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 3633:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var classofRaw = __webpack_require__(1079);
|
|
var uncurryThis = __webpack_require__(1371);
|
|
|
|
module.exports = function (fn) {
|
|
// Nashorn bug:
|
|
// https://github.com/zloirock/core-js/issues/1128
|
|
// https://github.com/zloirock/core-js/issues/1130
|
|
if (classofRaw(fn) === 'Function') return uncurryThis(fn);
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 3647:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var isCallable = __webpack_require__(6450);
|
|
var definePropertyModule = __webpack_require__(8564);
|
|
var makeBuiltIn = __webpack_require__(4544);
|
|
var defineGlobalProperty = __webpack_require__(8028);
|
|
|
|
module.exports = function (O, key, value, options) {
|
|
if (!options) options = {};
|
|
var simple = options.enumerable;
|
|
var name = options.name !== undefined ? options.name : key;
|
|
if (isCallable(value)) makeBuiltIn(value, name, options);
|
|
if (options.global) {
|
|
if (simple) O[key] = value;
|
|
else defineGlobalProperty(key, value);
|
|
} else {
|
|
try {
|
|
if (!options.unsafe) delete O[key];
|
|
else if (O[key]) simple = true;
|
|
} catch (error) { /* empty */ }
|
|
if (simple) O[key] = value;
|
|
else definePropertyModule.f(O, key, {
|
|
value: value,
|
|
enumerable: false,
|
|
configurable: !options.nonConfigurable,
|
|
writable: !options.nonWritable
|
|
});
|
|
} return O;
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 3741:
|
|
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var $ = __webpack_require__(8155);
|
|
var call = __webpack_require__(4978);
|
|
var aCallable = __webpack_require__(8951);
|
|
var anObject = __webpack_require__(6696);
|
|
var getIteratorDirect = __webpack_require__(8764);
|
|
var createIteratorProxy = __webpack_require__(7254);
|
|
var callWithSafeIterationClosing = __webpack_require__(5146);
|
|
var IS_PURE = __webpack_require__(8072);
|
|
|
|
var IteratorProxy = createIteratorProxy(function () {
|
|
var iterator = this.iterator;
|
|
var predicate = this.predicate;
|
|
var next = this.next;
|
|
var result, done, value;
|
|
while (true) {
|
|
result = anObject(call(next, iterator));
|
|
done = this.done = !!result.done;
|
|
if (done) return;
|
|
value = result.value;
|
|
if (callWithSafeIterationClosing(iterator, predicate, [value, this.counter++], true)) return value;
|
|
}
|
|
});
|
|
|
|
// `Iterator.prototype.filter` method
|
|
// https://github.com/tc39/proposal-iterator-helpers
|
|
$({ target: 'Iterator', proto: true, real: true, forced: IS_PURE }, {
|
|
filter: function filter(predicate) {
|
|
anObject(this);
|
|
aCallable(predicate);
|
|
return new IteratorProxy(getIteratorDirect(this), {
|
|
predicate: predicate
|
|
});
|
|
}
|
|
});
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 3773:
|
|
/***/ (function(__unused_webpack___webpack_module__, __webpack_exports__) {
|
|
|
|
"use strict";
|
|
|
|
|
|
/* harmony default export */ __webpack_exports__.A = ({
|
|
silentJSONParsing: true,
|
|
forcedJSONParsing: true,
|
|
clarifyTimeoutError: false
|
|
});
|
|
|
|
/***/ }),
|
|
|
|
/***/ 3876:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var wellKnownSymbol = __webpack_require__(9760);
|
|
var create = __webpack_require__(9891);
|
|
var defineProperty = (__webpack_require__(8564).f);
|
|
|
|
var UNSCOPABLES = wellKnownSymbol('unscopables');
|
|
var ArrayPrototype = Array.prototype;
|
|
|
|
// Array.prototype[@@unscopables]
|
|
// https://tc39.es/ecma262/#sec-array.prototype-@@unscopables
|
|
if (ArrayPrototype[UNSCOPABLES] === undefined) {
|
|
defineProperty(ArrayPrototype, UNSCOPABLES, {
|
|
configurable: true,
|
|
value: create(null)
|
|
});
|
|
}
|
|
|
|
// add a key to Array.prototype[@@unscopables]
|
|
module.exports = function (key) {
|
|
ArrayPrototype[UNSCOPABLES][key] = true;
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 3991:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var has = (__webpack_require__(5057).has);
|
|
|
|
// Perform ? RequireInternalSlot(M, [[SetData]])
|
|
module.exports = function (it) {
|
|
has(it);
|
|
return it;
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 4006:
|
|
/***/ (function(module) {
|
|
|
|
"use strict";
|
|
|
|
// `CreateIterResultObject` abstract operation
|
|
// https://tc39.es/ecma262/#sec-createiterresultobject
|
|
module.exports = function (value, done) {
|
|
return { value: value, done: done };
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 4062:
|
|
/***/ (function(__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) {
|
|
|
|
"use strict";
|
|
/* harmony import */ var _utils_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(5813);
|
|
/* harmony import */ var _helpers_bind_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(5603);
|
|
/* harmony import */ var _core_Axios_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(9972);
|
|
/* harmony import */ var _core_mergeConfig_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(308);
|
|
/* harmony import */ var _defaults_index_js__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(7719);
|
|
/* harmony import */ var _helpers_formDataToJSON_js__WEBPACK_IMPORTED_MODULE_14__ = __webpack_require__(797);
|
|
/* harmony import */ var _cancel_CanceledError_js__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(7080);
|
|
/* harmony import */ var _cancel_CancelToken_js__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(6255);
|
|
/* harmony import */ var _cancel_isCancel_js__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(8701);
|
|
/* harmony import */ var _env_data_js__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(7958);
|
|
/* harmony import */ var _helpers_toFormData_js__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(6631);
|
|
/* harmony import */ var _core_AxiosError_js__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(956);
|
|
/* harmony import */ var _helpers_spread_js__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(6587);
|
|
/* harmony import */ var _helpers_isAxiosError_js__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(7420);
|
|
/* harmony import */ var _core_AxiosHeaders_js__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(292);
|
|
/* harmony import */ var _adapters_adapters_js__WEBPACK_IMPORTED_MODULE_15__ = __webpack_require__(6905);
|
|
/* harmony import */ var _helpers_HttpStatusCode_js__WEBPACK_IMPORTED_MODULE_16__ = __webpack_require__(187);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
/**
|
|
* Create an instance of Axios
|
|
*
|
|
* @param {Object} defaultConfig The default config for the instance
|
|
*
|
|
* @returns {Axios} A new instance of Axios
|
|
*/
|
|
function createInstance(defaultConfig) {
|
|
const context = new _core_Axios_js__WEBPACK_IMPORTED_MODULE_0__/* ["default"] */ .A(defaultConfig);
|
|
const instance = (0,_helpers_bind_js__WEBPACK_IMPORTED_MODULE_1__/* ["default"] */ .A)(_core_Axios_js__WEBPACK_IMPORTED_MODULE_0__/* ["default"] */ .A.prototype.request, context);
|
|
|
|
// Copy axios.prototype to instance
|
|
_utils_js__WEBPACK_IMPORTED_MODULE_2__/* ["default"] */ .A.extend(instance, _core_Axios_js__WEBPACK_IMPORTED_MODULE_0__/* ["default"] */ .A.prototype, context, {
|
|
allOwnKeys: true
|
|
});
|
|
|
|
// Copy context to instance
|
|
_utils_js__WEBPACK_IMPORTED_MODULE_2__/* ["default"] */ .A.extend(instance, context, null, {
|
|
allOwnKeys: true
|
|
});
|
|
|
|
// Factory for creating new instances
|
|
instance.create = function create(instanceConfig) {
|
|
return createInstance((0,_core_mergeConfig_js__WEBPACK_IMPORTED_MODULE_3__/* ["default"] */ .A)(defaultConfig, instanceConfig));
|
|
};
|
|
return instance;
|
|
}
|
|
|
|
// Create the default instance to be exported
|
|
const axios = createInstance(_defaults_index_js__WEBPACK_IMPORTED_MODULE_4__/* ["default"] */ .A);
|
|
|
|
// Expose Axios class to allow class inheritance
|
|
axios.Axios = _core_Axios_js__WEBPACK_IMPORTED_MODULE_0__/* ["default"] */ .A;
|
|
|
|
// Expose Cancel & CancelToken
|
|
axios.CanceledError = _cancel_CanceledError_js__WEBPACK_IMPORTED_MODULE_5__/* ["default"] */ .A;
|
|
axios.CancelToken = _cancel_CancelToken_js__WEBPACK_IMPORTED_MODULE_6__/* ["default"] */ .A;
|
|
axios.isCancel = _cancel_isCancel_js__WEBPACK_IMPORTED_MODULE_7__/* ["default"] */ .A;
|
|
axios.VERSION = _env_data_js__WEBPACK_IMPORTED_MODULE_8__/* .VERSION */ .x;
|
|
axios.toFormData = _helpers_toFormData_js__WEBPACK_IMPORTED_MODULE_9__/* ["default"] */ .A;
|
|
|
|
// Expose AxiosError class
|
|
axios.AxiosError = _core_AxiosError_js__WEBPACK_IMPORTED_MODULE_10__/* ["default"] */ .A;
|
|
|
|
// alias for CanceledError for backward compatibility
|
|
axios.Cancel = axios.CanceledError;
|
|
|
|
// Expose all/spread
|
|
axios.all = function all(promises) {
|
|
return Promise.all(promises);
|
|
};
|
|
axios.spread = _helpers_spread_js__WEBPACK_IMPORTED_MODULE_11__/* ["default"] */ .A;
|
|
|
|
// Expose isAxiosError
|
|
axios.isAxiosError = _helpers_isAxiosError_js__WEBPACK_IMPORTED_MODULE_12__/* ["default"] */ .A;
|
|
|
|
// Expose mergeConfig
|
|
axios.mergeConfig = _core_mergeConfig_js__WEBPACK_IMPORTED_MODULE_3__/* ["default"] */ .A;
|
|
axios.AxiosHeaders = _core_AxiosHeaders_js__WEBPACK_IMPORTED_MODULE_13__/* ["default"] */ .A;
|
|
axios.formToJSON = thing => (0,_helpers_formDataToJSON_js__WEBPACK_IMPORTED_MODULE_14__/* ["default"] */ .A)(_utils_js__WEBPACK_IMPORTED_MODULE_2__/* ["default"] */ .A.isHTMLForm(thing) ? new FormData(thing) : thing);
|
|
axios.getAdapter = _adapters_adapters_js__WEBPACK_IMPORTED_MODULE_15__/* ["default"] */ .A.getAdapter;
|
|
axios.HttpStatusCode = _helpers_HttpStatusCode_js__WEBPACK_IMPORTED_MODULE_16__/* ["default"] */ .A;
|
|
axios.default = axios;
|
|
|
|
// this module should only have a default export
|
|
/* harmony default export */ __webpack_exports__.A = (axios);
|
|
|
|
/***/ }),
|
|
|
|
/***/ 4074:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var check = function (it) {
|
|
return it && it.Math === Math && it;
|
|
};
|
|
|
|
// https://github.com/zloirock/core-js/issues/86#issuecomment-115759028
|
|
module.exports =
|
|
// eslint-disable-next-line es/no-global-this -- safe
|
|
check(typeof globalThis == 'object' && globalThis) ||
|
|
check(typeof window == 'object' && window) ||
|
|
// eslint-disable-next-line no-restricted-globals -- safe
|
|
check(typeof self == 'object' && self) ||
|
|
check(typeof __webpack_require__.g == 'object' && __webpack_require__.g) ||
|
|
check(typeof this == 'object' && this) ||
|
|
// eslint-disable-next-line no-new-func -- fallback
|
|
(function () { return this; })() || Function('return this')();
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 4091:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var global = __webpack_require__(4074);
|
|
|
|
module.exports = function (CONSTRUCTOR, METHOD) {
|
|
var Constructor = global[CONSTRUCTOR];
|
|
var Prototype = Constructor && Constructor.prototype;
|
|
return Prototype && Prototype[METHOD];
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 4187:
|
|
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) {
|
|
|
|
"use strict";
|
|
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
/* harmony export */ $u: function() { return /* binding */ onUpdated; },
|
|
/* harmony export */ CE: function() { return /* binding */ createElementBlock; },
|
|
/* harmony export */ Df: function() { return /* binding */ getTransitionRawChildren; },
|
|
/* harmony export */ EW: function() { return /* binding */ computed; },
|
|
/* harmony export */ FK: function() { return /* binding */ Fragment; },
|
|
/* harmony export */ Fv: function() { return /* binding */ createStaticVNode; },
|
|
/* harmony export */ Gy: function() { return /* binding */ useTransitionState; },
|
|
/* harmony export */ Im: function() { return /* binding */ Teleport; },
|
|
/* harmony export */ K9: function() { return /* binding */ createRenderer; },
|
|
/* harmony export */ Lk: function() { return /* binding */ createBaseVNode; },
|
|
/* harmony export */ MZ: function() { return /* binding */ setTransitionHooks; },
|
|
/* harmony export */ OW: function() { return /* binding */ resolveTransitionHooks; },
|
|
/* harmony export */ PS: function() { return /* binding */ hasInjectionContext; },
|
|
/* harmony export */ Q3: function() { return /* binding */ createCommentVNode; },
|
|
/* harmony export */ QP: function() { return /* binding */ BaseTransitionPropsValidators; },
|
|
/* harmony export */ WQ: function() { return /* binding */ inject; },
|
|
/* harmony export */ Wv: function() { return /* binding */ createBlock; },
|
|
/* harmony export */ bF: function() { return /* binding */ createVNode; },
|
|
/* harmony export */ bo: function() { return /* binding */ withDirectives; },
|
|
/* harmony export */ dY: function() { return /* binding */ nextTick; },
|
|
/* harmony export */ eW: function() { return /* binding */ createTextVNode; },
|
|
/* harmony export */ h: function() { return /* binding */ h; },
|
|
/* harmony export */ nI: function() { return /* binding */ getCurrentInstance; },
|
|
/* harmony export */ pI: function() { return /* binding */ renderList; },
|
|
/* harmony export */ pM: function() { return /* binding */ defineComponent; },
|
|
/* harmony export */ qL: function() { return /* binding */ callWithAsyncErrorHandling; },
|
|
/* harmony export */ sV: function() { return /* binding */ onMounted; },
|
|
/* harmony export */ uX: function() { return /* binding */ openBlock; },
|
|
/* harmony export */ wB: function() { return /* binding */ watch; },
|
|
/* harmony export */ xo: function() { return /* binding */ onBeforeUnmount; }
|
|
/* harmony export */ });
|
|
/* unused harmony exports BaseTransition, Comment, DeprecationTypes, ErrorCodes, ErrorTypeStrings, KeepAlive, Static, Suspense, Text, assertNumber, callWithErrorHandling, cloneVNode, compatUtils, createHydrationRenderer, createPropsRestProxy, createSlots, defineAsyncComponent, defineEmits, defineExpose, defineModel, defineOptions, defineProps, defineSlots, devtools, guardReactiveProps, handleError, hydrateOnIdle, hydrateOnInteraction, hydrateOnMediaQuery, hydrateOnVisible, initCustomFormatter, isMemoSame, isRuntimeOnly, isVNode, mergeDefaults, mergeModels, mergeProps, onActivated, onBeforeMount, onBeforeUpdate, onDeactivated, onErrorCaptured, onRenderTracked, onRenderTriggered, onServerPrefetch, onUnmounted, popScopeId, provide, pushScopeId, queuePostFlushCb, registerRuntimeCompiler, renderSlot, resolveComponent, resolveDirective, resolveDynamicComponent, resolveFilter, setBlockTracking, setDevtoolsHook, ssrContextKey, ssrUtils, toHandlers, transformVNodeArgs, useAttrs, useId, useModel, useSSRContext, useSlots, useTemplateRef, version, warn, watchEffect, watchPostEffect, watchSyncEffect, withAsyncContext, withCtx, withDefaults, withMemo, withScopeId */
|
|
/* harmony import */ var core_js_modules_es_array_push_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(5513);
|
|
/* harmony import */ var core_js_modules_es_array_push_js__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_array_push_js__WEBPACK_IMPORTED_MODULE_0__);
|
|
/* harmony import */ var core_js_modules_es_regexp_flags_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(3444);
|
|
/* harmony import */ var core_js_modules_es_regexp_flags_js__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_regexp_flags_js__WEBPACK_IMPORTED_MODULE_1__);
|
|
/* harmony import */ var core_js_modules_esnext_iterator_constructor_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(7195);
|
|
/* harmony import */ var core_js_modules_esnext_iterator_constructor_js__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_esnext_iterator_constructor_js__WEBPACK_IMPORTED_MODULE_2__);
|
|
/* harmony import */ var core_js_modules_esnext_iterator_every_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(2176);
|
|
/* harmony import */ var core_js_modules_esnext_iterator_every_js__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_esnext_iterator_every_js__WEBPACK_IMPORTED_MODULE_3__);
|
|
/* harmony import */ var core_js_modules_esnext_iterator_filter_js__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(3741);
|
|
/* harmony import */ var core_js_modules_esnext_iterator_filter_js__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_esnext_iterator_filter_js__WEBPACK_IMPORTED_MODULE_4__);
|
|
/* harmony import */ var core_js_modules_esnext_iterator_for_each_js__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(680);
|
|
/* harmony import */ var core_js_modules_esnext_iterator_for_each_js__WEBPACK_IMPORTED_MODULE_5___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_esnext_iterator_for_each_js__WEBPACK_IMPORTED_MODULE_5__);
|
|
/* harmony import */ var core_js_modules_esnext_iterator_map_js__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(793);
|
|
/* harmony import */ var core_js_modules_esnext_iterator_map_js__WEBPACK_IMPORTED_MODULE_6___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_esnext_iterator_map_js__WEBPACK_IMPORTED_MODULE_6__);
|
|
/* harmony import */ var core_js_modules_esnext_iterator_reduce_js__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(5729);
|
|
/* harmony import */ var core_js_modules_esnext_iterator_reduce_js__WEBPACK_IMPORTED_MODULE_7___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_esnext_iterator_reduce_js__WEBPACK_IMPORTED_MODULE_7__);
|
|
/* harmony import */ var core_js_modules_esnext_iterator_some_js__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(6071);
|
|
/* harmony import */ var core_js_modules_esnext_iterator_some_js__WEBPACK_IMPORTED_MODULE_8___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_esnext_iterator_some_js__WEBPACK_IMPORTED_MODULE_8__);
|
|
/* harmony import */ var core_js_modules_esnext_set_difference_v2_js__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(8438);
|
|
/* harmony import */ var core_js_modules_esnext_set_difference_v2_js__WEBPACK_IMPORTED_MODULE_9___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_esnext_set_difference_v2_js__WEBPACK_IMPORTED_MODULE_9__);
|
|
/* harmony import */ var core_js_modules_esnext_set_intersection_v2_js__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(6768);
|
|
/* harmony import */ var core_js_modules_esnext_set_intersection_v2_js__WEBPACK_IMPORTED_MODULE_10___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_esnext_set_intersection_v2_js__WEBPACK_IMPORTED_MODULE_10__);
|
|
/* harmony import */ var core_js_modules_esnext_set_is_disjoint_from_v2_js__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(2409);
|
|
/* harmony import */ var core_js_modules_esnext_set_is_disjoint_from_v2_js__WEBPACK_IMPORTED_MODULE_11___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_esnext_set_is_disjoint_from_v2_js__WEBPACK_IMPORTED_MODULE_11__);
|
|
/* harmony import */ var core_js_modules_esnext_set_is_subset_of_v2_js__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(9488);
|
|
/* harmony import */ var core_js_modules_esnext_set_is_subset_of_v2_js__WEBPACK_IMPORTED_MODULE_12___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_esnext_set_is_subset_of_v2_js__WEBPACK_IMPORTED_MODULE_12__);
|
|
/* harmony import */ var core_js_modules_esnext_set_is_superset_of_v2_js__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(6591);
|
|
/* harmony import */ var core_js_modules_esnext_set_is_superset_of_v2_js__WEBPACK_IMPORTED_MODULE_13___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_esnext_set_is_superset_of_v2_js__WEBPACK_IMPORTED_MODULE_13__);
|
|
/* harmony import */ var core_js_modules_esnext_set_symmetric_difference_v2_js__WEBPACK_IMPORTED_MODULE_14__ = __webpack_require__(5412);
|
|
/* harmony import */ var core_js_modules_esnext_set_symmetric_difference_v2_js__WEBPACK_IMPORTED_MODULE_14___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_esnext_set_symmetric_difference_v2_js__WEBPACK_IMPORTED_MODULE_14__);
|
|
/* harmony import */ var core_js_modules_esnext_set_union_v2_js__WEBPACK_IMPORTED_MODULE_15__ = __webpack_require__(9214);
|
|
/* harmony import */ var core_js_modules_esnext_set_union_v2_js__WEBPACK_IMPORTED_MODULE_15___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_esnext_set_union_v2_js__WEBPACK_IMPORTED_MODULE_15__);
|
|
/* harmony import */ var _vue_reactivity__WEBPACK_IMPORTED_MODULE_17__ = __webpack_require__(7987);
|
|
/* harmony import */ var _vue_shared__WEBPACK_IMPORTED_MODULE_16__ = __webpack_require__(4546);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
/**
|
|
* @vue/runtime-core v3.5.13
|
|
* (c) 2018-present Yuxi (Evan) You and Vue contributors
|
|
* @license MIT
|
|
**/
|
|
|
|
|
|
|
|
|
|
const stack = [];
|
|
function pushWarningContext(vnode) {
|
|
stack.push(vnode);
|
|
}
|
|
function popWarningContext() {
|
|
stack.pop();
|
|
}
|
|
let isWarning = false;
|
|
function warn$1(msg, ...args) {
|
|
if (isWarning) return;
|
|
isWarning = true;
|
|
pauseTracking();
|
|
const instance = stack.length ? stack[stack.length - 1].component : null;
|
|
const appWarnHandler = instance && instance.appContext.config.warnHandler;
|
|
const trace = getComponentTrace();
|
|
if (appWarnHandler) {
|
|
callWithErrorHandling(appWarnHandler, instance, 11, [
|
|
// eslint-disable-next-line no-restricted-syntax
|
|
msg + args.map(a => {
|
|
var _a, _b;
|
|
return (_b = (_a = a.toString) == null ? void 0 : _a.call(a)) != null ? _b : JSON.stringify(a);
|
|
}).join(""), instance && instance.proxy, trace.map(({
|
|
vnode
|
|
}) => `at <${formatComponentName(instance, vnode.type)}>`).join("\n"), trace]);
|
|
} else {
|
|
const warnArgs = [`[Vue warn]: ${msg}`, ...args];
|
|
if (trace.length &&
|
|
// avoid spamming console during tests
|
|
true) {
|
|
warnArgs.push(`
|
|
`, ...formatTrace(trace));
|
|
}
|
|
console.warn(...warnArgs);
|
|
}
|
|
resetTracking();
|
|
isWarning = false;
|
|
}
|
|
function getComponentTrace() {
|
|
let currentVNode = stack[stack.length - 1];
|
|
if (!currentVNode) {
|
|
return [];
|
|
}
|
|
const normalizedStack = [];
|
|
while (currentVNode) {
|
|
const last = normalizedStack[0];
|
|
if (last && last.vnode === currentVNode) {
|
|
last.recurseCount++;
|
|
} else {
|
|
normalizedStack.push({
|
|
vnode: currentVNode,
|
|
recurseCount: 0
|
|
});
|
|
}
|
|
const parentInstance = currentVNode.component && currentVNode.component.parent;
|
|
currentVNode = parentInstance && parentInstance.vnode;
|
|
}
|
|
return normalizedStack;
|
|
}
|
|
function formatTrace(trace) {
|
|
const logs = [];
|
|
trace.forEach((entry, i) => {
|
|
logs.push(...(i === 0 ? [] : [`
|
|
`]), ...formatTraceEntry(entry));
|
|
});
|
|
return logs;
|
|
}
|
|
function formatTraceEntry({
|
|
vnode,
|
|
recurseCount
|
|
}) {
|
|
const postfix = recurseCount > 0 ? `... (${recurseCount} recursive calls)` : ``;
|
|
const isRoot = vnode.component ? vnode.component.parent == null : false;
|
|
const open = ` at <${formatComponentName(vnode.component, vnode.type, isRoot)}`;
|
|
const close = `>` + postfix;
|
|
return vnode.props ? [open, ...formatProps(vnode.props), close] : [open + close];
|
|
}
|
|
function formatProps(props) {
|
|
const res = [];
|
|
const keys = Object.keys(props);
|
|
keys.slice(0, 3).forEach(key => {
|
|
res.push(...formatProp(key, props[key]));
|
|
});
|
|
if (keys.length > 3) {
|
|
res.push(` ...`);
|
|
}
|
|
return res;
|
|
}
|
|
function formatProp(key, value, raw) {
|
|
if (isString(value)) {
|
|
value = JSON.stringify(value);
|
|
return raw ? value : [`${key}=${value}`];
|
|
} else if (typeof value === "number" || typeof value === "boolean" || value == null) {
|
|
return raw ? value : [`${key}=${value}`];
|
|
} else if (isRef(value)) {
|
|
value = formatProp(key, toRaw(value.value), true);
|
|
return raw ? value : [`${key}=Ref<`, value, `>`];
|
|
} else if (isFunction(value)) {
|
|
return [`${key}=fn${value.name ? `<${value.name}>` : ``}`];
|
|
} else {
|
|
value = toRaw(value);
|
|
return raw ? value : [`${key}=`, value];
|
|
}
|
|
}
|
|
function assertNumber(val, type) {
|
|
if (true) return;
|
|
if (val === void 0) {
|
|
return;
|
|
} else if (typeof val !== "number") {
|
|
warn$1(`${type} is not a valid number - got ${JSON.stringify(val)}.`);
|
|
} else if (isNaN(val)) {
|
|
warn$1(`${type} is NaN - the duration expression might be incorrect.`);
|
|
}
|
|
}
|
|
const ErrorCodes = {
|
|
"SETUP_FUNCTION": 0,
|
|
"0": "SETUP_FUNCTION",
|
|
"RENDER_FUNCTION": 1,
|
|
"1": "RENDER_FUNCTION",
|
|
"NATIVE_EVENT_HANDLER": 5,
|
|
"5": "NATIVE_EVENT_HANDLER",
|
|
"COMPONENT_EVENT_HANDLER": 6,
|
|
"6": "COMPONENT_EVENT_HANDLER",
|
|
"VNODE_HOOK": 7,
|
|
"7": "VNODE_HOOK",
|
|
"DIRECTIVE_HOOK": 8,
|
|
"8": "DIRECTIVE_HOOK",
|
|
"TRANSITION_HOOK": 9,
|
|
"9": "TRANSITION_HOOK",
|
|
"APP_ERROR_HANDLER": 10,
|
|
"10": "APP_ERROR_HANDLER",
|
|
"APP_WARN_HANDLER": 11,
|
|
"11": "APP_WARN_HANDLER",
|
|
"FUNCTION_REF": 12,
|
|
"12": "FUNCTION_REF",
|
|
"ASYNC_COMPONENT_LOADER": 13,
|
|
"13": "ASYNC_COMPONENT_LOADER",
|
|
"SCHEDULER": 14,
|
|
"14": "SCHEDULER",
|
|
"COMPONENT_UPDATE": 15,
|
|
"15": "COMPONENT_UPDATE",
|
|
"APP_UNMOUNT_CLEANUP": 16,
|
|
"16": "APP_UNMOUNT_CLEANUP"
|
|
};
|
|
const ErrorTypeStrings$1 = {
|
|
["sp"]: "serverPrefetch hook",
|
|
["bc"]: "beforeCreate hook",
|
|
["c"]: "created hook",
|
|
["bm"]: "beforeMount hook",
|
|
["m"]: "mounted hook",
|
|
["bu"]: "beforeUpdate hook",
|
|
["u"]: "updated",
|
|
["bum"]: "beforeUnmount hook",
|
|
["um"]: "unmounted hook",
|
|
["a"]: "activated hook",
|
|
["da"]: "deactivated hook",
|
|
["ec"]: "errorCaptured hook",
|
|
["rtc"]: "renderTracked hook",
|
|
["rtg"]: "renderTriggered hook",
|
|
[0]: "setup function",
|
|
[1]: "render function",
|
|
[2]: "watcher getter",
|
|
[3]: "watcher callback",
|
|
[4]: "watcher cleanup function",
|
|
[5]: "native event handler",
|
|
[6]: "component event handler",
|
|
[7]: "vnode hook",
|
|
[8]: "directive hook",
|
|
[9]: "transition hook",
|
|
[10]: "app errorHandler",
|
|
[11]: "app warnHandler",
|
|
[12]: "ref function",
|
|
[13]: "async component loader",
|
|
[14]: "scheduler flush",
|
|
[15]: "component update",
|
|
[16]: "app unmount cleanup function"
|
|
};
|
|
function callWithErrorHandling(fn, instance, type, args) {
|
|
try {
|
|
return args ? fn(...args) : fn();
|
|
} catch (err) {
|
|
handleError(err, instance, type);
|
|
}
|
|
}
|
|
function callWithAsyncErrorHandling(fn, instance, type, args) {
|
|
if ((0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .isFunction */ .Tn)(fn)) {
|
|
const res = callWithErrorHandling(fn, instance, type, args);
|
|
if (res && (0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .isPromise */ .yL)(res)) {
|
|
res.catch(err => {
|
|
handleError(err, instance, type);
|
|
});
|
|
}
|
|
return res;
|
|
}
|
|
if ((0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .isArray */ .cy)(fn)) {
|
|
const values = [];
|
|
for (let i = 0; i < fn.length; i++) {
|
|
values.push(callWithAsyncErrorHandling(fn[i], instance, type, args));
|
|
}
|
|
return values;
|
|
} else if (false) {}
|
|
}
|
|
function handleError(err, instance, type, throwInDev = true) {
|
|
const contextVNode = instance ? instance.vnode : null;
|
|
const {
|
|
errorHandler,
|
|
throwUnhandledErrorInProduction
|
|
} = instance && instance.appContext.config || _vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .EMPTY_OBJ */ .MZ;
|
|
if (instance) {
|
|
let cur = instance.parent;
|
|
const exposedInstance = instance.proxy;
|
|
const errorInfo = false ? 0 : `https://vuejs.org/error-reference/#runtime-${type}`;
|
|
while (cur) {
|
|
const errorCapturedHooks = cur.ec;
|
|
if (errorCapturedHooks) {
|
|
for (let i = 0; i < errorCapturedHooks.length; i++) {
|
|
if (errorCapturedHooks[i](err, exposedInstance, errorInfo) === false) {
|
|
return;
|
|
}
|
|
}
|
|
}
|
|
cur = cur.parent;
|
|
}
|
|
if (errorHandler) {
|
|
(0,_vue_reactivity__WEBPACK_IMPORTED_MODULE_17__/* .pauseTracking */ .C4)();
|
|
callWithErrorHandling(errorHandler, null, 10, [err, exposedInstance, errorInfo]);
|
|
(0,_vue_reactivity__WEBPACK_IMPORTED_MODULE_17__/* .resetTracking */ .bl)();
|
|
return;
|
|
}
|
|
}
|
|
logError(err, type, contextVNode, throwInDev, throwUnhandledErrorInProduction);
|
|
}
|
|
function logError(err, type, contextVNode, throwInDev = true, throwInProd = false) {
|
|
if (false) {} else if (throwInProd) {
|
|
throw err;
|
|
} else {
|
|
console.error(err);
|
|
}
|
|
}
|
|
const queue = [];
|
|
let flushIndex = -1;
|
|
const pendingPostFlushCbs = [];
|
|
let activePostFlushCbs = null;
|
|
let postFlushIndex = 0;
|
|
const resolvedPromise = /* @__PURE__ */Promise.resolve();
|
|
let currentFlushPromise = null;
|
|
const RECURSION_LIMIT = 100;
|
|
function nextTick(fn) {
|
|
const p = currentFlushPromise || resolvedPromise;
|
|
return fn ? p.then(this ? fn.bind(this) : fn) : p;
|
|
}
|
|
function findInsertionIndex(id) {
|
|
let start = flushIndex + 1;
|
|
let end = queue.length;
|
|
while (start < end) {
|
|
const middle = start + end >>> 1;
|
|
const middleJob = queue[middle];
|
|
const middleJobId = getId(middleJob);
|
|
if (middleJobId < id || middleJobId === id && middleJob.flags & 2) {
|
|
start = middle + 1;
|
|
} else {
|
|
end = middle;
|
|
}
|
|
}
|
|
return start;
|
|
}
|
|
function queueJob(job) {
|
|
if (!(job.flags & 1)) {
|
|
const jobId = getId(job);
|
|
const lastJob = queue[queue.length - 1];
|
|
if (!lastJob ||
|
|
// fast path when the job id is larger than the tail
|
|
!(job.flags & 2) && jobId >= getId(lastJob)) {
|
|
queue.push(job);
|
|
} else {
|
|
queue.splice(findInsertionIndex(jobId), 0, job);
|
|
}
|
|
job.flags |= 1;
|
|
queueFlush();
|
|
}
|
|
}
|
|
function queueFlush() {
|
|
if (!currentFlushPromise) {
|
|
currentFlushPromise = resolvedPromise.then(flushJobs);
|
|
}
|
|
}
|
|
function queuePostFlushCb(cb) {
|
|
if (!(0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .isArray */ .cy)(cb)) {
|
|
if (activePostFlushCbs && cb.id === -1) {
|
|
activePostFlushCbs.splice(postFlushIndex + 1, 0, cb);
|
|
} else if (!(cb.flags & 1)) {
|
|
pendingPostFlushCbs.push(cb);
|
|
cb.flags |= 1;
|
|
}
|
|
} else {
|
|
pendingPostFlushCbs.push(...cb);
|
|
}
|
|
queueFlush();
|
|
}
|
|
function flushPreFlushCbs(instance, seen, i = flushIndex + 1) {
|
|
if (false) {}
|
|
for (; i < queue.length; i++) {
|
|
const cb = queue[i];
|
|
if (cb && cb.flags & 2) {
|
|
if (instance && cb.id !== instance.uid) {
|
|
continue;
|
|
}
|
|
if (false) {}
|
|
queue.splice(i, 1);
|
|
i--;
|
|
if (cb.flags & 4) {
|
|
cb.flags &= ~1;
|
|
}
|
|
cb();
|
|
if (!(cb.flags & 4)) {
|
|
cb.flags &= ~1;
|
|
}
|
|
}
|
|
}
|
|
}
|
|
function flushPostFlushCbs(seen) {
|
|
if (pendingPostFlushCbs.length) {
|
|
const deduped = [...new Set(pendingPostFlushCbs)].sort((a, b) => getId(a) - getId(b));
|
|
pendingPostFlushCbs.length = 0;
|
|
if (activePostFlushCbs) {
|
|
activePostFlushCbs.push(...deduped);
|
|
return;
|
|
}
|
|
activePostFlushCbs = deduped;
|
|
if (false) {}
|
|
for (postFlushIndex = 0; postFlushIndex < activePostFlushCbs.length; postFlushIndex++) {
|
|
const cb = activePostFlushCbs[postFlushIndex];
|
|
if (false) {}
|
|
if (cb.flags & 4) {
|
|
cb.flags &= ~1;
|
|
}
|
|
if (!(cb.flags & 8)) cb();
|
|
cb.flags &= ~1;
|
|
}
|
|
activePostFlushCbs = null;
|
|
postFlushIndex = 0;
|
|
}
|
|
}
|
|
const getId = job => job.id == null ? job.flags & 2 ? -1 : Infinity : job.id;
|
|
function flushJobs(seen) {
|
|
if (false) {}
|
|
const check = false ? 0 : _vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .NOOP */ .tE;
|
|
try {
|
|
for (flushIndex = 0; flushIndex < queue.length; flushIndex++) {
|
|
const job = queue[flushIndex];
|
|
if (job && !(job.flags & 8)) {
|
|
if (false) {}
|
|
if (job.flags & 4) {
|
|
job.flags &= ~1;
|
|
}
|
|
callWithErrorHandling(job, job.i, job.i ? 15 : 14);
|
|
if (!(job.flags & 4)) {
|
|
job.flags &= ~1;
|
|
}
|
|
}
|
|
}
|
|
} finally {
|
|
for (; flushIndex < queue.length; flushIndex++) {
|
|
const job = queue[flushIndex];
|
|
if (job) {
|
|
job.flags &= ~1;
|
|
}
|
|
}
|
|
flushIndex = -1;
|
|
queue.length = 0;
|
|
flushPostFlushCbs(seen);
|
|
currentFlushPromise = null;
|
|
if (queue.length || pendingPostFlushCbs.length) {
|
|
flushJobs(seen);
|
|
}
|
|
}
|
|
}
|
|
function checkRecursiveUpdates(seen, fn) {
|
|
const count = seen.get(fn) || 0;
|
|
if (count > RECURSION_LIMIT) {
|
|
const instance = fn.i;
|
|
const componentName = instance && getComponentName(instance.type);
|
|
handleError(`Maximum recursive updates exceeded${componentName ? ` in component <${componentName}>` : ``}. This means you have a reactive effect that is mutating its own dependencies and thus recursively triggering itself. Possible sources include component template, render function, updated hook or watcher source function.`, null, 10);
|
|
return true;
|
|
}
|
|
seen.set(fn, count + 1);
|
|
return false;
|
|
}
|
|
let isHmrUpdating = false;
|
|
const hmrDirtyComponents = /* @__PURE__ */new Map();
|
|
if (false) {}
|
|
const map = /* @__PURE__ */new Map();
|
|
function registerHMR(instance) {
|
|
const id = instance.type.__hmrId;
|
|
let record = map.get(id);
|
|
if (!record) {
|
|
createRecord(id, instance.type);
|
|
record = map.get(id);
|
|
}
|
|
record.instances.add(instance);
|
|
}
|
|
function unregisterHMR(instance) {
|
|
map.get(instance.type.__hmrId).instances.delete(instance);
|
|
}
|
|
function createRecord(id, initialDef) {
|
|
if (map.has(id)) {
|
|
return false;
|
|
}
|
|
map.set(id, {
|
|
initialDef: normalizeClassComponent(initialDef),
|
|
instances: /* @__PURE__ */new Set()
|
|
});
|
|
return true;
|
|
}
|
|
function normalizeClassComponent(component) {
|
|
return isClassComponent(component) ? component.__vccOpts : component;
|
|
}
|
|
function rerender(id, newRender) {
|
|
const record = map.get(id);
|
|
if (!record) {
|
|
return;
|
|
}
|
|
record.initialDef.render = newRender;
|
|
[...record.instances].forEach(instance => {
|
|
if (newRender) {
|
|
instance.render = newRender;
|
|
normalizeClassComponent(instance.type).render = newRender;
|
|
}
|
|
instance.renderCache = [];
|
|
isHmrUpdating = true;
|
|
instance.update();
|
|
isHmrUpdating = false;
|
|
});
|
|
}
|
|
function reload(id, newComp) {
|
|
const record = map.get(id);
|
|
if (!record) return;
|
|
newComp = normalizeClassComponent(newComp);
|
|
updateComponentDef(record.initialDef, newComp);
|
|
const instances = [...record.instances];
|
|
for (let i = 0; i < instances.length; i++) {
|
|
const instance = instances[i];
|
|
const oldComp = normalizeClassComponent(instance.type);
|
|
let dirtyInstances = hmrDirtyComponents.get(oldComp);
|
|
if (!dirtyInstances) {
|
|
if (oldComp !== record.initialDef) {
|
|
updateComponentDef(oldComp, newComp);
|
|
}
|
|
hmrDirtyComponents.set(oldComp, dirtyInstances = /* @__PURE__ */new Set());
|
|
}
|
|
dirtyInstances.add(instance);
|
|
instance.appContext.propsCache.delete(instance.type);
|
|
instance.appContext.emitsCache.delete(instance.type);
|
|
instance.appContext.optionsCache.delete(instance.type);
|
|
if (instance.ceReload) {
|
|
dirtyInstances.add(instance);
|
|
instance.ceReload(newComp.styles);
|
|
dirtyInstances.delete(instance);
|
|
} else if (instance.parent) {
|
|
queueJob(() => {
|
|
isHmrUpdating = true;
|
|
instance.parent.update();
|
|
isHmrUpdating = false;
|
|
dirtyInstances.delete(instance);
|
|
});
|
|
} else if (instance.appContext.reload) {
|
|
instance.appContext.reload();
|
|
} else if (typeof window !== "undefined") {
|
|
window.location.reload();
|
|
} else {
|
|
console.warn("[HMR] Root or manually mounted instance modified. Full reload required.");
|
|
}
|
|
if (instance.root.ce && instance !== instance.root) {
|
|
instance.root.ce._removeChildStyle(oldComp);
|
|
}
|
|
}
|
|
queuePostFlushCb(() => {
|
|
hmrDirtyComponents.clear();
|
|
});
|
|
}
|
|
function updateComponentDef(oldComp, newComp) {
|
|
extend(oldComp, newComp);
|
|
for (const key in oldComp) {
|
|
if (key !== "__file" && !(key in newComp)) {
|
|
delete oldComp[key];
|
|
}
|
|
}
|
|
}
|
|
function tryWrap(fn) {
|
|
return (id, arg) => {
|
|
try {
|
|
return fn(id, arg);
|
|
} catch (e) {
|
|
console.error(e);
|
|
console.warn(`[HMR] Something went wrong during Vue component hot-reload. Full reload required.`);
|
|
}
|
|
};
|
|
}
|
|
let devtools$1;
|
|
let buffer = (/* unused pure expression or super */ null && ([]));
|
|
let devtoolsNotInstalled = false;
|
|
function emit$1(event, ...args) {
|
|
if (devtools$1) {
|
|
devtools$1.emit(event, ...args);
|
|
} else if (!devtoolsNotInstalled) {
|
|
buffer.push({
|
|
event,
|
|
args
|
|
});
|
|
}
|
|
}
|
|
function setDevtoolsHook$1(hook, target) {
|
|
var _a, _b;
|
|
devtools$1 = hook;
|
|
if (devtools$1) {
|
|
devtools$1.enabled = true;
|
|
buffer.forEach(({
|
|
event,
|
|
args
|
|
}) => devtools$1.emit(event, ...args));
|
|
buffer = [];
|
|
} else if (
|
|
// handle late devtools injection - only do this if we are in an actual
|
|
// browser environment to avoid the timer handle stalling test runner exit
|
|
// (#4815)
|
|
typeof window !== "undefined" &&
|
|
// some envs mock window but not fully
|
|
window.HTMLElement &&
|
|
// also exclude jsdom
|
|
// eslint-disable-next-line no-restricted-syntax
|
|
!((_b = (_a = window.navigator) == null ? void 0 : _a.userAgent) == null ? void 0 : _b.includes("jsdom"))) {
|
|
const replay = target.__VUE_DEVTOOLS_HOOK_REPLAY__ = target.__VUE_DEVTOOLS_HOOK_REPLAY__ || [];
|
|
replay.push(newHook => {
|
|
setDevtoolsHook$1(newHook, target);
|
|
});
|
|
setTimeout(() => {
|
|
if (!devtools$1) {
|
|
target.__VUE_DEVTOOLS_HOOK_REPLAY__ = null;
|
|
devtoolsNotInstalled = true;
|
|
buffer = [];
|
|
}
|
|
}, 3e3);
|
|
} else {
|
|
devtoolsNotInstalled = true;
|
|
buffer = [];
|
|
}
|
|
}
|
|
function devtoolsInitApp(app, version) {
|
|
emit$1("app:init" /* APP_INIT */, app, version, {
|
|
Fragment,
|
|
Text,
|
|
Comment,
|
|
Static
|
|
});
|
|
}
|
|
function devtoolsUnmountApp(app) {
|
|
emit$1("app:unmount" /* APP_UNMOUNT */, app);
|
|
}
|
|
const devtoolsComponentAdded = /* @__PURE__ */(/* unused pure expression or super */ null && (createDevtoolsComponentHook("component:added" /* COMPONENT_ADDED */)));
|
|
const devtoolsComponentUpdated = /* @__PURE__ */(/* unused pure expression or super */ null && (createDevtoolsComponentHook("component:updated" /* COMPONENT_UPDATED */)));
|
|
const _devtoolsComponentRemoved = /* @__PURE__ */(/* unused pure expression or super */ null && (createDevtoolsComponentHook("component:removed" /* COMPONENT_REMOVED */)));
|
|
const devtoolsComponentRemoved = component => {
|
|
if (devtools$1 && typeof devtools$1.cleanupBuffer === "function" &&
|
|
// remove the component if it wasn't buffered
|
|
!devtools$1.cleanupBuffer(component)) {
|
|
_devtoolsComponentRemoved(component);
|
|
}
|
|
};
|
|
/*! #__NO_SIDE_EFFECTS__ */
|
|
// @__NO_SIDE_EFFECTS__
|
|
function createDevtoolsComponentHook(hook) {
|
|
return component => {
|
|
emit$1(hook, component.appContext.app, component.uid, component.parent ? component.parent.uid : void 0, component);
|
|
};
|
|
}
|
|
const devtoolsPerfStart = /* @__PURE__ */(/* unused pure expression or super */ null && (createDevtoolsPerformanceHook("perf:start" /* PERFORMANCE_START */)));
|
|
const devtoolsPerfEnd = /* @__PURE__ */(/* unused pure expression or super */ null && (createDevtoolsPerformanceHook("perf:end" /* PERFORMANCE_END */)));
|
|
function createDevtoolsPerformanceHook(hook) {
|
|
return (component, type, time) => {
|
|
emit$1(hook, component.appContext.app, component.uid, component, type, time);
|
|
};
|
|
}
|
|
function devtoolsComponentEmit(component, event, params) {
|
|
emit$1("component:emit" /* COMPONENT_EMIT */, component.appContext.app, component, event, params);
|
|
}
|
|
let currentRenderingInstance = null;
|
|
let currentScopeId = null;
|
|
function setCurrentRenderingInstance(instance) {
|
|
const prev = currentRenderingInstance;
|
|
currentRenderingInstance = instance;
|
|
currentScopeId = instance && instance.type.__scopeId || null;
|
|
return prev;
|
|
}
|
|
function pushScopeId(id) {
|
|
currentScopeId = id;
|
|
}
|
|
function popScopeId() {
|
|
currentScopeId = null;
|
|
}
|
|
const withScopeId = _id => withCtx;
|
|
function withCtx(fn, ctx = currentRenderingInstance, isNonScopedSlot) {
|
|
if (!ctx) return fn;
|
|
if (fn._n) {
|
|
return fn;
|
|
}
|
|
const renderFnWithContext = (...args) => {
|
|
if (renderFnWithContext._d) {
|
|
setBlockTracking(-1);
|
|
}
|
|
const prevInstance = setCurrentRenderingInstance(ctx);
|
|
let res;
|
|
try {
|
|
res = fn(...args);
|
|
} finally {
|
|
setCurrentRenderingInstance(prevInstance);
|
|
if (renderFnWithContext._d) {
|
|
setBlockTracking(1);
|
|
}
|
|
}
|
|
if (false) {}
|
|
return res;
|
|
};
|
|
renderFnWithContext._n = true;
|
|
renderFnWithContext._c = true;
|
|
renderFnWithContext._d = true;
|
|
return renderFnWithContext;
|
|
}
|
|
function validateDirectiveName(name) {
|
|
if (isBuiltInDirective(name)) {
|
|
warn$1("Do not use built-in directive ids as custom directive id: " + name);
|
|
}
|
|
}
|
|
function withDirectives(vnode, directives) {
|
|
if (currentRenderingInstance === null) {
|
|
false && 0;
|
|
return vnode;
|
|
}
|
|
const instance = getComponentPublicInstance(currentRenderingInstance);
|
|
const bindings = vnode.dirs || (vnode.dirs = []);
|
|
for (let i = 0; i < directives.length; i++) {
|
|
let [dir, value, arg, modifiers = _vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .EMPTY_OBJ */ .MZ] = directives[i];
|
|
if (dir) {
|
|
if ((0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .isFunction */ .Tn)(dir)) {
|
|
dir = {
|
|
mounted: dir,
|
|
updated: dir
|
|
};
|
|
}
|
|
if (dir.deep) {
|
|
(0,_vue_reactivity__WEBPACK_IMPORTED_MODULE_17__/* .traverse */ .hV)(value);
|
|
}
|
|
bindings.push({
|
|
dir,
|
|
instance,
|
|
value,
|
|
oldValue: void 0,
|
|
arg,
|
|
modifiers
|
|
});
|
|
}
|
|
}
|
|
return vnode;
|
|
}
|
|
function invokeDirectiveHook(vnode, prevVNode, instance, name) {
|
|
const bindings = vnode.dirs;
|
|
const oldBindings = prevVNode && prevVNode.dirs;
|
|
for (let i = 0; i < bindings.length; i++) {
|
|
const binding = bindings[i];
|
|
if (oldBindings) {
|
|
binding.oldValue = oldBindings[i].value;
|
|
}
|
|
let hook = binding.dir[name];
|
|
if (hook) {
|
|
(0,_vue_reactivity__WEBPACK_IMPORTED_MODULE_17__/* .pauseTracking */ .C4)();
|
|
callWithAsyncErrorHandling(hook, instance, 8, [vnode.el, binding, vnode, prevVNode]);
|
|
(0,_vue_reactivity__WEBPACK_IMPORTED_MODULE_17__/* .resetTracking */ .bl)();
|
|
}
|
|
}
|
|
}
|
|
const TeleportEndKey = Symbol("_vte");
|
|
const isTeleport = type => type.__isTeleport;
|
|
const isTeleportDisabled = props => props && (props.disabled || props.disabled === "");
|
|
const isTeleportDeferred = props => props && (props.defer || props.defer === "");
|
|
const isTargetSVG = target => typeof SVGElement !== "undefined" && target instanceof SVGElement;
|
|
const isTargetMathML = target => typeof MathMLElement === "function" && target instanceof MathMLElement;
|
|
const resolveTarget = (props, select) => {
|
|
const targetSelector = props && props.to;
|
|
if ((0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .isString */ .Kg)(targetSelector)) {
|
|
if (!select) {
|
|
false && 0;
|
|
return null;
|
|
} else {
|
|
const target = select(targetSelector);
|
|
if (false) {}
|
|
return target;
|
|
}
|
|
} else {
|
|
if (false) {}
|
|
return targetSelector;
|
|
}
|
|
};
|
|
const TeleportImpl = {
|
|
name: "Teleport",
|
|
__isTeleport: true,
|
|
process(n1, n2, container, anchor, parentComponent, parentSuspense, namespace, slotScopeIds, optimized, internals) {
|
|
const {
|
|
mc: mountChildren,
|
|
pc: patchChildren,
|
|
pbc: patchBlockChildren,
|
|
o: {
|
|
insert,
|
|
querySelector,
|
|
createText,
|
|
createComment
|
|
}
|
|
} = internals;
|
|
const disabled = isTeleportDisabled(n2.props);
|
|
let {
|
|
shapeFlag,
|
|
children,
|
|
dynamicChildren
|
|
} = n2;
|
|
if (false) {}
|
|
if (n1 == null) {
|
|
const placeholder = n2.el = false ? 0 : createText("");
|
|
const mainAnchor = n2.anchor = false ? 0 : createText("");
|
|
insert(placeholder, container, anchor);
|
|
insert(mainAnchor, container, anchor);
|
|
const mount = (container2, anchor2) => {
|
|
if (shapeFlag & 16) {
|
|
if (parentComponent && parentComponent.isCE) {
|
|
parentComponent.ce._teleportTarget = container2;
|
|
}
|
|
mountChildren(children, container2, anchor2, parentComponent, parentSuspense, namespace, slotScopeIds, optimized);
|
|
}
|
|
};
|
|
const mountToTarget = () => {
|
|
const target = n2.target = resolveTarget(n2.props, querySelector);
|
|
const targetAnchor = prepareAnchor(target, n2, createText, insert);
|
|
if (target) {
|
|
if (namespace !== "svg" && isTargetSVG(target)) {
|
|
namespace = "svg";
|
|
} else if (namespace !== "mathml" && isTargetMathML(target)) {
|
|
namespace = "mathml";
|
|
}
|
|
if (!disabled) {
|
|
mount(target, targetAnchor);
|
|
updateCssVars(n2, false);
|
|
}
|
|
} else if (false) {}
|
|
};
|
|
if (disabled) {
|
|
mount(container, mainAnchor);
|
|
updateCssVars(n2, true);
|
|
}
|
|
if (isTeleportDeferred(n2.props)) {
|
|
queuePostRenderEffect(() => {
|
|
mountToTarget();
|
|
n2.el.__isMounted = true;
|
|
}, parentSuspense);
|
|
} else {
|
|
mountToTarget();
|
|
}
|
|
} else {
|
|
if (isTeleportDeferred(n2.props) && !n1.el.__isMounted) {
|
|
queuePostRenderEffect(() => {
|
|
TeleportImpl.process(n1, n2, container, anchor, parentComponent, parentSuspense, namespace, slotScopeIds, optimized, internals);
|
|
delete n1.el.__isMounted;
|
|
}, parentSuspense);
|
|
return;
|
|
}
|
|
n2.el = n1.el;
|
|
n2.targetStart = n1.targetStart;
|
|
const mainAnchor = n2.anchor = n1.anchor;
|
|
const target = n2.target = n1.target;
|
|
const targetAnchor = n2.targetAnchor = n1.targetAnchor;
|
|
const wasDisabled = isTeleportDisabled(n1.props);
|
|
const currentContainer = wasDisabled ? container : target;
|
|
const currentAnchor = wasDisabled ? mainAnchor : targetAnchor;
|
|
if (namespace === "svg" || isTargetSVG(target)) {
|
|
namespace = "svg";
|
|
} else if (namespace === "mathml" || isTargetMathML(target)) {
|
|
namespace = "mathml";
|
|
}
|
|
if (dynamicChildren) {
|
|
patchBlockChildren(n1.dynamicChildren, dynamicChildren, currentContainer, parentComponent, parentSuspense, namespace, slotScopeIds);
|
|
traverseStaticChildren(n1, n2, true);
|
|
} else if (!optimized) {
|
|
patchChildren(n1, n2, currentContainer, currentAnchor, parentComponent, parentSuspense, namespace, slotScopeIds, false);
|
|
}
|
|
if (disabled) {
|
|
if (!wasDisabled) {
|
|
moveTeleport(n2, container, mainAnchor, internals, 1);
|
|
} else {
|
|
if (n2.props && n1.props && n2.props.to !== n1.props.to) {
|
|
n2.props.to = n1.props.to;
|
|
}
|
|
}
|
|
} else {
|
|
if ((n2.props && n2.props.to) !== (n1.props && n1.props.to)) {
|
|
const nextTarget = n2.target = resolveTarget(n2.props, querySelector);
|
|
if (nextTarget) {
|
|
moveTeleport(n2, nextTarget, null, internals, 0);
|
|
} else if (false) {}
|
|
} else if (wasDisabled) {
|
|
moveTeleport(n2, target, targetAnchor, internals, 1);
|
|
}
|
|
}
|
|
updateCssVars(n2, disabled);
|
|
}
|
|
},
|
|
remove(vnode, parentComponent, parentSuspense, {
|
|
um: unmount,
|
|
o: {
|
|
remove: hostRemove
|
|
}
|
|
}, doRemove) {
|
|
const {
|
|
shapeFlag,
|
|
children,
|
|
anchor,
|
|
targetStart,
|
|
targetAnchor,
|
|
target,
|
|
props
|
|
} = vnode;
|
|
if (target) {
|
|
hostRemove(targetStart);
|
|
hostRemove(targetAnchor);
|
|
}
|
|
doRemove && hostRemove(anchor);
|
|
if (shapeFlag & 16) {
|
|
const shouldRemove = doRemove || !isTeleportDisabled(props);
|
|
for (let i = 0; i < children.length; i++) {
|
|
const child = children[i];
|
|
unmount(child, parentComponent, parentSuspense, shouldRemove, !!child.dynamicChildren);
|
|
}
|
|
}
|
|
},
|
|
move: moveTeleport,
|
|
hydrate: hydrateTeleport
|
|
};
|
|
function moveTeleport(vnode, container, parentAnchor, {
|
|
o: {
|
|
insert
|
|
},
|
|
m: move
|
|
}, moveType = 2) {
|
|
if (moveType === 0) {
|
|
insert(vnode.targetAnchor, container, parentAnchor);
|
|
}
|
|
const {
|
|
el,
|
|
anchor,
|
|
shapeFlag,
|
|
children,
|
|
props
|
|
} = vnode;
|
|
const isReorder = moveType === 2;
|
|
if (isReorder) {
|
|
insert(el, container, parentAnchor);
|
|
}
|
|
if (!isReorder || isTeleportDisabled(props)) {
|
|
if (shapeFlag & 16) {
|
|
for (let i = 0; i < children.length; i++) {
|
|
move(children[i], container, parentAnchor, 2);
|
|
}
|
|
}
|
|
}
|
|
if (isReorder) {
|
|
insert(anchor, container, parentAnchor);
|
|
}
|
|
}
|
|
function hydrateTeleport(node, vnode, parentComponent, parentSuspense, slotScopeIds, optimized, {
|
|
o: {
|
|
nextSibling,
|
|
parentNode,
|
|
querySelector,
|
|
insert,
|
|
createText
|
|
}
|
|
}, hydrateChildren) {
|
|
const target = vnode.target = resolveTarget(vnode.props, querySelector);
|
|
if (target) {
|
|
const disabled = isTeleportDisabled(vnode.props);
|
|
const targetNode = target._lpa || target.firstChild;
|
|
if (vnode.shapeFlag & 16) {
|
|
if (disabled) {
|
|
vnode.anchor = hydrateChildren(nextSibling(node), vnode, parentNode(node), parentComponent, parentSuspense, slotScopeIds, optimized);
|
|
vnode.targetStart = targetNode;
|
|
vnode.targetAnchor = targetNode && nextSibling(targetNode);
|
|
} else {
|
|
vnode.anchor = nextSibling(node);
|
|
let targetAnchor = targetNode;
|
|
while (targetAnchor) {
|
|
if (targetAnchor && targetAnchor.nodeType === 8) {
|
|
if (targetAnchor.data === "teleport start anchor") {
|
|
vnode.targetStart = targetAnchor;
|
|
} else if (targetAnchor.data === "teleport anchor") {
|
|
vnode.targetAnchor = targetAnchor;
|
|
target._lpa = vnode.targetAnchor && nextSibling(vnode.targetAnchor);
|
|
break;
|
|
}
|
|
}
|
|
targetAnchor = nextSibling(targetAnchor);
|
|
}
|
|
if (!vnode.targetAnchor) {
|
|
prepareAnchor(target, vnode, createText, insert);
|
|
}
|
|
hydrateChildren(targetNode && nextSibling(targetNode), vnode, target, parentComponent, parentSuspense, slotScopeIds, optimized);
|
|
}
|
|
}
|
|
updateCssVars(vnode, disabled);
|
|
}
|
|
return vnode.anchor && nextSibling(vnode.anchor);
|
|
}
|
|
const Teleport = TeleportImpl;
|
|
function updateCssVars(vnode, isDisabled) {
|
|
const ctx = vnode.ctx;
|
|
if (ctx && ctx.ut) {
|
|
let node, anchor;
|
|
if (isDisabled) {
|
|
node = vnode.el;
|
|
anchor = vnode.anchor;
|
|
} else {
|
|
node = vnode.targetStart;
|
|
anchor = vnode.targetAnchor;
|
|
}
|
|
while (node && node !== anchor) {
|
|
if (node.nodeType === 1) node.setAttribute("data-v-owner", ctx.uid);
|
|
node = node.nextSibling;
|
|
}
|
|
ctx.ut();
|
|
}
|
|
}
|
|
function prepareAnchor(target, vnode, createText, insert) {
|
|
const targetStart = vnode.targetStart = createText("");
|
|
const targetAnchor = vnode.targetAnchor = createText("");
|
|
targetStart[TeleportEndKey] = targetAnchor;
|
|
if (target) {
|
|
insert(targetStart, target);
|
|
insert(targetAnchor, target);
|
|
}
|
|
return targetAnchor;
|
|
}
|
|
const leaveCbKey = Symbol("_leaveCb");
|
|
const enterCbKey = Symbol("_enterCb");
|
|
function useTransitionState() {
|
|
const state = {
|
|
isMounted: false,
|
|
isLeaving: false,
|
|
isUnmounting: false,
|
|
leavingVNodes: /* @__PURE__ */new Map()
|
|
};
|
|
onMounted(() => {
|
|
state.isMounted = true;
|
|
});
|
|
onBeforeUnmount(() => {
|
|
state.isUnmounting = true;
|
|
});
|
|
return state;
|
|
}
|
|
const TransitionHookValidator = [Function, Array];
|
|
const BaseTransitionPropsValidators = {
|
|
mode: String,
|
|
appear: Boolean,
|
|
persisted: Boolean,
|
|
// enter
|
|
onBeforeEnter: TransitionHookValidator,
|
|
onEnter: TransitionHookValidator,
|
|
onAfterEnter: TransitionHookValidator,
|
|
onEnterCancelled: TransitionHookValidator,
|
|
// leave
|
|
onBeforeLeave: TransitionHookValidator,
|
|
onLeave: TransitionHookValidator,
|
|
onAfterLeave: TransitionHookValidator,
|
|
onLeaveCancelled: TransitionHookValidator,
|
|
// appear
|
|
onBeforeAppear: TransitionHookValidator,
|
|
onAppear: TransitionHookValidator,
|
|
onAfterAppear: TransitionHookValidator,
|
|
onAppearCancelled: TransitionHookValidator
|
|
};
|
|
const recursiveGetSubtree = instance => {
|
|
const subTree = instance.subTree;
|
|
return subTree.component ? recursiveGetSubtree(subTree.component) : subTree;
|
|
};
|
|
const BaseTransitionImpl = {
|
|
name: `BaseTransition`,
|
|
props: BaseTransitionPropsValidators,
|
|
setup(props, {
|
|
slots
|
|
}) {
|
|
const instance = getCurrentInstance();
|
|
const state = useTransitionState();
|
|
return () => {
|
|
const children = slots.default && getTransitionRawChildren(slots.default(), true);
|
|
if (!children || !children.length) {
|
|
return;
|
|
}
|
|
const child = findNonCommentChild(children);
|
|
const rawProps = (0,_vue_reactivity__WEBPACK_IMPORTED_MODULE_17__/* .toRaw */ .ux)(props);
|
|
const {
|
|
mode
|
|
} = rawProps;
|
|
if (false) {}
|
|
if (state.isLeaving) {
|
|
return emptyPlaceholder(child);
|
|
}
|
|
const innerChild = getInnerChild$1(child);
|
|
if (!innerChild) {
|
|
return emptyPlaceholder(child);
|
|
}
|
|
let enterHooks = resolveTransitionHooks(innerChild, rawProps, state, instance,
|
|
// #11061, ensure enterHooks is fresh after clone
|
|
hooks => enterHooks = hooks);
|
|
if (innerChild.type !== Comment) {
|
|
setTransitionHooks(innerChild, enterHooks);
|
|
}
|
|
let oldInnerChild = instance.subTree && getInnerChild$1(instance.subTree);
|
|
if (oldInnerChild && oldInnerChild.type !== Comment && !isSameVNodeType(innerChild, oldInnerChild) && recursiveGetSubtree(instance).type !== Comment) {
|
|
let leavingHooks = resolveTransitionHooks(oldInnerChild, rawProps, state, instance);
|
|
setTransitionHooks(oldInnerChild, leavingHooks);
|
|
if (mode === "out-in" && innerChild.type !== Comment) {
|
|
state.isLeaving = true;
|
|
leavingHooks.afterLeave = () => {
|
|
state.isLeaving = false;
|
|
if (!(instance.job.flags & 8)) {
|
|
instance.update();
|
|
}
|
|
delete leavingHooks.afterLeave;
|
|
oldInnerChild = void 0;
|
|
};
|
|
return emptyPlaceholder(child);
|
|
} else if (mode === "in-out" && innerChild.type !== Comment) {
|
|
leavingHooks.delayLeave = (el, earlyRemove, delayedLeave) => {
|
|
const leavingVNodesCache = getLeavingNodesForType(state, oldInnerChild);
|
|
leavingVNodesCache[String(oldInnerChild.key)] = oldInnerChild;
|
|
el[leaveCbKey] = () => {
|
|
earlyRemove();
|
|
el[leaveCbKey] = void 0;
|
|
delete enterHooks.delayedLeave;
|
|
oldInnerChild = void 0;
|
|
};
|
|
enterHooks.delayedLeave = () => {
|
|
delayedLeave();
|
|
delete enterHooks.delayedLeave;
|
|
oldInnerChild = void 0;
|
|
};
|
|
};
|
|
} else {
|
|
oldInnerChild = void 0;
|
|
}
|
|
} else if (oldInnerChild) {
|
|
oldInnerChild = void 0;
|
|
}
|
|
return child;
|
|
};
|
|
}
|
|
};
|
|
function findNonCommentChild(children) {
|
|
let child = children[0];
|
|
if (children.length > 1) {
|
|
let hasFound = false;
|
|
for (const c of children) {
|
|
if (c.type !== Comment) {
|
|
if (false) {}
|
|
child = c;
|
|
hasFound = true;
|
|
if (true) break;
|
|
}
|
|
}
|
|
}
|
|
return child;
|
|
}
|
|
const BaseTransition = (/* unused pure expression or super */ null && (BaseTransitionImpl));
|
|
function getLeavingNodesForType(state, vnode) {
|
|
const {
|
|
leavingVNodes
|
|
} = state;
|
|
let leavingVNodesCache = leavingVNodes.get(vnode.type);
|
|
if (!leavingVNodesCache) {
|
|
leavingVNodesCache = /* @__PURE__ */Object.create(null);
|
|
leavingVNodes.set(vnode.type, leavingVNodesCache);
|
|
}
|
|
return leavingVNodesCache;
|
|
}
|
|
function resolveTransitionHooks(vnode, props, state, instance, postClone) {
|
|
const {
|
|
appear,
|
|
mode,
|
|
persisted = false,
|
|
onBeforeEnter,
|
|
onEnter,
|
|
onAfterEnter,
|
|
onEnterCancelled,
|
|
onBeforeLeave,
|
|
onLeave,
|
|
onAfterLeave,
|
|
onLeaveCancelled,
|
|
onBeforeAppear,
|
|
onAppear,
|
|
onAfterAppear,
|
|
onAppearCancelled
|
|
} = props;
|
|
const key = String(vnode.key);
|
|
const leavingVNodesCache = getLeavingNodesForType(state, vnode);
|
|
const callHook = (hook, args) => {
|
|
hook && callWithAsyncErrorHandling(hook, instance, 9, args);
|
|
};
|
|
const callAsyncHook = (hook, args) => {
|
|
const done = args[1];
|
|
callHook(hook, args);
|
|
if ((0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .isArray */ .cy)(hook)) {
|
|
if (hook.every(hook2 => hook2.length <= 1)) done();
|
|
} else if (hook.length <= 1) {
|
|
done();
|
|
}
|
|
};
|
|
const hooks = {
|
|
mode,
|
|
persisted,
|
|
beforeEnter(el) {
|
|
let hook = onBeforeEnter;
|
|
if (!state.isMounted) {
|
|
if (appear) {
|
|
hook = onBeforeAppear || onBeforeEnter;
|
|
} else {
|
|
return;
|
|
}
|
|
}
|
|
if (el[leaveCbKey]) {
|
|
el[leaveCbKey](true
|
|
/* cancelled */);
|
|
}
|
|
const leavingVNode = leavingVNodesCache[key];
|
|
if (leavingVNode && isSameVNodeType(vnode, leavingVNode) && leavingVNode.el[leaveCbKey]) {
|
|
leavingVNode.el[leaveCbKey]();
|
|
}
|
|
callHook(hook, [el]);
|
|
},
|
|
enter(el) {
|
|
let hook = onEnter;
|
|
let afterHook = onAfterEnter;
|
|
let cancelHook = onEnterCancelled;
|
|
if (!state.isMounted) {
|
|
if (appear) {
|
|
hook = onAppear || onEnter;
|
|
afterHook = onAfterAppear || onAfterEnter;
|
|
cancelHook = onAppearCancelled || onEnterCancelled;
|
|
} else {
|
|
return;
|
|
}
|
|
}
|
|
let called = false;
|
|
const done = el[enterCbKey] = cancelled => {
|
|
if (called) return;
|
|
called = true;
|
|
if (cancelled) {
|
|
callHook(cancelHook, [el]);
|
|
} else {
|
|
callHook(afterHook, [el]);
|
|
}
|
|
if (hooks.delayedLeave) {
|
|
hooks.delayedLeave();
|
|
}
|
|
el[enterCbKey] = void 0;
|
|
};
|
|
if (hook) {
|
|
callAsyncHook(hook, [el, done]);
|
|
} else {
|
|
done();
|
|
}
|
|
},
|
|
leave(el, remove) {
|
|
const key2 = String(vnode.key);
|
|
if (el[enterCbKey]) {
|
|
el[enterCbKey](true
|
|
/* cancelled */);
|
|
}
|
|
if (state.isUnmounting) {
|
|
return remove();
|
|
}
|
|
callHook(onBeforeLeave, [el]);
|
|
let called = false;
|
|
const done = el[leaveCbKey] = cancelled => {
|
|
if (called) return;
|
|
called = true;
|
|
remove();
|
|
if (cancelled) {
|
|
callHook(onLeaveCancelled, [el]);
|
|
} else {
|
|
callHook(onAfterLeave, [el]);
|
|
}
|
|
el[leaveCbKey] = void 0;
|
|
if (leavingVNodesCache[key2] === vnode) {
|
|
delete leavingVNodesCache[key2];
|
|
}
|
|
};
|
|
leavingVNodesCache[key2] = vnode;
|
|
if (onLeave) {
|
|
callAsyncHook(onLeave, [el, done]);
|
|
} else {
|
|
done();
|
|
}
|
|
},
|
|
clone(vnode2) {
|
|
const hooks2 = resolveTransitionHooks(vnode2, props, state, instance, postClone);
|
|
if (postClone) postClone(hooks2);
|
|
return hooks2;
|
|
}
|
|
};
|
|
return hooks;
|
|
}
|
|
function emptyPlaceholder(vnode) {
|
|
if (isKeepAlive(vnode)) {
|
|
vnode = cloneVNode(vnode);
|
|
vnode.children = null;
|
|
return vnode;
|
|
}
|
|
}
|
|
function getInnerChild$1(vnode) {
|
|
if (!isKeepAlive(vnode)) {
|
|
if (isTeleport(vnode.type) && vnode.children) {
|
|
return findNonCommentChild(vnode.children);
|
|
}
|
|
return vnode;
|
|
}
|
|
if (false) {}
|
|
const {
|
|
shapeFlag,
|
|
children
|
|
} = vnode;
|
|
if (children) {
|
|
if (shapeFlag & 16) {
|
|
return children[0];
|
|
}
|
|
if (shapeFlag & 32 && (0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .isFunction */ .Tn)(children.default)) {
|
|
return children.default();
|
|
}
|
|
}
|
|
}
|
|
function setTransitionHooks(vnode, hooks) {
|
|
if (vnode.shapeFlag & 6 && vnode.component) {
|
|
vnode.transition = hooks;
|
|
setTransitionHooks(vnode.component.subTree, hooks);
|
|
} else if (vnode.shapeFlag & 128) {
|
|
vnode.ssContent.transition = hooks.clone(vnode.ssContent);
|
|
vnode.ssFallback.transition = hooks.clone(vnode.ssFallback);
|
|
} else {
|
|
vnode.transition = hooks;
|
|
}
|
|
}
|
|
function getTransitionRawChildren(children, keepComment = false, parentKey) {
|
|
let ret = [];
|
|
let keyedFragmentCount = 0;
|
|
for (let i = 0; i < children.length; i++) {
|
|
let child = children[i];
|
|
const key = parentKey == null ? child.key : String(parentKey) + String(child.key != null ? child.key : i);
|
|
if (child.type === Fragment) {
|
|
if (child.patchFlag & 128) keyedFragmentCount++;
|
|
ret = ret.concat(getTransitionRawChildren(child.children, keepComment, key));
|
|
} else if (keepComment || child.type !== Comment) {
|
|
ret.push(key != null ? cloneVNode(child, {
|
|
key
|
|
}) : child);
|
|
}
|
|
}
|
|
if (keyedFragmentCount > 1) {
|
|
for (let i = 0; i < ret.length; i++) {
|
|
ret[i].patchFlag = -2;
|
|
}
|
|
}
|
|
return ret;
|
|
}
|
|
|
|
/*! #__NO_SIDE_EFFECTS__ */
|
|
// @__NO_SIDE_EFFECTS__
|
|
function defineComponent(options, extraOptions) {
|
|
return (0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .isFunction */ .Tn)(options) ?
|
|
// #8236: extend call and options.name access are considered side-effects
|
|
// by Rollup, so we have to wrap it in a pure-annotated IIFE.
|
|
/* @__PURE__ */
|
|
(() => (0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .extend */ .X$)({
|
|
name: options.name
|
|
}, extraOptions, {
|
|
setup: options
|
|
}))() : options;
|
|
}
|
|
function useId() {
|
|
const i = getCurrentInstance();
|
|
if (i) {
|
|
return (i.appContext.config.idPrefix || "v") + "-" + i.ids[0] + i.ids[1]++;
|
|
} else if (false) {}
|
|
return "";
|
|
}
|
|
function markAsyncBoundary(instance) {
|
|
instance.ids = [instance.ids[0] + instance.ids[2]++ + "-", 0, 0];
|
|
}
|
|
const knownTemplateRefs = /* @__PURE__ */new WeakSet();
|
|
function useTemplateRef(key) {
|
|
const i = getCurrentInstance();
|
|
const r = shallowRef(null);
|
|
if (i) {
|
|
const refs = i.refs === EMPTY_OBJ ? i.refs = {} : i.refs;
|
|
let desc;
|
|
if (false) {} else {
|
|
Object.defineProperty(refs, key, {
|
|
enumerable: true,
|
|
get: () => r.value,
|
|
set: val => r.value = val
|
|
});
|
|
}
|
|
} else if (false) {}
|
|
const ret = false ? 0 : r;
|
|
if (false) {}
|
|
return ret;
|
|
}
|
|
function setRef(rawRef, oldRawRef, parentSuspense, vnode, isUnmount = false) {
|
|
if ((0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .isArray */ .cy)(rawRef)) {
|
|
rawRef.forEach((r, i) => setRef(r, oldRawRef && ((0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .isArray */ .cy)(oldRawRef) ? oldRawRef[i] : oldRawRef), parentSuspense, vnode, isUnmount));
|
|
return;
|
|
}
|
|
if (isAsyncWrapper(vnode) && !isUnmount) {
|
|
if (vnode.shapeFlag & 512 && vnode.type.__asyncResolved && vnode.component.subTree.component) {
|
|
setRef(rawRef, oldRawRef, parentSuspense, vnode.component.subTree);
|
|
}
|
|
return;
|
|
}
|
|
const refValue = vnode.shapeFlag & 4 ? getComponentPublicInstance(vnode.component) : vnode.el;
|
|
const value = isUnmount ? null : refValue;
|
|
const {
|
|
i: owner,
|
|
r: ref
|
|
} = rawRef;
|
|
if (false) {}
|
|
const oldRef = oldRawRef && oldRawRef.r;
|
|
const refs = owner.refs === _vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .EMPTY_OBJ */ .MZ ? owner.refs = {} : owner.refs;
|
|
const setupState = owner.setupState;
|
|
const rawSetupState = (0,_vue_reactivity__WEBPACK_IMPORTED_MODULE_17__/* .toRaw */ .ux)(setupState);
|
|
const canSetSetupRef = setupState === _vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .EMPTY_OBJ */ .MZ ? () => false : key => {
|
|
if (false) {}
|
|
return (0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .hasOwn */ .$3)(rawSetupState, key);
|
|
};
|
|
if (oldRef != null && oldRef !== ref) {
|
|
if ((0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .isString */ .Kg)(oldRef)) {
|
|
refs[oldRef] = null;
|
|
if (canSetSetupRef(oldRef)) {
|
|
setupState[oldRef] = null;
|
|
}
|
|
} else if ((0,_vue_reactivity__WEBPACK_IMPORTED_MODULE_17__/* .isRef */ .i9)(oldRef)) {
|
|
oldRef.value = null;
|
|
}
|
|
}
|
|
if ((0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .isFunction */ .Tn)(ref)) {
|
|
callWithErrorHandling(ref, owner, 12, [value, refs]);
|
|
} else {
|
|
const _isString = (0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .isString */ .Kg)(ref);
|
|
const _isRef = (0,_vue_reactivity__WEBPACK_IMPORTED_MODULE_17__/* .isRef */ .i9)(ref);
|
|
if (_isString || _isRef) {
|
|
const doSet = () => {
|
|
if (rawRef.f) {
|
|
const existing = _isString ? canSetSetupRef(ref) ? setupState[ref] : refs[ref] : ref.value;
|
|
if (isUnmount) {
|
|
(0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .isArray */ .cy)(existing) && (0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .remove */ .TF)(existing, refValue);
|
|
} else {
|
|
if (!(0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .isArray */ .cy)(existing)) {
|
|
if (_isString) {
|
|
refs[ref] = [refValue];
|
|
if (canSetSetupRef(ref)) {
|
|
setupState[ref] = refs[ref];
|
|
}
|
|
} else {
|
|
ref.value = [refValue];
|
|
if (rawRef.k) refs[rawRef.k] = ref.value;
|
|
}
|
|
} else if (!existing.includes(refValue)) {
|
|
existing.push(refValue);
|
|
}
|
|
}
|
|
} else if (_isString) {
|
|
refs[ref] = value;
|
|
if (canSetSetupRef(ref)) {
|
|
setupState[ref] = value;
|
|
}
|
|
} else if (_isRef) {
|
|
ref.value = value;
|
|
if (rawRef.k) refs[rawRef.k] = value;
|
|
} else if (false) {}
|
|
};
|
|
if (value) {
|
|
doSet.id = -1;
|
|
queuePostRenderEffect(doSet, parentSuspense);
|
|
} else {
|
|
doSet();
|
|
}
|
|
} else if (false) {}
|
|
}
|
|
}
|
|
let hasLoggedMismatchError = false;
|
|
const logMismatchError = () => {
|
|
if (hasLoggedMismatchError) {
|
|
return;
|
|
}
|
|
console.error("Hydration completed but contains mismatches.");
|
|
hasLoggedMismatchError = true;
|
|
};
|
|
const isSVGContainer = container => container.namespaceURI.includes("svg") && container.tagName !== "foreignObject";
|
|
const isMathMLContainer = container => container.namespaceURI.includes("MathML");
|
|
const getContainerType = container => {
|
|
if (container.nodeType !== 1) return void 0;
|
|
if (isSVGContainer(container)) return "svg";
|
|
if (isMathMLContainer(container)) return "mathml";
|
|
return void 0;
|
|
};
|
|
const isComment = node => node.nodeType === 8;
|
|
function createHydrationFunctions(rendererInternals) {
|
|
const {
|
|
mt: mountComponent,
|
|
p: patch,
|
|
o: {
|
|
patchProp,
|
|
createText,
|
|
nextSibling,
|
|
parentNode,
|
|
remove,
|
|
insert,
|
|
createComment
|
|
}
|
|
} = rendererInternals;
|
|
const hydrate = (vnode, container) => {
|
|
if (!container.hasChildNodes()) {
|
|
( false || __VUE_PROD_HYDRATION_MISMATCH_DETAILS__) && warn$1(`Attempting to hydrate existing markup but container is empty. Performing full mount instead.`);
|
|
patch(null, vnode, container);
|
|
flushPostFlushCbs();
|
|
container._vnode = vnode;
|
|
return;
|
|
}
|
|
hydrateNode(container.firstChild, vnode, null, null, null);
|
|
flushPostFlushCbs();
|
|
container._vnode = vnode;
|
|
};
|
|
const hydrateNode = (node, vnode, parentComponent, parentSuspense, slotScopeIds, optimized = false) => {
|
|
optimized = optimized || !!vnode.dynamicChildren;
|
|
const isFragmentStart = isComment(node) && node.data === "[";
|
|
const onMismatch = () => handleMismatch(node, vnode, parentComponent, parentSuspense, slotScopeIds, isFragmentStart);
|
|
const {
|
|
type,
|
|
ref,
|
|
shapeFlag,
|
|
patchFlag
|
|
} = vnode;
|
|
let domType = node.nodeType;
|
|
vnode.el = node;
|
|
if (false) {}
|
|
if (patchFlag === -2) {
|
|
optimized = false;
|
|
vnode.dynamicChildren = null;
|
|
}
|
|
let nextNode = null;
|
|
switch (type) {
|
|
case Text:
|
|
if (domType !== 3) {
|
|
if (vnode.children === "") {
|
|
insert(vnode.el = createText(""), parentNode(node), node);
|
|
nextNode = node;
|
|
} else {
|
|
nextNode = onMismatch();
|
|
}
|
|
} else {
|
|
if (node.data !== vnode.children) {
|
|
( false || __VUE_PROD_HYDRATION_MISMATCH_DETAILS__) && warn$1(`Hydration text mismatch in`, node.parentNode, `
|
|
- rendered on server: ${JSON.stringify(node.data)}
|
|
- expected on client: ${JSON.stringify(vnode.children)}`);
|
|
logMismatchError();
|
|
node.data = vnode.children;
|
|
}
|
|
nextNode = nextSibling(node);
|
|
}
|
|
break;
|
|
case Comment:
|
|
if (isTemplateNode(node)) {
|
|
nextNode = nextSibling(node);
|
|
replaceNode(vnode.el = node.content.firstChild, node, parentComponent);
|
|
} else if (domType !== 8 || isFragmentStart) {
|
|
nextNode = onMismatch();
|
|
} else {
|
|
nextNode = nextSibling(node);
|
|
}
|
|
break;
|
|
case Static:
|
|
if (isFragmentStart) {
|
|
node = nextSibling(node);
|
|
domType = node.nodeType;
|
|
}
|
|
if (domType === 1 || domType === 3) {
|
|
nextNode = node;
|
|
const needToAdoptContent = !vnode.children.length;
|
|
for (let i = 0; i < vnode.staticCount; i++) {
|
|
if (needToAdoptContent) vnode.children += nextNode.nodeType === 1 ? nextNode.outerHTML : nextNode.data;
|
|
if (i === vnode.staticCount - 1) {
|
|
vnode.anchor = nextNode;
|
|
}
|
|
nextNode = nextSibling(nextNode);
|
|
}
|
|
return isFragmentStart ? nextSibling(nextNode) : nextNode;
|
|
} else {
|
|
onMismatch();
|
|
}
|
|
break;
|
|
case Fragment:
|
|
if (!isFragmentStart) {
|
|
nextNode = onMismatch();
|
|
} else {
|
|
nextNode = hydrateFragment(node, vnode, parentComponent, parentSuspense, slotScopeIds, optimized);
|
|
}
|
|
break;
|
|
default:
|
|
if (shapeFlag & 1) {
|
|
if ((domType !== 1 || vnode.type.toLowerCase() !== node.tagName.toLowerCase()) && !isTemplateNode(node)) {
|
|
nextNode = onMismatch();
|
|
} else {
|
|
nextNode = hydrateElement(node, vnode, parentComponent, parentSuspense, slotScopeIds, optimized);
|
|
}
|
|
} else if (shapeFlag & 6) {
|
|
vnode.slotScopeIds = slotScopeIds;
|
|
const container = parentNode(node);
|
|
if (isFragmentStart) {
|
|
nextNode = locateClosingAnchor(node);
|
|
} else if (isComment(node) && node.data === "teleport start") {
|
|
nextNode = locateClosingAnchor(node, node.data, "teleport end");
|
|
} else {
|
|
nextNode = nextSibling(node);
|
|
}
|
|
mountComponent(vnode, container, null, parentComponent, parentSuspense, getContainerType(container), optimized);
|
|
if (isAsyncWrapper(vnode) && !vnode.type.__asyncResolved) {
|
|
let subTree;
|
|
if (isFragmentStart) {
|
|
subTree = createVNode(Fragment);
|
|
subTree.anchor = nextNode ? nextNode.previousSibling : container.lastChild;
|
|
} else {
|
|
subTree = node.nodeType === 3 ? createTextVNode("") : createVNode("div");
|
|
}
|
|
subTree.el = node;
|
|
vnode.component.subTree = subTree;
|
|
}
|
|
} else if (shapeFlag & 64) {
|
|
if (domType !== 8) {
|
|
nextNode = onMismatch();
|
|
} else {
|
|
nextNode = vnode.type.hydrate(node, vnode, parentComponent, parentSuspense, slotScopeIds, optimized, rendererInternals, hydrateChildren);
|
|
}
|
|
} else if (shapeFlag & 128) {
|
|
nextNode = vnode.type.hydrate(node, vnode, parentComponent, parentSuspense, getContainerType(parentNode(node)), slotScopeIds, optimized, rendererInternals, hydrateNode);
|
|
} else if ( false || __VUE_PROD_HYDRATION_MISMATCH_DETAILS__) {
|
|
warn$1("Invalid HostVNode type:", type, `(${typeof type})`);
|
|
}
|
|
}
|
|
if (ref != null) {
|
|
setRef(ref, null, parentSuspense, vnode);
|
|
}
|
|
return nextNode;
|
|
};
|
|
const hydrateElement = (el, vnode, parentComponent, parentSuspense, slotScopeIds, optimized) => {
|
|
optimized = optimized || !!vnode.dynamicChildren;
|
|
const {
|
|
type,
|
|
props,
|
|
patchFlag,
|
|
shapeFlag,
|
|
dirs,
|
|
transition
|
|
} = vnode;
|
|
const forcePatch = type === "input" || type === "option";
|
|
if ( false || forcePatch || patchFlag !== -1) {
|
|
if (dirs) {
|
|
invokeDirectiveHook(vnode, null, parentComponent, "created");
|
|
}
|
|
let needCallTransitionHooks = false;
|
|
if (isTemplateNode(el)) {
|
|
needCallTransitionHooks = needTransition(null,
|
|
// no need check parentSuspense in hydration
|
|
transition) && parentComponent && parentComponent.vnode.props && parentComponent.vnode.props.appear;
|
|
const content = el.content.firstChild;
|
|
if (needCallTransitionHooks) {
|
|
transition.beforeEnter(content);
|
|
}
|
|
replaceNode(content, el, parentComponent);
|
|
vnode.el = el = content;
|
|
}
|
|
if (shapeFlag & 16 &&
|
|
// skip if element has innerHTML / textContent
|
|
!(props && (props.innerHTML || props.textContent))) {
|
|
let next = hydrateChildren(el.firstChild, vnode, el, parentComponent, parentSuspense, slotScopeIds, optimized);
|
|
let hasWarned = false;
|
|
while (next) {
|
|
if (!isMismatchAllowed(el, 1 /* CHILDREN */)) {
|
|
if (( false || __VUE_PROD_HYDRATION_MISMATCH_DETAILS__) && !hasWarned) {
|
|
warn$1(`Hydration children mismatch on`, el, `
|
|
Server rendered element contains more child nodes than client vdom.`);
|
|
hasWarned = true;
|
|
}
|
|
logMismatchError();
|
|
}
|
|
const cur = next;
|
|
next = next.nextSibling;
|
|
remove(cur);
|
|
}
|
|
} else if (shapeFlag & 8) {
|
|
let clientText = vnode.children;
|
|
if (clientText[0] === "\n" && (el.tagName === "PRE" || el.tagName === "TEXTAREA")) {
|
|
clientText = clientText.slice(1);
|
|
}
|
|
if (el.textContent !== clientText) {
|
|
if (!isMismatchAllowed(el, 0 /* TEXT */)) {
|
|
( false || __VUE_PROD_HYDRATION_MISMATCH_DETAILS__) && warn$1(`Hydration text content mismatch on`, el, `
|
|
- rendered on server: ${el.textContent}
|
|
- expected on client: ${vnode.children}`);
|
|
logMismatchError();
|
|
}
|
|
el.textContent = vnode.children;
|
|
}
|
|
}
|
|
if (props) {
|
|
if ( false || __VUE_PROD_HYDRATION_MISMATCH_DETAILS__ || forcePatch || !optimized || patchFlag & (16 | 32)) {
|
|
const isCustomElement = el.tagName.includes("-");
|
|
for (const key in props) {
|
|
if (( false || __VUE_PROD_HYDRATION_MISMATCH_DETAILS__) &&
|
|
// #11189 skip if this node has directives that have created hooks
|
|
// as it could have mutated the DOM in any possible way
|
|
!(dirs && dirs.some(d => d.dir.created)) && propHasMismatch(el, key, props[key], vnode, parentComponent)) {
|
|
logMismatchError();
|
|
}
|
|
if (forcePatch && (key.endsWith("value") || key === "indeterminate") || isOn(key) && !isReservedProp(key) ||
|
|
// force hydrate v-bind with .prop modifiers
|
|
key[0] === "." || isCustomElement) {
|
|
patchProp(el, key, null, props[key], void 0, parentComponent);
|
|
}
|
|
}
|
|
} else if (props.onClick) {
|
|
patchProp(el, "onClick", null, props.onClick, void 0, parentComponent);
|
|
} else if (patchFlag & 4 && isReactive(props.style)) {
|
|
for (const key in props.style) props.style[key];
|
|
}
|
|
}
|
|
let vnodeHooks;
|
|
if (vnodeHooks = props && props.onVnodeBeforeMount) {
|
|
invokeVNodeHook(vnodeHooks, parentComponent, vnode);
|
|
}
|
|
if (dirs) {
|
|
invokeDirectiveHook(vnode, null, parentComponent, "beforeMount");
|
|
}
|
|
if ((vnodeHooks = props && props.onVnodeMounted) || dirs || needCallTransitionHooks) {
|
|
queueEffectWithSuspense(() => {
|
|
vnodeHooks && invokeVNodeHook(vnodeHooks, parentComponent, vnode);
|
|
needCallTransitionHooks && transition.enter(el);
|
|
dirs && invokeDirectiveHook(vnode, null, parentComponent, "mounted");
|
|
}, parentSuspense);
|
|
}
|
|
}
|
|
return el.nextSibling;
|
|
};
|
|
const hydrateChildren = (node, parentVNode, container, parentComponent, parentSuspense, slotScopeIds, optimized) => {
|
|
optimized = optimized || !!parentVNode.dynamicChildren;
|
|
const children = parentVNode.children;
|
|
const l = children.length;
|
|
let hasWarned = false;
|
|
for (let i = 0; i < l; i++) {
|
|
const vnode = optimized ? children[i] : children[i] = normalizeVNode(children[i]);
|
|
const isText = vnode.type === Text;
|
|
if (node) {
|
|
if (isText && !optimized) {
|
|
if (i + 1 < l && normalizeVNode(children[i + 1]).type === Text) {
|
|
insert(createText(node.data.slice(vnode.children.length)), container, nextSibling(node));
|
|
node.data = vnode.children;
|
|
}
|
|
}
|
|
node = hydrateNode(node, vnode, parentComponent, parentSuspense, slotScopeIds, optimized);
|
|
} else if (isText && !vnode.children) {
|
|
insert(vnode.el = createText(""), container);
|
|
} else {
|
|
if (!isMismatchAllowed(container, 1 /* CHILDREN */)) {
|
|
if (( false || __VUE_PROD_HYDRATION_MISMATCH_DETAILS__) && !hasWarned) {
|
|
warn$1(`Hydration children mismatch on`, container, `
|
|
Server rendered element contains fewer child nodes than client vdom.`);
|
|
hasWarned = true;
|
|
}
|
|
logMismatchError();
|
|
}
|
|
patch(null, vnode, container, null, parentComponent, parentSuspense, getContainerType(container), slotScopeIds);
|
|
}
|
|
}
|
|
return node;
|
|
};
|
|
const hydrateFragment = (node, vnode, parentComponent, parentSuspense, slotScopeIds, optimized) => {
|
|
const {
|
|
slotScopeIds: fragmentSlotScopeIds
|
|
} = vnode;
|
|
if (fragmentSlotScopeIds) {
|
|
slotScopeIds = slotScopeIds ? slotScopeIds.concat(fragmentSlotScopeIds) : fragmentSlotScopeIds;
|
|
}
|
|
const container = parentNode(node);
|
|
const next = hydrateChildren(nextSibling(node), vnode, container, parentComponent, parentSuspense, slotScopeIds, optimized);
|
|
if (next && isComment(next) && next.data === "]") {
|
|
return nextSibling(vnode.anchor = next);
|
|
} else {
|
|
logMismatchError();
|
|
insert(vnode.anchor = createComment(`]`), container, next);
|
|
return next;
|
|
}
|
|
};
|
|
const handleMismatch = (node, vnode, parentComponent, parentSuspense, slotScopeIds, isFragment) => {
|
|
if (!isMismatchAllowed(node.parentElement, 1 /* CHILDREN */)) {
|
|
( false || __VUE_PROD_HYDRATION_MISMATCH_DETAILS__) && warn$1(`Hydration node mismatch:
|
|
- rendered on server:`, node, node.nodeType === 3 ? `(text)` : isComment(node) && node.data === "[" ? `(start of fragment)` : ``, `
|
|
- expected on client:`, vnode.type);
|
|
logMismatchError();
|
|
}
|
|
vnode.el = null;
|
|
if (isFragment) {
|
|
const end = locateClosingAnchor(node);
|
|
while (true) {
|
|
const next2 = nextSibling(node);
|
|
if (next2 && next2 !== end) {
|
|
remove(next2);
|
|
} else {
|
|
break;
|
|
}
|
|
}
|
|
}
|
|
const next = nextSibling(node);
|
|
const container = parentNode(node);
|
|
remove(node);
|
|
patch(null, vnode, container, next, parentComponent, parentSuspense, getContainerType(container), slotScopeIds);
|
|
if (parentComponent) {
|
|
parentComponent.vnode.el = vnode.el;
|
|
updateHOCHostEl(parentComponent, vnode.el);
|
|
}
|
|
return next;
|
|
};
|
|
const locateClosingAnchor = (node, open = "[", close = "]") => {
|
|
let match = 0;
|
|
while (node) {
|
|
node = nextSibling(node);
|
|
if (node && isComment(node)) {
|
|
if (node.data === open) match++;
|
|
if (node.data === close) {
|
|
if (match === 0) {
|
|
return nextSibling(node);
|
|
} else {
|
|
match--;
|
|
}
|
|
}
|
|
}
|
|
}
|
|
return node;
|
|
};
|
|
const replaceNode = (newNode, oldNode, parentComponent) => {
|
|
const parentNode2 = oldNode.parentNode;
|
|
if (parentNode2) {
|
|
parentNode2.replaceChild(newNode, oldNode);
|
|
}
|
|
let parent = parentComponent;
|
|
while (parent) {
|
|
if (parent.vnode.el === oldNode) {
|
|
parent.vnode.el = parent.subTree.el = newNode;
|
|
}
|
|
parent = parent.parent;
|
|
}
|
|
};
|
|
const isTemplateNode = node => {
|
|
return node.nodeType === 1 && node.tagName === "TEMPLATE";
|
|
};
|
|
return [hydrate, hydrateNode];
|
|
}
|
|
function propHasMismatch(el, key, clientValue, vnode, instance) {
|
|
let mismatchType;
|
|
let mismatchKey;
|
|
let actual;
|
|
let expected;
|
|
if (key === "class") {
|
|
actual = el.getAttribute("class");
|
|
expected = normalizeClass(clientValue);
|
|
if (!isSetEqual(toClassSet(actual || ""), toClassSet(expected))) {
|
|
mismatchType = 2 /* CLASS */;
|
|
mismatchKey = `class`;
|
|
}
|
|
} else if (key === "style") {
|
|
actual = el.getAttribute("style") || "";
|
|
expected = isString(clientValue) ? clientValue : stringifyStyle(normalizeStyle(clientValue));
|
|
const actualMap = toStyleMap(actual);
|
|
const expectedMap = toStyleMap(expected);
|
|
if (vnode.dirs) {
|
|
for (const {
|
|
dir,
|
|
value
|
|
} of vnode.dirs) {
|
|
if (dir.name === "show" && !value) {
|
|
expectedMap.set("display", "none");
|
|
}
|
|
}
|
|
}
|
|
if (instance) {
|
|
resolveCssVars(instance, vnode, expectedMap);
|
|
}
|
|
if (!isMapEqual(actualMap, expectedMap)) {
|
|
mismatchType = 3 /* STYLE */;
|
|
mismatchKey = "style";
|
|
}
|
|
} else if (el instanceof SVGElement && isKnownSvgAttr(key) || el instanceof HTMLElement && (isBooleanAttr(key) || isKnownHtmlAttr(key))) {
|
|
if (isBooleanAttr(key)) {
|
|
actual = el.hasAttribute(key);
|
|
expected = includeBooleanAttr(clientValue);
|
|
} else if (clientValue == null) {
|
|
actual = el.hasAttribute(key);
|
|
expected = false;
|
|
} else {
|
|
if (el.hasAttribute(key)) {
|
|
actual = el.getAttribute(key);
|
|
} else if (key === "value" && el.tagName === "TEXTAREA") {
|
|
actual = el.value;
|
|
} else {
|
|
actual = false;
|
|
}
|
|
expected = isRenderableAttrValue(clientValue) ? String(clientValue) : false;
|
|
}
|
|
if (actual !== expected) {
|
|
mismatchType = 4 /* ATTRIBUTE */;
|
|
mismatchKey = key;
|
|
}
|
|
}
|
|
if (mismatchType != null && !isMismatchAllowed(el, mismatchType)) {
|
|
const format = v => v === false ? `(not rendered)` : `${mismatchKey}="${v}"`;
|
|
const preSegment = `Hydration ${MismatchTypeString[mismatchType]} mismatch on`;
|
|
const postSegment = `
|
|
- rendered on server: ${format(actual)}
|
|
- expected on client: ${format(expected)}
|
|
Note: this mismatch is check-only. The DOM will not be rectified in production due to performance overhead.
|
|
You should fix the source of the mismatch.`;
|
|
{
|
|
warn$1(preSegment, el, postSegment);
|
|
}
|
|
return true;
|
|
}
|
|
return false;
|
|
}
|
|
function toClassSet(str) {
|
|
return new Set(str.trim().split(/\s+/));
|
|
}
|
|
function isSetEqual(a, b) {
|
|
if (a.size !== b.size) {
|
|
return false;
|
|
}
|
|
for (const s of a) {
|
|
if (!b.has(s)) {
|
|
return false;
|
|
}
|
|
}
|
|
return true;
|
|
}
|
|
function toStyleMap(str) {
|
|
const styleMap = /* @__PURE__ */new Map();
|
|
for (const item of str.split(";")) {
|
|
let [key, value] = item.split(":");
|
|
key = key.trim();
|
|
value = value && value.trim();
|
|
if (key && value) {
|
|
styleMap.set(key, value);
|
|
}
|
|
}
|
|
return styleMap;
|
|
}
|
|
function isMapEqual(a, b) {
|
|
if (a.size !== b.size) {
|
|
return false;
|
|
}
|
|
for (const [key, value] of a) {
|
|
if (value !== b.get(key)) {
|
|
return false;
|
|
}
|
|
}
|
|
return true;
|
|
}
|
|
function resolveCssVars(instance, vnode, expectedMap) {
|
|
const root = instance.subTree;
|
|
if (instance.getCssVars && (vnode === root || root && root.type === Fragment && root.children.includes(vnode))) {
|
|
const cssVars = instance.getCssVars();
|
|
for (const key in cssVars) {
|
|
expectedMap.set(`--${getEscapedCssVarName(key, false)}`, String(cssVars[key]));
|
|
}
|
|
}
|
|
if (vnode === root && instance.parent) {
|
|
resolveCssVars(instance.parent, instance.vnode, expectedMap);
|
|
}
|
|
}
|
|
const allowMismatchAttr = "data-allow-mismatch";
|
|
const MismatchTypeString = {
|
|
[0 /* TEXT */]: "text",
|
|
[1 /* CHILDREN */]: "children",
|
|
[2 /* CLASS */]: "class",
|
|
[3 /* STYLE */]: "style",
|
|
[4 /* ATTRIBUTE */]: "attribute"
|
|
};
|
|
function isMismatchAllowed(el, allowedType) {
|
|
if (allowedType === 0 /* TEXT */ || allowedType === 1 /* CHILDREN */) {
|
|
while (el && !el.hasAttribute(allowMismatchAttr)) {
|
|
el = el.parentElement;
|
|
}
|
|
}
|
|
const allowedAttr = el && el.getAttribute(allowMismatchAttr);
|
|
if (allowedAttr == null) {
|
|
return false;
|
|
} else if (allowedAttr === "") {
|
|
return true;
|
|
} else {
|
|
const list = allowedAttr.split(",");
|
|
if (allowedType === 0 /* TEXT */ && list.includes("children")) {
|
|
return true;
|
|
}
|
|
return allowedAttr.split(",").includes(MismatchTypeString[allowedType]);
|
|
}
|
|
}
|
|
const requestIdleCallback = (0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .getGlobalThis */ .We)().requestIdleCallback || (cb => setTimeout(cb, 1));
|
|
const cancelIdleCallback = (0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .getGlobalThis */ .We)().cancelIdleCallback || (id => clearTimeout(id));
|
|
const hydrateOnIdle = (timeout = 1e4) => hydrate => {
|
|
const id = requestIdleCallback(hydrate, {
|
|
timeout
|
|
});
|
|
return () => cancelIdleCallback(id);
|
|
};
|
|
function elementIsVisibleInViewport(el) {
|
|
const {
|
|
top,
|
|
left,
|
|
bottom,
|
|
right
|
|
} = el.getBoundingClientRect();
|
|
const {
|
|
innerHeight,
|
|
innerWidth
|
|
} = window;
|
|
return (top > 0 && top < innerHeight || bottom > 0 && bottom < innerHeight) && (left > 0 && left < innerWidth || right > 0 && right < innerWidth);
|
|
}
|
|
const hydrateOnVisible = opts => (hydrate, forEach) => {
|
|
const ob = new IntersectionObserver(entries => {
|
|
for (const e of entries) {
|
|
if (!e.isIntersecting) continue;
|
|
ob.disconnect();
|
|
hydrate();
|
|
break;
|
|
}
|
|
}, opts);
|
|
forEach(el => {
|
|
if (!(el instanceof Element)) return;
|
|
if (elementIsVisibleInViewport(el)) {
|
|
hydrate();
|
|
ob.disconnect();
|
|
return false;
|
|
}
|
|
ob.observe(el);
|
|
});
|
|
return () => ob.disconnect();
|
|
};
|
|
const hydrateOnMediaQuery = query => hydrate => {
|
|
if (query) {
|
|
const mql = matchMedia(query);
|
|
if (mql.matches) {
|
|
hydrate();
|
|
} else {
|
|
mql.addEventListener("change", hydrate, {
|
|
once: true
|
|
});
|
|
return () => mql.removeEventListener("change", hydrate);
|
|
}
|
|
}
|
|
};
|
|
const hydrateOnInteraction = (interactions = []) => (hydrate, forEach) => {
|
|
if (isString(interactions)) interactions = [interactions];
|
|
let hasHydrated = false;
|
|
const doHydrate = e => {
|
|
if (!hasHydrated) {
|
|
hasHydrated = true;
|
|
teardown();
|
|
hydrate();
|
|
e.target.dispatchEvent(new e.constructor(e.type, e));
|
|
}
|
|
};
|
|
const teardown = () => {
|
|
forEach(el => {
|
|
for (const i of interactions) {
|
|
el.removeEventListener(i, doHydrate);
|
|
}
|
|
});
|
|
};
|
|
forEach(el => {
|
|
for (const i of interactions) {
|
|
el.addEventListener(i, doHydrate, {
|
|
once: true
|
|
});
|
|
}
|
|
});
|
|
return teardown;
|
|
};
|
|
function forEachElement(node, cb) {
|
|
if (isComment(node) && node.data === "[") {
|
|
let depth = 1;
|
|
let next = node.nextSibling;
|
|
while (next) {
|
|
if (next.nodeType === 1) {
|
|
const result = cb(next);
|
|
if (result === false) {
|
|
break;
|
|
}
|
|
} else if (isComment(next)) {
|
|
if (next.data === "]") {
|
|
if (--depth === 0) break;
|
|
} else if (next.data === "[") {
|
|
depth++;
|
|
}
|
|
}
|
|
next = next.nextSibling;
|
|
}
|
|
} else {
|
|
cb(node);
|
|
}
|
|
}
|
|
const isAsyncWrapper = i => !!i.type.__asyncLoader;
|
|
/*! #__NO_SIDE_EFFECTS__ */
|
|
// @__NO_SIDE_EFFECTS__
|
|
function defineAsyncComponent(source) {
|
|
if (isFunction(source)) {
|
|
source = {
|
|
loader: source
|
|
};
|
|
}
|
|
const {
|
|
loader,
|
|
loadingComponent,
|
|
errorComponent,
|
|
delay = 200,
|
|
hydrate: hydrateStrategy,
|
|
timeout,
|
|
// undefined = never times out
|
|
suspensible = true,
|
|
onError: userOnError
|
|
} = source;
|
|
let pendingRequest = null;
|
|
let resolvedComp;
|
|
let retries = 0;
|
|
const retry = () => {
|
|
retries++;
|
|
pendingRequest = null;
|
|
return load();
|
|
};
|
|
const load = () => {
|
|
let thisRequest;
|
|
return pendingRequest || (thisRequest = pendingRequest = loader().catch(err => {
|
|
err = err instanceof Error ? err : new Error(String(err));
|
|
if (userOnError) {
|
|
return new Promise((resolve, reject) => {
|
|
const userRetry = () => resolve(retry());
|
|
const userFail = () => reject(err);
|
|
userOnError(err, userRetry, userFail, retries + 1);
|
|
});
|
|
} else {
|
|
throw err;
|
|
}
|
|
}).then(comp => {
|
|
if (thisRequest !== pendingRequest && pendingRequest) {
|
|
return pendingRequest;
|
|
}
|
|
if (false) {}
|
|
if (comp && (comp.__esModule || comp[Symbol.toStringTag] === "Module")) {
|
|
comp = comp.default;
|
|
}
|
|
if (false) {}
|
|
resolvedComp = comp;
|
|
return comp;
|
|
}));
|
|
};
|
|
return defineComponent({
|
|
name: "AsyncComponentWrapper",
|
|
__asyncLoader: load,
|
|
__asyncHydrate(el, instance, hydrate) {
|
|
const doHydrate = hydrateStrategy ? () => {
|
|
const teardown = hydrateStrategy(hydrate, cb => forEachElement(el, cb));
|
|
if (teardown) {
|
|
(instance.bum || (instance.bum = [])).push(teardown);
|
|
}
|
|
} : hydrate;
|
|
if (resolvedComp) {
|
|
doHydrate();
|
|
} else {
|
|
load().then(() => !instance.isUnmounted && doHydrate());
|
|
}
|
|
},
|
|
get __asyncResolved() {
|
|
return resolvedComp;
|
|
},
|
|
setup() {
|
|
const instance = currentInstance;
|
|
markAsyncBoundary(instance);
|
|
if (resolvedComp) {
|
|
return () => createInnerComp(resolvedComp, instance);
|
|
}
|
|
const onError = err => {
|
|
pendingRequest = null;
|
|
handleError(err, instance, 13, !errorComponent);
|
|
};
|
|
if (suspensible && instance.suspense || isInSSRComponentSetup) {
|
|
return load().then(comp => {
|
|
return () => createInnerComp(comp, instance);
|
|
}).catch(err => {
|
|
onError(err);
|
|
return () => errorComponent ? createVNode(errorComponent, {
|
|
error: err
|
|
}) : null;
|
|
});
|
|
}
|
|
const loaded = ref(false);
|
|
const error = ref();
|
|
const delayed = ref(!!delay);
|
|
if (delay) {
|
|
setTimeout(() => {
|
|
delayed.value = false;
|
|
}, delay);
|
|
}
|
|
if (timeout != null) {
|
|
setTimeout(() => {
|
|
if (!loaded.value && !error.value) {
|
|
const err = new Error(`Async component timed out after ${timeout}ms.`);
|
|
onError(err);
|
|
error.value = err;
|
|
}
|
|
}, timeout);
|
|
}
|
|
load().then(() => {
|
|
loaded.value = true;
|
|
if (instance.parent && isKeepAlive(instance.parent.vnode)) {
|
|
instance.parent.update();
|
|
}
|
|
}).catch(err => {
|
|
onError(err);
|
|
error.value = err;
|
|
});
|
|
return () => {
|
|
if (loaded.value && resolvedComp) {
|
|
return createInnerComp(resolvedComp, instance);
|
|
} else if (error.value && errorComponent) {
|
|
return createVNode(errorComponent, {
|
|
error: error.value
|
|
});
|
|
} else if (loadingComponent && !delayed.value) {
|
|
return createVNode(loadingComponent);
|
|
}
|
|
};
|
|
}
|
|
});
|
|
}
|
|
function createInnerComp(comp, parent) {
|
|
const {
|
|
ref: ref2,
|
|
props,
|
|
children,
|
|
ce
|
|
} = parent.vnode;
|
|
const vnode = createVNode(comp, props, children);
|
|
vnode.ref = ref2;
|
|
vnode.ce = ce;
|
|
delete parent.vnode.ce;
|
|
return vnode;
|
|
}
|
|
const isKeepAlive = vnode => vnode.type.__isKeepAlive;
|
|
const KeepAliveImpl = {
|
|
name: `KeepAlive`,
|
|
// Marker for special handling inside the renderer. We are not using a ===
|
|
// check directly on KeepAlive in the renderer, because importing it directly
|
|
// would prevent it from being tree-shaken.
|
|
__isKeepAlive: true,
|
|
props: {
|
|
include: [String, RegExp, Array],
|
|
exclude: [String, RegExp, Array],
|
|
max: [String, Number]
|
|
},
|
|
setup(props, {
|
|
slots
|
|
}) {
|
|
const instance = getCurrentInstance();
|
|
const sharedContext = instance.ctx;
|
|
if (!sharedContext.renderer) {
|
|
return () => {
|
|
const children = slots.default && slots.default();
|
|
return children && children.length === 1 ? children[0] : children;
|
|
};
|
|
}
|
|
const cache = /* @__PURE__ */new Map();
|
|
const keys = /* @__PURE__ */new Set();
|
|
let current = null;
|
|
if (false) {}
|
|
const parentSuspense = instance.suspense;
|
|
const {
|
|
renderer: {
|
|
p: patch,
|
|
m: move,
|
|
um: _unmount,
|
|
o: {
|
|
createElement
|
|
}
|
|
}
|
|
} = sharedContext;
|
|
const storageContainer = createElement("div");
|
|
sharedContext.activate = (vnode, container, anchor, namespace, optimized) => {
|
|
const instance2 = vnode.component;
|
|
move(vnode, container, anchor, 0, parentSuspense);
|
|
patch(instance2.vnode, vnode, container, anchor, instance2, parentSuspense, namespace, vnode.slotScopeIds, optimized);
|
|
queuePostRenderEffect(() => {
|
|
instance2.isDeactivated = false;
|
|
if (instance2.a) {
|
|
(0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .invokeArrayFns */ .DY)(instance2.a);
|
|
}
|
|
const vnodeHook = vnode.props && vnode.props.onVnodeMounted;
|
|
if (vnodeHook) {
|
|
invokeVNodeHook(vnodeHook, instance2.parent, vnode);
|
|
}
|
|
}, parentSuspense);
|
|
if (false) {}
|
|
};
|
|
sharedContext.deactivate = vnode => {
|
|
const instance2 = vnode.component;
|
|
invalidateMount(instance2.m);
|
|
invalidateMount(instance2.a);
|
|
move(vnode, storageContainer, null, 1, parentSuspense);
|
|
queuePostRenderEffect(() => {
|
|
if (instance2.da) {
|
|
(0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .invokeArrayFns */ .DY)(instance2.da);
|
|
}
|
|
const vnodeHook = vnode.props && vnode.props.onVnodeUnmounted;
|
|
if (vnodeHook) {
|
|
invokeVNodeHook(vnodeHook, instance2.parent, vnode);
|
|
}
|
|
instance2.isDeactivated = true;
|
|
}, parentSuspense);
|
|
if (false) {}
|
|
};
|
|
function unmount(vnode) {
|
|
resetShapeFlag(vnode);
|
|
_unmount(vnode, instance, parentSuspense, true);
|
|
}
|
|
function pruneCache(filter) {
|
|
cache.forEach((vnode, key) => {
|
|
const name = getComponentName(vnode.type);
|
|
if (name && !filter(name)) {
|
|
pruneCacheEntry(key);
|
|
}
|
|
});
|
|
}
|
|
function pruneCacheEntry(key) {
|
|
const cached = cache.get(key);
|
|
if (cached && (!current || !isSameVNodeType(cached, current))) {
|
|
unmount(cached);
|
|
} else if (current) {
|
|
resetShapeFlag(current);
|
|
}
|
|
cache.delete(key);
|
|
keys.delete(key);
|
|
}
|
|
watch(() => [props.include, props.exclude], ([include, exclude]) => {
|
|
include && pruneCache(name => matches(include, name));
|
|
exclude && pruneCache(name => !matches(exclude, name));
|
|
},
|
|
// prune post-render after `current` has been updated
|
|
{
|
|
flush: "post",
|
|
deep: true
|
|
});
|
|
let pendingCacheKey = null;
|
|
const cacheSubtree = () => {
|
|
if (pendingCacheKey != null) {
|
|
if (isSuspense(instance.subTree.type)) {
|
|
queuePostRenderEffect(() => {
|
|
cache.set(pendingCacheKey, getInnerChild(instance.subTree));
|
|
}, instance.subTree.suspense);
|
|
} else {
|
|
cache.set(pendingCacheKey, getInnerChild(instance.subTree));
|
|
}
|
|
}
|
|
};
|
|
onMounted(cacheSubtree);
|
|
onUpdated(cacheSubtree);
|
|
onBeforeUnmount(() => {
|
|
cache.forEach(cached => {
|
|
const {
|
|
subTree,
|
|
suspense
|
|
} = instance;
|
|
const vnode = getInnerChild(subTree);
|
|
if (cached.type === vnode.type && cached.key === vnode.key) {
|
|
resetShapeFlag(vnode);
|
|
const da = vnode.component.da;
|
|
da && queuePostRenderEffect(da, suspense);
|
|
return;
|
|
}
|
|
unmount(cached);
|
|
});
|
|
});
|
|
return () => {
|
|
pendingCacheKey = null;
|
|
if (!slots.default) {
|
|
return current = null;
|
|
}
|
|
const children = slots.default();
|
|
const rawVNode = children[0];
|
|
if (children.length > 1) {
|
|
if (false) {}
|
|
current = null;
|
|
return children;
|
|
} else if (!isVNode(rawVNode) || !(rawVNode.shapeFlag & 4) && !(rawVNode.shapeFlag & 128)) {
|
|
current = null;
|
|
return rawVNode;
|
|
}
|
|
let vnode = getInnerChild(rawVNode);
|
|
if (vnode.type === Comment) {
|
|
current = null;
|
|
return vnode;
|
|
}
|
|
const comp = vnode.type;
|
|
const name = getComponentName(isAsyncWrapper(vnode) ? vnode.type.__asyncResolved || {} : comp);
|
|
const {
|
|
include,
|
|
exclude,
|
|
max
|
|
} = props;
|
|
if (include && (!name || !matches(include, name)) || exclude && name && matches(exclude, name)) {
|
|
vnode.shapeFlag &= ~256;
|
|
current = vnode;
|
|
return rawVNode;
|
|
}
|
|
const key = vnode.key == null ? comp : vnode.key;
|
|
const cachedVNode = cache.get(key);
|
|
if (vnode.el) {
|
|
vnode = cloneVNode(vnode);
|
|
if (rawVNode.shapeFlag & 128) {
|
|
rawVNode.ssContent = vnode;
|
|
}
|
|
}
|
|
pendingCacheKey = key;
|
|
if (cachedVNode) {
|
|
vnode.el = cachedVNode.el;
|
|
vnode.component = cachedVNode.component;
|
|
if (vnode.transition) {
|
|
setTransitionHooks(vnode, vnode.transition);
|
|
}
|
|
vnode.shapeFlag |= 512;
|
|
keys.delete(key);
|
|
keys.add(key);
|
|
} else {
|
|
keys.add(key);
|
|
if (max && keys.size > parseInt(max, 10)) {
|
|
pruneCacheEntry(keys.values().next().value);
|
|
}
|
|
}
|
|
vnode.shapeFlag |= 256;
|
|
current = vnode;
|
|
return isSuspense(rawVNode.type) ? rawVNode : vnode;
|
|
};
|
|
}
|
|
};
|
|
const KeepAlive = (/* unused pure expression or super */ null && (KeepAliveImpl));
|
|
function matches(pattern, name) {
|
|
if ((0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .isArray */ .cy)(pattern)) {
|
|
return pattern.some(p => matches(p, name));
|
|
} else if ((0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .isString */ .Kg)(pattern)) {
|
|
return pattern.split(",").includes(name);
|
|
} else if ((0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .isRegExp */ .gd)(pattern)) {
|
|
pattern.lastIndex = 0;
|
|
return pattern.test(name);
|
|
}
|
|
return false;
|
|
}
|
|
function onActivated(hook, target) {
|
|
registerKeepAliveHook(hook, "a", target);
|
|
}
|
|
function onDeactivated(hook, target) {
|
|
registerKeepAliveHook(hook, "da", target);
|
|
}
|
|
function registerKeepAliveHook(hook, type, target = currentInstance) {
|
|
const wrappedHook = hook.__wdc || (hook.__wdc = () => {
|
|
let current = target;
|
|
while (current) {
|
|
if (current.isDeactivated) {
|
|
return;
|
|
}
|
|
current = current.parent;
|
|
}
|
|
return hook();
|
|
});
|
|
injectHook(type, wrappedHook, target);
|
|
if (target) {
|
|
let current = target.parent;
|
|
while (current && current.parent) {
|
|
if (isKeepAlive(current.parent.vnode)) {
|
|
injectToKeepAliveRoot(wrappedHook, type, target, current);
|
|
}
|
|
current = current.parent;
|
|
}
|
|
}
|
|
}
|
|
function injectToKeepAliveRoot(hook, type, target, keepAliveRoot) {
|
|
const injected = injectHook(type, hook, keepAliveRoot, true
|
|
/* prepend */);
|
|
onUnmounted(() => {
|
|
(0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .remove */ .TF)(keepAliveRoot[type], injected);
|
|
}, target);
|
|
}
|
|
function resetShapeFlag(vnode) {
|
|
vnode.shapeFlag &= ~256;
|
|
vnode.shapeFlag &= ~512;
|
|
}
|
|
function getInnerChild(vnode) {
|
|
return vnode.shapeFlag & 128 ? vnode.ssContent : vnode;
|
|
}
|
|
function injectHook(type, hook, target = currentInstance, prepend = false) {
|
|
if (target) {
|
|
const hooks = target[type] || (target[type] = []);
|
|
const wrappedHook = hook.__weh || (hook.__weh = (...args) => {
|
|
(0,_vue_reactivity__WEBPACK_IMPORTED_MODULE_17__/* .pauseTracking */ .C4)();
|
|
const reset = setCurrentInstance(target);
|
|
const res = callWithAsyncErrorHandling(hook, target, type, args);
|
|
reset();
|
|
(0,_vue_reactivity__WEBPACK_IMPORTED_MODULE_17__/* .resetTracking */ .bl)();
|
|
return res;
|
|
});
|
|
if (prepend) {
|
|
hooks.unshift(wrappedHook);
|
|
} else {
|
|
hooks.push(wrappedHook);
|
|
}
|
|
return wrappedHook;
|
|
} else if (false) {}
|
|
}
|
|
const createHook = lifecycle => (hook, target = currentInstance) => {
|
|
if (!isInSSRComponentSetup || lifecycle === "sp") {
|
|
injectHook(lifecycle, (...args) => hook(...args), target);
|
|
}
|
|
};
|
|
const onBeforeMount = createHook("bm");
|
|
const onMounted = createHook("m");
|
|
const onBeforeUpdate = createHook("bu");
|
|
const onUpdated = createHook("u");
|
|
const onBeforeUnmount = createHook("bum");
|
|
const onUnmounted = createHook("um");
|
|
const onServerPrefetch = createHook("sp");
|
|
const onRenderTriggered = createHook("rtg");
|
|
const onRenderTracked = createHook("rtc");
|
|
function onErrorCaptured(hook, target = currentInstance) {
|
|
injectHook("ec", hook, target);
|
|
}
|
|
const COMPONENTS = "components";
|
|
const DIRECTIVES = "directives";
|
|
function resolveComponent(name, maybeSelfReference) {
|
|
return resolveAsset(COMPONENTS, name, true, maybeSelfReference) || name;
|
|
}
|
|
const NULL_DYNAMIC_COMPONENT = Symbol.for("v-ndc");
|
|
function resolveDynamicComponent(component) {
|
|
if (isString(component)) {
|
|
return resolveAsset(COMPONENTS, component, false) || component;
|
|
} else {
|
|
return component || NULL_DYNAMIC_COMPONENT;
|
|
}
|
|
}
|
|
function resolveDirective(name) {
|
|
return resolveAsset(DIRECTIVES, name);
|
|
}
|
|
function resolveAsset(type, name, warnMissing = true, maybeSelfReference = false) {
|
|
const instance = currentRenderingInstance || currentInstance;
|
|
if (instance) {
|
|
const Component = instance.type;
|
|
if (type === COMPONENTS) {
|
|
const selfName = getComponentName(Component, false);
|
|
if (selfName && (selfName === name || selfName === camelize(name) || selfName === capitalize(camelize(name)))) {
|
|
return Component;
|
|
}
|
|
}
|
|
const res =
|
|
// local registration
|
|
// check instance[type] first which is resolved for options API
|
|
resolve(instance[type] || Component[type], name) ||
|
|
// global registration
|
|
resolve(instance.appContext[type], name);
|
|
if (!res && maybeSelfReference) {
|
|
return Component;
|
|
}
|
|
if (false) {}
|
|
return res;
|
|
} else if (false) {}
|
|
}
|
|
function resolve(registry, name) {
|
|
return registry && (registry[name] || registry[camelize(name)] || registry[capitalize(camelize(name))]);
|
|
}
|
|
function renderList(source, renderItem, cache, index) {
|
|
let ret;
|
|
const cached = cache && cache[index];
|
|
const sourceIsArray = (0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .isArray */ .cy)(source);
|
|
if (sourceIsArray || (0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .isString */ .Kg)(source)) {
|
|
const sourceIsReactiveArray = sourceIsArray && (0,_vue_reactivity__WEBPACK_IMPORTED_MODULE_17__/* .isReactive */ .g8)(source);
|
|
let needsWrap = false;
|
|
if (sourceIsReactiveArray) {
|
|
needsWrap = !(0,_vue_reactivity__WEBPACK_IMPORTED_MODULE_17__/* .isShallow */ .fE)(source);
|
|
source = (0,_vue_reactivity__WEBPACK_IMPORTED_MODULE_17__/* .shallowReadArray */ .qA)(source);
|
|
}
|
|
ret = new Array(source.length);
|
|
for (let i = 0, l = source.length; i < l; i++) {
|
|
ret[i] = renderItem(needsWrap ? (0,_vue_reactivity__WEBPACK_IMPORTED_MODULE_17__/* .toReactive */ .lJ)(source[i]) : source[i], i, void 0, cached && cached[i]);
|
|
}
|
|
} else if (typeof source === "number") {
|
|
if (false) {}
|
|
ret = new Array(source);
|
|
for (let i = 0; i < source; i++) {
|
|
ret[i] = renderItem(i + 1, i, void 0, cached && cached[i]);
|
|
}
|
|
} else if ((0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .isObject */ .Gv)(source)) {
|
|
if (source[Symbol.iterator]) {
|
|
ret = Array.from(source, (item, i) => renderItem(item, i, void 0, cached && cached[i]));
|
|
} else {
|
|
const keys = Object.keys(source);
|
|
ret = new Array(keys.length);
|
|
for (let i = 0, l = keys.length; i < l; i++) {
|
|
const key = keys[i];
|
|
ret[i] = renderItem(source[key], key, i, cached && cached[i]);
|
|
}
|
|
}
|
|
} else {
|
|
ret = [];
|
|
}
|
|
if (cache) {
|
|
cache[index] = ret;
|
|
}
|
|
return ret;
|
|
}
|
|
function createSlots(slots, dynamicSlots) {
|
|
for (let i = 0; i < dynamicSlots.length; i++) {
|
|
const slot = dynamicSlots[i];
|
|
if (isArray(slot)) {
|
|
for (let j = 0; j < slot.length; j++) {
|
|
slots[slot[j].name] = slot[j].fn;
|
|
}
|
|
} else if (slot) {
|
|
slots[slot.name] = slot.key ? (...args) => {
|
|
const res = slot.fn(...args);
|
|
if (res) res.key = slot.key;
|
|
return res;
|
|
} : slot.fn;
|
|
}
|
|
}
|
|
return slots;
|
|
}
|
|
function renderSlot(slots, name, props = {}, fallback, noSlotted) {
|
|
if (currentRenderingInstance.ce || currentRenderingInstance.parent && isAsyncWrapper(currentRenderingInstance.parent) && currentRenderingInstance.parent.ce) {
|
|
if (name !== "default") props.name = name;
|
|
return openBlock(), createBlock(Fragment, null, [createVNode("slot", props, fallback && fallback())], 64);
|
|
}
|
|
let slot = slots[name];
|
|
if (false) {}
|
|
if (slot && slot._c) {
|
|
slot._d = false;
|
|
}
|
|
openBlock();
|
|
const validSlotContent = slot && ensureValidVNode(slot(props));
|
|
const slotKey = props.key ||
|
|
// slot content array of a dynamic conditional slot may have a branch
|
|
// key attached in the `createSlots` helper, respect that
|
|
validSlotContent && validSlotContent.key;
|
|
const rendered = createBlock(Fragment, {
|
|
key: (slotKey && !isSymbol(slotKey) ? slotKey : `_${name}`) + (
|
|
// #7256 force differentiate fallback content from actual content
|
|
!validSlotContent && fallback ? "_fb" : "")
|
|
}, validSlotContent || (fallback ? fallback() : []), validSlotContent && slots._ === 1 ? 64 : -2);
|
|
if (!noSlotted && rendered.scopeId) {
|
|
rendered.slotScopeIds = [rendered.scopeId + "-s"];
|
|
}
|
|
if (slot && slot._c) {
|
|
slot._d = true;
|
|
}
|
|
return rendered;
|
|
}
|
|
function ensureValidVNode(vnodes) {
|
|
return vnodes.some(child => {
|
|
if (!isVNode(child)) return true;
|
|
if (child.type === Comment) return false;
|
|
if (child.type === Fragment && !ensureValidVNode(child.children)) return false;
|
|
return true;
|
|
}) ? vnodes : null;
|
|
}
|
|
function toHandlers(obj, preserveCaseIfNecessary) {
|
|
const ret = {};
|
|
if (false) {}
|
|
for (const key in obj) {
|
|
ret[preserveCaseIfNecessary && /[A-Z]/.test(key) ? `on:${key}` : toHandlerKey(key)] = obj[key];
|
|
}
|
|
return ret;
|
|
}
|
|
const getPublicInstance = i => {
|
|
if (!i) return null;
|
|
if (isStatefulComponent(i)) return getComponentPublicInstance(i);
|
|
return getPublicInstance(i.parent);
|
|
};
|
|
const publicPropertiesMap =
|
|
// Move PURE marker to new line to workaround compiler discarding it
|
|
// due to type annotation
|
|
/* @__PURE__ */
|
|
(0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .extend */ .X$)(/* @__PURE__ */Object.create(null), {
|
|
$: i => i,
|
|
$el: i => i.vnode.el,
|
|
$data: i => i.data,
|
|
$props: i => false ? 0 : i.props,
|
|
$attrs: i => false ? 0 : i.attrs,
|
|
$slots: i => false ? 0 : i.slots,
|
|
$refs: i => false ? 0 : i.refs,
|
|
$parent: i => getPublicInstance(i.parent),
|
|
$root: i => getPublicInstance(i.root),
|
|
$host: i => i.ce,
|
|
$emit: i => i.emit,
|
|
$options: i => true ? resolveMergedOptions(i) : 0,
|
|
$forceUpdate: i => i.f || (i.f = () => {
|
|
queueJob(i.update);
|
|
}),
|
|
$nextTick: i => i.n || (i.n = nextTick.bind(i.proxy)),
|
|
$watch: i => true ? instanceWatch.bind(i) : 0
|
|
});
|
|
const isReservedPrefix = key => key === "_" || key === "$";
|
|
const hasSetupBinding = (state, key) => state !== _vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .EMPTY_OBJ */ .MZ && !state.__isScriptSetup && (0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .hasOwn */ .$3)(state, key);
|
|
const PublicInstanceProxyHandlers = {
|
|
get({
|
|
_: instance
|
|
}, key) {
|
|
if (key === "__v_skip") {
|
|
return true;
|
|
}
|
|
const {
|
|
ctx,
|
|
setupState,
|
|
data,
|
|
props,
|
|
accessCache,
|
|
type,
|
|
appContext
|
|
} = instance;
|
|
if (false) {}
|
|
let normalizedProps;
|
|
if (key[0] !== "$") {
|
|
const n = accessCache[key];
|
|
if (n !== void 0) {
|
|
switch (n) {
|
|
case 1 /* SETUP */:
|
|
return setupState[key];
|
|
case 2 /* DATA */:
|
|
return data[key];
|
|
case 4 /* CONTEXT */:
|
|
return ctx[key];
|
|
case 3 /* PROPS */:
|
|
return props[key];
|
|
}
|
|
} else if (hasSetupBinding(setupState, key)) {
|
|
accessCache[key] = 1 /* SETUP */;
|
|
return setupState[key];
|
|
} else if (data !== _vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .EMPTY_OBJ */ .MZ && (0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .hasOwn */ .$3)(data, key)) {
|
|
accessCache[key] = 2 /* DATA */;
|
|
return data[key];
|
|
} else if (
|
|
// only cache other properties when instance has declared (thus stable)
|
|
// props
|
|
(normalizedProps = instance.propsOptions[0]) && (0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .hasOwn */ .$3)(normalizedProps, key)) {
|
|
accessCache[key] = 3 /* PROPS */;
|
|
return props[key];
|
|
} else if (ctx !== _vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .EMPTY_OBJ */ .MZ && (0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .hasOwn */ .$3)(ctx, key)) {
|
|
accessCache[key] = 4 /* CONTEXT */;
|
|
return ctx[key];
|
|
} else if ( false || shouldCacheAccess) {
|
|
accessCache[key] = 0 /* OTHER */;
|
|
}
|
|
}
|
|
const publicGetter = publicPropertiesMap[key];
|
|
let cssModule, globalProperties;
|
|
if (publicGetter) {
|
|
if (key === "$attrs") {
|
|
(0,_vue_reactivity__WEBPACK_IMPORTED_MODULE_17__/* .track */ .u4)(instance.attrs, "get", "");
|
|
false && 0;
|
|
} else if (false) {}
|
|
return publicGetter(instance);
|
|
} else if (
|
|
// css module (injected by vue-loader)
|
|
(cssModule = type.__cssModules) && (cssModule = cssModule[key])) {
|
|
return cssModule;
|
|
} else if (ctx !== _vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .EMPTY_OBJ */ .MZ && (0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .hasOwn */ .$3)(ctx, key)) {
|
|
accessCache[key] = 4 /* CONTEXT */;
|
|
return ctx[key];
|
|
} else if (
|
|
// global properties
|
|
globalProperties = appContext.config.globalProperties, (0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .hasOwn */ .$3)(globalProperties, key)) {
|
|
{
|
|
return globalProperties[key];
|
|
}
|
|
} else if (false) {}
|
|
},
|
|
set({
|
|
_: instance
|
|
}, key, value) {
|
|
const {
|
|
data,
|
|
setupState,
|
|
ctx
|
|
} = instance;
|
|
if (hasSetupBinding(setupState, key)) {
|
|
setupState[key] = value;
|
|
return true;
|
|
} else if (false) {} else if (data !== _vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .EMPTY_OBJ */ .MZ && (0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .hasOwn */ .$3)(data, key)) {
|
|
data[key] = value;
|
|
return true;
|
|
} else if ((0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .hasOwn */ .$3)(instance.props, key)) {
|
|
false && 0;
|
|
return false;
|
|
}
|
|
if (key[0] === "$" && key.slice(1) in instance) {
|
|
false && 0;
|
|
return false;
|
|
} else {
|
|
if (false) {} else {
|
|
ctx[key] = value;
|
|
}
|
|
}
|
|
return true;
|
|
},
|
|
has({
|
|
_: {
|
|
data,
|
|
setupState,
|
|
accessCache,
|
|
ctx,
|
|
appContext,
|
|
propsOptions
|
|
}
|
|
}, key) {
|
|
let normalizedProps;
|
|
return !!accessCache[key] || data !== _vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .EMPTY_OBJ */ .MZ && (0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .hasOwn */ .$3)(data, key) || hasSetupBinding(setupState, key) || (normalizedProps = propsOptions[0]) && (0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .hasOwn */ .$3)(normalizedProps, key) || (0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .hasOwn */ .$3)(ctx, key) || (0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .hasOwn */ .$3)(publicPropertiesMap, key) || (0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .hasOwn */ .$3)(appContext.config.globalProperties, key);
|
|
},
|
|
defineProperty(target, key, descriptor) {
|
|
if (descriptor.get != null) {
|
|
target._.accessCache[key] = 0;
|
|
} else if ((0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .hasOwn */ .$3)(descriptor, "value")) {
|
|
this.set(target, key, descriptor.value, null);
|
|
}
|
|
return Reflect.defineProperty(target, key, descriptor);
|
|
}
|
|
};
|
|
if (false) {}
|
|
const RuntimeCompiledPublicInstanceProxyHandlers = /* @__PURE__ */(0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .extend */ .X$)({}, PublicInstanceProxyHandlers, {
|
|
get(target, key) {
|
|
if (key === Symbol.unscopables) {
|
|
return;
|
|
}
|
|
return PublicInstanceProxyHandlers.get(target, key, target);
|
|
},
|
|
has(_, key) {
|
|
const has = key[0] !== "_" && !(0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .isGloballyAllowed */ .BH)(key);
|
|
if (false) {}
|
|
return has;
|
|
}
|
|
});
|
|
function createDevRenderContext(instance) {
|
|
const target = {};
|
|
Object.defineProperty(target, `_`, {
|
|
configurable: true,
|
|
enumerable: false,
|
|
get: () => instance
|
|
});
|
|
Object.keys(publicPropertiesMap).forEach(key => {
|
|
Object.defineProperty(target, key, {
|
|
configurable: true,
|
|
enumerable: false,
|
|
get: () => publicPropertiesMap[key](instance),
|
|
// intercepted by the proxy so no need for implementation,
|
|
// but needed to prevent set errors
|
|
set: NOOP
|
|
});
|
|
});
|
|
return target;
|
|
}
|
|
function exposePropsOnRenderContext(instance) {
|
|
const {
|
|
ctx,
|
|
propsOptions: [propsOptions]
|
|
} = instance;
|
|
if (propsOptions) {
|
|
Object.keys(propsOptions).forEach(key => {
|
|
Object.defineProperty(ctx, key, {
|
|
enumerable: true,
|
|
configurable: true,
|
|
get: () => instance.props[key],
|
|
set: NOOP
|
|
});
|
|
});
|
|
}
|
|
}
|
|
function exposeSetupStateOnRenderContext(instance) {
|
|
const {
|
|
ctx,
|
|
setupState
|
|
} = instance;
|
|
Object.keys(toRaw(setupState)).forEach(key => {
|
|
if (!setupState.__isScriptSetup) {
|
|
if (isReservedPrefix(key[0])) {
|
|
warn$1(`setup() return property ${JSON.stringify(key)} should not start with "$" or "_" which are reserved prefixes for Vue internals.`);
|
|
return;
|
|
}
|
|
Object.defineProperty(ctx, key, {
|
|
enumerable: true,
|
|
configurable: true,
|
|
get: () => setupState[key],
|
|
set: NOOP
|
|
});
|
|
}
|
|
});
|
|
}
|
|
const warnRuntimeUsage = method => warn$1(`${method}() is a compiler-hint helper that is only usable inside <script setup> of a single file component. Its arguments should be compiled away and passing it at runtime has no effect.`);
|
|
function defineProps() {
|
|
if (false) {}
|
|
return null;
|
|
}
|
|
function defineEmits() {
|
|
if (false) {}
|
|
return null;
|
|
}
|
|
function defineExpose(exposed) {
|
|
if (false) {}
|
|
}
|
|
function defineOptions(options) {
|
|
if (false) {}
|
|
}
|
|
function defineSlots() {
|
|
if (false) {}
|
|
return null;
|
|
}
|
|
function defineModel() {
|
|
if (false) {}
|
|
}
|
|
function withDefaults(props, defaults) {
|
|
if (false) {}
|
|
return null;
|
|
}
|
|
function useSlots() {
|
|
return getContext().slots;
|
|
}
|
|
function useAttrs() {
|
|
return getContext().attrs;
|
|
}
|
|
function getContext() {
|
|
const i = getCurrentInstance();
|
|
if (false) {}
|
|
return i.setupContext || (i.setupContext = createSetupContext(i));
|
|
}
|
|
function normalizePropsOrEmits(props) {
|
|
return (0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .isArray */ .cy)(props) ? props.reduce((normalized, p) => (normalized[p] = null, normalized), {}) : props;
|
|
}
|
|
function mergeDefaults(raw, defaults) {
|
|
const props = normalizePropsOrEmits(raw);
|
|
for (const key in defaults) {
|
|
if (key.startsWith("__skip")) continue;
|
|
let opt = props[key];
|
|
if (opt) {
|
|
if (isArray(opt) || isFunction(opt)) {
|
|
opt = props[key] = {
|
|
type: opt,
|
|
default: defaults[key]
|
|
};
|
|
} else {
|
|
opt.default = defaults[key];
|
|
}
|
|
} else if (opt === null) {
|
|
opt = props[key] = {
|
|
default: defaults[key]
|
|
};
|
|
} else if (false) {}
|
|
if (opt && defaults[`__skip_${key}`]) {
|
|
opt.skipFactory = true;
|
|
}
|
|
}
|
|
return props;
|
|
}
|
|
function mergeModels(a, b) {
|
|
if (!a || !b) return a || b;
|
|
if (isArray(a) && isArray(b)) return a.concat(b);
|
|
return extend({}, normalizePropsOrEmits(a), normalizePropsOrEmits(b));
|
|
}
|
|
function createPropsRestProxy(props, excludedKeys) {
|
|
const ret = {};
|
|
for (const key in props) {
|
|
if (!excludedKeys.includes(key)) {
|
|
Object.defineProperty(ret, key, {
|
|
enumerable: true,
|
|
get: () => props[key]
|
|
});
|
|
}
|
|
}
|
|
return ret;
|
|
}
|
|
function withAsyncContext(getAwaitable) {
|
|
const ctx = getCurrentInstance();
|
|
if (false) {}
|
|
let awaitable = getAwaitable();
|
|
unsetCurrentInstance();
|
|
if (isPromise(awaitable)) {
|
|
awaitable = awaitable.catch(e => {
|
|
setCurrentInstance(ctx);
|
|
throw e;
|
|
});
|
|
}
|
|
return [awaitable, () => setCurrentInstance(ctx)];
|
|
}
|
|
function createDuplicateChecker() {
|
|
const cache = /* @__PURE__ */Object.create(null);
|
|
return (type, key) => {
|
|
if (cache[key]) {
|
|
warn$1(`${type} property "${key}" is already defined in ${cache[key]}.`);
|
|
} else {
|
|
cache[key] = type;
|
|
}
|
|
};
|
|
}
|
|
let shouldCacheAccess = true;
|
|
function applyOptions(instance) {
|
|
const options = resolveMergedOptions(instance);
|
|
const publicThis = instance.proxy;
|
|
const ctx = instance.ctx;
|
|
shouldCacheAccess = false;
|
|
if (options.beforeCreate) {
|
|
callHook(options.beforeCreate, instance, "bc");
|
|
}
|
|
const {
|
|
// state
|
|
data: dataOptions,
|
|
computed: computedOptions,
|
|
methods,
|
|
watch: watchOptions,
|
|
provide: provideOptions,
|
|
inject: injectOptions,
|
|
// lifecycle
|
|
created,
|
|
beforeMount,
|
|
mounted,
|
|
beforeUpdate,
|
|
updated,
|
|
activated,
|
|
deactivated,
|
|
beforeDestroy,
|
|
beforeUnmount,
|
|
destroyed,
|
|
unmounted,
|
|
render,
|
|
renderTracked,
|
|
renderTriggered,
|
|
errorCaptured,
|
|
serverPrefetch,
|
|
// public API
|
|
expose,
|
|
inheritAttrs,
|
|
// assets
|
|
components,
|
|
directives,
|
|
filters
|
|
} = options;
|
|
const checkDuplicateProperties = false ? 0 : null;
|
|
if (false) {}
|
|
if (injectOptions) {
|
|
resolveInjections(injectOptions, ctx, checkDuplicateProperties);
|
|
}
|
|
if (methods) {
|
|
for (const key in methods) {
|
|
const methodHandler = methods[key];
|
|
if ((0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .isFunction */ .Tn)(methodHandler)) {
|
|
if (false) {} else {
|
|
ctx[key] = methodHandler.bind(publicThis);
|
|
}
|
|
if (false) {}
|
|
} else if (false) {}
|
|
}
|
|
}
|
|
if (dataOptions) {
|
|
if (false) {}
|
|
const data = dataOptions.call(publicThis, publicThis);
|
|
if (false) {}
|
|
if (!(0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .isObject */ .Gv)(data)) {
|
|
false && 0;
|
|
} else {
|
|
instance.data = (0,_vue_reactivity__WEBPACK_IMPORTED_MODULE_17__/* .reactive */ .Kh)(data);
|
|
if (false) {}
|
|
}
|
|
}
|
|
shouldCacheAccess = true;
|
|
if (computedOptions) {
|
|
for (const key in computedOptions) {
|
|
const opt = computedOptions[key];
|
|
const get = (0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .isFunction */ .Tn)(opt) ? opt.bind(publicThis, publicThis) : (0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .isFunction */ .Tn)(opt.get) ? opt.get.bind(publicThis, publicThis) : _vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .NOOP */ .tE;
|
|
if (false) {}
|
|
const set = !(0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .isFunction */ .Tn)(opt) && (0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .isFunction */ .Tn)(opt.set) ? opt.set.bind(publicThis) : false ? 0 : _vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .NOOP */ .tE;
|
|
const c = computed({
|
|
get,
|
|
set
|
|
});
|
|
Object.defineProperty(ctx, key, {
|
|
enumerable: true,
|
|
configurable: true,
|
|
get: () => c.value,
|
|
set: v => c.value = v
|
|
});
|
|
if (false) {}
|
|
}
|
|
}
|
|
if (watchOptions) {
|
|
for (const key in watchOptions) {
|
|
createWatcher(watchOptions[key], ctx, publicThis, key);
|
|
}
|
|
}
|
|
if (provideOptions) {
|
|
const provides = (0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .isFunction */ .Tn)(provideOptions) ? provideOptions.call(publicThis) : provideOptions;
|
|
Reflect.ownKeys(provides).forEach(key => {
|
|
provide(key, provides[key]);
|
|
});
|
|
}
|
|
if (created) {
|
|
callHook(created, instance, "c");
|
|
}
|
|
function registerLifecycleHook(register, hook) {
|
|
if ((0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .isArray */ .cy)(hook)) {
|
|
hook.forEach(_hook => register(_hook.bind(publicThis)));
|
|
} else if (hook) {
|
|
register(hook.bind(publicThis));
|
|
}
|
|
}
|
|
registerLifecycleHook(onBeforeMount, beforeMount);
|
|
registerLifecycleHook(onMounted, mounted);
|
|
registerLifecycleHook(onBeforeUpdate, beforeUpdate);
|
|
registerLifecycleHook(onUpdated, updated);
|
|
registerLifecycleHook(onActivated, activated);
|
|
registerLifecycleHook(onDeactivated, deactivated);
|
|
registerLifecycleHook(onErrorCaptured, errorCaptured);
|
|
registerLifecycleHook(onRenderTracked, renderTracked);
|
|
registerLifecycleHook(onRenderTriggered, renderTriggered);
|
|
registerLifecycleHook(onBeforeUnmount, beforeUnmount);
|
|
registerLifecycleHook(onUnmounted, unmounted);
|
|
registerLifecycleHook(onServerPrefetch, serverPrefetch);
|
|
if ((0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .isArray */ .cy)(expose)) {
|
|
if (expose.length) {
|
|
const exposed = instance.exposed || (instance.exposed = {});
|
|
expose.forEach(key => {
|
|
Object.defineProperty(exposed, key, {
|
|
get: () => publicThis[key],
|
|
set: val => publicThis[key] = val
|
|
});
|
|
});
|
|
} else if (!instance.exposed) {
|
|
instance.exposed = {};
|
|
}
|
|
}
|
|
if (render && instance.render === _vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .NOOP */ .tE) {
|
|
instance.render = render;
|
|
}
|
|
if (inheritAttrs != null) {
|
|
instance.inheritAttrs = inheritAttrs;
|
|
}
|
|
if (components) instance.components = components;
|
|
if (directives) instance.directives = directives;
|
|
if (serverPrefetch) {
|
|
markAsyncBoundary(instance);
|
|
}
|
|
}
|
|
function resolveInjections(injectOptions, ctx, checkDuplicateProperties = _vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .NOOP */ .tE) {
|
|
if ((0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .isArray */ .cy)(injectOptions)) {
|
|
injectOptions = normalizeInject(injectOptions);
|
|
}
|
|
for (const key in injectOptions) {
|
|
const opt = injectOptions[key];
|
|
let injected;
|
|
if ((0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .isObject */ .Gv)(opt)) {
|
|
if ("default" in opt) {
|
|
injected = inject(opt.from || key, opt.default, true);
|
|
} else {
|
|
injected = inject(opt.from || key);
|
|
}
|
|
} else {
|
|
injected = inject(opt);
|
|
}
|
|
if ((0,_vue_reactivity__WEBPACK_IMPORTED_MODULE_17__/* .isRef */ .i9)(injected)) {
|
|
Object.defineProperty(ctx, key, {
|
|
enumerable: true,
|
|
configurable: true,
|
|
get: () => injected.value,
|
|
set: v => injected.value = v
|
|
});
|
|
} else {
|
|
ctx[key] = injected;
|
|
}
|
|
if (false) {}
|
|
}
|
|
}
|
|
function callHook(hook, instance, type) {
|
|
callWithAsyncErrorHandling((0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .isArray */ .cy)(hook) ? hook.map(h => h.bind(instance.proxy)) : hook.bind(instance.proxy), instance, type);
|
|
}
|
|
function createWatcher(raw, ctx, publicThis, key) {
|
|
let getter = key.includes(".") ? createPathGetter(publicThis, key) : () => publicThis[key];
|
|
if ((0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .isString */ .Kg)(raw)) {
|
|
const handler = ctx[raw];
|
|
if ((0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .isFunction */ .Tn)(handler)) {
|
|
{
|
|
watch(getter, handler);
|
|
}
|
|
} else if (false) {}
|
|
} else if ((0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .isFunction */ .Tn)(raw)) {
|
|
{
|
|
watch(getter, raw.bind(publicThis));
|
|
}
|
|
} else if ((0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .isObject */ .Gv)(raw)) {
|
|
if ((0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .isArray */ .cy)(raw)) {
|
|
raw.forEach(r => createWatcher(r, ctx, publicThis, key));
|
|
} else {
|
|
const handler = (0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .isFunction */ .Tn)(raw.handler) ? raw.handler.bind(publicThis) : ctx[raw.handler];
|
|
if ((0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .isFunction */ .Tn)(handler)) {
|
|
watch(getter, handler, raw);
|
|
} else if (false) {}
|
|
}
|
|
} else if (false) {}
|
|
}
|
|
function resolveMergedOptions(instance) {
|
|
const base = instance.type;
|
|
const {
|
|
mixins,
|
|
extends: extendsOptions
|
|
} = base;
|
|
const {
|
|
mixins: globalMixins,
|
|
optionsCache: cache,
|
|
config: {
|
|
optionMergeStrategies
|
|
}
|
|
} = instance.appContext;
|
|
const cached = cache.get(base);
|
|
let resolved;
|
|
if (cached) {
|
|
resolved = cached;
|
|
} else if (!globalMixins.length && !mixins && !extendsOptions) {
|
|
{
|
|
resolved = base;
|
|
}
|
|
} else {
|
|
resolved = {};
|
|
if (globalMixins.length) {
|
|
globalMixins.forEach(m => mergeOptions(resolved, m, optionMergeStrategies, true));
|
|
}
|
|
mergeOptions(resolved, base, optionMergeStrategies);
|
|
}
|
|
if ((0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .isObject */ .Gv)(base)) {
|
|
cache.set(base, resolved);
|
|
}
|
|
return resolved;
|
|
}
|
|
function mergeOptions(to, from, strats, asMixin = false) {
|
|
const {
|
|
mixins,
|
|
extends: extendsOptions
|
|
} = from;
|
|
if (extendsOptions) {
|
|
mergeOptions(to, extendsOptions, strats, true);
|
|
}
|
|
if (mixins) {
|
|
mixins.forEach(m => mergeOptions(to, m, strats, true));
|
|
}
|
|
for (const key in from) {
|
|
if (asMixin && key === "expose") {
|
|
false && 0;
|
|
} else {
|
|
const strat = internalOptionMergeStrats[key] || strats && strats[key];
|
|
to[key] = strat ? strat(to[key], from[key]) : from[key];
|
|
}
|
|
}
|
|
return to;
|
|
}
|
|
const internalOptionMergeStrats = {
|
|
data: mergeDataFn,
|
|
props: mergeEmitsOrPropsOptions,
|
|
emits: mergeEmitsOrPropsOptions,
|
|
// objects
|
|
methods: mergeObjectOptions,
|
|
computed: mergeObjectOptions,
|
|
// lifecycle
|
|
beforeCreate: mergeAsArray,
|
|
created: mergeAsArray,
|
|
beforeMount: mergeAsArray,
|
|
mounted: mergeAsArray,
|
|
beforeUpdate: mergeAsArray,
|
|
updated: mergeAsArray,
|
|
beforeDestroy: mergeAsArray,
|
|
beforeUnmount: mergeAsArray,
|
|
destroyed: mergeAsArray,
|
|
unmounted: mergeAsArray,
|
|
activated: mergeAsArray,
|
|
deactivated: mergeAsArray,
|
|
errorCaptured: mergeAsArray,
|
|
serverPrefetch: mergeAsArray,
|
|
// assets
|
|
components: mergeObjectOptions,
|
|
directives: mergeObjectOptions,
|
|
// watch
|
|
watch: mergeWatchOptions,
|
|
// provide / inject
|
|
provide: mergeDataFn,
|
|
inject: mergeInject
|
|
};
|
|
function mergeDataFn(to, from) {
|
|
if (!from) {
|
|
return to;
|
|
}
|
|
if (!to) {
|
|
return from;
|
|
}
|
|
return function mergedDataFn() {
|
|
return (0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .extend */ .X$)((0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .isFunction */ .Tn)(to) ? to.call(this, this) : to, (0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .isFunction */ .Tn)(from) ? from.call(this, this) : from);
|
|
};
|
|
}
|
|
function mergeInject(to, from) {
|
|
return mergeObjectOptions(normalizeInject(to), normalizeInject(from));
|
|
}
|
|
function normalizeInject(raw) {
|
|
if ((0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .isArray */ .cy)(raw)) {
|
|
const res = {};
|
|
for (let i = 0; i < raw.length; i++) {
|
|
res[raw[i]] = raw[i];
|
|
}
|
|
return res;
|
|
}
|
|
return raw;
|
|
}
|
|
function mergeAsArray(to, from) {
|
|
return to ? [...new Set([].concat(to, from))] : from;
|
|
}
|
|
function mergeObjectOptions(to, from) {
|
|
return to ? (0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .extend */ .X$)(/* @__PURE__ */Object.create(null), to, from) : from;
|
|
}
|
|
function mergeEmitsOrPropsOptions(to, from) {
|
|
if (to) {
|
|
if ((0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .isArray */ .cy)(to) && (0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .isArray */ .cy)(from)) {
|
|
return [... /* @__PURE__ */new Set([...to, ...from])];
|
|
}
|
|
return (0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .extend */ .X$)(/* @__PURE__ */Object.create(null), normalizePropsOrEmits(to), normalizePropsOrEmits(from != null ? from : {}));
|
|
} else {
|
|
return from;
|
|
}
|
|
}
|
|
function mergeWatchOptions(to, from) {
|
|
if (!to) return from;
|
|
if (!from) return to;
|
|
const merged = (0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .extend */ .X$)(/* @__PURE__ */Object.create(null), to);
|
|
for (const key in from) {
|
|
merged[key] = mergeAsArray(to[key], from[key]);
|
|
}
|
|
return merged;
|
|
}
|
|
function createAppContext() {
|
|
return {
|
|
app: null,
|
|
config: {
|
|
isNativeTag: _vue_shared__WEBPACK_IMPORTED_MODULE_16__.NO,
|
|
performance: false,
|
|
globalProperties: {},
|
|
optionMergeStrategies: {},
|
|
errorHandler: void 0,
|
|
warnHandler: void 0,
|
|
compilerOptions: {}
|
|
},
|
|
mixins: [],
|
|
components: {},
|
|
directives: {},
|
|
provides: /* @__PURE__ */Object.create(null),
|
|
optionsCache: /* @__PURE__ */new WeakMap(),
|
|
propsCache: /* @__PURE__ */new WeakMap(),
|
|
emitsCache: /* @__PURE__ */new WeakMap()
|
|
};
|
|
}
|
|
let uid$1 = 0;
|
|
function createAppAPI(render, hydrate) {
|
|
return function createApp(rootComponent, rootProps = null) {
|
|
if (!(0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .isFunction */ .Tn)(rootComponent)) {
|
|
rootComponent = (0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .extend */ .X$)({}, rootComponent);
|
|
}
|
|
if (rootProps != null && !(0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .isObject */ .Gv)(rootProps)) {
|
|
false && 0;
|
|
rootProps = null;
|
|
}
|
|
const context = createAppContext();
|
|
const installedPlugins = /* @__PURE__ */new WeakSet();
|
|
const pluginCleanupFns = [];
|
|
let isMounted = false;
|
|
const app = context.app = {
|
|
_uid: uid$1++,
|
|
_component: rootComponent,
|
|
_props: rootProps,
|
|
_container: null,
|
|
_context: context,
|
|
_instance: null,
|
|
version,
|
|
get config() {
|
|
return context.config;
|
|
},
|
|
set config(v) {
|
|
if (false) {}
|
|
},
|
|
use(plugin, ...options) {
|
|
if (installedPlugins.has(plugin)) {
|
|
false && 0;
|
|
} else if (plugin && (0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .isFunction */ .Tn)(plugin.install)) {
|
|
installedPlugins.add(plugin);
|
|
plugin.install(app, ...options);
|
|
} else if ((0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .isFunction */ .Tn)(plugin)) {
|
|
installedPlugins.add(plugin);
|
|
plugin(app, ...options);
|
|
} else if (false) {}
|
|
return app;
|
|
},
|
|
mixin(mixin) {
|
|
if (true) {
|
|
if (!context.mixins.includes(mixin)) {
|
|
context.mixins.push(mixin);
|
|
} else if (false) {}
|
|
} else {}
|
|
return app;
|
|
},
|
|
component(name, component) {
|
|
if (false) {}
|
|
if (!component) {
|
|
return context.components[name];
|
|
}
|
|
if (false) {}
|
|
context.components[name] = component;
|
|
return app;
|
|
},
|
|
directive(name, directive) {
|
|
if (false) {}
|
|
if (!directive) {
|
|
return context.directives[name];
|
|
}
|
|
if (false) {}
|
|
context.directives[name] = directive;
|
|
return app;
|
|
},
|
|
mount(rootContainer, isHydrate, namespace) {
|
|
if (!isMounted) {
|
|
if (false) {}
|
|
const vnode = app._ceVNode || createVNode(rootComponent, rootProps);
|
|
vnode.appContext = context;
|
|
if (namespace === true) {
|
|
namespace = "svg";
|
|
} else if (namespace === false) {
|
|
namespace = void 0;
|
|
}
|
|
if (false) {}
|
|
if (isHydrate && hydrate) {
|
|
hydrate(vnode, rootContainer);
|
|
} else {
|
|
render(vnode, rootContainer, namespace);
|
|
}
|
|
isMounted = true;
|
|
app._container = rootContainer;
|
|
rootContainer.__vue_app__ = app;
|
|
if (false) {}
|
|
return getComponentPublicInstance(vnode.component);
|
|
} else if (false) {}
|
|
},
|
|
onUnmount(cleanupFn) {
|
|
if (false) {}
|
|
pluginCleanupFns.push(cleanupFn);
|
|
},
|
|
unmount() {
|
|
if (isMounted) {
|
|
callWithAsyncErrorHandling(pluginCleanupFns, app._instance, 16);
|
|
render(null, app._container);
|
|
if (false) {}
|
|
delete app._container.__vue_app__;
|
|
} else if (false) {}
|
|
},
|
|
provide(key, value) {
|
|
if (false) {}
|
|
context.provides[key] = value;
|
|
return app;
|
|
},
|
|
runWithContext(fn) {
|
|
const lastApp = currentApp;
|
|
currentApp = app;
|
|
try {
|
|
return fn();
|
|
} finally {
|
|
currentApp = lastApp;
|
|
}
|
|
}
|
|
};
|
|
return app;
|
|
};
|
|
}
|
|
let currentApp = null;
|
|
function provide(key, value) {
|
|
if (!currentInstance) {
|
|
if (false) {}
|
|
} else {
|
|
let provides = currentInstance.provides;
|
|
const parentProvides = currentInstance.parent && currentInstance.parent.provides;
|
|
if (parentProvides === provides) {
|
|
provides = currentInstance.provides = Object.create(parentProvides);
|
|
}
|
|
provides[key] = value;
|
|
}
|
|
}
|
|
function inject(key, defaultValue, treatDefaultAsFactory = false) {
|
|
const instance = currentInstance || currentRenderingInstance;
|
|
if (instance || currentApp) {
|
|
const provides = currentApp ? currentApp._context.provides : instance ? instance.parent == null ? instance.vnode.appContext && instance.vnode.appContext.provides : instance.parent.provides : void 0;
|
|
if (provides && key in provides) {
|
|
return provides[key];
|
|
} else if (arguments.length > 1) {
|
|
return treatDefaultAsFactory && (0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .isFunction */ .Tn)(defaultValue) ? defaultValue.call(instance && instance.proxy) : defaultValue;
|
|
} else if (false) {}
|
|
} else if (false) {}
|
|
}
|
|
function hasInjectionContext() {
|
|
return !!(currentInstance || currentRenderingInstance || currentApp);
|
|
}
|
|
const internalObjectProto = {};
|
|
const createInternalObject = () => Object.create(internalObjectProto);
|
|
const isInternalObject = obj => Object.getPrototypeOf(obj) === internalObjectProto;
|
|
function initProps(instance, rawProps, isStateful, isSSR = false) {
|
|
const props = {};
|
|
const attrs = createInternalObject();
|
|
instance.propsDefaults = /* @__PURE__ */Object.create(null);
|
|
setFullProps(instance, rawProps, props, attrs);
|
|
for (const key in instance.propsOptions[0]) {
|
|
if (!(key in props)) {
|
|
props[key] = void 0;
|
|
}
|
|
}
|
|
if (false) {}
|
|
if (isStateful) {
|
|
instance.props = isSSR ? props : (0,_vue_reactivity__WEBPACK_IMPORTED_MODULE_17__/* .shallowReactive */ .Gc)(props);
|
|
} else {
|
|
if (!instance.type.props) {
|
|
instance.props = attrs;
|
|
} else {
|
|
instance.props = props;
|
|
}
|
|
}
|
|
instance.attrs = attrs;
|
|
}
|
|
function isInHmrContext(instance) {
|
|
while (instance) {
|
|
if (instance.type.__hmrId) return true;
|
|
instance = instance.parent;
|
|
}
|
|
}
|
|
function updateProps(instance, rawProps, rawPrevProps, optimized) {
|
|
const {
|
|
props,
|
|
attrs,
|
|
vnode: {
|
|
patchFlag
|
|
}
|
|
} = instance;
|
|
const rawCurrentProps = (0,_vue_reactivity__WEBPACK_IMPORTED_MODULE_17__/* .toRaw */ .ux)(props);
|
|
const [options] = instance.propsOptions;
|
|
let hasAttrsChanged = false;
|
|
if (
|
|
// always force full diff in dev
|
|
// - #1942 if hmr is enabled with sfc component
|
|
// - vite#872 non-sfc component used by sfc component
|
|
true && (optimized || patchFlag > 0) && !(patchFlag & 16)) {
|
|
if (patchFlag & 8) {
|
|
const propsToUpdate = instance.vnode.dynamicProps;
|
|
for (let i = 0; i < propsToUpdate.length; i++) {
|
|
let key = propsToUpdate[i];
|
|
if (isEmitListener(instance.emitsOptions, key)) {
|
|
continue;
|
|
}
|
|
const value = rawProps[key];
|
|
if (options) {
|
|
if ((0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .hasOwn */ .$3)(attrs, key)) {
|
|
if (value !== attrs[key]) {
|
|
attrs[key] = value;
|
|
hasAttrsChanged = true;
|
|
}
|
|
} else {
|
|
const camelizedKey = (0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .camelize */ .PT)(key);
|
|
props[camelizedKey] = resolvePropValue(options, rawCurrentProps, camelizedKey, value, instance, false);
|
|
}
|
|
} else {
|
|
if (value !== attrs[key]) {
|
|
attrs[key] = value;
|
|
hasAttrsChanged = true;
|
|
}
|
|
}
|
|
}
|
|
}
|
|
} else {
|
|
if (setFullProps(instance, rawProps, props, attrs)) {
|
|
hasAttrsChanged = true;
|
|
}
|
|
let kebabKey;
|
|
for (const key in rawCurrentProps) {
|
|
if (!rawProps ||
|
|
// for camelCase
|
|
!(0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .hasOwn */ .$3)(rawProps, key) && (
|
|
// it's possible the original props was passed in as kebab-case
|
|
// and converted to camelCase (#955)
|
|
(kebabKey = (0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .hyphenate */ .Tg)(key)) === key || !(0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .hasOwn */ .$3)(rawProps, kebabKey))) {
|
|
if (options) {
|
|
if (rawPrevProps && (
|
|
// for camelCase
|
|
rawPrevProps[key] !== void 0 ||
|
|
// for kebab-case
|
|
rawPrevProps[kebabKey] !== void 0)) {
|
|
props[key] = resolvePropValue(options, rawCurrentProps, key, void 0, instance, true);
|
|
}
|
|
} else {
|
|
delete props[key];
|
|
}
|
|
}
|
|
}
|
|
if (attrs !== rawCurrentProps) {
|
|
for (const key in attrs) {
|
|
if (!rawProps || !(0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .hasOwn */ .$3)(rawProps, key) && true) {
|
|
delete attrs[key];
|
|
hasAttrsChanged = true;
|
|
}
|
|
}
|
|
}
|
|
}
|
|
if (hasAttrsChanged) {
|
|
(0,_vue_reactivity__WEBPACK_IMPORTED_MODULE_17__/* .trigger */ .hZ)(instance.attrs, "set", "");
|
|
}
|
|
if (false) {}
|
|
}
|
|
function setFullProps(instance, rawProps, props, attrs) {
|
|
const [options, needCastKeys] = instance.propsOptions;
|
|
let hasAttrsChanged = false;
|
|
let rawCastValues;
|
|
if (rawProps) {
|
|
for (let key in rawProps) {
|
|
if ((0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .isReservedProp */ .SU)(key)) {
|
|
continue;
|
|
}
|
|
const value = rawProps[key];
|
|
let camelKey;
|
|
if (options && (0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .hasOwn */ .$3)(options, camelKey = (0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .camelize */ .PT)(key))) {
|
|
if (!needCastKeys || !needCastKeys.includes(camelKey)) {
|
|
props[camelKey] = value;
|
|
} else {
|
|
(rawCastValues || (rawCastValues = {}))[camelKey] = value;
|
|
}
|
|
} else if (!isEmitListener(instance.emitsOptions, key)) {
|
|
if (!(key in attrs) || value !== attrs[key]) {
|
|
attrs[key] = value;
|
|
hasAttrsChanged = true;
|
|
}
|
|
}
|
|
}
|
|
}
|
|
if (needCastKeys) {
|
|
const rawCurrentProps = (0,_vue_reactivity__WEBPACK_IMPORTED_MODULE_17__/* .toRaw */ .ux)(props);
|
|
const castValues = rawCastValues || _vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .EMPTY_OBJ */ .MZ;
|
|
for (let i = 0; i < needCastKeys.length; i++) {
|
|
const key = needCastKeys[i];
|
|
props[key] = resolvePropValue(options, rawCurrentProps, key, castValues[key], instance, !(0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .hasOwn */ .$3)(castValues, key));
|
|
}
|
|
}
|
|
return hasAttrsChanged;
|
|
}
|
|
function resolvePropValue(options, props, key, value, instance, isAbsent) {
|
|
const opt = options[key];
|
|
if (opt != null) {
|
|
const hasDefault = (0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .hasOwn */ .$3)(opt, "default");
|
|
if (hasDefault && value === void 0) {
|
|
const defaultValue = opt.default;
|
|
if (opt.type !== Function && !opt.skipFactory && (0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .isFunction */ .Tn)(defaultValue)) {
|
|
const {
|
|
propsDefaults
|
|
} = instance;
|
|
if (key in propsDefaults) {
|
|
value = propsDefaults[key];
|
|
} else {
|
|
const reset = setCurrentInstance(instance);
|
|
value = propsDefaults[key] = defaultValue.call(null, props);
|
|
reset();
|
|
}
|
|
} else {
|
|
value = defaultValue;
|
|
}
|
|
if (instance.ce) {
|
|
instance.ce._setProp(key, value);
|
|
}
|
|
}
|
|
if (opt[0 /* shouldCast */]) {
|
|
if (isAbsent && !hasDefault) {
|
|
value = false;
|
|
} else if (opt[1 /* shouldCastTrue */] && (value === "" || value === (0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .hyphenate */ .Tg)(key))) {
|
|
value = true;
|
|
}
|
|
}
|
|
}
|
|
return value;
|
|
}
|
|
const mixinPropsCache = /* @__PURE__ */new WeakMap();
|
|
function normalizePropsOptions(comp, appContext, asMixin = false) {
|
|
const cache = true && asMixin ? mixinPropsCache : appContext.propsCache;
|
|
const cached = cache.get(comp);
|
|
if (cached) {
|
|
return cached;
|
|
}
|
|
const raw = comp.props;
|
|
const normalized = {};
|
|
const needCastKeys = [];
|
|
let hasExtends = false;
|
|
if ( true && !(0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .isFunction */ .Tn)(comp)) {
|
|
const extendProps = raw2 => {
|
|
hasExtends = true;
|
|
const [props, keys] = normalizePropsOptions(raw2, appContext, true);
|
|
(0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .extend */ .X$)(normalized, props);
|
|
if (keys) needCastKeys.push(...keys);
|
|
};
|
|
if (!asMixin && appContext.mixins.length) {
|
|
appContext.mixins.forEach(extendProps);
|
|
}
|
|
if (comp.extends) {
|
|
extendProps(comp.extends);
|
|
}
|
|
if (comp.mixins) {
|
|
comp.mixins.forEach(extendProps);
|
|
}
|
|
}
|
|
if (!raw && !hasExtends) {
|
|
if ((0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .isObject */ .Gv)(comp)) {
|
|
cache.set(comp, _vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .EMPTY_ARR */ .Oj);
|
|
}
|
|
return _vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .EMPTY_ARR */ .Oj;
|
|
}
|
|
if ((0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .isArray */ .cy)(raw)) {
|
|
for (let i = 0; i < raw.length; i++) {
|
|
if (false) {}
|
|
const normalizedKey = (0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .camelize */ .PT)(raw[i]);
|
|
if (validatePropName(normalizedKey)) {
|
|
normalized[normalizedKey] = _vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .EMPTY_OBJ */ .MZ;
|
|
}
|
|
}
|
|
} else if (raw) {
|
|
if (false) {}
|
|
for (const key in raw) {
|
|
const normalizedKey = (0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .camelize */ .PT)(key);
|
|
if (validatePropName(normalizedKey)) {
|
|
const opt = raw[key];
|
|
const prop = normalized[normalizedKey] = (0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .isArray */ .cy)(opt) || (0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .isFunction */ .Tn)(opt) ? {
|
|
type: opt
|
|
} : (0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .extend */ .X$)({}, opt);
|
|
const propType = prop.type;
|
|
let shouldCast = false;
|
|
let shouldCastTrue = true;
|
|
if ((0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .isArray */ .cy)(propType)) {
|
|
for (let index = 0; index < propType.length; ++index) {
|
|
const type = propType[index];
|
|
const typeName = (0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .isFunction */ .Tn)(type) && type.name;
|
|
if (typeName === "Boolean") {
|
|
shouldCast = true;
|
|
break;
|
|
} else if (typeName === "String") {
|
|
shouldCastTrue = false;
|
|
}
|
|
}
|
|
} else {
|
|
shouldCast = (0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .isFunction */ .Tn)(propType) && propType.name === "Boolean";
|
|
}
|
|
prop[0 /* shouldCast */] = shouldCast;
|
|
prop[1 /* shouldCastTrue */] = shouldCastTrue;
|
|
if (shouldCast || (0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .hasOwn */ .$3)(prop, "default")) {
|
|
needCastKeys.push(normalizedKey);
|
|
}
|
|
}
|
|
}
|
|
}
|
|
const res = [normalized, needCastKeys];
|
|
if ((0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .isObject */ .Gv)(comp)) {
|
|
cache.set(comp, res);
|
|
}
|
|
return res;
|
|
}
|
|
function validatePropName(key) {
|
|
if (key[0] !== "$" && !(0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .isReservedProp */ .SU)(key)) {
|
|
return true;
|
|
} else if (false) {}
|
|
return false;
|
|
}
|
|
function getType(ctor) {
|
|
if (ctor === null) {
|
|
return "null";
|
|
}
|
|
if (typeof ctor === "function") {
|
|
return ctor.name || "";
|
|
} else if (typeof ctor === "object") {
|
|
const name = ctor.constructor && ctor.constructor.name;
|
|
return name || "";
|
|
}
|
|
return "";
|
|
}
|
|
function validateProps(rawProps, props, instance) {
|
|
const resolvedValues = toRaw(props);
|
|
const options = instance.propsOptions[0];
|
|
const camelizePropsKey = Object.keys(rawProps).map(key => camelize(key));
|
|
for (const key in options) {
|
|
let opt = options[key];
|
|
if (opt == null) continue;
|
|
validateProp(key, resolvedValues[key], opt, false ? 0 : resolvedValues, !camelizePropsKey.includes(key));
|
|
}
|
|
}
|
|
function validateProp(name, value, prop, props, isAbsent) {
|
|
const {
|
|
type,
|
|
required,
|
|
validator,
|
|
skipCheck
|
|
} = prop;
|
|
if (required && isAbsent) {
|
|
warn$1('Missing required prop: "' + name + '"');
|
|
return;
|
|
}
|
|
if (value == null && !required) {
|
|
return;
|
|
}
|
|
if (type != null && type !== true && !skipCheck) {
|
|
let isValid = false;
|
|
const types = isArray(type) ? type : [type];
|
|
const expectedTypes = [];
|
|
for (let i = 0; i < types.length && !isValid; i++) {
|
|
const {
|
|
valid,
|
|
expectedType
|
|
} = assertType(value, types[i]);
|
|
expectedTypes.push(expectedType || "");
|
|
isValid = valid;
|
|
}
|
|
if (!isValid) {
|
|
warn$1(getInvalidTypeMessage(name, value, expectedTypes));
|
|
return;
|
|
}
|
|
}
|
|
if (validator && !validator(value, props)) {
|
|
warn$1('Invalid prop: custom validator check failed for prop "' + name + '".');
|
|
}
|
|
}
|
|
const isSimpleType = /* @__PURE__ */(/* unused pure expression or super */ null && (makeMap("String,Number,Boolean,Function,Symbol,BigInt")));
|
|
function assertType(value, type) {
|
|
let valid;
|
|
const expectedType = getType(type);
|
|
if (expectedType === "null") {
|
|
valid = value === null;
|
|
} else if (isSimpleType(expectedType)) {
|
|
const t = typeof value;
|
|
valid = t === expectedType.toLowerCase();
|
|
if (!valid && t === "object") {
|
|
valid = value instanceof type;
|
|
}
|
|
} else if (expectedType === "Object") {
|
|
valid = isObject(value);
|
|
} else if (expectedType === "Array") {
|
|
valid = isArray(value);
|
|
} else {
|
|
valid = value instanceof type;
|
|
}
|
|
return {
|
|
valid,
|
|
expectedType
|
|
};
|
|
}
|
|
function getInvalidTypeMessage(name, value, expectedTypes) {
|
|
if (expectedTypes.length === 0) {
|
|
return `Prop type [] for prop "${name}" won't match anything. Did you mean to use type Array instead?`;
|
|
}
|
|
let message = `Invalid prop: type check failed for prop "${name}". Expected ${expectedTypes.map(capitalize).join(" | ")}`;
|
|
const expectedType = expectedTypes[0];
|
|
const receivedType = toRawType(value);
|
|
const expectedValue = styleValue(value, expectedType);
|
|
const receivedValue = styleValue(value, receivedType);
|
|
if (expectedTypes.length === 1 && isExplicable(expectedType) && !isBoolean(expectedType, receivedType)) {
|
|
message += ` with value ${expectedValue}`;
|
|
}
|
|
message += `, got ${receivedType} `;
|
|
if (isExplicable(receivedType)) {
|
|
message += `with value ${receivedValue}.`;
|
|
}
|
|
return message;
|
|
}
|
|
function styleValue(value, type) {
|
|
if (type === "String") {
|
|
return `"${value}"`;
|
|
} else if (type === "Number") {
|
|
return `${Number(value)}`;
|
|
} else {
|
|
return `${value}`;
|
|
}
|
|
}
|
|
function isExplicable(type) {
|
|
const explicitTypes = ["string", "number", "boolean"];
|
|
return explicitTypes.some(elem => type.toLowerCase() === elem);
|
|
}
|
|
function isBoolean(...args) {
|
|
return args.some(elem => elem.toLowerCase() === "boolean");
|
|
}
|
|
const isInternalKey = key => key[0] === "_" || key === "$stable";
|
|
const normalizeSlotValue = value => (0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .isArray */ .cy)(value) ? value.map(normalizeVNode) : [normalizeVNode(value)];
|
|
const normalizeSlot = (key, rawSlot, ctx) => {
|
|
if (rawSlot._n) {
|
|
return rawSlot;
|
|
}
|
|
const normalized = withCtx((...args) => {
|
|
if (false) {}
|
|
return normalizeSlotValue(rawSlot(...args));
|
|
}, ctx);
|
|
normalized._c = false;
|
|
return normalized;
|
|
};
|
|
const normalizeObjectSlots = (rawSlots, slots, instance) => {
|
|
const ctx = rawSlots._ctx;
|
|
for (const key in rawSlots) {
|
|
if (isInternalKey(key)) continue;
|
|
const value = rawSlots[key];
|
|
if ((0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .isFunction */ .Tn)(value)) {
|
|
slots[key] = normalizeSlot(key, value, ctx);
|
|
} else if (value != null) {
|
|
if (false) {}
|
|
const normalized = normalizeSlotValue(value);
|
|
slots[key] = () => normalized;
|
|
}
|
|
}
|
|
};
|
|
const normalizeVNodeSlots = (instance, children) => {
|
|
if (false) {}
|
|
const normalized = normalizeSlotValue(children);
|
|
instance.slots.default = () => normalized;
|
|
};
|
|
const assignSlots = (slots, children, optimized) => {
|
|
for (const key in children) {
|
|
if (optimized || key !== "_") {
|
|
slots[key] = children[key];
|
|
}
|
|
}
|
|
};
|
|
const initSlots = (instance, children, optimized) => {
|
|
const slots = instance.slots = createInternalObject();
|
|
if (instance.vnode.shapeFlag & 32) {
|
|
const type = children._;
|
|
if (type) {
|
|
assignSlots(slots, children, optimized);
|
|
if (optimized) {
|
|
(0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .def */ .yQ)(slots, "_", type, true);
|
|
}
|
|
} else {
|
|
normalizeObjectSlots(children, slots);
|
|
}
|
|
} else if (children) {
|
|
normalizeVNodeSlots(instance, children);
|
|
}
|
|
};
|
|
const updateSlots = (instance, children, optimized) => {
|
|
const {
|
|
vnode,
|
|
slots
|
|
} = instance;
|
|
let needDeletionCheck = true;
|
|
let deletionComparisonTarget = _vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .EMPTY_OBJ */ .MZ;
|
|
if (vnode.shapeFlag & 32) {
|
|
const type = children._;
|
|
if (type) {
|
|
if (false) {} else if (optimized && type === 1) {
|
|
needDeletionCheck = false;
|
|
} else {
|
|
assignSlots(slots, children, optimized);
|
|
}
|
|
} else {
|
|
needDeletionCheck = !children.$stable;
|
|
normalizeObjectSlots(children, slots);
|
|
}
|
|
deletionComparisonTarget = children;
|
|
} else if (children) {
|
|
normalizeVNodeSlots(instance, children);
|
|
deletionComparisonTarget = {
|
|
default: 1
|
|
};
|
|
}
|
|
if (needDeletionCheck) {
|
|
for (const key in slots) {
|
|
if (!isInternalKey(key) && deletionComparisonTarget[key] == null) {
|
|
delete slots[key];
|
|
}
|
|
}
|
|
}
|
|
};
|
|
let supported;
|
|
let perf;
|
|
function startMeasure(instance, type) {
|
|
if (instance.appContext.config.performance && isSupported()) {
|
|
perf.mark(`vue-${type}-${instance.uid}`);
|
|
}
|
|
if (false) {}
|
|
}
|
|
function endMeasure(instance, type) {
|
|
if (instance.appContext.config.performance && isSupported()) {
|
|
const startTag = `vue-${type}-${instance.uid}`;
|
|
const endTag = startTag + `:end`;
|
|
perf.mark(endTag);
|
|
perf.measure(`<${formatComponentName(instance, instance.type)}> ${type}`, startTag, endTag);
|
|
perf.clearMarks(startTag);
|
|
perf.clearMarks(endTag);
|
|
}
|
|
if (false) {}
|
|
}
|
|
function isSupported() {
|
|
if (supported !== void 0) {
|
|
return supported;
|
|
}
|
|
if (typeof window !== "undefined" && window.performance) {
|
|
supported = true;
|
|
perf = window.performance;
|
|
} else {
|
|
supported = false;
|
|
}
|
|
return supported;
|
|
}
|
|
function initFeatureFlags() {
|
|
const needWarn = [];
|
|
if (false) {}
|
|
if (false) {}
|
|
if (typeof __VUE_PROD_HYDRATION_MISMATCH_DETAILS__ !== "boolean") {
|
|
false && 0;
|
|
(0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .getGlobalThis */ .We)().__VUE_PROD_HYDRATION_MISMATCH_DETAILS__ = false;
|
|
}
|
|
if (false) {}
|
|
}
|
|
const queuePostRenderEffect = queueEffectWithSuspense;
|
|
function createRenderer(options) {
|
|
return baseCreateRenderer(options);
|
|
}
|
|
function createHydrationRenderer(options) {
|
|
return baseCreateRenderer(options, createHydrationFunctions);
|
|
}
|
|
function baseCreateRenderer(options, createHydrationFns) {
|
|
{
|
|
initFeatureFlags();
|
|
}
|
|
const target = (0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .getGlobalThis */ .We)();
|
|
target.__VUE__ = true;
|
|
if (false) {}
|
|
const {
|
|
insert: hostInsert,
|
|
remove: hostRemove,
|
|
patchProp: hostPatchProp,
|
|
createElement: hostCreateElement,
|
|
createText: hostCreateText,
|
|
createComment: hostCreateComment,
|
|
setText: hostSetText,
|
|
setElementText: hostSetElementText,
|
|
parentNode: hostParentNode,
|
|
nextSibling: hostNextSibling,
|
|
setScopeId: hostSetScopeId = _vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .NOOP */ .tE,
|
|
insertStaticContent: hostInsertStaticContent
|
|
} = options;
|
|
const patch = (n1, n2, container, anchor = null, parentComponent = null, parentSuspense = null, namespace = void 0, slotScopeIds = null, optimized = false ? 0 : !!n2.dynamicChildren) => {
|
|
if (n1 === n2) {
|
|
return;
|
|
}
|
|
if (n1 && !isSameVNodeType(n1, n2)) {
|
|
anchor = getNextHostNode(n1);
|
|
unmount(n1, parentComponent, parentSuspense, true);
|
|
n1 = null;
|
|
}
|
|
if (n2.patchFlag === -2) {
|
|
optimized = false;
|
|
n2.dynamicChildren = null;
|
|
}
|
|
const {
|
|
type,
|
|
ref,
|
|
shapeFlag
|
|
} = n2;
|
|
switch (type) {
|
|
case Text:
|
|
processText(n1, n2, container, anchor);
|
|
break;
|
|
case Comment:
|
|
processCommentNode(n1, n2, container, anchor);
|
|
break;
|
|
case Static:
|
|
if (n1 == null) {
|
|
mountStaticNode(n2, container, anchor, namespace);
|
|
} else if (false) {}
|
|
break;
|
|
case Fragment:
|
|
processFragment(n1, n2, container, anchor, parentComponent, parentSuspense, namespace, slotScopeIds, optimized);
|
|
break;
|
|
default:
|
|
if (shapeFlag & 1) {
|
|
processElement(n1, n2, container, anchor, parentComponent, parentSuspense, namespace, slotScopeIds, optimized);
|
|
} else if (shapeFlag & 6) {
|
|
processComponent(n1, n2, container, anchor, parentComponent, parentSuspense, namespace, slotScopeIds, optimized);
|
|
} else if (shapeFlag & 64) {
|
|
type.process(n1, n2, container, anchor, parentComponent, parentSuspense, namespace, slotScopeIds, optimized, internals);
|
|
} else if (shapeFlag & 128) {
|
|
type.process(n1, n2, container, anchor, parentComponent, parentSuspense, namespace, slotScopeIds, optimized, internals);
|
|
} else if (false) {}
|
|
}
|
|
if (ref != null && parentComponent) {
|
|
setRef(ref, n1 && n1.ref, parentSuspense, n2 || n1, !n2);
|
|
}
|
|
};
|
|
const processText = (n1, n2, container, anchor) => {
|
|
if (n1 == null) {
|
|
hostInsert(n2.el = hostCreateText(n2.children), container, anchor);
|
|
} else {
|
|
const el = n2.el = n1.el;
|
|
if (n2.children !== n1.children) {
|
|
hostSetText(el, n2.children);
|
|
}
|
|
}
|
|
};
|
|
const processCommentNode = (n1, n2, container, anchor) => {
|
|
if (n1 == null) {
|
|
hostInsert(n2.el = hostCreateComment(n2.children || ""), container, anchor);
|
|
} else {
|
|
n2.el = n1.el;
|
|
}
|
|
};
|
|
const mountStaticNode = (n2, container, anchor, namespace) => {
|
|
[n2.el, n2.anchor] = hostInsertStaticContent(n2.children, container, anchor, namespace, n2.el, n2.anchor);
|
|
};
|
|
const patchStaticNode = (n1, n2, container, namespace) => {
|
|
if (n2.children !== n1.children) {
|
|
const anchor = hostNextSibling(n1.anchor);
|
|
removeStaticNode(n1);
|
|
[n2.el, n2.anchor] = hostInsertStaticContent(n2.children, container, anchor, namespace);
|
|
} else {
|
|
n2.el = n1.el;
|
|
n2.anchor = n1.anchor;
|
|
}
|
|
};
|
|
const moveStaticNode = ({
|
|
el,
|
|
anchor
|
|
}, container, nextSibling) => {
|
|
let next;
|
|
while (el && el !== anchor) {
|
|
next = hostNextSibling(el);
|
|
hostInsert(el, container, nextSibling);
|
|
el = next;
|
|
}
|
|
hostInsert(anchor, container, nextSibling);
|
|
};
|
|
const removeStaticNode = ({
|
|
el,
|
|
anchor
|
|
}) => {
|
|
let next;
|
|
while (el && el !== anchor) {
|
|
next = hostNextSibling(el);
|
|
hostRemove(el);
|
|
el = next;
|
|
}
|
|
hostRemove(anchor);
|
|
};
|
|
const processElement = (n1, n2, container, anchor, parentComponent, parentSuspense, namespace, slotScopeIds, optimized) => {
|
|
if (n2.type === "svg") {
|
|
namespace = "svg";
|
|
} else if (n2.type === "math") {
|
|
namespace = "mathml";
|
|
}
|
|
if (n1 == null) {
|
|
mountElement(n2, container, anchor, parentComponent, parentSuspense, namespace, slotScopeIds, optimized);
|
|
} else {
|
|
patchElement(n1, n2, parentComponent, parentSuspense, namespace, slotScopeIds, optimized);
|
|
}
|
|
};
|
|
const mountElement = (vnode, container, anchor, parentComponent, parentSuspense, namespace, slotScopeIds, optimized) => {
|
|
let el;
|
|
let vnodeHook;
|
|
const {
|
|
props,
|
|
shapeFlag,
|
|
transition,
|
|
dirs
|
|
} = vnode;
|
|
el = vnode.el = hostCreateElement(vnode.type, namespace, props && props.is, props);
|
|
if (shapeFlag & 8) {
|
|
hostSetElementText(el, vnode.children);
|
|
} else if (shapeFlag & 16) {
|
|
mountChildren(vnode.children, el, null, parentComponent, parentSuspense, resolveChildrenNamespace(vnode, namespace), slotScopeIds, optimized);
|
|
}
|
|
if (dirs) {
|
|
invokeDirectiveHook(vnode, null, parentComponent, "created");
|
|
}
|
|
setScopeId(el, vnode, vnode.scopeId, slotScopeIds, parentComponent);
|
|
if (props) {
|
|
for (const key in props) {
|
|
if (key !== "value" && !(0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .isReservedProp */ .SU)(key)) {
|
|
hostPatchProp(el, key, null, props[key], namespace, parentComponent);
|
|
}
|
|
}
|
|
if ("value" in props) {
|
|
hostPatchProp(el, "value", null, props.value, namespace);
|
|
}
|
|
if (vnodeHook = props.onVnodeBeforeMount) {
|
|
invokeVNodeHook(vnodeHook, parentComponent, vnode);
|
|
}
|
|
}
|
|
if (false) {}
|
|
if (dirs) {
|
|
invokeDirectiveHook(vnode, null, parentComponent, "beforeMount");
|
|
}
|
|
const needCallTransitionHooks = needTransition(parentSuspense, transition);
|
|
if (needCallTransitionHooks) {
|
|
transition.beforeEnter(el);
|
|
}
|
|
hostInsert(el, container, anchor);
|
|
if ((vnodeHook = props && props.onVnodeMounted) || needCallTransitionHooks || dirs) {
|
|
queuePostRenderEffect(() => {
|
|
vnodeHook && invokeVNodeHook(vnodeHook, parentComponent, vnode);
|
|
needCallTransitionHooks && transition.enter(el);
|
|
dirs && invokeDirectiveHook(vnode, null, parentComponent, "mounted");
|
|
}, parentSuspense);
|
|
}
|
|
};
|
|
const setScopeId = (el, vnode, scopeId, slotScopeIds, parentComponent) => {
|
|
if (scopeId) {
|
|
hostSetScopeId(el, scopeId);
|
|
}
|
|
if (slotScopeIds) {
|
|
for (let i = 0; i < slotScopeIds.length; i++) {
|
|
hostSetScopeId(el, slotScopeIds[i]);
|
|
}
|
|
}
|
|
if (parentComponent) {
|
|
let subTree = parentComponent.subTree;
|
|
if (false) {}
|
|
if (vnode === subTree || isSuspense(subTree.type) && (subTree.ssContent === vnode || subTree.ssFallback === vnode)) {
|
|
const parentVNode = parentComponent.vnode;
|
|
setScopeId(el, parentVNode, parentVNode.scopeId, parentVNode.slotScopeIds, parentComponent.parent);
|
|
}
|
|
}
|
|
};
|
|
const mountChildren = (children, container, anchor, parentComponent, parentSuspense, namespace, slotScopeIds, optimized, start = 0) => {
|
|
for (let i = start; i < children.length; i++) {
|
|
const child = children[i] = optimized ? cloneIfMounted(children[i]) : normalizeVNode(children[i]);
|
|
patch(null, child, container, anchor, parentComponent, parentSuspense, namespace, slotScopeIds, optimized);
|
|
}
|
|
};
|
|
const patchElement = (n1, n2, parentComponent, parentSuspense, namespace, slotScopeIds, optimized) => {
|
|
const el = n2.el = n1.el;
|
|
if (false) {}
|
|
let {
|
|
patchFlag,
|
|
dynamicChildren,
|
|
dirs
|
|
} = n2;
|
|
patchFlag |= n1.patchFlag & 16;
|
|
const oldProps = n1.props || _vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .EMPTY_OBJ */ .MZ;
|
|
const newProps = n2.props || _vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .EMPTY_OBJ */ .MZ;
|
|
let vnodeHook;
|
|
parentComponent && toggleRecurse(parentComponent, false);
|
|
if (vnodeHook = newProps.onVnodeBeforeUpdate) {
|
|
invokeVNodeHook(vnodeHook, parentComponent, n2, n1);
|
|
}
|
|
if (dirs) {
|
|
invokeDirectiveHook(n2, n1, parentComponent, "beforeUpdate");
|
|
}
|
|
parentComponent && toggleRecurse(parentComponent, true);
|
|
if (false) {}
|
|
if (oldProps.innerHTML && newProps.innerHTML == null || oldProps.textContent && newProps.textContent == null) {
|
|
hostSetElementText(el, "");
|
|
}
|
|
if (dynamicChildren) {
|
|
patchBlockChildren(n1.dynamicChildren, dynamicChildren, el, parentComponent, parentSuspense, resolveChildrenNamespace(n2, namespace), slotScopeIds);
|
|
if (false) {}
|
|
} else if (!optimized) {
|
|
patchChildren(n1, n2, el, null, parentComponent, parentSuspense, resolveChildrenNamespace(n2, namespace), slotScopeIds, false);
|
|
}
|
|
if (patchFlag > 0) {
|
|
if (patchFlag & 16) {
|
|
patchProps(el, oldProps, newProps, parentComponent, namespace);
|
|
} else {
|
|
if (patchFlag & 2) {
|
|
if (oldProps.class !== newProps.class) {
|
|
hostPatchProp(el, "class", null, newProps.class, namespace);
|
|
}
|
|
}
|
|
if (patchFlag & 4) {
|
|
hostPatchProp(el, "style", oldProps.style, newProps.style, namespace);
|
|
}
|
|
if (patchFlag & 8) {
|
|
const propsToUpdate = n2.dynamicProps;
|
|
for (let i = 0; i < propsToUpdate.length; i++) {
|
|
const key = propsToUpdate[i];
|
|
const prev = oldProps[key];
|
|
const next = newProps[key];
|
|
if (next !== prev || key === "value") {
|
|
hostPatchProp(el, key, prev, next, namespace, parentComponent);
|
|
}
|
|
}
|
|
}
|
|
}
|
|
if (patchFlag & 1) {
|
|
if (n1.children !== n2.children) {
|
|
hostSetElementText(el, n2.children);
|
|
}
|
|
}
|
|
} else if (!optimized && dynamicChildren == null) {
|
|
patchProps(el, oldProps, newProps, parentComponent, namespace);
|
|
}
|
|
if ((vnodeHook = newProps.onVnodeUpdated) || dirs) {
|
|
queuePostRenderEffect(() => {
|
|
vnodeHook && invokeVNodeHook(vnodeHook, parentComponent, n2, n1);
|
|
dirs && invokeDirectiveHook(n2, n1, parentComponent, "updated");
|
|
}, parentSuspense);
|
|
}
|
|
};
|
|
const patchBlockChildren = (oldChildren, newChildren, fallbackContainer, parentComponent, parentSuspense, namespace, slotScopeIds) => {
|
|
for (let i = 0; i < newChildren.length; i++) {
|
|
const oldVNode = oldChildren[i];
|
|
const newVNode = newChildren[i];
|
|
const container =
|
|
// oldVNode may be an errored async setup() component inside Suspense
|
|
// which will not have a mounted element
|
|
oldVNode.el && (
|
|
// - In the case of a Fragment, we need to provide the actual parent
|
|
// of the Fragment itself so it can move its children.
|
|
oldVNode.type === Fragment ||
|
|
// - In the case of different nodes, there is going to be a replacement
|
|
// which also requires the correct parent container
|
|
!isSameVNodeType(oldVNode, newVNode) ||
|
|
// - In the case of a component, it could contain anything.
|
|
oldVNode.shapeFlag & (6 | 64)) ? hostParentNode(oldVNode.el) :
|
|
// In other cases, the parent container is not actually used so we
|
|
// just pass the block element here to avoid a DOM parentNode call.
|
|
fallbackContainer;
|
|
patch(oldVNode, newVNode, container, null, parentComponent, parentSuspense, namespace, slotScopeIds, true);
|
|
}
|
|
};
|
|
const patchProps = (el, oldProps, newProps, parentComponent, namespace) => {
|
|
if (oldProps !== newProps) {
|
|
if (oldProps !== _vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .EMPTY_OBJ */ .MZ) {
|
|
for (const key in oldProps) {
|
|
if (!(0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .isReservedProp */ .SU)(key) && !(key in newProps)) {
|
|
hostPatchProp(el, key, oldProps[key], null, namespace, parentComponent);
|
|
}
|
|
}
|
|
}
|
|
for (const key in newProps) {
|
|
if ((0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .isReservedProp */ .SU)(key)) continue;
|
|
const next = newProps[key];
|
|
const prev = oldProps[key];
|
|
if (next !== prev && key !== "value") {
|
|
hostPatchProp(el, key, prev, next, namespace, parentComponent);
|
|
}
|
|
}
|
|
if ("value" in newProps) {
|
|
hostPatchProp(el, "value", oldProps.value, newProps.value, namespace);
|
|
}
|
|
}
|
|
};
|
|
const processFragment = (n1, n2, container, anchor, parentComponent, parentSuspense, namespace, slotScopeIds, optimized) => {
|
|
const fragmentStartAnchor = n2.el = n1 ? n1.el : hostCreateText("");
|
|
const fragmentEndAnchor = n2.anchor = n1 ? n1.anchor : hostCreateText("");
|
|
let {
|
|
patchFlag,
|
|
dynamicChildren,
|
|
slotScopeIds: fragmentSlotScopeIds
|
|
} = n2;
|
|
if (false) {}
|
|
if (fragmentSlotScopeIds) {
|
|
slotScopeIds = slotScopeIds ? slotScopeIds.concat(fragmentSlotScopeIds) : fragmentSlotScopeIds;
|
|
}
|
|
if (n1 == null) {
|
|
hostInsert(fragmentStartAnchor, container, anchor);
|
|
hostInsert(fragmentEndAnchor, container, anchor);
|
|
mountChildren(
|
|
// #10007
|
|
// such fragment like `<></>` will be compiled into
|
|
// a fragment which doesn't have a children.
|
|
// In this case fallback to an empty array
|
|
n2.children || [], container, fragmentEndAnchor, parentComponent, parentSuspense, namespace, slotScopeIds, optimized);
|
|
} else {
|
|
if (patchFlag > 0 && patchFlag & 64 && dynamicChildren &&
|
|
// #2715 the previous fragment could've been a BAILed one as a result
|
|
// of renderSlot() with no valid children
|
|
n1.dynamicChildren) {
|
|
patchBlockChildren(n1.dynamicChildren, dynamicChildren, container, parentComponent, parentSuspense, namespace, slotScopeIds);
|
|
if (false) {} else if (
|
|
// #2080 if the stable fragment has a key, it's a <template v-for> that may
|
|
// get moved around. Make sure all root level vnodes inherit el.
|
|
// #2134 or if it's a component root, it may also get moved around
|
|
// as the component is being moved.
|
|
n2.key != null || parentComponent && n2 === parentComponent.subTree) {
|
|
traverseStaticChildren(n1, n2, true
|
|
/* shallow */);
|
|
}
|
|
} else {
|
|
patchChildren(n1, n2, container, fragmentEndAnchor, parentComponent, parentSuspense, namespace, slotScopeIds, optimized);
|
|
}
|
|
}
|
|
};
|
|
const processComponent = (n1, n2, container, anchor, parentComponent, parentSuspense, namespace, slotScopeIds, optimized) => {
|
|
n2.slotScopeIds = slotScopeIds;
|
|
if (n1 == null) {
|
|
if (n2.shapeFlag & 512) {
|
|
parentComponent.ctx.activate(n2, container, anchor, namespace, optimized);
|
|
} else {
|
|
mountComponent(n2, container, anchor, parentComponent, parentSuspense, namespace, optimized);
|
|
}
|
|
} else {
|
|
updateComponent(n1, n2, optimized);
|
|
}
|
|
};
|
|
const mountComponent = (initialVNode, container, anchor, parentComponent, parentSuspense, namespace, optimized) => {
|
|
const instance = initialVNode.component = createComponentInstance(initialVNode, parentComponent, parentSuspense);
|
|
if (false) {}
|
|
if (false) {}
|
|
if (isKeepAlive(initialVNode)) {
|
|
instance.ctx.renderer = internals;
|
|
}
|
|
{
|
|
if (false) {}
|
|
setupComponent(instance, false, optimized);
|
|
if (false) {}
|
|
}
|
|
if (instance.asyncDep) {
|
|
if (false) {}
|
|
parentSuspense && parentSuspense.registerDep(instance, setupRenderEffect, optimized);
|
|
if (!initialVNode.el) {
|
|
const placeholder = instance.subTree = createVNode(Comment);
|
|
processCommentNode(null, placeholder, container, anchor);
|
|
}
|
|
} else {
|
|
setupRenderEffect(instance, initialVNode, container, anchor, parentSuspense, namespace, optimized);
|
|
}
|
|
if (false) {}
|
|
};
|
|
const updateComponent = (n1, n2, optimized) => {
|
|
const instance = n2.component = n1.component;
|
|
if (shouldUpdateComponent(n1, n2, optimized)) {
|
|
if (instance.asyncDep && !instance.asyncResolved) {
|
|
if (false) {}
|
|
updateComponentPreRender(instance, n2, optimized);
|
|
if (false) {}
|
|
return;
|
|
} else {
|
|
instance.next = n2;
|
|
instance.update();
|
|
}
|
|
} else {
|
|
n2.el = n1.el;
|
|
instance.vnode = n2;
|
|
}
|
|
};
|
|
const setupRenderEffect = (instance, initialVNode, container, anchor, parentSuspense, namespace, optimized) => {
|
|
const componentUpdateFn = () => {
|
|
if (!instance.isMounted) {
|
|
let vnodeHook;
|
|
const {
|
|
el,
|
|
props
|
|
} = initialVNode;
|
|
const {
|
|
bm,
|
|
m,
|
|
parent,
|
|
root,
|
|
type
|
|
} = instance;
|
|
const isAsyncWrapperVNode = isAsyncWrapper(initialVNode);
|
|
toggleRecurse(instance, false);
|
|
if (bm) {
|
|
(0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .invokeArrayFns */ .DY)(bm);
|
|
}
|
|
if (!isAsyncWrapperVNode && (vnodeHook = props && props.onVnodeBeforeMount)) {
|
|
invokeVNodeHook(vnodeHook, parent, initialVNode);
|
|
}
|
|
toggleRecurse(instance, true);
|
|
if (el && hydrateNode) {
|
|
const hydrateSubTree = () => {
|
|
if (false) {}
|
|
instance.subTree = renderComponentRoot(instance);
|
|
if (false) {}
|
|
if (false) {}
|
|
hydrateNode(el, instance.subTree, instance, parentSuspense, null);
|
|
if (false) {}
|
|
};
|
|
if (isAsyncWrapperVNode && type.__asyncHydrate) {
|
|
type.__asyncHydrate(el, instance, hydrateSubTree);
|
|
} else {
|
|
hydrateSubTree();
|
|
}
|
|
} else {
|
|
if (root.ce) {
|
|
root.ce._injectChildStyle(type);
|
|
}
|
|
if (false) {}
|
|
const subTree = instance.subTree = renderComponentRoot(instance);
|
|
if (false) {}
|
|
if (false) {}
|
|
patch(null, subTree, container, anchor, instance, parentSuspense, namespace);
|
|
if (false) {}
|
|
initialVNode.el = subTree.el;
|
|
}
|
|
if (m) {
|
|
queuePostRenderEffect(m, parentSuspense);
|
|
}
|
|
if (!isAsyncWrapperVNode && (vnodeHook = props && props.onVnodeMounted)) {
|
|
const scopedInitialVNode = initialVNode;
|
|
queuePostRenderEffect(() => invokeVNodeHook(vnodeHook, parent, scopedInitialVNode), parentSuspense);
|
|
}
|
|
if (initialVNode.shapeFlag & 256 || parent && isAsyncWrapper(parent.vnode) && parent.vnode.shapeFlag & 256) {
|
|
instance.a && queuePostRenderEffect(instance.a, parentSuspense);
|
|
}
|
|
instance.isMounted = true;
|
|
if (false) {}
|
|
initialVNode = container = anchor = null;
|
|
} else {
|
|
let {
|
|
next,
|
|
bu,
|
|
u,
|
|
parent,
|
|
vnode
|
|
} = instance;
|
|
{
|
|
const nonHydratedAsyncRoot = locateNonHydratedAsyncRoot(instance);
|
|
if (nonHydratedAsyncRoot) {
|
|
if (next) {
|
|
next.el = vnode.el;
|
|
updateComponentPreRender(instance, next, optimized);
|
|
}
|
|
nonHydratedAsyncRoot.asyncDep.then(() => {
|
|
if (!instance.isUnmounted) {
|
|
componentUpdateFn();
|
|
}
|
|
});
|
|
return;
|
|
}
|
|
}
|
|
let originNext = next;
|
|
let vnodeHook;
|
|
if (false) {}
|
|
toggleRecurse(instance, false);
|
|
if (next) {
|
|
next.el = vnode.el;
|
|
updateComponentPreRender(instance, next, optimized);
|
|
} else {
|
|
next = vnode;
|
|
}
|
|
if (bu) {
|
|
(0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .invokeArrayFns */ .DY)(bu);
|
|
}
|
|
if (vnodeHook = next.props && next.props.onVnodeBeforeUpdate) {
|
|
invokeVNodeHook(vnodeHook, parent, next, vnode);
|
|
}
|
|
toggleRecurse(instance, true);
|
|
if (false) {}
|
|
const nextTree = renderComponentRoot(instance);
|
|
if (false) {}
|
|
const prevTree = instance.subTree;
|
|
instance.subTree = nextTree;
|
|
if (false) {}
|
|
patch(prevTree, nextTree,
|
|
// parent may have changed if it's in a teleport
|
|
hostParentNode(prevTree.el),
|
|
// anchor may have changed if it's in a fragment
|
|
getNextHostNode(prevTree), instance, parentSuspense, namespace);
|
|
if (false) {}
|
|
next.el = nextTree.el;
|
|
if (originNext === null) {
|
|
updateHOCHostEl(instance, nextTree.el);
|
|
}
|
|
if (u) {
|
|
queuePostRenderEffect(u, parentSuspense);
|
|
}
|
|
if (vnodeHook = next.props && next.props.onVnodeUpdated) {
|
|
queuePostRenderEffect(() => invokeVNodeHook(vnodeHook, parent, next, vnode), parentSuspense);
|
|
}
|
|
if (false) {}
|
|
if (false) {}
|
|
}
|
|
};
|
|
instance.scope.on();
|
|
const effect = instance.effect = new _vue_reactivity__WEBPACK_IMPORTED_MODULE_17__/* .ReactiveEffect */ .X2(componentUpdateFn);
|
|
instance.scope.off();
|
|
const update = instance.update = effect.run.bind(effect);
|
|
const job = instance.job = effect.runIfDirty.bind(effect);
|
|
job.i = instance;
|
|
job.id = instance.uid;
|
|
effect.scheduler = () => queueJob(job);
|
|
toggleRecurse(instance, true);
|
|
if (false) {}
|
|
update();
|
|
};
|
|
const updateComponentPreRender = (instance, nextVNode, optimized) => {
|
|
nextVNode.component = instance;
|
|
const prevProps = instance.vnode.props;
|
|
instance.vnode = nextVNode;
|
|
instance.next = null;
|
|
updateProps(instance, nextVNode.props, prevProps, optimized);
|
|
updateSlots(instance, nextVNode.children, optimized);
|
|
(0,_vue_reactivity__WEBPACK_IMPORTED_MODULE_17__/* .pauseTracking */ .C4)();
|
|
flushPreFlushCbs(instance);
|
|
(0,_vue_reactivity__WEBPACK_IMPORTED_MODULE_17__/* .resetTracking */ .bl)();
|
|
};
|
|
const patchChildren = (n1, n2, container, anchor, parentComponent, parentSuspense, namespace, slotScopeIds, optimized = false) => {
|
|
const c1 = n1 && n1.children;
|
|
const prevShapeFlag = n1 ? n1.shapeFlag : 0;
|
|
const c2 = n2.children;
|
|
const {
|
|
patchFlag,
|
|
shapeFlag
|
|
} = n2;
|
|
if (patchFlag > 0) {
|
|
if (patchFlag & 128) {
|
|
patchKeyedChildren(c1, c2, container, anchor, parentComponent, parentSuspense, namespace, slotScopeIds, optimized);
|
|
return;
|
|
} else if (patchFlag & 256) {
|
|
patchUnkeyedChildren(c1, c2, container, anchor, parentComponent, parentSuspense, namespace, slotScopeIds, optimized);
|
|
return;
|
|
}
|
|
}
|
|
if (shapeFlag & 8) {
|
|
if (prevShapeFlag & 16) {
|
|
unmountChildren(c1, parentComponent, parentSuspense);
|
|
}
|
|
if (c2 !== c1) {
|
|
hostSetElementText(container, c2);
|
|
}
|
|
} else {
|
|
if (prevShapeFlag & 16) {
|
|
if (shapeFlag & 16) {
|
|
patchKeyedChildren(c1, c2, container, anchor, parentComponent, parentSuspense, namespace, slotScopeIds, optimized);
|
|
} else {
|
|
unmountChildren(c1, parentComponent, parentSuspense, true);
|
|
}
|
|
} else {
|
|
if (prevShapeFlag & 8) {
|
|
hostSetElementText(container, "");
|
|
}
|
|
if (shapeFlag & 16) {
|
|
mountChildren(c2, container, anchor, parentComponent, parentSuspense, namespace, slotScopeIds, optimized);
|
|
}
|
|
}
|
|
}
|
|
};
|
|
const patchUnkeyedChildren = (c1, c2, container, anchor, parentComponent, parentSuspense, namespace, slotScopeIds, optimized) => {
|
|
c1 = c1 || _vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .EMPTY_ARR */ .Oj;
|
|
c2 = c2 || _vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .EMPTY_ARR */ .Oj;
|
|
const oldLength = c1.length;
|
|
const newLength = c2.length;
|
|
const commonLength = Math.min(oldLength, newLength);
|
|
let i;
|
|
for (i = 0; i < commonLength; i++) {
|
|
const nextChild = c2[i] = optimized ? cloneIfMounted(c2[i]) : normalizeVNode(c2[i]);
|
|
patch(c1[i], nextChild, container, null, parentComponent, parentSuspense, namespace, slotScopeIds, optimized);
|
|
}
|
|
if (oldLength > newLength) {
|
|
unmountChildren(c1, parentComponent, parentSuspense, true, false, commonLength);
|
|
} else {
|
|
mountChildren(c2, container, anchor, parentComponent, parentSuspense, namespace, slotScopeIds, optimized, commonLength);
|
|
}
|
|
};
|
|
const patchKeyedChildren = (c1, c2, container, parentAnchor, parentComponent, parentSuspense, namespace, slotScopeIds, optimized) => {
|
|
let i = 0;
|
|
const l2 = c2.length;
|
|
let e1 = c1.length - 1;
|
|
let e2 = l2 - 1;
|
|
while (i <= e1 && i <= e2) {
|
|
const n1 = c1[i];
|
|
const n2 = c2[i] = optimized ? cloneIfMounted(c2[i]) : normalizeVNode(c2[i]);
|
|
if (isSameVNodeType(n1, n2)) {
|
|
patch(n1, n2, container, null, parentComponent, parentSuspense, namespace, slotScopeIds, optimized);
|
|
} else {
|
|
break;
|
|
}
|
|
i++;
|
|
}
|
|
while (i <= e1 && i <= e2) {
|
|
const n1 = c1[e1];
|
|
const n2 = c2[e2] = optimized ? cloneIfMounted(c2[e2]) : normalizeVNode(c2[e2]);
|
|
if (isSameVNodeType(n1, n2)) {
|
|
patch(n1, n2, container, null, parentComponent, parentSuspense, namespace, slotScopeIds, optimized);
|
|
} else {
|
|
break;
|
|
}
|
|
e1--;
|
|
e2--;
|
|
}
|
|
if (i > e1) {
|
|
if (i <= e2) {
|
|
const nextPos = e2 + 1;
|
|
const anchor = nextPos < l2 ? c2[nextPos].el : parentAnchor;
|
|
while (i <= e2) {
|
|
patch(null, c2[i] = optimized ? cloneIfMounted(c2[i]) : normalizeVNode(c2[i]), container, anchor, parentComponent, parentSuspense, namespace, slotScopeIds, optimized);
|
|
i++;
|
|
}
|
|
}
|
|
} else if (i > e2) {
|
|
while (i <= e1) {
|
|
unmount(c1[i], parentComponent, parentSuspense, true);
|
|
i++;
|
|
}
|
|
} else {
|
|
const s1 = i;
|
|
const s2 = i;
|
|
const keyToNewIndexMap = /* @__PURE__ */new Map();
|
|
for (i = s2; i <= e2; i++) {
|
|
const nextChild = c2[i] = optimized ? cloneIfMounted(c2[i]) : normalizeVNode(c2[i]);
|
|
if (nextChild.key != null) {
|
|
if (false) {}
|
|
keyToNewIndexMap.set(nextChild.key, i);
|
|
}
|
|
}
|
|
let j;
|
|
let patched = 0;
|
|
const toBePatched = e2 - s2 + 1;
|
|
let moved = false;
|
|
let maxNewIndexSoFar = 0;
|
|
const newIndexToOldIndexMap = new Array(toBePatched);
|
|
for (i = 0; i < toBePatched; i++) newIndexToOldIndexMap[i] = 0;
|
|
for (i = s1; i <= e1; i++) {
|
|
const prevChild = c1[i];
|
|
if (patched >= toBePatched) {
|
|
unmount(prevChild, parentComponent, parentSuspense, true);
|
|
continue;
|
|
}
|
|
let newIndex;
|
|
if (prevChild.key != null) {
|
|
newIndex = keyToNewIndexMap.get(prevChild.key);
|
|
} else {
|
|
for (j = s2; j <= e2; j++) {
|
|
if (newIndexToOldIndexMap[j - s2] === 0 && isSameVNodeType(prevChild, c2[j])) {
|
|
newIndex = j;
|
|
break;
|
|
}
|
|
}
|
|
}
|
|
if (newIndex === void 0) {
|
|
unmount(prevChild, parentComponent, parentSuspense, true);
|
|
} else {
|
|
newIndexToOldIndexMap[newIndex - s2] = i + 1;
|
|
if (newIndex >= maxNewIndexSoFar) {
|
|
maxNewIndexSoFar = newIndex;
|
|
} else {
|
|
moved = true;
|
|
}
|
|
patch(prevChild, c2[newIndex], container, null, parentComponent, parentSuspense, namespace, slotScopeIds, optimized);
|
|
patched++;
|
|
}
|
|
}
|
|
const increasingNewIndexSequence = moved ? getSequence(newIndexToOldIndexMap) : _vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .EMPTY_ARR */ .Oj;
|
|
j = increasingNewIndexSequence.length - 1;
|
|
for (i = toBePatched - 1; i >= 0; i--) {
|
|
const nextIndex = s2 + i;
|
|
const nextChild = c2[nextIndex];
|
|
const anchor = nextIndex + 1 < l2 ? c2[nextIndex + 1].el : parentAnchor;
|
|
if (newIndexToOldIndexMap[i] === 0) {
|
|
patch(null, nextChild, container, anchor, parentComponent, parentSuspense, namespace, slotScopeIds, optimized);
|
|
} else if (moved) {
|
|
if (j < 0 || i !== increasingNewIndexSequence[j]) {
|
|
move(nextChild, container, anchor, 2);
|
|
} else {
|
|
j--;
|
|
}
|
|
}
|
|
}
|
|
}
|
|
};
|
|
const move = (vnode, container, anchor, moveType, parentSuspense = null) => {
|
|
const {
|
|
el,
|
|
type,
|
|
transition,
|
|
children,
|
|
shapeFlag
|
|
} = vnode;
|
|
if (shapeFlag & 6) {
|
|
move(vnode.component.subTree, container, anchor, moveType);
|
|
return;
|
|
}
|
|
if (shapeFlag & 128) {
|
|
vnode.suspense.move(container, anchor, moveType);
|
|
return;
|
|
}
|
|
if (shapeFlag & 64) {
|
|
type.move(vnode, container, anchor, internals);
|
|
return;
|
|
}
|
|
if (type === Fragment) {
|
|
hostInsert(el, container, anchor);
|
|
for (let i = 0; i < children.length; i++) {
|
|
move(children[i], container, anchor, moveType);
|
|
}
|
|
hostInsert(vnode.anchor, container, anchor);
|
|
return;
|
|
}
|
|
if (type === Static) {
|
|
moveStaticNode(vnode, container, anchor);
|
|
return;
|
|
}
|
|
const needTransition2 = moveType !== 2 && shapeFlag & 1 && transition;
|
|
if (needTransition2) {
|
|
if (moveType === 0) {
|
|
transition.beforeEnter(el);
|
|
hostInsert(el, container, anchor);
|
|
queuePostRenderEffect(() => transition.enter(el), parentSuspense);
|
|
} else {
|
|
const {
|
|
leave,
|
|
delayLeave,
|
|
afterLeave
|
|
} = transition;
|
|
const remove2 = () => hostInsert(el, container, anchor);
|
|
const performLeave = () => {
|
|
leave(el, () => {
|
|
remove2();
|
|
afterLeave && afterLeave();
|
|
});
|
|
};
|
|
if (delayLeave) {
|
|
delayLeave(el, remove2, performLeave);
|
|
} else {
|
|
performLeave();
|
|
}
|
|
}
|
|
} else {
|
|
hostInsert(el, container, anchor);
|
|
}
|
|
};
|
|
const unmount = (vnode, parentComponent, parentSuspense, doRemove = false, optimized = false) => {
|
|
const {
|
|
type,
|
|
props,
|
|
ref,
|
|
children,
|
|
dynamicChildren,
|
|
shapeFlag,
|
|
patchFlag,
|
|
dirs,
|
|
cacheIndex
|
|
} = vnode;
|
|
if (patchFlag === -2) {
|
|
optimized = false;
|
|
}
|
|
if (ref != null) {
|
|
setRef(ref, null, parentSuspense, vnode, true);
|
|
}
|
|
if (cacheIndex != null) {
|
|
parentComponent.renderCache[cacheIndex] = void 0;
|
|
}
|
|
if (shapeFlag & 256) {
|
|
parentComponent.ctx.deactivate(vnode);
|
|
return;
|
|
}
|
|
const shouldInvokeDirs = shapeFlag & 1 && dirs;
|
|
const shouldInvokeVnodeHook = !isAsyncWrapper(vnode);
|
|
let vnodeHook;
|
|
if (shouldInvokeVnodeHook && (vnodeHook = props && props.onVnodeBeforeUnmount)) {
|
|
invokeVNodeHook(vnodeHook, parentComponent, vnode);
|
|
}
|
|
if (shapeFlag & 6) {
|
|
unmountComponent(vnode.component, parentSuspense, doRemove);
|
|
} else {
|
|
if (shapeFlag & 128) {
|
|
vnode.suspense.unmount(parentSuspense, doRemove);
|
|
return;
|
|
}
|
|
if (shouldInvokeDirs) {
|
|
invokeDirectiveHook(vnode, null, parentComponent, "beforeUnmount");
|
|
}
|
|
if (shapeFlag & 64) {
|
|
vnode.type.remove(vnode, parentComponent, parentSuspense, internals, doRemove);
|
|
} else if (dynamicChildren &&
|
|
// #5154
|
|
// when v-once is used inside a block, setBlockTracking(-1) marks the
|
|
// parent block with hasOnce: true
|
|
// so that it doesn't take the fast path during unmount - otherwise
|
|
// components nested in v-once are never unmounted.
|
|
!dynamicChildren.hasOnce && (
|
|
// #1153: fast path should not be taken for non-stable (v-for) fragments
|
|
type !== Fragment || patchFlag > 0 && patchFlag & 64)) {
|
|
unmountChildren(dynamicChildren, parentComponent, parentSuspense, false, true);
|
|
} else if (type === Fragment && patchFlag & (128 | 256) || !optimized && shapeFlag & 16) {
|
|
unmountChildren(children, parentComponent, parentSuspense);
|
|
}
|
|
if (doRemove) {
|
|
remove(vnode);
|
|
}
|
|
}
|
|
if (shouldInvokeVnodeHook && (vnodeHook = props && props.onVnodeUnmounted) || shouldInvokeDirs) {
|
|
queuePostRenderEffect(() => {
|
|
vnodeHook && invokeVNodeHook(vnodeHook, parentComponent, vnode);
|
|
shouldInvokeDirs && invokeDirectiveHook(vnode, null, parentComponent, "unmounted");
|
|
}, parentSuspense);
|
|
}
|
|
};
|
|
const remove = vnode => {
|
|
const {
|
|
type,
|
|
el,
|
|
anchor,
|
|
transition
|
|
} = vnode;
|
|
if (type === Fragment) {
|
|
if (false) {} else {
|
|
removeFragment(el, anchor);
|
|
}
|
|
return;
|
|
}
|
|
if (type === Static) {
|
|
removeStaticNode(vnode);
|
|
return;
|
|
}
|
|
const performRemove = () => {
|
|
hostRemove(el);
|
|
if (transition && !transition.persisted && transition.afterLeave) {
|
|
transition.afterLeave();
|
|
}
|
|
};
|
|
if (vnode.shapeFlag & 1 && transition && !transition.persisted) {
|
|
const {
|
|
leave,
|
|
delayLeave
|
|
} = transition;
|
|
const performLeave = () => leave(el, performRemove);
|
|
if (delayLeave) {
|
|
delayLeave(vnode.el, performRemove, performLeave);
|
|
} else {
|
|
performLeave();
|
|
}
|
|
} else {
|
|
performRemove();
|
|
}
|
|
};
|
|
const removeFragment = (cur, end) => {
|
|
let next;
|
|
while (cur !== end) {
|
|
next = hostNextSibling(cur);
|
|
hostRemove(cur);
|
|
cur = next;
|
|
}
|
|
hostRemove(end);
|
|
};
|
|
const unmountComponent = (instance, parentSuspense, doRemove) => {
|
|
if (false) {}
|
|
const {
|
|
bum,
|
|
scope,
|
|
job,
|
|
subTree,
|
|
um,
|
|
m,
|
|
a
|
|
} = instance;
|
|
invalidateMount(m);
|
|
invalidateMount(a);
|
|
if (bum) {
|
|
(0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .invokeArrayFns */ .DY)(bum);
|
|
}
|
|
scope.stop();
|
|
if (job) {
|
|
job.flags |= 8;
|
|
unmount(subTree, instance, parentSuspense, doRemove);
|
|
}
|
|
if (um) {
|
|
queuePostRenderEffect(um, parentSuspense);
|
|
}
|
|
queuePostRenderEffect(() => {
|
|
instance.isUnmounted = true;
|
|
}, parentSuspense);
|
|
if (parentSuspense && parentSuspense.pendingBranch && !parentSuspense.isUnmounted && instance.asyncDep && !instance.asyncResolved && instance.suspenseId === parentSuspense.pendingId) {
|
|
parentSuspense.deps--;
|
|
if (parentSuspense.deps === 0) {
|
|
parentSuspense.resolve();
|
|
}
|
|
}
|
|
if (false) {}
|
|
};
|
|
const unmountChildren = (children, parentComponent, parentSuspense, doRemove = false, optimized = false, start = 0) => {
|
|
for (let i = start; i < children.length; i++) {
|
|
unmount(children[i], parentComponent, parentSuspense, doRemove, optimized);
|
|
}
|
|
};
|
|
const getNextHostNode = vnode => {
|
|
if (vnode.shapeFlag & 6) {
|
|
return getNextHostNode(vnode.component.subTree);
|
|
}
|
|
if (vnode.shapeFlag & 128) {
|
|
return vnode.suspense.next();
|
|
}
|
|
const el = hostNextSibling(vnode.anchor || vnode.el);
|
|
const teleportEnd = el && el[TeleportEndKey];
|
|
return teleportEnd ? hostNextSibling(teleportEnd) : el;
|
|
};
|
|
let isFlushing = false;
|
|
const render = (vnode, container, namespace) => {
|
|
if (vnode == null) {
|
|
if (container._vnode) {
|
|
unmount(container._vnode, null, null, true);
|
|
}
|
|
} else {
|
|
patch(container._vnode || null, vnode, container, null, null, null, namespace);
|
|
}
|
|
container._vnode = vnode;
|
|
if (!isFlushing) {
|
|
isFlushing = true;
|
|
flushPreFlushCbs();
|
|
flushPostFlushCbs();
|
|
isFlushing = false;
|
|
}
|
|
};
|
|
const internals = {
|
|
p: patch,
|
|
um: unmount,
|
|
m: move,
|
|
r: remove,
|
|
mt: mountComponent,
|
|
mc: mountChildren,
|
|
pc: patchChildren,
|
|
pbc: patchBlockChildren,
|
|
n: getNextHostNode,
|
|
o: options
|
|
};
|
|
let hydrate;
|
|
let hydrateNode;
|
|
if (createHydrationFns) {
|
|
[hydrate, hydrateNode] = createHydrationFns(internals);
|
|
}
|
|
return {
|
|
render,
|
|
hydrate,
|
|
createApp: createAppAPI(render, hydrate)
|
|
};
|
|
}
|
|
function resolveChildrenNamespace({
|
|
type,
|
|
props
|
|
}, currentNamespace) {
|
|
return currentNamespace === "svg" && type === "foreignObject" || currentNamespace === "mathml" && type === "annotation-xml" && props && props.encoding && props.encoding.includes("html") ? void 0 : currentNamespace;
|
|
}
|
|
function toggleRecurse({
|
|
effect,
|
|
job
|
|
}, allowed) {
|
|
if (allowed) {
|
|
effect.flags |= 32;
|
|
job.flags |= 4;
|
|
} else {
|
|
effect.flags &= ~32;
|
|
job.flags &= ~4;
|
|
}
|
|
}
|
|
function needTransition(parentSuspense, transition) {
|
|
return (!parentSuspense || parentSuspense && !parentSuspense.pendingBranch) && transition && !transition.persisted;
|
|
}
|
|
function traverseStaticChildren(n1, n2, shallow = false) {
|
|
const ch1 = n1.children;
|
|
const ch2 = n2.children;
|
|
if ((0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .isArray */ .cy)(ch1) && (0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .isArray */ .cy)(ch2)) {
|
|
for (let i = 0; i < ch1.length; i++) {
|
|
const c1 = ch1[i];
|
|
let c2 = ch2[i];
|
|
if (c2.shapeFlag & 1 && !c2.dynamicChildren) {
|
|
if (c2.patchFlag <= 0 || c2.patchFlag === 32) {
|
|
c2 = ch2[i] = cloneIfMounted(ch2[i]);
|
|
c2.el = c1.el;
|
|
}
|
|
if (!shallow && c2.patchFlag !== -2) traverseStaticChildren(c1, c2);
|
|
}
|
|
if (c2.type === Text) {
|
|
c2.el = c1.el;
|
|
}
|
|
if (false) {}
|
|
}
|
|
}
|
|
}
|
|
function getSequence(arr) {
|
|
const p = arr.slice();
|
|
const result = [0];
|
|
let i, j, u, v, c;
|
|
const len = arr.length;
|
|
for (i = 0; i < len; i++) {
|
|
const arrI = arr[i];
|
|
if (arrI !== 0) {
|
|
j = result[result.length - 1];
|
|
if (arr[j] < arrI) {
|
|
p[i] = j;
|
|
result.push(i);
|
|
continue;
|
|
}
|
|
u = 0;
|
|
v = result.length - 1;
|
|
while (u < v) {
|
|
c = u + v >> 1;
|
|
if (arr[result[c]] < arrI) {
|
|
u = c + 1;
|
|
} else {
|
|
v = c;
|
|
}
|
|
}
|
|
if (arrI < arr[result[u]]) {
|
|
if (u > 0) {
|
|
p[i] = result[u - 1];
|
|
}
|
|
result[u] = i;
|
|
}
|
|
}
|
|
}
|
|
u = result.length;
|
|
v = result[u - 1];
|
|
while (u-- > 0) {
|
|
result[u] = v;
|
|
v = p[v];
|
|
}
|
|
return result;
|
|
}
|
|
function locateNonHydratedAsyncRoot(instance) {
|
|
const subComponent = instance.subTree.component;
|
|
if (subComponent) {
|
|
if (subComponent.asyncDep && !subComponent.asyncResolved) {
|
|
return subComponent;
|
|
} else {
|
|
return locateNonHydratedAsyncRoot(subComponent);
|
|
}
|
|
}
|
|
}
|
|
function invalidateMount(hooks) {
|
|
if (hooks) {
|
|
for (let i = 0; i < hooks.length; i++) hooks[i].flags |= 8;
|
|
}
|
|
}
|
|
const ssrContextKey = Symbol.for("v-scx");
|
|
const useSSRContext = () => {
|
|
{
|
|
const ctx = inject(ssrContextKey);
|
|
if (!ctx) {
|
|
false && 0;
|
|
}
|
|
return ctx;
|
|
}
|
|
};
|
|
function watchEffect(effect, options) {
|
|
return doWatch(effect, null, options);
|
|
}
|
|
function watchPostEffect(effect, options) {
|
|
return doWatch(effect, null, false ? 0 : {
|
|
flush: "post"
|
|
});
|
|
}
|
|
function watchSyncEffect(effect, options) {
|
|
return doWatch(effect, null, false ? 0 : {
|
|
flush: "sync"
|
|
});
|
|
}
|
|
function watch(source, cb, options) {
|
|
if (false) {}
|
|
return doWatch(source, cb, options);
|
|
}
|
|
function doWatch(source, cb, options = _vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .EMPTY_OBJ */ .MZ) {
|
|
const {
|
|
immediate,
|
|
deep,
|
|
flush,
|
|
once
|
|
} = options;
|
|
if (false) {}
|
|
const baseWatchOptions = (0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .extend */ .X$)({}, options);
|
|
if (false) {}
|
|
const runsImmediately = cb && immediate || !cb && flush !== "post";
|
|
let ssrCleanup;
|
|
if (isInSSRComponentSetup) {
|
|
if (flush === "sync") {
|
|
const ctx = useSSRContext();
|
|
ssrCleanup = ctx.__watcherHandles || (ctx.__watcherHandles = []);
|
|
} else if (!runsImmediately) {
|
|
const watchStopHandle = () => {};
|
|
watchStopHandle.stop = _vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .NOOP */ .tE;
|
|
watchStopHandle.resume = _vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .NOOP */ .tE;
|
|
watchStopHandle.pause = _vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .NOOP */ .tE;
|
|
return watchStopHandle;
|
|
}
|
|
}
|
|
const instance = currentInstance;
|
|
baseWatchOptions.call = (fn, type, args) => callWithAsyncErrorHandling(fn, instance, type, args);
|
|
let isPre = false;
|
|
if (flush === "post") {
|
|
baseWatchOptions.scheduler = job => {
|
|
queuePostRenderEffect(job, instance && instance.suspense);
|
|
};
|
|
} else if (flush !== "sync") {
|
|
isPre = true;
|
|
baseWatchOptions.scheduler = (job, isFirstRun) => {
|
|
if (isFirstRun) {
|
|
job();
|
|
} else {
|
|
queueJob(job);
|
|
}
|
|
};
|
|
}
|
|
baseWatchOptions.augmentJob = job => {
|
|
if (cb) {
|
|
job.flags |= 4;
|
|
}
|
|
if (isPre) {
|
|
job.flags |= 2;
|
|
if (instance) {
|
|
job.id = instance.uid;
|
|
job.i = instance;
|
|
}
|
|
}
|
|
};
|
|
const watchHandle = (0,_vue_reactivity__WEBPACK_IMPORTED_MODULE_17__/* .watch */ .wB)(source, cb, baseWatchOptions);
|
|
if (isInSSRComponentSetup) {
|
|
if (ssrCleanup) {
|
|
ssrCleanup.push(watchHandle);
|
|
} else if (runsImmediately) {
|
|
watchHandle();
|
|
}
|
|
}
|
|
return watchHandle;
|
|
}
|
|
function instanceWatch(source, value, options) {
|
|
const publicThis = this.proxy;
|
|
const getter = (0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .isString */ .Kg)(source) ? source.includes(".") ? createPathGetter(publicThis, source) : () => publicThis[source] : source.bind(publicThis, publicThis);
|
|
let cb;
|
|
if ((0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .isFunction */ .Tn)(value)) {
|
|
cb = value;
|
|
} else {
|
|
cb = value.handler;
|
|
options = value;
|
|
}
|
|
const reset = setCurrentInstance(this);
|
|
const res = doWatch(getter, cb.bind(publicThis), options);
|
|
reset();
|
|
return res;
|
|
}
|
|
function createPathGetter(ctx, path) {
|
|
const segments = path.split(".");
|
|
return () => {
|
|
let cur = ctx;
|
|
for (let i = 0; i < segments.length && cur; i++) {
|
|
cur = cur[segments[i]];
|
|
}
|
|
return cur;
|
|
};
|
|
}
|
|
function useModel(props, name, options = EMPTY_OBJ) {
|
|
const i = getCurrentInstance();
|
|
if (false) {}
|
|
const camelizedName = camelize(name);
|
|
if (false) {}
|
|
const hyphenatedName = hyphenate(name);
|
|
const modifiers = getModelModifiers(props, camelizedName);
|
|
const res = customRef((track, trigger) => {
|
|
let localValue;
|
|
let prevSetValue = EMPTY_OBJ;
|
|
let prevEmittedValue;
|
|
watchSyncEffect(() => {
|
|
const propValue = props[camelizedName];
|
|
if (hasChanged(localValue, propValue)) {
|
|
localValue = propValue;
|
|
trigger();
|
|
}
|
|
});
|
|
return {
|
|
get() {
|
|
track();
|
|
return options.get ? options.get(localValue) : localValue;
|
|
},
|
|
set(value) {
|
|
const emittedValue = options.set ? options.set(value) : value;
|
|
if (!hasChanged(emittedValue, localValue) && !(prevSetValue !== EMPTY_OBJ && hasChanged(value, prevSetValue))) {
|
|
return;
|
|
}
|
|
const rawProps = i.vnode.props;
|
|
if (!(rawProps && (
|
|
// check if parent has passed v-model
|
|
name in rawProps || camelizedName in rawProps || hyphenatedName in rawProps) && (`onUpdate:${name}` in rawProps || `onUpdate:${camelizedName}` in rawProps || `onUpdate:${hyphenatedName}` in rawProps))) {
|
|
localValue = value;
|
|
trigger();
|
|
}
|
|
i.emit(`update:${name}`, emittedValue);
|
|
if (hasChanged(value, emittedValue) && hasChanged(value, prevSetValue) && !hasChanged(emittedValue, prevEmittedValue)) {
|
|
trigger();
|
|
}
|
|
prevSetValue = value;
|
|
prevEmittedValue = emittedValue;
|
|
}
|
|
};
|
|
});
|
|
res[Symbol.iterator] = () => {
|
|
let i2 = 0;
|
|
return {
|
|
next() {
|
|
if (i2 < 2) {
|
|
return {
|
|
value: i2++ ? modifiers || EMPTY_OBJ : res,
|
|
done: false
|
|
};
|
|
} else {
|
|
return {
|
|
done: true
|
|
};
|
|
}
|
|
}
|
|
};
|
|
};
|
|
return res;
|
|
}
|
|
const getModelModifiers = (props, modelName) => {
|
|
return modelName === "modelValue" || modelName === "model-value" ? props.modelModifiers : props[`${modelName}Modifiers`] || props[`${(0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .camelize */ .PT)(modelName)}Modifiers`] || props[`${(0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .hyphenate */ .Tg)(modelName)}Modifiers`];
|
|
};
|
|
function emit(instance, event, ...rawArgs) {
|
|
if (instance.isUnmounted) return;
|
|
const props = instance.vnode.props || _vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .EMPTY_OBJ */ .MZ;
|
|
if (false) {}
|
|
let args = rawArgs;
|
|
const isModelListener = event.startsWith("update:");
|
|
const modifiers = isModelListener && getModelModifiers(props, event.slice(7));
|
|
if (modifiers) {
|
|
if (modifiers.trim) {
|
|
args = rawArgs.map(a => (0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .isString */ .Kg)(a) ? a.trim() : a);
|
|
}
|
|
if (modifiers.number) {
|
|
args = rawArgs.map(_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .looseToNumber */ .bB);
|
|
}
|
|
}
|
|
if (false) {}
|
|
if (false) {}
|
|
let handlerName;
|
|
let handler = props[handlerName = (0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .toHandlerKey */ .rU)(event)] ||
|
|
// also try camelCase event handler (#2249)
|
|
props[handlerName = (0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .toHandlerKey */ .rU)((0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .camelize */ .PT)(event))];
|
|
if (!handler && isModelListener) {
|
|
handler = props[handlerName = (0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .toHandlerKey */ .rU)((0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .hyphenate */ .Tg)(event))];
|
|
}
|
|
if (handler) {
|
|
callWithAsyncErrorHandling(handler, instance, 6, args);
|
|
}
|
|
const onceHandler = props[handlerName + `Once`];
|
|
if (onceHandler) {
|
|
if (!instance.emitted) {
|
|
instance.emitted = {};
|
|
} else if (instance.emitted[handlerName]) {
|
|
return;
|
|
}
|
|
instance.emitted[handlerName] = true;
|
|
callWithAsyncErrorHandling(onceHandler, instance, 6, args);
|
|
}
|
|
}
|
|
function normalizeEmitsOptions(comp, appContext, asMixin = false) {
|
|
const cache = appContext.emitsCache;
|
|
const cached = cache.get(comp);
|
|
if (cached !== void 0) {
|
|
return cached;
|
|
}
|
|
const raw = comp.emits;
|
|
let normalized = {};
|
|
let hasExtends = false;
|
|
if ( true && !(0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .isFunction */ .Tn)(comp)) {
|
|
const extendEmits = raw2 => {
|
|
const normalizedFromExtend = normalizeEmitsOptions(raw2, appContext, true);
|
|
if (normalizedFromExtend) {
|
|
hasExtends = true;
|
|
(0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .extend */ .X$)(normalized, normalizedFromExtend);
|
|
}
|
|
};
|
|
if (!asMixin && appContext.mixins.length) {
|
|
appContext.mixins.forEach(extendEmits);
|
|
}
|
|
if (comp.extends) {
|
|
extendEmits(comp.extends);
|
|
}
|
|
if (comp.mixins) {
|
|
comp.mixins.forEach(extendEmits);
|
|
}
|
|
}
|
|
if (!raw && !hasExtends) {
|
|
if ((0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .isObject */ .Gv)(comp)) {
|
|
cache.set(comp, null);
|
|
}
|
|
return null;
|
|
}
|
|
if ((0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .isArray */ .cy)(raw)) {
|
|
raw.forEach(key => normalized[key] = null);
|
|
} else {
|
|
(0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .extend */ .X$)(normalized, raw);
|
|
}
|
|
if ((0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .isObject */ .Gv)(comp)) {
|
|
cache.set(comp, normalized);
|
|
}
|
|
return normalized;
|
|
}
|
|
function isEmitListener(options, key) {
|
|
if (!options || !(0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .isOn */ .Mp)(key)) {
|
|
return false;
|
|
}
|
|
key = key.slice(2).replace(/Once$/, "");
|
|
return (0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .hasOwn */ .$3)(options, key[0].toLowerCase() + key.slice(1)) || (0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .hasOwn */ .$3)(options, (0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .hyphenate */ .Tg)(key)) || (0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .hasOwn */ .$3)(options, key);
|
|
}
|
|
let accessedAttrs = false;
|
|
function markAttrsAccessed() {
|
|
accessedAttrs = true;
|
|
}
|
|
function renderComponentRoot(instance) {
|
|
const {
|
|
type: Component,
|
|
vnode,
|
|
proxy,
|
|
withProxy,
|
|
propsOptions: [propsOptions],
|
|
slots,
|
|
attrs,
|
|
emit,
|
|
render,
|
|
renderCache,
|
|
props,
|
|
data,
|
|
setupState,
|
|
ctx,
|
|
inheritAttrs
|
|
} = instance;
|
|
const prev = setCurrentRenderingInstance(instance);
|
|
let result;
|
|
let fallthroughAttrs;
|
|
if (false) {}
|
|
try {
|
|
if (vnode.shapeFlag & 4) {
|
|
const proxyToUse = withProxy || proxy;
|
|
const thisProxy = false ? 0 : proxyToUse;
|
|
result = normalizeVNode(render.call(thisProxy, proxyToUse, renderCache, false ? 0 : props, setupState, data, ctx));
|
|
fallthroughAttrs = attrs;
|
|
} else {
|
|
const render2 = Component;
|
|
if (false) {}
|
|
result = normalizeVNode(render2.length > 1 ? render2( false ? 0 : props, false ? 0 : {
|
|
attrs,
|
|
slots,
|
|
emit
|
|
}) : render2( false ? 0 : props, null));
|
|
fallthroughAttrs = Component.props ? attrs : getFunctionalFallthrough(attrs);
|
|
}
|
|
} catch (err) {
|
|
blockStack.length = 0;
|
|
handleError(err, instance, 1);
|
|
result = createVNode(Comment);
|
|
}
|
|
let root = result;
|
|
let setRoot = void 0;
|
|
if (false) {}
|
|
if (fallthroughAttrs && inheritAttrs !== false) {
|
|
const keys = Object.keys(fallthroughAttrs);
|
|
const {
|
|
shapeFlag
|
|
} = root;
|
|
if (keys.length) {
|
|
if (shapeFlag & (1 | 6)) {
|
|
if (propsOptions && keys.some(_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .isModelListener */ .CP)) {
|
|
fallthroughAttrs = filterModelListeners(fallthroughAttrs, propsOptions);
|
|
}
|
|
root = cloneVNode(root, fallthroughAttrs, false, true);
|
|
} else if (false) {}
|
|
}
|
|
}
|
|
if (vnode.dirs) {
|
|
if (false) {}
|
|
root = cloneVNode(root, null, false, true);
|
|
root.dirs = root.dirs ? root.dirs.concat(vnode.dirs) : vnode.dirs;
|
|
}
|
|
if (vnode.transition) {
|
|
if (false) {}
|
|
setTransitionHooks(root, vnode.transition);
|
|
}
|
|
if (false) {} else {
|
|
result = root;
|
|
}
|
|
setCurrentRenderingInstance(prev);
|
|
return result;
|
|
}
|
|
const getChildRoot = vnode => {
|
|
const rawChildren = vnode.children;
|
|
const dynamicChildren = vnode.dynamicChildren;
|
|
const childRoot = filterSingleRoot(rawChildren, false);
|
|
if (!childRoot) {
|
|
return [vnode, void 0];
|
|
} else if (false) {}
|
|
const index = rawChildren.indexOf(childRoot);
|
|
const dynamicIndex = dynamicChildren ? dynamicChildren.indexOf(childRoot) : -1;
|
|
const setRoot = updatedRoot => {
|
|
rawChildren[index] = updatedRoot;
|
|
if (dynamicChildren) {
|
|
if (dynamicIndex > -1) {
|
|
dynamicChildren[dynamicIndex] = updatedRoot;
|
|
} else if (updatedRoot.patchFlag > 0) {
|
|
vnode.dynamicChildren = [...dynamicChildren, updatedRoot];
|
|
}
|
|
}
|
|
};
|
|
return [normalizeVNode(childRoot), setRoot];
|
|
};
|
|
function filterSingleRoot(children, recurse = true) {
|
|
let singleRoot;
|
|
for (let i = 0; i < children.length; i++) {
|
|
const child = children[i];
|
|
if (isVNode(child)) {
|
|
if (child.type !== Comment || child.children === "v-if") {
|
|
if (singleRoot) {
|
|
return;
|
|
} else {
|
|
singleRoot = child;
|
|
if (false) {}
|
|
}
|
|
}
|
|
} else {
|
|
return;
|
|
}
|
|
}
|
|
return singleRoot;
|
|
}
|
|
const getFunctionalFallthrough = attrs => {
|
|
let res;
|
|
for (const key in attrs) {
|
|
if (key === "class" || key === "style" || (0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .isOn */ .Mp)(key)) {
|
|
(res || (res = {}))[key] = attrs[key];
|
|
}
|
|
}
|
|
return res;
|
|
};
|
|
const filterModelListeners = (attrs, props) => {
|
|
const res = {};
|
|
for (const key in attrs) {
|
|
if (!(0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .isModelListener */ .CP)(key) || !(key.slice(9) in props)) {
|
|
res[key] = attrs[key];
|
|
}
|
|
}
|
|
return res;
|
|
};
|
|
const isElementRoot = vnode => {
|
|
return vnode.shapeFlag & (6 | 1) || vnode.type === Comment;
|
|
};
|
|
function shouldUpdateComponent(prevVNode, nextVNode, optimized) {
|
|
const {
|
|
props: prevProps,
|
|
children: prevChildren,
|
|
component
|
|
} = prevVNode;
|
|
const {
|
|
props: nextProps,
|
|
children: nextChildren,
|
|
patchFlag
|
|
} = nextVNode;
|
|
const emits = component.emitsOptions;
|
|
if (false) {}
|
|
if (nextVNode.dirs || nextVNode.transition) {
|
|
return true;
|
|
}
|
|
if (optimized && patchFlag >= 0) {
|
|
if (patchFlag & 1024) {
|
|
return true;
|
|
}
|
|
if (patchFlag & 16) {
|
|
if (!prevProps) {
|
|
return !!nextProps;
|
|
}
|
|
return hasPropsChanged(prevProps, nextProps, emits);
|
|
} else if (patchFlag & 8) {
|
|
const dynamicProps = nextVNode.dynamicProps;
|
|
for (let i = 0; i < dynamicProps.length; i++) {
|
|
const key = dynamicProps[i];
|
|
if (nextProps[key] !== prevProps[key] && !isEmitListener(emits, key)) {
|
|
return true;
|
|
}
|
|
}
|
|
}
|
|
} else {
|
|
if (prevChildren || nextChildren) {
|
|
if (!nextChildren || !nextChildren.$stable) {
|
|
return true;
|
|
}
|
|
}
|
|
if (prevProps === nextProps) {
|
|
return false;
|
|
}
|
|
if (!prevProps) {
|
|
return !!nextProps;
|
|
}
|
|
if (!nextProps) {
|
|
return true;
|
|
}
|
|
return hasPropsChanged(prevProps, nextProps, emits);
|
|
}
|
|
return false;
|
|
}
|
|
function hasPropsChanged(prevProps, nextProps, emitsOptions) {
|
|
const nextKeys = Object.keys(nextProps);
|
|
if (nextKeys.length !== Object.keys(prevProps).length) {
|
|
return true;
|
|
}
|
|
for (let i = 0; i < nextKeys.length; i++) {
|
|
const key = nextKeys[i];
|
|
if (nextProps[key] !== prevProps[key] && !isEmitListener(emitsOptions, key)) {
|
|
return true;
|
|
}
|
|
}
|
|
return false;
|
|
}
|
|
function updateHOCHostEl({
|
|
vnode,
|
|
parent
|
|
}, el) {
|
|
while (parent) {
|
|
const root = parent.subTree;
|
|
if (root.suspense && root.suspense.activeBranch === vnode) {
|
|
root.el = vnode.el;
|
|
}
|
|
if (root === vnode) {
|
|
(vnode = parent.vnode).el = el;
|
|
parent = parent.parent;
|
|
} else {
|
|
break;
|
|
}
|
|
}
|
|
}
|
|
const isSuspense = type => type.__isSuspense;
|
|
let suspenseId = 0;
|
|
const SuspenseImpl = {
|
|
name: "Suspense",
|
|
// In order to make Suspense tree-shakable, we need to avoid importing it
|
|
// directly in the renderer. The renderer checks for the __isSuspense flag
|
|
// on a vnode's type and calls the `process` method, passing in renderer
|
|
// internals.
|
|
__isSuspense: true,
|
|
process(n1, n2, container, anchor, parentComponent, parentSuspense, namespace, slotScopeIds, optimized, rendererInternals) {
|
|
if (n1 == null) {
|
|
mountSuspense(n2, container, anchor, parentComponent, parentSuspense, namespace, slotScopeIds, optimized, rendererInternals);
|
|
} else {
|
|
if (parentSuspense && parentSuspense.deps > 0 && !n1.suspense.isInFallback) {
|
|
n2.suspense = n1.suspense;
|
|
n2.suspense.vnode = n2;
|
|
n2.el = n1.el;
|
|
return;
|
|
}
|
|
patchSuspense(n1, n2, container, anchor, parentComponent, namespace, slotScopeIds, optimized, rendererInternals);
|
|
}
|
|
},
|
|
hydrate: hydrateSuspense,
|
|
normalize: normalizeSuspenseChildren
|
|
};
|
|
const Suspense = (/* unused pure expression or super */ null && (SuspenseImpl));
|
|
function triggerEvent(vnode, name) {
|
|
const eventListener = vnode.props && vnode.props[name];
|
|
if ((0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .isFunction */ .Tn)(eventListener)) {
|
|
eventListener();
|
|
}
|
|
}
|
|
function mountSuspense(vnode, container, anchor, parentComponent, parentSuspense, namespace, slotScopeIds, optimized, rendererInternals) {
|
|
const {
|
|
p: patch,
|
|
o: {
|
|
createElement
|
|
}
|
|
} = rendererInternals;
|
|
const hiddenContainer = createElement("div");
|
|
const suspense = vnode.suspense = createSuspenseBoundary(vnode, parentSuspense, parentComponent, container, hiddenContainer, anchor, namespace, slotScopeIds, optimized, rendererInternals);
|
|
patch(null, suspense.pendingBranch = vnode.ssContent, hiddenContainer, null, parentComponent, suspense, namespace, slotScopeIds);
|
|
if (suspense.deps > 0) {
|
|
triggerEvent(vnode, "onPending");
|
|
triggerEvent(vnode, "onFallback");
|
|
patch(null, vnode.ssFallback, container, anchor, parentComponent, null,
|
|
// fallback tree will not have suspense context
|
|
namespace, slotScopeIds);
|
|
setActiveBranch(suspense, vnode.ssFallback);
|
|
} else {
|
|
suspense.resolve(false, true);
|
|
}
|
|
}
|
|
function patchSuspense(n1, n2, container, anchor, parentComponent, namespace, slotScopeIds, optimized, {
|
|
p: patch,
|
|
um: unmount,
|
|
o: {
|
|
createElement
|
|
}
|
|
}) {
|
|
const suspense = n2.suspense = n1.suspense;
|
|
suspense.vnode = n2;
|
|
n2.el = n1.el;
|
|
const newBranch = n2.ssContent;
|
|
const newFallback = n2.ssFallback;
|
|
const {
|
|
activeBranch,
|
|
pendingBranch,
|
|
isInFallback,
|
|
isHydrating
|
|
} = suspense;
|
|
if (pendingBranch) {
|
|
suspense.pendingBranch = newBranch;
|
|
if (isSameVNodeType(newBranch, pendingBranch)) {
|
|
patch(pendingBranch, newBranch, suspense.hiddenContainer, null, parentComponent, suspense, namespace, slotScopeIds, optimized);
|
|
if (suspense.deps <= 0) {
|
|
suspense.resolve();
|
|
} else if (isInFallback) {
|
|
if (!isHydrating) {
|
|
patch(activeBranch, newFallback, container, anchor, parentComponent, null,
|
|
// fallback tree will not have suspense context
|
|
namespace, slotScopeIds, optimized);
|
|
setActiveBranch(suspense, newFallback);
|
|
}
|
|
}
|
|
} else {
|
|
suspense.pendingId = suspenseId++;
|
|
if (isHydrating) {
|
|
suspense.isHydrating = false;
|
|
suspense.activeBranch = pendingBranch;
|
|
} else {
|
|
unmount(pendingBranch, parentComponent, suspense);
|
|
}
|
|
suspense.deps = 0;
|
|
suspense.effects.length = 0;
|
|
suspense.hiddenContainer = createElement("div");
|
|
if (isInFallback) {
|
|
patch(null, newBranch, suspense.hiddenContainer, null, parentComponent, suspense, namespace, slotScopeIds, optimized);
|
|
if (suspense.deps <= 0) {
|
|
suspense.resolve();
|
|
} else {
|
|
patch(activeBranch, newFallback, container, anchor, parentComponent, null,
|
|
// fallback tree will not have suspense context
|
|
namespace, slotScopeIds, optimized);
|
|
setActiveBranch(suspense, newFallback);
|
|
}
|
|
} else if (activeBranch && isSameVNodeType(newBranch, activeBranch)) {
|
|
patch(activeBranch, newBranch, container, anchor, parentComponent, suspense, namespace, slotScopeIds, optimized);
|
|
suspense.resolve(true);
|
|
} else {
|
|
patch(null, newBranch, suspense.hiddenContainer, null, parentComponent, suspense, namespace, slotScopeIds, optimized);
|
|
if (suspense.deps <= 0) {
|
|
suspense.resolve();
|
|
}
|
|
}
|
|
}
|
|
} else {
|
|
if (activeBranch && isSameVNodeType(newBranch, activeBranch)) {
|
|
patch(activeBranch, newBranch, container, anchor, parentComponent, suspense, namespace, slotScopeIds, optimized);
|
|
setActiveBranch(suspense, newBranch);
|
|
} else {
|
|
triggerEvent(n2, "onPending");
|
|
suspense.pendingBranch = newBranch;
|
|
if (newBranch.shapeFlag & 512) {
|
|
suspense.pendingId = newBranch.component.suspenseId;
|
|
} else {
|
|
suspense.pendingId = suspenseId++;
|
|
}
|
|
patch(null, newBranch, suspense.hiddenContainer, null, parentComponent, suspense, namespace, slotScopeIds, optimized);
|
|
if (suspense.deps <= 0) {
|
|
suspense.resolve();
|
|
} else {
|
|
const {
|
|
timeout,
|
|
pendingId
|
|
} = suspense;
|
|
if (timeout > 0) {
|
|
setTimeout(() => {
|
|
if (suspense.pendingId === pendingId) {
|
|
suspense.fallback(newFallback);
|
|
}
|
|
}, timeout);
|
|
} else if (timeout === 0) {
|
|
suspense.fallback(newFallback);
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
let hasWarned = false;
|
|
function createSuspenseBoundary(vnode, parentSuspense, parentComponent, container, hiddenContainer, anchor, namespace, slotScopeIds, optimized, rendererInternals, isHydrating = false) {
|
|
if (false) {}
|
|
const {
|
|
p: patch,
|
|
m: move,
|
|
um: unmount,
|
|
n: next,
|
|
o: {
|
|
parentNode,
|
|
remove
|
|
}
|
|
} = rendererInternals;
|
|
let parentSuspenseId;
|
|
const isSuspensible = isVNodeSuspensible(vnode);
|
|
if (isSuspensible) {
|
|
if (parentSuspense && parentSuspense.pendingBranch) {
|
|
parentSuspenseId = parentSuspense.pendingId;
|
|
parentSuspense.deps++;
|
|
}
|
|
}
|
|
const timeout = vnode.props ? (0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .toNumber */ .Ro)(vnode.props.timeout) : void 0;
|
|
if (false) {}
|
|
const initialAnchor = anchor;
|
|
const suspense = {
|
|
vnode,
|
|
parent: parentSuspense,
|
|
parentComponent,
|
|
namespace,
|
|
container,
|
|
hiddenContainer,
|
|
deps: 0,
|
|
pendingId: suspenseId++,
|
|
timeout: typeof timeout === "number" ? timeout : -1,
|
|
activeBranch: null,
|
|
pendingBranch: null,
|
|
isInFallback: !isHydrating,
|
|
isHydrating,
|
|
isUnmounted: false,
|
|
effects: [],
|
|
resolve(resume = false, sync = false) {
|
|
if (false) {}
|
|
const {
|
|
vnode: vnode2,
|
|
activeBranch,
|
|
pendingBranch,
|
|
pendingId,
|
|
effects,
|
|
parentComponent: parentComponent2,
|
|
container: container2
|
|
} = suspense;
|
|
let delayEnter = false;
|
|
if (suspense.isHydrating) {
|
|
suspense.isHydrating = false;
|
|
} else if (!resume) {
|
|
delayEnter = activeBranch && pendingBranch.transition && pendingBranch.transition.mode === "out-in";
|
|
if (delayEnter) {
|
|
activeBranch.transition.afterLeave = () => {
|
|
if (pendingId === suspense.pendingId) {
|
|
move(pendingBranch, container2, anchor === initialAnchor ? next(activeBranch) : anchor, 0);
|
|
queuePostFlushCb(effects);
|
|
}
|
|
};
|
|
}
|
|
if (activeBranch) {
|
|
if (parentNode(activeBranch.el) === container2) {
|
|
anchor = next(activeBranch);
|
|
}
|
|
unmount(activeBranch, parentComponent2, suspense, true);
|
|
}
|
|
if (!delayEnter) {
|
|
move(pendingBranch, container2, anchor, 0);
|
|
}
|
|
}
|
|
setActiveBranch(suspense, pendingBranch);
|
|
suspense.pendingBranch = null;
|
|
suspense.isInFallback = false;
|
|
let parent = suspense.parent;
|
|
let hasUnresolvedAncestor = false;
|
|
while (parent) {
|
|
if (parent.pendingBranch) {
|
|
parent.effects.push(...effects);
|
|
hasUnresolvedAncestor = true;
|
|
break;
|
|
}
|
|
parent = parent.parent;
|
|
}
|
|
if (!hasUnresolvedAncestor && !delayEnter) {
|
|
queuePostFlushCb(effects);
|
|
}
|
|
suspense.effects = [];
|
|
if (isSuspensible) {
|
|
if (parentSuspense && parentSuspense.pendingBranch && parentSuspenseId === parentSuspense.pendingId) {
|
|
parentSuspense.deps--;
|
|
if (parentSuspense.deps === 0 && !sync) {
|
|
parentSuspense.resolve();
|
|
}
|
|
}
|
|
}
|
|
triggerEvent(vnode2, "onResolve");
|
|
},
|
|
fallback(fallbackVNode) {
|
|
if (!suspense.pendingBranch) {
|
|
return;
|
|
}
|
|
const {
|
|
vnode: vnode2,
|
|
activeBranch,
|
|
parentComponent: parentComponent2,
|
|
container: container2,
|
|
namespace: namespace2
|
|
} = suspense;
|
|
triggerEvent(vnode2, "onFallback");
|
|
const anchor2 = next(activeBranch);
|
|
const mountFallback = () => {
|
|
if (!suspense.isInFallback) {
|
|
return;
|
|
}
|
|
patch(null, fallbackVNode, container2, anchor2, parentComponent2, null,
|
|
// fallback tree will not have suspense context
|
|
namespace2, slotScopeIds, optimized);
|
|
setActiveBranch(suspense, fallbackVNode);
|
|
};
|
|
const delayEnter = fallbackVNode.transition && fallbackVNode.transition.mode === "out-in";
|
|
if (delayEnter) {
|
|
activeBranch.transition.afterLeave = mountFallback;
|
|
}
|
|
suspense.isInFallback = true;
|
|
unmount(activeBranch, parentComponent2, null,
|
|
// no suspense so unmount hooks fire now
|
|
true
|
|
// shouldRemove
|
|
);
|
|
if (!delayEnter) {
|
|
mountFallback();
|
|
}
|
|
},
|
|
move(container2, anchor2, type) {
|
|
suspense.activeBranch && move(suspense.activeBranch, container2, anchor2, type);
|
|
suspense.container = container2;
|
|
},
|
|
next() {
|
|
return suspense.activeBranch && next(suspense.activeBranch);
|
|
},
|
|
registerDep(instance, setupRenderEffect, optimized2) {
|
|
const isInPendingSuspense = !!suspense.pendingBranch;
|
|
if (isInPendingSuspense) {
|
|
suspense.deps++;
|
|
}
|
|
const hydratedEl = instance.vnode.el;
|
|
instance.asyncDep.catch(err => {
|
|
handleError(err, instance, 0);
|
|
}).then(asyncSetupResult => {
|
|
if (instance.isUnmounted || suspense.isUnmounted || suspense.pendingId !== instance.suspenseId) {
|
|
return;
|
|
}
|
|
instance.asyncResolved = true;
|
|
const {
|
|
vnode: vnode2
|
|
} = instance;
|
|
if (false) {}
|
|
handleSetupResult(instance, asyncSetupResult, false);
|
|
if (hydratedEl) {
|
|
vnode2.el = hydratedEl;
|
|
}
|
|
const placeholder = !hydratedEl && instance.subTree.el;
|
|
setupRenderEffect(instance, vnode2,
|
|
// component may have been moved before resolve.
|
|
// if this is not a hydration, instance.subTree will be the comment
|
|
// placeholder.
|
|
parentNode(hydratedEl || instance.subTree.el),
|
|
// anchor will not be used if this is hydration, so only need to
|
|
// consider the comment placeholder case.
|
|
hydratedEl ? null : next(instance.subTree), suspense, namespace, optimized2);
|
|
if (placeholder) {
|
|
remove(placeholder);
|
|
}
|
|
updateHOCHostEl(instance, vnode2.el);
|
|
if (false) {}
|
|
if (isInPendingSuspense && --suspense.deps === 0) {
|
|
suspense.resolve();
|
|
}
|
|
});
|
|
},
|
|
unmount(parentSuspense2, doRemove) {
|
|
suspense.isUnmounted = true;
|
|
if (suspense.activeBranch) {
|
|
unmount(suspense.activeBranch, parentComponent, parentSuspense2, doRemove);
|
|
}
|
|
if (suspense.pendingBranch) {
|
|
unmount(suspense.pendingBranch, parentComponent, parentSuspense2, doRemove);
|
|
}
|
|
}
|
|
};
|
|
return suspense;
|
|
}
|
|
function hydrateSuspense(node, vnode, parentComponent, parentSuspense, namespace, slotScopeIds, optimized, rendererInternals, hydrateNode) {
|
|
const suspense = vnode.suspense = createSuspenseBoundary(vnode, parentSuspense, parentComponent, node.parentNode,
|
|
// eslint-disable-next-line no-restricted-globals
|
|
document.createElement("div"), null, namespace, slotScopeIds, optimized, rendererInternals, true);
|
|
const result = hydrateNode(node, suspense.pendingBranch = vnode.ssContent, parentComponent, suspense, slotScopeIds, optimized);
|
|
if (suspense.deps === 0) {
|
|
suspense.resolve(false, true);
|
|
}
|
|
return result;
|
|
}
|
|
function normalizeSuspenseChildren(vnode) {
|
|
const {
|
|
shapeFlag,
|
|
children
|
|
} = vnode;
|
|
const isSlotChildren = shapeFlag & 32;
|
|
vnode.ssContent = normalizeSuspenseSlot(isSlotChildren ? children.default : children);
|
|
vnode.ssFallback = isSlotChildren ? normalizeSuspenseSlot(children.fallback) : createVNode(Comment);
|
|
}
|
|
function normalizeSuspenseSlot(s) {
|
|
let block;
|
|
if ((0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .isFunction */ .Tn)(s)) {
|
|
const trackBlock = isBlockTreeEnabled && s._c;
|
|
if (trackBlock) {
|
|
s._d = false;
|
|
openBlock();
|
|
}
|
|
s = s();
|
|
if (trackBlock) {
|
|
s._d = true;
|
|
block = currentBlock;
|
|
closeBlock();
|
|
}
|
|
}
|
|
if ((0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .isArray */ .cy)(s)) {
|
|
const singleChild = filterSingleRoot(s);
|
|
if (false) {}
|
|
s = singleChild;
|
|
}
|
|
s = normalizeVNode(s);
|
|
if (block && !s.dynamicChildren) {
|
|
s.dynamicChildren = block.filter(c => c !== s);
|
|
}
|
|
return s;
|
|
}
|
|
function queueEffectWithSuspense(fn, suspense) {
|
|
if (suspense && suspense.pendingBranch) {
|
|
if ((0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .isArray */ .cy)(fn)) {
|
|
suspense.effects.push(...fn);
|
|
} else {
|
|
suspense.effects.push(fn);
|
|
}
|
|
} else {
|
|
queuePostFlushCb(fn);
|
|
}
|
|
}
|
|
function setActiveBranch(suspense, branch) {
|
|
suspense.activeBranch = branch;
|
|
const {
|
|
vnode,
|
|
parentComponent
|
|
} = suspense;
|
|
let el = branch.el;
|
|
while (!el && branch.component) {
|
|
branch = branch.component.subTree;
|
|
el = branch.el;
|
|
}
|
|
vnode.el = el;
|
|
if (parentComponent && parentComponent.subTree === vnode) {
|
|
parentComponent.vnode.el = el;
|
|
updateHOCHostEl(parentComponent, el);
|
|
}
|
|
}
|
|
function isVNodeSuspensible(vnode) {
|
|
const suspensible = vnode.props && vnode.props.suspensible;
|
|
return suspensible != null && suspensible !== false;
|
|
}
|
|
const Fragment = Symbol.for("v-fgt");
|
|
const Text = Symbol.for("v-txt");
|
|
const Comment = Symbol.for("v-cmt");
|
|
const Static = Symbol.for("v-stc");
|
|
const blockStack = [];
|
|
let currentBlock = null;
|
|
function openBlock(disableTracking = false) {
|
|
blockStack.push(currentBlock = disableTracking ? null : []);
|
|
}
|
|
function closeBlock() {
|
|
blockStack.pop();
|
|
currentBlock = blockStack[blockStack.length - 1] || null;
|
|
}
|
|
let isBlockTreeEnabled = 1;
|
|
function setBlockTracking(value, inVOnce = false) {
|
|
isBlockTreeEnabled += value;
|
|
if (value < 0 && currentBlock && inVOnce) {
|
|
currentBlock.hasOnce = true;
|
|
}
|
|
}
|
|
function setupBlock(vnode) {
|
|
vnode.dynamicChildren = isBlockTreeEnabled > 0 ? currentBlock || _vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .EMPTY_ARR */ .Oj : null;
|
|
closeBlock();
|
|
if (isBlockTreeEnabled > 0 && currentBlock) {
|
|
currentBlock.push(vnode);
|
|
}
|
|
return vnode;
|
|
}
|
|
function createElementBlock(type, props, children, patchFlag, dynamicProps, shapeFlag) {
|
|
return setupBlock(createBaseVNode(type, props, children, patchFlag, dynamicProps, shapeFlag, true));
|
|
}
|
|
function createBlock(type, props, children, patchFlag, dynamicProps) {
|
|
return setupBlock(createVNode(type, props, children, patchFlag, dynamicProps, true));
|
|
}
|
|
function isVNode(value) {
|
|
return value ? value.__v_isVNode === true : false;
|
|
}
|
|
function isSameVNodeType(n1, n2) {
|
|
if (false) {}
|
|
return n1.type === n2.type && n1.key === n2.key;
|
|
}
|
|
let vnodeArgsTransformer;
|
|
function transformVNodeArgs(transformer) {
|
|
vnodeArgsTransformer = transformer;
|
|
}
|
|
const createVNodeWithArgsTransform = (...args) => {
|
|
return _createVNode(...(vnodeArgsTransformer ? vnodeArgsTransformer(args, currentRenderingInstance) : args));
|
|
};
|
|
const normalizeKey = ({
|
|
key
|
|
}) => key != null ? key : null;
|
|
const normalizeRef = ({
|
|
ref,
|
|
ref_key,
|
|
ref_for
|
|
}) => {
|
|
if (typeof ref === "number") {
|
|
ref = "" + ref;
|
|
}
|
|
return ref != null ? (0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .isString */ .Kg)(ref) || (0,_vue_reactivity__WEBPACK_IMPORTED_MODULE_17__/* .isRef */ .i9)(ref) || (0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .isFunction */ .Tn)(ref) ? {
|
|
i: currentRenderingInstance,
|
|
r: ref,
|
|
k: ref_key,
|
|
f: !!ref_for
|
|
} : ref : null;
|
|
};
|
|
function createBaseVNode(type, props = null, children = null, patchFlag = 0, dynamicProps = null, shapeFlag = type === Fragment ? 0 : 1, isBlockNode = false, needFullChildrenNormalization = false) {
|
|
const vnode = {
|
|
__v_isVNode: true,
|
|
__v_skip: true,
|
|
type,
|
|
props,
|
|
key: props && normalizeKey(props),
|
|
ref: props && normalizeRef(props),
|
|
scopeId: currentScopeId,
|
|
slotScopeIds: null,
|
|
children,
|
|
component: null,
|
|
suspense: null,
|
|
ssContent: null,
|
|
ssFallback: null,
|
|
dirs: null,
|
|
transition: null,
|
|
el: null,
|
|
anchor: null,
|
|
target: null,
|
|
targetStart: null,
|
|
targetAnchor: null,
|
|
staticCount: 0,
|
|
shapeFlag,
|
|
patchFlag,
|
|
dynamicProps,
|
|
dynamicChildren: null,
|
|
appContext: null,
|
|
ctx: currentRenderingInstance
|
|
};
|
|
if (needFullChildrenNormalization) {
|
|
normalizeChildren(vnode, children);
|
|
if (shapeFlag & 128) {
|
|
type.normalize(vnode);
|
|
}
|
|
} else if (children) {
|
|
vnode.shapeFlag |= (0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .isString */ .Kg)(children) ? 8 : 16;
|
|
}
|
|
if (false) {}
|
|
if (isBlockTreeEnabled > 0 &&
|
|
// avoid a block node from tracking itself
|
|
!isBlockNode &&
|
|
// has current parent block
|
|
currentBlock && (
|
|
// presence of a patch flag indicates this node needs patching on updates.
|
|
// component nodes also should always be patched, because even if the
|
|
// component doesn't need to update, it needs to persist the instance on to
|
|
// the next vnode so that it can be properly unmounted later.
|
|
vnode.patchFlag > 0 || shapeFlag & 6) &&
|
|
// the EVENTS flag is only for hydration and if it is the only flag, the
|
|
// vnode should not be considered dynamic due to handler caching.
|
|
vnode.patchFlag !== 32) {
|
|
currentBlock.push(vnode);
|
|
}
|
|
return vnode;
|
|
}
|
|
const createVNode = false ? 0 : _createVNode;
|
|
function _createVNode(type, props = null, children = null, patchFlag = 0, dynamicProps = null, isBlockNode = false) {
|
|
if (!type || type === NULL_DYNAMIC_COMPONENT) {
|
|
if (false) {}
|
|
type = Comment;
|
|
}
|
|
if (isVNode(type)) {
|
|
const cloned = cloneVNode(type, props, true
|
|
/* mergeRef: true */);
|
|
if (children) {
|
|
normalizeChildren(cloned, children);
|
|
}
|
|
if (isBlockTreeEnabled > 0 && !isBlockNode && currentBlock) {
|
|
if (cloned.shapeFlag & 6) {
|
|
currentBlock[currentBlock.indexOf(type)] = cloned;
|
|
} else {
|
|
currentBlock.push(cloned);
|
|
}
|
|
}
|
|
cloned.patchFlag = -2;
|
|
return cloned;
|
|
}
|
|
if (isClassComponent(type)) {
|
|
type = type.__vccOpts;
|
|
}
|
|
if (props) {
|
|
props = guardReactiveProps(props);
|
|
let {
|
|
class: klass,
|
|
style
|
|
} = props;
|
|
if (klass && !(0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .isString */ .Kg)(klass)) {
|
|
props.class = (0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .normalizeClass */ .C4)(klass);
|
|
}
|
|
if ((0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .isObject */ .Gv)(style)) {
|
|
if ((0,_vue_reactivity__WEBPACK_IMPORTED_MODULE_17__/* .isProxy */ .ju)(style) && !(0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .isArray */ .cy)(style)) {
|
|
style = (0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .extend */ .X$)({}, style);
|
|
}
|
|
props.style = (0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .normalizeStyle */ .Tr)(style);
|
|
}
|
|
}
|
|
const shapeFlag = (0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .isString */ .Kg)(type) ? 1 : isSuspense(type) ? 128 : isTeleport(type) ? 64 : (0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .isObject */ .Gv)(type) ? 4 : (0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .isFunction */ .Tn)(type) ? 2 : 0;
|
|
if (false) {}
|
|
return createBaseVNode(type, props, children, patchFlag, dynamicProps, shapeFlag, isBlockNode, true);
|
|
}
|
|
function guardReactiveProps(props) {
|
|
if (!props) return null;
|
|
return (0,_vue_reactivity__WEBPACK_IMPORTED_MODULE_17__/* .isProxy */ .ju)(props) || isInternalObject(props) ? (0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .extend */ .X$)({}, props) : props;
|
|
}
|
|
function cloneVNode(vnode, extraProps, mergeRef = false, cloneTransition = false) {
|
|
const {
|
|
props,
|
|
ref,
|
|
patchFlag,
|
|
children,
|
|
transition
|
|
} = vnode;
|
|
const mergedProps = extraProps ? mergeProps(props || {}, extraProps) : props;
|
|
const cloned = {
|
|
__v_isVNode: true,
|
|
__v_skip: true,
|
|
type: vnode.type,
|
|
props: mergedProps,
|
|
key: mergedProps && normalizeKey(mergedProps),
|
|
ref: extraProps && extraProps.ref ?
|
|
// #2078 in the case of <component :is="vnode" ref="extra"/>
|
|
// if the vnode itself already has a ref, cloneVNode will need to merge
|
|
// the refs so the single vnode can be set on multiple refs
|
|
mergeRef && ref ? (0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .isArray */ .cy)(ref) ? ref.concat(normalizeRef(extraProps)) : [ref, normalizeRef(extraProps)] : normalizeRef(extraProps) : ref,
|
|
scopeId: vnode.scopeId,
|
|
slotScopeIds: vnode.slotScopeIds,
|
|
children: false ? 0 : children,
|
|
target: vnode.target,
|
|
targetStart: vnode.targetStart,
|
|
targetAnchor: vnode.targetAnchor,
|
|
staticCount: vnode.staticCount,
|
|
shapeFlag: vnode.shapeFlag,
|
|
// if the vnode is cloned with extra props, we can no longer assume its
|
|
// existing patch flag to be reliable and need to add the FULL_PROPS flag.
|
|
// note: preserve flag for fragments since they use the flag for children
|
|
// fast paths only.
|
|
patchFlag: extraProps && vnode.type !== Fragment ? patchFlag === -1 ? 16 : patchFlag | 16 : patchFlag,
|
|
dynamicProps: vnode.dynamicProps,
|
|
dynamicChildren: vnode.dynamicChildren,
|
|
appContext: vnode.appContext,
|
|
dirs: vnode.dirs,
|
|
transition,
|
|
// These should technically only be non-null on mounted VNodes. However,
|
|
// they *should* be copied for kept-alive vnodes. So we just always copy
|
|
// them since them being non-null during a mount doesn't affect the logic as
|
|
// they will simply be overwritten.
|
|
component: vnode.component,
|
|
suspense: vnode.suspense,
|
|
ssContent: vnode.ssContent && cloneVNode(vnode.ssContent),
|
|
ssFallback: vnode.ssFallback && cloneVNode(vnode.ssFallback),
|
|
el: vnode.el,
|
|
anchor: vnode.anchor,
|
|
ctx: vnode.ctx,
|
|
ce: vnode.ce
|
|
};
|
|
if (transition && cloneTransition) {
|
|
setTransitionHooks(cloned, transition.clone(cloned));
|
|
}
|
|
return cloned;
|
|
}
|
|
function deepCloneVNode(vnode) {
|
|
const cloned = cloneVNode(vnode);
|
|
if (isArray(vnode.children)) {
|
|
cloned.children = vnode.children.map(deepCloneVNode);
|
|
}
|
|
return cloned;
|
|
}
|
|
function createTextVNode(text = " ", flag = 0) {
|
|
return createVNode(Text, null, text, flag);
|
|
}
|
|
function createStaticVNode(content, numberOfNodes) {
|
|
const vnode = createVNode(Static, null, content);
|
|
vnode.staticCount = numberOfNodes;
|
|
return vnode;
|
|
}
|
|
function createCommentVNode(text = "", asBlock = false) {
|
|
return asBlock ? (openBlock(), createBlock(Comment, null, text)) : createVNode(Comment, null, text);
|
|
}
|
|
function normalizeVNode(child) {
|
|
if (child == null || typeof child === "boolean") {
|
|
return createVNode(Comment);
|
|
} else if ((0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .isArray */ .cy)(child)) {
|
|
return createVNode(Fragment, null,
|
|
// #3666, avoid reference pollution when reusing vnode
|
|
child.slice());
|
|
} else if (isVNode(child)) {
|
|
return cloneIfMounted(child);
|
|
} else {
|
|
return createVNode(Text, null, String(child));
|
|
}
|
|
}
|
|
function cloneIfMounted(child) {
|
|
return child.el === null && child.patchFlag !== -1 || child.memo ? child : cloneVNode(child);
|
|
}
|
|
function normalizeChildren(vnode, children) {
|
|
let type = 0;
|
|
const {
|
|
shapeFlag
|
|
} = vnode;
|
|
if (children == null) {
|
|
children = null;
|
|
} else if ((0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .isArray */ .cy)(children)) {
|
|
type = 16;
|
|
} else if (typeof children === "object") {
|
|
if (shapeFlag & (1 | 64)) {
|
|
const slot = children.default;
|
|
if (slot) {
|
|
slot._c && (slot._d = false);
|
|
normalizeChildren(vnode, slot());
|
|
slot._c && (slot._d = true);
|
|
}
|
|
return;
|
|
} else {
|
|
type = 32;
|
|
const slotFlag = children._;
|
|
if (!slotFlag && !isInternalObject(children)) {
|
|
children._ctx = currentRenderingInstance;
|
|
} else if (slotFlag === 3 && currentRenderingInstance) {
|
|
if (currentRenderingInstance.slots._ === 1) {
|
|
children._ = 1;
|
|
} else {
|
|
children._ = 2;
|
|
vnode.patchFlag |= 1024;
|
|
}
|
|
}
|
|
}
|
|
} else if ((0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .isFunction */ .Tn)(children)) {
|
|
children = {
|
|
default: children,
|
|
_ctx: currentRenderingInstance
|
|
};
|
|
type = 32;
|
|
} else {
|
|
children = String(children);
|
|
if (shapeFlag & 64) {
|
|
type = 16;
|
|
children = [createTextVNode(children)];
|
|
} else {
|
|
type = 8;
|
|
}
|
|
}
|
|
vnode.children = children;
|
|
vnode.shapeFlag |= type;
|
|
}
|
|
function mergeProps(...args) {
|
|
const ret = {};
|
|
for (let i = 0; i < args.length; i++) {
|
|
const toMerge = args[i];
|
|
for (const key in toMerge) {
|
|
if (key === "class") {
|
|
if (ret.class !== toMerge.class) {
|
|
ret.class = (0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .normalizeClass */ .C4)([ret.class, toMerge.class]);
|
|
}
|
|
} else if (key === "style") {
|
|
ret.style = (0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .normalizeStyle */ .Tr)([ret.style, toMerge.style]);
|
|
} else if ((0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .isOn */ .Mp)(key)) {
|
|
const existing = ret[key];
|
|
const incoming = toMerge[key];
|
|
if (incoming && existing !== incoming && !((0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .isArray */ .cy)(existing) && existing.includes(incoming))) {
|
|
ret[key] = existing ? [].concat(existing, incoming) : incoming;
|
|
}
|
|
} else if (key !== "") {
|
|
ret[key] = toMerge[key];
|
|
}
|
|
}
|
|
}
|
|
return ret;
|
|
}
|
|
function invokeVNodeHook(hook, instance, vnode, prevVNode = null) {
|
|
callWithAsyncErrorHandling(hook, instance, 7, [vnode, prevVNode]);
|
|
}
|
|
const emptyAppContext = createAppContext();
|
|
let uid = 0;
|
|
function createComponentInstance(vnode, parent, suspense) {
|
|
const type = vnode.type;
|
|
const appContext = (parent ? parent.appContext : vnode.appContext) || emptyAppContext;
|
|
const instance = {
|
|
uid: uid++,
|
|
vnode,
|
|
type,
|
|
parent,
|
|
appContext,
|
|
root: null,
|
|
// to be immediately set
|
|
next: null,
|
|
subTree: null,
|
|
// will be set synchronously right after creation
|
|
effect: null,
|
|
update: null,
|
|
// will be set synchronously right after creation
|
|
job: null,
|
|
scope: new _vue_reactivity__WEBPACK_IMPORTED_MODULE_17__/* .EffectScope */ .yC(true
|
|
/* detached */),
|
|
render: null,
|
|
proxy: null,
|
|
exposed: null,
|
|
exposeProxy: null,
|
|
withProxy: null,
|
|
provides: parent ? parent.provides : Object.create(appContext.provides),
|
|
ids: parent ? parent.ids : ["", 0, 0],
|
|
accessCache: null,
|
|
renderCache: [],
|
|
// local resolved assets
|
|
components: null,
|
|
directives: null,
|
|
// resolved props and emits options
|
|
propsOptions: normalizePropsOptions(type, appContext),
|
|
emitsOptions: normalizeEmitsOptions(type, appContext),
|
|
// emit
|
|
emit: null,
|
|
// to be set immediately
|
|
emitted: null,
|
|
// props default value
|
|
propsDefaults: _vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .EMPTY_OBJ */ .MZ,
|
|
// inheritAttrs
|
|
inheritAttrs: type.inheritAttrs,
|
|
// state
|
|
ctx: _vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .EMPTY_OBJ */ .MZ,
|
|
data: _vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .EMPTY_OBJ */ .MZ,
|
|
props: _vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .EMPTY_OBJ */ .MZ,
|
|
attrs: _vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .EMPTY_OBJ */ .MZ,
|
|
slots: _vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .EMPTY_OBJ */ .MZ,
|
|
refs: _vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .EMPTY_OBJ */ .MZ,
|
|
setupState: _vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .EMPTY_OBJ */ .MZ,
|
|
setupContext: null,
|
|
// suspense related
|
|
suspense,
|
|
suspenseId: suspense ? suspense.pendingId : 0,
|
|
asyncDep: null,
|
|
asyncResolved: false,
|
|
// lifecycle hooks
|
|
// not using enums here because it results in computed properties
|
|
isMounted: false,
|
|
isUnmounted: false,
|
|
isDeactivated: false,
|
|
bc: null,
|
|
c: null,
|
|
bm: null,
|
|
m: null,
|
|
bu: null,
|
|
u: null,
|
|
um: null,
|
|
bum: null,
|
|
da: null,
|
|
a: null,
|
|
rtg: null,
|
|
rtc: null,
|
|
ec: null,
|
|
sp: null
|
|
};
|
|
if (false) {} else {
|
|
instance.ctx = {
|
|
_: instance
|
|
};
|
|
}
|
|
instance.root = parent ? parent.root : instance;
|
|
instance.emit = emit.bind(null, instance);
|
|
if (vnode.ce) {
|
|
vnode.ce(instance);
|
|
}
|
|
return instance;
|
|
}
|
|
let currentInstance = null;
|
|
const getCurrentInstance = () => currentInstance || currentRenderingInstance;
|
|
let internalSetCurrentInstance;
|
|
let setInSSRSetupState;
|
|
{
|
|
const g = (0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .getGlobalThis */ .We)();
|
|
const registerGlobalSetter = (key, setter) => {
|
|
let setters;
|
|
if (!(setters = g[key])) setters = g[key] = [];
|
|
setters.push(setter);
|
|
return v => {
|
|
if (setters.length > 1) setters.forEach(set => set(v));else setters[0](v);
|
|
};
|
|
};
|
|
internalSetCurrentInstance = registerGlobalSetter(`__VUE_INSTANCE_SETTERS__`, v => currentInstance = v);
|
|
setInSSRSetupState = registerGlobalSetter(`__VUE_SSR_SETTERS__`, v => isInSSRComponentSetup = v);
|
|
}
|
|
const setCurrentInstance = instance => {
|
|
const prev = currentInstance;
|
|
internalSetCurrentInstance(instance);
|
|
instance.scope.on();
|
|
return () => {
|
|
instance.scope.off();
|
|
internalSetCurrentInstance(prev);
|
|
};
|
|
};
|
|
const unsetCurrentInstance = () => {
|
|
currentInstance && currentInstance.scope.off();
|
|
internalSetCurrentInstance(null);
|
|
};
|
|
const isBuiltInTag = /* @__PURE__ */(/* unused pure expression or super */ null && (makeMap("slot,component")));
|
|
function validateComponentName(name, {
|
|
isNativeTag
|
|
}) {
|
|
if (isBuiltInTag(name) || isNativeTag(name)) {
|
|
warn$1("Do not use built-in or reserved HTML elements as component id: " + name);
|
|
}
|
|
}
|
|
function isStatefulComponent(instance) {
|
|
return instance.vnode.shapeFlag & 4;
|
|
}
|
|
let isInSSRComponentSetup = false;
|
|
function setupComponent(instance, isSSR = false, optimized = false) {
|
|
isSSR && setInSSRSetupState(isSSR);
|
|
const {
|
|
props,
|
|
children
|
|
} = instance.vnode;
|
|
const isStateful = isStatefulComponent(instance);
|
|
initProps(instance, props, isStateful, isSSR);
|
|
initSlots(instance, children, optimized);
|
|
const setupResult = isStateful ? setupStatefulComponent(instance, isSSR) : void 0;
|
|
isSSR && setInSSRSetupState(false);
|
|
return setupResult;
|
|
}
|
|
function setupStatefulComponent(instance, isSSR) {
|
|
var _a;
|
|
const Component = instance.type;
|
|
if (false) {}
|
|
instance.accessCache = /* @__PURE__ */Object.create(null);
|
|
instance.proxy = new Proxy(instance.ctx, PublicInstanceProxyHandlers);
|
|
if (false) {}
|
|
const {
|
|
setup
|
|
} = Component;
|
|
if (setup) {
|
|
(0,_vue_reactivity__WEBPACK_IMPORTED_MODULE_17__/* .pauseTracking */ .C4)();
|
|
const setupContext = instance.setupContext = setup.length > 1 ? createSetupContext(instance) : null;
|
|
const reset = setCurrentInstance(instance);
|
|
const setupResult = callWithErrorHandling(setup, instance, 0, [ false ? 0 : instance.props, setupContext]);
|
|
const isAsyncSetup = (0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .isPromise */ .yL)(setupResult);
|
|
(0,_vue_reactivity__WEBPACK_IMPORTED_MODULE_17__/* .resetTracking */ .bl)();
|
|
reset();
|
|
if ((isAsyncSetup || instance.sp) && !isAsyncWrapper(instance)) {
|
|
markAsyncBoundary(instance);
|
|
}
|
|
if (isAsyncSetup) {
|
|
setupResult.then(unsetCurrentInstance, unsetCurrentInstance);
|
|
if (isSSR) {
|
|
return setupResult.then(resolvedResult => {
|
|
handleSetupResult(instance, resolvedResult, isSSR);
|
|
}).catch(e => {
|
|
handleError(e, instance, 0);
|
|
});
|
|
} else {
|
|
instance.asyncDep = setupResult;
|
|
if (false) {}
|
|
}
|
|
} else {
|
|
handleSetupResult(instance, setupResult, isSSR);
|
|
}
|
|
} else {
|
|
finishComponentSetup(instance, isSSR);
|
|
}
|
|
}
|
|
function handleSetupResult(instance, setupResult, isSSR) {
|
|
if ((0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .isFunction */ .Tn)(setupResult)) {
|
|
if (instance.type.__ssrInlineRender) {
|
|
instance.ssrRender = setupResult;
|
|
} else {
|
|
instance.render = setupResult;
|
|
}
|
|
} else if ((0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .isObject */ .Gv)(setupResult)) {
|
|
if (false) {}
|
|
if (false) {}
|
|
instance.setupState = (0,_vue_reactivity__WEBPACK_IMPORTED_MODULE_17__/* .proxyRefs */ .Pr)(setupResult);
|
|
if (false) {}
|
|
} else if (false) {}
|
|
finishComponentSetup(instance, isSSR);
|
|
}
|
|
let compile;
|
|
let installWithProxy;
|
|
function registerRuntimeCompiler(_compile) {
|
|
compile = _compile;
|
|
installWithProxy = i => {
|
|
if (i.render._rc) {
|
|
i.withProxy = new Proxy(i.ctx, RuntimeCompiledPublicInstanceProxyHandlers);
|
|
}
|
|
};
|
|
}
|
|
const isRuntimeOnly = () => !compile;
|
|
function finishComponentSetup(instance, isSSR, skipOptions) {
|
|
const Component = instance.type;
|
|
if (!instance.render) {
|
|
if (!isSSR && compile && !Component.render) {
|
|
const template = Component.template || true && resolveMergedOptions(instance).template;
|
|
if (template) {
|
|
if (false) {}
|
|
const {
|
|
isCustomElement,
|
|
compilerOptions
|
|
} = instance.appContext.config;
|
|
const {
|
|
delimiters,
|
|
compilerOptions: componentCompilerOptions
|
|
} = Component;
|
|
const finalCompilerOptions = (0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .extend */ .X$)((0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .extend */ .X$)({
|
|
isCustomElement,
|
|
delimiters
|
|
}, compilerOptions), componentCompilerOptions);
|
|
Component.render = compile(template, finalCompilerOptions);
|
|
if (false) {}
|
|
}
|
|
}
|
|
instance.render = Component.render || _vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .NOOP */ .tE;
|
|
if (installWithProxy) {
|
|
installWithProxy(instance);
|
|
}
|
|
}
|
|
if (true) {
|
|
const reset = setCurrentInstance(instance);
|
|
(0,_vue_reactivity__WEBPACK_IMPORTED_MODULE_17__/* .pauseTracking */ .C4)();
|
|
try {
|
|
applyOptions(instance);
|
|
} finally {
|
|
(0,_vue_reactivity__WEBPACK_IMPORTED_MODULE_17__/* .resetTracking */ .bl)();
|
|
reset();
|
|
}
|
|
}
|
|
if (false) {}
|
|
}
|
|
const attrsProxyHandlers = false ? 0 : {
|
|
get(target, key) {
|
|
(0,_vue_reactivity__WEBPACK_IMPORTED_MODULE_17__/* .track */ .u4)(target, "get", "");
|
|
return target[key];
|
|
}
|
|
};
|
|
function getSlotsProxy(instance) {
|
|
return new Proxy(instance.slots, {
|
|
get(target, key) {
|
|
track(instance, "get", "$slots");
|
|
return target[key];
|
|
}
|
|
});
|
|
}
|
|
function createSetupContext(instance) {
|
|
const expose = exposed => {
|
|
if (false) {}
|
|
instance.exposed = exposed || {};
|
|
};
|
|
if (false) {} else {
|
|
return {
|
|
attrs: new Proxy(instance.attrs, attrsProxyHandlers),
|
|
slots: instance.slots,
|
|
emit: instance.emit,
|
|
expose
|
|
};
|
|
}
|
|
}
|
|
function getComponentPublicInstance(instance) {
|
|
if (instance.exposed) {
|
|
return instance.exposeProxy || (instance.exposeProxy = new Proxy((0,_vue_reactivity__WEBPACK_IMPORTED_MODULE_17__/* .proxyRefs */ .Pr)((0,_vue_reactivity__WEBPACK_IMPORTED_MODULE_17__/* .markRaw */ .IG)(instance.exposed)), {
|
|
get(target, key) {
|
|
if (key in target) {
|
|
return target[key];
|
|
} else if (key in publicPropertiesMap) {
|
|
return publicPropertiesMap[key](instance);
|
|
}
|
|
},
|
|
has(target, key) {
|
|
return key in target || key in publicPropertiesMap;
|
|
}
|
|
}));
|
|
} else {
|
|
return instance.proxy;
|
|
}
|
|
}
|
|
const classifyRE = /(?:^|[-_])(\w)/g;
|
|
const classify = str => str.replace(classifyRE, c => c.toUpperCase()).replace(/[-_]/g, "");
|
|
function getComponentName(Component, includeInferred = true) {
|
|
return (0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .isFunction */ .Tn)(Component) ? Component.displayName || Component.name : Component.name || includeInferred && Component.__name;
|
|
}
|
|
function formatComponentName(instance, Component, isRoot = false) {
|
|
let name = getComponentName(Component);
|
|
if (!name && Component.__file) {
|
|
const match = Component.__file.match(/([^/\\]+)\.\w+$/);
|
|
if (match) {
|
|
name = match[1];
|
|
}
|
|
}
|
|
if (!name && instance && instance.parent) {
|
|
const inferFromRegistry = registry => {
|
|
for (const key in registry) {
|
|
if (registry[key] === Component) {
|
|
return key;
|
|
}
|
|
}
|
|
};
|
|
name = inferFromRegistry(instance.components || instance.parent.type.components) || inferFromRegistry(instance.appContext.components);
|
|
}
|
|
return name ? classify(name) : isRoot ? `App` : `Anonymous`;
|
|
}
|
|
function isClassComponent(value) {
|
|
return (0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .isFunction */ .Tn)(value) && "__vccOpts" in value;
|
|
}
|
|
const computed = (getterOrOptions, debugOptions) => {
|
|
const c = (0,_vue_reactivity__WEBPACK_IMPORTED_MODULE_17__/* .computed */ .EW)(getterOrOptions, debugOptions, isInSSRComponentSetup);
|
|
if (false) {}
|
|
return c;
|
|
};
|
|
function h(type, propsOrChildren, children) {
|
|
const l = arguments.length;
|
|
if (l === 2) {
|
|
if ((0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .isObject */ .Gv)(propsOrChildren) && !(0,_vue_shared__WEBPACK_IMPORTED_MODULE_16__/* .isArray */ .cy)(propsOrChildren)) {
|
|
if (isVNode(propsOrChildren)) {
|
|
return createVNode(type, null, [propsOrChildren]);
|
|
}
|
|
return createVNode(type, propsOrChildren);
|
|
} else {
|
|
return createVNode(type, null, propsOrChildren);
|
|
}
|
|
} else {
|
|
if (l > 3) {
|
|
children = Array.prototype.slice.call(arguments, 2);
|
|
} else if (l === 3 && isVNode(children)) {
|
|
children = [children];
|
|
}
|
|
return createVNode(type, propsOrChildren, children);
|
|
}
|
|
}
|
|
function initCustomFormatter() {
|
|
if (true) {
|
|
return;
|
|
}
|
|
const vueStyle = {
|
|
style: "color:#3ba776"
|
|
};
|
|
const numberStyle = {
|
|
style: "color:#1677ff"
|
|
};
|
|
const stringStyle = {
|
|
style: "color:#f5222d"
|
|
};
|
|
const keywordStyle = {
|
|
style: "color:#eb2f96"
|
|
};
|
|
const formatter = {
|
|
__vue_custom_formatter: true,
|
|
header(obj) {
|
|
if (!isObject(obj)) {
|
|
return null;
|
|
}
|
|
if (obj.__isVue) {
|
|
return ["div", vueStyle, `VueInstance`];
|
|
} else if (isRef(obj)) {
|
|
return ["div", {}, ["span", vueStyle, genRefFlag(obj)], "<",
|
|
// avoid debugger accessing value affecting behavior
|
|
formatValue("_value" in obj ? obj._value : obj), `>`];
|
|
} else if (isReactive(obj)) {
|
|
return ["div", {}, ["span", vueStyle, isShallow(obj) ? "ShallowReactive" : "Reactive"], "<", formatValue(obj), `>${isReadonly(obj) ? ` (readonly)` : ``}`];
|
|
} else if (isReadonly(obj)) {
|
|
return ["div", {}, ["span", vueStyle, isShallow(obj) ? "ShallowReadonly" : "Readonly"], "<", formatValue(obj), ">"];
|
|
}
|
|
return null;
|
|
},
|
|
hasBody(obj) {
|
|
return obj && obj.__isVue;
|
|
},
|
|
body(obj) {
|
|
if (obj && obj.__isVue) {
|
|
return ["div", {}, ...formatInstance(obj.$)];
|
|
}
|
|
}
|
|
};
|
|
function formatInstance(instance) {
|
|
const blocks = [];
|
|
if (instance.type.props && instance.props) {
|
|
blocks.push(createInstanceBlock("props", toRaw(instance.props)));
|
|
}
|
|
if (instance.setupState !== EMPTY_OBJ) {
|
|
blocks.push(createInstanceBlock("setup", instance.setupState));
|
|
}
|
|
if (instance.data !== EMPTY_OBJ) {
|
|
blocks.push(createInstanceBlock("data", toRaw(instance.data)));
|
|
}
|
|
const computed = extractKeys(instance, "computed");
|
|
if (computed) {
|
|
blocks.push(createInstanceBlock("computed", computed));
|
|
}
|
|
const injected = extractKeys(instance, "inject");
|
|
if (injected) {
|
|
blocks.push(createInstanceBlock("injected", injected));
|
|
}
|
|
blocks.push(["div", {}, ["span", {
|
|
style: keywordStyle.style + ";opacity:0.66"
|
|
}, "$ (internal): "], ["object", {
|
|
object: instance
|
|
}]]);
|
|
return blocks;
|
|
}
|
|
function createInstanceBlock(type, target) {
|
|
target = extend({}, target);
|
|
if (!Object.keys(target).length) {
|
|
return ["span", {}];
|
|
}
|
|
return ["div", {
|
|
style: "line-height:1.25em;margin-bottom:0.6em"
|
|
}, ["div", {
|
|
style: "color:#476582"
|
|
}, type], ["div", {
|
|
style: "padding-left:1.25em"
|
|
}, ...Object.keys(target).map(key => {
|
|
return ["div", {}, ["span", keywordStyle, key + ": "], formatValue(target[key], false)];
|
|
})]];
|
|
}
|
|
function formatValue(v, asRaw = true) {
|
|
if (typeof v === "number") {
|
|
return ["span", numberStyle, v];
|
|
} else if (typeof v === "string") {
|
|
return ["span", stringStyle, JSON.stringify(v)];
|
|
} else if (typeof v === "boolean") {
|
|
return ["span", keywordStyle, v];
|
|
} else if (isObject(v)) {
|
|
return ["object", {
|
|
object: asRaw ? toRaw(v) : v
|
|
}];
|
|
} else {
|
|
return ["span", stringStyle, String(v)];
|
|
}
|
|
}
|
|
function extractKeys(instance, type) {
|
|
const Comp = instance.type;
|
|
if (isFunction(Comp)) {
|
|
return;
|
|
}
|
|
const extracted = {};
|
|
for (const key in instance.ctx) {
|
|
if (isKeyOfType(Comp, key, type)) {
|
|
extracted[key] = instance.ctx[key];
|
|
}
|
|
}
|
|
return extracted;
|
|
}
|
|
function isKeyOfType(Comp, key, type) {
|
|
const opts = Comp[type];
|
|
if (isArray(opts) && opts.includes(key) || isObject(opts) && key in opts) {
|
|
return true;
|
|
}
|
|
if (Comp.extends && isKeyOfType(Comp.extends, key, type)) {
|
|
return true;
|
|
}
|
|
if (Comp.mixins && Comp.mixins.some(m => isKeyOfType(m, key, type))) {
|
|
return true;
|
|
}
|
|
}
|
|
function genRefFlag(v) {
|
|
if (isShallow(v)) {
|
|
return `ShallowRef`;
|
|
}
|
|
if (v.effect) {
|
|
return `ComputedRef`;
|
|
}
|
|
return `Ref`;
|
|
}
|
|
if (window.devtoolsFormatters) {
|
|
window.devtoolsFormatters.push(formatter);
|
|
} else {
|
|
window.devtoolsFormatters = [formatter];
|
|
}
|
|
}
|
|
function withMemo(memo, render, cache, index) {
|
|
const cached = cache[index];
|
|
if (cached && isMemoSame(cached, memo)) {
|
|
return cached;
|
|
}
|
|
const ret = render();
|
|
ret.memo = memo.slice();
|
|
ret.cacheIndex = index;
|
|
return cache[index] = ret;
|
|
}
|
|
function isMemoSame(cached, memo) {
|
|
const prev = cached.memo;
|
|
if (prev.length != memo.length) {
|
|
return false;
|
|
}
|
|
for (let i = 0; i < prev.length; i++) {
|
|
if (hasChanged(prev[i], memo[i])) {
|
|
return false;
|
|
}
|
|
}
|
|
if (isBlockTreeEnabled > 0 && currentBlock) {
|
|
currentBlock.push(cached);
|
|
}
|
|
return true;
|
|
}
|
|
const version = "3.5.13";
|
|
const warn = (/* unused pure expression or super */ null && ( false ? 0 : NOOP));
|
|
const ErrorTypeStrings = (/* unused pure expression or super */ null && (ErrorTypeStrings$1));
|
|
const devtools = true ? devtools$1 : 0;
|
|
const setDevtoolsHook = (/* unused pure expression or super */ null && ( true ? setDevtoolsHook$1 : 0));
|
|
const _ssrUtils = {
|
|
createComponentInstance,
|
|
setupComponent,
|
|
renderComponentRoot,
|
|
setCurrentRenderingInstance,
|
|
isVNode: isVNode,
|
|
normalizeVNode,
|
|
getComponentPublicInstance,
|
|
ensureValidVNode,
|
|
pushWarningContext,
|
|
popWarningContext
|
|
};
|
|
const ssrUtils = (/* unused pure expression or super */ null && (_ssrUtils));
|
|
const resolveFilter = null;
|
|
const compatUtils = null;
|
|
const DeprecationTypes = null;
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 4212:
|
|
/***/ (function(module) {
|
|
|
|
"use strict";
|
|
|
|
module.exports = function (exec) {
|
|
try {
|
|
return !!exec();
|
|
} catch (error) {
|
|
return true;
|
|
}
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 4231:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var toLength = __webpack_require__(3337);
|
|
|
|
// `LengthOfArrayLike` abstract operation
|
|
// https://tc39.es/ecma262/#sec-lengthofarraylike
|
|
module.exports = function (obj) {
|
|
return toLength(obj.length);
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 4257:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var NATIVE_ARRAY_BUFFER = __webpack_require__(4474);
|
|
var DESCRIPTORS = __webpack_require__(4911);
|
|
var global = __webpack_require__(4074);
|
|
var isCallable = __webpack_require__(6450);
|
|
var isObject = __webpack_require__(1909);
|
|
var hasOwn = __webpack_require__(1396);
|
|
var classof = __webpack_require__(4804);
|
|
var tryToString = __webpack_require__(9240);
|
|
var createNonEnumerableProperty = __webpack_require__(5266);
|
|
var defineBuiltIn = __webpack_require__(3647);
|
|
var defineBuiltInAccessor = __webpack_require__(2123);
|
|
var isPrototypeOf = __webpack_require__(1856);
|
|
var getPrototypeOf = __webpack_require__(3148);
|
|
var setPrototypeOf = __webpack_require__(640);
|
|
var wellKnownSymbol = __webpack_require__(9760);
|
|
var uid = __webpack_require__(5675);
|
|
var InternalStateModule = __webpack_require__(9868);
|
|
|
|
var enforceInternalState = InternalStateModule.enforce;
|
|
var getInternalState = InternalStateModule.get;
|
|
var Int8Array = global.Int8Array;
|
|
var Int8ArrayPrototype = Int8Array && Int8Array.prototype;
|
|
var Uint8ClampedArray = global.Uint8ClampedArray;
|
|
var Uint8ClampedArrayPrototype = Uint8ClampedArray && Uint8ClampedArray.prototype;
|
|
var TypedArray = Int8Array && getPrototypeOf(Int8Array);
|
|
var TypedArrayPrototype = Int8ArrayPrototype && getPrototypeOf(Int8ArrayPrototype);
|
|
var ObjectPrototype = Object.prototype;
|
|
var TypeError = global.TypeError;
|
|
|
|
var TO_STRING_TAG = wellKnownSymbol('toStringTag');
|
|
var TYPED_ARRAY_TAG = uid('TYPED_ARRAY_TAG');
|
|
var TYPED_ARRAY_CONSTRUCTOR = 'TypedArrayConstructor';
|
|
// Fixing native typed arrays in Opera Presto crashes the browser, see #595
|
|
var NATIVE_ARRAY_BUFFER_VIEWS = NATIVE_ARRAY_BUFFER && !!setPrototypeOf && classof(global.opera) !== 'Opera';
|
|
var TYPED_ARRAY_TAG_REQUIRED = false;
|
|
var NAME, Constructor, Prototype;
|
|
|
|
var TypedArrayConstructorsList = {
|
|
Int8Array: 1,
|
|
Uint8Array: 1,
|
|
Uint8ClampedArray: 1,
|
|
Int16Array: 2,
|
|
Uint16Array: 2,
|
|
Int32Array: 4,
|
|
Uint32Array: 4,
|
|
Float32Array: 4,
|
|
Float64Array: 8
|
|
};
|
|
|
|
var BigIntArrayConstructorsList = {
|
|
BigInt64Array: 8,
|
|
BigUint64Array: 8
|
|
};
|
|
|
|
var isView = function isView(it) {
|
|
if (!isObject(it)) return false;
|
|
var klass = classof(it);
|
|
return klass === 'DataView'
|
|
|| hasOwn(TypedArrayConstructorsList, klass)
|
|
|| hasOwn(BigIntArrayConstructorsList, klass);
|
|
};
|
|
|
|
var getTypedArrayConstructor = function (it) {
|
|
var proto = getPrototypeOf(it);
|
|
if (!isObject(proto)) return;
|
|
var state = getInternalState(proto);
|
|
return (state && hasOwn(state, TYPED_ARRAY_CONSTRUCTOR)) ? state[TYPED_ARRAY_CONSTRUCTOR] : getTypedArrayConstructor(proto);
|
|
};
|
|
|
|
var isTypedArray = function (it) {
|
|
if (!isObject(it)) return false;
|
|
var klass = classof(it);
|
|
return hasOwn(TypedArrayConstructorsList, klass)
|
|
|| hasOwn(BigIntArrayConstructorsList, klass);
|
|
};
|
|
|
|
var aTypedArray = function (it) {
|
|
if (isTypedArray(it)) return it;
|
|
throw new TypeError('Target is not a typed array');
|
|
};
|
|
|
|
var aTypedArrayConstructor = function (C) {
|
|
if (isCallable(C) && (!setPrototypeOf || isPrototypeOf(TypedArray, C))) return C;
|
|
throw new TypeError(tryToString(C) + ' is not a typed array constructor');
|
|
};
|
|
|
|
var exportTypedArrayMethod = function (KEY, property, forced, options) {
|
|
if (!DESCRIPTORS) return;
|
|
if (forced) for (var ARRAY in TypedArrayConstructorsList) {
|
|
var TypedArrayConstructor = global[ARRAY];
|
|
if (TypedArrayConstructor && hasOwn(TypedArrayConstructor.prototype, KEY)) try {
|
|
delete TypedArrayConstructor.prototype[KEY];
|
|
} catch (error) {
|
|
// old WebKit bug - some methods are non-configurable
|
|
try {
|
|
TypedArrayConstructor.prototype[KEY] = property;
|
|
} catch (error2) { /* empty */ }
|
|
}
|
|
}
|
|
if (!TypedArrayPrototype[KEY] || forced) {
|
|
defineBuiltIn(TypedArrayPrototype, KEY, forced ? property
|
|
: NATIVE_ARRAY_BUFFER_VIEWS && Int8ArrayPrototype[KEY] || property, options);
|
|
}
|
|
};
|
|
|
|
var exportTypedArrayStaticMethod = function (KEY, property, forced) {
|
|
var ARRAY, TypedArrayConstructor;
|
|
if (!DESCRIPTORS) return;
|
|
if (setPrototypeOf) {
|
|
if (forced) for (ARRAY in TypedArrayConstructorsList) {
|
|
TypedArrayConstructor = global[ARRAY];
|
|
if (TypedArrayConstructor && hasOwn(TypedArrayConstructor, KEY)) try {
|
|
delete TypedArrayConstructor[KEY];
|
|
} catch (error) { /* empty */ }
|
|
}
|
|
if (!TypedArray[KEY] || forced) {
|
|
// V8 ~ Chrome 49-50 `%TypedArray%` methods are non-writable non-configurable
|
|
try {
|
|
return defineBuiltIn(TypedArray, KEY, forced ? property : NATIVE_ARRAY_BUFFER_VIEWS && TypedArray[KEY] || property);
|
|
} catch (error) { /* empty */ }
|
|
} else return;
|
|
}
|
|
for (ARRAY in TypedArrayConstructorsList) {
|
|
TypedArrayConstructor = global[ARRAY];
|
|
if (TypedArrayConstructor && (!TypedArrayConstructor[KEY] || forced)) {
|
|
defineBuiltIn(TypedArrayConstructor, KEY, property);
|
|
}
|
|
}
|
|
};
|
|
|
|
for (NAME in TypedArrayConstructorsList) {
|
|
Constructor = global[NAME];
|
|
Prototype = Constructor && Constructor.prototype;
|
|
if (Prototype) enforceInternalState(Prototype)[TYPED_ARRAY_CONSTRUCTOR] = Constructor;
|
|
else NATIVE_ARRAY_BUFFER_VIEWS = false;
|
|
}
|
|
|
|
for (NAME in BigIntArrayConstructorsList) {
|
|
Constructor = global[NAME];
|
|
Prototype = Constructor && Constructor.prototype;
|
|
if (Prototype) enforceInternalState(Prototype)[TYPED_ARRAY_CONSTRUCTOR] = Constructor;
|
|
}
|
|
|
|
// WebKit bug - typed arrays constructors prototype is Object.prototype
|
|
if (!NATIVE_ARRAY_BUFFER_VIEWS || !isCallable(TypedArray) || TypedArray === Function.prototype) {
|
|
// eslint-disable-next-line no-shadow -- safe
|
|
TypedArray = function TypedArray() {
|
|
throw new TypeError('Incorrect invocation');
|
|
};
|
|
if (NATIVE_ARRAY_BUFFER_VIEWS) for (NAME in TypedArrayConstructorsList) {
|
|
if (global[NAME]) setPrototypeOf(global[NAME], TypedArray);
|
|
}
|
|
}
|
|
|
|
if (!NATIVE_ARRAY_BUFFER_VIEWS || !TypedArrayPrototype || TypedArrayPrototype === ObjectPrototype) {
|
|
TypedArrayPrototype = TypedArray.prototype;
|
|
if (NATIVE_ARRAY_BUFFER_VIEWS) for (NAME in TypedArrayConstructorsList) {
|
|
if (global[NAME]) setPrototypeOf(global[NAME].prototype, TypedArrayPrototype);
|
|
}
|
|
}
|
|
|
|
// WebKit bug - one more object in Uint8ClampedArray prototype chain
|
|
if (NATIVE_ARRAY_BUFFER_VIEWS && getPrototypeOf(Uint8ClampedArrayPrototype) !== TypedArrayPrototype) {
|
|
setPrototypeOf(Uint8ClampedArrayPrototype, TypedArrayPrototype);
|
|
}
|
|
|
|
if (DESCRIPTORS && !hasOwn(TypedArrayPrototype, TO_STRING_TAG)) {
|
|
TYPED_ARRAY_TAG_REQUIRED = true;
|
|
defineBuiltInAccessor(TypedArrayPrototype, TO_STRING_TAG, {
|
|
configurable: true,
|
|
get: function () {
|
|
return isObject(this) ? this[TYPED_ARRAY_TAG] : undefined;
|
|
}
|
|
});
|
|
for (NAME in TypedArrayConstructorsList) if (global[NAME]) {
|
|
createNonEnumerableProperty(global[NAME], TYPED_ARRAY_TAG, NAME);
|
|
}
|
|
}
|
|
|
|
module.exports = {
|
|
NATIVE_ARRAY_BUFFER_VIEWS: NATIVE_ARRAY_BUFFER_VIEWS,
|
|
TYPED_ARRAY_TAG: TYPED_ARRAY_TAG_REQUIRED && TYPED_ARRAY_TAG,
|
|
aTypedArray: aTypedArray,
|
|
aTypedArrayConstructor: aTypedArrayConstructor,
|
|
exportTypedArrayMethod: exportTypedArrayMethod,
|
|
exportTypedArrayStaticMethod: exportTypedArrayStaticMethod,
|
|
getTypedArrayConstructor: getTypedArrayConstructor,
|
|
isView: isView,
|
|
isTypedArray: isTypedArray,
|
|
TypedArray: TypedArray,
|
|
TypedArrayPrototype: TypedArrayPrototype
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 4259:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var uncurryThis = __webpack_require__(1371);
|
|
var arrayBufferByteLength = __webpack_require__(8299);
|
|
|
|
var slice = uncurryThis(ArrayBuffer.prototype.slice);
|
|
|
|
module.exports = function (O) {
|
|
if (arrayBufferByteLength(O) !== 0) return false;
|
|
try {
|
|
slice(O, 0, 0);
|
|
return false;
|
|
} catch (error) {
|
|
return true;
|
|
}
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 4417:
|
|
/***/ (function(module) {
|
|
|
|
"use strict";
|
|
|
|
/* global Deno -- Deno case */
|
|
module.exports = typeof Deno == 'object' && Deno && typeof Deno.version == 'object';
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 4474:
|
|
/***/ (function(module) {
|
|
|
|
"use strict";
|
|
|
|
// eslint-disable-next-line es/no-typed-arrays -- safe
|
|
module.exports = typeof ArrayBuffer != 'undefined' && typeof DataView != 'undefined';
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 4497:
|
|
/***/ (function(module) {
|
|
|
|
"use strict";
|
|
|
|
module.exports = {
|
|
IndexSizeError: { s: 'INDEX_SIZE_ERR', c: 1, m: 1 },
|
|
DOMStringSizeError: { s: 'DOMSTRING_SIZE_ERR', c: 2, m: 0 },
|
|
HierarchyRequestError: { s: 'HIERARCHY_REQUEST_ERR', c: 3, m: 1 },
|
|
WrongDocumentError: { s: 'WRONG_DOCUMENT_ERR', c: 4, m: 1 },
|
|
InvalidCharacterError: { s: 'INVALID_CHARACTER_ERR', c: 5, m: 1 },
|
|
NoDataAllowedError: { s: 'NO_DATA_ALLOWED_ERR', c: 6, m: 0 },
|
|
NoModificationAllowedError: { s: 'NO_MODIFICATION_ALLOWED_ERR', c: 7, m: 1 },
|
|
NotFoundError: { s: 'NOT_FOUND_ERR', c: 8, m: 1 },
|
|
NotSupportedError: { s: 'NOT_SUPPORTED_ERR', c: 9, m: 1 },
|
|
InUseAttributeError: { s: 'INUSE_ATTRIBUTE_ERR', c: 10, m: 1 },
|
|
InvalidStateError: { s: 'INVALID_STATE_ERR', c: 11, m: 1 },
|
|
SyntaxError: { s: 'SYNTAX_ERR', c: 12, m: 1 },
|
|
InvalidModificationError: { s: 'INVALID_MODIFICATION_ERR', c: 13, m: 1 },
|
|
NamespaceError: { s: 'NAMESPACE_ERR', c: 14, m: 1 },
|
|
InvalidAccessError: { s: 'INVALID_ACCESS_ERR', c: 15, m: 1 },
|
|
ValidationError: { s: 'VALIDATION_ERR', c: 16, m: 0 },
|
|
TypeMismatchError: { s: 'TYPE_MISMATCH_ERR', c: 17, m: 1 },
|
|
SecurityError: { s: 'SECURITY_ERR', c: 18, m: 1 },
|
|
NetworkError: { s: 'NETWORK_ERR', c: 19, m: 1 },
|
|
AbortError: { s: 'ABORT_ERR', c: 20, m: 1 },
|
|
URLMismatchError: { s: 'URL_MISMATCH_ERR', c: 21, m: 1 },
|
|
QuotaExceededError: { s: 'QUOTA_EXCEEDED_ERR', c: 22, m: 1 },
|
|
TimeoutError: { s: 'TIMEOUT_ERR', c: 23, m: 1 },
|
|
InvalidNodeTypeError: { s: 'INVALID_NODE_TYPE_ERR', c: 24, m: 1 },
|
|
DataCloneError: { s: 'DATA_CLONE_ERR', c: 25, m: 1 }
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 4505:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var aSet = __webpack_require__(3991);
|
|
var SetHelpers = __webpack_require__(5057);
|
|
var clone = __webpack_require__(7289);
|
|
var size = __webpack_require__(903);
|
|
var getSetRecord = __webpack_require__(3108);
|
|
var iterateSet = __webpack_require__(2282);
|
|
var iterateSimple = __webpack_require__(6550);
|
|
|
|
var has = SetHelpers.has;
|
|
var remove = SetHelpers.remove;
|
|
|
|
// `Set.prototype.difference` method
|
|
// https://github.com/tc39/proposal-set-methods
|
|
module.exports = function difference(other) {
|
|
var O = aSet(this);
|
|
var otherRec = getSetRecord(other);
|
|
var result = clone(O);
|
|
if (size(O) <= otherRec.size) iterateSet(O, function (e) {
|
|
if (otherRec.includes(e)) remove(result, e);
|
|
});
|
|
else iterateSimple(otherRec.getIterator(), function (e) {
|
|
if (has(O, e)) remove(result, e);
|
|
});
|
|
return result;
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 4544:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var uncurryThis = __webpack_require__(1371);
|
|
var fails = __webpack_require__(4212);
|
|
var isCallable = __webpack_require__(6450);
|
|
var hasOwn = __webpack_require__(1396);
|
|
var DESCRIPTORS = __webpack_require__(4911);
|
|
var CONFIGURABLE_FUNCTION_NAME = (__webpack_require__(2473).CONFIGURABLE);
|
|
var inspectSource = __webpack_require__(2607);
|
|
var InternalStateModule = __webpack_require__(9868);
|
|
|
|
var enforceInternalState = InternalStateModule.enforce;
|
|
var getInternalState = InternalStateModule.get;
|
|
var $String = String;
|
|
// eslint-disable-next-line es/no-object-defineproperty -- safe
|
|
var defineProperty = Object.defineProperty;
|
|
var stringSlice = uncurryThis(''.slice);
|
|
var replace = uncurryThis(''.replace);
|
|
var join = uncurryThis([].join);
|
|
|
|
var CONFIGURABLE_LENGTH = DESCRIPTORS && !fails(function () {
|
|
return defineProperty(function () { /* empty */ }, 'length', { value: 8 }).length !== 8;
|
|
});
|
|
|
|
var TEMPLATE = String(String).split('String');
|
|
|
|
var makeBuiltIn = module.exports = function (value, name, options) {
|
|
if (stringSlice($String(name), 0, 7) === 'Symbol(') {
|
|
name = '[' + replace($String(name), /^Symbol\(([^)]*)\).*$/, '$1') + ']';
|
|
}
|
|
if (options && options.getter) name = 'get ' + name;
|
|
if (options && options.setter) name = 'set ' + name;
|
|
if (!hasOwn(value, 'name') || (CONFIGURABLE_FUNCTION_NAME && value.name !== name)) {
|
|
if (DESCRIPTORS) defineProperty(value, 'name', { value: name, configurable: true });
|
|
else value.name = name;
|
|
}
|
|
if (CONFIGURABLE_LENGTH && options && hasOwn(options, 'arity') && value.length !== options.arity) {
|
|
defineProperty(value, 'length', { value: options.arity });
|
|
}
|
|
try {
|
|
if (options && hasOwn(options, 'constructor') && options.constructor) {
|
|
if (DESCRIPTORS) defineProperty(value, 'prototype', { writable: false });
|
|
// in V8 ~ Chrome 53, prototypes of some methods, like `Array.prototype.values`, are non-writable
|
|
} else if (value.prototype) value.prototype = undefined;
|
|
} catch (error) { /* empty */ }
|
|
var state = enforceInternalState(value);
|
|
if (!hasOwn(state, 'source')) {
|
|
state.source = join(TEMPLATE, typeof name == 'string' ? name : '');
|
|
} return value;
|
|
};
|
|
|
|
// add fake Function#toString for correct work wrapped methods / constructors with methods like LoDash isNative
|
|
// eslint-disable-next-line no-extend-native -- required
|
|
Function.prototype.toString = makeBuiltIn(function toString() {
|
|
return isCallable(this) && getInternalState(this).source || inspectSource(this);
|
|
}, 'toString');
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 4546:
|
|
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) {
|
|
|
|
"use strict";
|
|
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
/* harmony export */ $3: function() { return /* binding */ hasOwn; },
|
|
/* harmony export */ BH: function() { return /* binding */ isGloballyAllowed; },
|
|
/* harmony export */ C4: function() { return /* binding */ normalizeClass; },
|
|
/* harmony export */ CP: function() { return /* binding */ isModelListener; },
|
|
/* harmony export */ DY: function() { return /* binding */ invokeArrayFns; },
|
|
/* harmony export */ Gv: function() { return /* binding */ isObject; },
|
|
/* harmony export */ Kg: function() { return /* binding */ isString; },
|
|
/* harmony export */ MZ: function() { return /* binding */ EMPTY_OBJ; },
|
|
/* harmony export */ Mp: function() { return /* binding */ isOn; },
|
|
/* harmony export */ NO: function() { return /* binding */ NO; },
|
|
/* harmony export */ Oj: function() { return /* binding */ EMPTY_ARR; },
|
|
/* harmony export */ PT: function() { return /* binding */ camelize; },
|
|
/* harmony export */ Ro: function() { return /* binding */ toNumber; },
|
|
/* harmony export */ SU: function() { return /* binding */ isReservedProp; },
|
|
/* harmony export */ TF: function() { return /* binding */ remove; },
|
|
/* harmony export */ Tg: function() { return /* binding */ hyphenate; },
|
|
/* harmony export */ Tn: function() { return /* binding */ isFunction; },
|
|
/* harmony export */ Tr: function() { return /* binding */ normalizeStyle; },
|
|
/* harmony export */ We: function() { return /* binding */ getGlobalThis; },
|
|
/* harmony export */ X$: function() { return /* binding */ extend; },
|
|
/* harmony export */ bB: function() { return /* binding */ looseToNumber; },
|
|
/* harmony export */ cy: function() { return /* binding */ isArray; },
|
|
/* harmony export */ gd: function() { return /* binding */ isRegExp; },
|
|
/* harmony export */ rU: function() { return /* binding */ toHandlerKey; },
|
|
/* harmony export */ tE: function() { return /* binding */ NOOP; },
|
|
/* harmony export */ v_: function() { return /* binding */ toDisplayString; },
|
|
/* harmony export */ yL: function() { return /* binding */ isPromise; },
|
|
/* harmony export */ yQ: function() { return /* binding */ def; }
|
|
/* harmony export */ });
|
|
/* unused harmony exports PatchFlagNames, PatchFlags, ShapeFlags, SlotFlags, capitalize, cssVarNameEscapeSymbolsRE, escapeHtml, escapeHtmlComment, genCacheKey, genPropsAccessExp, generateCodeFrame, getEscapedCssVarName, hasChanged, includeBooleanAttr, isBooleanAttr, isBuiltInDirective, isDate, isGloballyWhitelisted, isHTMLTag, isIntegerKey, isKnownHtmlAttr, isKnownMathMLAttr, isKnownSvgAttr, isMap, isMathMLTag, isPlainObject, isRenderableAttrValue, isSSRSafeAttrName, isSVGTag, isSet, isSpecialBooleanAttr, isSymbol, isVoidTag, looseEqual, looseIndexOf, makeMap, normalizeProps, objectToString, parseStringStyle, propsToAttrMap, slotFlagsText, stringifyStyle, toRawType, toTypeString */
|
|
/* harmony import */ var core_js_modules_es_array_push_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(5513);
|
|
/* harmony import */ var core_js_modules_es_array_push_js__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_array_push_js__WEBPACK_IMPORTED_MODULE_0__);
|
|
/* harmony import */ var core_js_modules_esnext_iterator_constructor_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(7195);
|
|
/* harmony import */ var core_js_modules_esnext_iterator_constructor_js__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_esnext_iterator_constructor_js__WEBPACK_IMPORTED_MODULE_1__);
|
|
/* harmony import */ var core_js_modules_esnext_iterator_filter_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(3741);
|
|
/* harmony import */ var core_js_modules_esnext_iterator_filter_js__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_esnext_iterator_filter_js__WEBPACK_IMPORTED_MODULE_2__);
|
|
/* harmony import */ var core_js_modules_esnext_iterator_for_each_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(680);
|
|
/* harmony import */ var core_js_modules_esnext_iterator_for_each_js__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_esnext_iterator_for_each_js__WEBPACK_IMPORTED_MODULE_3__);
|
|
/* harmony import */ var core_js_modules_esnext_iterator_map_js__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(793);
|
|
/* harmony import */ var core_js_modules_esnext_iterator_map_js__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_esnext_iterator_map_js__WEBPACK_IMPORTED_MODULE_4__);
|
|
/* harmony import */ var core_js_modules_esnext_iterator_reduce_js__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(5729);
|
|
/* harmony import */ var core_js_modules_esnext_iterator_reduce_js__WEBPACK_IMPORTED_MODULE_5___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_esnext_iterator_reduce_js__WEBPACK_IMPORTED_MODULE_5__);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
/**
|
|
* @vue/shared v3.5.13
|
|
* (c) 2018-present Yuxi (Evan) You and Vue contributors
|
|
* @license MIT
|
|
**/
|
|
/*! #__NO_SIDE_EFFECTS__ */
|
|
// @__NO_SIDE_EFFECTS__
|
|
function makeMap(str) {
|
|
const map = /* @__PURE__ */Object.create(null);
|
|
for (const key of str.split(",")) map[key] = 1;
|
|
return val => val in map;
|
|
}
|
|
const EMPTY_OBJ = false ? 0 : {};
|
|
const EMPTY_ARR = false ? 0 : [];
|
|
const NOOP = () => {};
|
|
const NO = () => false;
|
|
const isOn = key => key.charCodeAt(0) === 111 && key.charCodeAt(1) === 110 && (
|
|
// uppercase letter
|
|
key.charCodeAt(2) > 122 || key.charCodeAt(2) < 97);
|
|
const isModelListener = key => key.startsWith("onUpdate:");
|
|
const extend = Object.assign;
|
|
const remove = (arr, el) => {
|
|
const i = arr.indexOf(el);
|
|
if (i > -1) {
|
|
arr.splice(i, 1);
|
|
}
|
|
};
|
|
const hasOwnProperty = Object.prototype.hasOwnProperty;
|
|
const hasOwn = (val, key) => hasOwnProperty.call(val, key);
|
|
const isArray = Array.isArray;
|
|
const isMap = val => toTypeString(val) === "[object Map]";
|
|
const isSet = val => toTypeString(val) === "[object Set]";
|
|
const isDate = val => toTypeString(val) === "[object Date]";
|
|
const isRegExp = val => toTypeString(val) === "[object RegExp]";
|
|
const isFunction = val => typeof val === "function";
|
|
const isString = val => typeof val === "string";
|
|
const isSymbol = val => typeof val === "symbol";
|
|
const isObject = val => val !== null && typeof val === "object";
|
|
const isPromise = val => {
|
|
return (isObject(val) || isFunction(val)) && isFunction(val.then) && isFunction(val.catch);
|
|
};
|
|
const objectToString = Object.prototype.toString;
|
|
const toTypeString = value => objectToString.call(value);
|
|
const toRawType = value => {
|
|
return toTypeString(value).slice(8, -1);
|
|
};
|
|
const isPlainObject = val => toTypeString(val) === "[object Object]";
|
|
const isIntegerKey = key => isString(key) && key !== "NaN" && key[0] !== "-" && "" + parseInt(key, 10) === key;
|
|
const isReservedProp = /* @__PURE__ */makeMap(
|
|
// the leading comma is intentional so empty string "" is also included
|
|
",key,ref,ref_for,ref_key,onVnodeBeforeMount,onVnodeMounted,onVnodeBeforeUpdate,onVnodeUpdated,onVnodeBeforeUnmount,onVnodeUnmounted");
|
|
const isBuiltInDirective = /* @__PURE__ */(/* unused pure expression or super */ null && (makeMap("bind,cloak,else-if,else,for,html,if,model,on,once,pre,show,slot,text,memo")));
|
|
const cacheStringFunction = fn => {
|
|
const cache = /* @__PURE__ */Object.create(null);
|
|
return str => {
|
|
const hit = cache[str];
|
|
return hit || (cache[str] = fn(str));
|
|
};
|
|
};
|
|
const camelizeRE = /-(\w)/g;
|
|
const camelize = cacheStringFunction(str => {
|
|
return str.replace(camelizeRE, (_, c) => c ? c.toUpperCase() : "");
|
|
});
|
|
const hyphenateRE = /\B([A-Z])/g;
|
|
const hyphenate = cacheStringFunction(str => str.replace(hyphenateRE, "-$1").toLowerCase());
|
|
const capitalize = cacheStringFunction(str => {
|
|
return str.charAt(0).toUpperCase() + str.slice(1);
|
|
});
|
|
const toHandlerKey = cacheStringFunction(str => {
|
|
const s = str ? `on${capitalize(str)}` : ``;
|
|
return s;
|
|
});
|
|
const hasChanged = (value, oldValue) => !Object.is(value, oldValue);
|
|
const invokeArrayFns = (fns, ...arg) => {
|
|
for (let i = 0; i < fns.length; i++) {
|
|
fns[i](...arg);
|
|
}
|
|
};
|
|
const def = (obj, key, value, writable = false) => {
|
|
Object.defineProperty(obj, key, {
|
|
configurable: true,
|
|
enumerable: false,
|
|
writable,
|
|
value
|
|
});
|
|
};
|
|
const looseToNumber = val => {
|
|
const n = parseFloat(val);
|
|
return isNaN(n) ? val : n;
|
|
};
|
|
const toNumber = val => {
|
|
const n = isString(val) ? Number(val) : NaN;
|
|
return isNaN(n) ? val : n;
|
|
};
|
|
let _globalThis;
|
|
const getGlobalThis = () => {
|
|
return _globalThis || (_globalThis = typeof globalThis !== "undefined" ? globalThis : typeof self !== "undefined" ? self : typeof window !== "undefined" ? window : typeof __webpack_require__.g !== "undefined" ? __webpack_require__.g : {});
|
|
};
|
|
const identRE = /^[_$a-zA-Z\xA0-\uFFFF][_$a-zA-Z0-9\xA0-\uFFFF]*$/;
|
|
function genPropsAccessExp(name) {
|
|
return identRE.test(name) ? `__props.${name}` : `__props[${JSON.stringify(name)}]`;
|
|
}
|
|
function genCacheKey(source, options) {
|
|
return source + JSON.stringify(options, (_, val) => typeof val === "function" ? val.toString() : val);
|
|
}
|
|
const PatchFlags = {
|
|
"TEXT": 1,
|
|
"1": "TEXT",
|
|
"CLASS": 2,
|
|
"2": "CLASS",
|
|
"STYLE": 4,
|
|
"4": "STYLE",
|
|
"PROPS": 8,
|
|
"8": "PROPS",
|
|
"FULL_PROPS": 16,
|
|
"16": "FULL_PROPS",
|
|
"NEED_HYDRATION": 32,
|
|
"32": "NEED_HYDRATION",
|
|
"STABLE_FRAGMENT": 64,
|
|
"64": "STABLE_FRAGMENT",
|
|
"KEYED_FRAGMENT": 128,
|
|
"128": "KEYED_FRAGMENT",
|
|
"UNKEYED_FRAGMENT": 256,
|
|
"256": "UNKEYED_FRAGMENT",
|
|
"NEED_PATCH": 512,
|
|
"512": "NEED_PATCH",
|
|
"DYNAMIC_SLOTS": 1024,
|
|
"1024": "DYNAMIC_SLOTS",
|
|
"DEV_ROOT_FRAGMENT": 2048,
|
|
"2048": "DEV_ROOT_FRAGMENT",
|
|
"CACHED": -1,
|
|
"-1": "CACHED",
|
|
"BAIL": -2,
|
|
"-2": "BAIL"
|
|
};
|
|
const PatchFlagNames = {
|
|
[1]: `TEXT`,
|
|
[2]: `CLASS`,
|
|
[4]: `STYLE`,
|
|
[8]: `PROPS`,
|
|
[16]: `FULL_PROPS`,
|
|
[32]: `NEED_HYDRATION`,
|
|
[64]: `STABLE_FRAGMENT`,
|
|
[128]: `KEYED_FRAGMENT`,
|
|
[256]: `UNKEYED_FRAGMENT`,
|
|
[512]: `NEED_PATCH`,
|
|
[1024]: `DYNAMIC_SLOTS`,
|
|
[2048]: `DEV_ROOT_FRAGMENT`,
|
|
[-1]: `HOISTED`,
|
|
[-2]: `BAIL`
|
|
};
|
|
const ShapeFlags = {
|
|
"ELEMENT": 1,
|
|
"1": "ELEMENT",
|
|
"FUNCTIONAL_COMPONENT": 2,
|
|
"2": "FUNCTIONAL_COMPONENT",
|
|
"STATEFUL_COMPONENT": 4,
|
|
"4": "STATEFUL_COMPONENT",
|
|
"TEXT_CHILDREN": 8,
|
|
"8": "TEXT_CHILDREN",
|
|
"ARRAY_CHILDREN": 16,
|
|
"16": "ARRAY_CHILDREN",
|
|
"SLOTS_CHILDREN": 32,
|
|
"32": "SLOTS_CHILDREN",
|
|
"TELEPORT": 64,
|
|
"64": "TELEPORT",
|
|
"SUSPENSE": 128,
|
|
"128": "SUSPENSE",
|
|
"COMPONENT_SHOULD_KEEP_ALIVE": 256,
|
|
"256": "COMPONENT_SHOULD_KEEP_ALIVE",
|
|
"COMPONENT_KEPT_ALIVE": 512,
|
|
"512": "COMPONENT_KEPT_ALIVE",
|
|
"COMPONENT": 6,
|
|
"6": "COMPONENT"
|
|
};
|
|
const SlotFlags = {
|
|
"STABLE": 1,
|
|
"1": "STABLE",
|
|
"DYNAMIC": 2,
|
|
"2": "DYNAMIC",
|
|
"FORWARDED": 3,
|
|
"3": "FORWARDED"
|
|
};
|
|
const slotFlagsText = {
|
|
[1]: "STABLE",
|
|
[2]: "DYNAMIC",
|
|
[3]: "FORWARDED"
|
|
};
|
|
const GLOBALS_ALLOWED = "Infinity,undefined,NaN,isFinite,isNaN,parseFloat,parseInt,decodeURI,decodeURIComponent,encodeURI,encodeURIComponent,Math,Number,Date,Array,Object,Boolean,String,RegExp,Map,Set,JSON,Intl,BigInt,console,Error,Symbol";
|
|
const isGloballyAllowed = /* @__PURE__ */makeMap(GLOBALS_ALLOWED);
|
|
const isGloballyWhitelisted = (/* unused pure expression or super */ null && (isGloballyAllowed));
|
|
const range = 2;
|
|
function generateCodeFrame(source, start = 0, end = source.length) {
|
|
start = Math.max(0, Math.min(start, source.length));
|
|
end = Math.max(0, Math.min(end, source.length));
|
|
if (start > end) return "";
|
|
let lines = source.split(/(\r?\n)/);
|
|
const newlineSequences = lines.filter((_, idx) => idx % 2 === 1);
|
|
lines = lines.filter((_, idx) => idx % 2 === 0);
|
|
let count = 0;
|
|
const res = [];
|
|
for (let i = 0; i < lines.length; i++) {
|
|
count += lines[i].length + (newlineSequences[i] && newlineSequences[i].length || 0);
|
|
if (count >= start) {
|
|
for (let j = i - range; j <= i + range || end > count; j++) {
|
|
if (j < 0 || j >= lines.length) continue;
|
|
const line = j + 1;
|
|
res.push(`${line}${" ".repeat(Math.max(3 - String(line).length, 0))}| ${lines[j]}`);
|
|
const lineLength = lines[j].length;
|
|
const newLineSeqLength = newlineSequences[j] && newlineSequences[j].length || 0;
|
|
if (j === i) {
|
|
const pad = start - (count - (lineLength + newLineSeqLength));
|
|
const length = Math.max(1, end > count ? lineLength - pad : end - start);
|
|
res.push(` | ` + " ".repeat(pad) + "^".repeat(length));
|
|
} else if (j > i) {
|
|
if (end > count) {
|
|
const length = Math.max(Math.min(end - count, lineLength), 1);
|
|
res.push(` | ` + "^".repeat(length));
|
|
}
|
|
count += lineLength + newLineSeqLength;
|
|
}
|
|
}
|
|
break;
|
|
}
|
|
}
|
|
return res.join("\n");
|
|
}
|
|
function normalizeStyle(value) {
|
|
if (isArray(value)) {
|
|
const res = {};
|
|
for (let i = 0; i < value.length; i++) {
|
|
const item = value[i];
|
|
const normalized = isString(item) ? parseStringStyle(item) : normalizeStyle(item);
|
|
if (normalized) {
|
|
for (const key in normalized) {
|
|
res[key] = normalized[key];
|
|
}
|
|
}
|
|
}
|
|
return res;
|
|
} else if (isString(value) || isObject(value)) {
|
|
return value;
|
|
}
|
|
}
|
|
const listDelimiterRE = /;(?![^(]*\))/g;
|
|
const propertyDelimiterRE = /:([^]+)/;
|
|
const styleCommentRE = /\/\*[^]*?\*\//g;
|
|
function parseStringStyle(cssText) {
|
|
const ret = {};
|
|
cssText.replace(styleCommentRE, "").split(listDelimiterRE).forEach(item => {
|
|
if (item) {
|
|
const tmp = item.split(propertyDelimiterRE);
|
|
tmp.length > 1 && (ret[tmp[0].trim()] = tmp[1].trim());
|
|
}
|
|
});
|
|
return ret;
|
|
}
|
|
function stringifyStyle(styles) {
|
|
if (!styles) return "";
|
|
if (isString(styles)) return styles;
|
|
let ret = "";
|
|
for (const key in styles) {
|
|
const value = styles[key];
|
|
if (isString(value) || typeof value === "number") {
|
|
const normalizedKey = key.startsWith(`--`) ? key : hyphenate(key);
|
|
ret += `${normalizedKey}:${value};`;
|
|
}
|
|
}
|
|
return ret;
|
|
}
|
|
function normalizeClass(value) {
|
|
let res = "";
|
|
if (isString(value)) {
|
|
res = value;
|
|
} else if (isArray(value)) {
|
|
for (let i = 0; i < value.length; i++) {
|
|
const normalized = normalizeClass(value[i]);
|
|
if (normalized) {
|
|
res += normalized + " ";
|
|
}
|
|
}
|
|
} else if (isObject(value)) {
|
|
for (const name in value) {
|
|
if (value[name]) {
|
|
res += name + " ";
|
|
}
|
|
}
|
|
}
|
|
return res.trim();
|
|
}
|
|
function normalizeProps(props) {
|
|
if (!props) return null;
|
|
let {
|
|
class: klass,
|
|
style
|
|
} = props;
|
|
if (klass && !isString(klass)) {
|
|
props.class = normalizeClass(klass);
|
|
}
|
|
if (style) {
|
|
props.style = normalizeStyle(style);
|
|
}
|
|
return props;
|
|
}
|
|
const HTML_TAGS = "html,body,base,head,link,meta,style,title,address,article,aside,footer,header,hgroup,h1,h2,h3,h4,h5,h6,nav,section,div,dd,dl,dt,figcaption,figure,picture,hr,img,li,main,ol,p,pre,ul,a,b,abbr,bdi,bdo,br,cite,code,data,dfn,em,i,kbd,mark,q,rp,rt,ruby,s,samp,small,span,strong,sub,sup,time,u,var,wbr,area,audio,map,track,video,embed,object,param,source,canvas,script,noscript,del,ins,caption,col,colgroup,table,thead,tbody,td,th,tr,button,datalist,fieldset,form,input,label,legend,meter,optgroup,option,output,progress,select,textarea,details,dialog,menu,summary,template,blockquote,iframe,tfoot";
|
|
const SVG_TAGS = "svg,animate,animateMotion,animateTransform,circle,clipPath,color-profile,defs,desc,discard,ellipse,feBlend,feColorMatrix,feComponentTransfer,feComposite,feConvolveMatrix,feDiffuseLighting,feDisplacementMap,feDistantLight,feDropShadow,feFlood,feFuncA,feFuncB,feFuncG,feFuncR,feGaussianBlur,feImage,feMerge,feMergeNode,feMorphology,feOffset,fePointLight,feSpecularLighting,feSpotLight,feTile,feTurbulence,filter,foreignObject,g,hatch,hatchpath,image,line,linearGradient,marker,mask,mesh,meshgradient,meshpatch,meshrow,metadata,mpath,path,pattern,polygon,polyline,radialGradient,rect,set,solidcolor,stop,switch,symbol,text,textPath,title,tspan,unknown,use,view";
|
|
const MATH_TAGS = "annotation,annotation-xml,maction,maligngroup,malignmark,math,menclose,merror,mfenced,mfrac,mfraction,mglyph,mi,mlabeledtr,mlongdiv,mmultiscripts,mn,mo,mover,mpadded,mphantom,mprescripts,mroot,mrow,ms,mscarries,mscarry,msgroup,msline,mspace,msqrt,msrow,mstack,mstyle,msub,msubsup,msup,mtable,mtd,mtext,mtr,munder,munderover,none,semantics";
|
|
const VOID_TAGS = "area,base,br,col,embed,hr,img,input,link,meta,param,source,track,wbr";
|
|
const isHTMLTag = /* @__PURE__ */(/* unused pure expression or super */ null && (makeMap(HTML_TAGS)));
|
|
const isSVGTag = /* @__PURE__ */(/* unused pure expression or super */ null && (makeMap(SVG_TAGS)));
|
|
const isMathMLTag = /* @__PURE__ */(/* unused pure expression or super */ null && (makeMap(MATH_TAGS)));
|
|
const isVoidTag = /* @__PURE__ */(/* unused pure expression or super */ null && (makeMap(VOID_TAGS)));
|
|
const specialBooleanAttrs = `itemscope,allowfullscreen,formnovalidate,ismap,nomodule,novalidate,readonly`;
|
|
const isSpecialBooleanAttr = /* @__PURE__ */(/* unused pure expression or super */ null && (makeMap(specialBooleanAttrs)));
|
|
const isBooleanAttr = /* @__PURE__ */makeMap(specialBooleanAttrs + `,async,autofocus,autoplay,controls,default,defer,disabled,hidden,inert,loop,open,required,reversed,scoped,seamless,checked,muted,multiple,selected`);
|
|
function includeBooleanAttr(value) {
|
|
return !!value || value === "";
|
|
}
|
|
const unsafeAttrCharRE = /[>/="'\u0009\u000a\u000c\u0020]/;
|
|
const attrValidationCache = {};
|
|
function isSSRSafeAttrName(name) {
|
|
if (attrValidationCache.hasOwnProperty(name)) {
|
|
return attrValidationCache[name];
|
|
}
|
|
const isUnsafe = unsafeAttrCharRE.test(name);
|
|
if (isUnsafe) {
|
|
console.error(`unsafe attribute name: ${name}`);
|
|
}
|
|
return attrValidationCache[name] = !isUnsafe;
|
|
}
|
|
const propsToAttrMap = {
|
|
acceptCharset: "accept-charset",
|
|
className: "class",
|
|
htmlFor: "for",
|
|
httpEquiv: "http-equiv"
|
|
};
|
|
const isKnownHtmlAttr = /* @__PURE__ */(/* unused pure expression or super */ null && (makeMap(`accept,accept-charset,accesskey,action,align,allow,alt,async,autocapitalize,autocomplete,autofocus,autoplay,background,bgcolor,border,buffered,capture,challenge,charset,checked,cite,class,code,codebase,color,cols,colspan,content,contenteditable,contextmenu,controls,coords,crossorigin,csp,data,datetime,decoding,default,defer,dir,dirname,disabled,download,draggable,dropzone,enctype,enterkeyhint,for,form,formaction,formenctype,formmethod,formnovalidate,formtarget,headers,height,hidden,high,href,hreflang,http-equiv,icon,id,importance,inert,integrity,ismap,itemprop,keytype,kind,label,lang,language,loading,list,loop,low,manifest,max,maxlength,minlength,media,min,multiple,muted,name,novalidate,open,optimum,pattern,ping,placeholder,poster,preload,radiogroup,readonly,referrerpolicy,rel,required,reversed,rows,rowspan,sandbox,scope,scoped,selected,shape,size,sizes,slot,span,spellcheck,src,srcdoc,srclang,srcset,start,step,style,summary,tabindex,target,title,translate,type,usemap,value,width,wrap`)));
|
|
const isKnownSvgAttr = /* @__PURE__ */(/* unused pure expression or super */ null && (makeMap(`xmlns,accent-height,accumulate,additive,alignment-baseline,alphabetic,amplitude,arabic-form,ascent,attributeName,attributeType,azimuth,baseFrequency,baseline-shift,baseProfile,bbox,begin,bias,by,calcMode,cap-height,class,clip,clipPathUnits,clip-path,clip-rule,color,color-interpolation,color-interpolation-filters,color-profile,color-rendering,contentScriptType,contentStyleType,crossorigin,cursor,cx,cy,d,decelerate,descent,diffuseConstant,direction,display,divisor,dominant-baseline,dur,dx,dy,edgeMode,elevation,enable-background,end,exponent,fill,fill-opacity,fill-rule,filter,filterRes,filterUnits,flood-color,flood-opacity,font-family,font-size,font-size-adjust,font-stretch,font-style,font-variant,font-weight,format,from,fr,fx,fy,g1,g2,glyph-name,glyph-orientation-horizontal,glyph-orientation-vertical,glyphRef,gradientTransform,gradientUnits,hanging,height,href,hreflang,horiz-adv-x,horiz-origin-x,id,ideographic,image-rendering,in,in2,intercept,k,k1,k2,k3,k4,kernelMatrix,kernelUnitLength,kerning,keyPoints,keySplines,keyTimes,lang,lengthAdjust,letter-spacing,lighting-color,limitingConeAngle,local,marker-end,marker-mid,marker-start,markerHeight,markerUnits,markerWidth,mask,maskContentUnits,maskUnits,mathematical,max,media,method,min,mode,name,numOctaves,offset,opacity,operator,order,orient,orientation,origin,overflow,overline-position,overline-thickness,panose-1,paint-order,path,pathLength,patternContentUnits,patternTransform,patternUnits,ping,pointer-events,points,pointsAtX,pointsAtY,pointsAtZ,preserveAlpha,preserveAspectRatio,primitiveUnits,r,radius,referrerPolicy,refX,refY,rel,rendering-intent,repeatCount,repeatDur,requiredExtensions,requiredFeatures,restart,result,rotate,rx,ry,scale,seed,shape-rendering,slope,spacing,specularConstant,specularExponent,speed,spreadMethod,startOffset,stdDeviation,stemh,stemv,stitchTiles,stop-color,stop-opacity,strikethrough-position,strikethrough-thickness,string,stroke,stroke-dasharray,stroke-dashoffset,stroke-linecap,stroke-linejoin,stroke-miterlimit,stroke-opacity,stroke-width,style,surfaceScale,systemLanguage,tabindex,tableValues,target,targetX,targetY,text-anchor,text-decoration,text-rendering,textLength,to,transform,transform-origin,type,u1,u2,underline-position,underline-thickness,unicode,unicode-bidi,unicode-range,units-per-em,v-alphabetic,v-hanging,v-ideographic,v-mathematical,values,vector-effect,version,vert-adv-y,vert-origin-x,vert-origin-y,viewBox,viewTarget,visibility,width,widths,word-spacing,writing-mode,x,x-height,x1,x2,xChannelSelector,xlink:actuate,xlink:arcrole,xlink:href,xlink:role,xlink:show,xlink:title,xlink:type,xmlns:xlink,xml:base,xml:lang,xml:space,y,y1,y2,yChannelSelector,z,zoomAndPan`)));
|
|
const isKnownMathMLAttr = /* @__PURE__ */(/* unused pure expression or super */ null && (makeMap(`accent,accentunder,actiontype,align,alignmentscope,altimg,altimg-height,altimg-valign,altimg-width,alttext,bevelled,close,columnsalign,columnlines,columnspan,denomalign,depth,dir,display,displaystyle,encoding,equalcolumns,equalrows,fence,fontstyle,fontweight,form,frame,framespacing,groupalign,height,href,id,indentalign,indentalignfirst,indentalignlast,indentshift,indentshiftfirst,indentshiftlast,indextype,justify,largetop,largeop,lquote,lspace,mathbackground,mathcolor,mathsize,mathvariant,maxsize,minlabelspacing,mode,other,overflow,position,rowalign,rowlines,rowspan,rquote,rspace,scriptlevel,scriptminsize,scriptsizemultiplier,selection,separator,separators,shift,side,src,stackalign,stretchy,subscriptshift,superscriptshift,symmetric,voffset,width,widths,xlink:href,xlink:show,xlink:type,xmlns`)));
|
|
function isRenderableAttrValue(value) {
|
|
if (value == null) {
|
|
return false;
|
|
}
|
|
const type = typeof value;
|
|
return type === "string" || type === "number" || type === "boolean";
|
|
}
|
|
const escapeRE = /["'&<>]/;
|
|
function escapeHtml(string) {
|
|
const str = "" + string;
|
|
const match = escapeRE.exec(str);
|
|
if (!match) {
|
|
return str;
|
|
}
|
|
let html = "";
|
|
let escaped;
|
|
let index;
|
|
let lastIndex = 0;
|
|
for (index = match.index; index < str.length; index++) {
|
|
switch (str.charCodeAt(index)) {
|
|
case 34:
|
|
escaped = """;
|
|
break;
|
|
case 38:
|
|
escaped = "&";
|
|
break;
|
|
case 39:
|
|
escaped = "'";
|
|
break;
|
|
case 60:
|
|
escaped = "<";
|
|
break;
|
|
case 62:
|
|
escaped = ">";
|
|
break;
|
|
default:
|
|
continue;
|
|
}
|
|
if (lastIndex !== index) {
|
|
html += str.slice(lastIndex, index);
|
|
}
|
|
lastIndex = index + 1;
|
|
html += escaped;
|
|
}
|
|
return lastIndex !== index ? html + str.slice(lastIndex, index) : html;
|
|
}
|
|
const commentStripRE = /^-?>|<!--|-->|--!>|<!-$/g;
|
|
function escapeHtmlComment(src) {
|
|
return src.replace(commentStripRE, "");
|
|
}
|
|
const cssVarNameEscapeSymbolsRE = /[ !"#$%&'()*+,./:;<=>?@[\\\]^`{|}~]/g;
|
|
function getEscapedCssVarName(key, doubleEscape) {
|
|
return key.replace(cssVarNameEscapeSymbolsRE, s => doubleEscape ? s === '"' ? '\\\\\\"' : `\\\\${s}` : `\\${s}`);
|
|
}
|
|
function looseCompareArrays(a, b) {
|
|
if (a.length !== b.length) return false;
|
|
let equal = true;
|
|
for (let i = 0; equal && i < a.length; i++) {
|
|
equal = looseEqual(a[i], b[i]);
|
|
}
|
|
return equal;
|
|
}
|
|
function looseEqual(a, b) {
|
|
if (a === b) return true;
|
|
let aValidType = isDate(a);
|
|
let bValidType = isDate(b);
|
|
if (aValidType || bValidType) {
|
|
return aValidType && bValidType ? a.getTime() === b.getTime() : false;
|
|
}
|
|
aValidType = isSymbol(a);
|
|
bValidType = isSymbol(b);
|
|
if (aValidType || bValidType) {
|
|
return a === b;
|
|
}
|
|
aValidType = isArray(a);
|
|
bValidType = isArray(b);
|
|
if (aValidType || bValidType) {
|
|
return aValidType && bValidType ? looseCompareArrays(a, b) : false;
|
|
}
|
|
aValidType = isObject(a);
|
|
bValidType = isObject(b);
|
|
if (aValidType || bValidType) {
|
|
if (!aValidType || !bValidType) {
|
|
return false;
|
|
}
|
|
const aKeysCount = Object.keys(a).length;
|
|
const bKeysCount = Object.keys(b).length;
|
|
if (aKeysCount !== bKeysCount) {
|
|
return false;
|
|
}
|
|
for (const key in a) {
|
|
const aHasKey = a.hasOwnProperty(key);
|
|
const bHasKey = b.hasOwnProperty(key);
|
|
if (aHasKey && !bHasKey || !aHasKey && bHasKey || !looseEqual(a[key], b[key])) {
|
|
return false;
|
|
}
|
|
}
|
|
}
|
|
return String(a) === String(b);
|
|
}
|
|
function looseIndexOf(arr, val) {
|
|
return arr.findIndex(item => looseEqual(item, val));
|
|
}
|
|
const isRef = val => {
|
|
return !!(val && val["__v_isRef"] === true);
|
|
};
|
|
const toDisplayString = val => {
|
|
return isString(val) ? val : val == null ? "" : isArray(val) || isObject(val) && (val.toString === objectToString || !isFunction(val.toString)) ? isRef(val) ? toDisplayString(val.value) : JSON.stringify(val, replacer, 2) : String(val);
|
|
};
|
|
const replacer = (_key, val) => {
|
|
if (isRef(val)) {
|
|
return replacer(_key, val.value);
|
|
} else if (isMap(val)) {
|
|
return {
|
|
[`Map(${val.size})`]: [...val.entries()].reduce((entries, [key, val2], i) => {
|
|
entries[stringifySymbol(key, i) + " =>"] = val2;
|
|
return entries;
|
|
}, {})
|
|
};
|
|
} else if (isSet(val)) {
|
|
return {
|
|
[`Set(${val.size})`]: [...val.values()].map(v => stringifySymbol(v))
|
|
};
|
|
} else if (isSymbol(val)) {
|
|
return stringifySymbol(val);
|
|
} else if (isObject(val) && !isArray(val) && !isPlainObject(val)) {
|
|
return String(val);
|
|
}
|
|
return val;
|
|
};
|
|
const stringifySymbol = (v, i = "") => {
|
|
var _a;
|
|
return (
|
|
// Symbol.description in es2019+ so we need to cast here to pass
|
|
// the lib: es2016 check
|
|
isSymbol(v) ? `Symbol(${(_a = v.description) != null ? _a : i})` : v
|
|
);
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 4568:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var IS_PURE = __webpack_require__(8072);
|
|
var globalThis = __webpack_require__(4074);
|
|
var defineGlobalProperty = __webpack_require__(8028);
|
|
|
|
var SHARED = '__core-js_shared__';
|
|
var store = module.exports = globalThis[SHARED] || defineGlobalProperty(SHARED, {});
|
|
|
|
(store.versions || (store.versions = [])).push({
|
|
version: '3.36.0',
|
|
mode: IS_PURE ? 'pure' : 'global',
|
|
copyright: '© 2014-2024 Denis Pushkarev (zloirock.ru)',
|
|
license: 'https://github.com/zloirock/core-js/blob/v3.36.0/LICENSE',
|
|
source: 'https://github.com/zloirock/core-js'
|
|
});
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 4675:
|
|
/***/ (function(module) {
|
|
|
|
"use strict";
|
|
|
|
var $TypeError = TypeError;
|
|
var MAX_SAFE_INTEGER = 0x1FFFFFFFFFFFFF; // 2 ** 53 - 1 == 9007199254740991
|
|
|
|
module.exports = function (it) {
|
|
if (it > MAX_SAFE_INTEGER) throw $TypeError('Maximum allowed index exceeded');
|
|
return it;
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 4804:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var TO_STRING_TAG_SUPPORT = __webpack_require__(5079);
|
|
var isCallable = __webpack_require__(6450);
|
|
var classofRaw = __webpack_require__(1079);
|
|
var wellKnownSymbol = __webpack_require__(9760);
|
|
|
|
var TO_STRING_TAG = wellKnownSymbol('toStringTag');
|
|
var $Object = Object;
|
|
|
|
// ES3 wrong here
|
|
var CORRECT_ARGUMENTS = classofRaw(function () { return arguments; }()) === 'Arguments';
|
|
|
|
// fallback for IE11 Script Access Denied error
|
|
var tryGet = function (it, key) {
|
|
try {
|
|
return it[key];
|
|
} catch (error) { /* empty */ }
|
|
};
|
|
|
|
// getting tag from ES6+ `Object.prototype.toString`
|
|
module.exports = TO_STRING_TAG_SUPPORT ? classofRaw : function (it) {
|
|
var O, tag, result;
|
|
return it === undefined ? 'Undefined' : it === null ? 'Null'
|
|
// @@toStringTag case
|
|
: typeof (tag = tryGet(O = $Object(it), TO_STRING_TAG)) == 'string' ? tag
|
|
// builtinTag case
|
|
: CORRECT_ARGUMENTS ? classofRaw(O)
|
|
// ES3 arguments fallback
|
|
: (result = classofRaw(O)) === 'Object' && isCallable(O.callee) ? 'Arguments' : result;
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 4815:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var fails = __webpack_require__(4212);
|
|
var isCallable = __webpack_require__(6450);
|
|
|
|
var replacement = /#|\.prototype\./;
|
|
|
|
var isForced = function (feature, detection) {
|
|
var value = data[normalize(feature)];
|
|
return value === POLYFILL ? true
|
|
: value === NATIVE ? false
|
|
: isCallable(detection) ? fails(detection)
|
|
: !!detection;
|
|
};
|
|
|
|
var normalize = isForced.normalize = function (string) {
|
|
return String(string).replace(replacement, '.').toLowerCase();
|
|
};
|
|
|
|
var data = isForced.data = {};
|
|
var NATIVE = isForced.NATIVE = 'N';
|
|
var POLYFILL = isForced.POLYFILL = 'P';
|
|
|
|
module.exports = isForced;
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 4858:
|
|
/***/ (function(module) {
|
|
|
|
"use strict";
|
|
|
|
module.exports = {};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 4863:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var aCallable = __webpack_require__(8951);
|
|
var isNullOrUndefined = __webpack_require__(5832);
|
|
|
|
// `GetMethod` abstract operation
|
|
// https://tc39.es/ecma262/#sec-getmethod
|
|
module.exports = function (V, P) {
|
|
var func = V[P];
|
|
return isNullOrUndefined(func) ? undefined : aCallable(func);
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 4873:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var classof = __webpack_require__(1079);
|
|
|
|
// `IsArray` abstract operation
|
|
// https://tc39.es/ecma262/#sec-isarray
|
|
// eslint-disable-next-line es/no-array-isarray -- safe
|
|
module.exports = Array.isArray || function isArray(argument) {
|
|
return classof(argument) === 'Array';
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 4911:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var fails = __webpack_require__(4212);
|
|
|
|
// Detect IE8's incomplete defineProperty implementation
|
|
module.exports = !fails(function () {
|
|
// eslint-disable-next-line es/no-object-defineproperty -- required for testing
|
|
return Object.defineProperty({}, 1, { get: function () { return 7; } })[1] !== 7;
|
|
});
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 4912:
|
|
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var $ = __webpack_require__(8155);
|
|
var iterate = __webpack_require__(1663);
|
|
var aCallable = __webpack_require__(8951);
|
|
var anObject = __webpack_require__(6696);
|
|
var getIteratorDirect = __webpack_require__(8764);
|
|
|
|
// `Iterator.prototype.find` method
|
|
// https://github.com/tc39/proposal-iterator-helpers
|
|
$({ target: 'Iterator', proto: true, real: true }, {
|
|
find: function find(predicate) {
|
|
anObject(this);
|
|
aCallable(predicate);
|
|
var record = getIteratorDirect(this);
|
|
var counter = 0;
|
|
return iterate(record, function (value, stop) {
|
|
if (predicate(value, counter++)) return stop(value);
|
|
}, { IS_RECORD: true, INTERRUPTED: true }).result;
|
|
}
|
|
});
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 4978:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var NATIVE_BIND = __webpack_require__(8537);
|
|
|
|
var call = Function.prototype.call;
|
|
|
|
module.exports = NATIVE_BIND ? call.bind(call) : function () {
|
|
return call.apply(call, arguments);
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 5057:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var uncurryThis = __webpack_require__(1371);
|
|
|
|
// eslint-disable-next-line es/no-set -- safe
|
|
var SetPrototype = Set.prototype;
|
|
|
|
module.exports = {
|
|
// eslint-disable-next-line es/no-set -- safe
|
|
Set: Set,
|
|
add: uncurryThis(SetPrototype.add),
|
|
has: uncurryThis(SetPrototype.has),
|
|
remove: uncurryThis(SetPrototype['delete']),
|
|
proto: SetPrototype
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 5079:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var wellKnownSymbol = __webpack_require__(9760);
|
|
|
|
var TO_STRING_TAG = wellKnownSymbol('toStringTag');
|
|
var test = {};
|
|
|
|
test[TO_STRING_TAG] = 'z';
|
|
|
|
module.exports = String(test) === '[object z]';
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 5146:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var anObject = __webpack_require__(6696);
|
|
var iteratorClose = __webpack_require__(1298);
|
|
|
|
// call something on iterator step with safe closing on error
|
|
module.exports = function (iterator, fn, value, ENTRIES) {
|
|
try {
|
|
return ENTRIES ? fn(anObject(value)[0], value[1]) : fn(value);
|
|
} catch (error) {
|
|
iteratorClose(iterator, 'throw', error);
|
|
}
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 5172:
|
|
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) {
|
|
|
|
"use strict";
|
|
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
/* harmony export */ K: function() { return /* binding */ HOOK_SETUP; },
|
|
/* harmony export */ N: function() { return /* binding */ HOOK_PLUGIN_SETTINGS_SET; }
|
|
/* harmony export */ });
|
|
const HOOK_SETUP = 'devtools-plugin:setup';
|
|
const HOOK_PLUGIN_SETTINGS_SET = 'plugin:settings:set';
|
|
|
|
/***/ }),
|
|
|
|
/***/ 5181:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var global = __webpack_require__(4074);
|
|
var classof = __webpack_require__(1079);
|
|
|
|
module.exports = classof(global.process) === 'process';
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 5266:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var DESCRIPTORS = __webpack_require__(4911);
|
|
var definePropertyModule = __webpack_require__(8564);
|
|
var createPropertyDescriptor = __webpack_require__(5569);
|
|
|
|
module.exports = DESCRIPTORS ? function (object, key, value) {
|
|
return definePropertyModule.f(object, key, createPropertyDescriptor(1, value));
|
|
} : function (object, key, value) {
|
|
object[key] = value;
|
|
return object;
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 5319:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var call = __webpack_require__(4978);
|
|
var anObject = __webpack_require__(6696);
|
|
var getIteratorDirect = __webpack_require__(8764);
|
|
var getIteratorMethod = __webpack_require__(7312);
|
|
|
|
module.exports = function (obj, stringHandling) {
|
|
if (!stringHandling || typeof obj !== 'string') anObject(obj);
|
|
var method = getIteratorMethod(obj);
|
|
return getIteratorDirect(anObject(method !== undefined ? call(method, obj) : obj));
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 5412:
|
|
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var $ = __webpack_require__(8155);
|
|
var symmetricDifference = __webpack_require__(1531);
|
|
var setMethodAcceptSetLike = __webpack_require__(5645);
|
|
|
|
// `Set.prototype.symmetricDifference` method
|
|
// https://github.com/tc39/proposal-set-methods
|
|
$({ target: 'Set', proto: true, real: true, forced: !setMethodAcceptSetLike('symmetricDifference') }, {
|
|
symmetricDifference: symmetricDifference
|
|
});
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 5513:
|
|
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var $ = __webpack_require__(8155);
|
|
var toObject = __webpack_require__(1258);
|
|
var lengthOfArrayLike = __webpack_require__(4231);
|
|
var setArrayLength = __webpack_require__(1858);
|
|
var doesNotExceedSafeInteger = __webpack_require__(4675);
|
|
var fails = __webpack_require__(4212);
|
|
|
|
var INCORRECT_TO_LENGTH = fails(function () {
|
|
return [].push.call({ length: 0x100000000 }, 1) !== 4294967297;
|
|
});
|
|
|
|
// V8 <= 121 and Safari <= 15.4; FF < 23 throws InternalError
|
|
// https://bugs.chromium.org/p/v8/issues/detail?id=12681
|
|
var properErrorOnNonWritableLength = function () {
|
|
try {
|
|
// eslint-disable-next-line es/no-object-defineproperty -- safe
|
|
Object.defineProperty([], 'length', { writable: false }).push();
|
|
} catch (error) {
|
|
return error instanceof TypeError;
|
|
}
|
|
};
|
|
|
|
var FORCED = INCORRECT_TO_LENGTH || !properErrorOnNonWritableLength();
|
|
|
|
// `Array.prototype.push` method
|
|
// https://tc39.es/ecma262/#sec-array.prototype.push
|
|
$({ target: 'Array', proto: true, arity: 1, forced: FORCED }, {
|
|
// eslint-disable-next-line no-unused-vars -- required for `.length`
|
|
push: function push(item) {
|
|
var O = toObject(this);
|
|
var len = lengthOfArrayLike(O);
|
|
var argCount = arguments.length;
|
|
doesNotExceedSafeInteger(len + argCount);
|
|
for (var i = 0; i < argCount; i++) {
|
|
O[len] = arguments[i];
|
|
len++;
|
|
}
|
|
setArrayLength(O, len);
|
|
return len;
|
|
}
|
|
});
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 5569:
|
|
/***/ (function(module) {
|
|
|
|
"use strict";
|
|
|
|
module.exports = function (bitmap, value) {
|
|
return {
|
|
enumerable: !(bitmap & 1),
|
|
configurable: !(bitmap & 2),
|
|
writable: !(bitmap & 4),
|
|
value: value
|
|
};
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 5603:
|
|
/***/ (function(__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) {
|
|
|
|
"use strict";
|
|
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
/* harmony export */ A: function() { return /* binding */ bind; }
|
|
/* harmony export */ });
|
|
|
|
|
|
function bind(fn, thisArg) {
|
|
return function wrap() {
|
|
return fn.apply(thisArg, arguments);
|
|
};
|
|
}
|
|
|
|
/***/ }),
|
|
|
|
/***/ 5645:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var getBuiltIn = __webpack_require__(6054);
|
|
|
|
var createSetLike = function (size) {
|
|
return {
|
|
size: size,
|
|
has: function () {
|
|
return false;
|
|
},
|
|
keys: function () {
|
|
return {
|
|
next: function () {
|
|
return { done: true };
|
|
}
|
|
};
|
|
}
|
|
};
|
|
};
|
|
|
|
module.exports = function (name) {
|
|
var Set = getBuiltIn('Set');
|
|
try {
|
|
new Set()[name](createSetLike(0));
|
|
try {
|
|
// late spec change, early WebKit ~ Safari 17.0 beta implementation does not pass it
|
|
// https://github.com/tc39/proposal-set-methods/pull/88
|
|
new Set()[name](createSetLike(-1));
|
|
return false;
|
|
} catch (error2) {
|
|
return true;
|
|
}
|
|
} catch (error) {
|
|
return false;
|
|
}
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 5675:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var uncurryThis = __webpack_require__(1371);
|
|
|
|
var id = 0;
|
|
var postfix = Math.random();
|
|
var toString = uncurryThis(1.0.toString);
|
|
|
|
module.exports = function (key) {
|
|
return 'Symbol(' + (key === undefined ? '' : key) + ')_' + toString(++id + postfix, 36);
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 5729:
|
|
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var $ = __webpack_require__(8155);
|
|
var iterate = __webpack_require__(1663);
|
|
var aCallable = __webpack_require__(8951);
|
|
var anObject = __webpack_require__(6696);
|
|
var getIteratorDirect = __webpack_require__(8764);
|
|
|
|
var $TypeError = TypeError;
|
|
|
|
// `Iterator.prototype.reduce` method
|
|
// https://github.com/tc39/proposal-iterator-helpers
|
|
$({ target: 'Iterator', proto: true, real: true }, {
|
|
reduce: function reduce(reducer /* , initialValue */) {
|
|
anObject(this);
|
|
aCallable(reducer);
|
|
var record = getIteratorDirect(this);
|
|
var noInitial = arguments.length < 2;
|
|
var accumulator = noInitial ? undefined : arguments[1];
|
|
var counter = 0;
|
|
iterate(record, function (value) {
|
|
if (noInitial) {
|
|
noInitial = false;
|
|
accumulator = value;
|
|
} else {
|
|
accumulator = reducer(accumulator, value, counter);
|
|
}
|
|
counter++;
|
|
}, { IS_RECORD: true });
|
|
if (noInitial) throw new $TypeError('Reduce of empty iterator with no initial value');
|
|
return accumulator;
|
|
}
|
|
});
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 5806:
|
|
/***/ (function(__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) {
|
|
|
|
"use strict";
|
|
/* harmony import */ var core_js_modules_es_array_push_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(5513);
|
|
/* harmony import */ var core_js_modules_esnext_iterator_constructor_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(7195);
|
|
/* harmony import */ var core_js_modules_esnext_iterator_map_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(793);
|
|
/* harmony import */ var _toFormData_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(6631);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
/**
|
|
* It encodes a string by replacing all characters that are not in the unreserved set with
|
|
* their percent-encoded equivalents
|
|
*
|
|
* @param {string} str - The string to encode.
|
|
*
|
|
* @returns {string} The encoded string.
|
|
*/
|
|
function encode(str) {
|
|
const charMap = {
|
|
'!': '%21',
|
|
"'": '%27',
|
|
'(': '%28',
|
|
')': '%29',
|
|
'~': '%7E',
|
|
'%20': '+',
|
|
'%00': '\x00'
|
|
};
|
|
return encodeURIComponent(str).replace(/[!'()~]|%20|%00/g, function replacer(match) {
|
|
return charMap[match];
|
|
});
|
|
}
|
|
|
|
/**
|
|
* It takes a params object and converts it to a FormData object
|
|
*
|
|
* @param {Object<string, any>} params - The parameters to be converted to a FormData object.
|
|
* @param {Object<string, any>} options - The options object passed to the Axios constructor.
|
|
*
|
|
* @returns {void}
|
|
*/
|
|
function AxiosURLSearchParams(params, options) {
|
|
this._pairs = [];
|
|
params && (0,_toFormData_js__WEBPACK_IMPORTED_MODULE_3__/* ["default"] */ .A)(params, this, options);
|
|
}
|
|
const prototype = AxiosURLSearchParams.prototype;
|
|
prototype.append = function append(name, value) {
|
|
this._pairs.push([name, value]);
|
|
};
|
|
prototype.toString = function toString(encoder) {
|
|
const _encode = encoder ? function (value) {
|
|
return encoder.call(this, value, encode);
|
|
} : encode;
|
|
return this._pairs.map(function each(pair) {
|
|
return _encode(pair[0]) + '=' + _encode(pair[1]);
|
|
}, '').join('&');
|
|
};
|
|
/* harmony default export */ __webpack_exports__.A = (AxiosURLSearchParams);
|
|
|
|
/***/ }),
|
|
|
|
/***/ 5813:
|
|
/***/ (function(__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) {
|
|
|
|
"use strict";
|
|
/* harmony import */ var core_js_modules_es_array_push_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(5513);
|
|
/* harmony import */ var core_js_modules_es_array_buffer_detached_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(2952);
|
|
/* harmony import */ var core_js_modules_es_array_buffer_transfer_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(6665);
|
|
/* harmony import */ var core_js_modules_es_array_buffer_transfer_to_fixed_length_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(1961);
|
|
/* harmony import */ var core_js_modules_es_typed_array_to_reversed_js__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(978);
|
|
/* harmony import */ var core_js_modules_es_typed_array_to_sorted_js__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(6949);
|
|
/* harmony import */ var core_js_modules_es_typed_array_with_js__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(1842);
|
|
/* harmony import */ var core_js_modules_esnext_iterator_constructor_js__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(7195);
|
|
/* harmony import */ var core_js_modules_esnext_iterator_for_each_js__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(680);
|
|
/* harmony import */ var _helpers_bind_js__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(5603);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// utils is a library of generic helper functions non-specific to axios
|
|
|
|
const {
|
|
toString
|
|
} = Object.prototype;
|
|
const {
|
|
getPrototypeOf
|
|
} = Object;
|
|
const kindOf = (cache => thing => {
|
|
const str = toString.call(thing);
|
|
return cache[str] || (cache[str] = str.slice(8, -1).toLowerCase());
|
|
})(Object.create(null));
|
|
const kindOfTest = type => {
|
|
type = type.toLowerCase();
|
|
return thing => kindOf(thing) === type;
|
|
};
|
|
const typeOfTest = type => thing => typeof thing === type;
|
|
|
|
/**
|
|
* Determine if a value is an Array
|
|
*
|
|
* @param {Object} val The value to test
|
|
*
|
|
* @returns {boolean} True if value is an Array, otherwise false
|
|
*/
|
|
const {
|
|
isArray
|
|
} = Array;
|
|
|
|
/**
|
|
* Determine if a value is undefined
|
|
*
|
|
* @param {*} val The value to test
|
|
*
|
|
* @returns {boolean} True if the value is undefined, otherwise false
|
|
*/
|
|
const isUndefined = typeOfTest('undefined');
|
|
|
|
/**
|
|
* Determine if a value is a Buffer
|
|
*
|
|
* @param {*} val The value to test
|
|
*
|
|
* @returns {boolean} True if value is a Buffer, otherwise false
|
|
*/
|
|
function isBuffer(val) {
|
|
return val !== null && !isUndefined(val) && val.constructor !== null && !isUndefined(val.constructor) && isFunction(val.constructor.isBuffer) && val.constructor.isBuffer(val);
|
|
}
|
|
|
|
/**
|
|
* Determine if a value is an ArrayBuffer
|
|
*
|
|
* @param {*} val The value to test
|
|
*
|
|
* @returns {boolean} True if value is an ArrayBuffer, otherwise false
|
|
*/
|
|
const isArrayBuffer = kindOfTest('ArrayBuffer');
|
|
|
|
/**
|
|
* Determine if a value is a view on an ArrayBuffer
|
|
*
|
|
* @param {*} val The value to test
|
|
*
|
|
* @returns {boolean} True if value is a view on an ArrayBuffer, otherwise false
|
|
*/
|
|
function isArrayBufferView(val) {
|
|
let result;
|
|
if (typeof ArrayBuffer !== 'undefined' && ArrayBuffer.isView) {
|
|
result = ArrayBuffer.isView(val);
|
|
} else {
|
|
result = val && val.buffer && isArrayBuffer(val.buffer);
|
|
}
|
|
return result;
|
|
}
|
|
|
|
/**
|
|
* Determine if a value is a String
|
|
*
|
|
* @param {*} val The value to test
|
|
*
|
|
* @returns {boolean} True if value is a String, otherwise false
|
|
*/
|
|
const isString = typeOfTest('string');
|
|
|
|
/**
|
|
* Determine if a value is a Function
|
|
*
|
|
* @param {*} val The value to test
|
|
* @returns {boolean} True if value is a Function, otherwise false
|
|
*/
|
|
const isFunction = typeOfTest('function');
|
|
|
|
/**
|
|
* Determine if a value is a Number
|
|
*
|
|
* @param {*} val The value to test
|
|
*
|
|
* @returns {boolean} True if value is a Number, otherwise false
|
|
*/
|
|
const isNumber = typeOfTest('number');
|
|
|
|
/**
|
|
* Determine if a value is an Object
|
|
*
|
|
* @param {*} thing The value to test
|
|
*
|
|
* @returns {boolean} True if value is an Object, otherwise false
|
|
*/
|
|
const isObject = thing => thing !== null && typeof thing === 'object';
|
|
|
|
/**
|
|
* Determine if a value is a Boolean
|
|
*
|
|
* @param {*} thing The value to test
|
|
* @returns {boolean} True if value is a Boolean, otherwise false
|
|
*/
|
|
const isBoolean = thing => thing === true || thing === false;
|
|
|
|
/**
|
|
* Determine if a value is a plain Object
|
|
*
|
|
* @param {*} val The value to test
|
|
*
|
|
* @returns {boolean} True if value is a plain Object, otherwise false
|
|
*/
|
|
const isPlainObject = val => {
|
|
if (kindOf(val) !== 'object') {
|
|
return false;
|
|
}
|
|
const prototype = getPrototypeOf(val);
|
|
return (prototype === null || prototype === Object.prototype || Object.getPrototypeOf(prototype) === null) && !(Symbol.toStringTag in val) && !(Symbol.iterator in val);
|
|
};
|
|
|
|
/**
|
|
* Determine if a value is a Date
|
|
*
|
|
* @param {*} val The value to test
|
|
*
|
|
* @returns {boolean} True if value is a Date, otherwise false
|
|
*/
|
|
const isDate = kindOfTest('Date');
|
|
|
|
/**
|
|
* Determine if a value is a File
|
|
*
|
|
* @param {*} val The value to test
|
|
*
|
|
* @returns {boolean} True if value is a File, otherwise false
|
|
*/
|
|
const isFile = kindOfTest('File');
|
|
|
|
/**
|
|
* Determine if a value is a Blob
|
|
*
|
|
* @param {*} val The value to test
|
|
*
|
|
* @returns {boolean} True if value is a Blob, otherwise false
|
|
*/
|
|
const isBlob = kindOfTest('Blob');
|
|
|
|
/**
|
|
* Determine if a value is a FileList
|
|
*
|
|
* @param {*} val The value to test
|
|
*
|
|
* @returns {boolean} True if value is a File, otherwise false
|
|
*/
|
|
const isFileList = kindOfTest('FileList');
|
|
|
|
/**
|
|
* Determine if a value is a Stream
|
|
*
|
|
* @param {*} val The value to test
|
|
*
|
|
* @returns {boolean} True if value is a Stream, otherwise false
|
|
*/
|
|
const isStream = val => isObject(val) && isFunction(val.pipe);
|
|
|
|
/**
|
|
* Determine if a value is a FormData
|
|
*
|
|
* @param {*} thing The value to test
|
|
*
|
|
* @returns {boolean} True if value is an FormData, otherwise false
|
|
*/
|
|
const isFormData = thing => {
|
|
let kind;
|
|
return thing && (typeof FormData === 'function' && thing instanceof FormData || isFunction(thing.append) && ((kind = kindOf(thing)) === 'formdata' ||
|
|
// detect form-data instance
|
|
kind === 'object' && isFunction(thing.toString) && thing.toString() === '[object FormData]'));
|
|
};
|
|
|
|
/**
|
|
* Determine if a value is a URLSearchParams object
|
|
*
|
|
* @param {*} val The value to test
|
|
*
|
|
* @returns {boolean} True if value is a URLSearchParams object, otherwise false
|
|
*/
|
|
const isURLSearchParams = kindOfTest('URLSearchParams');
|
|
|
|
/**
|
|
* Trim excess whitespace off the beginning and end of a string
|
|
*
|
|
* @param {String} str The String to trim
|
|
*
|
|
* @returns {String} The String freed of excess whitespace
|
|
*/
|
|
const trim = str => str.trim ? str.trim() : str.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g, '');
|
|
|
|
/**
|
|
* Iterate over an Array or an Object invoking a function for each item.
|
|
*
|
|
* If `obj` is an Array callback will be called passing
|
|
* the value, index, and complete array for each item.
|
|
*
|
|
* If 'obj' is an Object callback will be called passing
|
|
* the value, key, and complete object for each property.
|
|
*
|
|
* @param {Object|Array} obj The object to iterate
|
|
* @param {Function} fn The callback to invoke for each item
|
|
*
|
|
* @param {Boolean} [allOwnKeys = false]
|
|
* @returns {any}
|
|
*/
|
|
function forEach(obj, fn, {
|
|
allOwnKeys = false
|
|
} = {}) {
|
|
// Don't bother if no value provided
|
|
if (obj === null || typeof obj === 'undefined') {
|
|
return;
|
|
}
|
|
let i;
|
|
let l;
|
|
|
|
// Force an array if not already something iterable
|
|
if (typeof obj !== 'object') {
|
|
/*eslint no-param-reassign:0*/
|
|
obj = [obj];
|
|
}
|
|
if (isArray(obj)) {
|
|
// Iterate over array values
|
|
for (i = 0, l = obj.length; i < l; i++) {
|
|
fn.call(null, obj[i], i, obj);
|
|
}
|
|
} else {
|
|
// Iterate over object keys
|
|
const keys = allOwnKeys ? Object.getOwnPropertyNames(obj) : Object.keys(obj);
|
|
const len = keys.length;
|
|
let key;
|
|
for (i = 0; i < len; i++) {
|
|
key = keys[i];
|
|
fn.call(null, obj[key], key, obj);
|
|
}
|
|
}
|
|
}
|
|
function findKey(obj, key) {
|
|
key = key.toLowerCase();
|
|
const keys = Object.keys(obj);
|
|
let i = keys.length;
|
|
let _key;
|
|
while (i-- > 0) {
|
|
_key = keys[i];
|
|
if (key === _key.toLowerCase()) {
|
|
return _key;
|
|
}
|
|
}
|
|
return null;
|
|
}
|
|
const _global = (() => {
|
|
/*eslint no-undef:0*/
|
|
if (typeof globalThis !== "undefined") return globalThis;
|
|
return typeof self !== "undefined" ? self : typeof window !== 'undefined' ? window : global;
|
|
})();
|
|
const isContextDefined = context => !isUndefined(context) && context !== _global;
|
|
|
|
/**
|
|
* Accepts varargs expecting each argument to be an object, then
|
|
* immutably merges the properties of each object and returns result.
|
|
*
|
|
* When multiple objects contain the same key the later object in
|
|
* the arguments list will take precedence.
|
|
*
|
|
* Example:
|
|
*
|
|
* ```js
|
|
* var result = merge({foo: 123}, {foo: 456});
|
|
* console.log(result.foo); // outputs 456
|
|
* ```
|
|
*
|
|
* @param {Object} obj1 Object to merge
|
|
*
|
|
* @returns {Object} Result of all merge properties
|
|
*/
|
|
function merge(/* obj1, obj2, obj3, ... */
|
|
) {
|
|
const {
|
|
caseless
|
|
} = isContextDefined(this) && this || {};
|
|
const result = {};
|
|
const assignValue = (val, key) => {
|
|
const targetKey = caseless && findKey(result, key) || key;
|
|
if (isPlainObject(result[targetKey]) && isPlainObject(val)) {
|
|
result[targetKey] = merge(result[targetKey], val);
|
|
} else if (isPlainObject(val)) {
|
|
result[targetKey] = merge({}, val);
|
|
} else if (isArray(val)) {
|
|
result[targetKey] = val.slice();
|
|
} else {
|
|
result[targetKey] = val;
|
|
}
|
|
};
|
|
for (let i = 0, l = arguments.length; i < l; i++) {
|
|
arguments[i] && forEach(arguments[i], assignValue);
|
|
}
|
|
return result;
|
|
}
|
|
|
|
/**
|
|
* Extends object a by mutably adding to it the properties of object b.
|
|
*
|
|
* @param {Object} a The object to be extended
|
|
* @param {Object} b The object to copy properties from
|
|
* @param {Object} thisArg The object to bind function to
|
|
*
|
|
* @param {Boolean} [allOwnKeys]
|
|
* @returns {Object} The resulting value of object a
|
|
*/
|
|
const extend = (a, b, thisArg, {
|
|
allOwnKeys
|
|
} = {}) => {
|
|
forEach(b, (val, key) => {
|
|
if (thisArg && isFunction(val)) {
|
|
a[key] = (0,_helpers_bind_js__WEBPACK_IMPORTED_MODULE_9__/* ["default"] */ .A)(val, thisArg);
|
|
} else {
|
|
a[key] = val;
|
|
}
|
|
}, {
|
|
allOwnKeys
|
|
});
|
|
return a;
|
|
};
|
|
|
|
/**
|
|
* Remove byte order marker. This catches EF BB BF (the UTF-8 BOM)
|
|
*
|
|
* @param {string} content with BOM
|
|
*
|
|
* @returns {string} content value without BOM
|
|
*/
|
|
const stripBOM = content => {
|
|
if (content.charCodeAt(0) === 0xFEFF) {
|
|
content = content.slice(1);
|
|
}
|
|
return content;
|
|
};
|
|
|
|
/**
|
|
* Inherit the prototype methods from one constructor into another
|
|
* @param {function} constructor
|
|
* @param {function} superConstructor
|
|
* @param {object} [props]
|
|
* @param {object} [descriptors]
|
|
*
|
|
* @returns {void}
|
|
*/
|
|
const inherits = (constructor, superConstructor, props, descriptors) => {
|
|
constructor.prototype = Object.create(superConstructor.prototype, descriptors);
|
|
constructor.prototype.constructor = constructor;
|
|
Object.defineProperty(constructor, 'super', {
|
|
value: superConstructor.prototype
|
|
});
|
|
props && Object.assign(constructor.prototype, props);
|
|
};
|
|
|
|
/**
|
|
* Resolve object with deep prototype chain to a flat object
|
|
* @param {Object} sourceObj source object
|
|
* @param {Object} [destObj]
|
|
* @param {Function|Boolean} [filter]
|
|
* @param {Function} [propFilter]
|
|
*
|
|
* @returns {Object}
|
|
*/
|
|
const toFlatObject = (sourceObj, destObj, filter, propFilter) => {
|
|
let props;
|
|
let i;
|
|
let prop;
|
|
const merged = {};
|
|
destObj = destObj || {};
|
|
// eslint-disable-next-line no-eq-null,eqeqeq
|
|
if (sourceObj == null) return destObj;
|
|
do {
|
|
props = Object.getOwnPropertyNames(sourceObj);
|
|
i = props.length;
|
|
while (i-- > 0) {
|
|
prop = props[i];
|
|
if ((!propFilter || propFilter(prop, sourceObj, destObj)) && !merged[prop]) {
|
|
destObj[prop] = sourceObj[prop];
|
|
merged[prop] = true;
|
|
}
|
|
}
|
|
sourceObj = filter !== false && getPrototypeOf(sourceObj);
|
|
} while (sourceObj && (!filter || filter(sourceObj, destObj)) && sourceObj !== Object.prototype);
|
|
return destObj;
|
|
};
|
|
|
|
/**
|
|
* Determines whether a string ends with the characters of a specified string
|
|
*
|
|
* @param {String} str
|
|
* @param {String} searchString
|
|
* @param {Number} [position= 0]
|
|
*
|
|
* @returns {boolean}
|
|
*/
|
|
const endsWith = (str, searchString, position) => {
|
|
str = String(str);
|
|
if (position === undefined || position > str.length) {
|
|
position = str.length;
|
|
}
|
|
position -= searchString.length;
|
|
const lastIndex = str.indexOf(searchString, position);
|
|
return lastIndex !== -1 && lastIndex === position;
|
|
};
|
|
|
|
/**
|
|
* Returns new array from array like object or null if failed
|
|
*
|
|
* @param {*} [thing]
|
|
*
|
|
* @returns {?Array}
|
|
*/
|
|
const toArray = thing => {
|
|
if (!thing) return null;
|
|
if (isArray(thing)) return thing;
|
|
let i = thing.length;
|
|
if (!isNumber(i)) return null;
|
|
const arr = new Array(i);
|
|
while (i-- > 0) {
|
|
arr[i] = thing[i];
|
|
}
|
|
return arr;
|
|
};
|
|
|
|
/**
|
|
* Checking if the Uint8Array exists and if it does, it returns a function that checks if the
|
|
* thing passed in is an instance of Uint8Array
|
|
*
|
|
* @param {TypedArray}
|
|
*
|
|
* @returns {Array}
|
|
*/
|
|
// eslint-disable-next-line func-names
|
|
const isTypedArray = (TypedArray => {
|
|
// eslint-disable-next-line func-names
|
|
return thing => {
|
|
return TypedArray && thing instanceof TypedArray;
|
|
};
|
|
})(typeof Uint8Array !== 'undefined' && getPrototypeOf(Uint8Array));
|
|
|
|
/**
|
|
* For each entry in the object, call the function with the key and value.
|
|
*
|
|
* @param {Object<any, any>} obj - The object to iterate over.
|
|
* @param {Function} fn - The function to call for each entry.
|
|
*
|
|
* @returns {void}
|
|
*/
|
|
const forEachEntry = (obj, fn) => {
|
|
const generator = obj && obj[Symbol.iterator];
|
|
const iterator = generator.call(obj);
|
|
let result;
|
|
while ((result = iterator.next()) && !result.done) {
|
|
const pair = result.value;
|
|
fn.call(obj, pair[0], pair[1]);
|
|
}
|
|
};
|
|
|
|
/**
|
|
* It takes a regular expression and a string, and returns an array of all the matches
|
|
*
|
|
* @param {string} regExp - The regular expression to match against.
|
|
* @param {string} str - The string to search.
|
|
*
|
|
* @returns {Array<boolean>}
|
|
*/
|
|
const matchAll = (regExp, str) => {
|
|
let matches;
|
|
const arr = [];
|
|
while ((matches = regExp.exec(str)) !== null) {
|
|
arr.push(matches);
|
|
}
|
|
return arr;
|
|
};
|
|
|
|
/* Checking if the kindOfTest function returns true when passed an HTMLFormElement. */
|
|
const isHTMLForm = kindOfTest('HTMLFormElement');
|
|
const toCamelCase = str => {
|
|
return str.toLowerCase().replace(/[-_\s]([a-z\d])(\w*)/g, function replacer(m, p1, p2) {
|
|
return p1.toUpperCase() + p2;
|
|
});
|
|
};
|
|
|
|
/* Creating a function that will check if an object has a property. */
|
|
const hasOwnProperty = (({
|
|
hasOwnProperty
|
|
}) => (obj, prop) => hasOwnProperty.call(obj, prop))(Object.prototype);
|
|
|
|
/**
|
|
* Determine if a value is a RegExp object
|
|
*
|
|
* @param {*} val The value to test
|
|
*
|
|
* @returns {boolean} True if value is a RegExp object, otherwise false
|
|
*/
|
|
const isRegExp = kindOfTest('RegExp');
|
|
const reduceDescriptors = (obj, reducer) => {
|
|
const descriptors = Object.getOwnPropertyDescriptors(obj);
|
|
const reducedDescriptors = {};
|
|
forEach(descriptors, (descriptor, name) => {
|
|
let ret;
|
|
if ((ret = reducer(descriptor, name, obj)) !== false) {
|
|
reducedDescriptors[name] = ret || descriptor;
|
|
}
|
|
});
|
|
Object.defineProperties(obj, reducedDescriptors);
|
|
};
|
|
|
|
/**
|
|
* Makes all methods read-only
|
|
* @param {Object} obj
|
|
*/
|
|
|
|
const freezeMethods = obj => {
|
|
reduceDescriptors(obj, (descriptor, name) => {
|
|
// skip restricted props in strict mode
|
|
if (isFunction(obj) && ['arguments', 'caller', 'callee'].indexOf(name) !== -1) {
|
|
return false;
|
|
}
|
|
const value = obj[name];
|
|
if (!isFunction(value)) return;
|
|
descriptor.enumerable = false;
|
|
if ('writable' in descriptor) {
|
|
descriptor.writable = false;
|
|
return;
|
|
}
|
|
if (!descriptor.set) {
|
|
descriptor.set = () => {
|
|
throw Error('Can not rewrite read-only method \'' + name + '\'');
|
|
};
|
|
}
|
|
});
|
|
};
|
|
const toObjectSet = (arrayOrString, delimiter) => {
|
|
const obj = {};
|
|
const define = arr => {
|
|
arr.forEach(value => {
|
|
obj[value] = true;
|
|
});
|
|
};
|
|
isArray(arrayOrString) ? define(arrayOrString) : define(String(arrayOrString).split(delimiter));
|
|
return obj;
|
|
};
|
|
const noop = () => {};
|
|
const toFiniteNumber = (value, defaultValue) => {
|
|
value = +value;
|
|
return Number.isFinite(value) ? value : defaultValue;
|
|
};
|
|
const ALPHA = 'abcdefghijklmnopqrstuvwxyz';
|
|
const DIGIT = '0123456789';
|
|
const ALPHABET = {
|
|
DIGIT,
|
|
ALPHA,
|
|
ALPHA_DIGIT: ALPHA + ALPHA.toUpperCase() + DIGIT
|
|
};
|
|
const generateString = (size = 16, alphabet = ALPHABET.ALPHA_DIGIT) => {
|
|
let str = '';
|
|
const {
|
|
length
|
|
} = alphabet;
|
|
while (size--) {
|
|
str += alphabet[Math.random() * length | 0];
|
|
}
|
|
return str;
|
|
};
|
|
|
|
/**
|
|
* If the thing is a FormData object, return true, otherwise return false.
|
|
*
|
|
* @param {unknown} thing - The thing to check.
|
|
*
|
|
* @returns {boolean}
|
|
*/
|
|
function isSpecCompliantForm(thing) {
|
|
return !!(thing && isFunction(thing.append) && thing[Symbol.toStringTag] === 'FormData' && thing[Symbol.iterator]);
|
|
}
|
|
const toJSONObject = obj => {
|
|
const stack = new Array(10);
|
|
const visit = (source, i) => {
|
|
if (isObject(source)) {
|
|
if (stack.indexOf(source) >= 0) {
|
|
return;
|
|
}
|
|
if (!('toJSON' in source)) {
|
|
stack[i] = source;
|
|
const target = isArray(source) ? [] : {};
|
|
forEach(source, (value, key) => {
|
|
const reducedValue = visit(value, i + 1);
|
|
!isUndefined(reducedValue) && (target[key] = reducedValue);
|
|
});
|
|
stack[i] = undefined;
|
|
return target;
|
|
}
|
|
}
|
|
return source;
|
|
};
|
|
return visit(obj, 0);
|
|
};
|
|
const isAsyncFn = kindOfTest('AsyncFunction');
|
|
const isThenable = thing => thing && (isObject(thing) || isFunction(thing)) && isFunction(thing.then) && isFunction(thing.catch);
|
|
/* harmony default export */ __webpack_exports__.A = ({
|
|
isArray,
|
|
isArrayBuffer,
|
|
isBuffer,
|
|
isFormData,
|
|
isArrayBufferView,
|
|
isString,
|
|
isNumber,
|
|
isBoolean,
|
|
isObject,
|
|
isPlainObject,
|
|
isUndefined,
|
|
isDate,
|
|
isFile,
|
|
isBlob,
|
|
isRegExp,
|
|
isFunction,
|
|
isStream,
|
|
isURLSearchParams,
|
|
isTypedArray,
|
|
isFileList,
|
|
forEach,
|
|
merge,
|
|
extend,
|
|
trim,
|
|
stripBOM,
|
|
inherits,
|
|
toFlatObject,
|
|
kindOf,
|
|
kindOfTest,
|
|
endsWith,
|
|
toArray,
|
|
forEachEntry,
|
|
matchAll,
|
|
isHTMLForm,
|
|
hasOwnProperty,
|
|
hasOwnProp: hasOwnProperty,
|
|
// an alias to avoid ESLint no-prototype-builtins detection
|
|
reduceDescriptors,
|
|
freezeMethods,
|
|
toObjectSet,
|
|
toCamelCase,
|
|
noop,
|
|
toFiniteNumber,
|
|
findKey,
|
|
global: _global,
|
|
isContextDefined,
|
|
ALPHABET,
|
|
generateString,
|
|
isSpecCompliantForm,
|
|
toJSONObject,
|
|
isAsyncFn,
|
|
isThenable
|
|
});
|
|
|
|
/***/ }),
|
|
|
|
/***/ 5830:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
// toObject with fallback for non-array-like ES3 strings
|
|
var IndexedObject = __webpack_require__(8618);
|
|
var requireObjectCoercible = __webpack_require__(2967);
|
|
|
|
module.exports = function (it) {
|
|
return IndexedObject(requireObjectCoercible(it));
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 5832:
|
|
/***/ (function(module) {
|
|
|
|
"use strict";
|
|
|
|
// we can't use just `it == null` since of `document.all` special case
|
|
// https://tc39.es/ecma262/#sec-IsHTMLDDA-internal-slot-aec
|
|
module.exports = function (it) {
|
|
return it === null || it === undefined;
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 5904:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var store = __webpack_require__(4568);
|
|
|
|
module.exports = function (key, value) {
|
|
return store[key] || (store[key] = value || {});
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 6054:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var global = __webpack_require__(4074);
|
|
var isCallable = __webpack_require__(6450);
|
|
|
|
var aFunction = function (argument) {
|
|
return isCallable(argument) ? argument : undefined;
|
|
};
|
|
|
|
module.exports = function (namespace, method) {
|
|
return arguments.length < 2 ? aFunction(global[namespace]) : global[namespace] && global[namespace][method];
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 6071:
|
|
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var $ = __webpack_require__(8155);
|
|
var iterate = __webpack_require__(1663);
|
|
var aCallable = __webpack_require__(8951);
|
|
var anObject = __webpack_require__(6696);
|
|
var getIteratorDirect = __webpack_require__(8764);
|
|
|
|
// `Iterator.prototype.some` method
|
|
// https://github.com/tc39/proposal-iterator-helpers
|
|
$({ target: 'Iterator', proto: true, real: true }, {
|
|
some: function some(predicate) {
|
|
anObject(this);
|
|
aCallable(predicate);
|
|
var record = getIteratorDirect(this);
|
|
var counter = 0;
|
|
return iterate(record, function (value, stop) {
|
|
if (predicate(value, counter++)) return stop();
|
|
}, { IS_RECORD: true, INTERRUPTED: true }).stopped;
|
|
}
|
|
});
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 6087:
|
|
/***/ (function(__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) {
|
|
|
|
"use strict";
|
|
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
/* harmony export */ A: function() { return /* binding */ settle; }
|
|
/* harmony export */ });
|
|
/* harmony import */ var _AxiosError_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(956);
|
|
|
|
|
|
|
|
|
|
/**
|
|
* Resolve or reject a Promise based on response status.
|
|
*
|
|
* @param {Function} resolve A function that resolves the promise.
|
|
* @param {Function} reject A function that rejects the promise.
|
|
* @param {object} response The response.
|
|
*
|
|
* @returns {object} The response.
|
|
*/
|
|
function settle(resolve, reject, response) {
|
|
const validateStatus = response.config.validateStatus;
|
|
if (!response.status || !validateStatus || validateStatus(response.status)) {
|
|
resolve(response);
|
|
} else {
|
|
reject(new _AxiosError_js__WEBPACK_IMPORTED_MODULE_0__/* ["default"] */ .A('Request failed with status code ' + response.status, [_AxiosError_js__WEBPACK_IMPORTED_MODULE_0__/* ["default"] */ .A.ERR_BAD_REQUEST, _AxiosError_js__WEBPACK_IMPORTED_MODULE_0__/* ["default"] */ .A.ERR_BAD_RESPONSE][Math.floor(response.status / 100) - 4], response.config, response.request, response));
|
|
}
|
|
}
|
|
|
|
/***/ }),
|
|
|
|
/***/ 6122:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var lengthOfArrayLike = __webpack_require__(4231);
|
|
var toIntegerOrInfinity = __webpack_require__(9106);
|
|
|
|
var $RangeError = RangeError;
|
|
|
|
// https://tc39.es/proposal-change-array-by-copy/#sec-array.prototype.with
|
|
// https://tc39.es/proposal-change-array-by-copy/#sec-%typedarray%.prototype.with
|
|
module.exports = function (O, C, index, value) {
|
|
var len = lengthOfArrayLike(O);
|
|
var relativeIndex = toIntegerOrInfinity(index);
|
|
var actualIndex = relativeIndex < 0 ? len + relativeIndex : relativeIndex;
|
|
if (actualIndex >= len || actualIndex < 0) throw new $RangeError('Incorrect index');
|
|
var A = new C(len);
|
|
var k = 0;
|
|
for (; k < len; k++) A[k] = k === actualIndex ? value : O[k];
|
|
return A;
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 6162:
|
|
/***/ (function(__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) {
|
|
|
|
"use strict";
|
|
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
/* harmony export */ A: function() { return /* binding */ transformData; }
|
|
/* harmony export */ });
|
|
/* harmony import */ var core_js_modules_esnext_iterator_constructor_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(7195);
|
|
/* harmony import */ var core_js_modules_esnext_iterator_for_each_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(680);
|
|
/* harmony import */ var _utils_js__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(5813);
|
|
/* harmony import */ var _defaults_index_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(7719);
|
|
/* harmony import */ var _core_AxiosHeaders_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(292);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
/**
|
|
* Transform the data for a request or a response
|
|
*
|
|
* @param {Array|Function} fns A single function or Array of functions
|
|
* @param {?Object} response The response object
|
|
*
|
|
* @returns {*} The resulting transformed data
|
|
*/
|
|
function transformData(fns, response) {
|
|
const config = this || _defaults_index_js__WEBPACK_IMPORTED_MODULE_2__/* ["default"] */ .A;
|
|
const context = response || config;
|
|
const headers = _core_AxiosHeaders_js__WEBPACK_IMPORTED_MODULE_3__/* ["default"] */ .A.from(context.headers);
|
|
let data = context.data;
|
|
_utils_js__WEBPACK_IMPORTED_MODULE_4__/* ["default"] */ .A.forEach(fns, function transform(fn) {
|
|
data = fn.call(config, data, headers.normalize(), response ? response.status : undefined);
|
|
});
|
|
headers.normalize();
|
|
return data;
|
|
}
|
|
|
|
/***/ }),
|
|
|
|
/***/ 6180:
|
|
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var $ = __webpack_require__(8155);
|
|
var global = __webpack_require__(4074);
|
|
var getBuiltIn = __webpack_require__(6054);
|
|
var createPropertyDescriptor = __webpack_require__(5569);
|
|
var defineProperty = (__webpack_require__(8564).f);
|
|
var hasOwn = __webpack_require__(1396);
|
|
var anInstance = __webpack_require__(1476);
|
|
var inheritIfRequired = __webpack_require__(6188);
|
|
var normalizeStringArgument = __webpack_require__(7352);
|
|
var DOMExceptionConstants = __webpack_require__(4497);
|
|
var clearErrorStack = __webpack_require__(7994);
|
|
var DESCRIPTORS = __webpack_require__(4911);
|
|
var IS_PURE = __webpack_require__(8072);
|
|
|
|
var DOM_EXCEPTION = 'DOMException';
|
|
var Error = getBuiltIn('Error');
|
|
var NativeDOMException = getBuiltIn(DOM_EXCEPTION);
|
|
|
|
var $DOMException = function DOMException() {
|
|
anInstance(this, DOMExceptionPrototype);
|
|
var argumentsLength = arguments.length;
|
|
var message = normalizeStringArgument(argumentsLength < 1 ? undefined : arguments[0]);
|
|
var name = normalizeStringArgument(argumentsLength < 2 ? undefined : arguments[1], 'Error');
|
|
var that = new NativeDOMException(message, name);
|
|
var error = new Error(message);
|
|
error.name = DOM_EXCEPTION;
|
|
defineProperty(that, 'stack', createPropertyDescriptor(1, clearErrorStack(error.stack, 1)));
|
|
inheritIfRequired(that, this, $DOMException);
|
|
return that;
|
|
};
|
|
|
|
var DOMExceptionPrototype = $DOMException.prototype = NativeDOMException.prototype;
|
|
|
|
var ERROR_HAS_STACK = 'stack' in new Error(DOM_EXCEPTION);
|
|
var DOM_EXCEPTION_HAS_STACK = 'stack' in new NativeDOMException(1, 2);
|
|
|
|
// eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe
|
|
var descriptor = NativeDOMException && DESCRIPTORS && Object.getOwnPropertyDescriptor(global, DOM_EXCEPTION);
|
|
|
|
// Bun ~ 0.1.1 DOMException have incorrect descriptor and we can't redefine it
|
|
// https://github.com/Jarred-Sumner/bun/issues/399
|
|
var BUGGY_DESCRIPTOR = !!descriptor && !(descriptor.writable && descriptor.configurable);
|
|
|
|
var FORCED_CONSTRUCTOR = ERROR_HAS_STACK && !BUGGY_DESCRIPTOR && !DOM_EXCEPTION_HAS_STACK;
|
|
|
|
// `DOMException` constructor patch for `.stack` where it's required
|
|
// https://webidl.spec.whatwg.org/#es-DOMException-specialness
|
|
$({ global: true, constructor: true, forced: IS_PURE || FORCED_CONSTRUCTOR }, { // TODO: fix export logic
|
|
DOMException: FORCED_CONSTRUCTOR ? $DOMException : NativeDOMException
|
|
});
|
|
|
|
var PolyfilledDOMException = getBuiltIn(DOM_EXCEPTION);
|
|
var PolyfilledDOMExceptionPrototype = PolyfilledDOMException.prototype;
|
|
|
|
if (PolyfilledDOMExceptionPrototype.constructor !== PolyfilledDOMException) {
|
|
if (!IS_PURE) {
|
|
defineProperty(PolyfilledDOMExceptionPrototype, 'constructor', createPropertyDescriptor(1, PolyfilledDOMException));
|
|
}
|
|
|
|
for (var key in DOMExceptionConstants) if (hasOwn(DOMExceptionConstants, key)) {
|
|
var constant = DOMExceptionConstants[key];
|
|
var constantName = constant.s;
|
|
if (!hasOwn(PolyfilledDOMException, constantName)) {
|
|
defineProperty(PolyfilledDOMException, constantName, createPropertyDescriptor(6, constant.c));
|
|
}
|
|
}
|
|
}
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 6188:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var isCallable = __webpack_require__(6450);
|
|
var isObject = __webpack_require__(1909);
|
|
var setPrototypeOf = __webpack_require__(640);
|
|
|
|
// makes subclassing work correct for wrapped built-ins
|
|
module.exports = function ($this, dummy, Wrapper) {
|
|
var NewTarget, NewTargetPrototype;
|
|
if (
|
|
// it can work only with native `setPrototypeOf`
|
|
setPrototypeOf &&
|
|
// we haven't completely correct pre-ES6 way for getting `new.target`, so use this
|
|
isCallable(NewTarget = dummy.constructor) &&
|
|
NewTarget !== Wrapper &&
|
|
isObject(NewTargetPrototype = NewTarget.prototype) &&
|
|
NewTargetPrototype !== Wrapper.prototype
|
|
) setPrototypeOf($this, NewTargetPrototype);
|
|
return $this;
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 6255:
|
|
/***/ (function(__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) {
|
|
|
|
"use strict";
|
|
/* harmony import */ var core_js_modules_es_array_push_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(5513);
|
|
/* harmony import */ var _CanceledError_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(7080);
|
|
|
|
|
|
|
|
|
|
|
|
/**
|
|
* A `CancelToken` is an object that can be used to request cancellation of an operation.
|
|
*
|
|
* @param {Function} executor The executor function.
|
|
*
|
|
* @returns {CancelToken}
|
|
*/
|
|
class CancelToken {
|
|
constructor(executor) {
|
|
if (typeof executor !== 'function') {
|
|
throw new TypeError('executor must be a function.');
|
|
}
|
|
let resolvePromise;
|
|
this.promise = new Promise(function promiseExecutor(resolve) {
|
|
resolvePromise = resolve;
|
|
});
|
|
const token = this;
|
|
|
|
// eslint-disable-next-line func-names
|
|
this.promise.then(cancel => {
|
|
if (!token._listeners) return;
|
|
let i = token._listeners.length;
|
|
while (i-- > 0) {
|
|
token._listeners[i](cancel);
|
|
}
|
|
token._listeners = null;
|
|
});
|
|
|
|
// eslint-disable-next-line func-names
|
|
this.promise.then = onfulfilled => {
|
|
let _resolve;
|
|
// eslint-disable-next-line func-names
|
|
const promise = new Promise(resolve => {
|
|
token.subscribe(resolve);
|
|
_resolve = resolve;
|
|
}).then(onfulfilled);
|
|
promise.cancel = function reject() {
|
|
token.unsubscribe(_resolve);
|
|
};
|
|
return promise;
|
|
};
|
|
executor(function cancel(message, config, request) {
|
|
if (token.reason) {
|
|
// Cancellation has already been requested
|
|
return;
|
|
}
|
|
token.reason = new _CanceledError_js__WEBPACK_IMPORTED_MODULE_1__/* ["default"] */ .A(message, config, request);
|
|
resolvePromise(token.reason);
|
|
});
|
|
}
|
|
|
|
/**
|
|
* Throws a `CanceledError` if cancellation has been requested.
|
|
*/
|
|
throwIfRequested() {
|
|
if (this.reason) {
|
|
throw this.reason;
|
|
}
|
|
}
|
|
|
|
/**
|
|
* Subscribe to the cancel signal
|
|
*/
|
|
|
|
subscribe(listener) {
|
|
if (this.reason) {
|
|
listener(this.reason);
|
|
return;
|
|
}
|
|
if (this._listeners) {
|
|
this._listeners.push(listener);
|
|
} else {
|
|
this._listeners = [listener];
|
|
}
|
|
}
|
|
|
|
/**
|
|
* Unsubscribe from the cancel signal
|
|
*/
|
|
|
|
unsubscribe(listener) {
|
|
if (!this._listeners) {
|
|
return;
|
|
}
|
|
const index = this._listeners.indexOf(listener);
|
|
if (index !== -1) {
|
|
this._listeners.splice(index, 1);
|
|
}
|
|
}
|
|
|
|
/**
|
|
* Returns an object that contains a new `CancelToken` and a function that, when called,
|
|
* cancels the `CancelToken`.
|
|
*/
|
|
static source() {
|
|
let cancel;
|
|
const token = new CancelToken(function executor(c) {
|
|
cancel = c;
|
|
});
|
|
return {
|
|
token,
|
|
cancel
|
|
};
|
|
}
|
|
}
|
|
/* harmony default export */ __webpack_exports__.A = (CancelToken);
|
|
|
|
/***/ }),
|
|
|
|
/***/ 6406:
|
|
/***/ (function(__unused_webpack___webpack_module__, __webpack_exports__) {
|
|
|
|
"use strict";
|
|
|
|
|
|
/* harmony default export */ __webpack_exports__.A = (typeof FormData !== 'undefined' ? FormData : null);
|
|
|
|
/***/ }),
|
|
|
|
/***/ 6450:
|
|
/***/ (function(module) {
|
|
|
|
"use strict";
|
|
|
|
// https://tc39.es/ecma262/#sec-IsHTMLDDA-internal-slot
|
|
var documentAll = typeof document == 'object' && document.all;
|
|
|
|
// `IsCallable` abstract operation
|
|
// https://tc39.es/ecma262/#sec-iscallable
|
|
// eslint-disable-next-line unicorn/no-typeof-undefined -- required for testing
|
|
module.exports = typeof documentAll == 'undefined' && documentAll !== undefined ? function (argument) {
|
|
return typeof argument == 'function' || argument === documentAll;
|
|
} : function (argument) {
|
|
return typeof argument == 'function';
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 6539:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var aSet = __webpack_require__(3991);
|
|
var size = __webpack_require__(903);
|
|
var iterate = __webpack_require__(2282);
|
|
var getSetRecord = __webpack_require__(3108);
|
|
|
|
// `Set.prototype.isSubsetOf` method
|
|
// https://tc39.github.io/proposal-set-methods/#Set.prototype.isSubsetOf
|
|
module.exports = function isSubsetOf(other) {
|
|
var O = aSet(this);
|
|
var otherRec = getSetRecord(other);
|
|
if (size(O) > otherRec.size) return false;
|
|
return iterate(O, function (e) {
|
|
if (!otherRec.includes(e)) return false;
|
|
}, true) !== false;
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 6550:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var call = __webpack_require__(4978);
|
|
|
|
module.exports = function (record, fn, ITERATOR_INSTEAD_OF_RECORD) {
|
|
var iterator = ITERATOR_INSTEAD_OF_RECORD ? record : record.iterator;
|
|
var next = record.next;
|
|
var step, result;
|
|
while (!(step = call(next, iterator)).done) {
|
|
result = fn(step.value);
|
|
if (result !== undefined) return result;
|
|
}
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 6587:
|
|
/***/ (function(__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) {
|
|
|
|
"use strict";
|
|
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
/* harmony export */ A: function() { return /* binding */ spread; }
|
|
/* harmony export */ });
|
|
|
|
|
|
/**
|
|
* Syntactic sugar for invoking a function and expanding an array for arguments.
|
|
*
|
|
* Common use case would be to use `Function.prototype.apply`.
|
|
*
|
|
* ```js
|
|
* function f(x, y, z) {}
|
|
* var args = [1, 2, 3];
|
|
* f.apply(null, args);
|
|
* ```
|
|
*
|
|
* With `spread` this example can be re-written.
|
|
*
|
|
* ```js
|
|
* spread(function(x, y, z) {})([1, 2, 3]);
|
|
* ```
|
|
*
|
|
* @param {Function} callback
|
|
*
|
|
* @returns {Function}
|
|
*/
|
|
function spread(callback) {
|
|
return function wrap(arr) {
|
|
return callback.apply(null, arr);
|
|
};
|
|
}
|
|
|
|
/***/ }),
|
|
|
|
/***/ 6591:
|
|
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var $ = __webpack_require__(8155);
|
|
var isSupersetOf = __webpack_require__(2634);
|
|
var setMethodAcceptSetLike = __webpack_require__(5645);
|
|
|
|
// `Set.prototype.isSupersetOf` method
|
|
// https://github.com/tc39/proposal-set-methods
|
|
$({ target: 'Set', proto: true, real: true, forced: !setMethodAcceptSetLike('isSupersetOf') }, {
|
|
isSupersetOf: isSupersetOf
|
|
});
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 6631:
|
|
/***/ (function(__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) {
|
|
|
|
"use strict";
|
|
/* harmony import */ var core_js_modules_es_array_push_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(5513);
|
|
/* harmony import */ var core_js_modules_esnext_iterator_constructor_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(7195);
|
|
/* harmony import */ var core_js_modules_esnext_iterator_for_each_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(680);
|
|
/* harmony import */ var core_js_modules_esnext_iterator_map_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(793);
|
|
/* harmony import */ var core_js_modules_esnext_iterator_some_js__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(6071);
|
|
/* harmony import */ var core_js_modules_esnext_iterator_to_array_js__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(2602);
|
|
/* harmony import */ var _utils_js__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(5813);
|
|
/* harmony import */ var _core_AxiosError_js__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(956);
|
|
/* harmony import */ var _platform_node_classes_FormData_js__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(8273);
|
|
/* provided dependency */ var Buffer = __webpack_require__(9253)["hp"];
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// temporary hotfix to avoid circular references until AxiosURLSearchParams is refactored
|
|
|
|
|
|
/**
|
|
* Determines if the given thing is a array or js object.
|
|
*
|
|
* @param {string} thing - The object or array to be visited.
|
|
*
|
|
* @returns {boolean}
|
|
*/
|
|
function isVisitable(thing) {
|
|
return _utils_js__WEBPACK_IMPORTED_MODULE_6__/* ["default"] */ .A.isPlainObject(thing) || _utils_js__WEBPACK_IMPORTED_MODULE_6__/* ["default"] */ .A.isArray(thing);
|
|
}
|
|
|
|
/**
|
|
* It removes the brackets from the end of a string
|
|
*
|
|
* @param {string} key - The key of the parameter.
|
|
*
|
|
* @returns {string} the key without the brackets.
|
|
*/
|
|
function removeBrackets(key) {
|
|
return _utils_js__WEBPACK_IMPORTED_MODULE_6__/* ["default"] */ .A.endsWith(key, '[]') ? key.slice(0, -2) : key;
|
|
}
|
|
|
|
/**
|
|
* It takes a path, a key, and a boolean, and returns a string
|
|
*
|
|
* @param {string} path - The path to the current key.
|
|
* @param {string} key - The key of the current object being iterated over.
|
|
* @param {string} dots - If true, the key will be rendered with dots instead of brackets.
|
|
*
|
|
* @returns {string} The path to the current key.
|
|
*/
|
|
function renderKey(path, key, dots) {
|
|
if (!path) return key;
|
|
return path.concat(key).map(function each(token, i) {
|
|
// eslint-disable-next-line no-param-reassign
|
|
token = removeBrackets(token);
|
|
return !dots && i ? '[' + token + ']' : token;
|
|
}).join(dots ? '.' : '');
|
|
}
|
|
|
|
/**
|
|
* If the array is an array and none of its elements are visitable, then it's a flat array.
|
|
*
|
|
* @param {Array<any>} arr - The array to check
|
|
*
|
|
* @returns {boolean}
|
|
*/
|
|
function isFlatArray(arr) {
|
|
return _utils_js__WEBPACK_IMPORTED_MODULE_6__/* ["default"] */ .A.isArray(arr) && !arr.some(isVisitable);
|
|
}
|
|
const predicates = _utils_js__WEBPACK_IMPORTED_MODULE_6__/* ["default"] */ .A.toFlatObject(_utils_js__WEBPACK_IMPORTED_MODULE_6__/* ["default"] */ .A, {}, null, function filter(prop) {
|
|
return /^is[A-Z]/.test(prop);
|
|
});
|
|
|
|
/**
|
|
* Convert a data object to FormData
|
|
*
|
|
* @param {Object} obj
|
|
* @param {?Object} [formData]
|
|
* @param {?Object} [options]
|
|
* @param {Function} [options.visitor]
|
|
* @param {Boolean} [options.metaTokens = true]
|
|
* @param {Boolean} [options.dots = false]
|
|
* @param {?Boolean} [options.indexes = false]
|
|
*
|
|
* @returns {Object}
|
|
**/
|
|
|
|
/**
|
|
* It converts an object into a FormData object
|
|
*
|
|
* @param {Object<any, any>} obj - The object to convert to form data.
|
|
* @param {string} formData - The FormData object to append to.
|
|
* @param {Object<string, any>} options
|
|
*
|
|
* @returns
|
|
*/
|
|
function toFormData(obj, formData, options) {
|
|
if (!_utils_js__WEBPACK_IMPORTED_MODULE_6__/* ["default"] */ .A.isObject(obj)) {
|
|
throw new TypeError('target must be an object');
|
|
}
|
|
|
|
// eslint-disable-next-line no-param-reassign
|
|
formData = formData || new (_platform_node_classes_FormData_js__WEBPACK_IMPORTED_MODULE_7__/* ["default"] */ .A || FormData)();
|
|
|
|
// eslint-disable-next-line no-param-reassign
|
|
options = _utils_js__WEBPACK_IMPORTED_MODULE_6__/* ["default"] */ .A.toFlatObject(options, {
|
|
metaTokens: true,
|
|
dots: false,
|
|
indexes: false
|
|
}, false, function defined(option, source) {
|
|
// eslint-disable-next-line no-eq-null,eqeqeq
|
|
return !_utils_js__WEBPACK_IMPORTED_MODULE_6__/* ["default"] */ .A.isUndefined(source[option]);
|
|
});
|
|
const metaTokens = options.metaTokens;
|
|
// eslint-disable-next-line no-use-before-define
|
|
const visitor = options.visitor || defaultVisitor;
|
|
const dots = options.dots;
|
|
const indexes = options.indexes;
|
|
const _Blob = options.Blob || typeof Blob !== 'undefined' && Blob;
|
|
const useBlob = _Blob && _utils_js__WEBPACK_IMPORTED_MODULE_6__/* ["default"] */ .A.isSpecCompliantForm(formData);
|
|
if (!_utils_js__WEBPACK_IMPORTED_MODULE_6__/* ["default"] */ .A.isFunction(visitor)) {
|
|
throw new TypeError('visitor must be a function');
|
|
}
|
|
function convertValue(value) {
|
|
if (value === null) return '';
|
|
if (_utils_js__WEBPACK_IMPORTED_MODULE_6__/* ["default"] */ .A.isDate(value)) {
|
|
return value.toISOString();
|
|
}
|
|
if (!useBlob && _utils_js__WEBPACK_IMPORTED_MODULE_6__/* ["default"] */ .A.isBlob(value)) {
|
|
throw new _core_AxiosError_js__WEBPACK_IMPORTED_MODULE_8__/* ["default"] */ .A('Blob is not supported. Use a Buffer instead.');
|
|
}
|
|
if (_utils_js__WEBPACK_IMPORTED_MODULE_6__/* ["default"] */ .A.isArrayBuffer(value) || _utils_js__WEBPACK_IMPORTED_MODULE_6__/* ["default"] */ .A.isTypedArray(value)) {
|
|
return useBlob && typeof Blob === 'function' ? new Blob([value]) : Buffer.from(value);
|
|
}
|
|
return value;
|
|
}
|
|
|
|
/**
|
|
* Default visitor.
|
|
*
|
|
* @param {*} value
|
|
* @param {String|Number} key
|
|
* @param {Array<String|Number>} path
|
|
* @this {FormData}
|
|
*
|
|
* @returns {boolean} return true to visit the each prop of the value recursively
|
|
*/
|
|
function defaultVisitor(value, key, path) {
|
|
let arr = value;
|
|
if (value && !path && typeof value === 'object') {
|
|
if (_utils_js__WEBPACK_IMPORTED_MODULE_6__/* ["default"] */ .A.endsWith(key, '{}')) {
|
|
// eslint-disable-next-line no-param-reassign
|
|
key = metaTokens ? key : key.slice(0, -2);
|
|
// eslint-disable-next-line no-param-reassign
|
|
value = JSON.stringify(value);
|
|
} else if (_utils_js__WEBPACK_IMPORTED_MODULE_6__/* ["default"] */ .A.isArray(value) && isFlatArray(value) || (_utils_js__WEBPACK_IMPORTED_MODULE_6__/* ["default"] */ .A.isFileList(value) || _utils_js__WEBPACK_IMPORTED_MODULE_6__/* ["default"] */ .A.endsWith(key, '[]')) && (arr = _utils_js__WEBPACK_IMPORTED_MODULE_6__/* ["default"] */ .A.toArray(value))) {
|
|
// eslint-disable-next-line no-param-reassign
|
|
key = removeBrackets(key);
|
|
arr.forEach(function each(el, index) {
|
|
!(_utils_js__WEBPACK_IMPORTED_MODULE_6__/* ["default"] */ .A.isUndefined(el) || el === null) && formData.append(
|
|
// eslint-disable-next-line no-nested-ternary
|
|
indexes === true ? renderKey([key], index, dots) : indexes === null ? key : key + '[]', convertValue(el));
|
|
});
|
|
return false;
|
|
}
|
|
}
|
|
if (isVisitable(value)) {
|
|
return true;
|
|
}
|
|
formData.append(renderKey(path, key, dots), convertValue(value));
|
|
return false;
|
|
}
|
|
const stack = [];
|
|
const exposedHelpers = Object.assign(predicates, {
|
|
defaultVisitor,
|
|
convertValue,
|
|
isVisitable
|
|
});
|
|
function build(value, path) {
|
|
if (_utils_js__WEBPACK_IMPORTED_MODULE_6__/* ["default"] */ .A.isUndefined(value)) return;
|
|
if (stack.indexOf(value) !== -1) {
|
|
throw Error('Circular reference detected in ' + path.join('.'));
|
|
}
|
|
stack.push(value);
|
|
_utils_js__WEBPACK_IMPORTED_MODULE_6__/* ["default"] */ .A.forEach(value, function each(el, key) {
|
|
const result = !(_utils_js__WEBPACK_IMPORTED_MODULE_6__/* ["default"] */ .A.isUndefined(el) || el === null) && visitor.call(formData, el, _utils_js__WEBPACK_IMPORTED_MODULE_6__/* ["default"] */ .A.isString(key) ? key.trim() : key, path, exposedHelpers);
|
|
if (result === true) {
|
|
build(el, path ? path.concat(key) : [key]);
|
|
}
|
|
});
|
|
stack.pop();
|
|
}
|
|
if (!_utils_js__WEBPACK_IMPORTED_MODULE_6__/* ["default"] */ .A.isObject(obj)) {
|
|
throw new TypeError('data must be an object');
|
|
}
|
|
build(obj);
|
|
return formData;
|
|
}
|
|
/* harmony default export */ __webpack_exports__.A = (toFormData);
|
|
|
|
/***/ }),
|
|
|
|
/***/ 6665:
|
|
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var $ = __webpack_require__(8155);
|
|
var $transfer = __webpack_require__(8056);
|
|
|
|
// `ArrayBuffer.prototype.transfer` method
|
|
// https://tc39.es/proposal-arraybuffer-transfer/#sec-arraybuffer.prototype.transfer
|
|
if ($transfer) $({ target: 'ArrayBuffer', proto: true }, {
|
|
transfer: function transfer() {
|
|
return $transfer(this, arguments.length ? arguments[0] : undefined, true);
|
|
}
|
|
});
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 6696:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var isObject = __webpack_require__(1909);
|
|
|
|
var $String = String;
|
|
var $TypeError = TypeError;
|
|
|
|
// `Assert: Type(argument) is Object`
|
|
module.exports = function (argument) {
|
|
if (isObject(argument)) return argument;
|
|
throw new $TypeError($String(argument) + ' is not an object');
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 6701:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var uncurryThis = __webpack_require__(1371);
|
|
var hasOwn = __webpack_require__(1396);
|
|
var toIndexedObject = __webpack_require__(5830);
|
|
var indexOf = (__webpack_require__(2060).indexOf);
|
|
var hiddenKeys = __webpack_require__(4858);
|
|
|
|
var push = uncurryThis([].push);
|
|
|
|
module.exports = function (object, names) {
|
|
var O = toIndexedObject(object);
|
|
var i = 0;
|
|
var result = [];
|
|
var key;
|
|
for (key in O) !hasOwn(hiddenKeys, key) && hasOwn(O, key) && push(result, key);
|
|
// Don't enum bug & hidden keys
|
|
while (names.length > i) if (hasOwn(O, key = names[i++])) {
|
|
~indexOf(result, key) || push(result, key);
|
|
}
|
|
return result;
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 6746:
|
|
/***/ (function(__unused_webpack_module, exports) {
|
|
|
|
"use strict";
|
|
|
|
// eslint-disable-next-line es/no-object-getownpropertysymbols -- safe
|
|
exports.f = Object.getOwnPropertySymbols;
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 6768:
|
|
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var $ = __webpack_require__(8155);
|
|
var fails = __webpack_require__(4212);
|
|
var intersection = __webpack_require__(683);
|
|
var setMethodAcceptSetLike = __webpack_require__(5645);
|
|
|
|
var INCORRECT = !setMethodAcceptSetLike('intersection') || fails(function () {
|
|
// eslint-disable-next-line es/no-array-from, es/no-set -- testing
|
|
return String(Array.from(new Set([1, 2, 3]).intersection(new Set([3, 2])))) !== '3,2';
|
|
});
|
|
|
|
// `Set.prototype.intersection` method
|
|
// https://github.com/tc39/proposal-set-methods
|
|
$({ target: 'Set', proto: true, real: true, forced: INCORRECT }, {
|
|
intersection: intersection
|
|
});
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 6905:
|
|
/***/ (function(__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) {
|
|
|
|
"use strict";
|
|
/* harmony import */ var core_js_modules_esnext_iterator_constructor_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(7195);
|
|
/* harmony import */ var core_js_modules_esnext_iterator_for_each_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(680);
|
|
/* harmony import */ var core_js_modules_esnext_iterator_map_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(793);
|
|
/* harmony import */ var _utils_js__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(5813);
|
|
/* harmony import */ var _http_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(8273);
|
|
/* harmony import */ var _xhr_js__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(1591);
|
|
/* harmony import */ var _core_AxiosError_js__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(956);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
const knownAdapters = {
|
|
http: _http_js__WEBPACK_IMPORTED_MODULE_3__/* ["default"] */ .A,
|
|
xhr: _xhr_js__WEBPACK_IMPORTED_MODULE_4__/* ["default"] */ .A
|
|
};
|
|
_utils_js__WEBPACK_IMPORTED_MODULE_5__/* ["default"] */ .A.forEach(knownAdapters, (fn, value) => {
|
|
if (fn) {
|
|
try {
|
|
Object.defineProperty(fn, 'name', {
|
|
value
|
|
});
|
|
} catch (e) {
|
|
// eslint-disable-next-line no-empty
|
|
}
|
|
Object.defineProperty(fn, 'adapterName', {
|
|
value
|
|
});
|
|
}
|
|
});
|
|
const renderReason = reason => `- ${reason}`;
|
|
const isResolvedHandle = adapter => _utils_js__WEBPACK_IMPORTED_MODULE_5__/* ["default"] */ .A.isFunction(adapter) || adapter === null || adapter === false;
|
|
/* harmony default export */ __webpack_exports__.A = ({
|
|
getAdapter: adapters => {
|
|
adapters = _utils_js__WEBPACK_IMPORTED_MODULE_5__/* ["default"] */ .A.isArray(adapters) ? adapters : [adapters];
|
|
const {
|
|
length
|
|
} = adapters;
|
|
let nameOrAdapter;
|
|
let adapter;
|
|
const rejectedReasons = {};
|
|
for (let i = 0; i < length; i++) {
|
|
nameOrAdapter = adapters[i];
|
|
let id;
|
|
adapter = nameOrAdapter;
|
|
if (!isResolvedHandle(nameOrAdapter)) {
|
|
adapter = knownAdapters[(id = String(nameOrAdapter)).toLowerCase()];
|
|
if (adapter === undefined) {
|
|
throw new _core_AxiosError_js__WEBPACK_IMPORTED_MODULE_6__/* ["default"] */ .A(`Unknown adapter '${id}'`);
|
|
}
|
|
}
|
|
if (adapter) {
|
|
break;
|
|
}
|
|
rejectedReasons[id || '#' + i] = adapter;
|
|
}
|
|
if (!adapter) {
|
|
const reasons = Object.entries(rejectedReasons).map(([id, state]) => `adapter ${id} ` + (state === false ? 'is not supported by the environment' : 'is not available in the build'));
|
|
let s = length ? reasons.length > 1 ? 'since :\n' + reasons.map(renderReason).join('\n') : ' ' + renderReason(reasons[0]) : 'as no adapter specified';
|
|
throw new _core_AxiosError_js__WEBPACK_IMPORTED_MODULE_6__/* ["default"] */ .A(`There is no suitable adapter to dispatch the request ` + s, 'ERR_NOT_SUPPORT');
|
|
}
|
|
return adapter;
|
|
},
|
|
adapters: knownAdapters
|
|
});
|
|
|
|
/***/ }),
|
|
|
|
/***/ 6915:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var internalObjectKeys = __webpack_require__(6701);
|
|
var enumBugKeys = __webpack_require__(448);
|
|
|
|
// `Object.keys` method
|
|
// https://tc39.es/ecma262/#sec-object.keys
|
|
// eslint-disable-next-line es/no-object-keys -- safe
|
|
module.exports = Object.keys || function keys(O) {
|
|
return internalObjectKeys(O, enumBugKeys);
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 6949:
|
|
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var ArrayBufferViewCore = __webpack_require__(4257);
|
|
var uncurryThis = __webpack_require__(1371);
|
|
var aCallable = __webpack_require__(8951);
|
|
var arrayFromConstructorAndList = __webpack_require__(1341);
|
|
|
|
var aTypedArray = ArrayBufferViewCore.aTypedArray;
|
|
var getTypedArrayConstructor = ArrayBufferViewCore.getTypedArrayConstructor;
|
|
var exportTypedArrayMethod = ArrayBufferViewCore.exportTypedArrayMethod;
|
|
var sort = uncurryThis(ArrayBufferViewCore.TypedArrayPrototype.sort);
|
|
|
|
// `%TypedArray%.prototype.toSorted` method
|
|
// https://tc39.es/ecma262/#sec-%typedarray%.prototype.tosorted
|
|
exportTypedArrayMethod('toSorted', function toSorted(compareFn) {
|
|
if (compareFn !== undefined) aCallable(compareFn);
|
|
var O = aTypedArray(this);
|
|
var A = arrayFromConstructorAndList(getTypedArrayConstructor(O), O);
|
|
return sort(A, compareFn);
|
|
});
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 6968:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var getBuiltIn = __webpack_require__(6054);
|
|
|
|
module.exports = getBuiltIn('document', 'documentElement');
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 7037:
|
|
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var $ = __webpack_require__(8155);
|
|
var addToUnscopables = __webpack_require__(3876);
|
|
var doesNotExceedSafeInteger = __webpack_require__(4675);
|
|
var lengthOfArrayLike = __webpack_require__(4231);
|
|
var toAbsoluteIndex = __webpack_require__(1257);
|
|
var toIndexedObject = __webpack_require__(5830);
|
|
var toIntegerOrInfinity = __webpack_require__(9106);
|
|
|
|
var $Array = Array;
|
|
var max = Math.max;
|
|
var min = Math.min;
|
|
|
|
// `Array.prototype.toSpliced` method
|
|
// https://tc39.es/ecma262/#sec-array.prototype.tospliced
|
|
$({ target: 'Array', proto: true }, {
|
|
toSpliced: function toSpliced(start, deleteCount /* , ...items */) {
|
|
var O = toIndexedObject(this);
|
|
var len = lengthOfArrayLike(O);
|
|
var actualStart = toAbsoluteIndex(start, len);
|
|
var argumentsLength = arguments.length;
|
|
var k = 0;
|
|
var insertCount, actualDeleteCount, newLen, A;
|
|
if (argumentsLength === 0) {
|
|
insertCount = actualDeleteCount = 0;
|
|
} else if (argumentsLength === 1) {
|
|
insertCount = 0;
|
|
actualDeleteCount = len - actualStart;
|
|
} else {
|
|
insertCount = argumentsLength - 2;
|
|
actualDeleteCount = min(max(toIntegerOrInfinity(deleteCount), 0), len - actualStart);
|
|
}
|
|
newLen = doesNotExceedSafeInteger(len + insertCount - actualDeleteCount);
|
|
A = $Array(newLen);
|
|
|
|
for (; k < actualStart; k++) A[k] = O[k];
|
|
for (; k < actualStart + insertCount; k++) A[k] = arguments[k - actualStart + 2];
|
|
for (; k < newLen; k++) A[k] = O[k + actualDeleteCount - insertCount];
|
|
|
|
return A;
|
|
}
|
|
});
|
|
|
|
addToUnscopables('toSpliced');
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 7056:
|
|
/***/ (function(module) {
|
|
|
|
"use strict";
|
|
|
|
var ceil = Math.ceil;
|
|
var floor = Math.floor;
|
|
|
|
// `Math.trunc` method
|
|
// https://tc39.es/ecma262/#sec-math.trunc
|
|
// eslint-disable-next-line es/no-math-trunc -- safe
|
|
module.exports = Math.trunc || function trunc(x) {
|
|
var n = +x;
|
|
return (n > 0 ? floor : ceil)(n);
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 7080:
|
|
/***/ (function(__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) {
|
|
|
|
"use strict";
|
|
/* harmony import */ var _core_AxiosError_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(956);
|
|
/* harmony import */ var _utils_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(5813);
|
|
|
|
|
|
|
|
|
|
|
|
/**
|
|
* A `CanceledError` is an object that is thrown when an operation is canceled.
|
|
*
|
|
* @param {string=} message The message.
|
|
* @param {Object=} config The config.
|
|
* @param {Object=} request The request.
|
|
*
|
|
* @returns {CanceledError} The created error.
|
|
*/
|
|
function CanceledError(message, config, request) {
|
|
// eslint-disable-next-line no-eq-null,eqeqeq
|
|
_core_AxiosError_js__WEBPACK_IMPORTED_MODULE_0__/* ["default"] */ .A.call(this, message == null ? 'canceled' : message, _core_AxiosError_js__WEBPACK_IMPORTED_MODULE_0__/* ["default"] */ .A.ERR_CANCELED, config, request);
|
|
this.name = 'CanceledError';
|
|
}
|
|
_utils_js__WEBPACK_IMPORTED_MODULE_1__/* ["default"] */ .A.inherits(CanceledError, _core_AxiosError_js__WEBPACK_IMPORTED_MODULE_0__/* ["default"] */ .A, {
|
|
__CANCEL__: true
|
|
});
|
|
/* harmony default export */ __webpack_exports__.A = (CanceledError);
|
|
|
|
/***/ }),
|
|
|
|
/***/ 7103:
|
|
/***/ (function(__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) {
|
|
|
|
"use strict";
|
|
__webpack_require__.r(__webpack_exports__);
|
|
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
/* harmony export */ hasBrowserEnv: function() { return /* binding */ hasBrowserEnv; },
|
|
/* harmony export */ hasStandardBrowserEnv: function() { return /* binding */ hasStandardBrowserEnv; },
|
|
/* harmony export */ hasStandardBrowserWebWorkerEnv: function() { return /* binding */ hasStandardBrowserWebWorkerEnv; }
|
|
/* harmony export */ });
|
|
const hasBrowserEnv = typeof window !== 'undefined' && typeof document !== 'undefined';
|
|
|
|
/**
|
|
* Determine if we're running in a standard browser environment
|
|
*
|
|
* This allows axios to run in a web worker, and react-native.
|
|
* Both environments support XMLHttpRequest, but not fully standard globals.
|
|
*
|
|
* web workers:
|
|
* typeof window -> undefined
|
|
* typeof document -> undefined
|
|
*
|
|
* react-native:
|
|
* navigator.product -> 'ReactNative'
|
|
* nativescript
|
|
* navigator.product -> 'NativeScript' or 'NS'
|
|
*
|
|
* @returns {boolean}
|
|
*/
|
|
const hasStandardBrowserEnv = (product => {
|
|
return hasBrowserEnv && ['ReactNative', 'NativeScript', 'NS'].indexOf(product) < 0;
|
|
})(typeof navigator !== 'undefined' && navigator.product);
|
|
|
|
/**
|
|
* Determine if we're running in a standard browser webWorker environment
|
|
*
|
|
* Although the `isStandardBrowserEnv` method indicates that
|
|
* `allows axios to run in a web worker`, the WebWorker will still be
|
|
* filtered out due to its judgment standard
|
|
* `typeof window !== 'undefined' && typeof document !== 'undefined'`.
|
|
* This leads to a problem when axios post `FormData` in webWorker
|
|
*/
|
|
const hasStandardBrowserWebWorkerEnv = (() => {
|
|
return typeof WorkerGlobalScope !== 'undefined' &&
|
|
// eslint-disable-next-line no-undef
|
|
self instanceof WorkerGlobalScope && typeof self.importScripts === 'function';
|
|
})();
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 7144:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var DESCRIPTORS = __webpack_require__(4911);
|
|
var fails = __webpack_require__(4212);
|
|
var createElement = __webpack_require__(2936);
|
|
|
|
// Thanks to IE8 for its funny defineProperty
|
|
module.exports = !DESCRIPTORS && !fails(function () {
|
|
// eslint-disable-next-line es/no-object-defineproperty -- required for testing
|
|
return Object.defineProperty(createElement('div'), 'a', {
|
|
get: function () { return 7; }
|
|
}).a !== 7;
|
|
});
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 7153:
|
|
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) {
|
|
|
|
"use strict";
|
|
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
/* harmony export */ $3: function() { return /* binding */ hasOwn; },
|
|
/* harmony export */ BX: function() { return /* binding */ looseEqual; },
|
|
/* harmony export */ Bm: function() { return /* binding */ isSymbol; },
|
|
/* harmony export */ CP: function() { return /* binding */ isModelListener; },
|
|
/* harmony export */ DY: function() { return /* binding */ invokeArrayFns; },
|
|
/* harmony export */ Gv: function() { return /* binding */ isObject; },
|
|
/* harmony export */ J$: function() { return /* binding */ isSpecialBooleanAttr; },
|
|
/* harmony export */ Kg: function() { return /* binding */ isString; },
|
|
/* harmony export */ Mp: function() { return /* binding */ isOn; },
|
|
/* harmony export */ PT: function() { return /* binding */ camelize; },
|
|
/* harmony export */ Qd: function() { return /* binding */ isPlainObject; },
|
|
/* harmony export */ Ro: function() { return /* binding */ toNumber; },
|
|
/* harmony export */ Tg: function() { return /* binding */ hyphenate; },
|
|
/* harmony export */ Tn: function() { return /* binding */ isFunction; },
|
|
/* harmony export */ X$: function() { return /* binding */ extend; },
|
|
/* harmony export */ Y2: function() { return /* binding */ includeBooleanAttr; },
|
|
/* harmony export */ ZH: function() { return /* binding */ capitalize; },
|
|
/* harmony export */ bB: function() { return /* binding */ looseToNumber; },
|
|
/* harmony export */ cy: function() { return /* binding */ isArray; },
|
|
/* harmony export */ u3: function() { return /* binding */ looseIndexOf; },
|
|
/* harmony export */ vM: function() { return /* binding */ isSet; }
|
|
/* harmony export */ });
|
|
/* unused harmony exports EMPTY_ARR, EMPTY_OBJ, NO, NOOP, PatchFlagNames, PatchFlags, ShapeFlags, SlotFlags, cssVarNameEscapeSymbolsRE, def, escapeHtml, escapeHtmlComment, genCacheKey, genPropsAccessExp, generateCodeFrame, getEscapedCssVarName, getGlobalThis, hasChanged, isBooleanAttr, isBuiltInDirective, isDate, isGloballyAllowed, isGloballyWhitelisted, isHTMLTag, isIntegerKey, isKnownHtmlAttr, isKnownMathMLAttr, isKnownSvgAttr, isMap, isMathMLTag, isPromise, isRegExp, isRenderableAttrValue, isReservedProp, isSSRSafeAttrName, isSVGTag, isVoidTag, makeMap, normalizeClass, normalizeProps, normalizeStyle, objectToString, parseStringStyle, propsToAttrMap, remove, slotFlagsText, stringifyStyle, toDisplayString, toHandlerKey, toRawType, toTypeString */
|
|
/* harmony import */ var core_js_modules_es_array_push_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(5513);
|
|
/* harmony import */ var core_js_modules_es_array_push_js__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_array_push_js__WEBPACK_IMPORTED_MODULE_0__);
|
|
/* harmony import */ var core_js_modules_esnext_iterator_constructor_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(7195);
|
|
/* harmony import */ var core_js_modules_esnext_iterator_constructor_js__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_esnext_iterator_constructor_js__WEBPACK_IMPORTED_MODULE_1__);
|
|
/* harmony import */ var core_js_modules_esnext_iterator_filter_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(3741);
|
|
/* harmony import */ var core_js_modules_esnext_iterator_filter_js__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_esnext_iterator_filter_js__WEBPACK_IMPORTED_MODULE_2__);
|
|
/* harmony import */ var core_js_modules_esnext_iterator_for_each_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(680);
|
|
/* harmony import */ var core_js_modules_esnext_iterator_for_each_js__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_esnext_iterator_for_each_js__WEBPACK_IMPORTED_MODULE_3__);
|
|
/* harmony import */ var core_js_modules_esnext_iterator_map_js__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(793);
|
|
/* harmony import */ var core_js_modules_esnext_iterator_map_js__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_esnext_iterator_map_js__WEBPACK_IMPORTED_MODULE_4__);
|
|
/* harmony import */ var core_js_modules_esnext_iterator_reduce_js__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(5729);
|
|
/* harmony import */ var core_js_modules_esnext_iterator_reduce_js__WEBPACK_IMPORTED_MODULE_5___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_esnext_iterator_reduce_js__WEBPACK_IMPORTED_MODULE_5__);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
/**
|
|
* @vue/shared v3.5.13
|
|
* (c) 2018-present Yuxi (Evan) You and Vue contributors
|
|
* @license MIT
|
|
**/
|
|
/*! #__NO_SIDE_EFFECTS__ */
|
|
// @__NO_SIDE_EFFECTS__
|
|
function makeMap(str) {
|
|
const map = /* @__PURE__ */Object.create(null);
|
|
for (const key of str.split(",")) map[key] = 1;
|
|
return val => val in map;
|
|
}
|
|
const EMPTY_OBJ = false ? 0 : {};
|
|
const EMPTY_ARR = false ? 0 : [];
|
|
const NOOP = () => {};
|
|
const NO = () => false;
|
|
const isOn = key => key.charCodeAt(0) === 111 && key.charCodeAt(1) === 110 && (
|
|
// uppercase letter
|
|
key.charCodeAt(2) > 122 || key.charCodeAt(2) < 97);
|
|
const isModelListener = key => key.startsWith("onUpdate:");
|
|
const extend = Object.assign;
|
|
const remove = (arr, el) => {
|
|
const i = arr.indexOf(el);
|
|
if (i > -1) {
|
|
arr.splice(i, 1);
|
|
}
|
|
};
|
|
const hasOwnProperty = Object.prototype.hasOwnProperty;
|
|
const hasOwn = (val, key) => hasOwnProperty.call(val, key);
|
|
const isArray = Array.isArray;
|
|
const isMap = val => toTypeString(val) === "[object Map]";
|
|
const isSet = val => toTypeString(val) === "[object Set]";
|
|
const isDate = val => toTypeString(val) === "[object Date]";
|
|
const isRegExp = val => toTypeString(val) === "[object RegExp]";
|
|
const isFunction = val => typeof val === "function";
|
|
const isString = val => typeof val === "string";
|
|
const isSymbol = val => typeof val === "symbol";
|
|
const isObject = val => val !== null && typeof val === "object";
|
|
const isPromise = val => {
|
|
return (isObject(val) || isFunction(val)) && isFunction(val.then) && isFunction(val.catch);
|
|
};
|
|
const objectToString = Object.prototype.toString;
|
|
const toTypeString = value => objectToString.call(value);
|
|
const toRawType = value => {
|
|
return toTypeString(value).slice(8, -1);
|
|
};
|
|
const isPlainObject = val => toTypeString(val) === "[object Object]";
|
|
const isIntegerKey = key => isString(key) && key !== "NaN" && key[0] !== "-" && "" + parseInt(key, 10) === key;
|
|
const isReservedProp = /* @__PURE__ */(/* unused pure expression or super */ null && (makeMap(
|
|
// the leading comma is intentional so empty string "" is also included
|
|
",key,ref,ref_for,ref_key,onVnodeBeforeMount,onVnodeMounted,onVnodeBeforeUpdate,onVnodeUpdated,onVnodeBeforeUnmount,onVnodeUnmounted")));
|
|
const isBuiltInDirective = /* @__PURE__ */(/* unused pure expression or super */ null && (makeMap("bind,cloak,else-if,else,for,html,if,model,on,once,pre,show,slot,text,memo")));
|
|
const cacheStringFunction = fn => {
|
|
const cache = /* @__PURE__ */Object.create(null);
|
|
return str => {
|
|
const hit = cache[str];
|
|
return hit || (cache[str] = fn(str));
|
|
};
|
|
};
|
|
const camelizeRE = /-(\w)/g;
|
|
const camelize = cacheStringFunction(str => {
|
|
return str.replace(camelizeRE, (_, c) => c ? c.toUpperCase() : "");
|
|
});
|
|
const hyphenateRE = /\B([A-Z])/g;
|
|
const hyphenate = cacheStringFunction(str => str.replace(hyphenateRE, "-$1").toLowerCase());
|
|
const capitalize = cacheStringFunction(str => {
|
|
return str.charAt(0).toUpperCase() + str.slice(1);
|
|
});
|
|
const toHandlerKey = cacheStringFunction(str => {
|
|
const s = str ? `on${capitalize(str)}` : ``;
|
|
return s;
|
|
});
|
|
const hasChanged = (value, oldValue) => !Object.is(value, oldValue);
|
|
const invokeArrayFns = (fns, ...arg) => {
|
|
for (let i = 0; i < fns.length; i++) {
|
|
fns[i](...arg);
|
|
}
|
|
};
|
|
const def = (obj, key, value, writable = false) => {
|
|
Object.defineProperty(obj, key, {
|
|
configurable: true,
|
|
enumerable: false,
|
|
writable,
|
|
value
|
|
});
|
|
};
|
|
const looseToNumber = val => {
|
|
const n = parseFloat(val);
|
|
return isNaN(n) ? val : n;
|
|
};
|
|
const toNumber = val => {
|
|
const n = isString(val) ? Number(val) : NaN;
|
|
return isNaN(n) ? val : n;
|
|
};
|
|
let _globalThis;
|
|
const getGlobalThis = () => {
|
|
return _globalThis || (_globalThis = typeof globalThis !== "undefined" ? globalThis : typeof self !== "undefined" ? self : typeof window !== "undefined" ? window : typeof __webpack_require__.g !== "undefined" ? __webpack_require__.g : {});
|
|
};
|
|
const identRE = /^[_$a-zA-Z\xA0-\uFFFF][_$a-zA-Z0-9\xA0-\uFFFF]*$/;
|
|
function genPropsAccessExp(name) {
|
|
return identRE.test(name) ? `__props.${name}` : `__props[${JSON.stringify(name)}]`;
|
|
}
|
|
function genCacheKey(source, options) {
|
|
return source + JSON.stringify(options, (_, val) => typeof val === "function" ? val.toString() : val);
|
|
}
|
|
const PatchFlags = {
|
|
"TEXT": 1,
|
|
"1": "TEXT",
|
|
"CLASS": 2,
|
|
"2": "CLASS",
|
|
"STYLE": 4,
|
|
"4": "STYLE",
|
|
"PROPS": 8,
|
|
"8": "PROPS",
|
|
"FULL_PROPS": 16,
|
|
"16": "FULL_PROPS",
|
|
"NEED_HYDRATION": 32,
|
|
"32": "NEED_HYDRATION",
|
|
"STABLE_FRAGMENT": 64,
|
|
"64": "STABLE_FRAGMENT",
|
|
"KEYED_FRAGMENT": 128,
|
|
"128": "KEYED_FRAGMENT",
|
|
"UNKEYED_FRAGMENT": 256,
|
|
"256": "UNKEYED_FRAGMENT",
|
|
"NEED_PATCH": 512,
|
|
"512": "NEED_PATCH",
|
|
"DYNAMIC_SLOTS": 1024,
|
|
"1024": "DYNAMIC_SLOTS",
|
|
"DEV_ROOT_FRAGMENT": 2048,
|
|
"2048": "DEV_ROOT_FRAGMENT",
|
|
"CACHED": -1,
|
|
"-1": "CACHED",
|
|
"BAIL": -2,
|
|
"-2": "BAIL"
|
|
};
|
|
const PatchFlagNames = {
|
|
[1]: `TEXT`,
|
|
[2]: `CLASS`,
|
|
[4]: `STYLE`,
|
|
[8]: `PROPS`,
|
|
[16]: `FULL_PROPS`,
|
|
[32]: `NEED_HYDRATION`,
|
|
[64]: `STABLE_FRAGMENT`,
|
|
[128]: `KEYED_FRAGMENT`,
|
|
[256]: `UNKEYED_FRAGMENT`,
|
|
[512]: `NEED_PATCH`,
|
|
[1024]: `DYNAMIC_SLOTS`,
|
|
[2048]: `DEV_ROOT_FRAGMENT`,
|
|
[-1]: `HOISTED`,
|
|
[-2]: `BAIL`
|
|
};
|
|
const ShapeFlags = {
|
|
"ELEMENT": 1,
|
|
"1": "ELEMENT",
|
|
"FUNCTIONAL_COMPONENT": 2,
|
|
"2": "FUNCTIONAL_COMPONENT",
|
|
"STATEFUL_COMPONENT": 4,
|
|
"4": "STATEFUL_COMPONENT",
|
|
"TEXT_CHILDREN": 8,
|
|
"8": "TEXT_CHILDREN",
|
|
"ARRAY_CHILDREN": 16,
|
|
"16": "ARRAY_CHILDREN",
|
|
"SLOTS_CHILDREN": 32,
|
|
"32": "SLOTS_CHILDREN",
|
|
"TELEPORT": 64,
|
|
"64": "TELEPORT",
|
|
"SUSPENSE": 128,
|
|
"128": "SUSPENSE",
|
|
"COMPONENT_SHOULD_KEEP_ALIVE": 256,
|
|
"256": "COMPONENT_SHOULD_KEEP_ALIVE",
|
|
"COMPONENT_KEPT_ALIVE": 512,
|
|
"512": "COMPONENT_KEPT_ALIVE",
|
|
"COMPONENT": 6,
|
|
"6": "COMPONENT"
|
|
};
|
|
const SlotFlags = {
|
|
"STABLE": 1,
|
|
"1": "STABLE",
|
|
"DYNAMIC": 2,
|
|
"2": "DYNAMIC",
|
|
"FORWARDED": 3,
|
|
"3": "FORWARDED"
|
|
};
|
|
const slotFlagsText = {
|
|
[1]: "STABLE",
|
|
[2]: "DYNAMIC",
|
|
[3]: "FORWARDED"
|
|
};
|
|
const GLOBALS_ALLOWED = "Infinity,undefined,NaN,isFinite,isNaN,parseFloat,parseInt,decodeURI,decodeURIComponent,encodeURI,encodeURIComponent,Math,Number,Date,Array,Object,Boolean,String,RegExp,Map,Set,JSON,Intl,BigInt,console,Error,Symbol";
|
|
const isGloballyAllowed = /* @__PURE__ */(/* unused pure expression or super */ null && (makeMap(GLOBALS_ALLOWED)));
|
|
const isGloballyWhitelisted = (/* unused pure expression or super */ null && (isGloballyAllowed));
|
|
const range = 2;
|
|
function generateCodeFrame(source, start = 0, end = source.length) {
|
|
start = Math.max(0, Math.min(start, source.length));
|
|
end = Math.max(0, Math.min(end, source.length));
|
|
if (start > end) return "";
|
|
let lines = source.split(/(\r?\n)/);
|
|
const newlineSequences = lines.filter((_, idx) => idx % 2 === 1);
|
|
lines = lines.filter((_, idx) => idx % 2 === 0);
|
|
let count = 0;
|
|
const res = [];
|
|
for (let i = 0; i < lines.length; i++) {
|
|
count += lines[i].length + (newlineSequences[i] && newlineSequences[i].length || 0);
|
|
if (count >= start) {
|
|
for (let j = i - range; j <= i + range || end > count; j++) {
|
|
if (j < 0 || j >= lines.length) continue;
|
|
const line = j + 1;
|
|
res.push(`${line}${" ".repeat(Math.max(3 - String(line).length, 0))}| ${lines[j]}`);
|
|
const lineLength = lines[j].length;
|
|
const newLineSeqLength = newlineSequences[j] && newlineSequences[j].length || 0;
|
|
if (j === i) {
|
|
const pad = start - (count - (lineLength + newLineSeqLength));
|
|
const length = Math.max(1, end > count ? lineLength - pad : end - start);
|
|
res.push(` | ` + " ".repeat(pad) + "^".repeat(length));
|
|
} else if (j > i) {
|
|
if (end > count) {
|
|
const length = Math.max(Math.min(end - count, lineLength), 1);
|
|
res.push(` | ` + "^".repeat(length));
|
|
}
|
|
count += lineLength + newLineSeqLength;
|
|
}
|
|
}
|
|
break;
|
|
}
|
|
}
|
|
return res.join("\n");
|
|
}
|
|
function normalizeStyle(value) {
|
|
if (isArray(value)) {
|
|
const res = {};
|
|
for (let i = 0; i < value.length; i++) {
|
|
const item = value[i];
|
|
const normalized = isString(item) ? parseStringStyle(item) : normalizeStyle(item);
|
|
if (normalized) {
|
|
for (const key in normalized) {
|
|
res[key] = normalized[key];
|
|
}
|
|
}
|
|
}
|
|
return res;
|
|
} else if (isString(value) || isObject(value)) {
|
|
return value;
|
|
}
|
|
}
|
|
const listDelimiterRE = /;(?![^(]*\))/g;
|
|
const propertyDelimiterRE = /:([^]+)/;
|
|
const styleCommentRE = /\/\*[^]*?\*\//g;
|
|
function parseStringStyle(cssText) {
|
|
const ret = {};
|
|
cssText.replace(styleCommentRE, "").split(listDelimiterRE).forEach(item => {
|
|
if (item) {
|
|
const tmp = item.split(propertyDelimiterRE);
|
|
tmp.length > 1 && (ret[tmp[0].trim()] = tmp[1].trim());
|
|
}
|
|
});
|
|
return ret;
|
|
}
|
|
function stringifyStyle(styles) {
|
|
if (!styles) return "";
|
|
if (isString(styles)) return styles;
|
|
let ret = "";
|
|
for (const key in styles) {
|
|
const value = styles[key];
|
|
if (isString(value) || typeof value === "number") {
|
|
const normalizedKey = key.startsWith(`--`) ? key : hyphenate(key);
|
|
ret += `${normalizedKey}:${value};`;
|
|
}
|
|
}
|
|
return ret;
|
|
}
|
|
function normalizeClass(value) {
|
|
let res = "";
|
|
if (isString(value)) {
|
|
res = value;
|
|
} else if (isArray(value)) {
|
|
for (let i = 0; i < value.length; i++) {
|
|
const normalized = normalizeClass(value[i]);
|
|
if (normalized) {
|
|
res += normalized + " ";
|
|
}
|
|
}
|
|
} else if (isObject(value)) {
|
|
for (const name in value) {
|
|
if (value[name]) {
|
|
res += name + " ";
|
|
}
|
|
}
|
|
}
|
|
return res.trim();
|
|
}
|
|
function normalizeProps(props) {
|
|
if (!props) return null;
|
|
let {
|
|
class: klass,
|
|
style
|
|
} = props;
|
|
if (klass && !isString(klass)) {
|
|
props.class = normalizeClass(klass);
|
|
}
|
|
if (style) {
|
|
props.style = normalizeStyle(style);
|
|
}
|
|
return props;
|
|
}
|
|
const HTML_TAGS = "html,body,base,head,link,meta,style,title,address,article,aside,footer,header,hgroup,h1,h2,h3,h4,h5,h6,nav,section,div,dd,dl,dt,figcaption,figure,picture,hr,img,li,main,ol,p,pre,ul,a,b,abbr,bdi,bdo,br,cite,code,data,dfn,em,i,kbd,mark,q,rp,rt,ruby,s,samp,small,span,strong,sub,sup,time,u,var,wbr,area,audio,map,track,video,embed,object,param,source,canvas,script,noscript,del,ins,caption,col,colgroup,table,thead,tbody,td,th,tr,button,datalist,fieldset,form,input,label,legend,meter,optgroup,option,output,progress,select,textarea,details,dialog,menu,summary,template,blockquote,iframe,tfoot";
|
|
const SVG_TAGS = "svg,animate,animateMotion,animateTransform,circle,clipPath,color-profile,defs,desc,discard,ellipse,feBlend,feColorMatrix,feComponentTransfer,feComposite,feConvolveMatrix,feDiffuseLighting,feDisplacementMap,feDistantLight,feDropShadow,feFlood,feFuncA,feFuncB,feFuncG,feFuncR,feGaussianBlur,feImage,feMerge,feMergeNode,feMorphology,feOffset,fePointLight,feSpecularLighting,feSpotLight,feTile,feTurbulence,filter,foreignObject,g,hatch,hatchpath,image,line,linearGradient,marker,mask,mesh,meshgradient,meshpatch,meshrow,metadata,mpath,path,pattern,polygon,polyline,radialGradient,rect,set,solidcolor,stop,switch,symbol,text,textPath,title,tspan,unknown,use,view";
|
|
const MATH_TAGS = "annotation,annotation-xml,maction,maligngroup,malignmark,math,menclose,merror,mfenced,mfrac,mfraction,mglyph,mi,mlabeledtr,mlongdiv,mmultiscripts,mn,mo,mover,mpadded,mphantom,mprescripts,mroot,mrow,ms,mscarries,mscarry,msgroup,msline,mspace,msqrt,msrow,mstack,mstyle,msub,msubsup,msup,mtable,mtd,mtext,mtr,munder,munderover,none,semantics";
|
|
const VOID_TAGS = "area,base,br,col,embed,hr,img,input,link,meta,param,source,track,wbr";
|
|
const isHTMLTag = /* @__PURE__ */(/* unused pure expression or super */ null && (makeMap(HTML_TAGS)));
|
|
const isSVGTag = /* @__PURE__ */(/* unused pure expression or super */ null && (makeMap(SVG_TAGS)));
|
|
const isMathMLTag = /* @__PURE__ */(/* unused pure expression or super */ null && (makeMap(MATH_TAGS)));
|
|
const isVoidTag = /* @__PURE__ */(/* unused pure expression or super */ null && (makeMap(VOID_TAGS)));
|
|
const specialBooleanAttrs = `itemscope,allowfullscreen,formnovalidate,ismap,nomodule,novalidate,readonly`;
|
|
const isSpecialBooleanAttr = /* @__PURE__ */makeMap(specialBooleanAttrs);
|
|
const isBooleanAttr = /* @__PURE__ */makeMap(specialBooleanAttrs + `,async,autofocus,autoplay,controls,default,defer,disabled,hidden,inert,loop,open,required,reversed,scoped,seamless,checked,muted,multiple,selected`);
|
|
function includeBooleanAttr(value) {
|
|
return !!value || value === "";
|
|
}
|
|
const unsafeAttrCharRE = /[>/="'\u0009\u000a\u000c\u0020]/;
|
|
const attrValidationCache = {};
|
|
function isSSRSafeAttrName(name) {
|
|
if (attrValidationCache.hasOwnProperty(name)) {
|
|
return attrValidationCache[name];
|
|
}
|
|
const isUnsafe = unsafeAttrCharRE.test(name);
|
|
if (isUnsafe) {
|
|
console.error(`unsafe attribute name: ${name}`);
|
|
}
|
|
return attrValidationCache[name] = !isUnsafe;
|
|
}
|
|
const propsToAttrMap = {
|
|
acceptCharset: "accept-charset",
|
|
className: "class",
|
|
htmlFor: "for",
|
|
httpEquiv: "http-equiv"
|
|
};
|
|
const isKnownHtmlAttr = /* @__PURE__ */(/* unused pure expression or super */ null && (makeMap(`accept,accept-charset,accesskey,action,align,allow,alt,async,autocapitalize,autocomplete,autofocus,autoplay,background,bgcolor,border,buffered,capture,challenge,charset,checked,cite,class,code,codebase,color,cols,colspan,content,contenteditable,contextmenu,controls,coords,crossorigin,csp,data,datetime,decoding,default,defer,dir,dirname,disabled,download,draggable,dropzone,enctype,enterkeyhint,for,form,formaction,formenctype,formmethod,formnovalidate,formtarget,headers,height,hidden,high,href,hreflang,http-equiv,icon,id,importance,inert,integrity,ismap,itemprop,keytype,kind,label,lang,language,loading,list,loop,low,manifest,max,maxlength,minlength,media,min,multiple,muted,name,novalidate,open,optimum,pattern,ping,placeholder,poster,preload,radiogroup,readonly,referrerpolicy,rel,required,reversed,rows,rowspan,sandbox,scope,scoped,selected,shape,size,sizes,slot,span,spellcheck,src,srcdoc,srclang,srcset,start,step,style,summary,tabindex,target,title,translate,type,usemap,value,width,wrap`)));
|
|
const isKnownSvgAttr = /* @__PURE__ */(/* unused pure expression or super */ null && (makeMap(`xmlns,accent-height,accumulate,additive,alignment-baseline,alphabetic,amplitude,arabic-form,ascent,attributeName,attributeType,azimuth,baseFrequency,baseline-shift,baseProfile,bbox,begin,bias,by,calcMode,cap-height,class,clip,clipPathUnits,clip-path,clip-rule,color,color-interpolation,color-interpolation-filters,color-profile,color-rendering,contentScriptType,contentStyleType,crossorigin,cursor,cx,cy,d,decelerate,descent,diffuseConstant,direction,display,divisor,dominant-baseline,dur,dx,dy,edgeMode,elevation,enable-background,end,exponent,fill,fill-opacity,fill-rule,filter,filterRes,filterUnits,flood-color,flood-opacity,font-family,font-size,font-size-adjust,font-stretch,font-style,font-variant,font-weight,format,from,fr,fx,fy,g1,g2,glyph-name,glyph-orientation-horizontal,glyph-orientation-vertical,glyphRef,gradientTransform,gradientUnits,hanging,height,href,hreflang,horiz-adv-x,horiz-origin-x,id,ideographic,image-rendering,in,in2,intercept,k,k1,k2,k3,k4,kernelMatrix,kernelUnitLength,kerning,keyPoints,keySplines,keyTimes,lang,lengthAdjust,letter-spacing,lighting-color,limitingConeAngle,local,marker-end,marker-mid,marker-start,markerHeight,markerUnits,markerWidth,mask,maskContentUnits,maskUnits,mathematical,max,media,method,min,mode,name,numOctaves,offset,opacity,operator,order,orient,orientation,origin,overflow,overline-position,overline-thickness,panose-1,paint-order,path,pathLength,patternContentUnits,patternTransform,patternUnits,ping,pointer-events,points,pointsAtX,pointsAtY,pointsAtZ,preserveAlpha,preserveAspectRatio,primitiveUnits,r,radius,referrerPolicy,refX,refY,rel,rendering-intent,repeatCount,repeatDur,requiredExtensions,requiredFeatures,restart,result,rotate,rx,ry,scale,seed,shape-rendering,slope,spacing,specularConstant,specularExponent,speed,spreadMethod,startOffset,stdDeviation,stemh,stemv,stitchTiles,stop-color,stop-opacity,strikethrough-position,strikethrough-thickness,string,stroke,stroke-dasharray,stroke-dashoffset,stroke-linecap,stroke-linejoin,stroke-miterlimit,stroke-opacity,stroke-width,style,surfaceScale,systemLanguage,tabindex,tableValues,target,targetX,targetY,text-anchor,text-decoration,text-rendering,textLength,to,transform,transform-origin,type,u1,u2,underline-position,underline-thickness,unicode,unicode-bidi,unicode-range,units-per-em,v-alphabetic,v-hanging,v-ideographic,v-mathematical,values,vector-effect,version,vert-adv-y,vert-origin-x,vert-origin-y,viewBox,viewTarget,visibility,width,widths,word-spacing,writing-mode,x,x-height,x1,x2,xChannelSelector,xlink:actuate,xlink:arcrole,xlink:href,xlink:role,xlink:show,xlink:title,xlink:type,xmlns:xlink,xml:base,xml:lang,xml:space,y,y1,y2,yChannelSelector,z,zoomAndPan`)));
|
|
const isKnownMathMLAttr = /* @__PURE__ */(/* unused pure expression or super */ null && (makeMap(`accent,accentunder,actiontype,align,alignmentscope,altimg,altimg-height,altimg-valign,altimg-width,alttext,bevelled,close,columnsalign,columnlines,columnspan,denomalign,depth,dir,display,displaystyle,encoding,equalcolumns,equalrows,fence,fontstyle,fontweight,form,frame,framespacing,groupalign,height,href,id,indentalign,indentalignfirst,indentalignlast,indentshift,indentshiftfirst,indentshiftlast,indextype,justify,largetop,largeop,lquote,lspace,mathbackground,mathcolor,mathsize,mathvariant,maxsize,minlabelspacing,mode,other,overflow,position,rowalign,rowlines,rowspan,rquote,rspace,scriptlevel,scriptminsize,scriptsizemultiplier,selection,separator,separators,shift,side,src,stackalign,stretchy,subscriptshift,superscriptshift,symmetric,voffset,width,widths,xlink:href,xlink:show,xlink:type,xmlns`)));
|
|
function isRenderableAttrValue(value) {
|
|
if (value == null) {
|
|
return false;
|
|
}
|
|
const type = typeof value;
|
|
return type === "string" || type === "number" || type === "boolean";
|
|
}
|
|
const escapeRE = /["'&<>]/;
|
|
function escapeHtml(string) {
|
|
const str = "" + string;
|
|
const match = escapeRE.exec(str);
|
|
if (!match) {
|
|
return str;
|
|
}
|
|
let html = "";
|
|
let escaped;
|
|
let index;
|
|
let lastIndex = 0;
|
|
for (index = match.index; index < str.length; index++) {
|
|
switch (str.charCodeAt(index)) {
|
|
case 34:
|
|
escaped = """;
|
|
break;
|
|
case 38:
|
|
escaped = "&";
|
|
break;
|
|
case 39:
|
|
escaped = "'";
|
|
break;
|
|
case 60:
|
|
escaped = "<";
|
|
break;
|
|
case 62:
|
|
escaped = ">";
|
|
break;
|
|
default:
|
|
continue;
|
|
}
|
|
if (lastIndex !== index) {
|
|
html += str.slice(lastIndex, index);
|
|
}
|
|
lastIndex = index + 1;
|
|
html += escaped;
|
|
}
|
|
return lastIndex !== index ? html + str.slice(lastIndex, index) : html;
|
|
}
|
|
const commentStripRE = /^-?>|<!--|-->|--!>|<!-$/g;
|
|
function escapeHtmlComment(src) {
|
|
return src.replace(commentStripRE, "");
|
|
}
|
|
const cssVarNameEscapeSymbolsRE = /[ !"#$%&'()*+,./:;<=>?@[\\\]^`{|}~]/g;
|
|
function getEscapedCssVarName(key, doubleEscape) {
|
|
return key.replace(cssVarNameEscapeSymbolsRE, s => doubleEscape ? s === '"' ? '\\\\\\"' : `\\\\${s}` : `\\${s}`);
|
|
}
|
|
function looseCompareArrays(a, b) {
|
|
if (a.length !== b.length) return false;
|
|
let equal = true;
|
|
for (let i = 0; equal && i < a.length; i++) {
|
|
equal = looseEqual(a[i], b[i]);
|
|
}
|
|
return equal;
|
|
}
|
|
function looseEqual(a, b) {
|
|
if (a === b) return true;
|
|
let aValidType = isDate(a);
|
|
let bValidType = isDate(b);
|
|
if (aValidType || bValidType) {
|
|
return aValidType && bValidType ? a.getTime() === b.getTime() : false;
|
|
}
|
|
aValidType = isSymbol(a);
|
|
bValidType = isSymbol(b);
|
|
if (aValidType || bValidType) {
|
|
return a === b;
|
|
}
|
|
aValidType = isArray(a);
|
|
bValidType = isArray(b);
|
|
if (aValidType || bValidType) {
|
|
return aValidType && bValidType ? looseCompareArrays(a, b) : false;
|
|
}
|
|
aValidType = isObject(a);
|
|
bValidType = isObject(b);
|
|
if (aValidType || bValidType) {
|
|
if (!aValidType || !bValidType) {
|
|
return false;
|
|
}
|
|
const aKeysCount = Object.keys(a).length;
|
|
const bKeysCount = Object.keys(b).length;
|
|
if (aKeysCount !== bKeysCount) {
|
|
return false;
|
|
}
|
|
for (const key in a) {
|
|
const aHasKey = a.hasOwnProperty(key);
|
|
const bHasKey = b.hasOwnProperty(key);
|
|
if (aHasKey && !bHasKey || !aHasKey && bHasKey || !looseEqual(a[key], b[key])) {
|
|
return false;
|
|
}
|
|
}
|
|
}
|
|
return String(a) === String(b);
|
|
}
|
|
function looseIndexOf(arr, val) {
|
|
return arr.findIndex(item => looseEqual(item, val));
|
|
}
|
|
const isRef = val => {
|
|
return !!(val && val["__v_isRef"] === true);
|
|
};
|
|
const toDisplayString = val => {
|
|
return isString(val) ? val : val == null ? "" : isArray(val) || isObject(val) && (val.toString === objectToString || !isFunction(val.toString)) ? isRef(val) ? toDisplayString(val.value) : JSON.stringify(val, replacer, 2) : String(val);
|
|
};
|
|
const replacer = (_key, val) => {
|
|
if (isRef(val)) {
|
|
return replacer(_key, val.value);
|
|
} else if (isMap(val)) {
|
|
return {
|
|
[`Map(${val.size})`]: [...val.entries()].reduce((entries, [key, val2], i) => {
|
|
entries[stringifySymbol(key, i) + " =>"] = val2;
|
|
return entries;
|
|
}, {})
|
|
};
|
|
} else if (isSet(val)) {
|
|
return {
|
|
[`Set(${val.size})`]: [...val.values()].map(v => stringifySymbol(v))
|
|
};
|
|
} else if (isSymbol(val)) {
|
|
return stringifySymbol(val);
|
|
} else if (isObject(val) && !isArray(val) && !isPlainObject(val)) {
|
|
return String(val);
|
|
}
|
|
return val;
|
|
};
|
|
const stringifySymbol = (v, i = "") => {
|
|
var _a;
|
|
return (
|
|
// Symbol.description in es2019+ so we need to cast here to pass
|
|
// the lib: es2016 check
|
|
isSymbol(v) ? `Symbol(${(_a = v.description) != null ? _a : i})` : v
|
|
);
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 7195:
|
|
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var $ = __webpack_require__(8155);
|
|
var global = __webpack_require__(4074);
|
|
var anInstance = __webpack_require__(1476);
|
|
var anObject = __webpack_require__(6696);
|
|
var isCallable = __webpack_require__(6450);
|
|
var getPrototypeOf = __webpack_require__(3148);
|
|
var defineBuiltInAccessor = __webpack_require__(2123);
|
|
var createProperty = __webpack_require__(2735);
|
|
var fails = __webpack_require__(4212);
|
|
var hasOwn = __webpack_require__(1396);
|
|
var wellKnownSymbol = __webpack_require__(9760);
|
|
var IteratorPrototype = (__webpack_require__(1028).IteratorPrototype);
|
|
var DESCRIPTORS = __webpack_require__(4911);
|
|
var IS_PURE = __webpack_require__(8072);
|
|
|
|
var CONSTRUCTOR = 'constructor';
|
|
var ITERATOR = 'Iterator';
|
|
var TO_STRING_TAG = wellKnownSymbol('toStringTag');
|
|
|
|
var $TypeError = TypeError;
|
|
var NativeIterator = global[ITERATOR];
|
|
|
|
// FF56- have non-standard global helper `Iterator`
|
|
var FORCED = IS_PURE
|
|
|| !isCallable(NativeIterator)
|
|
|| NativeIterator.prototype !== IteratorPrototype
|
|
// FF44- non-standard `Iterator` passes previous tests
|
|
|| !fails(function () { NativeIterator({}); });
|
|
|
|
var IteratorConstructor = function Iterator() {
|
|
anInstance(this, IteratorPrototype);
|
|
if (getPrototypeOf(this) === IteratorPrototype) throw new $TypeError('Abstract class Iterator not directly constructable');
|
|
};
|
|
|
|
var defineIteratorPrototypeAccessor = function (key, value) {
|
|
if (DESCRIPTORS) {
|
|
defineBuiltInAccessor(IteratorPrototype, key, {
|
|
configurable: true,
|
|
get: function () {
|
|
return value;
|
|
},
|
|
set: function (replacement) {
|
|
anObject(this);
|
|
if (this === IteratorPrototype) throw new $TypeError("You can't redefine this property");
|
|
if (hasOwn(this, key)) this[key] = replacement;
|
|
else createProperty(this, key, replacement);
|
|
}
|
|
});
|
|
} else IteratorPrototype[key] = value;
|
|
};
|
|
|
|
if (!hasOwn(IteratorPrototype, TO_STRING_TAG)) defineIteratorPrototypeAccessor(TO_STRING_TAG, ITERATOR);
|
|
|
|
if (FORCED || !hasOwn(IteratorPrototype, CONSTRUCTOR) || IteratorPrototype[CONSTRUCTOR] === Object) {
|
|
defineIteratorPrototypeAccessor(CONSTRUCTOR, IteratorConstructor);
|
|
}
|
|
|
|
IteratorConstructor.prototype = IteratorPrototype;
|
|
|
|
// `Iterator` constructor
|
|
// https://github.com/tc39/proposal-iterator-helpers
|
|
$({ global: true, constructor: true, forced: FORCED }, {
|
|
Iterator: IteratorConstructor
|
|
});
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 7229:
|
|
/***/ (function(__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) {
|
|
|
|
"use strict";
|
|
/* harmony import */ var core_js_modules_es_array_push_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(5513);
|
|
/* harmony import */ var _utils_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(5813);
|
|
/* harmony import */ var _platform_index_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(8394);
|
|
|
|
|
|
|
|
/* harmony default export */ __webpack_exports__.A = (_platform_index_js__WEBPACK_IMPORTED_MODULE_1__/* ["default"] */ .A.hasStandardBrowserEnv ?
|
|
// Standard browser envs support document.cookie
|
|
{
|
|
write(name, value, expires, path, domain, secure) {
|
|
const cookie = [name + '=' + encodeURIComponent(value)];
|
|
_utils_js__WEBPACK_IMPORTED_MODULE_2__/* ["default"] */ .A.isNumber(expires) && cookie.push('expires=' + new Date(expires).toGMTString());
|
|
_utils_js__WEBPACK_IMPORTED_MODULE_2__/* ["default"] */ .A.isString(path) && cookie.push('path=' + path);
|
|
_utils_js__WEBPACK_IMPORTED_MODULE_2__/* ["default"] */ .A.isString(domain) && cookie.push('domain=' + domain);
|
|
secure === true && cookie.push('secure');
|
|
document.cookie = cookie.join('; ');
|
|
},
|
|
read(name) {
|
|
const match = document.cookie.match(new RegExp('(^|;\\s*)(' + name + ')=([^;]*)'));
|
|
return match ? decodeURIComponent(match[3]) : null;
|
|
},
|
|
remove(name) {
|
|
this.write(name, '', Date.now() - 86400000);
|
|
}
|
|
} :
|
|
// Non-standard browser env (web workers, react-native) lack needed support.
|
|
{
|
|
write() {},
|
|
read() {
|
|
return null;
|
|
},
|
|
remove() {}
|
|
});
|
|
|
|
/***/ }),
|
|
|
|
/***/ 7254:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var call = __webpack_require__(4978);
|
|
var create = __webpack_require__(9891);
|
|
var createNonEnumerableProperty = __webpack_require__(5266);
|
|
var defineBuiltIns = __webpack_require__(7866);
|
|
var wellKnownSymbol = __webpack_require__(9760);
|
|
var InternalStateModule = __webpack_require__(9868);
|
|
var getMethod = __webpack_require__(4863);
|
|
var IteratorPrototype = (__webpack_require__(1028).IteratorPrototype);
|
|
var createIterResultObject = __webpack_require__(4006);
|
|
var iteratorClose = __webpack_require__(1298);
|
|
|
|
var TO_STRING_TAG = wellKnownSymbol('toStringTag');
|
|
var ITERATOR_HELPER = 'IteratorHelper';
|
|
var WRAP_FOR_VALID_ITERATOR = 'WrapForValidIterator';
|
|
var setInternalState = InternalStateModule.set;
|
|
|
|
var createIteratorProxyPrototype = function (IS_ITERATOR) {
|
|
var getInternalState = InternalStateModule.getterFor(IS_ITERATOR ? WRAP_FOR_VALID_ITERATOR : ITERATOR_HELPER);
|
|
|
|
return defineBuiltIns(create(IteratorPrototype), {
|
|
next: function next() {
|
|
var state = getInternalState(this);
|
|
// for simplification:
|
|
// for `%WrapForValidIteratorPrototype%.next` our `nextHandler` returns `IterResultObject`
|
|
// for `%IteratorHelperPrototype%.next` - just a value
|
|
if (IS_ITERATOR) return state.nextHandler();
|
|
try {
|
|
var result = state.done ? undefined : state.nextHandler();
|
|
return createIterResultObject(result, state.done);
|
|
} catch (error) {
|
|
state.done = true;
|
|
throw error;
|
|
}
|
|
},
|
|
'return': function () {
|
|
var state = getInternalState(this);
|
|
var iterator = state.iterator;
|
|
state.done = true;
|
|
if (IS_ITERATOR) {
|
|
var returnMethod = getMethod(iterator, 'return');
|
|
return returnMethod ? call(returnMethod, iterator) : createIterResultObject(undefined, true);
|
|
}
|
|
if (state.inner) try {
|
|
iteratorClose(state.inner.iterator, 'normal');
|
|
} catch (error) {
|
|
return iteratorClose(iterator, 'throw', error);
|
|
}
|
|
iteratorClose(iterator, 'normal');
|
|
return createIterResultObject(undefined, true);
|
|
}
|
|
});
|
|
};
|
|
|
|
var WrapForValidIteratorPrototype = createIteratorProxyPrototype(true);
|
|
var IteratorHelperPrototype = createIteratorProxyPrototype(false);
|
|
|
|
createNonEnumerableProperty(IteratorHelperPrototype, TO_STRING_TAG, 'Iterator Helper');
|
|
|
|
module.exports = function (nextHandler, IS_ITERATOR) {
|
|
var IteratorProxy = function Iterator(record, state) {
|
|
if (state) {
|
|
state.iterator = record.iterator;
|
|
state.next = record.next;
|
|
} else state = record;
|
|
state.type = IS_ITERATOR ? WRAP_FOR_VALID_ITERATOR : ITERATOR_HELPER;
|
|
state.nextHandler = nextHandler;
|
|
state.counter = 0;
|
|
state.done = false;
|
|
setInternalState(this, state);
|
|
};
|
|
|
|
IteratorProxy.prototype = IS_ITERATOR ? WrapForValidIteratorPrototype : IteratorHelperPrototype;
|
|
|
|
return IteratorProxy;
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 7289:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var SetHelpers = __webpack_require__(5057);
|
|
var iterate = __webpack_require__(2282);
|
|
|
|
var Set = SetHelpers.Set;
|
|
var add = SetHelpers.add;
|
|
|
|
module.exports = function (set) {
|
|
var result = new Set();
|
|
iterate(set, function (it) {
|
|
add(result, it);
|
|
});
|
|
return result;
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 7312:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var classof = __webpack_require__(4804);
|
|
var getMethod = __webpack_require__(4863);
|
|
var isNullOrUndefined = __webpack_require__(5832);
|
|
var Iterators = __webpack_require__(9702);
|
|
var wellKnownSymbol = __webpack_require__(9760);
|
|
|
|
var ITERATOR = wellKnownSymbol('iterator');
|
|
|
|
module.exports = function (it) {
|
|
if (!isNullOrUndefined(it)) return getMethod(it, ITERATOR)
|
|
|| getMethod(it, '@@iterator')
|
|
|| Iterators[classof(it)];
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 7352:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var toString = __webpack_require__(9864);
|
|
|
|
module.exports = function (argument, $default) {
|
|
return argument === undefined ? arguments.length < 2 ? '' : $default : toString(argument);
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 7420:
|
|
/***/ (function(__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) {
|
|
|
|
"use strict";
|
|
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
/* harmony export */ A: function() { return /* binding */ isAxiosError; }
|
|
/* harmony export */ });
|
|
/* harmony import */ var _utils_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(5813);
|
|
|
|
|
|
|
|
|
|
/**
|
|
* Determines whether the payload is an error thrown by Axios
|
|
*
|
|
* @param {*} payload The value to test
|
|
*
|
|
* @returns {boolean} True if the payload is an error thrown by Axios, otherwise false
|
|
*/
|
|
function isAxiosError(payload) {
|
|
return _utils_js__WEBPACK_IMPORTED_MODULE_0__/* ["default"] */ .A.isObject(payload) && payload.isAxiosError === true;
|
|
}
|
|
|
|
/***/ }),
|
|
|
|
/***/ 7500:
|
|
/***/ (function(__unused_webpack_module, exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
|
|
__webpack_require__(5513);
|
|
__webpack_require__(2952);
|
|
__webpack_require__(6665);
|
|
__webpack_require__(1961);
|
|
__webpack_require__(978);
|
|
__webpack_require__(6949);
|
|
__webpack_require__(1842);
|
|
exports.byteLength = byteLength;
|
|
exports.toByteArray = toByteArray;
|
|
exports.fromByteArray = fromByteArray;
|
|
var lookup = [];
|
|
var revLookup = [];
|
|
var Arr = typeof Uint8Array !== 'undefined' ? Uint8Array : Array;
|
|
var code = 'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/';
|
|
for (var i = 0, len = code.length; i < len; ++i) {
|
|
lookup[i] = code[i];
|
|
revLookup[code.charCodeAt(i)] = i;
|
|
}
|
|
|
|
// Support decoding URL-safe base64 strings, as Node.js does.
|
|
// See: https://en.wikipedia.org/wiki/Base64#URL_applications
|
|
revLookup['-'.charCodeAt(0)] = 62;
|
|
revLookup['_'.charCodeAt(0)] = 63;
|
|
function getLens(b64) {
|
|
var len = b64.length;
|
|
if (len % 4 > 0) {
|
|
throw new Error('Invalid string. Length must be a multiple of 4');
|
|
}
|
|
|
|
// Trim off extra bytes after placeholder bytes are found
|
|
// See: https://github.com/beatgammit/base64-js/issues/42
|
|
var validLen = b64.indexOf('=');
|
|
if (validLen === -1) validLen = len;
|
|
var placeHoldersLen = validLen === len ? 0 : 4 - validLen % 4;
|
|
return [validLen, placeHoldersLen];
|
|
}
|
|
|
|
// base64 is 4/3 + up to two characters of the original data
|
|
function byteLength(b64) {
|
|
var lens = getLens(b64);
|
|
var validLen = lens[0];
|
|
var placeHoldersLen = lens[1];
|
|
return (validLen + placeHoldersLen) * 3 / 4 - placeHoldersLen;
|
|
}
|
|
function _byteLength(b64, validLen, placeHoldersLen) {
|
|
return (validLen + placeHoldersLen) * 3 / 4 - placeHoldersLen;
|
|
}
|
|
function toByteArray(b64) {
|
|
var tmp;
|
|
var lens = getLens(b64);
|
|
var validLen = lens[0];
|
|
var placeHoldersLen = lens[1];
|
|
var arr = new Arr(_byteLength(b64, validLen, placeHoldersLen));
|
|
var curByte = 0;
|
|
|
|
// if there are placeholders, only get up to the last complete 4 chars
|
|
var len = placeHoldersLen > 0 ? validLen - 4 : validLen;
|
|
var i;
|
|
for (i = 0; i < len; i += 4) {
|
|
tmp = revLookup[b64.charCodeAt(i)] << 18 | revLookup[b64.charCodeAt(i + 1)] << 12 | revLookup[b64.charCodeAt(i + 2)] << 6 | revLookup[b64.charCodeAt(i + 3)];
|
|
arr[curByte++] = tmp >> 16 & 0xFF;
|
|
arr[curByte++] = tmp >> 8 & 0xFF;
|
|
arr[curByte++] = tmp & 0xFF;
|
|
}
|
|
if (placeHoldersLen === 2) {
|
|
tmp = revLookup[b64.charCodeAt(i)] << 2 | revLookup[b64.charCodeAt(i + 1)] >> 4;
|
|
arr[curByte++] = tmp & 0xFF;
|
|
}
|
|
if (placeHoldersLen === 1) {
|
|
tmp = revLookup[b64.charCodeAt(i)] << 10 | revLookup[b64.charCodeAt(i + 1)] << 4 | revLookup[b64.charCodeAt(i + 2)] >> 2;
|
|
arr[curByte++] = tmp >> 8 & 0xFF;
|
|
arr[curByte++] = tmp & 0xFF;
|
|
}
|
|
return arr;
|
|
}
|
|
function tripletToBase64(num) {
|
|
return lookup[num >> 18 & 0x3F] + lookup[num >> 12 & 0x3F] + lookup[num >> 6 & 0x3F] + lookup[num & 0x3F];
|
|
}
|
|
function encodeChunk(uint8, start, end) {
|
|
var tmp;
|
|
var output = [];
|
|
for (var i = start; i < end; i += 3) {
|
|
tmp = (uint8[i] << 16 & 0xFF0000) + (uint8[i + 1] << 8 & 0xFF00) + (uint8[i + 2] & 0xFF);
|
|
output.push(tripletToBase64(tmp));
|
|
}
|
|
return output.join('');
|
|
}
|
|
function fromByteArray(uint8) {
|
|
var tmp;
|
|
var len = uint8.length;
|
|
var extraBytes = len % 3; // if we have 1 byte left, pad 2 bytes
|
|
var parts = [];
|
|
var maxChunkLength = 16383; // must be multiple of 3
|
|
|
|
// go through the array every three bytes, we'll deal with trailing stuff later
|
|
for (var i = 0, len2 = len - extraBytes; i < len2; i += maxChunkLength) {
|
|
parts.push(encodeChunk(uint8, i, i + maxChunkLength > len2 ? len2 : i + maxChunkLength));
|
|
}
|
|
|
|
// pad the end with zeros, but make sure to not forget the extra bytes
|
|
if (extraBytes === 1) {
|
|
tmp = uint8[len - 1];
|
|
parts.push(lookup[tmp >> 2] + lookup[tmp << 4 & 0x3F] + '==');
|
|
} else if (extraBytes === 2) {
|
|
tmp = (uint8[len - 2] << 8) + uint8[len - 1];
|
|
parts.push(lookup[tmp >> 10] + lookup[tmp >> 4 & 0x3F] + lookup[tmp << 2 & 0x3F] + '=');
|
|
}
|
|
return parts.join('');
|
|
}
|
|
|
|
/***/ }),
|
|
|
|
/***/ 7596:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
__webpack_require__(5513);
|
|
!function (t, e) {
|
|
true ? module.exports = e() : 0;
|
|
}(this, function () {
|
|
return function (t) {
|
|
function e(o) {
|
|
if (r[o]) return r[o].exports;
|
|
var n = r[o] = {
|
|
exports: {},
|
|
id: o,
|
|
loaded: !1
|
|
};
|
|
return t[o].call(n.exports, n, n.exports, e), n.loaded = !0, n.exports;
|
|
}
|
|
var r = {};
|
|
return e.m = t, e.c = r, e.p = "", e(0);
|
|
}([function (t, e, r) {
|
|
"use strict";
|
|
|
|
t.exports = r(3);
|
|
}, function (t, e) {
|
|
"use strict";
|
|
|
|
!function () {
|
|
Object.assign || Object.defineProperty(Object, "assign", {
|
|
enumerable: !1,
|
|
configurable: !0,
|
|
writable: !0,
|
|
value: function (t) {
|
|
if (void 0 === t || null === t) throw new TypeError("Cannot convert first argument to object");
|
|
for (var e = Object(t), r = 1; r < arguments.length; r++) {
|
|
var o = arguments[r];
|
|
if (void 0 !== o && null !== o) {
|
|
o = Object(o);
|
|
for (var n = Object.keys(Object(o)), i = 0, a = n.length; i < a; i++) {
|
|
var s = n[i],
|
|
u = Object.getOwnPropertyDescriptor(o, s);
|
|
void 0 !== u && u.enumerable && (e[s] = o[s]);
|
|
}
|
|
}
|
|
}
|
|
return e;
|
|
}
|
|
});
|
|
}();
|
|
}, function (t, e) {
|
|
"use strict";
|
|
|
|
t.exports = function () {
|
|
var t = {};
|
|
return t.utf16to8 = function (t) {
|
|
var e, r, o, n;
|
|
for (e = "", o = t.length, r = 0; r < o; r++) n = t.charCodeAt(r), n >= 1 && n <= 127 ? e += t.charAt(r) : n > 2047 ? (e += String.fromCharCode(224 | n >> 12 & 15), e += String.fromCharCode(128 | n >> 6 & 63), e += String.fromCharCode(128 | n >> 0 & 63)) : (e += String.fromCharCode(192 | n >> 6 & 31), e += String.fromCharCode(128 | n >> 0 & 63));
|
|
return e;
|
|
}, t.utf8to16 = function (t) {
|
|
var e, r, o, n, i, a;
|
|
for (e = "", o = t.length, r = 0; r < o;) switch (n = t.charCodeAt(r++), n >> 4) {
|
|
case 0:
|
|
case 1:
|
|
case 2:
|
|
case 3:
|
|
case 4:
|
|
case 5:
|
|
case 6:
|
|
case 7:
|
|
e += t.charAt(r - 1);
|
|
break;
|
|
case 12:
|
|
case 13:
|
|
i = t.charCodeAt(r++), e += String.fromCharCode((31 & n) << 6 | 63 & i);
|
|
break;
|
|
case 14:
|
|
i = t.charCodeAt(r++), a = t.charCodeAt(r++), e += String.fromCharCode((15 & n) << 12 | (63 & i) << 6 | (63 & a) << 0);
|
|
}
|
|
return e;
|
|
}, t;
|
|
}();
|
|
}, function (t, e, r) {
|
|
"use strict";
|
|
|
|
r(1), r(4);
|
|
var o = r(2),
|
|
n = function () {
|
|
function t(t) {
|
|
var e = new QRCode(t.typeNumber, t.correctLevel);
|
|
e.addData(t.text), e.make();
|
|
var r = document.createElement("canvas");
|
|
r.width = t.width, r.height = t.height;
|
|
var o = r.getContext("2d"),
|
|
n = (t.width - 2 * t.padding) / e.getModuleCount(),
|
|
i = (t.height - 2 * t.padding) / e.getModuleCount();
|
|
if (t.reverse) {
|
|
var a = "rgba(0, 0, 0, 0)";
|
|
o.fillStyle = a, t.foreground = a;
|
|
} else o.fillStyle = t.background;
|
|
o.fillRect(0, 0, r.width, r.height);
|
|
for (var s = 0; s < e.getModuleCount(); s++) for (var u = 0; u < e.getModuleCount(); u++) {
|
|
o.fillStyle = e.isDark(s, u) ? t.foreground : t.background;
|
|
var h = Math.ceil((u + 1) * n) - Math.floor(u * n),
|
|
f = Math.ceil((s + 1) * n) - Math.floor(s * n);
|
|
o.fillRect(Math.round(u * n) + t.padding, Math.round(s * i) + t.padding, h, f);
|
|
}
|
|
return r;
|
|
}
|
|
var e = {};
|
|
return e.getQrBase64 = function (e, r) {
|
|
"string" != typeof e && (e = ""), "string" == typeof r ? r = {
|
|
text: r
|
|
} : "object" != typeof r && (r = {}), r = Object.assign({
|
|
padding: 10,
|
|
width: 256,
|
|
height: 256,
|
|
typeNumber: -1,
|
|
correctLevel: QRErrorCorrectLevel.H,
|
|
reverse: !1,
|
|
background: "#ffffff",
|
|
foreground: "#000000"
|
|
}, r);
|
|
try {
|
|
r.text = o.utf16to8(e);
|
|
} catch (t) {
|
|
r.text = "" + t;
|
|
}
|
|
var n = t(r);
|
|
return n.toDataURL();
|
|
}, e.QRErrorCorrectLevel = QRErrorCorrectLevel, e;
|
|
}();
|
|
!window.jrQrcode && (window.jrQrcode = n), t.exports = n;
|
|
}, function (t, e) {
|
|
function r(t) {
|
|
this.mode = s.MODE_8BIT_BYTE, this.data = t;
|
|
}
|
|
function o(t, e) {
|
|
this.typeNumber = t, this.errorCorrectLevel = e, this.modules = null, this.moduleCount = 0, this.dataCache = null, this.dataList = new Array();
|
|
}
|
|
function n(t, e) {
|
|
if (void 0 == t.length) throw new Error(t.length + "/" + e);
|
|
for (var r = 0; r < t.length && 0 == t[r];) r++;
|
|
this.num = new Array(t.length - r + e);
|
|
for (var o = 0; o < t.length - r; o++) this.num[o] = t[o + r];
|
|
}
|
|
function i(t, e) {
|
|
this.totalCount = t, this.dataCount = e;
|
|
}
|
|
function a() {
|
|
this.buffer = new Array(), this.length = 0;
|
|
}
|
|
r.prototype = {
|
|
getLength: function (t) {
|
|
return this.data.length;
|
|
},
|
|
write: function (t) {
|
|
for (var e = 0; e < this.data.length; e++) t.put(this.data.charCodeAt(e), 8);
|
|
}
|
|
}, o.prototype = {
|
|
addData: function (t) {
|
|
var e = new r(t);
|
|
this.dataList.push(e), this.dataCache = null;
|
|
},
|
|
isDark: function (t, e) {
|
|
if (t < 0 || this.moduleCount <= t || e < 0 || this.moduleCount <= e) throw new Error(t + "," + e);
|
|
return this.modules[t][e];
|
|
},
|
|
getModuleCount: function () {
|
|
return this.moduleCount;
|
|
},
|
|
make: function () {
|
|
if (this.typeNumber < 1) {
|
|
var t = 1;
|
|
for (t = 1; t < 40; t++) {
|
|
for (var e = i.getRSBlocks(t, this.errorCorrectLevel), r = new a(), o = 0, n = 0; n < e.length; n++) o += e[n].dataCount;
|
|
for (var n = 0; n < this.dataList.length; n++) {
|
|
var s = this.dataList[n];
|
|
r.put(s.mode, 4), r.put(s.getLength(), f.getLengthInBits(s.mode, t)), s.write(r);
|
|
}
|
|
if (r.getLengthInBits() <= 8 * o) break;
|
|
}
|
|
this.typeNumber = t;
|
|
}
|
|
this.makeImpl(!1, this.getBestMaskPattern());
|
|
},
|
|
makeImpl: function (t, e) {
|
|
this.moduleCount = 4 * this.typeNumber + 17, this.modules = new Array(this.moduleCount);
|
|
for (var r = 0; r < this.moduleCount; r++) {
|
|
this.modules[r] = new Array(this.moduleCount);
|
|
for (var n = 0; n < this.moduleCount; n++) this.modules[r][n] = null;
|
|
}
|
|
this.setupPositionProbePattern(0, 0), this.setupPositionProbePattern(this.moduleCount - 7, 0), this.setupPositionProbePattern(0, this.moduleCount - 7), this.setupPositionAdjustPattern(), this.setupTimingPattern(), this.setupTypeInfo(t, e), this.typeNumber >= 7 && this.setupTypeNumber(t), null == this.dataCache && (this.dataCache = o.createData(this.typeNumber, this.errorCorrectLevel, this.dataList)), this.mapData(this.dataCache, e);
|
|
},
|
|
setupPositionProbePattern: function (t, e) {
|
|
for (var r = -1; r <= 7; r++) if (!(t + r <= -1 || this.moduleCount <= t + r)) for (var o = -1; o <= 7; o++) e + o <= -1 || this.moduleCount <= e + o || (0 <= r && r <= 6 && (0 == o || 6 == o) || 0 <= o && o <= 6 && (0 == r || 6 == r) || 2 <= r && r <= 4 && 2 <= o && o <= 4 ? this.modules[t + r][e + o] = !0 : this.modules[t + r][e + o] = !1);
|
|
},
|
|
getBestMaskPattern: function () {
|
|
for (var t = 0, e = 0, r = 0; r < 8; r++) {
|
|
this.makeImpl(!0, r);
|
|
var o = f.getLostPoint(this);
|
|
(0 == r || t > o) && (t = o, e = r);
|
|
}
|
|
return e;
|
|
},
|
|
createMovieClip: function (t, e, r) {
|
|
var o = t.createEmptyMovieClip(e, r),
|
|
n = 1;
|
|
this.make();
|
|
for (var i = 0; i < this.modules.length; i++) for (var a = i * n, s = 0; s < this.modules[i].length; s++) {
|
|
var u = s * n,
|
|
h = this.modules[i][s];
|
|
h && (o.beginFill(0, 100), o.moveTo(u, a), o.lineTo(u + n, a), o.lineTo(u + n, a + n), o.lineTo(u, a + n), o.endFill());
|
|
}
|
|
return o;
|
|
},
|
|
setupTimingPattern: function () {
|
|
for (var t = 8; t < this.moduleCount - 8; t++) null == this.modules[t][6] && (this.modules[t][6] = t % 2 == 0);
|
|
for (var e = 8; e < this.moduleCount - 8; e++) null == this.modules[6][e] && (this.modules[6][e] = e % 2 == 0);
|
|
},
|
|
setupPositionAdjustPattern: function () {
|
|
for (var t = f.getPatternPosition(this.typeNumber), e = 0; e < t.length; e++) for (var r = 0; r < t.length; r++) {
|
|
var o = t[e],
|
|
n = t[r];
|
|
if (null == this.modules[o][n]) for (var i = -2; i <= 2; i++) for (var a = -2; a <= 2; a++) i == -2 || 2 == i || a == -2 || 2 == a || 0 == i && 0 == a ? this.modules[o + i][n + a] = !0 : this.modules[o + i][n + a] = !1;
|
|
}
|
|
},
|
|
setupTypeNumber: function (t) {
|
|
for (var e = f.getBCHTypeNumber(this.typeNumber), r = 0; r < 18; r++) {
|
|
var o = !t && 1 == (e >> r & 1);
|
|
this.modules[Math.floor(r / 3)][r % 3 + this.moduleCount - 8 - 3] = o;
|
|
}
|
|
for (var r = 0; r < 18; r++) {
|
|
var o = !t && 1 == (e >> r & 1);
|
|
this.modules[r % 3 + this.moduleCount - 8 - 3][Math.floor(r / 3)] = o;
|
|
}
|
|
},
|
|
setupTypeInfo: function (t, e) {
|
|
for (var r = this.errorCorrectLevel << 3 | e, o = f.getBCHTypeInfo(r), n = 0; n < 15; n++) {
|
|
var i = !t && 1 == (o >> n & 1);
|
|
n < 6 ? this.modules[n][8] = i : n < 8 ? this.modules[n + 1][8] = i : this.modules[this.moduleCount - 15 + n][8] = i;
|
|
}
|
|
for (var n = 0; n < 15; n++) {
|
|
var i = !t && 1 == (o >> n & 1);
|
|
n < 8 ? this.modules[8][this.moduleCount - n - 1] = i : n < 9 ? this.modules[8][15 - n - 1 + 1] = i : this.modules[8][15 - n - 1] = i;
|
|
}
|
|
this.modules[this.moduleCount - 8][8] = !t;
|
|
},
|
|
mapData: function (t, e) {
|
|
for (var r = -1, o = this.moduleCount - 1, n = 7, i = 0, a = this.moduleCount - 1; a > 0; a -= 2) for (6 == a && a--;;) {
|
|
for (var s = 0; s < 2; s++) if (null == this.modules[o][a - s]) {
|
|
var u = !1;
|
|
i < t.length && (u = 1 == (t[i] >>> n & 1));
|
|
var h = f.getMask(e, o, a - s);
|
|
h && (u = !u), this.modules[o][a - s] = u, n--, n == -1 && (i++, n = 7);
|
|
}
|
|
if (o += r, o < 0 || this.moduleCount <= o) {
|
|
o -= r, r = -r;
|
|
break;
|
|
}
|
|
}
|
|
}
|
|
}, o.PAD0 = 236, o.PAD1 = 17, o.createData = function (t, e, r) {
|
|
for (var n = i.getRSBlocks(t, e), s = new a(), u = 0; u < r.length; u++) {
|
|
var h = r[u];
|
|
s.put(h.mode, 4), s.put(h.getLength(), f.getLengthInBits(h.mode, t)), h.write(s);
|
|
}
|
|
for (var l = 0, u = 0; u < n.length; u++) l += n[u].dataCount;
|
|
if (s.getLengthInBits() > 8 * l) throw new Error("code length overflow. (" + s.getLengthInBits() + ">" + 8 * l + ")");
|
|
for (s.getLengthInBits() + 4 <= 8 * l && s.put(0, 4); s.getLengthInBits() % 8 != 0;) s.putBit(!1);
|
|
for (;;) {
|
|
if (s.getLengthInBits() >= 8 * l) break;
|
|
if (s.put(o.PAD0, 8), s.getLengthInBits() >= 8 * l) break;
|
|
s.put(o.PAD1, 8);
|
|
}
|
|
return o.createBytes(s, n);
|
|
}, o.createBytes = function (t, e) {
|
|
for (var r = 0, o = 0, i = 0, a = new Array(e.length), s = new Array(e.length), u = 0; u < e.length; u++) {
|
|
var h = e[u].dataCount,
|
|
l = e[u].totalCount - h;
|
|
o = Math.max(o, h), i = Math.max(i, l), a[u] = new Array(h);
|
|
for (var g = 0; g < a[u].length; g++) a[u][g] = 255 & t.buffer[g + r];
|
|
r += h;
|
|
var c = f.getErrorCorrectPolynomial(l),
|
|
d = new n(a[u], c.getLength() - 1),
|
|
v = d.mod(c);
|
|
s[u] = new Array(c.getLength() - 1);
|
|
for (var g = 0; g < s[u].length; g++) {
|
|
var m = g + v.getLength() - s[u].length;
|
|
s[u][g] = m >= 0 ? v.get(m) : 0;
|
|
}
|
|
}
|
|
for (var p = 0, g = 0; g < e.length; g++) p += e[g].totalCount;
|
|
for (var C = new Array(p), E = 0, g = 0; g < o; g++) for (var u = 0; u < e.length; u++) g < a[u].length && (C[E++] = a[u][g]);
|
|
for (var g = 0; g < i; g++) for (var u = 0; u < e.length; u++) g < s[u].length && (C[E++] = s[u][g]);
|
|
return C;
|
|
};
|
|
for (var s = {
|
|
MODE_NUMBER: 1,
|
|
MODE_ALPHA_NUM: 2,
|
|
MODE_8BIT_BYTE: 4,
|
|
MODE_KANJI: 8
|
|
}, u = {
|
|
L: 1,
|
|
M: 0,
|
|
Q: 3,
|
|
H: 2
|
|
}, h = {
|
|
PATTERN000: 0,
|
|
PATTERN001: 1,
|
|
PATTERN010: 2,
|
|
PATTERN011: 3,
|
|
PATTERN100: 4,
|
|
PATTERN101: 5,
|
|
PATTERN110: 6,
|
|
PATTERN111: 7
|
|
}, f = {
|
|
PATTERN_POSITION_TABLE: [[], [6, 18], [6, 22], [6, 26], [6, 30], [6, 34], [6, 22, 38], [6, 24, 42], [6, 26, 46], [6, 28, 50], [6, 30, 54], [6, 32, 58], [6, 34, 62], [6, 26, 46, 66], [6, 26, 48, 70], [6, 26, 50, 74], [6, 30, 54, 78], [6, 30, 56, 82], [6, 30, 58, 86], [6, 34, 62, 90], [6, 28, 50, 72, 94], [6, 26, 50, 74, 98], [6, 30, 54, 78, 102], [6, 28, 54, 80, 106], [6, 32, 58, 84, 110], [6, 30, 58, 86, 114], [6, 34, 62, 90, 118], [6, 26, 50, 74, 98, 122], [6, 30, 54, 78, 102, 126], [6, 26, 52, 78, 104, 130], [6, 30, 56, 82, 108, 134], [6, 34, 60, 86, 112, 138], [6, 30, 58, 86, 114, 142], [6, 34, 62, 90, 118, 146], [6, 30, 54, 78, 102, 126, 150], [6, 24, 50, 76, 102, 128, 154], [6, 28, 54, 80, 106, 132, 158], [6, 32, 58, 84, 110, 136, 162], [6, 26, 54, 82, 110, 138, 166], [6, 30, 58, 86, 114, 142, 170]],
|
|
G15: 1335,
|
|
G18: 7973,
|
|
G15_MASK: 21522,
|
|
getBCHTypeInfo: function (t) {
|
|
for (var e = t << 10; f.getBCHDigit(e) - f.getBCHDigit(f.G15) >= 0;) e ^= f.G15 << f.getBCHDigit(e) - f.getBCHDigit(f.G15);
|
|
return (t << 10 | e) ^ f.G15_MASK;
|
|
},
|
|
getBCHTypeNumber: function (t) {
|
|
for (var e = t << 12; f.getBCHDigit(e) - f.getBCHDigit(f.G18) >= 0;) e ^= f.G18 << f.getBCHDigit(e) - f.getBCHDigit(f.G18);
|
|
return t << 12 | e;
|
|
},
|
|
getBCHDigit: function (t) {
|
|
for (var e = 0; 0 != t;) e++, t >>>= 1;
|
|
return e;
|
|
},
|
|
getPatternPosition: function (t) {
|
|
return f.PATTERN_POSITION_TABLE[t - 1];
|
|
},
|
|
getMask: function (t, e, r) {
|
|
switch (t) {
|
|
case h.PATTERN000:
|
|
return (e + r) % 2 == 0;
|
|
case h.PATTERN001:
|
|
return e % 2 == 0;
|
|
case h.PATTERN010:
|
|
return r % 3 == 0;
|
|
case h.PATTERN011:
|
|
return (e + r) % 3 == 0;
|
|
case h.PATTERN100:
|
|
return (Math.floor(e / 2) + Math.floor(r / 3)) % 2 == 0;
|
|
case h.PATTERN101:
|
|
return e * r % 2 + e * r % 3 == 0;
|
|
case h.PATTERN110:
|
|
return (e * r % 2 + e * r % 3) % 2 == 0;
|
|
case h.PATTERN111:
|
|
return (e * r % 3 + (e + r) % 2) % 2 == 0;
|
|
default:
|
|
throw new Error("bad maskPattern:" + t);
|
|
}
|
|
},
|
|
getErrorCorrectPolynomial: function (t) {
|
|
for (var e = new n([1], 0), r = 0; r < t; r++) e = e.multiply(new n([1, l.gexp(r)], 0));
|
|
return e;
|
|
},
|
|
getLengthInBits: function (t, e) {
|
|
if (1 <= e && e < 10) switch (t) {
|
|
case s.MODE_NUMBER:
|
|
return 10;
|
|
case s.MODE_ALPHA_NUM:
|
|
return 9;
|
|
case s.MODE_8BIT_BYTE:
|
|
return 8;
|
|
case s.MODE_KANJI:
|
|
return 8;
|
|
default:
|
|
throw new Error("mode:" + t);
|
|
} else if (e < 27) switch (t) {
|
|
case s.MODE_NUMBER:
|
|
return 12;
|
|
case s.MODE_ALPHA_NUM:
|
|
return 11;
|
|
case s.MODE_8BIT_BYTE:
|
|
return 16;
|
|
case s.MODE_KANJI:
|
|
return 10;
|
|
default:
|
|
throw new Error("mode:" + t);
|
|
} else {
|
|
if (!(e < 41)) throw new Error("type:" + e);
|
|
switch (t) {
|
|
case s.MODE_NUMBER:
|
|
return 14;
|
|
case s.MODE_ALPHA_NUM:
|
|
return 13;
|
|
case s.MODE_8BIT_BYTE:
|
|
return 16;
|
|
case s.MODE_KANJI:
|
|
return 12;
|
|
default:
|
|
throw new Error("mode:" + t);
|
|
}
|
|
}
|
|
},
|
|
getLostPoint: function (t) {
|
|
for (var e = t.getModuleCount(), r = 0, o = 0; o < e; o++) for (var n = 0; n < e; n++) {
|
|
for (var i = 0, a = t.isDark(o, n), s = -1; s <= 1; s++) if (!(o + s < 0 || e <= o + s)) for (var u = -1; u <= 1; u++) n + u < 0 || e <= n + u || 0 == s && 0 == u || a == t.isDark(o + s, n + u) && i++;
|
|
i > 5 && (r += 3 + i - 5);
|
|
}
|
|
for (var o = 0; o < e - 1; o++) for (var n = 0; n < e - 1; n++) {
|
|
var h = 0;
|
|
t.isDark(o, n) && h++, t.isDark(o + 1, n) && h++, t.isDark(o, n + 1) && h++, t.isDark(o + 1, n + 1) && h++, 0 != h && 4 != h || (r += 3);
|
|
}
|
|
for (var o = 0; o < e; o++) for (var n = 0; n < e - 6; n++) t.isDark(o, n) && !t.isDark(o, n + 1) && t.isDark(o, n + 2) && t.isDark(o, n + 3) && t.isDark(o, n + 4) && !t.isDark(o, n + 5) && t.isDark(o, n + 6) && (r += 40);
|
|
for (var n = 0; n < e; n++) for (var o = 0; o < e - 6; o++) t.isDark(o, n) && !t.isDark(o + 1, n) && t.isDark(o + 2, n) && t.isDark(o + 3, n) && t.isDark(o + 4, n) && !t.isDark(o + 5, n) && t.isDark(o + 6, n) && (r += 40);
|
|
for (var f = 0, n = 0; n < e; n++) for (var o = 0; o < e; o++) t.isDark(o, n) && f++;
|
|
var l = Math.abs(100 * f / e / e - 50) / 5;
|
|
return r += 10 * l;
|
|
}
|
|
}, l = {
|
|
glog: function (t) {
|
|
if (t < 1) throw new Error("glog(" + t + ")");
|
|
return l.LOG_TABLE[t];
|
|
},
|
|
gexp: function (t) {
|
|
for (; t < 0;) t += 255;
|
|
for (; t >= 256;) t -= 255;
|
|
return l.EXP_TABLE[t];
|
|
},
|
|
EXP_TABLE: new Array(256),
|
|
LOG_TABLE: new Array(256)
|
|
}, g = 0; g < 8; g++) l.EXP_TABLE[g] = 1 << g;
|
|
for (var g = 8; g < 256; g++) l.EXP_TABLE[g] = l.EXP_TABLE[g - 4] ^ l.EXP_TABLE[g - 5] ^ l.EXP_TABLE[g - 6] ^ l.EXP_TABLE[g - 8];
|
|
for (var g = 0; g < 255; g++) l.LOG_TABLE[l.EXP_TABLE[g]] = g;
|
|
n.prototype = {
|
|
get: function (t) {
|
|
return this.num[t];
|
|
},
|
|
getLength: function () {
|
|
return this.num.length;
|
|
},
|
|
multiply: function (t) {
|
|
for (var e = new Array(this.getLength() + t.getLength() - 1), r = 0; r < this.getLength(); r++) for (var o = 0; o < t.getLength(); o++) e[r + o] ^= l.gexp(l.glog(this.get(r)) + l.glog(t.get(o)));
|
|
return new n(e, 0);
|
|
},
|
|
mod: function (t) {
|
|
if (this.getLength() - t.getLength() < 0) return this;
|
|
for (var e = l.glog(this.get(0)) - l.glog(t.get(0)), r = new Array(this.getLength()), o = 0; o < this.getLength(); o++) r[o] = this.get(o);
|
|
for (var o = 0; o < t.getLength(); o++) r[o] ^= l.gexp(l.glog(t.get(o)) + e);
|
|
return new n(r, 0).mod(t);
|
|
}
|
|
}, i.RS_BLOCK_TABLE = [[1, 26, 19], [1, 26, 16], [1, 26, 13], [1, 26, 9], [1, 44, 34], [1, 44, 28], [1, 44, 22], [1, 44, 16], [1, 70, 55], [1, 70, 44], [2, 35, 17], [2, 35, 13], [1, 100, 80], [2, 50, 32], [2, 50, 24], [4, 25, 9], [1, 134, 108], [2, 67, 43], [2, 33, 15, 2, 34, 16], [2, 33, 11, 2, 34, 12], [2, 86, 68], [4, 43, 27], [4, 43, 19], [4, 43, 15], [2, 98, 78], [4, 49, 31], [2, 32, 14, 4, 33, 15], [4, 39, 13, 1, 40, 14], [2, 121, 97], [2, 60, 38, 2, 61, 39], [4, 40, 18, 2, 41, 19], [4, 40, 14, 2, 41, 15], [2, 146, 116], [3, 58, 36, 2, 59, 37], [4, 36, 16, 4, 37, 17], [4, 36, 12, 4, 37, 13], [2, 86, 68, 2, 87, 69], [4, 69, 43, 1, 70, 44], [6, 43, 19, 2, 44, 20], [6, 43, 15, 2, 44, 16], [4, 101, 81], [1, 80, 50, 4, 81, 51], [4, 50, 22, 4, 51, 23], [3, 36, 12, 8, 37, 13], [2, 116, 92, 2, 117, 93], [6, 58, 36, 2, 59, 37], [4, 46, 20, 6, 47, 21], [7, 42, 14, 4, 43, 15], [4, 133, 107], [8, 59, 37, 1, 60, 38], [8, 44, 20, 4, 45, 21], [12, 33, 11, 4, 34, 12], [3, 145, 115, 1, 146, 116], [4, 64, 40, 5, 65, 41], [11, 36, 16, 5, 37, 17], [11, 36, 12, 5, 37, 13], [5, 109, 87, 1, 110, 88], [5, 65, 41, 5, 66, 42], [5, 54, 24, 7, 55, 25], [11, 36, 12], [5, 122, 98, 1, 123, 99], [7, 73, 45, 3, 74, 46], [15, 43, 19, 2, 44, 20], [3, 45, 15, 13, 46, 16], [1, 135, 107, 5, 136, 108], [10, 74, 46, 1, 75, 47], [1, 50, 22, 15, 51, 23], [2, 42, 14, 17, 43, 15], [5, 150, 120, 1, 151, 121], [9, 69, 43, 4, 70, 44], [17, 50, 22, 1, 51, 23], [2, 42, 14, 19, 43, 15], [3, 141, 113, 4, 142, 114], [3, 70, 44, 11, 71, 45], [17, 47, 21, 4, 48, 22], [9, 39, 13, 16, 40, 14], [3, 135, 107, 5, 136, 108], [3, 67, 41, 13, 68, 42], [15, 54, 24, 5, 55, 25], [15, 43, 15, 10, 44, 16], [4, 144, 116, 4, 145, 117], [17, 68, 42], [17, 50, 22, 6, 51, 23], [19, 46, 16, 6, 47, 17], [2, 139, 111, 7, 140, 112], [17, 74, 46], [7, 54, 24, 16, 55, 25], [34, 37, 13], [4, 151, 121, 5, 152, 122], [4, 75, 47, 14, 76, 48], [11, 54, 24, 14, 55, 25], [16, 45, 15, 14, 46, 16], [6, 147, 117, 4, 148, 118], [6, 73, 45, 14, 74, 46], [11, 54, 24, 16, 55, 25], [30, 46, 16, 2, 47, 17], [8, 132, 106, 4, 133, 107], [8, 75, 47, 13, 76, 48], [7, 54, 24, 22, 55, 25], [22, 45, 15, 13, 46, 16], [10, 142, 114, 2, 143, 115], [19, 74, 46, 4, 75, 47], [28, 50, 22, 6, 51, 23], [33, 46, 16, 4, 47, 17], [8, 152, 122, 4, 153, 123], [22, 73, 45, 3, 74, 46], [8, 53, 23, 26, 54, 24], [12, 45, 15, 28, 46, 16], [3, 147, 117, 10, 148, 118], [3, 73, 45, 23, 74, 46], [4, 54, 24, 31, 55, 25], [11, 45, 15, 31, 46, 16], [7, 146, 116, 7, 147, 117], [21, 73, 45, 7, 74, 46], [1, 53, 23, 37, 54, 24], [19, 45, 15, 26, 46, 16], [5, 145, 115, 10, 146, 116], [19, 75, 47, 10, 76, 48], [15, 54, 24, 25, 55, 25], [23, 45, 15, 25, 46, 16], [13, 145, 115, 3, 146, 116], [2, 74, 46, 29, 75, 47], [42, 54, 24, 1, 55, 25], [23, 45, 15, 28, 46, 16], [17, 145, 115], [10, 74, 46, 23, 75, 47], [10, 54, 24, 35, 55, 25], [19, 45, 15, 35, 46, 16], [17, 145, 115, 1, 146, 116], [14, 74, 46, 21, 75, 47], [29, 54, 24, 19, 55, 25], [11, 45, 15, 46, 46, 16], [13, 145, 115, 6, 146, 116], [14, 74, 46, 23, 75, 47], [44, 54, 24, 7, 55, 25], [59, 46, 16, 1, 47, 17], [12, 151, 121, 7, 152, 122], [12, 75, 47, 26, 76, 48], [39, 54, 24, 14, 55, 25], [22, 45, 15, 41, 46, 16], [6, 151, 121, 14, 152, 122], [6, 75, 47, 34, 76, 48], [46, 54, 24, 10, 55, 25], [2, 45, 15, 64, 46, 16], [17, 152, 122, 4, 153, 123], [29, 74, 46, 14, 75, 47], [49, 54, 24, 10, 55, 25], [24, 45, 15, 46, 46, 16], [4, 152, 122, 18, 153, 123], [13, 74, 46, 32, 75, 47], [48, 54, 24, 14, 55, 25], [42, 45, 15, 32, 46, 16], [20, 147, 117, 4, 148, 118], [40, 75, 47, 7, 76, 48], [43, 54, 24, 22, 55, 25], [10, 45, 15, 67, 46, 16], [19, 148, 118, 6, 149, 119], [18, 75, 47, 31, 76, 48], [34, 54, 24, 34, 55, 25], [20, 45, 15, 61, 46, 16]], i.getRSBlocks = function (t, e) {
|
|
var r = i.getRsBlockTable(t, e);
|
|
if (void 0 == r) throw new Error("bad rs block @ typeNumber:" + t + "/errorCorrectLevel:" + e);
|
|
for (var o = r.length / 3, n = new Array(), a = 0; a < o; a++) for (var s = r[3 * a + 0], u = r[3 * a + 1], h = r[3 * a + 2], f = 0; f < s; f++) n.push(new i(u, h));
|
|
return n;
|
|
}, i.getRsBlockTable = function (t, e) {
|
|
switch (e) {
|
|
case u.L:
|
|
return i.RS_BLOCK_TABLE[4 * (t - 1) + 0];
|
|
case u.M:
|
|
return i.RS_BLOCK_TABLE[4 * (t - 1) + 1];
|
|
case u.Q:
|
|
return i.RS_BLOCK_TABLE[4 * (t - 1) + 2];
|
|
case u.H:
|
|
return i.RS_BLOCK_TABLE[4 * (t - 1) + 3];
|
|
default:
|
|
return;
|
|
}
|
|
}, a.prototype = {
|
|
get: function (t) {
|
|
var e = Math.floor(t / 8);
|
|
return 1 == (this.buffer[e] >>> 7 - t % 8 & 1);
|
|
},
|
|
put: function (t, e) {
|
|
for (var r = 0; r < e; r++) this.putBit(1 == (t >>> e - r - 1 & 1));
|
|
},
|
|
getLengthInBits: function () {
|
|
return this.length;
|
|
},
|
|
putBit: function (t) {
|
|
var e = Math.floor(this.length / 8);
|
|
this.buffer.length <= e && this.buffer.push(0), t && (this.buffer[e] |= 128 >>> this.length % 8), this.length++;
|
|
}
|
|
}, window.QRCode = o, window.QRErrorCorrectLevel = u;
|
|
try {
|
|
t.exports = {
|
|
QRCode: o,
|
|
QRErrorCorrectLevel: u
|
|
};
|
|
} catch (t) {}
|
|
}]);
|
|
});
|
|
|
|
/***/ }),
|
|
|
|
/***/ 7719:
|
|
/***/ (function(__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) {
|
|
|
|
"use strict";
|
|
/* harmony import */ var core_js_modules_esnext_iterator_constructor_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(7195);
|
|
/* harmony import */ var core_js_modules_esnext_iterator_for_each_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(680);
|
|
/* harmony import */ var _utils_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(5813);
|
|
/* harmony import */ var _core_AxiosError_js__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(956);
|
|
/* harmony import */ var _transitional_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(3773);
|
|
/* harmony import */ var _helpers_toFormData_js__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(6631);
|
|
/* harmony import */ var _helpers_toURLEncodedForm_js__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(9170);
|
|
/* harmony import */ var _platform_index_js__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(8394);
|
|
/* harmony import */ var _helpers_formDataToJSON_js__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(797);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
/**
|
|
* It takes a string, tries to parse it, and if it fails, it returns the stringified version
|
|
* of the input
|
|
*
|
|
* @param {any} rawValue - The value to be stringified.
|
|
* @param {Function} parser - A function that parses a string into a JavaScript object.
|
|
* @param {Function} encoder - A function that takes a value and returns a string.
|
|
*
|
|
* @returns {string} A stringified version of the rawValue.
|
|
*/
|
|
function stringifySafely(rawValue, parser, encoder) {
|
|
if (_utils_js__WEBPACK_IMPORTED_MODULE_2__/* ["default"] */ .A.isString(rawValue)) {
|
|
try {
|
|
(parser || JSON.parse)(rawValue);
|
|
return _utils_js__WEBPACK_IMPORTED_MODULE_2__/* ["default"] */ .A.trim(rawValue);
|
|
} catch (e) {
|
|
if (e.name !== 'SyntaxError') {
|
|
throw e;
|
|
}
|
|
}
|
|
}
|
|
return (encoder || JSON.stringify)(rawValue);
|
|
}
|
|
const defaults = {
|
|
transitional: _transitional_js__WEBPACK_IMPORTED_MODULE_3__/* ["default"] */ .A,
|
|
adapter: ['xhr', 'http'],
|
|
transformRequest: [function transformRequest(data, headers) {
|
|
const contentType = headers.getContentType() || '';
|
|
const hasJSONContentType = contentType.indexOf('application/json') > -1;
|
|
const isObjectPayload = _utils_js__WEBPACK_IMPORTED_MODULE_2__/* ["default"] */ .A.isObject(data);
|
|
if (isObjectPayload && _utils_js__WEBPACK_IMPORTED_MODULE_2__/* ["default"] */ .A.isHTMLForm(data)) {
|
|
data = new FormData(data);
|
|
}
|
|
const isFormData = _utils_js__WEBPACK_IMPORTED_MODULE_2__/* ["default"] */ .A.isFormData(data);
|
|
if (isFormData) {
|
|
return hasJSONContentType ? JSON.stringify((0,_helpers_formDataToJSON_js__WEBPACK_IMPORTED_MODULE_4__/* ["default"] */ .A)(data)) : data;
|
|
}
|
|
if (_utils_js__WEBPACK_IMPORTED_MODULE_2__/* ["default"] */ .A.isArrayBuffer(data) || _utils_js__WEBPACK_IMPORTED_MODULE_2__/* ["default"] */ .A.isBuffer(data) || _utils_js__WEBPACK_IMPORTED_MODULE_2__/* ["default"] */ .A.isStream(data) || _utils_js__WEBPACK_IMPORTED_MODULE_2__/* ["default"] */ .A.isFile(data) || _utils_js__WEBPACK_IMPORTED_MODULE_2__/* ["default"] */ .A.isBlob(data)) {
|
|
return data;
|
|
}
|
|
if (_utils_js__WEBPACK_IMPORTED_MODULE_2__/* ["default"] */ .A.isArrayBufferView(data)) {
|
|
return data.buffer;
|
|
}
|
|
if (_utils_js__WEBPACK_IMPORTED_MODULE_2__/* ["default"] */ .A.isURLSearchParams(data)) {
|
|
headers.setContentType('application/x-www-form-urlencoded;charset=utf-8', false);
|
|
return data.toString();
|
|
}
|
|
let isFileList;
|
|
if (isObjectPayload) {
|
|
if (contentType.indexOf('application/x-www-form-urlencoded') > -1) {
|
|
return (0,_helpers_toURLEncodedForm_js__WEBPACK_IMPORTED_MODULE_5__/* ["default"] */ .A)(data, this.formSerializer).toString();
|
|
}
|
|
if ((isFileList = _utils_js__WEBPACK_IMPORTED_MODULE_2__/* ["default"] */ .A.isFileList(data)) || contentType.indexOf('multipart/form-data') > -1) {
|
|
const _FormData = this.env && this.env.FormData;
|
|
return (0,_helpers_toFormData_js__WEBPACK_IMPORTED_MODULE_6__/* ["default"] */ .A)(isFileList ? {
|
|
'files[]': data
|
|
} : data, _FormData && new _FormData(), this.formSerializer);
|
|
}
|
|
}
|
|
if (isObjectPayload || hasJSONContentType) {
|
|
headers.setContentType('application/json', false);
|
|
return stringifySafely(data);
|
|
}
|
|
return data;
|
|
}],
|
|
transformResponse: [function transformResponse(data) {
|
|
const transitional = this.transitional || defaults.transitional;
|
|
const forcedJSONParsing = transitional && transitional.forcedJSONParsing;
|
|
const JSONRequested = this.responseType === 'json';
|
|
if (data && _utils_js__WEBPACK_IMPORTED_MODULE_2__/* ["default"] */ .A.isString(data) && (forcedJSONParsing && !this.responseType || JSONRequested)) {
|
|
const silentJSONParsing = transitional && transitional.silentJSONParsing;
|
|
const strictJSONParsing = !silentJSONParsing && JSONRequested;
|
|
try {
|
|
return JSON.parse(data);
|
|
} catch (e) {
|
|
if (strictJSONParsing) {
|
|
if (e.name === 'SyntaxError') {
|
|
throw _core_AxiosError_js__WEBPACK_IMPORTED_MODULE_7__/* ["default"] */ .A.from(e, _core_AxiosError_js__WEBPACK_IMPORTED_MODULE_7__/* ["default"] */ .A.ERR_BAD_RESPONSE, this, null, this.response);
|
|
}
|
|
throw e;
|
|
}
|
|
}
|
|
}
|
|
return data;
|
|
}],
|
|
/**
|
|
* A timeout in milliseconds to abort a request. If set to 0 (default) a
|
|
* timeout is not created.
|
|
*/
|
|
timeout: 0,
|
|
xsrfCookieName: 'XSRF-TOKEN',
|
|
xsrfHeaderName: 'X-XSRF-TOKEN',
|
|
maxContentLength: -1,
|
|
maxBodyLength: -1,
|
|
env: {
|
|
FormData: _platform_index_js__WEBPACK_IMPORTED_MODULE_8__/* ["default"] */ .A.classes.FormData,
|
|
Blob: _platform_index_js__WEBPACK_IMPORTED_MODULE_8__/* ["default"] */ .A.classes.Blob
|
|
},
|
|
validateStatus: function validateStatus(status) {
|
|
return status >= 200 && status < 300;
|
|
},
|
|
headers: {
|
|
common: {
|
|
'Accept': 'application/json, text/plain, */*',
|
|
'Content-Type': undefined
|
|
}
|
|
}
|
|
};
|
|
_utils_js__WEBPACK_IMPORTED_MODULE_2__/* ["default"] */ .A.forEach(['delete', 'get', 'head', 'post', 'put', 'patch'], method => {
|
|
defaults.headers[method] = {};
|
|
});
|
|
/* harmony default export */ __webpack_exports__.A = (defaults);
|
|
|
|
/***/ }),
|
|
|
|
/***/ 7727:
|
|
/***/ (function(__unused_webpack___webpack_module__, __webpack_exports__) {
|
|
|
|
"use strict";
|
|
|
|
|
|
/**
|
|
* Calculate data maxRate
|
|
* @param {Number} [samplesCount= 10]
|
|
* @param {Number} [min= 1000]
|
|
* @returns {Function}
|
|
*/
|
|
function speedometer(samplesCount, min) {
|
|
samplesCount = samplesCount || 10;
|
|
const bytes = new Array(samplesCount);
|
|
const timestamps = new Array(samplesCount);
|
|
let head = 0;
|
|
let tail = 0;
|
|
let firstSampleTS;
|
|
min = min !== undefined ? min : 1000;
|
|
return function push(chunkLength) {
|
|
const now = Date.now();
|
|
const startedAt = timestamps[tail];
|
|
if (!firstSampleTS) {
|
|
firstSampleTS = now;
|
|
}
|
|
bytes[head] = chunkLength;
|
|
timestamps[head] = now;
|
|
let i = tail;
|
|
let bytesCount = 0;
|
|
while (i !== head) {
|
|
bytesCount += bytes[i++];
|
|
i = i % samplesCount;
|
|
}
|
|
head = (head + 1) % samplesCount;
|
|
if (head === tail) {
|
|
tail = (tail + 1) % samplesCount;
|
|
}
|
|
if (now - firstSampleTS < min) {
|
|
return;
|
|
}
|
|
const passed = startedAt && now - startedAt;
|
|
return passed ? Math.round(bytesCount * 1000 / passed) : undefined;
|
|
};
|
|
}
|
|
/* harmony default export */ __webpack_exports__.A = (speedometer);
|
|
|
|
/***/ }),
|
|
|
|
/***/ 7866:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var defineBuiltIn = __webpack_require__(3647);
|
|
|
|
module.exports = function (target, src, options) {
|
|
for (var key in src) defineBuiltIn(target, key, src[key], options);
|
|
return target;
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 7900:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var aSet = __webpack_require__(3991);
|
|
var has = (__webpack_require__(5057).has);
|
|
var size = __webpack_require__(903);
|
|
var getSetRecord = __webpack_require__(3108);
|
|
var iterateSet = __webpack_require__(2282);
|
|
var iterateSimple = __webpack_require__(6550);
|
|
var iteratorClose = __webpack_require__(1298);
|
|
|
|
// `Set.prototype.isDisjointFrom` method
|
|
// https://tc39.github.io/proposal-set-methods/#Set.prototype.isDisjointFrom
|
|
module.exports = function isDisjointFrom(other) {
|
|
var O = aSet(this);
|
|
var otherRec = getSetRecord(other);
|
|
if (size(O) <= otherRec.size) return iterateSet(O, function (e) {
|
|
if (otherRec.includes(e)) return false;
|
|
}, true) !== false;
|
|
var iterator = otherRec.getIterator();
|
|
return iterateSimple(iterator, function (e) {
|
|
if (has(O, e)) return iteratorClose(iterator, 'normal', false);
|
|
}) !== false;
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 7958:
|
|
/***/ (function(__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) {
|
|
|
|
"use strict";
|
|
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
/* harmony export */ x: function() { return /* binding */ VERSION; }
|
|
/* harmony export */ });
|
|
const VERSION = "1.6.7";
|
|
|
|
/***/ }),
|
|
|
|
/***/ 7987:
|
|
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) {
|
|
|
|
"use strict";
|
|
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
/* harmony export */ C4: function() { return /* binding */ pauseTracking; },
|
|
/* harmony export */ EW: function() { return /* binding */ computed; },
|
|
/* harmony export */ Gc: function() { return /* binding */ shallowReactive; },
|
|
/* harmony export */ IG: function() { return /* binding */ markRaw; },
|
|
/* harmony export */ KR: function() { return /* binding */ ref; },
|
|
/* harmony export */ Kh: function() { return /* binding */ reactive; },
|
|
/* harmony export */ Pr: function() { return /* binding */ proxyRefs; },
|
|
/* harmony export */ QW: function() { return /* binding */ toRefs; },
|
|
/* harmony export */ R1: function() { return /* binding */ unref; },
|
|
/* harmony export */ X2: function() { return /* binding */ ReactiveEffect; },
|
|
/* harmony export */ bl: function() { return /* binding */ resetTracking; },
|
|
/* harmony export */ fE: function() { return /* binding */ isShallow; },
|
|
/* harmony export */ g8: function() { return /* binding */ isReactive; },
|
|
/* harmony export */ hV: function() { return /* binding */ traverse; },
|
|
/* harmony export */ hZ: function() { return /* binding */ trigger; },
|
|
/* harmony export */ i9: function() { return /* binding */ isRef; },
|
|
/* harmony export */ jr: function() { return /* binding */ onScopeDispose; },
|
|
/* harmony export */ ju: function() { return /* binding */ isProxy; },
|
|
/* harmony export */ lJ: function() { return /* binding */ toReactive; },
|
|
/* harmony export */ o5: function() { return /* binding */ getCurrentScope; },
|
|
/* harmony export */ qA: function() { return /* binding */ shallowReadArray; },
|
|
/* harmony export */ u4: function() { return /* binding */ track; },
|
|
/* harmony export */ uY: function() { return /* binding */ effectScope; },
|
|
/* harmony export */ ux: function() { return /* binding */ toRaw; },
|
|
/* harmony export */ wB: function() { return /* binding */ watch; },
|
|
/* harmony export */ yC: function() { return /* binding */ EffectScope; }
|
|
/* harmony export */ });
|
|
/* unused harmony exports ARRAY_ITERATE_KEY, EffectFlags, ITERATE_KEY, MAP_KEY_ITERATE_KEY, ReactiveFlags, TrackOpTypes, TriggerOpTypes, WatchErrorCodes, customRef, effect, enableTracking, getCurrentWatcher, isReadonly, onEffectCleanup, onWatcherCleanup, reactiveReadArray, readonly, shallowReadonly, shallowRef, stop, toReadonly, toRef, toValue, triggerRef */
|
|
/* harmony import */ var core_js_modules_es_array_push_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(5513);
|
|
/* harmony import */ var core_js_modules_es_array_push_js__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_array_push_js__WEBPACK_IMPORTED_MODULE_0__);
|
|
/* harmony import */ var core_js_modules_es_array_to_reversed_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(8631);
|
|
/* harmony import */ var core_js_modules_es_array_to_reversed_js__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_array_to_reversed_js__WEBPACK_IMPORTED_MODULE_1__);
|
|
/* harmony import */ var core_js_modules_es_array_to_sorted_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(2624);
|
|
/* harmony import */ var core_js_modules_es_array_to_sorted_js__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_array_to_sorted_js__WEBPACK_IMPORTED_MODULE_2__);
|
|
/* harmony import */ var core_js_modules_es_array_to_spliced_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(7037);
|
|
/* harmony import */ var core_js_modules_es_array_to_spliced_js__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_array_to_spliced_js__WEBPACK_IMPORTED_MODULE_3__);
|
|
/* harmony import */ var core_js_modules_es_regexp_flags_js__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(3444);
|
|
/* harmony import */ var core_js_modules_es_regexp_flags_js__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_regexp_flags_js__WEBPACK_IMPORTED_MODULE_4__);
|
|
/* harmony import */ var core_js_modules_esnext_iterator_constructor_js__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(7195);
|
|
/* harmony import */ var core_js_modules_esnext_iterator_constructor_js__WEBPACK_IMPORTED_MODULE_5___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_esnext_iterator_constructor_js__WEBPACK_IMPORTED_MODULE_5__);
|
|
/* harmony import */ var core_js_modules_esnext_iterator_filter_js__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(3741);
|
|
/* harmony import */ var core_js_modules_esnext_iterator_filter_js__WEBPACK_IMPORTED_MODULE_6___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_esnext_iterator_filter_js__WEBPACK_IMPORTED_MODULE_6__);
|
|
/* harmony import */ var core_js_modules_esnext_iterator_for_each_js__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(680);
|
|
/* harmony import */ var core_js_modules_esnext_iterator_for_each_js__WEBPACK_IMPORTED_MODULE_7___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_esnext_iterator_for_each_js__WEBPACK_IMPORTED_MODULE_7__);
|
|
/* harmony import */ var core_js_modules_esnext_iterator_map_js__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(793);
|
|
/* harmony import */ var core_js_modules_esnext_iterator_map_js__WEBPACK_IMPORTED_MODULE_8___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_esnext_iterator_map_js__WEBPACK_IMPORTED_MODULE_8__);
|
|
/* harmony import */ var core_js_modules_esnext_iterator_some_js__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(6071);
|
|
/* harmony import */ var core_js_modules_esnext_iterator_some_js__WEBPACK_IMPORTED_MODULE_9___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_esnext_iterator_some_js__WEBPACK_IMPORTED_MODULE_9__);
|
|
/* harmony import */ var core_js_modules_esnext_set_difference_v2_js__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(8438);
|
|
/* harmony import */ var core_js_modules_esnext_set_difference_v2_js__WEBPACK_IMPORTED_MODULE_10___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_esnext_set_difference_v2_js__WEBPACK_IMPORTED_MODULE_10__);
|
|
/* harmony import */ var core_js_modules_esnext_set_intersection_v2_js__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(6768);
|
|
/* harmony import */ var core_js_modules_esnext_set_intersection_v2_js__WEBPACK_IMPORTED_MODULE_11___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_esnext_set_intersection_v2_js__WEBPACK_IMPORTED_MODULE_11__);
|
|
/* harmony import */ var core_js_modules_esnext_set_is_disjoint_from_v2_js__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(2409);
|
|
/* harmony import */ var core_js_modules_esnext_set_is_disjoint_from_v2_js__WEBPACK_IMPORTED_MODULE_12___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_esnext_set_is_disjoint_from_v2_js__WEBPACK_IMPORTED_MODULE_12__);
|
|
/* harmony import */ var core_js_modules_esnext_set_is_subset_of_v2_js__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(9488);
|
|
/* harmony import */ var core_js_modules_esnext_set_is_subset_of_v2_js__WEBPACK_IMPORTED_MODULE_13___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_esnext_set_is_subset_of_v2_js__WEBPACK_IMPORTED_MODULE_13__);
|
|
/* harmony import */ var core_js_modules_esnext_set_is_superset_of_v2_js__WEBPACK_IMPORTED_MODULE_14__ = __webpack_require__(6591);
|
|
/* harmony import */ var core_js_modules_esnext_set_is_superset_of_v2_js__WEBPACK_IMPORTED_MODULE_14___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_esnext_set_is_superset_of_v2_js__WEBPACK_IMPORTED_MODULE_14__);
|
|
/* harmony import */ var core_js_modules_esnext_set_symmetric_difference_v2_js__WEBPACK_IMPORTED_MODULE_15__ = __webpack_require__(5412);
|
|
/* harmony import */ var core_js_modules_esnext_set_symmetric_difference_v2_js__WEBPACK_IMPORTED_MODULE_15___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_esnext_set_symmetric_difference_v2_js__WEBPACK_IMPORTED_MODULE_15__);
|
|
/* harmony import */ var core_js_modules_esnext_set_union_v2_js__WEBPACK_IMPORTED_MODULE_16__ = __webpack_require__(9214);
|
|
/* harmony import */ var core_js_modules_esnext_set_union_v2_js__WEBPACK_IMPORTED_MODULE_16___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_esnext_set_union_v2_js__WEBPACK_IMPORTED_MODULE_16__);
|
|
/* harmony import */ var _vue_shared__WEBPACK_IMPORTED_MODULE_17__ = __webpack_require__(9818);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
/**
|
|
* @vue/reactivity v3.5.13
|
|
* (c) 2018-present Yuxi (Evan) You and Vue contributors
|
|
* @license MIT
|
|
**/
|
|
|
|
function warn(msg, ...args) {
|
|
console.warn(`[Vue warn] ${msg}`, ...args);
|
|
}
|
|
let activeEffectScope;
|
|
class EffectScope {
|
|
constructor(detached = false) {
|
|
this.detached = detached;
|
|
/**
|
|
* @internal
|
|
*/
|
|
this._active = true;
|
|
/**
|
|
* @internal
|
|
*/
|
|
this.effects = [];
|
|
/**
|
|
* @internal
|
|
*/
|
|
this.cleanups = [];
|
|
this._isPaused = false;
|
|
this.parent = activeEffectScope;
|
|
if (!detached && activeEffectScope) {
|
|
this.index = (activeEffectScope.scopes || (activeEffectScope.scopes = [])).push(this) - 1;
|
|
}
|
|
}
|
|
get active() {
|
|
return this._active;
|
|
}
|
|
pause() {
|
|
if (this._active) {
|
|
this._isPaused = true;
|
|
let i, l;
|
|
if (this.scopes) {
|
|
for (i = 0, l = this.scopes.length; i < l; i++) {
|
|
this.scopes[i].pause();
|
|
}
|
|
}
|
|
for (i = 0, l = this.effects.length; i < l; i++) {
|
|
this.effects[i].pause();
|
|
}
|
|
}
|
|
}
|
|
/**
|
|
* Resumes the effect scope, including all child scopes and effects.
|
|
*/
|
|
resume() {
|
|
if (this._active) {
|
|
if (this._isPaused) {
|
|
this._isPaused = false;
|
|
let i, l;
|
|
if (this.scopes) {
|
|
for (i = 0, l = this.scopes.length; i < l; i++) {
|
|
this.scopes[i].resume();
|
|
}
|
|
}
|
|
for (i = 0, l = this.effects.length; i < l; i++) {
|
|
this.effects[i].resume();
|
|
}
|
|
}
|
|
}
|
|
}
|
|
run(fn) {
|
|
if (this._active) {
|
|
const currentEffectScope = activeEffectScope;
|
|
try {
|
|
activeEffectScope = this;
|
|
return fn();
|
|
} finally {
|
|
activeEffectScope = currentEffectScope;
|
|
}
|
|
} else if (false) {}
|
|
}
|
|
/**
|
|
* This should only be called on non-detached scopes
|
|
* @internal
|
|
*/
|
|
on() {
|
|
activeEffectScope = this;
|
|
}
|
|
/**
|
|
* This should only be called on non-detached scopes
|
|
* @internal
|
|
*/
|
|
off() {
|
|
activeEffectScope = this.parent;
|
|
}
|
|
stop(fromParent) {
|
|
if (this._active) {
|
|
this._active = false;
|
|
let i, l;
|
|
for (i = 0, l = this.effects.length; i < l; i++) {
|
|
this.effects[i].stop();
|
|
}
|
|
this.effects.length = 0;
|
|
for (i = 0, l = this.cleanups.length; i < l; i++) {
|
|
this.cleanups[i]();
|
|
}
|
|
this.cleanups.length = 0;
|
|
if (this.scopes) {
|
|
for (i = 0, l = this.scopes.length; i < l; i++) {
|
|
this.scopes[i].stop(true);
|
|
}
|
|
this.scopes.length = 0;
|
|
}
|
|
if (!this.detached && this.parent && !fromParent) {
|
|
const last = this.parent.scopes.pop();
|
|
if (last && last !== this) {
|
|
this.parent.scopes[this.index] = last;
|
|
last.index = this.index;
|
|
}
|
|
}
|
|
this.parent = void 0;
|
|
}
|
|
}
|
|
}
|
|
function effectScope(detached) {
|
|
return new EffectScope(detached);
|
|
}
|
|
function getCurrentScope() {
|
|
return activeEffectScope;
|
|
}
|
|
function onScopeDispose(fn, failSilently = false) {
|
|
if (activeEffectScope) {
|
|
activeEffectScope.cleanups.push(fn);
|
|
} else if (false) {}
|
|
}
|
|
let activeSub;
|
|
const EffectFlags = {
|
|
"ACTIVE": 1,
|
|
"1": "ACTIVE",
|
|
"RUNNING": 2,
|
|
"2": "RUNNING",
|
|
"TRACKING": 4,
|
|
"4": "TRACKING",
|
|
"NOTIFIED": 8,
|
|
"8": "NOTIFIED",
|
|
"DIRTY": 16,
|
|
"16": "DIRTY",
|
|
"ALLOW_RECURSE": 32,
|
|
"32": "ALLOW_RECURSE",
|
|
"PAUSED": 64,
|
|
"64": "PAUSED"
|
|
};
|
|
const pausedQueueEffects = /* @__PURE__ */new WeakSet();
|
|
class ReactiveEffect {
|
|
constructor(fn) {
|
|
this.fn = fn;
|
|
/**
|
|
* @internal
|
|
*/
|
|
this.deps = void 0;
|
|
/**
|
|
* @internal
|
|
*/
|
|
this.depsTail = void 0;
|
|
/**
|
|
* @internal
|
|
*/
|
|
this.flags = 1 | 4;
|
|
/**
|
|
* @internal
|
|
*/
|
|
this.next = void 0;
|
|
/**
|
|
* @internal
|
|
*/
|
|
this.cleanup = void 0;
|
|
this.scheduler = void 0;
|
|
if (activeEffectScope && activeEffectScope.active) {
|
|
activeEffectScope.effects.push(this);
|
|
}
|
|
}
|
|
pause() {
|
|
this.flags |= 64;
|
|
}
|
|
resume() {
|
|
if (this.flags & 64) {
|
|
this.flags &= ~64;
|
|
if (pausedQueueEffects.has(this)) {
|
|
pausedQueueEffects.delete(this);
|
|
this.trigger();
|
|
}
|
|
}
|
|
}
|
|
/**
|
|
* @internal
|
|
*/
|
|
notify() {
|
|
if (this.flags & 2 && !(this.flags & 32)) {
|
|
return;
|
|
}
|
|
if (!(this.flags & 8)) {
|
|
batch(this);
|
|
}
|
|
}
|
|
run() {
|
|
if (!(this.flags & 1)) {
|
|
return this.fn();
|
|
}
|
|
this.flags |= 2;
|
|
cleanupEffect(this);
|
|
prepareDeps(this);
|
|
const prevEffect = activeSub;
|
|
const prevShouldTrack = shouldTrack;
|
|
activeSub = this;
|
|
shouldTrack = true;
|
|
try {
|
|
return this.fn();
|
|
} finally {
|
|
if (false) {}
|
|
cleanupDeps(this);
|
|
activeSub = prevEffect;
|
|
shouldTrack = prevShouldTrack;
|
|
this.flags &= ~2;
|
|
}
|
|
}
|
|
stop() {
|
|
if (this.flags & 1) {
|
|
for (let link = this.deps; link; link = link.nextDep) {
|
|
removeSub(link);
|
|
}
|
|
this.deps = this.depsTail = void 0;
|
|
cleanupEffect(this);
|
|
this.onStop && this.onStop();
|
|
this.flags &= ~1;
|
|
}
|
|
}
|
|
trigger() {
|
|
if (this.flags & 64) {
|
|
pausedQueueEffects.add(this);
|
|
} else if (this.scheduler) {
|
|
this.scheduler();
|
|
} else {
|
|
this.runIfDirty();
|
|
}
|
|
}
|
|
/**
|
|
* @internal
|
|
*/
|
|
runIfDirty() {
|
|
if (isDirty(this)) {
|
|
this.run();
|
|
}
|
|
}
|
|
get dirty() {
|
|
return isDirty(this);
|
|
}
|
|
}
|
|
let batchDepth = 0;
|
|
let batchedSub;
|
|
let batchedComputed;
|
|
function batch(sub, isComputed = false) {
|
|
sub.flags |= 8;
|
|
if (isComputed) {
|
|
sub.next = batchedComputed;
|
|
batchedComputed = sub;
|
|
return;
|
|
}
|
|
sub.next = batchedSub;
|
|
batchedSub = sub;
|
|
}
|
|
function startBatch() {
|
|
batchDepth++;
|
|
}
|
|
function endBatch() {
|
|
if (--batchDepth > 0) {
|
|
return;
|
|
}
|
|
if (batchedComputed) {
|
|
let e = batchedComputed;
|
|
batchedComputed = void 0;
|
|
while (e) {
|
|
const next = e.next;
|
|
e.next = void 0;
|
|
e.flags &= ~8;
|
|
e = next;
|
|
}
|
|
}
|
|
let error;
|
|
while (batchedSub) {
|
|
let e = batchedSub;
|
|
batchedSub = void 0;
|
|
while (e) {
|
|
const next = e.next;
|
|
e.next = void 0;
|
|
e.flags &= ~8;
|
|
if (e.flags & 1) {
|
|
try {
|
|
;
|
|
e.trigger();
|
|
} catch (err) {
|
|
if (!error) error = err;
|
|
}
|
|
}
|
|
e = next;
|
|
}
|
|
}
|
|
if (error) throw error;
|
|
}
|
|
function prepareDeps(sub) {
|
|
for (let link = sub.deps; link; link = link.nextDep) {
|
|
link.version = -1;
|
|
link.prevActiveLink = link.dep.activeLink;
|
|
link.dep.activeLink = link;
|
|
}
|
|
}
|
|
function cleanupDeps(sub) {
|
|
let head;
|
|
let tail = sub.depsTail;
|
|
let link = tail;
|
|
while (link) {
|
|
const prev = link.prevDep;
|
|
if (link.version === -1) {
|
|
if (link === tail) tail = prev;
|
|
removeSub(link);
|
|
removeDep(link);
|
|
} else {
|
|
head = link;
|
|
}
|
|
link.dep.activeLink = link.prevActiveLink;
|
|
link.prevActiveLink = void 0;
|
|
link = prev;
|
|
}
|
|
sub.deps = head;
|
|
sub.depsTail = tail;
|
|
}
|
|
function isDirty(sub) {
|
|
for (let link = sub.deps; link; link = link.nextDep) {
|
|
if (link.dep.version !== link.version || link.dep.computed && (refreshComputed(link.dep.computed) || link.dep.version !== link.version)) {
|
|
return true;
|
|
}
|
|
}
|
|
if (sub._dirty) {
|
|
return true;
|
|
}
|
|
return false;
|
|
}
|
|
function refreshComputed(computed) {
|
|
if (computed.flags & 4 && !(computed.flags & 16)) {
|
|
return;
|
|
}
|
|
computed.flags &= ~16;
|
|
if (computed.globalVersion === globalVersion) {
|
|
return;
|
|
}
|
|
computed.globalVersion = globalVersion;
|
|
const dep = computed.dep;
|
|
computed.flags |= 2;
|
|
if (dep.version > 0 && !computed.isSSR && computed.deps && !isDirty(computed)) {
|
|
computed.flags &= ~2;
|
|
return;
|
|
}
|
|
const prevSub = activeSub;
|
|
const prevShouldTrack = shouldTrack;
|
|
activeSub = computed;
|
|
shouldTrack = true;
|
|
try {
|
|
prepareDeps(computed);
|
|
const value = computed.fn(computed._value);
|
|
if (dep.version === 0 || (0,_vue_shared__WEBPACK_IMPORTED_MODULE_17__/* .hasChanged */ .$H)(value, computed._value)) {
|
|
computed._value = value;
|
|
dep.version++;
|
|
}
|
|
} catch (err) {
|
|
dep.version++;
|
|
throw err;
|
|
} finally {
|
|
activeSub = prevSub;
|
|
shouldTrack = prevShouldTrack;
|
|
cleanupDeps(computed);
|
|
computed.flags &= ~2;
|
|
}
|
|
}
|
|
function removeSub(link, soft = false) {
|
|
const {
|
|
dep,
|
|
prevSub,
|
|
nextSub
|
|
} = link;
|
|
if (prevSub) {
|
|
prevSub.nextSub = nextSub;
|
|
link.prevSub = void 0;
|
|
}
|
|
if (nextSub) {
|
|
nextSub.prevSub = prevSub;
|
|
link.nextSub = void 0;
|
|
}
|
|
if (false) {}
|
|
if (dep.subs === link) {
|
|
dep.subs = prevSub;
|
|
if (!prevSub && dep.computed) {
|
|
dep.computed.flags &= ~4;
|
|
for (let l = dep.computed.deps; l; l = l.nextDep) {
|
|
removeSub(l, true);
|
|
}
|
|
}
|
|
}
|
|
if (!soft && ! --dep.sc && dep.map) {
|
|
dep.map.delete(dep.key);
|
|
}
|
|
}
|
|
function removeDep(link) {
|
|
const {
|
|
prevDep,
|
|
nextDep
|
|
} = link;
|
|
if (prevDep) {
|
|
prevDep.nextDep = nextDep;
|
|
link.prevDep = void 0;
|
|
}
|
|
if (nextDep) {
|
|
nextDep.prevDep = prevDep;
|
|
link.nextDep = void 0;
|
|
}
|
|
}
|
|
function effect(fn, options) {
|
|
if (fn.effect instanceof ReactiveEffect) {
|
|
fn = fn.effect.fn;
|
|
}
|
|
const e = new ReactiveEffect(fn);
|
|
if (options) {
|
|
extend(e, options);
|
|
}
|
|
try {
|
|
e.run();
|
|
} catch (err) {
|
|
e.stop();
|
|
throw err;
|
|
}
|
|
const runner = e.run.bind(e);
|
|
runner.effect = e;
|
|
return runner;
|
|
}
|
|
function stop(runner) {
|
|
runner.effect.stop();
|
|
}
|
|
let shouldTrack = true;
|
|
const trackStack = [];
|
|
function pauseTracking() {
|
|
trackStack.push(shouldTrack);
|
|
shouldTrack = false;
|
|
}
|
|
function enableTracking() {
|
|
trackStack.push(shouldTrack);
|
|
shouldTrack = true;
|
|
}
|
|
function resetTracking() {
|
|
const last = trackStack.pop();
|
|
shouldTrack = last === void 0 ? true : last;
|
|
}
|
|
function onEffectCleanup(fn, failSilently = false) {
|
|
if (activeSub instanceof ReactiveEffect) {
|
|
activeSub.cleanup = fn;
|
|
} else if (false) {}
|
|
}
|
|
function cleanupEffect(e) {
|
|
const {
|
|
cleanup
|
|
} = e;
|
|
e.cleanup = void 0;
|
|
if (cleanup) {
|
|
const prevSub = activeSub;
|
|
activeSub = void 0;
|
|
try {
|
|
cleanup();
|
|
} finally {
|
|
activeSub = prevSub;
|
|
}
|
|
}
|
|
}
|
|
let globalVersion = 0;
|
|
class Link {
|
|
constructor(sub, dep) {
|
|
this.sub = sub;
|
|
this.dep = dep;
|
|
this.version = dep.version;
|
|
this.nextDep = this.prevDep = this.nextSub = this.prevSub = this.prevActiveLink = void 0;
|
|
}
|
|
}
|
|
class Dep {
|
|
constructor(computed) {
|
|
this.computed = computed;
|
|
this.version = 0;
|
|
/**
|
|
* Link between this dep and the current active effect
|
|
*/
|
|
this.activeLink = void 0;
|
|
/**
|
|
* Doubly linked list representing the subscribing effects (tail)
|
|
*/
|
|
this.subs = void 0;
|
|
/**
|
|
* For object property deps cleanup
|
|
*/
|
|
this.map = void 0;
|
|
this.key = void 0;
|
|
/**
|
|
* Subscriber counter
|
|
*/
|
|
this.sc = 0;
|
|
if (false) {}
|
|
}
|
|
track(debugInfo) {
|
|
if (!activeSub || !shouldTrack || activeSub === this.computed) {
|
|
return;
|
|
}
|
|
let link = this.activeLink;
|
|
if (link === void 0 || link.sub !== activeSub) {
|
|
link = this.activeLink = new Link(activeSub, this);
|
|
if (!activeSub.deps) {
|
|
activeSub.deps = activeSub.depsTail = link;
|
|
} else {
|
|
link.prevDep = activeSub.depsTail;
|
|
activeSub.depsTail.nextDep = link;
|
|
activeSub.depsTail = link;
|
|
}
|
|
addSub(link);
|
|
} else if (link.version === -1) {
|
|
link.version = this.version;
|
|
if (link.nextDep) {
|
|
const next = link.nextDep;
|
|
next.prevDep = link.prevDep;
|
|
if (link.prevDep) {
|
|
link.prevDep.nextDep = next;
|
|
}
|
|
link.prevDep = activeSub.depsTail;
|
|
link.nextDep = void 0;
|
|
activeSub.depsTail.nextDep = link;
|
|
activeSub.depsTail = link;
|
|
if (activeSub.deps === link) {
|
|
activeSub.deps = next;
|
|
}
|
|
}
|
|
}
|
|
if (false) {}
|
|
return link;
|
|
}
|
|
trigger(debugInfo) {
|
|
this.version++;
|
|
globalVersion++;
|
|
this.notify(debugInfo);
|
|
}
|
|
notify(debugInfo) {
|
|
startBatch();
|
|
try {
|
|
if (false) {}
|
|
for (let link = this.subs; link; link = link.prevSub) {
|
|
if (link.sub.notify()) {
|
|
;
|
|
link.sub.dep.notify();
|
|
}
|
|
}
|
|
} finally {
|
|
endBatch();
|
|
}
|
|
}
|
|
}
|
|
function addSub(link) {
|
|
link.dep.sc++;
|
|
if (link.sub.flags & 4) {
|
|
const computed = link.dep.computed;
|
|
if (computed && !link.dep.subs) {
|
|
computed.flags |= 4 | 16;
|
|
for (let l = computed.deps; l; l = l.nextDep) {
|
|
addSub(l);
|
|
}
|
|
}
|
|
const currentTail = link.dep.subs;
|
|
if (currentTail !== link) {
|
|
link.prevSub = currentTail;
|
|
if (currentTail) currentTail.nextSub = link;
|
|
}
|
|
if (false) {}
|
|
link.dep.subs = link;
|
|
}
|
|
}
|
|
const targetMap = /* @__PURE__ */new WeakMap();
|
|
const ITERATE_KEY = Symbol( false ? 0 : "");
|
|
const MAP_KEY_ITERATE_KEY = Symbol( false ? 0 : "");
|
|
const ARRAY_ITERATE_KEY = Symbol( false ? 0 : "");
|
|
function track(target, type, key) {
|
|
if (shouldTrack && activeSub) {
|
|
let depsMap = targetMap.get(target);
|
|
if (!depsMap) {
|
|
targetMap.set(target, depsMap = /* @__PURE__ */new Map());
|
|
}
|
|
let dep = depsMap.get(key);
|
|
if (!dep) {
|
|
depsMap.set(key, dep = new Dep());
|
|
dep.map = depsMap;
|
|
dep.key = key;
|
|
}
|
|
if (false) {} else {
|
|
dep.track();
|
|
}
|
|
}
|
|
}
|
|
function trigger(target, type, key, newValue, oldValue, oldTarget) {
|
|
const depsMap = targetMap.get(target);
|
|
if (!depsMap) {
|
|
globalVersion++;
|
|
return;
|
|
}
|
|
const run = dep => {
|
|
if (dep) {
|
|
if (false) {} else {
|
|
dep.trigger();
|
|
}
|
|
}
|
|
};
|
|
startBatch();
|
|
if (type === "clear") {
|
|
depsMap.forEach(run);
|
|
} else {
|
|
const targetIsArray = (0,_vue_shared__WEBPACK_IMPORTED_MODULE_17__/* .isArray */ .cy)(target);
|
|
const isArrayIndex = targetIsArray && (0,_vue_shared__WEBPACK_IMPORTED_MODULE_17__/* .isIntegerKey */ .yI)(key);
|
|
if (targetIsArray && key === "length") {
|
|
const newLength = Number(newValue);
|
|
depsMap.forEach((dep, key2) => {
|
|
if (key2 === "length" || key2 === ARRAY_ITERATE_KEY || !(0,_vue_shared__WEBPACK_IMPORTED_MODULE_17__/* .isSymbol */ .Bm)(key2) && key2 >= newLength) {
|
|
run(dep);
|
|
}
|
|
});
|
|
} else {
|
|
if (key !== void 0 || depsMap.has(void 0)) {
|
|
run(depsMap.get(key));
|
|
}
|
|
if (isArrayIndex) {
|
|
run(depsMap.get(ARRAY_ITERATE_KEY));
|
|
}
|
|
switch (type) {
|
|
case "add":
|
|
if (!targetIsArray) {
|
|
run(depsMap.get(ITERATE_KEY));
|
|
if ((0,_vue_shared__WEBPACK_IMPORTED_MODULE_17__/* .isMap */ .CE)(target)) {
|
|
run(depsMap.get(MAP_KEY_ITERATE_KEY));
|
|
}
|
|
} else if (isArrayIndex) {
|
|
run(depsMap.get("length"));
|
|
}
|
|
break;
|
|
case "delete":
|
|
if (!targetIsArray) {
|
|
run(depsMap.get(ITERATE_KEY));
|
|
if ((0,_vue_shared__WEBPACK_IMPORTED_MODULE_17__/* .isMap */ .CE)(target)) {
|
|
run(depsMap.get(MAP_KEY_ITERATE_KEY));
|
|
}
|
|
}
|
|
break;
|
|
case "set":
|
|
if ((0,_vue_shared__WEBPACK_IMPORTED_MODULE_17__/* .isMap */ .CE)(target)) {
|
|
run(depsMap.get(ITERATE_KEY));
|
|
}
|
|
break;
|
|
}
|
|
}
|
|
}
|
|
endBatch();
|
|
}
|
|
function getDepFromReactive(object, key) {
|
|
const depMap = targetMap.get(object);
|
|
return depMap && depMap.get(key);
|
|
}
|
|
function reactiveReadArray(array) {
|
|
const raw = toRaw(array);
|
|
if (raw === array) return raw;
|
|
track(raw, "iterate", ARRAY_ITERATE_KEY);
|
|
return isShallow(array) ? raw : raw.map(toReactive);
|
|
}
|
|
function shallowReadArray(arr) {
|
|
track(arr = toRaw(arr), "iterate", ARRAY_ITERATE_KEY);
|
|
return arr;
|
|
}
|
|
const arrayInstrumentations = {
|
|
__proto__: null,
|
|
[Symbol.iterator]() {
|
|
return iterator(this, Symbol.iterator, toReactive);
|
|
},
|
|
concat(...args) {
|
|
return reactiveReadArray(this).concat(...args.map(x => (0,_vue_shared__WEBPACK_IMPORTED_MODULE_17__/* .isArray */ .cy)(x) ? reactiveReadArray(x) : x));
|
|
},
|
|
entries() {
|
|
return iterator(this, "entries", value => {
|
|
value[1] = toReactive(value[1]);
|
|
return value;
|
|
});
|
|
},
|
|
every(fn, thisArg) {
|
|
return apply(this, "every", fn, thisArg, void 0, arguments);
|
|
},
|
|
filter(fn, thisArg) {
|
|
return apply(this, "filter", fn, thisArg, v => v.map(toReactive), arguments);
|
|
},
|
|
find(fn, thisArg) {
|
|
return apply(this, "find", fn, thisArg, toReactive, arguments);
|
|
},
|
|
findIndex(fn, thisArg) {
|
|
return apply(this, "findIndex", fn, thisArg, void 0, arguments);
|
|
},
|
|
findLast(fn, thisArg) {
|
|
return apply(this, "findLast", fn, thisArg, toReactive, arguments);
|
|
},
|
|
findLastIndex(fn, thisArg) {
|
|
return apply(this, "findLastIndex", fn, thisArg, void 0, arguments);
|
|
},
|
|
// flat, flatMap could benefit from ARRAY_ITERATE but are not straight-forward to implement
|
|
forEach(fn, thisArg) {
|
|
return apply(this, "forEach", fn, thisArg, void 0, arguments);
|
|
},
|
|
includes(...args) {
|
|
return searchProxy(this, "includes", args);
|
|
},
|
|
indexOf(...args) {
|
|
return searchProxy(this, "indexOf", args);
|
|
},
|
|
join(separator) {
|
|
return reactiveReadArray(this).join(separator);
|
|
},
|
|
// keys() iterator only reads `length`, no optimisation required
|
|
lastIndexOf(...args) {
|
|
return searchProxy(this, "lastIndexOf", args);
|
|
},
|
|
map(fn, thisArg) {
|
|
return apply(this, "map", fn, thisArg, void 0, arguments);
|
|
},
|
|
pop() {
|
|
return noTracking(this, "pop");
|
|
},
|
|
push(...args) {
|
|
return noTracking(this, "push", args);
|
|
},
|
|
reduce(fn, ...args) {
|
|
return reduce(this, "reduce", fn, args);
|
|
},
|
|
reduceRight(fn, ...args) {
|
|
return reduce(this, "reduceRight", fn, args);
|
|
},
|
|
shift() {
|
|
return noTracking(this, "shift");
|
|
},
|
|
// slice could use ARRAY_ITERATE but also seems to beg for range tracking
|
|
some(fn, thisArg) {
|
|
return apply(this, "some", fn, thisArg, void 0, arguments);
|
|
},
|
|
splice(...args) {
|
|
return noTracking(this, "splice", args);
|
|
},
|
|
toReversed() {
|
|
return reactiveReadArray(this).toReversed();
|
|
},
|
|
toSorted(comparer) {
|
|
return reactiveReadArray(this).toSorted(comparer);
|
|
},
|
|
toSpliced(...args) {
|
|
return reactiveReadArray(this).toSpliced(...args);
|
|
},
|
|
unshift(...args) {
|
|
return noTracking(this, "unshift", args);
|
|
},
|
|
values() {
|
|
return iterator(this, "values", toReactive);
|
|
}
|
|
};
|
|
function iterator(self, method, wrapValue) {
|
|
const arr = shallowReadArray(self);
|
|
const iter = arr[method]();
|
|
if (arr !== self && !isShallow(self)) {
|
|
iter._next = iter.next;
|
|
iter.next = () => {
|
|
const result = iter._next();
|
|
if (result.value) {
|
|
result.value = wrapValue(result.value);
|
|
}
|
|
return result;
|
|
};
|
|
}
|
|
return iter;
|
|
}
|
|
const arrayProto = Array.prototype;
|
|
function apply(self, method, fn, thisArg, wrappedRetFn, args) {
|
|
const arr = shallowReadArray(self);
|
|
const needsWrap = arr !== self && !isShallow(self);
|
|
const methodFn = arr[method];
|
|
if (methodFn !== arrayProto[method]) {
|
|
const result2 = methodFn.apply(self, args);
|
|
return needsWrap ? toReactive(result2) : result2;
|
|
}
|
|
let wrappedFn = fn;
|
|
if (arr !== self) {
|
|
if (needsWrap) {
|
|
wrappedFn = function (item, index) {
|
|
return fn.call(this, toReactive(item), index, self);
|
|
};
|
|
} else if (fn.length > 2) {
|
|
wrappedFn = function (item, index) {
|
|
return fn.call(this, item, index, self);
|
|
};
|
|
}
|
|
}
|
|
const result = methodFn.call(arr, wrappedFn, thisArg);
|
|
return needsWrap && wrappedRetFn ? wrappedRetFn(result) : result;
|
|
}
|
|
function reduce(self, method, fn, args) {
|
|
const arr = shallowReadArray(self);
|
|
let wrappedFn = fn;
|
|
if (arr !== self) {
|
|
if (!isShallow(self)) {
|
|
wrappedFn = function (acc, item, index) {
|
|
return fn.call(this, acc, toReactive(item), index, self);
|
|
};
|
|
} else if (fn.length > 3) {
|
|
wrappedFn = function (acc, item, index) {
|
|
return fn.call(this, acc, item, index, self);
|
|
};
|
|
}
|
|
}
|
|
return arr[method](wrappedFn, ...args);
|
|
}
|
|
function searchProxy(self, method, args) {
|
|
const arr = toRaw(self);
|
|
track(arr, "iterate", ARRAY_ITERATE_KEY);
|
|
const res = arr[method](...args);
|
|
if ((res === -1 || res === false) && isProxy(args[0])) {
|
|
args[0] = toRaw(args[0]);
|
|
return arr[method](...args);
|
|
}
|
|
return res;
|
|
}
|
|
function noTracking(self, method, args = []) {
|
|
pauseTracking();
|
|
startBatch();
|
|
const res = toRaw(self)[method].apply(self, args);
|
|
endBatch();
|
|
resetTracking();
|
|
return res;
|
|
}
|
|
const isNonTrackableKeys = /* @__PURE__ */(0,_vue_shared__WEBPACK_IMPORTED_MODULE_17__/* .makeMap */ .pD)(`__proto__,__v_isRef,__isVue`);
|
|
const builtInSymbols = new Set(/* @__PURE__ */Object.getOwnPropertyNames(Symbol).filter(key => key !== "arguments" && key !== "caller").map(key => Symbol[key]).filter(_vue_shared__WEBPACK_IMPORTED_MODULE_17__/* .isSymbol */ .Bm));
|
|
function hasOwnProperty(key) {
|
|
if (!(0,_vue_shared__WEBPACK_IMPORTED_MODULE_17__/* .isSymbol */ .Bm)(key)) key = String(key);
|
|
const obj = toRaw(this);
|
|
track(obj, "has", key);
|
|
return obj.hasOwnProperty(key);
|
|
}
|
|
class BaseReactiveHandler {
|
|
constructor(_isReadonly = false, _isShallow = false) {
|
|
this._isReadonly = _isReadonly;
|
|
this._isShallow = _isShallow;
|
|
}
|
|
get(target, key, receiver) {
|
|
if (key === "__v_skip") return target["__v_skip"];
|
|
const isReadonly2 = this._isReadonly,
|
|
isShallow2 = this._isShallow;
|
|
if (key === "__v_isReactive") {
|
|
return !isReadonly2;
|
|
} else if (key === "__v_isReadonly") {
|
|
return isReadonly2;
|
|
} else if (key === "__v_isShallow") {
|
|
return isShallow2;
|
|
} else if (key === "__v_raw") {
|
|
if (receiver === (isReadonly2 ? isShallow2 ? shallowReadonlyMap : readonlyMap : isShallow2 ? shallowReactiveMap : reactiveMap).get(target) ||
|
|
// receiver is not the reactive proxy, but has the same prototype
|
|
// this means the receiver is a user proxy of the reactive proxy
|
|
Object.getPrototypeOf(target) === Object.getPrototypeOf(receiver)) {
|
|
return target;
|
|
}
|
|
return;
|
|
}
|
|
const targetIsArray = (0,_vue_shared__WEBPACK_IMPORTED_MODULE_17__/* .isArray */ .cy)(target);
|
|
if (!isReadonly2) {
|
|
let fn;
|
|
if (targetIsArray && (fn = arrayInstrumentations[key])) {
|
|
return fn;
|
|
}
|
|
if (key === "hasOwnProperty") {
|
|
return hasOwnProperty;
|
|
}
|
|
}
|
|
const res = Reflect.get(target, key,
|
|
// if this is a proxy wrapping a ref, return methods using the raw ref
|
|
// as receiver so that we don't have to call `toRaw` on the ref in all
|
|
// its class methods
|
|
isRef(target) ? target : receiver);
|
|
if ((0,_vue_shared__WEBPACK_IMPORTED_MODULE_17__/* .isSymbol */ .Bm)(key) ? builtInSymbols.has(key) : isNonTrackableKeys(key)) {
|
|
return res;
|
|
}
|
|
if (!isReadonly2) {
|
|
track(target, "get", key);
|
|
}
|
|
if (isShallow2) {
|
|
return res;
|
|
}
|
|
if (isRef(res)) {
|
|
return targetIsArray && (0,_vue_shared__WEBPACK_IMPORTED_MODULE_17__/* .isIntegerKey */ .yI)(key) ? res : res.value;
|
|
}
|
|
if ((0,_vue_shared__WEBPACK_IMPORTED_MODULE_17__/* .isObject */ .Gv)(res)) {
|
|
return isReadonly2 ? readonly(res) : reactive(res);
|
|
}
|
|
return res;
|
|
}
|
|
}
|
|
class MutableReactiveHandler extends BaseReactiveHandler {
|
|
constructor(isShallow2 = false) {
|
|
super(false, isShallow2);
|
|
}
|
|
set(target, key, value, receiver) {
|
|
let oldValue = target[key];
|
|
if (!this._isShallow) {
|
|
const isOldValueReadonly = isReadonly(oldValue);
|
|
if (!isShallow(value) && !isReadonly(value)) {
|
|
oldValue = toRaw(oldValue);
|
|
value = toRaw(value);
|
|
}
|
|
if (!(0,_vue_shared__WEBPACK_IMPORTED_MODULE_17__/* .isArray */ .cy)(target) && isRef(oldValue) && !isRef(value)) {
|
|
if (isOldValueReadonly) {
|
|
return false;
|
|
} else {
|
|
oldValue.value = value;
|
|
return true;
|
|
}
|
|
}
|
|
}
|
|
const hadKey = (0,_vue_shared__WEBPACK_IMPORTED_MODULE_17__/* .isArray */ .cy)(target) && (0,_vue_shared__WEBPACK_IMPORTED_MODULE_17__/* .isIntegerKey */ .yI)(key) ? Number(key) < target.length : (0,_vue_shared__WEBPACK_IMPORTED_MODULE_17__/* .hasOwn */ .$3)(target, key);
|
|
const result = Reflect.set(target, key, value, isRef(target) ? target : receiver);
|
|
if (target === toRaw(receiver)) {
|
|
if (!hadKey) {
|
|
trigger(target, "add", key, value);
|
|
} else if ((0,_vue_shared__WEBPACK_IMPORTED_MODULE_17__/* .hasChanged */ .$H)(value, oldValue)) {
|
|
trigger(target, "set", key, value, oldValue);
|
|
}
|
|
}
|
|
return result;
|
|
}
|
|
deleteProperty(target, key) {
|
|
const hadKey = (0,_vue_shared__WEBPACK_IMPORTED_MODULE_17__/* .hasOwn */ .$3)(target, key);
|
|
const oldValue = target[key];
|
|
const result = Reflect.deleteProperty(target, key);
|
|
if (result && hadKey) {
|
|
trigger(target, "delete", key, void 0, oldValue);
|
|
}
|
|
return result;
|
|
}
|
|
has(target, key) {
|
|
const result = Reflect.has(target, key);
|
|
if (!(0,_vue_shared__WEBPACK_IMPORTED_MODULE_17__/* .isSymbol */ .Bm)(key) || !builtInSymbols.has(key)) {
|
|
track(target, "has", key);
|
|
}
|
|
return result;
|
|
}
|
|
ownKeys(target) {
|
|
track(target, "iterate", (0,_vue_shared__WEBPACK_IMPORTED_MODULE_17__/* .isArray */ .cy)(target) ? "length" : ITERATE_KEY);
|
|
return Reflect.ownKeys(target);
|
|
}
|
|
}
|
|
class ReadonlyReactiveHandler extends BaseReactiveHandler {
|
|
constructor(isShallow2 = false) {
|
|
super(true, isShallow2);
|
|
}
|
|
set(target, key) {
|
|
if (false) {}
|
|
return true;
|
|
}
|
|
deleteProperty(target, key) {
|
|
if (false) {}
|
|
return true;
|
|
}
|
|
}
|
|
const mutableHandlers = /* @__PURE__ */new MutableReactiveHandler();
|
|
const readonlyHandlers = /* @__PURE__ */new ReadonlyReactiveHandler();
|
|
const shallowReactiveHandlers = /* @__PURE__ */new MutableReactiveHandler(true);
|
|
const shallowReadonlyHandlers = /* @__PURE__ */new ReadonlyReactiveHandler(true);
|
|
const toShallow = value => value;
|
|
const getProto = v => Reflect.getPrototypeOf(v);
|
|
function createIterableMethod(method, isReadonly2, isShallow2) {
|
|
return function (...args) {
|
|
const target = this["__v_raw"];
|
|
const rawTarget = toRaw(target);
|
|
const targetIsMap = (0,_vue_shared__WEBPACK_IMPORTED_MODULE_17__/* .isMap */ .CE)(rawTarget);
|
|
const isPair = method === "entries" || method === Symbol.iterator && targetIsMap;
|
|
const isKeyOnly = method === "keys" && targetIsMap;
|
|
const innerIterator = target[method](...args);
|
|
const wrap = isShallow2 ? toShallow : isReadonly2 ? toReadonly : toReactive;
|
|
!isReadonly2 && track(rawTarget, "iterate", isKeyOnly ? MAP_KEY_ITERATE_KEY : ITERATE_KEY);
|
|
return {
|
|
// iterator protocol
|
|
next() {
|
|
const {
|
|
value,
|
|
done
|
|
} = innerIterator.next();
|
|
return done ? {
|
|
value,
|
|
done
|
|
} : {
|
|
value: isPair ? [wrap(value[0]), wrap(value[1])] : wrap(value),
|
|
done
|
|
};
|
|
},
|
|
// iterable protocol
|
|
[Symbol.iterator]() {
|
|
return this;
|
|
}
|
|
};
|
|
};
|
|
}
|
|
function createReadonlyMethod(type) {
|
|
return function (...args) {
|
|
if (false) {}
|
|
return type === "delete" ? false : type === "clear" ? void 0 : this;
|
|
};
|
|
}
|
|
function createInstrumentations(readonly, shallow) {
|
|
const instrumentations = {
|
|
get(key) {
|
|
const target = this["__v_raw"];
|
|
const rawTarget = toRaw(target);
|
|
const rawKey = toRaw(key);
|
|
if (!readonly) {
|
|
if ((0,_vue_shared__WEBPACK_IMPORTED_MODULE_17__/* .hasChanged */ .$H)(key, rawKey)) {
|
|
track(rawTarget, "get", key);
|
|
}
|
|
track(rawTarget, "get", rawKey);
|
|
}
|
|
const {
|
|
has
|
|
} = getProto(rawTarget);
|
|
const wrap = shallow ? toShallow : readonly ? toReadonly : toReactive;
|
|
if (has.call(rawTarget, key)) {
|
|
return wrap(target.get(key));
|
|
} else if (has.call(rawTarget, rawKey)) {
|
|
return wrap(target.get(rawKey));
|
|
} else if (target !== rawTarget) {
|
|
target.get(key);
|
|
}
|
|
},
|
|
get size() {
|
|
const target = this["__v_raw"];
|
|
!readonly && track(toRaw(target), "iterate", ITERATE_KEY);
|
|
return Reflect.get(target, "size", target);
|
|
},
|
|
has(key) {
|
|
const target = this["__v_raw"];
|
|
const rawTarget = toRaw(target);
|
|
const rawKey = toRaw(key);
|
|
if (!readonly) {
|
|
if ((0,_vue_shared__WEBPACK_IMPORTED_MODULE_17__/* .hasChanged */ .$H)(key, rawKey)) {
|
|
track(rawTarget, "has", key);
|
|
}
|
|
track(rawTarget, "has", rawKey);
|
|
}
|
|
return key === rawKey ? target.has(key) : target.has(key) || target.has(rawKey);
|
|
},
|
|
forEach(callback, thisArg) {
|
|
const observed = this;
|
|
const target = observed["__v_raw"];
|
|
const rawTarget = toRaw(target);
|
|
const wrap = shallow ? toShallow : readonly ? toReadonly : toReactive;
|
|
!readonly && track(rawTarget, "iterate", ITERATE_KEY);
|
|
return target.forEach((value, key) => {
|
|
return callback.call(thisArg, wrap(value), wrap(key), observed);
|
|
});
|
|
}
|
|
};
|
|
(0,_vue_shared__WEBPACK_IMPORTED_MODULE_17__/* .extend */ .X$)(instrumentations, readonly ? {
|
|
add: createReadonlyMethod("add"),
|
|
set: createReadonlyMethod("set"),
|
|
delete: createReadonlyMethod("delete"),
|
|
clear: createReadonlyMethod("clear")
|
|
} : {
|
|
add(value) {
|
|
if (!shallow && !isShallow(value) && !isReadonly(value)) {
|
|
value = toRaw(value);
|
|
}
|
|
const target = toRaw(this);
|
|
const proto = getProto(target);
|
|
const hadKey = proto.has.call(target, value);
|
|
if (!hadKey) {
|
|
target.add(value);
|
|
trigger(target, "add", value, value);
|
|
}
|
|
return this;
|
|
},
|
|
set(key, value) {
|
|
if (!shallow && !isShallow(value) && !isReadonly(value)) {
|
|
value = toRaw(value);
|
|
}
|
|
const target = toRaw(this);
|
|
const {
|
|
has,
|
|
get
|
|
} = getProto(target);
|
|
let hadKey = has.call(target, key);
|
|
if (!hadKey) {
|
|
key = toRaw(key);
|
|
hadKey = has.call(target, key);
|
|
} else if (false) {}
|
|
const oldValue = get.call(target, key);
|
|
target.set(key, value);
|
|
if (!hadKey) {
|
|
trigger(target, "add", key, value);
|
|
} else if ((0,_vue_shared__WEBPACK_IMPORTED_MODULE_17__/* .hasChanged */ .$H)(value, oldValue)) {
|
|
trigger(target, "set", key, value, oldValue);
|
|
}
|
|
return this;
|
|
},
|
|
delete(key) {
|
|
const target = toRaw(this);
|
|
const {
|
|
has,
|
|
get
|
|
} = getProto(target);
|
|
let hadKey = has.call(target, key);
|
|
if (!hadKey) {
|
|
key = toRaw(key);
|
|
hadKey = has.call(target, key);
|
|
} else if (false) {}
|
|
const oldValue = get ? get.call(target, key) : void 0;
|
|
const result = target.delete(key);
|
|
if (hadKey) {
|
|
trigger(target, "delete", key, void 0, oldValue);
|
|
}
|
|
return result;
|
|
},
|
|
clear() {
|
|
const target = toRaw(this);
|
|
const hadItems = target.size !== 0;
|
|
const oldTarget = false ? 0 : void 0;
|
|
const result = target.clear();
|
|
if (hadItems) {
|
|
trigger(target, "clear", void 0, void 0, oldTarget);
|
|
}
|
|
return result;
|
|
}
|
|
});
|
|
const iteratorMethods = ["keys", "values", "entries", Symbol.iterator];
|
|
iteratorMethods.forEach(method => {
|
|
instrumentations[method] = createIterableMethod(method, readonly, shallow);
|
|
});
|
|
return instrumentations;
|
|
}
|
|
function createInstrumentationGetter(isReadonly2, shallow) {
|
|
const instrumentations = createInstrumentations(isReadonly2, shallow);
|
|
return (target, key, receiver) => {
|
|
if (key === "__v_isReactive") {
|
|
return !isReadonly2;
|
|
} else if (key === "__v_isReadonly") {
|
|
return isReadonly2;
|
|
} else if (key === "__v_raw") {
|
|
return target;
|
|
}
|
|
return Reflect.get((0,_vue_shared__WEBPACK_IMPORTED_MODULE_17__/* .hasOwn */ .$3)(instrumentations, key) && key in target ? instrumentations : target, key, receiver);
|
|
};
|
|
}
|
|
const mutableCollectionHandlers = {
|
|
get: /* @__PURE__ */createInstrumentationGetter(false, false)
|
|
};
|
|
const shallowCollectionHandlers = {
|
|
get: /* @__PURE__ */createInstrumentationGetter(false, true)
|
|
};
|
|
const readonlyCollectionHandlers = {
|
|
get: /* @__PURE__ */createInstrumentationGetter(true, false)
|
|
};
|
|
const shallowReadonlyCollectionHandlers = {
|
|
get: /* @__PURE__ */createInstrumentationGetter(true, true)
|
|
};
|
|
function checkIdentityKeys(target, has, key) {
|
|
const rawKey = toRaw(key);
|
|
if (rawKey !== key && has.call(target, rawKey)) {
|
|
const type = toRawType(target);
|
|
warn(`Reactive ${type} contains both the raw and reactive versions of the same object${type === `Map` ? ` as keys` : ``}, which can lead to inconsistencies. Avoid differentiating between the raw and reactive versions of an object and only use the reactive version if possible.`);
|
|
}
|
|
}
|
|
const reactiveMap = /* @__PURE__ */new WeakMap();
|
|
const shallowReactiveMap = /* @__PURE__ */new WeakMap();
|
|
const readonlyMap = /* @__PURE__ */new WeakMap();
|
|
const shallowReadonlyMap = /* @__PURE__ */new WeakMap();
|
|
function targetTypeMap(rawType) {
|
|
switch (rawType) {
|
|
case "Object":
|
|
case "Array":
|
|
return 1 /* COMMON */;
|
|
case "Map":
|
|
case "Set":
|
|
case "WeakMap":
|
|
case "WeakSet":
|
|
return 2 /* COLLECTION */;
|
|
default:
|
|
return 0 /* INVALID */;
|
|
}
|
|
}
|
|
function getTargetType(value) {
|
|
return value["__v_skip"] || !Object.isExtensible(value) ? 0 /* INVALID */ : targetTypeMap((0,_vue_shared__WEBPACK_IMPORTED_MODULE_17__/* .toRawType */ .Zf)(value));
|
|
}
|
|
function reactive(target) {
|
|
if (isReadonly(target)) {
|
|
return target;
|
|
}
|
|
return createReactiveObject(target, false, mutableHandlers, mutableCollectionHandlers, reactiveMap);
|
|
}
|
|
function shallowReactive(target) {
|
|
return createReactiveObject(target, false, shallowReactiveHandlers, shallowCollectionHandlers, shallowReactiveMap);
|
|
}
|
|
function readonly(target) {
|
|
return createReactiveObject(target, true, readonlyHandlers, readonlyCollectionHandlers, readonlyMap);
|
|
}
|
|
function shallowReadonly(target) {
|
|
return createReactiveObject(target, true, shallowReadonlyHandlers, shallowReadonlyCollectionHandlers, shallowReadonlyMap);
|
|
}
|
|
function createReactiveObject(target, isReadonly2, baseHandlers, collectionHandlers, proxyMap) {
|
|
if (!(0,_vue_shared__WEBPACK_IMPORTED_MODULE_17__/* .isObject */ .Gv)(target)) {
|
|
if (false) {}
|
|
return target;
|
|
}
|
|
if (target["__v_raw"] && !(isReadonly2 && target["__v_isReactive"])) {
|
|
return target;
|
|
}
|
|
const existingProxy = proxyMap.get(target);
|
|
if (existingProxy) {
|
|
return existingProxy;
|
|
}
|
|
const targetType = getTargetType(target);
|
|
if (targetType === 0 /* INVALID */) {
|
|
return target;
|
|
}
|
|
const proxy = new Proxy(target, targetType === 2 /* COLLECTION */ ? collectionHandlers : baseHandlers);
|
|
proxyMap.set(target, proxy);
|
|
return proxy;
|
|
}
|
|
function isReactive(value) {
|
|
if (isReadonly(value)) {
|
|
return isReactive(value["__v_raw"]);
|
|
}
|
|
return !!(value && value["__v_isReactive"]);
|
|
}
|
|
function isReadonly(value) {
|
|
return !!(value && value["__v_isReadonly"]);
|
|
}
|
|
function isShallow(value) {
|
|
return !!(value && value["__v_isShallow"]);
|
|
}
|
|
function isProxy(value) {
|
|
return value ? !!value["__v_raw"] : false;
|
|
}
|
|
function toRaw(observed) {
|
|
const raw = observed && observed["__v_raw"];
|
|
return raw ? toRaw(raw) : observed;
|
|
}
|
|
function markRaw(value) {
|
|
if (!(0,_vue_shared__WEBPACK_IMPORTED_MODULE_17__/* .hasOwn */ .$3)(value, "__v_skip") && Object.isExtensible(value)) {
|
|
(0,_vue_shared__WEBPACK_IMPORTED_MODULE_17__/* .def */ .yQ)(value, "__v_skip", true);
|
|
}
|
|
return value;
|
|
}
|
|
const toReactive = value => (0,_vue_shared__WEBPACK_IMPORTED_MODULE_17__/* .isObject */ .Gv)(value) ? reactive(value) : value;
|
|
const toReadonly = value => (0,_vue_shared__WEBPACK_IMPORTED_MODULE_17__/* .isObject */ .Gv)(value) ? readonly(value) : value;
|
|
function isRef(r) {
|
|
return r ? r["__v_isRef"] === true : false;
|
|
}
|
|
function ref(value) {
|
|
return createRef(value, false);
|
|
}
|
|
function shallowRef(value) {
|
|
return createRef(value, true);
|
|
}
|
|
function createRef(rawValue, shallow) {
|
|
if (isRef(rawValue)) {
|
|
return rawValue;
|
|
}
|
|
return new RefImpl(rawValue, shallow);
|
|
}
|
|
class RefImpl {
|
|
constructor(value, isShallow2) {
|
|
this.dep = new Dep();
|
|
this["__v_isRef"] = true;
|
|
this["__v_isShallow"] = false;
|
|
this._rawValue = isShallow2 ? value : toRaw(value);
|
|
this._value = isShallow2 ? value : toReactive(value);
|
|
this["__v_isShallow"] = isShallow2;
|
|
}
|
|
get value() {
|
|
if (false) {} else {
|
|
this.dep.track();
|
|
}
|
|
return this._value;
|
|
}
|
|
set value(newValue) {
|
|
const oldValue = this._rawValue;
|
|
const useDirectValue = this["__v_isShallow"] || isShallow(newValue) || isReadonly(newValue);
|
|
newValue = useDirectValue ? newValue : toRaw(newValue);
|
|
if ((0,_vue_shared__WEBPACK_IMPORTED_MODULE_17__/* .hasChanged */ .$H)(newValue, oldValue)) {
|
|
this._rawValue = newValue;
|
|
this._value = useDirectValue ? newValue : toReactive(newValue);
|
|
if (false) {} else {
|
|
this.dep.trigger();
|
|
}
|
|
}
|
|
}
|
|
}
|
|
function triggerRef(ref2) {
|
|
if (ref2.dep) {
|
|
if (false) {} else {
|
|
ref2.dep.trigger();
|
|
}
|
|
}
|
|
}
|
|
function unref(ref2) {
|
|
return isRef(ref2) ? ref2.value : ref2;
|
|
}
|
|
function toValue(source) {
|
|
return isFunction(source) ? source() : unref(source);
|
|
}
|
|
const shallowUnwrapHandlers = {
|
|
get: (target, key, receiver) => key === "__v_raw" ? target : unref(Reflect.get(target, key, receiver)),
|
|
set: (target, key, value, receiver) => {
|
|
const oldValue = target[key];
|
|
if (isRef(oldValue) && !isRef(value)) {
|
|
oldValue.value = value;
|
|
return true;
|
|
} else {
|
|
return Reflect.set(target, key, value, receiver);
|
|
}
|
|
}
|
|
};
|
|
function proxyRefs(objectWithRefs) {
|
|
return isReactive(objectWithRefs) ? objectWithRefs : new Proxy(objectWithRefs, shallowUnwrapHandlers);
|
|
}
|
|
class CustomRefImpl {
|
|
constructor(factory) {
|
|
this["__v_isRef"] = true;
|
|
this._value = void 0;
|
|
const dep = this.dep = new Dep();
|
|
const {
|
|
get,
|
|
set
|
|
} = factory(dep.track.bind(dep), dep.trigger.bind(dep));
|
|
this._get = get;
|
|
this._set = set;
|
|
}
|
|
get value() {
|
|
return this._value = this._get();
|
|
}
|
|
set value(newVal) {
|
|
this._set(newVal);
|
|
}
|
|
}
|
|
function customRef(factory) {
|
|
return new CustomRefImpl(factory);
|
|
}
|
|
function toRefs(object) {
|
|
if (false) {}
|
|
const ret = (0,_vue_shared__WEBPACK_IMPORTED_MODULE_17__/* .isArray */ .cy)(object) ? new Array(object.length) : {};
|
|
for (const key in object) {
|
|
ret[key] = propertyToRef(object, key);
|
|
}
|
|
return ret;
|
|
}
|
|
class ObjectRefImpl {
|
|
constructor(_object, _key, _defaultValue) {
|
|
this._object = _object;
|
|
this._key = _key;
|
|
this._defaultValue = _defaultValue;
|
|
this["__v_isRef"] = true;
|
|
this._value = void 0;
|
|
}
|
|
get value() {
|
|
const val = this._object[this._key];
|
|
return this._value = val === void 0 ? this._defaultValue : val;
|
|
}
|
|
set value(newVal) {
|
|
this._object[this._key] = newVal;
|
|
}
|
|
get dep() {
|
|
return getDepFromReactive(toRaw(this._object), this._key);
|
|
}
|
|
}
|
|
class GetterRefImpl {
|
|
constructor(_getter) {
|
|
this._getter = _getter;
|
|
this["__v_isRef"] = true;
|
|
this["__v_isReadonly"] = true;
|
|
this._value = void 0;
|
|
}
|
|
get value() {
|
|
return this._value = this._getter();
|
|
}
|
|
}
|
|
function toRef(source, key, defaultValue) {
|
|
if (isRef(source)) {
|
|
return source;
|
|
} else if (isFunction(source)) {
|
|
return new GetterRefImpl(source);
|
|
} else if (isObject(source) && arguments.length > 1) {
|
|
return propertyToRef(source, key, defaultValue);
|
|
} else {
|
|
return ref(source);
|
|
}
|
|
}
|
|
function propertyToRef(source, key, defaultValue) {
|
|
const val = source[key];
|
|
return isRef(val) ? val : new ObjectRefImpl(source, key, defaultValue);
|
|
}
|
|
class ComputedRefImpl {
|
|
constructor(fn, setter, isSSR) {
|
|
this.fn = fn;
|
|
this.setter = setter;
|
|
/**
|
|
* @internal
|
|
*/
|
|
this._value = void 0;
|
|
/**
|
|
* @internal
|
|
*/
|
|
this.dep = new Dep(this);
|
|
/**
|
|
* @internal
|
|
*/
|
|
this.__v_isRef = true;
|
|
// TODO isolatedDeclarations "__v_isReadonly"
|
|
// A computed is also a subscriber that tracks other deps
|
|
/**
|
|
* @internal
|
|
*/
|
|
this.deps = void 0;
|
|
/**
|
|
* @internal
|
|
*/
|
|
this.depsTail = void 0;
|
|
/**
|
|
* @internal
|
|
*/
|
|
this.flags = 16;
|
|
/**
|
|
* @internal
|
|
*/
|
|
this.globalVersion = globalVersion - 1;
|
|
/**
|
|
* @internal
|
|
*/
|
|
this.next = void 0;
|
|
// for backwards compat
|
|
this.effect = this;
|
|
this["__v_isReadonly"] = !setter;
|
|
this.isSSR = isSSR;
|
|
}
|
|
/**
|
|
* @internal
|
|
*/
|
|
notify() {
|
|
this.flags |= 16;
|
|
if (!(this.flags & 8) &&
|
|
// avoid infinite self recursion
|
|
activeSub !== this) {
|
|
batch(this, true);
|
|
return true;
|
|
} else if (false) {}
|
|
}
|
|
get value() {
|
|
const link = false ? 0 : this.dep.track();
|
|
refreshComputed(this);
|
|
if (link) {
|
|
link.version = this.dep.version;
|
|
}
|
|
return this._value;
|
|
}
|
|
set value(newValue) {
|
|
if (this.setter) {
|
|
this.setter(newValue);
|
|
} else if (false) {}
|
|
}
|
|
}
|
|
function computed(getterOrOptions, debugOptions, isSSR = false) {
|
|
let getter;
|
|
let setter;
|
|
if ((0,_vue_shared__WEBPACK_IMPORTED_MODULE_17__/* .isFunction */ .Tn)(getterOrOptions)) {
|
|
getter = getterOrOptions;
|
|
} else {
|
|
getter = getterOrOptions.get;
|
|
setter = getterOrOptions.set;
|
|
}
|
|
const cRef = new ComputedRefImpl(getter, setter, isSSR);
|
|
if (false) {}
|
|
return cRef;
|
|
}
|
|
const TrackOpTypes = {
|
|
"GET": "get",
|
|
"HAS": "has",
|
|
"ITERATE": "iterate"
|
|
};
|
|
const TriggerOpTypes = {
|
|
"SET": "set",
|
|
"ADD": "add",
|
|
"DELETE": "delete",
|
|
"CLEAR": "clear"
|
|
};
|
|
const ReactiveFlags = {
|
|
"SKIP": "__v_skip",
|
|
"IS_REACTIVE": "__v_isReactive",
|
|
"IS_READONLY": "__v_isReadonly",
|
|
"IS_SHALLOW": "__v_isShallow",
|
|
"RAW": "__v_raw",
|
|
"IS_REF": "__v_isRef"
|
|
};
|
|
const WatchErrorCodes = {
|
|
"WATCH_GETTER": 2,
|
|
"2": "WATCH_GETTER",
|
|
"WATCH_CALLBACK": 3,
|
|
"3": "WATCH_CALLBACK",
|
|
"WATCH_CLEANUP": 4,
|
|
"4": "WATCH_CLEANUP"
|
|
};
|
|
const INITIAL_WATCHER_VALUE = {};
|
|
const cleanupMap = /* @__PURE__ */new WeakMap();
|
|
let activeWatcher = void 0;
|
|
function getCurrentWatcher() {
|
|
return activeWatcher;
|
|
}
|
|
function onWatcherCleanup(cleanupFn, failSilently = false, owner = activeWatcher) {
|
|
if (owner) {
|
|
let cleanups = cleanupMap.get(owner);
|
|
if (!cleanups) cleanupMap.set(owner, cleanups = []);
|
|
cleanups.push(cleanupFn);
|
|
} else if (false) {}
|
|
}
|
|
function watch(source, cb, options = _vue_shared__WEBPACK_IMPORTED_MODULE_17__/* .EMPTY_OBJ */ .MZ) {
|
|
const {
|
|
immediate,
|
|
deep,
|
|
once,
|
|
scheduler,
|
|
augmentJob,
|
|
call
|
|
} = options;
|
|
const warnInvalidSource = s => {
|
|
(options.onWarn || warn)(`Invalid watch source: `, s, `A watch source can only be a getter/effect function, a ref, a reactive object, or an array of these types.`);
|
|
};
|
|
const reactiveGetter = source2 => {
|
|
if (deep) return source2;
|
|
if (isShallow(source2) || deep === false || deep === 0) return traverse(source2, 1);
|
|
return traverse(source2);
|
|
};
|
|
let effect;
|
|
let getter;
|
|
let cleanup;
|
|
let boundCleanup;
|
|
let forceTrigger = false;
|
|
let isMultiSource = false;
|
|
if (isRef(source)) {
|
|
getter = () => source.value;
|
|
forceTrigger = isShallow(source);
|
|
} else if (isReactive(source)) {
|
|
getter = () => reactiveGetter(source);
|
|
forceTrigger = true;
|
|
} else if ((0,_vue_shared__WEBPACK_IMPORTED_MODULE_17__/* .isArray */ .cy)(source)) {
|
|
isMultiSource = true;
|
|
forceTrigger = source.some(s => isReactive(s) || isShallow(s));
|
|
getter = () => source.map(s => {
|
|
if (isRef(s)) {
|
|
return s.value;
|
|
} else if (isReactive(s)) {
|
|
return reactiveGetter(s);
|
|
} else if ((0,_vue_shared__WEBPACK_IMPORTED_MODULE_17__/* .isFunction */ .Tn)(s)) {
|
|
return call ? call(s, 2) : s();
|
|
} else {
|
|
false && 0;
|
|
}
|
|
});
|
|
} else if ((0,_vue_shared__WEBPACK_IMPORTED_MODULE_17__/* .isFunction */ .Tn)(source)) {
|
|
if (cb) {
|
|
getter = call ? () => call(source, 2) : source;
|
|
} else {
|
|
getter = () => {
|
|
if (cleanup) {
|
|
pauseTracking();
|
|
try {
|
|
cleanup();
|
|
} finally {
|
|
resetTracking();
|
|
}
|
|
}
|
|
const currentEffect = activeWatcher;
|
|
activeWatcher = effect;
|
|
try {
|
|
return call ? call(source, 3, [boundCleanup]) : source(boundCleanup);
|
|
} finally {
|
|
activeWatcher = currentEffect;
|
|
}
|
|
};
|
|
}
|
|
} else {
|
|
getter = _vue_shared__WEBPACK_IMPORTED_MODULE_17__/* .NOOP */ .tE;
|
|
false && 0;
|
|
}
|
|
if (cb && deep) {
|
|
const baseGetter = getter;
|
|
const depth = deep === true ? Infinity : deep;
|
|
getter = () => traverse(baseGetter(), depth);
|
|
}
|
|
const scope = getCurrentScope();
|
|
const watchHandle = () => {
|
|
effect.stop();
|
|
if (scope && scope.active) {
|
|
(0,_vue_shared__WEBPACK_IMPORTED_MODULE_17__/* .remove */ .TF)(scope.effects, effect);
|
|
}
|
|
};
|
|
if (once && cb) {
|
|
const _cb = cb;
|
|
cb = (...args) => {
|
|
_cb(...args);
|
|
watchHandle();
|
|
};
|
|
}
|
|
let oldValue = isMultiSource ? new Array(source.length).fill(INITIAL_WATCHER_VALUE) : INITIAL_WATCHER_VALUE;
|
|
const job = immediateFirstRun => {
|
|
if (!(effect.flags & 1) || !effect.dirty && !immediateFirstRun) {
|
|
return;
|
|
}
|
|
if (cb) {
|
|
const newValue = effect.run();
|
|
if (deep || forceTrigger || (isMultiSource ? newValue.some((v, i) => (0,_vue_shared__WEBPACK_IMPORTED_MODULE_17__/* .hasChanged */ .$H)(v, oldValue[i])) : (0,_vue_shared__WEBPACK_IMPORTED_MODULE_17__/* .hasChanged */ .$H)(newValue, oldValue))) {
|
|
if (cleanup) {
|
|
cleanup();
|
|
}
|
|
const currentWatcher = activeWatcher;
|
|
activeWatcher = effect;
|
|
try {
|
|
const args = [newValue,
|
|
// pass undefined as the old value when it's changed for the first time
|
|
oldValue === INITIAL_WATCHER_VALUE ? void 0 : isMultiSource && oldValue[0] === INITIAL_WATCHER_VALUE ? [] : oldValue, boundCleanup];
|
|
call ? call(cb, 3, args) :
|
|
// @ts-expect-error
|
|
cb(...args);
|
|
oldValue = newValue;
|
|
} finally {
|
|
activeWatcher = currentWatcher;
|
|
}
|
|
}
|
|
} else {
|
|
effect.run();
|
|
}
|
|
};
|
|
if (augmentJob) {
|
|
augmentJob(job);
|
|
}
|
|
effect = new ReactiveEffect(getter);
|
|
effect.scheduler = scheduler ? () => scheduler(job, false) : job;
|
|
boundCleanup = fn => onWatcherCleanup(fn, false, effect);
|
|
cleanup = effect.onStop = () => {
|
|
const cleanups = cleanupMap.get(effect);
|
|
if (cleanups) {
|
|
if (call) {
|
|
call(cleanups, 4);
|
|
} else {
|
|
for (const cleanup2 of cleanups) cleanup2();
|
|
}
|
|
cleanupMap.delete(effect);
|
|
}
|
|
};
|
|
if (false) {}
|
|
if (cb) {
|
|
if (immediate) {
|
|
job(true);
|
|
} else {
|
|
oldValue = effect.run();
|
|
}
|
|
} else if (scheduler) {
|
|
scheduler(job.bind(null, true), true);
|
|
} else {
|
|
effect.run();
|
|
}
|
|
watchHandle.pause = effect.pause.bind(effect);
|
|
watchHandle.resume = effect.resume.bind(effect);
|
|
watchHandle.stop = watchHandle;
|
|
return watchHandle;
|
|
}
|
|
function traverse(value, depth = Infinity, seen) {
|
|
if (depth <= 0 || !(0,_vue_shared__WEBPACK_IMPORTED_MODULE_17__/* .isObject */ .Gv)(value) || value["__v_skip"]) {
|
|
return value;
|
|
}
|
|
seen = seen || /* @__PURE__ */new Set();
|
|
if (seen.has(value)) {
|
|
return value;
|
|
}
|
|
seen.add(value);
|
|
depth--;
|
|
if (isRef(value)) {
|
|
traverse(value.value, depth, seen);
|
|
} else if ((0,_vue_shared__WEBPACK_IMPORTED_MODULE_17__/* .isArray */ .cy)(value)) {
|
|
for (let i = 0; i < value.length; i++) {
|
|
traverse(value[i], depth, seen);
|
|
}
|
|
} else if ((0,_vue_shared__WEBPACK_IMPORTED_MODULE_17__/* .isSet */ .vM)(value) || (0,_vue_shared__WEBPACK_IMPORTED_MODULE_17__/* .isMap */ .CE)(value)) {
|
|
value.forEach(v => {
|
|
traverse(v, depth, seen);
|
|
});
|
|
} else if ((0,_vue_shared__WEBPACK_IMPORTED_MODULE_17__/* .isPlainObject */ .Qd)(value)) {
|
|
for (const key in value) {
|
|
traverse(value[key], depth, seen);
|
|
}
|
|
for (const key of Object.getOwnPropertySymbols(value)) {
|
|
if (Object.prototype.propertyIsEnumerable.call(value, key)) {
|
|
traverse(value[key], depth, seen);
|
|
}
|
|
}
|
|
}
|
|
return value;
|
|
}
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 7994:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var uncurryThis = __webpack_require__(1371);
|
|
|
|
var $Error = Error;
|
|
var replace = uncurryThis(''.replace);
|
|
|
|
var TEST = (function (arg) { return String(new $Error(arg).stack); })('zxcasd');
|
|
// eslint-disable-next-line redos/no-vulnerable -- safe
|
|
var V8_OR_CHAKRA_STACK_ENTRY = /\n\s*at [^:]*:[^\n]*/;
|
|
var IS_V8_OR_CHAKRA_STACK = V8_OR_CHAKRA_STACK_ENTRY.test(TEST);
|
|
|
|
module.exports = function (stack, dropEntries) {
|
|
if (IS_V8_OR_CHAKRA_STACK && typeof stack == 'string' && !$Error.prepareStackTrace) {
|
|
while (dropEntries--) stack = replace(stack, V8_OR_CHAKRA_STACK_ENTRY, '');
|
|
} return stack;
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 8004:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var call = __webpack_require__(4978);
|
|
var isObject = __webpack_require__(1909);
|
|
var isSymbol = __webpack_require__(3058);
|
|
var getMethod = __webpack_require__(4863);
|
|
var ordinaryToPrimitive = __webpack_require__(9821);
|
|
var wellKnownSymbol = __webpack_require__(9760);
|
|
|
|
var $TypeError = TypeError;
|
|
var TO_PRIMITIVE = wellKnownSymbol('toPrimitive');
|
|
|
|
// `ToPrimitive` abstract operation
|
|
// https://tc39.es/ecma262/#sec-toprimitive
|
|
module.exports = function (input, pref) {
|
|
if (!isObject(input) || isSymbol(input)) return input;
|
|
var exoticToPrim = getMethod(input, TO_PRIMITIVE);
|
|
var result;
|
|
if (exoticToPrim) {
|
|
if (pref === undefined) pref = 'default';
|
|
result = call(exoticToPrim, input, pref);
|
|
if (!isObject(result) || isSymbol(result)) return result;
|
|
throw new $TypeError("Can't convert object to primitive value");
|
|
}
|
|
if (pref === undefined) pref = 'number';
|
|
return ordinaryToPrimitive(input, pref);
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 8027:
|
|
/***/ (function(module) {
|
|
|
|
"use strict";
|
|
|
|
module.exports = typeof navigator != 'undefined' && String(navigator.userAgent) || '';
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 8028:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var global = __webpack_require__(4074);
|
|
|
|
// eslint-disable-next-line es/no-object-defineproperty -- safe
|
|
var defineProperty = Object.defineProperty;
|
|
|
|
module.exports = function (key, value) {
|
|
try {
|
|
defineProperty(global, key, { value: value, configurable: true, writable: true });
|
|
} catch (error) {
|
|
global[key] = value;
|
|
} return value;
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 8056:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var global = __webpack_require__(4074);
|
|
var uncurryThis = __webpack_require__(1371);
|
|
var uncurryThisAccessor = __webpack_require__(2471);
|
|
var toIndex = __webpack_require__(3425);
|
|
var isDetached = __webpack_require__(4259);
|
|
var arrayBufferByteLength = __webpack_require__(8299);
|
|
var detachTransferable = __webpack_require__(2800);
|
|
var PROPER_STRUCTURED_CLONE_TRANSFER = __webpack_require__(3117);
|
|
|
|
var structuredClone = global.structuredClone;
|
|
var ArrayBuffer = global.ArrayBuffer;
|
|
var DataView = global.DataView;
|
|
var TypeError = global.TypeError;
|
|
var min = Math.min;
|
|
var ArrayBufferPrototype = ArrayBuffer.prototype;
|
|
var DataViewPrototype = DataView.prototype;
|
|
var slice = uncurryThis(ArrayBufferPrototype.slice);
|
|
var isResizable = uncurryThisAccessor(ArrayBufferPrototype, 'resizable', 'get');
|
|
var maxByteLength = uncurryThisAccessor(ArrayBufferPrototype, 'maxByteLength', 'get');
|
|
var getInt8 = uncurryThis(DataViewPrototype.getInt8);
|
|
var setInt8 = uncurryThis(DataViewPrototype.setInt8);
|
|
|
|
module.exports = (PROPER_STRUCTURED_CLONE_TRANSFER || detachTransferable) && function (arrayBuffer, newLength, preserveResizability) {
|
|
var byteLength = arrayBufferByteLength(arrayBuffer);
|
|
var newByteLength = newLength === undefined ? byteLength : toIndex(newLength);
|
|
var fixedLength = !isResizable || !isResizable(arrayBuffer);
|
|
var newBuffer;
|
|
if (isDetached(arrayBuffer)) throw new TypeError('ArrayBuffer is detached');
|
|
if (PROPER_STRUCTURED_CLONE_TRANSFER) {
|
|
arrayBuffer = structuredClone(arrayBuffer, { transfer: [arrayBuffer] });
|
|
if (byteLength === newByteLength && (preserveResizability || fixedLength)) return arrayBuffer;
|
|
}
|
|
if (byteLength >= newByteLength && (!preserveResizability || fixedLength)) {
|
|
newBuffer = slice(arrayBuffer, 0, newByteLength);
|
|
} else {
|
|
var options = preserveResizability && !fixedLength && maxByteLength ? { maxByteLength: maxByteLength(arrayBuffer) } : undefined;
|
|
newBuffer = new ArrayBuffer(newByteLength, options);
|
|
var a = new DataView(arrayBuffer);
|
|
var b = new DataView(newBuffer);
|
|
var copyLength = min(newByteLength, byteLength);
|
|
for (var i = 0; i < copyLength; i++) setInt8(b, i, getInt8(a, i));
|
|
}
|
|
if (!PROPER_STRUCTURED_CLONE_TRANSFER) detachTransferable(arrayBuffer);
|
|
return newBuffer;
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 8069:
|
|
/***/ (function(__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) {
|
|
|
|
"use strict";
|
|
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
/* harmony export */ A: function() { return /* binding */ dispatchRequest; }
|
|
/* harmony export */ });
|
|
/* harmony import */ var _transformData_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(6162);
|
|
/* harmony import */ var _cancel_isCancel_js__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(8701);
|
|
/* harmony import */ var _defaults_index_js__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(7719);
|
|
/* harmony import */ var _cancel_CanceledError_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(7080);
|
|
/* harmony import */ var _core_AxiosHeaders_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(292);
|
|
/* harmony import */ var _adapters_adapters_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(6905);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
/**
|
|
* Throws a `CanceledError` if cancellation has been requested.
|
|
*
|
|
* @param {Object} config The config that is to be used for the request
|
|
*
|
|
* @returns {void}
|
|
*/
|
|
function throwIfCancellationRequested(config) {
|
|
if (config.cancelToken) {
|
|
config.cancelToken.throwIfRequested();
|
|
}
|
|
if (config.signal && config.signal.aborted) {
|
|
throw new _cancel_CanceledError_js__WEBPACK_IMPORTED_MODULE_0__/* ["default"] */ .A(null, config);
|
|
}
|
|
}
|
|
|
|
/**
|
|
* Dispatch a request to the server using the configured adapter.
|
|
*
|
|
* @param {object} config The config that is to be used for the request
|
|
*
|
|
* @returns {Promise} The Promise to be fulfilled
|
|
*/
|
|
function dispatchRequest(config) {
|
|
throwIfCancellationRequested(config);
|
|
config.headers = _core_AxiosHeaders_js__WEBPACK_IMPORTED_MODULE_1__/* ["default"] */ .A.from(config.headers);
|
|
|
|
// Transform request data
|
|
config.data = _transformData_js__WEBPACK_IMPORTED_MODULE_2__/* ["default"] */ .A.call(config, config.transformRequest);
|
|
if (['post', 'put', 'patch'].indexOf(config.method) !== -1) {
|
|
config.headers.setContentType('application/x-www-form-urlencoded', false);
|
|
}
|
|
const adapter = _adapters_adapters_js__WEBPACK_IMPORTED_MODULE_3__/* ["default"] */ .A.getAdapter(config.adapter || _defaults_index_js__WEBPACK_IMPORTED_MODULE_4__/* ["default"] */ .A.adapter);
|
|
return adapter(config).then(function onAdapterResolution(response) {
|
|
throwIfCancellationRequested(config);
|
|
|
|
// Transform response data
|
|
response.data = _transformData_js__WEBPACK_IMPORTED_MODULE_2__/* ["default"] */ .A.call(config, config.transformResponse, response);
|
|
response.headers = _core_AxiosHeaders_js__WEBPACK_IMPORTED_MODULE_1__/* ["default"] */ .A.from(response.headers);
|
|
return response;
|
|
}, function onAdapterRejection(reason) {
|
|
if (!(0,_cancel_isCancel_js__WEBPACK_IMPORTED_MODULE_5__/* ["default"] */ .A)(reason)) {
|
|
throwIfCancellationRequested(config);
|
|
|
|
// Transform response data
|
|
if (reason && reason.response) {
|
|
reason.response.data = _transformData_js__WEBPACK_IMPORTED_MODULE_2__/* ["default"] */ .A.call(config, config.transformResponse, reason.response);
|
|
reason.response.headers = _core_AxiosHeaders_js__WEBPACK_IMPORTED_MODULE_1__/* ["default"] */ .A.from(reason.response.headers);
|
|
}
|
|
}
|
|
return Promise.reject(reason);
|
|
});
|
|
}
|
|
|
|
/***/ }),
|
|
|
|
/***/ 8072:
|
|
/***/ (function(module) {
|
|
|
|
"use strict";
|
|
|
|
module.exports = false;
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 8155:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var global = __webpack_require__(4074);
|
|
var getOwnPropertyDescriptor = (__webpack_require__(2878).f);
|
|
var createNonEnumerableProperty = __webpack_require__(5266);
|
|
var defineBuiltIn = __webpack_require__(3647);
|
|
var defineGlobalProperty = __webpack_require__(8028);
|
|
var copyConstructorProperties = __webpack_require__(9539);
|
|
var isForced = __webpack_require__(4815);
|
|
|
|
/*
|
|
options.target - name of the target object
|
|
options.global - target is the global object
|
|
options.stat - export as static methods of target
|
|
options.proto - export as prototype methods of target
|
|
options.real - real prototype method for the `pure` version
|
|
options.forced - export even if the native feature is available
|
|
options.bind - bind methods to the target, required for the `pure` version
|
|
options.wrap - wrap constructors to preventing global pollution, required for the `pure` version
|
|
options.unsafe - use the simple assignment of property instead of delete + defineProperty
|
|
options.sham - add a flag to not completely full polyfills
|
|
options.enumerable - export as enumerable property
|
|
options.dontCallGetSet - prevent calling a getter on target
|
|
options.name - the .name of the function if it does not match the key
|
|
*/
|
|
module.exports = function (options, source) {
|
|
var TARGET = options.target;
|
|
var GLOBAL = options.global;
|
|
var STATIC = options.stat;
|
|
var FORCED, target, key, targetProperty, sourceProperty, descriptor;
|
|
if (GLOBAL) {
|
|
target = global;
|
|
} else if (STATIC) {
|
|
target = global[TARGET] || defineGlobalProperty(TARGET, {});
|
|
} else {
|
|
target = global[TARGET] && global[TARGET].prototype;
|
|
}
|
|
if (target) for (key in source) {
|
|
sourceProperty = source[key];
|
|
if (options.dontCallGetSet) {
|
|
descriptor = getOwnPropertyDescriptor(target, key);
|
|
targetProperty = descriptor && descriptor.value;
|
|
} else targetProperty = target[key];
|
|
FORCED = isForced(GLOBAL ? key : TARGET + (STATIC ? '.' : '#') + key, options.forced);
|
|
// contained in target
|
|
if (!FORCED && targetProperty !== undefined) {
|
|
if (typeof sourceProperty == typeof targetProperty) continue;
|
|
copyConstructorProperties(sourceProperty, targetProperty);
|
|
}
|
|
// add a flag to not completely full polyfills
|
|
if (options.sham || (targetProperty && targetProperty.sham)) {
|
|
createNonEnumerableProperty(sourceProperty, 'sham', true);
|
|
}
|
|
defineBuiltIn(target, key, sourceProperty, options);
|
|
}
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 8184:
|
|
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) {
|
|
|
|
"use strict";
|
|
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
/* harmony export */ Cx: function() { return /* binding */ isProxyAvailable; },
|
|
/* harmony export */ EW: function() { return /* binding */ getTarget; },
|
|
/* harmony export */ HH: function() { return /* binding */ getDevtoolsGlobalHook; }
|
|
/* harmony export */ });
|
|
function getDevtoolsGlobalHook() {
|
|
return getTarget().__VUE_DEVTOOLS_GLOBAL_HOOK__;
|
|
}
|
|
function getTarget() {
|
|
// @ts-expect-error navigator and windows are not available in all environments
|
|
return typeof navigator !== 'undefined' && typeof window !== 'undefined' ? window : typeof globalThis !== 'undefined' ? globalThis : {};
|
|
}
|
|
const isProxyAvailable = typeof Proxy === 'function';
|
|
|
|
/***/ }),
|
|
|
|
/***/ 8271:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var global = __webpack_require__(4074);
|
|
var isCallable = __webpack_require__(6450);
|
|
|
|
var WeakMap = global.WeakMap;
|
|
|
|
module.exports = isCallable(WeakMap) && /native code/.test(String(WeakMap));
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 8273:
|
|
/***/ (function(__unused_webpack___webpack_module__, __webpack_exports__) {
|
|
|
|
"use strict";
|
|
// eslint-disable-next-line strict
|
|
/* harmony default export */ __webpack_exports__.A = (null);
|
|
|
|
/***/ }),
|
|
|
|
/***/ 8299:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var uncurryThisAccessor = __webpack_require__(2471);
|
|
var classof = __webpack_require__(1079);
|
|
|
|
var $TypeError = TypeError;
|
|
|
|
// Includes
|
|
// - Perform ? RequireInternalSlot(O, [[ArrayBufferData]]).
|
|
// - If IsSharedArrayBuffer(O) is true, throw a TypeError exception.
|
|
module.exports = uncurryThisAccessor(ArrayBuffer.prototype, 'byteLength', 'get') || function (O) {
|
|
if (classof(O) !== 'ArrayBuffer') throw new $TypeError('ArrayBuffer expected');
|
|
return O.byteLength;
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 8394:
|
|
/***/ (function(__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) {
|
|
|
|
"use strict";
|
|
/* harmony import */ var _node_index_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(2873);
|
|
/* harmony import */ var _common_utils_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(7103);
|
|
|
|
|
|
/* harmony default export */ __webpack_exports__.A = ({
|
|
..._common_utils_js__WEBPACK_IMPORTED_MODULE_0__,
|
|
..._node_index_js__WEBPACK_IMPORTED_MODULE_1__/* ["default"] */ .A
|
|
});
|
|
|
|
/***/ }),
|
|
|
|
/***/ 8414:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var anObject = __webpack_require__(6696);
|
|
|
|
// `RegExp.prototype.flags` getter implementation
|
|
// https://tc39.es/ecma262/#sec-get-regexp.prototype.flags
|
|
module.exports = function () {
|
|
var that = anObject(this);
|
|
var result = '';
|
|
if (that.hasIndices) result += 'd';
|
|
if (that.global) result += 'g';
|
|
if (that.ignoreCase) result += 'i';
|
|
if (that.multiline) result += 'm';
|
|
if (that.dotAll) result += 's';
|
|
if (that.unicode) result += 'u';
|
|
if (that.unicodeSets) result += 'v';
|
|
if (that.sticky) result += 'y';
|
|
return result;
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 8438:
|
|
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var $ = __webpack_require__(8155);
|
|
var difference = __webpack_require__(4505);
|
|
var setMethodAcceptSetLike = __webpack_require__(5645);
|
|
|
|
// `Set.prototype.difference` method
|
|
// https://github.com/tc39/proposal-set-methods
|
|
$({ target: 'Set', proto: true, real: true, forced: !setMethodAcceptSetLike('difference') }, {
|
|
difference: difference
|
|
});
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 8537:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var fails = __webpack_require__(4212);
|
|
|
|
module.exports = !fails(function () {
|
|
// eslint-disable-next-line es/no-function-prototype-bind -- safe
|
|
var test = (function () { /* empty */ }).bind();
|
|
// eslint-disable-next-line no-prototype-builtins -- safe
|
|
return typeof test != 'function' || test.hasOwnProperty('prototype');
|
|
});
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 8564:
|
|
/***/ (function(__unused_webpack_module, exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var DESCRIPTORS = __webpack_require__(4911);
|
|
var IE8_DOM_DEFINE = __webpack_require__(7144);
|
|
var V8_PROTOTYPE_DEFINE_BUG = __webpack_require__(429);
|
|
var anObject = __webpack_require__(6696);
|
|
var toPropertyKey = __webpack_require__(1422);
|
|
|
|
var $TypeError = TypeError;
|
|
// eslint-disable-next-line es/no-object-defineproperty -- safe
|
|
var $defineProperty = Object.defineProperty;
|
|
// eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe
|
|
var $getOwnPropertyDescriptor = Object.getOwnPropertyDescriptor;
|
|
var ENUMERABLE = 'enumerable';
|
|
var CONFIGURABLE = 'configurable';
|
|
var WRITABLE = 'writable';
|
|
|
|
// `Object.defineProperty` method
|
|
// https://tc39.es/ecma262/#sec-object.defineproperty
|
|
exports.f = DESCRIPTORS ? V8_PROTOTYPE_DEFINE_BUG ? function defineProperty(O, P, Attributes) {
|
|
anObject(O);
|
|
P = toPropertyKey(P);
|
|
anObject(Attributes);
|
|
if (typeof O === 'function' && P === 'prototype' && 'value' in Attributes && WRITABLE in Attributes && !Attributes[WRITABLE]) {
|
|
var current = $getOwnPropertyDescriptor(O, P);
|
|
if (current && current[WRITABLE]) {
|
|
O[P] = Attributes.value;
|
|
Attributes = {
|
|
configurable: CONFIGURABLE in Attributes ? Attributes[CONFIGURABLE] : current[CONFIGURABLE],
|
|
enumerable: ENUMERABLE in Attributes ? Attributes[ENUMERABLE] : current[ENUMERABLE],
|
|
writable: false
|
|
};
|
|
}
|
|
} return $defineProperty(O, P, Attributes);
|
|
} : $defineProperty : function defineProperty(O, P, Attributes) {
|
|
anObject(O);
|
|
P = toPropertyKey(P);
|
|
anObject(Attributes);
|
|
if (IE8_DOM_DEFINE) try {
|
|
return $defineProperty(O, P, Attributes);
|
|
} catch (error) { /* empty */ }
|
|
if ('get' in Attributes || 'set' in Attributes) throw new $TypeError('Accessors not supported');
|
|
if ('value' in Attributes) O[P] = Attributes.value;
|
|
return O;
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 8618:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var uncurryThis = __webpack_require__(1371);
|
|
var fails = __webpack_require__(4212);
|
|
var classof = __webpack_require__(1079);
|
|
|
|
var $Object = Object;
|
|
var split = uncurryThis(''.split);
|
|
|
|
// fallback for non-array-like ES3 and non-enumerable old V8 strings
|
|
module.exports = fails(function () {
|
|
// throws an error in rhino, see https://github.com/mozilla/rhino/issues/346
|
|
// eslint-disable-next-line no-prototype-builtins -- safe
|
|
return !$Object('z').propertyIsEnumerable(0);
|
|
}) ? function (it) {
|
|
return classof(it) === 'String' ? split(it, '') : $Object(it);
|
|
} : $Object;
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 8631:
|
|
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var $ = __webpack_require__(8155);
|
|
var arrayToReversed = __webpack_require__(3495);
|
|
var toIndexedObject = __webpack_require__(5830);
|
|
var addToUnscopables = __webpack_require__(3876);
|
|
|
|
var $Array = Array;
|
|
|
|
// `Array.prototype.toReversed` method
|
|
// https://tc39.es/ecma262/#sec-array.prototype.toreversed
|
|
$({ target: 'Array', proto: true }, {
|
|
toReversed: function toReversed() {
|
|
return arrayToReversed(toIndexedObject(this), $Array);
|
|
}
|
|
});
|
|
|
|
addToUnscopables('toReversed');
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 8636:
|
|
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var DESCRIPTORS = __webpack_require__(4911);
|
|
var uncurryThis = __webpack_require__(1371);
|
|
var defineBuiltInAccessor = __webpack_require__(2123);
|
|
|
|
var URLSearchParamsPrototype = URLSearchParams.prototype;
|
|
var forEach = uncurryThis(URLSearchParamsPrototype.forEach);
|
|
|
|
// `URLSearchParams.prototype.size` getter
|
|
// https://github.com/whatwg/url/pull/734
|
|
if (DESCRIPTORS && !('size' in URLSearchParamsPrototype)) {
|
|
defineBuiltInAccessor(URLSearchParamsPrototype, 'size', {
|
|
get: function size() {
|
|
var count = 0;
|
|
forEach(this, function () { count++; });
|
|
return count;
|
|
},
|
|
configurable: true,
|
|
enumerable: true
|
|
});
|
|
}
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 8701:
|
|
/***/ (function(__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) {
|
|
|
|
"use strict";
|
|
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
/* harmony export */ A: function() { return /* binding */ isCancel; }
|
|
/* harmony export */ });
|
|
|
|
|
|
function isCancel(value) {
|
|
return !!(value && value.__CANCEL__);
|
|
}
|
|
|
|
/***/ }),
|
|
|
|
/***/ 8764:
|
|
/***/ (function(module) {
|
|
|
|
"use strict";
|
|
|
|
// `GetIteratorDirect(obj)` abstract operation
|
|
// https://tc39.es/proposal-iterator-helpers/#sec-getiteratordirect
|
|
module.exports = function (obj) {
|
|
return {
|
|
iterator: obj,
|
|
next: obj.next,
|
|
done: false
|
|
};
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 8937:
|
|
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var defineBuiltIn = __webpack_require__(3647);
|
|
var uncurryThis = __webpack_require__(1371);
|
|
var toString = __webpack_require__(9864);
|
|
var validateArgumentsLength = __webpack_require__(2331);
|
|
|
|
var $URLSearchParams = URLSearchParams;
|
|
var URLSearchParamsPrototype = $URLSearchParams.prototype;
|
|
var getAll = uncurryThis(URLSearchParamsPrototype.getAll);
|
|
var $has = uncurryThis(URLSearchParamsPrototype.has);
|
|
var params = new $URLSearchParams('a=1');
|
|
|
|
// `undefined` case is a Chromium 117 bug
|
|
// https://bugs.chromium.org/p/v8/issues/detail?id=14222
|
|
if (params.has('a', 2) || !params.has('a', undefined)) {
|
|
defineBuiltIn(URLSearchParamsPrototype, 'has', function has(name /* , value */) {
|
|
var length = arguments.length;
|
|
var $value = length < 2 ? undefined : arguments[1];
|
|
if (length && $value === undefined) return $has(this, name);
|
|
var values = getAll(this, name); // also validates `this`
|
|
validateArgumentsLength(length, 1);
|
|
var value = toString($value);
|
|
var index = 0;
|
|
while (index < values.length) {
|
|
if (values[index++] === value) return true;
|
|
} return false;
|
|
}, { enumerable: true, unsafe: true });
|
|
}
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 8951:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var isCallable = __webpack_require__(6450);
|
|
var tryToString = __webpack_require__(9240);
|
|
|
|
var $TypeError = TypeError;
|
|
|
|
// `Assert: IsCallable(argument) is true`
|
|
module.exports = function (argument) {
|
|
if (isCallable(argument)) return argument;
|
|
throw new $TypeError(tryToString(argument) + ' is not a function');
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 9008:
|
|
/***/ (function(__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) {
|
|
|
|
"use strict";
|
|
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
/* harmony export */ A: function() { return /* binding */ buildFullPath; }
|
|
/* harmony export */ });
|
|
/* harmony import */ var _helpers_isAbsoluteURL_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(1320);
|
|
/* harmony import */ var _helpers_combineURLs_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(1477);
|
|
|
|
|
|
|
|
|
|
|
|
/**
|
|
* Creates a new URL by combining the baseURL with the requestedURL,
|
|
* only when the requestedURL is not already an absolute URL.
|
|
* If the requestURL is absolute, this function returns the requestedURL untouched.
|
|
*
|
|
* @param {string} baseURL The base URL
|
|
* @param {string} requestedURL Absolute or relative URL to combine
|
|
*
|
|
* @returns {string} The combined full path
|
|
*/
|
|
function buildFullPath(baseURL, requestedURL) {
|
|
if (baseURL && !(0,_helpers_isAbsoluteURL_js__WEBPACK_IMPORTED_MODULE_0__/* ["default"] */ .A)(requestedURL)) {
|
|
return (0,_helpers_combineURLs_js__WEBPACK_IMPORTED_MODULE_1__/* ["default"] */ .A)(baseURL, requestedURL);
|
|
}
|
|
return requestedURL;
|
|
}
|
|
|
|
/***/ }),
|
|
|
|
/***/ 9106:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var trunc = __webpack_require__(7056);
|
|
|
|
// `ToIntegerOrInfinity` abstract operation
|
|
// https://tc39.es/ecma262/#sec-tointegerorinfinity
|
|
module.exports = function (argument) {
|
|
var number = +argument;
|
|
// eslint-disable-next-line no-self-compare -- NaN check
|
|
return number !== number || number === 0 ? 0 : trunc(number);
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 9130:
|
|
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var defineBuiltIn = __webpack_require__(3647);
|
|
var uncurryThis = __webpack_require__(1371);
|
|
var toString = __webpack_require__(9864);
|
|
var validateArgumentsLength = __webpack_require__(2331);
|
|
|
|
var $URLSearchParams = URLSearchParams;
|
|
var URLSearchParamsPrototype = $URLSearchParams.prototype;
|
|
var append = uncurryThis(URLSearchParamsPrototype.append);
|
|
var $delete = uncurryThis(URLSearchParamsPrototype['delete']);
|
|
var forEach = uncurryThis(URLSearchParamsPrototype.forEach);
|
|
var push = uncurryThis([].push);
|
|
var params = new $URLSearchParams('a=1&a=2&b=3');
|
|
|
|
params['delete']('a', 1);
|
|
// `undefined` case is a Chromium 117 bug
|
|
// https://bugs.chromium.org/p/v8/issues/detail?id=14222
|
|
params['delete']('b', undefined);
|
|
|
|
if (params + '' !== 'a=2') {
|
|
defineBuiltIn(URLSearchParamsPrototype, 'delete', function (name /* , value */) {
|
|
var length = arguments.length;
|
|
var $value = length < 2 ? undefined : arguments[1];
|
|
if (length && $value === undefined) return $delete(this, name);
|
|
var entries = [];
|
|
forEach(this, function (v, k) { // also validates `this`
|
|
push(entries, { key: k, value: v });
|
|
});
|
|
validateArgumentsLength(length, 1);
|
|
var key = toString(name);
|
|
var value = toString($value);
|
|
var index = 0;
|
|
var dindex = 0;
|
|
var found = false;
|
|
var entriesLength = entries.length;
|
|
var entry;
|
|
while (index < entriesLength) {
|
|
entry = entries[index++];
|
|
if (found || entry.key === key) {
|
|
found = true;
|
|
$delete(this, entry.key);
|
|
} else dindex++;
|
|
}
|
|
while (dindex < entriesLength) {
|
|
entry = entries[dindex++];
|
|
if (!(entry.key === key && entry.value === value)) append(this, entry.key, entry.value);
|
|
}
|
|
}, { enumerable: true, unsafe: true });
|
|
}
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 9170:
|
|
/***/ (function(__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) {
|
|
|
|
"use strict";
|
|
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
/* harmony export */ A: function() { return /* binding */ toURLEncodedForm; }
|
|
/* harmony export */ });
|
|
/* harmony import */ var _utils_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(5813);
|
|
/* harmony import */ var _toFormData_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(6631);
|
|
/* harmony import */ var _platform_index_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(8394);
|
|
|
|
|
|
|
|
|
|
|
|
function toURLEncodedForm(data, options) {
|
|
return (0,_toFormData_js__WEBPACK_IMPORTED_MODULE_0__/* ["default"] */ .A)(data, new _platform_index_js__WEBPACK_IMPORTED_MODULE_1__/* ["default"] */ .A.classes.URLSearchParams(), Object.assign({
|
|
visitor: function (value, key, path, helpers) {
|
|
if (_platform_index_js__WEBPACK_IMPORTED_MODULE_1__/* ["default"] */ .A.isNode && _utils_js__WEBPACK_IMPORTED_MODULE_2__/* ["default"] */ .A.isBuffer(value)) {
|
|
this.append(key, value.toString('base64'));
|
|
return false;
|
|
}
|
|
return helpers.defaultVisitor.apply(this, arguments);
|
|
}
|
|
}, options));
|
|
}
|
|
|
|
/***/ }),
|
|
|
|
/***/ 9205:
|
|
/***/ (function(__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) {
|
|
|
|
"use strict";
|
|
/* harmony import */ var core_js_modules_web_url_search_params_delete_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(9130);
|
|
/* harmony import */ var core_js_modules_web_url_search_params_has_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(8937);
|
|
/* harmony import */ var core_js_modules_web_url_search_params_size_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(8636);
|
|
/* harmony import */ var _helpers_AxiosURLSearchParams_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(5806);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
/* harmony default export */ __webpack_exports__.A = (typeof URLSearchParams !== 'undefined' ? URLSearchParams : _helpers_AxiosURLSearchParams_js__WEBPACK_IMPORTED_MODULE_3__/* ["default"] */ .A);
|
|
|
|
/***/ }),
|
|
|
|
/***/ 9214:
|
|
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var $ = __webpack_require__(8155);
|
|
var union = __webpack_require__(2239);
|
|
var setMethodAcceptSetLike = __webpack_require__(5645);
|
|
|
|
// `Set.prototype.union` method
|
|
// https://github.com/tc39/proposal-set-methods
|
|
$({ target: 'Set', proto: true, real: true, forced: !setMethodAcceptSetLike('union') }, {
|
|
union: union
|
|
});
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 9219:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var isPossiblePrototype = __webpack_require__(2346);
|
|
|
|
var $String = String;
|
|
var $TypeError = TypeError;
|
|
|
|
module.exports = function (argument) {
|
|
if (isPossiblePrototype(argument)) return argument;
|
|
throw new $TypeError("Can't set " + $String(argument) + ' as a prototype');
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 9240:
|
|
/***/ (function(module) {
|
|
|
|
"use strict";
|
|
|
|
var $String = String;
|
|
|
|
module.exports = function (argument) {
|
|
try {
|
|
return $String(argument);
|
|
} catch (error) {
|
|
return 'Object';
|
|
}
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 9253:
|
|
/***/ (function(__unused_webpack_module, exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
var __webpack_unused_export__;
|
|
/*!
|
|
* The buffer module from node.js, for the browser.
|
|
*
|
|
* @author Feross Aboukhadijeh <https://feross.org>
|
|
* @license MIT
|
|
*/
|
|
/* eslint-disable no-proto */
|
|
|
|
|
|
|
|
__webpack_require__(5513);
|
|
__webpack_require__(2952);
|
|
__webpack_require__(6665);
|
|
__webpack_require__(1961);
|
|
__webpack_require__(978);
|
|
__webpack_require__(6949);
|
|
__webpack_require__(1842);
|
|
const base64 = __webpack_require__(7500);
|
|
const ieee754 = __webpack_require__(2137);
|
|
const customInspectSymbol = typeof Symbol === 'function' && typeof Symbol['for'] === 'function' // eslint-disable-line dot-notation
|
|
? Symbol['for']('nodejs.util.inspect.custom') // eslint-disable-line dot-notation
|
|
: null;
|
|
exports.hp = Buffer;
|
|
__webpack_unused_export__ = SlowBuffer;
|
|
exports.IS = 50;
|
|
const K_MAX_LENGTH = 0x7fffffff;
|
|
__webpack_unused_export__ = K_MAX_LENGTH;
|
|
|
|
/**
|
|
* If `Buffer.TYPED_ARRAY_SUPPORT`:
|
|
* === true Use Uint8Array implementation (fastest)
|
|
* === false Print warning and recommend using `buffer` v4.x which has an Object
|
|
* implementation (most compatible, even IE6)
|
|
*
|
|
* Browsers that support typed arrays are IE 10+, Firefox 4+, Chrome 7+, Safari 5.1+,
|
|
* Opera 11.6+, iOS 4.2+.
|
|
*
|
|
* We report that the browser does not support typed arrays if the are not subclassable
|
|
* using __proto__. Firefox 4-29 lacks support for adding new properties to `Uint8Array`
|
|
* (See: https://bugzilla.mozilla.org/show_bug.cgi?id=695438). IE 10 lacks support
|
|
* for __proto__ and has a buggy typed array implementation.
|
|
*/
|
|
Buffer.TYPED_ARRAY_SUPPORT = typedArraySupport();
|
|
if (!Buffer.TYPED_ARRAY_SUPPORT && typeof console !== 'undefined' && typeof console.error === 'function') {
|
|
console.error('This browser lacks typed array (Uint8Array) support which is required by ' + '`buffer` v5.x. Use `buffer` v4.x if you require old browser support.');
|
|
}
|
|
function typedArraySupport() {
|
|
// Can typed array instances can be augmented?
|
|
try {
|
|
const arr = new Uint8Array(1);
|
|
const proto = {
|
|
foo: function () {
|
|
return 42;
|
|
}
|
|
};
|
|
Object.setPrototypeOf(proto, Uint8Array.prototype);
|
|
Object.setPrototypeOf(arr, proto);
|
|
return arr.foo() === 42;
|
|
} catch (e) {
|
|
return false;
|
|
}
|
|
}
|
|
Object.defineProperty(Buffer.prototype, 'parent', {
|
|
enumerable: true,
|
|
get: function () {
|
|
if (!Buffer.isBuffer(this)) return undefined;
|
|
return this.buffer;
|
|
}
|
|
});
|
|
Object.defineProperty(Buffer.prototype, 'offset', {
|
|
enumerable: true,
|
|
get: function () {
|
|
if (!Buffer.isBuffer(this)) return undefined;
|
|
return this.byteOffset;
|
|
}
|
|
});
|
|
function createBuffer(length) {
|
|
if (length > K_MAX_LENGTH) {
|
|
throw new RangeError('The value "' + length + '" is invalid for option "size"');
|
|
}
|
|
// Return an augmented `Uint8Array` instance
|
|
const buf = new Uint8Array(length);
|
|
Object.setPrototypeOf(buf, Buffer.prototype);
|
|
return buf;
|
|
}
|
|
|
|
/**
|
|
* The Buffer constructor returns instances of `Uint8Array` that have their
|
|
* prototype changed to `Buffer.prototype`. Furthermore, `Buffer` is a subclass of
|
|
* `Uint8Array`, so the returned instances will have all the node `Buffer` methods
|
|
* and the `Uint8Array` methods. Square bracket notation works as expected -- it
|
|
* returns a single octet.
|
|
*
|
|
* The `Uint8Array` prototype remains unmodified.
|
|
*/
|
|
|
|
function Buffer(arg, encodingOrOffset, length) {
|
|
// Common case.
|
|
if (typeof arg === 'number') {
|
|
if (typeof encodingOrOffset === 'string') {
|
|
throw new TypeError('The "string" argument must be of type string. Received type number');
|
|
}
|
|
return allocUnsafe(arg);
|
|
}
|
|
return from(arg, encodingOrOffset, length);
|
|
}
|
|
Buffer.poolSize = 8192; // not used by this implementation
|
|
|
|
function from(value, encodingOrOffset, length) {
|
|
if (typeof value === 'string') {
|
|
return fromString(value, encodingOrOffset);
|
|
}
|
|
if (ArrayBuffer.isView(value)) {
|
|
return fromArrayView(value);
|
|
}
|
|
if (value == null) {
|
|
throw new TypeError('The first argument must be one of type string, Buffer, ArrayBuffer, Array, ' + 'or Array-like Object. Received type ' + typeof value);
|
|
}
|
|
if (isInstance(value, ArrayBuffer) || value && isInstance(value.buffer, ArrayBuffer)) {
|
|
return fromArrayBuffer(value, encodingOrOffset, length);
|
|
}
|
|
if (typeof SharedArrayBuffer !== 'undefined' && (isInstance(value, SharedArrayBuffer) || value && isInstance(value.buffer, SharedArrayBuffer))) {
|
|
return fromArrayBuffer(value, encodingOrOffset, length);
|
|
}
|
|
if (typeof value === 'number') {
|
|
throw new TypeError('The "value" argument must not be of type number. Received type number');
|
|
}
|
|
const valueOf = value.valueOf && value.valueOf();
|
|
if (valueOf != null && valueOf !== value) {
|
|
return Buffer.from(valueOf, encodingOrOffset, length);
|
|
}
|
|
const b = fromObject(value);
|
|
if (b) return b;
|
|
if (typeof Symbol !== 'undefined' && Symbol.toPrimitive != null && typeof value[Symbol.toPrimitive] === 'function') {
|
|
return Buffer.from(value[Symbol.toPrimitive]('string'), encodingOrOffset, length);
|
|
}
|
|
throw new TypeError('The first argument must be one of type string, Buffer, ArrayBuffer, Array, ' + 'or Array-like Object. Received type ' + typeof value);
|
|
}
|
|
|
|
/**
|
|
* Functionally equivalent to Buffer(arg, encoding) but throws a TypeError
|
|
* if value is a number.
|
|
* Buffer.from(str[, encoding])
|
|
* Buffer.from(array)
|
|
* Buffer.from(buffer)
|
|
* Buffer.from(arrayBuffer[, byteOffset[, length]])
|
|
**/
|
|
Buffer.from = function (value, encodingOrOffset, length) {
|
|
return from(value, encodingOrOffset, length);
|
|
};
|
|
|
|
// Note: Change prototype *after* Buffer.from is defined to workaround Chrome bug:
|
|
// https://github.com/feross/buffer/pull/148
|
|
Object.setPrototypeOf(Buffer.prototype, Uint8Array.prototype);
|
|
Object.setPrototypeOf(Buffer, Uint8Array);
|
|
function assertSize(size) {
|
|
if (typeof size !== 'number') {
|
|
throw new TypeError('"size" argument must be of type number');
|
|
} else if (size < 0) {
|
|
throw new RangeError('The value "' + size + '" is invalid for option "size"');
|
|
}
|
|
}
|
|
function alloc(size, fill, encoding) {
|
|
assertSize(size);
|
|
if (size <= 0) {
|
|
return createBuffer(size);
|
|
}
|
|
if (fill !== undefined) {
|
|
// Only pay attention to encoding if it's a string. This
|
|
// prevents accidentally sending in a number that would
|
|
// be interpreted as a start offset.
|
|
return typeof encoding === 'string' ? createBuffer(size).fill(fill, encoding) : createBuffer(size).fill(fill);
|
|
}
|
|
return createBuffer(size);
|
|
}
|
|
|
|
/**
|
|
* Creates a new filled Buffer instance.
|
|
* alloc(size[, fill[, encoding]])
|
|
**/
|
|
Buffer.alloc = function (size, fill, encoding) {
|
|
return alloc(size, fill, encoding);
|
|
};
|
|
function allocUnsafe(size) {
|
|
assertSize(size);
|
|
return createBuffer(size < 0 ? 0 : checked(size) | 0);
|
|
}
|
|
|
|
/**
|
|
* Equivalent to Buffer(num), by default creates a non-zero-filled Buffer instance.
|
|
* */
|
|
Buffer.allocUnsafe = function (size) {
|
|
return allocUnsafe(size);
|
|
};
|
|
/**
|
|
* Equivalent to SlowBuffer(num), by default creates a non-zero-filled Buffer instance.
|
|
*/
|
|
Buffer.allocUnsafeSlow = function (size) {
|
|
return allocUnsafe(size);
|
|
};
|
|
function fromString(string, encoding) {
|
|
if (typeof encoding !== 'string' || encoding === '') {
|
|
encoding = 'utf8';
|
|
}
|
|
if (!Buffer.isEncoding(encoding)) {
|
|
throw new TypeError('Unknown encoding: ' + encoding);
|
|
}
|
|
const length = byteLength(string, encoding) | 0;
|
|
let buf = createBuffer(length);
|
|
const actual = buf.write(string, encoding);
|
|
if (actual !== length) {
|
|
// Writing a hex string, for example, that contains invalid characters will
|
|
// cause everything after the first invalid character to be ignored. (e.g.
|
|
// 'abxxcd' will be treated as 'ab')
|
|
buf = buf.slice(0, actual);
|
|
}
|
|
return buf;
|
|
}
|
|
function fromArrayLike(array) {
|
|
const length = array.length < 0 ? 0 : checked(array.length) | 0;
|
|
const buf = createBuffer(length);
|
|
for (let i = 0; i < length; i += 1) {
|
|
buf[i] = array[i] & 255;
|
|
}
|
|
return buf;
|
|
}
|
|
function fromArrayView(arrayView) {
|
|
if (isInstance(arrayView, Uint8Array)) {
|
|
const copy = new Uint8Array(arrayView);
|
|
return fromArrayBuffer(copy.buffer, copy.byteOffset, copy.byteLength);
|
|
}
|
|
return fromArrayLike(arrayView);
|
|
}
|
|
function fromArrayBuffer(array, byteOffset, length) {
|
|
if (byteOffset < 0 || array.byteLength < byteOffset) {
|
|
throw new RangeError('"offset" is outside of buffer bounds');
|
|
}
|
|
if (array.byteLength < byteOffset + (length || 0)) {
|
|
throw new RangeError('"length" is outside of buffer bounds');
|
|
}
|
|
let buf;
|
|
if (byteOffset === undefined && length === undefined) {
|
|
buf = new Uint8Array(array);
|
|
} else if (length === undefined) {
|
|
buf = new Uint8Array(array, byteOffset);
|
|
} else {
|
|
buf = new Uint8Array(array, byteOffset, length);
|
|
}
|
|
|
|
// Return an augmented `Uint8Array` instance
|
|
Object.setPrototypeOf(buf, Buffer.prototype);
|
|
return buf;
|
|
}
|
|
function fromObject(obj) {
|
|
if (Buffer.isBuffer(obj)) {
|
|
const len = checked(obj.length) | 0;
|
|
const buf = createBuffer(len);
|
|
if (buf.length === 0) {
|
|
return buf;
|
|
}
|
|
obj.copy(buf, 0, 0, len);
|
|
return buf;
|
|
}
|
|
if (obj.length !== undefined) {
|
|
if (typeof obj.length !== 'number' || numberIsNaN(obj.length)) {
|
|
return createBuffer(0);
|
|
}
|
|
return fromArrayLike(obj);
|
|
}
|
|
if (obj.type === 'Buffer' && Array.isArray(obj.data)) {
|
|
return fromArrayLike(obj.data);
|
|
}
|
|
}
|
|
function checked(length) {
|
|
// Note: cannot use `length < K_MAX_LENGTH` here because that fails when
|
|
// length is NaN (which is otherwise coerced to zero.)
|
|
if (length >= K_MAX_LENGTH) {
|
|
throw new RangeError('Attempt to allocate Buffer larger than maximum ' + 'size: 0x' + K_MAX_LENGTH.toString(16) + ' bytes');
|
|
}
|
|
return length | 0;
|
|
}
|
|
function SlowBuffer(length) {
|
|
if (+length != length) {
|
|
// eslint-disable-line eqeqeq
|
|
length = 0;
|
|
}
|
|
return Buffer.alloc(+length);
|
|
}
|
|
Buffer.isBuffer = function isBuffer(b) {
|
|
return b != null && b._isBuffer === true && b !== Buffer.prototype; // so Buffer.isBuffer(Buffer.prototype) will be false
|
|
};
|
|
Buffer.compare = function compare(a, b) {
|
|
if (isInstance(a, Uint8Array)) a = Buffer.from(a, a.offset, a.byteLength);
|
|
if (isInstance(b, Uint8Array)) b = Buffer.from(b, b.offset, b.byteLength);
|
|
if (!Buffer.isBuffer(a) || !Buffer.isBuffer(b)) {
|
|
throw new TypeError('The "buf1", "buf2" arguments must be one of type Buffer or Uint8Array');
|
|
}
|
|
if (a === b) return 0;
|
|
let x = a.length;
|
|
let y = b.length;
|
|
for (let i = 0, len = Math.min(x, y); i < len; ++i) {
|
|
if (a[i] !== b[i]) {
|
|
x = a[i];
|
|
y = b[i];
|
|
break;
|
|
}
|
|
}
|
|
if (x < y) return -1;
|
|
if (y < x) return 1;
|
|
return 0;
|
|
};
|
|
Buffer.isEncoding = function isEncoding(encoding) {
|
|
switch (String(encoding).toLowerCase()) {
|
|
case 'hex':
|
|
case 'utf8':
|
|
case 'utf-8':
|
|
case 'ascii':
|
|
case 'latin1':
|
|
case 'binary':
|
|
case 'base64':
|
|
case 'ucs2':
|
|
case 'ucs-2':
|
|
case 'utf16le':
|
|
case 'utf-16le':
|
|
return true;
|
|
default:
|
|
return false;
|
|
}
|
|
};
|
|
Buffer.concat = function concat(list, length) {
|
|
if (!Array.isArray(list)) {
|
|
throw new TypeError('"list" argument must be an Array of Buffers');
|
|
}
|
|
if (list.length === 0) {
|
|
return Buffer.alloc(0);
|
|
}
|
|
let i;
|
|
if (length === undefined) {
|
|
length = 0;
|
|
for (i = 0; i < list.length; ++i) {
|
|
length += list[i].length;
|
|
}
|
|
}
|
|
const buffer = Buffer.allocUnsafe(length);
|
|
let pos = 0;
|
|
for (i = 0; i < list.length; ++i) {
|
|
let buf = list[i];
|
|
if (isInstance(buf, Uint8Array)) {
|
|
if (pos + buf.length > buffer.length) {
|
|
if (!Buffer.isBuffer(buf)) buf = Buffer.from(buf);
|
|
buf.copy(buffer, pos);
|
|
} else {
|
|
Uint8Array.prototype.set.call(buffer, buf, pos);
|
|
}
|
|
} else if (!Buffer.isBuffer(buf)) {
|
|
throw new TypeError('"list" argument must be an Array of Buffers');
|
|
} else {
|
|
buf.copy(buffer, pos);
|
|
}
|
|
pos += buf.length;
|
|
}
|
|
return buffer;
|
|
};
|
|
function byteLength(string, encoding) {
|
|
if (Buffer.isBuffer(string)) {
|
|
return string.length;
|
|
}
|
|
if (ArrayBuffer.isView(string) || isInstance(string, ArrayBuffer)) {
|
|
return string.byteLength;
|
|
}
|
|
if (typeof string !== 'string') {
|
|
throw new TypeError('The "string" argument must be one of type string, Buffer, or ArrayBuffer. ' + 'Received type ' + typeof string);
|
|
}
|
|
const len = string.length;
|
|
const mustMatch = arguments.length > 2 && arguments[2] === true;
|
|
if (!mustMatch && len === 0) return 0;
|
|
|
|
// Use a for loop to avoid recursion
|
|
let loweredCase = false;
|
|
for (;;) {
|
|
switch (encoding) {
|
|
case 'ascii':
|
|
case 'latin1':
|
|
case 'binary':
|
|
return len;
|
|
case 'utf8':
|
|
case 'utf-8':
|
|
return utf8ToBytes(string).length;
|
|
case 'ucs2':
|
|
case 'ucs-2':
|
|
case 'utf16le':
|
|
case 'utf-16le':
|
|
return len * 2;
|
|
case 'hex':
|
|
return len >>> 1;
|
|
case 'base64':
|
|
return base64ToBytes(string).length;
|
|
default:
|
|
if (loweredCase) {
|
|
return mustMatch ? -1 : utf8ToBytes(string).length; // assume utf8
|
|
}
|
|
encoding = ('' + encoding).toLowerCase();
|
|
loweredCase = true;
|
|
}
|
|
}
|
|
}
|
|
Buffer.byteLength = byteLength;
|
|
function slowToString(encoding, start, end) {
|
|
let loweredCase = false;
|
|
|
|
// No need to verify that "this.length <= MAX_UINT32" since it's a read-only
|
|
// property of a typed array.
|
|
|
|
// This behaves neither like String nor Uint8Array in that we set start/end
|
|
// to their upper/lower bounds if the value passed is out of range.
|
|
// undefined is handled specially as per ECMA-262 6th Edition,
|
|
// Section 13.3.3.7 Runtime Semantics: KeyedBindingInitialization.
|
|
if (start === undefined || start < 0) {
|
|
start = 0;
|
|
}
|
|
// Return early if start > this.length. Done here to prevent potential uint32
|
|
// coercion fail below.
|
|
if (start > this.length) {
|
|
return '';
|
|
}
|
|
if (end === undefined || end > this.length) {
|
|
end = this.length;
|
|
}
|
|
if (end <= 0) {
|
|
return '';
|
|
}
|
|
|
|
// Force coercion to uint32. This will also coerce falsey/NaN values to 0.
|
|
end >>>= 0;
|
|
start >>>= 0;
|
|
if (end <= start) {
|
|
return '';
|
|
}
|
|
if (!encoding) encoding = 'utf8';
|
|
while (true) {
|
|
switch (encoding) {
|
|
case 'hex':
|
|
return hexSlice(this, start, end);
|
|
case 'utf8':
|
|
case 'utf-8':
|
|
return utf8Slice(this, start, end);
|
|
case 'ascii':
|
|
return asciiSlice(this, start, end);
|
|
case 'latin1':
|
|
case 'binary':
|
|
return latin1Slice(this, start, end);
|
|
case 'base64':
|
|
return base64Slice(this, start, end);
|
|
case 'ucs2':
|
|
case 'ucs-2':
|
|
case 'utf16le':
|
|
case 'utf-16le':
|
|
return utf16leSlice(this, start, end);
|
|
default:
|
|
if (loweredCase) throw new TypeError('Unknown encoding: ' + encoding);
|
|
encoding = (encoding + '').toLowerCase();
|
|
loweredCase = true;
|
|
}
|
|
}
|
|
}
|
|
|
|
// This property is used by `Buffer.isBuffer` (and the `is-buffer` npm package)
|
|
// to detect a Buffer instance. It's not possible to use `instanceof Buffer`
|
|
// reliably in a browserify context because there could be multiple different
|
|
// copies of the 'buffer' package in use. This method works even for Buffer
|
|
// instances that were created from another copy of the `buffer` package.
|
|
// See: https://github.com/feross/buffer/issues/154
|
|
Buffer.prototype._isBuffer = true;
|
|
function swap(b, n, m) {
|
|
const i = b[n];
|
|
b[n] = b[m];
|
|
b[m] = i;
|
|
}
|
|
Buffer.prototype.swap16 = function swap16() {
|
|
const len = this.length;
|
|
if (len % 2 !== 0) {
|
|
throw new RangeError('Buffer size must be a multiple of 16-bits');
|
|
}
|
|
for (let i = 0; i < len; i += 2) {
|
|
swap(this, i, i + 1);
|
|
}
|
|
return this;
|
|
};
|
|
Buffer.prototype.swap32 = function swap32() {
|
|
const len = this.length;
|
|
if (len % 4 !== 0) {
|
|
throw new RangeError('Buffer size must be a multiple of 32-bits');
|
|
}
|
|
for (let i = 0; i < len; i += 4) {
|
|
swap(this, i, i + 3);
|
|
swap(this, i + 1, i + 2);
|
|
}
|
|
return this;
|
|
};
|
|
Buffer.prototype.swap64 = function swap64() {
|
|
const len = this.length;
|
|
if (len % 8 !== 0) {
|
|
throw new RangeError('Buffer size must be a multiple of 64-bits');
|
|
}
|
|
for (let i = 0; i < len; i += 8) {
|
|
swap(this, i, i + 7);
|
|
swap(this, i + 1, i + 6);
|
|
swap(this, i + 2, i + 5);
|
|
swap(this, i + 3, i + 4);
|
|
}
|
|
return this;
|
|
};
|
|
Buffer.prototype.toString = function toString() {
|
|
const length = this.length;
|
|
if (length === 0) return '';
|
|
if (arguments.length === 0) return utf8Slice(this, 0, length);
|
|
return slowToString.apply(this, arguments);
|
|
};
|
|
Buffer.prototype.toLocaleString = Buffer.prototype.toString;
|
|
Buffer.prototype.equals = function equals(b) {
|
|
if (!Buffer.isBuffer(b)) throw new TypeError('Argument must be a Buffer');
|
|
if (this === b) return true;
|
|
return Buffer.compare(this, b) === 0;
|
|
};
|
|
Buffer.prototype.inspect = function inspect() {
|
|
let str = '';
|
|
const max = exports.IS;
|
|
str = this.toString('hex', 0, max).replace(/(.{2})/g, '$1 ').trim();
|
|
if (this.length > max) str += ' ... ';
|
|
return '<Buffer ' + str + '>';
|
|
};
|
|
if (customInspectSymbol) {
|
|
Buffer.prototype[customInspectSymbol] = Buffer.prototype.inspect;
|
|
}
|
|
Buffer.prototype.compare = function compare(target, start, end, thisStart, thisEnd) {
|
|
if (isInstance(target, Uint8Array)) {
|
|
target = Buffer.from(target, target.offset, target.byteLength);
|
|
}
|
|
if (!Buffer.isBuffer(target)) {
|
|
throw new TypeError('The "target" argument must be one of type Buffer or Uint8Array. ' + 'Received type ' + typeof target);
|
|
}
|
|
if (start === undefined) {
|
|
start = 0;
|
|
}
|
|
if (end === undefined) {
|
|
end = target ? target.length : 0;
|
|
}
|
|
if (thisStart === undefined) {
|
|
thisStart = 0;
|
|
}
|
|
if (thisEnd === undefined) {
|
|
thisEnd = this.length;
|
|
}
|
|
if (start < 0 || end > target.length || thisStart < 0 || thisEnd > this.length) {
|
|
throw new RangeError('out of range index');
|
|
}
|
|
if (thisStart >= thisEnd && start >= end) {
|
|
return 0;
|
|
}
|
|
if (thisStart >= thisEnd) {
|
|
return -1;
|
|
}
|
|
if (start >= end) {
|
|
return 1;
|
|
}
|
|
start >>>= 0;
|
|
end >>>= 0;
|
|
thisStart >>>= 0;
|
|
thisEnd >>>= 0;
|
|
if (this === target) return 0;
|
|
let x = thisEnd - thisStart;
|
|
let y = end - start;
|
|
const len = Math.min(x, y);
|
|
const thisCopy = this.slice(thisStart, thisEnd);
|
|
const targetCopy = target.slice(start, end);
|
|
for (let i = 0; i < len; ++i) {
|
|
if (thisCopy[i] !== targetCopy[i]) {
|
|
x = thisCopy[i];
|
|
y = targetCopy[i];
|
|
break;
|
|
}
|
|
}
|
|
if (x < y) return -1;
|
|
if (y < x) return 1;
|
|
return 0;
|
|
};
|
|
|
|
// Finds either the first index of `val` in `buffer` at offset >= `byteOffset`,
|
|
// OR the last index of `val` in `buffer` at offset <= `byteOffset`.
|
|
//
|
|
// Arguments:
|
|
// - buffer - a Buffer to search
|
|
// - val - a string, Buffer, or number
|
|
// - byteOffset - an index into `buffer`; will be clamped to an int32
|
|
// - encoding - an optional encoding, relevant is val is a string
|
|
// - dir - true for indexOf, false for lastIndexOf
|
|
function bidirectionalIndexOf(buffer, val, byteOffset, encoding, dir) {
|
|
// Empty buffer means no match
|
|
if (buffer.length === 0) return -1;
|
|
|
|
// Normalize byteOffset
|
|
if (typeof byteOffset === 'string') {
|
|
encoding = byteOffset;
|
|
byteOffset = 0;
|
|
} else if (byteOffset > 0x7fffffff) {
|
|
byteOffset = 0x7fffffff;
|
|
} else if (byteOffset < -0x80000000) {
|
|
byteOffset = -0x80000000;
|
|
}
|
|
byteOffset = +byteOffset; // Coerce to Number.
|
|
if (numberIsNaN(byteOffset)) {
|
|
// byteOffset: it it's undefined, null, NaN, "foo", etc, search whole buffer
|
|
byteOffset = dir ? 0 : buffer.length - 1;
|
|
}
|
|
|
|
// Normalize byteOffset: negative offsets start from the end of the buffer
|
|
if (byteOffset < 0) byteOffset = buffer.length + byteOffset;
|
|
if (byteOffset >= buffer.length) {
|
|
if (dir) return -1;else byteOffset = buffer.length - 1;
|
|
} else if (byteOffset < 0) {
|
|
if (dir) byteOffset = 0;else return -1;
|
|
}
|
|
|
|
// Normalize val
|
|
if (typeof val === 'string') {
|
|
val = Buffer.from(val, encoding);
|
|
}
|
|
|
|
// Finally, search either indexOf (if dir is true) or lastIndexOf
|
|
if (Buffer.isBuffer(val)) {
|
|
// Special case: looking for empty string/buffer always fails
|
|
if (val.length === 0) {
|
|
return -1;
|
|
}
|
|
return arrayIndexOf(buffer, val, byteOffset, encoding, dir);
|
|
} else if (typeof val === 'number') {
|
|
val = val & 0xFF; // Search for a byte value [0-255]
|
|
if (typeof Uint8Array.prototype.indexOf === 'function') {
|
|
if (dir) {
|
|
return Uint8Array.prototype.indexOf.call(buffer, val, byteOffset);
|
|
} else {
|
|
return Uint8Array.prototype.lastIndexOf.call(buffer, val, byteOffset);
|
|
}
|
|
}
|
|
return arrayIndexOf(buffer, [val], byteOffset, encoding, dir);
|
|
}
|
|
throw new TypeError('val must be string, number or Buffer');
|
|
}
|
|
function arrayIndexOf(arr, val, byteOffset, encoding, dir) {
|
|
let indexSize = 1;
|
|
let arrLength = arr.length;
|
|
let valLength = val.length;
|
|
if (encoding !== undefined) {
|
|
encoding = String(encoding).toLowerCase();
|
|
if (encoding === 'ucs2' || encoding === 'ucs-2' || encoding === 'utf16le' || encoding === 'utf-16le') {
|
|
if (arr.length < 2 || val.length < 2) {
|
|
return -1;
|
|
}
|
|
indexSize = 2;
|
|
arrLength /= 2;
|
|
valLength /= 2;
|
|
byteOffset /= 2;
|
|
}
|
|
}
|
|
function read(buf, i) {
|
|
if (indexSize === 1) {
|
|
return buf[i];
|
|
} else {
|
|
return buf.readUInt16BE(i * indexSize);
|
|
}
|
|
}
|
|
let i;
|
|
if (dir) {
|
|
let foundIndex = -1;
|
|
for (i = byteOffset; i < arrLength; i++) {
|
|
if (read(arr, i) === read(val, foundIndex === -1 ? 0 : i - foundIndex)) {
|
|
if (foundIndex === -1) foundIndex = i;
|
|
if (i - foundIndex + 1 === valLength) return foundIndex * indexSize;
|
|
} else {
|
|
if (foundIndex !== -1) i -= i - foundIndex;
|
|
foundIndex = -1;
|
|
}
|
|
}
|
|
} else {
|
|
if (byteOffset + valLength > arrLength) byteOffset = arrLength - valLength;
|
|
for (i = byteOffset; i >= 0; i--) {
|
|
let found = true;
|
|
for (let j = 0; j < valLength; j++) {
|
|
if (read(arr, i + j) !== read(val, j)) {
|
|
found = false;
|
|
break;
|
|
}
|
|
}
|
|
if (found) return i;
|
|
}
|
|
}
|
|
return -1;
|
|
}
|
|
Buffer.prototype.includes = function includes(val, byteOffset, encoding) {
|
|
return this.indexOf(val, byteOffset, encoding) !== -1;
|
|
};
|
|
Buffer.prototype.indexOf = function indexOf(val, byteOffset, encoding) {
|
|
return bidirectionalIndexOf(this, val, byteOffset, encoding, true);
|
|
};
|
|
Buffer.prototype.lastIndexOf = function lastIndexOf(val, byteOffset, encoding) {
|
|
return bidirectionalIndexOf(this, val, byteOffset, encoding, false);
|
|
};
|
|
function hexWrite(buf, string, offset, length) {
|
|
offset = Number(offset) || 0;
|
|
const remaining = buf.length - offset;
|
|
if (!length) {
|
|
length = remaining;
|
|
} else {
|
|
length = Number(length);
|
|
if (length > remaining) {
|
|
length = remaining;
|
|
}
|
|
}
|
|
const strLen = string.length;
|
|
if (length > strLen / 2) {
|
|
length = strLen / 2;
|
|
}
|
|
let i;
|
|
for (i = 0; i < length; ++i) {
|
|
const parsed = parseInt(string.substr(i * 2, 2), 16);
|
|
if (numberIsNaN(parsed)) return i;
|
|
buf[offset + i] = parsed;
|
|
}
|
|
return i;
|
|
}
|
|
function utf8Write(buf, string, offset, length) {
|
|
return blitBuffer(utf8ToBytes(string, buf.length - offset), buf, offset, length);
|
|
}
|
|
function asciiWrite(buf, string, offset, length) {
|
|
return blitBuffer(asciiToBytes(string), buf, offset, length);
|
|
}
|
|
function base64Write(buf, string, offset, length) {
|
|
return blitBuffer(base64ToBytes(string), buf, offset, length);
|
|
}
|
|
function ucs2Write(buf, string, offset, length) {
|
|
return blitBuffer(utf16leToBytes(string, buf.length - offset), buf, offset, length);
|
|
}
|
|
Buffer.prototype.write = function write(string, offset, length, encoding) {
|
|
// Buffer#write(string)
|
|
if (offset === undefined) {
|
|
encoding = 'utf8';
|
|
length = this.length;
|
|
offset = 0;
|
|
// Buffer#write(string, encoding)
|
|
} else if (length === undefined && typeof offset === 'string') {
|
|
encoding = offset;
|
|
length = this.length;
|
|
offset = 0;
|
|
// Buffer#write(string, offset[, length][, encoding])
|
|
} else if (isFinite(offset)) {
|
|
offset = offset >>> 0;
|
|
if (isFinite(length)) {
|
|
length = length >>> 0;
|
|
if (encoding === undefined) encoding = 'utf8';
|
|
} else {
|
|
encoding = length;
|
|
length = undefined;
|
|
}
|
|
} else {
|
|
throw new Error('Buffer.write(string, encoding, offset[, length]) is no longer supported');
|
|
}
|
|
const remaining = this.length - offset;
|
|
if (length === undefined || length > remaining) length = remaining;
|
|
if (string.length > 0 && (length < 0 || offset < 0) || offset > this.length) {
|
|
throw new RangeError('Attempt to write outside buffer bounds');
|
|
}
|
|
if (!encoding) encoding = 'utf8';
|
|
let loweredCase = false;
|
|
for (;;) {
|
|
switch (encoding) {
|
|
case 'hex':
|
|
return hexWrite(this, string, offset, length);
|
|
case 'utf8':
|
|
case 'utf-8':
|
|
return utf8Write(this, string, offset, length);
|
|
case 'ascii':
|
|
case 'latin1':
|
|
case 'binary':
|
|
return asciiWrite(this, string, offset, length);
|
|
case 'base64':
|
|
// Warning: maxLength not taken into account in base64Write
|
|
return base64Write(this, string, offset, length);
|
|
case 'ucs2':
|
|
case 'ucs-2':
|
|
case 'utf16le':
|
|
case 'utf-16le':
|
|
return ucs2Write(this, string, offset, length);
|
|
default:
|
|
if (loweredCase) throw new TypeError('Unknown encoding: ' + encoding);
|
|
encoding = ('' + encoding).toLowerCase();
|
|
loweredCase = true;
|
|
}
|
|
}
|
|
};
|
|
Buffer.prototype.toJSON = function toJSON() {
|
|
return {
|
|
type: 'Buffer',
|
|
data: Array.prototype.slice.call(this._arr || this, 0)
|
|
};
|
|
};
|
|
function base64Slice(buf, start, end) {
|
|
if (start === 0 && end === buf.length) {
|
|
return base64.fromByteArray(buf);
|
|
} else {
|
|
return base64.fromByteArray(buf.slice(start, end));
|
|
}
|
|
}
|
|
function utf8Slice(buf, start, end) {
|
|
end = Math.min(buf.length, end);
|
|
const res = [];
|
|
let i = start;
|
|
while (i < end) {
|
|
const firstByte = buf[i];
|
|
let codePoint = null;
|
|
let bytesPerSequence = firstByte > 0xEF ? 4 : firstByte > 0xDF ? 3 : firstByte > 0xBF ? 2 : 1;
|
|
if (i + bytesPerSequence <= end) {
|
|
let secondByte, thirdByte, fourthByte, tempCodePoint;
|
|
switch (bytesPerSequence) {
|
|
case 1:
|
|
if (firstByte < 0x80) {
|
|
codePoint = firstByte;
|
|
}
|
|
break;
|
|
case 2:
|
|
secondByte = buf[i + 1];
|
|
if ((secondByte & 0xC0) === 0x80) {
|
|
tempCodePoint = (firstByte & 0x1F) << 0x6 | secondByte & 0x3F;
|
|
if (tempCodePoint > 0x7F) {
|
|
codePoint = tempCodePoint;
|
|
}
|
|
}
|
|
break;
|
|
case 3:
|
|
secondByte = buf[i + 1];
|
|
thirdByte = buf[i + 2];
|
|
if ((secondByte & 0xC0) === 0x80 && (thirdByte & 0xC0) === 0x80) {
|
|
tempCodePoint = (firstByte & 0xF) << 0xC | (secondByte & 0x3F) << 0x6 | thirdByte & 0x3F;
|
|
if (tempCodePoint > 0x7FF && (tempCodePoint < 0xD800 || tempCodePoint > 0xDFFF)) {
|
|
codePoint = tempCodePoint;
|
|
}
|
|
}
|
|
break;
|
|
case 4:
|
|
secondByte = buf[i + 1];
|
|
thirdByte = buf[i + 2];
|
|
fourthByte = buf[i + 3];
|
|
if ((secondByte & 0xC0) === 0x80 && (thirdByte & 0xC0) === 0x80 && (fourthByte & 0xC0) === 0x80) {
|
|
tempCodePoint = (firstByte & 0xF) << 0x12 | (secondByte & 0x3F) << 0xC | (thirdByte & 0x3F) << 0x6 | fourthByte & 0x3F;
|
|
if (tempCodePoint > 0xFFFF && tempCodePoint < 0x110000) {
|
|
codePoint = tempCodePoint;
|
|
}
|
|
}
|
|
}
|
|
}
|
|
if (codePoint === null) {
|
|
// we did not generate a valid codePoint so insert a
|
|
// replacement char (U+FFFD) and advance only 1 byte
|
|
codePoint = 0xFFFD;
|
|
bytesPerSequence = 1;
|
|
} else if (codePoint > 0xFFFF) {
|
|
// encode to utf16 (surrogate pair dance)
|
|
codePoint -= 0x10000;
|
|
res.push(codePoint >>> 10 & 0x3FF | 0xD800);
|
|
codePoint = 0xDC00 | codePoint & 0x3FF;
|
|
}
|
|
res.push(codePoint);
|
|
i += bytesPerSequence;
|
|
}
|
|
return decodeCodePointsArray(res);
|
|
}
|
|
|
|
// Based on http://stackoverflow.com/a/22747272/680742, the browser with
|
|
// the lowest limit is Chrome, with 0x10000 args.
|
|
// We go 1 magnitude less, for safety
|
|
const MAX_ARGUMENTS_LENGTH = 0x1000;
|
|
function decodeCodePointsArray(codePoints) {
|
|
const len = codePoints.length;
|
|
if (len <= MAX_ARGUMENTS_LENGTH) {
|
|
return String.fromCharCode.apply(String, codePoints); // avoid extra slice()
|
|
}
|
|
|
|
// Decode in chunks to avoid "call stack size exceeded".
|
|
let res = '';
|
|
let i = 0;
|
|
while (i < len) {
|
|
res += String.fromCharCode.apply(String, codePoints.slice(i, i += MAX_ARGUMENTS_LENGTH));
|
|
}
|
|
return res;
|
|
}
|
|
function asciiSlice(buf, start, end) {
|
|
let ret = '';
|
|
end = Math.min(buf.length, end);
|
|
for (let i = start; i < end; ++i) {
|
|
ret += String.fromCharCode(buf[i] & 0x7F);
|
|
}
|
|
return ret;
|
|
}
|
|
function latin1Slice(buf, start, end) {
|
|
let ret = '';
|
|
end = Math.min(buf.length, end);
|
|
for (let i = start; i < end; ++i) {
|
|
ret += String.fromCharCode(buf[i]);
|
|
}
|
|
return ret;
|
|
}
|
|
function hexSlice(buf, start, end) {
|
|
const len = buf.length;
|
|
if (!start || start < 0) start = 0;
|
|
if (!end || end < 0 || end > len) end = len;
|
|
let out = '';
|
|
for (let i = start; i < end; ++i) {
|
|
out += hexSliceLookupTable[buf[i]];
|
|
}
|
|
return out;
|
|
}
|
|
function utf16leSlice(buf, start, end) {
|
|
const bytes = buf.slice(start, end);
|
|
let res = '';
|
|
// If bytes.length is odd, the last 8 bits must be ignored (same as node.js)
|
|
for (let i = 0; i < bytes.length - 1; i += 2) {
|
|
res += String.fromCharCode(bytes[i] + bytes[i + 1] * 256);
|
|
}
|
|
return res;
|
|
}
|
|
Buffer.prototype.slice = function slice(start, end) {
|
|
const len = this.length;
|
|
start = ~~start;
|
|
end = end === undefined ? len : ~~end;
|
|
if (start < 0) {
|
|
start += len;
|
|
if (start < 0) start = 0;
|
|
} else if (start > len) {
|
|
start = len;
|
|
}
|
|
if (end < 0) {
|
|
end += len;
|
|
if (end < 0) end = 0;
|
|
} else if (end > len) {
|
|
end = len;
|
|
}
|
|
if (end < start) end = start;
|
|
const newBuf = this.subarray(start, end);
|
|
// Return an augmented `Uint8Array` instance
|
|
Object.setPrototypeOf(newBuf, Buffer.prototype);
|
|
return newBuf;
|
|
};
|
|
|
|
/*
|
|
* Need to make sure that buffer isn't trying to write out of bounds.
|
|
*/
|
|
function checkOffset(offset, ext, length) {
|
|
if (offset % 1 !== 0 || offset < 0) throw new RangeError('offset is not uint');
|
|
if (offset + ext > length) throw new RangeError('Trying to access beyond buffer length');
|
|
}
|
|
Buffer.prototype.readUintLE = Buffer.prototype.readUIntLE = function readUIntLE(offset, byteLength, noAssert) {
|
|
offset = offset >>> 0;
|
|
byteLength = byteLength >>> 0;
|
|
if (!noAssert) checkOffset(offset, byteLength, this.length);
|
|
let val = this[offset];
|
|
let mul = 1;
|
|
let i = 0;
|
|
while (++i < byteLength && (mul *= 0x100)) {
|
|
val += this[offset + i] * mul;
|
|
}
|
|
return val;
|
|
};
|
|
Buffer.prototype.readUintBE = Buffer.prototype.readUIntBE = function readUIntBE(offset, byteLength, noAssert) {
|
|
offset = offset >>> 0;
|
|
byteLength = byteLength >>> 0;
|
|
if (!noAssert) {
|
|
checkOffset(offset, byteLength, this.length);
|
|
}
|
|
let val = this[offset + --byteLength];
|
|
let mul = 1;
|
|
while (byteLength > 0 && (mul *= 0x100)) {
|
|
val += this[offset + --byteLength] * mul;
|
|
}
|
|
return val;
|
|
};
|
|
Buffer.prototype.readUint8 = Buffer.prototype.readUInt8 = function readUInt8(offset, noAssert) {
|
|
offset = offset >>> 0;
|
|
if (!noAssert) checkOffset(offset, 1, this.length);
|
|
return this[offset];
|
|
};
|
|
Buffer.prototype.readUint16LE = Buffer.prototype.readUInt16LE = function readUInt16LE(offset, noAssert) {
|
|
offset = offset >>> 0;
|
|
if (!noAssert) checkOffset(offset, 2, this.length);
|
|
return this[offset] | this[offset + 1] << 8;
|
|
};
|
|
Buffer.prototype.readUint16BE = Buffer.prototype.readUInt16BE = function readUInt16BE(offset, noAssert) {
|
|
offset = offset >>> 0;
|
|
if (!noAssert) checkOffset(offset, 2, this.length);
|
|
return this[offset] << 8 | this[offset + 1];
|
|
};
|
|
Buffer.prototype.readUint32LE = Buffer.prototype.readUInt32LE = function readUInt32LE(offset, noAssert) {
|
|
offset = offset >>> 0;
|
|
if (!noAssert) checkOffset(offset, 4, this.length);
|
|
return (this[offset] | this[offset + 1] << 8 | this[offset + 2] << 16) + this[offset + 3] * 0x1000000;
|
|
};
|
|
Buffer.prototype.readUint32BE = Buffer.prototype.readUInt32BE = function readUInt32BE(offset, noAssert) {
|
|
offset = offset >>> 0;
|
|
if (!noAssert) checkOffset(offset, 4, this.length);
|
|
return this[offset] * 0x1000000 + (this[offset + 1] << 16 | this[offset + 2] << 8 | this[offset + 3]);
|
|
};
|
|
Buffer.prototype.readBigUInt64LE = defineBigIntMethod(function readBigUInt64LE(offset) {
|
|
offset = offset >>> 0;
|
|
validateNumber(offset, 'offset');
|
|
const first = this[offset];
|
|
const last = this[offset + 7];
|
|
if (first === undefined || last === undefined) {
|
|
boundsError(offset, this.length - 8);
|
|
}
|
|
const lo = first + this[++offset] * 2 ** 8 + this[++offset] * 2 ** 16 + this[++offset] * 2 ** 24;
|
|
const hi = this[++offset] + this[++offset] * 2 ** 8 + this[++offset] * 2 ** 16 + last * 2 ** 24;
|
|
return BigInt(lo) + (BigInt(hi) << BigInt(32));
|
|
});
|
|
Buffer.prototype.readBigUInt64BE = defineBigIntMethod(function readBigUInt64BE(offset) {
|
|
offset = offset >>> 0;
|
|
validateNumber(offset, 'offset');
|
|
const first = this[offset];
|
|
const last = this[offset + 7];
|
|
if (first === undefined || last === undefined) {
|
|
boundsError(offset, this.length - 8);
|
|
}
|
|
const hi = first * 2 ** 24 + this[++offset] * 2 ** 16 + this[++offset] * 2 ** 8 + this[++offset];
|
|
const lo = this[++offset] * 2 ** 24 + this[++offset] * 2 ** 16 + this[++offset] * 2 ** 8 + last;
|
|
return (BigInt(hi) << BigInt(32)) + BigInt(lo);
|
|
});
|
|
Buffer.prototype.readIntLE = function readIntLE(offset, byteLength, noAssert) {
|
|
offset = offset >>> 0;
|
|
byteLength = byteLength >>> 0;
|
|
if (!noAssert) checkOffset(offset, byteLength, this.length);
|
|
let val = this[offset];
|
|
let mul = 1;
|
|
let i = 0;
|
|
while (++i < byteLength && (mul *= 0x100)) {
|
|
val += this[offset + i] * mul;
|
|
}
|
|
mul *= 0x80;
|
|
if (val >= mul) val -= Math.pow(2, 8 * byteLength);
|
|
return val;
|
|
};
|
|
Buffer.prototype.readIntBE = function readIntBE(offset, byteLength, noAssert) {
|
|
offset = offset >>> 0;
|
|
byteLength = byteLength >>> 0;
|
|
if (!noAssert) checkOffset(offset, byteLength, this.length);
|
|
let i = byteLength;
|
|
let mul = 1;
|
|
let val = this[offset + --i];
|
|
while (i > 0 && (mul *= 0x100)) {
|
|
val += this[offset + --i] * mul;
|
|
}
|
|
mul *= 0x80;
|
|
if (val >= mul) val -= Math.pow(2, 8 * byteLength);
|
|
return val;
|
|
};
|
|
Buffer.prototype.readInt8 = function readInt8(offset, noAssert) {
|
|
offset = offset >>> 0;
|
|
if (!noAssert) checkOffset(offset, 1, this.length);
|
|
if (!(this[offset] & 0x80)) return this[offset];
|
|
return (0xff - this[offset] + 1) * -1;
|
|
};
|
|
Buffer.prototype.readInt16LE = function readInt16LE(offset, noAssert) {
|
|
offset = offset >>> 0;
|
|
if (!noAssert) checkOffset(offset, 2, this.length);
|
|
const val = this[offset] | this[offset + 1] << 8;
|
|
return val & 0x8000 ? val | 0xFFFF0000 : val;
|
|
};
|
|
Buffer.prototype.readInt16BE = function readInt16BE(offset, noAssert) {
|
|
offset = offset >>> 0;
|
|
if (!noAssert) checkOffset(offset, 2, this.length);
|
|
const val = this[offset + 1] | this[offset] << 8;
|
|
return val & 0x8000 ? val | 0xFFFF0000 : val;
|
|
};
|
|
Buffer.prototype.readInt32LE = function readInt32LE(offset, noAssert) {
|
|
offset = offset >>> 0;
|
|
if (!noAssert) checkOffset(offset, 4, this.length);
|
|
return this[offset] | this[offset + 1] << 8 | this[offset + 2] << 16 | this[offset + 3] << 24;
|
|
};
|
|
Buffer.prototype.readInt32BE = function readInt32BE(offset, noAssert) {
|
|
offset = offset >>> 0;
|
|
if (!noAssert) checkOffset(offset, 4, this.length);
|
|
return this[offset] << 24 | this[offset + 1] << 16 | this[offset + 2] << 8 | this[offset + 3];
|
|
};
|
|
Buffer.prototype.readBigInt64LE = defineBigIntMethod(function readBigInt64LE(offset) {
|
|
offset = offset >>> 0;
|
|
validateNumber(offset, 'offset');
|
|
const first = this[offset];
|
|
const last = this[offset + 7];
|
|
if (first === undefined || last === undefined) {
|
|
boundsError(offset, this.length - 8);
|
|
}
|
|
const val = this[offset + 4] + this[offset + 5] * 2 ** 8 + this[offset + 6] * 2 ** 16 + (last << 24); // Overflow
|
|
|
|
return (BigInt(val) << BigInt(32)) + BigInt(first + this[++offset] * 2 ** 8 + this[++offset] * 2 ** 16 + this[++offset] * 2 ** 24);
|
|
});
|
|
Buffer.prototype.readBigInt64BE = defineBigIntMethod(function readBigInt64BE(offset) {
|
|
offset = offset >>> 0;
|
|
validateNumber(offset, 'offset');
|
|
const first = this[offset];
|
|
const last = this[offset + 7];
|
|
if (first === undefined || last === undefined) {
|
|
boundsError(offset, this.length - 8);
|
|
}
|
|
const val = (first << 24) +
|
|
// Overflow
|
|
this[++offset] * 2 ** 16 + this[++offset] * 2 ** 8 + this[++offset];
|
|
return (BigInt(val) << BigInt(32)) + BigInt(this[++offset] * 2 ** 24 + this[++offset] * 2 ** 16 + this[++offset] * 2 ** 8 + last);
|
|
});
|
|
Buffer.prototype.readFloatLE = function readFloatLE(offset, noAssert) {
|
|
offset = offset >>> 0;
|
|
if (!noAssert) checkOffset(offset, 4, this.length);
|
|
return ieee754.read(this, offset, true, 23, 4);
|
|
};
|
|
Buffer.prototype.readFloatBE = function readFloatBE(offset, noAssert) {
|
|
offset = offset >>> 0;
|
|
if (!noAssert) checkOffset(offset, 4, this.length);
|
|
return ieee754.read(this, offset, false, 23, 4);
|
|
};
|
|
Buffer.prototype.readDoubleLE = function readDoubleLE(offset, noAssert) {
|
|
offset = offset >>> 0;
|
|
if (!noAssert) checkOffset(offset, 8, this.length);
|
|
return ieee754.read(this, offset, true, 52, 8);
|
|
};
|
|
Buffer.prototype.readDoubleBE = function readDoubleBE(offset, noAssert) {
|
|
offset = offset >>> 0;
|
|
if (!noAssert) checkOffset(offset, 8, this.length);
|
|
return ieee754.read(this, offset, false, 52, 8);
|
|
};
|
|
function checkInt(buf, value, offset, ext, max, min) {
|
|
if (!Buffer.isBuffer(buf)) throw new TypeError('"buffer" argument must be a Buffer instance');
|
|
if (value > max || value < min) throw new RangeError('"value" argument is out of bounds');
|
|
if (offset + ext > buf.length) throw new RangeError('Index out of range');
|
|
}
|
|
Buffer.prototype.writeUintLE = Buffer.prototype.writeUIntLE = function writeUIntLE(value, offset, byteLength, noAssert) {
|
|
value = +value;
|
|
offset = offset >>> 0;
|
|
byteLength = byteLength >>> 0;
|
|
if (!noAssert) {
|
|
const maxBytes = Math.pow(2, 8 * byteLength) - 1;
|
|
checkInt(this, value, offset, byteLength, maxBytes, 0);
|
|
}
|
|
let mul = 1;
|
|
let i = 0;
|
|
this[offset] = value & 0xFF;
|
|
while (++i < byteLength && (mul *= 0x100)) {
|
|
this[offset + i] = value / mul & 0xFF;
|
|
}
|
|
return offset + byteLength;
|
|
};
|
|
Buffer.prototype.writeUintBE = Buffer.prototype.writeUIntBE = function writeUIntBE(value, offset, byteLength, noAssert) {
|
|
value = +value;
|
|
offset = offset >>> 0;
|
|
byteLength = byteLength >>> 0;
|
|
if (!noAssert) {
|
|
const maxBytes = Math.pow(2, 8 * byteLength) - 1;
|
|
checkInt(this, value, offset, byteLength, maxBytes, 0);
|
|
}
|
|
let i = byteLength - 1;
|
|
let mul = 1;
|
|
this[offset + i] = value & 0xFF;
|
|
while (--i >= 0 && (mul *= 0x100)) {
|
|
this[offset + i] = value / mul & 0xFF;
|
|
}
|
|
return offset + byteLength;
|
|
};
|
|
Buffer.prototype.writeUint8 = Buffer.prototype.writeUInt8 = function writeUInt8(value, offset, noAssert) {
|
|
value = +value;
|
|
offset = offset >>> 0;
|
|
if (!noAssert) checkInt(this, value, offset, 1, 0xff, 0);
|
|
this[offset] = value & 0xff;
|
|
return offset + 1;
|
|
};
|
|
Buffer.prototype.writeUint16LE = Buffer.prototype.writeUInt16LE = function writeUInt16LE(value, offset, noAssert) {
|
|
value = +value;
|
|
offset = offset >>> 0;
|
|
if (!noAssert) checkInt(this, value, offset, 2, 0xffff, 0);
|
|
this[offset] = value & 0xff;
|
|
this[offset + 1] = value >>> 8;
|
|
return offset + 2;
|
|
};
|
|
Buffer.prototype.writeUint16BE = Buffer.prototype.writeUInt16BE = function writeUInt16BE(value, offset, noAssert) {
|
|
value = +value;
|
|
offset = offset >>> 0;
|
|
if (!noAssert) checkInt(this, value, offset, 2, 0xffff, 0);
|
|
this[offset] = value >>> 8;
|
|
this[offset + 1] = value & 0xff;
|
|
return offset + 2;
|
|
};
|
|
Buffer.prototype.writeUint32LE = Buffer.prototype.writeUInt32LE = function writeUInt32LE(value, offset, noAssert) {
|
|
value = +value;
|
|
offset = offset >>> 0;
|
|
if (!noAssert) checkInt(this, value, offset, 4, 0xffffffff, 0);
|
|
this[offset + 3] = value >>> 24;
|
|
this[offset + 2] = value >>> 16;
|
|
this[offset + 1] = value >>> 8;
|
|
this[offset] = value & 0xff;
|
|
return offset + 4;
|
|
};
|
|
Buffer.prototype.writeUint32BE = Buffer.prototype.writeUInt32BE = function writeUInt32BE(value, offset, noAssert) {
|
|
value = +value;
|
|
offset = offset >>> 0;
|
|
if (!noAssert) checkInt(this, value, offset, 4, 0xffffffff, 0);
|
|
this[offset] = value >>> 24;
|
|
this[offset + 1] = value >>> 16;
|
|
this[offset + 2] = value >>> 8;
|
|
this[offset + 3] = value & 0xff;
|
|
return offset + 4;
|
|
};
|
|
function wrtBigUInt64LE(buf, value, offset, min, max) {
|
|
checkIntBI(value, min, max, buf, offset, 7);
|
|
let lo = Number(value & BigInt(0xffffffff));
|
|
buf[offset++] = lo;
|
|
lo = lo >> 8;
|
|
buf[offset++] = lo;
|
|
lo = lo >> 8;
|
|
buf[offset++] = lo;
|
|
lo = lo >> 8;
|
|
buf[offset++] = lo;
|
|
let hi = Number(value >> BigInt(32) & BigInt(0xffffffff));
|
|
buf[offset++] = hi;
|
|
hi = hi >> 8;
|
|
buf[offset++] = hi;
|
|
hi = hi >> 8;
|
|
buf[offset++] = hi;
|
|
hi = hi >> 8;
|
|
buf[offset++] = hi;
|
|
return offset;
|
|
}
|
|
function wrtBigUInt64BE(buf, value, offset, min, max) {
|
|
checkIntBI(value, min, max, buf, offset, 7);
|
|
let lo = Number(value & BigInt(0xffffffff));
|
|
buf[offset + 7] = lo;
|
|
lo = lo >> 8;
|
|
buf[offset + 6] = lo;
|
|
lo = lo >> 8;
|
|
buf[offset + 5] = lo;
|
|
lo = lo >> 8;
|
|
buf[offset + 4] = lo;
|
|
let hi = Number(value >> BigInt(32) & BigInt(0xffffffff));
|
|
buf[offset + 3] = hi;
|
|
hi = hi >> 8;
|
|
buf[offset + 2] = hi;
|
|
hi = hi >> 8;
|
|
buf[offset + 1] = hi;
|
|
hi = hi >> 8;
|
|
buf[offset] = hi;
|
|
return offset + 8;
|
|
}
|
|
Buffer.prototype.writeBigUInt64LE = defineBigIntMethod(function writeBigUInt64LE(value, offset = 0) {
|
|
return wrtBigUInt64LE(this, value, offset, BigInt(0), BigInt('0xffffffffffffffff'));
|
|
});
|
|
Buffer.prototype.writeBigUInt64BE = defineBigIntMethod(function writeBigUInt64BE(value, offset = 0) {
|
|
return wrtBigUInt64BE(this, value, offset, BigInt(0), BigInt('0xffffffffffffffff'));
|
|
});
|
|
Buffer.prototype.writeIntLE = function writeIntLE(value, offset, byteLength, noAssert) {
|
|
value = +value;
|
|
offset = offset >>> 0;
|
|
if (!noAssert) {
|
|
const limit = Math.pow(2, 8 * byteLength - 1);
|
|
checkInt(this, value, offset, byteLength, limit - 1, -limit);
|
|
}
|
|
let i = 0;
|
|
let mul = 1;
|
|
let sub = 0;
|
|
this[offset] = value & 0xFF;
|
|
while (++i < byteLength && (mul *= 0x100)) {
|
|
if (value < 0 && sub === 0 && this[offset + i - 1] !== 0) {
|
|
sub = 1;
|
|
}
|
|
this[offset + i] = (value / mul >> 0) - sub & 0xFF;
|
|
}
|
|
return offset + byteLength;
|
|
};
|
|
Buffer.prototype.writeIntBE = function writeIntBE(value, offset, byteLength, noAssert) {
|
|
value = +value;
|
|
offset = offset >>> 0;
|
|
if (!noAssert) {
|
|
const limit = Math.pow(2, 8 * byteLength - 1);
|
|
checkInt(this, value, offset, byteLength, limit - 1, -limit);
|
|
}
|
|
let i = byteLength - 1;
|
|
let mul = 1;
|
|
let sub = 0;
|
|
this[offset + i] = value & 0xFF;
|
|
while (--i >= 0 && (mul *= 0x100)) {
|
|
if (value < 0 && sub === 0 && this[offset + i + 1] !== 0) {
|
|
sub = 1;
|
|
}
|
|
this[offset + i] = (value / mul >> 0) - sub & 0xFF;
|
|
}
|
|
return offset + byteLength;
|
|
};
|
|
Buffer.prototype.writeInt8 = function writeInt8(value, offset, noAssert) {
|
|
value = +value;
|
|
offset = offset >>> 0;
|
|
if (!noAssert) checkInt(this, value, offset, 1, 0x7f, -0x80);
|
|
if (value < 0) value = 0xff + value + 1;
|
|
this[offset] = value & 0xff;
|
|
return offset + 1;
|
|
};
|
|
Buffer.prototype.writeInt16LE = function writeInt16LE(value, offset, noAssert) {
|
|
value = +value;
|
|
offset = offset >>> 0;
|
|
if (!noAssert) checkInt(this, value, offset, 2, 0x7fff, -0x8000);
|
|
this[offset] = value & 0xff;
|
|
this[offset + 1] = value >>> 8;
|
|
return offset + 2;
|
|
};
|
|
Buffer.prototype.writeInt16BE = function writeInt16BE(value, offset, noAssert) {
|
|
value = +value;
|
|
offset = offset >>> 0;
|
|
if (!noAssert) checkInt(this, value, offset, 2, 0x7fff, -0x8000);
|
|
this[offset] = value >>> 8;
|
|
this[offset + 1] = value & 0xff;
|
|
return offset + 2;
|
|
};
|
|
Buffer.prototype.writeInt32LE = function writeInt32LE(value, offset, noAssert) {
|
|
value = +value;
|
|
offset = offset >>> 0;
|
|
if (!noAssert) checkInt(this, value, offset, 4, 0x7fffffff, -0x80000000);
|
|
this[offset] = value & 0xff;
|
|
this[offset + 1] = value >>> 8;
|
|
this[offset + 2] = value >>> 16;
|
|
this[offset + 3] = value >>> 24;
|
|
return offset + 4;
|
|
};
|
|
Buffer.prototype.writeInt32BE = function writeInt32BE(value, offset, noAssert) {
|
|
value = +value;
|
|
offset = offset >>> 0;
|
|
if (!noAssert) checkInt(this, value, offset, 4, 0x7fffffff, -0x80000000);
|
|
if (value < 0) value = 0xffffffff + value + 1;
|
|
this[offset] = value >>> 24;
|
|
this[offset + 1] = value >>> 16;
|
|
this[offset + 2] = value >>> 8;
|
|
this[offset + 3] = value & 0xff;
|
|
return offset + 4;
|
|
};
|
|
Buffer.prototype.writeBigInt64LE = defineBigIntMethod(function writeBigInt64LE(value, offset = 0) {
|
|
return wrtBigUInt64LE(this, value, offset, -BigInt('0x8000000000000000'), BigInt('0x7fffffffffffffff'));
|
|
});
|
|
Buffer.prototype.writeBigInt64BE = defineBigIntMethod(function writeBigInt64BE(value, offset = 0) {
|
|
return wrtBigUInt64BE(this, value, offset, -BigInt('0x8000000000000000'), BigInt('0x7fffffffffffffff'));
|
|
});
|
|
function checkIEEE754(buf, value, offset, ext, max, min) {
|
|
if (offset + ext > buf.length) throw new RangeError('Index out of range');
|
|
if (offset < 0) throw new RangeError('Index out of range');
|
|
}
|
|
function writeFloat(buf, value, offset, littleEndian, noAssert) {
|
|
value = +value;
|
|
offset = offset >>> 0;
|
|
if (!noAssert) {
|
|
checkIEEE754(buf, value, offset, 4, 3.4028234663852886e+38, -3.4028234663852886e+38);
|
|
}
|
|
ieee754.write(buf, value, offset, littleEndian, 23, 4);
|
|
return offset + 4;
|
|
}
|
|
Buffer.prototype.writeFloatLE = function writeFloatLE(value, offset, noAssert) {
|
|
return writeFloat(this, value, offset, true, noAssert);
|
|
};
|
|
Buffer.prototype.writeFloatBE = function writeFloatBE(value, offset, noAssert) {
|
|
return writeFloat(this, value, offset, false, noAssert);
|
|
};
|
|
function writeDouble(buf, value, offset, littleEndian, noAssert) {
|
|
value = +value;
|
|
offset = offset >>> 0;
|
|
if (!noAssert) {
|
|
checkIEEE754(buf, value, offset, 8, 1.7976931348623157E+308, -1.7976931348623157E+308);
|
|
}
|
|
ieee754.write(buf, value, offset, littleEndian, 52, 8);
|
|
return offset + 8;
|
|
}
|
|
Buffer.prototype.writeDoubleLE = function writeDoubleLE(value, offset, noAssert) {
|
|
return writeDouble(this, value, offset, true, noAssert);
|
|
};
|
|
Buffer.prototype.writeDoubleBE = function writeDoubleBE(value, offset, noAssert) {
|
|
return writeDouble(this, value, offset, false, noAssert);
|
|
};
|
|
|
|
// copy(targetBuffer, targetStart=0, sourceStart=0, sourceEnd=buffer.length)
|
|
Buffer.prototype.copy = function copy(target, targetStart, start, end) {
|
|
if (!Buffer.isBuffer(target)) throw new TypeError('argument should be a Buffer');
|
|
if (!start) start = 0;
|
|
if (!end && end !== 0) end = this.length;
|
|
if (targetStart >= target.length) targetStart = target.length;
|
|
if (!targetStart) targetStart = 0;
|
|
if (end > 0 && end < start) end = start;
|
|
|
|
// Copy 0 bytes; we're done
|
|
if (end === start) return 0;
|
|
if (target.length === 0 || this.length === 0) return 0;
|
|
|
|
// Fatal error conditions
|
|
if (targetStart < 0) {
|
|
throw new RangeError('targetStart out of bounds');
|
|
}
|
|
if (start < 0 || start >= this.length) throw new RangeError('Index out of range');
|
|
if (end < 0) throw new RangeError('sourceEnd out of bounds');
|
|
|
|
// Are we oob?
|
|
if (end > this.length) end = this.length;
|
|
if (target.length - targetStart < end - start) {
|
|
end = target.length - targetStart + start;
|
|
}
|
|
const len = end - start;
|
|
if (this === target && typeof Uint8Array.prototype.copyWithin === 'function') {
|
|
// Use built-in when available, missing from IE11
|
|
this.copyWithin(targetStart, start, end);
|
|
} else {
|
|
Uint8Array.prototype.set.call(target, this.subarray(start, end), targetStart);
|
|
}
|
|
return len;
|
|
};
|
|
|
|
// Usage:
|
|
// buffer.fill(number[, offset[, end]])
|
|
// buffer.fill(buffer[, offset[, end]])
|
|
// buffer.fill(string[, offset[, end]][, encoding])
|
|
Buffer.prototype.fill = function fill(val, start, end, encoding) {
|
|
// Handle string cases:
|
|
if (typeof val === 'string') {
|
|
if (typeof start === 'string') {
|
|
encoding = start;
|
|
start = 0;
|
|
end = this.length;
|
|
} else if (typeof end === 'string') {
|
|
encoding = end;
|
|
end = this.length;
|
|
}
|
|
if (encoding !== undefined && typeof encoding !== 'string') {
|
|
throw new TypeError('encoding must be a string');
|
|
}
|
|
if (typeof encoding === 'string' && !Buffer.isEncoding(encoding)) {
|
|
throw new TypeError('Unknown encoding: ' + encoding);
|
|
}
|
|
if (val.length === 1) {
|
|
const code = val.charCodeAt(0);
|
|
if (encoding === 'utf8' && code < 128 || encoding === 'latin1') {
|
|
// Fast path: If `val` fits into a single byte, use that numeric value.
|
|
val = code;
|
|
}
|
|
}
|
|
} else if (typeof val === 'number') {
|
|
val = val & 255;
|
|
} else if (typeof val === 'boolean') {
|
|
val = Number(val);
|
|
}
|
|
|
|
// Invalid ranges are not set to a default, so can range check early.
|
|
if (start < 0 || this.length < start || this.length < end) {
|
|
throw new RangeError('Out of range index');
|
|
}
|
|
if (end <= start) {
|
|
return this;
|
|
}
|
|
start = start >>> 0;
|
|
end = end === undefined ? this.length : end >>> 0;
|
|
if (!val) val = 0;
|
|
let i;
|
|
if (typeof val === 'number') {
|
|
for (i = start; i < end; ++i) {
|
|
this[i] = val;
|
|
}
|
|
} else {
|
|
const bytes = Buffer.isBuffer(val) ? val : Buffer.from(val, encoding);
|
|
const len = bytes.length;
|
|
if (len === 0) {
|
|
throw new TypeError('The value "' + val + '" is invalid for argument "value"');
|
|
}
|
|
for (i = 0; i < end - start; ++i) {
|
|
this[i + start] = bytes[i % len];
|
|
}
|
|
}
|
|
return this;
|
|
};
|
|
|
|
// CUSTOM ERRORS
|
|
// =============
|
|
|
|
// Simplified versions from Node, changed for Buffer-only usage
|
|
const errors = {};
|
|
function E(sym, getMessage, Base) {
|
|
errors[sym] = class NodeError extends Base {
|
|
constructor() {
|
|
super();
|
|
Object.defineProperty(this, 'message', {
|
|
value: getMessage.apply(this, arguments),
|
|
writable: true,
|
|
configurable: true
|
|
});
|
|
|
|
// Add the error code to the name to include it in the stack trace.
|
|
this.name = `${this.name} [${sym}]`;
|
|
// Access the stack to generate the error message including the error code
|
|
// from the name.
|
|
this.stack; // eslint-disable-line no-unused-expressions
|
|
// Reset the name to the actual name.
|
|
delete this.name;
|
|
}
|
|
get code() {
|
|
return sym;
|
|
}
|
|
set code(value) {
|
|
Object.defineProperty(this, 'code', {
|
|
configurable: true,
|
|
enumerable: true,
|
|
value,
|
|
writable: true
|
|
});
|
|
}
|
|
toString() {
|
|
return `${this.name} [${sym}]: ${this.message}`;
|
|
}
|
|
};
|
|
}
|
|
E('ERR_BUFFER_OUT_OF_BOUNDS', function (name) {
|
|
if (name) {
|
|
return `${name} is outside of buffer bounds`;
|
|
}
|
|
return 'Attempt to access memory outside buffer bounds';
|
|
}, RangeError);
|
|
E('ERR_INVALID_ARG_TYPE', function (name, actual) {
|
|
return `The "${name}" argument must be of type number. Received type ${typeof actual}`;
|
|
}, TypeError);
|
|
E('ERR_OUT_OF_RANGE', function (str, range, input) {
|
|
let msg = `The value of "${str}" is out of range.`;
|
|
let received = input;
|
|
if (Number.isInteger(input) && Math.abs(input) > 2 ** 32) {
|
|
received = addNumericalSeparator(String(input));
|
|
} else if (typeof input === 'bigint') {
|
|
received = String(input);
|
|
if (input > BigInt(2) ** BigInt(32) || input < -(BigInt(2) ** BigInt(32))) {
|
|
received = addNumericalSeparator(received);
|
|
}
|
|
received += 'n';
|
|
}
|
|
msg += ` It must be ${range}. Received ${received}`;
|
|
return msg;
|
|
}, RangeError);
|
|
function addNumericalSeparator(val) {
|
|
let res = '';
|
|
let i = val.length;
|
|
const start = val[0] === '-' ? 1 : 0;
|
|
for (; i >= start + 4; i -= 3) {
|
|
res = `_${val.slice(i - 3, i)}${res}`;
|
|
}
|
|
return `${val.slice(0, i)}${res}`;
|
|
}
|
|
|
|
// CHECK FUNCTIONS
|
|
// ===============
|
|
|
|
function checkBounds(buf, offset, byteLength) {
|
|
validateNumber(offset, 'offset');
|
|
if (buf[offset] === undefined || buf[offset + byteLength] === undefined) {
|
|
boundsError(offset, buf.length - (byteLength + 1));
|
|
}
|
|
}
|
|
function checkIntBI(value, min, max, buf, offset, byteLength) {
|
|
if (value > max || value < min) {
|
|
const n = typeof min === 'bigint' ? 'n' : '';
|
|
let range;
|
|
if (byteLength > 3) {
|
|
if (min === 0 || min === BigInt(0)) {
|
|
range = `>= 0${n} and < 2${n} ** ${(byteLength + 1) * 8}${n}`;
|
|
} else {
|
|
range = `>= -(2${n} ** ${(byteLength + 1) * 8 - 1}${n}) and < 2 ** ` + `${(byteLength + 1) * 8 - 1}${n}`;
|
|
}
|
|
} else {
|
|
range = `>= ${min}${n} and <= ${max}${n}`;
|
|
}
|
|
throw new errors.ERR_OUT_OF_RANGE('value', range, value);
|
|
}
|
|
checkBounds(buf, offset, byteLength);
|
|
}
|
|
function validateNumber(value, name) {
|
|
if (typeof value !== 'number') {
|
|
throw new errors.ERR_INVALID_ARG_TYPE(name, 'number', value);
|
|
}
|
|
}
|
|
function boundsError(value, length, type) {
|
|
if (Math.floor(value) !== value) {
|
|
validateNumber(value, type);
|
|
throw new errors.ERR_OUT_OF_RANGE(type || 'offset', 'an integer', value);
|
|
}
|
|
if (length < 0) {
|
|
throw new errors.ERR_BUFFER_OUT_OF_BOUNDS();
|
|
}
|
|
throw new errors.ERR_OUT_OF_RANGE(type || 'offset', `>= ${type ? 1 : 0} and <= ${length}`, value);
|
|
}
|
|
|
|
// HELPER FUNCTIONS
|
|
// ================
|
|
|
|
const INVALID_BASE64_RE = /[^+/0-9A-Za-z-_]/g;
|
|
function base64clean(str) {
|
|
// Node takes equal signs as end of the Base64 encoding
|
|
str = str.split('=')[0];
|
|
// Node strips out invalid characters like \n and \t from the string, base64-js does not
|
|
str = str.trim().replace(INVALID_BASE64_RE, '');
|
|
// Node converts strings with length < 2 to ''
|
|
if (str.length < 2) return '';
|
|
// Node allows for non-padded base64 strings (missing trailing ===), base64-js does not
|
|
while (str.length % 4 !== 0) {
|
|
str = str + '=';
|
|
}
|
|
return str;
|
|
}
|
|
function utf8ToBytes(string, units) {
|
|
units = units || Infinity;
|
|
let codePoint;
|
|
const length = string.length;
|
|
let leadSurrogate = null;
|
|
const bytes = [];
|
|
for (let i = 0; i < length; ++i) {
|
|
codePoint = string.charCodeAt(i);
|
|
|
|
// is surrogate component
|
|
if (codePoint > 0xD7FF && codePoint < 0xE000) {
|
|
// last char was a lead
|
|
if (!leadSurrogate) {
|
|
// no lead yet
|
|
if (codePoint > 0xDBFF) {
|
|
// unexpected trail
|
|
if ((units -= 3) > -1) bytes.push(0xEF, 0xBF, 0xBD);
|
|
continue;
|
|
} else if (i + 1 === length) {
|
|
// unpaired lead
|
|
if ((units -= 3) > -1) bytes.push(0xEF, 0xBF, 0xBD);
|
|
continue;
|
|
}
|
|
|
|
// valid lead
|
|
leadSurrogate = codePoint;
|
|
continue;
|
|
}
|
|
|
|
// 2 leads in a row
|
|
if (codePoint < 0xDC00) {
|
|
if ((units -= 3) > -1) bytes.push(0xEF, 0xBF, 0xBD);
|
|
leadSurrogate = codePoint;
|
|
continue;
|
|
}
|
|
|
|
// valid surrogate pair
|
|
codePoint = (leadSurrogate - 0xD800 << 10 | codePoint - 0xDC00) + 0x10000;
|
|
} else if (leadSurrogate) {
|
|
// valid bmp char, but last char was a lead
|
|
if ((units -= 3) > -1) bytes.push(0xEF, 0xBF, 0xBD);
|
|
}
|
|
leadSurrogate = null;
|
|
|
|
// encode utf8
|
|
if (codePoint < 0x80) {
|
|
if ((units -= 1) < 0) break;
|
|
bytes.push(codePoint);
|
|
} else if (codePoint < 0x800) {
|
|
if ((units -= 2) < 0) break;
|
|
bytes.push(codePoint >> 0x6 | 0xC0, codePoint & 0x3F | 0x80);
|
|
} else if (codePoint < 0x10000) {
|
|
if ((units -= 3) < 0) break;
|
|
bytes.push(codePoint >> 0xC | 0xE0, codePoint >> 0x6 & 0x3F | 0x80, codePoint & 0x3F | 0x80);
|
|
} else if (codePoint < 0x110000) {
|
|
if ((units -= 4) < 0) break;
|
|
bytes.push(codePoint >> 0x12 | 0xF0, codePoint >> 0xC & 0x3F | 0x80, codePoint >> 0x6 & 0x3F | 0x80, codePoint & 0x3F | 0x80);
|
|
} else {
|
|
throw new Error('Invalid code point');
|
|
}
|
|
}
|
|
return bytes;
|
|
}
|
|
function asciiToBytes(str) {
|
|
const byteArray = [];
|
|
for (let i = 0; i < str.length; ++i) {
|
|
// Node's code seems to be doing this and not & 0x7F..
|
|
byteArray.push(str.charCodeAt(i) & 0xFF);
|
|
}
|
|
return byteArray;
|
|
}
|
|
function utf16leToBytes(str, units) {
|
|
let c, hi, lo;
|
|
const byteArray = [];
|
|
for (let i = 0; i < str.length; ++i) {
|
|
if ((units -= 2) < 0) break;
|
|
c = str.charCodeAt(i);
|
|
hi = c >> 8;
|
|
lo = c % 256;
|
|
byteArray.push(lo);
|
|
byteArray.push(hi);
|
|
}
|
|
return byteArray;
|
|
}
|
|
function base64ToBytes(str) {
|
|
return base64.toByteArray(base64clean(str));
|
|
}
|
|
function blitBuffer(src, dst, offset, length) {
|
|
let i;
|
|
for (i = 0; i < length; ++i) {
|
|
if (i + offset >= dst.length || i >= src.length) break;
|
|
dst[i + offset] = src[i];
|
|
}
|
|
return i;
|
|
}
|
|
|
|
// ArrayBuffer or Uint8Array objects from other contexts (i.e. iframes) do not pass
|
|
// the `instanceof` check but they should be treated as of that type.
|
|
// See: https://github.com/feross/buffer/issues/166
|
|
function isInstance(obj, type) {
|
|
return obj instanceof type || obj != null && obj.constructor != null && obj.constructor.name != null && obj.constructor.name === type.name;
|
|
}
|
|
function numberIsNaN(obj) {
|
|
// For IE11 support
|
|
return obj !== obj; // eslint-disable-line no-self-compare
|
|
}
|
|
|
|
// Create lookup table for `toString('hex')`
|
|
// See: https://github.com/feross/buffer/issues/219
|
|
const hexSliceLookupTable = function () {
|
|
const alphabet = '0123456789abcdef';
|
|
const table = new Array(256);
|
|
for (let i = 0; i < 16; ++i) {
|
|
const i16 = i * 16;
|
|
for (let j = 0; j < 16; ++j) {
|
|
table[i16 + j] = alphabet[i] + alphabet[j];
|
|
}
|
|
}
|
|
return table;
|
|
}();
|
|
|
|
// Return not function with Error if BigInt not supported
|
|
function defineBigIntMethod(fn) {
|
|
return typeof BigInt === 'undefined' ? BufferBigIntNotDefined : fn;
|
|
}
|
|
function BufferBigIntNotDefined() {
|
|
throw new Error('BigInt not supported');
|
|
}
|
|
|
|
/***/ }),
|
|
|
|
/***/ 9488:
|
|
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var $ = __webpack_require__(8155);
|
|
var isSubsetOf = __webpack_require__(6539);
|
|
var setMethodAcceptSetLike = __webpack_require__(5645);
|
|
|
|
// `Set.prototype.isSubsetOf` method
|
|
// https://github.com/tc39/proposal-set-methods
|
|
$({ target: 'Set', proto: true, real: true, forced: !setMethodAcceptSetLike('isSubsetOf') }, {
|
|
isSubsetOf: isSubsetOf
|
|
});
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 9539:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var hasOwn = __webpack_require__(1396);
|
|
var ownKeys = __webpack_require__(3002);
|
|
var getOwnPropertyDescriptorModule = __webpack_require__(2878);
|
|
var definePropertyModule = __webpack_require__(8564);
|
|
|
|
module.exports = function (target, source, exceptions) {
|
|
var keys = ownKeys(source);
|
|
var defineProperty = definePropertyModule.f;
|
|
var getOwnPropertyDescriptor = getOwnPropertyDescriptorModule.f;
|
|
for (var i = 0; i < keys.length; i++) {
|
|
var key = keys[i];
|
|
if (!hasOwn(target, key) && !(exceptions && hasOwn(exceptions, key))) {
|
|
defineProperty(target, key, getOwnPropertyDescriptor(source, key));
|
|
}
|
|
}
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 9541:
|
|
/***/ (function(__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) {
|
|
|
|
"use strict";
|
|
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
/* harmony export */ A: function() { return /* binding */ buildURL; }
|
|
/* harmony export */ });
|
|
/* harmony import */ var _utils_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(5813);
|
|
/* harmony import */ var _helpers_AxiosURLSearchParams_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(5806);
|
|
|
|
|
|
|
|
|
|
|
|
/**
|
|
* It replaces all instances of the characters `:`, `$`, `,`, `+`, `[`, and `]` with their
|
|
* URI encoded counterparts
|
|
*
|
|
* @param {string} val The value to be encoded.
|
|
*
|
|
* @returns {string} The encoded value.
|
|
*/
|
|
function encode(val) {
|
|
return encodeURIComponent(val).replace(/%3A/gi, ':').replace(/%24/g, '$').replace(/%2C/gi, ',').replace(/%20/g, '+').replace(/%5B/gi, '[').replace(/%5D/gi, ']');
|
|
}
|
|
|
|
/**
|
|
* Build a URL by appending params to the end
|
|
*
|
|
* @param {string} url The base of the url (e.g., http://www.google.com)
|
|
* @param {object} [params] The params to be appended
|
|
* @param {?object} options
|
|
*
|
|
* @returns {string} The formatted url
|
|
*/
|
|
function buildURL(url, params, options) {
|
|
/*eslint no-param-reassign:0*/
|
|
if (!params) {
|
|
return url;
|
|
}
|
|
const _encode = options && options.encode || encode;
|
|
const serializeFn = options && options.serialize;
|
|
let serializedParams;
|
|
if (serializeFn) {
|
|
serializedParams = serializeFn(params, options);
|
|
} else {
|
|
serializedParams = _utils_js__WEBPACK_IMPORTED_MODULE_0__/* ["default"] */ .A.isURLSearchParams(params) ? params.toString() : new _helpers_AxiosURLSearchParams_js__WEBPACK_IMPORTED_MODULE_1__/* ["default"] */ .A(params, options).toString(_encode);
|
|
}
|
|
if (serializedParams) {
|
|
const hashmarkIndex = url.indexOf("#");
|
|
if (hashmarkIndex !== -1) {
|
|
url = url.slice(0, hashmarkIndex);
|
|
}
|
|
url += (url.indexOf('?') === -1 ? '?' : '&') + serializedParams;
|
|
}
|
|
return url;
|
|
}
|
|
|
|
/***/ }),
|
|
|
|
/***/ 9566:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
/* eslint-disable es/no-symbol -- required for testing */
|
|
var V8_VERSION = __webpack_require__(491);
|
|
var fails = __webpack_require__(4212);
|
|
var global = __webpack_require__(4074);
|
|
|
|
var $String = global.String;
|
|
|
|
// eslint-disable-next-line es/no-object-getownpropertysymbols -- required for testing
|
|
module.exports = !!Object.getOwnPropertySymbols && !fails(function () {
|
|
var symbol = Symbol('symbol detection');
|
|
// Chrome 38 Symbol has incorrect toString conversion
|
|
// `get-own-property-symbols` polyfill symbols converted to object are not Symbol instances
|
|
// nb: Do not call `String` directly to avoid this being optimized out to `symbol+''` which will,
|
|
// of course, fail.
|
|
return !$String(symbol) || !(Object(symbol) instanceof Symbol) ||
|
|
// Chrome 38-40 symbols are not inherited from DOM collections prototypes to instances
|
|
!Symbol.sham && V8_VERSION && V8_VERSION < 41;
|
|
});
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 9700:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var call = __webpack_require__(4978);
|
|
var aCallable = __webpack_require__(8951);
|
|
var anObject = __webpack_require__(6696);
|
|
var tryToString = __webpack_require__(9240);
|
|
var getIteratorMethod = __webpack_require__(7312);
|
|
|
|
var $TypeError = TypeError;
|
|
|
|
module.exports = function (argument, usingIterator) {
|
|
var iteratorMethod = arguments.length < 2 ? getIteratorMethod(argument) : usingIterator;
|
|
if (aCallable(iteratorMethod)) return anObject(call(iteratorMethod, argument));
|
|
throw new $TypeError(tryToString(argument) + ' is not iterable');
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 9702:
|
|
/***/ (function(module) {
|
|
|
|
"use strict";
|
|
|
|
module.exports = {};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 9760:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var global = __webpack_require__(4074);
|
|
var shared = __webpack_require__(5904);
|
|
var hasOwn = __webpack_require__(1396);
|
|
var uid = __webpack_require__(5675);
|
|
var NATIVE_SYMBOL = __webpack_require__(9566);
|
|
var USE_SYMBOL_AS_UID = __webpack_require__(3167);
|
|
|
|
var Symbol = global.Symbol;
|
|
var WellKnownSymbolsStore = shared('wks');
|
|
var createWellKnownSymbol = USE_SYMBOL_AS_UID ? Symbol['for'] || Symbol : Symbol && Symbol.withoutSetter || uid;
|
|
|
|
module.exports = function (name) {
|
|
if (!hasOwn(WellKnownSymbolsStore, name)) {
|
|
WellKnownSymbolsStore[name] = NATIVE_SYMBOL && hasOwn(Symbol, name)
|
|
? Symbol[name]
|
|
: createWellKnownSymbol('Symbol.' + name);
|
|
} return WellKnownSymbolsStore[name];
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 9776:
|
|
/***/ (function(__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) {
|
|
|
|
"use strict";
|
|
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
/* harmony export */ Ey: function() { return /* binding */ createPinia; },
|
|
/* harmony export */ nY: function() { return /* binding */ defineStore; }
|
|
/* harmony export */ });
|
|
/* unused harmony exports MutationType, PiniaVuePlugin, acceptHMRUpdate, getActivePinia, mapActions, mapGetters, mapState, mapStores, mapWritableState, setActivePinia, setMapStoreSuffix, skipHydrate, storeToRefs */
|
|
/* harmony import */ var core_js_modules_es_array_push_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(5513);
|
|
/* harmony import */ var core_js_modules_esnext_iterator_constructor_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(7195);
|
|
/* harmony import */ var core_js_modules_esnext_iterator_filter_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(3741);
|
|
/* harmony import */ var core_js_modules_esnext_iterator_for_each_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(680);
|
|
/* harmony import */ var core_js_modules_esnext_iterator_map_js__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(793);
|
|
/* harmony import */ var core_js_modules_esnext_iterator_reduce_js__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(5729);
|
|
/* harmony import */ var core_js_modules_esnext_set_difference_v2_js__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(8438);
|
|
/* harmony import */ var core_js_modules_esnext_set_intersection_v2_js__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(6768);
|
|
/* harmony import */ var core_js_modules_esnext_set_is_disjoint_from_v2_js__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(2409);
|
|
/* harmony import */ var core_js_modules_esnext_set_is_subset_of_v2_js__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(9488);
|
|
/* harmony import */ var core_js_modules_esnext_set_is_superset_of_v2_js__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(6591);
|
|
/* harmony import */ var core_js_modules_esnext_set_symmetric_difference_v2_js__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(5412);
|
|
/* harmony import */ var core_js_modules_esnext_set_union_v2_js__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(9214);
|
|
/* harmony import */ var core_js_modules_web_url_search_params_delete_js__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(9130);
|
|
/* harmony import */ var core_js_modules_web_url_search_params_has_js__WEBPACK_IMPORTED_MODULE_14__ = __webpack_require__(8937);
|
|
/* harmony import */ var core_js_modules_web_url_search_params_size_js__WEBPACK_IMPORTED_MODULE_15__ = __webpack_require__(8636);
|
|
/* harmony import */ var vue_demi__WEBPACK_IMPORTED_MODULE_17__ = __webpack_require__(7987);
|
|
/* harmony import */ var vue_demi__WEBPACK_IMPORTED_MODULE_18__ = __webpack_require__(4187);
|
|
/* harmony import */ var vue_demi__WEBPACK_IMPORTED_MODULE_19__ = __webpack_require__(3179);
|
|
/* harmony import */ var _vue_devtools_api__WEBPACK_IMPORTED_MODULE_16__ = __webpack_require__(1327);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
/*!
|
|
* pinia v2.1.7
|
|
* (c) 2023 Eduardo San Martin Morote
|
|
* @license MIT
|
|
*/
|
|
|
|
|
|
|
|
/**
|
|
* setActivePinia must be called to handle SSR at the top of functions like
|
|
* `fetch`, `setup`, `serverPrefetch` and others
|
|
*/
|
|
let activePinia;
|
|
/**
|
|
* Sets or unsets the active pinia. Used in SSR and internally when calling
|
|
* actions and getters
|
|
*
|
|
* @param pinia - Pinia instance
|
|
*/
|
|
// @ts-expect-error: cannot constrain the type of the return
|
|
const setActivePinia = pinia => activePinia = pinia;
|
|
/**
|
|
* Get the currently active pinia if there is any.
|
|
*/
|
|
const getActivePinia = () => hasInjectionContext() && inject(piniaSymbol) || activePinia;
|
|
const piniaSymbol = false ? 0 : /* istanbul ignore next */Symbol();
|
|
function isPlainObject(
|
|
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
o) {
|
|
return o && typeof o === 'object' && Object.prototype.toString.call(o) === '[object Object]' && typeof o.toJSON !== 'function';
|
|
}
|
|
// type DeepReadonly<T> = { readonly [P in keyof T]: DeepReadonly<T[P]> }
|
|
// TODO: can we change these to numbers?
|
|
/**
|
|
* Possible types for SubscriptionCallback
|
|
*/
|
|
var MutationType;
|
|
(function (MutationType) {
|
|
/**
|
|
* Direct mutation of the state:
|
|
*
|
|
* - `store.name = 'new name'`
|
|
* - `store.$state.name = 'new name'`
|
|
* - `store.list.push('new item')`
|
|
*/
|
|
MutationType["direct"] = "direct";
|
|
/**
|
|
* Mutated the state with `$patch` and an object
|
|
*
|
|
* - `store.$patch({ name: 'newName' })`
|
|
*/
|
|
MutationType["patchObject"] = "patch object";
|
|
/**
|
|
* Mutated the state with `$patch` and a function
|
|
*
|
|
* - `store.$patch(state => state.name = 'newName')`
|
|
*/
|
|
MutationType["patchFunction"] = "patch function";
|
|
// maybe reset? for $state = {} and $reset
|
|
})(MutationType || (MutationType = {}));
|
|
const IS_CLIENT = typeof window !== 'undefined';
|
|
/**
|
|
* Should we add the devtools plugins.
|
|
* - only if dev mode or forced through the prod devtools flag
|
|
* - not in test
|
|
* - only if window exists (could change in the future)
|
|
*/
|
|
const USE_DEVTOOLS = false && 0;
|
|
|
|
/*
|
|
* FileSaver.js A saveAs() FileSaver implementation.
|
|
*
|
|
* Originally by Eli Grey, adapted as an ESM module by Eduardo San Martin
|
|
* Morote.
|
|
*
|
|
* License : MIT
|
|
*/
|
|
// The one and only way of getting global scope in all environments
|
|
// https://stackoverflow.com/q/3277182/1008999
|
|
const _global = /*#__PURE__*/(() => typeof window === 'object' && window.window === window ? window : typeof self === 'object' && self.self === self ? self : typeof global === 'object' && global.global === global ? global : typeof globalThis === 'object' ? globalThis : {
|
|
HTMLElement: null
|
|
})();
|
|
function bom(blob, {
|
|
autoBom = false
|
|
} = {}) {
|
|
// prepend BOM for UTF-8 XML and text/* types (including HTML)
|
|
// note: your browser will automatically convert UTF-16 U+FEFF to EF BB BF
|
|
if (autoBom && /^\s*(?:text\/\S*|application\/xml|\S*\/\S*\+xml)\s*;.*charset\s*=\s*utf-8/i.test(blob.type)) {
|
|
return new Blob([String.fromCharCode(0xfeff), blob], {
|
|
type: blob.type
|
|
});
|
|
}
|
|
return blob;
|
|
}
|
|
function download(url, name, opts) {
|
|
const xhr = new XMLHttpRequest();
|
|
xhr.open('GET', url);
|
|
xhr.responseType = 'blob';
|
|
xhr.onload = function () {
|
|
saveAs(xhr.response, name, opts);
|
|
};
|
|
xhr.onerror = function () {
|
|
console.error('could not download file');
|
|
};
|
|
xhr.send();
|
|
}
|
|
function corsEnabled(url) {
|
|
const xhr = new XMLHttpRequest();
|
|
// use sync to avoid popup blocker
|
|
xhr.open('HEAD', url, false);
|
|
try {
|
|
xhr.send();
|
|
} catch (e) {}
|
|
return xhr.status >= 200 && xhr.status <= 299;
|
|
}
|
|
// `a.click()` doesn't work for all browsers (#465)
|
|
function click(node) {
|
|
try {
|
|
node.dispatchEvent(new MouseEvent('click'));
|
|
} catch (e) {
|
|
const evt = document.createEvent('MouseEvents');
|
|
evt.initMouseEvent('click', true, true, window, 0, 0, 0, 80, 20, false, false, false, false, 0, null);
|
|
node.dispatchEvent(evt);
|
|
}
|
|
}
|
|
const _navigator = typeof navigator === 'object' ? navigator : {
|
|
userAgent: ''
|
|
};
|
|
// Detect WebView inside a native macOS app by ruling out all browsers
|
|
// We just need to check for 'Safari' because all other browsers (besides Firefox) include that too
|
|
// https://www.whatismybrowser.com/guides/the-latest-user-agent/macos
|
|
const isMacOSWebView = /*#__PURE__*/(() => /Macintosh/.test(_navigator.userAgent) && /AppleWebKit/.test(_navigator.userAgent) && !/Safari/.test(_navigator.userAgent))();
|
|
const saveAs = !IS_CLIENT ? () => {} // noop
|
|
:
|
|
// Use download attribute first if possible (#193 Lumia mobile) unless this is a macOS WebView or mini program
|
|
typeof HTMLAnchorElement !== 'undefined' && 'download' in HTMLAnchorElement.prototype && !isMacOSWebView ? downloadSaveAs :
|
|
// Use msSaveOrOpenBlob as a second approach
|
|
'msSaveOrOpenBlob' in _navigator ? msSaveAs :
|
|
// Fallback to using FileReader and a popup
|
|
fileSaverSaveAs;
|
|
function downloadSaveAs(blob, name = 'download', opts) {
|
|
const a = document.createElement('a');
|
|
a.download = name;
|
|
a.rel = 'noopener'; // tabnabbing
|
|
// TODO: detect chrome extensions & packaged apps
|
|
// a.target = '_blank'
|
|
if (typeof blob === 'string') {
|
|
// Support regular links
|
|
a.href = blob;
|
|
if (a.origin !== location.origin) {
|
|
if (corsEnabled(a.href)) {
|
|
download(blob, name, opts);
|
|
} else {
|
|
a.target = '_blank';
|
|
click(a);
|
|
}
|
|
} else {
|
|
click(a);
|
|
}
|
|
} else {
|
|
// Support blobs
|
|
a.href = URL.createObjectURL(blob);
|
|
setTimeout(function () {
|
|
URL.revokeObjectURL(a.href);
|
|
}, 4e4); // 40s
|
|
setTimeout(function () {
|
|
click(a);
|
|
}, 0);
|
|
}
|
|
}
|
|
function msSaveAs(blob, name = 'download', opts) {
|
|
if (typeof blob === 'string') {
|
|
if (corsEnabled(blob)) {
|
|
download(blob, name, opts);
|
|
} else {
|
|
const a = document.createElement('a');
|
|
a.href = blob;
|
|
a.target = '_blank';
|
|
setTimeout(function () {
|
|
click(a);
|
|
});
|
|
}
|
|
} else {
|
|
// @ts-ignore: works on windows
|
|
navigator.msSaveOrOpenBlob(bom(blob, opts), name);
|
|
}
|
|
}
|
|
function fileSaverSaveAs(blob, name, opts, popup) {
|
|
// Open a popup immediately do go around popup blocker
|
|
// Mostly only available on user interaction and the fileReader is async so...
|
|
popup = popup || open('', '_blank');
|
|
if (popup) {
|
|
popup.document.title = popup.document.body.innerText = 'downloading...';
|
|
}
|
|
if (typeof blob === 'string') return download(blob, name, opts);
|
|
const force = blob.type === 'application/octet-stream';
|
|
const isSafari = /constructor/i.test(String(_global.HTMLElement)) || 'safari' in _global;
|
|
const isChromeIOS = /CriOS\/[\d]+/.test(navigator.userAgent);
|
|
if ((isChromeIOS || force && isSafari || isMacOSWebView) && typeof FileReader !== 'undefined') {
|
|
// Safari doesn't allow downloading of blob URLs
|
|
const reader = new FileReader();
|
|
reader.onloadend = function () {
|
|
let url = reader.result;
|
|
if (typeof url !== 'string') {
|
|
popup = null;
|
|
throw new Error('Wrong reader.result type');
|
|
}
|
|
url = isChromeIOS ? url : url.replace(/^data:[^;]*;/, 'data:attachment/file;');
|
|
if (popup) {
|
|
popup.location.href = url;
|
|
} else {
|
|
location.assign(url);
|
|
}
|
|
popup = null; // reverse-tabnabbing #460
|
|
};
|
|
reader.readAsDataURL(blob);
|
|
} else {
|
|
const url = URL.createObjectURL(blob);
|
|
if (popup) popup.location.assign(url);else location.href = url;
|
|
popup = null; // reverse-tabnabbing #460
|
|
setTimeout(function () {
|
|
URL.revokeObjectURL(url);
|
|
}, 4e4); // 40s
|
|
}
|
|
}
|
|
|
|
/**
|
|
* Shows a toast or console.log
|
|
*
|
|
* @param message - message to log
|
|
* @param type - different color of the tooltip
|
|
*/
|
|
function toastMessage(message, type) {
|
|
const piniaMessage = '🍍 ' + message;
|
|
if (typeof __VUE_DEVTOOLS_TOAST__ === 'function') {
|
|
// No longer available :(
|
|
__VUE_DEVTOOLS_TOAST__(piniaMessage, type);
|
|
} else if (type === 'error') {
|
|
console.error(piniaMessage);
|
|
} else if (type === 'warn') {
|
|
console.warn(piniaMessage);
|
|
} else {
|
|
console.log(piniaMessage);
|
|
}
|
|
}
|
|
function isPinia(o) {
|
|
return '_a' in o && 'install' in o;
|
|
}
|
|
|
|
/**
|
|
* This file contain devtools actions, they are not Pinia actions.
|
|
*/
|
|
// ---
|
|
function checkClipboardAccess() {
|
|
if (!('clipboard' in navigator)) {
|
|
toastMessage(`Your browser doesn't support the Clipboard API`, 'error');
|
|
return true;
|
|
}
|
|
}
|
|
function checkNotFocusedError(error) {
|
|
if (error instanceof Error && error.message.toLowerCase().includes('document is not focused')) {
|
|
toastMessage('You need to activate the "Emulate a focused page" setting in the "Rendering" panel of devtools.', 'warn');
|
|
return true;
|
|
}
|
|
return false;
|
|
}
|
|
async function actionGlobalCopyState(pinia) {
|
|
if (checkClipboardAccess()) return;
|
|
try {
|
|
await navigator.clipboard.writeText(JSON.stringify(pinia.state.value));
|
|
toastMessage('Global state copied to clipboard.');
|
|
} catch (error) {
|
|
if (checkNotFocusedError(error)) return;
|
|
toastMessage(`Failed to serialize the state. Check the console for more details.`, 'error');
|
|
console.error(error);
|
|
}
|
|
}
|
|
async function actionGlobalPasteState(pinia) {
|
|
if (checkClipboardAccess()) return;
|
|
try {
|
|
loadStoresState(pinia, JSON.parse(await navigator.clipboard.readText()));
|
|
toastMessage('Global state pasted from clipboard.');
|
|
} catch (error) {
|
|
if (checkNotFocusedError(error)) return;
|
|
toastMessage(`Failed to deserialize the state from clipboard. Check the console for more details.`, 'error');
|
|
console.error(error);
|
|
}
|
|
}
|
|
async function actionGlobalSaveState(pinia) {
|
|
try {
|
|
saveAs(new Blob([JSON.stringify(pinia.state.value)], {
|
|
type: 'text/plain;charset=utf-8'
|
|
}), 'pinia-state.json');
|
|
} catch (error) {
|
|
toastMessage(`Failed to export the state as JSON. Check the console for more details.`, 'error');
|
|
console.error(error);
|
|
}
|
|
}
|
|
let fileInput;
|
|
function getFileOpener() {
|
|
if (!fileInput) {
|
|
fileInput = document.createElement('input');
|
|
fileInput.type = 'file';
|
|
fileInput.accept = '.json';
|
|
}
|
|
function openFile() {
|
|
return new Promise((resolve, reject) => {
|
|
fileInput.onchange = async () => {
|
|
const files = fileInput.files;
|
|
if (!files) return resolve(null);
|
|
const file = files.item(0);
|
|
if (!file) return resolve(null);
|
|
return resolve({
|
|
text: await file.text(),
|
|
file
|
|
});
|
|
};
|
|
// @ts-ignore: TODO: changed from 4.3 to 4.4
|
|
fileInput.oncancel = () => resolve(null);
|
|
fileInput.onerror = reject;
|
|
fileInput.click();
|
|
});
|
|
}
|
|
return openFile;
|
|
}
|
|
async function actionGlobalOpenStateFile(pinia) {
|
|
try {
|
|
const open = getFileOpener();
|
|
const result = await open();
|
|
if (!result) return;
|
|
const {
|
|
text,
|
|
file
|
|
} = result;
|
|
loadStoresState(pinia, JSON.parse(text));
|
|
toastMessage(`Global state imported from "${file.name}".`);
|
|
} catch (error) {
|
|
toastMessage(`Failed to import the state from JSON. Check the console for more details.`, 'error');
|
|
console.error(error);
|
|
}
|
|
}
|
|
function loadStoresState(pinia, state) {
|
|
for (const key in state) {
|
|
const storeState = pinia.state.value[key];
|
|
// store is already instantiated, patch it
|
|
if (storeState) {
|
|
Object.assign(storeState, state[key]);
|
|
} else {
|
|
// store is not instantiated, set the initial state
|
|
pinia.state.value[key] = state[key];
|
|
}
|
|
}
|
|
}
|
|
function formatDisplay(display) {
|
|
return {
|
|
_custom: {
|
|
display
|
|
}
|
|
};
|
|
}
|
|
const PINIA_ROOT_LABEL = '🍍 Pinia (root)';
|
|
const PINIA_ROOT_ID = '_root';
|
|
function formatStoreForInspectorTree(store) {
|
|
return isPinia(store) ? {
|
|
id: PINIA_ROOT_ID,
|
|
label: PINIA_ROOT_LABEL
|
|
} : {
|
|
id: store.$id,
|
|
label: store.$id
|
|
};
|
|
}
|
|
function formatStoreForInspectorState(store) {
|
|
if (isPinia(store)) {
|
|
const storeNames = Array.from(store._s.keys());
|
|
const storeMap = store._s;
|
|
const state = {
|
|
state: storeNames.map(storeId => ({
|
|
editable: true,
|
|
key: storeId,
|
|
value: store.state.value[storeId]
|
|
})),
|
|
getters: storeNames.filter(id => storeMap.get(id)._getters).map(id => {
|
|
const store = storeMap.get(id);
|
|
return {
|
|
editable: false,
|
|
key: id,
|
|
value: store._getters.reduce((getters, key) => {
|
|
getters[key] = store[key];
|
|
return getters;
|
|
}, {})
|
|
};
|
|
})
|
|
};
|
|
return state;
|
|
}
|
|
const state = {
|
|
state: Object.keys(store.$state).map(key => ({
|
|
editable: true,
|
|
key,
|
|
value: store.$state[key]
|
|
}))
|
|
};
|
|
// avoid adding empty getters
|
|
if (store._getters && store._getters.length) {
|
|
state.getters = store._getters.map(getterName => ({
|
|
editable: false,
|
|
key: getterName,
|
|
value: store[getterName]
|
|
}));
|
|
}
|
|
if (store._customProperties.size) {
|
|
state.customProperties = Array.from(store._customProperties).map(key => ({
|
|
editable: true,
|
|
key,
|
|
value: store[key]
|
|
}));
|
|
}
|
|
return state;
|
|
}
|
|
function formatEventData(events) {
|
|
if (!events) return {};
|
|
if (Array.isArray(events)) {
|
|
// TODO: handle add and delete for arrays and objects
|
|
return events.reduce((data, event) => {
|
|
data.keys.push(event.key);
|
|
data.operations.push(event.type);
|
|
data.oldValue[event.key] = event.oldValue;
|
|
data.newValue[event.key] = event.newValue;
|
|
return data;
|
|
}, {
|
|
oldValue: {},
|
|
keys: [],
|
|
operations: [],
|
|
newValue: {}
|
|
});
|
|
} else {
|
|
return {
|
|
operation: formatDisplay(events.type),
|
|
key: formatDisplay(events.key),
|
|
oldValue: events.oldValue,
|
|
newValue: events.newValue
|
|
};
|
|
}
|
|
}
|
|
function formatMutationType(type) {
|
|
switch (type) {
|
|
case MutationType.direct:
|
|
return 'mutation';
|
|
case MutationType.patchFunction:
|
|
return '$patch';
|
|
case MutationType.patchObject:
|
|
return '$patch';
|
|
default:
|
|
return 'unknown';
|
|
}
|
|
}
|
|
|
|
// timeline can be paused when directly changing the state
|
|
let isTimelineActive = true;
|
|
const componentStateTypes = [];
|
|
const MUTATIONS_LAYER_ID = 'pinia:mutations';
|
|
const INSPECTOR_ID = 'pinia';
|
|
const {
|
|
assign: assign$1
|
|
} = Object;
|
|
/**
|
|
* Gets the displayed name of a store in devtools
|
|
*
|
|
* @param id - id of the store
|
|
* @returns a formatted string
|
|
*/
|
|
const getStoreType = id => '🍍 ' + id;
|
|
/**
|
|
* Add the pinia plugin without any store. Allows displaying a Pinia plugin tab
|
|
* as soon as it is added to the application.
|
|
*
|
|
* @param app - Vue application
|
|
* @param pinia - pinia instance
|
|
*/
|
|
function registerPiniaDevtools(app, pinia) {
|
|
(0,_vue_devtools_api__WEBPACK_IMPORTED_MODULE_16__/* .setupDevtoolsPlugin */ .$q)({
|
|
id: 'dev.esm.pinia',
|
|
label: 'Pinia 🍍',
|
|
logo: 'https://pinia.vuejs.org/logo.svg',
|
|
packageName: 'pinia',
|
|
homepage: 'https://pinia.vuejs.org',
|
|
componentStateTypes,
|
|
app
|
|
}, api => {
|
|
if (typeof api.now !== 'function') {
|
|
toastMessage('You seem to be using an outdated version of Vue Devtools. Are you still using the Beta release instead of the stable one? You can find the links at https://devtools.vuejs.org/guide/installation.html.');
|
|
}
|
|
api.addTimelineLayer({
|
|
id: MUTATIONS_LAYER_ID,
|
|
label: `Pinia 🍍`,
|
|
color: 0xe5df88
|
|
});
|
|
api.addInspector({
|
|
id: INSPECTOR_ID,
|
|
label: 'Pinia 🍍',
|
|
icon: 'storage',
|
|
treeFilterPlaceholder: 'Search stores',
|
|
actions: [{
|
|
icon: 'content_copy',
|
|
action: () => {
|
|
actionGlobalCopyState(pinia);
|
|
},
|
|
tooltip: 'Serialize and copy the state'
|
|
}, {
|
|
icon: 'content_paste',
|
|
action: async () => {
|
|
await actionGlobalPasteState(pinia);
|
|
api.sendInspectorTree(INSPECTOR_ID);
|
|
api.sendInspectorState(INSPECTOR_ID);
|
|
},
|
|
tooltip: 'Replace the state with the content of your clipboard'
|
|
}, {
|
|
icon: 'save',
|
|
action: () => {
|
|
actionGlobalSaveState(pinia);
|
|
},
|
|
tooltip: 'Save the state as a JSON file'
|
|
}, {
|
|
icon: 'folder_open',
|
|
action: async () => {
|
|
await actionGlobalOpenStateFile(pinia);
|
|
api.sendInspectorTree(INSPECTOR_ID);
|
|
api.sendInspectorState(INSPECTOR_ID);
|
|
},
|
|
tooltip: 'Import the state from a JSON file'
|
|
}],
|
|
nodeActions: [{
|
|
icon: 'restore',
|
|
tooltip: 'Reset the state (with "$reset")',
|
|
action: nodeId => {
|
|
const store = pinia._s.get(nodeId);
|
|
if (!store) {
|
|
toastMessage(`Cannot reset "${nodeId}" store because it wasn't found.`, 'warn');
|
|
} else if (typeof store.$reset !== 'function') {
|
|
toastMessage(`Cannot reset "${nodeId}" store because it doesn't have a "$reset" method implemented.`, 'warn');
|
|
} else {
|
|
store.$reset();
|
|
toastMessage(`Store "${nodeId}" reset.`);
|
|
}
|
|
}
|
|
}]
|
|
});
|
|
api.on.inspectComponent((payload, ctx) => {
|
|
const proxy = payload.componentInstance && payload.componentInstance.proxy;
|
|
if (proxy && proxy._pStores) {
|
|
const piniaStores = payload.componentInstance.proxy._pStores;
|
|
Object.values(piniaStores).forEach(store => {
|
|
payload.instanceData.state.push({
|
|
type: getStoreType(store.$id),
|
|
key: 'state',
|
|
editable: true,
|
|
value: store._isOptionsAPI ? {
|
|
_custom: {
|
|
value: (0,vue_demi__WEBPACK_IMPORTED_MODULE_17__/* .toRaw */ .ux)(store.$state),
|
|
actions: [{
|
|
icon: 'restore',
|
|
tooltip: 'Reset the state of this store',
|
|
action: () => store.$reset()
|
|
}]
|
|
}
|
|
} :
|
|
// NOTE: workaround to unwrap transferred refs
|
|
Object.keys(store.$state).reduce((state, key) => {
|
|
state[key] = store.$state[key];
|
|
return state;
|
|
}, {})
|
|
});
|
|
if (store._getters && store._getters.length) {
|
|
payload.instanceData.state.push({
|
|
type: getStoreType(store.$id),
|
|
key: 'getters',
|
|
editable: false,
|
|
value: store._getters.reduce((getters, key) => {
|
|
try {
|
|
getters[key] = store[key];
|
|
} catch (error) {
|
|
// @ts-expect-error: we just want to show it in devtools
|
|
getters[key] = error;
|
|
}
|
|
return getters;
|
|
}, {})
|
|
});
|
|
}
|
|
});
|
|
}
|
|
});
|
|
api.on.getInspectorTree(payload => {
|
|
if (payload.app === app && payload.inspectorId === INSPECTOR_ID) {
|
|
let stores = [pinia];
|
|
stores = stores.concat(Array.from(pinia._s.values()));
|
|
payload.rootNodes = (payload.filter ? stores.filter(store => '$id' in store ? store.$id.toLowerCase().includes(payload.filter.toLowerCase()) : PINIA_ROOT_LABEL.toLowerCase().includes(payload.filter.toLowerCase())) : stores).map(formatStoreForInspectorTree);
|
|
}
|
|
});
|
|
api.on.getInspectorState(payload => {
|
|
if (payload.app === app && payload.inspectorId === INSPECTOR_ID) {
|
|
const inspectedStore = payload.nodeId === PINIA_ROOT_ID ? pinia : pinia._s.get(payload.nodeId);
|
|
if (!inspectedStore) {
|
|
// this could be the selected store restored for a different project
|
|
// so it's better not to say anything here
|
|
return;
|
|
}
|
|
if (inspectedStore) {
|
|
payload.state = formatStoreForInspectorState(inspectedStore);
|
|
}
|
|
}
|
|
});
|
|
api.on.editInspectorState((payload, ctx) => {
|
|
if (payload.app === app && payload.inspectorId === INSPECTOR_ID) {
|
|
const inspectedStore = payload.nodeId === PINIA_ROOT_ID ? pinia : pinia._s.get(payload.nodeId);
|
|
if (!inspectedStore) {
|
|
return toastMessage(`store "${payload.nodeId}" not found`, 'error');
|
|
}
|
|
const {
|
|
path
|
|
} = payload;
|
|
if (!isPinia(inspectedStore)) {
|
|
// access only the state
|
|
if (path.length !== 1 || !inspectedStore._customProperties.has(path[0]) || path[0] in inspectedStore.$state) {
|
|
path.unshift('$state');
|
|
}
|
|
} else {
|
|
// Root access, we can omit the `.value` because the devtools API does it for us
|
|
path.unshift('state');
|
|
}
|
|
isTimelineActive = false;
|
|
payload.set(inspectedStore, path, payload.state.value);
|
|
isTimelineActive = true;
|
|
}
|
|
});
|
|
api.on.editComponentState(payload => {
|
|
if (payload.type.startsWith('🍍')) {
|
|
const storeId = payload.type.replace(/^🍍\s*/, '');
|
|
const store = pinia._s.get(storeId);
|
|
if (!store) {
|
|
return toastMessage(`store "${storeId}" not found`, 'error');
|
|
}
|
|
const {
|
|
path
|
|
} = payload;
|
|
if (path[0] !== 'state') {
|
|
return toastMessage(`Invalid path for store "${storeId}":\n${path}\nOnly state can be modified.`);
|
|
}
|
|
// rewrite the first entry to be able to directly set the state as
|
|
// well as any other path
|
|
path[0] = '$state';
|
|
isTimelineActive = false;
|
|
payload.set(store, path, payload.state.value);
|
|
isTimelineActive = true;
|
|
}
|
|
});
|
|
});
|
|
}
|
|
function addStoreToDevtools(app, store) {
|
|
if (!componentStateTypes.includes(getStoreType(store.$id))) {
|
|
componentStateTypes.push(getStoreType(store.$id));
|
|
}
|
|
(0,_vue_devtools_api__WEBPACK_IMPORTED_MODULE_16__/* .setupDevtoolsPlugin */ .$q)({
|
|
id: 'dev.esm.pinia',
|
|
label: 'Pinia 🍍',
|
|
logo: 'https://pinia.vuejs.org/logo.svg',
|
|
packageName: 'pinia',
|
|
homepage: 'https://pinia.vuejs.org',
|
|
componentStateTypes,
|
|
app,
|
|
settings: {
|
|
logStoreChanges: {
|
|
label: 'Notify about new/deleted stores',
|
|
type: 'boolean',
|
|
defaultValue: true
|
|
}
|
|
// useEmojis: {
|
|
// label: 'Use emojis in messages ⚡️',
|
|
// type: 'boolean',
|
|
// defaultValue: true,
|
|
// },
|
|
}
|
|
}, api => {
|
|
// gracefully handle errors
|
|
const now = typeof api.now === 'function' ? api.now.bind(api) : Date.now;
|
|
store.$onAction(({
|
|
after,
|
|
onError,
|
|
name,
|
|
args
|
|
}) => {
|
|
const groupId = runningActionId++;
|
|
api.addTimelineEvent({
|
|
layerId: MUTATIONS_LAYER_ID,
|
|
event: {
|
|
time: now(),
|
|
title: '🛫 ' + name,
|
|
subtitle: 'start',
|
|
data: {
|
|
store: formatDisplay(store.$id),
|
|
action: formatDisplay(name),
|
|
args
|
|
},
|
|
groupId
|
|
}
|
|
});
|
|
after(result => {
|
|
activeAction = undefined;
|
|
api.addTimelineEvent({
|
|
layerId: MUTATIONS_LAYER_ID,
|
|
event: {
|
|
time: now(),
|
|
title: '🛬 ' + name,
|
|
subtitle: 'end',
|
|
data: {
|
|
store: formatDisplay(store.$id),
|
|
action: formatDisplay(name),
|
|
args,
|
|
result
|
|
},
|
|
groupId
|
|
}
|
|
});
|
|
});
|
|
onError(error => {
|
|
activeAction = undefined;
|
|
api.addTimelineEvent({
|
|
layerId: MUTATIONS_LAYER_ID,
|
|
event: {
|
|
time: now(),
|
|
logType: 'error',
|
|
title: '💥 ' + name,
|
|
subtitle: 'end',
|
|
data: {
|
|
store: formatDisplay(store.$id),
|
|
action: formatDisplay(name),
|
|
args,
|
|
error
|
|
},
|
|
groupId
|
|
}
|
|
});
|
|
});
|
|
}, true);
|
|
store._customProperties.forEach(name => {
|
|
(0,vue_demi__WEBPACK_IMPORTED_MODULE_18__/* .watch */ .wB)(() => (0,vue_demi__WEBPACK_IMPORTED_MODULE_17__/* .unref */ .R1)(store[name]), (newValue, oldValue) => {
|
|
api.notifyComponentUpdate();
|
|
api.sendInspectorState(INSPECTOR_ID);
|
|
if (isTimelineActive) {
|
|
api.addTimelineEvent({
|
|
layerId: MUTATIONS_LAYER_ID,
|
|
event: {
|
|
time: now(),
|
|
title: 'Change',
|
|
subtitle: name,
|
|
data: {
|
|
newValue,
|
|
oldValue
|
|
},
|
|
groupId: activeAction
|
|
}
|
|
});
|
|
}
|
|
}, {
|
|
deep: true
|
|
});
|
|
});
|
|
store.$subscribe(({
|
|
events,
|
|
type
|
|
}, state) => {
|
|
api.notifyComponentUpdate();
|
|
api.sendInspectorState(INSPECTOR_ID);
|
|
if (!isTimelineActive) return;
|
|
// rootStore.state[store.id] = state
|
|
const eventData = {
|
|
time: now(),
|
|
title: formatMutationType(type),
|
|
data: assign$1({
|
|
store: formatDisplay(store.$id)
|
|
}, formatEventData(events)),
|
|
groupId: activeAction
|
|
};
|
|
if (type === MutationType.patchFunction) {
|
|
eventData.subtitle = '⤵️';
|
|
} else if (type === MutationType.patchObject) {
|
|
eventData.subtitle = '🧩';
|
|
} else if (events && !Array.isArray(events)) {
|
|
eventData.subtitle = events.type;
|
|
}
|
|
if (events) {
|
|
eventData.data['rawEvent(s)'] = {
|
|
_custom: {
|
|
display: 'DebuggerEvent',
|
|
type: 'object',
|
|
tooltip: 'raw DebuggerEvent[]',
|
|
value: events
|
|
}
|
|
};
|
|
}
|
|
api.addTimelineEvent({
|
|
layerId: MUTATIONS_LAYER_ID,
|
|
event: eventData
|
|
});
|
|
}, {
|
|
detached: true,
|
|
flush: 'sync'
|
|
});
|
|
const hotUpdate = store._hotUpdate;
|
|
store._hotUpdate = (0,vue_demi__WEBPACK_IMPORTED_MODULE_17__/* .markRaw */ .IG)(newStore => {
|
|
hotUpdate(newStore);
|
|
api.addTimelineEvent({
|
|
layerId: MUTATIONS_LAYER_ID,
|
|
event: {
|
|
time: now(),
|
|
title: '🔥 ' + store.$id,
|
|
subtitle: 'HMR update',
|
|
data: {
|
|
store: formatDisplay(store.$id),
|
|
info: formatDisplay(`HMR update`)
|
|
}
|
|
}
|
|
});
|
|
// update the devtools too
|
|
api.notifyComponentUpdate();
|
|
api.sendInspectorTree(INSPECTOR_ID);
|
|
api.sendInspectorState(INSPECTOR_ID);
|
|
});
|
|
const {
|
|
$dispose
|
|
} = store;
|
|
store.$dispose = () => {
|
|
$dispose();
|
|
api.notifyComponentUpdate();
|
|
api.sendInspectorTree(INSPECTOR_ID);
|
|
api.sendInspectorState(INSPECTOR_ID);
|
|
api.getSettings().logStoreChanges && toastMessage(`Disposed "${store.$id}" store 🗑`);
|
|
};
|
|
// trigger an update so it can display new registered stores
|
|
api.notifyComponentUpdate();
|
|
api.sendInspectorTree(INSPECTOR_ID);
|
|
api.sendInspectorState(INSPECTOR_ID);
|
|
api.getSettings().logStoreChanges && toastMessage(`"${store.$id}" store installed 🆕`);
|
|
});
|
|
}
|
|
let runningActionId = 0;
|
|
let activeAction;
|
|
/**
|
|
* Patches a store to enable action grouping in devtools by wrapping the store with a Proxy that is passed as the
|
|
* context of all actions, allowing us to set `runningAction` on each access and effectively associating any state
|
|
* mutation to the action.
|
|
*
|
|
* @param store - store to patch
|
|
* @param actionNames - list of actionst to patch
|
|
*/
|
|
function patchActionForGrouping(store, actionNames, wrapWithProxy) {
|
|
// original actions of the store as they are given by pinia. We are going to override them
|
|
const actions = actionNames.reduce((storeActions, actionName) => {
|
|
// use toRaw to avoid tracking #541
|
|
storeActions[actionName] = (0,vue_demi__WEBPACK_IMPORTED_MODULE_17__/* .toRaw */ .ux)(store)[actionName];
|
|
return storeActions;
|
|
}, {});
|
|
for (const actionName in actions) {
|
|
store[actionName] = function () {
|
|
// the running action id is incremented in a before action hook
|
|
const _actionId = runningActionId;
|
|
const trackedStore = wrapWithProxy ? new Proxy(store, {
|
|
get(...args) {
|
|
activeAction = _actionId;
|
|
return Reflect.get(...args);
|
|
},
|
|
set(...args) {
|
|
activeAction = _actionId;
|
|
return Reflect.set(...args);
|
|
}
|
|
}) : store;
|
|
// For Setup Stores we need https://github.com/tc39/proposal-async-context
|
|
activeAction = _actionId;
|
|
const retValue = actions[actionName].apply(trackedStore, arguments);
|
|
// this is safer as async actions in Setup Stores would associate mutations done outside of the action
|
|
activeAction = undefined;
|
|
return retValue;
|
|
};
|
|
}
|
|
}
|
|
/**
|
|
* pinia.use(devtoolsPlugin)
|
|
*/
|
|
function devtoolsPlugin({
|
|
app,
|
|
store,
|
|
options
|
|
}) {
|
|
// HMR module
|
|
if (store.$id.startsWith('__hot:')) {
|
|
return;
|
|
}
|
|
// detect option api vs setup api
|
|
store._isOptionsAPI = !!options.state;
|
|
patchActionForGrouping(store, Object.keys(options.actions), store._isOptionsAPI);
|
|
// Upgrade the HMR to also update the new actions
|
|
const originalHotUpdate = store._hotUpdate;
|
|
(0,vue_demi__WEBPACK_IMPORTED_MODULE_17__/* .toRaw */ .ux)(store)._hotUpdate = function (newStore) {
|
|
originalHotUpdate.apply(this, arguments);
|
|
patchActionForGrouping(store, Object.keys(newStore._hmrPayload.actions), !!store._isOptionsAPI);
|
|
};
|
|
addStoreToDevtools(app,
|
|
// FIXME: is there a way to allow the assignment from Store<Id, S, G, A> to StoreGeneric?
|
|
store);
|
|
}
|
|
|
|
/**
|
|
* Creates a Pinia instance to be used by the application
|
|
*/
|
|
function createPinia() {
|
|
const scope = (0,vue_demi__WEBPACK_IMPORTED_MODULE_17__/* .effectScope */ .uY)(true);
|
|
// NOTE: here we could check the window object for a state and directly set it
|
|
// if there is anything like it with Vue 3 SSR
|
|
const state = scope.run(() => (0,vue_demi__WEBPACK_IMPORTED_MODULE_17__/* .ref */ .KR)({}));
|
|
let _p = [];
|
|
// plugins added before calling app.use(pinia)
|
|
let toBeInstalled = [];
|
|
const pinia = (0,vue_demi__WEBPACK_IMPORTED_MODULE_17__/* .markRaw */ .IG)({
|
|
install(app) {
|
|
// this allows calling useStore() outside of a component setup after
|
|
// installing pinia's plugin
|
|
setActivePinia(pinia);
|
|
if (!vue_demi__WEBPACK_IMPORTED_MODULE_19__/* .isVue2 */ .LER) {
|
|
pinia._a = app;
|
|
app.provide(piniaSymbol, pinia);
|
|
app.config.globalProperties.$pinia = pinia;
|
|
/* istanbul ignore else */
|
|
if (USE_DEVTOOLS) {
|
|
registerPiniaDevtools(app, pinia);
|
|
}
|
|
toBeInstalled.forEach(plugin => _p.push(plugin));
|
|
toBeInstalled = [];
|
|
}
|
|
},
|
|
use(plugin) {
|
|
if (!this._a && !vue_demi__WEBPACK_IMPORTED_MODULE_19__/* .isVue2 */ .LER) {
|
|
toBeInstalled.push(plugin);
|
|
} else {
|
|
_p.push(plugin);
|
|
}
|
|
return this;
|
|
},
|
|
_p,
|
|
// it's actually undefined here
|
|
// @ts-expect-error
|
|
_a: null,
|
|
_e: scope,
|
|
_s: new Map(),
|
|
state
|
|
});
|
|
// pinia devtools rely on dev only features so they cannot be forced unless
|
|
// the dev build of Vue is used. Avoid old browsers like IE11.
|
|
if (USE_DEVTOOLS && typeof Proxy !== 'undefined') {
|
|
pinia.use(devtoolsPlugin);
|
|
}
|
|
return pinia;
|
|
}
|
|
|
|
/**
|
|
* Checks if a function is a `StoreDefinition`.
|
|
*
|
|
* @param fn - object to test
|
|
* @returns true if `fn` is a StoreDefinition
|
|
*/
|
|
const isUseStore = fn => {
|
|
return typeof fn === 'function' && typeof fn.$id === 'string';
|
|
};
|
|
/**
|
|
* Mutates in place `newState` with `oldState` to _hot update_ it. It will
|
|
* remove any key not existing in `newState` and recursively merge plain
|
|
* objects.
|
|
*
|
|
* @param newState - new state object to be patched
|
|
* @param oldState - old state that should be used to patch newState
|
|
* @returns - newState
|
|
*/
|
|
function patchObject(newState, oldState) {
|
|
// no need to go through symbols because they cannot be serialized anyway
|
|
for (const key in oldState) {
|
|
const subPatch = oldState[key];
|
|
// skip the whole sub tree
|
|
if (!(key in newState)) {
|
|
continue;
|
|
}
|
|
const targetValue = newState[key];
|
|
if (isPlainObject(targetValue) && isPlainObject(subPatch) && !isRef(subPatch) && !isReactive(subPatch)) {
|
|
newState[key] = patchObject(targetValue, subPatch);
|
|
} else {
|
|
// objects are either a bit more complex (e.g. refs) or primitives, so we
|
|
// just set the whole thing
|
|
if (isVue2) {
|
|
set(newState, key, subPatch);
|
|
} else {
|
|
newState[key] = subPatch;
|
|
}
|
|
}
|
|
}
|
|
return newState;
|
|
}
|
|
/**
|
|
* Creates an _accept_ function to pass to `import.meta.hot` in Vite applications.
|
|
*
|
|
* @example
|
|
* ```js
|
|
* const useUser = defineStore(...)
|
|
* if (import.meta.hot) {
|
|
* import.meta.hot.accept(acceptHMRUpdate(useUser, import.meta.hot))
|
|
* }
|
|
* ```
|
|
*
|
|
* @param initialUseStore - return of the defineStore to hot update
|
|
* @param hot - `import.meta.hot`
|
|
*/
|
|
function acceptHMRUpdate(initialUseStore, hot) {
|
|
// strip as much as possible from iife.prod
|
|
if (true) {
|
|
return () => {};
|
|
}
|
|
return newModule => {
|
|
const pinia = hot.data.pinia || initialUseStore._pinia;
|
|
if (!pinia) {
|
|
// this store is still not used
|
|
return;
|
|
}
|
|
// preserve the pinia instance across loads
|
|
hot.data.pinia = pinia;
|
|
// console.log('got data', newStore)
|
|
for (const exportName in newModule) {
|
|
const useStore = newModule[exportName];
|
|
// console.log('checking for', exportName)
|
|
if (isUseStore(useStore) && pinia._s.has(useStore.$id)) {
|
|
// console.log('Accepting update for', useStore.$id)
|
|
const id = useStore.$id;
|
|
if (id !== initialUseStore.$id) {
|
|
console.warn(`The id of the store changed from "${initialUseStore.$id}" to "${id}". Reloading.`);
|
|
// return import.meta.hot.invalidate()
|
|
return hot.invalidate();
|
|
}
|
|
const existingStore = pinia._s.get(id);
|
|
if (!existingStore) {
|
|
console.log(`[Pinia]: skipping hmr because store doesn't exist yet`);
|
|
return;
|
|
}
|
|
useStore(pinia, existingStore);
|
|
}
|
|
}
|
|
};
|
|
}
|
|
const noop = () => {};
|
|
function addSubscription(subscriptions, callback, detached, onCleanup = noop) {
|
|
subscriptions.push(callback);
|
|
const removeSubscription = () => {
|
|
const idx = subscriptions.indexOf(callback);
|
|
if (idx > -1) {
|
|
subscriptions.splice(idx, 1);
|
|
onCleanup();
|
|
}
|
|
};
|
|
if (!detached && (0,vue_demi__WEBPACK_IMPORTED_MODULE_17__/* .getCurrentScope */ .o5)()) {
|
|
(0,vue_demi__WEBPACK_IMPORTED_MODULE_17__/* .onScopeDispose */ .jr)(removeSubscription);
|
|
}
|
|
return removeSubscription;
|
|
}
|
|
function triggerSubscriptions(subscriptions, ...args) {
|
|
subscriptions.slice().forEach(callback => {
|
|
callback(...args);
|
|
});
|
|
}
|
|
const fallbackRunWithContext = fn => fn();
|
|
function mergeReactiveObjects(target, patchToApply) {
|
|
// Handle Map instances
|
|
if (target instanceof Map && patchToApply instanceof Map) {
|
|
patchToApply.forEach((value, key) => target.set(key, value));
|
|
}
|
|
// Handle Set instances
|
|
if (target instanceof Set && patchToApply instanceof Set) {
|
|
patchToApply.forEach(target.add, target);
|
|
}
|
|
// no need to go through symbols because they cannot be serialized anyway
|
|
for (const key in patchToApply) {
|
|
if (!patchToApply.hasOwnProperty(key)) continue;
|
|
const subPatch = patchToApply[key];
|
|
const targetValue = target[key];
|
|
if (isPlainObject(targetValue) && isPlainObject(subPatch) && target.hasOwnProperty(key) && !(0,vue_demi__WEBPACK_IMPORTED_MODULE_17__/* .isRef */ .i9)(subPatch) && !(0,vue_demi__WEBPACK_IMPORTED_MODULE_17__/* .isReactive */ .g8)(subPatch)) {
|
|
// NOTE: here I wanted to warn about inconsistent types but it's not possible because in setup stores one might
|
|
// start the value of a property as a certain type e.g. a Map, and then for some reason, during SSR, change that
|
|
// to `undefined`. When trying to hydrate, we want to override the Map with `undefined`.
|
|
target[key] = mergeReactiveObjects(targetValue, subPatch);
|
|
} else {
|
|
// @ts-expect-error: subPatch is a valid value
|
|
target[key] = subPatch;
|
|
}
|
|
}
|
|
return target;
|
|
}
|
|
const skipHydrateSymbol = false ? 0 : /* istanbul ignore next */Symbol();
|
|
const skipHydrateMap = /*#__PURE__*/new WeakMap();
|
|
/**
|
|
* Tells Pinia to skip the hydration process of a given object. This is useful in setup stores (only) when you return a
|
|
* stateful object in the store but it isn't really state. e.g. returning a router instance in a setup store.
|
|
*
|
|
* @param obj - target object
|
|
* @returns obj
|
|
*/
|
|
function skipHydrate(obj) {
|
|
return isVue2 ?
|
|
// in @vue/composition-api, the refs are sealed so defineProperty doesn't work...
|
|
/* istanbul ignore next */
|
|
skipHydrateMap.set(obj, 1) && obj : Object.defineProperty(obj, skipHydrateSymbol, {});
|
|
}
|
|
/**
|
|
* Returns whether a value should be hydrated
|
|
*
|
|
* @param obj - target variable
|
|
* @returns true if `obj` should be hydrated
|
|
*/
|
|
function shouldHydrate(obj) {
|
|
return vue_demi__WEBPACK_IMPORTED_MODULE_19__/* .isVue2 */ .LER ? /* istanbul ignore next */!skipHydrateMap.has(obj) : !isPlainObject(obj) || !obj.hasOwnProperty(skipHydrateSymbol);
|
|
}
|
|
const {
|
|
assign
|
|
} = Object;
|
|
function isComputed(o) {
|
|
return !!((0,vue_demi__WEBPACK_IMPORTED_MODULE_17__/* .isRef */ .i9)(o) && o.effect);
|
|
}
|
|
function createOptionsStore(id, options, pinia, hot) {
|
|
const {
|
|
state,
|
|
actions,
|
|
getters
|
|
} = options;
|
|
const initialState = pinia.state.value[id];
|
|
let store;
|
|
function setup() {
|
|
if (!initialState && ( true || 0)) {
|
|
/* istanbul ignore if */
|
|
if (vue_demi__WEBPACK_IMPORTED_MODULE_19__/* .isVue2 */ .LER) {
|
|
(0,vue_demi__WEBPACK_IMPORTED_MODULE_19__/* .set */ .hZp)(pinia.state.value, id, state ? state() : {});
|
|
} else {
|
|
pinia.state.value[id] = state ? state() : {};
|
|
}
|
|
}
|
|
// avoid creating a state in pinia.state.value
|
|
const localState = false ?
|
|
// use ref() to unwrap refs inside state TODO: check if this is still necessary
|
|
0 : (0,vue_demi__WEBPACK_IMPORTED_MODULE_17__/* .toRefs */ .QW)(pinia.state.value[id]);
|
|
return assign(localState, actions, Object.keys(getters || {}).reduce((computedGetters, name) => {
|
|
if (false) {}
|
|
computedGetters[name] = (0,vue_demi__WEBPACK_IMPORTED_MODULE_17__/* .markRaw */ .IG)((0,vue_demi__WEBPACK_IMPORTED_MODULE_18__/* .computed */ .EW)(() => {
|
|
setActivePinia(pinia);
|
|
// it was created just before
|
|
const store = pinia._s.get(id);
|
|
// allow cross using stores
|
|
/* istanbul ignore next */
|
|
if (vue_demi__WEBPACK_IMPORTED_MODULE_19__/* .isVue2 */ .LER && !store._r) return;
|
|
// @ts-expect-error
|
|
// return getters![name].call(context, context)
|
|
// TODO: avoid reading the getter while assigning with a global variable
|
|
return getters[name].call(store, store);
|
|
}));
|
|
return computedGetters;
|
|
}, {}));
|
|
}
|
|
store = createSetupStore(id, setup, options, pinia, hot, true);
|
|
return store;
|
|
}
|
|
function createSetupStore($id, setup, options = {}, pinia, hot, isOptionsStore) {
|
|
let scope;
|
|
const optionsForPlugin = assign({
|
|
actions: {}
|
|
}, options);
|
|
/* istanbul ignore if */
|
|
if (false) {}
|
|
// watcher options for $subscribe
|
|
const $subscribeOptions = {
|
|
deep: true
|
|
// flush: 'post',
|
|
};
|
|
/* istanbul ignore else */
|
|
if (false) {}
|
|
// internal state
|
|
let isListening; // set to true at the end
|
|
let isSyncListening; // set to true at the end
|
|
let subscriptions = [];
|
|
let actionSubscriptions = [];
|
|
let debuggerEvents;
|
|
const initialState = pinia.state.value[$id];
|
|
// avoid setting the state for option stores if it is set
|
|
// by the setup
|
|
if (!isOptionsStore && !initialState && ( true || 0)) {
|
|
/* istanbul ignore if */
|
|
if (vue_demi__WEBPACK_IMPORTED_MODULE_19__/* .isVue2 */ .LER) {
|
|
(0,vue_demi__WEBPACK_IMPORTED_MODULE_19__/* .set */ .hZp)(pinia.state.value, $id, {});
|
|
} else {
|
|
pinia.state.value[$id] = {};
|
|
}
|
|
}
|
|
const hotState = (0,vue_demi__WEBPACK_IMPORTED_MODULE_17__/* .ref */ .KR)({});
|
|
// avoid triggering too many listeners
|
|
// https://github.com/vuejs/pinia/issues/1129
|
|
let activeListener;
|
|
function $patch(partialStateOrMutator) {
|
|
let subscriptionMutation;
|
|
isListening = isSyncListening = false;
|
|
// reset the debugger events since patches are sync
|
|
/* istanbul ignore else */
|
|
if (false) {}
|
|
if (typeof partialStateOrMutator === 'function') {
|
|
partialStateOrMutator(pinia.state.value[$id]);
|
|
subscriptionMutation = {
|
|
type: MutationType.patchFunction,
|
|
storeId: $id,
|
|
events: debuggerEvents
|
|
};
|
|
} else {
|
|
mergeReactiveObjects(pinia.state.value[$id], partialStateOrMutator);
|
|
subscriptionMutation = {
|
|
type: MutationType.patchObject,
|
|
payload: partialStateOrMutator,
|
|
storeId: $id,
|
|
events: debuggerEvents
|
|
};
|
|
}
|
|
const myListenerId = activeListener = Symbol();
|
|
(0,vue_demi__WEBPACK_IMPORTED_MODULE_18__/* .nextTick */ .dY)().then(() => {
|
|
if (activeListener === myListenerId) {
|
|
isListening = true;
|
|
}
|
|
});
|
|
isSyncListening = true;
|
|
// because we paused the watcher, we need to manually call the subscriptions
|
|
triggerSubscriptions(subscriptions, subscriptionMutation, pinia.state.value[$id]);
|
|
}
|
|
const $reset = isOptionsStore ? function $reset() {
|
|
const {
|
|
state
|
|
} = options;
|
|
const newState = state ? state() : {};
|
|
// we use a patch to group all changes into one single subscription
|
|
this.$patch($state => {
|
|
assign($state, newState);
|
|
});
|
|
} : /* istanbul ignore next */
|
|
false ? 0 : noop;
|
|
function $dispose() {
|
|
scope.stop();
|
|
subscriptions = [];
|
|
actionSubscriptions = [];
|
|
pinia._s.delete($id);
|
|
}
|
|
/**
|
|
* Wraps an action to handle subscriptions.
|
|
*
|
|
* @param name - name of the action
|
|
* @param action - action to wrap
|
|
* @returns a wrapped action to handle subscriptions
|
|
*/
|
|
function wrapAction(name, action) {
|
|
return function () {
|
|
setActivePinia(pinia);
|
|
const args = Array.from(arguments);
|
|
const afterCallbackList = [];
|
|
const onErrorCallbackList = [];
|
|
function after(callback) {
|
|
afterCallbackList.push(callback);
|
|
}
|
|
function onError(callback) {
|
|
onErrorCallbackList.push(callback);
|
|
}
|
|
// @ts-expect-error
|
|
triggerSubscriptions(actionSubscriptions, {
|
|
args,
|
|
name,
|
|
store,
|
|
after,
|
|
onError
|
|
});
|
|
let ret;
|
|
try {
|
|
ret = action.apply(this && this.$id === $id ? this : store, args);
|
|
// handle sync errors
|
|
} catch (error) {
|
|
triggerSubscriptions(onErrorCallbackList, error);
|
|
throw error;
|
|
}
|
|
if (ret instanceof Promise) {
|
|
return ret.then(value => {
|
|
triggerSubscriptions(afterCallbackList, value);
|
|
return value;
|
|
}).catch(error => {
|
|
triggerSubscriptions(onErrorCallbackList, error);
|
|
return Promise.reject(error);
|
|
});
|
|
}
|
|
// trigger after callbacks
|
|
triggerSubscriptions(afterCallbackList, ret);
|
|
return ret;
|
|
};
|
|
}
|
|
const _hmrPayload = /*#__PURE__*/(0,vue_demi__WEBPACK_IMPORTED_MODULE_17__/* .markRaw */ .IG)({
|
|
actions: {},
|
|
getters: {},
|
|
state: [],
|
|
hotState
|
|
});
|
|
const partialStore = {
|
|
_p: pinia,
|
|
// _s: scope,
|
|
$id,
|
|
$onAction: addSubscription.bind(null, actionSubscriptions),
|
|
$patch,
|
|
$reset,
|
|
$subscribe(callback, options = {}) {
|
|
const removeSubscription = addSubscription(subscriptions, callback, options.detached, () => stopWatcher());
|
|
const stopWatcher = scope.run(() => (0,vue_demi__WEBPACK_IMPORTED_MODULE_18__/* .watch */ .wB)(() => pinia.state.value[$id], state => {
|
|
if (options.flush === 'sync' ? isSyncListening : isListening) {
|
|
callback({
|
|
storeId: $id,
|
|
type: MutationType.direct,
|
|
events: debuggerEvents
|
|
}, state);
|
|
}
|
|
}, assign({}, $subscribeOptions, options)));
|
|
return removeSubscription;
|
|
},
|
|
$dispose
|
|
};
|
|
/* istanbul ignore if */
|
|
if (vue_demi__WEBPACK_IMPORTED_MODULE_19__/* .isVue2 */ .LER) {
|
|
// start as non ready
|
|
partialStore._r = false;
|
|
}
|
|
const store = (0,vue_demi__WEBPACK_IMPORTED_MODULE_17__/* .reactive */ .Kh)( false || USE_DEVTOOLS ? assign({
|
|
_hmrPayload,
|
|
_customProperties: (0,vue_demi__WEBPACK_IMPORTED_MODULE_17__/* .markRaw */ .IG)(new Set()) // devtools custom properties
|
|
}, partialStore
|
|
// must be added later
|
|
// setupStore
|
|
) : partialStore);
|
|
// store the partial store now so the setup of stores can instantiate each other before they are finished without
|
|
// creating infinite loops.
|
|
pinia._s.set($id, store);
|
|
const runWithContext = pinia._a && pinia._a.runWithContext || fallbackRunWithContext;
|
|
// TODO: idea create skipSerialize that marks properties as non serializable and they are skipped
|
|
const setupStore = runWithContext(() => pinia._e.run(() => (scope = (0,vue_demi__WEBPACK_IMPORTED_MODULE_17__/* .effectScope */ .uY)()).run(setup)));
|
|
// overwrite existing actions to support $onAction
|
|
for (const key in setupStore) {
|
|
const prop = setupStore[key];
|
|
if ((0,vue_demi__WEBPACK_IMPORTED_MODULE_17__/* .isRef */ .i9)(prop) && !isComputed(prop) || (0,vue_demi__WEBPACK_IMPORTED_MODULE_17__/* .isReactive */ .g8)(prop)) {
|
|
// mark it as a piece of state to be serialized
|
|
if (false) {} else if (!isOptionsStore) {
|
|
// in setup stores we must hydrate the state and sync pinia state tree with the refs the user just created
|
|
if (initialState && shouldHydrate(prop)) {
|
|
if ((0,vue_demi__WEBPACK_IMPORTED_MODULE_17__/* .isRef */ .i9)(prop)) {
|
|
prop.value = initialState[key];
|
|
} else {
|
|
// probably a reactive object, lets recursively assign
|
|
// @ts-expect-error: prop is unknown
|
|
mergeReactiveObjects(prop, initialState[key]);
|
|
}
|
|
}
|
|
// transfer the ref to the pinia state to keep everything in sync
|
|
/* istanbul ignore if */
|
|
if (vue_demi__WEBPACK_IMPORTED_MODULE_19__/* .isVue2 */ .LER) {
|
|
(0,vue_demi__WEBPACK_IMPORTED_MODULE_19__/* .set */ .hZp)(pinia.state.value[$id], key, prop);
|
|
} else {
|
|
pinia.state.value[$id][key] = prop;
|
|
}
|
|
}
|
|
/* istanbul ignore else */
|
|
if (false) {}
|
|
// action
|
|
} else if (typeof prop === 'function') {
|
|
// @ts-expect-error: we are overriding the function we avoid wrapping if
|
|
const actionValue = false ? 0 : wrapAction(key, prop);
|
|
// this a hot module replacement store because the hotUpdate method needs
|
|
// to do it with the right context
|
|
/* istanbul ignore if */
|
|
if (vue_demi__WEBPACK_IMPORTED_MODULE_19__/* .isVue2 */ .LER) {
|
|
(0,vue_demi__WEBPACK_IMPORTED_MODULE_19__/* .set */ .hZp)(setupStore, key, actionValue);
|
|
} else {
|
|
// @ts-expect-error
|
|
setupStore[key] = actionValue;
|
|
}
|
|
/* istanbul ignore else */
|
|
if (false) {}
|
|
// list actions so they can be used in plugins
|
|
// @ts-expect-error
|
|
optionsForPlugin.actions[key] = prop;
|
|
} else if (false) {}
|
|
}
|
|
// add the state, getters, and action properties
|
|
/* istanbul ignore if */
|
|
if (vue_demi__WEBPACK_IMPORTED_MODULE_19__/* .isVue2 */ .LER) {
|
|
Object.keys(setupStore).forEach(key => {
|
|
(0,vue_demi__WEBPACK_IMPORTED_MODULE_19__/* .set */ .hZp)(store, key, setupStore[key]);
|
|
});
|
|
} else {
|
|
assign(store, setupStore);
|
|
// allows retrieving reactive objects with `storeToRefs()`. Must be called after assigning to the reactive object.
|
|
// Make `storeToRefs()` work with `reactive()` #799
|
|
assign((0,vue_demi__WEBPACK_IMPORTED_MODULE_17__/* .toRaw */ .ux)(store), setupStore);
|
|
}
|
|
// use this instead of a computed with setter to be able to create it anywhere
|
|
// without linking the computed lifespan to wherever the store is first
|
|
// created.
|
|
Object.defineProperty(store, '$state', {
|
|
get: () => false ? 0 : pinia.state.value[$id],
|
|
set: state => {
|
|
/* istanbul ignore if */
|
|
if (false) {}
|
|
$patch($state => {
|
|
assign($state, state);
|
|
});
|
|
}
|
|
});
|
|
// add the hotUpdate before plugins to allow them to override it
|
|
/* istanbul ignore else */
|
|
if (false) {}
|
|
if (USE_DEVTOOLS) {
|
|
const nonEnumerable = {
|
|
writable: true,
|
|
configurable: true,
|
|
// avoid warning on devtools trying to display this property
|
|
enumerable: false
|
|
};
|
|
['_p', '_hmrPayload', '_getters', '_customProperties'].forEach(p => {
|
|
Object.defineProperty(store, p, assign({
|
|
value: store[p]
|
|
}, nonEnumerable));
|
|
});
|
|
}
|
|
/* istanbul ignore if */
|
|
if (vue_demi__WEBPACK_IMPORTED_MODULE_19__/* .isVue2 */ .LER) {
|
|
// mark the store as ready before plugins
|
|
store._r = true;
|
|
}
|
|
// apply all plugins
|
|
pinia._p.forEach(extender => {
|
|
/* istanbul ignore else */
|
|
if (USE_DEVTOOLS) {
|
|
const extensions = scope.run(() => extender({
|
|
store,
|
|
app: pinia._a,
|
|
pinia,
|
|
options: optionsForPlugin
|
|
}));
|
|
Object.keys(extensions || {}).forEach(key => store._customProperties.add(key));
|
|
assign(store, extensions);
|
|
} else {
|
|
assign(store, scope.run(() => extender({
|
|
store,
|
|
app: pinia._a,
|
|
pinia,
|
|
options: optionsForPlugin
|
|
})));
|
|
}
|
|
});
|
|
if (false) {}
|
|
// only apply hydrate to option stores with an initial state in pinia
|
|
if (initialState && isOptionsStore && options.hydrate) {
|
|
options.hydrate(store.$state, initialState);
|
|
}
|
|
isListening = true;
|
|
isSyncListening = true;
|
|
return store;
|
|
}
|
|
function defineStore(
|
|
// TODO: add proper types from above
|
|
idOrOptions, setup, setupOptions) {
|
|
let id;
|
|
let options;
|
|
const isSetupStore = typeof setup === 'function';
|
|
if (typeof idOrOptions === 'string') {
|
|
id = idOrOptions;
|
|
// the option store setup will contain the actual options in this case
|
|
options = isSetupStore ? setupOptions : setup;
|
|
} else {
|
|
options = idOrOptions;
|
|
id = idOrOptions.id;
|
|
if (false) {}
|
|
}
|
|
function useStore(pinia, hot) {
|
|
const hasContext = (0,vue_demi__WEBPACK_IMPORTED_MODULE_18__/* .hasInjectionContext */ .PS)();
|
|
pinia =
|
|
// in test mode, ignore the argument provided as we can always retrieve a
|
|
// pinia instance with getActivePinia()
|
|
( false ? 0 : pinia) || (hasContext ? (0,vue_demi__WEBPACK_IMPORTED_MODULE_18__/* .inject */ .WQ)(piniaSymbol, null) : null);
|
|
if (pinia) setActivePinia(pinia);
|
|
if (false) {}
|
|
pinia = activePinia;
|
|
if (!pinia._s.has(id)) {
|
|
// creating the store registers it in `pinia._s`
|
|
if (isSetupStore) {
|
|
createSetupStore(id, setup, options, pinia);
|
|
} else {
|
|
createOptionsStore(id, options, pinia);
|
|
}
|
|
/* istanbul ignore else */
|
|
if (false) {}
|
|
}
|
|
const store = pinia._s.get(id);
|
|
if (false) {}
|
|
if (false) {}
|
|
// StoreGeneric cannot be casted towards Store
|
|
return store;
|
|
}
|
|
useStore.$id = id;
|
|
return useStore;
|
|
}
|
|
let mapStoreSuffix = 'Store';
|
|
/**
|
|
* Changes the suffix added by `mapStores()`. Can be set to an empty string.
|
|
* Defaults to `"Store"`. Make sure to extend the MapStoresCustomization
|
|
* interface if you are using TypeScript.
|
|
*
|
|
* @param suffix - new suffix
|
|
*/
|
|
function setMapStoreSuffix(suffix // could be 'Store' but that would be annoying for JS
|
|
) {
|
|
mapStoreSuffix = suffix;
|
|
}
|
|
/**
|
|
* Allows using stores without the composition API (`setup()`) by generating an
|
|
* object to be spread in the `computed` field of a component. It accepts a list
|
|
* of store definitions.
|
|
*
|
|
* @example
|
|
* ```js
|
|
* export default {
|
|
* computed: {
|
|
* // other computed properties
|
|
* ...mapStores(useUserStore, useCartStore)
|
|
* },
|
|
*
|
|
* created() {
|
|
* this.userStore // store with id "user"
|
|
* this.cartStore // store with id "cart"
|
|
* }
|
|
* }
|
|
* ```
|
|
*
|
|
* @param stores - list of stores to map to an object
|
|
*/
|
|
function mapStores(...stores) {
|
|
if (false) {}
|
|
return stores.reduce((reduced, useStore) => {
|
|
// @ts-expect-error: $id is added by defineStore
|
|
reduced[useStore.$id + mapStoreSuffix] = function () {
|
|
return useStore(this.$pinia);
|
|
};
|
|
return reduced;
|
|
}, {});
|
|
}
|
|
/**
|
|
* Allows using state and getters from one store without using the composition
|
|
* API (`setup()`) by generating an object to be spread in the `computed` field
|
|
* of a component.
|
|
*
|
|
* @param useStore - store to map from
|
|
* @param keysOrMapper - array or object
|
|
*/
|
|
function mapState(useStore, keysOrMapper) {
|
|
return Array.isArray(keysOrMapper) ? keysOrMapper.reduce((reduced, key) => {
|
|
reduced[key] = function () {
|
|
return useStore(this.$pinia)[key];
|
|
};
|
|
return reduced;
|
|
}, {}) : Object.keys(keysOrMapper).reduce((reduced, key) => {
|
|
// @ts-expect-error
|
|
reduced[key] = function () {
|
|
const store = useStore(this.$pinia);
|
|
const storeKey = keysOrMapper[key];
|
|
// for some reason TS is unable to infer the type of storeKey to be a
|
|
// function
|
|
return typeof storeKey === 'function' ? storeKey.call(this, store) : store[storeKey];
|
|
};
|
|
return reduced;
|
|
}, {});
|
|
}
|
|
/**
|
|
* Alias for `mapState()`. You should use `mapState()` instead.
|
|
* @deprecated use `mapState()` instead.
|
|
*/
|
|
const mapGetters = (/* unused pure expression or super */ null && (mapState));
|
|
/**
|
|
* Allows directly using actions from your store without using the composition
|
|
* API (`setup()`) by generating an object to be spread in the `methods` field
|
|
* of a component.
|
|
*
|
|
* @param useStore - store to map from
|
|
* @param keysOrMapper - array or object
|
|
*/
|
|
function mapActions(useStore, keysOrMapper) {
|
|
return Array.isArray(keysOrMapper) ? keysOrMapper.reduce((reduced, key) => {
|
|
// @ts-expect-error
|
|
reduced[key] = function (...args) {
|
|
return useStore(this.$pinia)[key](...args);
|
|
};
|
|
return reduced;
|
|
}, {}) : Object.keys(keysOrMapper).reduce((reduced, key) => {
|
|
// @ts-expect-error
|
|
reduced[key] = function (...args) {
|
|
return useStore(this.$pinia)[keysOrMapper[key]](...args);
|
|
};
|
|
return reduced;
|
|
}, {});
|
|
}
|
|
/**
|
|
* Allows using state and getters from one store without using the composition
|
|
* API (`setup()`) by generating an object to be spread in the `computed` field
|
|
* of a component.
|
|
*
|
|
* @param useStore - store to map from
|
|
* @param keysOrMapper - array or object
|
|
*/
|
|
function mapWritableState(useStore, keysOrMapper) {
|
|
return Array.isArray(keysOrMapper) ? keysOrMapper.reduce((reduced, key) => {
|
|
// @ts-ignore
|
|
reduced[key] = {
|
|
get() {
|
|
return useStore(this.$pinia)[key];
|
|
},
|
|
set(value) {
|
|
// it's easier to type it here as any
|
|
return useStore(this.$pinia)[key] = value;
|
|
}
|
|
};
|
|
return reduced;
|
|
}, {}) : Object.keys(keysOrMapper).reduce((reduced, key) => {
|
|
// @ts-ignore
|
|
reduced[key] = {
|
|
get() {
|
|
return useStore(this.$pinia)[keysOrMapper[key]];
|
|
},
|
|
set(value) {
|
|
// it's easier to type it here as any
|
|
return useStore(this.$pinia)[keysOrMapper[key]] = value;
|
|
}
|
|
};
|
|
return reduced;
|
|
}, {});
|
|
}
|
|
|
|
/**
|
|
* Creates an object of references with all the state, getters, and plugin-added
|
|
* state properties of the store. Similar to `toRefs()` but specifically
|
|
* designed for Pinia stores so methods and non reactive properties are
|
|
* completely ignored.
|
|
*
|
|
* @param store - store to extract the refs from
|
|
*/
|
|
function storeToRefs(store) {
|
|
// See https://github.com/vuejs/pinia/issues/852
|
|
// It's easier to just use toRefs() even if it includes more stuff
|
|
if (isVue2) {
|
|
// @ts-expect-error: toRefs include methods and others
|
|
return toRefs(store);
|
|
} else {
|
|
store = toRaw(store);
|
|
const refs = {};
|
|
for (const key in store) {
|
|
const value = store[key];
|
|
if (isRef(value) || isReactive(value)) {
|
|
// @ts-expect-error: the key is state or getter
|
|
refs[key] =
|
|
// ---
|
|
toRef(store, key);
|
|
}
|
|
}
|
|
return refs;
|
|
}
|
|
}
|
|
|
|
/**
|
|
* Vue 2 Plugin that must be installed for pinia to work. Note **you don't need
|
|
* this plugin if you are using Nuxt.js**. Use the `buildModule` instead:
|
|
* https://pinia.vuejs.org/ssr/nuxt.html.
|
|
*
|
|
* @example
|
|
* ```js
|
|
* import Vue from 'vue'
|
|
* import { PiniaVuePlugin, createPinia } from 'pinia'
|
|
*
|
|
* Vue.use(PiniaVuePlugin)
|
|
* const pinia = createPinia()
|
|
*
|
|
* new Vue({
|
|
* el: '#app',
|
|
* // ...
|
|
* pinia,
|
|
* })
|
|
* ```
|
|
*
|
|
* @param _Vue - `Vue` imported from 'vue'.
|
|
*/
|
|
const PiniaVuePlugin = function (_Vue) {
|
|
// Equivalent of
|
|
// app.config.globalProperties.$pinia = pinia
|
|
_Vue.mixin({
|
|
beforeCreate() {
|
|
const options = this.$options;
|
|
if (options.pinia) {
|
|
const pinia = options.pinia;
|
|
// HACK: taken from provide(): https://github.com/vuejs/composition-api/blob/main/src/apis/inject.ts#L31
|
|
/* istanbul ignore else */
|
|
if (!this._provided) {
|
|
const provideCache = {};
|
|
Object.defineProperty(this, '_provided', {
|
|
get: () => provideCache,
|
|
set: v => Object.assign(provideCache, v)
|
|
});
|
|
}
|
|
this._provided[piniaSymbol] = pinia;
|
|
// propagate the pinia instance in an SSR friendly way
|
|
// avoid adding it to nuxt twice
|
|
/* istanbul ignore else */
|
|
if (!this.$pinia) {
|
|
this.$pinia = pinia;
|
|
}
|
|
pinia._a = this;
|
|
if (IS_CLIENT) {
|
|
// this allows calling useStore() outside of a component setup after
|
|
// installing pinia's plugin
|
|
setActivePinia(pinia);
|
|
}
|
|
if (USE_DEVTOOLS) {
|
|
registerPiniaDevtools(pinia._a, pinia);
|
|
}
|
|
} else if (!this.$pinia && options.parent && options.parent.$pinia) {
|
|
this.$pinia = options.parent.$pinia;
|
|
}
|
|
},
|
|
destroyed() {
|
|
delete this._pStores;
|
|
}
|
|
});
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 9791:
|
|
/***/ (function(__unused_webpack_module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var $ = __webpack_require__(8155);
|
|
var call = __webpack_require__(4978);
|
|
var aCallable = __webpack_require__(8951);
|
|
var anObject = __webpack_require__(6696);
|
|
var getIteratorDirect = __webpack_require__(8764);
|
|
var getIteratorFlattenable = __webpack_require__(5319);
|
|
var createIteratorProxy = __webpack_require__(7254);
|
|
var iteratorClose = __webpack_require__(1298);
|
|
var IS_PURE = __webpack_require__(8072);
|
|
|
|
var IteratorProxy = createIteratorProxy(function () {
|
|
var iterator = this.iterator;
|
|
var mapper = this.mapper;
|
|
var result, inner;
|
|
|
|
while (true) {
|
|
if (inner = this.inner) try {
|
|
result = anObject(call(inner.next, inner.iterator));
|
|
if (!result.done) return result.value;
|
|
this.inner = null;
|
|
} catch (error) { iteratorClose(iterator, 'throw', error); }
|
|
|
|
result = anObject(call(this.next, iterator));
|
|
|
|
if (this.done = !!result.done) return;
|
|
|
|
try {
|
|
this.inner = getIteratorFlattenable(mapper(result.value, this.counter++), false);
|
|
} catch (error) { iteratorClose(iterator, 'throw', error); }
|
|
}
|
|
});
|
|
|
|
// `Iterator.prototype.flatMap` method
|
|
// https://github.com/tc39/proposal-iterator-helpers
|
|
$({ target: 'Iterator', proto: true, real: true, forced: IS_PURE }, {
|
|
flatMap: function flatMap(mapper) {
|
|
anObject(this);
|
|
aCallable(mapper);
|
|
return new IteratorProxy(getIteratorDirect(this), {
|
|
mapper: mapper,
|
|
inner: null
|
|
});
|
|
}
|
|
});
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 9818:
|
|
/***/ (function(__unused_webpack_module, __webpack_exports__, __webpack_require__) {
|
|
|
|
"use strict";
|
|
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
/* harmony export */ $3: function() { return /* binding */ hasOwn; },
|
|
/* harmony export */ $H: function() { return /* binding */ hasChanged; },
|
|
/* harmony export */ Bm: function() { return /* binding */ isSymbol; },
|
|
/* harmony export */ CE: function() { return /* binding */ isMap; },
|
|
/* harmony export */ Gv: function() { return /* binding */ isObject; },
|
|
/* harmony export */ MZ: function() { return /* binding */ EMPTY_OBJ; },
|
|
/* harmony export */ Qd: function() { return /* binding */ isPlainObject; },
|
|
/* harmony export */ TF: function() { return /* binding */ remove; },
|
|
/* harmony export */ Tn: function() { return /* binding */ isFunction; },
|
|
/* harmony export */ X$: function() { return /* binding */ extend; },
|
|
/* harmony export */ Zf: function() { return /* binding */ toRawType; },
|
|
/* harmony export */ cy: function() { return /* binding */ isArray; },
|
|
/* harmony export */ pD: function() { return /* binding */ makeMap; },
|
|
/* harmony export */ tE: function() { return /* binding */ NOOP; },
|
|
/* harmony export */ vM: function() { return /* binding */ isSet; },
|
|
/* harmony export */ yI: function() { return /* binding */ isIntegerKey; },
|
|
/* harmony export */ yQ: function() { return /* binding */ def; }
|
|
/* harmony export */ });
|
|
/* unused harmony exports EMPTY_ARR, NO, PatchFlagNames, PatchFlags, ShapeFlags, SlotFlags, camelize, capitalize, cssVarNameEscapeSymbolsRE, escapeHtml, escapeHtmlComment, genCacheKey, genPropsAccessExp, generateCodeFrame, getEscapedCssVarName, getGlobalThis, hyphenate, includeBooleanAttr, invokeArrayFns, isBooleanAttr, isBuiltInDirective, isDate, isGloballyAllowed, isGloballyWhitelisted, isHTMLTag, isKnownHtmlAttr, isKnownMathMLAttr, isKnownSvgAttr, isMathMLTag, isModelListener, isOn, isPromise, isRegExp, isRenderableAttrValue, isReservedProp, isSSRSafeAttrName, isSVGTag, isSpecialBooleanAttr, isString, isVoidTag, looseEqual, looseIndexOf, looseToNumber, normalizeClass, normalizeProps, normalizeStyle, objectToString, parseStringStyle, propsToAttrMap, slotFlagsText, stringifyStyle, toDisplayString, toHandlerKey, toNumber, toTypeString */
|
|
/* harmony import */ var core_js_modules_es_array_push_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(5513);
|
|
/* harmony import */ var core_js_modules_es_array_push_js__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es_array_push_js__WEBPACK_IMPORTED_MODULE_0__);
|
|
/* harmony import */ var core_js_modules_esnext_iterator_constructor_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(7195);
|
|
/* harmony import */ var core_js_modules_esnext_iterator_constructor_js__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_esnext_iterator_constructor_js__WEBPACK_IMPORTED_MODULE_1__);
|
|
/* harmony import */ var core_js_modules_esnext_iterator_filter_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(3741);
|
|
/* harmony import */ var core_js_modules_esnext_iterator_filter_js__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_esnext_iterator_filter_js__WEBPACK_IMPORTED_MODULE_2__);
|
|
/* harmony import */ var core_js_modules_esnext_iterator_for_each_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(680);
|
|
/* harmony import */ var core_js_modules_esnext_iterator_for_each_js__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_esnext_iterator_for_each_js__WEBPACK_IMPORTED_MODULE_3__);
|
|
/* harmony import */ var core_js_modules_esnext_iterator_map_js__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(793);
|
|
/* harmony import */ var core_js_modules_esnext_iterator_map_js__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_esnext_iterator_map_js__WEBPACK_IMPORTED_MODULE_4__);
|
|
/* harmony import */ var core_js_modules_esnext_iterator_reduce_js__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(5729);
|
|
/* harmony import */ var core_js_modules_esnext_iterator_reduce_js__WEBPACK_IMPORTED_MODULE_5___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_esnext_iterator_reduce_js__WEBPACK_IMPORTED_MODULE_5__);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
/**
|
|
* @vue/shared v3.5.13
|
|
* (c) 2018-present Yuxi (Evan) You and Vue contributors
|
|
* @license MIT
|
|
**/
|
|
/*! #__NO_SIDE_EFFECTS__ */
|
|
// @__NO_SIDE_EFFECTS__
|
|
function makeMap(str) {
|
|
const map = /* @__PURE__ */Object.create(null);
|
|
for (const key of str.split(",")) map[key] = 1;
|
|
return val => val in map;
|
|
}
|
|
const EMPTY_OBJ = false ? 0 : {};
|
|
const EMPTY_ARR = false ? 0 : [];
|
|
const NOOP = () => {};
|
|
const NO = () => false;
|
|
const isOn = key => key.charCodeAt(0) === 111 && key.charCodeAt(1) === 110 && (
|
|
// uppercase letter
|
|
key.charCodeAt(2) > 122 || key.charCodeAt(2) < 97);
|
|
const isModelListener = key => key.startsWith("onUpdate:");
|
|
const extend = Object.assign;
|
|
const remove = (arr, el) => {
|
|
const i = arr.indexOf(el);
|
|
if (i > -1) {
|
|
arr.splice(i, 1);
|
|
}
|
|
};
|
|
const hasOwnProperty = Object.prototype.hasOwnProperty;
|
|
const hasOwn = (val, key) => hasOwnProperty.call(val, key);
|
|
const isArray = Array.isArray;
|
|
const isMap = val => toTypeString(val) === "[object Map]";
|
|
const isSet = val => toTypeString(val) === "[object Set]";
|
|
const isDate = val => toTypeString(val) === "[object Date]";
|
|
const isRegExp = val => toTypeString(val) === "[object RegExp]";
|
|
const isFunction = val => typeof val === "function";
|
|
const isString = val => typeof val === "string";
|
|
const isSymbol = val => typeof val === "symbol";
|
|
const isObject = val => val !== null && typeof val === "object";
|
|
const isPromise = val => {
|
|
return (isObject(val) || isFunction(val)) && isFunction(val.then) && isFunction(val.catch);
|
|
};
|
|
const objectToString = Object.prototype.toString;
|
|
const toTypeString = value => objectToString.call(value);
|
|
const toRawType = value => {
|
|
return toTypeString(value).slice(8, -1);
|
|
};
|
|
const isPlainObject = val => toTypeString(val) === "[object Object]";
|
|
const isIntegerKey = key => isString(key) && key !== "NaN" && key[0] !== "-" && "" + parseInt(key, 10) === key;
|
|
const isReservedProp = /* @__PURE__ */(/* unused pure expression or super */ null && (makeMap(
|
|
// the leading comma is intentional so empty string "" is also included
|
|
",key,ref,ref_for,ref_key,onVnodeBeforeMount,onVnodeMounted,onVnodeBeforeUpdate,onVnodeUpdated,onVnodeBeforeUnmount,onVnodeUnmounted")));
|
|
const isBuiltInDirective = /* @__PURE__ */(/* unused pure expression or super */ null && (makeMap("bind,cloak,else-if,else,for,html,if,model,on,once,pre,show,slot,text,memo")));
|
|
const cacheStringFunction = fn => {
|
|
const cache = /* @__PURE__ */Object.create(null);
|
|
return str => {
|
|
const hit = cache[str];
|
|
return hit || (cache[str] = fn(str));
|
|
};
|
|
};
|
|
const camelizeRE = /-(\w)/g;
|
|
const camelize = cacheStringFunction(str => {
|
|
return str.replace(camelizeRE, (_, c) => c ? c.toUpperCase() : "");
|
|
});
|
|
const hyphenateRE = /\B([A-Z])/g;
|
|
const hyphenate = cacheStringFunction(str => str.replace(hyphenateRE, "-$1").toLowerCase());
|
|
const capitalize = cacheStringFunction(str => {
|
|
return str.charAt(0).toUpperCase() + str.slice(1);
|
|
});
|
|
const toHandlerKey = cacheStringFunction(str => {
|
|
const s = str ? `on${capitalize(str)}` : ``;
|
|
return s;
|
|
});
|
|
const hasChanged = (value, oldValue) => !Object.is(value, oldValue);
|
|
const invokeArrayFns = (fns, ...arg) => {
|
|
for (let i = 0; i < fns.length; i++) {
|
|
fns[i](...arg);
|
|
}
|
|
};
|
|
const def = (obj, key, value, writable = false) => {
|
|
Object.defineProperty(obj, key, {
|
|
configurable: true,
|
|
enumerable: false,
|
|
writable,
|
|
value
|
|
});
|
|
};
|
|
const looseToNumber = val => {
|
|
const n = parseFloat(val);
|
|
return isNaN(n) ? val : n;
|
|
};
|
|
const toNumber = val => {
|
|
const n = isString(val) ? Number(val) : NaN;
|
|
return isNaN(n) ? val : n;
|
|
};
|
|
let _globalThis;
|
|
const getGlobalThis = () => {
|
|
return _globalThis || (_globalThis = typeof globalThis !== "undefined" ? globalThis : typeof self !== "undefined" ? self : typeof window !== "undefined" ? window : typeof __webpack_require__.g !== "undefined" ? __webpack_require__.g : {});
|
|
};
|
|
const identRE = /^[_$a-zA-Z\xA0-\uFFFF][_$a-zA-Z0-9\xA0-\uFFFF]*$/;
|
|
function genPropsAccessExp(name) {
|
|
return identRE.test(name) ? `__props.${name}` : `__props[${JSON.stringify(name)}]`;
|
|
}
|
|
function genCacheKey(source, options) {
|
|
return source + JSON.stringify(options, (_, val) => typeof val === "function" ? val.toString() : val);
|
|
}
|
|
const PatchFlags = {
|
|
"TEXT": 1,
|
|
"1": "TEXT",
|
|
"CLASS": 2,
|
|
"2": "CLASS",
|
|
"STYLE": 4,
|
|
"4": "STYLE",
|
|
"PROPS": 8,
|
|
"8": "PROPS",
|
|
"FULL_PROPS": 16,
|
|
"16": "FULL_PROPS",
|
|
"NEED_HYDRATION": 32,
|
|
"32": "NEED_HYDRATION",
|
|
"STABLE_FRAGMENT": 64,
|
|
"64": "STABLE_FRAGMENT",
|
|
"KEYED_FRAGMENT": 128,
|
|
"128": "KEYED_FRAGMENT",
|
|
"UNKEYED_FRAGMENT": 256,
|
|
"256": "UNKEYED_FRAGMENT",
|
|
"NEED_PATCH": 512,
|
|
"512": "NEED_PATCH",
|
|
"DYNAMIC_SLOTS": 1024,
|
|
"1024": "DYNAMIC_SLOTS",
|
|
"DEV_ROOT_FRAGMENT": 2048,
|
|
"2048": "DEV_ROOT_FRAGMENT",
|
|
"CACHED": -1,
|
|
"-1": "CACHED",
|
|
"BAIL": -2,
|
|
"-2": "BAIL"
|
|
};
|
|
const PatchFlagNames = {
|
|
[1]: `TEXT`,
|
|
[2]: `CLASS`,
|
|
[4]: `STYLE`,
|
|
[8]: `PROPS`,
|
|
[16]: `FULL_PROPS`,
|
|
[32]: `NEED_HYDRATION`,
|
|
[64]: `STABLE_FRAGMENT`,
|
|
[128]: `KEYED_FRAGMENT`,
|
|
[256]: `UNKEYED_FRAGMENT`,
|
|
[512]: `NEED_PATCH`,
|
|
[1024]: `DYNAMIC_SLOTS`,
|
|
[2048]: `DEV_ROOT_FRAGMENT`,
|
|
[-1]: `HOISTED`,
|
|
[-2]: `BAIL`
|
|
};
|
|
const ShapeFlags = {
|
|
"ELEMENT": 1,
|
|
"1": "ELEMENT",
|
|
"FUNCTIONAL_COMPONENT": 2,
|
|
"2": "FUNCTIONAL_COMPONENT",
|
|
"STATEFUL_COMPONENT": 4,
|
|
"4": "STATEFUL_COMPONENT",
|
|
"TEXT_CHILDREN": 8,
|
|
"8": "TEXT_CHILDREN",
|
|
"ARRAY_CHILDREN": 16,
|
|
"16": "ARRAY_CHILDREN",
|
|
"SLOTS_CHILDREN": 32,
|
|
"32": "SLOTS_CHILDREN",
|
|
"TELEPORT": 64,
|
|
"64": "TELEPORT",
|
|
"SUSPENSE": 128,
|
|
"128": "SUSPENSE",
|
|
"COMPONENT_SHOULD_KEEP_ALIVE": 256,
|
|
"256": "COMPONENT_SHOULD_KEEP_ALIVE",
|
|
"COMPONENT_KEPT_ALIVE": 512,
|
|
"512": "COMPONENT_KEPT_ALIVE",
|
|
"COMPONENT": 6,
|
|
"6": "COMPONENT"
|
|
};
|
|
const SlotFlags = {
|
|
"STABLE": 1,
|
|
"1": "STABLE",
|
|
"DYNAMIC": 2,
|
|
"2": "DYNAMIC",
|
|
"FORWARDED": 3,
|
|
"3": "FORWARDED"
|
|
};
|
|
const slotFlagsText = {
|
|
[1]: "STABLE",
|
|
[2]: "DYNAMIC",
|
|
[3]: "FORWARDED"
|
|
};
|
|
const GLOBALS_ALLOWED = "Infinity,undefined,NaN,isFinite,isNaN,parseFloat,parseInt,decodeURI,decodeURIComponent,encodeURI,encodeURIComponent,Math,Number,Date,Array,Object,Boolean,String,RegExp,Map,Set,JSON,Intl,BigInt,console,Error,Symbol";
|
|
const isGloballyAllowed = /* @__PURE__ */(/* unused pure expression or super */ null && (makeMap(GLOBALS_ALLOWED)));
|
|
const isGloballyWhitelisted = (/* unused pure expression or super */ null && (isGloballyAllowed));
|
|
const range = 2;
|
|
function generateCodeFrame(source, start = 0, end = source.length) {
|
|
start = Math.max(0, Math.min(start, source.length));
|
|
end = Math.max(0, Math.min(end, source.length));
|
|
if (start > end) return "";
|
|
let lines = source.split(/(\r?\n)/);
|
|
const newlineSequences = lines.filter((_, idx) => idx % 2 === 1);
|
|
lines = lines.filter((_, idx) => idx % 2 === 0);
|
|
let count = 0;
|
|
const res = [];
|
|
for (let i = 0; i < lines.length; i++) {
|
|
count += lines[i].length + (newlineSequences[i] && newlineSequences[i].length || 0);
|
|
if (count >= start) {
|
|
for (let j = i - range; j <= i + range || end > count; j++) {
|
|
if (j < 0 || j >= lines.length) continue;
|
|
const line = j + 1;
|
|
res.push(`${line}${" ".repeat(Math.max(3 - String(line).length, 0))}| ${lines[j]}`);
|
|
const lineLength = lines[j].length;
|
|
const newLineSeqLength = newlineSequences[j] && newlineSequences[j].length || 0;
|
|
if (j === i) {
|
|
const pad = start - (count - (lineLength + newLineSeqLength));
|
|
const length = Math.max(1, end > count ? lineLength - pad : end - start);
|
|
res.push(` | ` + " ".repeat(pad) + "^".repeat(length));
|
|
} else if (j > i) {
|
|
if (end > count) {
|
|
const length = Math.max(Math.min(end - count, lineLength), 1);
|
|
res.push(` | ` + "^".repeat(length));
|
|
}
|
|
count += lineLength + newLineSeqLength;
|
|
}
|
|
}
|
|
break;
|
|
}
|
|
}
|
|
return res.join("\n");
|
|
}
|
|
function normalizeStyle(value) {
|
|
if (isArray(value)) {
|
|
const res = {};
|
|
for (let i = 0; i < value.length; i++) {
|
|
const item = value[i];
|
|
const normalized = isString(item) ? parseStringStyle(item) : normalizeStyle(item);
|
|
if (normalized) {
|
|
for (const key in normalized) {
|
|
res[key] = normalized[key];
|
|
}
|
|
}
|
|
}
|
|
return res;
|
|
} else if (isString(value) || isObject(value)) {
|
|
return value;
|
|
}
|
|
}
|
|
const listDelimiterRE = /;(?![^(]*\))/g;
|
|
const propertyDelimiterRE = /:([^]+)/;
|
|
const styleCommentRE = /\/\*[^]*?\*\//g;
|
|
function parseStringStyle(cssText) {
|
|
const ret = {};
|
|
cssText.replace(styleCommentRE, "").split(listDelimiterRE).forEach(item => {
|
|
if (item) {
|
|
const tmp = item.split(propertyDelimiterRE);
|
|
tmp.length > 1 && (ret[tmp[0].trim()] = tmp[1].trim());
|
|
}
|
|
});
|
|
return ret;
|
|
}
|
|
function stringifyStyle(styles) {
|
|
if (!styles) return "";
|
|
if (isString(styles)) return styles;
|
|
let ret = "";
|
|
for (const key in styles) {
|
|
const value = styles[key];
|
|
if (isString(value) || typeof value === "number") {
|
|
const normalizedKey = key.startsWith(`--`) ? key : hyphenate(key);
|
|
ret += `${normalizedKey}:${value};`;
|
|
}
|
|
}
|
|
return ret;
|
|
}
|
|
function normalizeClass(value) {
|
|
let res = "";
|
|
if (isString(value)) {
|
|
res = value;
|
|
} else if (isArray(value)) {
|
|
for (let i = 0; i < value.length; i++) {
|
|
const normalized = normalizeClass(value[i]);
|
|
if (normalized) {
|
|
res += normalized + " ";
|
|
}
|
|
}
|
|
} else if (isObject(value)) {
|
|
for (const name in value) {
|
|
if (value[name]) {
|
|
res += name + " ";
|
|
}
|
|
}
|
|
}
|
|
return res.trim();
|
|
}
|
|
function normalizeProps(props) {
|
|
if (!props) return null;
|
|
let {
|
|
class: klass,
|
|
style
|
|
} = props;
|
|
if (klass && !isString(klass)) {
|
|
props.class = normalizeClass(klass);
|
|
}
|
|
if (style) {
|
|
props.style = normalizeStyle(style);
|
|
}
|
|
return props;
|
|
}
|
|
const HTML_TAGS = "html,body,base,head,link,meta,style,title,address,article,aside,footer,header,hgroup,h1,h2,h3,h4,h5,h6,nav,section,div,dd,dl,dt,figcaption,figure,picture,hr,img,li,main,ol,p,pre,ul,a,b,abbr,bdi,bdo,br,cite,code,data,dfn,em,i,kbd,mark,q,rp,rt,ruby,s,samp,small,span,strong,sub,sup,time,u,var,wbr,area,audio,map,track,video,embed,object,param,source,canvas,script,noscript,del,ins,caption,col,colgroup,table,thead,tbody,td,th,tr,button,datalist,fieldset,form,input,label,legend,meter,optgroup,option,output,progress,select,textarea,details,dialog,menu,summary,template,blockquote,iframe,tfoot";
|
|
const SVG_TAGS = "svg,animate,animateMotion,animateTransform,circle,clipPath,color-profile,defs,desc,discard,ellipse,feBlend,feColorMatrix,feComponentTransfer,feComposite,feConvolveMatrix,feDiffuseLighting,feDisplacementMap,feDistantLight,feDropShadow,feFlood,feFuncA,feFuncB,feFuncG,feFuncR,feGaussianBlur,feImage,feMerge,feMergeNode,feMorphology,feOffset,fePointLight,feSpecularLighting,feSpotLight,feTile,feTurbulence,filter,foreignObject,g,hatch,hatchpath,image,line,linearGradient,marker,mask,mesh,meshgradient,meshpatch,meshrow,metadata,mpath,path,pattern,polygon,polyline,radialGradient,rect,set,solidcolor,stop,switch,symbol,text,textPath,title,tspan,unknown,use,view";
|
|
const MATH_TAGS = "annotation,annotation-xml,maction,maligngroup,malignmark,math,menclose,merror,mfenced,mfrac,mfraction,mglyph,mi,mlabeledtr,mlongdiv,mmultiscripts,mn,mo,mover,mpadded,mphantom,mprescripts,mroot,mrow,ms,mscarries,mscarry,msgroup,msline,mspace,msqrt,msrow,mstack,mstyle,msub,msubsup,msup,mtable,mtd,mtext,mtr,munder,munderover,none,semantics";
|
|
const VOID_TAGS = "area,base,br,col,embed,hr,img,input,link,meta,param,source,track,wbr";
|
|
const isHTMLTag = /* @__PURE__ */(/* unused pure expression or super */ null && (makeMap(HTML_TAGS)));
|
|
const isSVGTag = /* @__PURE__ */(/* unused pure expression or super */ null && (makeMap(SVG_TAGS)));
|
|
const isMathMLTag = /* @__PURE__ */(/* unused pure expression or super */ null && (makeMap(MATH_TAGS)));
|
|
const isVoidTag = /* @__PURE__ */(/* unused pure expression or super */ null && (makeMap(VOID_TAGS)));
|
|
const specialBooleanAttrs = `itemscope,allowfullscreen,formnovalidate,ismap,nomodule,novalidate,readonly`;
|
|
const isSpecialBooleanAttr = /* @__PURE__ */(/* unused pure expression or super */ null && (makeMap(specialBooleanAttrs)));
|
|
const isBooleanAttr = /* @__PURE__ */makeMap(specialBooleanAttrs + `,async,autofocus,autoplay,controls,default,defer,disabled,hidden,inert,loop,open,required,reversed,scoped,seamless,checked,muted,multiple,selected`);
|
|
function includeBooleanAttr(value) {
|
|
return !!value || value === "";
|
|
}
|
|
const unsafeAttrCharRE = /[>/="'\u0009\u000a\u000c\u0020]/;
|
|
const attrValidationCache = {};
|
|
function isSSRSafeAttrName(name) {
|
|
if (attrValidationCache.hasOwnProperty(name)) {
|
|
return attrValidationCache[name];
|
|
}
|
|
const isUnsafe = unsafeAttrCharRE.test(name);
|
|
if (isUnsafe) {
|
|
console.error(`unsafe attribute name: ${name}`);
|
|
}
|
|
return attrValidationCache[name] = !isUnsafe;
|
|
}
|
|
const propsToAttrMap = {
|
|
acceptCharset: "accept-charset",
|
|
className: "class",
|
|
htmlFor: "for",
|
|
httpEquiv: "http-equiv"
|
|
};
|
|
const isKnownHtmlAttr = /* @__PURE__ */(/* unused pure expression or super */ null && (makeMap(`accept,accept-charset,accesskey,action,align,allow,alt,async,autocapitalize,autocomplete,autofocus,autoplay,background,bgcolor,border,buffered,capture,challenge,charset,checked,cite,class,code,codebase,color,cols,colspan,content,contenteditable,contextmenu,controls,coords,crossorigin,csp,data,datetime,decoding,default,defer,dir,dirname,disabled,download,draggable,dropzone,enctype,enterkeyhint,for,form,formaction,formenctype,formmethod,formnovalidate,formtarget,headers,height,hidden,high,href,hreflang,http-equiv,icon,id,importance,inert,integrity,ismap,itemprop,keytype,kind,label,lang,language,loading,list,loop,low,manifest,max,maxlength,minlength,media,min,multiple,muted,name,novalidate,open,optimum,pattern,ping,placeholder,poster,preload,radiogroup,readonly,referrerpolicy,rel,required,reversed,rows,rowspan,sandbox,scope,scoped,selected,shape,size,sizes,slot,span,spellcheck,src,srcdoc,srclang,srcset,start,step,style,summary,tabindex,target,title,translate,type,usemap,value,width,wrap`)));
|
|
const isKnownSvgAttr = /* @__PURE__ */(/* unused pure expression or super */ null && (makeMap(`xmlns,accent-height,accumulate,additive,alignment-baseline,alphabetic,amplitude,arabic-form,ascent,attributeName,attributeType,azimuth,baseFrequency,baseline-shift,baseProfile,bbox,begin,bias,by,calcMode,cap-height,class,clip,clipPathUnits,clip-path,clip-rule,color,color-interpolation,color-interpolation-filters,color-profile,color-rendering,contentScriptType,contentStyleType,crossorigin,cursor,cx,cy,d,decelerate,descent,diffuseConstant,direction,display,divisor,dominant-baseline,dur,dx,dy,edgeMode,elevation,enable-background,end,exponent,fill,fill-opacity,fill-rule,filter,filterRes,filterUnits,flood-color,flood-opacity,font-family,font-size,font-size-adjust,font-stretch,font-style,font-variant,font-weight,format,from,fr,fx,fy,g1,g2,glyph-name,glyph-orientation-horizontal,glyph-orientation-vertical,glyphRef,gradientTransform,gradientUnits,hanging,height,href,hreflang,horiz-adv-x,horiz-origin-x,id,ideographic,image-rendering,in,in2,intercept,k,k1,k2,k3,k4,kernelMatrix,kernelUnitLength,kerning,keyPoints,keySplines,keyTimes,lang,lengthAdjust,letter-spacing,lighting-color,limitingConeAngle,local,marker-end,marker-mid,marker-start,markerHeight,markerUnits,markerWidth,mask,maskContentUnits,maskUnits,mathematical,max,media,method,min,mode,name,numOctaves,offset,opacity,operator,order,orient,orientation,origin,overflow,overline-position,overline-thickness,panose-1,paint-order,path,pathLength,patternContentUnits,patternTransform,patternUnits,ping,pointer-events,points,pointsAtX,pointsAtY,pointsAtZ,preserveAlpha,preserveAspectRatio,primitiveUnits,r,radius,referrerPolicy,refX,refY,rel,rendering-intent,repeatCount,repeatDur,requiredExtensions,requiredFeatures,restart,result,rotate,rx,ry,scale,seed,shape-rendering,slope,spacing,specularConstant,specularExponent,speed,spreadMethod,startOffset,stdDeviation,stemh,stemv,stitchTiles,stop-color,stop-opacity,strikethrough-position,strikethrough-thickness,string,stroke,stroke-dasharray,stroke-dashoffset,stroke-linecap,stroke-linejoin,stroke-miterlimit,stroke-opacity,stroke-width,style,surfaceScale,systemLanguage,tabindex,tableValues,target,targetX,targetY,text-anchor,text-decoration,text-rendering,textLength,to,transform,transform-origin,type,u1,u2,underline-position,underline-thickness,unicode,unicode-bidi,unicode-range,units-per-em,v-alphabetic,v-hanging,v-ideographic,v-mathematical,values,vector-effect,version,vert-adv-y,vert-origin-x,vert-origin-y,viewBox,viewTarget,visibility,width,widths,word-spacing,writing-mode,x,x-height,x1,x2,xChannelSelector,xlink:actuate,xlink:arcrole,xlink:href,xlink:role,xlink:show,xlink:title,xlink:type,xmlns:xlink,xml:base,xml:lang,xml:space,y,y1,y2,yChannelSelector,z,zoomAndPan`)));
|
|
const isKnownMathMLAttr = /* @__PURE__ */(/* unused pure expression or super */ null && (makeMap(`accent,accentunder,actiontype,align,alignmentscope,altimg,altimg-height,altimg-valign,altimg-width,alttext,bevelled,close,columnsalign,columnlines,columnspan,denomalign,depth,dir,display,displaystyle,encoding,equalcolumns,equalrows,fence,fontstyle,fontweight,form,frame,framespacing,groupalign,height,href,id,indentalign,indentalignfirst,indentalignlast,indentshift,indentshiftfirst,indentshiftlast,indextype,justify,largetop,largeop,lquote,lspace,mathbackground,mathcolor,mathsize,mathvariant,maxsize,minlabelspacing,mode,other,overflow,position,rowalign,rowlines,rowspan,rquote,rspace,scriptlevel,scriptminsize,scriptsizemultiplier,selection,separator,separators,shift,side,src,stackalign,stretchy,subscriptshift,superscriptshift,symmetric,voffset,width,widths,xlink:href,xlink:show,xlink:type,xmlns`)));
|
|
function isRenderableAttrValue(value) {
|
|
if (value == null) {
|
|
return false;
|
|
}
|
|
const type = typeof value;
|
|
return type === "string" || type === "number" || type === "boolean";
|
|
}
|
|
const escapeRE = /["'&<>]/;
|
|
function escapeHtml(string) {
|
|
const str = "" + string;
|
|
const match = escapeRE.exec(str);
|
|
if (!match) {
|
|
return str;
|
|
}
|
|
let html = "";
|
|
let escaped;
|
|
let index;
|
|
let lastIndex = 0;
|
|
for (index = match.index; index < str.length; index++) {
|
|
switch (str.charCodeAt(index)) {
|
|
case 34:
|
|
escaped = """;
|
|
break;
|
|
case 38:
|
|
escaped = "&";
|
|
break;
|
|
case 39:
|
|
escaped = "'";
|
|
break;
|
|
case 60:
|
|
escaped = "<";
|
|
break;
|
|
case 62:
|
|
escaped = ">";
|
|
break;
|
|
default:
|
|
continue;
|
|
}
|
|
if (lastIndex !== index) {
|
|
html += str.slice(lastIndex, index);
|
|
}
|
|
lastIndex = index + 1;
|
|
html += escaped;
|
|
}
|
|
return lastIndex !== index ? html + str.slice(lastIndex, index) : html;
|
|
}
|
|
const commentStripRE = /^-?>|<!--|-->|--!>|<!-$/g;
|
|
function escapeHtmlComment(src) {
|
|
return src.replace(commentStripRE, "");
|
|
}
|
|
const cssVarNameEscapeSymbolsRE = /[ !"#$%&'()*+,./:;<=>?@[\\\]^`{|}~]/g;
|
|
function getEscapedCssVarName(key, doubleEscape) {
|
|
return key.replace(cssVarNameEscapeSymbolsRE, s => doubleEscape ? s === '"' ? '\\\\\\"' : `\\\\${s}` : `\\${s}`);
|
|
}
|
|
function looseCompareArrays(a, b) {
|
|
if (a.length !== b.length) return false;
|
|
let equal = true;
|
|
for (let i = 0; equal && i < a.length; i++) {
|
|
equal = looseEqual(a[i], b[i]);
|
|
}
|
|
return equal;
|
|
}
|
|
function looseEqual(a, b) {
|
|
if (a === b) return true;
|
|
let aValidType = isDate(a);
|
|
let bValidType = isDate(b);
|
|
if (aValidType || bValidType) {
|
|
return aValidType && bValidType ? a.getTime() === b.getTime() : false;
|
|
}
|
|
aValidType = isSymbol(a);
|
|
bValidType = isSymbol(b);
|
|
if (aValidType || bValidType) {
|
|
return a === b;
|
|
}
|
|
aValidType = isArray(a);
|
|
bValidType = isArray(b);
|
|
if (aValidType || bValidType) {
|
|
return aValidType && bValidType ? looseCompareArrays(a, b) : false;
|
|
}
|
|
aValidType = isObject(a);
|
|
bValidType = isObject(b);
|
|
if (aValidType || bValidType) {
|
|
if (!aValidType || !bValidType) {
|
|
return false;
|
|
}
|
|
const aKeysCount = Object.keys(a).length;
|
|
const bKeysCount = Object.keys(b).length;
|
|
if (aKeysCount !== bKeysCount) {
|
|
return false;
|
|
}
|
|
for (const key in a) {
|
|
const aHasKey = a.hasOwnProperty(key);
|
|
const bHasKey = b.hasOwnProperty(key);
|
|
if (aHasKey && !bHasKey || !aHasKey && bHasKey || !looseEqual(a[key], b[key])) {
|
|
return false;
|
|
}
|
|
}
|
|
}
|
|
return String(a) === String(b);
|
|
}
|
|
function looseIndexOf(arr, val) {
|
|
return arr.findIndex(item => looseEqual(item, val));
|
|
}
|
|
const isRef = val => {
|
|
return !!(val && val["__v_isRef"] === true);
|
|
};
|
|
const toDisplayString = val => {
|
|
return isString(val) ? val : val == null ? "" : isArray(val) || isObject(val) && (val.toString === objectToString || !isFunction(val.toString)) ? isRef(val) ? toDisplayString(val.value) : JSON.stringify(val, replacer, 2) : String(val);
|
|
};
|
|
const replacer = (_key, val) => {
|
|
if (isRef(val)) {
|
|
return replacer(_key, val.value);
|
|
} else if (isMap(val)) {
|
|
return {
|
|
[`Map(${val.size})`]: [...val.entries()].reduce((entries, [key, val2], i) => {
|
|
entries[stringifySymbol(key, i) + " =>"] = val2;
|
|
return entries;
|
|
}, {})
|
|
};
|
|
} else if (isSet(val)) {
|
|
return {
|
|
[`Set(${val.size})`]: [...val.values()].map(v => stringifySymbol(v))
|
|
};
|
|
} else if (isSymbol(val)) {
|
|
return stringifySymbol(val);
|
|
} else if (isObject(val) && !isArray(val) && !isPlainObject(val)) {
|
|
return String(val);
|
|
}
|
|
return val;
|
|
};
|
|
const stringifySymbol = (v, i = "") => {
|
|
var _a;
|
|
return (
|
|
// Symbol.description in es2019+ so we need to cast here to pass
|
|
// the lib: es2016 check
|
|
isSymbol(v) ? `Symbol(${(_a = v.description) != null ? _a : i})` : v
|
|
);
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 9821:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var call = __webpack_require__(4978);
|
|
var isCallable = __webpack_require__(6450);
|
|
var isObject = __webpack_require__(1909);
|
|
|
|
var $TypeError = TypeError;
|
|
|
|
// `OrdinaryToPrimitive` abstract operation
|
|
// https://tc39.es/ecma262/#sec-ordinarytoprimitive
|
|
module.exports = function (input, pref) {
|
|
var fn, val;
|
|
if (pref === 'string' && isCallable(fn = input.toString) && !isObject(val = call(fn, input))) return val;
|
|
if (isCallable(fn = input.valueOf) && !isObject(val = call(fn, input))) return val;
|
|
if (pref !== 'string' && isCallable(fn = input.toString) && !isObject(val = call(fn, input))) return val;
|
|
throw new $TypeError("Can't convert object to primitive value");
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 9830:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var classof = __webpack_require__(4804);
|
|
|
|
module.exports = function (it) {
|
|
var klass = classof(it);
|
|
return klass === 'BigInt64Array' || klass === 'BigUint64Array';
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 9864:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var classof = __webpack_require__(4804);
|
|
|
|
var $String = String;
|
|
|
|
module.exports = function (argument) {
|
|
if (classof(argument) === 'Symbol') throw new TypeError('Cannot convert a Symbol value to a string');
|
|
return $String(argument);
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 9868:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
var NATIVE_WEAK_MAP = __webpack_require__(8271);
|
|
var global = __webpack_require__(4074);
|
|
var isObject = __webpack_require__(1909);
|
|
var createNonEnumerableProperty = __webpack_require__(5266);
|
|
var hasOwn = __webpack_require__(1396);
|
|
var shared = __webpack_require__(4568);
|
|
var sharedKey = __webpack_require__(2370);
|
|
var hiddenKeys = __webpack_require__(4858);
|
|
|
|
var OBJECT_ALREADY_INITIALIZED = 'Object already initialized';
|
|
var TypeError = global.TypeError;
|
|
var WeakMap = global.WeakMap;
|
|
var set, get, has;
|
|
|
|
var enforce = function (it) {
|
|
return has(it) ? get(it) : set(it, {});
|
|
};
|
|
|
|
var getterFor = function (TYPE) {
|
|
return function (it) {
|
|
var state;
|
|
if (!isObject(it) || (state = get(it)).type !== TYPE) {
|
|
throw new TypeError('Incompatible receiver, ' + TYPE + ' required');
|
|
} return state;
|
|
};
|
|
};
|
|
|
|
if (NATIVE_WEAK_MAP || shared.state) {
|
|
var store = shared.state || (shared.state = new WeakMap());
|
|
/* eslint-disable no-self-assign -- prototype methods protection */
|
|
store.get = store.get;
|
|
store.has = store.has;
|
|
store.set = store.set;
|
|
/* eslint-enable no-self-assign -- prototype methods protection */
|
|
set = function (it, metadata) {
|
|
if (store.has(it)) throw new TypeError(OBJECT_ALREADY_INITIALIZED);
|
|
metadata.facade = it;
|
|
store.set(it, metadata);
|
|
return metadata;
|
|
};
|
|
get = function (it) {
|
|
return store.get(it) || {};
|
|
};
|
|
has = function (it) {
|
|
return store.has(it);
|
|
};
|
|
} else {
|
|
var STATE = sharedKey('state');
|
|
hiddenKeys[STATE] = true;
|
|
set = function (it, metadata) {
|
|
if (hasOwn(it, STATE)) throw new TypeError(OBJECT_ALREADY_INITIALIZED);
|
|
metadata.facade = it;
|
|
createNonEnumerableProperty(it, STATE, metadata);
|
|
return metadata;
|
|
};
|
|
get = function (it) {
|
|
return hasOwn(it, STATE) ? it[STATE] : {};
|
|
};
|
|
has = function (it) {
|
|
return hasOwn(it, STATE);
|
|
};
|
|
}
|
|
|
|
module.exports = {
|
|
set: set,
|
|
get: get,
|
|
has: has,
|
|
enforce: enforce,
|
|
getterFor: getterFor
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 9891:
|
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
|
|
"use strict";
|
|
|
|
/* global ActiveXObject -- old IE, WSH */
|
|
var anObject = __webpack_require__(6696);
|
|
var definePropertiesModule = __webpack_require__(1252);
|
|
var enumBugKeys = __webpack_require__(448);
|
|
var hiddenKeys = __webpack_require__(4858);
|
|
var html = __webpack_require__(6968);
|
|
var documentCreateElement = __webpack_require__(2936);
|
|
var sharedKey = __webpack_require__(2370);
|
|
|
|
var GT = '>';
|
|
var LT = '<';
|
|
var PROTOTYPE = 'prototype';
|
|
var SCRIPT = 'script';
|
|
var IE_PROTO = sharedKey('IE_PROTO');
|
|
|
|
var EmptyConstructor = function () { /* empty */ };
|
|
|
|
var scriptTag = function (content) {
|
|
return LT + SCRIPT + GT + content + LT + '/' + SCRIPT + GT;
|
|
};
|
|
|
|
// Create object with fake `null` prototype: use ActiveX Object with cleared prototype
|
|
var NullProtoObjectViaActiveX = function (activeXDocument) {
|
|
activeXDocument.write(scriptTag(''));
|
|
activeXDocument.close();
|
|
var temp = activeXDocument.parentWindow.Object;
|
|
activeXDocument = null; // avoid memory leak
|
|
return temp;
|
|
};
|
|
|
|
// Create object with fake `null` prototype: use iframe Object with cleared prototype
|
|
var NullProtoObjectViaIFrame = function () {
|
|
// Thrash, waste and sodomy: IE GC bug
|
|
var iframe = documentCreateElement('iframe');
|
|
var JS = 'java' + SCRIPT + ':';
|
|
var iframeDocument;
|
|
iframe.style.display = 'none';
|
|
html.appendChild(iframe);
|
|
// https://github.com/zloirock/core-js/issues/475
|
|
iframe.src = String(JS);
|
|
iframeDocument = iframe.contentWindow.document;
|
|
iframeDocument.open();
|
|
iframeDocument.write(scriptTag('document.F=Object'));
|
|
iframeDocument.close();
|
|
return iframeDocument.F;
|
|
};
|
|
|
|
// Check for document.domain and active x support
|
|
// No need to use active x approach when document.domain is not set
|
|
// see https://github.com/es-shims/es5-shim/issues/150
|
|
// variation of https://github.com/kitcambridge/es5-shim/commit/4f738ac066346
|
|
// avoid IE GC bug
|
|
var activeXDocument;
|
|
var NullProtoObject = function () {
|
|
try {
|
|
activeXDocument = new ActiveXObject('htmlfile');
|
|
} catch (error) { /* ignore */ }
|
|
NullProtoObject = typeof document != 'undefined'
|
|
? document.domain && activeXDocument
|
|
? NullProtoObjectViaActiveX(activeXDocument) // old IE
|
|
: NullProtoObjectViaIFrame()
|
|
: NullProtoObjectViaActiveX(activeXDocument); // WSH
|
|
var length = enumBugKeys.length;
|
|
while (length--) delete NullProtoObject[PROTOTYPE][enumBugKeys[length]];
|
|
return NullProtoObject();
|
|
};
|
|
|
|
hiddenKeys[IE_PROTO] = true;
|
|
|
|
// `Object.create` method
|
|
// https://tc39.es/ecma262/#sec-object.create
|
|
// eslint-disable-next-line es/no-object-create -- safe
|
|
module.exports = Object.create || function create(O, Properties) {
|
|
var result;
|
|
if (O !== null) {
|
|
EmptyConstructor[PROTOTYPE] = anObject(O);
|
|
result = new EmptyConstructor();
|
|
EmptyConstructor[PROTOTYPE] = null;
|
|
// add "__proto__" for Object.getPrototypeOf polyfill
|
|
result[IE_PROTO] = O;
|
|
} else result = NullProtoObject();
|
|
return Properties === undefined ? result : definePropertiesModule.f(result, Properties);
|
|
};
|
|
|
|
|
|
/***/ }),
|
|
|
|
/***/ 9972:
|
|
/***/ (function(__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) {
|
|
|
|
"use strict";
|
|
/* harmony import */ var core_js_modules_es_array_push_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(5513);
|
|
/* harmony import */ var core_js_modules_esnext_iterator_constructor_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(7195);
|
|
/* harmony import */ var core_js_modules_esnext_iterator_for_each_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(680);
|
|
/* harmony import */ var _utils_js__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(5813);
|
|
/* harmony import */ var _helpers_buildURL_js__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(9541);
|
|
/* harmony import */ var _InterceptorManager_js__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(1694);
|
|
/* harmony import */ var _dispatchRequest_js__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(8069);
|
|
/* harmony import */ var _mergeConfig_js__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(308);
|
|
/* harmony import */ var _buildFullPath_js__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(9008);
|
|
/* harmony import */ var _helpers_validator_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(4);
|
|
/* harmony import */ var _AxiosHeaders_js__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(292);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
const validators = _helpers_validator_js__WEBPACK_IMPORTED_MODULE_3__/* ["default"] */ .A.validators;
|
|
|
|
/**
|
|
* Create a new instance of Axios
|
|
*
|
|
* @param {Object} instanceConfig The default config for the instance
|
|
*
|
|
* @return {Axios} A new instance of Axios
|
|
*/
|
|
class Axios {
|
|
constructor(instanceConfig) {
|
|
this.defaults = instanceConfig;
|
|
this.interceptors = {
|
|
request: new _InterceptorManager_js__WEBPACK_IMPORTED_MODULE_4__/* ["default"] */ .A(),
|
|
response: new _InterceptorManager_js__WEBPACK_IMPORTED_MODULE_4__/* ["default"] */ .A()
|
|
};
|
|
}
|
|
|
|
/**
|
|
* Dispatch a request
|
|
*
|
|
* @param {String|Object} configOrUrl The config specific for this request (merged with this.defaults)
|
|
* @param {?Object} config
|
|
*
|
|
* @returns {Promise} The Promise to be fulfilled
|
|
*/
|
|
async request(configOrUrl, config) {
|
|
try {
|
|
return await this._request(configOrUrl, config);
|
|
} catch (err) {
|
|
if (err instanceof Error) {
|
|
let dummy;
|
|
Error.captureStackTrace ? Error.captureStackTrace(dummy = {}) : dummy = new Error();
|
|
|
|
// slice off the Error: ... line
|
|
const stack = dummy.stack ? dummy.stack.replace(/^.+\n/, '') : '';
|
|
if (!err.stack) {
|
|
err.stack = stack;
|
|
// match without the 2 top stack lines
|
|
} else if (stack && !String(err.stack).endsWith(stack.replace(/^.+\n.+\n/, ''))) {
|
|
err.stack += '\n' + stack;
|
|
}
|
|
}
|
|
throw err;
|
|
}
|
|
}
|
|
_request(configOrUrl, config) {
|
|
/*eslint no-param-reassign:0*/
|
|
// Allow for axios('example/url'[, config]) a la fetch API
|
|
if (typeof configOrUrl === 'string') {
|
|
config = config || {};
|
|
config.url = configOrUrl;
|
|
} else {
|
|
config = configOrUrl || {};
|
|
}
|
|
config = (0,_mergeConfig_js__WEBPACK_IMPORTED_MODULE_5__/* ["default"] */ .A)(this.defaults, config);
|
|
const {
|
|
transitional,
|
|
paramsSerializer,
|
|
headers
|
|
} = config;
|
|
if (transitional !== undefined) {
|
|
_helpers_validator_js__WEBPACK_IMPORTED_MODULE_3__/* ["default"] */ .A.assertOptions(transitional, {
|
|
silentJSONParsing: validators.transitional(validators.boolean),
|
|
forcedJSONParsing: validators.transitional(validators.boolean),
|
|
clarifyTimeoutError: validators.transitional(validators.boolean)
|
|
}, false);
|
|
}
|
|
if (paramsSerializer != null) {
|
|
if (_utils_js__WEBPACK_IMPORTED_MODULE_6__/* ["default"] */ .A.isFunction(paramsSerializer)) {
|
|
config.paramsSerializer = {
|
|
serialize: paramsSerializer
|
|
};
|
|
} else {
|
|
_helpers_validator_js__WEBPACK_IMPORTED_MODULE_3__/* ["default"] */ .A.assertOptions(paramsSerializer, {
|
|
encode: validators.function,
|
|
serialize: validators.function
|
|
}, true);
|
|
}
|
|
}
|
|
|
|
// Set config.method
|
|
config.method = (config.method || this.defaults.method || 'get').toLowerCase();
|
|
|
|
// Flatten headers
|
|
let contextHeaders = headers && _utils_js__WEBPACK_IMPORTED_MODULE_6__/* ["default"] */ .A.merge(headers.common, headers[config.method]);
|
|
headers && _utils_js__WEBPACK_IMPORTED_MODULE_6__/* ["default"] */ .A.forEach(['delete', 'get', 'head', 'post', 'put', 'patch', 'common'], method => {
|
|
delete headers[method];
|
|
});
|
|
config.headers = _AxiosHeaders_js__WEBPACK_IMPORTED_MODULE_7__/* ["default"] */ .A.concat(contextHeaders, headers);
|
|
|
|
// filter out skipped interceptors
|
|
const requestInterceptorChain = [];
|
|
let synchronousRequestInterceptors = true;
|
|
this.interceptors.request.forEach(function unshiftRequestInterceptors(interceptor) {
|
|
if (typeof interceptor.runWhen === 'function' && interceptor.runWhen(config) === false) {
|
|
return;
|
|
}
|
|
synchronousRequestInterceptors = synchronousRequestInterceptors && interceptor.synchronous;
|
|
requestInterceptorChain.unshift(interceptor.fulfilled, interceptor.rejected);
|
|
});
|
|
const responseInterceptorChain = [];
|
|
this.interceptors.response.forEach(function pushResponseInterceptors(interceptor) {
|
|
responseInterceptorChain.push(interceptor.fulfilled, interceptor.rejected);
|
|
});
|
|
let promise;
|
|
let i = 0;
|
|
let len;
|
|
if (!synchronousRequestInterceptors) {
|
|
const chain = [_dispatchRequest_js__WEBPACK_IMPORTED_MODULE_8__/* ["default"] */ .A.bind(this), undefined];
|
|
chain.unshift.apply(chain, requestInterceptorChain);
|
|
chain.push.apply(chain, responseInterceptorChain);
|
|
len = chain.length;
|
|
promise = Promise.resolve(config);
|
|
while (i < len) {
|
|
promise = promise.then(chain[i++], chain[i++]);
|
|
}
|
|
return promise;
|
|
}
|
|
len = requestInterceptorChain.length;
|
|
let newConfig = config;
|
|
i = 0;
|
|
while (i < len) {
|
|
const onFulfilled = requestInterceptorChain[i++];
|
|
const onRejected = requestInterceptorChain[i++];
|
|
try {
|
|
newConfig = onFulfilled(newConfig);
|
|
} catch (error) {
|
|
onRejected.call(this, error);
|
|
break;
|
|
}
|
|
}
|
|
try {
|
|
promise = _dispatchRequest_js__WEBPACK_IMPORTED_MODULE_8__/* ["default"] */ .A.call(this, newConfig);
|
|
} catch (error) {
|
|
return Promise.reject(error);
|
|
}
|
|
i = 0;
|
|
len = responseInterceptorChain.length;
|
|
while (i < len) {
|
|
promise = promise.then(responseInterceptorChain[i++], responseInterceptorChain[i++]);
|
|
}
|
|
return promise;
|
|
}
|
|
getUri(config) {
|
|
config = (0,_mergeConfig_js__WEBPACK_IMPORTED_MODULE_5__/* ["default"] */ .A)(this.defaults, config);
|
|
const fullPath = (0,_buildFullPath_js__WEBPACK_IMPORTED_MODULE_9__/* ["default"] */ .A)(config.baseURL, config.url);
|
|
return (0,_helpers_buildURL_js__WEBPACK_IMPORTED_MODULE_10__/* ["default"] */ .A)(fullPath, config.params, config.paramsSerializer);
|
|
}
|
|
}
|
|
|
|
// Provide aliases for supported request methods
|
|
_utils_js__WEBPACK_IMPORTED_MODULE_6__/* ["default"] */ .A.forEach(['delete', 'get', 'head', 'options'], function forEachMethodNoData(method) {
|
|
/*eslint func-names:0*/
|
|
Axios.prototype[method] = function (url, config) {
|
|
return this.request((0,_mergeConfig_js__WEBPACK_IMPORTED_MODULE_5__/* ["default"] */ .A)(config || {}, {
|
|
method,
|
|
url,
|
|
data: (config || {}).data
|
|
}));
|
|
};
|
|
});
|
|
_utils_js__WEBPACK_IMPORTED_MODULE_6__/* ["default"] */ .A.forEach(['post', 'put', 'patch'], function forEachMethodWithData(method) {
|
|
/*eslint func-names:0*/
|
|
|
|
function generateHTTPMethod(isForm) {
|
|
return function httpMethod(url, data, config) {
|
|
return this.request((0,_mergeConfig_js__WEBPACK_IMPORTED_MODULE_5__/* ["default"] */ .A)(config || {}, {
|
|
method,
|
|
headers: isForm ? {
|
|
'Content-Type': 'multipart/form-data'
|
|
} : {},
|
|
url,
|
|
data
|
|
}));
|
|
};
|
|
}
|
|
Axios.prototype[method] = generateHTTPMethod();
|
|
Axios.prototype[method + 'Form'] = generateHTTPMethod(true);
|
|
});
|
|
/* harmony default export */ __webpack_exports__.A = (Axios);
|
|
|
|
/***/ })
|
|
|
|
}]);
|
|
//# sourceMappingURL=chunk-vendors.075405dd.js.map
|