Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

idmp

Package Overview
Dependencies
Maintainers
0
Versions
98
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

idmp - npm Package Compare versions

Comparing version 2.1.8 to 2.1.9

2

dist/index.browser.esm.js

@@ -1,2 +0,2 @@

/*! idmp v2.1.8 | (c) github/haozi | MIT */
/*! idmp v2.1.9 | (c) github/haozi | MIT */
const x = () => {

@@ -3,0 +3,0 @@ };

@@ -1,2 +0,2 @@

/*! idmp v2.1.8 | (c) github/haozi | MIT */
/*! idmp v2.1.9 | (c) github/haozi | MIT */
(function(n,f){typeof exports=="object"&&typeof module!="undefined"?f(exports):typeof define=="function"&&define.amd?define(["exports"],f):(n=typeof globalThis!="undefined"?globalThis:n||self,f(n.idmp={}))})(this,function(n){"use strict";const g=()=>{},l=e=>e<0?0:e>6048e5?6048e5:e;n.g={};const a=e=>{const{maxRetry:i=30,maxAge:u=3e3,onBeforeRetry:c=g}=e||{},m=l(u);return{maxRetry:i,maxAge:m,onBeforeRetry:c,f:u===1/0}},r=e=>{e&&(n.g[e]=void 0)},_=()=>{n.g={}},h=(e,i,u)=>{if(!e)return i();const{maxRetry:c,maxAge:m,onBeforeRetry:p,f:R}=a(u);n.g[e]=n.g[e]||{0:0,1:0,4:[]};const t=n.g[e],T=()=>{t[1]=0,t[2]=void 0,t[3]=void 0},M=()=>{const o=t[4].length;for(let s=0;s<o;++s)t[4][s][0](t[2]);t[4]=[],R||setTimeout(()=>{r(e)},m)},y=()=>{const o=t[4].length-c;for(let s=0;s<o;++s)t[4][s][1](t[3]);r(e)},A=()=>new Promise((o,s)=>{if(!t[5]&&(t[5]=i),t[2]){o(t[2]);return}t[1]===0?(t[1]=1,t[4].push([o,s]),t[5]().then(d=>{t[2]=d,M(),t[1]=4}).catch(d=>{t[1]=3,t[3]=d,++t[0],t[0]>c?y():(p(d,{globalKey:e,retryCount:t[0]}),T(),setTimeout(A,(t[0]-1)*50))})):t[1]===1&&t[4].push([o,s])});return A()};h.flush=r,h.flushAll=_,n.default=h,n.getOptions=a,Object.defineProperties(n,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}})});

@@ -1,2 +0,2 @@

/*! idmp v2.1.8 | (c) github/haozi | MIT */
/*! idmp v2.1.9 | (c) github/haozi | MIT */
const DEFAULT_MAX_AGE = 3e3;

@@ -3,0 +3,0 @@ const _7days = 6048e5;

@@ -1,2 +0,2 @@

/*! idmp v2.1.8 | (c) github/haozi | MIT */
/*! idmp v2.1.9 | (c) github/haozi | MIT */
const DEFAULT_MAX_AGE = 3e3;

@@ -3,0 +3,0 @@ const _7days = 6048e5;

{
"name": "idmp",
"version": "2.1.8",
"version": "2.1.9",
"keywords": [

@@ -5,0 +5,0 @@ "deduplicate network requests",

@@ -18,3 +18,3 @@ /*! idmp v1.0.0 | (c) github/haozi | MIT */

});
/*! idmp v2.1.8 | (c) github/haozi | MIT */
/*! idmp v2.1.9 | (c) github/haozi | MIT */
const h = () => {

@@ -21,0 +21,0 @@ }, l = (r) => r < 0 ? 0 : r > 6048e5 ? 6048e5 : r, m = (r) => {

/*! idmp v1.0.0 | (c) github/haozi | MIT */
(function(a,u){typeof exports=="object"&&typeof module!="undefined"?u(exports):typeof define=="function"&&define.amd?define(["exports"],u):(a=typeof globalThis!="undefined"?globalThis:a||self,u(a.idmp={}))})(this,function(a){"use strict";var D=(a,u,i)=>new Promise((m,h)=>{var g=c=>{try{s(i.next(c))}catch(d){h(d)}},A=c=>{try{s(i.throw(c))}catch(d){h(d)}},s=c=>c.done?m(c.value):Promise.resolve(c.value).then(g,A);s((i=i.apply(a,u)).next())});/*! idmp v2.1.8 | (c) github/haozi | MIT */const m=()=>{},h=n=>n<0?0:n>6048e5?6048e5:n,g=n=>{const{maxRetry:o=30,maxAge:e=3e3,onBeforeRetry:r=m}=n||{},t=h(e);return{maxRetry:o,maxAge:t,onBeforeRetry:r,f:e===1/0}},s=n=>`@idmp/v1/${n}`,c=n=>{let o;try{o=window[n]}catch(e){}return{get:e=>{if(!e)return;const r=s(e);let t;try{if(t=JSON.parse(o[r]),t===void 0)return;const{t:f,a:l,d:y}=t;if(Date.now()-f>l){o.removeItem(r);return}return y}catch(f){}},set:(e,r,t)=>{if(!e)return;const f=s(e);try{o[f]=JSON.stringify({t:Date.now(),a:t,d:r})}catch(l){}},remove:e=>{if(e)try{const r=s(e);o.removeItem(r)}catch(r){}},clear:()=>{try{o.clear()}catch(e){}}}},d=(n,o="sessionStorage")=>{const e=c(o),r=(t,f,l)=>{const y=g(l);return n(t,()=>D(this,null,function*(){const v=e.get(t);if(v!==void 0)return v;const p=yield f();return p!==void 0&&e.set(t,p,y.maxAge),p}),l)};return r.flush=t=>{n.flush(t),e.remove(t)},r.flushAll=()=>{n.flushAll(),e.clear()},r};a.default=d,a.getCacheKey=s,Object.defineProperties(a,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}})});
(function(a,u){typeof exports=="object"&&typeof module!="undefined"?u(exports):typeof define=="function"&&define.amd?define(["exports"],u):(a=typeof globalThis!="undefined"?globalThis:a||self,u(a.idmp={}))})(this,function(a){"use strict";var D=(a,u,i)=>new Promise((m,h)=>{var g=c=>{try{s(i.next(c))}catch(d){h(d)}},A=c=>{try{s(i.throw(c))}catch(d){h(d)}},s=c=>c.done?m(c.value):Promise.resolve(c.value).then(g,A);s((i=i.apply(a,u)).next())});/*! idmp v2.1.9 | (c) github/haozi | MIT */const m=()=>{},h=n=>n<0?0:n>6048e5?6048e5:n,g=n=>{const{maxRetry:o=30,maxAge:e=3e3,onBeforeRetry:r=m}=n||{},t=h(e);return{maxRetry:o,maxAge:t,onBeforeRetry:r,f:e===1/0}},s=n=>`@idmp/v1/${n}`,c=n=>{let o;try{o=window[n]}catch(e){}return{get:e=>{if(!e)return;const r=s(e);let t;try{if(t=JSON.parse(o[r]),t===void 0)return;const{t:f,a:l,d:y}=t;if(Date.now()-f>l){o.removeItem(r);return}return y}catch(f){}},set:(e,r,t)=>{if(!e)return;const f=s(e);try{o[f]=JSON.stringify({t:Date.now(),a:t,d:r})}catch(l){}},remove:e=>{if(e)try{const r=s(e);o.removeItem(r)}catch(r){}},clear:()=>{try{o.clear()}catch(e){}}}},d=(n,o="sessionStorage")=>{const e=c(o),r=(t,f,l)=>{const y=g(l);return n(t,()=>D(this,null,function*(){const v=e.get(t);if(v!==void 0)return v;const p=yield f();return p!==void 0&&e.set(t,p,y.maxAge),p}),l)};return r.flush=t=>{n.flush(t),e.remove(t)},r.flushAll=()=>{n.flushAll(),e.clear()},r};a.default=d,a.getCacheKey=s,Object.defineProperties(a,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}})});

@@ -22,3 +22,3 @@ /*! idmp v1.0.0 | (c) github/haozi | MIT */

};
/*! idmp v2.1.8 | (c) github/haozi | MIT */
/*! idmp v2.1.9 | (c) github/haozi | MIT */
const DEFAULT_MAX_AGE = 3e3;

@@ -25,0 +25,0 @@ const _7days = 6048e5;

@@ -22,3 +22,3 @@ /*! idmp v1.0.0 | (c) github/haozi | MIT */

};
/*! idmp v2.1.8 | (c) github/haozi | MIT */
/*! idmp v2.1.9 | (c) github/haozi | MIT */
const DEFAULT_MAX_AGE = 3e3;

@@ -25,0 +25,0 @@ const _7days = 6048e5;

/*! idmp v1.0.0 | (c) github/haozi | MIT */
var Yt = Object.defineProperty;
var Je = Object.getOwnPropertySymbols;
var Vt = Object.prototype.hasOwnProperty, Xt = Object.prototype.propertyIsEnumerable;
var ze = (e, t, r) => t in e ? Yt(e, t, { enumerable: !0, configurable: !0, writable: !0, value: r }) : e[t] = r, B = (e, t) => {
for (var r in t || (t = {}))
Vt.call(t, r) && ze(e, r, t[r]);
if (Je)
for (var r of Je(t))
Xt.call(t, r) && ze(e, r, t[r]);
var Jt = Object.defineProperty;
var Xe = Object.getOwnPropertySymbols;
var Wt = Object.prototype.hasOwnProperty, zt = Object.prototype.propertyIsEnumerable;
var He = (e, n, i) => n in e ? Jt(e, n, { enumerable: !0, configurable: !0, writable: !0, value: i }) : e[n] = i, z = (e, n) => {
for (var i in n || (n = {}))
Wt.call(n, i) && He(e, i, n[i]);
if (Xe)
for (var i of Xe(n))
zt.call(n, i) && He(e, i, n[i]);
return e;
};
var E = (e, t, r) => new Promise((n, i) => {
var o = (u) => {
var $ = (e, n, i) => new Promise((a, c) => {
var u = (y) => {
try {
s(r.next(u));
} catch (p) {
i(p);
w(i.next(y));
} catch (m) {
c(m);
}
}, c = (u) => {
}, r = (y) => {
try {
s(r.throw(u));
} catch (p) {
i(p);
w(i.throw(y));
} catch (m) {
c(m);
}
}, s = (u) => u.done ? n(u.value) : Promise.resolve(u.value).then(o, c);
s((r = r.apply(e, t)).next());
}, w = (y) => y.done ? a(y.value) : Promise.resolve(y.value).then(u, r);
w((i = i.apply(e, n)).next());
});
/*! idmp v2.1.8 | (c) github/haozi | MIT */
const Ht = () => {
}, Kt = (e) => e < 0 ? 0 : e > 6048e5 ? 6048e5 : e, Qt = (e) => {
/*! idmp v2.1.9 | (c) github/haozi | MIT */
const Gt = () => {
}, Yt = (e) => e < 0 ? 0 : e > 6048e5 ? 6048e5 : e, Vt = (e) => {
const {
maxRetry: t = 30,
maxAge: r = 3e3,
onBeforeRetry: n = Ht
} = e || {}, i = Kt(r);
maxRetry: n = 30,
maxAge: i = 3e3,
onBeforeRetry: a = Gt
} = e || {}, c = Yt(i);
return {
maxRetry: t,
maxAge: i,
onBeforeRetry: n,
f: r === 1 / 0
maxRetry: n,
maxAge: c,
onBeforeRetry: a,
f: i === 1 / 0
// Infinity
};
}, Zt = new Proxy({}, {
get(e, t) {
throw new Error(`Module "node:os" has been externalized for browser compatibility. Cannot access "node:os.${t}" in client code. See https://vite.dev/guide/troubleshooting.html#module-externalized-for-browser-compatibility for more details.`);
}, Xt = new Proxy({}, {
get(e, n) {
throw new Error(`Module "node:os" has been externalized for browser compatibility. Cannot access "node:os.${n}" in client code. See https://vite.dev/guide/troubleshooting.html#module-externalized-for-browser-compatibility for more details.`);
}
}), st = new Proxy({}, {
get(e, t) {
throw new Error(`Module "node:path" has been externalized for browser compatibility. Cannot access "node:path.${t}" in client code. See https://vite.dev/guide/troubleshooting.html#module-externalized-for-browser-compatibility for more details.`);
}), Nt = new Proxy({}, {
get(e, n) {
throw new Error(`Module "node:path" has been externalized for browser compatibility. Cannot access "node:path.${n}" in client code. See https://vite.dev/guide/troubleshooting.html#module-externalized-for-browser-compatibility for more details.`);
}
});
var ue = typeof globalThis != "undefined" ? globalThis : typeof window != "undefined" ? window : typeof global != "undefined" ? global : typeof self != "undefined" ? self : {};
function ut(e) {
var ie = typeof globalThis != "undefined" ? globalThis : typeof window != "undefined" ? window : typeof global != "undefined" ? global : typeof self != "undefined" ? self : {};
function Tt(e) {
return e && e.__esModule && Object.prototype.hasOwnProperty.call(e, "default") ? e.default : e;
}
function K(e) {
function Q(e) {
if (e.__esModule) return e;
var t = e.default;
if (typeof t == "function") {
var r = function n() {
return this instanceof n ? Reflect.construct(t, arguments, this.constructor) : t.apply(this, arguments);
var n = e.default;
if (typeof n == "function") {
var i = function a() {
return this instanceof a ? Reflect.construct(n, arguments, this.constructor) : n.apply(this, arguments);
};
r.prototype = t.prototype;
} else r = {};
return Object.defineProperty(r, "__esModule", { value: !0 }), Object.keys(e).forEach(function(n) {
var i = Object.getOwnPropertyDescriptor(e, n);
Object.defineProperty(r, n, i.get ? i : {
i.prototype = n.prototype;
} else i = {};
return Object.defineProperty(i, "__esModule", { value: !0 }), Object.keys(e).forEach(function(a) {
var c = Object.getOwnPropertyDescriptor(e, a);
Object.defineProperty(i, a, c.get ? c : {
enumerable: !0,
get: function() {
return e[n];
return e[a];
}
});
}), r;
}), i;
}
var I = {}, x = {};
x.fromCallback = function(e) {
return Object.defineProperty(function(...t) {
if (typeof t[t.length - 1] == "function") e.apply(this, t);
else
return new Promise((r, n) => {
t.push((i, o) => i != null ? n(i) : r(o)), e.apply(this, t);
});
}, "name", { value: e.name });
};
x.fromPromise = function(e) {
return Object.defineProperty(function(...t) {
const r = t[t.length - 1];
if (typeof r != "function") return e.apply(this, t);
t.pop(), e.apply(this, t).then((n) => r(null, n), r);
}, "name", { value: e.name });
};
const er = new Proxy({}, {
get(e, t) {
throw new Error(`Module "fs" has been externalized for browser compatibility. Cannot access "fs.${t}" in client code. See https://vite.dev/guide/troubleshooting.html#module-externalized-for-browser-compatibility for more details.`);
var me = {}, ae = {}, Ke;
function U() {
return Ke || (Ke = 1, ae.fromCallback = function(e) {
return Object.defineProperty(function(...n) {
if (typeof n[n.length - 1] == "function") e.apply(this, n);
else
return new Promise((i, a) => {
n.push((c, u) => c != null ? a(c) : i(u)), e.apply(this, n);
});
}, "name", { value: e.name });
}, ae.fromPromise = function(e) {
return Object.defineProperty(function(...n) {
const i = n[n.length - 1];
if (typeof i != "function") return e.apply(this, n);
n.pop(), e.apply(this, n).then((a) => i(null, a), i);
}, "name", { value: e.name });
}), ae;
}
const Ht = new Proxy({}, {
get(e, n) {
throw new Error(`Module "fs" has been externalized for browser compatibility. Cannot access "fs.${n}" in client code. See https://vite.dev/guide/troubleshooting.html#module-externalized-for-browser-compatibility for more details.`);
}
}), tr = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
}), Kt = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
__proto__: null,
default: er
}, Symbol.toStringTag, { value: "Module" })), ft = /* @__PURE__ */ K(tr), rr = new Proxy({}, {
get(e, t) {
throw new Error(`Module "constants" has been externalized for browser compatibility. Cannot access "constants.${t}" in client code. See https://vite.dev/guide/troubleshooting.html#module-externalized-for-browser-compatibility for more details.`);
default: Ht
}, Symbol.toStringTag, { value: "Module" })), Lt = /* @__PURE__ */ Q(Kt), Qt = new Proxy({}, {
get(e, n) {
throw new Error(`Module "constants" has been externalized for browser compatibility. Cannot access "constants.${n}" in client code. See https://vite.dev/guide/troubleshooting.html#module-externalized-for-browser-compatibility for more details.`);
}
}), nr = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
}), Zt = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
__proto__: null,
default: rr
}, Symbol.toStringTag, { value: "Module" })), ir = /* @__PURE__ */ K(nr);
var Y = ir, or = process.cwd, Se = null, cr = process.env.GRACEFUL_FS_PLATFORM || process.platform;
process.cwd = function() {
return Se || (Se = or.call(process)), Se;
};
try {
process.cwd();
} catch (e) {
}
if (typeof process.chdir == "function") {
var Ge = process.chdir;
process.chdir = function(e) {
Se = null, Ge.call(process, e);
}, Object.setPrototypeOf && Object.setPrototypeOf(process.chdir, Ge);
}
var ar = sr;
function sr(e) {
Y.hasOwnProperty("O_SYMLINK") && process.version.match(/^v0\.6\.[0-2]|^v0\.5\./) && t(e), e.lutimes || r(e), e.chown = o(e.chown), e.fchown = o(e.fchown), e.lchown = o(e.lchown), e.chmod = n(e.chmod), e.fchmod = n(e.fchmod), e.lchmod = n(e.lchmod), e.chownSync = c(e.chownSync), e.fchownSync = c(e.fchownSync), e.lchownSync = c(e.lchownSync), e.chmodSync = i(e.chmodSync), e.fchmodSync = i(e.fchmodSync), e.lchmodSync = i(e.lchmodSync), e.stat = s(e.stat), e.fstat = s(e.fstat), e.lstat = s(e.lstat), e.statSync = u(e.statSync), e.fstatSync = u(e.fstatSync), e.lstatSync = u(e.lstatSync), e.chmod && !e.lchmod && (e.lchmod = function(a, l, y) {
y && process.nextTick(y);
}, e.lchmodSync = function() {
}), e.chown && !e.lchown && (e.lchown = function(a, l, y, f) {
f && process.nextTick(f);
}, e.lchownSync = function() {
}), cr === "win32" && (e.rename = typeof e.rename != "function" ? e.rename : function(a) {
function l(y, f, d) {
var v = Date.now(), _ = 0;
a(y, f, function w(m) {
if (m && (m.code === "EACCES" || m.code === "EPERM" || m.code === "EBUSY") && Date.now() - v < 6e4) {
setTimeout(function() {
e.stat(f, function(S, W) {
S && S.code === "ENOENT" ? a(y, f, w) : d(m);
});
}, _), _ < 100 && (_ += 10);
return;
default: Qt
}, Symbol.toStringTag, { value: "Module" })), er = /* @__PURE__ */ Q(Zt);
var de, Qe;
function tr() {
if (Qe) return de;
Qe = 1;
var e = er, n = process.cwd, i = null, a = process.env.GRACEFUL_FS_PLATFORM || process.platform;
process.cwd = function() {
return i || (i = n.call(process)), i;
};
try {
process.cwd();
} catch (r) {
}
if (typeof process.chdir == "function") {
var c = process.chdir;
process.chdir = function(r) {
i = null, c.call(process, r);
}, Object.setPrototypeOf && Object.setPrototypeOf(process.chdir, c);
}
de = u;
function u(r) {
e.hasOwnProperty("O_SYMLINK") && process.version.match(/^v0\.6\.[0-2]|^v0\.5\./) && w(r), r.lutimes || y(r), r.chown = v(r.chown), r.fchown = v(r.fchown), r.lchown = v(r.lchown), r.chmod = m(r.chmod), r.fchmod = m(r.fchmod), r.lchmod = m(r.lchmod), r.chownSync = s(r.chownSync), r.fchownSync = s(r.fchownSync), r.lchownSync = s(r.lchownSync), r.chmodSync = E(r.chmodSync), r.fchmodSync = E(r.fchmodSync), r.lchmodSync = E(r.lchmodSync), r.stat = f(r.stat), r.fstat = f(r.fstat), r.lstat = f(r.lstat), r.statSync = _(r.statSync), r.fstatSync = _(r.fstatSync), r.lstatSync = _(r.lstatSync), r.chmod && !r.lchmod && (r.lchmod = function(t, o, l) {
l && process.nextTick(l);
}, r.lchmodSync = function() {
}), r.chown && !r.lchown && (r.lchown = function(t, o, l, h) {
h && process.nextTick(h);
}, r.lchownSync = function() {
}), a === "win32" && (r.rename = typeof r.rename != "function" ? r.rename : function(t) {
function o(l, h, g) {
var p = Date.now(), b = 0;
t(l, h, function S(k) {
if (k && (k.code === "EACCES" || k.code === "EPERM" || k.code === "EBUSY") && Date.now() - p < 6e4) {
setTimeout(function() {
r.stat(h, function(P, x) {
P && P.code === "ENOENT" ? t(l, h, S) : g(k);
});
}, b), b < 100 && (b += 10);
return;
}
g && g(k);
});
}
return Object.setPrototypeOf && Object.setPrototypeOf(o, t), o;
}(r.rename)), r.read = typeof r.read != "function" ? r.read : function(t) {
function o(l, h, g, p, b, S) {
var k;
if (S && typeof S == "function") {
var P = 0;
k = function(x, V, G) {
if (x && x.code === "EAGAIN" && P < 10)
return P++, t.call(r, l, h, g, p, b, k);
S.apply(this, arguments);
};
}
d && d(m);
});
}
return Object.setPrototypeOf && Object.setPrototypeOf(l, a), l;
}(e.rename)), e.read = typeof e.read != "function" ? e.read : function(a) {
function l(y, f, d, v, _, w) {
var m;
if (w && typeof w == "function") {
var S = 0;
m = function(W, Z, We) {
if (W && W.code === "EAGAIN" && S < 10)
return S++, a.call(e, y, f, d, v, _, m);
w.apply(this, arguments);
};
return t.call(r, l, h, g, p, b, k);
}
return a.call(e, y, f, d, v, _, m);
}
return Object.setPrototypeOf && Object.setPrototypeOf(l, a), l;
}(e.read), e.readSync = typeof e.readSync != "function" ? e.readSync : /* @__PURE__ */ function(a) {
return function(l, y, f, d, v) {
for (var _ = 0; ; )
return Object.setPrototypeOf && Object.setPrototypeOf(o, t), o;
}(r.read), r.readSync = typeof r.readSync != "function" ? r.readSync : /* @__PURE__ */ function(t) {
return function(o, l, h, g, p) {
for (var b = 0; ; )
try {
return t.call(r, o, l, h, g, p);
} catch (S) {
if (S.code === "EAGAIN" && b < 10) {
b++;
continue;
}
throw S;
}
};
}(r.readSync);
function w(t) {
t.lchmod = function(o, l, h) {
t.open(
o,
e.O_WRONLY | e.O_SYMLINK,
l,
function(g, p) {
if (g) {
h && h(g);
return;
}
t.fchmod(p, l, function(b) {
t.close(p, function(S) {
h && h(b || S);
});
});
}
);
}, t.lchmodSync = function(o, l) {
var h = t.openSync(o, e.O_WRONLY | e.O_SYMLINK, l), g = !0, p;
try {
return a.call(e, l, y, f, d, v);
} catch (w) {
if (w.code === "EAGAIN" && _ < 10) {
_++;
continue;
}
throw w;
p = t.fchmodSync(h, l), g = !1;
} finally {
if (g)
try {
t.closeSync(h);
} catch (b) {
}
else
t.closeSync(h);
}
};
}(e.readSync);
function t(a) {
a.lchmod = function(l, y, f) {
a.open(
l,
Y.O_WRONLY | Y.O_SYMLINK,
y,
function(d, v) {
if (d) {
f && f(d);
return p;
};
}
function y(t) {
e.hasOwnProperty("O_SYMLINK") && t.futimes ? (t.lutimes = function(o, l, h, g) {
t.open(o, e.O_SYMLINK, function(p, b) {
if (p) {
g && g(p);
return;
}
a.fchmod(v, y, function(_) {
a.close(v, function(w) {
f && f(_ || w);
t.futimes(b, l, h, function(S) {
t.close(b, function(k) {
g && g(S || k);
});
});
});
}, t.lutimesSync = function(o, l, h) {
var g = t.openSync(o, e.O_SYMLINK), p, b = !0;
try {
p = t.futimesSync(g, l, h), b = !1;
} finally {
if (b)
try {
t.closeSync(g);
} catch (S) {
}
else
t.closeSync(g);
}
);
}, a.lchmodSync = function(l, y) {
var f = a.openSync(l, Y.O_WRONLY | Y.O_SYMLINK, y), d = !0, v;
try {
v = a.fchmodSync(f, y), d = !1;
} finally {
if (d)
try {
a.closeSync(f);
} catch (_) {
}
else
a.closeSync(f);
return p;
}) : t.futimes && (t.lutimes = function(o, l, h, g) {
g && process.nextTick(g);
}, t.lutimesSync = function() {
});
}
function m(t) {
return t && function(o, l, h) {
return t.call(r, o, l, function(g) {
d(g) && (g = null), h && h.apply(this, arguments);
});
};
}
function E(t) {
return t && function(o, l) {
try {
return t.call(r, o, l);
} catch (h) {
if (!d(h)) throw h;
}
};
}
function v(t) {
return t && function(o, l, h, g) {
return t.call(r, o, l, h, function(p) {
d(p) && (p = null), g && g.apply(this, arguments);
});
};
}
function s(t) {
return t && function(o, l, h) {
try {
return t.call(r, o, l, h);
} catch (g) {
if (!d(g)) throw g;
}
};
}
function f(t) {
return t && function(o, l, h) {
typeof l == "function" && (h = l, l = null);
function g(p, b) {
b && (b.uid < 0 && (b.uid += 4294967296), b.gid < 0 && (b.gid += 4294967296)), h && h.apply(this, arguments);
}
return l ? t.call(r, o, l, g) : t.call(r, o, g);
};
}
function _(t) {
return t && function(o, l) {
var h = l ? t.call(r, o, l) : t.call(r, o);
return h && (h.uid < 0 && (h.uid += 4294967296), h.gid < 0 && (h.gid += 4294967296)), h;
};
}
function d(t) {
if (!t || t.code === "ENOSYS")
return !0;
var o = !process.getuid || process.getuid() !== 0;
return !!(o && (t.code === "EINVAL" || t.code === "EPERM"));
}
}
return de;
}
const rr = new Proxy({}, {
get(e, n) {
throw new Error(`Module "stream" has been externalized for browser compatibility. Cannot access "stream.${n}" in client code. See https://vite.dev/guide/troubleshooting.html#module-externalized-for-browser-compatibility for more details.`);
}
}), nr = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
__proto__: null,
default: rr
}, Symbol.toStringTag, { value: "Module" })), ir = /* @__PURE__ */ Q(nr);
var he, Ze;
function or() {
if (Ze) return he;
Ze = 1;
var e = ir.Stream;
he = n;
function n(i) {
return {
ReadStream: a,
WriteStream: c
};
function a(u, r) {
if (!(this instanceof a)) return new a(u, r);
e.call(this);
var w = this;
this.path = u, this.fd = null, this.readable = !0, this.paused = !1, this.flags = "r", this.mode = 438, this.bufferSize = 64 * 1024, r = r || {};
for (var y = Object.keys(r), m = 0, E = y.length; m < E; m++) {
var v = y[m];
this[v] = r[v];
}
return v;
};
}
function r(a) {
Y.hasOwnProperty("O_SYMLINK") && a.futimes ? (a.lutimes = function(l, y, f, d) {
a.open(l, Y.O_SYMLINK, function(v, _) {
if (v) {
d && d(v);
if (this.encoding && this.setEncoding(this.encoding), this.start !== void 0) {
if (typeof this.start != "number")
throw TypeError("start must be a Number");
if (this.end === void 0)
this.end = 1 / 0;
else if (typeof this.end != "number")
throw TypeError("end must be a Number");
if (this.start > this.end)
throw new Error("start must be <= end");
this.pos = this.start;
}
if (this.fd !== null) {
process.nextTick(function() {
w._read();
});
return;
}
i.open(this.path, this.flags, this.mode, function(s, f) {
if (s) {
w.emit("error", s), w.readable = !1;
return;
}
a.futimes(_, y, f, function(w) {
a.close(_, function(m) {
d && d(w || m);
});
});
w.fd = f, w.emit("open", f), w._read();
});
}, a.lutimesSync = function(l, y, f) {
var d = a.openSync(l, Y.O_SYMLINK), v, _ = !0;
try {
v = a.futimesSync(d, y, f), _ = !1;
} finally {
if (_)
try {
a.closeSync(d);
} catch (w) {
}
else
a.closeSync(d);
}
function c(u, r) {
if (!(this instanceof c)) return new c(u, r);
e.call(this), this.path = u, this.fd = null, this.writable = !0, this.flags = "w", this.encoding = "binary", this.mode = 438, this.bytesWritten = 0, r = r || {};
for (var w = Object.keys(r), y = 0, m = w.length; y < m; y++) {
var E = w[y];
this[E] = r[E];
}
return v;
}) : a.futimes && (a.lutimes = function(l, y, f, d) {
d && process.nextTick(d);
}, a.lutimesSync = function() {
});
if (this.start !== void 0) {
if (typeof this.start != "number")
throw TypeError("start must be a Number");
if (this.start < 0)
throw new Error("start must be >= zero");
this.pos = this.start;
}
this.busy = !1, this._queue = [], this.fd === null && (this._open = i.open, this._queue.push([this._open, this.path, this.flags, this.mode, void 0]), this.flush());
}
}
function n(a) {
return a && function(l, y, f) {
return a.call(e, l, y, function(d) {
p(d) && (d = null), f && f.apply(this, arguments);
});
};
return he;
}
var we, et;
function ar() {
if (et) return we;
et = 1, we = n;
var e = Object.getPrototypeOf || function(i) {
return i.__proto__;
};
function n(i) {
if (i === null || typeof i != "object")
return i;
if (i instanceof Object)
var a = { __proto__: e(i) };
else
var a = /* @__PURE__ */ Object.create(null);
return Object.getOwnPropertyNames(i).forEach(function(c) {
Object.defineProperty(a, c, Object.getOwnPropertyDescriptor(i, c));
}), a;
}
function i(a) {
return a && function(l, y) {
try {
return a.call(e, l, y);
} catch (f) {
if (!p(f)) throw f;
}
};
return we;
}
const cr = new Proxy({}, {
get(e, n) {
throw new Error(`Module "util" has been externalized for browser compatibility. Cannot access "util.${n}" in client code. See https://vite.dev/guide/troubleshooting.html#module-externalized-for-browser-compatibility for more details.`);
}
function o(a) {
return a && function(l, y, f, d) {
return a.call(e, l, y, f, function(v) {
p(v) && (v = null), d && d.apply(this, arguments);
});
};
}), ur = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
__proto__: null,
default: cr
}, Symbol.toStringTag, { value: "Module" })), sr = /* @__PURE__ */ Q(ur), fr = new Proxy({}, {
get(e, n) {
throw new Error(`Module "assert" has been externalized for browser compatibility. Cannot access "assert.${n}" in client code. See https://vite.dev/guide/troubleshooting.html#module-externalized-for-browser-compatibility for more details.`);
}
function c(a) {
return a && function(l, y, f) {
try {
return a.call(e, l, y, f);
} catch (d) {
if (!p(d)) throw d;
}), lr = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
__proto__: null,
default: fr
}, Symbol.toStringTag, { value: "Module" })), yr = /* @__PURE__ */ Q(lr);
var ce, tt;
function oe() {
if (tt) return ce;
tt = 1;
var e = Lt, n = tr(), i = or(), a = ar(), c = sr, u, r;
typeof Symbol == "function" && typeof Symbol.for == "function" ? (u = Symbol.for("graceful-fs.queue"), r = Symbol.for("graceful-fs.previous")) : (u = "___graceful-fs.queue", r = "___graceful-fs.previous");
function w() {
}
function y(t, o) {
Object.defineProperty(t, u, {
get: function() {
return o;
}
};
});
}
function s(a) {
return a && function(l, y, f) {
typeof y == "function" && (f = y, y = null);
function d(v, _) {
_ && (_.uid < 0 && (_.uid += 4294967296), _.gid < 0 && (_.gid += 4294967296)), f && f.apply(this, arguments);
var m = w;
if (c.debuglog ? m = c.debuglog("gfs4") : /\bgfs4\b/i.test(process.env.NODE_DEBUG || "") && (m = function() {
var t = c.format.apply(c, arguments);
t = "GFS4: " + t.split(/\n/).join(`
GFS4: `), console.error(t);
}), !e[u]) {
var E = ie[u] || [];
y(e, E), e.close = function(t) {
function o(l, h) {
return t.call(e, l, function(g) {
g || _(), typeof h == "function" && h.apply(this, arguments);
});
}
return y ? a.call(e, l, y, d) : a.call(e, l, d);
};
return Object.defineProperty(o, r, {
value: t
}), o;
}(e.close), e.closeSync = function(t) {
function o(l) {
t.apply(e, arguments), _();
}
return Object.defineProperty(o, r, {
value: t
}), o;
}(e.closeSync), /\bgfs4\b/i.test(process.env.NODE_DEBUG || "") && process.on("exit", function() {
m(e[u]), yr.equal(e[u].length, 0);
});
}
function u(a) {
return a && function(l, y) {
var f = y ? a.call(e, l, y) : a.call(e, l);
return f && (f.uid < 0 && (f.uid += 4294967296), f.gid < 0 && (f.gid += 4294967296)), f;
};
}
function p(a) {
if (!a || a.code === "ENOSYS")
return !0;
var l = !process.getuid || process.getuid() !== 0;
return !!(l && (a.code === "EINVAL" || a.code === "EPERM"));
}
}
const ur = new Proxy({}, {
get(e, t) {
throw new Error(`Module "stream" has been externalized for browser compatibility. Cannot access "stream.${t}" in client code. See https://vite.dev/guide/troubleshooting.html#module-externalized-for-browser-compatibility for more details.`);
}
}), fr = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
__proto__: null,
default: ur
}, Symbol.toStringTag, { value: "Module" })), lr = /* @__PURE__ */ K(fr);
var qe = lr.Stream, yr = mr;
function mr(e) {
return {
ReadStream: t,
WriteStream: r
};
function t(n, i) {
if (!(this instanceof t)) return new t(n, i);
qe.call(this);
var o = this;
this.path = n, this.fd = null, this.readable = !0, this.paused = !1, this.flags = "r", this.mode = 438, this.bufferSize = 64 * 1024, i = i || {};
for (var c = Object.keys(i), s = 0, u = c.length; s < u; s++) {
var p = c[s];
this[p] = i[p];
ie[u] || y(ie, e[u]), ce = v(a(e)), process.env.TEST_GRACEFUL_FS_GLOBAL_PATCH && !e.__patched && (ce = v(e), e.__patched = !0);
function v(t) {
n(t), t.gracefulify = v, t.createReadStream = It, t.createWriteStream = Bt;
var o = t.readFile;
t.readFile = l;
function l(F, R, D) {
return typeof R == "function" && (D = R, R = null), A(F, R, D);
function A(I, j, T, M) {
return o(I, j, function(q) {
q && (q.code === "EMFILE" || q.code === "ENFILE") ? s([A, [I, j, T], q, M || Date.now(), Date.now()]) : typeof T == "function" && T.apply(this, arguments);
});
}
}
if (this.encoding && this.setEncoding(this.encoding), this.start !== void 0) {
if (typeof this.start != "number")
throw TypeError("start must be a Number");
if (this.end === void 0)
this.end = 1 / 0;
else if (typeof this.end != "number")
throw TypeError("end must be a Number");
if (this.start > this.end)
throw new Error("start must be <= end");
this.pos = this.start;
var h = t.writeFile;
t.writeFile = g;
function g(F, R, D, A) {
return typeof D == "function" && (A = D, D = null), I(F, R, D, A);
function I(j, T, M, q, B) {
return h(j, T, M, function(N) {
N && (N.code === "EMFILE" || N.code === "ENFILE") ? s([I, [j, T, M, q], N, B || Date.now(), Date.now()]) : typeof q == "function" && q.apply(this, arguments);
});
}
}
if (this.fd !== null) {
process.nextTick(function() {
o._read();
});
return;
var p = t.appendFile;
p && (t.appendFile = b);
function b(F, R, D, A) {
return typeof D == "function" && (A = D, D = null), I(F, R, D, A);
function I(j, T, M, q, B) {
return p(j, T, M, function(N) {
N && (N.code === "EMFILE" || N.code === "ENFILE") ? s([I, [j, T, M, q], N, B || Date.now(), Date.now()]) : typeof q == "function" && q.apply(this, arguments);
});
}
}
e.open(this.path, this.flags, this.mode, function(a, l) {
if (a) {
o.emit("error", a), o.readable = !1;
return;
var S = t.copyFile;
S && (t.copyFile = k);
function k(F, R, D, A) {
return typeof D == "function" && (A = D, D = 0), I(F, R, D, A);
function I(j, T, M, q, B) {
return S(j, T, M, function(N) {
N && (N.code === "EMFILE" || N.code === "ENFILE") ? s([I, [j, T, M, q], N, B || Date.now(), Date.now()]) : typeof q == "function" && q.apply(this, arguments);
});
}
o.fd = l, o.emit("open", l), o._read();
});
}
function r(n, i) {
if (!(this instanceof r)) return new r(n, i);
qe.call(this), this.path = n, this.fd = null, this.writable = !0, this.flags = "w", this.encoding = "binary", this.mode = 438, this.bytesWritten = 0, i = i || {};
for (var o = Object.keys(i), c = 0, s = o.length; c < s; c++) {
var u = o[c];
this[u] = i[u];
}
if (this.start !== void 0) {
if (typeof this.start != "number")
throw TypeError("start must be a Number");
if (this.start < 0)
throw new Error("start must be >= zero");
this.pos = this.start;
var P = t.readdir;
t.readdir = V;
var x = /^v[0-5]\./;
function V(F, R, D) {
typeof R == "function" && (D = R, R = null);
var A = x.test(process.version) ? function(T, M, q, B) {
return P(T, I(
T,
M,
q,
B
));
} : function(T, M, q, B) {
return P(T, M, I(
T,
M,
q,
B
));
};
return A(F, R, D);
function I(j, T, M, q) {
return function(B, N) {
B && (B.code === "EMFILE" || B.code === "ENFILE") ? s([
A,
[j, T, M],
B,
q || Date.now(),
Date.now()
]) : (N && N.sort && N.sort(), typeof M == "function" && M.call(this, B, N));
};
}
}
this.busy = !1, this._queue = [], this.fd === null && (this._open = e.open, this._queue.push([this._open, this.path, this.flags, this.mode, void 0]), this.flush());
}
}
var dr = wr, hr = Object.getPrototypeOf || function(e) {
return e.__proto__;
};
function wr(e) {
if (e === null || typeof e != "object")
return e;
if (e instanceof Object)
var t = { __proto__: hr(e) };
else
var t = /* @__PURE__ */ Object.create(null);
return Object.getOwnPropertyNames(e).forEach(function(r) {
Object.defineProperty(t, r, Object.getOwnPropertyDescriptor(e, r));
}), t;
}
const pr = new Proxy({}, {
get(e, t) {
throw new Error(`Module "util" has been externalized for browser compatibility. Cannot access "util.${t}" in client code. See https://vite.dev/guide/troubleshooting.html#module-externalized-for-browser-compatibility for more details.`);
}
}), Sr = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
__proto__: null,
default: pr
}, Symbol.toStringTag, { value: "Module" })), vr = /* @__PURE__ */ K(Sr), _r = new Proxy({}, {
get(e, t) {
throw new Error(`Module "assert" has been externalized for browser compatibility. Cannot access "assert.${t}" in client code. See https://vite.dev/guide/troubleshooting.html#module-externalized-for-browser-compatibility for more details.`);
}
}), gr = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
__proto__: null,
default: _r
}, Symbol.toStringTag, { value: "Module" })), br = /* @__PURE__ */ K(gr);
var P = ft, Er = ar, $r = yr, kr = dr, he = vr, R, ve;
typeof Symbol == "function" && typeof Symbol.for == "function" ? (R = Symbol.for("graceful-fs.queue"), ve = Symbol.for("graceful-fs.previous")) : (R = "___graceful-fs.queue", ve = "___graceful-fs.previous");
function Fr() {
}
function lt(e, t) {
Object.defineProperty(e, R, {
get: function() {
return t;
if (process.version.substr(0, 4) === "v0.8") {
var G = i(t);
J = G.ReadStream, K = G.WriteStream;
}
});
}
var H = Fr;
he.debuglog ? H = he.debuglog("gfs4") : /\bgfs4\b/i.test(process.env.NODE_DEBUG || "") && (H = function() {
var e = he.format.apply(he, arguments);
e = "GFS4: " + e.split(/\n/).join(`
GFS4: `), console.error(e);
});
if (!P[R]) {
var Pr = ue[R] || [];
lt(P, Pr), P.close = function(e) {
function t(r, n) {
return e.call(P, r, function(i) {
i || Ye(), typeof n == "function" && n.apply(this, arguments);
var X = t.ReadStream;
X && (J.prototype = Object.create(X.prototype), J.prototype.open = ne);
var L = t.WriteStream;
L && (K.prototype = Object.create(L.prototype), K.prototype.open = At), Object.defineProperty(t, "ReadStream", {
get: function() {
return J;
},
set: function(F) {
J = F;
},
enumerable: !0,
configurable: !0
}), Object.defineProperty(t, "WriteStream", {
get: function() {
return K;
},
set: function(F) {
K = F;
},
enumerable: !0,
configurable: !0
});
var O = J;
Object.defineProperty(t, "FileReadStream", {
get: function() {
return O;
},
set: function(F) {
O = F;
},
enumerable: !0,
configurable: !0
});
var C = K;
Object.defineProperty(t, "FileWriteStream", {
get: function() {
return C;
},
set: function(F) {
C = F;
},
enumerable: !0,
configurable: !0
});
function J(F, R) {
return this instanceof J ? (X.apply(this, arguments), this) : J.apply(Object.create(J.prototype), arguments);
}
function ne() {
var F = this;
ye(F.path, F.flags, F.mode, function(R, D) {
R ? (F.autoClose && F.destroy(), F.emit("error", R)) : (F.fd = D, F.emit("open", D), F.read());
});
}
return Object.defineProperty(t, ve, {
value: e
}), t;
}(P.close), P.closeSync = function(e) {
function t(r) {
e.apply(P, arguments), Ye();
function K(F, R) {
return this instanceof K ? (L.apply(this, arguments), this) : K.apply(Object.create(K.prototype), arguments);
}
return Object.defineProperty(t, ve, {
value: e
}), t;
}(P.closeSync), /\bgfs4\b/i.test(process.env.NODE_DEBUG || "") && process.on("exit", function() {
H(P[R]), br.equal(P[R].length, 0);
});
}
ue[R] || lt(ue, P[R]);
var ce = Te(kr(P));
process.env.TEST_GRACEFUL_FS_GLOBAL_PATCH && !P.__patched && (ce = Te(P), P.__patched = !0);
function Te(e) {
Er(e), e.gracefulify = Te, e.createReadStream = Z, e.createWriteStream = We;
var t = e.readFile;
e.readFile = r;
function r(h, b, g) {
return typeof b == "function" && (g = b, b = null), N(h, b, g);
function N(T, D, F, O) {
return t(T, D, function($) {
$ && ($.code === "EMFILE" || $.code === "ENFILE") ? ee([N, [T, D, F], $, O || Date.now(), Date.now()]) : typeof F == "function" && F.apply(this, arguments);
function At() {
var F = this;
ye(F.path, F.flags, F.mode, function(R, D) {
R ? (F.destroy(), F.emit("error", R)) : (F.fd = D, F.emit("open", D));
});
}
}
var n = e.writeFile;
e.writeFile = i;
function i(h, b, g, N) {
return typeof g == "function" && (N = g, g = null), T(h, b, g, N);
function T(D, F, O, $, L) {
return n(D, F, O, function(k) {
k && (k.code === "EMFILE" || k.code === "ENFILE") ? ee([T, [D, F, O, $], k, L || Date.now(), Date.now()]) : typeof $ == "function" && $.apply(this, arguments);
});
function It(F, R) {
return new t.ReadStream(F, R);
}
}
var o = e.appendFile;
o && (e.appendFile = c);
function c(h, b, g, N) {
return typeof g == "function" && (N = g, g = null), T(h, b, g, N);
function T(D, F, O, $, L) {
return o(D, F, O, function(k) {
k && (k.code === "EMFILE" || k.code === "ENFILE") ? ee([T, [D, F, O, $], k, L || Date.now(), Date.now()]) : typeof $ == "function" && $.apply(this, arguments);
});
function Bt(F, R) {
return new t.WriteStream(F, R);
}
}
var s = e.copyFile;
s && (e.copyFile = u);
function u(h, b, g, N) {
return typeof g == "function" && (N = g, g = 0), T(h, b, g, N);
function T(D, F, O, $, L) {
return s(D, F, O, function(k) {
k && (k.code === "EMFILE" || k.code === "ENFILE") ? ee([T, [D, F, O, $], k, L || Date.now(), Date.now()]) : typeof $ == "function" && $.apply(this, arguments);
});
var Ut = t.open;
t.open = ye;
function ye(F, R, D, A) {
return typeof D == "function" && (A = D, D = null), I(F, R, D, A);
function I(j, T, M, q, B) {
return Ut(j, T, M, function(N, Vr) {
N && (N.code === "EMFILE" || N.code === "ENFILE") ? s([I, [j, T, M, q], N, B || Date.now(), Date.now()]) : typeof q == "function" && q.apply(this, arguments);
});
}
}
return t;
}
var p = e.readdir;
e.readdir = l;
var a = /^v[0-5]\./;
function l(h, b, g) {
typeof b == "function" && (g = b, b = null);
var N = a.test(process.version) ? function(F, O, $, L) {
return p(F, T(
F,
O,
$,
L
));
} : function(F, O, $, L) {
return p(F, O, T(
F,
O,
$,
L
));
};
return N(h, b, g);
function T(D, F, O, $) {
return function(L, k) {
L && (L.code === "EMFILE" || L.code === "ENFILE") ? ee([
N,
[D, F, O],
L,
$ || Date.now(),
Date.now()
]) : (k && k.sort && k.sort(), typeof O == "function" && O.call(this, L, k));
};
}
function s(t) {
m("ENQUEUE", t[0].name, t[1]), e[u].push(t), d();
}
if (process.version.substr(0, 4) === "v0.8") {
var y = $r(e);
w = y.ReadStream, S = y.WriteStream;
var f;
function _() {
for (var t = Date.now(), o = 0; o < e[u].length; ++o)
e[u][o].length > 2 && (e[u][o][3] = t, e[u][o][4] = t);
d();
}
var f = e.ReadStream;
f && (w.prototype = Object.create(f.prototype), w.prototype.open = m);
var d = e.WriteStream;
d && (S.prototype = Object.create(d.prototype), S.prototype.open = W), Object.defineProperty(e, "ReadStream", {
get: function() {
return w;
},
set: function(h) {
w = h;
},
enumerable: !0,
configurable: !0
}), Object.defineProperty(e, "WriteStream", {
get: function() {
return S;
},
set: function(h) {
S = h;
},
enumerable: !0,
configurable: !0
});
var v = w;
Object.defineProperty(e, "FileReadStream", {
get: function() {
return v;
},
set: function(h) {
v = h;
},
enumerable: !0,
configurable: !0
});
var _ = S;
Object.defineProperty(e, "FileWriteStream", {
get: function() {
return _;
},
set: function(h) {
_ = h;
},
enumerable: !0,
configurable: !0
});
function w(h, b) {
return this instanceof w ? (f.apply(this, arguments), this) : w.apply(Object.create(w.prototype), arguments);
}
function m() {
var h = this;
$e(h.path, h.flags, h.mode, function(b, g) {
b ? (h.autoClose && h.destroy(), h.emit("error", b)) : (h.fd = g, h.emit("open", g), h.read());
});
}
function S(h, b) {
return this instanceof S ? (d.apply(this, arguments), this) : S.apply(Object.create(S.prototype), arguments);
}
function W() {
var h = this;
$e(h.path, h.flags, h.mode, function(b, g) {
b ? (h.destroy(), h.emit("error", b)) : (h.fd = g, h.emit("open", g));
});
}
function Z(h, b) {
return new e.ReadStream(h, b);
}
function We(h, b) {
return new e.WriteStream(h, b);
}
var qt = e.open;
e.open = $e;
function $e(h, b, g, N) {
return typeof g == "function" && (N = g, g = null), T(h, b, g, N);
function T(D, F, O, $, L) {
return qt(D, F, O, function(k, lo) {
k && (k.code === "EMFILE" || k.code === "ENFILE") ? ee([T, [D, F, O, $], k, L || Date.now(), Date.now()]) : typeof $ == "function" && $.apply(this, arguments);
});
function d() {
if (clearTimeout(f), f = void 0, e[u].length !== 0) {
var t = e[u].shift(), o = t[0], l = t[1], h = t[2], g = t[3], p = t[4];
if (g === void 0)
m("RETRY", o.name, l), o.apply(null, l);
else if (Date.now() - g >= 6e4) {
m("TIMEOUT", o.name, l);
var b = l.pop();
typeof b == "function" && b.call(null, h);
} else {
var S = Date.now() - p, k = Math.max(p - g, 1), P = Math.min(k * 1.2, 100);
S >= P ? (m("RETRY", o.name, l), o.apply(null, l.concat([g]))) : e[u].push(t);
}
f === void 0 && (f = setTimeout(d, 0));
}
}
return e;
return ce;
}
function ee(e) {
H("ENQUEUE", e[0].name, e[1]), P[R].push(e), Le();
}
var we;
function Ye() {
for (var e = Date.now(), t = 0; t < P[R].length; ++t)
P[R][t].length > 2 && (P[R][t][3] = e, P[R][t][4] = e);
Le();
}
function Le() {
if (clearTimeout(we), we = void 0, P[R].length !== 0) {
var e = P[R].shift(), t = e[0], r = e[1], n = e[2], i = e[3], o = e[4];
if (i === void 0)
H("RETRY", t.name, r), t.apply(null, r);
else if (Date.now() - i >= 6e4) {
H("TIMEOUT", t.name, r);
var c = r.pop();
typeof c == "function" && c.call(null, n);
} else {
var s = Date.now() - o, u = Math.max(o - i, 1), p = Math.min(u * 1.2, 100);
s >= p ? (H("RETRY", t.name, r), t.apply(null, r.concat([i]))) : P[R].push(e);
}
we === void 0 && (we = setTimeout(Le, 0));
}
}
(function(e) {
const t = x.fromCallback, r = ce, n = [
"access",
"appendFile",
"chmod",
"chown",
"close",
"copyFile",
"fchmod",
"fchown",
"fdatasync",
"fstat",
"fsync",
"ftruncate",
"futimes",
"lchmod",
"lchown",
"link",
"lstat",
"mkdir",
"mkdtemp",
"open",
"opendir",
"readdir",
"readFile",
"readlink",
"realpath",
"rename",
"rm",
"rmdir",
"stat",
"symlink",
"truncate",
"unlink",
"utimes",
"writeFile"
].filter((i) => typeof r[i] == "function");
Object.assign(e, r), n.forEach((i) => {
e[i] = t(r[i]);
}), e.exists = function(i, o) {
return typeof o == "function" ? r.exists(i, o) : new Promise((c) => r.exists(i, c));
}, e.read = function(i, o, c, s, u, p) {
return typeof p == "function" ? r.read(i, o, c, s, u, p) : new Promise((a, l) => {
r.read(i, o, c, s, u, (y, f, d) => {
if (y) return l(y);
a({ bytesRead: f, buffer: d });
var rt;
function W() {
return rt || (rt = 1, function(e) {
const n = U().fromCallback, i = oe(), a = [
"access",
"appendFile",
"chmod",
"chown",
"close",
"copyFile",
"fchmod",
"fchown",
"fdatasync",
"fstat",
"fsync",
"ftruncate",
"futimes",
"lchmod",
"lchown",
"link",
"lstat",
"mkdir",
"mkdtemp",
"open",
"opendir",
"readdir",
"readFile",
"readlink",
"realpath",
"rename",
"rm",
"rmdir",
"stat",
"symlink",
"truncate",
"unlink",
"utimes",
"writeFile"
].filter((c) => typeof i[c] == "function");
Object.assign(e, i), a.forEach((c) => {
e[c] = n(i[c]);
}), e.exists = function(c, u) {
return typeof u == "function" ? i.exists(c, u) : new Promise((r) => i.exists(c, r));
}, e.read = function(c, u, r, w, y, m) {
return typeof m == "function" ? i.read(c, u, r, w, y, m) : new Promise((E, v) => {
i.read(c, u, r, w, y, (s, f, _) => {
if (s) return v(s);
E({ bytesRead: f, buffer: _ });
});
});
});
}, e.write = function(i, o, ...c) {
return typeof c[c.length - 1] == "function" ? r.write(i, o, ...c) : new Promise((s, u) => {
r.write(i, o, ...c, (p, a, l) => {
if (p) return u(p);
s({ bytesWritten: a, buffer: l });
}, e.write = function(c, u, ...r) {
return typeof r[r.length - 1] == "function" ? i.write(c, u, ...r) : new Promise((w, y) => {
i.write(c, u, ...r, (m, E, v) => {
if (m) return y(m);
w({ bytesWritten: E, buffer: v });
});
});
});
}, e.readv = function(i, o, ...c) {
return typeof c[c.length - 1] == "function" ? r.readv(i, o, ...c) : new Promise((s, u) => {
r.readv(i, o, ...c, (p, a, l) => {
if (p) return u(p);
s({ bytesRead: a, buffers: l });
}, e.readv = function(c, u, ...r) {
return typeof r[r.length - 1] == "function" ? i.readv(c, u, ...r) : new Promise((w, y) => {
i.readv(c, u, ...r, (m, E, v) => {
if (m) return y(m);
w({ bytesRead: E, buffers: v });
});
});
});
}, e.writev = function(i, o, ...c) {
return typeof c[c.length - 1] == "function" ? r.writev(i, o, ...c) : new Promise((s, u) => {
r.writev(i, o, ...c, (p, a, l) => {
if (p) return u(p);
s({ bytesWritten: a, buffers: l });
}, e.writev = function(c, u, ...r) {
return typeof r[r.length - 1] == "function" ? i.writev(c, u, ...r) : new Promise((w, y) => {
i.writev(c, u, ...r, (m, E, v) => {
if (m) return y(m);
w({ bytesWritten: E, buffers: v });
});
});
});
}, typeof r.realpath.native == "function" ? e.realpath.native = t(r.realpath.native) : process.emitWarning(
"fs.realpath.native is not a function. Is fs being monkey-patched?",
"Warning",
"fs-extra-WARN0003"
);
})(I);
const Or = new Proxy({}, {
get(e, t) {
throw new Error(`Module "path" has been externalized for browser compatibility. Cannot access "path.${t}" in client code. See https://vite.dev/guide/troubleshooting.html#module-externalized-for-browser-compatibility for more details.`);
}, typeof i.realpath.native == "function" ? e.realpath.native = n(i.realpath.native) : process.emitWarning(
"fs.realpath.native is not a function. Is fs being monkey-patched?",
"Warning",
"fs-extra-WARN0003"
);
}(me)), me;
}
const mr = new Proxy({}, {
get(e, n) {
throw new Error(`Module "path" has been externalized for browser compatibility. Cannot access "path.${n}" in client code. See https://vite.dev/guide/troubleshooting.html#module-externalized-for-browser-compatibility for more details.`);
}
}), xr = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
}), dr = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
__proto__: null,
default: Or
}, Symbol.toStringTag, { value: "Module" })), U = /* @__PURE__ */ K(xr);
var Re = {}, yt = {};
const Dr = U;
yt.checkPath = function(t) {
if (process.platform === "win32" && /[<>:"|?*]/.test(t.replace(Dr.parse(t).root, ""))) {
const n = new Error(`Path contains invalid characters: ${t}`);
throw n.code = "EINVAL", n;
}
};
const mt = I, { checkPath: dt } = yt, ht = (e) => {
const t = { mode: 511 };
return typeof e == "number" ? e : B(B({}, t), e).mode;
};
Re.makeDir = (e, t) => E(void 0, null, function* () {
return dt(e), mt.mkdir(e, {
mode: ht(t),
default: mr
}, Symbol.toStringTag, { value: "Module" })), Y = /* @__PURE__ */ Q(dr);
var ue = {}, pe = {}, nt;
function hr() {
if (nt) return pe;
nt = 1;
const e = Y;
return pe.checkPath = function(i) {
if (process.platform === "win32" && /[<>:"|?*]/.test(i.replace(e.parse(i).root, ""))) {
const c = new Error(`Path contains invalid characters: ${i}`);
throw c.code = "EINVAL", c;
}
}, pe;
}
var it;
function wr() {
if (it) return ue;
it = 1;
const e = /* @__PURE__ */ W(), { checkPath: n } = /* @__PURE__ */ hr(), i = (a) => {
const c = { mode: 511 };
return typeof a == "number" ? a : z(z({}, c), a).mode;
};
return ue.makeDir = (a, c) => $(this, null, function* () {
return n(a), e.mkdir(a, {
mode: i(c),
recursive: !0
});
}), ue.makeDirSync = (a, c) => (n(a), e.mkdirSync(a, {
mode: i(c),
recursive: !0
});
});
Re.makeDirSync = (e, t) => (dt(e), mt.mkdirSync(e, {
mode: ht(t),
recursive: !0
}));
const Cr = x.fromPromise, { makeDir: Nr, makeDirSync: ke } = Re, Fe = Cr(Nr);
var G = {
mkdirs: Fe,
mkdirsSync: ke,
// alias
mkdirp: Fe,
mkdirpSync: ke,
ensureDir: Fe,
ensureDirSync: ke
};
const Tr = x.fromPromise, wt = I;
function Lr(e) {
return wt.access(e).then(() => !0).catch(() => !1);
})), ue;
}
var Q = {
pathExists: Tr(Lr),
pathExistsSync: wt.existsSync
};
const re = I, Rr = x.fromPromise;
function jr(e, t, r) {
return E(this, null, function* () {
const n = yield re.open(e, "r+");
let i = null;
try {
yield re.futimes(n, t, r);
} finally {
var ve, ot;
function H() {
if (ot) return ve;
ot = 1;
const e = U().fromPromise, { makeDir: n, makeDirSync: i } = /* @__PURE__ */ wr(), a = e(n);
return ve = {
mkdirs: a,
mkdirsSync: i,
// alias
mkdirp: a,
mkdirpSync: i,
ensureDir: a,
ensureDirSync: i
}, ve;
}
var Se, at;
function Z() {
if (at) return Se;
at = 1;
const e = U().fromPromise, n = /* @__PURE__ */ W();
function i(a) {
return n.access(a).then(() => !0).catch(() => !1);
}
return Se = {
pathExists: e(i),
pathExistsSync: n.existsSync
}, Se;
}
var _e, ct;
function Mt() {
if (ct) return _e;
ct = 1;
const e = /* @__PURE__ */ W(), n = U().fromPromise;
function i(c, u, r) {
return $(this, null, function* () {
const w = yield e.open(c, "r+");
let y = null;
try {
yield re.close(n);
} catch (o) {
i = o;
yield e.futimes(w, u, r);
} finally {
try {
yield e.close(w);
} catch (m) {
y = m;
}
}
}
if (i)
throw i;
});
if (y)
throw y;
});
}
function a(c, u, r) {
const w = e.openSync(c, "r+");
return e.futimesSync(w, u, r), e.closeSync(w);
}
return _e = {
utimesMillis: n(i),
utimesMillisSync: a
}, _e;
}
function Ar(e, t, r) {
const n = re.openSync(e, "r+");
return re.futimesSync(n, t, r), re.closeSync(n);
}
var pt = {
utimesMillis: Rr(jr),
utimesMillisSync: Ar
};
const ne = I, C = U, Ve = x.fromPromise;
function Mr(e, t, r) {
const n = r.dereference ? (i) => ne.stat(i, { bigint: !0 }) : (i) => ne.lstat(i, { bigint: !0 });
return Promise.all([
n(e),
n(t).catch((i) => {
if (i.code === "ENOENT") return null;
throw i;
})
]).then(([i, o]) => ({ srcStat: i, destStat: o }));
}
function Ir(e, t, r) {
let n;
const i = r.dereference ? (c) => ne.statSync(c, { bigint: !0 }) : (c) => ne.lstatSync(c, { bigint: !0 }), o = i(e);
try {
n = i(t);
} catch (c) {
if (c.code === "ENOENT") return { srcStat: o, destStat: null };
throw c;
var ge, ut;
function re() {
if (ut) return ge;
ut = 1;
const e = /* @__PURE__ */ W(), n = Y, i = U().fromPromise;
function a(s, f, _) {
const d = _.dereference ? (t) => e.stat(t, { bigint: !0 }) : (t) => e.lstat(t, { bigint: !0 });
return Promise.all([
d(s),
d(f).catch((t) => {
if (t.code === "ENOENT") return null;
throw t;
})
]).then(([t, o]) => ({ srcStat: t, destStat: o }));
}
return { srcStat: o, destStat: n };
}
function Br(e, t, r, n) {
return E(this, null, function* () {
const { srcStat: i, destStat: o } = yield Mr(e, t, n);
function c(s, f, _) {
let d;
const t = _.dereference ? (l) => e.statSync(l, { bigint: !0 }) : (l) => e.lstatSync(l, { bigint: !0 }), o = t(s);
try {
d = t(f);
} catch (l) {
if (l.code === "ENOENT") return { srcStat: o, destStat: null };
throw l;
}
return { srcStat: o, destStat: d };
}
function u(s, f, _, d) {
return $(this, null, function* () {
const { srcStat: t, destStat: o } = yield a(s, f, d);
if (o) {
if (m(t, o)) {
const l = n.basename(s), h = n.basename(f);
if (_ === "move" && l !== h && l.toLowerCase() === h.toLowerCase())
return { srcStat: t, destStat: o, isChangingCase: !0 };
throw new Error("Source and destination must not be the same.");
}
if (t.isDirectory() && !o.isDirectory())
throw new Error(`Cannot overwrite non-directory '${f}' with directory '${s}'.`);
if (!t.isDirectory() && o.isDirectory())
throw new Error(`Cannot overwrite directory '${f}' with non-directory '${s}'.`);
}
if (t.isDirectory() && E(s, f))
throw new Error(v(s, f, _));
return { srcStat: t, destStat: o };
});
}
function r(s, f, _, d) {
const { srcStat: t, destStat: o } = c(s, f, d);
if (o) {
if (de(i, o)) {
const c = C.basename(e), s = C.basename(t);
if (r === "move" && c !== s && c.toLowerCase() === s.toLowerCase())
return { srcStat: i, destStat: o, isChangingCase: !0 };
if (m(t, o)) {
const l = n.basename(s), h = n.basename(f);
if (_ === "move" && l !== h && l.toLowerCase() === h.toLowerCase())
return { srcStat: t, destStat: o, isChangingCase: !0 };
throw new Error("Source and destination must not be the same.");
}
if (i.isDirectory() && !o.isDirectory())
throw new Error(`Cannot overwrite non-directory '${t}' with directory '${e}'.`);
if (!i.isDirectory() && o.isDirectory())
throw new Error(`Cannot overwrite directory '${t}' with non-directory '${e}'.`);
if (t.isDirectory() && !o.isDirectory())
throw new Error(`Cannot overwrite non-directory '${f}' with directory '${s}'.`);
if (!t.isDirectory() && o.isDirectory())
throw new Error(`Cannot overwrite directory '${f}' with non-directory '${s}'.`);
}
if (i.isDirectory() && je(e, t))
throw new Error(ge(e, t, r));
return { srcStat: i, destStat: o };
});
}
function Ur(e, t, r, n) {
const { srcStat: i, destStat: o } = Ir(e, t, n);
if (o) {
if (de(i, o)) {
const c = C.basename(e), s = C.basename(t);
if (r === "move" && c !== s && c.toLowerCase() === s.toLowerCase())
return { srcStat: i, destStat: o, isChangingCase: !0 };
throw new Error("Source and destination must not be the same.");
}
if (i.isDirectory() && !o.isDirectory())
throw new Error(`Cannot overwrite non-directory '${t}' with directory '${e}'.`);
if (!i.isDirectory() && o.isDirectory())
throw new Error(`Cannot overwrite directory '${t}' with non-directory '${e}'.`);
if (t.isDirectory() && E(s, f))
throw new Error(v(s, f, _));
return { srcStat: t, destStat: o };
}
if (i.isDirectory() && je(e, t))
throw new Error(ge(e, t, r));
return { srcStat: i, destStat: o };
}
function St(e, t, r, n) {
return E(this, null, function* () {
const i = C.resolve(C.dirname(e)), o = C.resolve(C.dirname(r));
if (o === i || o === C.parse(o).root) return;
let c;
function w(s, f, _, d) {
return $(this, null, function* () {
const t = n.resolve(n.dirname(s)), o = n.resolve(n.dirname(_));
if (o === t || o === n.parse(o).root) return;
let l;
try {
l = yield e.stat(o, { bigint: !0 });
} catch (h) {
if (h.code === "ENOENT") return;
throw h;
}
if (m(f, l))
throw new Error(v(s, _, d));
return w(s, f, o, d);
});
}
function y(s, f, _, d) {
const t = n.resolve(n.dirname(s)), o = n.resolve(n.dirname(_));
if (o === t || o === n.parse(o).root) return;
let l;
try {
c = yield ne.stat(o, { bigint: !0 });
} catch (s) {
if (s.code === "ENOENT") return;
throw s;
l = e.statSync(o, { bigint: !0 });
} catch (h) {
if (h.code === "ENOENT") return;
throw h;
}
if (de(t, c))
throw new Error(ge(e, r, n));
return St(e, t, o, n);
});
if (m(f, l))
throw new Error(v(s, _, d));
return y(s, f, o, d);
}
function m(s, f) {
return f.ino && f.dev && f.ino === s.ino && f.dev === s.dev;
}
function E(s, f) {
const _ = n.resolve(s).split(n.sep).filter((t) => t), d = n.resolve(f).split(n.sep).filter((t) => t);
return _.every((t, o) => d[o] === t);
}
function v(s, f, _) {
return `Cannot ${_} '${s}' to a subdirectory of itself, '${f}'.`;
}
return ge = {
// checkPaths
checkPaths: i(u),
checkPathsSync: r,
// checkParent
checkParentPaths: i(w),
checkParentPathsSync: y,
// Misc
isSrcSubdir: E,
areIdentical: m
}, ge;
}
function vt(e, t, r, n) {
const i = C.resolve(C.dirname(e)), o = C.resolve(C.dirname(r));
if (o === i || o === C.parse(o).root) return;
let c;
try {
c = ne.statSync(o, { bigint: !0 });
} catch (s) {
if (s.code === "ENOENT") return;
throw s;
var be, st;
function pr() {
if (st) return be;
st = 1;
const e = /* @__PURE__ */ W(), n = Y, { mkdirs: i } = /* @__PURE__ */ H(), { pathExists: a } = /* @__PURE__ */ Z(), { utimesMillis: c } = /* @__PURE__ */ Mt(), u = /* @__PURE__ */ re();
function r(l, h) {
return $(this, arguments, function* (d, t, o = {}) {
typeof o == "function" && (o = { filter: o }), o.clobber = "clobber" in o ? !!o.clobber : !0, o.overwrite = "overwrite" in o ? !!o.overwrite : o.clobber, o.preserveTimestamps && process.arch === "ia32" && process.emitWarning(
`Using the preserveTimestamps option in 32-bit node is not recommended;
see https://github.com/jprichardson/node-fs-extra/issues/269`,
"Warning",
"fs-extra-WARN0001"
);
const { srcStat: g, destStat: p } = yield u.checkPaths(d, t, "copy", o);
if (yield u.checkParentPaths(d, g, t, "copy"), !(yield w(d, t, o))) return;
const S = n.dirname(t);
(yield a(S)) || (yield i(S)), yield y(p, d, t, o);
});
}
if (de(t, c))
throw new Error(ge(e, r, n));
return vt(e, t, o, n);
function w(d, t, o) {
return $(this, null, function* () {
return o.filter ? o.filter(d, t) : !0;
});
}
function y(d, t, o, l) {
return $(this, null, function* () {
const g = yield (l.dereference ? e.stat : e.lstat)(t);
if (g.isDirectory()) return f(g, d, t, o, l);
if (g.isFile() || g.isCharacterDevice() || g.isBlockDevice()) return m(g, d, t, o, l);
if (g.isSymbolicLink()) return _(d, t, o, l);
throw g.isSocket() ? new Error(`Cannot copy a socket file: ${t}`) : g.isFIFO() ? new Error(`Cannot copy a FIFO pipe: ${t}`) : new Error(`Unknown file: ${t}`);
});
}
function m(d, t, o, l, h) {
return $(this, null, function* () {
if (!t) return E(d, o, l, h);
if (h.overwrite)
return yield e.unlink(l), E(d, o, l, h);
if (h.errorOnExist)
throw new Error(`'${l}' already exists`);
});
}
function E(d, t, o, l) {
return $(this, null, function* () {
if (yield e.copyFile(t, o), l.preserveTimestamps) {
v(d.mode) && (yield s(o, d.mode));
const h = yield e.stat(t);
yield c(o, h.atime, h.mtime);
}
return e.chmod(o, d.mode);
});
}
function v(d) {
return (d & 128) === 0;
}
function s(d, t) {
return e.chmod(d, t | 128);
}
function f(d, t, o, l, h) {
return $(this, null, function* () {
t || (yield e.mkdir(l));
const g = yield e.readdir(o);
yield Promise.all(g.map((p) => $(this, null, function* () {
const b = n.join(o, p), S = n.join(l, p);
if (!(yield w(b, S, h))) return;
const { destStat: P } = yield u.checkPaths(b, S, "copy", h);
return y(P, b, S, h);
}))), t || (yield e.chmod(l, d.mode));
});
}
function _(d, t, o, l) {
return $(this, null, function* () {
let h = yield e.readlink(t);
if (l.dereference && (h = n.resolve(process.cwd(), h)), !d)
return e.symlink(h, o);
let g = null;
try {
g = yield e.readlink(o);
} catch (p) {
if (p.code === "EINVAL" || p.code === "UNKNOWN") return e.symlink(h, o);
throw p;
}
if (l.dereference && (g = n.resolve(process.cwd(), g)), u.isSrcSubdir(h, g))
throw new Error(`Cannot copy '${h}' to a subdirectory of itself, '${g}'.`);
if (u.isSrcSubdir(g, h))
throw new Error(`Cannot overwrite '${g}' with '${h}'.`);
return yield e.unlink(o), e.symlink(h, o);
});
}
return be = r, be;
}
function de(e, t) {
return t.ino && t.dev && t.ino === e.ino && t.dev === e.dev;
}
function je(e, t) {
const r = C.resolve(e).split(C.sep).filter((i) => i), n = C.resolve(t).split(C.sep).filter((i) => i);
return r.every((i, o) => n[o] === i);
}
function ge(e, t, r) {
return `Cannot ${r} '${e}' to a subdirectory of itself, '${t}'.`;
}
var ae = {
// checkPaths
checkPaths: Ve(Br),
checkPathsSync: Ur,
// checkParent
checkParentPaths: Ve(St),
checkParentPathsSync: vt,
// Misc
isSrcSubdir: je,
areIdentical: de
};
const j = I, fe = U, { mkdirs: Wr } = G, { pathExists: Jr } = Q, { utimesMillis: zr } = pt, le = ae;
function Gr(n, i) {
return E(this, arguments, function* (e, t, r = {}) {
typeof r == "function" && (r = { filter: r }), r.clobber = "clobber" in r ? !!r.clobber : !0, r.overwrite = "overwrite" in r ? !!r.overwrite : r.clobber, r.preserveTimestamps && process.arch === "ia32" && process.emitWarning(
var Ee, ft;
function vr() {
if (ft) return Ee;
ft = 1;
const e = oe(), n = Y, i = H().mkdirsSync, a = Mt().utimesMillisSync, c = /* @__PURE__ */ re();
function u(p, b, S) {
typeof S == "function" && (S = { filter: S }), S = S || {}, S.clobber = "clobber" in S ? !!S.clobber : !0, S.overwrite = "overwrite" in S ? !!S.overwrite : S.clobber, S.preserveTimestamps && process.arch === "ia32" && process.emitWarning(
`Using the preserveTimestamps option in 32-bit node is not recommended;

@@ -882,816 +1031,837 @@

"Warning",
"fs-extra-WARN0001"
"fs-extra-WARN0002"
);
const { srcStat: o, destStat: c } = yield le.checkPaths(e, t, "copy", r);
if (yield le.checkParentPaths(e, o, t, "copy"), !(yield _t(e, t, r))) return;
const u = fe.dirname(t);
(yield Jr(u)) || (yield Wr(u)), yield gt(c, e, t, r);
});
const { srcStat: k, destStat: P } = c.checkPathsSync(p, b, "copy", S);
if (c.checkParentPathsSync(p, k, b, "copy"), S.filter && !S.filter(p, b)) return;
const x = n.dirname(b);
return e.existsSync(x) || i(x), r(P, p, b, S);
}
function r(p, b, S, k) {
const x = (k.dereference ? e.statSync : e.lstatSync)(b);
if (x.isDirectory()) return d(x, p, b, S, k);
if (x.isFile() || x.isCharacterDevice() || x.isBlockDevice()) return w(x, p, b, S, k);
if (x.isSymbolicLink()) return h(p, b, S, k);
throw x.isSocket() ? new Error(`Cannot copy a socket file: ${b}`) : x.isFIFO() ? new Error(`Cannot copy a FIFO pipe: ${b}`) : new Error(`Unknown file: ${b}`);
}
function w(p, b, S, k, P) {
return b ? y(p, S, k, P) : m(p, S, k, P);
}
function y(p, b, S, k) {
if (k.overwrite)
return e.unlinkSync(S), m(p, b, S, k);
if (k.errorOnExist)
throw new Error(`'${S}' already exists`);
}
function m(p, b, S, k) {
return e.copyFileSync(b, S), k.preserveTimestamps && E(p.mode, b, S), f(S, p.mode);
}
function E(p, b, S) {
return v(p) && s(S, p), _(b, S);
}
function v(p) {
return (p & 128) === 0;
}
function s(p, b) {
return f(p, b | 128);
}
function f(p, b) {
return e.chmodSync(p, b);
}
function _(p, b) {
const S = e.statSync(p);
return a(b, S.atime, S.mtime);
}
function d(p, b, S, k, P) {
return b ? o(S, k, P) : t(p.mode, S, k, P);
}
function t(p, b, S, k) {
return e.mkdirSync(S), o(b, S, k), f(S, p);
}
function o(p, b, S) {
e.readdirSync(p).forEach((k) => l(k, p, b, S));
}
function l(p, b, S, k) {
const P = n.join(b, p), x = n.join(S, p);
if (k.filter && !k.filter(P, x)) return;
const { destStat: V } = c.checkPathsSync(P, x, "copy", k);
return r(V, P, x, k);
}
function h(p, b, S, k) {
let P = e.readlinkSync(b);
if (k.dereference && (P = n.resolve(process.cwd(), P)), p) {
let x;
try {
x = e.readlinkSync(S);
} catch (V) {
if (V.code === "EINVAL" || V.code === "UNKNOWN") return e.symlinkSync(P, S);
throw V;
}
if (k.dereference && (x = n.resolve(process.cwd(), x)), c.isSrcSubdir(P, x))
throw new Error(`Cannot copy '${P}' to a subdirectory of itself, '${x}'.`);
if (c.isSrcSubdir(x, P))
throw new Error(`Cannot overwrite '${x}' with '${P}'.`);
return g(P, S);
} else
return e.symlinkSync(P, S);
}
function g(p, b) {
return e.unlinkSync(b), e.symlinkSync(p, b);
}
return Ee = u, Ee;
}
function _t(e, t, r) {
return E(this, null, function* () {
return r.filter ? r.filter(e, t) : !0;
});
var ke, lt;
function ze() {
if (lt) return ke;
lt = 1;
const e = U().fromPromise;
return ke = {
copy: e(/* @__PURE__ */ pr()),
copySync: /* @__PURE__ */ vr()
}, ke;
}
function gt(e, t, r, n) {
return E(this, null, function* () {
const o = yield (n.dereference ? j.stat : j.lstat)(t);
if (o.isDirectory()) return Xr(o, e, t, r, n);
if (o.isFile() || o.isCharacterDevice() || o.isBlockDevice()) return qr(o, e, t, r, n);
if (o.isSymbolicLink()) return Hr(e, t, r, n);
throw o.isSocket() ? new Error(`Cannot copy a socket file: ${t}`) : o.isFIFO() ? new Error(`Cannot copy a FIFO pipe: ${t}`) : new Error(`Unknown file: ${t}`);
});
var Fe, yt;
function le() {
if (yt) return Fe;
yt = 1;
const e = oe(), n = U().fromCallback;
function i(c, u) {
e.rm(c, { recursive: !0, force: !0 }, u);
}
function a(c) {
e.rmSync(c, { recursive: !0, force: !0 });
}
return Fe = {
remove: n(i),
removeSync: a
}, Fe;
}
function qr(e, t, r, n, i) {
return E(this, null, function* () {
if (!t) return Xe(e, r, n, i);
if (i.overwrite)
return yield j.unlink(n), Xe(e, r, n, i);
if (i.errorOnExist)
throw new Error(`'${n}' already exists`);
var Pe, mt;
function Sr() {
if (mt) return Pe;
mt = 1;
const e = U().fromPromise, n = /* @__PURE__ */ W(), i = Y, a = /* @__PURE__ */ H(), c = /* @__PURE__ */ le(), u = e(function(y) {
return $(this, null, function* () {
let m;
try {
m = yield n.readdir(y);
} catch (E) {
return a.mkdirs(y);
}
return Promise.all(m.map((E) => c.remove(i.join(y, E))));
});
});
}
function Xe(e, t, r, n) {
return E(this, null, function* () {
if (yield j.copyFile(t, r), n.preserveTimestamps) {
Yr(e.mode) && (yield Vr(r, e.mode));
const i = yield j.stat(t);
yield zr(r, i.atime, i.mtime);
}
return j.chmod(r, e.mode);
});
}
function Yr(e) {
return (e & 128) === 0;
}
function Vr(e, t) {
return j.chmod(e, t | 128);
}
function Xr(e, t, r, n, i) {
return E(this, null, function* () {
t || (yield j.mkdir(n));
const o = yield j.readdir(r);
yield Promise.all(o.map((c) => E(this, null, function* () {
const s = fe.join(r, c), u = fe.join(n, c);
if (!(yield _t(s, u, i))) return;
const { destStat: a } = yield le.checkPaths(s, u, "copy", i);
return gt(a, s, u, i);
}))), t || (yield j.chmod(n, e.mode));
});
}
function Hr(e, t, r, n) {
return E(this, null, function* () {
let i = yield j.readlink(t);
if (n.dereference && (i = fe.resolve(process.cwd(), i)), !e)
return j.symlink(i, r);
let o = null;
function r(w) {
let y;
try {
o = yield j.readlink(r);
} catch (c) {
if (c.code === "EINVAL" || c.code === "UNKNOWN") return j.symlink(i, r);
throw c;
y = n.readdirSync(w);
} catch (m) {
return a.mkdirsSync(w);
}
if (n.dereference && (o = fe.resolve(process.cwd(), o)), le.isSrcSubdir(i, o))
throw new Error(`Cannot copy '${i}' to a subdirectory of itself, '${o}'.`);
if (le.isSrcSubdir(o, i))
throw new Error(`Cannot overwrite '${o}' with '${i}'.`);
return yield j.unlink(r), j.symlink(i, r);
});
y.forEach((m) => {
m = i.join(w, m), c.removeSync(m);
});
}
return Pe = {
emptyDirSync: r,
emptydirSync: r,
emptyDir: u,
emptydir: u
}, Pe;
}
var Kr = Gr;
const A = ce, ye = U, Qr = G.mkdirsSync, Zr = pt.utimesMillisSync, me = ae;
function en(e, t, r) {
typeof r == "function" && (r = { filter: r }), r = r || {}, r.clobber = "clobber" in r ? !!r.clobber : !0, r.overwrite = "overwrite" in r ? !!r.overwrite : r.clobber, r.preserveTimestamps && process.arch === "ia32" && process.emitWarning(
`Using the preserveTimestamps option in 32-bit node is not recommended;
see https://github.com/jprichardson/node-fs-extra/issues/269`,
"Warning",
"fs-extra-WARN0002"
);
const { srcStat: n, destStat: i } = me.checkPathsSync(e, t, "copy", r);
if (me.checkParentPathsSync(e, n, t, "copy"), r.filter && !r.filter(e, t)) return;
const o = ye.dirname(t);
return A.existsSync(o) || Qr(o), bt(i, e, t, r);
}
function bt(e, t, r, n) {
const o = (n.dereference ? A.statSync : A.lstatSync)(t);
if (o.isDirectory()) return sn(o, e, t, r, n);
if (o.isFile() || o.isCharacterDevice() || o.isBlockDevice()) return tn(o, e, t, r, n);
if (o.isSymbolicLink()) return ln(e, t, r, n);
throw o.isSocket() ? new Error(`Cannot copy a socket file: ${t}`) : o.isFIFO() ? new Error(`Cannot copy a FIFO pipe: ${t}`) : new Error(`Unknown file: ${t}`);
}
function tn(e, t, r, n, i) {
return t ? rn(e, r, n, i) : Et(e, r, n, i);
}
function rn(e, t, r, n) {
if (n.overwrite)
return A.unlinkSync(r), Et(e, t, r, n);
if (n.errorOnExist)
throw new Error(`'${r}' already exists`);
}
function Et(e, t, r, n) {
return A.copyFileSync(t, r), n.preserveTimestamps && nn(e.mode, t, r), Ae(r, e.mode);
}
function nn(e, t, r) {
return on(e) && cn(r, e), an(t, r);
}
function on(e) {
return (e & 128) === 0;
}
function cn(e, t) {
return Ae(e, t | 128);
}
function Ae(e, t) {
return A.chmodSync(e, t);
}
function an(e, t) {
const r = A.statSync(e);
return Zr(t, r.atime, r.mtime);
}
function sn(e, t, r, n, i) {
return t ? $t(r, n, i) : un(e.mode, r, n, i);
}
function un(e, t, r, n) {
return A.mkdirSync(r), $t(t, r, n), Ae(r, e);
}
function $t(e, t, r) {
A.readdirSync(e).forEach((n) => fn(n, e, t, r));
}
function fn(e, t, r, n) {
const i = ye.join(t, e), o = ye.join(r, e);
if (n.filter && !n.filter(i, o)) return;
const { destStat: c } = me.checkPathsSync(i, o, "copy", n);
return bt(c, i, o, n);
}
function ln(e, t, r, n) {
let i = A.readlinkSync(t);
if (n.dereference && (i = ye.resolve(process.cwd(), i)), e) {
let o;
var Oe, dt;
function _r() {
if (dt) return Oe;
dt = 1;
const e = U().fromPromise, n = Y, i = /* @__PURE__ */ W(), a = /* @__PURE__ */ H();
function c(r) {
return $(this, null, function* () {
let w;
try {
w = yield i.stat(r);
} catch (E) {
}
if (w && w.isFile()) return;
const y = n.dirname(r);
let m = null;
try {
m = yield i.stat(y);
} catch (E) {
if (E.code === "ENOENT") {
yield a.mkdirs(y), yield i.writeFile(r, "");
return;
} else
throw E;
}
m.isDirectory() ? yield i.writeFile(r, "") : yield i.readdir(y);
});
}
function u(r) {
let w;
try {
o = A.readlinkSync(r);
} catch (c) {
if (c.code === "EINVAL" || c.code === "UNKNOWN") return A.symlinkSync(i, r);
throw c;
w = i.statSync(r);
} catch (m) {
}
if (n.dereference && (o = ye.resolve(process.cwd(), o)), me.isSrcSubdir(i, o))
throw new Error(`Cannot copy '${i}' to a subdirectory of itself, '${o}'.`);
if (me.isSrcSubdir(o, i))
throw new Error(`Cannot overwrite '${o}' with '${i}'.`);
return yn(i, r);
} else
return A.symlinkSync(i, r);
}
function yn(e, t) {
return A.unlinkSync(t), A.symlinkSync(e, t);
}
var mn = en;
const dn = x.fromPromise;
var Me = {
copy: dn(Kr),
copySync: mn
};
const kt = ce, hn = x.fromCallback;
function wn(e, t) {
kt.rm(e, { recursive: !0, force: !0 }, t);
}
function pn(e) {
kt.rmSync(e, { recursive: !0, force: !0 });
}
var be = {
remove: hn(wn),
removeSync: pn
};
const Sn = x.fromPromise, Ft = I, Pt = U, Ot = G, xt = be, He = Sn(function(t) {
return E(this, null, function* () {
let r;
if (w && w.isFile()) return;
const y = n.dirname(r);
try {
r = yield Ft.readdir(t);
} catch (n) {
return Ot.mkdirs(t);
i.statSync(y).isDirectory() || i.readdirSync(y);
} catch (m) {
if (m && m.code === "ENOENT") a.mkdirsSync(y);
else throw m;
}
return Promise.all(r.map((n) => xt.remove(Pt.join(t, n))));
});
});
function Ke(e) {
let t;
try {
t = Ft.readdirSync(e);
} catch (r) {
return Ot.mkdirsSync(e);
i.writeFileSync(r, "");
}
t.forEach((r) => {
r = Pt.join(e, r), xt.removeSync(r);
});
return Oe = {
createFile: e(c),
createFileSync: u
}, Oe;
}
var vn = {
emptyDirSync: Ke,
emptydirSync: Ke,
emptyDir: He,
emptydir: He
};
const _n = x.fromPromise, Dt = U, q = I, Ct = G;
function gn(e) {
return E(this, null, function* () {
let t;
try {
t = yield q.stat(e);
} catch (i) {
}
if (t && t.isFile()) return;
const r = Dt.dirname(e);
let n = null;
try {
n = yield q.stat(r);
} catch (i) {
if (i.code === "ENOENT") {
yield Ct.mkdirs(r), yield q.writeFile(e, "");
return;
} else
throw i;
}
n.isDirectory() ? yield q.writeFile(e, "") : yield q.readdir(r);
});
}
function bn(e) {
let t;
try {
t = q.statSync(e);
} catch (n) {
var xe, ht;
function gr() {
if (ht) return xe;
ht = 1;
const e = U().fromPromise, n = Y, i = /* @__PURE__ */ W(), a = /* @__PURE__ */ H(), { pathExists: c } = /* @__PURE__ */ Z(), { areIdentical: u } = /* @__PURE__ */ re();
function r(y, m) {
return $(this, null, function* () {
let E;
try {
E = yield i.lstat(m);
} catch (_) {
}
let v;
try {
v = yield i.lstat(y);
} catch (_) {
throw _.message = _.message.replace("lstat", "ensureLink"), _;
}
if (E && u(v, E)) return;
const s = n.dirname(m);
(yield c(s)) || (yield a.mkdirs(s)), yield i.link(y, m);
});
}
if (t && t.isFile()) return;
const r = Dt.dirname(e);
try {
q.statSync(r).isDirectory() || q.readdirSync(r);
} catch (n) {
if (n && n.code === "ENOENT") Ct.mkdirsSync(r);
else throw n;
}
q.writeFileSync(e, "");
}
var En = {
createFile: _n(gn),
createFileSync: bn
};
const $n = x.fromPromise, Nt = U, V = I, Tt = G, { pathExists: kn } = Q, { areIdentical: Lt } = ae;
function Fn(e, t) {
return E(this, null, function* () {
let r;
function w(y, m) {
let E;
try {
r = yield V.lstat(t);
} catch (c) {
E = i.lstatSync(m);
} catch (f) {
}
let n;
try {
n = yield V.lstat(e);
} catch (c) {
throw c.message = c.message.replace("lstat", "ensureLink"), c;
const f = i.lstatSync(y);
if (E && u(f, E)) return;
} catch (f) {
throw f.message = f.message.replace("lstat", "ensureLink"), f;
}
if (r && Lt(n, r)) return;
const i = Nt.dirname(t);
(yield kn(i)) || (yield Tt.mkdirs(i)), yield V.link(e, t);
});
}
function Pn(e, t) {
let r;
try {
r = V.lstatSync(t);
} catch (o) {
const v = n.dirname(m);
return i.existsSync(v) || a.mkdirsSync(v), i.linkSync(y, m);
}
try {
const o = V.lstatSync(e);
if (r && Lt(o, r)) return;
} catch (o) {
throw o.message = o.message.replace("lstat", "ensureLink"), o;
}
const n = Nt.dirname(t);
return V.existsSync(n) || Tt.mkdirsSync(n), V.linkSync(e, t);
return xe = {
createLink: e(r),
createLinkSync: w
}, xe;
}
var On = {
createLink: $n(Fn),
createLinkSync: Pn
};
const X = U, se = I, { pathExists: xn } = Q, Dn = x.fromPromise;
function Cn(e, t) {
return E(this, null, function* () {
if (X.isAbsolute(e)) {
var De, wt;
function br() {
if (wt) return De;
wt = 1;
const e = Y, n = /* @__PURE__ */ W(), { pathExists: i } = /* @__PURE__ */ Z(), a = U().fromPromise;
function c(r, w) {
return $(this, null, function* () {
if (e.isAbsolute(r)) {
try {
yield n.lstat(r);
} catch (v) {
throw v.message = v.message.replace("lstat", "ensureSymlink"), v;
}
return {
toCwd: r,
toDst: r
};
}
const y = e.dirname(w), m = e.join(y, r);
if (yield i(m))
return {
toCwd: m,
toDst: r
};
try {
yield se.lstat(e);
} catch (o) {
throw o.message = o.message.replace("lstat", "ensureSymlink"), o;
yield n.lstat(r);
} catch (v) {
throw v.message = v.message.replace("lstat", "ensureSymlink"), v;
}
return {
toCwd: e,
toDst: e
toCwd: r,
toDst: e.relative(y, r)
};
});
}
function u(r, w) {
if (e.isAbsolute(r)) {
if (!n.existsSync(r)) throw new Error("absolute srcpath does not exist");
return {
toCwd: r,
toDst: r
};
}
const r = X.dirname(t), n = X.join(r, e);
if (yield xn(n))
const y = e.dirname(w), m = e.join(y, r);
if (n.existsSync(m))
return {
toCwd: n,
toDst: e
toCwd: m,
toDst: r
};
try {
yield se.lstat(e);
} catch (o) {
throw o.message = o.message.replace("lstat", "ensureSymlink"), o;
}
if (!n.existsSync(r)) throw new Error("relative srcpath does not exist");
return {
toCwd: e,
toDst: X.relative(r, e)
toCwd: r,
toDst: e.relative(y, r)
};
});
}
return De = {
symlinkPaths: a(c),
symlinkPathsSync: u
}, De;
}
function Nn(e, t) {
if (X.isAbsolute(e)) {
if (!se.existsSync(e)) throw new Error("absolute srcpath does not exist");
return {
toCwd: e,
toDst: e
};
var Re, pt;
function Er() {
if (pt) return Re;
pt = 1;
const e = /* @__PURE__ */ W(), n = U().fromPromise;
function i(c, u) {
return $(this, null, function* () {
if (u) return u;
let r;
try {
r = yield e.lstat(c);
} catch (w) {
return "file";
}
return r && r.isDirectory() ? "dir" : "file";
});
}
const r = X.dirname(t), n = X.join(r, e);
if (se.existsSync(n))
return {
toCwd: n,
toDst: e
};
if (!se.existsSync(e)) throw new Error("relative srcpath does not exist");
return {
toCwd: e,
toDst: X.relative(r, e)
};
}
var Tn = {
symlinkPaths: Dn(Cn),
symlinkPathsSync: Nn
};
const Rt = I, Ln = x.fromPromise;
function Rn(e, t) {
return E(this, null, function* () {
if (t) return t;
function a(c, u) {
if (u) return u;
let r;
try {
r = yield Rt.lstat(e);
} catch (n) {
r = e.lstatSync(c);
} catch (w) {
return "file";
}
return r && r.isDirectory() ? "dir" : "file";
});
}
return Re = {
symlinkType: n(i),
symlinkTypeSync: a
}, Re;
}
function jn(e, t) {
if (t) return t;
let r;
try {
r = Rt.lstatSync(e);
} catch (n) {
return "file";
var $e, vt;
function kr() {
if (vt) return $e;
vt = 1;
const e = U().fromPromise, n = Y, i = /* @__PURE__ */ W(), { mkdirs: a, mkdirsSync: c } = /* @__PURE__ */ H(), { symlinkPaths: u, symlinkPathsSync: r } = /* @__PURE__ */ br(), { symlinkType: w, symlinkTypeSync: y } = /* @__PURE__ */ Er(), { pathExists: m } = /* @__PURE__ */ Z(), { areIdentical: E } = /* @__PURE__ */ re();
function v(f, _, d) {
return $(this, null, function* () {
let t;
try {
t = yield i.lstat(_);
} catch (g) {
}
if (t && t.isSymbolicLink()) {
const [g, p] = yield Promise.all([
i.stat(f),
i.stat(_)
]);
if (E(g, p)) return;
}
const o = yield u(f, _);
f = o.toDst;
const l = yield w(o.toCwd, d), h = n.dirname(_);
return (yield m(h)) || (yield a(h)), i.symlink(f, _, l);
});
}
return r && r.isDirectory() ? "dir" : "file";
}
var An = {
symlinkType: Ln(Rn),
symlinkTypeSync: jn
};
const Mn = x.fromPromise, jt = U, z = I, { mkdirs: In, mkdirsSync: Bn } = G, { symlinkPaths: Un, symlinkPathsSync: Wn } = Tn, { symlinkType: Jn, symlinkTypeSync: zn } = An, { pathExists: Gn } = Q, { areIdentical: At } = ae;
function qn(e, t, r) {
return E(this, null, function* () {
let n;
function s(f, _, d) {
let t;
try {
n = yield z.lstat(t);
} catch (s) {
t = i.lstatSync(_);
} catch (g) {
}
if (n && n.isSymbolicLink()) {
const [s, u] = yield Promise.all([
z.stat(e),
z.stat(t)
]);
if (At(s, u)) return;
if (t && t.isSymbolicLink()) {
const g = i.statSync(f), p = i.statSync(_);
if (E(g, p)) return;
}
const i = yield Un(e, t);
e = i.toDst;
const o = yield Jn(i.toCwd, r), c = jt.dirname(t);
return (yield Gn(c)) || (yield In(c)), z.symlink(e, t, o);
});
const o = r(f, _);
f = o.toDst, d = y(o.toCwd, d);
const l = n.dirname(_);
return i.existsSync(l) || c(l), i.symlinkSync(f, _, d);
}
return $e = {
createSymlink: e(v),
createSymlinkSync: s
}, $e;
}
function Yn(e, t, r) {
let n;
var qe, St;
function Fr() {
if (St) return qe;
St = 1;
const { createFile: e, createFileSync: n } = /* @__PURE__ */ _r(), { createLink: i, createLinkSync: a } = /* @__PURE__ */ gr(), { createSymlink: c, createSymlinkSync: u } = /* @__PURE__ */ kr();
return qe = {
// file
createFile: e,
createFileSync: n,
ensureFile: e,
ensureFileSync: n,
// link
createLink: i,
createLinkSync: a,
ensureLink: i,
ensureLinkSync: a,
// symlink
createSymlink: c,
createSymlinkSync: u,
ensureSymlink: c,
ensureSymlinkSync: u
}, qe;
}
var Ce, _t;
function Ge() {
if (_t) return Ce;
_t = 1;
function e(i, { EOL: a = `
`, finalEOL: c = !0, replacer: u = null, spaces: r } = {}) {
const w = c ? a : "";
return JSON.stringify(i, u, r).replace(/\n/g, a) + w;
}
function n(i) {
return Buffer.isBuffer(i) && (i = i.toString("utf8")), i.replace(/^\uFEFF/, "");
}
return Ce = { stringify: e, stripBom: n }, Ce;
}
var Ne, gt;
function Pr() {
if (gt) return Ne;
gt = 1;
let e;
try {
n = z.lstatSync(t);
} catch (s) {
e = oe();
} catch (v) {
e = Lt;
}
if (n && n.isSymbolicLink()) {
const s = z.statSync(e), u = z.statSync(t);
if (At(s, u)) return;
const n = U(), { stringify: i, stripBom: a } = Ge();
function c(f) {
return $(this, arguments, function* (v, s = {}) {
typeof s == "string" && (s = { encoding: s });
const _ = s.fs || e, d = "throws" in s ? s.throws : !0;
let t = yield n.fromCallback(_.readFile)(v, s);
t = a(t);
let o;
try {
o = JSON.parse(t, s ? s.reviver : null);
} catch (l) {
if (d)
throw l.message = `${v}: ${l.message}`, l;
return null;
}
return o;
});
}
const i = Wn(e, t);
e = i.toDst, r = zn(i.toCwd, r);
const o = jt.dirname(t);
return z.existsSync(o) || Bn(o), z.symlinkSync(e, t, r);
}
var Vn = {
createSymlink: Mn(qn),
createSymlinkSync: Yn
};
const { createFile: Qe, createFileSync: Ze } = En, { createLink: et, createLinkSync: tt } = On, { createSymlink: rt, createSymlinkSync: nt } = Vn;
var Xn = {
// file
createFile: Qe,
createFileSync: Ze,
ensureFile: Qe,
ensureFileSync: Ze,
// link
createLink: et,
createLinkSync: tt,
ensureLink: et,
ensureLinkSync: tt,
// symlink
createSymlink: rt,
createSymlinkSync: nt,
ensureSymlink: rt,
ensureSymlinkSync: nt
};
function Hn(e, { EOL: t = `
`, finalEOL: r = !0, replacer: n = null, spaces: i } = {}) {
const o = r ? t : "";
return JSON.stringify(e, n, i).replace(/\n/g, t) + o;
}
function Kn(e) {
return Buffer.isBuffer(e) && (e = e.toString("utf8")), e.replace(/^\uFEFF/, "");
}
var Ie = { stringify: Hn, stripBom: Kn };
let ie;
try {
ie = ce;
} catch (e) {
ie = ft;
}
const Ee = x, { stringify: Mt, stripBom: It } = Ie;
function Qn(r) {
return E(this, arguments, function* (e, t = {}) {
typeof t == "string" && (t = { encoding: t });
const n = t.fs || ie, i = "throws" in t ? t.throws : !0;
let o = yield Ee.fromCallback(n.readFile)(e, t);
o = It(o);
let c;
const u = n.fromPromise(c);
function r(v, s = {}) {
typeof s == "string" && (s = { encoding: s });
const f = s.fs || e, _ = "throws" in s ? s.throws : !0;
try {
c = JSON.parse(o, t ? t.reviver : null);
} catch (s) {
if (i)
throw s.message = `${e}: ${s.message}`, s;
let d = f.readFileSync(v, s);
return d = a(d), JSON.parse(d, s.reviver);
} catch (d) {
if (_)
throw d.message = `${v}: ${d.message}`, d;
return null;
}
return c;
});
}
const Zn = Ee.fromPromise(Qn);
function ei(e, t = {}) {
typeof t == "string" && (t = { encoding: t });
const r = t.fs || ie, n = "throws" in t ? t.throws : !0;
try {
let i = r.readFileSync(e, t);
return i = It(i), JSON.parse(i, t.reviver);
} catch (i) {
if (n)
throw i.message = `${e}: ${i.message}`, i;
return null;
}
function w(_, d) {
return $(this, arguments, function* (v, s, f = {}) {
const t = f.fs || e, o = i(s, f);
yield n.fromCallback(t.writeFile)(v, o, f);
});
}
const y = n.fromPromise(w);
function m(v, s, f = {}) {
const _ = f.fs || e, d = i(s, f);
return _.writeFileSync(v, d, f);
}
return Ne = {
readFile: u,
readFileSync: r,
writeFile: y,
writeFileSync: m
}, Ne;
}
function ti(n, i) {
return E(this, arguments, function* (e, t, r = {}) {
const o = r.fs || ie, c = Mt(t, r);
yield Ee.fromCallback(o.writeFile)(e, c, r);
});
var Te, bt;
function Or() {
if (bt) return Te;
bt = 1;
const e = Pr();
return Te = {
// jsonfile exports
readJson: e.readFile,
readJsonSync: e.readFileSync,
writeJson: e.writeFile,
writeJsonSync: e.writeFileSync
}, Te;
}
const ri = Ee.fromPromise(ti);
function ni(e, t, r = {}) {
const n = r.fs || ie, i = Mt(t, r);
return n.writeFileSync(e, i, r);
var Le, Et;
function Ye() {
if (Et) return Le;
Et = 1;
const e = U().fromPromise, n = /* @__PURE__ */ W(), i = Y, a = /* @__PURE__ */ H(), c = Z().pathExists;
function u(w, y, m = "utf-8") {
return $(this, null, function* () {
const E = i.dirname(w);
return (yield c(E)) || (yield a.mkdirs(E)), n.writeFile(w, y, m);
});
}
function r(w, ...y) {
const m = i.dirname(w);
n.existsSync(m) || a.mkdirsSync(m), n.writeFileSync(w, ...y);
}
return Le = {
outputFile: e(u),
outputFileSync: r
}, Le;
}
const ii = {
readFile: Zn,
readFileSync: ei,
writeFile: ri,
writeFileSync: ni
};
var oi = ii;
const pe = oi;
var ci = {
// jsonfile exports
readJson: pe.readFile,
readJsonSync: pe.readFileSync,
writeJson: pe.writeFile,
writeJsonSync: pe.writeFileSync
};
const ai = x.fromPromise, xe = I, Bt = U, Ut = G, si = Q.pathExists;
function ui(e, t, r = "utf-8") {
return E(this, null, function* () {
const n = Bt.dirname(e);
return (yield si(n)) || (yield Ut.mkdirs(n)), xe.writeFile(e, t, r);
});
var Me, kt;
function xr() {
if (kt) return Me;
kt = 1;
const { stringify: e } = Ge(), { outputFile: n } = /* @__PURE__ */ Ye();
function i(r, w) {
return $(this, arguments, function* (a, c, u = {}) {
const y = e(c, u);
yield n(a, y, u);
});
}
return Me = i, Me;
}
function fi(e, ...t) {
const r = Bt.dirname(e);
xe.existsSync(r) || Ut.mkdirsSync(r), xe.writeFileSync(e, ...t);
var je, Ft;
function Dr() {
if (Ft) return je;
Ft = 1;
const { stringify: e } = Ge(), { outputFileSync: n } = /* @__PURE__ */ Ye();
function i(a, c, u) {
const r = e(c, u);
n(a, r, u);
}
return je = i, je;
}
var Be = {
outputFile: ai(ui),
outputFileSync: fi
};
const { stringify: li } = Ie, { outputFile: yi } = Be;
function mi(n, i) {
return E(this, arguments, function* (e, t, r = {}) {
const o = li(t, r);
yield yi(e, o, r);
});
var Ae, Pt;
function Rr() {
if (Pt) return Ae;
Pt = 1;
const e = U().fromPromise, n = /* @__PURE__ */ Or();
return n.outputJson = e(/* @__PURE__ */ xr()), n.outputJsonSync = /* @__PURE__ */ Dr(), n.outputJSON = n.outputJson, n.outputJSONSync = n.outputJsonSync, n.writeJSON = n.writeJson, n.writeJSONSync = n.writeJsonSync, n.readJSON = n.readJson, n.readJSONSync = n.readJsonSync, Ae = n, Ae;
}
var di = mi;
const { stringify: hi } = Ie, { outputFileSync: wi } = Be;
function pi(e, t, r) {
const n = hi(t, r);
wi(e, n, r);
var Ie, Ot;
function $r() {
if (Ot) return Ie;
Ot = 1;
const e = /* @__PURE__ */ W(), n = Y, { copy: i } = /* @__PURE__ */ ze(), { remove: a } = /* @__PURE__ */ le(), { mkdirp: c } = /* @__PURE__ */ H(), { pathExists: u } = /* @__PURE__ */ Z(), r = /* @__PURE__ */ re();
function w(f, _) {
return $(this, arguments, function* (E, v, s = {}) {
const d = s.overwrite || s.clobber || !1, { srcStat: t, isChangingCase: o = !1 } = yield r.checkPaths(E, v, "move", s);
yield r.checkParentPaths(E, t, v, "move");
const l = n.dirname(v);
return n.parse(l).root !== l && (yield c(l)), y(E, v, d, o);
});
}
function y(E, v, s, f) {
return $(this, null, function* () {
if (!f) {
if (s)
yield a(v);
else if (yield u(v))
throw new Error("dest already exists.");
}
try {
yield e.rename(E, v);
} catch (_) {
if (_.code !== "EXDEV")
throw _;
yield m(E, v, s);
}
});
}
function m(E, v, s) {
return $(this, null, function* () {
return yield i(E, v, {
overwrite: s,
errorOnExist: !0,
preserveTimestamps: !0
}), a(E);
});
}
return Ie = w, Ie;
}
var Si = pi;
const vi = x.fromPromise, M = ci;
M.outputJson = vi(di);
M.outputJsonSync = Si;
M.outputJSON = M.outputJson;
M.outputJSONSync = M.outputJsonSync;
M.writeJSON = M.writeJson;
M.writeJSONSync = M.writeJsonSync;
M.readJSON = M.readJson;
M.readJSONSync = M.readJsonSync;
var _i = M;
const gi = I, it = U, { copy: bi } = Me, { remove: Wt } = be, { mkdirp: Ei } = G, { pathExists: $i } = Q, ot = ae;
function ki(n, i) {
return E(this, arguments, function* (e, t, r = {}) {
const o = r.overwrite || r.clobber || !1, { srcStat: c, isChangingCase: s = !1 } = yield ot.checkPaths(e, t, "move", r);
yield ot.checkParentPaths(e, c, t, "move");
const u = it.dirname(t);
return it.parse(u).root !== u && (yield Ei(u)), Fi(e, t, o, s);
});
}
function Fi(e, t, r, n) {
return E(this, null, function* () {
if (!n) {
if (r)
yield Wt(t);
else if (yield $i(t))
throw new Error("dest already exists.");
}
var Be, xt;
function qr() {
if (xt) return Be;
xt = 1;
const e = oe(), n = Y, i = ze().copySync, a = le().removeSync, c = H().mkdirpSync, u = /* @__PURE__ */ re();
function r(v, s, f) {
f = f || {};
const _ = f.overwrite || f.clobber || !1, { srcStat: d, isChangingCase: t = !1 } = u.checkPathsSync(v, s, "move", f);
return u.checkParentPathsSync(v, d, s, "move"), w(s) || c(n.dirname(s)), y(v, s, _, t);
}
function w(v) {
const s = n.dirname(v);
return n.parse(s).root === s;
}
function y(v, s, f, _) {
if (_) return m(v, s, f);
if (f)
return a(s), m(v, s, f);
if (e.existsSync(s)) throw new Error("dest already exists.");
return m(v, s, f);
}
function m(v, s, f) {
try {
yield gi.rename(e, t);
} catch (i) {
if (i.code !== "EXDEV")
throw i;
yield Pi(e, t, r);
e.renameSync(v, s);
} catch (_) {
if (_.code !== "EXDEV") throw _;
return E(v, s, f);
}
});
}
function Pi(e, t, r) {
return E(this, null, function* () {
return yield bi(e, t, {
overwrite: r,
}
function E(v, s, f) {
return i(v, s, {
overwrite: f,
errorOnExist: !0,
preserveTimestamps: !0
}), Wt(e);
});
}), a(v);
}
return Be = r, Be;
}
var Oi = ki;
const Jt = ce, De = U, xi = Me.copySync, zt = be.removeSync, Di = G.mkdirpSync, ct = ae;
function Ci(e, t, r) {
r = r || {};
const n = r.overwrite || r.clobber || !1, { srcStat: i, isChangingCase: o = !1 } = ct.checkPathsSync(e, t, "move", r);
return ct.checkParentPathsSync(e, i, t, "move"), Ni(t) || Di(De.dirname(t)), Ti(e, t, n, o);
var Ue, Dt;
function Cr() {
if (Dt) return Ue;
Dt = 1;
const e = U().fromPromise;
return Ue = {
move: e(/* @__PURE__ */ $r()),
moveSync: /* @__PURE__ */ qr()
}, Ue;
}
function Ni(e) {
const t = De.dirname(e);
return De.parse(t).root === t;
var Je, Rt;
function Nr() {
return Rt || (Rt = 1, Je = z(z(z(z(z(z(z(z(z(z({}, /* @__PURE__ */ W()), /* @__PURE__ */ ze()), /* @__PURE__ */ Sr()), /* @__PURE__ */ Fr()), /* @__PURE__ */ Rr()), /* @__PURE__ */ H()), /* @__PURE__ */ Cr()), /* @__PURE__ */ Ye()), /* @__PURE__ */ Z()), /* @__PURE__ */ le())), Je;
}
function Ti(e, t, r, n) {
if (n) return Pe(e, t, r);
if (r)
return zt(t), Pe(e, t, r);
if (Jt.existsSync(t)) throw new Error("dest already exists.");
return Pe(e, t, r);
var Tr = /* @__PURE__ */ Nr();
const te = /* @__PURE__ */ Tt(Tr);
var se = { exports: {} }, fe = { exports: {} };
const Lr = new Proxy({}, {
get(e, n) {
throw new Error(`Module "buffer" has been externalized for browser compatibility. Cannot access "buffer.${n}" in client code. See https://vite.dev/guide/troubleshooting.html#module-externalized-for-browser-compatibility for more details.`);
}
}), Mr = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
__proto__: null,
default: Lr
}, Symbol.toStringTag, { value: "Module" })), jr = /* @__PURE__ */ Q(Mr);
/*! safe-buffer. MIT License. Feross Aboukhadijeh <https://feross.org/opensource> */
var $t;
function Ar() {
return $t || ($t = 1, function(e, n) {
var i = jr, a = i.Buffer;
function c(r, w) {
for (var y in r)
w[y] = r[y];
}
a.from && a.alloc && a.allocUnsafe && a.allocUnsafeSlow ? e.exports = i : (c(i, n), n.Buffer = u);
function u(r, w, y) {
return a(r, w, y);
}
u.prototype = Object.create(a.prototype), c(a, u), u.from = function(r, w, y) {
if (typeof r == "number")
throw new TypeError("Argument must not be a number");
return a(r, w, y);
}, u.alloc = function(r, w, y) {
if (typeof r != "number")
throw new TypeError("Argument must be a number");
var m = a(r);
return w !== void 0 ? typeof y == "string" ? m.fill(w, y) : m.fill(w) : m.fill(0), m;
}, u.allocUnsafe = function(r) {
if (typeof r != "number")
throw new TypeError("Argument must be a number");
return a(r);
}, u.allocUnsafeSlow = function(r) {
if (typeof r != "number")
throw new TypeError("Argument must be a number");
return i.SlowBuffer(r);
};
}(fe, fe.exports)), fe.exports;
}
function Pe(e, t, r) {
try {
Jt.renameSync(e, t);
} catch (n) {
if (n.code !== "EXDEV") throw n;
return Li(e, t, r);
var qt;
function Ir() {
if (qt) return se.exports;
qt = 1;
var e = 65536, n = 4294967295;
function i() {
throw new Error(`Secure random number generation is not supported by this browser.
Use Chrome, Firefox or Internet Explorer 11`);
}
var a = Ar().Buffer, c = ie.crypto || ie.msCrypto;
c && c.getRandomValues ? se.exports = u : se.exports = i;
function u(r, w) {
if (r > n) throw new RangeError("requested too many random bytes");
var y = a.allocUnsafe(r);
if (r > 0)
if (r > e)
for (var m = 0; m < r; m += e)
c.getRandomValues(y.slice(m, m + e));
else
c.getRandomValues(y);
return typeof w == "function" ? process.nextTick(function() {
w(null, y);
}) : y;
}
return se.exports;
}
function Li(e, t, r) {
return xi(e, t, {
overwrite: r,
errorOnExist: !0,
preserveTimestamps: !0
}), zt(e);
}
var Ri = Ci;
const ji = x.fromPromise;
var Ai = {
move: ji(Oi),
moveSync: Ri
}, Mi = B(B(B(B(B(B(B(B(B(B({}, I), Me), vn), Xn), _i), G), Ai), Be), Q), be);
const oe = /* @__PURE__ */ ut(Mi);
var Ce = { exports: {} }, Ne = { exports: {} };
const Ii = new Proxy({}, {
get(e, t) {
throw new Error(`Module "buffer" has been externalized for browser compatibility. Cannot access "buffer.${t}" in client code. See https://vite.dev/guide/troubleshooting.html#module-externalized-for-browser-compatibility for more details.`);
var We, Ct;
function Br() {
if (Ct) return We;
Ct = 1;
var e = Ir(), n = 16, i = v(), a = new RegExp('(\\\\)?"@__(F|R|D|M|S|A|U|I|B|L)-' + i + '-(\\d+)__@"', "g"), c = /\{\s*\[native code\]\s*\}/g, u = /function.*?\(/, r = /.*?=>.*?/, w = /[<>\/\u2028\u2029]/g, y = ["*", "async"], m = {
"<": "\\u003C",
">": "\\u003E",
"/": "\\u002F",
"\u2028": "\\u2028",
"\u2029": "\\u2029"
};
function E(f) {
return m[f];
}
}), Bi = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
__proto__: null,
default: Ii
}, Symbol.toStringTag, { value: "Module" })), Ui = /* @__PURE__ */ K(Bi);
/*! safe-buffer. MIT License. Feross Aboukhadijeh <https://feross.org/opensource> */
(function(e, t) {
var r = Ui, n = r.Buffer;
function i(c, s) {
for (var u in c)
s[u] = c[u];
function v() {
for (var f = e(n), _ = "", d = 0; d < n; ++d)
_ += f[d].toString(16);
return _;
}
n.from && n.alloc && n.allocUnsafe && n.allocUnsafeSlow ? e.exports = r : (i(r, t), t.Buffer = o);
function o(c, s, u) {
return n(c, s, u);
function s(f) {
var _ = [];
for (var d in f)
typeof f[d] == "function" && _.push(d);
for (var t = 0; t < _.length; t++)
delete f[_[t]];
}
o.prototype = Object.create(n.prototype), i(n, o), o.from = function(c, s, u) {
if (typeof c == "number")
throw new TypeError("Argument must not be a number");
return n(c, s, u);
}, o.alloc = function(c, s, u) {
if (typeof c != "number")
throw new TypeError("Argument must be a number");
var p = n(c);
return s !== void 0 ? typeof u == "string" ? p.fill(s, u) : p.fill(s) : p.fill(0), p;
}, o.allocUnsafe = function(c) {
if (typeof c != "number")
throw new TypeError("Argument must be a number");
return n(c);
}, o.allocUnsafeSlow = function(c) {
if (typeof c != "number")
throw new TypeError("Argument must be a number");
return r.SlowBuffer(c);
};
})(Ne, Ne.exports);
var Wi = Ne.exports, Oe = 65536, Ji = 4294967295;
function zi() {
throw new Error(`Secure random number generation is not supported by this browser.
Use Chrome, Firefox or Internet Explorer 11`);
}
var Gi = Wi.Buffer, _e = ue.crypto || ue.msCrypto;
_e && _e.getRandomValues ? Ce.exports = qi : Ce.exports = zi;
function qi(e, t) {
if (e > Ji) throw new RangeError("requested too many random bytes");
var r = Gi.allocUnsafe(e);
if (e > 0)
if (e > Oe)
for (var n = 0; n < e; n += Oe)
_e.getRandomValues(r.slice(n, n + Oe));
else
_e.getRandomValues(r);
return typeof t == "function" ? process.nextTick(function() {
t(null, r);
}) : r;
}
var Yi = Ce.exports, Vi = Yi, at = 16, J = no(), Xi = new RegExp('(\\\\)?"@__(F|R|D|M|S|A|U|I|B|L)-' + J + '-(\\d+)__@"', "g"), Hi = /\{\s*\[native code\]\s*\}/g, Ki = /function.*?\(/, Qi = /.*?=>.*?/, Zi = /[<>\/\u2028\u2029]/g, eo = ["*", "async"], to = {
"<": "\\u003C",
">": "\\u003E",
"/": "\\u002F",
"\u2028": "\\u2028",
"\u2029": "\\u2029"
};
function ro(e) {
return to[e];
}
function no() {
for (var e = Vi(at), t = "", r = 0; r < at; ++r)
t += e[r].toString(16);
return t;
}
function io(e) {
var t = [];
for (var r in e)
typeof e[r] == "function" && t.push(r);
for (var n = 0; n < t.length; n++)
delete e[t[n]];
}
var oo = function e(t, r) {
r || (r = {}), (typeof r == "number" || typeof r == "string") && (r = { space: r });
var n = [], i = [], o = [], c = [], s = [], u = [], p = [], a = [], l = [], y = [];
function f(_, w) {
if (r.ignoreFunction && io(w), !w && w !== void 0 && w !== BigInt(0))
return w;
var m = this[_], S = typeof m;
if (S === "object") {
if (m instanceof RegExp)
return "@__R-" + J + "-" + (i.push(m) - 1) + "__@";
if (m instanceof Date)
return "@__D-" + J + "-" + (o.push(m) - 1) + "__@";
if (m instanceof Map)
return "@__M-" + J + "-" + (c.push(m) - 1) + "__@";
if (m instanceof Set)
return "@__S-" + J + "-" + (s.push(m) - 1) + "__@";
if (m instanceof Array) {
var W = m.filter(function() {
return !0;
}).length !== m.length;
if (W)
return "@__A-" + J + "-" + (u.push(m) - 1) + "__@";
return We = function f(_, d) {
d || (d = {}), (typeof d == "number" || typeof d == "string") && (d = { space: d });
var t = [], o = [], l = [], h = [], g = [], p = [], b = [], S = [], k = [], P = [];
function x(X, L) {
if (d.ignoreFunction && s(L), !L && L !== void 0 && L !== BigInt(0))
return L;
var O = this[X], C = typeof O;
if (C === "object") {
if (O instanceof RegExp)
return "@__R-" + i + "-" + (o.push(O) - 1) + "__@";
if (O instanceof Date)
return "@__D-" + i + "-" + (l.push(O) - 1) + "__@";
if (O instanceof Map)
return "@__M-" + i + "-" + (h.push(O) - 1) + "__@";
if (O instanceof Set)
return "@__S-" + i + "-" + (g.push(O) - 1) + "__@";
if (O instanceof Array) {
var J = O.filter(function() {
return !0;
}).length !== O.length;
if (J)
return "@__A-" + i + "-" + (p.push(O) - 1) + "__@";
}
if (O instanceof URL)
return "@__L-" + i + "-" + (P.push(O) - 1) + "__@";
}
if (m instanceof URL)
return "@__L-" + J + "-" + (y.push(m) - 1) + "__@";
return C === "function" ? "@__F-" + i + "-" + (t.push(O) - 1) + "__@" : C === "undefined" ? "@__U-" + i + "-" + (b.push(O) - 1) + "__@" : C === "number" && !isNaN(O) && !isFinite(O) ? "@__I-" + i + "-" + (S.push(O) - 1) + "__@" : C === "bigint" ? "@__B-" + i + "-" + (k.push(O) - 1) + "__@" : L;
}
return S === "function" ? "@__F-" + J + "-" + (n.push(m) - 1) + "__@" : S === "undefined" ? "@__U-" + J + "-" + (p.push(m) - 1) + "__@" : S === "number" && !isNaN(m) && !isFinite(m) ? "@__I-" + J + "-" + (a.push(m) - 1) + "__@" : S === "bigint" ? "@__B-" + J + "-" + (l.push(m) - 1) + "__@" : w;
}
function d(_) {
var w = _.toString();
if (Hi.test(w))
throw new TypeError("Serializing native function: " + _.name);
if (Ki.test(w) || Qi.test(w))
return w;
var m = w.indexOf("("), S = w.substr(0, m).trim().split(" ").filter(function(Z) {
return Z.length > 0;
}), W = S.filter(function(Z) {
return eo.indexOf(Z) === -1;
});
return W.length > 0 ? (S.indexOf("async") > -1 ? "async " : "") + "function" + (S.join("").indexOf("*") > -1 ? "*" : "") + w.substr(m) : w;
}
if (r.ignoreFunction && typeof t == "function" && (t = void 0), t === void 0)
return String(t);
var v;
return r.isJSON && !r.space ? v = JSON.stringify(t) : v = JSON.stringify(t, r.isJSON ? null : f, r.space), typeof v != "string" ? String(v) : (r.unsafe !== !0 && (v = v.replace(Zi, ro)), n.length === 0 && i.length === 0 && o.length === 0 && c.length === 0 && s.length === 0 && u.length === 0 && p.length === 0 && a.length === 0 && l.length === 0 && y.length === 0 ? v : v.replace(Xi, function(_, w, m, S) {
if (w)
return _;
if (m === "D")
return 'new Date("' + o[S].toISOString() + '")';
if (m === "R")
return "new RegExp(" + e(i[S].source) + ', "' + i[S].flags + '")';
if (m === "M")
return "new Map(" + e(Array.from(c[S].entries()), r) + ")";
if (m === "S")
return "new Set(" + e(Array.from(s[S].values()), r) + ")";
if (m === "A")
return "Array.prototype.slice.call(" + e(Object.assign({ length: u[S].length }, u[S]), r) + ")";
if (m === "U")
return "undefined";
if (m === "I")
return a[S];
if (m === "B")
return 'BigInt("' + l[S] + '")';
if (m === "L")
return "new URL(" + e(y[S].toString(), r) + ")";
var W = n[S];
return d(W);
}));
};
const co = /* @__PURE__ */ ut(oo), ao = (e) => new Function(`return ${e}`)(), te = void 0, so = encodeURIComponent, Gt = st.resolve(Zt.tmpdir(), "idmp"), Ue = (e) => st.resolve(Gt, "v1/node", so(e)), uo = (e, t, r) => E(void 0, null, function* () {
function V(X) {
var L = X.toString();
if (c.test(L))
throw new TypeError("Serializing native function: " + X.name);
if (u.test(L) || r.test(L))
return L;
var O = L.indexOf("("), C = L.substr(0, O).trim().split(" ").filter(function(ne) {
return ne.length > 0;
}), J = C.filter(function(ne) {
return y.indexOf(ne) === -1;
});
return J.length > 0 ? (C.indexOf("async") > -1 ? "async " : "") + "function" + (C.join("").indexOf("*") > -1 ? "*" : "") + L.substr(O) : L;
}
if (d.ignoreFunction && typeof _ == "function" && (_ = void 0), _ === void 0)
return String(_);
var G;
return d.isJSON && !d.space ? G = JSON.stringify(_) : G = JSON.stringify(_, d.isJSON ? null : x, d.space), typeof G != "string" ? String(G) : (d.unsafe !== !0 && (G = G.replace(w, E)), t.length === 0 && o.length === 0 && l.length === 0 && h.length === 0 && g.length === 0 && p.length === 0 && b.length === 0 && S.length === 0 && k.length === 0 && P.length === 0 ? G : G.replace(a, function(X, L, O, C) {
if (L)
return X;
if (O === "D")
return 'new Date("' + l[C].toISOString() + '")';
if (O === "R")
return "new RegExp(" + f(o[C].source) + ', "' + o[C].flags + '")';
if (O === "M")
return "new Map(" + f(Array.from(h[C].entries()), d) + ")";
if (O === "S")
return "new Set(" + f(Array.from(g[C].values()), d) + ")";
if (O === "A")
return "Array.prototype.slice.call(" + f(Object.assign({ length: p[C].length }, p[C]), d) + ")";
if (O === "U")
return "undefined";
if (O === "I")
return S[C];
if (O === "B")
return 'BigInt("' + k[C] + '")';
if (O === "L")
return "new URL(" + f(P[C].toString(), d) + ")";
var J = t[C];
return V(J);
}));
}, We;
}
var Ur = Br();
const Jr = /* @__PURE__ */ Tt(Ur), Wr = (e) => new Function(`return ${e}`)(), ee = void 0, zr = encodeURIComponent, jt = Nt.resolve(Xt.tmpdir(), "idmp"), Ve = (e) => Nt.resolve(jt, "v1/node", zr(e)), Gr = (e, n, i) => $(void 0, null, function* () {
if (!e) return;
const n = Ue(e);
oe.ensureFileSync(n), oe.outputFileSync(
n,
co({
const a = Ve(e);
te.ensureFileSync(a), te.outputFileSync(
a,
Jr({
t: Date.now(),
a: r,
d: t
a: i,
d: n
})
);
}), fo = (e) => E(void 0, null, function* () {
if (!e) return te;
const t = Ue(e);
let r;
}), Yr = (e) => $(void 0, null, function* () {
if (!e) return ee;
const n = Ve(e);
let i;
try {
r = ao(oe.readFileSync(t, "utf-8"));
} catch (c) {
i = Wr(te.readFileSync(n, "utf-8"));
} catch (r) {
}
if (r === te) return te;
const { t: n, a: i, d: o } = r;
return Date.now() - n > i ? (oe.removeSync(t), te) : o;
}), mo = (e, t = "") => {
const r = (n, i, o) => {
n = `${t}_${n}`;
const c = Qt(o);
if (i === ee) return ee;
const { t: a, a: c, d: u } = i;
return Date.now() - a > c ? (te.removeSync(n), ee) : u;
}), Hr = (e, n = "") => {
const i = (a, c, u) => {
a = `${n}_${a}`;
const r = Vt(u);
return e(
n,
() => E(void 0, null, function* () {
const s = yield fo(n);
if (s !== te)
return s;
const u = yield i();
return u !== te && uo(n, u, c.maxAge), u;
a,
() => $(void 0, null, function* () {
const w = yield Yr(a);
if (w !== ee)
return w;
const y = yield c();
return y !== ee && Gr(a, y, r.maxAge), y;
}),
o
u
);
};
return r.flush = (n) => {
e.flush(n), oe.removeSync(Ue(n));
}, r.flushAll = () => {
e.flushAll(), oe.removeSync(Gt);
}, r;
return i.flush = (a) => {
e.flush(a), te.removeSync(Ve(a));
}, i.flushAll = () => {
e.flushAll(), te.removeSync(jt);
}, i;
};
export {
Gt as cacheDir,
mo as default,
Ue as getCachePath
jt as cacheDir,
Hr as default,
Ve as getCachePath
};
/*! idmp v1.0.0 | (c) github/haozi | MIT */
(function(D,T){typeof exports=="object"&&typeof module!="undefined"?T(exports):typeof define=="function"&&define.amd?define(["exports"],T):(D=typeof globalThis!="undefined"?globalThis:D||self,T(D.idmp={}))})(this,function(D){"use strict";var ro=Object.defineProperty;var Kt=Object.getOwnPropertySymbols;var no=Object.prototype.hasOwnProperty,io=Object.prototype.propertyIsEnumerable;var Qt=(D,T,A)=>T in D?ro(D,T,{enumerable:!0,configurable:!0,writable:!0,value:A}):D[T]=A,z=(D,T)=>{for(var A in T||(T={}))no.call(T,A)&&Qt(D,A,T[A]);if(Kt)for(var A of Kt(T))io.call(T,A)&&Qt(D,A,T[A]);return D};var E=(D,T,A)=>new Promise((Ce,_e)=>{var Ne=J=>{try{ne(A.next(J))}catch(ie){_e(ie)}},Te=J=>{try{ne(A.throw(J))}catch(ie){_e(ie)}},ne=J=>J.done?Ce(J.value):Promise.resolve(J.value).then(Ne,Te);ne((A=A.apply(D,T)).next())});/*! idmp v2.1.8 | (c) github/haozi | MIT */const Ce=()=>{},_e=e=>e<0?0:e>6048e5?6048e5:e,Ne=e=>{const{maxRetry:t=30,maxAge:r=3e3,onBeforeRetry:n=Ce}=e||{},i=_e(r);return{maxRetry:t,maxAge:i,onBeforeRetry:n,f:r===1/0}},Te=new Proxy({},{get(e,t){throw new Error(`Module "node:os" has been externalized for browser compatibility. Cannot access "node:os.${t}" in client code. See https://vite.dev/guide/troubleshooting.html#module-externalized-for-browser-compatibility for more details.`)}}),ne=new Proxy({},{get(e,t){throw new Error(`Module "node:path" has been externalized for browser compatibility. Cannot access "node:path.${t}" in client code. See https://vite.dev/guide/troubleshooting.html#module-externalized-for-browser-compatibility for more details.`)}});var J=typeof globalThis!="undefined"?globalThis:typeof window!="undefined"?window:typeof global!="undefined"?global:typeof self!="undefined"?self:{};function ie(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}function ee(e){if(e.__esModule)return e;var t=e.default;if(typeof t=="function"){var r=function n(){return this instanceof n?Reflect.construct(t,arguments,this.constructor):t.apply(this,arguments)};r.prototype=t.prototype}else r={};return Object.defineProperty(r,"__esModule",{value:!0}),Object.keys(e).forEach(function(n){var i=Object.getOwnPropertyDescriptor(e,n);Object.defineProperty(r,n,i.get?i:{enumerable:!0,get:function(){return e[n]}})}),r}var I={},x={};x.fromCallback=function(e){return Object.defineProperty(function(...t){if(typeof t[t.length-1]=="function")e.apply(this,t);else return new Promise((r,n)=>{t.push((i,o)=>i!=null?n(i):r(o)),e.apply(this,t)})},"name",{value:e.name})},x.fromPromise=function(e){return Object.defineProperty(function(...t){const r=t[t.length-1];if(typeof r!="function")return e.apply(this,t);t.pop(),e.apply(this,t).then(n=>r(null,n),r)},"name",{value:e.name})};const Zt=new Proxy({},{get(e,t){throw new Error(`Module "fs" has been externalized for browser compatibility. Cannot access "fs.${t}" in client code. See https://vite.dev/guide/troubleshooting.html#module-externalized-for-browser-compatibility for more details.`)}}),Qe=ee(Object.freeze(Object.defineProperty({__proto__:null,default:Zt},Symbol.toStringTag,{value:"Module"}))),er=new Proxy({},{get(e,t){throw new Error(`Module "constants" has been externalized for browser compatibility. Cannot access "constants.${t}" in client code. See https://vite.dev/guide/troubleshooting.html#module-externalized-for-browser-compatibility for more details.`)}});var K=ee(Object.freeze(Object.defineProperty({__proto__:null,default:er},Symbol.toStringTag,{value:"Module"}))),tr=process.cwd,ge=null,rr=process.env.GRACEFUL_FS_PLATFORM||process.platform;process.cwd=function(){return ge||(ge=tr.call(process)),ge};try{process.cwd()}catch(e){}if(typeof process.chdir=="function"){var Ze=process.chdir;process.chdir=function(e){ge=null,Ze.call(process,e)},Object.setPrototypeOf&&Object.setPrototypeOf(process.chdir,Ze)}var nr=ir;function ir(e){K.hasOwnProperty("O_SYMLINK")&&process.version.match(/^v0\.6\.[0-2]|^v0\.5\./)&&t(e),e.lutimes||r(e),e.chown=o(e.chown),e.fchown=o(e.fchown),e.lchown=o(e.lchown),e.chmod=n(e.chmod),e.fchmod=n(e.fchmod),e.lchmod=n(e.lchmod),e.chownSync=c(e.chownSync),e.fchownSync=c(e.fchownSync),e.lchownSync=c(e.lchownSync),e.chmodSync=i(e.chmodSync),e.fchmodSync=i(e.fchmodSync),e.lchmodSync=i(e.lchmodSync),e.stat=s(e.stat),e.fstat=s(e.fstat),e.lstat=s(e.lstat),e.statSync=u(e.statSync),e.fstatSync=u(e.fstatSync),e.lstatSync=u(e.lstatSync),e.chmod&&!e.lchmod&&(e.lchmod=function(a,l,y){y&&process.nextTick(y)},e.lchmodSync=function(){}),e.chown&&!e.lchown&&(e.lchown=function(a,l,y,f){f&&process.nextTick(f)},e.lchownSync=function(){}),rr==="win32"&&(e.rename=typeof e.rename!="function"?e.rename:function(a){function l(y,f,d){var v=Date.now(),_=0;a(y,f,function w(m){if(m&&(m.code==="EACCES"||m.code==="EPERM"||m.code==="EBUSY")&&Date.now()-v<6e4){setTimeout(function(){e.stat(f,function(p,Y){p&&p.code==="ENOENT"?a(y,f,w):d(m)})},_),_<100&&(_+=10);return}d&&d(m)})}return Object.setPrototypeOf&&Object.setPrototypeOf(l,a),l}(e.rename)),e.read=typeof e.read!="function"?e.read:function(a){function l(y,f,d,v,_,w){var m;if(w&&typeof w=="function"){var p=0;m=function(Y,me,Ht){if(Y&&Y.code==="EAGAIN"&&p<10)return p++,a.call(e,y,f,d,v,_,m);w.apply(this,arguments)}}return a.call(e,y,f,d,v,_,m)}return Object.setPrototypeOf&&Object.setPrototypeOf(l,a),l}(e.read),e.readSync=typeof e.readSync!="function"?e.readSync:function(a){return function(l,y,f,d,v){for(var _=0;;)try{return a.call(e,l,y,f,d,v)}catch(w){if(w.code==="EAGAIN"&&_<10){_++;continue}throw w}}}(e.readSync);function t(a){a.lchmod=function(l,y,f){a.open(l,K.O_WRONLY|K.O_SYMLINK,y,function(d,v){if(d){f&&f(d);return}a.fchmod(v,y,function(_){a.close(v,function(w){f&&f(_||w)})})})},a.lchmodSync=function(l,y){var f=a.openSync(l,K.O_WRONLY|K.O_SYMLINK,y),d=!0,v;try{v=a.fchmodSync(f,y),d=!1}finally{if(d)try{a.closeSync(f)}catch(_){}else a.closeSync(f)}return v}}function r(a){K.hasOwnProperty("O_SYMLINK")&&a.futimes?(a.lutimes=function(l,y,f,d){a.open(l,K.O_SYMLINK,function(v,_){if(v){d&&d(v);return}a.futimes(_,y,f,function(w){a.close(_,function(m){d&&d(w||m)})})})},a.lutimesSync=function(l,y,f){var d=a.openSync(l,K.O_SYMLINK),v,_=!0;try{v=a.futimesSync(d,y,f),_=!1}finally{if(_)try{a.closeSync(d)}catch(w){}else a.closeSync(d)}return v}):a.futimes&&(a.lutimes=function(l,y,f,d){d&&process.nextTick(d)},a.lutimesSync=function(){})}function n(a){return a&&function(l,y,f){return a.call(e,l,y,function(d){S(d)&&(d=null),f&&f.apply(this,arguments)})}}function i(a){return a&&function(l,y){try{return a.call(e,l,y)}catch(f){if(!S(f))throw f}}}function o(a){return a&&function(l,y,f,d){return a.call(e,l,y,f,function(v){S(v)&&(v=null),d&&d.apply(this,arguments)})}}function c(a){return a&&function(l,y,f){try{return a.call(e,l,y,f)}catch(d){if(!S(d))throw d}}}function s(a){return a&&function(l,y,f){typeof y=="function"&&(f=y,y=null);function d(v,_){_&&(_.uid<0&&(_.uid+=4294967296),_.gid<0&&(_.gid+=4294967296)),f&&f.apply(this,arguments)}return y?a.call(e,l,y,d):a.call(e,l,d)}}function u(a){return a&&function(l,y){var f=y?a.call(e,l,y):a.call(e,l);return f&&(f.uid<0&&(f.uid+=4294967296),f.gid<0&&(f.gid+=4294967296)),f}}function S(a){if(!a||a.code==="ENOSYS")return!0;var l=!process.getuid||process.getuid()!==0;return!!(l&&(a.code==="EINVAL"||a.code==="EPERM"))}}const or=new Proxy({},{get(e,t){throw new Error(`Module "stream" has been externalized for browser compatibility. Cannot access "stream.${t}" in client code. See https://vite.dev/guide/troubleshooting.html#module-externalized-for-browser-compatibility for more details.`)}});var et=ee(Object.freeze(Object.defineProperty({__proto__:null,default:or},Symbol.toStringTag,{value:"Module"}))).Stream,cr=ar;function ar(e){return{ReadStream:t,WriteStream:r};function t(n,i){if(!(this instanceof t))return new t(n,i);et.call(this);var o=this;this.path=n,this.fd=null,this.readable=!0,this.paused=!1,this.flags="r",this.mode=438,this.bufferSize=64*1024,i=i||{};for(var c=Object.keys(i),s=0,u=c.length;s<u;s++){var S=c[s];this[S]=i[S]}if(this.encoding&&this.setEncoding(this.encoding),this.start!==void 0){if(typeof this.start!="number")throw TypeError("start must be a Number");if(this.end===void 0)this.end=1/0;else if(typeof this.end!="number")throw TypeError("end must be a Number");if(this.start>this.end)throw new Error("start must be <= end");this.pos=this.start}if(this.fd!==null){process.nextTick(function(){o._read()});return}e.open(this.path,this.flags,this.mode,function(a,l){if(a){o.emit("error",a),o.readable=!1;return}o.fd=l,o.emit("open",l),o._read()})}function r(n,i){if(!(this instanceof r))return new r(n,i);et.call(this),this.path=n,this.fd=null,this.writable=!0,this.flags="w",this.encoding="binary",this.mode=438,this.bytesWritten=0,i=i||{};for(var o=Object.keys(i),c=0,s=o.length;c<s;c++){var u=o[c];this[u]=i[u]}if(this.start!==void 0){if(typeof this.start!="number")throw TypeError("start must be a Number");if(this.start<0)throw new Error("start must be >= zero");this.pos=this.start}this.busy=!1,this._queue=[],this.fd===null&&(this._open=e.open,this._queue.push([this._open,this.path,this.flags,this.mode,void 0]),this.flush())}}var sr=fr,ur=Object.getPrototypeOf||function(e){return e.__proto__};function fr(e){if(e===null||typeof e!="object")return e;if(e instanceof Object)var t={__proto__:ur(e)};else var t=Object.create(null);return Object.getOwnPropertyNames(e).forEach(function(r){Object.defineProperty(t,r,Object.getOwnPropertyDescriptor(e,r))}),t}const lr=new Proxy({},{get(e,t){throw new Error(`Module "util" has been externalized for browser compatibility. Cannot access "util.${t}" in client code. See https://vite.dev/guide/troubleshooting.html#module-externalized-for-browser-compatibility for more details.`)}}),yr=ee(Object.freeze(Object.defineProperty({__proto__:null,default:lr},Symbol.toStringTag,{value:"Module"}))),mr=new Proxy({},{get(e,t){throw new Error(`Module "assert" has been externalized for browser compatibility. Cannot access "assert.${t}" in client code. See https://vite.dev/guide/troubleshooting.html#module-externalized-for-browser-compatibility for more details.`)}}),dr=ee(Object.freeze(Object.defineProperty({__proto__:null,default:mr},Symbol.toStringTag,{value:"Module"})));var F=Qe,hr=nr,wr=cr,pr=sr,be=yr,j,Ee;typeof Symbol=="function"&&typeof Symbol.for=="function"?(j=Symbol.for("graceful-fs.queue"),Ee=Symbol.for("graceful-fs.previous")):(j="___graceful-fs.queue",Ee="___graceful-fs.previous");function Sr(){}function tt(e,t){Object.defineProperty(e,j,{get:function(){return t}})}var te=Sr;if(be.debuglog?te=be.debuglog("gfs4"):/\bgfs4\b/i.test(process.env.NODE_DEBUG||"")&&(te=function(){var e=be.format.apply(be,arguments);e="GFS4: "+e.split(/\n/).join(`
GFS4: `),console.error(e)}),!F[j]){var vr=J[j]||[];tt(F,vr),F.close=function(e){function t(r,n){return e.call(F,r,function(i){i||rt(),typeof n=="function"&&n.apply(this,arguments)})}return Object.defineProperty(t,Ee,{value:e}),t}(F.close),F.closeSync=function(e){function t(r){e.apply(F,arguments),rt()}return Object.defineProperty(t,Ee,{value:e}),t}(F.closeSync),/\bgfs4\b/i.test(process.env.NODE_DEBUG||"")&&process.on("exit",function(){te(F[j]),dr.equal(F[j].length,0)})}J[j]||tt(J,F[j]);var oe=je(pr(F));process.env.TEST_GRACEFUL_FS_GLOBAL_PATCH&&!F.__patched&&(oe=je(F),F.__patched=!0);function je(e){hr(e),e.gracefulify=je,e.createReadStream=me,e.createWriteStream=Ht;var t=e.readFile;e.readFile=r;function r(h,b,g){return typeof b=="function"&&(g=b,b=null),L(h,b,g);function L(R,N,P,O){return t(R,N,function($){$&&($.code==="EMFILE"||$.code==="ENFILE")?ce([L,[R,N,P],$,O||Date.now(),Date.now()]):typeof P=="function"&&P.apply(this,arguments)})}}var n=e.writeFile;e.writeFile=i;function i(h,b,g,L){return typeof g=="function"&&(L=g,g=null),R(h,b,g,L);function R(N,P,O,$,M){return n(N,P,O,function(k){k&&(k.code==="EMFILE"||k.code==="ENFILE")?ce([R,[N,P,O,$],k,M||Date.now(),Date.now()]):typeof $=="function"&&$.apply(this,arguments)})}}var o=e.appendFile;o&&(e.appendFile=c);function c(h,b,g,L){return typeof g=="function"&&(L=g,g=null),R(h,b,g,L);function R(N,P,O,$,M){return o(N,P,O,function(k){k&&(k.code==="EMFILE"||k.code==="ENFILE")?ce([R,[N,P,O,$],k,M||Date.now(),Date.now()]):typeof $=="function"&&$.apply(this,arguments)})}}var s=e.copyFile;s&&(e.copyFile=u);function u(h,b,g,L){return typeof g=="function"&&(L=g,g=0),R(h,b,g,L);function R(N,P,O,$,M){return s(N,P,O,function(k){k&&(k.code==="EMFILE"||k.code==="ENFILE")?ce([R,[N,P,O,$],k,M||Date.now(),Date.now()]):typeof $=="function"&&$.apply(this,arguments)})}}var S=e.readdir;e.readdir=l;var a=/^v[0-5]\./;function l(h,b,g){typeof b=="function"&&(g=b,b=null);var L=a.test(process.version)?function(P,O,$,M){return S(P,R(P,O,$,M))}:function(P,O,$,M){return S(P,O,R(P,O,$,M))};return L(h,b,g);function R(N,P,O,$){return function(M,k){M&&(M.code==="EMFILE"||M.code==="ENFILE")?ce([L,[N,P,O],M,$||Date.now(),Date.now()]):(k&&k.sort&&k.sort(),typeof O=="function"&&O.call(this,M,k))}}}if(process.version.substr(0,4)==="v0.8"){var y=wr(e);w=y.ReadStream,p=y.WriteStream}var f=e.ReadStream;f&&(w.prototype=Object.create(f.prototype),w.prototype.open=m);var d=e.WriteStream;d&&(p.prototype=Object.create(d.prototype),p.prototype.open=Y),Object.defineProperty(e,"ReadStream",{get:function(){return w},set:function(h){w=h},enumerable:!0,configurable:!0}),Object.defineProperty(e,"WriteStream",{get:function(){return p},set:function(h){p=h},enumerable:!0,configurable:!0});var v=w;Object.defineProperty(e,"FileReadStream",{get:function(){return v},set:function(h){v=h},enumerable:!0,configurable:!0});var _=p;Object.defineProperty(e,"FileWriteStream",{get:function(){return _},set:function(h){_=h},enumerable:!0,configurable:!0});function w(h,b){return this instanceof w?(f.apply(this,arguments),this):w.apply(Object.create(w.prototype),arguments)}function m(){var h=this;Ke(h.path,h.flags,h.mode,function(b,g){b?(h.autoClose&&h.destroy(),h.emit("error",b)):(h.fd=g,h.emit("open",g),h.read())})}function p(h,b){return this instanceof p?(d.apply(this,arguments),this):p.apply(Object.create(p.prototype),arguments)}function Y(){var h=this;Ke(h.path,h.flags,h.mode,function(b,g){b?(h.destroy(),h.emit("error",b)):(h.fd=g,h.emit("open",g))})}function me(h,b){return new e.ReadStream(h,b)}function Ht(h,b){return new e.WriteStream(h,b)}var to=e.open;e.open=Ke;function Ke(h,b,g,L){return typeof g=="function"&&(L=g,g=null),R(h,b,g,L);function R(N,P,O,$,M){return to(N,P,O,function(k,wo){k&&(k.code==="EMFILE"||k.code==="ENFILE")?ce([R,[N,P,O,$],k,M||Date.now(),Date.now()]):typeof $=="function"&&$.apply(this,arguments)})}}return e}function ce(e){te("ENQUEUE",e[0].name,e[1]),F[j].push(e),Le()}var $e;function rt(){for(var e=Date.now(),t=0;t<F[j].length;++t)F[j][t].length>2&&(F[j][t][3]=e,F[j][t][4]=e);Le()}function Le(){if(clearTimeout($e),$e=void 0,F[j].length!==0){var e=F[j].shift(),t=e[0],r=e[1],n=e[2],i=e[3],o=e[4];if(i===void 0)te("RETRY",t.name,r),t.apply(null,r);else if(Date.now()-i>=6e4){te("TIMEOUT",t.name,r);var c=r.pop();typeof c=="function"&&c.call(null,n)}else{var s=Date.now()-o,u=Math.max(o-i,1),S=Math.min(u*1.2,100);s>=S?(te("RETRY",t.name,r),t.apply(null,r.concat([i]))):F[j].push(e)}$e===void 0&&($e=setTimeout(Le,0))}}(function(e){const t=x.fromCallback,r=oe,n=["access","appendFile","chmod","chown","close","copyFile","fchmod","fchown","fdatasync","fstat","fsync","ftruncate","futimes","lchmod","lchown","link","lstat","mkdir","mkdtemp","open","opendir","readdir","readFile","readlink","realpath","rename","rm","rmdir","stat","symlink","truncate","unlink","utimes","writeFile"].filter(i=>typeof r[i]=="function");Object.assign(e,r),n.forEach(i=>{e[i]=t(r[i])}),e.exists=function(i,o){return typeof o=="function"?r.exists(i,o):new Promise(c=>r.exists(i,c))},e.read=function(i,o,c,s,u,S){return typeof S=="function"?r.read(i,o,c,s,u,S):new Promise((a,l)=>{r.read(i,o,c,s,u,(y,f,d)=>{if(y)return l(y);a({bytesRead:f,buffer:d})})})},e.write=function(i,o,...c){return typeof c[c.length-1]=="function"?r.write(i,o,...c):new Promise((s,u)=>{r.write(i,o,...c,(S,a,l)=>{if(S)return u(S);s({bytesWritten:a,buffer:l})})})},e.readv=function(i,o,...c){return typeof c[c.length-1]=="function"?r.readv(i,o,...c):new Promise((s,u)=>{r.readv(i,o,...c,(S,a,l)=>{if(S)return u(S);s({bytesRead:a,buffers:l})})})},e.writev=function(i,o,...c){return typeof c[c.length-1]=="function"?r.writev(i,o,...c):new Promise((s,u)=>{r.writev(i,o,...c,(S,a,l)=>{if(S)return u(S);s({bytesWritten:a,buffers:l})})})},typeof r.realpath.native=="function"?e.realpath.native=t(r.realpath.native):process.emitWarning("fs.realpath.native is not a function. Is fs being monkey-patched?","Warning","fs-extra-WARN0003")})(I);const _r=new Proxy({},{get(e,t){throw new Error(`Module "path" has been externalized for browser compatibility. Cannot access "path.${t}" in client code. See https://vite.dev/guide/troubleshooting.html#module-externalized-for-browser-compatibility for more details.`)}}),q=ee(Object.freeze(Object.defineProperty({__proto__:null,default:_r},Symbol.toStringTag,{value:"Module"})));var Re={},nt={};const gr=q;nt.checkPath=function(t){if(process.platform==="win32"&&/[<>:"|?*]/.test(t.replace(gr.parse(t).root,""))){const n=new Error(`Path contains invalid characters: ${t}`);throw n.code="EINVAL",n}};const it=I,{checkPath:ot}=nt,ct=e=>{const t={mode:511};return typeof e=="number"?e:z(z({},t),e).mode};Re.makeDir=(e,t)=>E(this,null,function*(){return ot(e),it.mkdir(e,{mode:ct(t),recursive:!0})}),Re.makeDirSync=(e,t)=>(ot(e),it.mkdirSync(e,{mode:ct(t),recursive:!0}));const br=x.fromPromise,{makeDir:Er,makeDirSync:Me}=Re,Ae=br(Er);var V={mkdirs:Ae,mkdirsSync:Me,mkdirp:Ae,mkdirpSync:Me,ensureDir:Ae,ensureDirSync:Me};const $r=x.fromPromise,at=I;function kr(e){return at.access(e).then(()=>!0).catch(()=>!1)}var re={pathExists:$r(kr),pathExistsSync:at.existsSync};const ae=I,Fr=x.fromPromise;function Pr(e,t,r){return E(this,null,function*(){const n=yield ae.open(e,"r+");let i=null;try{yield ae.futimes(n,t,r)}finally{try{yield ae.close(n)}catch(o){i=o}}if(i)throw i})}function Or(e,t,r){const n=ae.openSync(e,"r+");return ae.futimesSync(n,t,r),ae.closeSync(n)}var st={utimesMillis:Fr(Pr),utimesMillisSync:Or};const se=I,C=q,ut=x.fromPromise;function xr(e,t,r){const n=r.dereference?i=>se.stat(i,{bigint:!0}):i=>se.lstat(i,{bigint:!0});return Promise.all([n(e),n(t).catch(i=>{if(i.code==="ENOENT")return null;throw i})]).then(([i,o])=>({srcStat:i,destStat:o}))}function Dr(e,t,r){let n;const i=r.dereference?c=>se.statSync(c,{bigint:!0}):c=>se.lstatSync(c,{bigint:!0}),o=i(e);try{n=i(t)}catch(c){if(c.code==="ENOENT")return{srcStat:o,destStat:null};throw c}return{srcStat:o,destStat:n}}function Cr(e,t,r,n){return E(this,null,function*(){const{srcStat:i,destStat:o}=yield xr(e,t,n);if(o){if(de(i,o)){const c=C.basename(e),s=C.basename(t);if(r==="move"&&c!==s&&c.toLowerCase()===s.toLowerCase())return{srcStat:i,destStat:o,isChangingCase:!0};throw new Error("Source and destination must not be the same.")}if(i.isDirectory()&&!o.isDirectory())throw new Error(`Cannot overwrite non-directory '${t}' with directory '${e}'.`);if(!i.isDirectory()&&o.isDirectory())throw new Error(`Cannot overwrite directory '${t}' with non-directory '${e}'.`)}if(i.isDirectory()&&Be(e,t))throw new Error(ke(e,t,r));return{srcStat:i,destStat:o}})}function Nr(e,t,r,n){const{srcStat:i,destStat:o}=Dr(e,t,n);if(o){if(de(i,o)){const c=C.basename(e),s=C.basename(t);if(r==="move"&&c!==s&&c.toLowerCase()===s.toLowerCase())return{srcStat:i,destStat:o,isChangingCase:!0};throw new Error("Source and destination must not be the same.")}if(i.isDirectory()&&!o.isDirectory())throw new Error(`Cannot overwrite non-directory '${t}' with directory '${e}'.`);if(!i.isDirectory()&&o.isDirectory())throw new Error(`Cannot overwrite directory '${t}' with non-directory '${e}'.`)}if(i.isDirectory()&&Be(e,t))throw new Error(ke(e,t,r));return{srcStat:i,destStat:o}}function ft(e,t,r,n){return E(this,null,function*(){const i=C.resolve(C.dirname(e)),o=C.resolve(C.dirname(r));if(o===i||o===C.parse(o).root)return;let c;try{c=yield se.stat(o,{bigint:!0})}catch(s){if(s.code==="ENOENT")return;throw s}if(de(t,c))throw new Error(ke(e,r,n));return ft(e,t,o,n)})}function lt(e,t,r,n){const i=C.resolve(C.dirname(e)),o=C.resolve(C.dirname(r));if(o===i||o===C.parse(o).root)return;let c;try{c=se.statSync(o,{bigint:!0})}catch(s){if(s.code==="ENOENT")return;throw s}if(de(t,c))throw new Error(ke(e,r,n));return lt(e,t,o,n)}function de(e,t){return t.ino&&t.dev&&t.ino===e.ino&&t.dev===e.dev}function Be(e,t){const r=C.resolve(e).split(C.sep).filter(i=>i),n=C.resolve(t).split(C.sep).filter(i=>i);return r.every((i,o)=>n[o]===i)}function ke(e,t,r){return`Cannot ${r} '${e}' to a subdirectory of itself, '${t}'.`}var ue={checkPaths:ut(Cr),checkPathsSync:Nr,checkParentPaths:ut(ft),checkParentPathsSync:lt,isSrcSubdir:Be,areIdentical:de};const B=I,he=q,{mkdirs:Tr}=V,{pathExists:jr}=re,{utimesMillis:Lr}=st,we=ue;function Rr(n,i){return E(this,arguments,function*(e,t,r={}){typeof r=="function"&&(r={filter:r}),r.clobber="clobber"in r?!!r.clobber:!0,r.overwrite="overwrite"in r?!!r.overwrite:r.clobber,r.preserveTimestamps&&process.arch==="ia32"&&process.emitWarning(`Using the preserveTimestamps option in 32-bit node is not recommended;
(function(j,A){typeof exports=="object"&&typeof module!="undefined"?A(exports):typeof define=="function"&&define.amd?define(["exports"],A):(j=typeof globalThis!="undefined"?globalThis:j||self,A(j.idmp={}))})(this,function(j){"use strict";var Ur=Object.defineProperty;var Wt=Object.getOwnPropertySymbols;var Jr=Object.prototype.hasOwnProperty,Wr=Object.prototype.propertyIsEnumerable;var zt=(j,A,z)=>A in j?Ur(j,A,{enumerable:!0,configurable:!0,writable:!0,value:z}):j[A]=z,X=(j,A)=>{for(var z in A||(A={}))Jr.call(A,z)&&zt(j,z,A[z]);if(Wt)for(var z of Wt(A))Wr.call(A,z)&&zt(j,z,A[z]);return j};var $=(j,A,z)=>new Promise((Se,le)=>{var _e=V=>{try{ie(z.next(V))}catch(oe){le(oe)}},ge=V=>{try{ie(z.throw(V))}catch(oe){le(oe)}},ie=V=>V.done?Se(V.value):Promise.resolve(V.value).then(_e,ge);ie((z=z.apply(j,A)).next())});/*! idmp v2.1.9 | (c) github/haozi | MIT */const Se=()=>{},le=e=>e<0?0:e>6048e5?6048e5:e,_e=e=>{const{maxRetry:n=30,maxAge:i=3e3,onBeforeRetry:a=Se}=e||{},c=le(i);return{maxRetry:n,maxAge:c,onBeforeRetry:a,f:i===1/0}},ge=new Proxy({},{get(e,n){throw new Error(`Module "node:os" has been externalized for browser compatibility. Cannot access "node:os.${n}" in client code. See https://vite.dev/guide/troubleshooting.html#module-externalized-for-browser-compatibility for more details.`)}}),ie=new Proxy({},{get(e,n){throw new Error(`Module "node:path" has been externalized for browser compatibility. Cannot access "node:path.${n}" in client code. See https://vite.dev/guide/troubleshooting.html#module-externalized-for-browser-compatibility for more details.`)}});var V=typeof globalThis!="undefined"?globalThis:typeof window!="undefined"?window:typeof global!="undefined"?global:typeof self!="undefined"?self:{};function oe(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}function re(e){if(e.__esModule)return e;var n=e.default;if(typeof n=="function"){var i=function a(){return this instanceof a?Reflect.construct(n,arguments,this.constructor):n.apply(this,arguments)};i.prototype=n.prototype}else i={};return Object.defineProperty(i,"__esModule",{value:!0}),Object.keys(e).forEach(function(a){var c=Object.getOwnPropertyDescriptor(e,a);Object.defineProperty(i,a,c.get?c:{enumerable:!0,get:function(){return e[a]}})}),i}var Ee={},ye={},ot;function I(){return ot||(ot=1,ye.fromCallback=function(e){return Object.defineProperty(function(...n){if(typeof n[n.length-1]=="function")e.apply(this,n);else return new Promise((i,a)=>{n.push((c,f)=>c!=null?a(c):i(f)),e.apply(this,n)})},"name",{value:e.name})},ye.fromPromise=function(e){return Object.defineProperty(function(...n){const i=n[n.length-1];if(typeof i!="function")return e.apply(this,n);n.pop(),e.apply(this,n).then(a=>i(null,a),i)},"name",{value:e.name})}),ye}const Gt=new Proxy({},{get(e,n){throw new Error(`Module "fs" has been externalized for browser compatibility. Cannot access "fs.${n}" in client code. See https://vite.dev/guide/troubleshooting.html#module-externalized-for-browser-compatibility for more details.`)}}),at=re(Object.freeze(Object.defineProperty({__proto__:null,default:Gt},Symbol.toStringTag,{value:"Module"}))),Yt=new Proxy({},{get(e,n){throw new Error(`Module "constants" has been externalized for browser compatibility. Cannot access "constants.${n}" in client code. See https://vite.dev/guide/troubleshooting.html#module-externalized-for-browser-compatibility for more details.`)}}),Vt=re(Object.freeze(Object.defineProperty({__proto__:null,default:Yt},Symbol.toStringTag,{value:"Module"})));var be,ct;function Xt(){if(ct)return be;ct=1;var e=Vt,n=process.cwd,i=null,a=process.env.GRACEFUL_FS_PLATFORM||process.platform;process.cwd=function(){return i||(i=n.call(process)),i};try{process.cwd()}catch(r){}if(typeof process.chdir=="function"){var c=process.chdir;process.chdir=function(r){i=null,c.call(process,r)},Object.setPrototypeOf&&Object.setPrototypeOf(process.chdir,c)}be=f;function f(r){e.hasOwnProperty("O_SYMLINK")&&process.version.match(/^v0\.6\.[0-2]|^v0\.5\./)&&w(r),r.lutimes||h(r),r.chown=v(r.chown),r.fchown=v(r.fchown),r.lchown=v(r.lchown),r.chmod=m(r.chmod),r.fchmod=m(r.fchmod),r.lchmod=m(r.lchmod),r.chownSync=u(r.chownSync),r.fchownSync=u(r.fchownSync),r.lchownSync=u(r.lchownSync),r.chmodSync=b(r.chmodSync),r.fchmodSync=b(r.fchmodSync),r.lchmodSync=b(r.lchmodSync),r.stat=s(r.stat),r.fstat=s(r.fstat),r.lstat=s(r.lstat),r.statSync=_(r.statSync),r.fstatSync=_(r.fstatSync),r.lstatSync=_(r.lstatSync),r.chmod&&!r.lchmod&&(r.lchmod=function(t,o,l){l&&process.nextTick(l)},r.lchmodSync=function(){}),r.chown&&!r.lchown&&(r.lchown=function(t,o,l,d){d&&process.nextTick(d)},r.lchownSync=function(){}),a==="win32"&&(r.rename=typeof r.rename!="function"?r.rename:function(t){function o(l,d,g){var p=Date.now(),E=0;t(l,d,function S(k){if(k&&(k.code==="EACCES"||k.code==="EPERM"||k.code==="EBUSY")&&Date.now()-p<6e4){setTimeout(function(){r.stat(d,function(P,x){P&&P.code==="ENOENT"?t(l,d,S):g(k)})},E),E<100&&(E+=10);return}g&&g(k)})}return Object.setPrototypeOf&&Object.setPrototypeOf(o,t),o}(r.rename)),r.read=typeof r.read!="function"?r.read:function(t){function o(l,d,g,p,E,S){var k;if(S&&typeof S=="function"){var P=0;k=function(x,Z,K){if(x&&x.code==="EAGAIN"&&P<10)return P++,t.call(r,l,d,g,p,E,k);S.apply(this,arguments)}}return t.call(r,l,d,g,p,E,k)}return Object.setPrototypeOf&&Object.setPrototypeOf(o,t),o}(r.read),r.readSync=typeof r.readSync!="function"?r.readSync:function(t){return function(o,l,d,g,p){for(var E=0;;)try{return t.call(r,o,l,d,g,p)}catch(S){if(S.code==="EAGAIN"&&E<10){E++;continue}throw S}}}(r.readSync);function w(t){t.lchmod=function(o,l,d){t.open(o,e.O_WRONLY|e.O_SYMLINK,l,function(g,p){if(g){d&&d(g);return}t.fchmod(p,l,function(E){t.close(p,function(S){d&&d(E||S)})})})},t.lchmodSync=function(o,l){var d=t.openSync(o,e.O_WRONLY|e.O_SYMLINK,l),g=!0,p;try{p=t.fchmodSync(d,l),g=!1}finally{if(g)try{t.closeSync(d)}catch(E){}else t.closeSync(d)}return p}}function h(t){e.hasOwnProperty("O_SYMLINK")&&t.futimes?(t.lutimes=function(o,l,d,g){t.open(o,e.O_SYMLINK,function(p,E){if(p){g&&g(p);return}t.futimes(E,l,d,function(S){t.close(E,function(k){g&&g(S||k)})})})},t.lutimesSync=function(o,l,d){var g=t.openSync(o,e.O_SYMLINK),p,E=!0;try{p=t.futimesSync(g,l,d),E=!1}finally{if(E)try{t.closeSync(g)}catch(S){}else t.closeSync(g)}return p}):t.futimes&&(t.lutimes=function(o,l,d,g){g&&process.nextTick(g)},t.lutimesSync=function(){})}function m(t){return t&&function(o,l,d){return t.call(r,o,l,function(g){y(g)&&(g=null),d&&d.apply(this,arguments)})}}function b(t){return t&&function(o,l){try{return t.call(r,o,l)}catch(d){if(!y(d))throw d}}}function v(t){return t&&function(o,l,d,g){return t.call(r,o,l,d,function(p){y(p)&&(p=null),g&&g.apply(this,arguments)})}}function u(t){return t&&function(o,l,d){try{return t.call(r,o,l,d)}catch(g){if(!y(g))throw g}}}function s(t){return t&&function(o,l,d){typeof l=="function"&&(d=l,l=null);function g(p,E){E&&(E.uid<0&&(E.uid+=4294967296),E.gid<0&&(E.gid+=4294967296)),d&&d.apply(this,arguments)}return l?t.call(r,o,l,g):t.call(r,o,g)}}function _(t){return t&&function(o,l){var d=l?t.call(r,o,l):t.call(r,o);return d&&(d.uid<0&&(d.uid+=4294967296),d.gid<0&&(d.gid+=4294967296)),d}}function y(t){if(!t||t.code==="ENOSYS")return!0;var o=!process.getuid||process.getuid()!==0;return!!(o&&(t.code==="EINVAL"||t.code==="EPERM"))}}return be}const Ht=new Proxy({},{get(e,n){throw new Error(`Module "stream" has been externalized for browser compatibility. Cannot access "stream.${n}" in client code. See https://vite.dev/guide/troubleshooting.html#module-externalized-for-browser-compatibility for more details.`)}}),Kt=re(Object.freeze(Object.defineProperty({__proto__:null,default:Ht},Symbol.toStringTag,{value:"Module"})));var ke,ut;function Qt(){if(ut)return ke;ut=1;var e=Kt.Stream;ke=n;function n(i){return{ReadStream:a,WriteStream:c};function a(f,r){if(!(this instanceof a))return new a(f,r);e.call(this);var w=this;this.path=f,this.fd=null,this.readable=!0,this.paused=!1,this.flags="r",this.mode=438,this.bufferSize=64*1024,r=r||{};for(var h=Object.keys(r),m=0,b=h.length;m<b;m++){var v=h[m];this[v]=r[v]}if(this.encoding&&this.setEncoding(this.encoding),this.start!==void 0){if(typeof this.start!="number")throw TypeError("start must be a Number");if(this.end===void 0)this.end=1/0;else if(typeof this.end!="number")throw TypeError("end must be a Number");if(this.start>this.end)throw new Error("start must be <= end");this.pos=this.start}if(this.fd!==null){process.nextTick(function(){w._read()});return}i.open(this.path,this.flags,this.mode,function(u,s){if(u){w.emit("error",u),w.readable=!1;return}w.fd=s,w.emit("open",s),w._read()})}function c(f,r){if(!(this instanceof c))return new c(f,r);e.call(this),this.path=f,this.fd=null,this.writable=!0,this.flags="w",this.encoding="binary",this.mode=438,this.bytesWritten=0,r=r||{};for(var w=Object.keys(r),h=0,m=w.length;h<m;h++){var b=w[h];this[b]=r[b]}if(this.start!==void 0){if(typeof this.start!="number")throw TypeError("start must be a Number");if(this.start<0)throw new Error("start must be >= zero");this.pos=this.start}this.busy=!1,this._queue=[],this.fd===null&&(this._open=i.open,this._queue.push([this._open,this.path,this.flags,this.mode,void 0]),this.flush())}}return ke}var Fe,st;function Zt(){if(st)return Fe;st=1,Fe=n;var e=Object.getPrototypeOf||function(i){return i.__proto__};function n(i){if(i===null||typeof i!="object")return i;if(i instanceof Object)var a={__proto__:e(i)};else var a=Object.create(null);return Object.getOwnPropertyNames(i).forEach(function(c){Object.defineProperty(a,c,Object.getOwnPropertyDescriptor(i,c))}),a}return Fe}const er=new Proxy({},{get(e,n){throw new Error(`Module "util" has been externalized for browser compatibility. Cannot access "util.${n}" in client code. See https://vite.dev/guide/troubleshooting.html#module-externalized-for-browser-compatibility for more details.`)}}),tr=re(Object.freeze(Object.defineProperty({__proto__:null,default:er},Symbol.toStringTag,{value:"Module"}))),rr=new Proxy({},{get(e,n){throw new Error(`Module "assert" has been externalized for browser compatibility. Cannot access "assert.${n}" in client code. See https://vite.dev/guide/troubleshooting.html#module-externalized-for-browser-compatibility for more details.`)}}),nr=re(Object.freeze(Object.defineProperty({__proto__:null,default:rr},Symbol.toStringTag,{value:"Module"})));var me,ft;function se(){if(ft)return me;ft=1;var e=at,n=Xt(),i=Qt(),a=Zt(),c=tr,f,r;typeof Symbol=="function"&&typeof Symbol.for=="function"?(f=Symbol.for("graceful-fs.queue"),r=Symbol.for("graceful-fs.previous")):(f="___graceful-fs.queue",r="___graceful-fs.previous");function w(){}function h(t,o){Object.defineProperty(t,f,{get:function(){return o}})}var m=w;if(c.debuglog?m=c.debuglog("gfs4"):/\bgfs4\b/i.test(process.env.NODE_DEBUG||"")&&(m=function(){var t=c.format.apply(c,arguments);t="GFS4: "+t.split(/\n/).join(`
GFS4: `),console.error(t)}),!e[f]){var b=V[f]||[];h(e,b),e.close=function(t){function o(l,d){return t.call(e,l,function(g){g||_(),typeof d=="function"&&d.apply(this,arguments)})}return Object.defineProperty(o,r,{value:t}),o}(e.close),e.closeSync=function(t){function o(l){t.apply(e,arguments),_()}return Object.defineProperty(o,r,{value:t}),o}(e.closeSync),/\bgfs4\b/i.test(process.env.NODE_DEBUG||"")&&process.on("exit",function(){m(e[f]),nr.equal(e[f].length,0)})}V[f]||h(V,e[f]),me=v(a(e)),process.env.TEST_GRACEFUL_FS_GLOBAL_PATCH&&!e.__patched&&(me=v(e),e.__patched=!0);function v(t){n(t),t.gracefulify=v,t.createReadStream=Br,t.createWriteStream=Ar;var o=t.readFile;t.readFile=l;function l(F,R,D){return typeof R=="function"&&(D=R,R=null),U(F,R,D);function U(J,B,T,L){return o(J,B,function(q){q&&(q.code==="EMFILE"||q.code==="ENFILE")?u([U,[J,B,T],q,L||Date.now(),Date.now()]):typeof T=="function"&&T.apply(this,arguments)})}}var d=t.writeFile;t.writeFile=g;function g(F,R,D,U){return typeof D=="function"&&(U=D,D=null),J(F,R,D,U);function J(B,T,L,q,W){return d(B,T,L,function(N){N&&(N.code==="EMFILE"||N.code==="ENFILE")?u([J,[B,T,L,q],N,W||Date.now(),Date.now()]):typeof q=="function"&&q.apply(this,arguments)})}}var p=t.appendFile;p&&(t.appendFile=E);function E(F,R,D,U){return typeof D=="function"&&(U=D,D=null),J(F,R,D,U);function J(B,T,L,q,W){return p(B,T,L,function(N){N&&(N.code==="EMFILE"||N.code==="ENFILE")?u([J,[B,T,L,q],N,W||Date.now(),Date.now()]):typeof q=="function"&&q.apply(this,arguments)})}}var S=t.copyFile;S&&(t.copyFile=k);function k(F,R,D,U){return typeof D=="function"&&(U=D,D=0),J(F,R,D,U);function J(B,T,L,q,W){return S(B,T,L,function(N){N&&(N.code==="EMFILE"||N.code==="ENFILE")?u([J,[B,T,L,q],N,W||Date.now(),Date.now()]):typeof q=="function"&&q.apply(this,arguments)})}}var P=t.readdir;t.readdir=Z;var x=/^v[0-5]\./;function Z(F,R,D){typeof R=="function"&&(D=R,R=null);var U=x.test(process.version)?function(T,L,q,W){return P(T,J(T,L,q,W))}:function(T,L,q,W){return P(T,L,J(T,L,q,W))};return U(F,R,D);function J(B,T,L,q){return function(W,N){W&&(W.code==="EMFILE"||W.code==="ENFILE")?u([U,[B,T,L],W,q||Date.now(),Date.now()]):(N&&N.sort&&N.sort(),typeof L=="function"&&L.call(this,W,N))}}}if(process.version.substr(0,4)==="v0.8"){var K=i(t);G=K.ReadStream,te=K.WriteStream}var ee=t.ReadStream;ee&&(G.prototype=Object.create(ee.prototype),G.prototype.open=fe);var M=t.WriteStream;M&&(te.prototype=Object.create(M.prototype),te.prototype.open=jr),Object.defineProperty(t,"ReadStream",{get:function(){return G},set:function(F){G=F},enumerable:!0,configurable:!0}),Object.defineProperty(t,"WriteStream",{get:function(){return te},set:function(F){te=F},enumerable:!0,configurable:!0});var O=G;Object.defineProperty(t,"FileReadStream",{get:function(){return O},set:function(F){O=F},enumerable:!0,configurable:!0});var C=te;Object.defineProperty(t,"FileWriteStream",{get:function(){return C},set:function(F){C=F},enumerable:!0,configurable:!0});function G(F,R){return this instanceof G?(ee.apply(this,arguments),this):G.apply(Object.create(G.prototype),arguments)}function fe(){var F=this;it(F.path,F.flags,F.mode,function(R,D){R?(F.autoClose&&F.destroy(),F.emit("error",R)):(F.fd=D,F.emit("open",D),F.read())})}function te(F,R){return this instanceof te?(M.apply(this,arguments),this):te.apply(Object.create(te.prototype),arguments)}function jr(){var F=this;it(F.path,F.flags,F.mode,function(R,D){R?(F.destroy(),F.emit("error",R)):(F.fd=D,F.emit("open",D))})}function Br(F,R){return new t.ReadStream(F,R)}function Ar(F,R){return new t.WriteStream(F,R)}var Ir=t.open;t.open=it;function it(F,R,D,U){return typeof D=="function"&&(U=D,D=null),J(F,R,D,U);function J(B,T,L,q,W){return Ir(B,T,L,function(N,Qr){N&&(N.code==="EMFILE"||N.code==="ENFILE")?u([J,[B,T,L,q],N,W||Date.now(),Date.now()]):typeof q=="function"&&q.apply(this,arguments)})}}return t}function u(t){m("ENQUEUE",t[0].name,t[1]),e[f].push(t),y()}var s;function _(){for(var t=Date.now(),o=0;o<e[f].length;++o)e[f][o].length>2&&(e[f][o][3]=t,e[f][o][4]=t);y()}function y(){if(clearTimeout(s),s=void 0,e[f].length!==0){var t=e[f].shift(),o=t[0],l=t[1],d=t[2],g=t[3],p=t[4];if(g===void 0)m("RETRY",o.name,l),o.apply(null,l);else if(Date.now()-g>=6e4){m("TIMEOUT",o.name,l);var E=l.pop();typeof E=="function"&&E.call(null,d)}else{var S=Date.now()-p,k=Math.max(p-g,1),P=Math.min(k*1.2,100);S>=P?(m("RETRY",o.name,l),o.apply(null,l.concat([g]))):e[f].push(t)}s===void 0&&(s=setTimeout(y,0))}}return me}var lt;function Y(){return lt||(lt=1,function(e){const n=I().fromCallback,i=se(),a=["access","appendFile","chmod","chown","close","copyFile","fchmod","fchown","fdatasync","fstat","fsync","ftruncate","futimes","lchmod","lchown","link","lstat","mkdir","mkdtemp","open","opendir","readdir","readFile","readlink","realpath","rename","rm","rmdir","stat","symlink","truncate","unlink","utimes","writeFile"].filter(c=>typeof i[c]=="function");Object.assign(e,i),a.forEach(c=>{e[c]=n(i[c])}),e.exists=function(c,f){return typeof f=="function"?i.exists(c,f):new Promise(r=>i.exists(c,r))},e.read=function(c,f,r,w,h,m){return typeof m=="function"?i.read(c,f,r,w,h,m):new Promise((b,v)=>{i.read(c,f,r,w,h,(u,s,_)=>{if(u)return v(u);b({bytesRead:s,buffer:_})})})},e.write=function(c,f,...r){return typeof r[r.length-1]=="function"?i.write(c,f,...r):new Promise((w,h)=>{i.write(c,f,...r,(m,b,v)=>{if(m)return h(m);w({bytesWritten:b,buffer:v})})})},e.readv=function(c,f,...r){return typeof r[r.length-1]=="function"?i.readv(c,f,...r):new Promise((w,h)=>{i.readv(c,f,...r,(m,b,v)=>{if(m)return h(m);w({bytesRead:b,buffers:v})})})},e.writev=function(c,f,...r){return typeof r[r.length-1]=="function"?i.writev(c,f,...r):new Promise((w,h)=>{i.writev(c,f,...r,(m,b,v)=>{if(m)return h(m);w({bytesWritten:b,buffers:v})})})},typeof i.realpath.native=="function"?e.realpath.native=n(i.realpath.native):process.emitWarning("fs.realpath.native is not a function. Is fs being monkey-patched?","Warning","fs-extra-WARN0003")}(Ee)),Ee}const ir=new Proxy({},{get(e,n){throw new Error(`Module "path" has been externalized for browser compatibility. Cannot access "path.${n}" in client code. See https://vite.dev/guide/troubleshooting.html#module-externalized-for-browser-compatibility for more details.`)}}),H=re(Object.freeze(Object.defineProperty({__proto__:null,default:ir},Symbol.toStringTag,{value:"Module"})));var de={},Pe={},yt;function or(){if(yt)return Pe;yt=1;const e=H;return Pe.checkPath=function(i){if(process.platform==="win32"&&/[<>:"|?*]/.test(i.replace(e.parse(i).root,""))){const c=new Error(`Path contains invalid characters: ${i}`);throw c.code="EINVAL",c}},Pe}var mt;function ar(){if(mt)return de;mt=1;const e=Y(),{checkPath:n}=or(),i=a=>{const c={mode:511};return typeof a=="number"?a:X(X({},c),a).mode};return de.makeDir=(a,c)=>$(this,null,function*(){return n(a),e.mkdir(a,{mode:i(c),recursive:!0})}),de.makeDirSync=(a,c)=>(n(a),e.mkdirSync(a,{mode:i(c),recursive:!0})),de}var Oe,dt;function Q(){if(dt)return Oe;dt=1;const e=I().fromPromise,{makeDir:n,makeDirSync:i}=ar(),a=e(n);return Oe={mkdirs:a,mkdirsSync:i,mkdirp:a,mkdirpSync:i,ensureDir:a,ensureDirSync:i},Oe}var xe,ht;function ne(){if(ht)return xe;ht=1;const e=I().fromPromise,n=Y();function i(a){return n.access(a).then(()=>!0).catch(()=>!1)}return xe={pathExists:e(i),pathExistsSync:n.existsSync},xe}var De,wt;function pt(){if(wt)return De;wt=1;const e=Y(),n=I().fromPromise;function i(c,f,r){return $(this,null,function*(){const w=yield e.open(c,"r+");let h=null;try{yield e.futimes(w,f,r)}finally{try{yield e.close(w)}catch(m){h=m}}if(h)throw h})}function a(c,f,r){const w=e.openSync(c,"r+");return e.futimesSync(w,f,r),e.closeSync(w)}return De={utimesMillis:n(i),utimesMillisSync:a},De}var Re,vt;function ae(){if(vt)return Re;vt=1;const e=Y(),n=H,i=I().fromPromise;function a(u,s,_){const y=_.dereference?t=>e.stat(t,{bigint:!0}):t=>e.lstat(t,{bigint:!0});return Promise.all([y(u),y(s).catch(t=>{if(t.code==="ENOENT")return null;throw t})]).then(([t,o])=>({srcStat:t,destStat:o}))}function c(u,s,_){let y;const t=_.dereference?l=>e.statSync(l,{bigint:!0}):l=>e.lstatSync(l,{bigint:!0}),o=t(u);try{y=t(s)}catch(l){if(l.code==="ENOENT")return{srcStat:o,destStat:null};throw l}return{srcStat:o,destStat:y}}function f(u,s,_,y){return $(this,null,function*(){const{srcStat:t,destStat:o}=yield a(u,s,y);if(o){if(m(t,o)){const l=n.basename(u),d=n.basename(s);if(_==="move"&&l!==d&&l.toLowerCase()===d.toLowerCase())return{srcStat:t,destStat:o,isChangingCase:!0};throw new Error("Source and destination must not be the same.")}if(t.isDirectory()&&!o.isDirectory())throw new Error(`Cannot overwrite non-directory '${s}' with directory '${u}'.`);if(!t.isDirectory()&&o.isDirectory())throw new Error(`Cannot overwrite directory '${s}' with non-directory '${u}'.`)}if(t.isDirectory()&&b(u,s))throw new Error(v(u,s,_));return{srcStat:t,destStat:o}})}function r(u,s,_,y){const{srcStat:t,destStat:o}=c(u,s,y);if(o){if(m(t,o)){const l=n.basename(u),d=n.basename(s);if(_==="move"&&l!==d&&l.toLowerCase()===d.toLowerCase())return{srcStat:t,destStat:o,isChangingCase:!0};throw new Error("Source and destination must not be the same.")}if(t.isDirectory()&&!o.isDirectory())throw new Error(`Cannot overwrite non-directory '${s}' with directory '${u}'.`);if(!t.isDirectory()&&o.isDirectory())throw new Error(`Cannot overwrite directory '${s}' with non-directory '${u}'.`)}if(t.isDirectory()&&b(u,s))throw new Error(v(u,s,_));return{srcStat:t,destStat:o}}function w(u,s,_,y){return $(this,null,function*(){const t=n.resolve(n.dirname(u)),o=n.resolve(n.dirname(_));if(o===t||o===n.parse(o).root)return;let l;try{l=yield e.stat(o,{bigint:!0})}catch(d){if(d.code==="ENOENT")return;throw d}if(m(s,l))throw new Error(v(u,_,y));return w(u,s,o,y)})}function h(u,s,_,y){const t=n.resolve(n.dirname(u)),o=n.resolve(n.dirname(_));if(o===t||o===n.parse(o).root)return;let l;try{l=e.statSync(o,{bigint:!0})}catch(d){if(d.code==="ENOENT")return;throw d}if(m(s,l))throw new Error(v(u,_,y));return h(u,s,o,y)}function m(u,s){return s.ino&&s.dev&&s.ino===u.ino&&s.dev===u.dev}function b(u,s){const _=n.resolve(u).split(n.sep).filter(t=>t),y=n.resolve(s).split(n.sep).filter(t=>t);return _.every((t,o)=>y[o]===t)}function v(u,s,_){return`Cannot ${_} '${u}' to a subdirectory of itself, '${s}'.`}return Re={checkPaths:i(f),checkPathsSync:r,checkParentPaths:i(w),checkParentPathsSync:h,isSrcSubdir:b,areIdentical:m},Re}var $e,St;function cr(){if(St)return $e;St=1;const e=Y(),n=H,{mkdirs:i}=Q(),{pathExists:a}=ne(),{utimesMillis:c}=pt(),f=ae();function r(l,d){return $(this,arguments,function*(y,t,o={}){typeof o=="function"&&(o={filter:o}),o.clobber="clobber"in o?!!o.clobber:!0,o.overwrite="overwrite"in o?!!o.overwrite:o.clobber,o.preserveTimestamps&&process.arch==="ia32"&&process.emitWarning(`Using the preserveTimestamps option in 32-bit node is not recommended;
see https://github.com/jprichardson/node-fs-extra/issues/269`,"Warning","fs-extra-WARN0001");const{srcStat:o,destStat:c}=yield we.checkPaths(e,t,"copy",r);if(yield we.checkParentPaths(e,o,t,"copy"),!(yield yt(e,t,r)))return;const u=he.dirname(t);(yield jr(u))||(yield Tr(u)),yield mt(c,e,t,r)})}function yt(e,t,r){return E(this,null,function*(){return r.filter?r.filter(e,t):!0})}function mt(e,t,r,n){return E(this,null,function*(){const o=yield(n.dereference?B.stat:B.lstat)(t);if(o.isDirectory())return Ir(o,e,t,r,n);if(o.isFile()||o.isCharacterDevice()||o.isBlockDevice())return Mr(o,e,t,r,n);if(o.isSymbolicLink())return Ur(e,t,r,n);throw o.isSocket()?new Error(`Cannot copy a socket file: ${t}`):o.isFIFO()?new Error(`Cannot copy a FIFO pipe: ${t}`):new Error(`Unknown file: ${t}`)})}function Mr(e,t,r,n,i){return E(this,null,function*(){if(!t)return dt(e,r,n,i);if(i.overwrite)return yield B.unlink(n),dt(e,r,n,i);if(i.errorOnExist)throw new Error(`'${n}' already exists`)})}function dt(e,t,r,n){return E(this,null,function*(){if(yield B.copyFile(t,r),n.preserveTimestamps){Ar(e.mode)&&(yield Br(r,e.mode));const i=yield B.stat(t);yield Lr(r,i.atime,i.mtime)}return B.chmod(r,e.mode)})}function Ar(e){return(e&128)===0}function Br(e,t){return B.chmod(e,t|128)}function Ir(e,t,r,n,i){return E(this,null,function*(){t||(yield B.mkdir(n));const o=yield B.readdir(r);yield Promise.all(o.map(c=>E(this,null,function*(){const s=he.join(r,c),u=he.join(n,c);if(!(yield yt(s,u,i)))return;const{destStat:a}=yield we.checkPaths(s,u,"copy",i);return mt(a,s,u,i)}))),t||(yield B.chmod(n,e.mode))})}function Ur(e,t,r,n){return E(this,null,function*(){let i=yield B.readlink(t);if(n.dereference&&(i=he.resolve(process.cwd(),i)),!e)return B.symlink(i,r);let o=null;try{o=yield B.readlink(r)}catch(c){if(c.code==="EINVAL"||c.code==="UNKNOWN")return B.symlink(i,r);throw c}if(n.dereference&&(o=he.resolve(process.cwd(),o)),we.isSrcSubdir(i,o))throw new Error(`Cannot copy '${i}' to a subdirectory of itself, '${o}'.`);if(we.isSrcSubdir(o,i))throw new Error(`Cannot overwrite '${o}' with '${i}'.`);return yield B.unlink(r),B.symlink(i,r)})}var Wr=Rr;const U=oe,pe=q,Jr=V.mkdirsSync,zr=st.utimesMillisSync,Se=ue;function qr(e,t,r){typeof r=="function"&&(r={filter:r}),r=r||{},r.clobber="clobber"in r?!!r.clobber:!0,r.overwrite="overwrite"in r?!!r.overwrite:r.clobber,r.preserveTimestamps&&process.arch==="ia32"&&process.emitWarning(`Using the preserveTimestamps option in 32-bit node is not recommended;
see https://github.com/jprichardson/node-fs-extra/issues/269`,"Warning","fs-extra-WARN0001");const{srcStat:g,destStat:p}=yield f.checkPaths(y,t,"copy",o);if(yield f.checkParentPaths(y,g,t,"copy"),!(yield w(y,t,o)))return;const S=n.dirname(t);(yield a(S))||(yield i(S)),yield h(p,y,t,o)})}function w(y,t,o){return $(this,null,function*(){return o.filter?o.filter(y,t):!0})}function h(y,t,o,l){return $(this,null,function*(){const g=yield(l.dereference?e.stat:e.lstat)(t);if(g.isDirectory())return s(g,y,t,o,l);if(g.isFile()||g.isCharacterDevice()||g.isBlockDevice())return m(g,y,t,o,l);if(g.isSymbolicLink())return _(y,t,o,l);throw g.isSocket()?new Error(`Cannot copy a socket file: ${t}`):g.isFIFO()?new Error(`Cannot copy a FIFO pipe: ${t}`):new Error(`Unknown file: ${t}`)})}function m(y,t,o,l,d){return $(this,null,function*(){if(!t)return b(y,o,l,d);if(d.overwrite)return yield e.unlink(l),b(y,o,l,d);if(d.errorOnExist)throw new Error(`'${l}' already exists`)})}function b(y,t,o,l){return $(this,null,function*(){if(yield e.copyFile(t,o),l.preserveTimestamps){v(y.mode)&&(yield u(o,y.mode));const d=yield e.stat(t);yield c(o,d.atime,d.mtime)}return e.chmod(o,y.mode)})}function v(y){return(y&128)===0}function u(y,t){return e.chmod(y,t|128)}function s(y,t,o,l,d){return $(this,null,function*(){t||(yield e.mkdir(l));const g=yield e.readdir(o);yield Promise.all(g.map(p=>$(this,null,function*(){const E=n.join(o,p),S=n.join(l,p);if(!(yield w(E,S,d)))return;const{destStat:P}=yield f.checkPaths(E,S,"copy",d);return h(P,E,S,d)}))),t||(yield e.chmod(l,y.mode))})}function _(y,t,o,l){return $(this,null,function*(){let d=yield e.readlink(t);if(l.dereference&&(d=n.resolve(process.cwd(),d)),!y)return e.symlink(d,o);let g=null;try{g=yield e.readlink(o)}catch(p){if(p.code==="EINVAL"||p.code==="UNKNOWN")return e.symlink(d,o);throw p}if(l.dereference&&(g=n.resolve(process.cwd(),g)),f.isSrcSubdir(d,g))throw new Error(`Cannot copy '${d}' to a subdirectory of itself, '${g}'.`);if(f.isSrcSubdir(g,d))throw new Error(`Cannot overwrite '${g}' with '${d}'.`);return yield e.unlink(o),e.symlink(d,o)})}return $e=r,$e}var qe,_t;function ur(){if(_t)return qe;_t=1;const e=se(),n=H,i=Q().mkdirsSync,a=pt().utimesMillisSync,c=ae();function f(p,E,S){typeof S=="function"&&(S={filter:S}),S=S||{},S.clobber="clobber"in S?!!S.clobber:!0,S.overwrite="overwrite"in S?!!S.overwrite:S.clobber,S.preserveTimestamps&&process.arch==="ia32"&&process.emitWarning(`Using the preserveTimestamps option in 32-bit node is not recommended;
see https://github.com/jprichardson/node-fs-extra/issues/269`,"Warning","fs-extra-WARN0002");const{srcStat:n,destStat:i}=Se.checkPathsSync(e,t,"copy",r);if(Se.checkParentPathsSync(e,n,t,"copy"),r.filter&&!r.filter(e,t))return;const o=pe.dirname(t);return U.existsSync(o)||Jr(o),ht(i,e,t,r)}function ht(e,t,r,n){const o=(n.dereference?U.statSync:U.lstatSync)(t);if(o.isDirectory())return Qr(o,e,t,r,n);if(o.isFile()||o.isCharacterDevice()||o.isBlockDevice())return Gr(o,e,t,r,n);if(o.isSymbolicLink())return tn(e,t,r,n);throw o.isSocket()?new Error(`Cannot copy a socket file: ${t}`):o.isFIFO()?new Error(`Cannot copy a FIFO pipe: ${t}`):new Error(`Unknown file: ${t}`)}function Gr(e,t,r,n,i){return t?Yr(e,r,n,i):wt(e,r,n,i)}function Yr(e,t,r,n){if(n.overwrite)return U.unlinkSync(r),wt(e,t,r,n);if(n.errorOnExist)throw new Error(`'${r}' already exists`)}function wt(e,t,r,n){return U.copyFileSync(t,r),n.preserveTimestamps&&Vr(e.mode,t,r),Ie(r,e.mode)}function Vr(e,t,r){return Xr(e)&&Hr(r,e),Kr(t,r)}function Xr(e){return(e&128)===0}function Hr(e,t){return Ie(e,t|128)}function Ie(e,t){return U.chmodSync(e,t)}function Kr(e,t){const r=U.statSync(e);return zr(t,r.atime,r.mtime)}function Qr(e,t,r,n,i){return t?pt(r,n,i):Zr(e.mode,r,n,i)}function Zr(e,t,r,n){return U.mkdirSync(r),pt(t,r,n),Ie(r,e)}function pt(e,t,r){U.readdirSync(e).forEach(n=>en(n,e,t,r))}function en(e,t,r,n){const i=pe.join(t,e),o=pe.join(r,e);if(n.filter&&!n.filter(i,o))return;const{destStat:c}=Se.checkPathsSync(i,o,"copy",n);return ht(c,i,o,n)}function tn(e,t,r,n){let i=U.readlinkSync(t);if(n.dereference&&(i=pe.resolve(process.cwd(),i)),e){let o;try{o=U.readlinkSync(r)}catch(c){if(c.code==="EINVAL"||c.code==="UNKNOWN")return U.symlinkSync(i,r);throw c}if(n.dereference&&(o=pe.resolve(process.cwd(),o)),Se.isSrcSubdir(i,o))throw new Error(`Cannot copy '${i}' to a subdirectory of itself, '${o}'.`);if(Se.isSrcSubdir(o,i))throw new Error(`Cannot overwrite '${o}' with '${i}'.`);return rn(i,r)}else return U.symlinkSync(i,r)}function rn(e,t){return U.unlinkSync(t),U.symlinkSync(e,t)}var nn=qr;const on=x.fromPromise;var Ue={copy:on(Wr),copySync:nn};const St=oe,cn=x.fromCallback;function an(e,t){St.rm(e,{recursive:!0,force:!0},t)}function sn(e){St.rmSync(e,{recursive:!0,force:!0})}var Fe={remove:cn(an),removeSync:sn};const un=x.fromPromise,vt=I,_t=q,gt=V,bt=Fe,Et=un(function(t){return E(this,null,function*(){let r;try{r=yield vt.readdir(t)}catch(n){return gt.mkdirs(t)}return Promise.all(r.map(n=>bt.remove(_t.join(t,n))))})});function $t(e){let t;try{t=vt.readdirSync(e)}catch(r){return gt.mkdirsSync(e)}t.forEach(r=>{r=_t.join(e,r),bt.removeSync(r)})}var fn={emptyDirSync:$t,emptydirSync:$t,emptyDir:Et,emptydir:Et};const ln=x.fromPromise,kt=q,H=I,Ft=V;function yn(e){return E(this,null,function*(){let t;try{t=yield H.stat(e)}catch(i){}if(t&&t.isFile())return;const r=kt.dirname(e);let n=null;try{n=yield H.stat(r)}catch(i){if(i.code==="ENOENT"){yield Ft.mkdirs(r),yield H.writeFile(e,"");return}else throw i}n.isDirectory()?yield H.writeFile(e,""):yield H.readdir(r)})}function mn(e){let t;try{t=H.statSync(e)}catch(n){}if(t&&t.isFile())return;const r=kt.dirname(e);try{H.statSync(r).isDirectory()||H.readdirSync(r)}catch(n){if(n&&n.code==="ENOENT")Ft.mkdirsSync(r);else throw n}H.writeFileSync(e,"")}var dn={createFile:ln(yn),createFileSync:mn};const hn=x.fromPromise,Pt=q,Q=I,Ot=V,{pathExists:wn}=re,{areIdentical:xt}=ue;function pn(e,t){return E(this,null,function*(){let r;try{r=yield Q.lstat(t)}catch(c){}let n;try{n=yield Q.lstat(e)}catch(c){throw c.message=c.message.replace("lstat","ensureLink"),c}if(r&&xt(n,r))return;const i=Pt.dirname(t);(yield wn(i))||(yield Ot.mkdirs(i)),yield Q.link(e,t)})}function Sn(e,t){let r;try{r=Q.lstatSync(t)}catch(o){}try{const o=Q.lstatSync(e);if(r&&xt(o,r))return}catch(o){throw o.message=o.message.replace("lstat","ensureLink"),o}const n=Pt.dirname(t);return Q.existsSync(n)||Ot.mkdirsSync(n),Q.linkSync(e,t)}var vn={createLink:hn(pn),createLinkSync:Sn};const Z=q,ve=I,{pathExists:_n}=re,gn=x.fromPromise;function bn(e,t){return E(this,null,function*(){if(Z.isAbsolute(e)){try{yield ve.lstat(e)}catch(o){throw o.message=o.message.replace("lstat","ensureSymlink"),o}return{toCwd:e,toDst:e}}const r=Z.dirname(t),n=Z.join(r,e);if(yield _n(n))return{toCwd:n,toDst:e};try{yield ve.lstat(e)}catch(o){throw o.message=o.message.replace("lstat","ensureSymlink"),o}return{toCwd:e,toDst:Z.relative(r,e)}})}function En(e,t){if(Z.isAbsolute(e)){if(!ve.existsSync(e))throw new Error("absolute srcpath does not exist");return{toCwd:e,toDst:e}}const r=Z.dirname(t),n=Z.join(r,e);if(ve.existsSync(n))return{toCwd:n,toDst:e};if(!ve.existsSync(e))throw new Error("relative srcpath does not exist");return{toCwd:e,toDst:Z.relative(r,e)}}var $n={symlinkPaths:gn(bn),symlinkPathsSync:En};const Dt=I,kn=x.fromPromise;function Fn(e,t){return E(this,null,function*(){if(t)return t;let r;try{r=yield Dt.lstat(e)}catch(n){return"file"}return r&&r.isDirectory()?"dir":"file"})}function Pn(e,t){if(t)return t;let r;try{r=Dt.lstatSync(e)}catch(n){return"file"}return r&&r.isDirectory()?"dir":"file"}var On={symlinkType:kn(Fn),symlinkTypeSync:Pn};const xn=x.fromPromise,Ct=q,X=I,{mkdirs:Dn,mkdirsSync:Cn}=V,{symlinkPaths:Nn,symlinkPathsSync:Tn}=$n,{symlinkType:jn,symlinkTypeSync:Ln}=On,{pathExists:Rn}=re,{areIdentical:Nt}=ue;function Mn(e,t,r){return E(this,null,function*(){let n;try{n=yield X.lstat(t)}catch(s){}if(n&&n.isSymbolicLink()){const[s,u]=yield Promise.all([X.stat(e),X.stat(t)]);if(Nt(s,u))return}const i=yield Nn(e,t);e=i.toDst;const o=yield jn(i.toCwd,r),c=Ct.dirname(t);return(yield Rn(c))||(yield Dn(c)),X.symlink(e,t,o)})}function An(e,t,r){let n;try{n=X.lstatSync(t)}catch(s){}if(n&&n.isSymbolicLink()){const s=X.statSync(e),u=X.statSync(t);if(Nt(s,u))return}const i=Tn(e,t);e=i.toDst,r=Ln(i.toCwd,r);const o=Ct.dirname(t);return X.existsSync(o)||Cn(o),X.symlinkSync(e,t,r)}var Bn={createSymlink:xn(Mn),createSymlinkSync:An};const{createFile:Tt,createFileSync:jt}=dn,{createLink:Lt,createLinkSync:Rt}=vn,{createSymlink:Mt,createSymlinkSync:At}=Bn;var In={createFile:Tt,createFileSync:jt,ensureFile:Tt,ensureFileSync:jt,createLink:Lt,createLinkSync:Rt,ensureLink:Lt,ensureLinkSync:Rt,createSymlink:Mt,createSymlinkSync:At,ensureSymlink:Mt,ensureSymlinkSync:At};function Un(e,{EOL:t=`
`,finalEOL:r=!0,replacer:n=null,spaces:i}={}){const o=r?t:"";return JSON.stringify(e,n,i).replace(/\n/g,t)+o}function Wn(e){return Buffer.isBuffer(e)&&(e=e.toString("utf8")),e.replace(/^\uFEFF/,"")}var We={stringify:Un,stripBom:Wn};let fe;try{fe=oe}catch(e){fe=Qe}const Pe=x,{stringify:Bt,stripBom:It}=We;function Jn(r){return E(this,arguments,function*(e,t={}){typeof t=="string"&&(t={encoding:t});const n=t.fs||fe,i="throws"in t?t.throws:!0;let o=yield Pe.fromCallback(n.readFile)(e,t);o=It(o);let c;try{c=JSON.parse(o,t?t.reviver:null)}catch(s){if(i)throw s.message=`${e}: ${s.message}`,s;return null}return c})}const zn=Pe.fromPromise(Jn);function qn(e,t={}){typeof t=="string"&&(t={encoding:t});const r=t.fs||fe,n="throws"in t?t.throws:!0;try{let i=r.readFileSync(e,t);return i=It(i),JSON.parse(i,t.reviver)}catch(i){if(n)throw i.message=`${e}: ${i.message}`,i;return null}}function Gn(n,i){return E(this,arguments,function*(e,t,r={}){const o=r.fs||fe,c=Bt(t,r);yield Pe.fromCallback(o.writeFile)(e,c,r)})}const Yn=Pe.fromPromise(Gn);function Vn(e,t,r={}){const n=r.fs||fe,i=Bt(t,r);return n.writeFileSync(e,i,r)}var Xn={readFile:zn,readFileSync:qn,writeFile:Yn,writeFileSync:Vn};const Oe=Xn;var Hn={readJson:Oe.readFile,readJsonSync:Oe.readFileSync,writeJson:Oe.writeFile,writeJsonSync:Oe.writeFileSync};const Kn=x.fromPromise,Je=I,Ut=q,Wt=V,Qn=re.pathExists;function Zn(e,t,r="utf-8"){return E(this,null,function*(){const n=Ut.dirname(e);return(yield Qn(n))||(yield Wt.mkdirs(n)),Je.writeFile(e,t,r)})}function ei(e,...t){const r=Ut.dirname(e);Je.existsSync(r)||Wt.mkdirsSync(r),Je.writeFileSync(e,...t)}var ze={outputFile:Kn(Zn),outputFileSync:ei};const{stringify:ti}=We,{outputFile:ri}=ze;function ni(n,i){return E(this,arguments,function*(e,t,r={}){const o=ti(t,r);yield ri(e,o,r)})}var ii=ni;const{stringify:oi}=We,{outputFileSync:ci}=ze;function ai(e,t,r){const n=oi(t,r);ci(e,n,r)}var si=ai;const ui=x.fromPromise,W=Hn;W.outputJson=ui(ii),W.outputJsonSync=si,W.outputJSON=W.outputJson,W.outputJSONSync=W.outputJsonSync,W.writeJSON=W.writeJson,W.writeJSONSync=W.writeJsonSync,W.readJSON=W.readJson,W.readJSONSync=W.readJsonSync;var fi=W;const li=I,Jt=q,{copy:yi}=Ue,{remove:zt}=Fe,{mkdirp:mi}=V,{pathExists:di}=re,qt=ue;function hi(n,i){return E(this,arguments,function*(e,t,r={}){const o=r.overwrite||r.clobber||!1,{srcStat:c,isChangingCase:s=!1}=yield qt.checkPaths(e,t,"move",r);yield qt.checkParentPaths(e,c,t,"move");const u=Jt.dirname(t);return Jt.parse(u).root!==u&&(yield mi(u)),wi(e,t,o,s)})}function wi(e,t,r,n){return E(this,null,function*(){if(!n){if(r)yield zt(t);else if(yield di(t))throw new Error("dest already exists.")}try{yield li.rename(e,t)}catch(i){if(i.code!=="EXDEV")throw i;yield pi(e,t,r)}})}function pi(e,t,r){return E(this,null,function*(){return yield yi(e,t,{overwrite:r,errorOnExist:!0,preserveTimestamps:!0}),zt(e)})}var Si=hi;const Gt=oe,qe=q,vi=Ue.copySync,Yt=Fe.removeSync,_i=V.mkdirpSync,Vt=ue;function gi(e,t,r){r=r||{};const n=r.overwrite||r.clobber||!1,{srcStat:i,isChangingCase:o=!1}=Vt.checkPathsSync(e,t,"move",r);return Vt.checkParentPathsSync(e,i,t,"move"),bi(t)||_i(qe.dirname(t)),Ei(e,t,n,o)}function bi(e){const t=qe.dirname(e);return qe.parse(t).root===t}function Ei(e,t,r,n){if(n)return Ge(e,t,r);if(r)return Yt(t),Ge(e,t,r);if(Gt.existsSync(t))throw new Error("dest already exists.");return Ge(e,t,r)}function Ge(e,t,r){try{Gt.renameSync(e,t)}catch(n){if(n.code!=="EXDEV")throw n;return $i(e,t,r)}}function $i(e,t,r){return vi(e,t,{overwrite:r,errorOnExist:!0,preserveTimestamps:!0}),Yt(e)}var ki=gi;const Fi=x.fromPromise;var Pi={move:Fi(Si),moveSync:ki},Oi=z(z(z(z(z(z(z(z(z(z({},I),Ue),fn),In),fi),V),Pi),ze),re),Fe);const le=ie(Oi);var Ye={exports:{}},Ve={exports:{}};const xi=new Proxy({},{get(e,t){throw new Error(`Module "buffer" has been externalized for browser compatibility. Cannot access "buffer.${t}" in client code. See https://vite.dev/guide/troubleshooting.html#module-externalized-for-browser-compatibility for more details.`)}}),Di=ee(Object.freeze(Object.defineProperty({__proto__:null,default:xi},Symbol.toStringTag,{value:"Module"})));/*! safe-buffer. MIT License. Feross Aboukhadijeh <https://feross.org/opensource> */(function(e,t){var r=Di,n=r.Buffer;function i(c,s){for(var u in c)s[u]=c[u]}n.from&&n.alloc&&n.allocUnsafe&&n.allocUnsafeSlow?e.exports=r:(i(r,t),t.Buffer=o);function o(c,s,u){return n(c,s,u)}o.prototype=Object.create(n.prototype),i(n,o),o.from=function(c,s,u){if(typeof c=="number")throw new TypeError("Argument must not be a number");return n(c,s,u)},o.alloc=function(c,s,u){if(typeof c!="number")throw new TypeError("Argument must be a number");var S=n(c);return s!==void 0?typeof u=="string"?S.fill(s,u):S.fill(s):S.fill(0),S},o.allocUnsafe=function(c){if(typeof c!="number")throw new TypeError("Argument must be a number");return n(c)},o.allocUnsafeSlow=function(c){if(typeof c!="number")throw new TypeError("Argument must be a number");return r.SlowBuffer(c)}})(Ve,Ve.exports);var Ci=Ve.exports,Xe=65536,Ni=4294967295;function Ti(){throw new Error(`Secure random number generation is not supported by this browser.
Use Chrome, Firefox or Internet Explorer 11`)}var ji=Ci.Buffer,xe=J.crypto||J.msCrypto;xe&&xe.getRandomValues?Ye.exports=Li:Ye.exports=Ti;function Li(e,t){if(e>Ni)throw new RangeError("requested too many random bytes");var r=ji.allocUnsafe(e);if(e>0)if(e>Xe)for(var n=0;n<e;n+=Xe)xe.getRandomValues(r.slice(n,n+Xe));else xe.getRandomValues(r);return typeof t=="function"?process.nextTick(function(){t(null,r)}):r}var Ri=Ye.exports,Mi=Ri,Xt=16,G=Gi(),Ai=new RegExp('(\\\\)?"@__(F|R|D|M|S|A|U|I|B|L)-'+G+'-(\\d+)__@"',"g"),Bi=/\{\s*\[native code\]\s*\}/g,Ii=/function.*?\(/,Ui=/.*?=>.*?/,Wi=/[<>\/\u2028\u2029]/g,Ji=["*","async"],zi={"<":"\\u003C",">":"\\u003E","/":"\\u002F","\u2028":"\\u2028","\u2029":"\\u2029"};function qi(e){return zi[e]}function Gi(){for(var e=Mi(Xt),t="",r=0;r<Xt;++r)t+=e[r].toString(16);return t}function Yi(e){var t=[];for(var r in e)typeof e[r]=="function"&&t.push(r);for(var n=0;n<t.length;n++)delete e[t[n]]}var Vi=function e(t,r){r||(r={}),(typeof r=="number"||typeof r=="string")&&(r={space:r});var n=[],i=[],o=[],c=[],s=[],u=[],S=[],a=[],l=[],y=[];function f(_,w){if(r.ignoreFunction&&Yi(w),!w&&w!==void 0&&w!==BigInt(0))return w;var m=this[_],p=typeof m;if(p==="object"){if(m instanceof RegExp)return"@__R-"+G+"-"+(i.push(m)-1)+"__@";if(m instanceof Date)return"@__D-"+G+"-"+(o.push(m)-1)+"__@";if(m instanceof Map)return"@__M-"+G+"-"+(c.push(m)-1)+"__@";if(m instanceof Set)return"@__S-"+G+"-"+(s.push(m)-1)+"__@";if(m instanceof Array){var Y=m.filter(function(){return!0}).length!==m.length;if(Y)return"@__A-"+G+"-"+(u.push(m)-1)+"__@"}if(m instanceof URL)return"@__L-"+G+"-"+(y.push(m)-1)+"__@"}return p==="function"?"@__F-"+G+"-"+(n.push(m)-1)+"__@":p==="undefined"?"@__U-"+G+"-"+(S.push(m)-1)+"__@":p==="number"&&!isNaN(m)&&!isFinite(m)?"@__I-"+G+"-"+(a.push(m)-1)+"__@":p==="bigint"?"@__B-"+G+"-"+(l.push(m)-1)+"__@":w}function d(_){var w=_.toString();if(Bi.test(w))throw new TypeError("Serializing native function: "+_.name);if(Ii.test(w)||Ui.test(w))return w;var m=w.indexOf("("),p=w.substr(0,m).trim().split(" ").filter(function(me){return me.length>0}),Y=p.filter(function(me){return Ji.indexOf(me)===-1});return Y.length>0?(p.indexOf("async")>-1?"async ":"")+"function"+(p.join("").indexOf("*")>-1?"*":"")+w.substr(m):w}if(r.ignoreFunction&&typeof t=="function"&&(t=void 0),t===void 0)return String(t);var v;return r.isJSON&&!r.space?v=JSON.stringify(t):v=JSON.stringify(t,r.isJSON?null:f,r.space),typeof v!="string"?String(v):(r.unsafe!==!0&&(v=v.replace(Wi,qi)),n.length===0&&i.length===0&&o.length===0&&c.length===0&&s.length===0&&u.length===0&&S.length===0&&a.length===0&&l.length===0&&y.length===0?v:v.replace(Ai,function(_,w,m,p){if(w)return _;if(m==="D")return'new Date("'+o[p].toISOString()+'")';if(m==="R")return"new RegExp("+e(i[p].source)+', "'+i[p].flags+'")';if(m==="M")return"new Map("+e(Array.from(c[p].entries()),r)+")";if(m==="S")return"new Set("+e(Array.from(s[p].values()),r)+")";if(m==="A")return"Array.prototype.slice.call("+e(Object.assign({length:u[p].length},u[p]),r)+")";if(m==="U")return"undefined";if(m==="I")return a[p];if(m==="B")return'BigInt("'+l[p]+'")';if(m==="L")return"new URL("+e(y[p].toString(),r)+")";var Y=n[p];return d(Y)}))};const Xi=ie(Vi),Hi=e=>new Function(`return ${e}`)(),ye=void 0,Ki=encodeURIComponent,He=ne.resolve(Te.tmpdir(),"idmp"),De=e=>ne.resolve(He,"v1/node",Ki(e)),Qi=(e,t,r)=>E(this,null,function*(){if(!e)return;const n=De(e);le.ensureFileSync(n),le.outputFileSync(n,Xi({t:Date.now(),a:r,d:t}))}),Zi=e=>E(this,null,function*(){if(!e)return ye;const t=De(e);let r;try{r=Hi(le.readFileSync(t,"utf-8"))}catch(c){}if(r===ye)return ye;const{t:n,a:i,d:o}=r;return Date.now()-n>i?(le.removeSync(t),ye):o}),eo=(e,t="")=>{const r=(n,i,o)=>{n=`${t}_${n}`;const c=Ne(o);return e(n,()=>E(this,null,function*(){const s=yield Zi(n);if(s!==ye)return s;const u=yield i();return u!==ye&&Qi(n,u,c.maxAge),u}),o)};return r.flush=n=>{e.flush(n),le.removeSync(De(n))},r.flushAll=()=>{e.flushAll(),le.removeSync(He)},r};D.cacheDir=He,D.default=eo,D.getCachePath=De,Object.defineProperties(D,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}})});
see https://github.com/jprichardson/node-fs-extra/issues/269`,"Warning","fs-extra-WARN0002");const{srcStat:k,destStat:P}=c.checkPathsSync(p,E,"copy",S);if(c.checkParentPathsSync(p,k,E,"copy"),S.filter&&!S.filter(p,E))return;const x=n.dirname(E);return e.existsSync(x)||i(x),r(P,p,E,S)}function r(p,E,S,k){const x=(k.dereference?e.statSync:e.lstatSync)(E);if(x.isDirectory())return y(x,p,E,S,k);if(x.isFile()||x.isCharacterDevice()||x.isBlockDevice())return w(x,p,E,S,k);if(x.isSymbolicLink())return d(p,E,S,k);throw x.isSocket()?new Error(`Cannot copy a socket file: ${E}`):x.isFIFO()?new Error(`Cannot copy a FIFO pipe: ${E}`):new Error(`Unknown file: ${E}`)}function w(p,E,S,k,P){return E?h(p,S,k,P):m(p,S,k,P)}function h(p,E,S,k){if(k.overwrite)return e.unlinkSync(S),m(p,E,S,k);if(k.errorOnExist)throw new Error(`'${S}' already exists`)}function m(p,E,S,k){return e.copyFileSync(E,S),k.preserveTimestamps&&b(p.mode,E,S),s(S,p.mode)}function b(p,E,S){return v(p)&&u(S,p),_(E,S)}function v(p){return(p&128)===0}function u(p,E){return s(p,E|128)}function s(p,E){return e.chmodSync(p,E)}function _(p,E){const S=e.statSync(p);return a(E,S.atime,S.mtime)}function y(p,E,S,k,P){return E?o(S,k,P):t(p.mode,S,k,P)}function t(p,E,S,k){return e.mkdirSync(S),o(E,S,k),s(S,p)}function o(p,E,S){e.readdirSync(p).forEach(k=>l(k,p,E,S))}function l(p,E,S,k){const P=n.join(E,p),x=n.join(S,p);if(k.filter&&!k.filter(P,x))return;const{destStat:Z}=c.checkPathsSync(P,x,"copy",k);return r(Z,P,x,k)}function d(p,E,S,k){let P=e.readlinkSync(E);if(k.dereference&&(P=n.resolve(process.cwd(),P)),p){let x;try{x=e.readlinkSync(S)}catch(Z){if(Z.code==="EINVAL"||Z.code==="UNKNOWN")return e.symlinkSync(P,S);throw Z}if(k.dereference&&(x=n.resolve(process.cwd(),x)),c.isSrcSubdir(P,x))throw new Error(`Cannot copy '${P}' to a subdirectory of itself, '${x}'.`);if(c.isSrcSubdir(x,P))throw new Error(`Cannot overwrite '${x}' with '${P}'.`);return g(P,S)}else return e.symlinkSync(P,S)}function g(p,E){return e.unlinkSync(E),e.symlinkSync(p,E)}return qe=f,qe}var Ce,gt;function Ne(){if(gt)return Ce;gt=1;const e=I().fromPromise;return Ce={copy:e(cr()),copySync:ur()},Ce}var Te,Et;function he(){if(Et)return Te;Et=1;const e=se(),n=I().fromCallback;function i(c,f){e.rm(c,{recursive:!0,force:!0},f)}function a(c){e.rmSync(c,{recursive:!0,force:!0})}return Te={remove:n(i),removeSync:a},Te}var Me,bt;function sr(){if(bt)return Me;bt=1;const e=I().fromPromise,n=Y(),i=H,a=Q(),c=he(),f=e(function(h){return $(this,null,function*(){let m;try{m=yield n.readdir(h)}catch(b){return a.mkdirs(h)}return Promise.all(m.map(b=>c.remove(i.join(h,b))))})});function r(w){let h;try{h=n.readdirSync(w)}catch(m){return a.mkdirsSync(w)}h.forEach(m=>{m=i.join(w,m),c.removeSync(m)})}return Me={emptyDirSync:r,emptydirSync:r,emptyDir:f,emptydir:f},Me}var Le,kt;function fr(){if(kt)return Le;kt=1;const e=I().fromPromise,n=H,i=Y(),a=Q();function c(r){return $(this,null,function*(){let w;try{w=yield i.stat(r)}catch(b){}if(w&&w.isFile())return;const h=n.dirname(r);let m=null;try{m=yield i.stat(h)}catch(b){if(b.code==="ENOENT"){yield a.mkdirs(h),yield i.writeFile(r,"");return}else throw b}m.isDirectory()?yield i.writeFile(r,""):yield i.readdir(h)})}function f(r){let w;try{w=i.statSync(r)}catch(m){}if(w&&w.isFile())return;const h=n.dirname(r);try{i.statSync(h).isDirectory()||i.readdirSync(h)}catch(m){if(m&&m.code==="ENOENT")a.mkdirsSync(h);else throw m}i.writeFileSync(r,"")}return Le={createFile:e(c),createFileSync:f},Le}var je,Ft;function lr(){if(Ft)return je;Ft=1;const e=I().fromPromise,n=H,i=Y(),a=Q(),{pathExists:c}=ne(),{areIdentical:f}=ae();function r(h,m){return $(this,null,function*(){let b;try{b=yield i.lstat(m)}catch(_){}let v;try{v=yield i.lstat(h)}catch(_){throw _.message=_.message.replace("lstat","ensureLink"),_}if(b&&f(v,b))return;const u=n.dirname(m);(yield c(u))||(yield a.mkdirs(u)),yield i.link(h,m)})}function w(h,m){let b;try{b=i.lstatSync(m)}catch(s){}try{const s=i.lstatSync(h);if(b&&f(s,b))return}catch(s){throw s.message=s.message.replace("lstat","ensureLink"),s}const v=n.dirname(m);return i.existsSync(v)||a.mkdirsSync(v),i.linkSync(h,m)}return je={createLink:e(r),createLinkSync:w},je}var Be,Pt;function yr(){if(Pt)return Be;Pt=1;const e=H,n=Y(),{pathExists:i}=ne(),a=I().fromPromise;function c(r,w){return $(this,null,function*(){if(e.isAbsolute(r)){try{yield n.lstat(r)}catch(v){throw v.message=v.message.replace("lstat","ensureSymlink"),v}return{toCwd:r,toDst:r}}const h=e.dirname(w),m=e.join(h,r);if(yield i(m))return{toCwd:m,toDst:r};try{yield n.lstat(r)}catch(v){throw v.message=v.message.replace("lstat","ensureSymlink"),v}return{toCwd:r,toDst:e.relative(h,r)}})}function f(r,w){if(e.isAbsolute(r)){if(!n.existsSync(r))throw new Error("absolute srcpath does not exist");return{toCwd:r,toDst:r}}const h=e.dirname(w),m=e.join(h,r);if(n.existsSync(m))return{toCwd:m,toDst:r};if(!n.existsSync(r))throw new Error("relative srcpath does not exist");return{toCwd:r,toDst:e.relative(h,r)}}return Be={symlinkPaths:a(c),symlinkPathsSync:f},Be}var Ae,Ot;function mr(){if(Ot)return Ae;Ot=1;const e=Y(),n=I().fromPromise;function i(c,f){return $(this,null,function*(){if(f)return f;let r;try{r=yield e.lstat(c)}catch(w){return"file"}return r&&r.isDirectory()?"dir":"file"})}function a(c,f){if(f)return f;let r;try{r=e.lstatSync(c)}catch(w){return"file"}return r&&r.isDirectory()?"dir":"file"}return Ae={symlinkType:n(i),symlinkTypeSync:a},Ae}var Ie,xt;function dr(){if(xt)return Ie;xt=1;const e=I().fromPromise,n=H,i=Y(),{mkdirs:a,mkdirsSync:c}=Q(),{symlinkPaths:f,symlinkPathsSync:r}=yr(),{symlinkType:w,symlinkTypeSync:h}=mr(),{pathExists:m}=ne(),{areIdentical:b}=ae();function v(s,_,y){return $(this,null,function*(){let t;try{t=yield i.lstat(_)}catch(g){}if(t&&t.isSymbolicLink()){const[g,p]=yield Promise.all([i.stat(s),i.stat(_)]);if(b(g,p))return}const o=yield f(s,_);s=o.toDst;const l=yield w(o.toCwd,y),d=n.dirname(_);return(yield m(d))||(yield a(d)),i.symlink(s,_,l)})}function u(s,_,y){let t;try{t=i.lstatSync(_)}catch(g){}if(t&&t.isSymbolicLink()){const g=i.statSync(s),p=i.statSync(_);if(b(g,p))return}const o=r(s,_);s=o.toDst,y=h(o.toCwd,y);const l=n.dirname(_);return i.existsSync(l)||c(l),i.symlinkSync(s,_,y)}return Ie={createSymlink:e(v),createSymlinkSync:u},Ie}var Ue,Dt;function hr(){if(Dt)return Ue;Dt=1;const{createFile:e,createFileSync:n}=fr(),{createLink:i,createLinkSync:a}=lr(),{createSymlink:c,createSymlinkSync:f}=dr();return Ue={createFile:e,createFileSync:n,ensureFile:e,ensureFileSync:n,createLink:i,createLinkSync:a,ensureLink:i,ensureLinkSync:a,createSymlink:c,createSymlinkSync:f,ensureSymlink:c,ensureSymlinkSync:f},Ue}var Je,Rt;function We(){if(Rt)return Je;Rt=1;function e(i,{EOL:a=`
`,finalEOL:c=!0,replacer:f=null,spaces:r}={}){const w=c?a:"";return JSON.stringify(i,f,r).replace(/\n/g,a)+w}function n(i){return Buffer.isBuffer(i)&&(i=i.toString("utf8")),i.replace(/^\uFEFF/,"")}return Je={stringify:e,stripBom:n},Je}var ze,$t;function wr(){if($t)return ze;$t=1;let e;try{e=se()}catch(v){e=at}const n=I(),{stringify:i,stripBom:a}=We();function c(s){return $(this,arguments,function*(v,u={}){typeof u=="string"&&(u={encoding:u});const _=u.fs||e,y="throws"in u?u.throws:!0;let t=yield n.fromCallback(_.readFile)(v,u);t=a(t);let o;try{o=JSON.parse(t,u?u.reviver:null)}catch(l){if(y)throw l.message=`${v}: ${l.message}`,l;return null}return o})}const f=n.fromPromise(c);function r(v,u={}){typeof u=="string"&&(u={encoding:u});const s=u.fs||e,_="throws"in u?u.throws:!0;try{let y=s.readFileSync(v,u);return y=a(y),JSON.parse(y,u.reviver)}catch(y){if(_)throw y.message=`${v}: ${y.message}`,y;return null}}function w(_,y){return $(this,arguments,function*(v,u,s={}){const t=s.fs||e,o=i(u,s);yield n.fromCallback(t.writeFile)(v,o,s)})}const h=n.fromPromise(w);function m(v,u,s={}){const _=s.fs||e,y=i(u,s);return _.writeFileSync(v,y,s)}return ze={readFile:f,readFileSync:r,writeFile:h,writeFileSync:m},ze}var Ge,qt;function pr(){if(qt)return Ge;qt=1;const e=wr();return Ge={readJson:e.readFile,readJsonSync:e.readFileSync,writeJson:e.writeFile,writeJsonSync:e.writeFileSync},Ge}var Ye,Ct;function Ve(){if(Ct)return Ye;Ct=1;const e=I().fromPromise,n=Y(),i=H,a=Q(),c=ne().pathExists;function f(w,h,m="utf-8"){return $(this,null,function*(){const b=i.dirname(w);return(yield c(b))||(yield a.mkdirs(b)),n.writeFile(w,h,m)})}function r(w,...h){const m=i.dirname(w);n.existsSync(m)||a.mkdirsSync(m),n.writeFileSync(w,...h)}return Ye={outputFile:e(f),outputFileSync:r},Ye}var Xe,Nt;function vr(){if(Nt)return Xe;Nt=1;const{stringify:e}=We(),{outputFile:n}=Ve();function i(r,w){return $(this,arguments,function*(a,c,f={}){const h=e(c,f);yield n(a,h,f)})}return Xe=i,Xe}var He,Tt;function Sr(){if(Tt)return He;Tt=1;const{stringify:e}=We(),{outputFileSync:n}=Ve();function i(a,c,f){const r=e(c,f);n(a,r,f)}return He=i,He}var Ke,Mt;function _r(){if(Mt)return Ke;Mt=1;const e=I().fromPromise,n=pr();return n.outputJson=e(vr()),n.outputJsonSync=Sr(),n.outputJSON=n.outputJson,n.outputJSONSync=n.outputJsonSync,n.writeJSON=n.writeJson,n.writeJSONSync=n.writeJsonSync,n.readJSON=n.readJson,n.readJSONSync=n.readJsonSync,Ke=n,Ke}var Qe,Lt;function gr(){if(Lt)return Qe;Lt=1;const e=Y(),n=H,{copy:i}=Ne(),{remove:a}=he(),{mkdirp:c}=Q(),{pathExists:f}=ne(),r=ae();function w(s,_){return $(this,arguments,function*(b,v,u={}){const y=u.overwrite||u.clobber||!1,{srcStat:t,isChangingCase:o=!1}=yield r.checkPaths(b,v,"move",u);yield r.checkParentPaths(b,t,v,"move");const l=n.dirname(v);return n.parse(l).root!==l&&(yield c(l)),h(b,v,y,o)})}function h(b,v,u,s){return $(this,null,function*(){if(!s){if(u)yield a(v);else if(yield f(v))throw new Error("dest already exists.")}try{yield e.rename(b,v)}catch(_){if(_.code!=="EXDEV")throw _;yield m(b,v,u)}})}function m(b,v,u){return $(this,null,function*(){return yield i(b,v,{overwrite:u,errorOnExist:!0,preserveTimestamps:!0}),a(b)})}return Qe=w,Qe}var Ze,jt;function Er(){if(jt)return Ze;jt=1;const e=se(),n=H,i=Ne().copySync,a=he().removeSync,c=Q().mkdirpSync,f=ae();function r(v,u,s){s=s||{};const _=s.overwrite||s.clobber||!1,{srcStat:y,isChangingCase:t=!1}=f.checkPathsSync(v,u,"move",s);return f.checkParentPathsSync(v,y,u,"move"),w(u)||c(n.dirname(u)),h(v,u,_,t)}function w(v){const u=n.dirname(v);return n.parse(u).root===u}function h(v,u,s,_){if(_)return m(v,u,s);if(s)return a(u),m(v,u,s);if(e.existsSync(u))throw new Error("dest already exists.");return m(v,u,s)}function m(v,u,s){try{e.renameSync(v,u)}catch(_){if(_.code!=="EXDEV")throw _;return b(v,u,s)}}function b(v,u,s){return i(v,u,{overwrite:s,errorOnExist:!0,preserveTimestamps:!0}),a(v)}return Ze=r,Ze}var et,Bt;function br(){if(Bt)return et;Bt=1;const e=I().fromPromise;return et={move:e(gr()),moveSync:Er()},et}var tt,At;function kr(){return At||(At=1,tt=X(X(X(X(X(X(X(X(X(X({},Y()),Ne()),sr()),hr()),_r()),Q()),br()),Ve()),ne()),he())),tt}var Fr=kr();const ce=oe(Fr);var we={exports:{}},pe={exports:{}};const Pr=new Proxy({},{get(e,n){throw new Error(`Module "buffer" has been externalized for browser compatibility. Cannot access "buffer.${n}" in client code. See https://vite.dev/guide/troubleshooting.html#module-externalized-for-browser-compatibility for more details.`)}}),Or=re(Object.freeze(Object.defineProperty({__proto__:null,default:Pr},Symbol.toStringTag,{value:"Module"})));/*! safe-buffer. MIT License. Feross Aboukhadijeh <https://feross.org/opensource> */var It;function xr(){return It||(It=1,function(e,n){var i=Or,a=i.Buffer;function c(r,w){for(var h in r)w[h]=r[h]}a.from&&a.alloc&&a.allocUnsafe&&a.allocUnsafeSlow?e.exports=i:(c(i,n),n.Buffer=f);function f(r,w,h){return a(r,w,h)}f.prototype=Object.create(a.prototype),c(a,f),f.from=function(r,w,h){if(typeof r=="number")throw new TypeError("Argument must not be a number");return a(r,w,h)},f.alloc=function(r,w,h){if(typeof r!="number")throw new TypeError("Argument must be a number");var m=a(r);return w!==void 0?typeof h=="string"?m.fill(w,h):m.fill(w):m.fill(0),m},f.allocUnsafe=function(r){if(typeof r!="number")throw new TypeError("Argument must be a number");return a(r)},f.allocUnsafeSlow=function(r){if(typeof r!="number")throw new TypeError("Argument must be a number");return i.SlowBuffer(r)}}(pe,pe.exports)),pe.exports}var Ut;function Dr(){if(Ut)return we.exports;Ut=1;var e=65536,n=4294967295;function i(){throw new Error(`Secure random number generation is not supported by this browser.
Use Chrome, Firefox or Internet Explorer 11`)}var a=xr().Buffer,c=V.crypto||V.msCrypto;c&&c.getRandomValues?we.exports=f:we.exports=i;function f(r,w){if(r>n)throw new RangeError("requested too many random bytes");var h=a.allocUnsafe(r);if(r>0)if(r>e)for(var m=0;m<r;m+=e)c.getRandomValues(h.slice(m,m+e));else c.getRandomValues(h);return typeof w=="function"?process.nextTick(function(){w(null,h)}):h}return we.exports}var rt,Jt;function Rr(){if(Jt)return rt;Jt=1;var e=Dr(),n=16,i=v(),a=new RegExp('(\\\\)?"@__(F|R|D|M|S|A|U|I|B|L)-'+i+'-(\\d+)__@"',"g"),c=/\{\s*\[native code\]\s*\}/g,f=/function.*?\(/,r=/.*?=>.*?/,w=/[<>\/\u2028\u2029]/g,h=["*","async"],m={"<":"\\u003C",">":"\\u003E","/":"\\u002F","\u2028":"\\u2028","\u2029":"\\u2029"};function b(s){return m[s]}function v(){for(var s=e(n),_="",y=0;y<n;++y)_+=s[y].toString(16);return _}function u(s){var _=[];for(var y in s)typeof s[y]=="function"&&_.push(y);for(var t=0;t<_.length;t++)delete s[_[t]]}return rt=function s(_,y){y||(y={}),(typeof y=="number"||typeof y=="string")&&(y={space:y});var t=[],o=[],l=[],d=[],g=[],p=[],E=[],S=[],k=[],P=[];function x(ee,M){if(y.ignoreFunction&&u(M),!M&&M!==void 0&&M!==BigInt(0))return M;var O=this[ee],C=typeof O;if(C==="object"){if(O instanceof RegExp)return"@__R-"+i+"-"+(o.push(O)-1)+"__@";if(O instanceof Date)return"@__D-"+i+"-"+(l.push(O)-1)+"__@";if(O instanceof Map)return"@__M-"+i+"-"+(d.push(O)-1)+"__@";if(O instanceof Set)return"@__S-"+i+"-"+(g.push(O)-1)+"__@";if(O instanceof Array){var G=O.filter(function(){return!0}).length!==O.length;if(G)return"@__A-"+i+"-"+(p.push(O)-1)+"__@"}if(O instanceof URL)return"@__L-"+i+"-"+(P.push(O)-1)+"__@"}return C==="function"?"@__F-"+i+"-"+(t.push(O)-1)+"__@":C==="undefined"?"@__U-"+i+"-"+(E.push(O)-1)+"__@":C==="number"&&!isNaN(O)&&!isFinite(O)?"@__I-"+i+"-"+(S.push(O)-1)+"__@":C==="bigint"?"@__B-"+i+"-"+(k.push(O)-1)+"__@":M}function Z(ee){var M=ee.toString();if(c.test(M))throw new TypeError("Serializing native function: "+ee.name);if(f.test(M)||r.test(M))return M;var O=M.indexOf("("),C=M.substr(0,O).trim().split(" ").filter(function(fe){return fe.length>0}),G=C.filter(function(fe){return h.indexOf(fe)===-1});return G.length>0?(C.indexOf("async")>-1?"async ":"")+"function"+(C.join("").indexOf("*")>-1?"*":"")+M.substr(O):M}if(y.ignoreFunction&&typeof _=="function"&&(_=void 0),_===void 0)return String(_);var K;return y.isJSON&&!y.space?K=JSON.stringify(_):K=JSON.stringify(_,y.isJSON?null:x,y.space),typeof K!="string"?String(K):(y.unsafe!==!0&&(K=K.replace(w,b)),t.length===0&&o.length===0&&l.length===0&&d.length===0&&g.length===0&&p.length===0&&E.length===0&&S.length===0&&k.length===0&&P.length===0?K:K.replace(a,function(ee,M,O,C){if(M)return ee;if(O==="D")return'new Date("'+l[C].toISOString()+'")';if(O==="R")return"new RegExp("+s(o[C].source)+', "'+o[C].flags+'")';if(O==="M")return"new Map("+s(Array.from(d[C].entries()),y)+")";if(O==="S")return"new Set("+s(Array.from(g[C].values()),y)+")";if(O==="A")return"Array.prototype.slice.call("+s(Object.assign({length:p[C].length},p[C]),y)+")";if(O==="U")return"undefined";if(O==="I")return S[C];if(O==="B")return'BigInt("'+k[C]+'")';if(O==="L")return"new URL("+s(P[C].toString(),y)+")";var G=t[C];return Z(G)}))},rt}var $r=Rr();const qr=oe($r),Cr=e=>new Function(`return ${e}`)(),ue=void 0,Nr=encodeURIComponent,nt=ie.resolve(ge.tmpdir(),"idmp"),ve=e=>ie.resolve(nt,"v1/node",Nr(e)),Tr=(e,n,i)=>$(this,null,function*(){if(!e)return;const a=ve(e);ce.ensureFileSync(a),ce.outputFileSync(a,qr({t:Date.now(),a:i,d:n}))}),Mr=e=>$(this,null,function*(){if(!e)return ue;const n=ve(e);let i;try{i=Cr(ce.readFileSync(n,"utf-8"))}catch(r){}if(i===ue)return ue;const{t:a,a:c,d:f}=i;return Date.now()-a>c?(ce.removeSync(n),ue):f}),Lr=(e,n="")=>{const i=(a,c,f)=>{a=`${n}_${a}`;const r=_e(f);return e(a,()=>$(this,null,function*(){const w=yield Mr(a);if(w!==ue)return w;const h=yield c();return h!==ue&&Tr(a,h,r.maxAge),h}),f)};return i.flush=a=>{e.flush(a),ce.removeSync(ve(a))},i.flushAll=()=>{e.flushAll(),ce.removeSync(nt)},i};j.cacheDir=nt,j.default=Lr,j.getCachePath=ve,Object.defineProperties(j,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}})});

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc