818 lines
23 KiB
JavaScript
818 lines
23 KiB
JavaScript
import {
|
|
__commonJS
|
|
} from "./chunk-EWTE5DHJ.js";
|
|
|
|
// node_modules/extend/index.js
|
|
var require_extend = __commonJS({
|
|
"node_modules/extend/index.js"(exports, module) {
|
|
"use strict";
|
|
var hasOwn = Object.prototype.hasOwnProperty;
|
|
var toStr = Object.prototype.toString;
|
|
var defineProperty = Object.defineProperty;
|
|
var gOPD = Object.getOwnPropertyDescriptor;
|
|
var isArray = function isArray2(arr) {
|
|
if (typeof Array.isArray === "function") {
|
|
return Array.isArray(arr);
|
|
}
|
|
return toStr.call(arr) === "[object Array]";
|
|
};
|
|
var isPlainObject2 = function isPlainObject3(obj) {
|
|
if (!obj || toStr.call(obj) !== "[object Object]") {
|
|
return false;
|
|
}
|
|
var hasOwnConstructor = hasOwn.call(obj, "constructor");
|
|
var hasIsPrototypeOf = obj.constructor && obj.constructor.prototype && hasOwn.call(obj.constructor.prototype, "isPrototypeOf");
|
|
if (obj.constructor && !hasOwnConstructor && !hasIsPrototypeOf) {
|
|
return false;
|
|
}
|
|
var key;
|
|
for (key in obj) {
|
|
}
|
|
return typeof key === "undefined" || hasOwn.call(obj, key);
|
|
};
|
|
var setProperty = function setProperty2(target, options) {
|
|
if (defineProperty && options.name === "__proto__") {
|
|
defineProperty(target, options.name, {
|
|
enumerable: true,
|
|
configurable: true,
|
|
value: options.newValue,
|
|
writable: true
|
|
});
|
|
} else {
|
|
target[options.name] = options.newValue;
|
|
}
|
|
};
|
|
var getProperty = function getProperty2(obj, name) {
|
|
if (name === "__proto__") {
|
|
if (!hasOwn.call(obj, name)) {
|
|
return void 0;
|
|
} else if (gOPD) {
|
|
return gOPD(obj, name).value;
|
|
}
|
|
}
|
|
return obj[name];
|
|
};
|
|
module.exports = function extend() {
|
|
var options, name, src, copy, copyIsArray, clone;
|
|
var target = arguments[0];
|
|
var i = 1;
|
|
var length = arguments.length;
|
|
var deep = false;
|
|
if (typeof target === "boolean") {
|
|
deep = target;
|
|
target = arguments[1] || {};
|
|
i = 2;
|
|
}
|
|
if (target == null || typeof target !== "object" && typeof target !== "function") {
|
|
target = {};
|
|
}
|
|
for (; i < length; ++i) {
|
|
options = arguments[i];
|
|
if (options != null) {
|
|
for (name in options) {
|
|
src = getProperty(target, name);
|
|
copy = getProperty(options, name);
|
|
if (target !== copy) {
|
|
if (deep && copy && (isPlainObject2(copy) || (copyIsArray = isArray(copy)))) {
|
|
if (copyIsArray) {
|
|
copyIsArray = false;
|
|
clone = src && isArray(src) ? src : [];
|
|
} else {
|
|
clone = src && isPlainObject2(src) ? src : {};
|
|
}
|
|
setProperty(target, { name, newValue: extend(deep, clone, copy) });
|
|
} else if (typeof copy !== "undefined") {
|
|
setProperty(target, { name, newValue: copy });
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
return target;
|
|
};
|
|
}
|
|
});
|
|
|
|
// node_modules/ms/index.js
|
|
var require_ms = __commonJS({
|
|
"node_modules/ms/index.js"(exports, module) {
|
|
var s = 1e3;
|
|
var m = s * 60;
|
|
var h = m * 60;
|
|
var d = h * 24;
|
|
var w = d * 7;
|
|
var y = d * 365.25;
|
|
module.exports = function(val, options) {
|
|
options = options || {};
|
|
var type = typeof val;
|
|
if (type === "string" && val.length > 0) {
|
|
return parse(val);
|
|
} else if (type === "number" && isFinite(val)) {
|
|
return options.long ? fmtLong(val) : fmtShort(val);
|
|
}
|
|
throw new Error(
|
|
"val is not a non-empty string or a valid number. val=" + JSON.stringify(val)
|
|
);
|
|
};
|
|
function parse(str) {
|
|
str = String(str);
|
|
if (str.length > 100) {
|
|
return;
|
|
}
|
|
var match = /^(-?(?:\d+)?\.?\d+) *(milliseconds?|msecs?|ms|seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|weeks?|w|years?|yrs?|y)?$/i.exec(
|
|
str
|
|
);
|
|
if (!match) {
|
|
return;
|
|
}
|
|
var n = parseFloat(match[1]);
|
|
var type = (match[2] || "ms").toLowerCase();
|
|
switch (type) {
|
|
case "years":
|
|
case "year":
|
|
case "yrs":
|
|
case "yr":
|
|
case "y":
|
|
return n * y;
|
|
case "weeks":
|
|
case "week":
|
|
case "w":
|
|
return n * w;
|
|
case "days":
|
|
case "day":
|
|
case "d":
|
|
return n * d;
|
|
case "hours":
|
|
case "hour":
|
|
case "hrs":
|
|
case "hr":
|
|
case "h":
|
|
return n * h;
|
|
case "minutes":
|
|
case "minute":
|
|
case "mins":
|
|
case "min":
|
|
case "m":
|
|
return n * m;
|
|
case "seconds":
|
|
case "second":
|
|
case "secs":
|
|
case "sec":
|
|
case "s":
|
|
return n * s;
|
|
case "milliseconds":
|
|
case "millisecond":
|
|
case "msecs":
|
|
case "msec":
|
|
case "ms":
|
|
return n;
|
|
default:
|
|
return void 0;
|
|
}
|
|
}
|
|
function fmtShort(ms) {
|
|
var msAbs = Math.abs(ms);
|
|
if (msAbs >= d) {
|
|
return Math.round(ms / d) + "d";
|
|
}
|
|
if (msAbs >= h) {
|
|
return Math.round(ms / h) + "h";
|
|
}
|
|
if (msAbs >= m) {
|
|
return Math.round(ms / m) + "m";
|
|
}
|
|
if (msAbs >= s) {
|
|
return Math.round(ms / s) + "s";
|
|
}
|
|
return ms + "ms";
|
|
}
|
|
function fmtLong(ms) {
|
|
var msAbs = Math.abs(ms);
|
|
if (msAbs >= d) {
|
|
return plural(ms, msAbs, d, "day");
|
|
}
|
|
if (msAbs >= h) {
|
|
return plural(ms, msAbs, h, "hour");
|
|
}
|
|
if (msAbs >= m) {
|
|
return plural(ms, msAbs, m, "minute");
|
|
}
|
|
if (msAbs >= s) {
|
|
return plural(ms, msAbs, s, "second");
|
|
}
|
|
return ms + " ms";
|
|
}
|
|
function plural(ms, msAbs, n, name) {
|
|
var isPlural = msAbs >= n * 1.5;
|
|
return Math.round(ms / n) + " " + name + (isPlural ? "s" : "");
|
|
}
|
|
}
|
|
});
|
|
|
|
// node_modules/debug/src/common.js
|
|
var require_common = __commonJS({
|
|
"node_modules/debug/src/common.js"(exports, module) {
|
|
function setup(env) {
|
|
createDebug.debug = createDebug;
|
|
createDebug.default = createDebug;
|
|
createDebug.coerce = coerce;
|
|
createDebug.disable = disable;
|
|
createDebug.enable = enable;
|
|
createDebug.enabled = enabled;
|
|
createDebug.humanize = require_ms();
|
|
createDebug.destroy = destroy;
|
|
Object.keys(env).forEach((key) => {
|
|
createDebug[key] = env[key];
|
|
});
|
|
createDebug.names = [];
|
|
createDebug.skips = [];
|
|
createDebug.formatters = {};
|
|
function selectColor(namespace) {
|
|
let hash = 0;
|
|
for (let i = 0; i < namespace.length; i++) {
|
|
hash = (hash << 5) - hash + namespace.charCodeAt(i);
|
|
hash |= 0;
|
|
}
|
|
return createDebug.colors[Math.abs(hash) % createDebug.colors.length];
|
|
}
|
|
createDebug.selectColor = selectColor;
|
|
function createDebug(namespace) {
|
|
let prevTime;
|
|
let enableOverride = null;
|
|
let namespacesCache;
|
|
let enabledCache;
|
|
function debug(...args) {
|
|
if (!debug.enabled) {
|
|
return;
|
|
}
|
|
const self = debug;
|
|
const curr = Number(/* @__PURE__ */ new Date());
|
|
const ms = curr - (prevTime || curr);
|
|
self.diff = ms;
|
|
self.prev = prevTime;
|
|
self.curr = curr;
|
|
prevTime = curr;
|
|
args[0] = createDebug.coerce(args[0]);
|
|
if (typeof args[0] !== "string") {
|
|
args.unshift("%O");
|
|
}
|
|
let index = 0;
|
|
args[0] = args[0].replace(/%([a-zA-Z%])/g, (match, format) => {
|
|
if (match === "%%") {
|
|
return "%";
|
|
}
|
|
index++;
|
|
const formatter = createDebug.formatters[format];
|
|
if (typeof formatter === "function") {
|
|
const val = args[index];
|
|
match = formatter.call(self, val);
|
|
args.splice(index, 1);
|
|
index--;
|
|
}
|
|
return match;
|
|
});
|
|
createDebug.formatArgs.call(self, args);
|
|
const logFn = self.log || createDebug.log;
|
|
logFn.apply(self, args);
|
|
}
|
|
debug.namespace = namespace;
|
|
debug.useColors = createDebug.useColors();
|
|
debug.color = createDebug.selectColor(namespace);
|
|
debug.extend = extend;
|
|
debug.destroy = createDebug.destroy;
|
|
Object.defineProperty(debug, "enabled", {
|
|
enumerable: true,
|
|
configurable: false,
|
|
get: () => {
|
|
if (enableOverride !== null) {
|
|
return enableOverride;
|
|
}
|
|
if (namespacesCache !== createDebug.namespaces) {
|
|
namespacesCache = createDebug.namespaces;
|
|
enabledCache = createDebug.enabled(namespace);
|
|
}
|
|
return enabledCache;
|
|
},
|
|
set: (v) => {
|
|
enableOverride = v;
|
|
}
|
|
});
|
|
if (typeof createDebug.init === "function") {
|
|
createDebug.init(debug);
|
|
}
|
|
return debug;
|
|
}
|
|
function extend(namespace, delimiter) {
|
|
const newDebug = createDebug(this.namespace + (typeof delimiter === "undefined" ? ":" : delimiter) + namespace);
|
|
newDebug.log = this.log;
|
|
return newDebug;
|
|
}
|
|
function enable(namespaces) {
|
|
createDebug.save(namespaces);
|
|
createDebug.namespaces = namespaces;
|
|
createDebug.names = [];
|
|
createDebug.skips = [];
|
|
const split = (typeof namespaces === "string" ? namespaces : "").trim().replace(/\s+/g, ",").split(",").filter(Boolean);
|
|
for (const ns of split) {
|
|
if (ns[0] === "-") {
|
|
createDebug.skips.push(ns.slice(1));
|
|
} else {
|
|
createDebug.names.push(ns);
|
|
}
|
|
}
|
|
}
|
|
function matchesTemplate(search, template) {
|
|
let searchIndex = 0;
|
|
let templateIndex = 0;
|
|
let starIndex = -1;
|
|
let matchIndex = 0;
|
|
while (searchIndex < search.length) {
|
|
if (templateIndex < template.length && (template[templateIndex] === search[searchIndex] || template[templateIndex] === "*")) {
|
|
if (template[templateIndex] === "*") {
|
|
starIndex = templateIndex;
|
|
matchIndex = searchIndex;
|
|
templateIndex++;
|
|
} else {
|
|
searchIndex++;
|
|
templateIndex++;
|
|
}
|
|
} else if (starIndex !== -1) {
|
|
templateIndex = starIndex + 1;
|
|
matchIndex++;
|
|
searchIndex = matchIndex;
|
|
} else {
|
|
return false;
|
|
}
|
|
}
|
|
while (templateIndex < template.length && template[templateIndex] === "*") {
|
|
templateIndex++;
|
|
}
|
|
return templateIndex === template.length;
|
|
}
|
|
function disable() {
|
|
const namespaces = [
|
|
...createDebug.names,
|
|
...createDebug.skips.map((namespace) => "-" + namespace)
|
|
].join(",");
|
|
createDebug.enable("");
|
|
return namespaces;
|
|
}
|
|
function enabled(name) {
|
|
for (const skip of createDebug.skips) {
|
|
if (matchesTemplate(name, skip)) {
|
|
return false;
|
|
}
|
|
}
|
|
for (const ns of createDebug.names) {
|
|
if (matchesTemplate(name, ns)) {
|
|
return true;
|
|
}
|
|
}
|
|
return false;
|
|
}
|
|
function coerce(val) {
|
|
if (val instanceof Error) {
|
|
return val.stack || val.message;
|
|
}
|
|
return val;
|
|
}
|
|
function destroy() {
|
|
console.warn("Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`.");
|
|
}
|
|
createDebug.enable(createDebug.load());
|
|
return createDebug;
|
|
}
|
|
module.exports = setup;
|
|
}
|
|
});
|
|
|
|
// node_modules/debug/src/browser.js
|
|
var require_browser = __commonJS({
|
|
"node_modules/debug/src/browser.js"(exports, module) {
|
|
exports.formatArgs = formatArgs;
|
|
exports.save = save;
|
|
exports.load = load;
|
|
exports.useColors = useColors;
|
|
exports.storage = localstorage();
|
|
exports.destroy = /* @__PURE__ */ (() => {
|
|
let warned = false;
|
|
return () => {
|
|
if (!warned) {
|
|
warned = true;
|
|
console.warn("Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`.");
|
|
}
|
|
};
|
|
})();
|
|
exports.colors = [
|
|
"#0000CC",
|
|
"#0000FF",
|
|
"#0033CC",
|
|
"#0033FF",
|
|
"#0066CC",
|
|
"#0066FF",
|
|
"#0099CC",
|
|
"#0099FF",
|
|
"#00CC00",
|
|
"#00CC33",
|
|
"#00CC66",
|
|
"#00CC99",
|
|
"#00CCCC",
|
|
"#00CCFF",
|
|
"#3300CC",
|
|
"#3300FF",
|
|
"#3333CC",
|
|
"#3333FF",
|
|
"#3366CC",
|
|
"#3366FF",
|
|
"#3399CC",
|
|
"#3399FF",
|
|
"#33CC00",
|
|
"#33CC33",
|
|
"#33CC66",
|
|
"#33CC99",
|
|
"#33CCCC",
|
|
"#33CCFF",
|
|
"#6600CC",
|
|
"#6600FF",
|
|
"#6633CC",
|
|
"#6633FF",
|
|
"#66CC00",
|
|
"#66CC33",
|
|
"#9900CC",
|
|
"#9900FF",
|
|
"#9933CC",
|
|
"#9933FF",
|
|
"#99CC00",
|
|
"#99CC33",
|
|
"#CC0000",
|
|
"#CC0033",
|
|
"#CC0066",
|
|
"#CC0099",
|
|
"#CC00CC",
|
|
"#CC00FF",
|
|
"#CC3300",
|
|
"#CC3333",
|
|
"#CC3366",
|
|
"#CC3399",
|
|
"#CC33CC",
|
|
"#CC33FF",
|
|
"#CC6600",
|
|
"#CC6633",
|
|
"#CC9900",
|
|
"#CC9933",
|
|
"#CCCC00",
|
|
"#CCCC33",
|
|
"#FF0000",
|
|
"#FF0033",
|
|
"#FF0066",
|
|
"#FF0099",
|
|
"#FF00CC",
|
|
"#FF00FF",
|
|
"#FF3300",
|
|
"#FF3333",
|
|
"#FF3366",
|
|
"#FF3399",
|
|
"#FF33CC",
|
|
"#FF33FF",
|
|
"#FF6600",
|
|
"#FF6633",
|
|
"#FF9900",
|
|
"#FF9933",
|
|
"#FFCC00",
|
|
"#FFCC33"
|
|
];
|
|
function useColors() {
|
|
if (typeof window !== "undefined" && window.process && (window.process.type === "renderer" || window.process.__nwjs)) {
|
|
return true;
|
|
}
|
|
if (typeof navigator !== "undefined" && navigator.userAgent && navigator.userAgent.toLowerCase().match(/(edge|trident)\/(\d+)/)) {
|
|
return false;
|
|
}
|
|
let m;
|
|
return typeof document !== "undefined" && document.documentElement && document.documentElement.style && document.documentElement.style.WebkitAppearance || // Is firebug? http://stackoverflow.com/a/398120/376773
|
|
typeof window !== "undefined" && window.console && (window.console.firebug || window.console.exception && window.console.table) || // Is firefox >= v31?
|
|
// https://developer.mozilla.org/en-US/docs/Tools/Web_Console#Styling_messages
|
|
typeof navigator !== "undefined" && navigator.userAgent && (m = navigator.userAgent.toLowerCase().match(/firefox\/(\d+)/)) && parseInt(m[1], 10) >= 31 || // Double check webkit in userAgent just in case we are in a worker
|
|
typeof navigator !== "undefined" && navigator.userAgent && navigator.userAgent.toLowerCase().match(/applewebkit\/(\d+)/);
|
|
}
|
|
function formatArgs(args) {
|
|
args[0] = (this.useColors ? "%c" : "") + this.namespace + (this.useColors ? " %c" : " ") + args[0] + (this.useColors ? "%c " : " ") + "+" + module.exports.humanize(this.diff);
|
|
if (!this.useColors) {
|
|
return;
|
|
}
|
|
const c = "color: " + this.color;
|
|
args.splice(1, 0, c, "color: inherit");
|
|
let index = 0;
|
|
let lastC = 0;
|
|
args[0].replace(/%[a-zA-Z%]/g, (match) => {
|
|
if (match === "%%") {
|
|
return;
|
|
}
|
|
index++;
|
|
if (match === "%c") {
|
|
lastC = index;
|
|
}
|
|
});
|
|
args.splice(lastC, 0, c);
|
|
}
|
|
exports.log = console.debug || console.log || (() => {
|
|
});
|
|
function save(namespaces) {
|
|
try {
|
|
if (namespaces) {
|
|
exports.storage.setItem("debug", namespaces);
|
|
} else {
|
|
exports.storage.removeItem("debug");
|
|
}
|
|
} catch (error) {
|
|
}
|
|
}
|
|
function load() {
|
|
let r;
|
|
try {
|
|
r = exports.storage.getItem("debug") || exports.storage.getItem("DEBUG");
|
|
} catch (error) {
|
|
}
|
|
if (!r && typeof process !== "undefined" && "env" in process) {
|
|
r = process.env.DEBUG;
|
|
}
|
|
return r;
|
|
}
|
|
function localstorage() {
|
|
try {
|
|
return localStorage;
|
|
} catch (error) {
|
|
}
|
|
}
|
|
module.exports = require_common()(exports);
|
|
var { formatters } = module.exports;
|
|
formatters.j = function(v) {
|
|
try {
|
|
return JSON.stringify(v);
|
|
} catch (error) {
|
|
return "[UnexpectedJSONParseError]: " + error.message;
|
|
}
|
|
};
|
|
}
|
|
});
|
|
|
|
// node_modules/bail/index.js
|
|
function bail(error) {
|
|
if (error) {
|
|
throw error;
|
|
}
|
|
}
|
|
|
|
// node_modules/is-plain-obj/index.js
|
|
function isPlainObject(value) {
|
|
if (typeof value !== "object" || value === null) {
|
|
return false;
|
|
}
|
|
const prototype = Object.getPrototypeOf(value);
|
|
return (prototype === null || prototype === Object.prototype || Object.getPrototypeOf(prototype) === null) && !(Symbol.toStringTag in value) && !(Symbol.iterator in value);
|
|
}
|
|
|
|
// node_modules/trough/lib/index.js
|
|
function trough() {
|
|
const fns = [];
|
|
const pipeline = { run, use };
|
|
return pipeline;
|
|
function run(...values) {
|
|
let middlewareIndex = -1;
|
|
const callback = values.pop();
|
|
if (typeof callback !== "function") {
|
|
throw new TypeError("Expected function as last argument, not " + callback);
|
|
}
|
|
next(null, ...values);
|
|
function next(error, ...output) {
|
|
const fn = fns[++middlewareIndex];
|
|
let index = -1;
|
|
if (error) {
|
|
callback(error);
|
|
return;
|
|
}
|
|
while (++index < values.length) {
|
|
if (output[index] === null || output[index] === void 0) {
|
|
output[index] = values[index];
|
|
}
|
|
}
|
|
values = output;
|
|
if (fn) {
|
|
wrap(fn, next)(...output);
|
|
} else {
|
|
callback(null, ...output);
|
|
}
|
|
}
|
|
}
|
|
function use(middelware) {
|
|
if (typeof middelware !== "function") {
|
|
throw new TypeError(
|
|
"Expected `middelware` to be a function, not " + middelware
|
|
);
|
|
}
|
|
fns.push(middelware);
|
|
return pipeline;
|
|
}
|
|
}
|
|
function wrap(middleware, callback) {
|
|
let called;
|
|
return wrapped;
|
|
function wrapped(...parameters) {
|
|
const fnExpectsCallback = middleware.length > parameters.length;
|
|
let result;
|
|
if (fnExpectsCallback) {
|
|
parameters.push(done);
|
|
}
|
|
try {
|
|
result = middleware.apply(this, parameters);
|
|
} catch (error) {
|
|
const exception = (
|
|
/** @type {Error} */
|
|
error
|
|
);
|
|
if (fnExpectsCallback && called) {
|
|
throw exception;
|
|
}
|
|
return done(exception);
|
|
}
|
|
if (!fnExpectsCallback) {
|
|
if (result && result.then && typeof result.then === "function") {
|
|
result.then(then, done);
|
|
} else if (result instanceof Error) {
|
|
done(result);
|
|
} else {
|
|
then(result);
|
|
}
|
|
}
|
|
}
|
|
function done(error, ...output) {
|
|
if (!called) {
|
|
called = true;
|
|
callback(error, ...output);
|
|
}
|
|
}
|
|
function then(value) {
|
|
done(null, value);
|
|
}
|
|
}
|
|
|
|
// node_modules/dequal/dist/index.mjs
|
|
var has = Object.prototype.hasOwnProperty;
|
|
function find(iter, tar, key) {
|
|
for (key of iter.keys()) {
|
|
if (dequal(key, tar)) return key;
|
|
}
|
|
}
|
|
function dequal(foo, bar) {
|
|
var ctor, len, tmp;
|
|
if (foo === bar) return true;
|
|
if (foo && bar && (ctor = foo.constructor) === bar.constructor) {
|
|
if (ctor === Date) return foo.getTime() === bar.getTime();
|
|
if (ctor === RegExp) return foo.toString() === bar.toString();
|
|
if (ctor === Array) {
|
|
if ((len = foo.length) === bar.length) {
|
|
while (len-- && dequal(foo[len], bar[len])) ;
|
|
}
|
|
return len === -1;
|
|
}
|
|
if (ctor === Set) {
|
|
if (foo.size !== bar.size) {
|
|
return false;
|
|
}
|
|
for (len of foo) {
|
|
tmp = len;
|
|
if (tmp && typeof tmp === "object") {
|
|
tmp = find(bar, tmp);
|
|
if (!tmp) return false;
|
|
}
|
|
if (!bar.has(tmp)) return false;
|
|
}
|
|
return true;
|
|
}
|
|
if (ctor === Map) {
|
|
if (foo.size !== bar.size) {
|
|
return false;
|
|
}
|
|
for (len of foo) {
|
|
tmp = len[0];
|
|
if (tmp && typeof tmp === "object") {
|
|
tmp = find(bar, tmp);
|
|
if (!tmp) return false;
|
|
}
|
|
if (!dequal(len[1], bar.get(tmp))) {
|
|
return false;
|
|
}
|
|
}
|
|
return true;
|
|
}
|
|
if (ctor === ArrayBuffer) {
|
|
foo = new Uint8Array(foo);
|
|
bar = new Uint8Array(bar);
|
|
} else if (ctor === DataView) {
|
|
if ((len = foo.byteLength) === bar.byteLength) {
|
|
while (len-- && foo.getInt8(len) === bar.getInt8(len)) ;
|
|
}
|
|
return len === -1;
|
|
}
|
|
if (ArrayBuffer.isView(foo)) {
|
|
if ((len = foo.byteLength) === bar.byteLength) {
|
|
while (len-- && foo[len] === bar[len]) ;
|
|
}
|
|
return len === -1;
|
|
}
|
|
if (!ctor || typeof foo === "object") {
|
|
len = 0;
|
|
for (ctor in foo) {
|
|
if (has.call(foo, ctor) && ++len && !has.call(bar, ctor)) return false;
|
|
if (!(ctor in bar) || !dequal(foo[ctor], bar[ctor])) return false;
|
|
}
|
|
return Object.keys(bar).length === len;
|
|
}
|
|
}
|
|
return foo !== foo && bar !== bar;
|
|
}
|
|
|
|
// node_modules/space-separated-tokens/index.js
|
|
function stringify(values) {
|
|
return values.join(" ").trim();
|
|
}
|
|
|
|
// node_modules/comma-separated-tokens/index.js
|
|
function stringify2(values, options) {
|
|
const settings = options || {};
|
|
const input = values[values.length - 1] === "" ? [...values, ""] : values;
|
|
return input.join(
|
|
(settings.padRight ? " " : "") + "," + (settings.padLeft === false ? "" : " ")
|
|
).trim();
|
|
}
|
|
|
|
// node_modules/decode-named-character-reference/index.dom.js
|
|
var element = document.createElement("i");
|
|
function decodeNamedCharacterReference(value) {
|
|
const characterReference = "&" + value + ";";
|
|
element.innerHTML = characterReference;
|
|
const character = element.textContent;
|
|
if (
|
|
// @ts-expect-error: TypeScript is wrong that `textContent` on elements can
|
|
// yield `null`.
|
|
character.charCodeAt(character.length - 1) === 59 && value !== "semi"
|
|
) {
|
|
return false;
|
|
}
|
|
return character === characterReference ? false : character;
|
|
}
|
|
|
|
// node_modules/trim-lines/index.js
|
|
var tab = 9;
|
|
var space = 32;
|
|
function trimLines(value) {
|
|
const source = String(value);
|
|
const search = /\r?\n|\r/g;
|
|
let match = search.exec(source);
|
|
let last = 0;
|
|
const lines = [];
|
|
while (match) {
|
|
lines.push(
|
|
trimLine(source.slice(last, match.index), last > 0, true),
|
|
match[0]
|
|
);
|
|
last = match.index + match[0].length;
|
|
match = search.exec(source);
|
|
}
|
|
lines.push(trimLine(source.slice(last), last > 0, false));
|
|
return lines.join("");
|
|
}
|
|
function trimLine(value, start, end) {
|
|
let startIndex = 0;
|
|
let endIndex = value.length;
|
|
if (start) {
|
|
let code = value.codePointAt(startIndex);
|
|
while (code === tab || code === space) {
|
|
startIndex++;
|
|
code = value.codePointAt(startIndex);
|
|
}
|
|
}
|
|
if (end) {
|
|
let code = value.codePointAt(endIndex - 1);
|
|
while (code === tab || code === space) {
|
|
endIndex--;
|
|
code = value.codePointAt(endIndex - 1);
|
|
}
|
|
}
|
|
return endIndex > startIndex ? value.slice(startIndex, endIndex) : "";
|
|
}
|
|
|
|
export {
|
|
bail,
|
|
require_extend,
|
|
isPlainObject,
|
|
trough,
|
|
dequal,
|
|
decodeNamedCharacterReference,
|
|
require_browser,
|
|
trimLines,
|
|
stringify,
|
|
stringify2
|
|
};
|
|
//# sourceMappingURL=chunk-LLYCTVJM.js.map
|