1import { a as e, n as t, o as n, r, t as i } from "./chunk-CDGyQ605.js"; 2import { n as a, t as o } from "./dist-csr2igEd.js"; 3import { n as s, t as c } from "./dist-B5OGMWK4.js"; 4import { n as l, t as u } from "./dist-Bz0oLIIB.js"; 5import { t as d } from "./path-browserify-Q9kGtxRe.js"; 6var f = r({ __addDisposableResource: () => B, __assign: () => W, __asyncDelegator: () => M, __asyncGenerator: () => j, __asyncValues: () => N, __await: () => A, __awaiter: () => S, __classPrivateFieldGet: () => L, __classPrivateFieldIn: () => z, __classPrivateFieldSet: () => R, __createBinding: () => G, __decorate: () => h, __disposeResources: () => V, __esDecorate: () => _, __exportStar: () => w, __extends: () => p, __generator: () => C, __importDefault: () => I, __importStar: () => F, __makeTemplateObject: () => P, __metadata: () => x, __param: () => g, __propKey: () => y, __read: () => E, __rest: () => m, __rewriteRelativeImportExtension: () => H, __runInitializers: () => v, __setFunctionName: () => b, __spread: () => D, __spreadArray: () => k, __spreadArrays: () => O, __values: () => T, default: () => q }); 7function p(e2, t2) { 8 if (typeof t2 != `function` && t2 !== null) throw TypeError(`Class extends value ` + String(t2) + ` is not a constructor or null`); 9 U(e2, t2); 10 function n2() { 11 this.constructor = e2; 12 } 13 e2.prototype = t2 === null ? Object.create(t2) : (n2.prototype = t2.prototype, new n2()); 14} 15function m(e2, t2) { 16 var n2 = {}; 17 for (var r2 in e2) Object.prototype.hasOwnProperty.call(e2, r2) && t2.indexOf(r2) < 0 && (n2[r2] = e2[r2]); 18 if (e2 != null && typeof Object.getOwnPropertySymbols == `function`) for (var i2 = 0, r2 = Object.getOwnPropertySymbols(e2); i2 < r2.length; i2++) t2.indexOf(r2[i2]) < 0 && Object.prototype.propertyIsEnumerable.call(e2, r2[i2]) && (n2[r2[i2]] = e2[r2[i2]]); 19 return n2; 20} 21function h(e2, t2, n2, r2) { 22 var i2 = arguments.length, a2 = i2 < 3 ? t2 : r2 === null ? r2 = Object.getOwnPropertyDescriptor(t2, n2) : r2, o2; 23 if (typeof Reflect == `object` && typeof Reflect.decorate == `function`) a2 = Reflect.decorate(e2, t2, n2, r2); 24 else for (var s2 = e2.length - 1; s2 >= 0; s2--) (o2 = e2[s2]) && (a2 = (i2 < 3 ? o2(a2) : i2 > 3 ? o2(t2, n2, a2) : o2(t2, n2)) || a2); 25 return i2 > 3 && a2 && Object.defineProperty(t2, n2, a2), a2; 26} 27function g(e2, t2) { 28 return function(n2, r2) { 29 t2(n2, r2, e2); 30 }; 31} 32function _(e2, t2, n2, r2, i2, a2) { 33 function o2(e3) { 34 if (e3 !== void 0 && typeof e3 != `function`) throw TypeError(`Function expected`); 35 return e3; 36 } 37 for (var s2 = r2.kind, c2 = s2 === `getter` ? `get` : s2 === `setter` ? `set` : `value`, l2 = !t2 && e2 ? r2.static ? e2 : e2.prototype : null, u2 = t2 || (l2 ? Object.getOwnPropertyDescriptor(l2, r2.name) : {}), d2, f2 = false, p2 = n2.length - 1; p2 >= 0; p2--) { 38 var m2 = {}; 39 for (var h2 in r2) m2[h2] = h2 === `access` ? {} : r2[h2]; 40 for (var h2 in r2.access) m2.access[h2] = r2.access[h2]; 41 m2.addInitializer = function(e3) { 42 if (f2) throw TypeError(`Cannot add initializers after decoration has completed`); 43 a2.push(o2(e3 || null)); 44 }; 45 var g2 = (0, n2[p2])(s2 === `accessor` ? { get: u2.get, set: u2.set } : u2[c2], m2); 46 if (s2 === `accessor`) { 47 if (g2 === void 0) continue; 48 if (typeof g2 != `object` || !g2) throw TypeError(`Object expected`); 49 (d2 = o2(g2.get)) && (u2.get = d2), (d2 = o2(g2.set)) && (u2.set = d2), (d2 = o2(g2.init)) && i2.unshift(d2); 50 } else (d2 = o2(g2)) && (s2 === `field` ? i2.unshift(d2) : u2[c2] = d2); 51 } 52 l2 && Object.defineProperty(l2, r2.name, u2), f2 = true; 53} 54function v(e2, t2, n2) { 55 for (var r2 = arguments.length > 2, i2 = 0; i2 < t2.length; i2++) n2 = r2 ? t2[i2].call(e2, n2) : t2[i2].call(e2); 56 return r2 ? n2 : void 0; 57} 58function y(e2) { 59 return typeof e2 == `symbol` ? e2 : `${e2}`; 60} 61function b(e2, t2, n2) { 62 return typeof t2 == `symbol` && (t2 = t2.description ? `[${t2.description}]` : ``), Object.defineProperty(e2, `name`, { configurable: true, value: n2 ? `${n2} ${t2}` : t2 }); 63} 64function x(e2, t2) { 65 if (typeof Reflect == `object` && typeof Reflect.metadata == `function`) return Reflect.metadata(e2, t2); 66} 67function S(e2, t2, n2, r2) { 68 function i2(e3) { 69 return e3 instanceof n2 ? e3 : new n2(function(t3) { 70 t3(e3); 71 }); 72 } 73 return new (n2 || (n2 = Promise))(function(n3, a2) { 74 function o2(e3) {
75 try { 76 c2(r2.next(e3)); 77 } catch (e4) { 78 a2(e4); 79 } 80 } 81 function s2(e3) { 82 try { 83 c2(r2.throw(e3)); 84 } catch (e4) { 85 a2(e4); 86 } 87 } 88 function c2(e3) { 89 e3.done ? n3(e3.value) : i2(e3.value).then(o2, s2); 90 } 91 c2((r2 = r2.apply(e2, t2 || [])).next()); 92 }); 93} 94function C(e2, t2) { 95 var n2 = { label: 0, sent: function() { 96 if (a2[0] & 1) throw a2[1]; 97 return a2[1]; 98 }, trys: [], ops: [] }, r2, i2, a2, o2 = Object.create((typeof Iterator == `function` ? Iterator : Object).prototype); 99 return o2.next = s2(0), o2.throw = s2(1), o2.return = s2(2), typeof Symbol == `function` && (o2[Symbol.iterator] = function() { 100 return this; 101 }), o2; 102 function s2(e3) { 103 return function(t3) { 104 return c2([e3, t3]); 105 }; 106 } 107 function c2(s3) { 108 if (r2) throw TypeError(`Generator is already executing.`); 109 for (; o2 && (o2 = 0, s3[0] && (n2 = 0)), n2; ) try { 110 if (r2 = 1, i2 && (a2 = s3[0] & 2 ? i2.return : s3[0] ? i2.throw || ((a2 = i2.return) && a2.call(i2), 0) : i2.next) && !(a2 = a2.call(i2, s3[1])).done) return a2; 111 switch (i2 = 0, a2 && (s3 = [s3[0] & 2, a2.value]), s3[0]) { 112 case 0: 113 case 1: 114 a2 = s3; 115 break; 116 case 4: 117 return n2.label++, { value: s3[1], done: false }; 118 case 5: 119 n2.label++, i2 = s3[1], s3 = [0]; 120 continue; 121 case 7: 122 s3 = n2.ops.pop(), n2.trys.pop(); 123 continue; 124 default: 125 if ((a2 = n2.trys, !(a2 = a2.length > 0 && a2[a2.length - 1])) && (s3[0] === 6 || s3[0] === 2)) { 126 n2 = 0; 127 continue; 128 } 129 if (s3[0] === 3 && (!a2 || s3[1] > a2[0] && s3[1] < a2[3])) { 130 n2.label = s3[1]; 131 break; 132 } 133 if (s3[0] === 6 && n2.label < a2[1]) { 134 n2.label = a2[1], a2 = s3; 135 break; 136 } 137 if (a2 && n2.label < a2[2]) { 138 n2.label = a2[2], n2.ops.push(s3); 139 break; 140 } 141 a2[2] && n2.ops.pop(), n2.trys.pop(); 142 continue; 143 } 144 s3 = t2.call(e2, n2); 145 } catch (e3) { 146 s3 = [6, e3], i2 = 0; 147 } finally { 148 r2 = a2 = 0; 149 } 150 if (s3[0] & 5) throw s3[1]; 151 return { value: s3[0] ? s3[1] : void 0, done: true }; 152 } 153} 154function w(e2, t2) { 155 for (var n2 in e2) n2 !== `default` && !Object.prototype.hasOwnProperty.call(t2, n2) && G(t2, e2, n2); 156} 157function T(e2) { 158 var t2 = typeof Symbol == `function` && Symbol.iterator, n2 = t2 && e2[t2], r2 = 0; 159 if (n2) return n2.call(e2); 160 if (e2 && typeof e2.length == `number`) return { next: function() { 161 return e2 && r2 >= e2.length && (e2 = void 0), { value: e2 && e2[r2++], done: !e2 }; 162 } }; 163 throw TypeError(t2 ? `Object is not iterable.` : `Symbol.iterator is not defined.`); 164} 165function E(e2, t2) { 166 var n2 = typeof Symbol == `function` && e2[Symbol.iterator]; 167 if (!n2) return e2; 168 var r2 = n2.call(e2), i2, a2 = [], o2; 169 try { 170 for (; (t2 === void 0 || t2-- > 0) && !(i2 = r2.next()).done; ) a2.push(i2.value); 171 } catch (e3) { 172 o2 = { error: e3 }; 173 } finally { 174 try { 175 i2 && !i2.done && (n2 = r2.return) && n2.call(r2); 176 } finally { 177 if (o2) throw o2.error; 178 } 179 } 180 return a2; 181} 182function D() { 183 for (var e2 = [], t2 = 0; t2 < arguments.length; t2++) e2 = e2.concat(E(arguments[t2])); 184 return e2; 185} 186function O() { 187 for (var e2 = 0, t2 = 0, n2 = arguments.length; t2 < n2; t2++) e2 += arguments[t2].length; 188 for (var r2 = Array(e2), i2 = 0, t2 = 0; t2 < n2; t2++) for (var a2 = arguments[t2], o2 = 0, s2 = a2.length; o2 < s2; o2++, i2++) r2[i2] = a2[o2]; 189 return r2; 190} 191function k(e2, t2, n2) { 192 if (n2 || arguments.length === 2) for (var r2 = 0, i2 = t2.length, a2; r2 < i2; r2++) (a2 || !(r2 in t2)) && (a2 || (a2 = Array.prototype.slice.call(t2, 0, r2)), a2[r2] = t2[r2]); 193 return e2.concat(a2 || Array.prototype.slice.call(t2)); 194} 195function A(e2) { 196 return this instanceof A ? (this.v = e2, this) : new A(e2); 197} 198function j(e2, t2, n2) { 199 if (!Symbol.asyncIterator) throw TypeError(`Symbol.asyncIterator is not defined.`); 200 var r2 = n2.apply(e2, t2 || []), i2, a2 = []; 201 return i2 = Object.create((typeof AsyncIterator == `function` ? AsyncIterator : Object).prototype), s2(`next`), s2(`throw`), s2(`return`, o2), i2[Symbol.asyncIterator] = function() { 202 return this; 203 }, i2; 204 function o2(e3) { 205 return function(t3) { 206 return Promise.resolve(t3).then(e3, d2); 207 }; 208 } 209 function s2(e3, t3) { 210 r2[e3] && (i2[e3] = function(t4) { 211 return new Promise(function(n3, r3) { 212 a2.push([e3, t4, n3, r3]) > 1 || c2(e3, t4); 213 }); 214 }, t3 && (i2[e3] = t3(i2[e3]))); 215 } 216 function c2(e3, t3) { 217 try { 218 l2(r2[e3](t3)); 219 } catch (e4) { 220 f2(a2[0][3], e4); 221 } 222 } 223 function l2(e3) { 224 e3.value instanceof A ? Promise.resolve(e3.value.v).then(u2, d2) : f2(a2[0][2], e3); 225 } 226 function u2(e3) { 227 c2(`next`, e3); 228 } 229 function d2(e3) { 230 c2(`throw`, e3); 231 } 232 function f2(e3, t3) { 233 e3(t3), a2.shift(), a2.length && c2(a2[0][0], a2[0][1]); 234 } 235} 236function M(e2) { 237 var t2, n2; 238 return t2 = {}, r2(`next`), r2(`throw`, function(e3) { 239 throw e3; 240 }), r2(`return`), t2[Symbol.iterator] = function() { 241 return this; 242 }, t2; 243 function r2(r3, i2) { 244 t2[r3] = e2[r3] ? function(t3) { 245 return (n2 = !n2) ? { value: A(e2[r3](t3)), done: false } : i2 ? i2(t3) : t3; 246 } : i2; 247 } 248} 249function N(e2) { 250 if (!Symbol.asyncIterator) throw TypeError(`Symbol.asyncIterator is not defined.`); 251 var t2 = e2[Symbol.asyncIterator], n2; 252 return t2 ? t2.call(e2) : (e2 = typeof T == `function` ? T(e2) : e2[Symbol.iterator](), n2 = {}, r2(`next`), r2(`throw`), r2(`return`), n2[Symbol.asyncIterator] = function() { 253 return this; 254 }, n2); 255 function r2(t3) { 256 n2[t3] = e2[t3] && function(n3) { 257 return new Promise(function(r3, a2) { 258 n3 = e2[t3](n3), i2(r3, a2, n3.done, n3.value); 259 }); 260 }; 261 } 262 function i2(e3, t3, n3, r3) { 263 Promise.resolve(r3).then(function(t4) { 264 e3({ value: t4, done: n3 }); 265 }, t3); 266 } 267} 268function P(e2, t2) { 269 return Object.defineProperty ? Object.defineProperty(e2, `raw`, { value: t2 }) : e2.raw = t2, e2;
270} 271function F(e2) { 272 if (e2 && e2.__esModule) return e2; 273 var t2 = {}; 274 if (e2 != null) for (var n2 = K(e2), r2 = 0; r2 < n2.length; r2++) n2[r2] !== `default` && G(t2, e2, n2[r2]); 275 return ee(t2, e2), t2; 276} 277function I(e2) { 278 return e2 && e2.__esModule ? e2 : { default: e2 }; 279} 280function L(e2, t2, n2, r2) { 281 if (n2 === `a` && !r2) throw TypeError(`Private accessor was defined without a getter`); 282 if (typeof t2 == `function` ? e2 !== t2 || !r2 : !t2.has(e2)) throw TypeError(`Cannot read private member from an object whose class did not declare it`); 283 return n2 === `m` ? r2 : n2 === `a` ? r2.call(e2) : r2 ? r2.value : t2.get(e2); 284} 285function R(e2, t2, n2, r2, i2) { 286 if (r2 === `m`) throw TypeError(`Private method is not writable`); 287 if (r2 === `a` && !i2) throw TypeError(`Private accessor was defined without a setter`); 288 if (typeof t2 == `function` ? e2 !== t2 || !i2 : !t2.has(e2)) throw TypeError(`Cannot write private member to an object whose class did not declare it`); 289 return r2 === `a` ? i2.call(e2, n2) : i2 ? i2.value = n2 : t2.set(e2, n2), n2; 290} 291function z(e2, t2) { 292 if (t2 === null || typeof t2 != `object` && typeof t2 != `function`) throw TypeError(`Cannot use 'in' operator on non-object`); 293 return typeof e2 == `function` ? t2 === e2 : e2.has(t2); 294} 295function B(e2, t2, n2) { 296 if (t2 != null) { 297 if (typeof t2 != `object` && typeof t2 != `function`) throw TypeError(`Object expected.`); 298 var r2, i2; 299 if (n2) { 300 if (!Symbol.asyncDispose) throw TypeError(`Symbol.asyncDispose is not defined.`); 301 r2 = t2[Symbol.asyncDispose]; 302 } 303 if (r2 === void 0) { 304 if (!Symbol.dispose) throw TypeError(`Symbol.dispose is not defined.`); 305 r2 = t2[Symbol.dispose], n2 && (i2 = r2); 306 } 307 if (typeof r2 != `function`) throw TypeError(`Object not disposable.`); 308 i2 && (r2 = function() { 309 try { 310 i2.call(this); 311 } catch (e3) { 312 return Promise.reject(e3); 313 } 314 }), e2.stack.push({ value: t2, dispose: r2, async: n2 }); 315 } else n2 && e2.stack.push({ async: true }); 316 return t2; 317} 318function V(e2) { 319 function t2(t3) { 320 e2.error = e2.hasError ? new te(t3, e2.error, `An error was suppressed during disposal.`) : t3, e2.hasError = true; 321 } 322 var n2, r2 = 0; 323 function i2() { 324 for (; n2 = e2.stack.pop(); ) try { 325 if (!n2.async && r2 === 1) return r2 = 0, e2.stack.push(n2), Promise.resolve().then(i2); 326 if (n2.dispose) { 327 var a2 = n2.dispose.call(n2.value); 328 if (n2.async) return r2 |= 2, Promise.resolve(a2).then(i2, function(e3) { 329 return t2(e3), i2(); 330 }); 331 } else r2 |= 1; 332 } catch (e3) { 333 t2(e3); 334 } 335 if (r2 === 1) return e2.hasError ? Promise.reject(e2.error) : Promise.resolve(); 336 if (e2.hasError) throw e2.error; 337 } 338 return i2(); 339} 340function H(e2, t2) { 341 return typeof e2 == `string` && /^\.\.?\//.test(e2) ? e2.replace(/\.(tsx)$|((?:\.d)?)((?:\.[^./]+?)?)\.([cm]?)ts$/i, function(e3, n2, r2, i2, a2) { 342 return n2 ? t2 ? `.jsx` : `.js` : r2 && (!i2 || !a2) ? e3 : r2 + i2 + `.` + a2.toLowerCase() + `js`; 343 }) : e2; 344} 345var U, W, G, ee, K, te, q, J = t((() => { 346 U = function(e2, t2) { 347 return U = Object.setPrototypeOf || { __proto__: [] } instanceof Array && function(e3, t3) { 348 e3.__proto__ = t3; 349 } || function(e3, t3) { 350 for (var n2 in t3) Object.prototype.hasOwnProperty.call(t3, n2) && (e3[n2] = t3[n2]); 351 }, U(e2, t2); 352 }, W = function() { 353 return W = Object.assign || function(e2) { 354 for (var t2, n2 = 1, r2 = arguments.length; n2 < r2; n2++) for (var i2 in t2 = arguments[n2], t2) Object.prototype.hasOwnProperty.call(t2, i2) && (e2[i2] = t2[i2]); 355 return e2; 356 }, W.apply(this, arguments); 357 }, G = Object.create ? (function(e2, t2, n2, r2) { 358 r2 === void 0 && (r2 = n2); 359 var i2 = Object.getOwnPropertyDescriptor(t2, n2); 360 (!i2 || (`get` in i2 ? !t2.__esModule : i2.writable || i2.configurable)) && (i2 = { enumerable: true, get: function() { 361 return t2[n2]; 362 } }), Object.defineProperty(e2, r2, i2); 363 }) : (function(e2, t2, n2, r2) { 364 r2 === void 0 && (r2 = n2), e2[r2] = t2[n2]; 365 }), ee = Object.create ? (function(e2, t2) { 366 Object.defineProperty(e2, `default`, { enumerable: true, value: t2 }); 367 }) : function(e2, t2) { 368 e2.default = t2; 369 }, K = function(e2) { 370 return K = Object.getOwnPropertyNames || function(e3) { 371 var t2 = []; 372 for (var n2 in e3) Object.prototype.hasOwnProperty.call(e3, n2) && (t2[t2.length] = n2); 373 return t2; 374 }, K(e2); 375 }, te = typeof SuppressedError == `function` ? SuppressedError : function(e2, t2, n2) { 376 var r2 = Error(n2); 377 return r2.name = `SuppressedError`, r2.error = e2, r2.suppressed = t2, r2; 378 }, q = { __extends: p, __assign: W, __rest: m, __decorate: h, __param: g, __esDecorate: _, __runInitializer
vendor: 8,587 bytes, lines 378-507
378s: v, __propKey: y, __setFunctionName: b, __metadata: x, __awaiter: S, __generator: C, __createBinding: G, __exportStar: w, __values: T, __read: E, __spread: D, __spreadArrays: O, __spreadArray: k, __await: A, __asyncGenerator: j, __asyncDelegator: M, __asyncValues: N, __makeTemplateObject: P, __importStar: F, __importDefault: I, __classPrivateFieldGet: L, __classPrivateFieldSet: R, __classPrivateFieldIn: z, __addDisposableResource: B, __disposeResources: V, __rewriteRelativeImportExtension: H }; 379})), Y = i(((e2) => { 380 Object.defineProperty(e2, `__esModule`, { value: true }), e2.basename = e2.isAbsolute = e2.normalize = e2.dirname = e2.relative = e2.join = e2.posix = e2.sep = e2.resolve = void 0; 381 var t2 = d(); 382 Object.defineProperty(e2, `resolve`, { enumerable: true, get: function() { 383 return t2.resolve; 384 } }), Object.defineProperty(e2, `sep`, { enumerable: true, get: function() { 385 return t2.sep; 386 } }), Object.defineProperty(e2, `posix`, { enumerable: true, get: function() { 387 return t2.posix; 388 } }), Object.defineProperty(e2, `join`, { enumerable: true, get: function() { 389 return t2.join; 390 } }), Object.defineProperty(e2, `relative`, { enumerable: true, get: function() { 391 return t2.relative; 392 } }), Object.defineProperty(e2, `dirname`, { enumerable: true, get: function() { 393 return t2.dirname; 394 } }), Object.defineProperty(e2, `normalize`, { enumerable: true, get: function() { 395 return t2.normalize; 396 } }), Object.defineProperty(e2, `isAbsolute`, { enumerable: true, get: function() { 397 return t2.isAbsolute; 398 } }), Object.defineProperty(e2, `basename`, { enumerable: true, get: function() { 399 return t2.basename; 400 } }); 401})), ne = i(((e2) => { 402 Object.defineProperty(e2, `__esModule`, { value: true }); 403})), re = i(((e2) => { 404 Object.defineProperties(e2, { __esModule: { value: true }, [Symbol.toStringTag]: { value: `Module` } }); 405 var t2 = {}, n2 = {}; 406 n2.byteLength = u2, n2.toByteArray = f2, n2.fromByteArray = h2; 407 for (var r2 = [], i2 = [], a2 = typeof Uint8Array < `u` ? Uint8Array : Array, o2 = `ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/`, s2 = 0, c2 = o2.length; s2 < c2; ++s2) r2[s2] = o2[s2], i2[o2.charCodeAt(s2)] = s2; 408 i2[45] = 62, i2[95] = 63; 409 function l2(e3) { 410 var t3 = e3.length; 411 if (t3 % 4 > 0) throw Error(`Invalid string. Length must be a multiple of 4`); 412 var n3 = e3.indexOf(`=`); 413 n3 === -1 && (n3 = t3); 414 var r3 = n3 === t3 ? 0 : 4 - n3 % 4; 415 return [n3, r3]; 416 } 417 function u2(e3) { 418 var t3 = l2(e3), n3 = t3[0], r3 = t3[1]; 419 return (n3 + r3) * 3 / 4 - r3; 420 } 421 function d2(e3, t3, n3) { 422 return (t3 + n3) * 3 / 4 - n3; 423 } 424 function f2(e3) { 425 var t3, n3 = l2(e3), r3 = n3[0], o3 = n3[1], s3 = new a2(d2(e3, r3, o3)), c3 = 0, u3 = o3 > 0 ? r3 - 4 : r3, f3; 426 for (f3 = 0; f3 < u3; f3 += 4) t3 = i2[e3.charCodeAt(f3)] << 18 | i2[e3.charCodeAt(f3 + 1)] << 12 | i2[e3.charCodeAt(f3 + 2)] << 6 | i2[e3.charCodeAt(f3 + 3)], s3[c3++] = t3 >> 16 & 255, s3[c3++] = t3 >> 8 & 255, s3[c3++] = t3 & 255; 427 return o3 === 2 && (t3 = i2[e3.charCodeAt(f3)] << 2 | i2[e3.charCodeAt(f3 + 1)] >> 4, s3[c3++] = t3 & 255), o3 === 1 && (t3 = i2[e3.charCodeAt(f3)] << 10 | i2[e3.charCodeAt(f3 + 1)] << 4 | i2[e3.charCodeAt(f3 + 2)] >> 2, s3[c3++] = t3 >> 8 & 255, s3[c3++] = t3 & 255), s3; 428 } 429 function p2(e3) { 430 return r2[e3 >> 18 & 63] + r2[e3 >> 12 & 63] + r2[e3 >> 6 & 63] + r2[e3 & 63]; 431 } 432 function m2(e3, t3, n3) { 433 for (var r3, i3 = [], a3 = t3; a3 < n3; a3 += 3) r3 = (e3[a3] << 16 & 16711680) + (e3[a3 + 1] << 8 & 65280) + (e3[a3 + 2] & 255), i3.push(p2(r3)); 434 return i3.join(``); 435 } 436 function h2(e3) { 437 for (var t3, n3 = e3.length, i3 = n3 % 3, a3 = [], o3 = 16383, s3 = 0, c3 = n3 - i3; s3 < c3; s3 += o3) a3.push(m2(e3, s3, s3 + o3 > c3 ? c3 : s3 + o3)); 438 return i3 === 1 ? (t3 = e3[n3 - 1], a3.push(r2[t3 >> 2] + r2[t3 << 4 & 63] + `==`)) : i3 === 2 && (t3 = (e3[n3 - 2] << 8) + e3[n3 - 1], a3.push(r2[t3 >> 10] + r2[t3 >> 4 & 63] + r2[t3 << 2 & 63] + `=`)), a3.join(``); 439 } 440 var g2 = {}; 441 g2.read = function(e3, t3, n3, r3, i3) { 442 var a3, o3, s3 = i3 * 8 - r3 - 1, c3 = (1 << s3) - 1, l3 = c3 >> 1, u3 = -7, d3 = n3 ? i3 - 1 : 0, f3 = n3 ? -1 : 1, p3 = e3[t3 + d3]; 443 for (d3 += f3, a3 = p3 & (1 << -u3) - 1, p3 >>= -u3, u3 += s3; u3 > 0; a3 = a3 * 256 + e3[t3 + d3], d3 += f3, u3 -= 8) ; 444 for (o3 = a3 & (1 << -u3) - 1, a3 >>= -u3, u3 += r3; u3 > 0; o3 = o3 * 256 + e3[t3 + d3], d3 += f3, u3 -= 8) ; 445 if (a3 === 0) a3 = 1 - l3; 446 else if (a3 === c3) return o3 ? NaN : (p3 ? -1 : 1) * (1 / 0); 447 else o3 += 2 ** r3, a3 -= l3; 448 return (p3 ? -1 : 1) * o3 * 2 ** (a3 - r3); 449 }, g2.write = function(e3, t3, n3, r3, i3, a3) { 450 var o3, s3, c3, l3 = a3 * 8 - i3 - 1, u3 = (1 << l3) - 1, d3 = u3 >> 1, f3 = i3 === 23 ? 2 ** -24 - 2 ** -77 : 0, p3 = r3 ? 0 : a3 - 1, m3 = r3 ? 1 : -1, h3 = +(t3 < 0 || t3 === 0 && 1 / t3 < 0); 451 for (t3 = Math.abs(t3), isNaN(t3) || t3 === 1 / 0 ? (s3 = +!!isNaN(t3), o3 = u3) : (o3 = Math.floor(Math.log(t3) / Math.LN2), t3 * (c3 = 2 ** -o3) < 1 && (o3--, c3 *= 2), o3 + d3 >= 1 ? t3 += f3 / c3 : t3 += f3 * 2 ** (1 - d3), t3 * c3 >= 2 && (o3++, c3 /= 2), o3 + d3 >= u3 ? (s3 = 0, o3 = u3) : o3 + d3 >= 1 ? (s3 = (t3 * c3 - 1) * 2 ** i3, o3 += d3) : (s3 = t3 * 2 ** (d3 - 1) * 2 ** i3, o3 = 0)); i3 >= 8; e3[n3 + p3] = s3 & 255, p3 += m3, s3 /= 256, i3 -= 8) ; 452 for (o3 = o3 << i3 | s3, l3 += i3; l3 > 0; e3[n3 + p3] = o3 & 255, p3 += m3, o3 /= 256, l3 -= 8) ; 453 e3[n3 + p3 - m3] |= h3 * 128; 454 }, (function(e3) { 455 let t3 = n2, r3 = g2, i3 = typeof Symbol == `function` && typeof Symbol.for == `function` ? /* @__PURE__ */ Symbol.for(`nodejs.util.inspect.custom`) : null; 456 e3.Buffer = d3, e3.SlowBuffer = C2, e3.INSPECT_MAX_BYTES = 50; 457 let a3 = 2147483647; 458 e3.kMaxLength = a3; 459 let { Uint8Array: o3, ArrayBuffer: s3, SharedArrayBuffer: c3 } = globalThis; 460 d3.TYPED_ARRAY_SUPPORT = l3(), !d3.TYPED_ARRAY_SUPPORT && typeof console < `u` && 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."); 461 function l3() { 462 try { 463 let e4 = new o3(1), t4 = { foo: function() { 464 return 42; 465 } }; 466 return Object.setPrototypeOf(t4, o3.prototype), Object.setPrototypeOf(e4, t4), e4.foo() === 42; 467 } catch { 468 return false; 469 } 470 } 471 Object.defineProperty(d3.prototype, `parent`, { enumerable: true, get: function() { 472 if (d3.isBuffer(this)) return this.buffer; 473 } }), Object.defineProperty(d3.prototype, `offset`, { enumerable: true, get: function() { 474 if (d3.isBuffer(this)) return this.byteOffset; 475 } }); 476 function u3(e4) { 477 if (e4 > a3) throw RangeError(`The value "` + e4 + `" is invalid for option "size"`); 478 let t4 = new o3(e4); 479 return Object.setPrototypeOf(t4, d3.prototype), t4; 480 } 481 function d3(e4, t4, n3) { 482 if (typeof e4 == `number`) { 483 if (typeof t4 == `string`) throw TypeError(`The "string" argument must be of type string. Received type number`); 484 return h3(e4); 485 } 486 return f3(e4, t4, n3); 487 } 488 d3.poolSize = 8192; 489 function f3(e4, t4, n3) { 490 if (typeof e4 == `string`) return _3(e4, t4); 491 if (s3.isView(e4)) return y2(e4); 492 if (e4 == null) throw TypeError(`The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type ` + typeof e4); 493 if (de2(e4, s3) || e4 && de2(e4.buffer, s3) || c3 !== void 0 && (de2(e4, c3) || e4 && de2(e4.buffer, c3))) return b2(e4, t4, n3); 494 if (typeof e4 == `number`) throw TypeError(`The "value" argument must not be of type number. Received type number`); 495 let r4 = e4.valueOf && e4.valueOf(); 496 if (r4 != null && r4 !== e4) return d3.from(r4, t4, n3); 497 let i4 = x2(e4); 498 if (i4) return i4; 499 if (typeof Symbol < `u` && Symbol.toPrimitive != null && typeof e4[Symbol.toPrimitive] == `function`) return d3.from(e4[Symbol.toPrimitive](`string`), t4, n3); 500 throw TypeError(`The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type ` + typeof e4); 501 } 502 d3.from = function(e4, t4, n3) { 503 return f3(e4, t4, n3); 504 }, Object.setPrototypeOf(d3.prototype, o3.prototype), Object.setPrototypeOf(d3, o3); 505 function p3(e4) { 506 if (typeof e4 != `number`) throw TypeError(`"size" argument must be of type number`); 507 if (e4 < 0) throw RangeError(`The value "` + e4 + `" is invali
507d for option "size"`); 508 } 509 function m3(e4, t4, n3) { 510 return p3(e4), e4 <= 0 || t4 === void 0 ? u3(e4) : typeof n3 == `string` ? u3(e4).fill(t4, n3) : u3(e4).fill(t4); 511 } 512 d3.alloc = function(e4, t4, n3) { 513 return m3(e4, t4, n3); 514 }; 515 function h3(e4) { 516 return p3(e4), u3(e4 < 0 ? 0 : S2(e4) | 0); 517 } 518 d3.allocUnsafe = function(e4) { 519 return h3(e4); 520 }, d3.allocUnsafeSlow = function(e4) { 521 return h3(e4); 522 }; 523 function _3(e4, t4) { 524 if ((typeof t4 != `string` || t4 === ``) && (t4 = `utf8`), !d3.isEncoding(t4)) throw TypeError(`Unknown encoding: ` + t4); 525 let n3 = w2(e4, t4) | 0, r4 = u3(n3), i4 = r4.write(e4, t4); 526 return i4 !== n3 && (r4 = r4.slice(0, i4)), r4; 527 } 528 function v2(e4) { 529 let t4 = e4.length < 0 ? 0 : S2(e4.length) | 0, n3 = u3(t4); 530 for (let r4 = 0; r4 < t4; r4 += 1) n3[r4] = e4[r4] & 255; 531 return n3; 532 } 533 function y2(e4) { 534 if (de2(e4, o3)) { 535 let t4 = new o3(e4); 536 return b2(t4.buffer, t4.byteOffset, t4.byteLength); 537 } 538 return v2(e4); 539 } 540 function b2(e4, t4, n3) { 541 if (t4 < 0 || e4.byteLength < t4) throw RangeError(`"offset" is outside of buffer bounds`); 542 if (e4.byteLength < t4 + (n3 || 0)) throw RangeError(`"length" is outside of buffer bounds`); 543 let r4; 544 return r4 = t4 === void 0 && n3 === void 0 ? new o3(e4) : n3 === void 0 ? new o3(e4, t4) : new o3(e4, t4, n3), Object.setPrototypeOf(r4, d3.prototype), r4; 545 } 546 function x2(e4) { 547 if (d3.isBuffer(e4)) { 548 let t4 = S2(e4.length) | 0, n3 = u3(t4); 549 return n3.length === 0 || e4.copy(n3, 0, 0, t4), n3; 550 } 551 if (e4.length !== void 0) return typeof e4.length != `number` || fe2(e4.length) ? u3(0) : v2(e4); 552 if (e4.type === `Buffer` && Array.isArray(e4.data)) return v2(e4.data); 553 } 554 function S2(e4) { 555 if (e4 >= a3) throw RangeError(`Attempt to allocate Buffer larger than maximum size: 0x` + a3.toString(16) + ` bytes`); 556 return e4 | 0; 557 } 558 function C2(e4) { 559 return +e4 != e4 && (e4 = 0), d3.alloc(+e4); 560 } 561 d3.isBuffer = function(e4) { 562 return e4 != null && e4._isBuffer === true && e4 !== d3.prototype; 563 }, d3.compare = function(e4, t4) { 564 if (de2(e4, o3) && (e4 = d3.from(e4, e4.offset, e4.byteLength)), de2(t4, o3) && (t4 = d3.from(t4, t4.offset, t4.byteLength)), !d3.isBuffer(e4) || !d3.isBuffer(t4)) throw TypeError(`The "buf1", "buf2" arguments must be one of type Buffer or Uint8Array`); 565 if (e4 === t4) return 0; 566 let n3 = e4.length, r4 = t4.length; 567 for (let i4 = 0, a4 = Math.min(n3, r4); i4 < a4; ++i4) if (e4[i4] !== t4[i4]) { 568 n3 = e4[i4], r4 = t4[i4]; 569 break; 570 } 571 return n3 < r4 ? -1 : +(r4 < n3); 572 }, d3.isEncoding = function(e4) { 573 switch (String(e4).toLowerCase()) { 574 case `hex`: 575 case `utf8`: 576 case `utf-8`: 577 case `ascii`: 578 case `latin1`: 579 case `binary`: 580 case `base64`: 581 case `ucs2`: 582 case `ucs-2`: 583 case `utf16le`: 584 case `utf-16le`: 585 return true; 586 default: 587 return false; 588 } 589 }, d3.concat = function(e4, t4) { 590 if (!Array.isArray(e4)) throw TypeError(`"list" argument must be an Array of Buffers`); 591 if (e4.length === 0) return d3.alloc(0); 592 let n3; 593 if (t4 === void 0) for (t4 = 0, n3 = 0; n3 < e4.length; ++n3) t4 += e4[n3].length; 594 let r4 = d3.allocUnsafe(t4), i4 = 0; 595 for (n3 = 0; n3 < e4.length; ++n3) { 596 let t5 = e4[n3]; 597 if (de2(t5, o3)) i4 + t5.length > r4.length ? (d3.isBuffer(t5) || (t5 = d3.from(t5)), t5.copy(r4, i4)) : o3.prototype.set.call(r4, t5, i4); 598 else if (d3.isBuffer(t5)) t5.copy(r4, i4); 599 else throw TypeError(`"list" argument must be an Array of Buffers`); 600 i4 += t5.length; 601 } 602 return r4; 603 }; 604 function w2(e4, t4) { 605 if (d3.isBuffer(e4)) return e4.length; 606 if (s3.isView(e4) || de2(e4, s3)) return e4.byteLength; 607 if (typeof e4 != `string`) throw TypeError(`The "string" argument must be one of type string, Buffer, or ArrayBuffer. Received type ` + typeof e4); 608 let n3 = e4.length, r4 = arguments.length > 2 && arguments[2] === true; 609 if (!r4 && n3 === 0) return 0; 610 let i4 = false;
vendor: 24,738 bytes, lines 611-1076
611 for (; ; ) switch (t4) { 612 case `ascii`: 613 case `latin1`: 614 case `binary`: 615 return n3; 616 case `utf8`: 617 case `utf-8`: 618 return oe2(e4).length; 619 case `ucs2`: 620 case `ucs-2`: 621 case `utf16le`: 622 case `utf-16le`: 623 return n3 * 2; 624 case `hex`: 625 return n3 >>> 1; 626 case `base64`: 627 return le2(e4).length; 628 default: 629 if (i4) return r4 ? -1 : oe2(e4).length; 630 t4 = (`` + t4).toLowerCase(), i4 = true; 631 } 632 } 633 d3.byteLength = w2; 634 function T2(e4, t4, n3) { 635 let r4 = false; 636 if ((t4 === void 0 || t4 < 0) && (t4 = 0), t4 > this.length || ((n3 === void 0 || n3 > this.length) && (n3 = this.length), n3 <= 0) || (n3 >>>= 0, t4 >>>= 0, n3 <= t4)) return ``; 637 for (e4 || (e4 = `utf8`); ; ) switch (e4) { 638 case `hex`: 639 return B2(this, t4, n3); 640 case `utf8`: 641 case `utf-8`: 642 return F2(this, t4, n3); 643 case `ascii`: 644 return R2(this, t4, n3); 645 case `latin1`: 646 case `binary`: 647 return z2(this, t4, n3); 648 case `base64`: 649 return P2(this, t4, n3); 650 case `ucs2`: 651 case `ucs-2`: 652 case `utf16le`: 653 case `utf-16le`: 654 return V2(this, t4, n3); 655 default: 656 if (r4) throw TypeError(`Unknown encoding: ` + e4); 657 e4 = (e4 + ``).toLowerCase(), r4 = true; 658 } 659 } 660 d3.prototype._isBuffer = true; 661 function E2(e4, t4, n3) { 662 let r4 = e4[t4]; 663 e4[t4] = e4[n3], e4[n3] = r4; 664 } 665 d3.prototype.swap16 = function() { 666 let e4 = this.length; 667 if (e4 % 2 != 0) throw RangeError(`Buffer size must be a multiple of 16-bits`); 668 for (let t4 = 0; t4 < e4; t4 += 2) E2(this, t4, t4 + 1); 669 return this; 670 }, d3.prototype.swap32 = function() { 671 let e4 = this.length; 672 if (e4 % 4 != 0) throw RangeError(`Buffer size must be a multiple of 32-bits`); 673 for (let t4 = 0; t4 < e4; t4 += 4) E2(this, t4, t4 + 3), E2(this, t4 + 1, t4 + 2); 674 return this; 675 }, d3.prototype.swap64 = function() { 676 let e4 = this.length; 677 if (e4 % 8 != 0) throw RangeError(`Buffer size must be a multiple of 64-bits`); 678 for (let t4 = 0; t4 < e4; t4 += 8) E2(this, t4, t4 + 7), E2(this, t4 + 1, t4 + 6), E2(this, t4 + 2, t4 + 5), E2(this, t4 + 3, t4 + 4); 679 return this; 680 }, d3.prototype.toString = function() { 681 let e4 = this.length; 682 return e4 === 0 ? `` : arguments.length === 0 ? F2(this, 0, e4) : T2.apply(this, arguments); 683 }, d3.prototype.toLocaleString = d3.prototype.toString, d3.prototype.equals = function(e4) { 684 if (!d3.isBuffer(e4)) throw TypeError(`Argument must be a Buffer`); 685 return this === e4 ? true : d3.compare(this, e4) === 0; 686 }, d3.prototype.inspect = function() { 687 let t4 = ``, n3 = e3.INSPECT_MAX_BYTES; 688 return t4 = this.toString(`hex`, 0, n3).replace(/(.{2})/g, `$1 `).trim(), this.length > n3 && (t4 += ` ... `), `<Buffer ` + t4 + `>`; 689 }, i3 && (d3.prototype[i3] = d3.prototype.inspect), d3.prototype.compare = function(e4, t4, n3, r4, i4) { 690 if (de2(e4, o3) && (e4 = d3.from(e4, e4.offset, e4.byteLength)), !d3.isBuffer(e4)) throw TypeError(`The "target" argument must be one of type Buffer or Uint8Array. Received type ` + typeof e4); 691 if (t4 === void 0 && (t4 = 0), n3 === void 0 && (n3 = e4 ? e4.length : 0), r4 === void 0 && (r4 = 0), i4 === void 0 && (i4 = this.length), t4 < 0 || n3 > e4.length || r4 < 0 || i4 > this.length) throw RangeError(`out of range index`); 692 if (r4 >= i4 && t4 >= n3) return 0; 693 if (r4 >= i4) return -1; 694 if (t4 >= n3) return 1; 695 if (t4 >>>= 0, n3 >>>= 0, r4 >>>= 0, i4 >>>= 0, this === e4) return 0; 696 let a4 = i4 - r4, s4 = n3 - t4, c4 = Math.min(a4, s4), l4 = this.slice(r4, i4), u4 = e4.slice(t4, n3); 697 for (let e5 = 0; e5 < c4; ++e5) if (l4[e5] !== u4[e5]) { 698 a4 = l4[e5], s4 = u4[e5]; 699 break; 700 } 701 return a4 < s4 ? -1 : +(s4 < a4); 702 }; 703 function D2(e4, t4, n3, r4, i4) { 704 if (e4.length === 0) return -1; 705 if (typeof n3 == `string` ? (r4 = n3, n3 = 0) : n3 > 2147483647 ? n3 = 2147483647 : n3 < -2147483648 && (n3 = -2147483648), n3 = +n3, fe2(n3) && (n3 = i4 ? 0 : e4.length - 1), n3 < 0 && (n3 = e4.length + n3), n3 >= e4.length) { 706 if (i4) return -1; 707 n3 = e4.length - 1; 708 } else if (n3 < 0) if (i4) n3 = 0; 709 else return -1; 710 if (typeof t4 == `string` && (t4 = d3.from(t4, r4)), d3.isBuffer(t4)) return t4.length === 0 ? -1 : O2(e4, t4, n3, r4, i4); 711 if (typeof t4 == `number`) return t4 &= 255, typeof o3.prototype.indexOf == `function` ? i4 ? o3.prototype.indexOf.call(e4, t4, n3) : o3.prototype.lastIndexOf.call(e4, t4, n3) : O2(e4, [t4], n3, r4, i4); 712 throw TypeError(`val must be string, number or Buffer`); 713 } 714 function O2(e4, t4, n3, r4, i4) { 715 let a4 = 1, o4 = e4.length, s4 = t4.length; 716 if (r4 !== void 0 && (r4 = String(r4).toLowerCase(), r4 === `ucs2` || r4 === `ucs-2` || r4 === `utf16le` || r4 === `utf-16le`)) { 717 if (e4.length < 2 || t4.length < 2) return -1; 718 a4 = 2, o4 /= 2, s4 /= 2, n3 /= 2; 719 } 720 function c4(e5, t5) { 721 return a4 === 1 ? e5[t5] : e5.readUInt16BE(t5 * a4); 722 } 723 let l4; 724 if (i4) { 725 let r5 = -1; 726 for (l4 = n3; l4 < o4; l4++) if (c4(e4, l4) === c4(t4, r5 === -1 ? 0 : l4 - r5)) { 727 if (r5 === -1 && (r5 = l4), l4 - r5 + 1 === s4) return r5 * a4; 728 } else r5 !== -1 && (l4 -= l4 - r5), r5 = -1; 729 } else for (n3 + s4 > o4 && (n3 = o4 - s4), l4 = n3; l4 >= 0; l4--) { 730 let n4 = true; 731 for (let r5 = 0; r5 < s4; r5++) if (c4(e4, l4 + r5) !== c4(t4, r5)) { 732 n4 = false; 733 break; 734 } 735 if (n4) return l4; 736 } 737 return -1; 738 } 739 d3.prototype.includes = function(e4, t4, n3) { 740 return this.indexOf(e4, t4, n3) !== -1; 741 }, d3.prototype.indexOf = function(e4, t4, n3) { 742 return D2(this, e4, t4, n3, true); 743 }, d3.prototype.lastIndexOf = function(e4, t4, n3) { 744 return D2(this, e4, t4, n3, false); 745 }; 746 function k2(e4, t4, n3, r4) { 747 n3 = Number(n3) || 0; 748 let i4 = e4.length - n3; 749 r4 ? (r4 = Number(r4), r4 > i4 && (r4 = i4)) : r4 = i4; 750 let a4 = t4.length; 751 r4 > a4 / 2 && (r4 = a4 / 2); 752 let o4; 753 for (o4 = 0; o4 < r4; ++o4) { 754 let r5 = parseInt(t4.substr(o4 * 2, 2), 16); 755 if (fe2(r5)) return o4; 756 e4[n3 + o4] = r5; 757 } 758 return o4; 759 } 760 function A2(e4, t4, n3, r4) { 761 return ue2(oe2(t4, e4.length - n3), e4, n3, r4); 762 } 763 function j2(e4, t4, n3, r4) { 764 return ue2(se2(t4), e4, n3, r4); 765 } 766 function M2(e4, t4, n3, r4) { 767 return ue2(le2(t4), e4, n3, r4); 768 } 769 function N2(e4, t4, n3, r4) { 770 return ue2(ce2(t4, e4.length - n3), e4, n3, r4); 771 } 772 d3.prototype.write = function(e4, t4, n3, r4) { 773 if (t4 === void 0) r4 = `utf8`, n3 = this.length, t4 = 0; 774 else if (n3 === void 0 && typeof t4 == `string`) r4 = t4, n3 = this.length, t4 = 0; 775 else if (isFinite(t4)) t4 >>>= 0, isFinite(n3) ? (n3 >>>= 0, r4 === void 0 && (r4 = `utf8`)) : (r4 = n3, n3 = void 0); 776 else throw Error(`Buffer.write(string, encoding, offset[, length]) is no longer supported`); 777 let i4 = this.length - t4; 778 if ((n3 === void 0 || n3 > i4) && (n3 = i4), e4.length > 0 && (n3 < 0 || t4 < 0) || t4 > this.length) throw RangeError(`Attempt to write outside buffer bounds`); 779 r4 || (r4 = `utf8`); 780 let a4 = false; 781 for (; ; ) switch (r4) { 782 case `hex`: 783 return k2(this, e4, t4, n3); 784 case `utf8`: 785 case `utf-8`: 786 return A2(this, e4, t4, n3); 787 case `ascii`: 788 case `latin1`: 789 case `binary`: 790 return j2(this, e4, t4, n3); 791 case `base64`: 792 return M2(this, e4, t4, n3); 793 case `ucs2`: 794 case `ucs-2`: 795 case `utf16le`: 796 case `utf-16le`: 797 return N2(this, e4, t4, n3); 798 default: 799 if (a4) throw TypeError(`Unknown encoding: ` + r4); 800 r4 = (`` + r4).toLowerCase(), a4 = true; 801 } 802 }, d3.prototype.toJSON = function() { 803 return { type: `Buffer`, data: Array.prototype.slice.call(this._arr || this, 0) }; 804 }; 805 function P2(e4, n3, r4) { 806 return n3 === 0 && r4 === e4.length ? t3.fromByteArray(e4) : t3.fromByteArray(e4.slice(n3, r4)); 807 } 808 function F2(e4, t4, n3) { 809 n3 = Math.min(e4.length, n3); 810 let r4 = [], i4 = t4; 811 for (; i4 < n3; ) { 812 let t5 = e4[i4], a4 = null, o4 = t5 > 239 ? 4 : t5 > 223 ? 3 : t5 > 191 ? 2 : 1; 813 if (i4 + o4 <= n3) { 814 let n4, r5, s4, c4; 815 switch (o4) { 816 case 1: 817 t5 < 128 && (a4 = t5); 818 break; 819 case 2: 820 n4 = e4[i4 + 1], (n4 & 192) == 128 && (c4 = (t5 & 31) << 6 | n4 & 63, c4 > 127 && (a4 = c4)); 821 break; 822 case 3: 823 n4 = e4[i4 + 1], r5 = e4[i4 + 2], (n4 & 192) == 128 && (r5 & 192) == 128 && (c4 = (t5 & 15) << 12 | (n4 & 63) << 6 | r5 & 63, c4 > 2047 && (c4 < 55296 || c4 > 57343) && (a4 = c4)); 824 break; 825 case 4: 826 n4 = e4[i4 + 1], r5 = e4[i4 + 2], s4 = e4[i4 + 3], (n4 & 192) == 128 && (r5 & 192) == 128 && (s4 & 192) == 128 && (c4 = (t5 & 15) << 18 | (n4 & 63) << 12 | (r5 & 63) << 6 | s4 & 63, c4 > 65535 && c4 < 1114112 && (a4 = c4)); 827 } 828 } 829 a4 === null ? (a4 = 65533, o4 = 1) : a4 > 65535 && (a4 -= 65536, r4.push(a4 >>> 10 & 1023 | 55296), a4 = 56320 | a4 & 1023), r4.push(a4), i4 += o4; 830 } 831 return L2(r4); 832 } 833 let I2 = 4096; 834 function L2(e4) { 835 let t4 = e4.length; 836 if (t4 <= I2) return String.fromCharCode.apply(String, e4); 837 let n3 = ``, r4 = 0; 838 for (; r4 < t4; ) n3 += String.fromCharCode.apply(String, e4.slice(r4, r4 += I2)); 839 return n3; 840 } 841 function R2(e4, t4, n3) { 842 let r4 = ``; 843 n3 = Math.min(e4.length, n3); 844 for (let i4 = t4; i4 < n3; ++i4) r4 += String.fromCharCode(e4[i4] & 127); 845 return r4; 846 } 847 function z2(e4, t4, n3) { 848 let r4 = ``; 849 n3 = Math.min(e4.length, n3); 850 for (let i4 = t4; i4 < n3; ++i4) r4 += String.fromCharCode(e4[i4]); 851 return r4; 852 } 853 function B2(e4, t4, n3) { 854 let r4 = e4.length; 855 (!t4 || t4 < 0) && (t4 = 0), (!n3 || n3 < 0 || n3 > r4) && (n3 = r4); 856 let i4 = ``; 857 for (let r5 = t4; r5 < n3; ++r5) i4 += pe2[e4[r5]]; 858 return i4; 859 } 860 function V2(e4, t4, n3) { 861 let r4 = e4.slice(t4, n3), i4 = ``; 862 for (let e5 = 0; e5 < r4.length - 1; e5 += 2) i4 += String.fromCharCode(r4[e5] + r4[e5 + 1] * 256); 863 return i4; 864 } 865 d3.prototype.slice = function(e4, t4) { 866 let n3 = this.length; 867 e4 = ~~e4, t4 = t4 === void 0 ? n3 : ~~t4, e4 < 0 ? (e4 += n3, e4 < 0 && (e4 = 0)) : e4 > n3 && (e4 = n3), t4 < 0 ? (t4 += n3, t4 < 0 && (t4 = 0)) : t4 > n3 && (t4 = n3), t4 < e4 && (t4 = e4); 868 let r4 = this.subarray(e4, t4); 869 return Object.setPrototypeOf(r4, d3.prototype), r4; 870 }; 871 function H2(e4, t4, n3) { 872 if (e4 % 1 != 0 || e4 < 0) throw RangeError(`offset is not uint`); 873 if (e4 + t4 > n3) throw RangeError(`Trying to access beyond buffer length`); 874 } 875 d3.prototype.readUintLE = d3.prototype.readUIntLE = function(e4, t4, n3) { 876 e4 >>>= 0, t4 >>>= 0, n3 || H2(e4, t4, this.length); 877 let r4 = this[e4], i4 = 1, a4 = 0; 878 for (; ++a4 < t4 && (i4 *= 256); ) r4 += this[e4 + a4] * i4; 879 return r4; 880 }, d3.prototype.readUintBE = d3.prototype.readUIntBE = function(e4, t4, n3) { 881 e4 >>>= 0, t4 >>>= 0, n3 || H2(e4, t4, this.length); 882 let r4 = this[e4 + --t4], i4 = 1; 883 for (; t4 > 0 && (i4 *= 256); ) r4 += this[e4 + --t4] * i4; 884 return r4; 885 }, d3.prototype.readUint8 = d3.prototype.readUInt8 = function(e4, t4) { 886 return e4 >>>= 0, t4 || H2(e4, 1, this.length), this[e4]; 887 }, d3.prototype.readUint16LE = d3.prototype.readUInt16LE = function(e4, t4) { 888 return e4 >>>= 0, t4 || H2(e4, 2, this.length), this[e4] | this[e4 + 1] << 8; 889 }, d3.prototype.readUint16BE = d3.prototype.readUInt16BE = function(e4, t4) { 890 return e4 >>>= 0, t4 || H2(e4, 2, this.length), this[e4] << 8 | this[e4 + 1]; 891 }, d3.prototype.readUint32LE = d3.prototype.readUInt32LE = function(e4, t4) { 892 return e4 >>>= 0, t4 || H2(e4, 4, this.length), (this[e4] | this[e4 + 1] << 8 | this[e4 + 2] << 16) + this[e4 + 3] * 16777216; 893 }, d3.prototype.readUint32BE = d3.prototype.readUInt32BE = function(e4, t4) { 894 return e4 >>>= 0, t4 || H2(e4, 4, this.length), this[e4] * 16777216 + (this[e4 + 1] << 16 | this[e4 + 2] << 8 | this[e4 + 3]); 895 }, d3.prototype.readBigUInt64LE = Q2(function(e4) { 896 e4 >>>= 0, X2(e4, `offset`); 897 let t4 = this[e4], n3 = this[e4 + 7]; 898 (t4 === void 0 || n3 === void 0) && Z2(e4, this.length - 8); 899 let r4 = t4 + this[++e4] * 2 ** 8 + this[++e4] * 2 ** 16 + this[++e4] * 2 ** 24, i4 = this[++e4] + this[++e4] * 2 ** 8 + this[++e4] * 2 ** 16 + n3 * 2 ** 24; 900 return BigInt(r4) + (BigInt(i4) << BigInt(32)); 901 }), d3.prototype.readBigUInt64BE = Q2(function(e4) { 902 e4 >>>= 0, X2(e4, `offset`); 903 let t4 = this[e4], n3 = this[e4 + 7]; 904 (t4 === void 0 || n3 === void 0) && Z2(e4, this.length - 8); 905 let r4 = t4 * 2 ** 24 + this[++e4] * 2 ** 16 + this[++e4] * 2 ** 8 + this[++e4], i4 = this[++e4] * 2 ** 24 + this[++e4] * 2 ** 16 + this[++e4] * 2 ** 8 + n3; 906 return (BigInt(r4) << BigInt(32)) + BigInt(i4); 907 }), d3.prototype.readIntLE = function(e4, t4, n3) { 908 e4 >>>= 0, t4 >>>= 0, n3 || H2(e4, t4, this.length); 909 let r4 = this[e4], i4 = 1, a4 = 0; 910 for (; ++a4 < t4 && (i4 *= 256); ) r4 += this[e4 + a4] * i4; 911 return i4 *= 128, r4 >= i4 && (r4 -= 2 ** (8 * t4)), r4; 912 }, d3.prototype.readIntBE = function(e4, t4, n3) { 913 e4 >>>= 0, t4 >>>= 0, n3 || H2(e4, t4, this.length); 914 let r4 = t4, i4 = 1, a4 = this[e4 + --r4]; 915 for (; r4 > 0 && (i4 *= 256); ) a4 += this[e4 + --r4] * i4; 916 return i4 *= 128, a4 >= i4 && (a4 -= 2 ** (8 * t4)), a4; 917 }, d3.prototype.readInt8 = function(e4, t4) { 918 return e4 >>>= 0, t4 || H2(e4, 1, this.length), this[e4] & 128 ? (255 - this[e4] + 1) * -1 : this[e4]; 919 }, d3.prototype.readInt16LE = function(e4, t4) { 920 e4 >>>= 0, t4 || H2(e4, 2, this.length); 921 let n3 = this[e4] | this[e4 + 1] << 8; 922 return n3 & 32768 ? n3 | 4294901760 : n3; 923 }, d3.prototype.readInt16BE = function(e4, t4) { 924 e4 >>>= 0, t4 || H2(e4, 2, this.length); 925 let n3 = this[e4 + 1] | this[e4] << 8; 926 return n3 & 32768 ? n3 | 4294901760 : n3; 927 }, d3.prototype.readInt32LE = function(e4, t4) { 928 return e4 >>>= 0, t4 || H2(e4, 4, this.length), this[e4] | this[e4 + 1] << 8 | this[e4 + 2] << 16 | this[e4 + 3] << 24; 929 }, d3.prototype.readInt32BE = function(e4, t4) { 930 return e4 >>>= 0, t4 || H2(e4, 4, this.length), this[e4] << 24 | this[e4 + 1] << 16 | this[e4 + 2] << 8 | this[e4 + 3]; 931 }, d3.prototype.readBigInt64LE = Q2(function(e4) { 932 e4 >>>= 0, X2(e4, `offset`); 933 let t4 = this[e4], n3 = this[e4 + 7]; 934 (t4 === void 0 || n3 === void 0) && Z2(e4, this.length - 8); 935 let r4 = this[e4 + 4] + this[e4 + 5] * 2 ** 8 + this[e4 + 6] * 2 ** 16 + (n3 << 24); 936 return (BigInt(r4) << BigInt(32)) + BigInt(t4 + this[++e4] * 2 ** 8 + this[++e4] * 2 ** 16 + this[++e4] * 2 ** 24); 937 }), d3.prototype.readBigInt64BE = Q2(function(e4) { 938 e4 >>>= 0, X2(e4, `offset`); 939 let t4 = this[e4], n3 = this[e4 + 7]; 940 (t4 === void 0 || n3 === void 0) && Z2(e4, this.length - 8); 941 let r4 = (t4 << 24) + this[++e4] * 2 ** 16 + this[++e4] * 2 ** 8 + this[++e4]; 942 return (BigInt(r4) << BigInt(32)) + BigInt(this[++e4] * 2 ** 24 + this[++e4] * 2 ** 16 + this[++e4] * 2 ** 8 + n3); 943 }), d3.prototype.readFloatLE = function(e4, t4) { 944 return e4 >>>= 0, t4 || H2(e4, 4, this.length), r3.read(this, e4, true, 23, 4); 945 }, d3.prototype.readFloatBE = function(e4, t4) { 946 return e4 >>>= 0, t4 || H2(e4, 4, this.length), r3.read(this, e4, false, 23, 4); 947 }, d3.prototype.readDoubleLE = function(e4, t4) { 948 return e4 >>>= 0, t4 || H2(e4, 8, this.length), r3.read(this, e4, true, 52, 8); 949 }, d3.prototype.readDoubleBE = function(e4, t4) { 950 return e4 >>>= 0, t4 || H2(e4, 8, this.length), r3.read(this, e4, false, 52, 8); 951 }; 952 function U2(e4, t4, n3, r4, i4, a4) { 953 if (!d3.isBuffer(e4)) throw TypeError(`"buffer" argument must be a Buffer instance`); 954 if (t4 > i4 || t4 < a4) throw RangeError(`"value" argument is out of bounds`); 955 if (n3 + r4 > e4.length) throw RangeError(`Index out of range`); 956 } 957 d3.prototype.writeUintLE = d3.prototype.writeUIntLE = function(e4, t4, n3, r4) { 958 if (e4 = +e4, t4 >>>= 0, n3 >>>= 0, !r4) { 959 let r5 = 2 ** (8 * n3) - 1; 960 U2(this, e4, t4, n3, r5, 0); 961 } 962 let i4 = 1, a4 = 0; 963 for (this[t4] = e4 & 255; ++a4 < n3 && (i4 *= 256); ) this[t4 + a4] = e4 / i4 & 255; 964 return t4 + n3; 965 }, d3.prototype.writeUintBE = d3.prototype.writeUIntBE = function(e4, t4, n3, r4) { 966 if (e4 = +e4, t4 >>>= 0, n3 >>>= 0, !r4) { 967 let r5 = 2 ** (8 * n3) - 1; 968 U2(this, e4, t4, n3, r5, 0); 969 } 970 let i4 = n3 - 1, a4 = 1; 971 for (this[t4 + i4] = e4 & 255; --i4 >= 0 && (a4 *= 256); ) this[t4 + i4] = e4 / a4 & 255; 972 return t4 + n3; 973 }, d3.prototype.writeUint8 = d3.prototype.writeUInt8 = function(e4, t4, n3) { 974 return e4 = +e4, t4 >>>= 0, n3 || U2(this, e4, t4, 1, 255, 0), this[t4] = e4 & 255, t4 + 1; 975 }, d3.prototype.writeUint16LE = d3.prototype.writeUInt16LE = function(e4, t4, n3) { 976 return e4 = +e4, t4 >>>= 0, n3 || U2(this, e4, t4, 2, 65535, 0), this[t4] = e4 & 255, this[t4 + 1] = e4 >>> 8, t4 + 2; 977 }, d3.prototype.writeUint16BE = d3.prototype.writeUInt16BE = function(e4, t4, n3) { 978 return e4 = +e4, t4 >>>= 0, n3 || U2(this, e4, t4, 2, 65535, 0), this[t4] = e4 >>> 8, this[t4 + 1] = e4 & 255, t4 + 2; 979 }, d3.prototype.writeUint32LE = d3.prototype.writeUInt32LE = function(e4, t4, n3) { 980 return e4 = +e4, t4 >>>= 0, n3 || U2(this, e4, t4, 4, 4294967295, 0), this[t4 + 3] = e4 >>> 24, this[t4 + 2] = e4 >>> 16, this[t4 + 1] = e4 >>> 8, this[t4] = e4 & 255, t4 + 4; 981 }, d3.prototype.writeUint32BE = d3.prototype.writeUInt32BE = function(e4, t4, n3) { 982 return e4 = +e4, t4 >>>= 0, n3 || U2(this, e4, t4, 4, 4294967295, 0), this[t4] = e4 >>> 24, this[t4 + 1] = e4 >>> 16, this[t4 + 2] = e4 >>> 8, this[t4 + 3] = e4 & 255, t4 + 4; 983 }; 984 function W2(e4, t4, n3, r4, i4) { 985 re2(t4, r4, i4, e4, n3, 7); 986 let a4 = Number(t4 & BigInt(4294967295)); 987 e4[n3++] = a4, a4 >>= 8, e4[n3++] = a4, a4 >>= 8, e4[n3++] = a4, a4 >>= 8, e4[n3++] = a4; 988 let o4 = Number(t4 >> BigInt(32) & BigInt(4294967295)); 989 return e4[n3++] = o4, o4 >>= 8, e4[n3++] = o4, o4 >>= 8, e4[n3++] = o4, o4 >>= 8, e4[n3++] = o4, n3; 990 } 991 function G2(e4, t4, n3, r4, i4) { 992 re2(t4, r4, i4, e4, n3, 7); 993 let a4 = Number(t4 & BigInt(4294967295)); 994 e4[n3 + 7] = a4, a4 >>= 8, e4[n3 + 6] = a4, a4 >>= 8, e4[n3 + 5] = a4, a4 >>= 8, e4[n3 + 4] = a4; 995 let o4 = Number(t4 >> BigInt(32) & BigInt(4294967295)); 996 return e4[n3 + 3] = o4, o4 >>= 8, e4[n3 + 2] = o4, o4 >>= 8, e4[n3 + 1] = o4, o4 >>= 8, e4[n3] = o4, n3 + 8; 997 } 998 d3.prototype.writeBigUInt64LE = Q2(function(e4, t4 = 0) { 999 return W2(this, e4, t4, BigInt(0), BigInt(`0xffffffffffffffff`)); 1000 }), d3.prototype.writeBigUInt64BE = Q2(function(e4, t4 = 0) { 1001 return G2(this, e4, t4, BigInt(0), BigInt(`0xffffffffffffffff`)); 1002 }), d3.prototype.writeIntLE = function(e4, t4, n3, r4) { 1003 if (e4 = +e4, t4 >>>= 0, !r4) { 1004 let r5 = 2 ** (8 * n3 - 1); 1005 U2(this, e4, t4, n3, r5 - 1, -r5); 1006 } 1007 let i4 = 0, a4 = 1, o4 = 0; 1008 for (this[t4] = e4 & 255; ++i4 < n3 && (a4 *= 256); ) e4 < 0 && o4 === 0 && this[t4 + i4 - 1] !== 0 && (o4 = 1), this[t4 + i4] = (e4 / a4 >> 0) - o4 & 255; 1009 return t4 + n3; 1010 }, d3.prototype.writeIntBE = function(e4, t4, n3, r4) { 1011 if (e4 = +e4, t4 >>>= 0, !r4) { 1012 let r5 = 2 ** (8 * n3 - 1); 1013 U2(this, e4, t4, n3, r5 - 1, -r5); 1014 } 1015 let i4 = n3 - 1, a4 = 1, o4 = 0; 1016 for (this[t4 + i4] = e4 & 255; --i4 >= 0 && (a4 *= 256); ) e4 < 0 && o4 === 0 && this[t4 + i4 + 1] !== 0 && (o4 = 1), this[t4 + i4] = (e4 / a4 >> 0) - o4 & 255; 1017 return t4 + n3; 1018 }, d3.prototype.writeInt8 = function(e4, t4, n3) { 1019 return e4 = +e4, t4 >>>= 0, n3 || U2(this, e4, t4, 1, 127, -128), e4 < 0 && (e4 = 255 + e4 + 1), this[t4] = e4 & 255, t4 + 1; 1020 }, d3.prototype.writeInt16LE = function(e4, t4, n3) { 1021 return e4 = +e4, t4 >>>= 0, n3 || U2(this, e4, t4, 2, 32767, -32768), this[t4] = e4 & 255, this[t4 + 1] = e4 >>> 8, t4 + 2; 1022 }, d3.prototype.writeInt16BE = function(e4, t4, n3) { 1023 return e4 = +e4, t4 >>>= 0, n3 || U2(this, e4, t4, 2, 32767, -32768), this[t4] = e4 >>> 8, this[t4 + 1] = e4 & 255, t4 + 2; 1024 }, d3.prototype.writeInt32LE = function(e4, t4, n3) { 1025 return e4 = +e4, t4 >>>= 0, n3 || U2(this, e4, t4, 4, 2147483647, -2147483648), this[t4] = e4 & 255, this[t4 + 1] = e4 >>> 8, this[t4 + 2] = e4 >>> 16, this[t4 + 3] = e4 >>> 24, t4 + 4; 1026 }, d3.prototype.writeInt32BE = function(e4, t4, n3) { 1027 return e4 = +e4, t4 >>>= 0, n3 || U2(this, e4, t4, 4, 2147483647, -2147483648), e4 < 0 && (e4 = 4294967295 + e4 + 1), this[t4] = e4 >>> 24, this[t4 + 1] = e4 >>> 16, this[t4 + 2] = e4 >>> 8, this[t4 + 3] = e4 & 255, t4 + 4; 1028 }, d3.prototype.writeBigInt64LE = Q2(function(e4, t4 = 0) { 1029 return W2(this, e4, t4, -BigInt(`0x8000000000000000`), BigInt(`0x7fffffffffffffff`)); 1030 }), d3.prototype.writeBigInt64BE = Q2(function(e4, t4 = 0) { 1031 return G2(this, e4, t4, -BigInt(`0x8000000000000000`), BigInt(`0x7fffffffffffffff`)); 1032 }); 1033 function ee2(e4, t4, n3, r4, i4, a4) { 1034 if (n3 + r4 > e4.length || n3 < 0) throw RangeError(`Index out of range`); 1035 } 1036 function K2(e4, t4, n3, i4, a4) { 1037 return t4 = +t4, n3 >>>= 0, a4 || ee2(e4, t4, n3, 4), r3.write(e4, t4, n3, i4, 23, 4), n3 + 4; 1038 } 1039 d3.prototype.writeFloatLE = function(e4, t4, n3) { 1040 return K2(this, e4, t4, true, n3); 1041 }, d3.prototype.writeFloatBE = function(e4, t4, n3) { 1042 return K2(this, e4, t4, false, n3); 1043 }; 1044 function te2(e4, t4, n3, i4, a4) { 1045 return t4 = +t4, n3 >>>= 0, a4 || ee2(e4, t4, n3, 8), r3.write(e4, t4, n3, i4, 52, 8), n3 + 8; 1046 } 1047 d3.prototype.writeDoubleLE = function(e4, t4, n3) { 1048 return te2(this, e4, t4, true, n3); 1049 }, d3.prototype.writeDoubleBE = function(e4, t4, n3) { 1050 return te2(this, e4, t4, false, n3); 1051 }, d3.prototype.copy = function(e4, t4, n3, r4) { 1052 if (!d3.isBuffer(e4)) throw TypeError(`argument should be a Buffer`); 1053 if (n3 || (n3 = 0), !r4 && r4 !== 0 && (r4 = this.length), t4 >= e4.length && (t4 = e4.length), t4 || (t4 = 0), r4 > 0 && r4 < n3 && (r4 = n3), r4 === n3 || e4.length === 0 || this.length === 0) return 0; 1054 if (t4 < 0) throw RangeError(`targetStart out of bounds`); 1055 if (n3 < 0 || n3 >= this.length) throw RangeError(`Index out of range`); 1056 if (r4 < 0) throw RangeError(`sourceEnd out of bounds`); 1057 r4 > this.length && (r4 = this.length), e4.length - t4 < r4 - n3 && (r4 = e4.length - t4 + n3); 1058 let i4 = r4 - n3; 1059 return this === e4 && typeof o3.prototype.copyWithin == `function` ? this.copyWithin(t4, n3, r4) : o3.prototype.set.call(e4, this.subarray(n3, r4), t4), i4; 1060 }, d3.prototype.fill = function(e4, t4, n3, r4) { 1061 if (typeof e4 == `string`) { 1062 if (typeof t4 == `string` ? (r4 = t4, t4 = 0, n3 = this.length) : typeof n3 == `string` && (r4 = n3, n3 = this.length), r4 !== void 0 && typeof r4 != `string`) throw TypeError(`encoding must be a string`); 1063 if (typeof r4 == `string` && !d3.isEncoding(r4)) throw TypeError(`Unknown encoding: ` + r4); 1064 if (e4.length === 1) { 1065 let t5 = e4.charCodeAt(0); 1066 (r4 === `utf8` && t5 < 128 || r4 === `latin1`) && (e4 = t5); 1067 } 1068 } else typeof e4 == `number` ? e4 &= 255 : typeof e4 == `boolean` && (e4 = Number(e4)); 1069 if (t4 < 0 || this.length < t4 || this.length < n3) throw RangeError(`Out of range index`); 1070 if (n3 <= t4) return this; 1071 t4 >>>= 0, n3 = n3 === void 0 ? this.length : n3 >>> 0, e4 || (e4 = 0); 1072 let i4; 1073 if (typeof e4 == `number`) for (i4 = t4; i4 < n3; ++i4) this[i4] = e4; 1074 else { 1075 let a4 = d3.isBuffer(e4) ? e4 : d3.from(e4, r4), o4 = a4.length; 1076 if (o4 === 0) throw TypeError(`The value "` + e4 + `" is invali
1076d for argument "value"`); 1077 for (i4 = 0; i4 < n3 - t4; ++i4) this[i4 + t4] = a4[i4 % o4]; 1078 } 1079 return this; 1080 }; 1081 let q2 = {}; 1082 function J2(e4, t4, n3) { 1083 q2[e4] = class extends n3 { 1084 constructor() { 1085 super(), Object.defineProperty(this, `message`, { value: t4.apply(this, arguments), writable: true, configurable: true }), this.name = `${this.name} [${e4}]`, this.stack, delete this.name; 1086 } 1087 get code() { 1088 return e4; 1089 } 1090 set code(e5) { 1091 Object.defineProperty(this, `code`, { configurable: true, enumerable: true, value: e5, writable: true }); 1092 } 1093 toString() { 1094 return `${this.name} [${e4}]: ${this.message}`; 1095 } 1096 }; 1097 } 1098 J2(`ERR_BUFFER_OUT_OF_BOUNDS`, function(e4) { 1099 return e4 ? `${e4} is outside of buffer bounds` : `Attempt to access memory outside buffer bounds`; 1100 }, RangeError), J2(`ERR_INVALID_ARG_TYPE`, function(e4, t4) { 1101 return `The "${e4}" argument must be of type number. Received type ${typeof t4}`; 1102 }, TypeError), J2(`ERR_OUT_OF_RANGE`, function(e4, t4, n3) { 1103 let r4 = `The value of "${e4}" is out of range.`, i4 = n3; 1104 return Number.isInteger(n3) && Math.abs(n3) > 2 ** 32 ? i4 = Y2(String(n3)) : typeof n3 == `bigint` && (i4 = String(n3), (n3 > BigInt(2) ** BigInt(32) || n3 < -(BigInt(2) ** BigInt(32))) && (i4 = Y2(i4)), i4 += `n`), r4 += ` It must be ${t4}. Received ${i4}`, r4; 1105 }, RangeError); 1106 function Y2(e4) { 1107 let t4 = ``, n3 = e4.length, r4 = +(e4[0] === `-`); 1108 for (; n3 >= r4 + 4; n3 -= 3) t4 = `_${e4.slice(n3 - 3, n3)}${t4}`; 1109 return `${e4.slice(0, n3)}${t4}`; 1110 } 1111 function ne2(e4, t4, n3) { 1112 X2(t4, `offset`), (e4[t4] === void 0 || e4[t4 + n3] === void 0) && Z2(t4, e4.length - (n3 + 1)); 1113 } 1114 function re2(e4, t4, n3, r4, i4, a4) { 1115 if (e4 > n3 || e4 < t4) { 1116 let r5 = typeof t4 == `bigint` ? `n` : ``, i5; 1117 throw i5 = a4 > 3 ? t4 === 0 || t4 === BigInt(0) ? `>= 0${r5} and < 2${r5} ** ${(a4 + 1) * 8}${r5}` : `>= -(2${r5} ** ${(a4 + 1) * 8 - 1}${r5}) and < 2 ** ${(a4 + 1) * 8 - 1}${r5}` : `>= ${t4}${r5} and <= ${n3}${r5}`, new q2.ERR_OUT_OF_RANGE(`value`, i5, e4); 1118 } 1119 ne2(r4, i4, a4); 1120 } 1121 function X2(e4, t4) { 1122 if (typeof e4 != `number`) throw new q2.ERR_INVALID_ARG_TYPE(t4, `number`, e4); 1123 } 1124 function Z2(e4, t4, n3) { 1125 throw Math.floor(e4) === e4 ? t4 < 0 ? new q2.ERR_BUFFER_OUT_OF_BOUNDS() : new q2.ERR_OUT_OF_RANGE(n3 || `offset`, `>= ${+!!n3} and <= ${t4}`, e4) : (X2(e4, n3), new q2.ERR_OUT_OF_RANGE(n3 || `offset`, `an integer`, e4)); 1126 } 1127 let ie2 = /[^+/0-9A-Za-z-_]/g; 1128 function ae2(e4) { 1129 if (e4 = e4.split(`=`)[0], e4 = e4.trim().replace(ie2, ``), e4.length < 2) return ``; 1130 for (; e4.length % 4 != 0; ) e4 += `=`; 1131 return e4; 1132 } 1133 function oe2(e4, t4) { 1134 t4 || (t4 = 1 / 0); 1135 let n3, r4 = e4.length, i4 = null, a4 = []; 1136 for (let o4 = 0; o4 < r4; ++o4) { 1137 if (n3 = e4.charCodeAt(o4), n3 > 55295 && n3 < 57344) { 1138 if (!i4) { 1139 if (n3 > 56319) { 1140 (t4 -= 3) > -1 && a4.push(239, 191, 189); 1141 continue; 1142 } else if (o4 + 1 === r4) { 1143 (t4 -= 3) > -1 && a4.push(239, 191, 189); 1144 continue; 1145 } 1146 i4 = n3; 1147 continue; 1148 } 1149 if (n3 < 56320) { 1150 (t4 -= 3) > -1 && a4.push(239, 191, 189), i4 = n3; 1151 continue; 1152 } 1153 n3 = (i4 - 55296 << 10 | n3 - 56320) + 65536; 1154 } else i4 && (t4 -= 3) > -1 && a4.push(239, 191, 189); 1155 if (i4 = null, n3 < 128) { 1156 if (--t4 < 0) break; 1157 a4.push(n3); 1158 } else if (n3 < 2048) { 1159 if ((t4 -= 2) < 0) break; 1160 a4.push(n3 >> 6 | 192, n3 & 63 | 128); 1161 } else if (n3 < 65536) { 1162 if ((t4 -= 3) < 0) break; 1163 a4.push(n3 >> 12 | 224, n3 >> 6 & 63 | 128, n3 & 63 | 128); 1164 } else if (n3 < 1114112) { 1165 if ((t4 -= 4) < 0) break; 1166 a4.push(n3 >> 18 | 240, n3 >> 12 & 63 | 128, n3 >> 6 & 63 | 128, n3 & 63 | 128); 1167 } else throw Error(`Invalid code point`); 1168 } 1169 return a4; 1170 } 1171 function se2(e4) { 1172 let t4 = []; 1173 for (let n3 = 0; n3 < e4.length; ++n3) t4.push(e4.charCodeAt(n3) & 255); 1174 return t4; 1175 } 1176 function ce2(e4, t4) { 1177 let n3, r4, i4, a4 = []; 1178 for (let o4 = 0; o4 < e4.length && !((t4 -= 2) < 0); ++o4) n3 = e4.charCodeAt(o4), r4 = n3 >> 8, i4 = n3 % 256, a4.push(i4), a4.push(r4); 1179 return a4; 1180 } 1181 function le2(e4) { 1182 return t3.toByteArray(ae2(e4)); 1183 } 1184 function ue2(e4, t4, n3, r4) { 1185 let i4; 1186 for (i4 = 0; i4 < r4 && !(i4 + n3 >= t4.length || i4 >= e4.length); ++i4) t4[i4 + n3] = e4[i4]; 1187 return i4; 1188 } 1189 function de2(e4, t4) { 1190 return e4 instanceof t4 || e4 != null && e4.constructor != null && e4.constructor.name != null && e4.constructor.name === t4.name; 1191 } 1192 function fe2(e4) { 1193 return e4 !== e4; 1194 } 1195 let pe2 = (function() { 1196 let e4 = `0123456789abcdef`, t4 = Array(256); 1197 for (let n3 = 0; n3 < 16; ++n3) { 1198 let r4 = n3 * 16; 1199 for (let i4 = 0; i4 < 16; ++i4) t4[r4 + i4] = e4[n3] + e4[i4]; 1200 } 1201 return t4; 1202 })(); 1203 function Q2(e4) { 1204 return typeof BigInt > `u` ? me2 : e4; 1205 } 1206 function me2() { 1207 throw Error(`BigInt not supported`); 1208 } 1209 })(t2); 1210 var _2 = t2.Buffer; 1211 e2.Blob = t2.Blob, e2.BlobOptions = t2.BlobOptions, e2.Buffer = t2.Buffer, e2.File = t2.File, e2.FileOptions = t2.FileOptions, e2.INSPECT_MAX_BYTES = t2.INSPECT_MAX_BYTES, e2.SlowBuffer = t2.SlowBuffer, e2.TranscodeEncoding = t2.TranscodeEncoding, e2.atob = t2.atob, e2.btoa = t2.btoa, e2.constants = t2.constants, e2.default = _2, e2.isAscii = t2.isAscii, e2.isUtf8 = t2.isUtf8, e2.kMaxLength = t2.kMaxLength, e2.kStringMaxLength = t2.kStringMaxLength, e2.resolveObjectURL = t2.resolveObjectURL, e2.transcode = t2.transcode; 1212})), X = i(((e2) => { 1213 Object.defineProperty(e2, `__esModule`, { value: true }), e2.Buffer = void 0; 1214 var t2 = re(); 1215 Object.defineProperty(e2, `Buffer`, { enumerable: true, get: function() { 1216 return t2.Buffer; 1217 } }); 1218})), Z = i(((e2) => { 1219 Object.defineProperty(e2, `__esModule`, { value: true }), e2.bufferFrom = e2.bufferAllocUnsafe = e2.Buffer = void 0; 1220 var t2 = X(); 1221 Object.defineProperty(e2, `Buffer`, { enumerable: true, get: function() { 1222 return t2.Buffer; 1223 } }); 1224 function n2(e3, ...n3) { 1225 return new t2.Buffer(e3, ...n3); 1226 } 1227 e2.bufferAllocUnsafe = t2.Buffer.allocUnsafe || n2, e2.bufferFrom = t2.Buffer.from || n2; 1228})), ie = i(((e2) => { 1229 Object.defineProperty(e2, `__esModule`, { value: true }), e2.flattenJSON = void 0; 1230 var t2 = Z(), n2 = Y(), r2 = n2.posix ? n2.posix.join : n2.join; 1231 e2.flattenJSON = (e3) => { 1232 let n3 = {}; 1233 function i2(e4, a2) { 1234 for (let o2 in a2) { 1235 let s2 = a2[o2], c2 = r2(e4, o2); 1236 typeof s2 == `string` || s2 instanceof t2.Buffer ? n3[c2] = s2 : typeof s2 == `object` && s2 && !(s2 instanceof t2.Buffer) && Object.keys(s2).length > 0 ? i2(c2, s2) : n3[c2] = null; 1237 } 1238 } 1239 return i2(``, e3), n3; 1240 }; 1241})), ae = i(((e2) => { 1242 Object.defineProperty(e2, `__esModule`, { value: true }); 1243})), oe = i(((e2) => { 1244 Object.defineProperty(e2, `__esModule`, { value: true }), e2.Ok = t2, e2.Err = n2; 1245 function t2(e3) { 1246 return { ok: true, value: e3 }; 1247 } 1248 function n2(e3) { 1249 return { ok: false, err: e3 }; 1250 } 1251})), se = i(((e2) => { 1252 Object.defineProperty(e2, `__esModule`, { value: true }), e2.FanOut = void 0, e2.FanOut = class { 1253 constructor() { 1254 this.listeners = /* @__PURE__ */ new Set(); 1255 } 1256 emit(e3) {
1257 this.listeners.forEach((t2) => t2(e3)); 1258 } 1259 listen(e3) { 1260 let t2 = this.listeners; 1261 return t2.add(e3), () => t2.delete(e3); 1262 } 1263 }; 1264})), ce = i(((e2) => { 1265 Object.defineProperties(e2, { __esModule: { value: true }, [Symbol.toStringTag]: { value: `Module` } }); 1266 function t2(e3) { 1267 return e3 && e3.__esModule && Object.prototype.hasOwnProperty.call(e3, `default`) ? e3.default : e3; 1268 } 1269 var n2 = { exports: {} }, r2 = n2.exports = {}, i2, a2; 1270 function o2() { 1271 throw Error(`setTimeout has not been defined`); 1272 } 1273 function s2() { 1274 throw Error(`clearTimeout has not been defined`); 1275 } 1276 (function() { 1277 try { 1278 i2 = typeof setTimeout == `function` ? setTimeout : o2; 1279 } catch { 1280 i2 = o2; 1281 } 1282 try { 1283 a2 = typeof clearTimeout == `function` ? clearTimeout : s2; 1284 } catch { 1285 a2 = s2; 1286 } 1287 })(); 1288 function c2(e3) { 1289 if (i2 === setTimeout) return setTimeout(e3, 0); 1290 if ((i2 === o2 || !i2) && setTimeout) return i2 = setTimeout, setTimeout(e3, 0); 1291 try { 1292 return i2(e3, 0); 1293 } catch { 1294 try { 1295 return i2.call(null, e3, 0); 1296 } catch { 1297 return i2.call(this, e3, 0); 1298 } 1299 } 1300 } 1301 function l2(e3) { 1302 if (a2 === clearTimeout) return clearTimeout(e3); 1303 if ((a2 === s2 || !a2) && clearTimeout) return a2 = clearTimeout, clearTimeout(e3); 1304 try { 1305 return a2(e3); 1306 } catch { 1307 try { 1308 return a2.call(null, e3); 1309 } catch { 1310 return a2.call(this, e3); 1311 } 1312 } 1313 } 1314 var u2 = [], d2 = false, f2, p2 = -1; 1315 function m2() { 1316 !d2 || !f2 || (d2 = false, f2.length ? u2 = f2.concat(u2) : p2 = -1, u2.length && h2()); 1317 } 1318 function h2() { 1319 if (!d2) { 1320 var e3 = c2(m2); 1321 d2 = true; 1322 for (var t3 = u2.length; t3; ) { 1323 for (f2 = u2, u2 = []; ++p2 < t3; ) f2 && f2[p2].run(); 1324 p2 = -1, t3 = u2.length; 1325 } 1326 f2 = null, d2 = false, l2(e3); 1327 } 1328 } 1329 r2.nextTick = function(e3) { 1330 var t3 = Array(arguments.length - 1); 1331 if (arguments.length > 1) for (var n3 = 1; n3 < arguments.length; n3++) t3[n3 - 1] = arguments[n3]; 1332 u2.push(new g2(e3, t3)), u2.length === 1 && !d2 && c2(h2); 1333 }; 1334 function g2(e3, t3) { 1335 this.fun = e3, this.array = t3; 1336 } 1337 g2.prototype.run = function() { 1338 this.fun.apply(null, this.array); 1339 }, r2.title = `browser`, r2.browser = true, r2.env = {}, r2.argv = [], r2.version = ``, r2.versions = {}; 1340 function _2() { 1341 } 1342 r2.on = _2, r2.addListener = _2, r2.once = _2, r2.off = _2, r2.removeListener = _2, r2.removeAllListeners = _2, r2.emit = _2, r2.prependListener = _2, r2.prependOnceListener = _2, r2.listeners = function(e3) { 1343 return []; 1344 }, r2.binding = function(e3) { 1345 throw Error(`process.binding is not supported`); 1346 }, r2.cwd = function() { 1347 return `/`; 1348 }, r2.chdir = function(e3) { 1349 throw Error(`process.chdir is not supported`); 1350 }, r2.umask = function() { 1351 return 0; 1352 }; 1353 var v2 = n2.exports, y2 = t2(v2); 1354 e2.default = y2, e2.process = y2; 1355})), le = i(((e2) => { 1356 u(), Object.defineProperty(e2, `__esModule`, { value: true }), e2.createProcess = n2; 1357 var t2 = () => { 1358 if (l !== void 0) return l; 1359 try { 1360 return ce(); 1361 } catch { 1362 return; 1363 } 1364 }; 1365 function n2() { 1366 let e3 = t2() || {}; 1367 return e3.cwd || (e3.cwd = () => `/`), e3.emitWarning || (e3.emitWarning = (e4, t3) => { 1368 console.warn(`${t3}${t3 ? `: ` : ``}${e4}`); 1369 }), e3.env || (e3.env = {}), e3; 1370 } 1371 e2.default = n2(); 1372})), ue = i(((e2) => { 1373 Object.defineProperty(e2, `__esModule`, { value: true }); 1374})), de = i(((e2) => { 1375 Object.defineProperty(e2, `__esModule`, { value: true }), e2.FLAGS = e2.ERRSTR = e2.constants = e2.SEP = void 0, e2.SEP = `/`, e2.constants = { O_RDONLY: 0, O_WRONLY: 1, O_RDWR: 2, S_IFMT: 61440, S_IFREG: 32768, S_IFDIR: 16384, S_IFCHR: 8192, S_IFBLK: 24576, S_IFIFO: 4096, S_IFLNK: 40960, S_IFSOCK: 49152, O_CREAT: 64, O_EXCL: 128, O_NOCTTY: 256, O_TRUNC: 512, O_APPEND: 1024, O_DIRECTORY: 65536, O_NOATIME: 262144, O_NOFOLLOW: 131072, O_SYNC: 1052672, O_SYMLINK: 2097152, O_DIRECT: 16384, O_NONBLOCK: 2048, S_IRWXU: 448, S_IRUSR: 256, S_IWUSR: 128, S_IXUSR: 64, S_IRWXG: 56, S_IRGRP: 32, S_IWGRP: 16, S_IXGRP: 8, S_IRWXO: 7, S_IROTH: 4, S_IWOTH: 2, S_IXOTH: 1, F_OK: 0, R_OK: 4, W_OK: 2, X_OK: 1, UV_FS_SYMLINK_DIR: 1, UV_FS_SYMLINK_JUNCTION: 2, UV_FS_COPYFILE_EXCL: 1, UV_FS_COPYFILE_FICLONE: 2, UV_FS_COPYFILE_FICLONE_FORCE: 4, COPYFILE_EXCL: 1, COPYFILE_FICLONE: 2, COPYFILE_FICLONE_FORCE: 4 }, e2.ERRSTR = { PATH_STR: `path must be a string, Buffer, or Uint8Array`, FD: `fd must be a file descriptor`, MODE_INT: `mode must be an int`, CB: `callback must be a function`, UID: `uid must be an unsigned int`, GID: `gid must be an unsigned int`, LEN: `len must be an integer`, ATIME: `atime must be an integer`, MTIME: `mtime must be an integer`, PREFIX: `filename prefix is required`, BUFFER: `buffer must be an instance of Buffer or StaticBuffer`, OFFSET: `offset must be an integer`, LENGTH: `length must be an integer`, POSITION: `position must be an integer` }; 1376 var { O_RDONLY: t2, O_WRONLY: n2, O_RDWR: r2, O_CREAT: i2, O_EXCL: a2, O_TRUNC: o2, O_APPEND: s2, O_SYNC: c2 } = e2.constants, l2; 1377 (function(e3) { 1378 e3[e3.r = t2] = `r`, e3[e3[`r+`] = r2] = `r+`, e3[e3.rs = t2 | c2] = `rs`, e3[e3.sr = e3.rs] = `sr`, e3[e3[`rs+`] = r2 | c2] = `rs+`, e3[e3[`sr+`] = e3[`rs+`]] = `sr+`, e3[e3.w = n2 | i2 | o2] = `w`, e3[e3.wx = n2 | i2 | o2 | a2] = `wx`, e3[e3.xw = e3.wx] = `xw`, e3[e3[`w+`] = r2 | i2 | o2] = `w+`, e3[e3[`wx+`] = r2 | i2 | o2 | a2] = `wx+`, e3[e3[`xw+`] = e3[`wx+`]] = `xw+`, e3[e3.a = n2 | s2 | i2] = `a`, e3[e3.ax = n2 | s2 | i2 | a2] = `ax`, e3[e3.xa = e3.ax] = `xa`, e3[e3[`a+`] = r2 | s2 | i2] = `a+`, e3[e3[`ax+`] = r2 | s2 | i2 | a2] = `ax+`, e3[e3[`xa+`] = e3[`ax+`]] = `xa+`; 1379 })(l2 || (e2.FLAGS = l2 = {})); 1380})), fe = i(((e2) => { 1381 Object.defineProperty(e2, `__esModule`, { value: true }); 1382})), pe = i(((e2) => { 1383 Object.defineProperty(e2, `__esModule`, { value: true }), e2.FLAG = void 0; 1384 var t2; 1385 (function(e3) { 1386 e3[e3.O_RDONLY = 0] = `O_RDONLY`, e3[e3.O_WRONLY = 1] = `O_WRONLY`, e3[e3.O_RDWR = 2] = `O_RDWR`, e3[e3.O_ACCMODE = 3] = `O_ACCMODE`, e3[e3.O_CREAT = 64] = `O_CREAT`, e3[e3.O_EXCL = 128] = `O_EXCL`, e3[e3.O_NOCTTY = 256] = `O_NOCTTY`, e3[e3.O_TRUNC = 512] = `O_TRUNC`, e3[e3.O_APPEND = 1024] = `O_APPEND`, e3[e3.O_NONBLOCK = 2048] = `O_NONBLOCK`, e3[e3.O_DSYNC = 4096] = `O_DSYNC`, e3[e3.FASYNC = 8192] = `FASYNC`, e3[e3.O_DIRECT = 16384] = `O_DIRECT`, e3[e3.O_LARGEFILE = 0] = `O_LARGEFILE`, e3[e3.O_DIRECTORY = 65536] = `O_DIRECTORY`, e3[e3.O_NOFOLLOW = 131072] = `O_NOFOLLOW`, e3[e3.O_NOATIME = 262144] = `O_NOATIME`, e3[e3.O_CLOEXEC = 524288] = `O_CLOEXEC`, e3[e3.O_SYNC = 1052672] = `O_SYNC`, e3[e3.O_NDELAY = 2048] = `O_NDELAY`; 1387 })(t2 || (e2.FLAG = t2 = {})); 1388})), Q = i(((e2) => { 1389 Object.defineProperty(e2, `__esModule`, { value: true }), e2.basename = void 0, e2.basename = (e3, t2) => { 1390 e3[e3.length - 1] === t2 && (e3 = e3.slice(0, -1)); 1391 let n2 = e3.lastIndexOf(t2); 1392 return n2 === -1 ? e3 : e3.slice(n2 + 1); 1393 }; 1394})), me = i(((e2) => { 1395 Object.defineProperty(e2, `__esModule`, { value: true }), e2.inherits = t2, e2.promisify = n2, e2.inspect = r2, e2.format = i2; 1396 function t2(e3, t3) { 1397 if (e3 == null) throw TypeError(`The constructor to inherit from is not defined`); 1398 if (t3 == null) throw TypeError(`The super constructor to inherit from is not defined`); 1399 e3.super_ = t3, e3.prototype = Object.create(t3.prototype, { c
1399onstructor: { value: e3, enumerable: false, writable: true, configurable: true } }); 1400 } 1401 function n2(e3) { 1402 if (typeof e3 != `function`) throw TypeError(`The "original" argument must be of type function`); 1403 return function(...t3) { 1404 return new Promise((n3, r3) => { 1405 e3.call(this, ...t3, (e4, t4) => { 1406 e4 ? r3(e4) : n3(t4); 1407 }); 1408 }); 1409 }; 1410 } 1411 function r2(e3) { 1412 return e3 === null ? `null` : e3 === void 0 ? `undefined` : typeof e3 == `string` ? `'${e3}'` : typeof e3 == `number` || typeof e3 == `boolean` ? String(e3) : Array.isArray(e3) ? `[ ${e3.map((e4) => r2(e4)).join(`, `)} ]` : typeof e3 == `object` ? `{ ${Object.entries(e3).map(([e4, t3]) => `${e4}: ${r2(t3)}`).join(`, `)} }` : String(e3); 1413 } 1414 function i2(e3, ...t3) { 1415 if (t3.length === 0) return e3; 1416 let n3 = e3, r3 = 0; 1417 for (n3 = n3.replace(/%[sdj%]/g, (e4) => { 1418 if (r3 >= t3.length) return e4; 1419 let n4 = t3[r3++]; 1420 switch (e4) { 1421 case `%s`: 1422 return String(n4); 1423 case `%d`: 1424 return Number(n4).toString(); 1425 case `%j`: 1426 try { 1427 return JSON.stringify(n4); 1428 } catch { 1429 return `[Circular]`; 1430 } 1431 case `%%`: 1432 return `%`; 1433 default: 1434 return e4; 1435 } 1436 }); r3 < t3.length; ) n3 += ` ` + String(t3[r3++]); 1437 return n3; 1438 } 1439})), he = i(((e2) => { 1440 a(), Object.defineProperty(e2, `__esModule`, { value: true }), e2.AssertionError = e2.RangeError = e2.TypeError = e2.Error = void 0, e2.message = c2, e2.E = l2; 1441 var t2 = me(), n2 = typeof Symbol > `u` ? `_kCode` : /* @__PURE__ */ Symbol(`code`), r2 = {}; 1442 function i2(e3) { 1443 return class extends e3 { 1444 constructor(e4, ...t3) { 1445 super(c2(e4, t3)), this.code = e4, this[n2] = e4, this.name = `${super.name} [${this[n2]}]`; 1446 } 1447 }; 1448 } 1449 var s2 = typeof globalThis < `u` ? globalThis : o; 1450 e2.AssertionError = class extends s2.Error { 1451 constructor(n3) { 1452 if (typeof n3 != `object` || !n3) throw new e2.TypeError(`ERR_INVALID_ARG_TYPE`, `options`, `object`); 1453 n3.message ? super(n3.message) : super(`${(0, t2.inspect)(n3.actual).slice(0, 128)} ${n3.operator} ${(0, t2.inspect)(n3.expected).slice(0, 128)}`), this.generatedMessage = !n3.message, this.name = `AssertionError [ERR_ASSERTION]`, this.code = `ERR_ASSERTION`, this.actual = n3.actual, this.expected = n3.expected, this.operator = n3.operator, e2.Error.captureStackTrace(this, n3.stackStartFunction); 1454 } 1455 }; 1456 function c2(n3, i3) { 1457 if (typeof n3 != `string`) throw new e2.Error(`Error message key must be a string`); 1458 let a2 = r2[n3]; 1459 if (!a2) throw new e2.Error(`An invalid error message key was used: ${n3}.`); 1460 let o2; 1461 if (typeof a2 == `function`) o2 = a2; 1462 else { 1463 if (o2 = t2.format, i3 === void 0 || i3.length === 0) return a2; 1464 i3.unshift(a2); 1465 } 1466 return String(o2.apply(null, i3)); 1467 } 1468 function l2(e3, t3) { 1469 r2[e3] = typeof t3 == `function` ? t3 : String(t3); 1470 } 1471 e2.Error = i2(s2.Error), e2.TypeError = i2(s2.TypeError), e2.RangeError = i2(s2.RangeError), l2(`ERR_DIR_CLOSED`, `Directory handle was closed`), l2(`ERR_DIR_CONCURRENT_OPERATION`, `Cannot do synchronous work on directory handle with concurrent asynchronous operations`), l2(`ERR_INVALID_FILE_URL_HOST`, `File URL host must be "localhost" or empty on %s`), l2(`ERR_INVALID_FILE_URL_PATH`, `File URL path %s`), l2(`ERR_INVALID_OPT_VALUE`, (e3, t3) => `The value "${String(t3)}" is invalid for option "${e3}"`), l2(`ERR_INVALID_OPT_VALUE_ENCODING`, (e3) => `The value "${String(e3)}" is invalid for option "encoding"`), l2(`ERR_INVALID_ARG_VALUE`, `Unable to open file as blob`); 1472})), ge = i(((e2) => { 1473 Object.defineProperty(e2, `__esModule`, { value: true }), e2.ENCODING_UTF8 = void 0, e2.assertEncoding = r2, e2.strToEncoding = i2; 1474 var t2 = Z(), n2 = he(); 1475 e2.ENCODING_UTF8 = `utf8`; 1476 function r2(e3) { 1477 if (e3 && !t2.Buffer.isEncoding(e3)) throw new n2.TypeError(`ERR_INVALID_OPT_VALUE_ENCODING`, e3); 1478 } 1479 function i2(n3, r3) { 1480 return !r3 || r3 === e2.ENCODING_UTF8 ? n3 : r3 === `buffer` ? new t2.Buffer(n3) : new t2.Buffer(n3).toString(r3); 1481 } 1482})), $ = i(((t2) => { 1483 Object.defineProperty(t2, `__esModule`, { value: true }); 1484 var n2 = (J(), e(f)); 1485 n2.__exportStar(ue(), t2), n2.__exportStar(de(), t2), n2.__exportStar(fe(), t2), n2.__exportStar(pe(), t2), n2.__exportStar(Q(), t2), n2.__exportStar(ge(), t2); 1486})), _e = i(((e2) => { 1487 Object.defineProperty(e2, `__esModule`, { value: true }), e2.Node = void 0;
1488 var t2 = se(), n2 = le(), r2 = Z(), { S_IFMT: i2, S_IFDIR: a2, S_IFREG: o2, S_IFLNK: s2, S_IFCHR: c2 } = $().constants, l2 = () => n2.default.getuid?.() ?? 0, u2 = () => n2.default.getgid?.() ?? 0, d2 = (0, r2.bufferAllocUnsafe)(0); 1489 e2.Node = class { 1490 constructor(e3, n3 = 438, r3 = l2(), i3 = u2()) { 1491 this.changes = new t2.FanOut(), this._uid = l2(), this._gid = u2(), this._atime = /* @__PURE__ */ new Date(), this._mtime = /* @__PURE__ */ new Date(), this._ctime = /* @__PURE__ */ new Date(), this.buf = d2, this.capacity = 0, this.size = 0, this.rdev = 0, this._nlink = 1, this.mode = n3, this.ino = e3, this._uid = r3, this._gid = i3; 1492 } 1493 set ctime(e3) { 1494 this._ctime = e3; 1495 } 1496 get ctime() { 1497 return this._ctime; 1498 } 1499 set uid(e3) { 1500 this._uid = e3, this.ctime = /* @__PURE__ */ new Date(); 1501 } 1502 get uid() { 1503 return this._uid; 1504 } 1505 set gid(e3) { 1506 this._gid = e3, this.ctime = /* @__PURE__ */ new Date(); 1507 } 1508 get gid() { 1509 return this._gid; 1510 } 1511 set atime(e3) { 1512 this._atime = e3; 1513 } 1514 get atime() { 1515 return this._atime; 1516 } 1517 set mtime(e3) { 1518 this._mtime = e3, this.ctime = /* @__PURE__ */ new Date(); 1519 } 1520 get mtime() { 1521 return this._mtime; 1522 } 1523 get perm() { 1524 return this.mode & ~i2; 1525 } 1526 set perm(e3) { 1527 this.mode = this.mode & i2 | e3 & ~i2, this.ctime = /* @__PURE__ */ new Date(); 1528 } 1529 set nlink(e3) { 1530 this._nlink = e3, this.ctime = /* @__PURE__ */ new Date(); 1531 } 1532 get nlink() { 1533 return this._nlink; 1534 } 1535 getString(e3 = `utf8`) { 1536 return this.atime = /* @__PURE__ */ new Date(), this.getBuffer().toString(e3); 1537 } 1538 setString(e3) { 1539 this._setBuf((0, r2.bufferFrom)(e3, `utf8`)); 1540 } 1541 getBuffer() { 1542 return this.atime = /* @__PURE__ */ new Date(), this.buf || (this.buf = (0, r2.bufferAllocUnsafe)(0)), (0, r2.bufferFrom)(this.buf.subarray(0, this.size)); 1543 } 1544 setBuffer(e3) { 1545 let t3 = (0, r2.bufferFrom)(e3); 1546 this._setBuf(t3); 1547 } 1548 _setBuf(e3) { 1549 let t3 = e3.length; 1550 this.buf = e3, this.capacity = t3, this.size = t3, this.touch(); 1551 } 1552 getSize() { 1553 return this.size; 1554 } 1555 setModeProperty(e3) { 1556 this.mode = e3; 1557 } 1558 isFile() { 1559 return (this.mode & i2) === o2; 1560 } 1561 isDirectory() { 1562 return (this.mode & i2) === a2; 1563 } 1564 isSymlink() { 1565 return (this.mode & i2) === s2; 1566 } 1567 isCharacterDevice() { 1568 return (this.mode & i2) === c2; 1569 } 1570 makeSymlink(e3) { 1571 this.mode = s2 | 438, this.symlink = e3; 1572 } 1573 write(e3, t3 = 0, n3 = e3.length, i3 = 0) { 1574 let a3 = e3.length; 1575 if (t3 + n3 > a3 && (n3 = a3 - t3), n3 <= 0) return 0; 1576 let o3 = i3 + n3; 1577 if (o3 > this.capacity) { 1578 let e4 = Math.max(this.capacity * 2, 64); 1579 for (; e4 < o3; ) e4 *= 2; 1580 let t4 = (0, r2.bufferAllocUnsafe)(e4); 1581 this.size > 0 && this.buf.copy(t4, 0, 0, this.size), this.buf = t4, this.capacity = e4; 1582 } 1583 return i3 > this.size && this.buf.fill(0, this.size, i3), e3.copy(this.buf, i3, t3, t3 + n3), o3 > this.size && (this.size = o3), this.touch(), n3; 1584 } 1585 read(e3, t3 = 0, n3 = e3.byteLength, i3 = 0) { 1586 if (this.atime = /* @__PURE__ */ new Date(), i3 >= this.size) return 0; 1587 let a3 = n3; 1588 if (a3 > e3.byteLength && (a3 = e3.byteLength), a3 + i3 > this.size && (a3 = this.size - i3), a3 <= 0) return 0; 1589 let o3 = e3 instanceof r2.Buffer ? e3 : r2.Buffer.from(e3.buffer, e3.byteOffset, e3.byteLength); 1590 return this.buf.copy(o3, t3, i3, i3 + a3), a3; 1591 } 1592 truncate(e3 = 0) { 1593 if (!e3) { 1594 this.buf = d2, this.capacity = 0, this.size = 0, this.touch(); 1595 return; 1596 } 1597 if (e3 <= this.size) this.size = e3; 1598 else { 1599 if (e3 > this.capacity) { 1600 let t3 = Math.max(this.capacity * 2, 64); 1601 for (; t3 < e3; ) t3 *= 2; 1602 let n3 = (0, r2.bufferAllocUnsafe)(t3); 1603 this.size > 0 && this.buf.copy(n3, 0, 0, this.size), n3.fill(0, this.size, e3), this.buf = n3, this.capacity = t3; 1604 } else this.buf.fill(0, this.size, e3); 1605 this.size = e3; 1606 } 1607 this.touch(); 1608 } 1609 chmod(e3) { 1610 this.mode = this.mode & i2 | e3 & ~i2, this.touch(); 1611 } 1612 chown(e3, t3) { 1613 this.uid = e3, this.gid = t3, this.touch(); 1614 } 1615 touch() { 1616 this.mtime = /* @__PURE__ */ new Date(), this.changes.emit([`modify`]); 1617 } 1618 canRead(e3 = l2(), t3 = u2()) { 1619 return !!(this.perm & 4 || t3 === this.gid && this.perm & 32 || e3 === this.uid && this.perm & 256); 1620 } 1621 canWrite(e3 = l2(), t3 = u2()) { 1622 return !!(this.perm & 2 || t3 === this.gid && this.perm & 16 || e3 === this.uid && this.perm & 128); 1623 } 1624 canExecute(e3 = l2(), t3 = u2()) { 1625 return !!(this.perm & 1 || t3 === this.gid && this.perm & 8 || e3 === this.uid && this.perm & 64); 1626 } 1627 del() { 1628 this.changes.emit([`delete`]); 1629 } 1630 toJSON() { 1631 return { ino: this.ino, uid: this.uid, gid: this.gid, atime: this.atime.getTime(), mtime: this.mtime.getTime(), ctime: this.ctime.getTime(), perm: this.perm, mode: this.mode, nlink: this.nlink, symlink: this.symlink, data: this.get
1631String() }; 1632 } 1633 }; 1634})), ve = i(((e2) => { 1635 Object.defineProperty(e2, `__esModule`, { value: true }), e2.Link = void 0; 1636 var t2 = $(), n2 = se(), { S_IFREG: r2 } = t2.constants; 1637 e2.Link = class e3 { 1638 get steps() { 1639 return this._steps; 1640 } 1641 set steps(e4) { 1642 this._steps = e4; 1643 for (let [e5, t3] of this.children.entries()) e5 === `.` || e5 === `..` || t3?.syncSteps(); 1644 } 1645 constructor(e4, t3, r3) { 1646 this.changes = new n2.FanOut(), this.children = /* @__PURE__ */ new Map(), this._steps = [], this.ino = 0, this.length = 0, this.vol = e4, this.parent = t3, this.name = r3, this.syncSteps(); 1647 } 1648 setNode(e4) { 1649 this.node = e4, this.ino = e4.ino; 1650 } 1651 getNode() { 1652 return this.node; 1653 } 1654 createChild(t3, n3 = this.vol.createNode(r2 | 438)) { 1655 let i2 = new e3(this.vol, this, t3); 1656 return i2.setNode(n3), n3.isDirectory() && (i2.children.set(`.`, i2), i2.getNode().nlink++), this.setChild(t3, i2), i2; 1657 } 1658 setChild(t3, n3 = new e3(this.vol, this, t3)) { 1659 return this.children.set(t3, n3), n3.parent = this, this.length++, n3.getNode().isDirectory() && (n3.children.set(`..`, this), this.getNode().nlink++), this.getNode().mtime = /* @__PURE__ */ new Date(), this.changes.emit([`child:add`, n3, this]), n3; 1660 } 1661 deleteChild(e4) { 1662 e4.getNode().isDirectory() && (e4.children.delete(`..`), this.getNode().nlink--), this.children.delete(e4.getName()), this.length--, this.getNode().mtime = /* @__PURE__ */ new Date(), this.changes.emit([`child:del`, e4, this]); 1663 } 1664 getChild(e4) { 1665 return this.getNode().atime = /* @__PURE__ */ new Date(), this.children.get(e4); 1666 } 1667 getPath() { 1668 return this.steps.join(`/`); 1669 } 1670 getParentPath() { 1671 return this.steps.slice(0, -1).join(`/`) || `/`; 1672 } 1673 getName() { 1674 return this.steps[this.steps.length - 1]; 1675 } 1676 toJSON() { 1677 return { steps: this.steps, ino: this.ino, children: Array.from(this.children.keys()) }; 1678 } 1679 syncSteps() { 1680 this.steps = this.parent ? this.parent.steps.concat([this.name]) : [this.name]; 1681 } 1682 }; 1683})), ye = i(((e2) => { 1684 Object.defineProperty(e2, `__esModule`, { value: true }), e2.File = void 0; 1685 var { O_APPEND: t2 } = $().constants; 1686 e2.File = class { 1687 constructor(e3, n2, r2, i2) { 1688 this.link = e3, this.node = n2, this.flags = r2, this.fd = i2, this.position = 0, this.flags & t2 && (this.position = this.getSize()); 1689 } 1690 getString(e3 = `utf8`) { 1691 return this.node.getString(); 1692 } 1693 setString(e3) { 1694 this.node.setString(e3); 1695 } 1696 getBuffer() { 1697 return this.node.getBuffer(); 1698 } 1699 setBuffer(e3) { 1700 this.node.setBuffer(e3); 1701 } 1702 getSize() { 1703 return this.node.getSize(); 1704 } 1705 truncate(e3) { 1706 this.node.truncate(e3); 1707 } 1708 seekTo(e3) { 1709 this.position = e3; 1710 } 1711 write(e3, t3 = 0, n2 = e3.length, r2) { 1712 typeof r2 != `number` && (r2 = this.position); 1713 let i2 = this.node.write(e3, t3, n2, r2); 1714 return this.position = r2 + i2, i2; 1715 } 1716 read(e3, t3 = 0, n2 = e3.byteLength, r2) { 1717 typeof r2 != `number` && (r2 = this.position); 1718 let i2 = this.node.read(e3, t3, n2, r2); 1719 return this.position = r2 + i2, i2; 1720 } 1721 chmod(e3) { 1722 this.node.chmod(e3); 1723 } 1724 chown(e3, t3) { 1725 this.node.chown(e3, t3); 1726 } 1727 }; 1728})), be = i(((e2) => { 1729 Object.defineProperty(e2, `__esModule`, { value: true }), e2.ENCODING_UTF8 = void 0, e2.assertEncoding = r2, e2.strToEncoding = i2; 1730 var t2 = Z(), n2 = he(); 1731 e2.ENCODING_UTF8 = `utf8`; 1732 function r2(e3) { 1733 if (e3 && !t2.Buffer.isEncoding(e3)) throw new n2.TypeError(`ERR_INVALID_OPT_VALUE_ENCODING`, e3); 1734 } 1735 function i2(n3, r3) { 1736 return !r3 || r3 === e2.ENCODING_UTF8 ? n3 : r3 === `buffer` ? new t2.Buffer(n3) : new t2.Buffer(n3).toString(r3); 1737 } 1738})), xe = i(((e2, t2) => { 1739 a(), (function(n2) { 1740 var r2 = typeof e2 == `object` && e2 && !e2.nodeType && e2, i2 = typeof t2 == `object` && t2 && !t2.nodeType && t2, a2 = typeof o == `object` && o; 1741 (a2.global === a2 || a2.window === a2 || a2.self === a2) && (n2 = a2); 1742 var s2, c2 = 2147483647, l2 = 36, u2 = 1, d2 = 26, f2 = 38, p2 = 700, m2 = 72, h2 = 128, g2 = `-`, _2 = /^xn--/, v2 = /[^\x20-\x7E]/, y2 = /[\x2E\u3002\uFF0E\uFF61]/g, b2 = { overflow: `Overflow: input needs wider integers to process`, "not-basic": `Illegal input >= 0x80 (not a basic code point)`, "invalid-input": `Invalid input` }, x2 = l2 - u2, S2 = Math.floor, C2 = String.fromCharCode, w2; 1743 function T2(e3) { 1744 throw RangeError(b2[e3]); 1745 } 1746 function E2(e3, t3) { 1747 for (var n3 = e3.length, r3 = []; n3--; ) r3[n3] = t3(e3[n3]); 1748 return r3; 1749 } 1750 function D2(e3, t3) { 1751 var n3 = e3.split(`@`), r3 = ``; 1752 n3.length > 1 && (r3 = n3[0] + `@`, e3 = n3[1]), e3 = e3.replace(y2, `.`); 1753 var i3 = E2(e3.split(`.`), t3).join(`.`); 1754 return r3 + i3; 1755 } 1756 function O2(e3) { 1757 for (var t3 = [], n3 = 0, r3 = e3.length, i3, a3; n3 < r3; ) i3 = e3.charCodeAt(n3++), i3 >= 55296 && i3 <= 56319 && n3 < r3 ? (a3 = e3.charCodeAt(n3++), (a3 & 64512) == 56320 ? t3.push(((i3 & 1023) << 10) + (a3 & 1023) + 65536) : (t3.push(i3), n3--)) : t3.push(i3); 1758 return t3; 1759 } 1760 function k2(e3) { 1761 return E2(e3, function(e4) { 1762 var t3 = ``; 1763 return e4 > 65535 && (e4 -= 65536, t3 += C2(e4 >>> 10 & 1023 | 55296), e4 = 56320 | e4 & 1023), t3 += C2(e4), t3; 1764 }).join(``); 1765 } 1766 function A2(e3) { 1767 return e3 - 48 < 10 ? e3 - 22 : e3 - 65 < 26 ? e3 - 65 : e3 - 97 < 26 ? e3 - 97 : l2; 1768 } 1769 function j2(e3, t3) { 1770 return e3 + 22 + 75 * (e3 < 26) - ((t3 != 0) << 5); 1771 } 1772 function M2(e3, t3, n3) { 1773 var r3 = 0; 1774 for (e3 = n3 ? S2(e3 / p2) : e3 >> 1, e3 += S2(e3 / t3); e3 > x2 * d2 >> 1; r3 += l2) e3 = S2(e3 / x2); 1775 return S2(r3 + (x2 + 1) * e3 / (e3 + f2)); 1776 } 1777 function N2(e3) { 1778 var t3 = [], n3 = e3.length, r3, i3 = 0, a3 = h2, o2 = m2, s3 = e3.lastIndexOf(g2), f3, p3, _3, v3, y3, b3, x3, C3; 1779 for (s3 < 0 && (s3 = 0), f3 = 0; f3 < s3; ++f3) e3.charCodeAt(f3) >
1779= 128 && T2(`not-basic`), t3.push(e3.charCodeAt(f3)); 1780 for (p3 = s3 > 0 ? s3 + 1 : 0; p3 < n3; ) { 1781 for (_3 = i3, v3 = 1, y3 = l2; p3 >= n3 && T2(`invalid-input`), b3 = A2(e3.charCodeAt(p3++)), (b3 >= l2 || b3 > S2((c2 - i3) / v3)) && T2(`overflow`), i3 += b3 * v3, x3 = y3 <= o2 ? u2 : y3 >= o2 + d2 ? d2 : y3 - o2, !(b3 < x3); y3 += l2) C3 = l2 - x3, v3 > S2(c2 / C3) && T2(`overflow`), v3 *= C3; 1782 r3 = t3.length + 1, o2 = M2(i3 - _3, r3, _3 == 0), S2(i3 / r3) > c2 - a3 && T2(`overflow`), a3 += S2(i3 / r3), i3 %= r3, t3.splice(i3++, 0, a3); 1783 } 1784 return k2(t3); 1785 } 1786 function P2(e3) { 1787 var t3, n3, r3, i3, a3, o2, s3, f3, p3, _3, v3, y3 = [], b3, x3, w3, E3; 1788 for (e3 = O2(e3), b3 = e3.length, t3 = h2, n3 = 0, a3 = m2, o2 = 0; o2 < b3; ++o2) v3 = e3[o2], v3 < 128 && y3.push(C2(v3)); 1789 for (r3 = i3 = y3.length, i3 && y3.push(g2); r3 < b3; ) { 1790 for (s3 = c2, o2 = 0; o2 < b3; ++o2) v3 = e3[o2], v3 >= t3 && v3 < s3 && (s3 = v3); 1791 for (x3 = r3 + 1, s3 - t3 > S2((c2 - n3) / x3) && T2(`overflow`), n3 += (s3 - t3) * x3, t3 = s3, o2 = 0; o2 < b3; ++o2) if (v3 = e3[o2], v3 < t3 && ++n3 > c2 && T2(`overflow`), v3 == t3) { 1792 for (f3 = n3, p3 = l2; _3 = p3 <= a3 ? u2 : p3 >= a3 + d2 ? d2 : p3 - a3, !(f3 < _3); p3 += l2) E3 = f3 - _3, w3 = l2 - _3, y3.push(C2(j2(_3 + E3 % w3, 0))), f3 = S2(E3 / w3); 1793 y3.push(C2(j2(f3, 0))), a3 = M2(n3, x3, r3 == i3), n3 = 0, ++r3; 1794 } 1795 ++n3, ++t3; 1796 } 1797 return y3.join(``); 1798 } 1799 function F2(e3) { 1800 return D2(e3, function(e4) { 1801 return _2.test(e4) ? N2(e4.slice(4).toLowerCase()) : e4; 1802 }); 1803 } 1804 function I2(e3) { 1805 return D2(e3, function(e4) { 1806 return v2.test(e4) ? `xn--` + P2(e4) : e4; 1807 }); 1808 } 1809 if (s2 = { version: `1.4.1`, ucs2: { decode: O2, encode: k2 }, decode: N2, encode: P2, toASCII: I2, toUnicode: F2 }, typeof define == `function` && typeof define.amd == `object` && define.amd) define(`punycode`, function() { 1810 return s2; 1811 }); 1812 else if (r2 && i2) if (t2.exports == r2) i2.exports = s2; 1813 else for (w2 in s2) s2.hasOwnProperty(w2) && (r2[w2] = s2[w2]); 1814 else n2.punycode = s2; 1815 })(e2); 1816})), Se = i(((e2, t2) => { 1817 t2.exports = TypeError; 1818})), Ce = i(((e2, t2) => { 1819 t2.exports = {}; 1820})), we = i(((e2, t2) => { 1821 a(); 1822 var n2 = typeof Map == `function` && Map.prototype, r2 = Object.getOwnPropertyDescriptor && n2 ? Object.getOwnPropertyDescriptor(Map.prototype, `size`) : null, i2 = n2 && r2 && typeof r2.get == `function` ? r2.get : null, s2 = n2 && Map.prototype.forEach, c2 = typeof Set == `function` && Set.prototype, l2 = Object.getOwnPropertyDescriptor && c2 ? Object.getOwnPropertyDescriptor(Set.prototype, `size`) : null, u2 = c2 && l2 && typeof l2.get == `function` ? l2.get : null, d2 = c2 && Set.prototype.forEach, f2 = typeof WeakMap == `function` && WeakMap.prototype ? WeakMap.prototype.has : null, p2 = typeof WeakSet == `function` && WeakSet.prototype ? WeakSet.prototype.has : null, m2 = typeof WeakRef == `function` && WeakRef.prototype ? WeakRef.prototype.deref : null, h2 = Boolean.prototype.valueOf, g2 = Object.prototype.toString, _2 = Function.prototype.toString, v2 = String.prototype.match, y2 = String.prototype.slice, b2 = String.prototype.replace, x2 = String.prototype.toUpperCase, S2 = String.prototype.toLowerCase, C2 = RegExp.prototype.test, w2 = Array.prototype.concat, T2 = Array.prototype.join, E2 = Array.prototype.slice, D2 = Math.floor, O2 = typeof BigInt == `function` ? BigInt.prototype.valueOf : null, k2 = Object.getOwnPropertySymbols, A2 = typeof Symbol == `function` && typeof Symbol.iterator == `symbol` ? Symbol.prototype.toString : null, j2 = typeof Symbol == `function` && typeof Symbol.iterator == `object`, M2 = typeof Symbol == `function` && Symbol.toStringTag ? Symbol.toStringTag : null, N2 = Object.prototype.propertyIsEnumerable, P2 = (typeof Reflect == `function` ? Reflect.getPrototypeOf : Object.getPrototypeOf) || ([].__proto__ === Array.prototype ? function(e3) { 1823 return e3.__proto__; 1824 } : null); 1825 function F2(e3, t3) { 1826 if (e3 === 1 / 0 || e3 === -1 / 0 || e3 !== e3 || e3 && e3 > -1e3 && e3 < 1e3 || C2.call(/e/, t3)) return t3; 1827 var n3 = /[0-9](?=(?:[0-9]{3})+(?![0-9]))/g; 1828 if (typeof e3 == `number`) { 1829 var r3 = e3 < 0 ? -D2(-e3) : D2(e3); 1830 if (r3 !== e3) { 1831 var i3 = String(r3), a2 = y2.call(t3, i3.length + 1); 1832 return b2.call(i3, n3, `$&_`) + `.` + b2.call(b2.call(a2, /([0-9]{3})/g, `$&_`), /_$/, ``); 1833 } 1834 } 1835 return b2.call(t3, n3, `$&_`); 1836 } 1837 var I2 = Ce(), L2 = I2.custom, R2 = Y2(L2) ? L2 : null, z2 = { __proto__: null, double: `"`, single: `'` }, B2 = { __proto__: null, double: /(["\\])/g, single: /(['\\])/g }; 1838 t2.exports = function e3(t3, n3, r3, a2) { 1839 var c3 = n3 || {}; 1840 if (X2(c3, `quoteStyle`) && !X2(z2, c3.quoteStyle)) throw TypeError(`option "quoteStyle" must be "single" or "double"`); 1841 if (X2(c3, `maxStringLength`) && (typeof c3.maxStringLength == `number` ? c3.maxStringLength < 0 && c3.maxStringLength !== 1 / 0 : c3.maxStringLength !== null)) throw TypeError('option "maxStringLength", if provided, must be a positive integer, Infinity, or `null`'); 1842 var l3 = X2(c3, `customInspect`) ? c3.customInspect : true; 1843 if (typeof l3 != `boolean` && l3 !== `symbol`) throw TypeError("option \"customInspect\", if provided, must be `true`, `false`, or `'symbol'`"); 1844 if (X2(c3, `indent`) && c3.indent !== null && c3.indent !== ` ` && !(parseInt(c3.indent, 10) === c3.indent && c3.indent > 0)) throw TypeError('option "indent" must be "\\t", an integer > 0, or `null`'); 1845 if (X2(c3, `numericSeparator`) && typeof c3.numericSeparator != `boolean`) throw TypeError('option "numericSeparator", if provided, must be `true` or `false`'); 1846 var f3 = c3.numericSeparator; 1847 if (t3 === void 0) return `undefined`; 1848 if (t3 === null) return `null`; 1849 if (typeof t3 == `boolean`) return t3 ? `true` : `false`; 1850 if (typeof t3 == `string`) return fe2(t3, c3); 1851 if (typeof t3 == `number`) { 1852 if (t3 === 0) return 1 / 0 / t3 > 0 ? `0` : `-0`; 1853 var p3 = String(t3); 1854 return f3 ? F2(t3, p3) : p3; 1855 } 1856 if (typeof t3 == `bigint`) { 1857 var m3 = String(t3) + `n`; 1858 return f3 ? F2(t3, m3) : m3; 1859 } 1860 var g3 = c3.depth === void 0 ? 5 : c3.depth; 1861 if (r3 === void 0 && (r3 = 0), r3 >= g3 && g3 > 0 && typeof t3 == `object`) return W2(t3) ? `[Array]` : `[Object]`; 1862 var _3 = $2(c3, r3); 1863 if (a2 === void 0) a2 = []; 1864 else if (ae2(a2, t3) >= 0) return `[Circular]`; 1865 function v3(t4, n4, i3) { 1866 if (n4 && (a2 = E2.call(a2), a2.push(n4)), i3) { 1867 var o2 = { depth: c3.depth }; 1868 return X2(c3, `quoteStyle`) && (o2.quoteStyle = c3.quoteStyle), e3(t4, o2, r3 + 1, a2); 1869 } 1870 return e3(t4, c3, r3 + 1, a2); 1871 } 1872 if (typeof t3 == `function` && !ee2(t3)) { 1873 var x3 = ie2(t3), C3 = ve2(t3, v3); 1874 return `[Function` + (x3 ? `: ` + x3 : ` (anonymous)`) + `]` + (C3.length >
vendor: 19,898 bytes, lines 1874-2333
1874 0 ? ` { ` + T2.call(C3, `, `) + ` }` : ``); 1875 } 1876 if (Y2(t3)) { 1877 var D3 = j2 ? b2.call(String(t3), /^(Symbol\(.*\))_[^)]*$/, `$1`) : A2.call(t3); 1878 return typeof t3 == `object` && !j2 ? Q2(D3) : D3; 1879 } 1880 if (de2(t3)) { 1881 for (var k3 = `<` + S2.call(String(t3.nodeName)), L3 = t3.attributes || [], B3 = 0; B3 < L3.length; B3++) k3 += ` ` + L3[B3].name + `=` + V2(H2(L3[B3].value), `double`, c3); 1882 return k3 += `>`, t3.childNodes && t3.childNodes.length && (k3 += `...`), k3 += `</` + S2.call(String(t3.nodeName)) + `>`, k3; 1883 } 1884 if (W2(t3)) { 1885 if (t3.length === 0) return `[]`; 1886 var U3 = ve2(t3, v3); 1887 return _3 && !ge2(U3) ? `[` + _e2(U3, _3) + `]` : `[ ` + T2.call(U3, `, `) + ` ]`; 1888 } 1889 if (K2(t3)) { 1890 var re3 = ve2(t3, v3); 1891 return !(`cause` in Error.prototype) && `cause` in t3 && !N2.call(t3, `cause`) ? `{ [` + String(t3) + `] ` + T2.call(w2.call(`[cause]: ` + v3(t3.cause), re3), `, `) + ` }` : re3.length === 0 ? `[` + String(t3) + `]` : `{ [` + String(t3) + `] ` + T2.call(re3, `, `) + ` }`; 1892 } 1893 if (typeof t3 == `object` && l3) { 1894 if (R2 && typeof t3[R2] == `function` && I2) return I2(t3, { depth: g3 - r3 }); 1895 if (l3 !== `symbol` && typeof t3.inspect == `function`) return t3.inspect(); 1896 } 1897 if (oe2(t3)) { 1898 var pe3 = []; 1899 return s2 && s2.call(t3, function(e4, n4) { 1900 pe3.push(v3(n4, t3, true) + ` => ` + v3(e4, t3)); 1901 }), he2(`Map`, i2.call(t3), pe3, _3); 1902 } 1903 if (le2(t3)) { 1904 var ye2 = []; 1905 return d2 && d2.call(t3, function(e4) { 1906 ye2.push(v3(e4, t3)); 1907 }), he2(`Set`, u2.call(t3), ye2, _3); 1908 } 1909 if (se2(t3)) return me2(`WeakMap`); 1910 if (ue2(t3)) return me2(`WeakSet`); 1911 if (ce2(t3)) return me2(`WeakRef`); 1912 if (q2(t3)) return Q2(v3(Number(t3))); 1913 if (ne2(t3)) return Q2(v3(O2.call(t3))); 1914 if (J2(t3)) return Q2(h2.call(t3)); 1915 if (te2(t3)) return Q2(v3(String(t3))); 1916 if (typeof window < `u` && t3 === window) return `{ [object Window] }`; 1917 if (typeof globalThis < `u` && t3 === globalThis || o !== void 0 && t3 === o) return `{ [object globalThis] }`; 1918 if (!G2(t3) && !ee2(t3)) { 1919 var be2 = ve2(t3, v3), xe2 = P2 ? P2(t3) === Object.prototype : t3 instanceof Object || t3.constructor === Object, Se2 = t3 instanceof Object ? `` : `null prototype`, Ce2 = !xe2 && M2 && Object(t3) === t3 && M2 in t3 ? y2.call(Z2(t3), 8, -1) : Se2 ? `Object` : ``, we2 = (xe2 || typeof t3.constructor != `function` ? `` : t3.constructor.name ? t3.constructor.name + ` ` : ``) + (Ce2 || Se2 ? `[` + T2.call(w2.call([], Ce2 || [], Se2 || []), `: `) + `] ` : ``); 1920 return be2.length === 0 ? we2 + `{}` : _3 ? we2 + `{` + _e2(be2, _3) + `}` : we2 + `{ ` + T2.call(be2, `, `) + ` }`; 1921 } 1922 return String(t3); 1923 }; 1924 function V2(e3, t3, n3) { 1925 var r3 = z2[n3.quoteStyle || t3]; 1926 return r3 + e3 + r3; 1927 } 1928 function H2(e3) { 1929 return b2.call(String(e3), /"/g, `"`); 1930 } 1931 function U2(e3) { 1932 return !M2 || !(typeof e3 == `object` && (M2 in e3 || e3[M2] !== void 0)); 1933 } 1934 function W2(e3) { 1935 return Z2(e3) === `[object Array]` && U2(e3); 1936 } 1937 function G2(e3) { 1938 return Z2(e3) === `[object Date]` && U2(e3); 1939 } 1940 function ee2(e3) { 1941 return Z2(e3) === `[object RegExp]` && U2(e3); 1942 } 1943 function K2(e3) { 1944 return Z2(e3) === `[object Error]` && U2(e3); 1945 } 1946 function te2(e3) { 1947 return Z2(e3) === `[object String]` && U2(e3); 1948 } 1949 function q2(e3) { 1950 return Z2(e3) === `[object Number]` && U2(e3); 1951 } 1952 function J2(e3) { 1953 return Z2(e3) === `[object Boolean]` && U2(e3); 1954 } 1955 function Y2(e3) { 1956 if (j2) return e3 && typeof e3 == `object` && e3 instanceof Symbol; 1957 if (typeof e3 == `symbol`) return true; 1958 if (!e3 || typeof e3 != `object` || !A2) return false; 1959 try { 1960 return A2.call(e3), true; 1961 } catch { 1962 } 1963 return false; 1964 } 1965 function ne2(e3) { 1966 if (!e3 || typeof e3 != `object` || !O2) return false; 1967 try { 1968 return O2.call(e3), true; 1969 } catch { 1970 } 1971 return false; 1972 } 1973 var re2 = Object.prototype.hasOwnProperty || function(e3) { 1974 return e3 in this; 1975 }; 1976 function X2(e3, t3) { 1977 return re2.call(e3, t3); 1978 } 1979 function Z2(e3) { 1980 return g2.call(e3); 1981 } 1982 function ie2(e3) { 1983 if (e3.name) return e3.name; 1984 var t3 = v2.call(_2.call(e3), /^function\s*([\w$]+)/); 1985 return t3 ? t3[1] : null; 1986 } 1987 function ae2(e3, t3) { 1988 if (e3.indexOf) return e3.indexOf(t3); 1989 for (var n3 = 0, r3 = e3.length; n3 < r3; n3++) if (e3[n3] === t3) return n3; 1990 return -1; 1991 } 1992 function oe2(e3) { 1993 if (!i2 || !e3 || typeof e3 != `object`) return false; 1994 try { 1995 i2.call(e3); 1996 try { 1997 u2.call(e3); 1998 } catch { 1999 return true; 2000 } 2001 return e3 instanceof Map; 2002 } catch { 2003 } 2004 return false; 2005 } 2006 function se2(e3) { 2007 if (!f2 || !e3 || typeof e3 != `object`) return false; 2008 try { 2009 f2.call(e3, f2); 2010 try { 2011 p2.call(e3, p2); 2012 } catch { 2013 return true; 2014 } 2015 return e3 instanceof WeakMap; 2016 } catch { 2017 } 2018 return false; 2019 } 2020 function ce2(e3) { 2021 if (!m2 || !e3 || typeof e3 != `object`) return false; 2022 try { 2023 return m2.call(e3), true; 2024 } catch { 2025 } 2026 return false; 2027 } 2028 function le2(e3) { 2029 if (!u2 || !e3 || typeof e3 != `object`) return false; 2030 try { 2031 u2.call(e3); 2032 try { 2033 i2.call(e3); 2034 } catch { 2035 return true; 2036 } 2037 return e3 instanceof Set; 2038 } catch { 2039 } 2040 return false; 2041 } 2042 function ue2(e3) { 2043 if (!p2 || !e3 || typeof e3 != `object`) return false; 2044 try { 2045 p2.call(e3, p2); 2046 try { 2047 f2.call(e3, f2); 2048 } catch { 2049 return true; 2050 } 2051 return e3 instanceof WeakSet; 2052 } catch { 2053 } 2054 return false; 2055 } 2056 function de2(e3) { 2057 return !e3 || typeof e3 != `object` ? false : typeof HTMLElement < `u` && e3 instanceof HTMLElement ? true : typeof e3.nodeName == `string` && typeof e3.getAttribute == `function`; 2058 } 2059 function fe2(e3, t3) { 2060 if (e3.length > t3.maxStringLength) { 2061 var n3 = e3.length - t3.maxStringLength, r3 = `... ` + n3 + ` more character` + (n3 > 1 ? `s` : ``); 2062 return fe2(y2.call(e3, 0, t3.maxStringLength), t3) + r3; 2063 } 2064 var i3 = B2[t3.quoteStyle || `single`]; 2065 return i3.lastIndex = 0, V2(b2.call(b2.call(e3, i3, `\\$1`), /[\x00-\x1f]/g, pe2), `single`, t3); 2066 } 2067 function pe2(e3) { 2068 var t3 = e3.charCodeAt(0), n3 = { 8: `b`, 9: `t`, 10: `n`, 12: `f`, 13: `r` }[t3]; 2069 return n3 ? `\\` + n3 : `\\x` + (t3 < 16 ? `0` : ``) + x2.call(t3.toString(16)); 2070 } 2071 function Q2(e3) { 2072 return `Object(` + e3 + `)`; 2073 } 2074 function me2(e3) { 2075 return e3 + ` { ? }`; 2076 } 2077 function he2(e3, t3, n3, r3) { 2078 var i3 = r3 ? _e2(n3, r3) : T2.call(n3, `, `); 2079 return e3 + ` (` + t3 + `) {` + i3 + `}`; 2080 } 2081 function ge2(e3) { 2082 for (var t3 = 0; t3 < e3.length; t3++) if (ae2(e3[t3], ` 2083`) >= 0) return false; 2084 return true; 2085 } 2086 function $2(e3, t3) { 2087 var n3; 2088 if (e3.indent === ` `) n3 = ` `; 2089 else if (typeof e3.indent == `number` && e3.indent > 0) n3 = T2.call(Array(e3.indent + 1), ` `); 2090 else return null; 2091 return { base: n3, prev: T2.call(Array(t3 + 1), n3) }; 2092 } 2093 function _e2(e3, t3) { 2094 if (e3.length === 0) return ``; 2095 var n3 = ` 2096` + t3.prev + t3.base; 2097 return n3 + T2.call(e3, `,` + n3) + ` 2098` + t3.prev; 2099 } 2100 function ve2(e3, t3) { 2101 var n3 = W2(e3), r3 = []; 2102 if (n3) { 2103 r3.length = e3.length; 2104 for (var i3 = 0; i3 < e3.length; i3++) r3[i3] = X2(e3, i3) ? t3(e3[i3], e3) : ``; 2105 } 2106 var a2 = typeof k2 == `function` ? k2(e3) : [], o2; 2107 if (j2) { 2108 o2 = {}; 2109 for (var s3 = 0; s3 < a2.length; s3++) o2[`$` + a2[s3]] = a2[s3]; 2110 } 2111 for (var c3 in e3) X2(e3, c3) && (n3 && String(Number(c3)) === c3 && c3 < e3.length || j2 && o2[`$` + c3] instanceof Symbol || (C2.call(/[^\w$]/, c3) ? r3.push(t3(c3, e3) + `: ` + t3(e3[c3], e3)) : r3.push(c3 + `: ` + t3(e3[c3], e3)))); 2112 if (typeof k2 == `function`) for (var l3 = 0; l3 < a2.length; l3++) N2.call(e3, a2[l3]) && r3.push(`[` + t3(a2[l3]) + `]: ` + t3(e3[a2[l3]], e3)); 2113 return r3; 2114 } 2115})), Te = i(((e2, t2) => { 2116 var n2 = we(), r2 = Se(), i2 = function(e3, t3, n3) { 2117 for (var r3 = e3, i3; (i3 = r3.next) != null; r3 = i3) if (i3.key === t3) return r3.next = i3.next, n3 || (i3.next = e3.next, e3.next = i3), i3; 2118 }, a2 = function(e3, t3) { 2119 if (e3) { 2120 var n3 = i2(e3, t3); 2121 return n3 && n3.value; 2122 } 2123 }, o2 = function(e3, t3, n3) { 2124 var r3 = i2(e3, t3); 2125 r3 ? r3.value = n3 : e3.next = { key: t3, next: e3.next, value: n3 }; 2126 }, s2 = function(e3, t3) { 2127 return e3 ? !!i2(e3, t3) : false; 2128 }, c2 = function(e3, t3) { 2129 if (e3) return i2(e3, t3, true); 2130 }; 2131 t2.exports = function() { 2132 var e3, t3 = { assert: function(e4) { 2133 if (!t3.has(e4)) throw new r2(`Side channel does not contain ` + n2(e4)); 2134 }, delete: function(t4) { 2135 var n3 = c2(e3, t4); 2136 return n3 && e3 && !e3.next && (e3 = void 0), !!n3; 2137 }, get: function(t4) { 2138 return a2(e3, t4); 2139 }, has: function(t4) { 2140 return s2(e3, t4); 2141 }, set: function(t4, n3) { 2142 e3 || (e3 = { next: void 0 }), o2(e3, t4, n3); 2143 } }; 2144 return t3; 2145 }; 2146})), Ee = i(((e2, t2) => { 2147 t2.exports = Object; 2148})), De = i(((e2, t2) => { 2149 t2.exports = Error; 2150})), Oe = i(((e2, t2) => { 2151 t2.exports = EvalError; 2152})), ke = i(((e2, t2) => { 2153 t2.exports = RangeError; 2154})), Ae = i(((e2, t2) => { 2155 t2.exports = ReferenceError; 2156})), je = i(((e2, t2) => { 2157 t2.exports = SyntaxError; 2158})), Me = i(((e2, t2) => { 2159 t2.exports = URIError; 2160})), Ne = i(((e2, t2) => { 2161 t2.exports = Math.abs; 2162})), Pe = i(((e2, t2) => { 2163 t2.exports = Math.floor; 2164})), Fe = i(((e2, t2) => { 2165 t2.exports = Math.max; 2166})), Ie = i(((e2, t2) => { 2167 t2.exports = Math.min; 2168})), Le = i(((e2, t2) => { 2169 t2.exports = Math.pow; 2170})), Re = i(((e2, t2) => { 2171 t2.exports = Math.round; 2172})), ze = i(((e2, t2) => { 2173 t2.exports = Number.isNaN || function(e3) { 2174 return e3 !== e3; 2175 }; 2176})), Be = i(((e2, t2) => { 2177 var n2 = ze(); 2178 t2.exports = function(e3) { 2179 return n2(e3) || e3 === 0 ? e3 : e3 < 0 ? -1 : 1; 2180 }; 2181})), Ve = i(((e2, t2) => { 2182 t2.exports = Object.getOwnPropertyDescriptor; 2183})), He = i(((e2, t2) => { 2184 var n2 = Ve(); 2185 if (n2) try { 2186 n2([], `length`); 2187 } catch { 2188 n2 = null; 2189 } 2190 t2.exports = n2; 2191})), Ue = i(((e2, t2) => { 2192 var n2 = Object.defineProperty || false; 2193 if (n2) try { 2194 n2({}, `a`, { value: 1 }); 2195 } catch { 2196 n2 = false; 2197 } 2198 t2.exports = n2; 2199})), We = i(((e2, t2) => { 2200 t2.exports = function() { 2201 if (typeof Symbol != `function` || typeof Object.getOwnPropertySymbols != `function`) return false; 2202 if (typeof Symbol.iterator == `symbol`) return true; 2203 var e3 = {}, t3 = /* @__PURE__ */ Symbol(`test`), n2 = Object(t3); 2204 if (typeof t3 == `string` || Object.prototype.toString.call(t3) !== `[object Symbol]` || Object.prototype.toString.call(n2) !== `[object Symbol]`) return false; 2205 var r2 = 42; 2206 for (var i2 in e3[t3] = r2, e3) return false; 2207 if (typeof Object.keys == `function` && Object.keys(e3).length !== 0 || typeof Object.getOwnPropertyNames == `function` && Object.getOwnPropertyNames(e3).length !== 0) return false; 2208 var a2 = Object.getOwnPropertySymbols(e3); 2209 if (a2.length !== 1 || a2[0] !== t3 || !Object.prototype.propertyIsEnumerable.call(e3, t3)) return false; 2210 if (typeof Object.getOwnPropertyDescriptor == `function`) { 2211 var o2 = Object.getOwnPropertyDescriptor(e3, t3); 2212 if (o2.value !== r2 || o2.enumerable !== true) return false; 2213 } 2214 return true; 2215 }; 2216})), Ge = i(((e2, t2) => { 2217 var n2 = typeof Symbol < `u` && Symbol, r2 = We(); 2218 t2.exports = function() { 2219 return typeof n2 != `function` || typeof Symbol != `function` || typeof n2(`foo`) != `symbol` || typeof /* @__PURE__ */ Symbol(`bar`) != `symbol` ? false : r2(); 2220 }; 2221})), Ke = i(((e2, t2) => { 2222 t2.exports = typeof Reflect < `u` && Reflect.getPrototypeOf || null; 2223})), qe = i(((e2, t2) => { 2224 t2.exports = Ee().getPrototypeOf || null; 2225})), Je = i(((e2, t2) => { 2226 var n2 = `Function.prototype.bind called on incompatible `, r2 = Object.prototype.toString, i2 = Math.max, a2 = `[object Function]`, o2 = function(e3, t3) { 2227 for (var n3 = [], r3 = 0; r3 < e3.length; r3 += 1) n3[r3] = e3[r3]; 2228 for (var i3 = 0; i3 < t3.length; i3 += 1) n3[i3 + e3.length] = t3[i3]; 2229 return n3; 2230 }, s2 = function(e3, t3) { 2231 for (var n3 = [], r3 = t3 || 0, i3 = 0; r3 < e3.length; r3 += 1, i3 += 1) n3[i3] = e3[r3]; 2232 return n3; 2233 }, c2 = function(e3, t3) { 2234 for (var n3 = ``, r3 = 0; r3 < e3.length; r3 += 1) n3 += e3[r3], r3 + 1 < e3.length && (n3 += t3); 2235 return n3; 2236 }; 2237 t2.exports = function(e3) { 2238 var t3 = this; 2239 if (typeof t3 != `function` || r2.apply(t3) !== a2) throw TypeError(n2 + t3); 2240 for (var l2 = s2(arguments, 1), u2, d2 = function() { 2241 if (this instanceof u2) { 2242 var n3 = t3.apply(this, o2(l2, arguments)); 2243 return Object(n3) === n3 ? n3 : this; 2244 } 2245 return t3.apply(e3, o2(l2, arguments)); 2246 }, f2 = i2(0, t3.length - l2.length), p2 = [], m2 = 0; m2 < f2; m2++) p2[m2] = `$` + m2; 2247 if (u2 = Function(`binder`, `return function (` + c2(p2, `,`) + `){ return binder.apply(this,arguments); }`)(d2), t3.prototype) { 2248 var h2 = function() { 2249 }; 2250 h2.prototype = t3.prototype, u2.prototype = new h2(), h2.prototype = null; 2251 } 2252 return u2; 2253 }; 2254})), Ye = i(((e2, t2) => { 2255 var n2 = Je(); 2256 t2.exports = Function.prototype.bind || n2; 2257})), Xe = i(((e2, t2) => { 2258 t2.exports = Function.prototype.call; 2259})), Ze = i(((e2, t2) => { 2260 t2.exports = Function.prototype.apply; 2261})), Qe = i(((e2, t2) => { 2262 t2.exports = typeof Reflect < `u` && Reflect && Reflect.apply; 2263})), $e = i(((e2, t2) => { 2264 var n2 = Ye(), r2 = Ze(), i2 = Xe(); 2265 t2.exports = Qe() || n2.call(i2, r2); 2266})), et = i(((e2, t2) => { 2267 var n2 = Ye(), r2 = Se(), i2 = Xe(), a2 = $e(); 2268 t2.exports = function(e3) { 2269 if (e3.length < 1 || typeof e3[0] != `function`) throw new r2(`a function is required`); 2270 return a2(n2, i2, e3); 2271 }; 2272})), tt = i(((e2, t2) => { 2273 var n2 = et(), r2 = He(), i2; 2274 try { 2275 i2 = [].__proto__ === Array.prototype; 2276 } catch (e3) { 2277 if (!e3 || typeof e3 != `object` || !(`code` in e3) || e3.code !== `ERR_PROTO_ACCESS`) throw e3; 2278 } 2279 var a2 = !!i2 && r2 && r2(Object.prototype, `__proto__`), o2 = Object, s2 = o2.getPrototypeOf; 2280 t2.exports = a2 && typeof a2.get == `function` ? n2([a2.get]) : typeof s2 == `function` ? function(e3) { 2281 return s2(e3 == null ? e3 : o2(e3)); 2282 } : false; 2283})), nt = i(((e2, t2) => { 2284 var n2 = Ke(), r2 = qe(), i2 = tt(); 2285 t2.exports = n2 ? function(e3) { 2286 return n2(e3); 2287 } : r2 ? function(e3) { 2288 if (!e3 || typeof e3 != `object` && typeof e3 != `function`) throw TypeError(`getProto: not an object`); 2289 return r2(e3); 2290 } : i2 ? function(e3) { 2291 return i2(e3); 2292 } : null; 2293})), rt = i(((e2, t2) => { 2294 var n2 = Function.prototype.call, r2 = Object.prototype.hasOwnProperty; 2295 t2.exports = Ye().call(n2, r2); 2296})), it = i(((e2, t2) => { 2297 var n2, r2 = Ee(), i2 = De(), a2 = Oe(), o2 = ke(), s2 = Ae(), c2 = je(), l2 = Se(), u2 = Me(), d2 = Ne(), f2 = Pe(), p2 = Fe(), m2 = Ie(), h2 = Le(), g2 = Re(), _2 = Be(), v2 = Function, y2 = function(e3) { 2298 try { 2299 return v2(`"use strict"; return (` + e3 + `).constructor;`)(); 2300 } catch { 2301 } 2302 }, b2 = He(), x2 = Ue(), S2 = function() { 2303 throw new l2(); 2304 }, C2 = b2 ? (function() { 2305 try { 2306 return arguments.callee, S2; 2307 } catch { 2308 try { 2309 return b2(arguments, `callee`).get; 2310 } catch { 2311 return S2; 2312 } 2313 } 2314 })() : S2, w2 = Ge()(), T2 = nt(), E2 = qe(), D2 = Ke(), O2 = Ze(), k2 = Xe(), A2 = {}, j2 = typeof Uint8Array > `u` || !T2 ? n2 : T2(Uint8Array), M2 = { __proto__: null, "%AggregateError%": typeof AggregateError > `u` ? n2 : AggregateError, "%Array%": Array, "%ArrayBuffer%": typeof ArrayBuffer > `u` ? n2 : ArrayBuffer, "%ArrayIteratorPrototype%": w2 && T2 ? T2([][Symbol.iterator]()) : n2, "%AsyncFromSyncIteratorPrototype%": n2, "%AsyncFunction%": A2, "%AsyncGenerator%": A2, "%AsyncGeneratorFunction%": A2, "%AsyncIteratorPrototype%": A2, "%Atomics%": typeof Atomics > `u` ? n2 : Atomics, "%BigInt%": typeof BigInt > `u` ? n2 : BigInt, "%BigInt64Array%": typeof BigInt64Array > `u` ? n2 : BigInt64Array, "%BigUint64Array%": typeof BigUint64Array > `u` ? n2 : BigUint64Array, "%Boolean%": Boolean, "%DataView%": typeof DataView > `u` ? n2 : DataView, "%Date%": Date, "%decodeURI%": decodeURI, "%decodeURIComponent%": decodeURIComponent, "%encodeURI%": encodeURI, "%encodeURIComponent%": encodeURIComponent, "%Error%": i2, "%eval%": eval, "%EvalError%": a2, "%Float16Array%": typeof Float16Array > `u` ? n2 : Float16Array, "%Float32Array%": typeof Float32Array > `u` ? n2 : Float32Array, "%Float64Array%": typeof Float64Array > `u` ? n2 : Float64Array, "%FinalizationRegistry%": typeof FinalizationRegistry > `u` ? n2 : FinalizationRegistry, "%Function%": v2, "%GeneratorFunction%": A2, "%Int8Array%": typeof Int8Array > `u` ? n2 : Int8Array, "%Int16Array%": typeof Int16Array > `u` ? n2 : Int16Array, "%Int32Array%": typeof Int32Array > `u` ? n2 : Int32Array, "%isFinite%": isFinite, "%isNaN%": isNaN, "%IteratorPrototype%": w2 && T2 ? T2(T2([][Symbol.iterator]())) : n2, "%JSON%": typeof JSON == `object` ? JSON : n2, "%Map%": typeof Map > `u` ? n2 : Map, "%MapIteratorPrototype%": typeof Map > `u` || !w2 || !T2 ? n2 : T2((/* @__PURE__ */ new Map())[Symbol.iterator]()), "%Math%": Math, "%Number%": Number, "%Object%": r2, "%Object.getOwnPropertyDescriptor%": b2, "%parseFloat%": parseFloat, "%parseInt%": parseInt, "%Promise%": typeof Promise > `u` ? n2 : Promise, "%Proxy%": typeof Proxy > `u` ? n2 : Proxy, "%RangeError%": o2, "%ReferenceError%": s2, "%Reflect%": typeof Reflect > `u` ? n2 : Reflect, "%RegExp%": RegExp, "%Set%": typeof Set > `u` ? n2 : Set, "%SetIteratorPrototype%": typeof Set > `u` || !w2 || !T2 ? n2 : T2((/* @__PURE__ */ new Set())[Symbol.iterator]()), "%SharedArrayBuffer%": typeof SharedArrayBuffer > `u` ? n2 : SharedArrayBuffer, "%String%": String, "%StringIteratorPrototype%": w2 && T2 ? T2(``[Symbol.iterator]()) : n2, "%Symbol%": w2 ? Symbol : n2, "%SyntaxError%": c2, "%ThrowTypeError%": C2, "%TypedArray%": j2, "%TypeError%": l2, "%Uint8Array%": typeof Uint8Array > `u` ? n2 : Uint8Array, "%Uint8ClampedArray%": typeof Uint8ClampedArray > `u` ? n2 : Uint8ClampedArray, "%Uint16Array%": typeof Uint16Array > `u` ? n2 : Uint16Array, "%Uint32Array%": typeof Uint32Array > `u` ? n2 : Uint32Array, "%URIError%": u2, "%WeakMap%": typeof WeakMap > `u` ? n2 : WeakMap, "%WeakRef%": typeof WeakRef > `u` ? n2 : WeakRef, "%WeakSet%": typeof WeakSet > `u` ? n2 : WeakSet, "%Function.prototype.call%": k2, "%Function.prototype.apply%": O2, "%Object.defineProperty%": x2, "%Object.getPrototypeOf%": E2, "%Math.abs%": d2, "%Math.floor%": f2, "%Math.max%": p2, "%Math.min%": m2, "%Math.pow%": h2, "%Math.round%": g2, "%Math.sign%": _2, "%Reflect.getPrototypeOf%": D2 }; 2315 if (T2) try { 2316 null.error; 2317 } catch (e3) { 2318 M2[`%Error.prototype%`] = T2(T2(e3)); 2319 } 2320 var N2 = function e3(t3) { 2321 var n3; 2322 if (t3 === `%AsyncFunction%`) n3 = y2(`async function () {}`); 2323 else if (t3 === `%GeneratorFunction%`) n3 = y2(`function* () {}`); 2324 else if (t3 === `%AsyncGeneratorFunction%`) n3 = y2(`async function* () {}`); 2325 else if (t3 === `%AsyncGenerator%`) { 2326 var r3 = e3(`%AsyncGeneratorFunction%`); 2327 r3 && (n3 = r3.prototype); 2328 } else if (t3 === `%AsyncIteratorPrototype%`) { 2329 var i3 = e3(`%AsyncGenerator%`); 2330 i3 && T2 && (n3 = T2(i3.prototype)); 2331 } 2332 return M2[t3] = n3, n3; 2333 }, P2 = { __proto__: null, "%ArrayBufferPrototype%": [`ArrayBuffer`, `prototype`], "%ArrayPrototype%": [`Array`, `prototype`], "%ArrayProto_entries%": [`Array`, `prototype`, `entries`], "%ArrayProto_forEach%": [`Array`, `prototype`, `forEac
2333h`], "%ArrayProto_keys%": [`Array`, `prototype`, `keys`], "%ArrayProto_values%": [`Array`, `prototype`, `values`], "%AsyncFunctionPrototype%": [`AsyncFunction`, `prototype`], "%AsyncGenerator%": [`AsyncGeneratorFunction`, `prototype`], "%AsyncGeneratorPrototype%": [`AsyncGeneratorFunction`, `prototype`, `prototype`], "%BooleanPrototype%": [`Boolean`, `prototype`], "%DataViewPrototype%": [`DataView`, `prototype`], "%DatePrototype%": [`Date`, `prototype`], "%ErrorPrototype%": [`Error`, `prototype`], "%EvalErrorPrototype%": [`EvalError`, `prototype`], "%Float32ArrayPrototype%": [`Float32Array`, `prototype`], "%Float64ArrayPrototype%": [`Float64Array`, `prototype`], "%FunctionPrototype%": [`Function`, `prototype`], "%Generator%": [`GeneratorFunction`, `prototype`], "%GeneratorPrototype%": [`GeneratorFunction`, `prototype`, `prototype`], "%Int8ArrayPrototype%": [`Int8Array`, `prototype`], "%Int16ArrayPrototype%": [`Int16Array`, `prototype`], "%Int32ArrayPrototype%": [`Int32Array`, `prototype`], "%JSONParse%": [`JSON`, `parse`], "%JSONStringify%": [`JSON`, `stringify`], "%MapPrototype%": [`Map`, `prototype`], "%NumberPrototype%": [`Number`, `prototype`], "%ObjectPrototype%": [`Object`, `prototype`], "%ObjProto_toString%": [`Object`, `prototype`, `toString`], "%ObjProto_valueOf%": [`Object`, `prototype`, `valueOf`], "%PromisePrototype%": [`Promise`, `prototype`], "%PromiseProto_then%": [`Promise`, `prototype`, `then`], "%Promise_all%": [`Promise`, `all`], "%Promise_reject%": [`Promise`, `reject`], "%Promise_resolve%": [`Promise`, `resolve`], "%RangeErrorPrototype%": [`RangeError`, `prototype`], "%ReferenceErrorPrototype%": [`ReferenceError`, `prototype`], "%RegExpPrototype%": [`RegExp`, `prototype`], "%SetPrototype%": [`Set`, `prototype`], "%SharedArrayBufferPrototype%": [`SharedArrayBuffer`, `prototype`], "%StringPrototype%": [`String`, `prototype`], "%SymbolPrototype%": [`Symbol`, `prototype`], "%SyntaxErrorPrototype%": [`SyntaxError`, `prototype`], "%TypedArrayPrototype%": [`TypedArray`, `prototype`], "%TypeErrorPrototype%": [`TypeError`, `prototype`], "%Uint8ArrayPrototype%": [`Uint8Array`, `prototype`], "%Uint8ClampedArrayPrototype%": [`Uint8ClampedArray`, `prototype`], "%Uint16ArrayPrototype%": [`Uint16Array`, `prototype`], "%Uint32ArrayPrototype%": [`Uint32Array`, `prototype`], "%URIErrorPrototype%": [`URIError`, `prototype`], "%WeakMapPrototype%": [`WeakMap`, `prototype`], "%WeakSetPrototype%": [`WeakSet`, `prototype`] }, F2 = Ye(), I2 = rt(), L2 = F2.call(k2, Array.prototype.concat), R2 = F2.call(O2, Array.prototype.splice), z2 = F2.call(k2, String.prototype.replace), B2 = F2.call(k2, String.prototype.slice), V2 = F2.call(k2, RegExp.prototype.exec), H2 = /[^%.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|%$))/g, U2 = /\\(\\)?/g, W2 = function(e3) { 2334 var t3 = B2(e3, 0, 1), n3 = B2(e3, -1); 2335 if (t3 === `%` && n3 !== `%`) throw new c2("invalid intrinsic syntax, expected closing `%`"); 2336 if (n3 === `%` && t3 !== `%`) throw new c2("invalid intrinsic syntax, expected opening `%`"); 2337 var r3 = []; 2338 return z2(e3, H2, function(e4, t4, n4, i3) { 2339 r3[r3.length] = n4 ? z2(i3, U2, `$1`) : t4 || e4; 2340 }), r3; 2341 }, G2 = function(e3, t3) { 2342 var n3 = e3, r3; 2343 if (I2(P2, n3) && (r3 = P2[n3], n3 = `%` + r3[0] + `%`), I2(M2, n3)) { 2344 var i3 = M2[n3]; 2345 if (i3 === A2 && (i3 = N2(n3)), i3 === void 0 && !t3) throw new l2(`intrinsic ` + e3 + ` exists, but is not available. Please file an issue!`); 2346 return { alias: r3, name: n3, value: i3 }; 2347 } 2348 throw new c2(`intrinsic ` + e3 + ` does not exist!`); 2349 }; 2350 t2.exports = function(e3, t3) { 2351 if (typeof e3 != `string` || e3.length === 0) throw new l2(`intrinsic name must be a non-empty string`); 2352 if (arguments.length > 1 && typeof t3 != `boolean`) throw new l2(`"allowMissing" argument must be a boolean`); 2353 if (V2(/^%?[^%]*%?$/, e3) === null) throw new c2("`%` may not be present anywhere but at the beginning and end of the intrinsic name"); 2354 var n3 = W2(e3), r3 = n3.length > 0 ? n3[0] : ``, i3 = G2(`%` + r3 + `%`, t3), a3 = i3.name, o3 = i3.value, s3 = false, u3 = i3.alias; 2355 u3 && (r3 = u3[0], R2(n3, L2([0, 1], u3))); 2356 for (var d3 = 1, f3 = true; d3 < n3.length; d3 += 1) { 2357 var p3 = n3[d3], m3 = B2(p3, 0, 1), h3 = B2(p3, -1); 2358 if ((m3 === `"` || m3 === `'` || m3 === "`" || h3 === `"` || h3 === `'` || h3 === "`") && m3 !== h3) throw new c2(`property names with quotes must have matching quotes`); 2359 if ((p3 === `constructor` || !f3) && (s3 = true), r3 += `.` + p3, a3 = `%` + r3 + `%`, I2(M2, a3)) o3 = M2[a3]; 2360 else if (o3 != null) { 2361 if (!(p3 in o3)) { 2362 if (!t3) throw new l2(`base intrinsic for ` + e3 + ` exists, but the property is not available.`); 2363 return; 2364 } 2365 if (b2 && d3 + 1 >= n3.length) { 2366 var g3 = b2(o3, p3); 2367 f3 = !!g3, o3 = f3 && `get` in g3 && !(`originalValue` in g3.get) ? g3.get : o3[p3]; 2368 } else f3 = I2(o3, p3), o3 = o3[p3]; 2369 f3 && !s3 && (M2[a3] = o3); 2370 } 2371 } 2372 return o3; 2373 }; 2374})), at = i(((e2, t2) => { 2375 var n2 = it(), r2 = et(), i2 = r2([n2(`%String.prototype.indexOf%`)]); 2376 t2.exports = function(e3, t3) { 2377 var a2 = n2(e3, !!t3); 2378 return typeof a2 == `function` && i2(e3, `.prototype.`) > -1 ? r2([a2]) : a2; 2379 }; 2380})), ot = i(((e2, t2) => { 2381 var n2 = it(), r2 = at(), i2 = we(), a2 = Se(), o2 = n2(`%Map%`, true), s2 = r2(`Map.prototype.get`, true), c2 = r2(`Map.prototype.set`, true), l2 = r2(`Map.prototype.has`, true), u2 = r2(`Map.prototype.delete`, true), d2 = r2(`Map.prototype.size`, true); 2382 t2.exports = !!o2 && function() { 2383 var e3, t3 = { assert: function(e4) { 2384 if (!t3.has(e4)) throw new a2(`Side channel does not contain ` + i2(e4)); 2385 }, delete: function(t4) { 2386 if (e3) { 2387 var n3 = u2(e3, t4); 2388 return d2(e3) === 0 && (e3 = void 0), n3; 2389 } 2390 return false;
2391 }, get: function(t4) { 2392 if (e3) return s2(e3, t4); 2393 }, has: function(t4) { 2394 return e3 ? l2(e3, t4) : false; 2395 }, set: function(t4, n3) { 2396 e3 || (e3 = new o2()), c2(e3, t4, n3); 2397 } }; 2398 return t3; 2399 }; 2400})), st = i(((e2, t2) => { 2401 var n2 = it(), r2 = at(), i2 = we(), a2 = ot(), o2 = Se(), s2 = n2(`%WeakMap%`, true), c2 = r2(`WeakMap.prototype.get`, true), l2 = r2(`WeakMap.prototype.set`, true), u2 = r2(`WeakMap.prototype.has`, true), d2 = r2(`WeakMap.prototype.delete`, true); 2402 t2.exports = s2 ? function() { 2403 var e3, t3, n3 = { assert: function(e4) { 2404 if (!n3.has(e4)) throw new o2(`Side channel does not contain ` + i2(e4)); 2405 }, delete: function(n4) { 2406 if (s2 && n4 && (typeof n4 == `object` || typeof n4 == `function`)) { 2407 if (e3) return d2(e3, n4); 2408 } else if (a2 && t3) return t3.delete(n4); 2409 return false; 2410 }, get: function(n4) { 2411 return s2 && n4 && (typeof n4 == `object` || typeof n4 == `function`) && e3 ? c2(e3, n4) : t3 && t3.get(n4); 2412 }, has: function(n4) { 2413 return s2 && n4 && (typeof n4 == `object` || typeof n4 == `function`) && e3 ? u2(e3, n4) : !!t3 && t3.has(n4); 2414 }, set: function(n4, r3) { 2415 s2 && n4 && (typeof n4 == `object` || typeof n4 == `function`) ? (e3 || (e3 = new s2()), l2(e3, n4, r3)) : a2 && (t3 || (t3 = a2()), t3.set(n4, r3)); 2416 } }; 2417 return n3; 2418 } : a2; 2419})), ct = i(((e2, t2) => { 2420 var n2 = Se(), r2 = we(), i2 = Te(), a2 = ot(), o2 = st() || a2 || i2; 2421 t2.exports = function() { 2422 var e3, t3 = { assert: function(e4) { 2423 if (!t3.has(e4)) throw new n2(`Side channel does not contain ` + r2(e4)); 2424 }, delete: function(t4) { 2425 return !!e3 && e3.delete(t4); 2426 }, get: function(t4) { 2427 return e3 && e3.get(t4); 2428 }, has: function(t4) { 2429 return !!e3 && e3.has(t4); 2430 }, set: function(t4, n3) { 2431 e3 || (e3 = o2()), e3.set(t4, n3); 2432 } }; 2433 return t3; 2434 }; 2435})), lt = i(((e2, t2) => { 2436 var n2 = String.prototype.replace, r2 = /%20/g, i2 = { RFC1738: `RFC1738`, RFC3986: `RFC3986` }; 2437 t2.exports = { default: i2.RFC3986, formatters: { RFC1738: function(e3) { 2438 return n2.call(e3, r2, `+`); 2439 }, RFC3986: function(e3) { 2440 return String(e3); 2441 } }, RFC1738: i2.RFC1738, RFC3986: i2.RFC3986 }; 2442})), ut = i(((e2, t2) => { 2443 var n2 = lt(), r2 = ct(), i2 = Object.prototype.hasOwnProperty, a2 = Array.isArray, o2 = r2(), s2 = function(e3, t3) { 2444 return o2.set(e3, t3), e3; 2445 }, c2 = function(e3) { 2446 return o2.has(e3); 2447 }, l2 = function(e3) { 2448 return o2.get(e3); 2449 }, u2 = function(e3, t3) { 2450 o2.set(e3, t3); 2451 }, d2 = (function() { 2452 for (var e3 = [], t3 = 0; t3 < 256; ++t3) e3[e3.length] = `%` + ((t3 < 16 ? `0` : ``) + t3.toString(16)).toUpperCase(); 2453 return e3; 2454 })(), f2 = function(e3) { 2455 for (; e3.length > 1; ) { 2456 var t3 = e3.pop(), n3 = t3.obj[t3.prop]; 2457 if (a2(n3)) { 2458 for (var r3 = [], i3 = 0; i3 < n3.length; ++i3) n3[i3] !== void 0 && (r3[r3.length] = n3[i3]); 2459 t3.obj[t3.prop] = r3; 2460 } 2461 } 2462 }, p2 = function(e3, t3) { 2463 for (var n3 = t3 && t3.plainObjects ? { __proto__: null } : {}, r3 = 0; r3 < e3.length; ++r3) e3[r3] !== void 0 && (n3[r3] = e3[r3]); 2464 return n3; 2465 }, m2 = function e3(t3, n3, r3) { 2466 if (!n3) return t3; 2467 if (typeof n3 != `object` && typeof n3 != `function`) { 2468 if (a2(t3)) { 2469 var o3 = t3.length; 2470 if (r3 && typeof r3.arrayLimit == `number` && o3 > r3.arrayLimit) return s2(p2(t3.concat(n3), r3), o3); 2471 t3[o3] = n3; 2472 } else if (t3 && typeof t3 == `object`) if (c2(t3)) { 2473 var d3 = l2(t3) + 1; 2474 t3[d3] = n3, u2(t3, d3); 2475 } else if (r3 && r3.strictMerge) return [t3, n3]; 2476 else (r3 && (r3.plainObjects || r3.allowPrototypes) || !i2.call(Object.prototype, n3)) && (t3[n3] = true); 2477 else return [t3, n3]; 2478 return t3; 2479 } 2480 if (!t3 || typeof t3 != `object`) { 2481 if (c2(n3)) { 2482 for (var f3 = Object.keys(n3), m3 = r3 && r3.plainObjects ? { __proto__: null, 0: t3 } : { 0: t3 }, h3 = 0; h3 < f3.length; h3++) { 2483 var g3 = parseInt(f3[h3], 10); 2484 m3[g3 + 1] = n3[f3[h3]]; 2485 } 2486 return s2(m3, l2(n3) + 1); 2487 } 2488 var _3 = [t3].concat(n3); 2489 return r3 && typeof r3.arrayLimit == `number` && _3.length > r3.arrayLimit ? s2(p2(_3, r3), _3.length - 1) : _3; 2490 } 2491 var v2 = t3; 2492 return a2(t3) && !a2(n3) && (v2 = p2(t3, r3)), a2(t3) && a2(n3) ? (n3.forEach(function(n4, a3) { 2493 if (i2.call(t3, a3)) { 2494 var o4 = t3[a3]; 2495 o4 && typeof o4 == `object` && n4 && typeof n4 == `object` ? t3[a3] = e3(o4, n4, r3) : t3[t3.length] = n4; 2496 } else t3[a3] = n4; 2497 }), t3) : Object.keys(n3).reduce(function(t4, a3) { 2498 var o4 = n3[a3]; 2499 if (i2.call(t4, a3) ? t4[a3] = e3(t4[a3], o4, r3) : t4[a3] = o4, c2(n3) && !c2(t4) && s2(t4, l2(n3)), c2(t4)) { 2500 var d4 = parseInt(a3, 10); 2501 String(d4) === a3 && d4 >= 0 && d4 > l2(t4) && u2(t4, d4); 2502 } 2503 return t4; 2504 }, v2); 2505 }, h2 = function(e3, t3) { 2506 return Object.keys(t3).reduce(function(e4, n3) { 2507 return e4[n3] = t3[n3], e4; 2508 }, e3); 2509 }, g2 = function(e3, t3, n3) { 2510 var r3 = e3.replace(/\+/g, ` `); 2511 if (n3 === `iso-8859-1`) return r3.replace(/%[0-9a-f]{2}/gi, unescape); 2512 try { 2513 return decodeURIComponent(r3); 2514 } catch { 2515 return r3; 2516 } 2517 }, _2 = 1024; 2518 t2.exports = { arrayToObject: p2, assign: h2, combine: function(e3, t3, n3, r3) { 2519 if (c2(e3)) { 2520 var i3 = l2(e3) + 1; 2521 return e3[i3] = t3, u2(e3, i3), e3; 2522 } 2523 var a3 = [].concat(e3, t3); 2524 return a3.length > n3 ? s2(p2(a3, { plainObjects: r3 }), a3.length - 1) : a3; 2525 }, compact: function(e3) { 2526 for (var t3 = [{ obj: { o: e3 }, prop: `o` }], n3 = [], r3 = 0; r3 < t3.length; ++r3) for (var i3 = t3[r3], a3 = i3.obj[i3.prop], o3 = Object.keys(a3), s3 = 0; s3 < o3.length; ++s3) { 2527 var c3 = o3[s3], l3 = a3[c3]; 2528 typeof l3 == `object` && l3 && n3.indexOf(l3) === -1 && (t3[t3.length] = { obj: a3, prop: c3 }, n3[n3.length] = l3); 2529 } 2530 return f2(t3), e3; 2531 }, decode: g2, encode: function(e3, t3, r3, i3, a3) { 2532 if (e3.length === 0) return e3; 2533 var o3 = e3; 2534 if (typeof e3 == `symbol` ? o3 = Symbol.prototype.toString.call(e3) : typeof e3 != `string` && (o3 = String(e3)), r3 === `iso-8859-1`) return escape(o3).replace(/%u[0-9a-f]{4}/gi, function(e4) { 2535 return `%26%23` + parseInt(e4.slice(2), 16) + `%3B`; 2536 }); 2537 for (var s3 = ``, c3 = 0; c3 < o3.length; c3 += _2) { 2538 for (var l3 = o3.length >= _2 ? o3.slice(c3, c3 + _2) : o3, u3 = [], f3 = 0; f3 < l3.length; ++f3) { 2539 var p3 = l3.charCodeAt(f3); 2540 if (p3 === 45 || p3 === 46 || p3 === 95 || p3 === 126 || p3 >= 48 && p3 <= 57 || p3 >= 65 && p3 <= 90 || p3 >= 97 && p3 <= 122 || a3 === n2.RFC1738 && (p3 === 40 || p3 === 41)) { 2541 u3[u3.length] = l3.charAt(f3); 2542 continue; 2543 } 2544 if (p3 < 128) { 2545 u3[u3.length] = d2[p3]; 2546 continue; 2547 } 2548 if (p3 < 2048) { 2549 u3[u3.length] = d2[192 | p3 >> 6] + d2[128 | p3 & 63]; 2550 continue; 2551 } 2552 if (p3 < 55296 || p3 >= 57344) { 2553 u3[u3.length] = d2[224 | p3 >> 12] + d2[128 | p3 >> 6 & 63] + d2[128 | p3 & 63]; 2554 continue; 2555 } 2556 f3 += 1, p3 = 65536 + ((p3 & 1023) << 10 | l3.charCodeAt(f3) & 1023), u3[u3.length] = d2[240 | p3 >> 18] + d2[128 | p3 >> 12 & 63] + d2[128 | p3 >> 6 & 63] + d2[128 | p3 & 63]; 2557 } 2558 s3 += u3.join(``); 2559 } 2560 return s3; 2561 }, isBuffer: function(e3) { 2562 return !e3 || typeof e3 != `object` ? false : !!(e3.constructor && e3.constructor.isBuffer && e3.constructor.isBuffer(e3)); 2563 }, isOverflow: c2, isRegExp: function(e3) { 2564 return Object.prototype.toString.call(e3) === `[object RegExp]`; 2565 }, markOverflow: s2, maybeMap: function(e3, t3) { 2566 if (a2(e3)) { 2567 for (var n3 = [], r3 = 0; r3 < e3.length; r3 += 1) n3[n3.length] = t3(e3[r3]); 2568 return n3; 2569 } 2570 return t3(e3); 2571 }, merge: m2 }; 2572})), dt = i(((e2, t2) => { 2573 var n2 = ct(), r2 = ut(), i2 = lt(), a2 = Object.prototype.hasOwnProperty, o2 = { brackets: function(e3) { 2574 return e3 + `[]`; 2575 }, comma: `comma`, indices: function(e3, t3) { 2576 return e3 + `[` + t3 + `]`; 2577 }, repeat: function(e3) { 2578 return e3; 2579 } }, s2 = Array.isArray, c2 = Array.prototype.push, l2 = function(e3, t3) { 2580 c2.apply(e3, s2(t3) ? t3 : [t3]); 2581 }, u2 = Date.prototype.toISOString, d2 = i2.default, f2 = { addQueryPrefix: false, allowDots: false, allowEmptyArrays: fal
vendor: 10,312 bytes, lines 2581-2699
2581se, arrayFormat: `indices`, charset: `utf-8`, charsetSentinel: false, commaRoundTrip: false, delimiter: `&`, encode: true, encodeDotInKeys: false, encoder: r2.encode, encodeValuesOnly: false, filter: void 0, format: d2, formatter: i2.formatters[d2], indices: false, serializeDate: function(e3) { 2582 return u2.call(e3); 2583 }, skipNulls: false, strictNullHandling: false }, p2 = function(e3) { 2584 return typeof e3 == `string` || typeof e3 == `number` || typeof e3 == `boolean` || typeof e3 == `symbol` || typeof e3 == `bigint`; 2585 }, m2 = {}, h2 = function e3(t3, i3, a3, o3, c3, u3, d3, h3, g3, _2, v2, y2, b2, x2, S2, C2, w2, T2) { 2586 for (var E2 = t3, D2 = T2, O2 = 0, k2 = false; (D2 = D2.get(m2)) !== void 0 && !k2; ) { 2587 var A2 = D2.get(t3); 2588 if (O2 += 1, A2 !== void 0) { 2589 if (A2 === O2) throw RangeError(`Cyclic object value`); 2590 k2 = true; 2591 } 2592 D2.get(m2) === void 0 && (O2 = 0); 2593 } 2594 if (typeof _2 == `function` ? E2 = _2(i3, E2) : E2 instanceof Date ? E2 = b2(E2) : a3 === `comma` && s2(E2) && (E2 = r2.maybeMap(E2, function(e4) { 2595 return e4 instanceof Date ? b2(e4) : e4; 2596 })), E2 === null) { 2597 if (u3) return g3 && !C2 ? g3(i3, f2.encoder, w2, `key`, x2) : i3; 2598 E2 = ``; 2599 } 2600 if (p2(E2) || r2.isBuffer(E2)) return g3 ? [S2(C2 ? i3 : g3(i3, f2.encoder, w2, `key`, x2)) + `=` + S2(g3(E2, f2.encoder, w2, `value`, x2))] : [S2(i3) + `=` + S2(String(E2))]; 2601 var j2 = []; 2602 if (E2 === void 0) return j2; 2603 var M2; 2604 if (a3 === `comma` && s2(E2)) C2 && g3 && (E2 = r2.maybeMap(E2, g3)), M2 = [{ value: E2.length > 0 ? E2.join(`,`) || null : void 0 }]; 2605 else if (s2(_2)) M2 = _2; 2606 else { 2607 var N2 = Object.keys(E2); 2608 M2 = v2 ? N2.sort(v2) : N2; 2609 } 2610 var P2 = h3 ? String(i3).replace(/\./g, `%2E`) : String(i3), F2 = o3 && s2(E2) && E2.length === 1 ? P2 + `[]` : P2; 2611 if (c3 && s2(E2) && E2.length === 0) return F2 + `[]`; 2612 for (var I2 = 0; I2 < M2.length; ++I2) { 2613 var L2 = M2[I2], R2 = typeof L2 == `object` && L2 && L2.value !== void 0 ? L2.value : E2[L2]; 2614 if (!(d3 && R2 === null)) { 2615 var z2 = y2 && h3 ? String(L2).replace(/\./g, `%2E`) : String(L2), B2 = s2(E2) ? typeof a3 == `function` ? a3(F2, z2) : F2 : F2 + (y2 ? `.` + z2 : `[` + z2 + `]`); 2616 T2.set(t3, O2); 2617 var V2 = n2(); 2618 V2.set(m2, T2), l2(j2, e3(R2, B2, a3, o3, c3, u3, d3, h3, a3 === `comma` && C2 && s2(E2) ? null : g3, _2, v2, y2, b2, x2, S2, C2, w2, V2)); 2619 } 2620 } 2621 return j2; 2622 }, g2 = function(e3) { 2623 if (!e3) return f2; 2624 if (e3.allowEmptyArrays !== void 0 && typeof e3.allowEmptyArrays != `boolean`) throw TypeError("`allowEmptyArrays` option can only be `true` or `false`, when provided"); 2625 if (e3.encodeDotInKeys !== void 0 && typeof e3.encodeDotInKeys != `boolean`) throw TypeError("`encodeDotInKeys` option can only be `true` or `false`, when provided"); 2626 if (e3.encoder !== null && e3.encoder !== void 0 && typeof e3.encoder != `function`) throw TypeError(`Encoder has to be a function.`); 2627 var t3 = e3.charset || f2.charset; 2628 if (e3.charset !== void 0 && e3.charset !== `utf-8` && e3.charset !== `iso-8859-1`) throw TypeError(`The charset option must be either utf-8, iso-8859-1, or undefined`); 2629 var n3 = i2.default; 2630 if (e3.format !== void 0) { 2631 if (!a2.call(i2.formatters, e3.format)) throw TypeError(`Unknown format option provided.`); 2632 n3 = e3.format; 2633 } 2634 var r3 = i2.formatters[n3], c3 = f2.filter; 2635 (typeof e3.filter == `function` || s2(e3.filter)) && (c3 = e3.filter); 2636 var l3 = e3.arrayFormat in o2 ? e3.arrayFormat : `indices` in e3 ? e3.indices ? `indices` : `repeat` : f2.arrayFormat; 2637 if (`commaRoundTrip` in e3 && typeof e3.commaRoundTrip != `boolean`) throw TypeError("`commaRoundTrip` must be a boolean, or absent"); 2638 var u3 = e3.allowDots === void 0 ? e3.encodeDotInKeys === true ? true : f2.allowDots : !!e3.allowDots; 2639 return { addQueryPrefix: typeof e3.addQueryPrefix == `boolean` ? e3.addQueryPrefix : f2.addQueryPrefix, allowDots: u3, allowEmptyArrays: typeof e3.allowEmptyArrays == `boolean` ? !!e3.allowEmptyArrays : f2.allowEmptyArrays, arrayFormat: l3, charset: t3, charsetSentinel: typeof e3.charsetSentinel == `boolean` ? e3.charsetSentinel : f2.charsetSentinel, commaRoundTrip: !!e3.commaRoundTrip, delimiter: e3.delimiter === void 0 ? f2.delimiter : e3.delimiter, encode: typeof e3.encode == `boolean` ? e3.encode : f2.encode, encodeDotInKeys: typeof e3.encodeDotInKeys == `boolean` ? e3.encodeDotInKeys : f2.encodeDotInKeys, encoder: typeof e3.encoder == `function` ? e3.encoder : f2.encoder, encodeValuesOnly: typeof e3.encodeValuesOnly == `boolean` ? e3.encodeValuesOnly : f2.encodeValuesOnly, filter: c3, format: n3, formatter: r3, serializeDate: typeof e3.serializeDate == `function` ? e3.serializeDate : f2.serializeDate, skipNulls: typeof e3.skipNulls == `boolean` ? e3.skipNulls : f2.skipNulls, sort: typeof e3.sort == `function` ? e3.sort : null, strictNullHandling: typeof e3.strictNullHandling == `boolean` ? e3.strictNullHandling : f2.strictNullHandling }; 2640 }; 2641 t2.exports = function(e3, t3) { 2642 var r3 = e3, i3 = g2(t3), a3, c3; 2643 typeof i3.filter == `function` ? (c3 = i3.filter, r3 = c3(``, r3)) : s2(i3.filter) && (c3 = i3.filter, a3 = c3); 2644 var u3 = []; 2645 if (typeof r3 != `object` || !r3) return ``; 2646 var d3 = o2[i3.arrayFormat], f3 = d3 === `comma` && i3.commaRoundTrip; 2647 a3 || (a3 = Object.keys(r3)), i3.sort && a3.sort(i3.sort); 2648 for (var p3 = n2(), m3 = 0; m3 < a3.length; ++m3) { 2649 var _2 = a3[m3], v2 = r3[_2]; 2650 i3.skipNulls && v2 === null || l2(u3, h2(v2, _2, d3, f3, i3.allowEmptyArrays, i3.strictNullHandling, i3.skipNulls, i3.encodeDotInKeys, i3.encode ? i3.encoder : null, i3.filter, i3.sort, i3.allowDots, i3.serializeDate, i3.format, i3.formatter, i3.encodeValuesOnly, i3.charset, p3)); 2651 } 2652 var y2 = u3.join(i3.delimiter), b2 = i3.addQueryPrefix === true ? `?` : ``; 2653 return i3.charsetSentinel && (i3.charset === `iso-8859-1` ? b2 += `utf8=%26%2310003%3B&` : b2 += `utf8=%E2%9C%93&`), y2.length > 0 ? b2 + y2 : ``; 2654 }; 2655})), ft = i(((e2, t2) => { 2656 var n2 = ut(), r2 = Object.prototype.hasOwnProperty, i2 = Array.isArray, a2 = { allowDots: false, allowEmptyArrays: false, allowPrototypes: false, allowSparse: false, arrayLimit: 20, charset: `utf-8`, charsetSentinel: false, comma: false, decodeDotInKeys: false, decoder: n2.decode, delimiter: `&`, depth: 5, duplicates: `combine`, ignoreQueryPrefix: false, interpretNumericEntities: false, parameterLimit: 1e3, parseArrays: true, plainObjects: false, strictDepth: false, strictMerge: true, strictNullHandling: false, throwOnLimitExceeded: false }, o2 = function(e3) { 2657 return e3.replace(/&#(\d+);/g, function(e4, t3) { 2658 return String.fromCharCode(parseInt(t3, 10)); 2659 }); 2660 }, s2 = function(e3, t3, n3) { 2661 if (e3 && typeof e3 == `string` && t3.comma && e3.indexOf(`,`) > -1) return e3.split(`,`); 2662 if (t3.throwOnLimitExceeded && n3 >= t3.arrayLimit) throw RangeError(`Array limit exceeded. Only ` + t3.arrayLimit + ` element` + (t3.arrayLimit === 1 ? `` : `s`) + ` allowed in an array.`); 2663 return e3; 2664 }, c2 = `utf8=%26%2310003%3B`, l2 = `utf8=%E2%9C%93`, u2 = function(e3, t3) { 2665 var u3 = { __proto__: null }, d3 = t3.ignoreQueryPrefix ? e3.replace(/^\?/, ``) : e3; 2666 d3 = d3.replace(/%5B/gi, `[`).replace(/%5D/gi, `]`); 2667 var f3 = t3.parameterLimit === 1 / 0 ? void 0 : t3.parameterLimit, p3 = d3.split(t3.delimiter, t3.throwOnLimitExceeded && f3 !== void 0 ? f3 + 1 : f3); 2668 if (t3.throwOnLimitExceeded && f3 !== void 0 && p3.length > f3) throw RangeError(`Parameter limit exceeded. Only ` + f3 + ` parameter` + (f3 === 1 ? `` : `s`) + ` allowed.`); 2669 var m3 = -1, h2, g2 = t3.charset; 2670 if (t3.charsetSentinel) for (h2 = 0; h2 < p3.length; ++h2) p3[h2].indexOf(`utf8=`) === 0 && (p3[h2] === l2 ? g2 = `utf-8` : p3[h2] === c2 && (g2 = `iso-8859-1`), m3 = h2, h2 = p3.length); 2671 for (h2 = 0; h2 < p3.length; ++h2) if (h2 !== m3) { 2672 var _2 = p3[h2], v2 = _2.indexOf(`]=`), y2 = v2 === -1 ? _2.indexOf(`=`) : v2 + 1, b2, x2; 2673 if (y2 === -1 ? (b2 = t3.decoder(_2, a2.decoder, g2, `key`), x2 = t3.strictNullHandling ? null : ``) : (b2 = t3.decoder(_2.slice(0, y2), a2.decoder, g2, `key`), b2 !== null && (x2 = n2.maybeMap(s2(_2.slice(y2 + 1), t3, i2(u3[b2]) ? u3[b2].length : 0), function(e4) { 2674 return t3.decoder(e4, a2.decoder, g2, `value`); 2675 }))), x2 && t3.interpretNumericEntities && g2 === `iso-8859-1` && (x2 = o2(String(x2))), _2.indexOf(`[]=`) > -1 && (x2 = i2(x2) ? [x2] : x2), t3.comma && i2(x2) && x2.length > t3.arrayLimit) { 2676 if (t3.throwOnLimitExceeded) throw RangeError(`Array limit exceeded. Only ` + t3.arrayLimit + ` element` + (t3.arrayLimit === 1 ? `` : `s`) + ` allowed in an array.`); 2677 x2 = n2.combine([], x2, t3.arrayLimit, t3.plainObjects); 2678 } 2679 if (b2 !== null) { 2680 var S2 = r2.call(u3, b2); 2681 S2 && (t3.duplicates === `combine` || _2.indexOf(`[]=`) > -1) ? u3[b2] = n2.combine(u3[b2], x2, t3.arrayLimit, t3.plainObjects) : (!S2 || t3.duplicates === `last`) && (u3[b2] = x2); 2682 } 2683 } 2684 return u3; 2685 }, d2 = function(e3, t3, r3, i3) { 2686 var a3 = 0; 2687 if (e3.length > 0 && e3[e3.length - 1] === `[]`) { 2688 var o3 = e3.slice(0, -1).join(``); 2689 a3 = Array.isArray(t3) && t3[o3] ? t3[o3].length : 0; 2690 } 2691 for (var c3 = i3 ? t3 : s2(t3, r3, a3), l3 = e3.length - 1; l3 >= 0; --l3) { 2692 var u3, d3 = e3[l3]; 2693 if (d3 === `[]` && r3.parseArrays) u3 = n2.isOverflow(c3) ? c3 : r3.allowEmptyArrays && (c3 === `` || r3.strictNullHandling && c3 === null) ? [] : n2.combine([], c3, r3.arrayLimit, r3.plainObjects); 2694 else { 2695 u3 = r3.plainObjects ? { __proto__: null } : {}; 2696 var f3 = d3.charAt(0) === `[` && d3.charAt(d3.length - 1) === `]` ? d3.slice(1, -1) : d3, p3 = r3.decodeDotInKeys ? f3.replace(/%2E/g, `.`) : f3, m3 = parseInt(p3, 10), h2 = !isNaN(m3) && d3 !== p3 && String(m3) === p3 && m3 >= 0 && r3.parseArrays; 2697 if (!r3.parseArrays && p3 === ``) u3 = { 0: c3 }; 2698 else if (h2 && m3 < r3.arrayLimit) u3 = [], u3[m3] = c3; 2699 else if (h2 && r3.throwOnLimitExceeded) throw RangeError(`Array limit exceeded. Only ` + r3.arrayLimit + ` element` + (r3.arrayLimit === 1 ? `` : `s`) + ` allowed in an array.`);
2700 else h2 ? (u3[m3] = c3, n2.markOverflow(u3, m3)) : p3 !== `__proto__` && (u3[p3] = c3); 2701 } 2702 c3 = u3; 2703 } 2704 return c3; 2705 }, f2 = function(e3, t3) { 2706 var n3 = t3.allowDots ? e3.replace(/\.([^.[]+)/g, `[$1]`) : e3; 2707 if (t3.depth <= 0) return !t3.plainObjects && r2.call(Object.prototype, n3) && !t3.allowPrototypes ? void 0 : [n3]; 2708 var i3 = /(\[[^[\]]*])/, a3 = /(\[[^[\]]*])/g, o3 = i3.exec(n3), s3 = o3 ? n3.slice(0, o3.index) : n3, c3 = []; 2709 if (s3) { 2710 if (!t3.plainObjects && r2.call(Object.prototype, s3) && !t3.allowPrototypes) return; 2711 c3[c3.length] = s3; 2712 } 2713 for (var l3 = 0; (o3 = a3.exec(n3)) !== null && l3 < t3.depth; ) { 2714 l3 += 1; 2715 var u3 = o3[1].slice(1, -1); 2716 if (!t3.plainObjects && r2.call(Object.prototype, u3) && !t3.allowPrototypes) return; 2717 c3[c3.length] = o3[1]; 2718 } 2719 if (o3) { 2720 if (t3.strictDepth === true) throw RangeError(`Input depth exceeded depth option of ` + t3.depth + ` and strictDepth is true`); 2721 c3[c3.length] = `[` + n3.slice(o3.index) + `]`; 2722 } 2723 return c3; 2724 }, p2 = function(e3, t3, n3, r3) { 2725 if (e3) { 2726 var i3 = f2(e3, n3); 2727 if (i3) return d2(i3, t3, n3, r3); 2728 } 2729 }, m2 = function(e3) { 2730 if (!e3) return a2; 2731 if (e3.allowEmptyArrays !== void 0 && typeof e3.allowEmptyArrays != `boolean`) throw TypeError("`allowEmptyArrays` option can only be `true` or `false`, when provided"); 2732 if (e3.decodeDotInKeys !== void 0 && typeof e3.decodeDotInKeys != `boolean`) throw TypeError("`decodeDotInKeys` option can only be `true` or `false`, when provided"); 2733 if (e3.decoder !== null && e3.decoder !== void 0 && typeof e3.decoder != `function`) throw TypeError(`Decoder has to be a function.`); 2734 if (e3.charset !== void 0 && e3.charset !== `utf-8` && e3.charset !== `iso-8859-1`) throw TypeError(`The charset option must be either utf-8, iso-8859-1, or undefined`); 2735 if (e3.throwOnLimitExceeded !== void 0 && typeof e3.throwOnLimitExceeded != `boolean`) throw TypeError("`throwOnLimitExceeded` option must be a boolean"); 2736 var t3 = e3.charset === void 0 ? a2.charset : e3.charset, r3 = e3.duplicates === void 0 ? a2.duplicates : e3.duplicates; 2737 if (r3 !== `combine` && r3 !== `first` && r3 !== `last`) throw TypeError(`The duplicates option must be either combine, first, or last`); 2738 return { allowDots: e3.allowDots === void 0 ? e3.decodeDotInKeys === true ? true : a2.allowDots : !!e3.allowDots, allowEmptyArrays: typeof e3.allowEmptyArrays == `boolean` ? !!e3.allowEmptyArrays : a2.allowEmptyArrays, allowPrototypes: typeof e3.allowPrototypes == `boolean` ? e3.allowPrototypes : a2.allowPrototypes, allowSparse: typeof e3.allowSparse == `boolean` ? e3.allowSparse : a2.allowSparse, arrayLimit: typeof e3.arrayLimit == `number` ? e3.arrayLimit : a2.arrayLimit, charset: t3, charsetSentinel: typeof e3.charsetSentinel == `boolean` ? e3.charsetSentinel : a2.charsetSentinel, comma: typeof e3.comma == `boolean` ? e3.comma : a2.comma, decodeDotInKeys: typeof e3.decodeDotInKeys == `boolean` ? e3.decodeDotInKeys : a2.decodeDotInKeys, decoder: typeof e3.decoder == `function` ? e3.decoder : a2.decoder, delimiter: typeof e3.delimiter == `string` || n2.isRegExp(e3.delimiter) ? e3.delimiter : a2.delimiter, depth: typeof e3.depth == `number` || e3.depth === false ? +e3.depth : a2.depth, duplicates: r3, ignoreQueryPrefix: e3.ignoreQueryPrefix === true, interpretNumericEntities: typeof e3.interpretNumericEntities == `boolean` ? e3.interpretNumericEntities : a2.interpretNumericEntities, parameterLimit: typeof e3.parameterLimit == `number` ? e3.parameterLimit : a2.parameterLimit, parseArrays: e3.parseArrays !== false, plainObjects: typeof e3.plainObjects == `boolean` ? e3.plainObjects : a2.plainObjects, strictDepth: typeof e3.strictDepth == `boolean` ? !!e3.strictDepth : a2.strictDepth, strictMerge: typeof e3.strictMerge == `boolean` ? !!e3.strictMerge : a2.strictMerge, strictNullHandling: typeof e3.strictNullHandling == `boolean` ? e3.strictNullHandling : a2.strictNullHandling, throwOnLimitExceeded: typeof e3.throwOnLimitExceeded == `boolean` ? e3.throwOnLimitExceeded : false }; 2739 }; 2740 t2.exports = function(e3, t3) { 2741 var r3 = m2(t3); 2742 if (e3 === `` || e3 == null) return r3.plainObjects ? { __proto__: null } : {}; 2743 for (var i3 = typeof e3 == `string` ? u2(e3, r3) : e3, a3 = r3.plainObjects ? { __proto__: null } : {}, o3 = Object.keys(i3), s3 = 0; s3 < o3.length; ++s3) { 2744 var c3 = o3[s3], l3 = p2(c3, i3[c3], r3, typeof e3 == `string`); 2745 a3 = n2.merge(a3, l3, r3); 2746 } 2747 return r3.allowSparse === true ? a3 : n2.compact(a3); 2748 }; 2749})), pt = i(((e2, t2) => { 2750 var n2 = dt(), r2 = ft(); 2751 t2.exports = { formats: lt(), parse: r2, stringify: n2 }; 2752})), mt = r({ URL: () => $t, URLSearchParams: () => en, Url: () => Qt, default: () => pn, domainToASCII: () => cn, domainToUnicode: () => ln, fileURLToPath: () => dn, format: () => fn, parse: () => Xt, pathToFileURL: () => un, resolve: () => Zt, resolveObject: () => Gt }); 2753function ht() { 2754 this.protocol = null, this.slashes = null, this.auth = null, this.host = null, this.port = null, this.hostname = null, this.hash = null, this.search = null, this.query = null, this.pathname = null, this.path = null, this.href = null; 2755} 2756function gt(e2, t2, n2) { 2757 if (e2 && typeof e2 == `object` && e2 instanceof ht) return e2; 2758 var r2 = new ht(); 2759 return r2.parse(e2, t2, n2), r2; 2760} 2761function _t(e2) { 2762 return typeof e2 == `string` && (e2 = gt(e2)), e2 instanceof ht ? e2.format() : ht.prototype.format.call(e2); 2763} 2764function vt(e2, t2) { 2765 return gt(e2, false, true).resolve(t2); 2766} 2767function yt(e2, t2) { 2768 return e2 ? gt(e2, false, true).resolveObject(t2) : t2; 2769} 2770function bt(e2, t2) { 2771 for (var n2 = 0, r2 = e2.length - 1; r2 >= 0; r2--) { 2772 var i2 = e2[r2]; 2773 i2 === `.` ? e2.splice(r2, 1) : i2 === `..` ? (e2.splice(r2, 1), n2++) : n2 && (e2.splice(r2, 1), n2--); 2774 } 2775 if (t2) for (; n2--; ) e2.unshift(`..`); 2776 return e2; 2777}
2778function xt() { 2779 for (var e2 = ``, t2 = false, n2 = arguments.length - 1; n2 >= -1 && !t2; n2--) { 2780 var r2 = n2 >= 0 ? arguments[n2] : `/`; 2781 if (typeof r2 != `string`) throw TypeError(`Arguments to path.resolve must be strings`); 2782 r2 && (e2 = r2 + `/` + e2, t2 = r2.charAt(0) === `/`); 2783 } 2784 return e2 = bt(St(e2.split(`/`), function(e3) { 2785 return !!e3; 2786 }), !t2).join(`/`), (t2 ? `/` : ``) + e2 || `.`; 2787} 2788function St(e2, t2) { 2789 if (e2.filter) return e2.filter(t2); 2790 for (var n2 = [], r2 = 0; r2 < e2.length; r2++) t2(e2[r2], r2, e2) && n2.push(e2[r2]); 2791 return n2; 2792} 2793function Ct(e2) { 2794 var t2 = e2 ?? null; 2795 return !!(t2 !== null && t2?.href && t2?.origin); 2796} 2797function wt(e2) { 2798 if (e2.hostname !== ``) throw TypeError(`File URL host must be "localhost" or empty on browser`); 2799 for (var t2 = e2.pathname, n2 = 0; n2 < t2.length; n2++) if (t2[n2] === `%`) { 2800 var r2 = t2.codePointAt(n2 + 2) | 32; 2801 if (t2[n2 + 1] === `2` && r2 === 102) throw TypeError(`File URL path must not include encoded / characters`); 2802 } 2803 return decodeURIComponent(t2); 2804} 2805function Tt(e2) { 2806 return e2.includes(`%`) && (e2 = e2.replace(tn, `%25`)), e2.includes(`\\`) && (e2 = e2.replace(nn, `%5C`)), e2.includes(` 2807`) && (e2 = e2.replace(rn, `%0A`)), e2.includes(`\r`) && (e2 = e2.replace(an, `%0D`)), e2.includes(` `) && (e2 = e2.replace(on, `%09`)), e2; 2808} 2809var Et, Dt, Ot, kt, At, jt, Mt, Nt, Pt, Ft, It, Lt, Rt, zt, Bt, Vt, Ht, Ut, Wt, Gt, Kt, qt, Jt, Yt, Xt, Zt, Qt, $t, en, tn, nn, rn, an, on, sn, cn, ln, un, dn, fn, pn, mn = t((() => { 2810 Et = n(xe()), Dt = n(pt()), Ot = Et.default, kt = /^([a-z0-9.+-]+:)/i, At = /:[0-9]*$/, jt = /^(\/\/?(?!\/)[^?\s]*)(\?[^\s]*)?$/, Mt = [`{`, `}`, `|`, `\\`, `^`, "`", `<`, `>`, `"`, "`", ` `, `\r`, ` 2811`, ` `], Nt = [`'`].concat(Mt), Pt = [`%`, `/`, `?`, `;`, `#`].concat(Nt), Ft = [`/`, `?`, `#`], It = 255, Lt = /^[+a-z0-9A-Z_-]{0,63}$/, Rt = /^([+a-z0-9A-Z_-]{0,63})(.*)$/, zt = { javascript: true, "javascript:": true }, Bt = { javascript: true, "javascript:": true }, Vt = { http: true, https: true, ftp: true, gopher: true, file: true, "http:": true, "https:": true, "ftp:": true, "gopher:": true, "file:": true }, Ht = Dt.default, ht.prototype.parse = function(e2, t2, n2) { 2812 if (typeof e2 != `string`) throw TypeError(`Parameter 'url' must be a string, not ` + typeof e2); 2813 var r2 = e2.indexOf(`?`), i2 = r2 !== -1 && r2 < e2.indexOf(`#`) ? `?` : `#`, a2 = e2.split(i2); 2814 a2[0] = a2[0].replace(/\\/g, `/`), e2 = a2.join(i2); 2815 var o2 = e2; 2816 if (o2 = o2.trim(), !n2 && e2.split(`#`).length === 1) { 2817 var s2 = jt.exec(o2); 2818 if (s2) return this.path = o2, this.href = o2, this.pathname = s2[1], s2[2] ? (this.search = s2[2], t2 ? this.query = Ht.parse(this.search.substr(1)) : this.query = this.search.substr(1)) : t2 && (this.search = ``, this.query = {}), this; 2819 } 2820 var c2 = kt.exec(o2); 2821 if (c2) { 2822 c2 = c2[0]; 2823 var l2 = c2.toLowerCase(); 2824 this.protocol = l2, o2 = o2.substr(c2.length); 2825 } 2826 if (n2 || c2 || o2.match(/^\/\/[^@/]+@[^@/]+/)) { 2827 var u2 = o2.substr(0, 2) === `//`; 2828 u2 && !(c2 && Bt[c2]) && (o2 = o2.substr(2), this.slashes = true); 2829 } 2830 if (!Bt[c2] && (u2 || c2 && !Vt[c2])) { 2831 for (var d2 = -1, f2 = 0; f2 < Ft.length; f2++) { 2832 var p2 = o2.indexOf(Ft[f2]); 2833 p2 !== -1 && (d2 === -1 || p2 < d2) && (d2 = p2); 2834 } 2835 var m2, h2 = d2 === -1 ? o2.lastIndexOf(`@`) : o2.lastIndexOf(`@`, d2); 2836 h2 !== -1 && (m2 = o2.slice(0, h2), o2 = o2.slice(h2 + 1), this.auth = decodeURIComponent(m2)), d2 = -1; 2837 for (var f2 = 0; f2 < Pt.length; f2++) { 2838 var p2 = o2.indexOf(Pt[f2]); 2839 p2 !== -1 && (d2 === -1 || p2 < d2) && (d2 = p2); 2840 } 2841 d2 === -1 && (d2 = o2.length), this.host = o2.slice(0, d2), o2 = o2.slice(d2), this.parseHost(), this.hostname = this.hostname || ``; 2842 var g2 = this.hostname[0] === `[` && this.hostname[this.hostname.length - 1] === `]`; 2843 if (!g2) for (var _2 = this.hostname.split(/\./), f2 = 0, v2 = _2.length; f2 < v2; f2++) { 2844 var y2 = _2[f2]; 2845 if (y2 && !y2.match(Lt)) { 2846 for (var b2 = ``, x2 = 0, S2 = y2.length; x2 < S2; x2++) y2.charCodeAt(x2) > 127 ? b2 += `x` : b2 += y2[x2]; 2847 if (!b2.match(Lt)) { 2848 var C2 = _2.slice(0, f2), w2 = _2.slice(f2 + 1), T2 = y2.match(Rt); 2849 T2 && (C2.push(T2[1]), w2.unshift(T2[2])), w2.length && (o2 = `/` + w2.join(`.`) + o2), this.hostname = C2.join(`.`); 2850 break; 2851 } 2852 } 2853 } 2854 this.hostname.length > It ? this.hostname = `` : this.hostname = this.hostname.toLowerCase(), g2 || (this.hostname = Ot.toASCII(this.hostname)); 2855 var E2 = this.port ? `:` + this.port : ``, D2 = this.hostname || ``; 2856 this.host = D2 + E2, this.href += this.host, g2 && (this.hostname = this.hostname.substr(1, this.hostname.length - 2), o2[0] !== `/` && (o2 = `/` + o2)); 2857 } 2858 if (!zt[l2]) for (var f2 = 0, v2 = Nt.length; f2 < v2; f2++) { 2859 var O2 = Nt[f2]; 2860 if (o2.indexOf(O2) !== -1) { 2861 var k2 = encodeURIComponent(O2); 2862 k2 === O2 && (k2 = escape(O2)), o2 = o2.split(O2).join(k2); 2863 } 2864 } 2865 var A2 = o2.indexOf(`#`); 2866 A2 !== -1 && (this.hash = o2.substr(A2), o2 = o2.slice(0, A2)); 2867 var j2 = o2.indexOf(`?`); 2868 if (j2 === -1 ? t2 && (this.search = ``, this.query = {}) : (this.search = o2.substr(j2), this.query = o2.substr(j2 + 1), t2 && (this.query = Ht.parse(this.query)), o2 = o2.slice(0, j2)), o2 && (this.pathname = o2), Vt[l2] && this.hostname && !this.pathname && (this.pathname = `/`), this.pathname || this.search) { 2869 var E2 = this.pathname || ``, M2 = this.search || ``; 2870 this.path = E2 + M2; 2871 } 2872 return this.href = this.format(), this; 2873 }, ht.prototype.format = function() { 2874 var e2 = this.auth || ``; 2875 e2 && (e2 = encodeURIComponent(e2), e2 = e2.replace(/%3A/i, `:`), e2 += `@`); 2876 var t2 = this.protocol || ``, n2 = this.pathname || ``, r2 = this.hash || ``, i2 = false, a2 = ``; 2877 this.host ? i2 = e2 + this.host : this.hostname && (i2 = e2 + (this.hostname.indexOf(`:`) === -1 ? this.hostname : `[` + this.hostname + `]`), this.port && (i2 += `:` + this.port)), this.query && typeof this.query == `object` && Object.keys(this.query).length && (a2 = Ht.stringify(this.query, { arrayFormat: `repeat`, addQueryPrefix: false })); 2878 var o2 = this.search || a2 && `?` + a2 || ``; 2879 return t2 && t2.substr(-1) !== `:` && (t2 += `:`), this.slashes || (!t2 || Vt[t2]) && i2 !== false ? (i2 = `//` + (i2 || ``), n2 && n2.charAt(0) !== `/` && (n2 = `/` + n2)) : i2 || (i2 = ``), r2 && r2.charAt(0) !== `#` && (r2 = `#` + r2), o2 && o2.charAt(0) !== `?` && (o2 = `?` + o2), n2 = n2.replace(/[?#]/g, function(e3) { 2880 return encodeURIComponent(e3); 2881 }), o2 = o2.replace(`#`, `%23`), t2 + i2 + n2 + o2 + r2; 2882 }, ht.prototype.resolve = function(e2) { 2883 return this.resolveObject(gt(e2, false, true)).format(); 2884 }, ht.prototype.resolveObject = function(e2) { 2885 if (typeof e2 == `string`) { 2886 var t2 = new ht(); 2887 t2.parse(e2, false, true), e2 = t2; 2888 } 2889 for (var n2 = new ht(), r2 = Object.keys(this), i2 = 0; i2 < r2.length; i2++) { 2890 var a2 = r2[i2]; 2891 n2[a2] = this[a2]; 2892 } 2893 if (n2.hash = e2.hash, e2.href === ``) return n2.href = n2.format(), n2; 2894 if (e2.slashes && !e2.protocol) { 2895 for (var o2 = Object.keys(e2), s2 = 0; s2 < o2.length; s2++) { 2896 var c2 = o2[s2]; 2897 c2 !== `protocol` && (n2[c2] = e2[c2]); 2898 } 2899 return Vt[n2.protocol] && n2.hostname && !n2.pathname && (n2.pathname = `/`, n2.path = n2.pathname), n2.href = n2.format(), n2; 2900 } 2901 if (e2.protocol && e2.protocol !== n2.protocol) { 2902 if (!Vt[e2.protocol]) { 2903 for (var l2 = Object.keys(e2), u2 = 0; u2 < l2.length; u2++) { 2904 var d2 = l2[u2]; 2905 n2[d2] = e2[d2]; 2906 } 2907 return n2.href = n2.format(), n2; 2908 } 2909 if (n2.protocol = e2.protocol, !e2.host && !Bt[e2.protocol]) { 2910 for (var f2 = (e2.pathname || ``).split(`/`); f2.length && !(e2.host = f2.shift()); ) ; 2911 e2.host || (e2.host = ``), e2.hostname || (e2.hostname = ``), f2[0] !== `` && f2.unshift(``), f2.length < 2 && f2.unshift(``), n2.pathname = f2.join(`/`); 2912 } else n2.pathname = e2.pathname; 2913 return n2.search = e2.search, n2.query = e2.query, n2.host = e2.host || ``, n2.auth = e2.auth, n2.hostname = e2.hostname || e2.host, n2.port = e2.port, (n2.pathname || n2.search) && (n2.path = (n2.pathname || ``) + (n2.search || ``)), n2.slashes = n2.slashes || e2.slashes, n2.href = n2.format(), n2; 2914 } 2915 var p2 = n2.pathname && n2.pathname.charAt(0) === `/`, m2 = e2.host || e2.pathname && e2.pathname.charAt(0) === `/`, h2 = m2 || p2 || n2.host && e2.pathname, g2 = h2, _2 = n2.pathname && n2.pathname.split(`/`) || [], f2 = e2.pathname && e2.pathname.split(`/`) || [], v2 = n2.protocol && !Vt[n2.protocol]; 2916 if (v2 && (n2.hostname = ``, n2.port = null, n2.host && (_2[0] === `` ? _2[0] = n2.host : _2.unshift(n2.host)), n2.host = ``, e2.protocol && (e2.hostname = null, e2.port = null, e2.host && (f2[0] === `` ? f2[0] = e2.host : f2.unshift(e2.host)), e2.host = null), h2 && (h2 = f2[0] === `` || _2[0] === ``)), m2) n2.host = e2.host || e2.host === `` ? e2.host : n2.host, n2.hostname = e2.hostname || e2.hostname === `` ? e2.hostname : n2.hostname, n2.search = e2.search, n2.query = e2.query, _2 = f2; 2917 else if (f2.length) _2 || (_2 = []), _2.pop(), _2 = _2.concat(f2), n2.search = e2.search, n2.query = e2.query; 2918 else if (e2.search != null) { 2919 if (v2) { 2920 n2.host = _2.shift(), n2.hostname = n2.host; 2921 var y2 = n2.host && n2.host.indexOf(`@`) > 0 ? n2.host.split(`@`) : false;
2922 y2 && (n2.auth = y2.shift(), n2.hostname = y2.shift(), n2.host = n2.hostname); 2923 } 2924 return n2.search = e2.search, n2.query = e2.query, (n2.pathname !== null || n2.search !== null) && (n2.path = (n2.pathname ? n2.pathname : ``) + (n2.search ? n2.search : ``)), n2.href = n2.format(), n2; 2925 } 2926 if (!_2.length) return n2.pathname = null, n2.search ? n2.path = `/` + n2.search : n2.path = null, n2.href = n2.format(), n2; 2927 for (var b2 = _2.slice(-1)[0], x2 = (n2.host || e2.host || _2.length > 1) && (b2 === `.` || b2 === `..`) || b2 === ``, S2 = 0, C2 = _2.length; C2 >= 0; C2--) b2 = _2[C2], b2 === `.` ? _2.splice(C2, 1) : b2 === `..` ? (_2.splice(C2, 1), S2++) : S2 && (_2.splice(C2, 1), S2--); 2928 if (!h2 && !g2) for (; S2--; ) _2.unshift(`..`); 2929 h2 && _2[0] !== `` && (!_2[0] || _2[0].charAt(0) !== `/`) && _2.unshift(``), x2 && _2.join(`/`).substr(-1) !== `/` && _2.push(``); 2930 var w2 = _2[0] === `` || _2[0] && _2[0].charAt(0) === `/`; 2931 if (v2) { 2932 n2.hostname = w2 ? `` : _2.length ? _2.shift() : ``, n2.host = n2.hostname; 2933 var y2 = n2.host && n2.host.indexOf(`@`) > 0 ? n2.host.split(`@`) : false; 2934 y2 && (n2.auth = y2.shift(), n2.hostname = y2.shift(), n2.host = n2.hostname); 2935 } 2936 return h2 || (h2 = n2.host && _2.length), h2 && !w2 && _2.unshift(``), _2.length > 0 ? n2.pathname = _2.join(`/`) : (n2.pathname = null, n2.path = null), (n2.pathname !== null || n2.search !== null) && (n2.path = (n2.pathname ? n2.pathname : ``) + (n2.search ? n2.search : ``)), n2.auth = e2.auth || n2.auth, n2.slashes = n2.slashes || e2.slashes, n2.href = n2.format(), n2; 2937 }, ht.prototype.parseHost = function() { 2938 var e2 = this.host, t2 = At.exec(e2); 2939 t2 && (t2 = t2[0], t2 !== `:` && (this.port = t2.substr(1)), e2 = e2.substr(0, e2.length - t2.length)), e2 && (this.hostname = e2); 2940 }, Ut = gt, Wt = vt, Gt = yt, Kt = _t, qt = ht, Jt = (function(e2) { 2941 function t2() { 2942 var t3 = this || self; 2943 return delete e2.prototype.__magic__, t3; 2944 } 2945 return typeof globalThis == `object` ? globalThis : this ? t2() : (e2.defineProperty(e2.prototype, `__magic__`, { configurable: true, get: t2 }), __magic__); 2946 })(Object), Yt = Kt, Xt = Ut, Zt = Wt, Qt = qt, $t = Jt.URL, en = Jt.URLSearchParams, tn = /%/g, nn = /\\/g, rn = /\n/g, an = /\r/g, on = /\t/g, sn = 47, cn = function(e2) { 2947 if (e2 === void 0) throw TypeError(`The "domain" argument must be specified`); 2948 return new $t(`http://` + e2).hostname; 2949 }, ln = function(e2) { 2950 if (e2 === void 0) throw TypeError(`The "domain" argument must be specified`); 2951 return new $t(`http://` + e2).hostname; 2952 }, un = function(e2) { 2953 var t2 = new $t(`file://`), n2 = xt(e2); 2954 return e2.charCodeAt(e2.length - 1) === sn && n2[n2.length - 1] !== `/` && (n2 += `/`), t2.pathname = Tt(n2), t2; 2955 }, dn = function(e2) { 2956 if (!Ct(e2) && typeof e2 != `string`) throw TypeError(`The "path" argument must be of type string or an instance of URL. Received type ` + typeof e2 + ` (` + e2 + `)`); 2957 var t2 = new $t(e2); 2958 if (t2.protocol !== `file:`) throw TypeError(`The URL must be of scheme file`); 2959 return wt(t2); 2960 }, fn = function(e2, t2) { 2961 if (t2 === void 0 && (t2 = {}), !(e2 instanceof $t)) return Yt(e2); 2962 if (typeof t2 != `object` || !t2) throw TypeError(`The "options" argument must be of type object.`); 2963 var n2 = t2.auth ?? true, r2 = t2.fragment ?? true, i2 = t2.search ?? true; 2964 t2.unicode; 2965 var a2 = new $t(e2.toString()); 2966 return n2 || (a2.username = ``, a2.password = ``), r2 || (a2.hash = ``), i2 || (a2.search = ``), a2.toString(); 2967 }, pn = { format: fn, parse: Xt, resolve: Zt, resolveObject: Gt, Url: Qt, URL: $t, URLSearchParams: en, domainToASCII: cn, domainToUnicode: ln, pathToFileURL: un, fileURLToPath: dn }; 2968})), hn = i(((t2) => { 2969 Object.defineProperty(t2, `__esModule`, { value: true }), t2.filenameToSteps = t2.resolve = t2.unixify = t2.isWin = void 0, t2.isFd = m2, t2.validateFd = h2, t2.dataToBuffer = g2, t2.nullCheck = _2, t2.pathToFilename = y2, t2.createError = F2, t2.createStatError = I2; 2970 var n2 = Y(), r2 = Z(), i2 = he(), a2 = le(), o2 = be(), s2 = $(); 2971 t2.isWin = a2.default.platform === `win32`; 2972 var c2 = n2.resolve, l2 = n2.posix ? n2.posix.sep : n2.sep, u2 = (e2, n3) => { 2973 let r3 = e2[n3]; 2974 return n3 > 0 && (r3 === `/` || t2.isWin && r3 === `\\`); 2975 }, d2 = (e2) => { 2976 let t3 = e2.length - 1; 2977 if (t3 < 2) return e2; 2978 for (; u2(e2, t3); ) t3--; 2979 return e2.substr(0, t3 + 1); 2980 }, f2 = (e2, t3) => { 2981 if (typeof e2 != `string`) throw TypeError(`expected a string`); 2982 return e2 = e2.replace(/[\\\/]+/g, `/`), t3 !== false && (e2 = d2(e2)), e2; 2983 }; 2984 t2.unixify = (e2, n3 = true) => t2.isWin ? (e2 = f2(e2, n3), e2.replace(/^([a-zA-Z]+:|\.\/)/, ``)) : e2; 2985 var p2 = (e2, t3 = a2.default.cwd()) => c2(t3, e2); 2986 if (t2.resolve = p2, t2.isWin) { 2987 let e2 = p2; 2988 t2.resolve = p2 = (n3, r3) => (0, t2.unixify)(e2(n3, r3)); 2989 } 2990 t2.filenameToSteps = (e2, t3) => { 2991 let n3 = p2(e2, t3).substring(1); 2992 return n3 ? n3.split(l2) : []; 2993 }; 2994 function m2(e2) { 2995 return e2 >>> 0 === e2; 2996 } 2997 function h2(e2) { 2998 if (!m2(e2)) throw TypeError(s2.ERRSTR.FD); 2999 } 3000 function g2(e2, t3 = o2.ENCODING_UTF8) { 3001 return r2.Buffer.isBuffer(e2) ? e2 : e2 instanceof Uint8Array ? (0, r2.bufferFrom)(e2) : t3 === `buffer` ? (0, r2.bufferFrom)(String(e2), `utf8`) : (0, r2.bufferFrom)(String(e2), t3); 3002 } 3003 function _2(e2, t3) { 3004 if ((`` + e2).indexOf(`\0`) !== -1) { 3005 let e3 = Error(`Path must be a string without null bytes`); 3006 if (e3.code = `ENOENT`, typeof t3 != `function`) throw e3; 3007 return Promise.resolve().then(() => t3(e3)), false; 3008 } 3009 return true; 3010 } 3011 function v2(e2) { 3012 if (e2.hostname !== ``) throw new i2.TypeError(`ERR_INVALID_FILE_URL_HOST`, a2.default.platform); 3013 let t3 = e2.pathname; 3014 for (let e3 = 0; e3 < t3.length; e3++) if (t3[e3] === `%`) { 3015 let n3 = t3.codePointAt(e3 + 2) | 32; 3016 if (t3[e3 + 1] === `2` && n3 === 102) throw new i2.TypeError(`ERR_INVALID_FILE_URL_PATH`, `must not include encoded / characters`); 3017 } 3018 return decodeURIComponent(t3); 3019 } 3020 function y2(t3) { 3021 if (t3 instanceof Uint8Array && (t3 = (0, r2.bufferFrom)(t3)), typeof t3 != `string` && !r2.Buffer.isBuffer(t3)) {
3022 try { 3023 if (!(t3 instanceof (mn(), e(mt)).URL)) throw TypeError(s2.ERRSTR.PATH_STR); 3024 } catch { 3025 throw TypeError(s2.ERRSTR.PATH_STR); 3026 } 3027 t3 = v2(t3); 3028 } 3029 let n3 = String(t3); 3030 return _2(n3), n3; 3031 } 3032 var b2 = `ENOENT`, x2 = `EBADF`, S2 = `EINVAL`, C2 = `EPERM`, w2 = `EPROTO`, T2 = `EEXIST`, E2 = `ENOTDIR`, D2 = `EMFILE`, O2 = `EACCES`, k2 = `EISDIR`, A2 = `ENOTEMPTY`, j2 = `ENOSYS`, M2 = `ERR_FS_EISDIR`, N2 = `ERR_OUT_OF_RANGE`; 3033 function P2(e2, t3 = ``, n3 = ``, r3 = ``) { 3034 let i3 = ``; 3035 switch (n3 && (i3 = ` '${n3}'`), r3 && (i3 += ` -> '${r3}'`), e2) { 3036 case b2: 3037 return `ENOENT: no such file or directory, ${t3}${i3}`; 3038 case x2: 3039 return `EBADF: bad file descriptor, ${t3}${i3}`; 3040 case S2: 3041 return `EINVAL: invalid argument, ${t3}${i3}`; 3042 case C2: 3043 return `EPERM: operation not permitted, ${t3}${i3}`; 3044 case w2: 3045 return `EPROTO: protocol error, ${t3}${i3}`; 3046 case T2: 3047 return `EEXIST: file already exists, ${t3}${i3}`; 3048 case E2: 3049 return `ENOTDIR: not a directory, ${t3}${i3}`; 3050 case k2: 3051 return `EISDIR: illegal operation on a directory, ${t3}${i3}`; 3052 case O2: 3053 return `EACCES: permission denied, ${t3}${i3}`; 3054 case A2: 3055 return `ENOTEMPTY: directory not empty, ${t3}${i3}`; 3056 case D2: 3057 return `EMFILE: too many open files, ${t3}${i3}`; 3058 case j2: 3059 return `ENOSYS: function not implemented, ${t3}${i3}`; 3060 case M2: 3061 return `[ERR_FS_EISDIR]: Path is a directory: ${t3} returned EISDIR (is a directory) ${n3}`; 3062 case N2: 3063 return `[ERR_OUT_OF_RANGE]: value out of range, ${t3}${i3}`; 3064 default: 3065 return `${e2}: error occurred, ${t3}${i3}`; 3066 } 3067 } 3068 function F2(e2, t3 = ``, n3 = ``, r3 = ``, i3 = Error) { 3069 let a3 = new i3(P2(e2, t3, n3, r3)); 3070 return a3.code = e2, n3 && (a3.path = n3), a3; 3071 } 3072 function I2(e2, t3 = ``, n3 = ``, r3 = ``) { 3073 return { code: e2, message: P2(e2, t3, n3, r3), path: n3, toError() { 3074 let e3 = Error(this.message); 3075 return e3.code = this.code, this.path && (e3.path = this.path), e3; 3076 } }; 3077 } 3078})), gn = i(((e2) => { 3079 Object.defineProperty(e2, `__esModule`, { value: true }), e2.Superblock = void 0; 3080 var t2 = Y(), n2 = _e(), r2 = ve(), i2 = ye(), a2 = Z(), o2 = le(), s2 = $(), c2 = $(), l2 = hn(), u2 = ie(), d2 = oe(), f2 = t2.posix ? t2.posix.sep : t2.sep, p2 = t2.posix ? t2.posix.relative : t2.relative, m2 = t2.posix ? t2.posix.join : t2.join, { O_RDONLY: h2, O_WRONLY: g2, O_RDWR: _2, O_CREAT: v2, O_EXCL: y2, O_TRUNC: b2, O_APPEND: x2, O_DIRECTORY: S2 } = s2.constants, C2 = class e3 { 3081 static fromJSON(t3, n3, r3) { 3082 let i3 = new e3(r3); 3083 return i3.fromJSON(t3, n3), i3; 3084 } 3085 static fromNestedJSON(t3, n3, r3) { 3086 let i3 = new e3(r3); 3087 return i3.fromNestedJSON(t3, n3), i3; 3088 } 3089 constructor(e4 = {}) { 3090 this.ino = 0, this.inodes = {}, this.releasedInos = [], this.fds = {}, this.releasedFds = [], this.maxFiles = 1e4, this.openFiles = 0, this.open = (e5, t3, n4, r3 = true) => { 3091 let i3 = this.openFile(e5, t3, n4, r3); 3092 if (!i3) throw (0, l2.createError)(`ENOENT`, `open`, e5); 3093 return i3.fd; 3094 }, this.writeFile = (e5, t3, n4, r3) => { 3095 let i3 = typeof e5 == `number`, a3; 3096 a3 = i3 ? e5 : this.open((0, l2.pathToFilename)(e5), n4, r3); 3097 let o3 = 0, s3 = t3.length, c3 = n4 & x2 ? void 0 : 0; 3098 try { 3099 for (; s3 > 0; ) { 3100 let e6 = this.write(a3, t3, o3, s3, c3); 3101 o3 += e6, s3 -= e6, c3 !== void 0 && (c3 += e6); 3102 } 3103 } finally { 3104 i3 || this.close(a3); 3105 } 3106 }, this.read = (e5, t3, n4, r3, i3) => { 3107 if (t3.byteLength < r3) throw (0, l2.createError)(`ERR_OUT_OF_RANGE`, `read`, void 0, void 0, RangeError); 3108 let a3 = this.getFileByFdOrThrow(e5); 3109 if (a3.node.isSymlink()) throw (0, l2.createError)(`EPERM`, `read`, a3.link.getPath()); 3110 return a3.read(t3, Number(n4), Number(r3), i3 === -1 || typeof i3 != `number` ? void 0 : i3); 3111 }, this.readv = (e5, t3, n4) => { 3112 let r3 = this.getFileByFdOrThrow(e5), i3 = n4 ?? void 0; 3113 i3 === -1 && (i3 = void 0); 3114 let a3 = 0; 3115 for (let e6 of t3) { 3116 let t4 = r3.read(e6, 0, e6.byteLength, i3); 3117 if (i3 = void 0, a3 += t4, t4 < e6.byteLength) break; 3118 } 3119 return a3; 3120 }, this.link = (e5, n4) => { 3121 let r3; 3122 try { 3123 r3 = this.getLinkOrThrow(e5, `link`); 3124 } catch (t3) { 3125 throw t3.code && (t3 = (0, l2.createError)(t3.code, `link`, e5, n4)), t3; 3126 } 3127 let i3 = (0, t2.dirname)(n4), a3; 3128 try { 3129 a3 = this.getLinkOrThrow(i3, `link`); 3130 } catch (t3) { 3131 throw t3.code && (t3 = (0, l2.createError)(t3.code, `link`, e5, n4)), t3; 3132 } 3133 let o3 = (0, t2.basename)(n4); 3134 if (a3.getChild(o3)) throw (0, l2.createError)(`EEXIST`, `link`, e5, n4); 3135 let s3 = r3.getNode(); 3136 s3.nlink++, a3.createChild(o3, s3); 3137 }, this.unlink = (e5) => { 3138 let t3 = this.getLinkOrThrow(e5, `unlink`); 3139 if (t3.length) throw Error(`Dir not empty...`); 3140 this.deleteLink(t3); 3141 let n4 = t3.getNode(); 3142 n4.nlink--, n4.nlink <= 0 && this.deleteNode(n4); 3143 }, this.symlink = (e5, t3) => { 3144 let n4 = (0, l2.filenameToSteps)(t3), r3; 3145 try { 3146 r3 = this.getLinkParentAsDirOrThrow(n4); 3147 } catch (n5) { 3148 throw n5.code && (n5 = (0, l2.createError)(n5.code, `symlink`, e5, t3)), n5; 3149 } 3150 let i3 = n4[n4.length - 1]; 3151 if (r3.getChild(i3)) throw (0, l2.createError)(`EEXIST`, `symlink`, e5, t3); 3152 let a3 = r3.getNode(); 3153 if (!a3.canExecute() || !a3.canWrite()) throw (0, l2.createError)(`EACCES`, `symlink`, e5, t3); 3154 let o3 = r3.createChild(i3); 3155 return o3.getNode().makeSymlink(e5), o3; 3156 }, this.rename = (e5, n4) => { 3157 let r3; 3158 try { 3159 r3 = this.getResolvedLinkOrThrow(e5); 3160 } catch (t3) { 3161 throw t3.code && (t3 = (0, l2.createError)(t3.code, `rename`, e5, n4)), t3; 3162 } 3163 let i3; 3164 try { 3165 i3 = this.getLinkParentAsDirOrThrow(n4); 3166 } catch (t3) { 3167 throw t3.code && (t3 = (0, l2.createError)(t3.code, `rename`, e5, n4)), t3; 3168 } 3169 let a3 = r3.parent; 3170 if (!a3) throw (0, l2.createError)(`EINVAL`, `rename`, e5, n4); 3171 let o3 = a3.getNode(), s3 = i3.getNode(); 3172 if (!o3.canExecute() || !o3.canWrite() || !s3.canExecute() || !s3.canWrite()) throw (0, l2.createError)(`EACCES`, `rename`, e5, n4); 3173 a3.deleteChild(r3); 3174 let c3 = (0, t2.basename)(n4); 3175 r3.name = c3, r3.steps = [...i3.steps, c3], i3.setChild(r3.getName(), r3); 3176 }, this.mkdir = (e5, t3) => { 3177 let n4 = (0, l2.filenameToSteps)(e5); 3178 if (!n4.length) throw (0, l2.createError)(`EEXIST`, `mkdir`, e5); 3179 let r3 = this.getLinkParentAsDirOrThrow(e5, `mkdir`), i3 = n4[n4.length - 1]; 3180 if (r3.getChild(i3)) throw (0, l2.createError)(`EEXIST`, `mkdir`, e5); 3181 let a3 = r3.getNode(); 3182 if (!a3.canWrite() || !a3.canExecute()) throw (0, l2.createError)(`EACCES`, `mkdir`, e5); 3183 r3.createChild(i3, this.createNode(s2.constants.S_IFDIR | t3)); 3184 }, this.mkdirp = (e5, n4) => { 3185 let r3 = false, i3 = (0, l2.filenameToSteps)(e5), a3 = null, o3 = i3.length; 3186 for (o3 = i3.length; o3 >= 0 && (a3 = this.getResolvedLink(i3.slice(0, o3)), !a3); o3--) ; 3187 for (a3 || (a3 = this.root, o3 = 0), a3 = this.getResolvedLinkOrThrow(t2.sep + i3.slice(0, o3).join(t2.sep), `mkdir`); o3 < i3.length; o3++) { 3188 let t3 = a3.getNode(); 3189 if (t3.isDirectory()) { 3190 if (!t3.canExecute() || !t3.canWrite()) throw (0, l2.createError)(`EACCES`, `mkdir`, e5); 3191 } else throw (0, l2.createError)(`ENOTDIR`, `mkdir`, e5); 3192 r3 = true, a3 = a3.createChild(i3[o3], this.createNode(s2.constants.S_IFDIR | n4)); 3193 } 3194 return r3 ? e5 : void 0; 3195 }, this.rmdir = (e5, t3 = false) => { 3196 let n4 = this.getLinkAsDirOrThrow(e5, `rmdir`); 3197 if (n4.length && !t3) throw (0, l2.createError)(`ENOTEMPTY`, `rmdir`, e5); 3198 this.deleteLink(n4); 3199 }, this.rm = (e5, t3 = false, n4 = false) => { 3200 let r3; 3201 try { 3202 r3 = this.getResolvedLinkOrThrow(e5, `stat`); 3203 } catch (e6) { 3204 if (e6.code === `ENOENT` && t3) return; 3205 throw e6; 3206 } 3207 if (r3.getNode().isDirectory() && !n4) throw (0, l2.createError)(`ERR_FS_EISDIR`, `rm`, e5); 3208 if (!r3.parent?.getNode().canWrite()) throw (0, l2.createError)(`EACCES`, `rm`, e5); 3209 this.deleteLink(r3); 3210 }, this.close = (e5) => { 3211 (0, l2.validateFd)(e5); 3212 let t3 = this.getFileByFdOrThrow(e5, `close`); 3213 this.closeFile(t3); 3214 }, this.process = e4.process ?? o2.default; 3215 let n3 = this.createLink();
3216 n3.setNode(this.createNode(s2.constants.S_IFDIR | 511)), n3.setChild(`.`, n3), n3.getNode().nlink++, n3.setChild(`..`, n3), n3.getNode().nlink++, this.root = n3; 3217 } 3218 createLink(e4, t3, n3 = false, i3) { 3219 if (!e4) return new r2.Link(this, void 0, ``); 3220 if (!t3) throw Error(`createLink: name cannot be empty`); 3221 let a3 = i3 ?? (n3 ? 511 : 438), o3 = i3 && i3 & s2.constants.S_IFMT ? i3 & s2.constants.S_IFMT : n3 ? s2.constants.S_IFDIR : s2.constants.S_IFREG, c3 = a3 & ~s2.constants.S_IFMT | o3; 3222 return e4.createChild(t3, this.createNode(c3)); 3223 } 3224 deleteLink(e4) { 3225 let t3 = e4.parent; 3226 return t3 ? (t3.deleteChild(e4), true) : false; 3227 } 3228 newInoNumber() { 3229 return this.releasedInos.pop() || (this.ino = (this.ino + 1) % 4294967295, this.ino); 3230 } 3231 newFdNumber() { 3232 let t3 = this.releasedFds.pop(); 3233 return typeof t3 == `number` ? t3 : e3.fd--; 3234 } 3235 createNode(e4) { 3236 let t3 = this.process.getuid?.() ?? 0, r3 = this.process.getgid?.() ?? 0, i3 = new n2.Node(this.newInoNumber(), e4, t3, r3); 3237 return this.inodes[i3.ino] = i3, i3; 3238 } 3239 deleteNode(e4) { 3240 e4.del(), delete this.inodes[e4.ino], this.releasedInos.push(e4.ino); 3241 } 3242 walk(e4, n3 = false, i3 = false, a3 = false, o3) { 3243 let s3, c3; 3244 e4 instanceof r2.Link ? (s3 = e4.steps, c3 = f2 + s3.join(f2)) : typeof e4 == `string` ? (s3 = (0, l2.filenameToSteps)(e4), c3 = e4) : (s3 = e4, c3 = f2 + s3.join(f2)); 3245 let u3 = this.root, p3 = 0, h3 = this.process.getuid?.() ?? 0, g3 = this.process.getgid?.() ?? 0; 3246 for (; p3 < s3.length; ) { 3247 let e5 = u3.getNode(); 3248 if (e5.isDirectory()) { 3249 if (a3 && !e5.canExecute(h3, g3)) return (0, d2.Err)((0, l2.createStatError)(`EACCES`, o3, c3)); 3250 } else if (p3 < s3.length - 1) return (0, d2.Err)((0, l2.createStatError)(`ENOTDIR`, o3, c3)); 3251 if (u3 = u3.getChild(s3[p3]) ?? null, !u3) return i3 ? (0, d2.Err)((0, l2.createStatError)(`ENOENT`, o3, c3)) : (0, d2.Ok)(null); 3252 if (e5 = u3?.getNode(), e5.isSymlink() && (n3 || p3 < s3.length - 1)) { 3253 let n4 = (0, t2.isAbsolute)(e5.symlink) ? e5.symlink : m2((0, t2.dirname)(u3.getPath()), e5.symlink); 3254 s3 = (0, l2.filenameToSteps)(n4).concat(s3.slice(p3 + 1)), u3 = this.root, p3 = 0; 3255 continue; 3256 } 3257 if (i3 && !e5.isDirectory() && p3 < s3.length - 1) { 3258 let e6 = this.process.platform === `win32` ? `ENOENT` : `ENOTDIR`; 3259 return (0, d2.Err)((0, l2.createStatError)(e6, o3, c3)); 3260 } 3261 p3++; 3262 } 3263 return (0, d2.Ok)(u3); 3264 } 3265 getLink(e4) { 3266 let t3 = this.walk(e4, false, false, false); 3267 if (t3.ok) return t3.value; 3268 throw t3.err.toError(); 3269 } 3270 getLinkOrThrow(e4, t3) { 3271 let n3 = this.walk(e4, false, true, true, t3); 3272 if (n3.ok) return n3.value; 3273 throw n3.err.toError(); 3274 } 3275 getResolvedLink(e4) { 3276 let t3 = this.walk(e4, true, false, false); 3277 if (t3.ok) return t3.value; 3278 throw t3.err.toError(); 3279 } 3280 getResolvedLinkOrThrow(e4, t3) { 3281 let n3 = this.walk(e4, true, true, true, t3); 3282 if (n3.ok) return n3.value; 3283 throw n3.err.toError(); 3284 } 3285 getResolvedLinkResult(e4, t3) { 3286 let n3 = this.walk(e4, true, true, true, t3); 3287 return n3.ok ? (0, d2.Ok)(n3.value) : n3; 3288 } 3289 resolveSymlinks(e4) { 3290 return this.getResolvedLink(e4.steps.slice(1)); 3291 } 3292 getLinkAsDirOrThrow(e4, t3) { 3293 let n3 = this.getLinkOrThrow(e4, t3); 3294 if (!n3.getNode().isDirectory()) throw (0, l2.createError)(`ENOTDIR`, t3, e4); 3295 return n3; 3296 } 3297 getLinkParent(e4) { 3298 return this.getLink(e4.slice(0, -1)); 3299 } 3300 getLinkParentAsDirOrThrow(e4, t3) { 3301 let n3 = f2 + (e4 instanceof Array ? e4 : (0, l2.filenameToSteps)(e4)).slice(0, -1).join(f2), r3 = this.getLinkOrThrow(n3, t3); 3302 if (!r3.getNode().isDirectory()) throw (0, l2.createError)(`ENOTDIR`, t3, n3); 3303 return r3; 3304 } 3305 getFileByFd(e4) { 3306 return this.fds[String(e4)]; 3307 } 3308 getFileByFdOrThrow(e4, t3) {
3309 if (!(0, l2.isFd)(e4)) throw TypeError(c2.ERRSTR.FD); 3310 let n3 = this.getFileByFd(e4); 3311 if (!n3) throw (0, l2.createError)(`EBADF`, t3); 3312 return n3; 3313 } 3314 _toJSON(e4 = this.root, t3 = {}, n3, r3) { 3315 let i3 = true, a3 = e4.children; 3316 e4.getNode().isFile() && (a3 = /* @__PURE__ */ new Map([[e4.getName(), e4.parent.getChild(e4.getName())]]), e4 = e4.parent); 3317 for (let o4 of a3.keys()) { 3318 if (o4 === `.` || o4 === `..`) continue; 3319 i3 = false; 3320 let a4 = e4.getChild(o4); 3321 if (!a4) throw Error(`_toJSON: unexpected undefined`); 3322 let s3 = a4.getNode(); 3323 if (s3.isFile()) { 3324 let e5 = a4.getPath(); 3325 n3 && (e5 = p2(n3, e5)), t3[e5] = r3 ? s3.getBuffer() : s3.getString(); 3326 } else s3.isDirectory() && this._toJSON(a4, t3, n3, r3); 3327 } 3328 let o3 = e4.getPath(); 3329 return n3 && (o3 = p2(n3, o3)), o3 && i3 && (t3[o3] = null), t3; 3330 } 3331 toJSON(e4, t3 = {}, n3 = false, r3 = false) { 3332 let i3 = []; 3333 if (e4) { 3334 Array.isArray(e4) || (e4 = [e4]); 3335 for (let t4 of e4) { 3336 let e5 = (0, l2.pathToFilename)(t4), n4 = this.getResolvedLink(e5); 3337 n4 && i3.push(n4); 3338 } 3339 } else i3.push(this.root); 3340 if (!i3.length) return t3; 3341 for (let e5 of i3) this._toJSON(e5, t3, n3 ? e5.getPath() : ``, r3); 3342 return t3; 3343 } 3344 fromJSON(e4, n3 = this.process.cwd()) { 3345 for (let r3 in e4) { 3346 let i3 = e4[r3]; 3347 if (r3 = (0, l2.resolve)(r3, n3), typeof i3 == `string` || i3 instanceof a2.Buffer) { 3348 let e5 = (0, t2.dirname)(r3); 3349 this.mkdirp(e5, 511); 3350 let n4 = (0, l2.dataToBuffer)(i3); 3351 this.writeFile(r3, n4, c2.FLAGS.w, 438); 3352 } else this.mkdirp(r3, 511); 3353 } 3354 } 3355 fromNestedJSON(e4, t3) { 3356 this.fromJSON((0, u2.flattenJSON)(e4), t3); 3357 } 3358 reset() { 3359 this.ino = 0, this.inodes = {}, this.releasedInos = [], this.fds = {}, this.releasedFds = [], this.openFiles = 0, this.root = this.createLink(), this.root.setNode(this.createNode(s2.constants.S_IFDIR | 511)); 3360 } 3361 mountSync(e4, t3) { 3362 this.fromJSON(t3, e4); 3363 } 3364 openLink(e4, t3, n3 = true) { 3365 if (this.openFiles >= this.maxFiles) throw (0, l2.createError)(`EMFILE`, `open`, e4.getPath()); 3366 let r3 = e4; 3367 n3 && (r3 = this.getResolvedLinkOrThrow(e4.getPath(), `open`)); 3368 let a3 = r3.getNode(); 3369 if (a3.isDirectory()) { 3370 if ((t3 & (h2 | _2 | g2)) !== h2) throw (0, l2.createError)(`EISDIR`, `open`, e4.getPath()); 3371 } else if (t3 & S2) throw (0, l2.createError)(`ENOTDIR`, `open`, e4.getPath()); 3372 if ((t3 & (h2 | _2 | g2)) !== g2 && !a3.canRead() || t3 & (g2 | _2) && !a3.canWrite()) throw (0, l2.createError)(`EACCES`, `open`, e4.getPath()); 3373 let o3 = new i2.File(e4, a3, t3, this.newFdNumber()); 3374 return this.fds[o3.fd] = o3, this.openFiles++, t3 & b2 && o3.truncate(), o3; 3375 } 3376 openFile(e4, n3, r3, i3 = true) { 3377 let a3 = (0, l2.filenameToSteps)(e4), o3; 3378 try { 3379 if (o3 = i3 ? this.getResolvedLinkOrThrow(e4, `open`) : this.getLinkOrThrow(e4, `open`), o3 && n3 & v2 && n3 & y2) throw (0, l2.createError)(`EEXIST`, `open`, e4); 3380 } catch (i4) { 3381 if (i4.code === `ENOENT` && n3 & v2) { 3382 let n4 = (0, t2.dirname)(e4), i5 = this.getResolvedLinkOrThrow(n4), s3 = i5.getNode(); 3383 if (!s3.isDirectory()) throw (0, l2.createError)(`ENOTDIR`, `open`, e4); 3384 if (!s3.canExecute() || !s3.canWrite()) throw (0, l2.createError)(`EACCES`, `open`, e4); 3385 r3 ?? (r3 = 438), o3 = this.createLink(i5, a3[a3.length - 1], false, r3); 3386 } else throw i4; 3387 } 3388 if (o3) return this.openLink(o3, n3, i3); 3389 throw (0, l2.createError)(`ENOENT`, `open`, e4); 3390 } 3391 closeFile(e4) { 3392 this.fds[e4.fd] && (this.openFiles--, delete this.fds[e4.fd], this.releasedFds.push(e4.fd)); 3393 } 3394 write(e4, t3, n3, r3, i3) { 3395 let a3 = this.getFileByFdOrThrow(e4, `write`); 3396 if (a3.node.isSymlink()) throw (0, l2.createError)(`EBADF`, `write`, a3.link.getPath()); 3397 return a3.write(t3, n3, r3, i3 === -1 || typeof i3 != `number` ? void 0 : i3); 3398 } 3399 }; 3400 e2.Superblock = C2, C2.fd = 2147483647; 3401})), _n = i(((t2) => { 3402 Object.defineProperty(t2, `__esModule`, { value: true }), t2.resolve = t2.pathToFilename = t2.createStatError = t2.createError = t2.validateFd = t2.isFd = t2.filenameToSteps = t2.dataToBuffer = t2.Superblock = t2.File = t2.Link = t2.Node = void 0; 3403 var n2 = (J(), e(f)); 3404 n2.__exportStar(ne(), t2), n2.__exportStar(ie(), t2), n2.__exportStar(ae(), t2), n2.__exportStar(oe(), t2);
3405 var r2 = _e(); 3406 Object.defineProperty(t2, `Node`, { enumerable: true, get: function() { 3407 return r2.Node; 3408 } }); 3409 var i2 = ve(); 3410 Object.defineProperty(t2, `Link`, { enumerable: true, get: function() { 3411 return i2.Link; 3412 } }); 3413 var a2 = ye(); 3414 Object.defineProperty(t2, `File`, { enumerable: true, get: function() { 3415 return a2.File; 3416 } }); 3417 var o2 = gn(); 3418 Object.defineProperty(t2, `Superblock`, { enumerable: true, get: function() { 3419 return o2.Superblock; 3420 } }); 3421 var s2 = hn(); 3422 Object.defineProperty(t2, `dataToBuffer`, { enumerable: true, get: function() { 3423 return s2.dataToBuffer; 3424 } }), Object.defineProperty(t2, `filenameToSteps`, { enumerable: true, get: function() { 3425 return s2.filenameToSteps; 3426 } }), Object.defineProperty(t2, `isFd`, { enumerable: true, get: function() { 3427 return s2.isFd; 3428 } }), Object.defineProperty(t2, `validateFd`, { enumerable: true, get: function() { 3429 return s2.validateFd; 3430 } }), Object.defineProperty(t2, `createError`, { enumerable: true, get: function() { 3431 return s2.createError; 3432 } }), Object.defineProperty(t2, `createStatError`, { enumerable: true, get: function() { 3433 return s2.createStatError; 3434 } }), Object.defineProperty(t2, `pathToFilename`, { enumerable: true, get: function() { 3435 return s2.pathToFilename; 3436 } }), Object.defineProperty(t2, `resolve`, { enumerable: true, get: function() { 3437 return s2.resolve; 3438 } }); 3439})), vn = i(((e2) => { 3440 Object.defineProperty(e2, `__esModule`, { value: true }), e2.Stats = void 0; 3441 var { S_IFMT: t2, S_IFDIR: n2, S_IFREG: r2, S_IFBLK: i2, S_IFCHR: a2, S_IFLNK: o2, S_IFIFO: s2, S_IFSOCK: c2 } = $().constants, l2 = class e3 { 3442 static build(t3, n3 = false) { 3443 let r3 = new e3(), { uid: i3, gid: a3, atime: o3, mtime: s3, ctime: c3 } = t3, l3 = n3 ? (e4) => BigInt(e4) : (e4) => e4; 3444 r3.uid = l3(i3), r3.gid = l3(a3), r3.rdev = l3(t3.rdev), r3.blksize = l3(4096), r3.ino = l3(t3.ino), r3.size = l3(t3.getSize()), r3.blocks = l3(1), r3.atime = o3, r3.mtime = s3, r3.ctime = c3, r3.birthtime = c3, r3.atimeMs = l3(o3.getTime()), r3.mtimeMs = l3(s3.getTime()); 3445 let u2 = l3(c3.getTime()); 3446 if (r3.ctimeMs = u2, r3.birthtimeMs = u2, n3) { 3447 r3.atimeNs = BigInt(o3.getTime()) * BigInt(1e6), r3.mtimeNs = BigInt(s3.getTime()) * BigInt(1e6); 3448 let e4 = BigInt(c3.getTime()) * BigInt(1e6); 3449 r3.ctimeNs = e4, r3.birthtimeNs = e4; 3450 } 3451 return r3.dev = l3(0), r3.mode = l3(t3.mode), r3.nlink = l3(t3.nlink), r3; 3452 } 3453 _checkModeProperty(e4) { 3454 return (Number(this.mode) & t2) === e4; 3455 } 3456 isDirectory() { 3457 return this._checkModeProperty(n2); 3458 } 3459 isFile() { 3460 return this._checkModeProperty(r2); 3461 } 3462 isBlockDevice() { 3463 return this._checkModeProperty(i2); 3464 } 3465 isCharacterDevice() { 3466 return this._checkModeProperty(a2); 3467 } 3468 isSymbolicLink() { 3469 return this._checkModeProperty(o2); 3470 } 3471 isFIFO() { 3472 return this._checkModeProperty(s2); 3473 } 3474 isSocket() { 3475 return this._checkModeProperty(c2); 3476 } 3477 }; 3478 e2.Stats = l2, e2.default = l2; 3479})), yn = i(((e2) => { 3480 Object.defineProperty(e2, `__esModule`, { value: true }), e2.Dirent = void 0; 3481 var t2 = $(), { S_IFMT: n2, S_IFDIR: r2, S_IFREG: i2, S_IFBLK: a2, S_IFCHR: o2, S_IFLNK: s2, S_IFIFO: c2, S_IFSOCK: l2 } = t2.constants, u2 = class e3 { 3482 constructor() { 3483 this.name = ``, this.parentPath = ``, this.mode = 0, this.path = ``; 3484 } 3485 static build(n3, r3) { 3486 let i3 = new e3(), { mode: a3 } = n3.getNode(); 3487 return i3.name = (0, t2.strToEncoding)(n3.getName(), r3), i3.mode = a3, i3.parentPath = n3.getParentPath(), i3.path = i3.parentPath, i3; 3488 } 3489 _checkModeProperty(e4) { 3490 return (this.mode & n2) === e4; 3491 } 3492 isDirectory() { 3493 return this._checkModeProperty(r2); 3494 } 3495 isFile() { 3496 return this._checkModeProperty(i2); 3497 } 3498 isBlockDevice() { 3499 return this._checkModeProperty(a2); 3500 } 3501 isCharacterDevice() { 3502 return this._checkModeProperty(o2); 3503 } 3504 isSymbolicLink() { 3505 return this._checkModeProperty(s2); 3506 } 3507 isFIFO() { 3508 return this._checkModeProperty(c2); 3509 } 3510 isSocket() { 3511 return this._checkModeProperty(l2); 3512 } 3513 }; 3514 e2.Dirent = u2, e2.default = u2; 3515})), bn = i(((e2) => { 3516 Object.defineProperty(e2, `__esModule`, { value: true }), e2.StatFs = void 0; 3517 var t2 = class e3 { 3518 static build(t3, n2 = false) { 3519 let r2 = new e3(), i2 = n2 ? (e4) => BigInt(e4) : (e4) => e4; 3520 r2.type = i2(2240043254), r2.bsize = i2(4096); 3521 let a2 = Object.keys(t3.inodes).length, o2 = 1e6, s2 = o2 - Math.min(a2 * 2, o2); 3522 r2.blocks = i2(o2), r2.bfree = i2(s2), r2.bavail = i2(s2); 3523 let c2 = 1e6; 3524 return r2.files = i2(c2), r2.ffree = i2(c2 - a2), r2; 3525 } 3526 }; 3527 e2.StatFs = t2, e2.default = t2; 3528})), xn = i(((e2) => { 3529 a(), Object.defineProperty(e2, `__esModule`, { value: true }); 3530 function t2(e3, t3, n2) { 3531 let r2 = setTimeout.apply(typeof globalThis < `u` ? globalThis : o, arguments); 3532 return r2 && typeof r2 == `object` && typeof r2.unref == `function` && r2.unref(), r2; 3533 } 3534 e2.default = t2; 3535})), Sn = i(((e2, t2) => { 3536 var n2 = typeof Reflect == `object` ? Reflect : null, r2 = n2 && typeof n2.apply == `function` ? n2.apply : function(e3, t3, n3) { 3537 return Function.prototype.apply.call(e3, t3, n3); 3538 }, i2 = n2 && typeof n2.ownKeys == `function` ? n2.ownKeys : Object.getOwnPropertySymbols ? function(e3) { 3539 return Object.getOwnPropertyNames(e3).concat(Object.getOwnPropertySymbols(e3)); 3540 } : function(e3) { 3541 return Object.getOwnPropertyNames(e3); 3542 }; 3543 function a2(e3) { 3544 console && console.warn && console.warn(e3); 3545 } 3546 var o2 = Number.isNaN || function(e3) { 3547 return e3 !== e3; 3548 }; 3549 function s2() { 3550 s2.init.call(this); 3551 } 3552 t2.exports = s2, t2.exports.once = y2, s2.EventEmitter = s2, s2.prototype._events = void 0, s2.prototype._eventsCount = 0, s2.prototype._maxListeners = void 0; 3553 var c2 = 10; 3554 function l2(e3) { 3555 if (typeof e3 != `function`) throw TypeError(`The "listener" argument must be of type Function. Received type ` + typeof e3); 3556 } 3557 Object.defineProperty(s2, `defaultMaxListeners`, { enumerable: true, get: function() { 3558 return c2; 3559 }
vendor: 7,331 bytes, lines 3559-3702
3559, set: function(e3) { 3560 if (typeof e3 != `number` || e3 < 0 || o2(e3)) throw RangeError(`The value of "defaultMaxListeners" is out of range. It must be a non-negative number. Received ` + e3 + `.`); 3561 c2 = e3; 3562 } }), s2.init = function() { 3563 (this._events === void 0 || this._events === Object.getPrototypeOf(this)._events) && (this._events = /* @__PURE__ */ Object.create(null), this._eventsCount = 0), this._maxListeners = this._maxListeners || void 0; 3564 }, s2.prototype.setMaxListeners = function(e3) { 3565 if (typeof e3 != `number` || e3 < 0 || o2(e3)) throw RangeError(`The value of "n" is out of range. It must be a non-negative number. Received ` + e3 + `.`); 3566 return this._maxListeners = e3, this; 3567 }; 3568 function u2(e3) { 3569 return e3._maxListeners === void 0 ? s2.defaultMaxListeners : e3._maxListeners; 3570 } 3571 s2.prototype.getMaxListeners = function() { 3572 return u2(this); 3573 }, s2.prototype.emit = function(e3) { 3574 for (var t3 = [], n3 = 1; n3 < arguments.length; n3++) t3.push(arguments[n3]); 3575 var i3 = e3 === `error`, a3 = this._events; 3576 if (a3 !== void 0) i3 && (i3 = a3.error === void 0); 3577 else if (!i3) return false; 3578 if (i3) { 3579 var o3; 3580 if (t3.length > 0 && (o3 = t3[0]), o3 instanceof Error) throw o3; 3581 var s3 = Error(`Unhandled error.` + (o3 ? ` (` + o3.message + `)` : ``)); 3582 throw s3.context = o3, s3; 3583 } 3584 var c3 = a3[e3]; 3585 if (c3 === void 0) return false; 3586 if (typeof c3 == `function`) r2(c3, this, t3); 3587 else for (var l3 = c3.length, u3 = g2(c3, l3), n3 = 0; n3 < l3; ++n3) r2(u3[n3], this, t3); 3588 return true; 3589 }; 3590 function d2(e3, t3, n3, r3) { 3591 var i3, o3, s3; 3592 if (l2(n3), o3 = e3._events, o3 === void 0 ? (o3 = e3._events = /* @__PURE__ */ Object.create(null), e3._eventsCount = 0) : (o3.newListener !== void 0 && (e3.emit(`newListener`, t3, n3.listener ? n3.listener : n3), o3 = e3._events), s3 = o3[t3]), s3 === void 0) s3 = o3[t3] = n3, ++e3._eventsCount; 3593 else if (typeof s3 == `function` ? s3 = o3[t3] = r3 ? [n3, s3] : [s3, n3] : r3 ? s3.unshift(n3) : s3.push(n3), i3 = u2(e3), i3 > 0 && s3.length > i3 && !s3.warned) { 3594 s3.warned = true; 3595 var c3 = Error(`Possible EventEmitter memory leak detected. ` + s3.length + ` ` + String(t3) + ` listeners added. Use emitter.setMaxListeners() to increase limit`); 3596 c3.name = `MaxListenersExceededWarning`, c3.emitter = e3, c3.type = t3, c3.count = s3.length, a2(c3); 3597 } 3598 return e3; 3599 } 3600 s2.prototype.addListener = function(e3, t3) { 3601 return d2(this, e3, t3, false); 3602 }, s2.prototype.on = s2.prototype.addListener, s2.prototype.prependListener = function(e3, t3) { 3603 return d2(this, e3, t3, true); 3604 }; 3605 function f2() { 3606 if (!this.fired) return this.target.removeListener(this.type, this.wrapFn), this.fired = true, arguments.length === 0 ? this.listener.call(this.target) : this.listener.apply(this.target, arguments); 3607 } 3608 function p2(e3, t3, n3) { 3609 var r3 = { fired: false, wrapFn: void 0, target: e3, type: t3, listener: n3 }, i3 = f2.bind(r3); 3610 return i3.listener = n3, r3.wrapFn = i3, i3; 3611 } 3612 s2.prototype.once = function(e3, t3) { 3613 return l2(t3), this.on(e3, p2(this, e3, t3)), this; 3614 }, s2.prototype.prependOnceListener = function(e3, t3) { 3615 return l2(t3), this.prependListener(e3, p2(this, e3, t3)), this; 3616 }, s2.prototype.removeListener = function(e3, t3) { 3617 var n3, r3, i3, a3, o3; 3618 if (l2(t3), r3 = this._events, r3 === void 0 || (n3 = r3[e3], n3 === void 0)) return this; 3619 if (n3 === t3 || n3.listener === t3) --this._eventsCount === 0 ? this._events = /* @__PURE__ */ Object.create(null) : (delete r3[e3], r3.removeListener && this.emit(`removeListener`, e3, n3.listener || t3)); 3620 else if (typeof n3 != `function`) { 3621 for (i3 = -1, a3 = n3.length - 1; a3 >= 0; a3--) if (n3[a3] === t3 || n3[a3].listener === t3) { 3622 o3 = n3[a3].listener, i3 = a3; 3623 break; 3624 } 3625 if (i3 < 0) return this; 3626 i3 === 0 ? n3.shift() : _2(n3, i3), n3.length === 1 && (r3[e3] = n3[0]), r3.removeListener !== void 0 && this.emit(`removeListener`, e3, o3 || t3); 3627 } 3628 return this; 3629 }, s2.prototype.off = s2.prototype.removeListener, s2.prototype.removeAllListeners = function(e3) { 3630 var t3, n3 = this._events, r3; 3631 if (n3 === void 0) return this; 3632 if (n3.removeListener === void 0) return arguments.length === 0 ? (this._events = /* @__PURE__ */ Object.create(null), this._eventsCount = 0) : n3[e3] !== void 0 && (--this._eventsCount === 0 ? this._events = /* @__PURE__ */ Object.create(null) : delete n3[e3]), this; 3633 if (arguments.length === 0) { 3634 var i3 = Object.keys(n3), a3; 3635 for (r3 = 0; r3 < i3.length; ++r3) a3 = i3[r3], a3 !== `removeListener` && this.removeAllListeners(a3); 3636 return this.removeAllListeners(`removeListener`), this._events = /* @__PURE__ */ Object.create(null), this._eventsCount = 0, this; 3637 } 3638 if (t3 = n3[e3], typeof t3 == `function`) this.removeListener(e3, t3); 3639 else if (t3 !== void 0) for (r3 = t3.length - 1; r3 >= 0; r3--) this.removeListener(e3, t3[r3]); 3640 return this; 3641 }; 3642 function m2(e3, t3, n3) { 3643 var r3 = e3._events; 3644 if (r3 === void 0) return []; 3645 var i3 = r3[t3]; 3646 return i3 === void 0 ? [] : typeof i3 == `function` ? n3 ? [i3.listener || i3] : [i3] : n3 ? v2(i3) : g2(i3, i3.length); 3647 } 3648 s2.prototype.listeners = function(e3) { 3649 return m2(this, e3, true); 3650 }, s2.prototype.rawListeners = function(e3) { 3651 return m2(this, e3, false); 3652 }, s2.listenerCount = function(e3, t3) { 3653 return typeof e3.listenerCount == `function` ? e3.listenerCount(t3) : h2.call(e3, t3); 3654 }, s2.prototype.listenerCount = h2; 3655 function h2(e3) { 3656 var t3 = this._events; 3657 if (t3 !== void 0) { 3658 var n3 = t3[e3]; 3659 if (typeof n3 == `function`) return 1; 3660 if (n3 !== void 0) return n3.length; 3661 } 3662 return 0; 3663 } 3664 s2.prototype.eventNames = function() { 3665 return this._eventsCount > 0 ? i2(this._events) : []; 3666 }; 3667 function g2(e3, t3) { 3668 for (var n3 = Array(t3), r3 = 0; r3 < t3; ++r3) n3[r3] = e3[r3]; 3669 return n3; 3670 } 3671 function _2(e3, t3) { 3672 for (; t3 + 1 < e3.length; t3++) e3[t3] = e3[t3 + 1]; 3673 e3.pop(); 3674 } 3675 function v2(e3) { 3676 for (var t3 = Array(e3.length), n3 = 0; n3 < t3.length; ++n3) t3[n3] = e3[n3].listener || e3[n3]; 3677 return t3; 3678 } 3679 function y2(e3, t3) { 3680 return new Promise(function(n3, r3) { 3681 function i3(n4) { 3682 e3.removeListener(t3, a3), r3(n4); 3683 } 3684 function a3() { 3685 typeof e3.removeListener == `function` && e3.removeListener(`error`, i3), n3([].slice.call(arguments)); 3686 } 3687 x2(e3, t3, a3, { once: true }), t3 !== `error` && b2(e3, i3, { once: true }); 3688 }); 3689 } 3690 function b2(e3, t3, n3) { 3691 typeof e3.on == `function` && x2(e3, `error`, t3, n3); 3692 } 3693 function x2(e3, t3, n3, r3) { 3694 if (typeof e3.on == `function`) r3.once ? e3.once(t3, n3) : e3.on(t3, n3); 3695 else if (typeof e3.addEventListener == `function`) e3.addEventListener(t3, function i3(a3) { 3696 r3.once && e3.removeEventListener(t3, i3), n3(a3); 3697 }); 3698 else throw TypeError(`The "emitter" argument must be of type EventEmitter. Received type ` + typeof e3); 3699 } 3700})), Cn = i(((e2, t2) => { 3701 typeof Object.create == `function` ? t2.exports = function(e3, t3) { 3702 t3 && (e3.super_ = t3, e3.prototype = Object.create(t3.prototype, { c
3702onstructor: { value: e3, enumerable: false, writable: true, configurable: true } })); 3703 } : t2.exports = function(e3, t3) { 3704 if (t3) { 3705 e3.super_ = t3; 3706 var n2 = function() { 3707 }; 3708 n2.prototype = t3.prototype, e3.prototype = new n2(), e3.prototype.constructor = e3; 3709 } 3710 }; 3711})), wn = i(((e2, t2) => { 3712 t2.exports = Sn().EventEmitter; 3713})), Tn = i(((e2, t2) => { 3714 var n2 = We(); 3715 t2.exports = function() { 3716 return n2() && !!Symbol.toStringTag; 3717 }; 3718})), En = i(((e2, t2) => { 3719 var n2 = Tn()(), r2 = at()(`Object.prototype.toString`), i2 = function(e3) { 3720 return n2 && e3 && typeof e3 == `object` && Symbol.toStringTag in e3 ? false : r2(e3) === `[object Arguments]`; 3721 }, a2 = function(e3) { 3722 return i2(e3) ? true : typeof e3 == `object` && !!e3 && `length` in e3 && typeof e3.length == `number` && e3.length >= 0 && r2(e3) !== `[object Array]` && `callee` in e3 && r2(e3.callee) === `[object Function]`; 3723 }, o2 = (function() { 3724 return i2(arguments); 3725 })(); 3726 i2.isLegacyArguments = a2, t2.exports = o2 ? i2 : a2; 3727})), Dn = i(((e2, t2) => { 3728 var n2 = at(), r2 = Tn()(), i2 = rt(), a2 = He(), o2; 3729 if (r2) { 3730 var s2 = n2(`RegExp.prototype.exec`), c2 = {}, l2 = function() { 3731 throw c2; 3732 }, u2 = { toString: l2, valueOf: l2 }; 3733 typeof Symbol.toPrimitive == `symbol` && (u2[Symbol.toPrimitive] = l2), o2 = function(e3) { 3734 if (!e3 || typeof e3 != `object`) return false; 3735 var t3 = a2(e3, `lastIndex`); 3736 if (!(t3 && i2(t3, `value`))) return false; 3737 try { 3738 s2(e3, u2); 3739 } catch (e4) { 3740 return e4 === c2; 3741 } 3742 }; 3743 } else { 3744 var d2 = n2(`Object.prototype.toString`), f2 = `[object RegExp]`; 3745 o2 = function(e3) { 3746 return !e3 || typeof e3 != `object` && typeof e3 != `function` ? false : d2(e3) === f2; 3747 }; 3748 } 3749 t2.exports = o2; 3750})), On = i(((e2, t2) => { 3751 var n2 = at(), r2 = Dn(), i2 = n2(`RegExp.prototype.exec`), a2 = Se(); 3752 t2.exports = function(e3) { 3753 if (!r2(e3)) throw new a2("`regex` must be a RegExp"); 3754 return function(t3) { 3755 return i2(e3, t3) !== null; 3756 }; 3757 }; 3758})), kn = i(((e2, t2) => { 3759 var n2 = function* () { 3760 }.constructor; 3761 t2.exports = () => n2; 3762})), An = i(((e2, t2) => { 3763 var n2 = at(), r2 = On()(/^\s*(?:function)?\*/), i2 = Tn()(), a2 = nt(), o2 = n2(`Object.prototype.toString`), s2 = n2(`Function.prototype.toString`), c2 = kn(); 3764 t2.exports = function(e3) { 3765 if (typeof e3 != `function`) return false; 3766 if (r2(s2(e3))) return true; 3767 if (!i2) return o2(e3) === `[object GeneratorFunction]`; 3768 if (!a2) return false; 3769 var t3 = c2(); 3770 return t3 && a2(e3) === t3.prototype; 3771 }; 3772})), jn = i(((e2, t2) => { 3773 var n2 = Function.prototype.toString, r2 = typeof Reflect == `object` && Reflect !== null && Reflect.apply, i2, a2; 3774 if (typeof r2 == `function` && typeof Object.defineProperty == `function`) try { 3775 i2 = Object.defineProperty({}, `length`, { get: function() { 3776 throw a2; 3777 } }), a2 = {}, r2(function() { 3778 throw 42; 3779 }, null, i2); 3780 } catch (e3) { 3781 e3 !== a2 && (r2 = null); 3782 } 3783 else r2 = null; 3784 var o2 = /^\s*class\b/, s2 = function(e3) { 3785 try { 3786 var t3 = n2.call(e3); 3787 return o2.test(t3); 3788 } catch { 3789 return false; 3790 } 3791 }, c2 = function(e3) { 3792 try { 3793 return s2(e3) ? false : (n2.call(e3), true); 3794 } catch { 3795 return false; 3796 } 3797 }, l2 = Object.prototype.toString, u2 = `[object Object]`, d2 = `[object Function]`, f2 = `[object GeneratorFunction]`, p2 = `[object HTMLAllCollection]`, m2 = `[object HTML document.all class]`, h2 = `[object HTMLCollection]`, g2 = typeof Symbol == `function` && !!Symbol.toStringTag, _2 = !(0 in [,]), v2 = function() { 3798 return false; 3799 }; 3800 if (typeof document == `object`) { 3801 var y2 = document.all; 3802 l2.call(y2) === l2.call(document.all) && (v2 = function(e3) { 3803 if ((_2 || !e3) && (e3 === void 0 || typeof e3 == `object`)) try { 3804 var t3 = l2.call(e3); 3805 return (t3 === p2 || t3 === m2 || t3 === h2 || t3 === u2) && e3(``) == null; 3806 } catch { 3807 } 3808 return false; 3809 }); 3810 } 3811 t2.exports = r2 ? function(e3) { 3812 if (v2(e3)) return true; 3813 if (!e3 || typeof e3 != `function` && typeof e3 != `object`) return false;
3814 try { 3815 r2(e3, null, i2); 3816 } catch (e4) { 3817 if (e4 !== a2) return false; 3818 } 3819 return !s2(e3) && c2(e3); 3820 } : function(e3) { 3821 if (v2(e3)) return true; 3822 if (!e3 || typeof e3 != `function` && typeof e3 != `object`) return false; 3823 if (g2) return c2(e3); 3824 if (s2(e3)) return false; 3825 var t3 = l2.call(e3); 3826 return t3 !== d2 && t3 !== f2 && !/^\[object HTML/.test(t3) ? false : c2(e3); 3827 }; 3828})), Mn = i(((e2, t2) => { 3829 var n2 = jn(), r2 = Object.prototype.toString, i2 = Object.prototype.hasOwnProperty, a2 = function(e3, t3, n3) { 3830 for (var r3 = 0, a3 = e3.length; r3 < a3; r3++) i2.call(e3, r3) && (n3 == null ? t3(e3[r3], r3, e3) : t3.call(n3, e3[r3], r3, e3)); 3831 }, o2 = function(e3, t3, n3) { 3832 for (var r3 = 0, i3 = e3.length; r3 < i3; r3++) n3 == null ? t3(e3.charAt(r3), r3, e3) : t3.call(n3, e3.charAt(r3), r3, e3); 3833 }, s2 = function(e3, t3, n3) { 3834 for (var r3 in e3) i2.call(e3, r3) && (n3 == null ? t3(e3[r3], r3, e3) : t3.call(n3, e3[r3], r3, e3)); 3835 }; 3836 function c2(e3) { 3837 return r2.call(e3) === `[object Array]`; 3838 } 3839 t2.exports = function(e3, t3, r3) { 3840 if (!n2(t3)) throw TypeError(`iterator must be a function`); 3841 var i3; 3842 arguments.length >= 3 && (i3 = r3), c2(e3) ? a2(e3, t3, i3) : typeof e3 == `string` ? o2(e3, t3, i3) : s2(e3, t3, i3); 3843 }; 3844})), Nn = i(((e2, t2) => { 3845 t2.exports = [`Float16Array`, `Float32Array`, `Float64Array`, `Int8Array`, `Int16Array`, `Int32Array`, `Uint8Array`, `Uint8ClampedArray`, `Uint16Array`, `Uint32Array`, `BigInt64Array`, `BigUint64Array`]; 3846})), Pn = i(((e2, t2) => { 3847 a(); 3848 var n2 = Nn(), r2 = typeof globalThis > `u` ? o : globalThis; 3849 t2.exports = function() { 3850 for (var e3 = [], t3 = 0; t3 < n2.length; t3++) typeof r2[n2[t3]] == `function` && (e3[e3.length] = n2[t3]); 3851 return e3; 3852 }; 3853})), Fn = i(((e2, t2) => { 3854 var n2 = Ue(), r2 = je(), i2 = Se(), a2 = He(); 3855 t2.exports = function(e3, t3, o2) { 3856 if (!e3 || typeof e3 != `object` && typeof e3 != `function`) throw new i2("`obj` must be an object or a function`"); 3857 if (typeof t3 != `string` && typeof t3 != `symbol`) throw new i2("`property` must be a string or a symbol`"); 3858 if (arguments.length > 3 && typeof arguments[3] != `boolean` && arguments[3] !== null) throw new i2("`nonEnumerable`, if provided, must be a boolean or null"); 3859 if (arguments.length > 4 && typeof arguments[4] != `boolean` && arguments[4] !== null) throw new i2("`nonWritable`, if provided, must be a boolean or null"); 3860 if (arguments.length > 5 && typeof arguments[5] != `boolean` && arguments[5] !== null) throw new i2("`nonConfigurable`, if provided, must be a boolean or null"); 3861 if (arguments.length > 6 && typeof arguments[6] != `boolean`) throw new i2("`loose`, if provided, must be a boolean"); 3862 var s2 = arguments.length > 3 ? arguments[3] : null, c2 = arguments.length > 4 ? arguments[4] : null, l2 = arguments.length > 5 ? arguments[5] : null, u2 = arguments.length > 6 ? arguments[6] : false, d2 = !!a2 && a2(e3, t3); 3863 if (n2) n2(e3, t3, { configurable: l2 === null && d2 ? d2.configurable : !l2, enumerable: s2 === null && d2 ? d2.enumerable : !s2, value: o2, writable: c2 === null && d2 ? d2.writable : !c2 }); 3864 else if (u2 || !s2 && !c2 && !l2) e3[t3] = o2; 3865 else throw new r2(`This environment does not support defining a property as non-configurable, non-writable, or non-enumerable.`); 3866 }; 3867})), In = i(((e2, t2) => { 3868 var n2 = Ue(), r2 = function() { 3869 return !!n2; 3870 }; 3871 r2.hasArrayLengthDefineBug = function() { 3872 if (!n2) return null; 3873 try { 3874 return n2([], `length`, { value: 1 }).length !== 1; 3875 } catch { 3876 return true; 3877 } 3878 }, t2.exports = r2; 3879})), Ln = i(((e2, t2) => { 3880 var n2 = it(), r2 = Fn(), i2 = In()(), a2 = He(), o2 = Se(), s2 = n2(`%Math.floor%`); 3881 t2.exports = function(e3, t3) { 3882 if (typeof e3 != `function`) throw new o2("`fn` is not a function"); 3883 if (typeof t3 != `number` || t3 < 0 || t3 > 4294967295 || s2(t3) !== t3) throw new o2("`length` must be a positive 32-bit integer"); 3884 var n3 = arguments.length > 2 && !!arguments[2], c2 = true, l2 = true; 3885 if (`length` in e3 && a2) { 3886 var u2 = a2(e3, `length`); 3887 u2 && !u2.configurable && (c2 = false), u2 && !u2.writable && (l2 = false); 3888 } 3889 return (c2 || l2 || !n3) && (i2 ? r2(e3, `length`, t3, true, true) : r2(e3, `length`, t3)), e3; 3890 }; 3891})), Rn = i(((e2, t2) => { 3892 var n2 = Ye(), r2 = Ze(), i2 = $e(); 3893 t2.exports = function() { 3894 return i2(n2, r2, arguments); 3895 }; 3896})), zn = i(((e2, t2) => { 3897 var n2 = Ln(), r2 = Ue(), i2 = et(), a2 = Rn(); 3898 t2.exports = function(e3) { 3899 var t3 = i2(arguments), r3 = 1 + e3.length - (arguments.length - 1); 3900 return n2(t3, r3 > 0 ? r3 : 0, true); 3901 }
3901, r2 ? r2(t2.exports, `apply`, { value: a2 }) : t2.exports.apply = a2; 3902})), Bn = i(((e2, t2) => { 3903 a(); 3904 var n2 = Mn(), r2 = Pn(), i2 = zn(), s2 = at(), c2 = He(), l2 = nt(), u2 = s2(`Object.prototype.toString`), d2 = Tn()(), f2 = typeof globalThis > `u` ? o : globalThis, p2 = r2(), m2 = s2(`String.prototype.slice`), h2 = s2(`Array.prototype.indexOf`, true) || function(e3, t3) { 3905 for (var n3 = 0; n3 < e3.length; n3 += 1) if (e3[n3] === t3) return n3; 3906 return -1; 3907 }, g2 = { __proto__: null }; 3908 d2 && c2 && l2 ? n2(p2, function(e3) { 3909 var t3 = new f2[e3](); 3910 if (Symbol.toStringTag in t3 && l2) { 3911 var n3 = l2(t3), r3 = c2(n3, Symbol.toStringTag); 3912 if (!r3 && n3 && (r3 = c2(l2(n3), Symbol.toStringTag)), r3 && r3.get) { 3913 var a2 = i2(r3.get); 3914 g2[`$` + e3] = a2; 3915 } 3916 } 3917 }) : n2(p2, function(e3) { 3918 var t3 = new f2[e3](), n3 = t3.slice || t3.set; 3919 if (n3) { 3920 var r3 = i2(n3); 3921 g2[`$` + e3] = r3; 3922 } 3923 }); 3924 var _2 = function(e3) { 3925 var t3 = false; 3926 return n2(g2, function(n3, r3) { 3927 if (!t3) try { 3928 `$` + n3(e3) === r3 && (t3 = m2(r3, 1)); 3929 } catch { 3930 } 3931 }), t3; 3932 }, v2 = function(e3) { 3933 var t3 = false; 3934 return n2(g2, function(n3, r3) { 3935 if (!t3) try { 3936 n3(e3), t3 = m2(r3, 1); 3937 } catch { 3938 } 3939 }), t3; 3940 }; 3941 t2.exports = function(e3) { 3942 if (!e3 || typeof e3 != `object`) return false; 3943 if (!d2) { 3944 var t3 = m2(u2(e3), 8, -1); 3945 return h2(p2, t3) > -1 ? t3 : t3 === `Object` ? v2(e3) : false; 3946 } 3947 return c2 ? _2(e3) : null; 3948 }; 3949})), Vn = i(((e2, t2) => { 3950 var n2 = Bn(); 3951 t2.exports = function(e3) { 3952 return !!n2(e3); 3953 }; 3954})), Hn = i(((e2) => { 3955 var t2 = En(), n2 = An(), r2 = Bn(), i2 = Vn(); 3956 function a2(e3) { 3957 return e3.call.bind(e3); 3958 } 3959 var o2 = typeof BigInt < `u`, s2 = typeof Symbol < `u`, c2 = a2(Object.prototype.toString), l2 = a2(Number.prototype.valueOf), u2 = a2(String.prototype.valueOf), d2 = a2(Boolean.prototype.valueOf); 3960 if (o2) var f2 = a2(BigInt.prototype.valueOf); 3961 if (s2) var p2 = a2(Symbol.prototype.valueOf); 3962 function m2(e3, t3) { 3963 if (typeof e3 != `object`) return false; 3964 try { 3965 return t3(e3), true; 3966 } catch { 3967 return false; 3968 } 3969 } 3970 e2.isArgumentsObject = t2, e2.isGeneratorFunction = n2, e2.isTypedArray = i2; 3971 function h2(e3) { 3972 return typeof Promise < `u` && e3 instanceof Promise || typeof e3 == `object` && !!e3 && typeof e3.then == `function` && typeof e3.catch == `function`; 3973 } 3974 e2.isPromise = h2; 3975 function g2(e3) { 3976 return typeof ArrayBuffer < `u` && ArrayBuffer.isView ? ArrayBuffer.isView(e3) : i2(e3) || z2(e3); 3977 } 3978 e2.isArrayBufferView = g2; 3979 function _2(e3) { 3980 return r2(e3) === `Uint8Array`; 3981 } 3982 e2.isUint8Array = _2; 3983 function v2(e3) { 3984 return r2(e3) === `Uint8ClampedArray`; 3985 } 3986 e2.isUint8ClampedArray = v2; 3987 function y2(e3) { 3988 return r2(e3) === `Uint16Array`; 3989 } 3990 e2.isUint16Array = y2; 3991 function b2(e3) { 3992 return r2(e3) === `Uint32Array`; 3993 } 3994 e2.isUint32Array = b2; 3995 function x2(e3) { 3996 return r2(e3) === `Int8Array`; 3997 } 3998 e2.isInt8Array = x2; 3999 function S2(e3) { 4000 return r2(e3) === `Int16Array`; 4001 } 4002 e2.isInt16Array = S2; 4003 function C2(e3) { 4004 return r2(e3) === `Int32Array`; 4005 } 4006 e2.isInt32Array = C2; 4007 function w2(e3) { 4008 return r2(e3) === `Float32Array`; 4009 } 4010 e2.isFloat32Array = w2; 4011 function T2(e3) { 4012 return r2(e3) === `Float64Array`; 4013 } 4014 e2.isFloat64Array = T2; 4015 function E2(e3) { 4016 return r2(e3) === `BigInt64Array`; 4017 } 4018 e2.isBigInt64Array = E2; 4019 function D2(e3) { 4020 return r2(e3) === `BigUint64Array`; 4021 } 4022 e2.isBigUint64Array = D2; 4023 function O2(e3) { 4024 return c2(e3) === `[object Map]`; 4025 } 4026 O2.working = typeof Map < `u` && O2(/* @__PURE__ */ new Map()); 4027 function k2(e3) { 4028 return typeof Map > `u` ? false : O2.working ? O2(e3) : e3 instanceof Map; 4029 } 4030 e2.isMap = k2; 4031 function A2(e3) { 4032 return c2(e3) === `[object Set]`; 4033 } 4034 A2.working = typeof Set < `u` && A2(/* @__PURE__ */ new Set()); 4035 function j2(e3) { 4036 return typeof Set > `u` ? false : A2.working ? A2(e3) : e3 instanceof Set; 4037 } 4038 e2.isSet = j2; 4039 function M2(e3) { 4040 return c2(e3) === `[object WeakMap]`; 4041 } 4042 M2.working = typeof WeakMap < `u` && M2(/* @__PURE__ */ new WeakMap()); 4043 function N2(e3) { 4044 return typeof WeakMap > `u` ? false : M2.working ? M2(e3) : e3 instanceof WeakMap; 4045 } 4046 e2.isWeakMap = N2; 4047 function P2(e3) { 4048 return c2(e3) === `[object WeakSet]`; 4049 } 4050 P2.working = typeof WeakSet < `u` && P2(/* @__PURE__ */ new WeakSet()); 4051 function F2(e3) { 4052 return P2(e3); 4053 } 4054 e2.isWeakSet = F2; 4055 function I2(e3) { 4056 return c2(e3) === `[object ArrayBuffer]`; 4057 } 4058 I2.working = typeof ArrayBuffer < `u` && I2(new ArrayBuffer()); 4059 function L2(e3) { 4060 return typeof ArrayBuffer > `u` ? false : I2.working ? I2(e3) : e3 instanceof ArrayBuffer; 4061 } 4062 e2.isArrayBuffer = L2; 4063 function R2(e3) { 4064 return c2(e3) === `[object DataView]`; 4065 } 4066 R2.working = typeof ArrayBuffer < `u` && typeof DataView < `u` && R2(new DataView(new ArrayBuffer(1), 0, 1)); 4067 function z2(e3) { 4068 return typeof DataView > `u` ? false : R2.working ? R2(e3) : e3 instanceof DataView; 4069 } 4070 e2.isDataView = z2; 4071 var B2 = typeof SharedArrayBuffer < `u` ? SharedArrayBuffer : void 0; 4072 function V2(e3) { 4073 return c2(e3) === `[object SharedArrayBuffer]`; 4074 } 4075 function H2(e3) { 4076 return B2 === void 0 ? false : (V2.working === void 0 && (V2.working = V2(new B2())), V2.working ? V2(e3) : e3 instanceof B2); 4077 } 4078 e2.isSharedArrayBuffer = H2; 4079 function U2(e3) { 4080 return c2(e3) === `[object AsyncFunction]`; 4081 } 4082 e2.isAsyncFunction = U2; 4083 function W2(e3) { 4084 return c2(e3) === `[object Map Iterator]`; 4085 } 4086 e2.isMapIterator = W2; 4087 function G2(e3) { 4088 return c2(e3) === `[object Set Iterator]`; 4089 } 4090 e2.isSetIterator = G2; 4091 function ee2(e3) { 4092 return c2(e3) === `[object Generator]`; 4093 } 4094 e2.isGeneratorObject = ee2; 4095 function K2(e3) { 4096 return c2(e3) === `[object WebAssembly.Module]`; 4097 } 4098 e2.isWebAssemblyCompiledModule = K2; 4099 function te2(e3) { 4100 return m2(e3, l2); 4101 } 4102 e2.isNumberObject = te2; 4103 function q2(e3) { 4104 return m2(e3, u2); 4105 } 4106 e2.isStringObject = q2; 4107 function J2(e3) { 4108 return m2(e3, d2); 4109 } 4110 e2.isBooleanObject = J2; 4111 function Y2(e3) { 4112 return o2 && m2(e3, f2); 4113 } 4114 e2.isBigIntObject = Y2; 4115 function ne2(e3) { 4116 return s2 && m2(e3, p2); 4117 } 4118 e2.isSymbolObject = ne2; 4119 function re2(e3) { 4120 return te2(e3) || q2(e3) || J2(e3) || Y2(e3) || ne2(e3); 4121 } 4122 e2.isBoxedPrimitive = re2; 4123 function X2(e3) { 4124 return typeof Uint8Array < `u` && (L2(e3) || H2(e3)); 4125 } 4126 e2.isAnyArrayBuffer = X2, [`isProxy`, `isExternal`, `isModuleNamespaceObject`].forEach(function(t3) { 4127 Object.defineProperty(e2, t3, { enumerable: false, value: function() { 4128 throw Error(t3 + ` is not supported in userland`); 4129 } }); 4130 }); 4131})), Un = i(((e2, t2) => { 4132 t2.exports = function(e3) { 4133 return e3 && typeof e3 == `object` && typeof e3.copy == `function` && typeof e3.fill == `function` && typeof e3.readUInt8 == `function`; 4134 }; 4135})), Wn = i(((e2) => { 4136 u(); 4137 var t2 = Object.getOwnPropertyDescriptors || function(e3) { 4138 for (var t3 = Object.keys(e3), n3 = {}, r3 = 0; r3 < t3.length; r3++) n3[t3[r3]] = Object.getOwnPropertyDescriptor(e3, t3[r3]); 4139 return n3; 4140 }, n2 = /%[sdj%]/g; 4141 e2.format = function(e3) { 4142 if (!C2(e3)) { 4143 for (var t3 = [], r3 = 0; r3 < arguments.length; r3++) t3.push(o2(arguments[r3])); 4144 return t3.join(` `); 4145 } 4146 for (var r3 = 1, i3 = arguments, a3 = i3.length, s3 = String(e3).replace(n2, function(e4) { 4147 if (e4 === `%%`) return `%`; 4148 if (r3 >= a3) return e4; 4149 switch (e4) { 4150 case `%s`: 4151 return String(i3[r3++]); 4152 case `%d`: 4153 return Number(i3[r3++]); 4154 case `%j`: 4155 try { 4156 return JSON.stringify(i3[r3++]); 4157 } catch { 4158 return `[Circular]`; 4159 } 4160 default: 4161 return e4; 4162 } 4163 }), c3 = i3[r3]; r3 < a3; c3 = i3[++r3]) b2(c3) || !D2(c3) ? s3 += ` ` + c3 : s3 += ` ` + o2(c3); 4164 return s3; 4165 }, e2.deprecate = function(t3, n3) { 4166 if (l !== void 0 && l.noDeprecation === true) return t3; 4167 if (l === void 0) return function() { 4168 return e2.deprecate(t3, n3).apply(this, arguments); 4169 }; 4170 var r3 = false;
4171 function i3() { 4172 if (!r3) { 4173 if (l.throwDeprecation) throw Error(n3); 4174 l.traceDeprecation ? console.trace(n3) : console.error(n3), r3 = true; 4175 } 4176 return t3.apply(this, arguments); 4177 } 4178 return i3; 4179 }; 4180 var r2 = {}, i2 = /^$/; 4181 if ({}.NODE_DEBUG) { 4182 var a2 = {}.NODE_DEBUG; 4183 a2 = a2.replace(/[|\\{}()[\]^$+?.]/g, `\\$&`).replace(/\*/g, `.*`).replace(/,/g, `$|^`).toUpperCase(), i2 = RegExp(`^` + a2 + `$`, `i`); 4184 } 4185 e2.debuglog = function(t3) { 4186 if (t3 = t3.toUpperCase(), !r2[t3]) if (i2.test(t3)) { 4187 var n3 = l.pid; 4188 r2[t3] = function() { 4189 var r3 = e2.format.apply(e2, arguments); 4190 console.error(`%s %d: %s`, t3, n3, r3); 4191 }; 4192 } else r2[t3] = function() { 4193 }; 4194 return r2[t3]; 4195 }; 4196 function o2(t3, n3) { 4197 var r3 = { seen: [], stylize: c2 }; 4198 return arguments.length >= 3 && (r3.depth = arguments[2]), arguments.length >= 4 && (r3.colors = arguments[3]), y2(n3) ? r3.showHidden = n3 : n3 && e2._extend(r3, n3), T2(r3.showHidden) && (r3.showHidden = false), T2(r3.depth) && (r3.depth = 2), T2(r3.colors) && (r3.colors = false), T2(r3.customInspect) && (r3.customInspect = true), r3.colors && (r3.stylize = s2), f2(r3, t3, r3.depth); 4199 } 4200 e2.inspect = o2, o2.colors = { bold: [1, 22], italic: [3, 23], underline: [4, 24], inverse: [7, 27], white: [37, 39], grey: [90, 39], black: [30, 39], blue: [34, 39], cyan: [36, 39], green: [32, 39], magenta: [35, 39], red: [31, 39], yellow: [33, 39] }, o2.styles = { special: `cyan`, number: `yellow`, boolean: `yellow`, undefined: `grey`, null: `bold`, string: `green`, date: `magenta`, regexp: `red` }; 4201 function s2(e3, t3) { 4202 var n3 = o2.styles[t3]; 4203 return n3 ? `\x1B[` + o2.colors[n3][0] + `m` + e3 + `\x1B[` + o2.colors[n3][1] + `m` : e3; 4204 } 4205 function c2(e3, t3) { 4206 return e3; 4207 } 4208 function d2(e3) { 4209 var t3 = {}; 4210 return e3.forEach(function(e4, n3) { 4211 t3[e4] = true; 4212 }), t3; 4213 } 4214 function f2(t3, n3, r3) { 4215 if (t3.customInspect && n3 && A2(n3.inspect) && n3.inspect !== e2.inspect && !(n3.constructor && n3.constructor.prototype === n3)) { 4216 var i3 = n3.inspect(r3, t3); 4217 return C2(i3) || (i3 = f2(t3, i3, r3)), i3; 4218 } 4219 var a3 = p2(t3, n3); 4220 if (a3) return a3; 4221 var o3 = Object.keys(n3), s3 = d2(o3); 4222 if (t3.showHidden && (o3 = Object.getOwnPropertyNames(n3)), k2(n3) && (o3.indexOf(`message`) >= 0 || o3.indexOf(`description`) >= 0)) return m2(n3); 4223 if (o3.length === 0) { 4224 if (A2(n3)) { 4225 var c3 = n3.name ? `: ` + n3.name : ``; 4226 return t3.stylize(`[Function` + c3 + `]`, `special`); 4227 } 4228 if (E2(n3)) return t3.stylize(RegExp.prototype.toString.call(n3), `regexp`); 4229 if (O2(n3)) return t3.stylize(Date.prototype.toString.call(n3), `date`); 4230 if (k2(n3)) return m2(n3); 4231 } 4232 var l2 = ``, u2 = false, y3 = [`{`, `}`]; 4233 if (v2(n3) && (u2 = true, y3 = [`[`, `]`]), A2(n3) && (l2 = ` [Function` + (n3.name ? `: ` + n3.name : ``) + `]`), E2(n3) && (l2 = ` ` + RegExp.prototype.toString.call(n3)), O2(n3) && (l2 = ` ` + Date.prototype.toUTCString.call(n3)), k2(n3) && (l2 = ` ` + m2(n3)), o3.length === 0 && (!u2 || n3.length == 0)) return y3[0] + l2 + y3[1]; 4234 if (r3 < 0) return E2(n3) ? t3.stylize(RegExp.prototype.toString.call(n3), `regexp`) : t3.stylize(`[Object]`, `special`); 4235 t3.seen.push(n3); 4236 var b3 = u2 ? h2(t3, n3, r3, s3, o3) : o3.map(function(e3) { 4237 return g2(t3, n3, r3, s3, e3, u2); 4238 }); 4239 return t3.seen.pop(), _2(b3, l2, y3); 4240 } 4241 function p2(e3, t3) { 4242 if (T2(t3)) return e3.stylize(`undefined`, `undefined`); 4243 if (C2(t3)) { 4244 var n3 = `'` + JSON.stringify(t3).replace(/^"|"$/g, ``).replace(/'/g, `\\'`).replace(/\\"/g, `"`) + `'`; 4245 return e3.stylize(n3, `string`); 4246 } 4247 if (S2(t3)) return e3.stylize(`` + t3, `number`); 4248 if (y2(t3)) return e3.stylize(`` + t3, `boolean`); 4249 if (b2(t3)) return e3.stylize(`null`, `null`); 4250 } 4251 function m2(e3) { 4252 return `[` + Error.prototype.toString.call(e3) + `]`; 4253 } 4254 function h2(e3, t3, n3, r3, i3) { 4255 for (var a3 = [], o3 = 0, s3 = t3.length; o3 < s3; ++o3) I2(t3, String(o3)) ? a3.push(g2(e3, t3, n3, r3, String(o3), true)) : a3.push(``); 4256 return i3.forEach(function(i4) { 4257 i4.match(/^\d+$/) || a3.push(g2(e3, t3, n3, r3, i4, true)); 4258 }), a3; 4259 } 4260 function g2(e3, t3, n3, r3, i3, a3) { 4261 var o3, s3, c3 = Object.getOwnPropertyDescriptor(t3, i3) || { value: t3[i3] }; 4262 if (c3.get ? s3 = c3.set ? e3.stylize(`[Getter/Setter]`, `special`) : e3.stylize(`[Getter]`, `special`) : c3.set && (s3 = e3.stylize(`[Setter]`, `special`)), I2(r3, i3) || (
4262o3 = `[` + i3 + `]`), s3 || (e3.seen.indexOf(c3.value) < 0 ? (s3 = b2(n3) ? f2(e3, c3.value, null) : f2(e3, c3.value, n3 - 1), s3.indexOf(` 4263`) > -1 && (s3 = a3 ? s3.split(` 4264`).map(function(e4) { 4265 return ` ` + e4; 4266 }).join(` 4267`).slice(2) : ` 4268` + s3.split(` 4269`).map(function(e4) { 4270 return ` ` + e4; 4271 }).join(` 4272`))) : s3 = e3.stylize(`[Circular]`, `special`)), T2(o3)) { 4273 if (a3 && i3.match(/^\d+$/)) return s3; 4274 o3 = JSON.stringify(`` + i3), o3.match(/^"([a-zA-Z_][a-zA-Z_0-9]*)"$/) ? (o3 = o3.slice(1, -1), o3 = e3.stylize(o3, `name`)) : (o3 = o3.replace(/'/g, `\\'`).replace(/\\"/g, `"`).replace(/(^"|"$)/g, `'`), o3 = e3.stylize(o3, `string`)); 4275 } 4276 return o3 + `: ` + s3; 4277 } 4278 function _2(e3, t3, n3) { 4279 var r3 = 0; 4280 return e3.reduce(function(e4, t4) { 4281 return r3++, t4.indexOf(` 4282`) >= 0 && r3++, e4 + t4.replace(/\u001b\[\d\d?m/g, ``).length + 1; 4283 }, 0) > 60 ? n3[0] + (t3 === `` ? `` : t3 + ` 4284 `) + ` ` + e3.join(`, 4285 `) + ` ` + n3[1] : n3[0] + t3 + ` ` + e3.join(`, `) + ` ` + n3[1]; 4286 } 4287 e2.types = Hn(); 4288 function v2(e3) { 4289 return Array.isArray(e3); 4290 } 4291 e2.isArray = v2; 4292 function y2(e3) { 4293 return typeof e3 == `boolean`; 4294 } 4295 e2.isBoolean = y2; 4296 function b2(e3) { 4297 return e3 === null; 4298 } 4299 e2.isNull = b2; 4300 function x2(e3) { 4301 return e3 == null; 4302 } 4303 e2.isNullOrUndefined = x2; 4304 function S2(e3) { 4305 return typeof e3 == `number`; 4306 } 4307 e2.isNumber = S2; 4308 function C2(e3) { 4309 return typeof e3 == `string`; 4310 } 4311 e2.isString = C2; 4312 function w2(e3) { 4313 return typeof e3 == `symbol`; 4314 } 4315 e2.isSymbol = w2; 4316 function T2(e3) { 4317 return e3 === void 0; 4318 } 4319 e2.isUndefined = T2; 4320 function E2(e3) { 4321 return D2(e3) && M2(e3) === `[object RegExp]`; 4322 } 4323 e2.isRegExp = E2, e2.types.isRegExp = E2; 4324 function D2(e3) { 4325 return typeof e3 == `object` && !!e3; 4326 } 4327 e2.isObject = D2; 4328 function O2(e3) { 4329 return D2(e3) && M2(e3) === `[object Date]`; 4330 } 4331 e2.isDate = O2, e2.types.isDate = O2; 4332 function k2(e3) { 4333 return D2(e3) && (M2(e3) === `[object Error]` || e3 instanceof Error); 4334 } 4335 e2.isError = k2, e2.types.isNativeError = k2; 4336 function A2(e3) { 4337 return typeof e3 == `function`; 4338 } 4339 e2.isFunction = A2; 4340 function j2(e3) { 4341 return e3 === null || typeof e3 == `boolean` || typeof e3 == `number` || typeof e3 == `string` || typeof e3 == `symbol` || e3 === void 0; 4342 } 4343 e2.isPrimitive = j2, e2.isBuffer = Un(); 4344 function M2(e3) { 4345 return Object.prototype.toString.call(e3); 4346 } 4347 function N2(e3) { 4348 return e3 < 10 ? `0` + e3.toString(10) : e3.toString(10); 4349 } 4350 var P2 = [`Jan`, `Feb`, `Mar`, `Apr`, `May`, `Jun`, `Jul`, `Aug`, `Sep`, `Oct`, `Nov`, `Dec`]; 4351 function F2() { 4352 var e3 = /* @__PURE__ */ new Date(), t3 = [N2(e3.getHours()), N2(e3.getMinutes()), N2(e3.getSeconds())].join(`:`); 4353 return [e3.getDate(), P2[e3.getMonth()], t3].join(` `); 4354 } 4355 e2.log = function() { 4356 console.log(`%s - %s`, F2(), e2.format.apply(e2, arguments)); 4357 }, e2.inherits = Cn(), e2._extend = function(e3, t3) { 4358 if (!t3 || !D2(t3)) return e3; 4359 for (var n3 = Object.keys(t3), r3 = n3.length; r3--; ) e3[n3[r3]] = t3[n3[r3]]; 4360 return e3; 4361 }; 4362 function I2(e3, t3) { 4363 return Object.prototype.hasOwnProperty.call(e3, t3); 4364 }
4365 var L2 = typeof Symbol < `u` ? /* @__PURE__ */ Symbol(`util.promisify.custom`) : void 0; 4366 e2.promisify = function(e3) { 4367 if (typeof e3 != `function`) throw TypeError(`The "original" argument must be of type Function`); 4368 if (L2 && e3[L2]) { 4369 var n3 = e3[L2]; 4370 if (typeof n3 != `function`) throw TypeError(`The "util.promisify.custom" argument must be of type Function`); 4371 return Object.defineProperty(n3, L2, { value: n3, enumerable: false, writable: false, configurable: true }), n3; 4372 } 4373 function n3() { 4374 for (var t3, n4, r3 = new Promise(function(e4, r4) { 4375 t3 = e4, n4 = r4; 4376 }), i3 = [], a3 = 0; a3 < arguments.length; a3++) i3.push(arguments[a3]); 4377 i3.push(function(e4, r4) { 4378 e4 ? n4(e4) : t3(r4); 4379 }); 4380 try { 4381 e3.apply(this, i3); 4382 } catch (e4) { 4383 n4(e4); 4384 } 4385 return r3; 4386 } 4387 return Object.setPrototypeOf(n3, Object.getPrototypeOf(e3)), L2 && Object.defineProperty(n3, L2, { value: n3, enumerable: false, writable: false, configurable: true }), Object.defineProperties(n3, t2(e3)); 4388 }, e2.promisify.custom = L2; 4389 function R2(e3, t3) { 4390 if (!e3) { 4391 var n3 = Error(`Promise was rejected with a falsy value`); 4392 n3.reason = e3, e3 = n3; 4393 } 4394 return t3(e3); 4395 } 4396 function z2(e3) { 4397 if (typeof e3 != `function`) throw TypeError(`The "original" argument must be of type Function`); 4398 function n3() { 4399 for (var t3 = [], n4 = 0; n4 < arguments.length; n4++) t3.push(arguments[n4]); 4400 var r3 = t3.pop(); 4401 if (typeof r3 != `function`) throw TypeError(`The last argument must be of type Function`); 4402 var i3 = this, a3 = function() { 4403 return r3.apply(i3, arguments); 4404 }; 4405 e3.apply(this, t3).then(function(e4) { 4406 l.nextTick(a3.bind(null, null, e4)); 4407 }, function(e4) { 4408 l.nextTick(R2.bind(null, e4, a3)); 4409 }); 4410 } 4411 return Object.setPrototypeOf(n3, Object.getPrototypeOf(e3)), Object.defineProperties(n3, t2(e3)), n3; 4412 } 4413 e2.callbackify = z2; 4414})), Gn = i(((e2, t2) => { 4415 function n2(e3, t3) { 4416 var n3 = Object.keys(e3); 4417 if (Object.getOwnPropertySymbols) { 4418 var r3 = Object.getOwnPropertySymbols(e3); 4419 t3 && (r3 = r3.filter(function(t4) { 4420 return Object.getOwnPropertyDescriptor(e3, t4).enumerable; 4421 })), n3.push.apply(n3, r3); 4422 } 4423 return n3; 4424 } 4425 function r2(e3) { 4426 for (var t3 = 1; t3 < arguments.length; t3++) { 4427 var r3 = arguments[t3] == null ? {} : arguments[t3]; 4428 t3 % 2 ? n2(Object(r3), true).forEach(function(t4) { 4429 i2(e3, t4, r3[t4]); 4430 }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e3, Object.getOwnPropertyDescriptors(r3)) : n2(Object(r3)).forEach(function(t4) { 4431 Object.defineProperty(e3, t4, Object.getOwnPropertyDescriptor(r3, t4)); 4432 }); 4433 } 4434 return e3; 4435 } 4436 function i2(e3, t3, n3) { 4437 return t3 = c2(t3), t3 in e3 ? Object.defineProperty(e3, t3, { value: n3, enumerable: true, configurable: true, writable: true }) : e3[t3] = n3, e3; 4438 } 4439 function a2(e3, t3) { 4440 if (!(e3 instanceof t3)) throw TypeError(`Cannot call a class as a function`); 4441 } 4442 function o2(e3, t3) { 4443 for (var n3 = 0; n3 < t3.length; n3++) { 4444 var r3 = t3[n3]; 4445 r3.enumerable = r3.enumerable || false, r3.configurable = true, `value` in r3 && (r3.writable = true), Object.defineProperty(e3, c2(r3.key), r3); 4446 } 4447 } 4448 function s2(e3, t3, n3) { 4449 return t3 && o2(e3.prototype, t3), n3 && o2(e3, n3), Object.defineProperty(e3, `prototype`, { writable: false }), e3; 4450 } 4451 function c2(e3) { 4452 var t3 = l2(e3, `string`); 4453 return typeof t3 == `symbol` ? t3 : String(t3); 4454 } 4455 function l2(e3, t3) { 4456 if (typeof e3 != `object` || !e3) return e3; 4457 var n3 = e3[Symbol.toPrimitive]; 4458 if (n3 !== void 0) { 4459 var r3 = n3.call(e3, t3 || `default`); 4460 if (typeof r3 != `object`) return r3; 4461 throw TypeError(`@@toPrimitive must return a primitive value.`); 4462 } 4463 return (t3 === `string` ? String : Number)(e3); 4464 } 4465 var u2 = re().Buffer, d2 = Wn().inspect, f2 = d2 && d2.custom || `inspect`; 4466 function p2(e3, t3, n3) { 4467 u2.prototype.copy.call(e3, t3, n3); 4468 } 4469 t2.exports = (function() { 4470 function e3() { 4471 a2(this, e3), this.head = null, this.tail = null, this.length = 0; 4472 } 4473 return s2(e3, [{ key: `push`, value: function(e4) { 4474 var t3 = { data: e4, next: null }; 4475 this.length > 0 ? this.tail.next = t3 : this.head = t3, this.tail = t3, ++this.length; 4476 } }, { key: `unshift`, value: function(e4) { 4477 var t3 = { data: e4, next: this.head }; 4478 this.length === 0 && (this.tail = t3), this.head = t3, ++this.length; 4479 } }, { key: `shift`, value: function() { 4480 if (this.length !== 0) { 4481 var e4 = this.head.data; 4482 return this.length === 1 ? this.head = this.tail = null : this.head = this.head.next, --this.length, e4; 4483 } 4484 } }, { key: `clear`, value: function() { 4485 this.head = this.tail = null, this.length = 0; 4486 } }, { key: `join`, value: function(e4) { 4487 if (this.length === 0) return ``; 4488 for (var t3 = this.head, n3 = `` + t3.data; t3 = t3.next; ) n3 += e4 + t3.data; 4489 return n3; 4490 } }, { key: `concat`, value: function(e4) { 4491 if (this.length === 0) return u2.alloc(0); 4492 for (var t3 = u2.allocUnsafe(e4 >>> 0), n3 = this.head, r3 = 0; n3; ) p2(n3.data, t3, r3), r3 += n3.data.length, n3 = n3.next; 4493 return t3; 4494 } }, { key: `consume`, value: function(e4, t3) { 4495 var n3; 4496 return e4 < this.head.data.length ? (n3 = this.head.data.slice(0, e4), this.head.data = this.head.data.slice(e4)) : n3 = e4 === this.head.data.length ? this.shift() : t3 ? this._getString(e4) : this._getBuffer(e4), n3; 4497 } }, { key: `first`, value: function() { 4498 return this.head.data; 4499 } }, { key: `_getString`, value: function(e4) { 4500 var t3 = this.head, n3 = 1, r3 = t3.data; 4501 for (e4 -= r3.length; t3 = t3.next; ) { 4502 var i3 = t3.data, a3 = e4 > i3.length ? i3.length : e4; 4503 if (a3 === i3.length ? r3 += i3 : r3 += i3.slice(0, e4), e4 -= a3, e4 === 0) { 4504 a3 === i3.length ? (++n3, t3.next ? this.head = t3.next : this.head = this.tail = null) : (this.head = t3, t3.data = i3.slice(a3)); 4505 break; 4506 } 4507 ++n3; 4508 } 4509 return this.length -= n3, r3; 4510 } }, { key: `_getBuffer`, value: function(e4) { 4511 var t3 = u2.allocUnsafe(e4), n3 = this.head, r3 = 1; 4512 for (n3.data.copy(t3), e4 -= n3.data.length; n3 = n3.next; ) { 4513 var i3 = n3.data, a3 = e4 > i3.length ? i3.length : e4; 4514 if (i3.copy(t3, t3.length - e4, 0, a3), e4 -= a3, e4 === 0) { 4515 a3 === i3.length ? (++r3, n3.next ? this.head = n3.next : this.head = this.tail = null) : (this.head = n3, n3.data = i3.slice(a3)); 4516 break; 4517 } 4518 ++r3; 4519 } 4520 return this.length -= r3, t3; 4521 } }, { key: f2, value: function(e4, t3) { 4522 return d2(this, r2(r2({}, t3), {}, { depth: 0, customInspect: false })); 4523 } }]), e3; 4524 })(); 4525})), Kn = i(((e2, t2) => { 4526 u(); 4527 function n2(e3, t3) { 4528 var n3 = this, a3 = this._readableState && this._readableState.destroyed, s3 = this._writableState && this._writableState.destroyed; 4529 return a3 || s3 ? (t3 ? t3(e3) : e3 && (this._writableState ? this._writableState.errorEmitted || (this._writableState.errorEmitted = true, l.nextTick(o2, this, e3)) : l.nextTick(o2, this, e3)), this) : (this._readableState && (this._readableState.destroyed = true), this._writableState && (this._writableState.destroyed = true), this._destroy(e3 || null, function(e4) { 4530 !t3 && e4 ? n3._writableState ? n3._writableState.errorEmitted ? l.nextTick(i2, n3) : (n3._writableState.errorEmitted = true, l.nextTick(r2, n3, e4)) : l.nextTick(r2, n3, e4) : t3 ? (l.nextTick(i2, n3), t3(e4)) : l.nextTick(i2, n3); 4531 }), this); 4532 } 4533 function r2(e3, t3) { 4534 o2(e3, t3), i2(e3); 4535 } 4536 function i2(e3) { 4537 e3._writableState && !e3._writableState.emitClose || e3._readableState && !e3._readableState.emitClose || e3.emit(`close`); 4538 } 4539 function a2() { 4540 this._readableState && (this._readableState.destroyed = false, this._readableState.reading = false, this._readableState.ended = false, this._readableState.endEmitted = false), this._writableState && (this._writableState.destroyed = false, this._writableState.ended = false, this._writableState.ending = false, this._writableState.finalCalled = false, this._writableState.prefinished = false, this._writableState.finished = false, this._writableState.errorEmitted = false); 4541 } 4542 function o2(e3, t3) { 4543 e3.emit(`error`, t3); 4544 } 4545 function s2(e3, t3) { 4546 var n3 = e3._readableState, r3 = e3._writableState; 4547 n3 && n3.autoDestroy || r3 && r3.autoDestroy ? e3.destroy(t3) : e3.emit(`error`, t3); 4548 } 4549 t2.exports = { destroy: n2, undestroy: a2, errorOrDestroy: s2 }; 4550})), qn = i(((e2, t2) => { 4551 function n2(e3, t3) { 4552 e3.prototype = Object.create(t3.prototype), e3.prototype.constructor = e3, e3.__proto__ = t3; 4553 } 4554 var r2 = {}; 4555 function i2(e3, t3, i3) { 4556 i3 || (i3 = Error); 4557 function a3(e4, n3, r3) { 4558 return typeof t3 == `string` ? t3 : t3(e4, n3, r3); 4559 } 4560 var o3 = (function(e4) { 4561 n2(t4, e4); 4562 function t4(t5, n3, r3) { 4563 return e4.call(this, a3(t5, n3, r3)) || this; 4564 } 4565 return t4; 4566 })(i3); 4567 o3.prototype.name = i3.name, o3.prototype.code = e3, r2[e3] = o3; 4568 } 4569 function a2(e3, t3) { 4570 if (Array.isArray(e3)) { 4571 var n3 = e3.length; 4572 return e3 = e3.map(function(e4) { 4573 return String(e4); 4574 }), n3 > 2 ? `one of ${t3} ${e3.slice(0, n3 - 1).join(`, `)}, or ` + e3[n3 - 1] : n3 === 2 ? `one of ${t3} ${e3[0]} or ${e3[1]}` : `of ${t3} ${e3[0]}`; 4575 } else return `of ${t3} ${String(e3)}`; 4576 } 4577 function o2(e3, t3, n3) { 4578 return e3.substr(!n3 || n3 < 0 ? 0 : +n3, t3.length) === t3; 4579 } 4580 function s2(e3, t3, n3) { 4581 return (n3 === void 0 || n3 > e3.length) && (n3 = e3.length), e3.substring(n3 - t3.length, n3) === t3; 4582 } 4583 function c2(e3, t3, n3) { 4584 return typeof n3 != `number` && (n3 = 0), n3 + t3.length > e3.length ? false : e3.indexOf(t3, n3) !== -1; 4585 } 4586 i2(`ERR_INVALID_OPT_VALUE`, function(e3, t3) {
4587 return `The value "` + t3 + `" is invalid for option "` + e3 + `"`; 4588 }, TypeError), i2(`ERR_INVALID_ARG_TYPE`, function(e3, t3, n3) { 4589 var r3; 4590 typeof t3 == `string` && o2(t3, `not `) ? (r3 = `must not be`, t3 = t3.replace(/^not /, ``)) : r3 = `must be`; 4591 var i3 = s2(e3, ` argument`) ? `The ${e3} ${r3} ${a2(t3, `type`)}` : `The "${e3}" ${c2(e3, `.`) ? `property` : `argument`} ${r3} ${a2(t3, `type`)}`; 4592 return i3 += `. Received type ${typeof n3}`, i3; 4593 }, TypeError), i2(`ERR_STREAM_PUSH_AFTER_EOF`, `stream.push() after EOF`), i2(`ERR_METHOD_NOT_IMPLEMENTED`, function(e3) { 4594 return `The ` + e3 + ` method is not implemented`; 4595 }), i2(`ERR_STREAM_PREMATURE_CLOSE`, `Premature close`), i2(`ERR_STREAM_DESTROYED`, function(e3) { 4596 return `Cannot call ` + e3 + ` after a stream was destroyed`; 4597 }), i2(`ERR_MULTIPLE_CALLBACK`, `Callback called multiple times`), i2(`ERR_STREAM_CANNOT_PIPE`, `Cannot pipe, not readable`), i2(`ERR_STREAM_WRITE_AFTER_END`, `write after end`), i2(`ERR_STREAM_NULL_VALUES`, `May not write null values to stream`, TypeError), i2(`ERR_UNKNOWN_ENCODING`, function(e3) { 4598 return `Unknown encoding: ` + e3; 4599 }, TypeError), i2(`ERR_STREAM_UNSHIFT_AFTER_END_EVENT`, `stream.unshift() after end event`), t2.exports.codes = r2; 4600})), Jn = i(((e2, t2) => { 4601 var n2 = qn().codes.ERR_INVALID_OPT_VALUE; 4602 function r2(e3, t3, n3) { 4603 return e3.highWaterMark == null ? t3 ? e3[n3] : null : e3.highWaterMark; 4604 } 4605 function i2(e3, t3, i3, a2) { 4606 var o2 = r2(t3, a2, i3); 4607 if (o2 != null) { 4608 if (!(isFinite(o2) && Math.floor(o2) === o2) || o2 < 0) throw new n2(a2 ? i3 : `highWaterMark`, o2); 4609 return Math.floor(o2); 4610 } 4611 return e3.objectMode ? 16 : 16 * 1024; 4612 } 4613 t2.exports = { getHighWaterMark: i2 }; 4614})), Yn = i(((e2, t2) => { 4615 a(), t2.exports = n2; 4616 function n2(e3, t3) { 4617 if (r2(`noDeprecation`)) return e3; 4618 var n3 = false;
4619 function i2() { 4620 if (!n3) { 4621 if (r2(`throwDeprecation`)) throw Error(t3); 4622 r2(`traceDeprecation`) ? console.trace(t3) : console.warn(t3), n3 = true; 4623 } 4624 return e3.apply(this, arguments); 4625 } 4626 return i2; 4627 } 4628 function r2(e3) { 4629 try { 4630 if (!o.localStorage) return false; 4631 } catch { 4632 return false; 4633 } 4634 var t3 = o.localStorage[e3]; 4635 return t3 == null ? false : String(t3).toLowerCase() === `true`; 4636 } 4637})), Xn = i(((e2, t2) => { 4638 a(), u(), t2.exports = k2; 4639 function n2(e3) { 4640 var t3 = this; 4641 this.next = null, this.entry = null, this.finish = function() { 4642 ee2(t3, e3); 4643 }; 4644 } 4645 var r2; 4646 k2.WritableState = D2; 4647 var i2 = { deprecate: Yn() }, s2 = wn(), c2 = re().Buffer, d2 = (o === void 0 ? typeof window < `u` ? window : typeof self < `u` ? self : {} : o).Uint8Array || function() { 4648 }; 4649 function f2(e3) { 4650 return c2.from(e3); 4651 } 4652 function p2(e3) { 4653 return c2.isBuffer(e3) || e3 instanceof d2; 4654 } 4655 var m2 = Kn(), h2 = Jn().getHighWaterMark, g2 = qn().codes, _2 = g2.ERR_INVALID_ARG_TYPE, v2 = g2.ERR_METHOD_NOT_IMPLEMENTED, y2 = g2.ERR_MULTIPLE_CALLBACK, b2 = g2.ERR_STREAM_CANNOT_PIPE, x2 = g2.ERR_STREAM_DESTROYED, S2 = g2.ERR_STREAM_NULL_VALUES, C2 = g2.ERR_STREAM_WRITE_AFTER_END, w2 = g2.ERR_UNKNOWN_ENCODING, T2 = m2.errorOrDestroy; 4656 Cn()(k2, s2); 4657 function E2() { 4658 } 4659 function D2(e3, t3, i3) { 4660 r2 || (r2 = Zn()), e3 || (e3 = {}), typeof i3 != `boolean` && (i3 = t3 instanceof r2), this.objectMode = !!e3.objectMode, i3 && (this.objectMode = this.objectMode || !!e3.writableObjectMode), this.highWaterMark = h2(this, e3, `writableHighWaterMark`, i3), this.finalCalled = false, this.needDrain = false, this.ending = false, this.ended = false, this.finished = false, this.destroyed = false; 4661 var a2 = e3.decodeStrings === false; 4662 this.decodeStrings = !a2, this.defaultEncoding = e3.defaultEncoding || `utf8`, this.length = 0, this.writing = false, this.corked = 0, this.sync = true, this.bufferProcessing = false, this.onwrite = function(e4) { 4663 L2(t3, e4); 4664 }, this.writecb = null, this.writelen = 0, this.bufferedRequest = null, this.lastBufferedRequest = null, this.pendingcb = 0, this.prefinished = false, this.errorEmitted = false, this.emitClose = e3.emitClose !== false, this.autoDestroy = !!e3.autoDestroy, this.bufferedRequestCount = 0, this.corkedRequestsFree = new n2(this); 4665 } 4666 D2.prototype.getBuffer = function() { 4667 for (var e3 = this.bufferedRequest, t3 = []; e3; ) t3.push(e3), e3 = e3.next; 4668 return t3; 4669 }, (function() { 4670 try { 4671 Object.defineProperty(D2.prototype, `buffer`, { get: i2.deprecate(function() { 4672 return this.getBuffer(); 4673 }, `_writableState.buffer is deprecated. Use _writableState.getBuffer instead.`, `DEP0003`) }); 4674 } catch { 4675 } 4676 })(); 4677 var O2; 4678 typeof Symbol == `function` && Symbol.hasInstance && typeof Function.prototype[Symbol.hasInstance] == `function` ? (O2 = Function.prototype[Symbol.hasInstance], Object.defineProperty(k2, Symbol.hasInstance, { value: function(e3) { 4679 return O2.call(this, e3) ? true : this === k2 ? e3 && e3._writableState instanceof D2 : false; 4680 } })) : O2 = function(e3) { 4681 return e3 instanceof this; 4682 }; 4683 function k2(e3) { 4684 r2 || (r2 = Zn()); 4685 var t3 = this instanceof r2; 4686 if (!t3 && !O2.call(k2, this)) return new k2(e3); 4687 this._writableState = new D2(e3, this, t3), this.writable = true, e3 && (typeof e3.write == `function` && (this._write = e3.write), typeof e3.writev == `function` && (this._writev = e3.writev), typeof e3.destroy == `function` && (this._destroy = e3.destroy), typeof e3.final == `function` && (this._final = e3.final)), s2.call(this); 4688 } 4689 k2.prototype.pipe = function() { 4690 T2(this, new b2()); 4691 }; 4692 function A2(e3, t3) { 4693 var n3 = new C2(); 4694 T2(e3, n3), l.nextTick(t3, n3); 4695 } 4696 function j2(e3, t3, n3, r3) { 4697 var i3; 4698 return n3 === null ? i3 = new S2() : typeof n3 != `string` && !t3.objectMode && (i3 = new _2(`chunk`, [`string`, `Buffer`], n3)), i3 ? (T2(e3, i3), l.nextTick(r3, i3), false) : true; 4699 } 4700 k2.prototype.write = function(e3, t3, n3) { 4701 var r3 = this._writableState, i3 = false, a2 = !r3.objectMode && p2(e3); 4702 return a2 && !c2.isBuffer(e3) && (e3 = f2(e3)), typeof t3 == `function` && (n3 = t3, t3 = null), a2 ? t3 = `buffer` : t3 || (t3 = r3.defaultEncoding), typeof n3 != `function` && (n3 = E2), r3.ending ? A2(this, n3) : (a2 || j2(this, r3, e3, n3)) && (r3.pendingcb++, i3 = N2(this, r3, a2, e3, t3, n3)), i3; 4703 }, k2.prototype.cork = function() { 4704 this._writableState.corked++; 4705 }, k2.prototype.uncork = function() { 4706 var e3 = this._writableState; 4707 e3.corked && (e3.corked--, !e3.writing && !e3.corked && !e3.bufferProcessing && e3.bufferedRequest && B2(this, e3)); 4708 }, k2.prototype.setDefaultEncoding = function(e3) { 4709 if (typeof e3 == `string` && (e3 = e3.toLowerCase()), !([`hex`, `utf8`, `utf-8`, `ascii`, `binary`, `base64`, `ucs2`, `ucs-2`, `utf16le`, `utf-16le`, `raw`].indexOf((e3 + ``).toLowerCase()) > -1)) throw new w2(e3); 4710 return this._writableState.defaultEncoding = e3, this; 4711 }, Object.defineProperty(k2.prototype, `writableBuffer`, { enumerable: false, get: function() { 4712 return this._writableState && this._writableState.getBuffer(); 4713 } }); 4714 function M2(e3, t3, n3) { 4715 return !e3.objectMode && e3.decodeStrings !== false && typeof t3 == `string` && (t3 = c2.from(t3, n3)), t3; 4716 } 4717 Object.defineProperty(k2.prototype, `writableHighWaterMark`, { enumerable: false, get: function() { 4718 return this._writableState.highWaterMark; 4719 } }); 4720 function N2(e3, t3, n3, r3, i3, a2) { 4721 if (!n3) { 4722 var o2 = M2(t3, r3, i3); 4723 r3 !== o2 && (n3 = true, i3 = `buffer`, r3 = o2); 4724 } 4725 var s3 = t3.objectMode ? 1 : r3.length; 4726 t3.length += s3; 4727 var c3 = t3.length < t3.highWaterMark; 4728 if (c3 || (t3.needDrain = true), t3.writing || t3.corked) { 4729 var l2 = t3.lastBufferedRequest; 4730 t3.lastBufferedRequest = { chunk: r3, encoding: i3, isBuf: n3, callback: a2, next: null }, l2 ? l2.next = t3.lastBufferedRequest : t3.bufferedRequest = t3.lastBufferedRequest, t3.bufferedRequestCount += 1; 4731 } else P2(e3, t3, false, s3, r3, i3, a2); 4732 return c3; 4733 } 4734 function P2(e3, t3, n3, r3, i3, a2, o2) { 4735 t3.writelen = r3, t3.writecb = o2, t3.writing = true, t3.sync = true, t3.de
4735stroyed ? t3.onwrite(new x2(`write`)) : n3 ? e3._writev(i3, t3.onwrite) : e3._write(i3, a2, t3.onwrite), t3.sync = false; 4736 } 4737 function F2(e3, t3, n3, r3, i3) { 4738 --t3.pendingcb, n3 ? (l.nextTick(i3, r3), l.nextTick(W2, e3, t3), e3._writableState.errorEmitted = true, T2(e3, r3)) : (i3(r3), e3._writableState.errorEmitted = true, T2(e3, r3), W2(e3, t3)); 4739 } 4740 function I2(e3) { 4741 e3.writing = false, e3.writecb = null, e3.length -= e3.writelen, e3.writelen = 0; 4742 } 4743 function L2(e3, t3) { 4744 var n3 = e3._writableState, r3 = n3.sync, i3 = n3.writecb; 4745 if (typeof i3 != `function`) throw new y2(); 4746 if (I2(n3), t3) F2(e3, n3, r3, t3, i3); 4747 else { 4748 var a2 = V2(n3) || e3.destroyed; 4749 !a2 && !n3.corked && !n3.bufferProcessing && n3.bufferedRequest && B2(e3, n3), r3 ? l.nextTick(R2, e3, n3, a2, i3) : R2(e3, n3, a2, i3); 4750 } 4751 } 4752 function R2(e3, t3, n3, r3) { 4753 n3 || z2(e3, t3), t3.pendingcb--, r3(), W2(e3, t3); 4754 } 4755 function z2(e3, t3) { 4756 t3.length === 0 && t3.needDrain && (t3.needDrain = false, e3.emit(`drain`)); 4757 } 4758 function B2(e3, t3) { 4759 t3.bufferProcessing = true; 4760 var r3 = t3.bufferedRequest; 4761 if (e3._writev && r3 && r3.next) { 4762 var i3 = t3.bufferedRequestCount, a2 = Array(i3), o2 = t3.corkedRequestsFree; 4763 o2.entry = r3; 4764 for (var s3 = 0, c3 = true; r3; ) a2[s3] = r3, r3.isBuf || (c3 = false), r3 = r3.next, s3 += 1; 4765 a2.allBuffers = c3, P2(e3, t3, true, t3.length, a2, ``, o2.finish), t3.pendingcb++, t3.lastBufferedRequest = null, o2.next ? (t3.corkedRequestsFree = o2.next, o2.next = null) : t3.corkedRequestsFree = new n2(t3), t3.bufferedRequestCount = 0; 4766 } else { 4767 for (; r3; ) { 4768 var l2 = r3.chunk, u2 = r3.encoding, d3 = r3.callback; 4769 if (P2(e3, t3, false, t3.objectMode ? 1 : l2.length, l2, u2, d3), r3 = r3.next, t3.bufferedRequestCount--, t3.writing) break; 4770 } 4771 r3 === null && (t3.lastBufferedRequest = null); 4772 } 4773 t3.bufferedRequest = r3, t3.bufferProcessing = false; 4774 } 4775 k2.prototype._write = function(e3, t3, n3) { 4776 n3(new v2(`_write()`)); 4777 }, k2.prototype._writev = null, k2.prototype.end = function(e3, t3, n3) { 4778 var r3 = this._writableState; 4779 return typeof e3 == `function` ? (n3 = e3, e3 = null, t3 = null) : typeof t3 == `function` && (n3 = t3, t3 = null), e3 != null && this.write(e3, t3), r3.corked && (r3.corked = 1, this.uncork()), r3.ending || G2(this, r3, n3), this; 4780 }, Object.defineProperty(k2.prototype, `writableLength`, { enumerable: false, get: function() { 4781 return this._writableState.length; 4782 } }); 4783 function V2(e3) { 4784 return e3.ending && e3.length === 0 && e3.bufferedRequest === null && !e3.finished && !e3.writing; 4785 } 4786 function H2(e3, t3) { 4787 e3._final(function(n3) { 4788 t3.pendingcb--, n3 && T2(e3, n3), t3.prefinished = true, e3.emit(`prefinish`), W2(e3, t3); 4789 }); 4790 } 4791 function U2(e3, t3) { 4792 !t3.prefinished && !t3.finalCalled && (typeof e3._final == `function` && !t3.destroyed ? (t3.pendingcb++, t3.finalCalled = true, l.nextTick(H2, e3, t3)) : (t3.prefinished = true, e3.emit(`prefinish`))); 4793 } 4794 function W2(e3, t3) { 4795 var n3 = V2(t3); 4796 if (n3 && (U2(e3, t3), t3.pendingcb === 0 && (t3.finished = true, e3.emit(`finish`), t3.autoDestroy))) { 4797 var r3 = e3._readableState; 4798 (!r3 || r3.autoDestroy && r3.endEmitted) && e3.destroy(); 4799 } 4800 return n3; 4801 } 4802 function G2(e3, t3, n3) { 4803 t3.ending = true, W2(e3, t3), n3 && (t3.finished ? l.nextTick(n3) : e3.once(`finish`, n3)), t3.ended = true, e3.writable = false; 4804 } 4805 function ee2(e3, t3, n3) { 4806 var r3 = e3.entry; 4807 for (e3.entry = null; r3; ) { 4808 var i3 = r3.callback; 4809 t3.pendingcb--, i3(n3), r3 = r3.next; 4810 } 4811 t3.corkedRequestsFree.next = e3; 4812 } 4813 Object.defineProperty(k2.prototype, `destroyed`, { enumerable: false, get: function() { 4814 return this._writableState === void 0 ? false : this._writableState.destroyed; 4815 }, set: function(e3) { 4816 this._writableState && (this._writableState.destroyed = e3); 4817 } }), k2.prototype.destroy = m2.destroy, k2.prototype._undestroy = m2.undestroy, k2.prototype._destroy = function(e3, t3) { 4818 t3(e3); 4819 }; 4820})), Zn = i(((e2, t2) => { 4821 u(); 4822 var n2 = Object.keys || function(e3) { 4823 var t3 = []; 4824 for (var n3 in e3) t3.push(n3); 4825 return t3; 4826 }; 4827 t2.exports = c2; 4828 var r2 = rr(), i2 = Xn(); 4829 Cn()(c2, r2); 4830 for (var a2 = n2(i2.prototype), o2 = 0; o2 < a2.length; o2++) { 4831 var s2 = a2[o2]; 4832 c2.prototype[s2] || (c2.prototype[s2] = i2.prototype[s2]); 4833 } 4834 function c2(e3) { 4835 if (!(this instanceof c2)) return new c2(e3); 4836 r2.call(this, e3), i2.call(this, e3), this.allowHalfOpen = true, e3 && (e3.readable === false && (this.readable = false), e3.writable === false && (this.writable = false), e3.allowHalfOpen === false && (this.allowHalfOpen = false, this.once(`end`, d2))); 4837 } 4838 Object.defineProperty(c2.prototype, `writableHighWaterMark`, { enumerable: false, get: function() { 4839 return this._writableState.highWaterMark; 4840 } }), Object.defineProperty(c2.prototype, `writableBuffer`, { enumerable: false, get: function() { 4841 return this._writableState && this._writableState.getBuffer(); 4842 } }), Object.defineProperty(c2.prototype, `writableLength`, { enumerable: false, get: function() { 4843 return this._writableState.length; 4844 } }); 4845 function d2() { 4846 this._writableState.ended || l.nextTick(f2, this); 4847 } 4848 function f2(e3) { 4849 e3.end(); 4850 } 4851 Object.defineProperty(c2.prototype, `destroyed`, { enumerable: false, get: function() { 4852 return this._readableState === void 0 || this._writableState === void 0 ? false : this._readableState.destroyed && this._writableState.destroyed; 4853 }
4853, set: function(e3) { 4854 this._readableState === void 0 || this._writableState === void 0 || (this._readableState.destroyed = e3, this._writableState.destroyed = e3); 4855 } }); 4856})), Qn = i(((e2, t2) => { 4857 var n2 = re(), r2 = n2.Buffer; 4858 function i2(e3, t3) { 4859 for (var n3 in e3) t3[n3] = e3[n3]; 4860 } 4861 r2.from && r2.alloc && r2.allocUnsafe && r2.allocUnsafeSlow ? t2.exports = n2 : (i2(n2, e2), e2.Buffer = a2); 4862 function a2(e3, t3, n3) { 4863 return r2(e3, t3, n3); 4864 } 4865 a2.prototype = Object.create(r2.prototype), i2(r2, a2), a2.from = function(e3, t3, n3) { 4866 if (typeof e3 == `number`) throw TypeError(`Argument must not be a number`); 4867 return r2(e3, t3, n3); 4868 }, a2.alloc = function(e3, t3, n3) { 4869 if (typeof e3 != `number`) throw TypeError(`Argument must be a number`); 4870 var i3 = r2(e3); 4871 return t3 === void 0 ? i3.fill(0) : typeof n3 == `string` ? i3.fill(t3, n3) : i3.fill(t3), i3; 4872 }, a2.allocUnsafe = function(e3) { 4873 if (typeof e3 != `number`) throw TypeError(`Argument must be a number`); 4874 return r2(e3); 4875 }, a2.allocUnsafeSlow = function(e3) { 4876 if (typeof e3 != `number`) throw TypeError(`Argument must be a number`); 4877 return n2.SlowBuffer(e3); 4878 }; 4879})), $n = i(((e2) => { 4880 var t2 = Qn().Buffer, n2 = t2.isEncoding || function(e3) { 4881 switch (e3 = `` + e3, e3 && e3.toLowerCase()) { 4882 case `hex`: 4883 case `utf8`: 4884 case `utf-8`: 4885 case `ascii`: 4886 case `binary`: 4887 case `base64`: 4888 case `ucs2`: 4889 case `ucs-2`: 4890 case `utf16le`: 4891 case `utf-16le`: 4892 case `raw`: 4893 return true; 4894 default: 4895 return false; 4896 } 4897 }; 4898 function r2(e3) { 4899 if (!e3) return `utf8`; 4900 for (var t3; ; ) switch (e3) { 4901 case `utf8`: 4902 case `utf-8`: 4903 return `utf8`; 4904 case `ucs2`: 4905 case `ucs-2`: 4906 case `utf16le`: 4907 case `utf-16le`: 4908 return `utf16le`; 4909 case `latin1`: 4910 case `binary`: 4911 return `latin1`; 4912 case `base64`: 4913 case `ascii`: 4914 case `hex`: 4915 return e3; 4916 default: 4917 if (t3) return; 4918 e3 = (`` + e3).toLowerCase(), t3 = true; 4919 } 4920 } 4921 function i2(e3) { 4922 var i3 = r2(e3); 4923 if (typeof i3 != `string` && (t2.isEncoding === n2 || !n2(e3))) throw Error(`Unknown encoding: ` + e3); 4924 return i3 || e3; 4925 } 4926 e2.StringDecoder = a2; 4927 function a2(e3) { 4928 this.encoding = i2(e3); 4929 var n3; 4930 switch (this.encoding) { 4931 case `utf16le`: 4932 this.text = f2, this.end = p2, n3 = 4; 4933 break; 4934 case `utf8`: 4935 this.fillLast = l2, n3 = 4; 4936 break; 4937 case `base64`: 4938 this.text = m2, this.end = h2, n3 = 3; 4939 break; 4940 default: 4941 this.write = g2, this.end = _2; 4942 return; 4943 } 4944 this.lastNeed = 0, this.lastTotal = 0, this.lastChar = t2.allocUnsafe(n3); 4945 } 4946 a2.prototype.write = function(e3) { 4947 if (e3.length === 0) return ``; 4948 var t3, n3; 4949 if (this.lastNeed) { 4950 if (t3 = this.fillLast(e3), t3 === void 0) return ``; 4951 n3 = this.lastNeed, this.lastNeed = 0; 4952 } else n3 = 0; 4953 return n3 < e3.length ? t3 ? t3 + this.text(e3, n3) : this.text(e3, n3) : t3 || ``; 4954 }, a2.prototype.end = d2, a2.prototype.text = u2, a2.prototype.fillLast = function(e3) { 4955 if (this.lastNeed <= e3.length) return e3.copy(this.lastChar, this.lastTotal - this.lastNeed, 0, this.lastNeed), this.lastChar.toString(this.encoding, 0, this.lastTotal); 4956 e3.copy(this.lastChar, this.lastTotal - this.lastNeed, 0, e3.length), this.lastNeed -= e3.length; 4957 }; 4958 function o2(e3) { 4959 return e3 <= 127 ? 0 : e3 >> 5 == 6 ? 2 : e3 >> 4 == 14 ? 3 : e3 >> 3 == 30 ? 4 : e3 >> 6 == 2 ? -1 : -2; 4960 } 4961 function s2(e3, t3, n3) { 4962 var r3 = t3.length - 1; 4963 if (r3 < n3) return 0; 4964 var i3 = o2(t3[r3]); 4965 return i3 >= 0 ? (i3 > 0 && (e3.lastNeed = i3 - 1), i3) : --r3 < n3 || i3 === -2 ? 0 : (i3 = o2(t3[r3]), i3 >= 0 ? (i3 > 0 && (e3.lastNeed = i3 - 2), i3) : --r3 < n3 || i3 === -2 ? 0 : (i3 = o2(t3[r3]), i3 >= 0 ? (i3 > 0 && (i3 === 2 ? i3 = 0 : e3.lastNeed = i3 - 3), i3) : 0)); 4966 } 4967 function c2(e3, t3, n3) { 4968 if ((t3[0] & 192) != 128) return e3.lastNeed = 0, `\uFFFD`; 4969 if (e3.lastNeed > 1 && t3.length > 1) { 4970 if ((t3[1] & 192) != 128) return e3.lastNeed = 1, `\uFFFD`; 4971 if (e3.lastNeed > 2 && t3.length > 2 && (t3[2] & 192) != 128) return e3.lastNeed = 2, `\uFFFD`; 4972 } 4973 } 4974 function l2(e3) { 4975 var t3 = this.lastTotal - this.lastNeed, n3 = c2(this, e3, t3); 4976 if (n3 !== void 0) return n3; 4977 if (this.lastNeed <= e3.length) return e3.copy(this.lastChar, t3, 0, this.lastNeed), this.lastChar.toString(this.encoding, 0, this.lastTotal); 4978 e3.copy(this.lastChar, t3, 0, e3.length), this.lastNeed -= e3.length; 4979 } 4980 function u2(e3, t3) { 4981 var n3 = s2(this, e3, t3); 4982 if (!this.lastNeed) return e3.toString(`utf8`, t3); 4983 this.lastTotal = n3; 4984 var r3 = e3.length - (n3 - this.lastNeed); 4985 return e3.copy(this.lastChar, 0, r3), e3.toString(`utf8`, t3, r3); 4986 } 4987 function d2(e3) { 4988 var t3 = e3 && e3.length ? this.write(e3) : ``; 4989 return this.lastNeed ? t3 + `\uFFFD` : t3; 4990 } 4991 function f2(e3, t3) { 4992 if ((e3.length - t3) % 2 == 0) { 4993 var n3 = e3.toString(`utf16le`, t3); 4994 if (n3) { 4995 var r3 = n3.charCodeAt(n3.length - 1); 4996 if (r3 >= 55296 && r3 <= 56319) return this.lastNeed = 2, this.lastTotal = 4, this.lastChar[0] = e3[e3.length - 2], this.lastChar[1] = e3[e3.length - 1], n3.slice(0, -1); 4997 } 4998 return n3; 4999 } 5000 return this.lastNeed = 1, this.lastTotal = 2, this.lastChar[0] = e3[e3.length - 1], e3.toString(`utf16le`, t3, e3.length - 1); 5001 } 5002 function p2(e3) { 5003 var t3 = e3 && e3.length ? this.write(e3) : ``; 5004 if (this.lastNeed) { 5005 var n3 = this.lastTotal - this.lastNeed; 5006 return t3 + this.lastChar.toString(`utf16le`, 0, n3); 5007 } 5008 return t3; 5009 } 5010 function m2(e3, t3) { 5011 var n3 = (e3.length - t3) % 3; 5012 return n3 === 0 ? e3.toString(`base64`, t3) : (this.lastNeed = 3 - n3, this.lastTotal = 3, n3 === 1 ? this.lastChar[0] = e3[e3.length - 1] : (this.lastChar[0] = e3[e3.length - 2], this.lastChar[1] = e3[e3.length - 1]), e3.toString(`base64`, t3, e3.length - n3)); 5013 } 5014 function h2(e3) { 5015 var t3 = e3 && e3.length ? this.write(e3) : ``; 5016 return this.lastNeed ? t3 + this.lastChar.toString(`base64`, 0, 3 - this.lastNeed) : t3; 5017 } 5018 function g2(e3) { 5019 return e3.toString(this.encoding); 5020 } 5021 function _2(e3) { 5022 return e3 && e3.length ? this.write(e3) : ``; 5023 } 5024})), er = i(((e2, t2) => { 5025 var n2 = qn().codes.ERR_STREAM_PREMATURE_CLOSE; 5026 function r2(e3) { 5027 var t3 = false;
5028 return function() { 5029 if (!t3) { 5030 t3 = true; 5031 var n3 = [...arguments]; 5032 e3.apply(this, n3); 5033 } 5034 }; 5035 } 5036 function i2() { 5037 } 5038 function a2(e3) { 5039 return e3.setHeader && typeof e3.abort == `function`; 5040 } 5041 function o2(e3, t3, s2) { 5042 if (typeof t3 == `function`) return o2(e3, null, t3); 5043 t3 || (t3 = {}), s2 = r2(s2 || i2); 5044 var c2 = t3.readable || t3.readable !== false && e3.readable, l2 = t3.writable || t3.writable !== false && e3.writable, u2 = function() { 5045 e3.writable || f2(); 5046 }, d2 = e3._writableState && e3._writableState.finished, f2 = function() { 5047 l2 = false, d2 = true, c2 || s2.call(e3); 5048 }, p2 = e3._readableState && e3._readableState.endEmitted, m2 = function() { 5049 c2 = false, p2 = true, l2 || s2.call(e3); 5050 }, h2 = function(t4) { 5051 s2.call(e3, t4); 5052 }, g2 = function() { 5053 var t4; 5054 if (c2 && !p2) return (!e3._readableState || !e3._readableState.ended) && (t4 = new n2()), s2.call(e3, t4); 5055 if (l2 && !d2) return (!e3._writableState || !e3._writableState.ended) && (t4 = new n2()), s2.call(e3, t4); 5056 }, _2 = function() { 5057 e3.req.on(`finish`, f2); 5058 }; 5059 return a2(e3) ? (e3.on(`complete`, f2), e3.on(`abort`, g2), e3.req ? _2() : e3.on(`request`, _2)) : l2 && !e3._writableState && (e3.on(`end`, u2), e3.on(`close`, u2)), e3.on(`end`, m2), e3.on(`finish`, f2), t3.error !== false && e3.on(`error`, h2), e3.on(`close`, g2), function() { 5060 e3.removeListener(`complete`, f2), e3.removeListener(`abort`, g2), e3.removeListener(`request`, _2), e3.req && e3.req.removeListener(`finish`, f2), e3.removeListener(`end`, u2), e3.removeListener(`close`, u2), e3.removeListener(`finish`, f2), e3.removeListener(`end`, m2), e3.removeListener(`error`, h2), e3.removeListener(`close`, g2); 5061 }; 5062 } 5063 t2.exports = o2; 5064})), tr = i(((e2, t2) => { 5065 u(); 5066 var n2; 5067 function r2(e3, t3, n3) { 5068 return t3 = i2(t3), t3 in e3 ? Object.defineProperty(e3, t3, { value: n3, enumerable: true, configurable: true, writable: true }) : e3[t3] = n3, e3; 5069 } 5070 function i2(e3) { 5071 var t3 = a2(e3, `string`); 5072 return typeof t3 == `symbol` ? t3 : String(t3); 5073 } 5074 function a2(e3, t3) { 5075 if (typeof e3 != `object` || !e3) return e3; 5076 var n3 = e3[Symbol.toPrimitive]; 5077 if (n3 !== void 0) { 5078 var r3 = n3.call(e3, t3 || `default`); 5079 if (typeof r3 != `object`) return r3; 5080 throw TypeError(`@@toPrimitive must return a primitive value.`); 5081 } 5082 return (t3 === `string` ? String : Number)(e3); 5083 } 5084 var o2 = er(), s2 = /* @__PURE__ */ Symbol(`lastResolve`), c2 = /* @__PURE__ */ Symbol(`lastReject`), d2 = /* @__PURE__ */ Symbol(`error`), f2 = /* @__PURE__ */ Symbol(`ended`), p2 = /* @__PURE__ */ Symbol(`lastPromise`), m2 = /* @__PURE__ */ Symbol(`handlePromise`), h2 = /* @__PURE__ */ Symbol(`stream`); 5085 function g2(e3, t3) { 5086 return { value: e3, done: t3 }; 5087 } 5088 function _2(e3) { 5089 var t3 = e3[s2]; 5090 if (t3 !== null) { 5091 var n3 = e3[h2].read(); 5092 n3 !== null && (e3[p2] = null, e3[s2] = null, e3[c2] = null, t3(g2(n3, false))); 5093 } 5094 } 5095 function v2(e3) { 5096 l.nextTick(_2, e3); 5097 } 5098 function y2(e3, t3) { 5099 return function(n3, r3) { 5100 e3.then(function() { 5101 if (t3[f2]) { 5102 n3(g2(void 0, true)); 5103 return; 5104 } 5105 t3[m2](n3, r3); 5106 }, r3); 5107 }; 5108 } 5109 var b2 = Object.getPrototypeOf(function() { 5110 }), x2 = Object.setPrototypeOf((n2 = { get stream() { 5111 return this[h2]; 5112 }, next: function() { 5113 var e3 = this, t3 = this[d2]; 5114 if (t3 !== null) return Promise.reject(t3); 5115 if (this[f2]) return Promise.resolve(g2(void 0, true)); 5116 if (this[h2].destroyed) return new Promise(function(t4, n4) { 5117 l.nextTick(function() { 5118 e3[d2] ? n4(e3[d2]) : t4(g2(void 0, true)); 5119 }); 5120 }); 5121 var n3 = this[p2], r3; 5122 if (n3) r3 = new Promise(y2(n3, this)); 5123 else { 5124 var i3 = this[h2].read(); 5125 if (i3 !== null) return Promise.resolve(g2(i3, false)); 5126 r3 = new Promise(this[m2]); 5127 } 5128 return this[p2] = r3, r3; 5129 } }, r2(n2, Symbol.asyncIterator, function() { 5130 return this; 5131 }), r2(n2, `return`, function() { 5132 var e3 = this; 5133 return new Promise(function(t3, n3) { 5134 e3[h2].destroy(null, function(e4) { 5135 if (e4) { 5136 n3(e4); 5137 return; 5138 } 5139 t3(g2(void 0, true)); 5140 }); 5141 }); 5142 }), n2), b2); 5143 t2.exports = function(e3) { 5144 var t3, n3 = Object.create(x2, (t3 = {}, r2(t3, h2, { value: e3, writable: true }), r2(t3, s2, { value: null, writable: true }), r2(t3, c2, { value: null, writable: true }), r2(t3, d2, { value: null, writable: true }), r2(t3, f2, { value: e3._readableState.endEmitted, writable: true }), r2(t3, m2, { value: function(e4, t4) { 5145 var r3 = n3[h2].read(); 5146 r3 ? (n3[p2] = null, n3[s2] = null, n3[c2] = null, e4(g2(r3, false))) : (n3[s2] = e4, n3[c2] = t4); 5147 }, writable: true }), t3)); 5148 return n3[p2] = null, o2(e3, function(e4) { 5149 if (e4 && e4.code !== `ERR_STREAM_PREMATURE_CLOSE`) { 5150 var t4 = n3[c2]; 5151 t4 !== null && (n3[p2] = null, n3[s2] = null, n3[c2] = null, t4(e4)), n3[d2] = e4; 5152 return; 5153 } 5154 var r3 = n3[s2]; 5155 r3 !== null && (n3[p2] = null, n3[s2] = null, n3[c2] = null, r3(g2(void 0, true))), n3[f2] = true; 5156 }), e3.on(`readable`, v2.bind(null, n3)), n3; 5157 }; 5158})), nr = i(((e2, t2) => { 5159 t2.exports = function() { 5160 throw Error(`Readable.from is not available in the browser`); 5161 }; 5162})), rr = i(((e2, t2) => { 5163 a(), u(), t2.exports = A2; 5164 var n2; 5165 A2.ReadableState = k2, Sn().EventEmitter; 5166 var r2 = function(e3, t3) { 5167 return e3.listeners(t3).length; 5168 }, i2 = wn(), s2 = re().Buffer, c2 = (o === void 0 ? typeof window < `u` ? window : typeof self < `u` ? self : {} : o).Uint8Array || function() { 5169 }; 5170 function d2(e3) { 5171 return s2.from(e3); 5172 } 5173 function f2(e3) { 5174 return s2.isBuffer(e3) || e3 instanceof c2; 5175 } 5176 var p2 = Wn(), m2 = p2 && p2.debuglog ? p2.debuglog(`stream`) : function() { 5177 }, h2 = Gn(), g2 = Kn(), _2 = Jn().getHighWaterMark, v2 = qn().codes, y2 = v2.ERR_INVALID_ARG_TYPE, b2 = v2.ERR_STREAM_PUSH_AFTER_EOF, x2 = v2.ERR_METHOD_NOT_IMPLEMENT
5177ED, S2 = v2.ERR_STREAM_UNSHIFT_AFTER_END_EVENT, C2, w2, T2; 5178 Cn()(A2, i2); 5179 var E2 = g2.errorOrDestroy, D2 = [`error`, `close`, `destroy`, `pause`, `resume`]; 5180 function O2(e3, t3, n3) { 5181 if (typeof e3.prependListener == `function`) return e3.prependListener(t3, n3); 5182 !e3._events || !e3._events[t3] ? e3.on(t3, n3) : Array.isArray(e3._events[t3]) ? e3._events[t3].unshift(n3) : e3._events[t3] = [n3, e3._events[t3]]; 5183 } 5184 function k2(e3, t3, r3) { 5185 n2 || (n2 = Zn()), e3 || (e3 = {}), typeof r3 != `boolean` && (r3 = t3 instanceof n2), this.objectMode = !!e3.objectMode, r3 && (this.objectMode = this.objectMode || !!e3.readableObjectMode), this.highWaterMark = _2(this, e3, `readableHighWaterMark`, r3), this.buffer = new h2(), this.length = 0, this.pipes = null, this.pipesCount = 0, this.flowing = null, this.ended = false, this.endEmitted = false, this.reading = false, this.sync = true, this.needReadable = false, this.emittedReadable = false, this.readableListening = false, this.resumeScheduled = false, this.paused = true, this.emitClose = e3.emitClose !== false, this.autoDestroy = !!e3.autoDestroy, this.destroyed = false, this.defaultEncoding = e3.defaultEncoding || `utf8`, this.awaitDrain = 0, this.readingMore = false, this.decoder = null, this.encoding = null, e3.encoding && (C2 || (C2 = $n().StringDecoder), this.decoder = new C2(e3.encoding), this.encoding = e3.encoding); 5186 } 5187 function A2(e3) { 5188 if (n2 || (n2 = Zn()), !(this instanceof A2)) return new A2(e3); 5189 var t3 = this instanceof n2; 5190 this._readableState = new k2(e3, this, t3), this.readable = true, e3 && (typeof e3.read == `function` && (this._read = e3.read), typeof e3.destroy == `function` && (this._destroy = e3.destroy)), i2.call(this); 5191 } 5192 Object.defineProperty(A2.prototype, `destroyed`, { enumerable: false, get: function() { 5193 return this._readableState === void 0 ? false : this._readableState.destroyed; 5194 }, set: function(e3) { 5195 this._readableState && (this._readableState.destroyed = e3); 5196 } }), A2.prototype.destroy = g2.destroy, A2.prototype._undestroy = g2.undestroy, A2.prototype._destroy = function(e3, t3) { 5197 t3(e3); 5198 }, A2.prototype.push = function(e3, t3) { 5199 var n3 = this._readableState, r3; 5200 return n3.objectMode ? r3 = true : typeof e3 == `string` && (t3 || (t3 = n3.defaultEncoding), t3 !== n3.encoding && (e3 = s2.from(e3, t3), t3 = ``), r3 = true), j2(this, e3, t3, false, r3); 5201 }, A2.prototype.unshift = function(e3) { 5202 return j2(this, e3, null, true, false); 5203 }; 5204 function j2(e3, t3, n3, r3, i3) { 5205 m2(`readableAddChunk`, t3); 5206 var a2 = e3._readableState; 5207 if (t3 === null) a2.reading = false, L2(e3, a2); 5208 else { 5209 var o2; 5210 if (i3 || (o2 = N2(a2, t3)), o2) E2(e3, o2); 5211 else if (a2.objectMode || t3 && t3.length > 0) if (typeof t3 != `string` && !a2.objectMode && Object.getPrototypeOf(t3) !== s2.prototype && (t3 = d2(t3)), r3) a2.endEmitted ? E2(e3, new S2()) : M2(e3, a2, t3, true); 5212 else if (a2.ended) E2(e3, new b2()); 5213 else if (a2.destroyed) return false; 5214 else a2.reading = false, a2.decoder && !n3 ? (t3 = a2.decoder.write(t3), a2.objectMode || t3.length !== 0 ? M2(e3, a2, t3, false) : B2(e3, a2)) : M2(e3, a2, t3, false); 5215 else r3 || (a2.reading = false, B2(e3, a2)); 5216 } 5217 return !a2.ended && (a2.length < a2.highWaterMark || a2.length === 0); 5218 } 5219 function M2(e3, t3, n3, r3) { 5220 t3.flowing && t3.length === 0 && !t3.sync ? (t3.awaitDrain = 0, e3.emit(`data`, n3)) : (t3.length += t3.objectMode ? 1 : n3.length, r3 ? t3.buffer.unshift(n3) : t3.buffer.push(n3), t3.needReadable && R2(e3)), B2(e3, t3); 5221 } 5222 function N2(e3, t3) { 5223 var n3; 5224 return !f2(t3) && typeof t3 != `string` && t3 !== void 0 && !e3.objectMode && (n3 = new y2(`chunk`, [`string`, `Buffer`, `Uint8Array`], t3)), n3; 5225 } 5226 A2.prototype.isPaused = function() { 5227 return this._readableState.flowing === false; 5228 }, A2.prototype.setEncoding = function(e3) { 5229 C2 || (C2 = $n().StringDecoder); 5230 var t3 = new C2(e3); 5231 this._readableState.decoder = t3, this._readableState.encoding = this._readableState.decoder.encoding; 5232 for (var n3 = this._readableState.buffer.head, r3 = ``; n3 !== null; ) r3 += t3.write(n3.data), n3 = n3.next; 5233 return this._readableState.buffer.clear(), r3 !== `` && this._readableState.buffer.push(r3), this._readableState.length = r3.length, this; 5234 }; 5235 var P2 = 1073741824; 5236 function F2(e3) { 5237 return e3 >= P2 ? e3 = P2 : (e3--, e3 |= e3 >>> 1, e3 |= e3 >>> 2, e3 |= e3 >>> 4, e3 |= e3 >>> 8, e3 |= e3 >>> 16, e3++), e3; 5238 } 5239 function I2(e3, t3) { 5240 return e3 <= 0 || t3.length === 0 && t3.ended ? 0 : t3.objectMode ? 1 : e3 === e3 ? (e3 > t3.highWaterMark && (t3.highWaterMark = F2(e3)), e3 <= t3.length ? e3 : t3.ended ? t3.length : (t3.needReadable = true, 0)) : t3.flowing && t3.length ? t3.buffer.head.data.length : t3.length; 5241 } 5242 A2.prototype.read = function(e3) { 5243 m2(`read`, e3), e3 = parseInt(e3, 10); 5244 var t3 = this._readableState, n3 = e3; 5245 if (e3 !== 0 && (t3.emittedReadable = false), e3 === 0 && t3.needReadable && ((t3.highWaterMark === 0 ? t3.length > 0 : t3.length >= t3.highWaterMark) || t3.ended)) return m2(`read: emitReadable`, t3.length, t3.ended), t3.length === 0 && t3.ended ? q2(this) : R2(this), null; 5246 if (e3 = I2(e3, t3), e3 === 0 && t3.ended) return t3.length === 0 && q2(this), null; 5247 var r3 = t3.needReadable; 5248 m2(`need readable`, r3), (t3.length === 0 || t3.length - e3 < t3.highWaterMark) && (r3 = true, m2(`length less than watermark`, r3)), t3.ended || t3.reading ? (r3 = false, m2(`reading or ended`, r3)) : r3 && (m2(`do read`), t3.reading = true, t3.sync = true, t3.length === 0 && (t3.needReadable = true), this._read(t3.highWaterMark), t3.sync = false, t3.reading || (e3 = I2(n3, t3))); 5249 var i3 = e3 > 0 ? te2(e3, t3) : null; 5250 return i3 === null ? (t3.needReadable = t3.length <= t3.highWaterMark, e3 = 0) : (t3.length -= e3, t3.awaitDrain = 0), t3.length === 0 && (t3.ended || (t3.needReadable = true), n3 !== e3 && t3.ended && q2(this)), i3 !== null && this.emit
5250(`data`, i3), i3; 5251 }; 5252 function L2(e3, t3) { 5253 if (m2(`onEofChunk`), !t3.ended) { 5254 if (t3.decoder) { 5255 var n3 = t3.decoder.end(); 5256 n3 && n3.length && (t3.buffer.push(n3), t3.length += t3.objectMode ? 1 : n3.length); 5257 } 5258 t3.ended = true, t3.sync ? R2(e3) : (t3.needReadable = false, t3.emittedReadable || (t3.emittedReadable = true, z2(e3))); 5259 } 5260 } 5261 function R2(e3) { 5262 var t3 = e3._readableState; 5263 m2(`emitReadable`, t3.needReadable, t3.emittedReadable), t3.needReadable = false, t3.emittedReadable || (m2(`emitReadable`, t3.flowing), t3.emittedReadable = true, l.nextTick(z2, e3)); 5264 } 5265 function z2(e3) { 5266 var t3 = e3._readableState; 5267 m2(`emitReadable_`, t3.destroyed, t3.length, t3.ended), !t3.destroyed && (t3.length || t3.ended) && (e3.emit(`readable`), t3.emittedReadable = false), t3.needReadable = !t3.flowing && !t3.ended && t3.length <= t3.highWaterMark, K2(e3); 5268 } 5269 function B2(e3, t3) { 5270 t3.readingMore || (t3.readingMore = true, l.nextTick(V2, e3, t3)); 5271 } 5272 function V2(e3, t3) { 5273 for (; !t3.reading && !t3.ended && (t3.length < t3.highWaterMark || t3.flowing && t3.length === 0); ) { 5274 var n3 = t3.length; 5275 if (m2(`maybeReadMore read 0`), e3.read(0), n3 === t3.length) break; 5276 } 5277 t3.readingMore = false; 5278 } 5279 A2.prototype._read = function(e3) { 5280 E2(this, new x2(`_read()`)); 5281 }, A2.prototype.pipe = function(e3, t3) { 5282 var n3 = this, i3 = this._readableState; 5283 switch (i3.pipesCount) { 5284 case 0: 5285 i3.pipes = e3; 5286 break; 5287 case 1: 5288 i3.pipes = [i3.pipes, e3]; 5289 break; 5290 default: 5291 i3.pipes.push(e3); 5292 break; 5293 } 5294 i3.pipesCount += 1, m2(`pipe count=%d opts=%j`, i3.pipesCount, t3); 5295 var a2 = (!t3 || t3.end !== false) && e3 !== l.stdout && e3 !== l.stderr ? s3 : _3; 5296 i3.endEmitted ? l.nextTick(a2) : n3.once(`end`, a2), e3.on(`unpipe`, o2); 5297 function o2(e4, t4) { 5298 m2(`onunpipe`), e4 === n3 && t4 && t4.hasUnpiped === false && (t4.hasUnpiped = true, d3()); 5299 } 5300 function s3() { 5301 m2(`onend`), e3.end(); 5302 } 5303 var c3 = H2(n3); 5304 e3.on(`drain`, c3); 5305 var u2 = false; 5306 function d3() { 5307 m2(`cleanup`), e3.removeListener(`close`, h3), e3.removeListener(`finish`, g3), e3.removeListener(`drain`, c3), e3.removeListener(`error`, p3), e3.removeListener(`unpipe`, o2), n3.removeListener(`end`, s3), n3.removeListener(`end`, _3), n3.removeListener(`data`, f3), u2 = true, i3.awaitDrain && (!e3._writableState || e3._writableState.needDrain) && c3(); 5308 } 5309 n3.on(`data`, f3); 5310 function f3(t4) { 5311 m2(`ondata`); 5312 var r3 = e3.write(t4); 5313 m2(`dest.write`, r3), r3 === false && ((i3.pipesCount === 1 && i3.pipes === e3 || i3.pipesCount > 1 && Y2(i3.pipes, e3) !== -1) && !u2 && (m2(`false write response, pause`, i3.awaitDrain), i3.awaitDrain++), n3.pause()); 5314 } 5315 function p3(t4) { 5316 m2(`onerror`, t4), _3(), e3.removeListener(`error`, p3), r2(e3, `error`) === 0 && E2(e3, t4); 5317 } 5318 O2(e3, `error`, p3); 5319 function h3() { 5320 e3.removeListener(`finish`, g3), _3(); 5321 } 5322 e3.once(`close`, h3); 5323 function g3() { 5324 m2(`onfinish`), e3.removeListener(`close`, h3), _3(); 5325 } 5326 e3.once(`finish`, g3); 5327 function _3() { 5328 m2(`unpipe`), n3.unpipe(e3); 5329 } 5330 return e3.emit(`pipe`, n3), i3.flowing || (m2(`pipe resume`), n3.resume()), e3; 5331 }; 5332 function H2(e3) { 5333 return function() { 5334 var t3 = e3._readableState; 5335 m2(`pipeOnDrain`, t3.awaitDrain), t3.awaitDrain && t3.awaitDrain--, t3.awaitDrain === 0 && r2(e3, `data`) && (t3.flowing = true, K2(e3)); 5336 }; 5337 } 5338 A2.prototype.unpipe = function(e3) { 5339 var t3 = this._readableState, n3 = { hasUnpiped: false }; 5340 if (t3.pipesCount === 0) return this; 5341 if (t3.pipesCount === 1) return e3 && e3 !== t3.pipes ? this : (e3 || (e3 = t3.pipes), t3.pipes = null, t3.pipesCount = 0, t3.flowing = false, e3 && e3.emit(`unpipe`, this, n3), this); 5342 if (!e3) { 5343 var r3 = t3.pipes, i3 = t3.pipesCount; 5344 t3.pipes = null, t3.pipesCount = 0, t3.flowing = false; 5345 for (var a2 = 0; a2 < i3;
5345 a2++) r3[a2].emit(`unpipe`, this, { hasUnpiped: false }); 5346 return this; 5347 } 5348 var o2 = Y2(t3.pipes, e3); 5349 return o2 === -1 ? this : (t3.pipes.splice(o2, 1), --t3.pipesCount, t3.pipesCount === 1 && (t3.pipes = t3.pipes[0]), e3.emit(`unpipe`, this, n3), this); 5350 }, A2.prototype.on = function(e3, t3) { 5351 var n3 = i2.prototype.on.call(this, e3, t3), r3 = this._readableState; 5352 return e3 === `data` ? (r3.readableListening = this.listenerCount(`readable`) > 0, r3.flowing !== false && this.resume()) : e3 === `readable` && !r3.endEmitted && !r3.readableListening && (r3.readableListening = r3.needReadable = true, r3.flowing = false, r3.emittedReadable = false, m2(`on readable`, r3.length, r3.reading), r3.length ? R2(this) : r3.reading || l.nextTick(W2, this)), n3; 5353 }, A2.prototype.addListener = A2.prototype.on, A2.prototype.removeListener = function(e3, t3) { 5354 var n3 = i2.prototype.removeListener.call(this, e3, t3); 5355 return e3 === `readable` && l.nextTick(U2, this), n3; 5356 }, A2.prototype.removeAllListeners = function(e3) { 5357 var t3 = i2.prototype.removeAllListeners.apply(this, arguments); 5358 return (e3 === `readable` || e3 === void 0) && l.nextTick(U2, this), t3; 5359 }; 5360 function U2(e3) { 5361 var t3 = e3._readableState; 5362 t3.readableListening = e3.listenerCount(`readable`) > 0, t3.resumeScheduled && !t3.paused ? t3.flowing = true : e3.listenerCount(`data`) > 0 && e3.resume(); 5363 } 5364 function W2(e3) { 5365 m2(`readable nexttick read 0`), e3.read(0); 5366 } 5367 A2.prototype.resume = function() { 5368 var e3 = this._readableState; 5369 return e3.flowing || (m2(`resume`), e3.flowing = !e3.readableListening, G2(this, e3)), e3.paused = false, this; 5370 }; 5371 function G2(e3, t3) { 5372 t3.resumeScheduled || (t3.resumeScheduled = true, l.nextTick(ee2, e3, t3)); 5373 } 5374 function ee2(e3, t3) { 5375 m2(`resume`, t3.reading), t3.reading || e3.read(0), t3.resumeScheduled = false, e3.emit(`resume`), K2(e3), t3.flowing && !t3.reading && e3.read(0); 5376 } 5377 A2.prototype.pause = function() { 5378 return m2(`call pause flowing=%j`, this._readableState.flowing), this._readableState.flowing !== false && (m2(`pause`), this._readableState.flowing = false, this.emit(`pause`)), this._readableState.paused = true, this; 5379 }; 5380 function K2(e3) { 5381 var t3 = e3._readableState; 5382 for (m2(`flow`, t3.flowing); t3.flowing && e3.read() !== null; ) ; 5383 } 5384 A2.prototype.wrap = function(e3) { 5385 var t3 = this, n3 = this._readableState, r3 = false; 5386 for (var i3 in e3.on(`end`, function() { 5387 if (m2(`wrapped end`), n3.decoder && !n3.ended) { 5388 var e4 = n3.decoder.end(); 5389 e4 && e4.length && t3.push(e4); 5390 } 5391 t3.push(null); 5392 }), e3.on(`data`, function(i4) { 5393 m2(`wrapped data`), n3.decoder && (i4 = n3.decoder.write(i4)), !(n3.objectMode && i4 == null) && (!n3.objectMode && (!i4 || !i4.length) || t3.push(i4) || (r3 = true, e3.pause())); 5394 }), e3) this[i3] === void 0 && typeof e3[i3] == `function` && (this[i3] = /* @__PURE__ */ (function(t4) { 5395 return function() { 5396 return e3[t4].apply(e3, arguments); 5397 }; 5398 })(i3)); 5399 for (var a2 = 0; a2 < D2.length; a2++) e3.on(D2[a2], this.emit.bind(this, D2[a2])); 5400 return this._read = function(t4) { 5401 m2(`wrapped _read`, t4), r3 && (r3 = false, e3.resume()); 5402 }, this; 5403 }, typeof Symbol == `function` && (A2.prototype[Symbol.asyncIterator] = function() { 5404 return w2 === void 0 && (w2 = tr()), w2(this); 5405 }), Object.defineProperty(A2.prototype, `readableHighWaterMark`, { enumerable: false, get: function() { 5406 return this._readableState.highWaterMark; 5407 } }), Object.defineProperty(A2.prototype, `readableBuffer`, { enumerable: false, get: function() { 5408 return this._readableState && this._readableState.buffer; 5409 } }), Object.defineProperty(A2.prototype, `readableFlowing`, { enumerable: false, get: function() { 5410 return this._readableState.flowing; 5411 }, set: function(e3) { 5412 this._readableState && (this._readableState.flowing = e3); 5413 } }), A2._fromList = te2, Object.defineProperty(A2.prototype, `readableLength`, { enumerable: false, get: function() { 5414 return this._readableState.length; 5415 } }); 5416 function te2(e3, t3) { 5417 if (t3.length === 0) return null; 5418 var n3; 5419 return t3.objectMode ? n3 = t3.buffer.shift() : !e3 || e3 >= t3.length ? (n3 = t3.decoder ? t3.buffer.join(``) : t3.buffer.length === 1 ? t3.buffer.first() : t3.buffer.concat(t3.length), t3.buffer.clear()) : n3 = t3.buffer.consume(e3, t3.decoder), n3; 5420 } 5421 function q2(e3) { 5422 var t3 = e3._readableState; 5423 m2(`endReadable`, t3.endEmitted), t3.endEmitted || (t3.ended = true, l.nextTick(J2, t3, e3)); 5424 } 5425 function J2(e3, t3) { 5426 if (m2(`endReadableNT`, e3.endEmitted, e3.length), !e3.endEmitted && e3.length === 0 && (e3.endEmitted = true, t3.readable = false, t3.emit(`end`), e3.autoDestroy)) { 5427 var n3 = t3._writableState; 5428 (!n3 || n3.autoDestroy && n3.finished) && t3.destroy(); 5429 } 5430 } 5431 typeof Symbol == `function` && (A2.from = function(e3, t3) { 5432 return T2 === void 0 && (T2 = nr()), T2(A2, e3, t3); 5433 }); 5434 function Y2(e3, t3) { 5435 for (var n3 = 0, r3 = e3.length; n3 < r3; n3++) if (e3[n3] === t3) return n3; 5436 return -1; 5437 } 5438})), ir = i(((e2, t2) => { 5439 t2.exports = l2;
5440 var n2 = qn().codes, r2 = n2.ERR_METHOD_NOT_IMPLEMENTED, i2 = n2.ERR_MULTIPLE_CALLBACK, a2 = n2.ERR_TRANSFORM_ALREADY_TRANSFORMING, o2 = n2.ERR_TRANSFORM_WITH_LENGTH_0, s2 = Zn(); 5441 Cn()(l2, s2); 5442 function c2(e3, t3) { 5443 var n3 = this._transformState; 5444 n3.transforming = false; 5445 var r3 = n3.writecb; 5446 if (r3 === null) return this.emit(`error`, new i2()); 5447 n3.writechunk = null, n3.writecb = null, t3 != null && this.push(t3), r3(e3); 5448 var a3 = this._readableState; 5449 a3.reading = false, (a3.needReadable || a3.length < a3.highWaterMark) && this._read(a3.highWaterMark); 5450 } 5451 function l2(e3) { 5452 if (!(this instanceof l2)) return new l2(e3); 5453 s2.call(this, e3), this._transformState = { afterTransform: c2.bind(this), needTransform: false, transforming: false, writecb: null, writechunk: null, writeencoding: null }, this._readableState.needReadable = true, this._readableState.sync = false, e3 && (typeof e3.transform == `function` && (this._transform = e3.transform), typeof e3.flush == `function` && (this._flush = e3.flush)), this.on(`prefinish`, u2); 5454 } 5455 function u2() { 5456 var e3 = this; 5457 typeof this._flush == `function` && !this._readableState.destroyed ? this._flush(function(t3, n3) { 5458 d2(e3, t3, n3); 5459 }) : d2(this, null, null); 5460 } 5461 l2.prototype.push = function(e3, t3) { 5462 return this._transformState.needTransform = false, s2.prototype.push.call(this, e3, t3); 5463 }, l2.prototype._transform = function(e3, t3, n3) { 5464 n3(new r2(`_transform()`)); 5465 }, l2.prototype._write = function(e3, t3, n3) { 5466 var r3 = this._transformState; 5467 if (r3.writecb = n3, r3.writechunk = e3, r3.writeencoding = t3, !r3.transforming) { 5468 var i3 = this._readableState; 5469 (r3.needTransform || i3.needReadable || i3.length < i3.highWaterMark) && this._read(i3.highWaterMark); 5470 } 5471 }, l2.prototype._read = function(e3) { 5472 var t3 = this._transformState; 5473 t3.writechunk !== null && !t3.transforming ? (t3.transforming = true, this._transform(t3.writechunk, t3.writeencoding, t3.afterTransform)) : t3.needTransform = true; 5474 }, l2.prototype._destroy = function(e3, t3) { 5475 s2.prototype._destroy.call(this, e3, function(e4) { 5476 t3(e4); 5477 }); 5478 }; 5479 function d2(e3, t3, n3) { 5480 if (t3) return e3.emit(`error`, t3); 5481 if (n3 != null && e3.push(n3), e3._writableState.length) throw new o2(); 5482 if (e3._transformState.transforming) throw new a2(); 5483 return e3.push(null); 5484 } 5485})), ar = i(((e2, t2) => { 5486 t2.exports = r2; 5487 var n2 = ir(); 5488 Cn()(r2, n2); 5489 function r2(e3) { 5490 if (!(this instanceof r2)) return new r2(e3); 5491 n2.call(this, e3); 5492 } 5493 r2.prototype._transform = function(e3, t3, n3) { 5494 n3(null, e3); 5495 }; 5496})), or = i(((e2, t2) => { 5497 var n2; 5498 function r2(e3) { 5499 var t3 = false; 5500 return function() { 5501 t3 || (t3 = true, e3.apply(void 0, arguments)); 5502 }; 5503 } 5504 var i2 = qn().codes, a2 = i2.ERR_MISSING_ARGS, o2 = i2.ERR_STREAM_DESTROYED; 5505 function s2(e3) { 5506 if (e3) throw e3; 5507 } 5508 function c2(e3) { 5509 return e3.setHeader && typeof e3.abort == `function`; 5510 } 5511 function l2(e3, t3, i3, a3) { 5512 a3 = r2(a3); 5513 var s3 = false;
5514 e3.on(`close`, function() { 5515 s3 = true; 5516 }), n2 === void 0 && (n2 = er()), n2(e3, { readable: t3, writable: i3 }, function(e4) { 5517 if (e4) return a3(e4); 5518 s3 = true, a3(); 5519 }); 5520 var l3 = false; 5521 return function(t4) { 5522 if (!s3 && !l3) { 5523 if (l3 = true, c2(e3)) return e3.abort(); 5524 if (typeof e3.destroy == `function`) return e3.destroy(); 5525 a3(t4 || new o2(`pipe`)); 5526 } 5527 }; 5528 } 5529 function u2(e3) { 5530 e3(); 5531 } 5532 function d2(e3, t3) { 5533 return e3.pipe(t3); 5534 } 5535 function f2(e3) { 5536 return !e3.length || typeof e3[e3.length - 1] != `function` ? s2 : e3.pop(); 5537 } 5538 function p2() { 5539 var e3 = [...arguments], t3 = f2(e3); 5540 if (Array.isArray(e3[0]) && (e3 = e3[0]), e3.length < 2) throw new a2(`streams`); 5541 var n3, r3 = e3.map(function(i3, a3) { 5542 var o3 = a3 < e3.length - 1; 5543 return l2(i3, o3, a3 > 0, function(e4) { 5544 n3 || (n3 = e4), e4 && r3.forEach(u2), !o3 && (r3.forEach(u2), t3(n3)); 5545 }); 5546 }); 5547 return e3.reduce(d2); 5548 } 5549 t2.exports = p2; 5550})), sr = i(((e2, t2) => { 5551 t2.exports = r2; 5552 var n2 = Sn().EventEmitter; 5553 Cn()(r2, n2), r2.Readable = rr(), r2.Writable = Xn(), r2.Duplex = Zn(), r2.Transform = ir(), r2.PassThrough = ar(), r2.finished = er(), r2.pipeline = or(), r2.Stream = r2; 5554 function r2() { 5555 n2.call(this); 5556 } 5557 r2.prototype.pipe = function(e3, t3) { 5558 var r3 = this; 5559 function i2(t4) { 5560 e3.writable && false === e3.write(t4) && r3.pause && r3.pause(); 5561 } 5562 r3.on(`data`, i2); 5563 function a2() { 5564 r3.readable && r3.resume && r3.resume(); 5565 } 5566 e3.on(`drain`, a2), !e3._isStdio && (!t3 || t3.end !== false) && (r3.on(`end`, s2), r3.on(`close`, c2)); 5567 var o2 = false; 5568 function s2() { 5569 o2 || (o2 = true, e3.end()); 5570 } 5571 function c2() { 5572 o2 || (o2 = true, typeof e3.destroy == `function` && e3.destroy()); 5573 } 5574 function l2(e4) { 5575 if (u2(), n2.listenerCount(this, `error`) === 0) throw e4; 5576 } 5577 r3.on(`error`, l2), e3.on(`error`, l2); 5578 function u2() { 5579 r3.removeListener(`data`, i2), e3.removeListener(`drain`, a2), r3.removeListener(`end`, s2), r3.removeListener(`close`, c2), r3.removeListener(`error`, l2), e3.removeListener(`error`, l2), r3.removeListener(`end`, u2), r3.removeListener(`close`, u2), e3.removeListener(`close`, u2); 5580 } 5581 return r3.on(`end`, u2), r3.on(`close`, u2), e3.on(`close`, u2), e3.emit(`pipe`, r3), e3; 5582 }; 5583})), cr = i(((e2) => { 5584 Object.defineProperty(e2, `__esModule`, { value: true }), e2.Writable = e2.Readable = void 0; 5585 var t2 = sr(); 5586 Object.defineProperty(e2, `Readable`, { enumerable: true, get: function() { 5587 return t2.Readable; 5588 } }), Object.defineProperty(e2, `Writable`, { enumerable: true, get: function() { 5589 return t2.Writable; 5590 } }); 5591})), lr = i(((e2) => { 5592 Object.defineProperty(e2, `__esModule`, { value: true }), e2.EventEmitter = void 0; 5593 var t2 = Sn(); 5594 Object.defineProperty(e2, `EventEmitter`, { enumerable: true, get: function() { 5595 return t2.EventEmitter; 5596 } }); 5597})), ur = i(((t2) => { 5598 u(), Object.defineProperty(t2, `__esModule`, { value: true }), t2.getWriteSyncArgs = t2.getWriteArgs = t2.bufToUint8 = void 0, t2.promisify = o2, t2.validateCallback = s2, t2.modeToNumber = d2, t2.nullCheck = f2, t2.pathToFilename = m2, t2.createError = A2, t2.createStatError = j2, t2.genRndStr6 = M2, t2.flagsToNumber = N2, t2.streamToBuffer = P2, t2.bufferToEncoding = F2, t2.isReadableStream = I2; 5599 var n2 = $(), r2 = he(), i2 = Z(), a2 = _n(); 5600 function o2(e2, t3, n3 = (e3) => e3) { 5601 return (...r3) => new Promise((i3, a3) => { 5602 e2[t3].bind(e2)(...r3, (e3, t4) => e3 ? a3(e3) : i3(n3(t4))); 5603 }); 5604 } 5605 function s2(e2) { 5606 if (typeof e2 != `function`) throw TypeError(n2.ERRSTR.CB); 5607 return e2; 5608 } 5609 function c2(e2, t3) { 5610 if (typeof e2 == `number`) return e2; 5611 if (typeof e2 == `string`) return parseInt(e2, 8); 5612 if (t3) return d2(t3); 5613 } 5614 function d2(e2, t3) { 5615 let r3 = c2(e2, t3); 5616 if (typeof r3 != `number` || isNaN(r3)) throw TypeError(n2.ERRSTR.MODE_INT); 5617 return r3; 5618 } 5619 function f2(e2, t3) { 5620 if ((`` + e2).indexOf(`\0`) !== -1) { 5621 let e3 = Error(`Path must be a string without null bytes`); 5622 if (e3.code = `ENOENT`, typeof t3 != `function`) throw e3; 5623 return queueMicrotask(() => { 5624 t3(e3); 5625 }), false; 5626 } 5627 return true; 5628 } 5629 function p2(e2) { 5630 if (e2.hostname !== ``) throw new r2.TypeError(`ERR_INVALID_FILE_URL_HOST`, l.platform); 5631 let t3 = e2.pathname; 5632 for (let e3 = 0; e3 < t3.length; e3++) if (t3[e3] === `%`) { 5633 let n3 = t3.codePointAt(e3 + 2) | 32; 5634 if (t3[e3 + 1] === `2` && n3 === 102) throw new r2.TypeError(`ERR_INVALID_FILE_URL_PATH`, `must not include encoded / characters`); 5635 } 5636 return decodeURIComponent(t3); 5637 } 5638 function m2(t3) { 5639 if (t3 instanceof Uint8Array && (t3 = (0, i2.bufferFrom)(t3)), typeof t3 != `string` && !i2.Buffer.isBuffer(t3)) {
5640 try { 5641 if (!(t3 instanceof (mn(), e(mt)).URL)) throw TypeError(n2.ERRSTR.PATH_STR); 5642 } catch { 5643 throw TypeError(n2.ERRSTR.PATH_STR); 5644 } 5645 t3 = p2(t3); 5646 } 5647 let r3 = String(t3); 5648 return f2(r3), r3; 5649 } 5650 var h2 = `ENOENT`, g2 = `EBADF`, _2 = `EINVAL`, v2 = `EPERM`, y2 = `EPROTO`, b2 = `EEXIST`, x2 = `ENOTDIR`, S2 = `EMFILE`, C2 = `EACCES`, w2 = `EISDIR`, T2 = `ENOTEMPTY`, E2 = `ENOSYS`, D2 = `ERR_FS_EISDIR`, O2 = `ERR_OUT_OF_RANGE`; 5651 function k2(e2, t3 = ``, n3 = ``, r3 = ``) { 5652 let i3 = ``; 5653 switch (n3 && (i3 = ` '${n3}'`), r3 && (i3 += ` -> '${r3}'`), e2) { 5654 case h2: 5655 return `ENOENT: no such file or directory, ${t3}${i3}`; 5656 case g2: 5657 return `EBADF: bad file descriptor, ${t3}${i3}`; 5658 case _2: 5659 return `EINVAL: invalid argument, ${t3}${i3}`; 5660 case v2: 5661 return `EPERM: operation not permitted, ${t3}${i3}`; 5662 case y2: 5663 return `EPROTO: protocol error, ${t3}${i3}`; 5664 case b2: 5665 return `EEXIST: file already exists, ${t3}${i3}`; 5666 case x2: 5667 return `ENOTDIR: not a directory, ${t3}${i3}`; 5668 case w2: 5669 return `EISDIR: illegal operation on a directory, ${t3}${i3}`; 5670 case C2: 5671 return `EACCES: permission denied, ${t3}${i3}`; 5672 case T2: 5673 return `ENOTEMPTY: directory not empty, ${t3}${i3}`; 5674 case S2: 5675 return `EMFILE: too many open files, ${t3}${i3}`; 5676 case E2: 5677 return `ENOSYS: function not implemented, ${t3}${i3}`; 5678 case D2: 5679 return `[ERR_FS_EISDIR]: Path is a directory: ${t3} returned EISDIR (is a directory) ${n3}`; 5680 case O2: 5681 return `[ERR_OUT_OF_RANGE]: value out of range, ${t3}${i3}`; 5682 default: 5683 return `${e2}: error occurred, ${t3}${i3}`; 5684 } 5685 } 5686 function A2(e2, t3 = ``, n3 = ``, r3 = ``, i3 = Error) { 5687 let a3 = new i3(k2(e2, t3, n3, r3)); 5688 return a3.code = e2, n3 && (a3.path = n3), a3; 5689 } 5690 function j2(e2, t3 = ``, n3 = ``, r3 = ``) { 5691 return { code: e2, message: k2(e2, t3, n3, r3), path: n3, toError() { 5692 let e3 = Error(this.message); 5693 return e3.code = this.code, this.path && (e3.path = this.path), e3; 5694 } }; 5695 } 5696 function M2() { 5697 return Math.random().toString(36).slice(2, 8).padEnd(6, `0`); 5698 } 5699 function N2(e2) { 5700 if (typeof e2 == `number`) return e2; 5701 if (typeof e2 == `string`) { 5702 let t3 = n2.FLAGS[e2]; 5703 if (t3 !== void 0) return t3; 5704 } 5705 throw new r2.TypeError(`ERR_INVALID_OPT_VALUE`, `flags`, e2); 5706 } 5707 function P2(e2) { 5708 let t3 = []; 5709 return new Promise((n3, r3) => { 5710 e2.on(`data`, (e3) => t3.push(e3)), e2.on(`end`, () => n3(i2.Buffer.concat(t3))), e2.on(`error`, r3); 5711 }); 5712 } 5713 t2.bufToUint8 = (e2) => new Uint8Array(e2.buffer, e2.byteOffset, e2.byteLength), t2.getWriteArgs = (e2, t3, n3, r3, i3, o3) => { 5714 (0, a2.validateFd)(e2); 5715 let c3 = 0, l2, u2 = null, d3, f3, p3 = typeof t3, m3 = typeof n3, h3 = typeof r3, g3 = typeof i3; 5716 p3 === `string` ? m3 === `function` ? f3 = n3 : h3 === `function` ? (u2 = n3, f3 = r3) : g3 === `function` && (u2 = n3, d3 = r3, f3 = i3) : m3 === `function` ? f3 = n3 : h3 === `function` ? (c3 = n3 | 0, f3 = r3) : g3 === `function` ? (c3 = n3 | 0, l2 = r3, f3 = i3) : (c3 = n3 | 0, l2 = r3, u2 = i3, f3 = o3); 5717 let _3 = (0, a2.dataToBuffer)(t3, d3); 5718 p3 === `string` ? (c3 = 0, l2 = _3.length) : l2 === void 0 && (l2 = _3.length); 5719 let v3 = s2(f3); 5720 return [e2, p3 === `string`, _3, c3, l2, u2, v3]; 5721 }, t2.getWriteSyncArgs = (e2, t3, n3, r3, i3) => { 5722 (0, a2.validateFd)(e2); 5723 let o3, s3, c3, l2, u2 = typeof t3 != `string`; 5724 u2 ? (s3 = (n3 || 0) | 0, c3 = r3, l2 = i3) : (l2 = n3, o3 = r3); 5725 let d3 = (0, a2.dataToBuffer)(t3, o3); 5726 return u2 ? c3 === void 0 && (c3 = d3.length) : (s3 = 0, c3 = d3.length), [e2, d3, s3 || 0, c3, l2]; 5727 }; 5728 function F2(e2, t3) { 5729 return !t3 || t3 === `buffer` ? e2 : e2.toString(t3); 5730 } 5731 function I2(e2) { 5732 return typeof e2 == `object` && !!e2 && typeof e2.pipe == `function` && typeof e2.on == `function` && e2.readable === true; 5733 } 5734})), dr = i(((e2) => { 5735 Object.defineProperty(e2, `__esModule`, { value: true }), e2.FileHandle = void 0; 5736 var t2 = ur(), n2 = lr(); 5737 e2.FileHandle = class extends n2.EventEmitter { 5738 constructor(e3, t3) { 5739 super(), this.refs = 1, this.closePromise = null, this.position = 0, this.readableWebStreamLocked = false, this.fs = e3, this.fd = t3; 5740 } 5741 getAsyncId() { 5742 return this.fd; 5743 } 5744 appendFile(e3, n3) { 5745 return (0, t2.promisify)(this.fs, `appendFile`)(this.fd, e3, n3); 5746 } 5747 chmod(e3) { 5748 return (0, t2.promisify)(this.fs, `fchmod`)(this.fd, e3); 5749 } 5750 chown(e3, n3) { 5751 return (0, t2.promisify)(this.fs, `fchown`)(this.fd, e3, n3); 5752 } 5753 close() { 5754 if (this.fd === -1) return Promise.resolve(); 5755 if (this.closePromise) return this.closePromise; 5756 if (this.refs--, this.refs === 0) { 5757 let e3 = this.fd; 5758 this.fd = -1, this.closePromise = (0, t2.promisify)(this.fs, `close`)(e3).finally(() => { 5759 this.closePromise = null; 5760 }); 5761 } else this.closePromise = new Promise((e3, t3) => { 5762 this.closeResolve = e3, this.closeReject = t3; 5763 }).finally(() => { 5764 this.closePromise = null, this.closeReject = void 0, this.closeResolve = void 0; 5765 });
5766 return this.emit(`close`), this.closePromise; 5767 } 5768 datasync() { 5769 return (0, t2.promisify)(this.fs, `fdatasync`)(this.fd); 5770 } 5771 createReadStream(e3) { 5772 return this.fs.createReadStream(``, { ...e3, fd: this }); 5773 } 5774 createWriteStream(e3) { 5775 return this.fs.createWriteStream(``, { ...e3, fd: this }); 5776 } 5777 readableWebStream(e3 = {}) { 5778 let { type: t3 = `bytes`, autoClose: n3 = false } = e3, r2 = 0; 5779 if (this.fd === -1) throw Error(`The FileHandle is closed`); 5780 if (this.closePromise) throw Error(`The FileHandle is closing`); 5781 if (this.readableWebStreamLocked) throw Error(`An error will be thrown if this method is called more than once or is called after the FileHandle is closed or closing.`); 5782 this.readableWebStreamLocked = true, this.ref(); 5783 let i2 = () => { 5784 this.readableWebStreamLocked = false, this.unref(), n3 && this.close().catch(() => { 5785 }); 5786 }; 5787 return new ReadableStream({ type: t3 === `bytes` ? `bytes` : void 0, autoAllocateChunkSize: 16384, pull: async (e4) => { 5788 try { 5789 let t4 = e4.byobRequest?.view; 5790 if (!t4) { 5791 let t5 = new Uint8Array(16384), n5 = await this.read(t5, 0, t5.length, r2); 5792 if (n5.bytesRead === 0) { 5793 e4.close(), i2(); 5794 return; 5795 } 5796 r2 += n5.bytesRead, e4.enqueue(t5.slice(0, n5.bytesRead)); 5797 return; 5798 } 5799 let n4 = await this.read(t4, t4.byteOffset, t4.byteLength, r2); 5800 if (n4.bytesRead === 0) { 5801 e4.close(), i2(); 5802 return; 5803 } 5804 r2 += n4.bytesRead, e4.byobRequest.respond(n4.bytesRead); 5805 } catch (t4) { 5806 e4.error(t4), i2(); 5807 } 5808 }, cancel: async () => { 5809 i2(); 5810 } }); 5811 } 5812 async read(e3, n3, r2, i2) { 5813 let a2 = i2 ?? this.position, o2 = await (0, t2.promisify)(this.fs, `read`, (t3) => ({ bytesRead: t3, buffer: e3 }))(this.fd, e3, n3, r2, a2); 5814 return i2 ?? (this.position += o2.bytesRead), o2; 5815 } 5816 readv(e3, n3) { 5817 return (0, t2.promisify)(this.fs, `readv`, (t3) => ({ bytesRead: t3, buffers: e3 }))(this.fd, e3, n3); 5818 } 5819 readFile(e3) { 5820 return (0, t2.promisify)(this.fs, `readFile`)(this.fd, e3); 5821 } 5822 stat(e3) { 5823 return (0, t2.promisify)(this.fs, `fstat`)(this.fd, e3); 5824 } 5825 sync() { 5826 return (0, t2.promisify)(this.fs, `fsync`)(this.fd); 5827 } 5828 truncate(e3) { 5829 return (0, t2.promisify)(this.fs, `ftruncate`)(this.fd, e3); 5830 } 5831 utimes(e3, n3) { 5832 return (0, t2.promisify)(this.fs, `futimes`)(this.fd, e3, n3); 5833 } 5834 async write(e3, n3, r2, i2) { 5835 let a2 = typeof i2 != `number`, o2 = a2 ? this.position : i2, s2 = await (0, t2.promisify)(this.fs, `write`, (t3) => ({ bytesWritten: t3, buffer: e3 }))(this.fd, e3, n3, r2, o2); 5836 return a2 && (this.position += s2.bytesWritten), s2; 5837 } 5838 writev(e3, n3) { 5839 return (0, t2.promisify)(this.fs, `writev`, (t3) => ({ bytesWritten: t3, buffers: e3 }))(this.fd, e3, n3); 5840 } 5841 writeFile(e3, n3) { 5842 return (0, t2.promisify)(this.fs, `writeFile`)(this.fd, e3, n3); 5843 } 5844 async [Symbol.asyncDispose]() { 5845 await this.close(); 5846 } 5847 ref() { 5848 this.refs++; 5849 } 5850 unref() { 5851 this.refs--, this.refs === 0 && (this.fd = -1, this.closeResolve && (0, t2.promisify)(this.fs, `close`)(this.fd).then(this.closeResolve, this.closeReject)); 5852 } 5853 }; 5854})), fr = i(((e2) => { 5855 Object.defineProperty(e2, `__esModule`, { value: true }), e2.FsPromises = void 0; 5856 var t2 = ur(), n2 = $(), r2 = class { 5857 constructor(e3, t3, n3 = {}) { 5858 if (this.fs = e3, this.path = t3, this.options = n3, this.eventQueue = [], this.resolveQueue = [], this.finished = false, this.maxQueue = n3.maxQueue || 2048, this.overflow = n3.overflow || `ignore`, this.startWatching(), n3.signal) { 5859 if (n3.signal.aborted) { 5860 this.finish(); 5861 return; 5862 } 5863 n3.signal.addEventListener(`abort`, () => { 5864 this.finish(); 5865 }); 5866 } 5867 } 5868 startWatching() { 5869 try { 5870 this.watcher = this.fs.watch(this.path, this.options, (e3, t3) => { 5871 this.enqueueEvent({ eventType: e3, filename: t3 }); 5872 }); 5873 } catch (e3) { 5874 throw this.finish(), e3; 5875 } 5876 } 5877 enqueueEvent(e3) { 5878 if (!this.finished) { 5879 if (this.eventQueue.length >= this.maxQueue) if (this.overflow === `throw`) { 5880 let e4 = Error(`Watch queue overflow: more than ${this.maxQueue} events queued`); 5881 this.finish(e4); 5882 return; 5883 } else this.eventQueue.shift(); 5884 if (this.eventQueue.push(e3), this.resolveQueue.length > 0) { 5885 let { resolve: e4 } = this.resolveQueue.shift(); 5886 e4({ value: this.eventQueue.shift(), done: false }); 5887 } 5888 } 5889 } 5890 finish(e3) { 5891 if (!this.finished) for (this.finished = true, this.watcher && (this.watcher = (this.watcher.close(), null)); this.resolveQueue.length > 0; ) { 5892 let { resolve: t3, reject: n3 } = this.resolveQueue.shift(); 5893 e3 ? n3(e3) : t3({ value: void 0, done: true }); 5894 } 5895 } 5896 async next() { 5897 return this.finished ? { value: void 0, done: true } : this.eventQueue.length > 0 ? { value: this.eventQueue.shift(), done: false } : new Promise((e3, t3) => { 5898 this.resolveQueue.push({ resolve: e3, reject: t3 }); 5899 }); 5900 } 5901 async return() { 5902 return this.finish(), { value: void 0, done: true }; 5903 } 5904 async throw(e3) { 5905 throw this.finish(e3), e3; 5906 } 5907 [Symbol.asyncIterator]() { 5908 return this; 5909 } 5910 };
5911 e2.FsPromises = class { 5912 constructor(e3, i2) { 5913 this.fs = e3, this.FileHandle = i2, this.constants = n2.constants, this.cp = (0, t2.promisify)(this.fs, `cp`), this.opendir = (0, t2.promisify)(this.fs, `opendir`), this.statfs = (0, t2.promisify)(this.fs, `statfs`), this.lutimes = (0, t2.promisify)(this.fs, `lutimes`), this.glob = (0, t2.promisify)(this.fs, `glob`), this.access = (0, t2.promisify)(this.fs, `access`), this.chmod = (0, t2.promisify)(this.fs, `chmod`), this.chown = (0, t2.promisify)(this.fs, `chown`), this.copyFile = (0, t2.promisify)(this.fs, `copyFile`), this.lchmod = (0, t2.promisify)(this.fs, `lchmod`), this.lchown = (0, t2.promisify)(this.fs, `lchown`), this.link = (0, t2.promisify)(this.fs, `link`), this.lstat = (0, t2.promisify)(this.fs, `lstat`), this.mkdir = (0, t2.promisify)(this.fs, `mkdir`), this.mkdtemp = (0, t2.promisify)(this.fs, `mkdtemp`), this.readdir = (0, t2.promisify)(this.fs, `readdir`), this.readlink = (0, t2.promisify)(this.fs, `readlink`), this.realpath = (0, t2.promisify)(this.fs, `realpath`), this.rename = (0, t2.promisify)(this.fs, `rename`), this.rmdir = (0, t2.promisify)(this.fs, `rmdir`), this.rm = (0, t2.promisify)(this.fs, `rm`), this.stat = (0, t2.promisify)(this.fs, `stat`), this.symlink = (0, t2.promisify)(this.fs, `symlink`), this.truncate = (0, t2.promisify)(this.fs, `truncate`), this.unlink = (0, t2.promisify)(this.fs, `unlink`), this.utimes = (0, t2.promisify)(this.fs, `utimes`), this.readFile = (e4, n3) => (0, t2.promisify)(this.fs, `readFile`)(e4 instanceof this.FileHandle ? e4.fd : e4, n3), this.appendFile = (e4, n3, r3) => (0, t2.promisify)(this.fs, `appendFile`)(e4 instanceof this.FileHandle ? e4.fd : e4, n3, r3), this.open = (e4, n3 = `r`, r3) => (0, t2.promisify)(this.fs, `open`, (e5) => new this.FileHandle(this.fs, e5))(e4, n3, r3), this.writeFile = (e4, n3, r3) => ((0, t2.isReadableStream)(n3) ? (0, t2.streamToBuffer)(n3) : Promise.resolve(n3)).then((n4) => (0, t2.promisify)(this.fs, `writeFile`)(e4 instanceof this.FileHandle ? e4.fd : e4, n4, r3)), this.watch = (e4, t3) => { 5914 let n3 = typeof t3 == `string` ? { encoding: t3 } : t3 || {}; 5915 return new r2(this.fs, e4, n3); 5916 }; 5917 } 5918 }; 5919})), pr = i(((e2) => { 5920 Object.defineProperty(e2, `__esModule`, { value: true }), e2.printTree = void 0, e2.printTree = (e3 = ``, t2) => { 5921 let n2 = ``, r2 = t2.length - 1; 5922 for (; r2 >= 0 && !t2[r2]; r2--) ; 5923 for (let i2 = 0; i2 <= r2; i2++) { 5924 let a2 = t2[i2]; 5925 if (!a2) continue; 5926 let o2 = i2 === r2, s2 = a2(e3 + (o2 ? ` ` : `\u2502`) + ` `), c2 = s2 ? o2 ? `\u2514\u2500` : `\u251C\u2500` : `\u2502`; 5927 n2 += ` 5928` + e3 + c2 + (s2 ? ` ` + s2 : ``); 5929 } 5930 return n2; 5931 }; 5932})), mr = i(((e2) => { 5933 Object.defineProperty(e2, `__esModule`, { value: true }), e2.printBinary = void 0, e2.printBinary = (e3 = ``, t2) => { 5934 let n2 = t2[0], r2 = t2[1], i2 = ``; 5935 return n2 && (i2 += ` 5936` + e3 + `\u2190 ` + n2(e3 + ` `)), r2 && (i2 += ` 5937` + e3 + `\u2192 ` + r2(e3 + ` `)), i2; 5938 }; 5939})), hr = i(((e2) => { 5940 Object.defineProperty(e2, `__esModule`, { value: true }), e2.printJson = void 0, e2.printJson = (e3 = ``, t2, n2 = 2) => (JSON.stringify(t2, null, n2) || `nil`).split(` 5941`).join(` 5942` + e3); 5943})), gr = i(((t2) => { 5944 Object.defineProperty(t2, `__esModule`, { value: true }); 5945 var n2 = (J(), e(f)); 5946 n2.__exportStar(pr(), t2), n2.__exportStar(mr(), t2), n2.__exportStar(hr(), t2); 5947})), _r = i(((e2) => { 5948 Object.defineProperty(e2, `__esModule`, { value: true }), e2.toTreeSync = void 0; 5949 var t2 = gr(), n2 = $(); 5950 e2.toTreeSync = (r2, i2 = {}) => { 5951 let a2 = i2.separator || `/`, o2 = i2.dir || a2; 5952 o2[o2.length - 1] !== a2 && (o2 += a2); 5953 let s2 = i2.tab || ``, c2 = i2.depth ?? 10, l2 = i2.sort ?? true, u2 = ` (...)`; 5954 if (c2 > 0) { 5955 let n3 = r2.readdirSync(o2, { withFileTypes: true }); 5956 l2 && n3.sort((e3, t3) => e3.isDirectory() && t3.isDirectory() ? e3.name.toString().localeCompare(t3.name.toString()) : e3.isDirectory() ? -1 : t3.isDirectory() ? 1 : e3.name.toString().localeCompare(t3.name.toString())), u2 = (0, t2.printTree)(s2, n3.map((t3) => (n4) =>
5956 t3.isDirectory() ? (0, e2.toTreeSync)(r2, { dir: o2 + t3.name, depth: c2 - 1, tab: n4 }) : t3.isSymbolicLink() ? `` + t3.name + ` \u2192 ` + r2.readlinkSync(o2 + t3.name) : `` + t3.name)); 5957 } 5958 return (0, n2.basename)(o2, a2) + a2 + u2; 5959 }; 5960})), vr = i(((e2) => { 5961 Object.defineProperty(e2, `__esModule`, { value: true }); 5962})), yr = i(((e2) => { 5963 Object.defineProperty(e2, `__esModule`, { value: true }), e2.fromSnapshotSync = e2.toSnapshotSync = void 0, e2.toSnapshotSync = ({ fs: t2, path: n2 = `/`, separator: r2 = `/` }) => { 5964 let i2 = t2.lstatSync(n2); 5965 if (i2.isDirectory()) { 5966 let i3 = t2.readdirSync(n2), a2 = {}, o2 = n2.endsWith(r2) ? n2 : n2 + r2; 5967 for (let n3 of i3) { 5968 let i4 = (0, e2.toSnapshotSync)({ fs: t2, path: `${o2}${n3}`, separator: r2 }); 5969 i4 && (a2[`` + n3] = i4); 5970 } 5971 return [0, {}, a2]; 5972 } else if (i2.isFile()) { 5973 let e3 = t2.readFileSync(n2); 5974 return [1, {}, new Uint8Array(e3.buffer, e3.byteOffset, e3.byteLength)]; 5975 } else if (i2.isSymbolicLink()) return [2, { target: t2.readlinkSync(n2).toString() }]; 5976 return null; 5977 }, e2.fromSnapshotSync = (t2, { fs: n2, path: r2 = `/`, separator: i2 = `/` }) => { 5978 if (t2) switch (t2[0]) { 5979 case 0: { 5980 r2.endsWith(i2) || (r2 += i2); 5981 let [, , a2] = t2; 5982 n2.mkdirSync(r2, { recursive: true }); 5983 for (let [t3, o2] of Object.entries(a2)) (0, e2.fromSnapshotSync)(o2, { fs: n2, path: `${r2}${t3}`, separator: i2 }); 5984 break; 5985 } 5986 case 1: { 5987 let [, , e3] = t2; 5988 n2.writeFileSync(r2, e3); 5989 break; 5990 } 5991 case 2: { 5992 let [, { target: e3 }] = t2; 5993 n2.symlinkSync(e3, r2); 5994 break; 5995 } 5996 } 5997 }; 5998})), br = i(((e2) => { 5999 Object.defineProperty(e2, `__esModule`, { value: true }), e2.isFloat32 = void 0; 6000 var t2 = new DataView(new ArrayBuffer(4)); 6001 e2.isFloat32 = (e3) => (t2.setFloat32(0, e3), e3 === t2.getFloat32(0)); 6002})), xr = i(((e2) => { 6003 Object.defineProperty(e2, `__esModule`, { value: true }), e2.JsonPackExtension = void 0, e2.JsonPackExtension = class { 6004 constructor(e3, t2) { 6005 this.tag = e3, this.val = t2; 6006 } 6007 }; 6008})), Sr = i(((e2) => { 6009 Object.defineProperty(e2, `__esModule`, { value: true }), e2.Slice = void 0, e2.Slice = class { 6010 constructor(e3, t2, n2, r2) { 6011 this.uint8 = e3, this.view = t2, this.start = n2, this.end = r2; 6012 } 6013 subarray() { 6014 return this.uint8.subarray(this.start, this.end); 6015 } 6016 }; 6017})), Cr = i(((e2) => { 6018 s(), Object.defineProperty(e2, `__esModule`, { value: true }), e2.Writer = void 0; 6019 var t2 = Sr(), n2 = new Uint8Array([]), r2 = new DataView(n2.buffer), i2 = typeof c == `function`, a2 = i2 ? c.prototype.utf8Write : null, o2 = i2 ? c.from : null, l2 = typeof TextEncoder < `u` ? new TextEncoder() : null; 6020 e2.Writer = class { 6021 constructor(e3 = 64 * 1024) { 6022 this.allocSize = e3, this.view = r2, this.x0 = 0, this.x = 0, this.uint8 = new Uint8Array(e3), this.size = e3, this.view = new DataView(this.uint8.buffer); 6023 } 6024 grow(e3) { 6025 let t3 = this.x0, n3 = this.x, r3 = this.uint8, i3 = new Uint8Array(e3), a3 = new DataView(i3.buffer), o3 = r3.subarray(t3, n3); 6026 i3.set(o3, 0), this.x = n3 - t3, this.x0 = 0, this.uint8 = i3, this.size = e3, this.view = a3; 6027 } 6028 ensureCapacity(e3) { 6029 let t3 = this.size, n3 = t3 - this.x; 6030 if (n3 < e3) { 6031 let r3 = t3 - this.x0 + (e3 - n3); 6032 this.grow(r3 <= this.allocSize ? this.allocSize : r3 * 2); 6033 } 6034 } 6035 move(e3) { 6036 this.ensureCapacity(e3), this.x += e3; 6037 } 6038 reset() { 6039 this.x0 = this.x; 6040 } 6041 newBuffer(e3) { 6042 let t3 = this.uint8 = new Uint8Array(e3); 6043 this.size = e3, this.view = new DataView(t3.buffer), this.x = this.x0 = 0; 6044 } 6045 flush() { 6046 let e3 = this.uint8.subarray(this.x0, this.x); 6047 return this.x0 = this.x, e3; 6048 } 6049 flushSlice() { 6050 let e3 = new t2.Slice(this.uint8, this.view, this.x0, this.x); 6051 return this.x0 = this.x, e3; 6052 } 6053 u8(e3) { 6054 this.ensureCapacity(1), this.uint8[this.x++] = e3; 6055 } 6056 u16(e3) { 6057 this.ensureCapacity(2), this.view.setUint16(this.x, e3), this.x += 2; 6058 } 6059 u32(e3) { 6060 this.ensureCapacity(4), this.view.setUint32(this.x, e3), this.x += 4; 6061 } 6062 i32(e3) { 6063 this.ensureCapacity(4), this.view.setInt32(this.x, e3), this.x += 4; 6064 } 6065 u64(e3) { 6066 this.ensureCapacity(8), this.view.setBigUint64(this.x, BigInt(e3)), this.x += 8; 6067 } 6068 f64(e3) { 6069 this.ensureCapacity(8), this.view.setFloat64(this.x, e3), this.x += 8; 6070 } 6071 u8u16(e3, t3) { 6072 this.ensureCapacity(3); 6073 let n3 = this.x; 6074 this.uint8[n3++] = e3, this.uint8[n3++] = t3 >>> 8, this.uint8[n3++] = t3 & 255, this.x = n3; 6075 } 6076 u8u32(e3, t3) { 6077 this.ensureCapacity(5); 6078 let n3 = this.x; 6079 this.uint8[n3++] = e3, this.view.setUint32(n3, t3), this.x = n3 + 4; 6080 } 6081 u8u64(e3, t3) { 6082 this.ensureCapacity(9); 6083 let n3 = this.x; 6084 this.uint8[n3++] = e3, this.view.setBigUint64(n3, BigInt(t3)), this.x = n3 + 8; 6085 } 6086 u8f32(e3, t3) { 6087 this.ensureCapacity(5); 6088 let n3 = this.x; 6089 this.uint8[n3++] = e3, this.view.setFloat32(n3, t3), this.x = n3 + 4; 6090 } 6091 u8f64(e3, t3) { 6092 this.ensureCapacity(9); 6093 let n3 = this.x; 6094 this.uint8[n3++] = e3, this.view.setFloat64(n3, t3), this.x = n3 + 8; 6095 } 6096 buf(e3, t3) { 6097 this.ensureCapacity(t3); 6098 let n3 = this.x; 6099 this.uint8.set(e3, n3), this.x = n3 + t3; 6100 } 6101 utf8(e3) { 6102 let t3 = e3.length * 4; 6103 if (t3 < 168) return this.utf8Native(e3); 6104 this.ensureCapacity(t3); 6105 let n3 = this.size - this.x; 6106 if (a2) { 6107 let t4 = a2.call(this.uint8, e3, this.x, n3); 6108 return this.x += t4, t4; 6109 } else if (o2) { 6110 let t4 = this.uint8, r3 = t4.byteOffset + this.x, i3 = o2(t4.buffer).subarray(r3, r3 + n3).write(e3, 0, n3, `utf8`); 6111 return this.x += i3, i3; 6112 } else if (t3 > 1024 && l2) { 6113 let t4 = l2.encodeInto(e3, this.uint8.subarray(this.x, this.x + n3)).written; 6114 return this.x += t4, t4; 6115 } 6116 return this.utf8Native(e3); 6117 } 6118 utf8Native(e3) { 6119 let t3 = e3.length, n3 = this.uint8, r3 = this.x, i3 = 0; 6120 for (; i3 < t3; ) { 6121 let a4 = e3.charCodeAt(i3++); 6122 if (!(a4 & 4294967168)) { 6123 n3[r3++] = a4; 6124 continue; 6125 } else if (!(a4 & 4294965248)) n3[r3++] = a4 >> 6 & 31 | 192; 6126 else { 6127 if (a4 >= 55296 && a4 <= 56319 && i3 < t3) { 6128 let t4 = e3.charCodeAt(i3); 6129 (t4 & 64512) == 56320 && (i3++, a4 = ((a4 & 1023) << 10) + (t4 & 1023) + 65536); 6130 } 6131 a4 & 4294901760 ? (n3[r3++] = a4 >> 18 & 7 | 240, n3[r3++] = a4 >> 12 & 63 | 128, n3[r3++] = a4 >> 6 & 63 | 128) : (n3[r3++] = a4 >> 12 & 15 | 224, n3[r3++] = a4 >> 6 & 63 | 128); 6132 } 6133 n3[r3++] = a4 & 63 | 128; 6134 } 6135 let a3 = r3 - this.x; 6136 return this.x = r3, a3; 6137 } 6138 ascii(e3) { 6139 let t3 = e3.length; 6140 this.ensureCapacity(t3); 6141 let n3 = this.uint8, r3 = this.x, i3 = 0; 6142 for (; i3 < t3; ) n3[r3++] = e3.charCodeAt(i3++); 6143 this.x = r3; 6144 } 6145 }; 6146})), wr = i(((e2) => { 6147 Object.defineProperty(e2, `__esModule`, { value: true }), e2.CborEncoderFast = void 0; 6148 var t2 = Cr(), n2 = Number.isSafeInteger; 6149 e2.CborEncoderFast = class { 6150 constructor(e3 = new t2.Writer()) { 6151 this.writer = e3; 6152 } 6153 encode(e3) { 6154 return this.writeAny(e3), this.writer.flush(); 6155 } 6156 writeAny(e3) { 6157 switch (typeof e3) { 6158 case `number`: 6159 return this.writeNumber(e3); 6160 case `string`: 6161 return this.writeStr(e3); 6162 case `boolean`: 6163 return this.writer.u8(244 + +e3); 6164 case `object`: 6165 if (!e3) return this.writer.u8(246); 6166 switch (e3.constructor) { 6167 case Array: 6168 return this.writeArr(e3); 6169 default: 6170 return this.writeObj(e3); 6171 } 6172 } 6173 } 6174 writeCbor() { 6175 this.writer.u8u16(217, 55799); 6176 } 6177 writeEnd() { 6178 this.writer.u8(255); 6179 }
6180 writeNull() { 6181 this.writer.u8(246); 6182 } 6183 writeBoolean(e3) { 6184 e3 ? this.writer.u8(245) : this.writer.u8(244); 6185 } 6186 writeNumber(e3) { 6187 n2(e3) ? this.writeInteger(e3) : typeof e3 == `bigint` ? this.writeBigInt(e3) : this.writeFloat(e3); 6188 } 6189 writeBigInt(e3) { 6190 e3 >= 0 ? this.writeBigUint(e3) : this.writeBigSint(e3); 6191 } 6192 writeBigUint(e3) { 6193 if (e3 <= 2 ** 53 - 1) return this.writeUInteger(Number(e3)); 6194 this.writer.u8u64(27, e3); 6195 } 6196 writeBigSint(e3) { 6197 if (e3 >= -(2 ** 53 - 1)) return this.encodeNint(Number(e3)); 6198 let t3 = -BigInt(1) - e3; 6199 this.writer.u8u64(59, t3); 6200 } 6201 writeInteger(e3) { 6202 e3 >= 0 ? this.writeUInteger(e3) : this.encodeNint(e3); 6203 } 6204 writeUInteger(e3) { 6205 let t3 = this.writer; 6206 t3.ensureCapacity(9); 6207 let n3 = t3.uint8, r2 = t3.x; 6208 e3 <= 23 ? n3[r2++] = 0 + e3 : e3 <= 255 ? (n3[r2++] = 24, n3[r2++] = e3) : e3 <= 65535 ? (n3[r2++] = 25, t3.view.setUint16(r2, e3), r2 += 2) : e3 <= 4294967295 ? (n3[r2++] = 26, t3.view.setUint32(r2, e3), r2 += 4) : (n3[r2++] = 27, t3.view.setBigUint64(r2, BigInt(e3)), r2 += 8), t3.x = r2; 6209 } 6210 encodeNumber(e3) { 6211 this.writeNumber(e3); 6212 } 6213 encodeInteger(e3) { 6214 this.writeInteger(e3); 6215 } 6216 encodeUint(e3) { 6217 this.writeUInteger(e3); 6218 } 6219 encodeNint(e3) { 6220 let t3 = -1 - e3, n3 = this.writer; 6221 n3.ensureCapacity(9); 6222 let r2 = n3.uint8, i2 = n3.x; 6223 t3 < 24 ? r2[i2++] = 32 + t3 : t3 <= 255 ? (r2[i2++] = 56, r2[i2++] = t3) : t3 <= 65535 ? (r2[i2++] = 57, n3.view.setUint16(i2, t3), i2 += 2) : t3 <= 4294967295 ? (r2[i2++] = 58, n3.view.setUint32(i2, t3), i2 += 4) : (r2[i2++] = 59, n3.view.setBigUint64(i2, BigInt(t3)), i2 += 8), n3.x = i2; 6224 } 6225 writeFloat(e3) { 6226 this.writer.u8f64(251, e3); 6227 } 6228 writeBin(e3) { 6229 let t3 = e3.length; 6230 this.writeBinHdr(t3), this.writer.buf(e3, t3); 6231 } 6232 writeBinHdr(e3) { 6233 let t3 = this.writer; 6234 e3 <= 23 ? t3.u8(64 + e3) : e3 <= 255 ? t3.u16(22528 + e3) : e3 <= 65535 ? t3.u8u16(89, e3) : e3 <= 4294967295 ? t3.u8u32(90, e3) : t3.u8u64(91, e3); 6235 } 6236 writeStr(e3) { 6237 let t3 = this.writer, n3 = e3.length * 4; 6238 t3.ensureCapacity(5 + n3); 6239 let r2 = t3.uint8, i2 = t3.x; 6240 n3 <= 23 ? t3.x++ : n3 <= 255 ? (r2[t3.x++] = 120, i2 = t3.x, t3.x++) : n3 <= 65535 ? (r2[t3.x++] = 121, i2 = t3.x, t3.x += 2) : (r2[t3.x++] = 122, i2 = t3.x, t3.x += 4); 6241 let a2 = t3.utf8(e3); 6242 n3 <= 23 ? r2[i2] = 96 + a2 : n3 <= 255 ? r2[i2] = a2 : n3 <= 65535 ? t3.view.setUint16(i2, a2) : t3.view.setUint32(i2, a2); 6243 } 6244 writeStrHdr(e3) { 6245 let t3 = this.writer; 6246 e3 <= 23 ? t3.u8(96 + e3) : e3 <= 255 ? t3.u16(30720 + e3) : e3 <= 65535 ? t3.u8u16(121, e3) : t3.u8u32(122, e3); 6247 } 6248 writeAsciiStr(e3) { 6249 this.writeStrHdr(e3.length), this.writer.ascii(e3); 6250 } 6251 writeArr(e3) { 6252 let t3 = e3.length; 6253 this.writeArrHdr(t3); 6254 for (let n3 = 0; n3 < t3; n3++) this.writeAny(e3[n3]); 6255 } 6256 writeArrHdr(e3) { 6257 let t3 = this.writer; 6258 e3 <= 23 ? t3.u8(128 + e3) : e3 <= 255 ? t3.u16(38912 + e3) : e3 <= 65535 ? t3.u8u16(153, e3) : e3 <= 4294967295 ? t3.u8u32(154, e3) : t3.u8u64(155, e3); 6259 } 6260 writeObj(e3) { 6261 let t3 = Object.keys(e3), n3 = t3.length; 6262 this.writeObjHdr(n3); 6263 for (let r2 = 0; r2 < n3; r2++) { 6264 let n4 = t3[r2]; 6265 this.writeStr(n4), this.writeAny(e3[n4]); 6266 } 6267 } 6268 writeObjHdr(e3) { 6269 let t3 = this.writer; 6270 e3 <= 23 ? t3.u8(160 + e3) : e3 <= 255 ? t3.u16(47104 + e3) : e3 <= 65535 ? t3.u8u16(185, e3) : e3 <= 4294967295 ? t3.u8u32(186, e3) : t3.u8u64(187, e3); 6271 } 6272 writeMapHdr(e3) { 6273 this.writeObjHdr(e3); 6274 } 6275 writeStartMap() { 6276 this.writer.u8(191); 6277 } 6278 writeTag(e3, t3) { 6279 this.writeTagHdr(e3), this.writeAny(t3); 6280 } 6281 writeTagHdr(e3) { 6282 let t3 = this.writer; 6283 e3 <= 23 ? t3.u8(192 + e3) : e3 <= 255 ? t3.u16(55296 + e3) : e3 <= 65535 ? t3.u8u16(217, e3) : e3 <= 4294967295 ? t3.u8u32(218, e3) : t3.u8u64(219, e3); 6284 } 6285 writeTkn(e3) { 6286 let t3 = this.writer;
6287 e3 <= 23 ? t3.u8(224 + e3) : e3 <= 255 && t3.u16(63488 + e3); 6288 } 6289 writeStartStr() { 6290 this.writer.u8(127); 6291 } 6292 writeStrChunk(e3) { 6293 throw Error(`Not implemented`); 6294 } 6295 writeEndStr() { 6296 throw Error(`Not implemented`); 6297 } 6298 writeStartBin() { 6299 this.writer.u8(95); 6300 } 6301 writeBinChunk(e3) { 6302 throw Error(`Not implemented`); 6303 } 6304 writeEndBin() { 6305 throw Error(`Not implemented`); 6306 } 6307 writeStartArr() { 6308 this.writer.u8(159); 6309 } 6310 writeArrChunk(e3) { 6311 throw Error(`Not implemented`); 6312 } 6313 writeEndArr() { 6314 this.writer.u8(255); 6315 } 6316 writeStartObj() { 6317 this.writer.u8(191); 6318 } 6319 writeObjChunk(e3, t3) { 6320 throw Error(`Not implemented`); 6321 } 6322 writeEndObj() { 6323 this.writer.u8(255); 6324 } 6325 }; 6326})), Tr = i(((e2) => { 6327 Object.defineProperty(e2, `__esModule`, { value: true }), e2.JsonPackValue = void 0, e2.JsonPackValue = class { 6328 constructor(e3) { 6329 this.val = e3; 6330 } 6331 }; 6332})), Er = i(((e2) => { 6333 Object.defineProperty(e2, `__esModule`, { value: true }), e2.CborEncoder = void 0; 6334 var t2 = br(), n2 = xr(), r2 = wr(), i2 = Tr(); 6335 e2.CborEncoder = class extends r2.CborEncoderFast { 6336 writeUnknown(e3) { 6337 this.writeNull(); 6338 } 6339 writeAny(e3) { 6340 switch (typeof e3) { 6341 case `number`: 6342 return this.writeNumber(e3); 6343 case `string`: 6344 return this.writeStr(e3); 6345 case `boolean`: 6346 return this.writer.u8(244 + +e3); 6347 case `object`: 6348 if (!e3) return this.writer.u8(246); 6349 switch (e3.constructor) { 6350 case Object: 6351 return this.writeObj(e3); 6352 case Array: 6353 return this.writeArr(e3); 6354 case Uint8Array: 6355 return this.writeBin(e3); 6356 case Map: 6357 return this.writeMap(e3); 6358 case n2.JsonPackExtension: 6359 return this.writeTag(e3.tag, e3.val); 6360 case i2.JsonPackValue: { 6361 let t3 = e3.val; 6362 return this.writer.buf(t3, t3.length); 6363 } 6364 default: 6365 return e3 instanceof Uint8Array ? this.writeBin(e3) : Array.isArray(e3) ? this.writeArr(e3) : e3 instanceof Map ? this.writeMap(e3) : this.writeUnknown(e3); 6366 } 6367 case `undefined`: 6368 return this.writeUndef(); 6369 case `bigint`: 6370 return this.writeBigInt(e3); 6371 default: 6372 return this.writeUnknown(e3); 6373 } 6374 } 6375 writeFloat(e3) { 6376 (0, t2.isFloat32)(e3) ? this.writer.u8f32(250, e3) : this.writer.u8f64(251, e3); 6377 } 6378 writeMap(e3) { 6379 this.writeMapHdr(e3.size), e3.forEach((e4, t3) => { 6380 this.writeAny(t3), this.writeAny(e4); 6381 }); 6382 } 6383 writeUndef() { 6384 this.writer.u8(247); 6385 } 6386 }; 6387})), Dr = i(((e2) => { 6388 Object.defineProperty(e2, `__esModule`, { value: true }), e2.decodeF16 = void 0; 6389 var t2 = Math.pow; 6390 e2.decodeF16 = (e3) => { 6391 let n2 = (e3 & 31744) >> 10, r2 = e3 & 1023; 6392 return (e3 >> 15 ? -1 : 1) * (n2 ? n2 === 31 ? r2 ? NaN : 1 / 0 : t2(2, n2 - 15) * (1 + r2 / 1024) : r2 / 1024 * 6103515625e-14); 6393 }; 6394})), Or = i(((e2) => { 6395 Object.defineProperty(e2, `__esModule`, { value: true }), e2.decodeAsciiMax15 = e2.decodeAscii = void 0; 6396 var t2 = String.fromCharCode; 6397 e2.decodeAscii = (e3, n2, r2) => { 6398 let i2 = []; 6399 for (let t3 = 0; t3 < r2; t3++) { 6400 let t4 = e3[n2++]; 6401 if (t4 & 128) return; 6402 i2.push(t4); 6403 } 6404 return t2.apply(String, i2); 6405 }, e2.decodeAsciiMax15 = (e3, n2, r2) => { 6406 if (r2 < 4) if (r2 < 2) { 6407 if (r2 === 0) return ``; 6408 { 6409 let r3 = e3[n2++]; 6410 if ((r3 & 128) > 1) { 6411 --n2; 6412 return; 6413 } 6414 return t2(r3); 6415 } 6416 } else { 6417 let i2 = e3[n2++], a2 = e3[n2++]; 6418 if ((i2 & 128) > 0 || (a2 & 128) > 0) { 6419 n2 -= 2; 6420 return; 6421 } 6422 if (r2 < 3) return t2(i2, a2); 6423 let o2 = e3[n2++]; 6424 if ((o2 & 128) > 0) { 6425 n2 -= 3; 6426 return; 6427 } 6428 return t2(i2, a2, o2); 6429 } 6430 else { 6431 let i2 = e3[n2++], a2 = e3[n2++], o2 = e3[n2++], s2 = e3[n2++]; 6432 if ((i2 & 128) > 0 || (a2 & 128) > 0 || (o2 & 128) > 0 || (s2 & 128) > 0) { 6433 n2 -= 4; 6434 return; 6435 }
6436 if (r2 < 6) { 6437 if (r2 === 4) return t2(i2, a2, o2, s2); 6438 { 6439 let r3 = e3[n2++]; 6440 if ((r3 & 128) > 0) { 6441 n2 -= 5; 6442 return; 6443 } 6444 return t2(i2, a2, o2, s2, r3); 6445 } 6446 } else if (r2 < 8) { 6447 let c2 = e3[n2++], l2 = e3[n2++]; 6448 if ((c2 & 128) > 0 || (l2 & 128) > 0) { 6449 n2 -= 6; 6450 return; 6451 } 6452 if (r2 < 7) return t2(i2, a2, o2, s2, c2, l2); 6453 let u2 = e3[n2++]; 6454 if ((u2 & 128) > 0) { 6455 n2 -= 7; 6456 return; 6457 } 6458 return t2(i2, a2, o2, s2, c2, l2, u2); 6459 } else { 6460 let c2 = e3[n2++], l2 = e3[n2++], u2 = e3[n2++], d2 = e3[n2++]; 6461 if ((c2 & 128) > 0 || (l2 & 128) > 0 || (u2 & 128) > 0 || (d2 & 128) > 0) { 6462 n2 -= 8; 6463 return; 6464 } 6465 if (r2 < 10) { 6466 if (r2 === 8) return t2(i2, a2, o2, s2, c2, l2, u2, d2); 6467 { 6468 let r3 = e3[n2++]; 6469 if ((r3 & 128) > 0) { 6470 n2 -= 9; 6471 return; 6472 } 6473 return t2(i2, a2, o2, s2, c2, l2, u2, d2, r3); 6474 } 6475 } else if (r2 < 12) { 6476 let f2 = e3[n2++], p2 = e3[n2++]; 6477 if ((f2 & 128) > 0 || (p2 & 128) > 0) { 6478 n2 -= 10; 6479 return; 6480 } 6481 if (r2 < 11) return t2(i2, a2, o2, s2, c2, l2, u2, d2, f2, p2); 6482 let m2 = e3[n2++]; 6483 if ((m2 & 128) > 0) { 6484 n2 -= 11; 6485 return; 6486 } 6487 return t2(i2, a2, o2, s2, c2, l2, u2, d2, f2, p2, m2); 6488 } else { 6489 let f2 = e3[n2++], p2 = e3[n2++], m2 = e3[n2++], h2 = e3[n2++]; 6490 if ((f2 & 128) > 0 || (p2 & 128) > 0 || (m2 & 128) > 0 || (h2 & 128) > 0) { 6491 n2 -= 12; 6492 return; 6493 } 6494 if (r2 < 14) { 6495 if (r2 === 12) return t2(i2, a2, o2, s2, c2, l2, u2, d2, f2, p2, m2, h2); 6496 { 6497 let r3 = e3[n2++]; 6498 if ((r3 & 128) > 0) { 6499 n2 -= 13; 6500 return; 6501 } 6502 return t2(i2, a2, o2, s2, c2, l2, u2, d2, f2, p2, m2, h2, r3); 6503 } 6504 } else { 6505 let g2 = e3[n2++], _2 = e3[n2++]; 6506 if ((g2 & 128) > 0 || (_2 & 128) > 0) { 6507 n2 -= 14; 6508 return; 6509 } 6510 if (r2 < 15) return t2(i2, a2, o2, s2, c2, l2, u2, d2, f2, p2, m2, h2, g2, _2); 6511 let v2 = e3[n2++]; 6512 if ((v2 & 128) > 0) { 6513 n2 -= 15; 6514 return; 6515 } 6516 return t2(i2, a2, o2, s2, c2, l2, u2, d2, f2, p2, m2, h2, g2, _2, v2); 6517 } 6518 } 6519 } 6520 } 6521 }; 6522})), kr = i(((e2) => { 6523 Object.defineProperty(e2, `__esModule`, { value: true }); 6524 var t2 = String.fromCharCode; 6525 e2.default = (e3, n2, r2) => { 6526 let i2 = n2, a2 = i2 + r2, o2 = []; 6527 for (; i2 < a2; ) { 6528 let t3 = e3[i2++]; 6529 if (t3 & 128) { 6530 let n3 = e3[i2++] & 63; 6531 if ((t3 & 224) == 192) t3 = (t3 & 31) << 6 | n3; 6532 else { 6533 let r3 = e3[i2++] & 63; 6534 if ((t3 & 240) == 224) t3 = (t3 & 31) << 12 | n3 << 6 | r3; 6535 else if ((t3 & 248) == 240) { 6536 let a3 = e3[i2++] & 63, s2 = (t3 & 7) << 18 | n3 << 12 | r3 << 6 | a3; 6537 if (s2 > 65535) { 6538 s2 -= 65536; 6539 let e4 = s2 >>> 10 & 1023 | 55296; 6540 t3 = 56320 | s2 & 1023, o2.push(e4); 6541 } else t3 = s2; 6542 } 6543 } 6544 } 6545 o2.push(t3); 6546 } 6547 return t2.apply(String, o2); 6548 }; 6549})), Ar = i(((t2) => { 6550 s(), Object.defineProperty(t2, `__esModule`, { value: true }); 6551 var n2 = (J(), e(f)), r2 = Or(), i2 = n2.__importDefault(kr()), a2 = c !== void 0, o2 = a2 ? c.prototype.utf8Slice : null, l2 = a2 ? c.from : null, u2 = (e2, t3, n3) => (0, r2.decodeAsciiMax15)(e2, t3, n3) ?? (0, i2.default)(e2, t3, n3), d2 = (e2, t3, n3) => (0, r2.decodeAscii)(e2, t3, n3) ?? (0, i2.default)(e2, t3, n3), p2 = o2 ? (e2, t3, n3) => o2.call(e2, t3, t3 + n3) : l2 ? (e2, t3, n3) => l2(e2).subarray(t3, t3 + n3).toString(`utf8`) : i2.default; 6552 t2.default = (e2, t3, n3) => n3 < 16 ? u2(e2, t3, n3) : n3 < 32 ? d2(e2, t3, n3) : p2(e2, t3, n3); 6553})), jr = i(((t2) => { 6554 Object.defineProperty(t2, `__esModule`, { value: true }), t2.decodeUtf8 = void 0, t2.decodeUtf8 = (J(), e(f)).__importDefault(Ar()).default; 6555})), Mr = i(((e2) => { 6556 Object.defineProperty(e2, `__esModule`, { value: true }), e2.Reader = void 0; 6557 var t2 = jr(); 6558 e2.Reader = class e3 { 6559 constructor(e4 = new Uint8Array([]), t3 = new DataView(e4.buffer, e4.byteOffset, e4.length), n2 = 0, r2 = e4.length) { 6560 this.uint8 = e4, this.view = t3, this.x = n2, this.end = r2; 6561 } 6562 reset(e4) { 6563 this.x = 0, this.uint8 = e4, this.view = new DataView(e4.buffer, e4.byteOffset, e4.length); 6564 } 6565 size() {
6566 return this.end - this.x; 6567 } 6568 peek() { 6569 return this.view.getUint8(this.x); 6570 } 6571 peak() { 6572 return this.peek(); 6573 } 6574 skip(e4) { 6575 this.x += e4; 6576 } 6577 buf(e4 = this.size()) { 6578 let t3 = this.x, n2 = t3 + e4, r2 = this.uint8.subarray(t3, n2); 6579 return this.x = n2, r2; 6580 } 6581 subarray(e4 = 0, t3) { 6582 let n2 = this.x, r2 = n2 + e4, i2 = typeof t3 == `number` ? n2 + t3 : this.end; 6583 return this.uint8.subarray(r2, i2); 6584 } 6585 slice(t3 = 0, n2) { 6586 let r2 = this.x, i2 = r2 + t3, a2 = typeof n2 == `number` ? r2 + n2 : this.end; 6587 return new e3(this.uint8, this.view, i2, a2); 6588 } 6589 cut(e4 = this.size()) { 6590 let t3 = this.slice(0, e4); 6591 return this.skip(e4), t3; 6592 } 6593 u8() { 6594 return this.uint8[this.x++]; 6595 } 6596 i8() { 6597 return this.view.getInt8(this.x++); 6598 } 6599 u16() { 6600 let e4 = this.x, t3 = (this.uint8[e4++] << 8) + this.uint8[e4++]; 6601 return this.x = e4, t3; 6602 } 6603 i16() { 6604 let e4 = this.view.getInt16(this.x); 6605 return this.x += 2, e4; 6606 } 6607 u32() { 6608 let e4 = this.view.getUint32(this.x); 6609 return this.x += 4, e4; 6610 } 6611 i32() { 6612 let e4 = this.view.getInt32(this.x); 6613 return this.x += 4, e4; 6614 } 6615 u64() { 6616 let e4 = this.view.getBigUint64(this.x); 6617 return this.x += 8, e4; 6618 } 6619 i64() { 6620 let e4 = this.view.getBigInt64(this.x); 6621 return this.x += 8, e4; 6622 } 6623 f32() { 6624 let e4 = this.x; 6625 return this.x += 4, this.view.getFloat32(e4); 6626 } 6627 f64() { 6628 let e4 = this.x; 6629 return this.x += 8, this.view.getFloat64(e4); 6630 } 6631 utf8(e4) { 6632 let n2 = this.x; 6633 return this.x += e4, (0, t2.decodeUtf8)(this.uint8, n2, e4); 6634 } 6635 ascii(e4) { 6636 let t3 = this.uint8, n2 = ``, r2 = this.x + e4; 6637 for (let e5 = this.x; e5 < r2; e5++) n2 += String.fromCharCode(t3[e5]); 6638 return this.x = r2, n2; 6639 } 6640 }; 6641})), Nr = i(((e2) => { 6642 Object.defineProperty(e2, `__esModule`, { value: true }); 6643 var t2 = String.fromCharCode; 6644 e2.default = (e3, n2, r2) => { 6645 let i2 = n2, a2 = i2 + r2, o2 = ``; 6646 for (; i2 < a2; ) { 6647 let n3 = e3[i2++]; 6648 if (!(n3 & 128)) { 6649 o2 += t2(n3); 6650 continue; 6651 } 6652 let r3 = e3[i2++] & 63; 6653 if ((n3 & 224) == 192) { 6654 o2 += t2((n3 & 31) << 6 | r3); 6655 continue; 6656 } 6657 let a3 = e3[i2++] & 63; 6658 if ((n3 & 240) == 224) { 6659 o2 += t2((n3 & 31) << 12 | r3 << 6 | a3); 6660 continue; 6661 } 6662 if ((n3 & 248) == 240) { 6663 let s2 = e3[i2++] & 63, c2 = (n3 & 7) << 18 | r3 << 12 | a3 << 6 | s2; 6664 if (c2 > 65535) { 6665 c2 -= 65536; 6666 let e4 = c2 >>> 10 & 1023 | 55296; 6667 c2 = 56320 | c2 & 1023, o2 += t2(e4, c2); 6668 } else o2 += t2(c2); 6669 } else o2 += t2(n3); 6670 } 6671 return o2; 6672 }; 6673})), Pr = i(((t2) => { 6674 Object.defineProperty(t2, `__esModule`, { value: true }), t2.CachedUtf8Decoder = void 0; 6675 var n2 = (J(), e(f)).__importDefault(Nr()), r2 = 1 + Math.round(Math.random() * ((-1 >>> 0) - 1)); 6676 function i2(e2, t3) { 6677 return r2 ^= r2 << 13, r2 ^= r2 >>> 17, r2 ^= r2 << 5, (r2 >>> 0) % (t3 - e2 + 1) + e2; 6678 } 6679 var a2 = class { 6680 constructor(e2, t3) { 6681 this.bytes = e2, this.value = t3; 6682 } 6683 }; 6684 t2.CachedUtf8Decoder = class { 6685 constructor() { 6686 this.caches = []; 6687 for (let e2 = 0; e2 < 31; e2++) this.caches.push([]); 6688 } 6689 get(e2, t3, n3) { 6690 let r3 = this.caches[n3 - 1], i3 = r3.length; 6691 FIND_CHUNK: for (let a3 = 0; a3 < i3; a3++) { 6692 let i4 = r3[a3], o2 = i4.bytes; 6693 for (let r4 = 0; r4 < n3; r4++) if (o2[r4] !== e2[t3 + r4]) continue FIND_CHUNK; 6694 return i4.value; 6695 } 6696 return null; 6697 } 6698 store(e2, t3) { 6699 let n3 = this.caches[e2.length - 1], r3 = new a2(e2, t3); 6700 n3.length >= 16 ? n3[i2(0, 15)] = r3 : n3.push(r3); 6701 } 6702 decode(e2, t3, r3) { 6703 if (!r3) return ``; 6704 let i3 = this.get(e2, t3, r3); 6705 if (i3 !== null) return i3; 6706 let a3 = (0, n2.default)(e2, t3, r3), o2 = Uint8Array.prototype.slice.call(e2, t3, t3 + r3); 6707 return this.store(o2, a3), a3; 6708 } 6709 }; 6710})), Fr = i(((e2) => { 6711 Object.defineProperty(e2, `__esModule`, { value: true }), e2.default = new (Pr()).CachedUtf8Decoder(); 6712})), Ir = i(((t2) => { 6713 Object.defineProperty(t2, `__esModule`, { value: true }), t2.CborDecoderBase = void 0; 6714 var n2 = (J(), e(f)), r2 = Dr(), i2 = xr(), a2 = Tr(), o2 = Mr(), s2 = n2.__importDefault(Fr()); 6715 t2.CborDecoderBase = class { 6716 constructor(e2 = new o2.Reader(), t3 = s2.default) { 6717 this.reader = e2, this.keyDecoder = t3; 6718 } 6719 read(e2) { 6720 return this.reader.reset(e2), this.readAny(); 6721 } 6722 decode(e2) { 6723 return this.reader.reset(e2), this.readAny(); 6724 } 6725 val() { 6726 return this.readAny(); 6727 } 6728 readAny() { 6729 let e2 = this.reader.u8(), t3 = e2 >> 5, n3 = e2 & 31; 6730 return t3 < 4 ? t3 < 2 ? t3 === 0 ? this.readUint(n3) : this.readNint(n3) : t3 === 2 ? this.readBin(n3) : this.readStr(n3) : t3 < 6 ? t3 === 4 ? this.readArr(n3) : this.readObj(n3) : t3 === 6 ? this.readTag(n3) : this.readTkn(n3); 6731 } 6732 readAnyRaw(e2) { 6733 let t3 = e2 >> 5, n3 = e2 & 31; 6734 return t3 < 4 ? t3 < 2 ? t3 === 0 ? this.readUint(n3) : this.readNint(n3) : t3 === 2 ? this.readBin(n3) : this.readStr(n3) : t3 < 6 ? t3 === 4 ? this.readArr(n3) : this.readObj(n3) : t3 === 6 ? this.readTag(n3) : this.readTkn(n3); 6735 } 6736 readMinorLen(e2) { 6737 if (e2 < 24) return e2; 6738 switch (e2) { 6739 case 24: 6740 return this.reader.u8(); 6741 case 25: 6742 return this.reader.u16(); 6743 case 26: 6744 return this.reader.u32(); 6745 case 27: 6746 return Number(this.reader.u64()); 6747 case 31: 6748 return -1; 6749 default: 6750 throw 1; 6751 } 6752 } 6753 readUint(e2) { 6754 if (e2 < 25) return e2 === 24 ? this.reader.u8() : e2; 6755 if (e2 < 27) return e2 === 25 ? this.reader.u16() : this.reader.u32(); 6756 { 6757 let e3 = this.reader.u64(); 6758 return e3 > 9007199254740991 ? e3 : Number(e3); 6759 } 6760 } 6761 readNint(e2) { 6762 if (e2 < 25) return e2 === 24 ? -this.reader.u8() - 1 : -e2 - 1; 6763 if (e2 < 27) return e2 === 25 ? -this.reader.u16() - 1 : -this.reader.u32()
6763- 1; 6764 { 6765 let e3 = this.reader.u64(); 6766 return e3 > 9007199254740990 ? -e3 - BigInt(1) : -Number(e3) - 1; 6767 } 6768 } 6769 readBin(e2) { 6770 let t3 = this.reader; 6771 if (e2 <= 23) return t3.buf(e2); 6772 switch (e2) { 6773 case 24: 6774 return t3.buf(t3.u8()); 6775 case 25: 6776 return t3.buf(t3.u16()); 6777 case 26: 6778 return t3.buf(t3.u32()); 6779 case 27: 6780 return t3.buf(Number(t3.u64())); 6781 case 31: { 6782 let e3 = 0, t4 = []; 6783 for (; this.reader.peak() !== 255; ) { 6784 let n4 = this.readBinChunk(); 6785 e3 += n4.length, t4.push(n4); 6786 } 6787 this.reader.x++; 6788 let n3 = new Uint8Array(e3), r3 = 0, i3 = t4.length; 6789 for (let e4 = 0; e4 < i3; e4++) { 6790 let i4 = t4[e4]; 6791 n3.set(i4, r3), r3 += i4.length; 6792 } 6793 return n3; 6794 } 6795 default: 6796 throw 1; 6797 } 6798 } 6799 readBinChunk() { 6800 let e2 = this.reader.u8(), t3 = e2 >> 5, n3 = e2 & 31; 6801 if (t3 !== 2) throw 2; 6802 if (n3 > 27) throw 3; 6803 return this.readBin(n3); 6804 } 6805 readAsStr() { 6806 let e2 = this.reader.u8(), t3 = e2 >> 5, n3 = e2 & 31; 6807 if (t3 !== 3) throw 11; 6808 return this.readStr(n3); 6809 } 6810 readStr(e2) { 6811 let t3 = this.reader; 6812 if (e2 <= 23) return t3.utf8(e2); 6813 switch (e2) { 6814 case 24: 6815 return t3.utf8(t3.u8()); 6816 case 25: 6817 return t3.utf8(t3.u16()); 6818 case 26: 6819 return t3.utf8(t3.u32()); 6820 case 27: 6821 return t3.utf8(Number(t3.u64())); 6822 case 31: { 6823 let e3 = ``; 6824 for (; t3.peak() !== 255; ) e3 += this.readStrChunk(); 6825 return this.reader.x++, e3; 6826 } 6827 default: 6828 throw 1; 6829 } 6830 } 6831 readStrLen(e2) { 6832 if (e2 <= 23) return e2; 6833 switch (e2) { 6834 case 24: 6835 return this.reader.u8(); 6836 case 25: 6837 return this.reader.u16(); 6838 case 26: 6839 return this.reader.u32(); 6840 case 27: 6841 return Number(this.reader.u64()); 6842 default: 6843 throw 1; 6844 } 6845 } 6846 readStrChunk() { 6847 let e2 = this.reader.u8(), t3 = e2 >> 5, n3 = e2 & 31; 6848 if (t3 !== 3) throw 4; 6849 if (n3 > 27) throw 5; 6850 return this.readStr(n3); 6851 } 6852 readArr(e2) { 6853 let t3 = this.readMinorLen(e2); 6854 return t3 >= 0 ? this.readArrRaw(t3) : this.readArrIndef(); 6855 } 6856 readArrRaw(e2) { 6857 let t3 = []; 6858 for (let n3 = 0; n3 < e2; n3++) t3.push(this.readAny()); 6859 return t3; 6860 } 6861 readArrIndef() { 6862 let e2 = []; 6863 for (; this.reader.peak() !== 255; ) e2.push(this.readAny()); 6864 return this.reader.x++, e2; 6865 } 6866 readObj(e2) { 6867 if (e2 < 28) { 6868 let t3 = e2; 6869 switch (e2) { 6870 case 24: 6871 t3 = this.reader.u8(); 6872 break; 6873 case 25: 6874 t3 = this.reader.u16(); 6875 break; 6876 case 26: 6877 t3 = this.reader.u32(); 6878 break; 6879 case 27: 6880 t3 = Number(this.reader.u64()); 6881 break; 6882 } 6883 let n3 = {}; 6884 for (let e3 = 0; e3 < t3; e3++) { 6885 let e4 = this.key(); 6886 if (e4 === `__proto__`) throw 6; 6887 n3[e4] = this.readAny(); 6888 } 6889 return n3; 6890 } else if (e2 === 31) return this.readObjIndef(); 6891 else throw 1; 6892 } 6893 readObjRaw(e2) { 6894 let t3 = {}; 6895 for (let n3 = 0; n3 < e2; n3++) { 6896 let e3 = this.key(); 6897 t3[e3] = this.readAny(); 6898 } 6899 return t3; 6900 } 6901 readObjIndef() { 6902 let e2 = {}; 6903 for (; this.reader.peak() !== 255; ) { 6904 let t3 = this.key(); 6905 if (this.reader.peak() === 255) throw 7; 6906 e2[t3] = this.readAny(); 6907 } 6908 return this.reader.x++, e2; 6909 } 6910 key() { 6911 let e2 = this.reader.u8(), t3 = e2 >> 5, n3 = e2 & 31; 6912 if (t3 !== 3) return String(this.readAnyRaw(e2)); 6913 let r3 = this.readStrLen(n3); 6914 if (r3 > 31) return this.reader.utf8(r3); 6915 let i3 = this.keyDecoder.decode(this.reader.uint8, this.reader.x, r3); 6916 return this.reader.skip(r3), i3; 6917 } 6918 readTag(e2) { 6919 if (e2 <= 23) return this.readTagRaw(e2); 6920 switch (e2) { 6921 case 24: 6922 return this.readTagRaw(this.reader.u8()); 6923 case 25: 6924 return this.readTagRaw(this.reader.u16()); 6925 case 26: 6926 return this.readTagRaw(this.reader.u32()); 6927 case 27: 6928 return this.readTagRaw(Number(this.reader.u64())); 6929 default: 6930 throw 1; 6931 } 6932 } 6933 readTagRaw(e2) { 6934 return new i2.JsonPackExtension(e2, this.readAny()); 6935 } 6936 readTkn(e2) { 6937 switch (e2) { 6938 case 20: 6939 return false;
6940 case 21: 6941 return true; 6942 case 22: 6943 return null; 6944 case 23: 6945 return; 6946 case 24: 6947 return new a2.JsonPackValue(this.reader.u8()); 6948 case 25: 6949 return this.f16(); 6950 case 26: 6951 return this.reader.f32(); 6952 case 27: 6953 return this.reader.f64(); 6954 } 6955 if (e2 <= 23) return new a2.JsonPackValue(e2); 6956 throw 1; 6957 } 6958 f16() { 6959 return (0, r2.decodeF16)(this.reader.u16()); 6960 } 6961 }; 6962})), Lr = i(((e2) => { 6963 Object.defineProperty(e2, `__esModule`, { value: true }), e2.CborDecoder = void 0; 6964 var t2 = Ir(), n2 = Tr(); 6965 e2.CborDecoder = class extends t2.CborDecoderBase { 6966 readAsMap() { 6967 let e3 = this.reader.u8(), t3 = e3 >> 5, n3 = e3 & 31; 6968 switch (t3) { 6969 case 5: 6970 return this.readMap(n3); 6971 default: 6972 throw 0; 6973 } 6974 } 6975 readMap(e3) { 6976 let t3 = this.readMinorLen(e3); 6977 return t3 >= 0 ? this.readMapRaw(t3) : this.readMapIndef(); 6978 } 6979 readMapRaw(e3) { 6980 let t3 = /* @__PURE__ */ new Map(); 6981 for (let n3 = 0; n3 < e3; n3++) { 6982 let e4 = this.readAny(), n4 = this.readAny(); 6983 t3.set(e4, n4); 6984 } 6985 return t3; 6986 } 6987 readMapIndef() { 6988 let e3 = /* @__PURE__ */ new Map(); 6989 for (; this.reader.peak() !== 255; ) { 6990 let t3 = this.readAny(); 6991 if (this.reader.peak() === 255) throw 7; 6992 let n3 = this.readAny(); 6993 e3.set(t3, n3); 6994 } 6995 return this.reader.x++, e3; 6996 } 6997 skipN(e3) { 6998 for (let t3 = 0; t3 < e3; t3++) this.skipAny(); 6999 } 7000 skipAny() { 7001 this.skipAnyRaw(this.reader.u8()); 7002 } 7003 skipAnyRaw(e3) { 7004 let t3 = e3 >> 5, n3 = e3 & 31; 7005 switch (t3) { 7006 case 0: 7007 case 1: 7008 this.skipUNint(n3); 7009 break; 7010 case 2: 7011 this.skipBin(n3); 7012 break; 7013 case 3: 7014 this.skipStr(n3); 7015 break; 7016 case 4: 7017 this.skipArr(n3); 7018 break; 7019 case 5: 7020 this.skipObj(n3); 7021 break; 7022 case 7: 7023 this.skipTkn(n3); 7024 break; 7025 case 6: 7026 this.skipTag(n3); 7027 break; 7028 } 7029 } 7030 skipMinorLen(e3) { 7031 if (e3 <= 23) return e3; 7032 switch (e3) { 7033 case 24: 7034 return this.reader.u8(); 7035 case 25: 7036 return this.reader.u16(); 7037 case 26: 7038 return this.reader.u32(); 7039 case 27: 7040 return Number(this.reader.u64()); 7041 case 31: 7042 return -1; 7043 default: 7044 throw 1; 7045 } 7046 } 7047 skipUNint(e3) { 7048 if (!(e3 <= 23)) switch (e3) { 7049 case 24: 7050 return this.reader.skip(1); 7051 case 25: 7052 return this.reader.skip(2); 7053 case 26: 7054 return this.reader.skip(4); 7055 case 27: 7056 return this.reader.skip(8); 7057 default: 7058 throw 1; 7059 } 7060 } 7061 skipBin(e3) { 7062 let t3 = this.skipMinorLen(e3); 7063 if (t3 >= 0) this.reader.skip(t3); 7064 else { 7065 for (; this.reader.peak() !== 255; ) this.skipBinChunk(); 7066 this.reader.x++; 7067 } 7068 } 7069 skipBinChunk() { 7070 let e3 = this.reader.u8(), t3 = e3 >> 5, n3 = e3 & 31; 7071 if (t3 !== 2) throw 2; 7072 if (n3 > 27) throw 3; 7073 this.skipBin(n3); 7074 } 7075 skipStr(e3) { 7076 let t3 = this.skipMinorLen(e3); 7077 if (t3 >= 0) this.reader.skip(t3); 7078 else { 7079 for (; this.reader.peak() !== 255; ) this.skipStrChunk(); 7080 this.reader.x++; 7081 } 7082 } 7083 skipStrChunk() { 7084 let e3 = this.reader.u8(), t3 = e3 >> 5, n3 = e3 & 31; 7085 if (t3 !== 3) throw 4; 7086 if (n3 > 27) throw 5; 7087 this.skipStr(n3); 7088 } 7089 skipArr(e3) { 7090 let t3 = this.skipMinorLen(e3); 7091 if (t3 >= 0) this.skipN(t3); 7092 else { 7093 for (; this.reader.peak() !== 255; ) this.skipAny(); 7094 this.reader.x++; 7095 } 7096 } 7097 skipObj(e3) { 7098 let t3 = this.readMinorLen(e3); 7099 if (t3 >= 0) return this.skipN(t3 * 2); 7100 for (; this.reader.peak() !== 255; ) { 7101 if (this.skipAny(), this.reader.peak() === 255) throw 7; 7102 this.skipAny(); 7103 } 7104 this.reader.x++; 7105 } 7106 skipTag(e3) { 7107 if (this.skipMinorLen(e3) < 0) throw 1; 7108 this.skipAny(); 7109 } 7110 skipTkn(e3) { 7111 switch (e3) { 7112 case 24: 7113 this.reader.skip(1); 7114 return; 7115 case 25: 7116 this.reader.skip(2); 7117 return; 7118 case 26: 7119 this.reader.skip(4); 7120 return; 7121 case 27: 7122 this.reader.skip(8); 7123 return; 7124 } 7125 if (!(e3 <= 23)) throw 1; 7126 } 7127 validate(e3, t3 = 0, n3 = e3.length) { 7128 this.reader.reset(e3), this.reader.x = t3; 7129 let r2 = t3; 7130 if (this.skipAny(), this.reader.x - r2 !== n3) throw 8; 7131 } 7132 decodeLevel(e3) { 7133 return this.reader.reset(e3), this.readLevel(); 7134 } 7135 readLevel() { 7136 let e3 = this.reader.u8(), t3 = e3 >> 5, n3 = e3 & 31; 7137 switch (t3) { 7138 case 4: 7139 return this.readArrLevel(n3); 7140 case 5: 7141 return this.readObjLevel(n3); 7142 default: 7143 return super.readAnyRaw(e3); 7144 } 7145 } 7146 readPrimitiveOrVal() { 7147 switch (this.reader.peak() >> 5) { 7148 case 4: 7149 case 5: 7150 return this.readAsValue(); 7151 default: 7152 return this.readAny(); 7153 } 7154 } 7155 readAsValue() { 7156 let e3 = this.reader, t3 = e3.x; 7157 this.skipAny(); 7158 let r2 = e3.x; 7159 return new n2.JsonPackValue(e3.uint8.subarray(t3, r2)); 7160 } 7161 readObjLevel(e3) { 7162 let t3 = this.readMinorLen(e3); 7163 return t3 >= 0 ? this.readObjRawLevel(t3) : this.readObjIndefLevel(); 7164 } 7165 readObjRawLevel(e3) { 7166 let t3 = {}; 7167 for (let n3 = 0; n3 < e3; n3++) { 7168 let e4 = this.key(); 7169 t3[e4] = this.readPrimitiveOrVal(); 7170 } 7171 return t3; 7172 } 7173 readObjIndefLevel() { 7174 let e3 = {}; 7175 for (; this.reader.peak() !== 255; ) { 7176 let t3 = this.key(); 7177 if (this.reader.peak() === 255) throw 7; 7178 e3[t3] = this.readPrimitiveOrVal(); 7179 } 7180 return this.reader.x++, e3; 7181 } 7182 readArrLevel(e3) { 7183 let t3 = this.readMinorLen(e3); 7184 return t3 >= 0 ? this.readArrRawLevel(t3) : this.readArrIndefLevel(); 7185 } 7186 readArrRawLevel(e3) { 7187 let t3 = []; 7188 for (let n3 = 0; n3 < e3; n3++) t3.push(this.readPrimitiveOrVal()); 7189 return t3; 7190 } 7191 readArrIndefLevel() { 7192 let e3 = []; 7193 for (; this.reader.peak() !== 255; ) e3.push(this.readPrimitiveOrVal()); 7194 return this.reader.x++, e3; 7195 } 7196 readHdr(e3) { 7197 let t3 = this.reader.u8(); 7198 if (t3 >> 5 !== e3) throw 0; 7199 let n3 = t3 & 31; 7200 if (n3 < 24) return n3; 7201 switch (n3) { 7202 case 24: 7203 return this.reader.u8(); 7204 case 25: 7205 return this.reader.u16(); 7206 case 26: 7207 return this.reader.u32(); 7208 case 27: 7209 return Number(this.reader.u64()); 7210 case 31: 7211 return -1; 7212 } 7213 throw 1; 7214 } 7215 readStrHdr() { 7216 return this.readHdr(3); 7217 } 7218 readObjHdr() { 7219 return this.readHdr(5); 7220 } 7221 readArrHdr() { 7222 return this.readHdr(4); 7223 } 7224 findKey(e3) { 7225 let t3 = this.readObjHdr(); 7226 for (let n3 = 0; n3 < t3; n3++) { 7227 if (this.key() === e3) return this; 7228 this.skipAny(); 7229 } 7230 throw 9; 7231 } 7232 findIndex(e3) { 7233 if (e3 >= this.readArrHdr()) throw 10; 7234 for (let t3 = 0; t3 < e3; t3++) this.skipAny(); 7235 return this; 7236 } 7237 find(e3) { 7238 for (let t3 = 0; t3 < e3.length; t3++) { 7239 let n3 = e3[t3]; 7240 typeof n3 == `string` ? this.findKey(n3) : this.findIndex(n3); 7241 } 7242 return this; 7243 } 7244 }; 7245})), Rr = i(((e2) => { 7246 Object.defineProperty(e2, `__esModule`, { value: true }), e2.fromSnapshot = e2.toSnapshot = void 0, e2.toSnapshot = async ({ fs: t2, path: n2 = `/`, separator: r2 = `/` }) => { 7247 let i2 = await t2.lstat(n2); 7248 if (i2.isDirectory()) { 7249 let i3 = await t2.readdir(n2), a2 = {}, o2 = n2.endsWith(r2) ? n2 : n2 + r2, s2 = await Promise.all(i3.map((n3) => (0, e2.toSnapshot)({ fs: t2, path: `${o2}${n3}`, separator: r2 }))); 7250 for (let e3 = 0; e3 < i3.length; e3++) s2[e3] && (a2[`` + i3[e3]] = s2[e3]); 7251 return [0, {}, a2]; 7252 } else if (i2.isFile()) { 7253 let e3 = await t2.readFile(n2); 7254 return [1, {}, new Uint8Array(e3.buffer, e3.byteOffset, e3.byteLength)]; 7255 } else if (i2.isSymbolicLink()) return [2, { target: await t2.readlink(n2, { encoding: `utf8` }) }]; 7256 return null; 7257 }, e2.fromSnapshot = async (t2, { fs: n2, path: r2 = `/`, separator: i2 = `/` }) => { 7258 if (t2) switch (t2[0]) { 7259 case 0: { 7260 r2.endsWith(i2) || (r2 += i2); 7261 let [, , a2] = t2; 7262 await n2.mkdir(r2, { recursive: true }); 7263 for (let [t3, o2] of Object.entries(a2)) await (0, e2.fromSnapshot)(o2, { fs: n2, path: `${r2}${t3}`, separator: i2 }); 7264 break; 7265 } 7266 case 1: {
7267 let [, , e3] = t2; 7268 await n2.writeFile(r2, e3); 7269 break; 7270 } 7271 case 2: { 7272 let [, { target: e3 }] = t2; 7273 await n2.symlink(e3, r2); 7274 break; 7275 } 7276 } 7277 }; 7278})), zr = i(((e2) => { 7279 Object.defineProperty(e2, `__esModule`, { value: true }), e2.writer = void 0, e2.writer = new (Cr()).Writer(1024 * 32); 7280})), Br = i(((e2) => { 7281 Object.defineProperty(e2, `__esModule`, { value: true }), e2.fromBinarySnapshot = e2.toBinarySnapshot = e2.fromBinarySnapshotSync = e2.toBinarySnapshotSync = void 0; 7282 var t2 = Er(), n2 = Lr(), r2 = yr(), i2 = Rr(), a2 = zr(), o2 = new t2.CborEncoder(a2.writer), s2 = new n2.CborDecoder(); 7283 e2.toBinarySnapshotSync = (e3) => { 7284 let t3 = (0, r2.toSnapshotSync)(e3); 7285 return o2.encode(t3); 7286 }, e2.fromBinarySnapshotSync = (e3, t3) => { 7287 let n3 = s2.decode(e3); 7288 (0, r2.fromSnapshotSync)(n3, t3); 7289 }, e2.toBinarySnapshot = async (e3) => { 7290 let t3 = await (0, i2.toSnapshot)(e3); 7291 return o2.encode(t3); 7292 }, e2.fromBinarySnapshot = async (e3, t3) => { 7293 let n3 = s2.decode(e3); 7294 await (0, i2.fromSnapshot)(n3, t3); 7295 }; 7296})), Vr = i(((e2) => { 7297 s(), Object.defineProperty(e2, `__esModule`, { value: true }), e2.hasBuffer = e2.alphabet = void 0, e2.alphabet = `ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/`, e2.hasBuffer = typeof c == `function` && typeof c.from == `function`; 7298})), Hr = i(((e2) => { 7299 Object.defineProperty(e2, `__esModule`, { value: true }), e2.createToBase64Bin = void 0; 7300 var t2 = Vr(); 7301 e2.createToBase64Bin = (e3 = t2.alphabet, n2 = `=`) => { 7302 if (e3.length !== 64) throw Error(`chars must be 64 characters long`); 7303 let r2 = e3.split(``).map((e4) => e4.charCodeAt(0)), i2 = []; 7304 for (let e4 of r2) for (let t3 of r2) { 7305 let n3 = (e4 << 8) + t3; 7306 i2.push(n3); 7307 } 7308 let a2 = n2.length === 1, o2 = a2 ? n2.charCodeAt(0) : 0, s2 = a2 ? o2 << 8 | o2 : 0; 7309 return (e4, t3, n3, c2, l2) => { 7310 let u2 = n3 % 3, d2 = n3 - u2; 7311 for (; t3 < d2; t3 += 3) { 7312 let n4 = e4[t3], r3 = e4[t3 + 1], a3 = e4[t3 + 2], o3 = n4 << 4 | r3 >> 4, s3 = (r3 & 15) << 8 | a3; 7313 c2.setInt32(l2, (i2[o3] << 16) + i2[s3]), l2 += 4; 7314 } 7315 if (u2 === 1) { 7316 let t4 = e4[d2]; 7317 a2 ? (c2.setInt32(l2, (i2[t4 << 4] << 16) + s2), l2 += 4) : (c2.setInt16(l2, i2[t4 << 4]), l2 += 2); 7318 } else if (u2) { 7319 let t4 = e4[d2], n4 = e4[d2 + 1], s3 = t4 << 4 | n4 >> 4, u3 = (n4 & 15) << 2; 7320 a2 ? (c2.setInt32(l2, (i2[s3] << 16) + (r2[u3] << 8) + o2), l2 += 4) : (c2.setInt16(l2, i2[s3]), l2 += 2, c2.setInt8(l2, r2[u3]), l2 += 1); 7321 } 7322 return l2; 7323 }; 7324 }; 7325})), Ur = i(((e2) => { 7326 Object.defineProperty(e2, `__esModule`, { value: true }), e2.toBase64Bin = void 0, e2.toBase64Bin = (0, Hr().createToBase64Bin)(); 7327})), Wr = i(((e2) => { 7328 Object.defineProperty(e2, `__esModule`, { value: true }), e2.JsonEncoder = void 0; 7329 var t2 = Ur(); 7330 e2.JsonEncoder = class { 7331 constructor(e3) { 7332 this.writer = e3; 7333 } 7334 encode(e3) { 7335 let t3 = this.writer; 7336 return t3.reset(), this.writeAny(e3), t3.flush(); 7337 } 7338 writeUnknown(e3) { 7339 this.writeNull(); 7340 } 7341 writeAny(e3) { 7342 switch (typeof e3) { 7343 case `boolean`: 7344 return this.writeBoolean(e3); 7345 case `number`: 7346 return this.writeNumber(e3); 7347 case `string`: 7348 return this.writeStr(e3); 7349 case `object`: 7350 if (e3 === null) return this.writeNull(); 7351 switch (e3.constructor) { 7352 case Object: 7353 return this.writeObj(e3); 7354 case Array: 7355 return this.writeArr(e3); 7356 case Uint8Array: 7357 return this.writeBin(e3); 7358 default: 7359 return e3 instanceof Uint8Array ? this.writeBin(e3) : Array.isArray(e3) ? this.writeArr(e3) : this.writeUnknown(e3); 7360 } 7361 case `undefined`: 7362 return this.writeUndef(); 7363 default: 7364 return this.writeUnknown(e3); 7365 } 7366 } 7367 writeNull() { 7368 this.writer.u32(1853189228); 7369 } 7370 writeUndef() { 7371 let e3 = this.writer; 7372 e3.ensureCapacity(35); 7373 let t3 = e3.view, n2 = e3.x; 7374 t3.setUint32(n2, 577003892), n2 += 4, t3.setUint32(n2, 1631215984), n2 += 4, t3.setUint32(n2, 1886153059), n2 += 4, t3.setUint32(n2, 1635019119), n2 += 4, t3.setUint32(n2, 1848599394), n2 += 4, t3.setUint32(n2, 1869753442), n2 += 4, t3.setUint32(n2, 1634952502), n2 += 4, t3.setUint32(n2, 876296567), n2 += 4, t3.setUint16(n2, 15677), n2 += 2, e3.uint8[n2++] = 34, e3.x = n2; 7375 } 7376 writeBoolean(e3) { 7377 e3 ? this.writer.u32(1953658213) : this.writer.u8u32(102, 1634497381); 7378 } 7379 writeNumber(e3) { 7380 let t3 = e3.toString(); 7381 this.writer.ascii(t3); 7382 } 7383 writeInteger(e3) { 7384 this.writeNumber(e3 >> 0 === e3 ? e3 : Math.trunc(e3)); 7385 } 7386 writeUInteger(e3) { 7387 this.writeInteger(e3 < 0 ? -e3 : e3); 7388 } 7389 writeFloat(e3) { 7390 this.writeNumber(e3); 7391 } 7392 writeBin(e3) { 7393 let n2 = this.writer, r2 = e3.length; 7394 n2.ensureCapacity(41 + (r2 << 1)); 7395 let i2 = n2.view, a2 = n2.x; 7396 i2.setUint32(a2, 577003892), a2 += 4, i2.setUint32(a2, 1631215984), a2 += 4, i2.setUint32(a2, 1886153059), a2 += 4, i2.setUint32(a2, 1635019119), a2 += 4, i2.setUint32(a2, 1848602467), a2 += 4, i2.setUint32(a2, 1952805933), a2 += 4, i2.setUint32(a2, 1937011301), a2 += 4, i2.setUint32(a2, 1634548578), a2 += 4, i2.setUint32(a2, 1634952502), a2 += 4, i2.setUint16(a2, 13356), a2 += 2, a2 = (0, t2.toBase64Bin)(e3, 0, r2, i2, a2), n2.uint8[a2++] = 34, n2.x = a2; 7397 } 7398 writeStr(e3) { 7399 let t3 = this.writer, n2 = e3.length; 7400 if (t3.ensureCapacity(n2 * 4 + 2), n2 < 256) { 7401 let r3 = t3.x, i2 = r3, a2 = t3.uint8; 7402 a2[i2++] = 34; 7403 for (let o2 = 0; o2 < n2; o2++) { 7404 let n3 = e3.charCodeAt(o2); 7405 switch (n3) { 7406 case 34: 7407 case 92: 7408 a2[i2++] = 92; 7409 break; 7410 } 7411 if (n3 < 32 || n3 > 126) { 7412 t3.x = r3; 7413 let n4 = JSON.stringify(e3); 7414 t3.ensureCapacity(n4.length * 4 + 4), t3.utf8(n4); 7415 return; 7416 } else a2[i2++] = n3; 7417 } 7418 a2[i2++] = 34, t3.x = i2; 7419 return; 7420 } 7421 let r2 = JSON.stringify(e3); 7422 t3.ensureCapacity(r2.length * 4 + 4), t3.utf8(r2); 7423 } 7424 writeAsciiStr(e3) { 7425 let t3 = e3.length, n2 = this.writer; 7426 n2.ensureCapacity(t3 * 2 + 2); 7427 let r2 = n2.uint8, i2 = n2.x; 7428 r2[i2++] = 34; 7429 for (let n3 = 0; n3 < t3; n3++) { 7430 let t4 = e3.charCodeAt(n3); 7431 switch (t4) { 7432 case 34: 7433 case 92: 7434 r2[i2++] = 92; 7435 break; 7436 } 7437 r2[i2++] = t4; 7438 } 7439 r2[i2++] = 34, n2.x = i2; 7440 } 7441 writeArr(e3) { 7442 let t3 = this.writer; 7443 t3.u8(91); 7444 let n2 = e3.length - 1; 7445 for (let r2 = 0; r2 < n2; r2++) this.writeAny(e3[r2]), t3.u8(44); 7446 n2 >= 0 && this.writeAny(e3[n2]), t3.u8(93); 7447 } 7448 writeArrSeparator() { 7449 this.writer.u8(44); 7450 } 7451 writeObj(e3) { 7452 let t3 = this.writer, n2 = Object.keys(e3), r2 = n2.length; 7453 if (!r2) return t3.u16(31613); 7454 t3.u8(123); 7455 for (let i2 = 0; i2 < r2; i2++) { 7456 let r3 = n2[i2], a2 = e3[r3]; 7457 this.writeStr(r3), t3.u8(58), this.writeAny(a2), t3.u8(44); 7458 } 7459 t3.uint8[t3.x - 1] = 125; 7460 } 7461 writeObjSeparator() { 7462 this.writer.u8(44); 7463 } 7464 writeObjKeySeparator() { 7465 this.writer.u8(58); 7466 } 7467 writeStartStr() { 7468 throw Error(`Method not implemented.`); 7469 } 7470 writeStrChunk(e3) { 7471 throw Error(`Method not implemented.`); 7472 } 7473 writeEndStr() { 7474 throw Error(`Method not implemented.`); 7475 } 7476 writeStartBin() { 7477 throw Error(`Method not implemented.`); 7478 } 7479 writeBinChunk(e3) { 7480 throw Error(`Method not implemented.`); 7481 } 7482 writeEndBin() { 7483 throw Error(`Method not implemented.`); 7484 } 7485 writeStartArr() { 7486 this.writer.u8(91); 7487 } 7488 writeArrChunk(e3) { 7489 throw Error(`Method not implemented.`); 7490 } 7491 writeEndArr() { 7492 this.writer.u8(93); 7493 } 7494 writeStartObj() { 7495 this.writer.u8(123); 7496 } 7497 writeObjChunk(e3, t3) { 7498 throw Error(`Method not implemented.`); 7499 } 7500 writeEndObj() { 7501 this.writer.u8(125); 7502 } 7503 }; 7504})), Gr = i(((e2) => { 7505 Object.defineProperty(e2, `__esModule`, { value: true }
7505), e2.createFromBase64Bin = void 0; 7506 var t2 = Vr(); 7507 e2.createFromBase64Bin = (e3 = t2.alphabet, n2 = `=`) => { 7508 if (e3.length !== 64) throw Error(`chars must be 64 characters long`); 7509 let r2 = 0; 7510 for (let t3 = 0; t3 < e3.length; t3++) r2 = Math.max(r2, e3.charCodeAt(t3)); 7511 let i2 = []; 7512 for (let e4 = 0; e4 <= r2; e4 += 1) i2[e4] = -1; 7513 for (let t3 = 0; t3 < e3.length; t3++) i2[e3.charCodeAt(t3)] = t3; 7514 let a2 = n2.length === 1 ? n2.charCodeAt(0) : 0; 7515 return (e4, t3, n3) => { 7516 if (!n3) return new Uint8Array(); 7517 let r3 = 0; 7518 if (n3 % 4 != 0) r3 = 4 - n3 % 4, n3 += r3; 7519 else { 7520 let i3 = t3 + n3 - 1; 7521 e4.getUint8(i3) === a2 && (r3 = 1, n3 > 1 && e4.getUint8(i3 - 1) === a2 && (r3 = 2)); 7522 } 7523 if (n3 % 4 != 0) throw Error(`Base64 string length must be a multiple of 4`); 7524 let o2 = t3 + n3 - (r3 ? 4 : 0), s2 = (n3 >> 2) * 3 - r3, c2 = new Uint8Array(s2), l2 = 0, u2 = t3; 7525 for (; u2 < o2; u2 += 4) { 7526 let t4 = e4.getUint32(u2), n4 = t4 >>> 24, r4 = t4 >>> 16 & 255, a3 = t4 >>> 8 & 255, o3 = t4 & 255, s3 = i2[n4], d3 = i2[r4], f3 = i2[a3], p3 = i2[o3]; 7527 if (s3 < 0 || d3 < 0 || f3 < 0 || p3 < 0) throw Error(`INVALID_BASE64_SEQ`); 7528 c2[l2] = s3 << 2 | d3 >> 4, c2[l2 + 1] = d3 << 4 | f3 >> 2, c2[l2 + 2] = f3 << 6 | p3, l2 += 3; 7529 } 7530 if (!r3) return c2; 7531 if (r3 === 1) { 7532 let t4 = e4.getUint16(o2), n4 = t4 >> 8, r4 = t4 & 255, a3 = e4.getUint8(o2 + 2), s3 = i2[n4], u3 = i2[r4], d3 = i2[a3]; 7533 if (s3 < 0 || u3 < 0 || d3 < 0) throw Error(`INVALID_BASE64_SEQ`); 7534 return c2[l2] = s3 << 2 | u3 >> 4, c2[l2 + 1] = u3 << 4 | d3 >> 2, c2; 7535 } 7536 let d2 = e4.getUint16(o2), f2 = d2 >> 8, p2 = d2 & 255, m2 = i2[f2], h2 = i2[p2]; 7537 if (m2 < 0 || h2 < 0) throw Error(`INVALID_BASE64_SEQ`); 7538 return c2[l2] = m2 << 2 | h2 >> 4, c2; 7539 }; 7540 }; 7541})), Kr = i(((e2) => { 7542 Object.defineProperty(e2, `__esModule`, { value: true }), e2.fromBase64Bin = void 0, e2.fromBase64Bin = (0, Gr().createFromBase64Bin)(); 7543})), qr = i(((e2) => { 7544 Object.defineProperty(e2, `__esModule`, { value: true }), e2.findEndingQuote = void 0, e2.findEndingQuote = (e3, t2) => { 7545 let n2 = e3.length, r2 = e3[t2], i2 = 0; 7546 for (; t2 < n2 && !(r2 === 34 && i2 !== 92); ) i2 = r2 === 92 && i2 === 92 ? 0 : r2, r2 = e3[++t2]; 7547 if (t2 === n2) throw Error(`Invalid JSON`); 7548 return t2; 7549 }; 7550})), Jr = i(((e2) => { 7551 Object.defineProperty(e2, `__esModule`, { value: true }), e2.JsonDecoder = e2.readKey = void 0; 7552 var t2 = jr(), n2 = Mr(), r2 = Kr(), i2 = qr(), a2 = /\\(b|f|n|r|t|"|\/|\\)/g, o2 = (e3) => { 7553 switch (e3) { 7554 case `\\b`: 7555 return `\b`; 7556 case `\\f`: 7557 return `\f`; 7558 case `\\n`: 7559 return ` 7560`; 7561 case `\\r`: 7562 return `\r`; 7563 case `\\t`: 7564 return ` `; 7565 case `\\"`: 7566 return `"`; 7567 case `\\/`: 7568 return `/`; 7569 case `\\\\`: 7570 return `\\`; 7571 } 7572 return e3; 7573 }, s2 = (e3, t3) => e3[t3] === 100 && e3[t3 + 1] === 97 && e3[t3 + 2] === 116 && e3[t3 + 3] === 97 && e3[t3 + 4] === 58 && e3[t3 + 5] === 97 && e3[t3 + 6] === 112 && e3[t3 + 7] === 112 && e3[t3 + 8] === 108 && e3[t3 + 9] === 105 && e3[t3 + 10] === 99 && e3[t3 + 11] === 97 && e3[t3 + 12] === 116 && e3[t3 + 13] === 105 && e3[t3 + 14] === 111 && e3[t3 + 15] === 110 && e3[t3 + 16] === 47 && e3[t3 + 17] === 111 && e3[t3 + 18] === 99 && e3[t3 + 19] === 116 && e3[t3 + 20] === 101 && e3[t3 + 21] === 116 && e3[t3 + 22] === 45 && e3[t3 + 23] === 115 && e3[t3 + 24] === 116 && e3[t3 + 25] === 114 && e3[t3 + 26] === 101 && e3[t3 + 27] === 97 && e3[t3 + 28] === 109 && e3[t3 + 29] === 59 && e3[t3 + 30] === 98 && e3[t3 + 31] === 97 && e3[t3 + 32] === 115 && e3[t3 + 33] === 101 && e3[t3 + 34] === 54 && e3[t3 + 35] === 52 && e3[t3 + 36] === 44, c2 = (e3, t3) => e3[t3++] === 97 && e3[t3++] === 116 && e3[t3++] === 97 && e3[t3++] === 58 && e3[t3++] === 97 && e3[t3++] === 112 && e3[t3++] === 112 && e3[t3++] === 108 && e3[t3++] === 105 && e3[t3++] === 99 && e3[t3++] === 97 && e3[t3++] === 116 && e3[t3++] === 105 && e3[t3++] === 111 && e3[t3++] === 110 && e3[t3++] === 47 && e3[t3++] === 99 && e3[t3++] === 98 && e3[t3++] === 111 && e3[t3++] === 114 && e3[t3++] === 44 && e3[t3++] === 98 && e3[t3++] === 97 && e3[t3++] === 115 && e3[t3++] === 101 && e3[t3++] === 54 && e3[t3++] === 52 && e3[t3++] === 59 && e3[t3++] === 57 && e3[t3++] === 119 && e3[t3++] === 61 && e3[t3++] === 61 && e3[t3++] === 34, l2 = String.fromCharCode; 7574 e2.readKey = (e3) => { 7575 let t3 = e3.uint8, n3 = t3.length, r3 = [], i3 = e3.x, a3 = 0; 7576 for (; i3 < n3; ) { 7577 let e4 = t3[i3++]; 7578 if (e4 & 128) { 7579 let n4 = t3[i3++] & 63; 7580 if ((e4 & 224) == 192) e4 = (e4 & 31) << 6 | n4; 7581 else { 7582 let a4 = t3[i3++] & 63; 7583 if ((e4 & 240) == 224) e4 = (e4 & 31) << 12 | n4 << 6 | a4; 7584 else if ((e4 & 248) == 240) { 7585 let o3 = t3[i3++] & 63, s3 = (e4 & 7) << 18 | n4 << 12 | a4 << 6 | o3; 7586 if (s3 > 65535) { 7587 s3 -= 65536; 7588 let t4 = s3 >>> 10 & 1023 | 55296; 7589 s3 = 56320 | s3 & 1023, r3.push(t4), e4 = s3; 7590 } else e4 = s3; 7591 } 7592 } 7593 } else if (a3 === 92) { 7594 switch (e4) { 7595 case 98: 7596 e4 = 8; 7597 break; 7598 case 102: 7599 e4 = 12; 7600 break; 7601 case 110: 7602 e4 = 10; 7603 break; 7604 case 114: 7605 e4 = 13; 7606 break; 7607 case 116: 7608 e4 = 9; 7609 break; 7610 case 34: 7611 e4 = 34; 7612 break; 7613 case 47: 7614 e4 = 47; 7615 break; 7616 case 92: 7617 e4 = 92; 7618 break; 7619 default: 7620 throw Error(`Invalid JSON`); 7621 } 7622 a3 = 0; 7623 } else { 7624 if (e4 === 34) break; 7625 if (a3 = e4, a3 === 92) continue; 7626 } 7627 r3.push(e4); 7628 } 7629 return e3.x = i3, l2.apply(String, r3); 7630 }, e2.JsonDecoder = class { 7631 constructor() { 7632 this.reader = new n2.Reader(); 7633 } 7634 read(e3) { 7635 return this.reader.reset(e3), this.readAny(); 7636 } 7637 decode(e3) { 7638 return this.reader.reset(e3), this.readAny(); 7639 } 7640 readAny() { 7641 this.skipWhitespace(); 7642 let e3 = this.reader, t3 = e3.x, n3 = e3.uint8, r3 = n3[t3]; 7643 switch (r3) { 7644 case 34: 7645 if (n3[t3 + 1] === 100) { 7646 let r4 = this.tryReadBin(); 7647 if (r4) return r4; 7648 if (c2(n3, t3 + 2)) { 7649 e3.x = t3 + 35; 7650 return; 7651 } 7652 } 7653 return this.readStr(); 7654 case 91: 7655 return this.readArr(); 7656 case 102: 7657 return this.readFalse(); 7658 case 110: 7659 return this.readNull(); 7660 case 116: 7661 return this.readTrue(); 7662 case 123: 7663 return this.readObj(); 7664 default: 7665 if (r3 >= 48 && r3 <= 57 || r3 === 45) return this.readNum(); 7666 throw Error(`Invalid JSON`); 7667 } 7668 } 7669 skipWhitespace() { 7670 let e3 = this.reader, t3 = e3.uint8, n3 = e3.x, r3 = 0; 7671 for (; ; ) switch (r3 = t3[n3], r3) { 7672 case 32: 7673 case 9: 7674 case 10: 7675 case 13: 7676 n3++; 7677 continue; 7678 default: 7679 e3.x = n3; 7680 return; 7681 } 7682 } 7683 readNull() { 7684 if (this.reader.u32() !== 1853189228) throw Error(`Invalid JSON`); 7685 return null; 7686 } 7687 readTrue() { 7688 if (this.reader.u32() !== 1953658213) throw Error(`Invalid JSON`); 7689 return true; 7690 } 7691 readFalse() { 7692 let e3 = this.reader; 7693 if (e3.u8() !== 102 || e3.u32() !== 1634497381) throw Error(`Invalid JSON`); 7694 return false;
7695 } 7696 readBool() { 7697 let e3 = this.reader; 7698 switch (e3.uint8[e3.x]) { 7699 case 102: 7700 return this.readFalse(); 7701 case 116: 7702 return this.readTrue(); 7703 default: 7704 throw Error(`Invalid JSON`); 7705 } 7706 } 7707 readNum() { 7708 let e3 = this.reader, t3 = e3.uint8, n3 = e3.x, r3 = t3[n3++], i3 = r3; 7709 if (r3 = t3[n3++], !r3 || (r3 < 45 || r3 > 57) && r3 !== 43 && r3 !== 69 && r3 !== 101) { 7710 e3.x = n3 - 1; 7711 let t4 = +l2(i3); 7712 if (t4 !== t4) throw Error(`Invalid JSON`); 7713 return t4; 7714 } 7715 let a3 = r3; 7716 if (r3 = t3[n3++], !r3 || (r3 < 45 || r3 > 57) && r3 !== 43 && r3 !== 69 && r3 !== 101) { 7717 e3.x = n3 - 1; 7718 let t4 = +l2(i3, a3); 7719 if (t4 !== t4) throw Error(`Invalid JSON`); 7720 return t4; 7721 } 7722 let o3 = r3; 7723 if (r3 = t3[n3++], !r3 || (r3 < 45 || r3 > 57) && r3 !== 43 && r3 !== 69 && r3 !== 101) { 7724 e3.x = n3 - 1; 7725 let t4 = +l2(i3, a3, o3); 7726 if (t4 !== t4) throw Error(`Invalid JSON`); 7727 return t4; 7728 } 7729 let s3 = r3; 7730 if (r3 = t3[n3++], !r3 || (r3 < 45 || r3 > 57) && r3 !== 43 && r3 !== 69 && r3 !== 101) { 7731 e3.x = n3 - 1; 7732 let t4 = +l2(i3, a3, o3, s3); 7733 if (t4 !== t4) throw Error(`Invalid JSON`); 7734 return t4; 7735 } 7736 let c3 = r3; 7737 if (r3 = t3[n3++], !r3 || (r3 < 45 || r3 > 57) && r3 !== 43 && r3 !== 69 && r3 !== 101) { 7738 e3.x = n3 - 1; 7739 let t4 = +l2(i3, a3, o3, s3, c3); 7740 if (t4 !== t4) throw Error(`Invalid JSON`); 7741 return t4; 7742 } 7743 let u2 = r3; 7744 if (r3 = t3[n3++], !r3 || (r3 < 45 || r3 > 57) && r3 !== 43 && r3 !== 69 && r3 !== 101) { 7745 e3.x = n3 - 1; 7746 let t4 = +l2(i3, a3, o3, s3, c3, u2); 7747 if (t4 !== t4) throw Error(`Invalid JSON`); 7748 return t4; 7749 } 7750 let d2 = r3; 7751 if (r3 = t3[n3++], !r3 || (r3 < 45 || r3 > 57) && r3 !== 43 && r3 !== 69 && r3 !== 101) { 7752 e3.x = n3 - 1; 7753 let t4 = +l2(i3, a3, o3, s3, c3, u2, d2); 7754 if (t4 !== t4) throw Error(`Invalid JSON`); 7755 return t4; 7756 } 7757 let f2 = r3; 7758 if (r3 = t3[n3++], !r3 || (r3 < 45 || r3 > 57) && r3 !== 43 && r3 !== 69 && r3 !== 101) { 7759 e3.x = n3 - 1; 7760 let t4 = +l2(i3, a3, o3, s3, c3, u2, d2, f2); 7761 if (t4 !== t4) throw Error(`Invalid JSON`); 7762 return t4; 7763 } 7764 let p2 = r3; 7765 if (r3 = t3[n3++], !r3 || (r3 < 45 || r3 > 57) && r3 !== 43 && r3 !== 69 && r3 !== 101) { 7766 e3.x = n3 - 1; 7767 let t4 = +l2(i3, a3, o3, s3, c3, u2, d2, f2, p2); 7768 if (t4 !== t4) throw Error(`Invalid JSON`); 7769 return t4; 7770 } 7771 let m2 = r3; 7772 if (r3 = t3[n3++], !r3 || (r3 < 45 || r3 > 57) && r3 !== 43 && r3 !== 69 && r3 !== 101) { 7773 e3.x = n3 - 1; 7774 let t4 = +l2(i3, a3, o3, s3, c3, u2, d2, f2, p2, m2); 7775 if (t4 !== t4) throw Error(`Invalid JSON`); 7776 return t4; 7777 } 7778 let h2 = r3; 7779 if (r3 = t3[n3++], !r3 || (r3 < 45 || r3 > 57) && r3 !== 43 && r3 !== 69 && r3 !== 101) { 7780 e3.x = n3 - 1; 7781 let t4 = +l2(i3, a3, o3, s3, c3, u2, d2, f2, p2, m2, h2); 7782 if (t4 !== t4) throw Error(`Invalid JSON`); 7783 return t4; 7784 } 7785 let g2 = r3; 7786 if (r3 = t3[n3++], !r3 || (r3 < 45 || r3 > 57) && r3 !== 43 && r3 !== 69 && r3 !== 101) { 7787 e3.x = n3 - 1; 7788 let t4 = +l2(i3, a3, o3, s3, c3, u2, d2, f2, p2, m2, h2, g2); 7789 if (t4 !== t4) throw Error(`Invalid JSON`); 7790 return t4; 7791 } 7792 let _2 = r3; 7793 if (r3 = t3[n3++], !r3 || (r3 < 45 || r3 > 57) && r3 !== 43 && r3 !== 69 && r3 !== 101) { 7794 e3.x = n3 - 1; 7795 let t4 = +l2(i3, a3, o3, s3, c3, u2, d2, f2, p2, m2, h2, g2, _2); 7796 if (t4 !== t4) throw Error(`Invalid JSON`); 7797 return t4; 7798 } 7799 let v2 = r3; 7800 if (r3 = t3[n3++], !r3 || (r3 < 45 || r3 > 57) && r3 !== 43 && r3 !== 69 && r3 !== 101) { 7801 e3.x = n3 - 1; 7802 let t4 = +l2(i3, a3, o3, s3, c3, u2, d2, f2, p2, m2, h2, g2, _2, v2); 7803 if (t4 !== t4) throw Error(`Invalid JSON`); 7804 return t4; 7805 } 7806 let y2 = r3; 7807 if (r3 = t3[n3++], !r3 || (r3 < 45 || r3 > 57) && r3 !== 43 && r3 !== 69 && r3 !== 101) { 7808 e3.x = n3 - 1; 7809 let t4 = +l2(i3, a3, o3, s3, c3, u2, d2, f2, p2, m2, h2, g2, _2, v2, y2); 7810 if (t4 !== t4) throw Error(`Invalid JSON`); 7811 return t4; 7812 } 7813 let b2 = r3; 7814 if (r3 = t3[n3++], !r3 || (r3 < 45 || r3 > 57) && r3 !== 43 && r3 !== 69 && r3 !== 101) { 7815 e3.x = n3 - 1; 7816 let t4 = +l2(i3, a3, o3, s3, c3, u2, d2, f2, p2, m2, h2, g2, _2, v2, y2, b2); 7817 if (t4 !== t4) throw Error(`Invalid JSON`); 7818 return t4; 7819 } 7820 let x2 = r3; 7821 if (r3 = t3[n3++], !r3 || (r3 < 45 || r3 > 57) && r3 !== 43 && r3 !== 69 && r3 !== 101) { 7822 e3.x = n3 - 1; 7823 let t4 = +l2(i3, a3, o3, s3, c3, u2, d2, f2, p2, m2, h2, g2, _2, v2, y2, b2, x2); 7824 if (t4 !== t4) throw Error(`Invalid JSON`); 7825 return t4; 7826 } 7827 let S2 = r3; 7828 if (r3 = t3[n3++], !r3 || (r3 < 45 || r3 > 57) && r3 !== 43 && r3 !== 69 && r3 !== 101) { 7829 e3.x = n3 - 1; 7830 let t4 = +l2(i3, a3, o3, s3, c3, u2, d2, f2, p2, m2, h2, g2, _2, v2, y2, b2, x2, S2); 7831 if (t4 !== t4) throw Error(`Invalid JSON`); 7832 return t4; 7833 } 7834 let C2 = r3; 7835 if (r3 = t3[n3++], !r3 || (r3 < 45 || r3 > 57) && r3 !== 43 && r3 !== 69 && r3 !== 101) { 7836 e3.x = n3 - 1; 7837 let t4 = +l2(i3, a3, o3, s3, c3, u2, d2, f2, p2, m2, h2, g2, _2, v2, y2, b2, x2, S2, C2); 7838 if (t4 !== t4) throw Error(`Invalid JSON`); 7839 return t4; 7840 } 7841 let w2 = r3; 7842 if (r3 = t3[n3++], !r3 || (r3 < 45 || r3 > 57) && r3 !== 43 && r3 !== 69 && r3 !== 101) { 7843 e3.x = n3 - 1; 7844 let t4 = +l2(i3, a3, o3, s3, c3, u2, d2, f2, p2, m2, h2, g2, _2, v2, y2, b2, x2, S2, C2, w2); 7845 if (t4 !== t4) throw Error(`Invalid JSON`); 7846 return t4; 7847 } 7848 let T2 = r3; 7849 if (r3 = t3[n3++], !r3 || (r3 < 45 || r3 > 57) && r3 !== 43 && r3 !== 69 && r3 !== 101) { 7850 e3.x = n3 - 1; 7851 let t4 = +l2(i3, a3, o3, s3, c3, u2, d2, f2, p2, m2, h2, g2, _2, v2, y2, b2, x2, S2, C2, w2, T2); 7852 if (t4 !== t4) throw Error(`Invalid JSON`); 7853 return t4; 7854 } 7855 let E2 = r3; 7856 if (r3 = t3[n3++], !r3 || (r3 < 45 || r3 > 57) && r3 !== 43 && r3 !== 69 && r3 !== 101) { 7857 e3.x = n3 - 1; 7858 let t4 = +l2(i3, a3, o3, s3, c3, u2, d2, f2, p2, m2, h2, g2, _2, v2, y2, b2, x2, S2, C2, w2, T2, E2); 7859 if (t4 !== t4) throw Error(`Invalid JSON`); 7860 return t4; 7861 } 7862 let D2 = r3; 7863 if (r3 = t3[n3++], !r3 || (r3 < 45 || r3 > 57) && r3 !== 43 && r3 !== 69 && r3 !== 101) { 7864 e3.x = n3 - 1; 7865 let t4 = +l2(i3, a3, o3, s3, c3, u2, d2, f2, p2, m2, h2, g2, _2, v2, y2, b2, x2, S2, C2, w2, T2, E2, D2); 7866 if (t4 !== t4) throw Error(`Invalid JSON`); 7867 return t4; 7868 } 7869 let O2 = r3; 7870 if (r3 = t3[n3++], !r3 || (r3 < 45 || r3 > 57) && r3 !== 43 && r3 !== 69 && r3 !== 101) { 7871 e3.x = n3 - 1; 7872 let t4 = +l2(i3, a3, o3, s3, c3, u2, d2, f2, p2, m2, h2, g2, _2, v2, y2, b2, x2, S2, C2, w2, T2, E2, D2, O2); 7873 if (t4 !== t4) throw Error(`Invalid JSON`); 7874 return t4; 7875 } 7876 throw Error(`Invalid JSON`); 7877 } 7878 readStr() { 7879 let e3 = this.reader, n3 = e3.uint8; 7880 if (n3[e3.x++] !== 34) throw Error(`Invalid JSON`); 7881 let r3 = e3.x, s3 = (0, i2.findEndingQuote)(n3, r3), c3 = (0, t2.decodeUtf8)(n3, r3, s3 - r3); 7882 return c3 = c3.replace(a2, o2), e3.x = s3 + 1, c3; 7883 } 7884 tryReadBin() { 7885 let e3 = this.reader, t3 = e3.uint8, n3 = e3.x; 7886 if (t3[n3++] !== 34 || !s2(t3, n3)) return; 7887 n3 += 37; 7888 let a3 = n3; 7889 n3 = (0, i2.findEndingQuote)(t3, n3), e3.x = a3; 7890 let o3 = (0, r2.fromBase64Bin)(e3.view, a3, n3 - a3); 7891 return e3.x = n3 + 1, o3; 7892 } 7893 readBin() { 7894 let e3 = this.reader, t3 = e3.uint8, n3 = e3.x; 7895 if (t3[n3++] !== 34 || !s2(t3, n3)) throw Error(`Invalid JSON`); 7896 n3 += 37; 7897 let a3 = n3; 7898 n3 = (0, i2.findEndingQuote)(t3, n3), e3.x = a3; 7899 let o3 = (0, r2.fromBase64Bin)(e3.view, a3, n3 - a3); 7900 return e3.x = n3 + 1, o3; 7901 } 7902 readArr() { 7903 let e3 = this.reader; 7904 if (e3.u8() !== 91) throw Error(`Invalid JSON`); 7905 let t3 = [], n3 = e3.uint8, r3 = true; 7906 for (; ; ) { 7907 this.skipWhitespace(); 7908 let i3 = n3[e3.x]; 7909 if (i3 === 93) return e3.x++, t3; 7910 if (i3 === 44) e3.x++; 7911 else if (!r3) throw Error(`Invalid JSON`); 7912 this.skipWhitespace(), t3.push(this.readAny()), r3 = false;
7913 } 7914 } 7915 readObj() { 7916 let t3 = this.reader; 7917 if (t3.u8() !== 123) throw Error(`Invalid JSON`); 7918 let n3 = {}, r3 = t3.uint8, i3 = true; 7919 for (; ; ) { 7920 this.skipWhitespace(); 7921 let a3 = r3[t3.x]; 7922 if (a3 === 125) return t3.x++, n3; 7923 if (a3 === 44) t3.x++; 7924 else if (!i3) throw Error(`Invalid JSON`); 7925 if (this.skipWhitespace(), a3 = r3[t3.x++], a3 !== 34) throw Error(`Invalid JSON`); 7926 let o3 = (0, e2.readKey)(t3); 7927 if (o3 === `__proto__` || (this.skipWhitespace(), t3.u8() !== 58)) throw Error(`Invalid JSON`); 7928 this.skipWhitespace(), n3[o3] = this.readAny(), i3 = false; 7929 } 7930 } 7931 }; 7932})), Yr = i(((e2) => { 7933 Object.defineProperty(e2, `__esModule`, { value: true }), e2.fromJsonSnapshot = e2.toJsonSnapshot = e2.fromJsonSnapshotSync = e2.toJsonSnapshotSync = void 0; 7934 var t2 = Wr(), n2 = Jr(), r2 = yr(), i2 = Rr(), a2 = zr(), o2 = new t2.JsonEncoder(a2.writer), s2 = new n2.JsonDecoder(); 7935 e2.toJsonSnapshotSync = (e3) => { 7936 let t3 = (0, r2.toSnapshotSync)(e3); 7937 return o2.encode(t3); 7938 }, e2.fromJsonSnapshotSync = (e3, t3) => { 7939 let n3 = s2.read(e3); 7940 (0, r2.fromSnapshotSync)(n3, t3); 7941 }, e2.toJsonSnapshot = async (e3) => { 7942 let t3 = await (0, i2.toSnapshot)(e3); 7943 return o2.encode(t3); 7944 }, e2.fromJsonSnapshot = async (e3, t3) => { 7945 let n3 = s2.read(e3); 7946 await (0, i2.fromSnapshot)(n3, t3); 7947 }; 7948})), Xr = i(((t2) => { 7949 Object.defineProperty(t2, `__esModule`, { value: true }); 7950 var n2 = (J(), e(f)); 7951 n2.__exportStar(vr(), t2), n2.__exportStar(yr(), t2), n2.__exportStar(Br(), t2), n2.__exportStar(Yr(), t2); 7952})), Zr = i(((e2) => { 7953 Object.defineProperty(e2, `__esModule`, { value: true }), e2.getWriteFileOptions = e2.writeFileDefaults = e2.getRealpathOptsAndCb = e2.getRealpathOptions = e2.getStatfsOptsAndCb = e2.getStatfsOptions = e2.getStatOptsAndCb = e2.getStatOptions = e2.getAppendFileOptsAndCb = e2.getAppendFileOpts = e2.getOpendirOptsAndCb = e2.getOpendirOptions = e2.getReaddirOptsAndCb = e2.getReaddirOptions = e2.getReadFileOptions = e2.getRmOptsAndCb = e2.getRmdirOptions = e2.getDefaultOptsAndCb = e2.getDefaultOpts = e2.optsDefaults = e2.getMkdirOptions = void 0, e2.getOptions = a2, e2.optsGenerator = o2, e2.optsAndCbGenerator = s2; 7954 var t2 = $(), n2 = ur(), r2 = { mode: 511, recursive: false }; 7955 e2.getMkdirOptions = (e3) => typeof e3 == `number` ? Object.assign({}, r2, { mode: e3 }) : Object.assign({}, r2, e3); 7956 var i2 = (e3) => `Expected options to be either an object or a string, but got ${e3} instead`; 7957 function a2(e3, n3) { 7958 let r3; 7959 if (n3) { 7960 let t3 = typeof n3; 7961 switch (t3) { 7962 case `string`: 7963 r3 = Object.assign({}, e3, { encoding: n3 }); 7964 break; 7965 case `object`: 7966 r3 = Object.assign({}, e3, n3); 7967 break; 7968 default: 7969 throw TypeError(i2(t3)); 7970 } 7971 } else return e3; 7972 return r3.encoding !== `buffer` && (0, t2.assertEncoding)(r3.encoding), r3; 7973 } 7974 function o2(e3) { 7975 return (t3) => a2(e3, t3); 7976 } 7977 function s2(e3) { 7978 return (t3, r3) => typeof t3 == `function` ? [e3(), t3] : [e3(t3), (0, n2.validateCallback)(r3)]; 7979 } 7980 e2.optsDefaults = { encoding: `utf8` }, e2.getDefaultOpts = o2(e2.optsDefaults), e2.getDefaultOptsAndCb = s2(e2.getDefaultOpts); 7981 var c2 = { recursive: false }; 7982 e2.getRmdirOptions = (e3) => Object.assign({}, c2, e3), e2.getRmOptsAndCb = s2(o2(e2.optsDefaults)), e2.getReadFileOptions = o2({ flag: `r` }), e2.getReaddirOptions = o2({ encoding: `utf8`, recursive: false, withFileTypes: false }), e2.getReaddirOptsAndCb = s2(e2.getReaddirOptions), e2.getOpendirOptions = o2({ encoding: `utf8`, bufferSize: 32, recursive: false }), e2.getOpendirOptsAndCb = s2(e2.getOpendirOptions), e2.getAppendFileOpts = o2({ encoding: `utf8`, mode: 438, flag: t2.FLAGS[t2.FLAGS.a] }), e2.getAppendFileOptsAndCb = s2(e2.getAppendFileOpts); 7983 var l2 = { bigint: false }; 7984 e2.getStatOptions = (e3 = {}) => Object.assign({}, l2, e3), e2.getStatOptsAndCb = (t3, r3) => typeof t3 == `function` ? [(0, e2.getStatOptions)(), t3] : [(0, e2.getStatOptions)(t3), (0, n2.validateCallback)(r3)]; 7985 var u2 = { bigint: false }; 7986 e2.getStatfsOptions = (e3 = {}) => Object.assign({}, u2, e3), e2.getStatfsOptsAndCb = (t3, r3) => typeof t3 == `function` ? [(0, e2.getStatfsOptions)(), t3] : [(0, e2.getStatfsOptions)(t3), (0, n2.validateCallback)(r3)];
7987 var d2 = e2.optsDefaults; 7988 e2.getRealpathOptions = o2(d2), e2.getRealpathOptsAndCb = s2(e2.getRealpathOptions), e2.writeFileDefaults = { encoding: `utf8`, mode: 438, flag: t2.FLAGS[t2.FLAGS.w] }, e2.getWriteFileOptions = o2(e2.writeFileDefaults); 7989})), Qr = i(((e2) => { 7990 u(), Object.defineProperty(e2, `__esModule`, { value: true }), e2.Dir = void 0; 7991 var t2 = ur(), n2 = yn(), r2 = he(); 7992 e2.Dir = class { 7993 constructor(e3, t3) { 7994 this.link = e3, this.options = t3, this.iteratorInfo = [], this.closed = false, this.operationQueue = null, this.path = e3.getPath(), this.iteratorInfo.push(e3.children[Symbol.iterator]()); 7995 } 7996 closeBase() { 7997 } 7998 readBase(e3) { 7999 let t3, r3, i2, a2; 8000 do { 8001 do 8002 if ({ done: t3, value: r3 } = e3[e3.length - 1].next(), !t3) [i2, a2] = r3; 8003 else break; 8004 while (i2 === `.` || i2 === `..`); 8005 if (t3) { 8006 if (e3.pop(), e3.length === 0) break; 8007 t3 = false; 8008 } else return this.options.recursive && a2.children.size && e3.push(a2.children[Symbol.iterator]()), n2.default.build(a2, this.options.encoding); 8009 } while (!t3); 8010 return null; 8011 } 8012 close(e3) { 8013 if (e3 === void 0) return this.closed ? Promise.reject(new r2.Error(`ERR_DIR_CLOSED`)) : new Promise((e4, t3) => { 8014 this.close((n3) => { 8015 n3 ? t3(n3) : e4(); 8016 }); 8017 }); 8018 if ((0, t2.validateCallback)(e3), this.closed) { 8019 l.nextTick(e3, new r2.Error(`ERR_DIR_CLOSED`)); 8020 return; 8021 } 8022 if (this.operationQueue !== null) { 8023 this.operationQueue.push(() => { 8024 this.close(e3); 8025 }); 8026 return; 8027 } 8028 this.closed = true; 8029 try { 8030 this.closeBase(), l.nextTick(e3); 8031 } catch (t3) { 8032 l.nextTick(e3, t3); 8033 } 8034 } 8035 closeSync() { 8036 if (this.closed) throw new r2.Error(`ERR_DIR_CLOSED`); 8037 if (this.operationQueue !== null) throw new r2.Error(`ERR_DIR_CONCURRENT_OPERATION`); 8038 this.closed = true, this.closeBase(); 8039 } 8040 read(e3) { 8041 if (e3 === void 0) return new Promise((e4, t3) => { 8042 this.read((n3, r3) => { 8043 n3 ? t3(n3) : e4(r3 ?? null); 8044 }); 8045 }); 8046 if ((0, t2.validateCallback)(e3), this.closed) { 8047 l.nextTick(e3, new r2.Error(`ERR_DIR_CLOSED`)); 8048 return; 8049 } 8050 if (this.operationQueue !== null) { 8051 this.operationQueue.push(() => { 8052 this.read(e3); 8053 }); 8054 return; 8055 } 8056 this.operationQueue = [];
8057 try { 8058 let t3 = this.readBase(this.iteratorInfo); 8059 l.nextTick(() => { 8060 let n3 = this.operationQueue; 8061 this.operationQueue = null; 8062 for (let e4 of n3) e4(); 8063 e3(null, t3); 8064 }); 8065 } catch (t3) { 8066 l.nextTick(() => { 8067 let n3 = this.operationQueue; 8068 this.operationQueue = null; 8069 for (let e4 of n3) e4(); 8070 e3(t3); 8071 }); 8072 } 8073 } 8074 readSync() { 8075 if (this.closed) throw new r2.Error(`ERR_DIR_CLOSED`); 8076 if (this.operationQueue !== null) throw new r2.Error(`ERR_DIR_CONCURRENT_OPERATION`); 8077 return this.readBase(this.iteratorInfo); 8078 } 8079 [Symbol.asyncIterator]() { 8080 return { next: async () => { 8081 try { 8082 let e3 = await this.read(); 8083 return e3 === null ? { done: true, value: void 0 } : { done: false, value: e3 }; 8084 } catch (e3) { 8085 throw e3; 8086 } 8087 }, [Symbol.asyncIterator]() { 8088 return this; 8089 } }; 8090 } 8091 [Symbol.asyncDispose]() { 8092 return this.close(); 8093 } 8094 [Symbol.dispose]() { 8095 this.closeSync(); 8096 } 8097 }; 8098})), $r = i(((e2) => { 8099 Object.defineProperty(e2, `__esModule`, { value: true }), e2.toMatcher = e2.toRegex = void 0; 8100 var t2 = (e3) => /[.^$+{}()|\\]/.test(e3) ? `\\${e3}` : e3, n2 = (t3, n3, r3, i2) => { 8101 let a2 = n3, o2 = [], s2 = ``, c2 = 1; 8102 for (; a2 < t3.length && c2 > 0; ) { 8103 let e3 = t3[a2]; 8104 if (e3 === `(`) c2++, s2 += e3, a2++; 8105 else if (e3 === `)`) if (c2--, c2 === 0) { 8106 o2.push(s2), a2++; 8107 break; 8108 } else s2 += e3, a2++; 8109 else e3 === `|` && c2 === 1 ? (o2.push(s2), s2 = ``, a2++) : (s2 += e3, a2++); 8110 } 8111 if (c2 !== 0) return; 8112 let l2 = ``, u2 = o2.length; 8113 for (let t4 = 0; t4 < u2; t4++) l2 += (l2 ? `|` : ``) + (0, e2.toRegex)(o2[t4], i2).source.replace(/^\^/, ``).replace(/\$$/, ``); 8114 switch (r3) { 8115 case `?`: 8116 return [`(?:${l2})?`, a2]; 8117 case `*`: 8118 return [`(?:${l2})*`, a2]; 8119 case `+`: 8120 return [`(?:${l2})+`, a2]; 8121 case `@`: 8122 return [`(?:${l2})`, a2]; 8123 case `!`: 8124 return [`(?!${l2})[^/]*`, a2]; 8125 } 8126 }; 8127 e2.toRegex = (r3, i2) => { 8128 let a2 = ``, o2 = 0, s2 = () => { 8129 o2++; 8130 let n3 = [], a3 = ``, s3 = false;
8131 for (; o2 < r3.length; ) { 8132 let e3 = r3[o2]; 8133 if (e3 === `}`) { 8134 n3.push(a3), o2++, s3 = true; 8135 break; 8136 } 8137 if (e3 === `,`) { 8138 n3.push(a3), a3 = ``, o2++; 8139 continue; 8140 } 8141 a3 += e3, o2++; 8142 } 8143 return s3 ? `(?:${n3.map((t3) => (0, e2.toRegex)(t3, i2).source.replace(/^\^/, ``).replace(/\$$/, ``)).join(`|`)})` : `\\{` + t2(a3); 8144 }, c2 = !!i2?.extglob; 8145 for (; o2 < r3.length; ) { 8146 let e3 = r3[o2]; 8147 if (c2 && r3[o2 + 1] === `(` && (e3 === `?` || e3 === `*` || e3 === `+` || e3 === `@` || e3 === `!`)) { 8148 let t3 = n2(r3, o2 + 2, e3, i2); 8149 if (t3) { 8150 a2 += t3[0], o2 = t3[1]; 8151 continue; 8152 } 8153 } 8154 switch (e3) { 8155 case `*`: 8156 if (r3[o2 + 1] === `*`) { 8157 let e4 = o2 + 2; 8158 for (; r3[e4] === `*`; ) e4++; 8159 r3[e4] === `/` ? (a2 += `(?:.*/)?`, o2 = e4 + 1) : (a2 += `.*`, o2 = e4); 8160 } else a2 += `[^/]*`, o2++; 8161 break; 8162 case `?`: 8163 a2 += `[^/]`, o2++; 8164 break; 8165 case `[`: { 8166 let e4 = `[`; 8167 for (o2++, o2 < r3.length && r3[o2] === `!` && (e4 += `^`, o2++), o2 < r3.length && r3[o2] === `]` && (e4 += `]`, o2++); o2 < r3.length && r3[o2] !== `]`; ) { 8168 let t3 = r3[o2]; 8169 e4 += t3 === `\\` ? `\\\\` : t3, o2++; 8170 } 8171 if (o2 < r3.length && r3[o2] === `]`) e4 += `]`, o2++; 8172 else { 8173 a2 += `\\[`; 8174 continue; 8175 } 8176 a2 += e4; 8177 break; 8178 } 8179 case `{`: 8180 a2 += s2(); 8181 break; 8182 case `/`: 8183 a2 += `/`, o2++; 8184 break; 8185 case `.`: 8186 case `^`: 8187 case `$`: 8188 case `+`: 8189 case `(`: 8190 case `)`: 8191 case `|`: 8192 case `\\`: 8193 a2 += `\\${e3}`, o2++; 8194 break; 8195 default: 8196 a2 += e3, o2++; 8197 break; 8198 } 8199 } 8200 let l2 = i2?.nocase ? `i` : ``; 8201 return RegExp(`^` + a2 + `$`, l2); 8202 }; 8203 var r2 = /^\/(.{1,4096})\/([gimsuy]{0,6})$/; 8204 e2.toMatcher = (t3, n3) => { 8205 let i2 = [], a2 = Array.isArray(t3) ? t3 : [t3]; 8206 for (let t4 of a2) if (typeof t4 == `string`) { 8207 let a3 = r2.exec(t4); 8208 if (a3) { 8209 let [, e3, t5] = a3; 8210 i2.push(new RegExp(e3, t5)); 8211 } else i2.push((0, e2.toRegex)(t4, n3)); 8212 } else i2.push(t4); 8213 return i2.length ? Function(`p`, `return ` + i2.map((e3) => e3 + `.test(p)`).join(`||`)) : () => false; 8214 }; 8215})), ei = i(((e2) => { 8216 u(), Object.defineProperty(e2, `__esModule`, { value: true }), e2.globSync = f2; 8217 var t2 = Y(), n2 = $r(), r2 = ur(), i2 = t2.posix.join, a2 = t2.posix.relative, o2 = t2.posix.resolve; 8218 function s2(e3, t3) { 8219 return (0, n2.toRegex)(t3).test(e3); 8220 } 8221 function c2(e3, t3) { 8222 return t3 ? typeof t3 == `function` ? t3(e3) : (Array.isArray(t3) ? t3 : [t3]).some((t4) => s2(e3, t4)) : false; 8223 } 8224 function d2(e3, t3, n3, o3, u2 = 0) { 8225 let f3 = [], p2 = o3.maxdepth ?? 1 / 0, m2 = o3.cwd ? (0, r2.pathToFilename)(o3.cwd) : l.cwd(); 8226 if (u2 > p2) return f3; 8227 try { 8228 let r3 = e3.readdirSync(t3, { withFileTypes: true }); 8229 for (let l2 of r3) { 8230 let r4 = i2(t3, l2.name.toString()), h2 = a2(m2, r4); 8231 if (!c2(h2, o3.exclude) && (n3.some((e4) => s2(h2, e4)) && f3.push(h2), l2.isDirectory() && u2 < p2)) { 8232 let t4 = d2(e3, r4, n3, o3, u2 + 1); 8233 f3.push(...t4); 8234 } 8235 } 8236 } catch { 8237 } 8238 return f3; 8239 } 8240 function f2(e3, n3, i3 = {}) { 8241 let a3 = o2(i3.cwd ? (0, r2.pathToFilename)(i3.cwd) : l.cwd()), s3 = { cwd: a3, exclude: i3.exclude, maxdepth: i3.maxdepth, withFileTypes: i3.withFileTypes || false }, c3 = []; 8242 if (t2.posix.isAbsolute(n3)) { 8243 let r3 = t2.posix.dirname(n3), i4 = d2(e3, r3, [t2.posix.basename(n3)], { ...s3, cwd: r3 }); 8244 c3.push(...i4.map((e4) => t2.posix.resolve(r3, e4))); 8245 } else { 8246 let t3 = d2(e3, a3, [n3.replace(/^\.\//, ``)], s3); 8247 c3.push(...t3); 8248 } 8249 return c3 = [...new Set(c3)].sort(), c3; 8250 } 8251})), ti = i(((e2) => { 8252 a(), Object.defineProperty(e2, `__esModule`, { value: true }), e2.FSWatcher = e2.StatWatcher = e2.Volume = void 0, e2.pathToSteps = L2, e2.dataToStr = R2, e2.toUnixTimestamp = z2; 8253 var t2 = Y(), n2 = _n(), r2 = hn(), i2 = vn(), s2 = yn(), c2 = bn(), l2 = Z(), u2 = xn(), d2 = cr(), f2 = $(), p2 = lr(), m2 = dr(), h2 = me(), g2 = fr(), _2 = _r(), v2 = Xr(), y2 = $(), b2 = he(), x2 = Zr(), S2 = ur(), C2 = Qr(), w2 = t2.resolve, { O_SYMLINK: T2, F_OK: E2, R_OK: D2, W_OK: O2, X_OK: k2, COPYFILE_EXCL: A2, COPYFILE_FICLONE_FORCE: j2 } = f2.constants; 8254 t2.posix ? t2.posix.sep : t2.sep; 8255 var M2 = t2.posix ? t2.posix.relative : t2.relative, N2 = t2.posix ? t2.posix.join : t2.join, P2 = t2.posix ? t2.posix.dirname : t2.dirname, F2 = t2.posix ? t2.posix.normalize : t2.normalize, I2 = 128; 8256 function L2(e3) { 8257 return (0, n2.filenameToSteps)((0, S2.pathToFilename)(e3)); 8258 } 8259 function R2(e3, t3 = f2.ENCODING_UTF8) { 8260 return l2.Buffer.isBuffer(e3) ? e3.toString(t3) : e3 instanceof Uint8Array ? (0, l2.bufferFrom)(e3).toString(t3) : String(e3); 8261 } 8262 function z2(e3) { 8263 if (typeof e3 == `string` && +e3 == e3) return +e3; 8264 if (e3 instanceof Date) return e3.getTime() / 1e3; 8265 if (isFinite(e3)) return e3 < 0 ? Date.now() / 1e3 : e3; 8266 throw Error(`Cannot parse time: ` + e3); 8267 } 8268 function B2(e3) { 8269 if (typeof e3 != `number`) throw TypeError(y2.ERRSTR.UID); 8270 } 8271 function V2(e3) { 8272 if (typeof e3 != `number`) throw TypeError(y2.ERRSTR.GID); 8273 } 8274 var H2 = class { 8275 get promises() { 8276 if (this.promisesApi === null) throw Error(`Promise is not supported in this environment.`); 8277 return this.promisesApi; 8278 } 8279 constructor(e3 = new n2.Superblock()) {
8280 this._core = e3, this.promisesApi = new g2.FsPromises(this, m2.FileHandle), this.openSync = (e4, t3, n3 = 438) => { 8281 let r3 = (0, S2.modeToNumber)(n3), i3 = (0, S2.pathToFilename)(e4), a3 = (0, S2.flagsToNumber)(t3); 8282 return this._core.open(i3, a3, r3, !(a3 & T2)); 8283 }, this.open = (e4, t3, n3, r3) => { 8284 let i3 = n3, a3 = r3; 8285 typeof n3 == `function` && (i3 = 438, a3 = n3), i3 || (i3 = 438); 8286 let o3 = (0, S2.modeToNumber)(i3), s3 = (0, S2.pathToFilename)(e4), c4 = (0, S2.flagsToNumber)(t3); 8287 this.wrapAsync(this._core.open, [s3, c4, o3, !(c4 & T2)], a3); 8288 }, this.closeSync = (e4) => { 8289 this._core.close(e4); 8290 }, this.close = (e4, t3) => { 8291 (0, n2.validateFd)(e4); 8292 let r3 = this._core.getFileByFdOrThrow(e4, `close`); 8293 this.wrapAsync(this._core.close, [r3.fd], t3); 8294 }, this.readSync = (e4, t3, r3, i3, a3) => ((0, n2.validateFd)(e4), this._core.read(e4, t3, r3, i3, a3)), this.read = (e4, t3, n3, r3, i3, a3) => { 8295 if ((0, S2.validateCallback)(a3), r3 === 0) return queueMicrotask(() => { 8296 a3 && a3(null, 0, t3); 8297 }); 8298 Promise.resolve().then(() => { 8299 try { 8300 a3(null, this._core.read(e4, t3, n3, r3, i3), t3); 8301 } catch (e5) { 8302 a3(e5); 8303 } 8304 }); 8305 }, this.readv = (e4, t3, n3, r3) => { 8306 let i3 = n3, a3 = r3; 8307 typeof n3 == `function` && ([i3, a3] = [null, n3]), (0, S2.validateCallback)(a3), Promise.resolve().then(() => { 8308 try { 8309 let n4 = this._core.readv(e4, t3, i3); 8310 a3(null, n4, t3); 8311 } catch (e5) { 8312 a3(e5); 8313 } 8314 }); 8315 }, this.readvSync = (e4, t3, r3) => ((0, n2.validateFd)(e4), this._core.readv(e4, t3, r3 ?? null)), this._readfile = (e4, t3, r3) => { 8316 let i3, a3 = typeof e4 == `number` && (0, n2.isFd)(e4), o3; 8317 if (a3) o3 = e4; 8318 else { 8319 let n3 = (0, S2.pathToFilename)(e4), r4 = String(e4), i4 = r4.length > 1 && r4.endsWith(`/`), a4 = this._core.getResolvedLinkOrThrow(n3, `open`), s3 = a4.getNode(); 8320 if (s3.isDirectory()) throw (0, S2.createError)(`EISDIR`, `open`, a4.getPath()); 8321 if (i4 && s3.isFile()) throw (0, S2.createError)(`ENOTDIR`, `open`, r4); 8322 o3 = this.openSync(e4, t3); 8323 } 8324 try { 8325 i3 = (0, S2.bufferToEncoding)(this._core.getFileByFdOrThrow(o3).getBuffer(), r3); 8326 } finally { 8327 a3 || this.closeSync(o3); 8328 } 8329 return i3; 8330 }, this.readFileSync = (e4, t3) => { 8331 let n3 = (0, x2.getReadFileOptions)(t3), r3 = (0, S2.flagsToNumber)(n3.flag); 8332 return this._readfile(e4, r3, n3.encoding); 8333 }, this.readFile = (e4, t3, n3) => { 8334 let [r3, i3] = (0, x2.optsAndCbGenerator)(x2.getReadFileOptions)(t3, n3), a3 = (0, S2.flagsToNumber)(r3.flag); 8335 this.wrapAsync(this._readfile, [e4, a3, r3.encoding], i3); 8336 }, this.writeSync = (e4, t3, n3, r3, i3) => { 8337 let [, a3, o3, s3, c4] = (0, S2.getWriteSyncArgs)(e4, t3, n3, r3, i3); 8338 return this._write(e4, a3, o3, s3, c4); 8339 }, this.write = (e4, t3, n3, r3, i3, a3) => { 8340 let [, o3, s3, c4, l4, u4, d4] = (0, S2.getWriteArgs)(e4, t3, n3, r3, i3, a3); 8341 Promise.resolve().then(() => { 8342 try { 8343 let n4 = this._write(e4, s3, c4, l4, u4); 8344 o3 ? d4(null, n4, t3) : d4(null, n4, s3); 8345 } catch (e5) { 8346 d4(e5); 8347 } 8348 }); 8349 }, this.writev = (e4, t3, n3, r3) => { 8350 let i3 = n3, a3 = r3; 8351 typeof n3 == `function` && ([i3, a3] = [null, n3]), (0, S2.validateCallback)(a3), Promise.resolve().then(() => { 8352 try { 8353 let n4 = this.writevBase(e4, t3, i3); 8354 a3(null, n4, t3); 8355 } catch (e5) { 8356 a3(e5); 8357 } 8358 }); 8359 }, this.writevSync = (e4, t3, r3) => ((0, n2.validateFd)(e4), this.writevBase(e4, t3, r3 ?? null)), this.writeFileSync = (e4, t3, r3) => { 8360 let i3 = (0, x2.getWriteFileOptions)(r3), a3 = (0, S2.flagsToNumber)(i3.flag), o3 = (0, S2.modeToNumber)(i3.mode), s3 = (0, n2.dataToBuffer)(t3, i3.encoding); 8361 this._core.writeFile(e4, s3, a3, o3); 8362 }, this.writeFile = (e4, t3, r3, i3) => { 8363 let a3 = r3, o3 = i3; 8364 typeof r3 == `function` && ([a3, o3] = [x2.writeFileDefaults, r3]); 8365 let s3 = (0, S2.validateCallback)(o3), c4 = (0, x2.getWriteFileOptions)(a3), l4 = (0, S2.flagsToNumber)(c4.flag), u4 = (0, S2.modeToNumber)(c4.mode), d4 = (0, n2.dataToBuffer)(t3, c4.encoding); 8366 this.wrapAsync(this._core.writeFile, [e4, d4, l4, u4], s3); 8367 }, this.copyFileSync = (e4, t3, n3) => { 8368 let r3 = (0, S2.pathToFilename)(e4), i3 = (0, S2.pathToFilename)(t3); 8369 return this._copyFile(r3, i3, (n3 || 0) | 0); 8370 }, this.copyFile = (e4, t3, n3, r3) => { 8371 let i3 = (0, S2.pathToFilename)(e4), a3 = (0, S2.pathToFilename)(t3), o3, s3; 8372 typeof n3 == `function` ? [o3, s3] = [0, n3] : [o3, s3] = [n3, r3], (0, S2.validateCallback)(s3), this.wrapAsync(this._copyFile, [i3, a3, o3], s3); 8373 }, this._cp = (e4, t3, n3) => {
8374 if (n3.filter && !n3.filter(e4, t3)) return; 8375 let r3 = n3.dereference ? this.statSync(e4) : this.lstatSync(e4), i3 = null; 8376 try { 8377 i3 = this.lstatSync(t3); 8378 } catch (e5) { 8379 if (e5.code !== `ENOENT`) throw e5; 8380 } 8381 if (i3 && r3.ino === i3.ino && r3.dev === i3.dev) throw (0, S2.createError)(`EINVAL`, `cp`, e4, t3); 8382 if (i3) { 8383 if (r3.isDirectory() && !i3.isDirectory()) throw (0, S2.createError)(`EISDIR`, `cp`, e4, t3); 8384 if (!r3.isDirectory() && i3.isDirectory()) throw (0, S2.createError)(`ENOTDIR`, `cp`, e4, t3); 8385 } 8386 if (r3.isDirectory() && this.isSrcSubdir(e4, t3)) throw (0, S2.createError)(`EINVAL`, `cp`, e4, t3); 8387 ENDURE_PARENT_DIR_EXISTS: { 8388 let e5 = P2(t3); 8389 this.existsSync(e5) || this.mkdirSync(e5, { recursive: true }); 8390 } 8391 if (r3.isDirectory()) { 8392 if (!n3.recursive) throw (0, S2.createError)(`EISDIR`, `cp`, e4); 8393 this.cpDirSync(r3, i3, e4, t3, n3); 8394 } else if (r3.isFile() || r3.isCharacterDevice() || r3.isBlockDevice()) this.cpFileSync(r3, i3, e4, t3, n3); 8395 else if (r3.isSymbolicLink() && !n3.dereference) this.cpSymlinkSync(i3, e4, t3, n3); 8396 else throw (0, S2.createError)(`EINVAL`, `cp`, e4); 8397 }, this.linkSync = (e4, t3) => { 8398 let n3 = (0, S2.pathToFilename)(e4), r3 = (0, S2.pathToFilename)(t3); 8399 this._core.link(n3, r3); 8400 }, this.link = (e4, t3, n3) => { 8401 let r3 = (0, S2.pathToFilename)(e4), i3 = (0, S2.pathToFilename)(t3); 8402 this.wrapAsync(this._core.link, [r3, i3], n3); 8403 }, this.unlinkSync = (e4) => { 8404 let t3 = (0, S2.pathToFilename)(e4); 8405 this._core.unlink(t3); 8406 }, this.unlink = (e4, t3) => { 8407 let n3 = (0, S2.pathToFilename)(e4); 8408 this.wrapAsync(this._core.unlink, [n3], t3); 8409 }, this.symlinkSync = (e4, t3, n3) => { 8410 let r3 = (0, S2.pathToFilename)(e4), i3 = (0, S2.pathToFilename)(t3); 8411 this._core.symlink(r3, i3); 8412 }, this.symlink = (e4, t3, n3, r3) => { 8413 let i3 = (0, S2.validateCallback)(typeof n3 == `function` ? n3 : r3), a3 = (0, S2.pathToFilename)(e4), o3 = (0, S2.pathToFilename)(t3); 8414 this.wrapAsync(this._core.symlink, [a3, o3], i3); 8415 }, this._lstat = (e4, t3 = false, n3 = false) => { 8416 let r3; 8417 try { 8418 r3 = this._core.getLinkOrThrow(e4, `lstat`); 8419 } catch (e5) { 8420 if (e5.code === `ENOENT` && !n3) return; 8421 throw e5; 8422 } 8423 return i2.default.build(r3.getNode(), t3); 8424 }, this.lstatSync = (e4, t3) => { 8425 let { throwIfNoEntry: n3 = true, bigint: r3 = false } = (0, x2.getStatOptions)(t3); 8426 return this._lstat((0, S2.pathToFilename)(e4), r3, n3); 8427 }, this.renameSync = (e4, t3) => { 8428 let n3 = (0, S2.pathToFilename)(e4), r3 = (0, S2.pathToFilename)(t3); 8429 this._core.rename(n3, r3); 8430 }, this.rename = (e4, t3, n3) => { 8431 let r3 = (0, S2.pathToFilename)(e4), i3 = (0, S2.pathToFilename)(t3); 8432 this.wrapAsync(this._core.rename, [r3, i3], n3); 8433 }, this.existsSync = (e4) => { 8434 try { 8435 return this._exists((0, S2.pathToFilename)(e4)).ok; 8436 } catch { 8437 return false; 8438 } 8439 }, this.exists = (e4, t3) => { 8440 let n3 = (0, S2.pathToFilename)(e4); 8441 if (typeof t3 != `function`) throw Error(y2.ERRSTR.CB); 8442 Promise.resolve().then(() => { 8443 try { 8444 t3(this._exists(n3).ok); 8445 } catch { 8446 t3(false); 8447 } 8448 }); 8449 }, this.accessSync = (e4, t3 = E2) => { 8450 let n3 = (0, S2.pathToFilename)(e4); 8451 t3 |= 0, this._access(n3, t3); 8452 }, this.access = (e4, t3, n3) => { 8453 let r3 = E2, i3; 8454 typeof t3 == `function` ? i3 = t3 : [r3, i3] = [t3 | 0, (0, S2.validateCallback)(n3)]; 8455 let a3 = (0, S2.pathToFilename)(e4); 8456 this.wrapAsync(this._access, [a3, r3], i3); 8457 }, this.appendFileSync = (e4, t3, r3) => { 8458 let i3 = (0, x2.getAppendFileOpts)(r3); 8459 (!i3.flag || (0, n2.isFd)(e4)) && (i3.flag = `a`), this.writeFileSync(e4, t3, i3); 8460 }, this.appendFile = (e4, t3, r3, i3) => { 8461 let [a3, o3] = (0, x2.getAppendFileOptsAndCb)(r3, i3); 8462 (!a3.flag || (0, n2.isFd)(e4)) && (a3.flag = `a`), this.writeFile(e4, t3, a3, o3); 8463 }, this._readdir = (e4, i3) => { 8464 (0, n2.filenameToSteps)(e4); 8465 let a3 = this._core.getResolvedLinkOrThrow(e4, `scandir`), o3 = a3.getNode(); 8466 if (!o3.isDirectory()) throw (0, S2.createError)(`ENOTDIR`, `scandir`, e4); 8467 if (!o3.canRead()) throw (0, S2.createError)(`EACCES`, `scandir`, e4); 8468 let c4 = []; 8469 for (let e5 of a3.children.keys()) { 8470 let t3 = a3.getChild(e5); 8471 if (!(!t3 || e5 === `.` || e5 === `..`) && (c4.push(s2.default.build(t3, i3.encoding)), i3.recursive && t3.children.size)) { 8472 let e6 = { ...i3, recursive: true, withFileTypes: true }, n3 = this._readdir(t3.getPath(), e6); 8473 c4.push(...n3); 8474 } 8475 } 8476 if (!r2.isWin && i3.encoding !== `buffer` && c4.sort((e5, t3) => e5.name < t3.name ? -1 : +(e5.name > t3.name)), i3.withFileTypes) return c4; 8477 let l4 = e4; 8478 return r2.isWin && (l4 = l4.replace(/\\/g, `/`)), c4.map((e5) => { 8479 if (i3.recursive) { 8480 let n3 = N2(e5.parentPath, e5.name.toString()); 8481 return r2.isWin && (n3 = n3.replace(/\\/g, `/`)), n3.replace(l4 + t2.posix.sep, ``); 8482 } 8483 return e5.name; 8484 }); 8485 }, this.readdirSync = (e4, t3) => { 8486 let n3 = (0, x2.getReaddirOptions)(t3), r3 = (0, S2.pathToFilename)(e4); 8487 return this._readdir(r3, n3); 8488 }, this.readdir = (e4, t3, n3) => { 8489 let [r3, i3] = (0, x2.getReaddirOptsAndCb)(t3, n3), a3 = (0, S2.pathToFilename)(e4); 8490 this.wrapAsync(this._readdir, [a3, r3], i3); 8491 }, this._readlink = (e4, t3) => { 8492 let n3 = this._core.getLinkOrThrow(e4, `readlink`).getNode(); 8493 if (!n3.isSymlink()) throw (0, S2.createError)(`EINVAL`, `readlink`, e4); 8494 return (0, f2.strToEncoding)(n3.symlink, t3); 8495 }, this.readlinkSync = (e4, t3) => { 8496 let n3 = (0, x2.getDefaultOpts)(t3), r3 = (0, S2.pathToFilename)(e4); 8497 return this._readlink(r3, n3.encoding); 8498 }, this.readlink = (e4, t3, n3) => { 8499 let [r3, i3] = (0, x2.getDefaultOptsAndCb)(t3, n3), a3 = (0, S2.pathToFilename)(e4); 8500 this.wrapAsync(this._readlink, [a3, r3.encoding], i3); 8501 }, this._fsync = (e4) => { 8502 this._core.getFileByFdOrThrow(e4, `fsync`); 8503 }, this.fsyncSync = (e4) => { 8504 this._fsync(e4); 8505 }, this.fsync = (e4, t3) => { 8506 this.wrapAsync(this._fsync, [e4], t3); 8507 }, this._fdatasync = (e4) => { 8508 this._core.getFileByFdOrThrow(e4, `fdatasync`); 8509 }, this.fdatasyncSync = (e4) => { 8510 this._fdatasync(e4); 8511 }, this.fdatasync = (e4, t3) => { 8512 this.wrapAsync(this._fdatasync, [e4], t3); 8513 }, this._ftruncate = (e4, t3) => { 8514 this._core.getFileByFdOrThrow(e4, `ftruncate`).truncate(t3); 8515 }, this.ftruncateSync = (e4, t3) => { 8516 this._ftruncate(e4, t3); 8517 }, this.ftruncate = (e4, t3, n3) => { 8518 let r3 = typeof t3 == `number` ? t3 : 0, i3 = (0, S2.validateCallback)(typeof t3 == `number` ? n3 : t3); 8519 this.wrapAsync(this._ftruncate, [e4, r3], i3); 8520 }, this._truncate = (e4, t3) => { 8521 let n3 = this.openSync(e4, `r+`); 8522 try { 8523 this.ftruncateSync(n3, t3); 8524 } finally { 8525 this.closeSync(n3); 8526 } 8527 }, this.truncateSync = (e4, t3) => { 8528 if ((0, n2.isFd)(e4)) return this.ftruncateSync(e4, t3); 8529 this._truncate(e4, t3); 8530 }, this.truncate = (e4, t3, r3) => { 8531 let i3 = typeof t3 == `number` ? t3 : 0, a3 = (0, S2.validateCallback)(typeof t3 == `number` ? r3 : t3); 8532 if ((0, n2.isFd)(e4)) return this.ftruncate(e4, i3, a3); 8533 this.wrapAsync(this._truncate, [e4, i3], a3); 8534 }, this._futimes = (e4, t3, n3) => { 8535 let r3 = this._core.getFileByFdOrThrow(e4, `futimes`).node; 8536 r3.atime = new Date(t3 * 1e3), r3.mtime = new Date(n3 * 1e3); 8537 }, this.futimesSync = (e4, t3, n3) => { 8538 this._futimes(e4, z2(t3), z2(n3)); 8539 }, this.futimes = (e4, t3, n3, r3) => { 8540 this.wrapAsync(this._futimes, [e4, z2(t3), z2(n3)], r3); 8541 }, this._utimes = (e4, t3, n3, r3 = true) => { 8542 let i3 = this._core, a3 = (r3 ? i3.getResolvedLinkOrThrow(e4, `utimes`) : i3.getLinkOrThrow(e4, `lutimes`)).getNode(); 8543 a3.atime = new Date(t3 * 1e3), a3.mtime = new Date(n3 * 1e3); 8544 }, this.utimesSync = (e4, t3, n3) => { 8545 this._utimes((0, S2.pathToFilename)(e4), z2(t3), z2(n3), true); 8546 }, this.utimes = (e4, t3, n3, r3) => { 8547 this.wrapAsync(this._utimes, [(0, S2.pathToFilename)(e4), z2(t3), z2(n3), true], r3); 8548 }, this.lutimesSync = (e4, t3, n3) => { 8549 this._utimes((0, S2.pathToFilename)(e4), z2(t3), z2(n3), false); 8550 }, this.lutimes = (e4, t3, n3, r3) => { 8551 this.wrapAsync(this._utimes, [(0, S2.pathToFilename)(e4), z2(t3), z2(n3), false], r3); 8552 }, this.mkdirSync = (e4, t3) => { 8553 let n3 = (0, x2.getMkdirOptions)(t3), r3 = (0, S2.modeToNumber)(n3.mode, 511), i3 = (0, S2.pathToFilename)(e4); 8554 if (n3.recursive) return this._core.mkdirp(i3, r3); 8555 this._core.mkdir(i3, r3); 8556 }, this.mkdir = (e4, t3, n3) => { 8557 let r3 = (0, x2.getMkdirOptions)(t3), i3 = (0, S2.validateCallback)(typeof t3 == `function` ? t3 : n3), a3 = (0, S2.modeToNumber)(r3.mode, 511), o3 = (0, S2.pathToFilename)(e4); 8558 r3.recursive ? this.wrapAsync(this._core.mkdirp, [o3, a3], i3) : this.wrapAsync(this._core.mkdir, [o3, a3], i3); 8559 }, this._mkdtemp = (e4, t3, n3 = 5) => { 8560 let r3 = e4 + (0, S2.genRndStr6)(); 8561 try { 8562 return this._core.mkdir(r3, 511), (0, f2.strToEncoding)(r3, t3); 8563 } catch (r4) { 8564 if (r4.code === `EEXIST`) { 8565 if (n3 > 1) return this._mkdtemp(e4, t3, n3 - 1); 8566 throw Error(`Could not create temp dir.`); 8567 } else throw r4; 8568 } 8569 }, this.mkdtempSync = (e4, t3) => { 8570 let { encoding: n3 } = (0, x2.getDefaultOpts)(t3); 8571 if (!e4 || typeof e4 != `string`) throw TypeError(`filename prefix is required`); 8572 return (0, S2.nullCheck)(e4), this._mkdtemp(e4, n3); 8573 }, this.mkdtemp = (e4, t3, n3) => { 8574 let [{ encoding: r3 }, i3] = (0, x2.getDefaultOptsAndCb)(t3, n3); 8575 if (!e4 || typeof e4 != `string`) throw TypeError(`filename prefix is required`); 8576 (0, S2.nullCheck)(e4) && this.wrapAsync(this._mkdtemp, [e4, r3], i3); 8577 }, this.rmdirSync = (e4, t3) => { 8578 let n3 = (0, x2.getRmdirOptions)(t3); 8579 this._core.rmdir((0, S2.pathToFilename)(e4), n3.recursive); 8580 }, this.rmdir = (e4, t3, n3) => { 8581 let r3 = (0, x2.getRmdirOptions)(t3), i3 = (0, S2.validateCallback)(typeof t3 == `function` ? t3 : n3); 8582 this.wrapAsync(this._core.rmdir, [(0, S2.pathToFilename)(e4), r3.recursive], i3); 8583 }, this.rmSync = (e4, t3) => { 8584 this._core.rm((0, S2.pathToFilename)(e4), t3?.force, t3?.recursive); 8585 }, this.rm = (e4, t3, n3) => { 8586 let [r3, i3] = (0, x2.getRmOptsAndCb)(t3, n3); 8587 this.wrapAsync(this._core.rm, [(0, S2.pathToFilename)(e4), r3?.force, r3?.recursive], i3); 8588 }, this._fchmod = (e4, t3) => { 8589 this._core.getFileByFdOrThrow(e4, `fchmod`).chmod(t3); 8590 }, this.fchmodSync = (e4, t3) => { 8591 this._fchmod(e4, (0, S2.modeToNumber)(t3)); 8592 }, this.fchmod = (e4, t3, n3) => { 8593 this.wrapAsync(this._fchmod, [e4, (0, S2.modeToNumber)(t3)], n3); 8594 }, this._chmod = (e4, t3, n3 = true) => { 8595 (n3 ? this._core.getResolvedLinkOrThrow(e4, `chmod`) : this._core.getLinkOrThrow(e4, `chmod`)).getNode().chmod(t3); 8596 }, this.chmodSync = (e4, t3) => { 8597 let n3 = (0, S2.modeToNumber)(t3), r3 = (0, S2.pathToFilename)(e4); 8598 this._chmod(r3, n3, true); 8599 }, this.chmod = (e4, t3, n3) => { 8600 let r3 = (0, S2.modeToNumber)(t3), i3 = (0, S2.pathToFilename)(e4); 8601 this.wrapAsync(this._chmod, [i3, r3], n3); 8602 }, this._lchmod = (e4, t3) => { 8603 this._chmod(e4, t3, false); 8604 }, this.lchmodSync = (e4, t3) => { 8605 let n3 = (0, S2.modeToNumber)(t3), r3 = (0, S2.pathToFilename)(e4); 8606 this._lchmod(r3, n3); 8607 }, this.lchmod = (e4, t3, n3) => { 8608 let r3 = (0, S2.modeToNumber)(t3), i3 = (0, S2.pathToFilename)(e4); 8609 this.wrapAsync(this._lchmod, [i3, r3], n3); 8610 }, this._fchown = (e4, t3, n3) => { 8611 this._core.getFileByFdOrThrow(e4, `fchown`).chown(t3, n3); 8612 }, this.fchownSync = (e4, t3, n3) => { 8613 B2(t3), V2(n3), this._fchown(e4, t3, n3); 8614 }, this.fchown = (e4, t3, n3, r3) => { 8615 B2(t3), V2(n3), this.wrapAsync(this._fchown, [e4, t3, n3], r3); 8616 }, this._chown = (e4, t3, n3) => { 8617 this._core.getResolvedLinkOrThrow(e4, `chown`).getNode().chown(t3, n3); 8618 }, this.chownSync = (e4, t3, n3) => { 8619 B2(t3), V2(n3), this._chown((0, S2.pathToFilename)(e4), t3, n3); 8620 }, this.chown = (e4, t3, n3, r3) => { 8621 B2(t3), V2(n3), this.wrapAsync(this._chown, [(0, S2.pathToFilename)(e4), t3, n3], r3); 8622 }, this._lchown = (e4, t3, n3) => { 8623 this._core.getLinkOrThrow(e4, `lchown`).getNode().chown(t3, n3); 8624 }, this.lchownSync = (e4, t3, n3) => { 8625 B2(t3), V2(n3), this._lchown((0, S2.pathToFilename)(e4), t3, n3); 8626 }, this.lchown = (e4, t3, n3, r3) => { 8627 B2(t3), V2(n3), this.wrapAsync(this._lchown, [(0, S2.pathToFilename)(e4), t3, n3], r3); 8628 }, this.statWatchers = {}, this.cpSync = (e4, t3, n3) => { 8629 let r3 = (0, S2.pathToFilename)(e4), i3 = (0, S2.pathToFilename)(t3), a3 = { dereference: n3?.dereference ?? false, errorOnExist: n3?.errorOnExist ?? false, filter: n3?.filter, force: n3?.force ?? true, mode: n3?.mode ?? 0, preserveTimestamps: n3?.preserveTimestamps ?? false, recursive: n3?.recursive ?? false, verbatimSymlinks: n3?.verbatimSymlinks ?? false }; 8630 return this._cp(r3, i3, a3); 8631 }, this.cp = (e4, t3, n3, r3) => { 8632 let i3 = (0, S2.pathToFilename)(e4), a3 = (0, S2.pathToFilename)(t3), o3, s3; 8633 typeof n3 == `function` ? [o3, s3] = [{}, n3] : [o3, s3] = [n3 || {}, r3], (0, S2.validateCallback)(s3); 8634 let c4 = { dereference: o3?.dereference ?? false, errorOnExist: o3?.errorOnExist ?? false, filter: o3?.filter, force: o3?.force ?? true, mode: o3?.mode ?? 0, preserveTimestamps: o3?.preserveTimestamps ?? false, recursive: o3?.recursive ?? false, verbatimSymlinks: o3?.verbatimSymlinks ?? false };
8635 this.wrapAsync(this._cp, [i3, a3, c4], s3); 8636 }, this.openAsBlob = async (e4, t3) => { 8637 let n3 = (0, S2.pathToFilename)(e4), r3; 8638 try { 8639 r3 = this._core.getResolvedLinkOrThrow(n3, `open`); 8640 } catch (e5) { 8641 throw e5 && typeof e5 == `object` && e5.code === `ENOENT` ? new b2.TypeError(`ERR_INVALID_ARG_VALUE`) : e5; 8642 } 8643 let i3 = r3.getNode().getBuffer(), a3 = t3?.type || ``; 8644 return new Blob([i3], { type: a3 }); 8645 }, this.glob = (e4, ...t3) => { 8646 let [n3, r3] = t3.length === 1 ? [{}, t3[0]] : [t3[0], t3[1]]; 8647 this.wrapAsync(this._globSync, [e4, n3 || {}], r3); 8648 }, this.globSync = (e4, t3 = {}) => this._globSync(e4, t3), this._globSync = (e4, t3 = {}) => { 8649 let { globSync: n3 } = ei(); 8650 return n3(this, e4, t3); 8651 }, this._opendir = (e4, t3) => { 8652 let n3 = this._core.getResolvedLinkOrThrow(e4, `scandir`); 8653 if (!n3.getNode().isDirectory()) throw (0, S2.createError)(`ENOTDIR`, `scandir`, e4); 8654 return new C2.Dir(n3, t3); 8655 }, this.opendirSync = (e4, t3) => { 8656 let n3 = (0, x2.getOpendirOptions)(t3), r3 = (0, S2.pathToFilename)(e4); 8657 return this._opendir(r3, n3); 8658 }, this.opendir = (e4, t3, n3) => { 8659 let [r3, i3] = (0, x2.getOpendirOptsAndCb)(t3, n3), a3 = (0, S2.pathToFilename)(e4); 8660 this.wrapAsync(this._opendir, [a3, r3], i3); 8661 }; 8662 let a2 = this; 8663 this.StatWatcher = class extends W2 { 8664 constructor() { 8665 super(a2); 8666 } 8667 }; 8668 let o2 = K2; 8669 this.ReadStream = class extends o2 { 8670 constructor(...e4) { 8671 super(a2, ...e4); 8672 } 8673 }; 8674 let c3 = q2; 8675 this.WriteStream = class extends c3 { 8676 constructor(...e4) { 8677 super(a2, ...e4); 8678 } 8679 }, this.FSWatcher = class extends J2 { 8680 constructor() { 8681 super(a2); 8682 } 8683 }; 8684 let l3 = (e4, t3) => { 8685 let n3 = this._core.getResolvedLinkOrThrow(e4, `realpath`); 8686 return (0, f2.strToEncoding)(n3.getPath() || `/`, t3); 8687 }, u3 = (e4, t3, n3) => { 8688 let [r3, i3] = (0, x2.getRealpathOptsAndCb)(t3, n3), o3 = (0, S2.pathToFilename)(e4); 8689 a2.wrapAsync(l3, [o3, r3.encoding], i3); 8690 }, d3 = (e4, t3) => l3((0, S2.pathToFilename)(e4), (0, x2.getRealpathOptions)(t3).encoding); 8691 this.realpath = u3, this.realpath.native = u3, this.realpathSync = d3, this.realpathSync.native = d3; 8692 } 8693 wrapAsync(e3, t3, n3) { 8694 (0, S2.validateCallback)(n3), Promise.resolve().then(() => { 8695 let r3; 8696 try { 8697 r3 = e3.apply(this, t3); 8698 } catch (e4) { 8699 n3(e4); 8700 return; 8701 } 8702 n3(null, r3); 8703 }); 8704 } 8705 reset() { 8706 this._core.reset(); 8707 } 8708 toJSON(e3, t3 = {}, n3 = false, r3 = false) { 8709 return this._core.toJSON(e3, t3, n3, r3); 8710 } 8711 fromJSON(e3, t3) { 8712 return this._core.fromJSON(e3, t3); 8713 } 8714 fromNestedJSON(e3, t3) { 8715 return this._core.fromNestedJSON(e3, t3); 8716 } 8717 mountSync(e3, t3) { 8718 this._core.fromJSON(t3, e3); 8719 } 8720 _write(e3, t3, n3, r3, i3) { 8721 let a2 = this._core.getFileByFdOrThrow(e3, `write`); 8722 if (a2.node.isSymlink()) throw (0, S2.createError)(`EBADF`, `write`, a2.link.getPath()); 8723 return a2.write(t3, n3, r3, i3 === -1 || typeof i3 != `number` ? void 0 : i3); 8724 } 8725 writevBase(e3, t3, n3) { 8726 let r3 = this._core.getFileByFdOrThrow(e3), i3 = n3 ?? void 0; 8727 i3 === -1 && (i3 = void 0); 8728 let a2 = 0; 8729 for (let e4 of t3) { 8730 let t4 = l2.Buffer.from(e4.buffer, e4.byteOffset, e4.byteLength), n4 = r3.write(t4, 0, t4.byteLength, i3); 8731 if (i3 = void 0, a2 += n4, n4 < t4.byteLength) break; 8732 } 8733 return a2; 8734 } 8735 _copyFile(e3, t3, n3) { 8736 let r3 = this.readFileSync(e3); 8737 if (n3 & A2 && this.existsSync(t3)) throw (0, S2.createError)(`EEXIST`, `copyFile`, e3, t3); 8738 if (n3 & j2) throw (0, S2.createError)(`ENOSYS`, `copyFile`, e3, t3); 8739 this._core.writeFile(t3, r3, y2.FLAGS.w, 438); 8740 } 8741 isSrcSubdir(e3, n3) {
8742 try { 8743 let r3 = F2(e3.startsWith(`/`) ? e3 : `/` + e3), i3 = F2(n3.startsWith(`/`) ? n3 : `/` + n3); 8744 if (r3 === i3) return true; 8745 let a2 = M2(r3, i3); 8746 return a2 === `` || !a2.startsWith(`..`) && !(0, t2.isAbsolute)(a2); 8747 } catch { 8748 return false; 8749 } 8750 } 8751 cpFileSync(e3, t3, n3, r3, i3) { 8752 if (t3) { 8753 if (i3.errorOnExist) throw (0, S2.createError)(`EEXIST`, `cp`, r3); 8754 if (!i3.force) return; 8755 this.unlinkSync(r3); 8756 } 8757 this.copyFileSync(n3, r3, i3.mode), i3.preserveTimestamps && this.utimesSync(r3, e3.atime, e3.mtime), this.chmodSync(r3, Number(e3.mode)); 8758 } 8759 cpDirSync(e3, t3, n3, r3, i3) { 8760 t3 || this.mkdirSync(r3); 8761 let a2 = this.readdirSync(n3); 8762 for (let e4 of a2) { 8763 let t4 = N2(n3, String(e4)), a3 = N2(r3, String(e4)); 8764 i3.filter && !i3.filter(t4, a3) || this._cp(t4, a3, i3); 8765 } 8766 this.chmodSync(r3, Number(e3.mode)); 8767 } 8768 cpSymlinkSync(e3, n3, r3, i3) { 8769 let a2 = String(this.readlinkSync(n3)); 8770 !i3.verbatimSymlinks && !(0, t2.isAbsolute)(a2) && (a2 = w2(P2(n3), a2)), e3 && this.unlinkSync(r3), this.symlinkSync(a2, r3); 8771 } 8772 lstat(e3, t3, n3) { 8773 let [{ throwIfNoEntry: r3 = true, bigint: i3 = false }, a2] = (0, x2.getStatOptsAndCb)(t3, n3); 8774 this.wrapAsync(this._lstat, [(0, S2.pathToFilename)(e3), i3, r3], a2); 8775 } 8776 _stat(e3, t3 = false, r3 = true) { 8777 let a2 = this._core.getResolvedLinkResult(e3, `stat`); 8778 return a2.ok ? (0, n2.Ok)(i2.default.build(a2.value.getNode(), t3)) : a2.err.code === `ENOENT` && !r3 ? (0, n2.Ok)(void 0) : a2; 8779 } 8780 _statOrThrow(e3, t3 = false, n3 = true) { 8781 let r3 = this._stat(e3, t3, n3); 8782 if (r3.ok) return r3.value; 8783 throw r3.err.toError(); 8784 } 8785 statSync(e3, t3) { 8786 let { bigint: n3 = true, throwIfNoEntry: r3 = true } = (0, x2.getStatOptions)(t3), i3 = this._stat((0, S2.pathToFilename)(e3), n3, r3); 8787 if (i3.ok) return i3.value; 8788 throw i3.err.toError(); 8789 } 8790 stat(e3, t3, n3) { 8791 let [{ bigint: r3 = false, throwIfNoEntry: i3 = true }, a2] = (0, x2.getStatOptsAndCb)(t3, n3); 8792 this.wrapAsync(this._statOrThrow, [(0, S2.pathToFilename)(e3), r3, i3], a2); 8793 } 8794 fstatBase(e3, t3 = false) { 8795 let n3 = this._core.getFileByFd(e3); 8796 if (!n3) throw (0, S2.createError)(`EBADF`, `fstat`); 8797 return i2.default.build(n3.node, t3); 8798 } 8799 fstatSync(e3, t3) { 8800 return this.fstatBase(e3, (0, x2.getStatOptions)(t3).bigint); 8801 } 8802 fstat(e3, t3, n3) { 8803 let [r3, i3] = (0, x2.getStatOptsAndCb)(t3, n3); 8804 this.wrapAsync(this.fstatBase, [e3, r3.bigint], i3); 8805 } 8806 _exists(e3) { 8807 let t3 = this._stat(e3); 8808 return t3.ok ? (0, n2.Ok)(true) : t3; 8809 } 8810 _access(e3, t3) { 8811 let n3 = this._core.getResolvedLinkOrThrow(e3, `access`).getNode(); 8812 if (t3 !== E2 && (t3 & D2 && !n3.canRead() || t3 & O2 && !n3.canWrite() || t3 & k2 && !n3.canExecute())) throw (0, S2.createError)(`EACCES`, `access`, e3); 8813 } 8814 watchFile(e3, t3, n3) { 8815 let r3 = (0, S2.pathToFilename)(e3), i3 = t3, a2 = n3; 8816 if (typeof i3 == `function` && (a2 = t3, i3 = null), typeof a2 != `function`) throw Error(`"watchFile()" requires a listener function`); 8817 let o2 = 5007, s3 = true; 8818 i3 && typeof i3 == `object` && (typeof i3.interval == `number` && (o2 = i3.interval), typeof i3.persistent == `boolean` && (s3 = i3.persistent)); 8819 let c3 = this.statWatchers[r3]; 8820 return c3 || (c3 = new this.StatWatcher(), c3.start(r3, s3, o2), this.statWatchers[r3] = c3), c3.addListener(`change`, a2), c3; 8821 } 8822 unwatchFile(e3, t3) { 8823 let n3 = (0, S2.pathToFilename)(e3), r3 = this.statWatchers[n3]; 8824 r3 && (typeof t3 == `function` ? r3.removeListener(`change`, t3) : r3.removeAllListeners(`change`), r3.listenerCount(`change`) === 0 && (r3.stop(), delete this.statWatchers[n3])); 8825 } 8826 createReadStream(e3, t3) { 8827 return new this.ReadStream(e3, t3); 8828 } 8829 createWriteStream(e3, t3) { 8830 return new this.WriteStream(e3, t3); 8831 } 8832 watch(e3, t3, n3) { 8833 let r3 = (0, S2.pathToFilename)(e3), i3 = t3; 8834 typeof t3 == `function` && (n3 = t3, i3 = null); 8835 let { persistent: a2, recursive: o2, encoding: s3 } = (0, x2.getDefaultOpts)(i3); 8836 a2 === void 0 && (a2 = true), o2 === void 0 && (o2 = false); 8837 let c3 = new this.FSWatcher(); 8838 return c3.start(r3, a2, o2, s3), n3 && c3.addListener(`change`, n3), c3; 8839 } 8840 _statfs(e3, t3 = false) { 8841 return this._core.getResolvedLinkOrThrow(e3, `statfs`), c2.default.build(this._core, t3); 8842 } 8843 statfsSync(e3, t3) { 8844 let { bigint: n3 = false } = (0, x2.getStatfsOptions)(t3); 8845 return this._statfs((0, S2.pathToFilename)(e3), n3); 8846 } 8847 statfs(e3, t3, n3) { 8848 let [{ bigint: r3 = false }, i3] = (0, x2.getStatfsOptsAndCb)(t3, n3); 8849 this.wrapAsync(this._statfs, [(0, S2.pathToFilename)(e3), r3], i3); 8850 } 8851 toTree(e3 = { separator: t2.sep }) { 8852 return (0, _2.toTreeSync)(this, e3); 8853 } 8854 toSnapshot(e3 = `/`) { 8855 return v2.toSnapshotSync({ fs: this, path: e3 }); 8856 } 8857 fromSnapshot(e3, t3 = `/`) { 8858 return v2.fromSnapshotSync(e3, { fs: this, path: t3 }); 8859 } 8860 toBinarySnapshot(e3 = `/`) { 8861 return v2.toBinarySnapshotSync({ fs: this, path: e3 }); 8862 } 8863 fromBinarySnapshot(e3, t3 = `/`) { 8864 return v2.fromBinarySnapshotSync(e3, { fs: this, path: t3 }); 8865 } 8866 toJsonSnapshot(e3 = `/`) { 8867 let t3 = v2.toJsonSnapshotSync({ fs: this, path: e3 }); 8868 return l2.Buffer.from(t3).toString(`utf8`); 8869 } 8870 fromJsonSnapshot(e3, t3 = `/`) { 8871 let n3 = new Uint8Array(l2.Buffer.from(e3, `utf8`)); 8872 return v2.fromJsonSnapshotSync(n3, { fs: this, path: t3 }); 8873 } 8874 }; 8875 e2.Volume = H2, H2.fromJSON = (e3, t3, r3) => new H2(n2.Superblock.fromJSON(e3, t3, r3)), H2.fromNestedJSON = (e3, t3, r3) => new H2(n2.Superblock.fromNestedJSON(e3, t3, r3)); 8876 function U2(e3) { 8877 e3.emit(`stop`); 8878 } 8879 var W2 = class extends p2.EventEmitter { 8880 constructor(e3) { 8881 super(), this.onInterval = () => { 8882 try { 8883 let e4 = this.vol.statSync(this.filename);
8884 this.hasChanged(e4) && (this.emit(`change`, e4, this.prev), this.prev = e4); 8885 } finally { 8886 this.loop(); 8887 } 8888 }, this.vol = e3; 8889 } 8890 loop() { 8891 this.timeoutRef = this.setTimeout(this.onInterval, this.interval); 8892 } 8893 hasChanged(e3) { 8894 return e3.mtimeMs > this.prev.mtimeMs || e3.nlink !== this.prev.nlink; 8895 } 8896 start(e3, t3 = true, n3 = 5007) { 8897 this.filename = (0, S2.pathToFilename)(e3), this.setTimeout = t3 ? setTimeout.bind(typeof globalThis < `u` ? globalThis : o) : u2.default, this.interval = n3, this.prev = this.vol.statSync(this.filename), this.loop(); 8898 } 8899 stop() { 8900 clearTimeout(this.timeoutRef), queueMicrotask(() => { 8901 U2.call(this, this); 8902 }); 8903 } 8904 }; 8905 e2.StatWatcher = W2; 8906 var G2; 8907 function ee2(e3) { 8908 G2 = (0, l2.bufferAllocUnsafe)(e3), G2.used = 0; 8909 } 8910 (0, h2.inherits)(K2, d2.Readable), e2.ReadStream = K2; 8911 function K2(e3, t3, n3) { 8912 if (!(this instanceof K2)) return new K2(e3, t3, n3); 8913 if (this._vol = e3, n3 = Object.assign({}, (0, x2.getOptions)(n3, {})), n3.highWaterMark === void 0 && (n3.highWaterMark = 64 * 1024), d2.Readable.call(this, n3), this.path = (0, S2.pathToFilename)(t3), this._fileHandle = n3.fd && typeof n3.fd != `number` ? n3.fd : null, this.fd = n3.fd === void 0 ? null : typeof n3.fd == `number` ? n3.fd : n3.fd.fd, this.flags = n3.flags === void 0 ? `r` : n3.flags, this.mode = n3.mode === void 0 ? 438 : n3.mode, this.start = n3.start, this.end = n3.end, this.autoClose = n3.autoClose === void 0 ? true : n3.autoClose, this.pos = void 0, this.bytesRead = 0, this.start !== void 0) { 8914 if (typeof this.start != `number`) throw TypeError(`"start" option must be a Number`); 8915 if (this.end === void 0) this.end = 1 / 0; 8916 else if (typeof this.end != `number`) throw TypeError(`"end" option must be a Number`); 8917 if (this.start > this.end) throw Error(`"start" option must be <= "end" option`); 8918 this.pos = this.start; 8919 } 8920 typeof this.fd != `number` && this.open(), this.on(`end`, function() { 8921 this.autoClose && this.destroy && this.destroy(); 8922 }); 8923 } 8924 K2.prototype.open = function() { 8925 var e3 = this; 8926 this._vol.open(this.path, this.flags, this.mode, (t3, n3) => { 8927 if (t3) { 8928 e3.autoClose && e3.destroy && e3.destroy(), e3.emit(`error`, t3); 8929 return; 8930 } 8931 e3.fd = n3, e3.emit(`open`, n3), e3.read(); 8932 }); 8933 }, K2.prototype._read = function(e3) { 8934 if (typeof this.fd != `number`) return this.once(`open`, function() { 8935 this._read(e3); 8936 }); 8937 if (this.destroyed) return; 8938 (!G2 || G2.length - G2.used < I2) && ee2(this._readableState.highWaterMark); 8939 var t3 = G2, n3 = Math.min(G2.length - G2.used, e3), r3 = G2.used; 8940 if (this.pos !== void 0 && (n3 = Math.min(this.end - this.pos + 1, n3)), n3 <= 0) return this.push(null); 8941 var i3 = this; 8942 this._vol.read(this.fd, G2, G2.used, n3, this.pos, a2), this.pos !== void 0 && (this.pos += n3), G2.used += n3; 8943 function a2(e4, n4) { 8944 if (e4) i3.autoClose && i3.destroy && i3.destroy(), i3.emit(`error`, e4); 8945 else { 8946 var a3 = null; 8947 n4 > 0 && (i3.bytesRead += n4, a3 = t3.slice(r3, r3 + n4)), i3.push(a3); 8948 } 8949 } 8950 }, K2.prototype._destroy = function(e3, t3) { 8951 this.close((n3) => { 8952 t3(e3 || n3); 8953 }); 8954 }, K2.prototype.close = function(e3) { 8955 if (e3 && this.once(`close`, e3), this.closed || typeof this.fd != `number`) { 8956 if (typeof this.fd != `number`) { 8957 this.once(`open`, te2); 8958 return; 8959 } 8960 return queueMicrotask(() => this.emit(`close`)); 8961 } 8962 typeof this._readableState?.closed == `boolean` ? this._readableState.closed = true : this.closed = true, this._fileHandle ? this._fileHandle.close().then(() => this.emit(`close`), (e4) => this.emit(`error`, e4)) : this._vol.close(this.fd, (e4) => { 8963 e4 ? this.emit(`error`, e4) : this.emit(`close`); 8964 }), this.fd = null; 8965 }; 8966 function te2(e3) { 8967 this.close(); 8968 } 8969 (0, h2.inherits)(q2, d2.Writable), e2.WriteStream = q2; 8970 function q2(e3, t3, n3) { 8971 if (!(this instanceof q2)) return new q2(e3, t3, n3); 8972 if (this._vol = e3, n3 = Object.assign({}, (0, x2.getOptions)(n3, {})), d2.Writable.call(this, n3), this.path = (0, S2.pathToFilename)(t3), this._fileHandle = n3.fd && typeof n3.fd != `number` ? n3.fd : null, this.fd = n3.fd
8972=== void 0 ? null : typeof n3.fd == `number` ? n3.fd : n3.fd.fd, this.flags = n3.flags === void 0 ? `w` : n3.flags, this.mode = n3.mode === void 0 ? 438 : n3.mode, this.start = n3.start, this.autoClose = n3.autoClose === void 0 ? true : !!n3.autoClose, this.pos = void 0, this.bytesWritten = 0, this.pending = true, this.start !== void 0) { 8973 if (typeof this.start != `number`) throw TypeError(`"start" option must be a Number`); 8974 if (this.start < 0) throw Error(`"start" must be >= zero`); 8975 this.pos = this.start; 8976 } 8977 n3.encoding && this.setDefaultEncoding(n3.encoding), typeof this.fd != `number` && this.open(), this.once(`finish`, function() { 8978 this.autoClose && this.close(); 8979 }); 8980 } 8981 q2.prototype.open = function() { 8982 this._vol.open(this.path, this.flags, this.mode, function(e3, t3) { 8983 if (e3) { 8984 this.autoClose && this.destroy && this.destroy(), this.emit(`error`, e3); 8985 return; 8986 } 8987 this.fd = t3, this.pending = false, this.emit(`open`, t3); 8988 }.bind(this)); 8989 }, q2.prototype._write = function(e3, t3, n3) { 8990 if (!(e3 instanceof l2.Buffer || e3 instanceof Uint8Array)) return this.emit(`error`, Error(`Invalid data`)); 8991 if (typeof this.fd != `number`) return this.once(`open`, function() { 8992 this._write(e3, t3, n3); 8993 }); 8994 var r3 = this; 8995 this._vol.write(this.fd, e3, 0, e3.length, this.pos, (e4, t4) => { 8996 if (e4) return r3.autoClose && r3.destroy && r3.destroy(), n3(e4); 8997 r3.bytesWritten += t4, n3(); 8998 }), this.pos !== void 0 && (this.pos += e3.length); 8999 }, q2.prototype._writev = function(e3, t3) { 9000 if (typeof this.fd != `number`) return this.once(`open`, function() { 9001 this._writev(e3, t3); 9002 }); 9003 let n3 = this, r3 = e3.length, i3 = Array(r3); 9004 for (var a2 = 0, o2 = 0; o2 < r3; o2++) { 9005 var s3 = e3[o2].chunk; 9006 i3[o2] = s3, a2 += s3.length; 9007 } 9008 let c3 = l2.Buffer.concat(i3); 9009 this._vol.write(this.fd, c3, 0, c3.length, this.pos, (e4, r4) => { 9010 if (e4) return n3.destroy && n3.destroy(), t3(e4); 9011 n3.bytesWritten += r4, t3(); 9012 }), this.pos !== void 0 && (this.pos += a2); 9013 }, q2.prototype.close = function(e3) { 9014 if (e3 && this.once(`close`, e3), this.closed || typeof this.fd != `number`) { 9015 if (typeof this.fd != `number`) { 9016 this.once(`open`, te2); 9017 return; 9018 } 9019 return queueMicrotask(() => this.emit(`close`)); 9020 } 9021 typeof this._writableState?.closed == `boolean` ? this._writableState.closed = true : this.closed = true, this._fileHandle ? this._fileHandle.close().then(() => this.emit(`close`), (e4) => this.emit(`error`, e4)) : this._vol.close(this.fd, (e4) => { 9022 e4 ? this.emit(`error`, e4) : this.emit(`close`); 9023 }), this.fd = null; 9024 }, q2.prototype._destroy = K2.prototype._destroy, q2.prototype.destroySoon = q2.prototype.end; 9025 var J2 = class extends p2.EventEmitter { 9026 constructor(e3) { 9027 super(), this._filename = ``, this._filenameEncoded = ``, this._recursive = false, this._encoding = f2.ENCODING_UTF8, this._listenerRemovers = /* @__PURE__ */ new Map(), this._onParentChild = (e4) => { 9028 e4.getName() === this._getName() && this._emit(`rename`); 9029 }, this._emit = (e4) => { 9030 this.emit(`change`, e4, this._filenameEncoded); 9031 }, this._persist = () => { 9032 this._timer = setTimeout(this._persist, 1e6); 9033 }, this._vol = e3; 9034 } 9035 _getName() { 9036 return this._steps[this._steps.length - 1]; 9037 } 9038 start(e3, t3 = true, r3 = false, i3 = f2.ENCODING_UTF8) { 9039 this._filename = (0, S2.pathToFilename)(e3), this._steps = (0, n2.filenameToSteps)(this._filename), this._filenameEncoded = (0, f2.strToEncoding)(this._filename), this._recursive = r3, this._encoding = i3; 9040 try { 9041 this._link = this._vol._core.getLinkOrThrow(this._filename, `FSWatcher`); 9042 } catch (e4) { 9043 let t4 = Error(`watch ${this._filename} ${e4.code}`); 9044 throw t4.code = e4.code, t4.errno = e4.code, t4; 9045 } 9046 let a2 = (e4) => { 9047 let t4 = e4.getPath(), n3 = e4.getNode(), r4 = () => { 9048 let e5 = M2(this._filename, t4);
9049 return e5 || (e5 = this._getName()), this.emit(`change`, `change`, e5); 9050 }, i4 = n3.changes.listen(([e5]) => { 9051 e5 === `modify` && r4(); 9052 }), a3 = this._listenerRemovers.get(n3.ino) ?? []; 9053 a3.push(() => i4()), this._listenerRemovers.set(n3.ino, a3); 9054 }, o2 = (e4) => { 9055 let t4 = e4.getNode(), n3 = (e5) => { 9056 this.emit(`change`, `rename`, M2(this._filename, e5.getPath())), a2(e5), o2(e5); 9057 }, i4 = (e5) => { 9058 let t5 = (e6) => { 9059 let n4 = e6.getNode().ino, r4 = this._listenerRemovers.get(n4); 9060 r4 && (r4.forEach((e7) => e7()), this._listenerRemovers.delete(n4)); 9061 for (let [n5, r5] of e6.children.entries()) r5 && n5 !== `.` && n5 !== `..` && t5(r5); 9062 }; 9063 t5(e5), this.emit(`change`, `rename`, M2(this._filename, e5.getPath())); 9064 }; 9065 for (let [t5, n4] of e4.children.entries()) n4 && t5 !== `.` && t5 !== `..` && a2(n4); 9066 let s4 = e4.changes.listen(([e5, t5]) => { 9067 e5 === `child:add` ? n3(t5) : e5 === `child:del` && i4(t5); 9068 }); 9069 if ((this._listenerRemovers.get(t4.ino) ?? []).push(() => { 9070 s4(); 9071 }), r3) for (let [t5, n4] of e4.children.entries()) n4 && t5 !== `.` && t5 !== `..` && o2(n4); 9072 }; 9073 a2(this._link), o2(this._link); 9074 let s3 = this._link.parent; 9075 s3 && s3.changes.listen(([e4, t4]) => { 9076 e4 === `child:del` && this._onParentChild(t4); 9077 }), t3 && this._persist(); 9078 } 9079 close() { 9080 clearTimeout(this._timer), this._listenerRemovers.forEach((e3) => { 9081 e3.forEach((e4) => e4()); 9082 }), this._listenerRemovers.clear(), this._parentChangesUnsub?.(); 9083 } 9084 }; 9085 e2.FSWatcher = J2; 9086})), ni = i(((e2) => { 9087 Object.defineProperty(e2, `__esModule`, { value: true }), e2.fsCallbackApiList = void 0, e2.fsCallbackApiList = `access.appendFile.chmod.chown.close.copyFile.cp.createReadStream.createWriteStream.exists.fchmod.fchown.fdatasync.fstat.fsync.ftruncate.futimes.glob.lchmod.lchown.link.lstat.mkdir.mkdtemp.open.openAsBlob.opendir.read.readv.readdir.readFile.readlink.realpath.rename.rm.rmdir.stat.statfs.symlink.truncate.unlink.unwatchFile.utimes.lutimes.watch.watchFile.write.writev.writeFile`.split(`.`); 9088})), ri = i(((e2) => { 9089 Object.defineProperty(e2, `__esModule`, { value: true }), e2.fsSynchronousApiList = void 0, e2.fsSynchronousApiList = `accessSync.appendFileSync.chmodSync.chownSync.closeSync.copyFileSync.existsSync.fchmodSync.fchownSync.fdatasyncSync.fstatSync.fsyncSync.ftruncateSync.futimesSync.globSync.lchmodSync.lchownSync.linkSync.lstatSync.mkdirSync.mkdtempSync.openSync.opendirSync.readdirSync.readFileSync.readlinkSync.readSync.readvSync.realpathSync.renameSync.rmdirSync.rmSync.statSync.symlinkSync.truncateSync.unlinkSync.utimesSync.lutimesSync.writeFileSync.writeSync.writevSync`.split(`.`); 9090})), ii = i(((e2) => { 9091 Object.defineProperty(e2, `__esModule`, { value: true }), e2.fsCommonObjectsList = void 0, e2.fsCommonObjectsList = [`F_OK`, `R_OK`, `W_OK`, `X_OK`, `constants`, `Stats`, `StatFs`, `Dir`, `Dirent`, `StatsWatcher`, `FSWatcher`, `ReadStream`, `WriteStream`]; 9092})), ai = i(((t2) => { 9093 Object.defineProperty(t2, `__esModule`, { value: true }), t2.fsCommonObjectsList = t2.fsSynchronousApiList = t2.fsCallbackApiList = t2.FsPromises = t2.Dir = t2.FileHandle = t2.StatFs = t2.Dirent = t2.Stats = t2.toUnixTimestamp = t2.FSWatcher = t2.StatWatcher = t2.Volume = void 0; 9094 var n2 = (J(), e(f)), r2 = ti(); 9095 Object.defineProperty(t2, `Volume`, { enumerable: true, get: function() { 9096 return r2.Volume; 9097 } }), Object.defineProperty(t2, `StatWatcher`, { enumerable: true, get: function() { 9098 return r2.StatWatcher; 9099 } }), Object.defineProperty(t2, `FSWatcher`, { enumerable: true, get: function() { 9100 return r2.FSWatcher; 9101 } }), Object.defineProperty(t2, `toUnixTimestamp`, { enumerable: true, get: function() { 9102 return r2.toUnixTimestamp; 9103 } }); 9104 var i2 = vn(); 9105 Object.defineProperty(t2, `Stats`, { enumerable: true, get: function() { 9106 return i2.default; 9107 } }); 9108 var a2 = yn(); 9109 Object.defineProperty(t2, `Dirent`, { enumerable: true, get: function() { 9110 return a2.default; 9111 } }); 9112 var o2 = bn(); 9113 Object.defineProperty(t2, `StatFs`, { enumerable: true, get: function() { 9114 return o2.default; 9115 } }); 9116 var s2 = dr(); 9117 Object.defineProperty(t2, `FileHandle`, { enumerable: true, get: function() { 9118 return s2.FileHandle; 9119 } }); 9120 var c2 = Qr(); 9121 Object.defineProperty(t2, `Dir`, { enumerable: true, get: function() { 9122 return c2.Dir; 9123 } }); 9124 var l2 = fr(); 9125 Object.defineProperty(t2, `FsPromises`, { enumerable: true, get: function() {
9126 return l2.FsPromises; 9127 } }), n2.__exportStar(Zr(), t2), n2.__exportStar(ur(), t2), n2.__exportStar(ei(), t2); 9128 var u2 = ni(); 9129 Object.defineProperty(t2, `fsCallbackApiList`, { enumerable: true, get: function() { 9130 return u2.fsCallbackApiList; 9131 } }); 9132 var d2 = ri(); 9133 Object.defineProperty(t2, `fsSynchronousApiList`, { enumerable: true, get: function() { 9134 return d2.fsSynchronousApiList; 9135 } }); 9136 var p2 = ii(); 9137 Object.defineProperty(t2, `fsCommonObjectsList`, { enumerable: true, get: function() { 9138 return p2.fsCommonObjectsList; 9139 } }); 9140})), oi = i(((e2, t2) => { 9141 Object.defineProperty(e2, `__esModule`, { value: true }), e2.memfs = e2.fs = e2.vol = e2.Volume = void 0, e2.createFsFromVolume = c2; 9142 var n2 = ai(); 9143 Object.defineProperty(e2, `Volume`, { enumerable: true, get: function() { 9144 return n2.Volume; 9145 } }); 9146 var r2 = $(), { F_OK: i2, R_OK: a2, W_OK: o2, X_OK: s2 } = r2.constants; 9147 e2.vol = new n2.Volume(); 9148 function c2(e3) { 9149 let t3 = { F_OK: i2, R_OK: a2, W_OK: o2, X_OK: s2, constants: r2.constants, Stats: n2.Stats, Dirent: n2.Dirent }; 9150 for (let r3 of n2.fsSynchronousApiList) typeof e3[r3] == `function` && (t3[r3] = e3[r3].bind(e3)); 9151 for (let r3 of n2.fsCallbackApiList) typeof e3[r3] == `function` && (t3[r3] = e3[r3].bind(e3)); 9152 return t3.StatWatcher = e3.StatWatcher, t3.FSWatcher = e3.FSWatcher, t3.WriteStream = e3.WriteStream, t3.ReadStream = e3.ReadStream, t3.promises = e3.promises, typeof e3.realpath == `function` && (t3.realpath = e3.realpath.bind(e3), typeof e3.realpath.native == `function` && (t3.realpath.native = e3.realpath.native.bind(e3))), typeof e3.realpathSync == `function` && (t3.realpathSync = e3.realpathSync.bind(e3), typeof e3.realpathSync.native == `function` && (t3.realpathSync.native = e3.realpathSync.native.bind(e3))), t3._toUnixTimestamp = n2.toUnixTimestamp, t3.__vol = e3, t3; 9153 } 9154 e2.fs = c2(e2.vol), e2.memfs = (e3 = {}, t3 = `/`) => { 9155 let r3 = typeof t3 == `string` ? { cwd: t3 } : t3, i3 = r3.cwd ?? (r3.process ? void 0 : `/`), a3 = n2.Volume.fromNestedJSON(e3, i3, { process: r3.process }); 9156 return { fs: c2(a3), vol: a3 }; 9157 }, t2.exports = { ...t2.exports, ...e2.fs }, t2.exports.semantic = true; 9158})); 9159export { 9160 mt as a, 9161 Ce as c, 9162 mn as i, 9163 Se as l, 9164 Yn as n, 9165 rt as o, 9166 Wn as r, 9167 De as s, 9168 oi as t 9169};
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.