titanfiber 1.0.119 → 1.0.123

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,6 @@
1
+ {
2
+ "t": {},
3
+ "globals": {},
4
+ "shortNamesToGlobals": {},
5
+ "itemsInOrder": []
6
+ }
package/build.pkg.js CHANGED
@@ -1 +1 @@
1
- var e=function(e){var n,r=!1;return function(){return r||(r=!0,n=e.apply(this,arguments)),n}},n=e((function(){return process.argv.slice(2)})),r=n,u=function(e){return"string"==typeof e},i=function(e){const n=[];let r="",u="outside",i=!1;for(let o=0;o<e.length;o++){const s=e[o];switch(u){case"outside":'"'===s?i?(r+=s,i=!1):u="insideQuote":"\\"===s?i=!0:" "===s?(r.length>0&&(n.push(r),r=""),i=!1):(r+=s,i=!1);break;case"insideQuote":'"'!==s||i?"\\"!==s||i?(r+=s,i=!1):i=!0:u="outside"}}return r.length>0&&n.push(r),n},o=function(e){for(var n,o=[],s=!1,c=(n=null==(a=e)?r():u(a)?i(a):a).length,l=0;l<c;l++){var a=n[l];if(!s){var f=a[0];let e;if("-"===f)if("-"===a[1]){if(2===a.length){s=!0;continue}e=2}else e=1;else"/"===f&&(e=1);if(e){var p,d,h=a.slice(e),v=h.indexOf("=");if(-1!==v)p=h.slice(0,v),d=h.slice(v+1);else{p=h;var m=n[l+1];null==m||"-"===m[0]?d=!0:(d=m,l++)}o[p]=d;continue}}o.push(a)}return o},s=o,c=s,l=c,a=function(e){return require(e)},f=function(e){return!!e.startsWith("node:")||a("node:module").isBuiltin(e)},p=function(e){return e.startsWith(".")},d=function(e){return Array.isArray(e)},h=function(e){return class extends e{constructor(e,n){super(e,n);var r=this.constructor.name;r&&(this.name=r)}}},v=h(globalThis.Error),m=class extends v{constructor(e,n){super(e??"Unexpected value",n)}},g=e((function(){return"undefined"==typeof window})),y=function(e){return require("node:"+e)},w=function(n){return e((()=>y(n)))},b=w("util"),x=function(e,n){return n||(n={}),null==n.colors&&(n.colors=!0),b().inspect(e,n)},E=function(e,n){return null!=e&&e.constructor===n},F=function(e){return E(e,Object)},A=function(e,n){return n<0?e.length+n:n},O=A,S=function(e,n,r,u){return void 0!==n&&(null===n||0===n?n=void 0:(n=O(e,n),u&&0==u.inclusiveStart&&n++)),void 0!==r&&(null===r||r===e.length?r=void 0:(r=O(e,r),u&&u.inclusiveEnd&&r++)),[n,r]},_=function(e,n,r,u,i,o){if(r||null!=u){[r,u]=S(e,r,u,o);var s=e.slice(r,u),c=n(s);return i?i(c,r,u,s,e):c}return n(e)},I=function(e,n,r,u,i){return _(e,n,r,u,((n,r,u)=>(void 0!==r?e.slice(0,r):"")+(n||"")+(void 0!==u?e.slice(u):"")),i)},j=E,k=function(e){return j(e,RegExp)},N=function(e){return d(e)?e:[e]},q=function(e){return e instanceof Promise},T=function(e,n){var r=e;return q(r)?r.then(n):n(r)},C=function(e){return"function"==typeof e},R=function(e){return C(e)&&null==e.prototype},M=R,P=function(e){return function(){return e.apply(this,arguments)}},L=function(e,n){var r;return r=n?function(){this.super=n;var r=e.apply(this,arguments);return T(r,(()=>(delete this.super,r)))}:M(e)?P(e):e,r._isConstructor=!0,r},D=function(e,n){return e._isConstructor?e:L(e,n)},W=function(){return this},K=function(e,n,r){var u=new v(e,r);return n&&Object.assign(u,n),u},B=class extends v{constructor(e,n){super(e??"Not yet implemented",n)}},U=function(e,n,r,u){var i=e[n];if(void 0===i){var o=r;!1!==u&&C(o)&&(o=o(e,n)),e[n]=i=o}return i},Y=function(e,n,r,u){return e||(e={}),U(e,n,r,u),e},z=function(e,n){return Y(e,"fromFn",n,!1)},J=function(e,n){return new B(e,z(n,J))},G=function(e){var n=typeof e;return"object"!==n&&"function"!==n||null===e},Q=function(e){return!G(e)},V=function(e,n,r){return Object.defineProperty(e,n,{value:r,writable:!0,enumerable:!1,configurable:!0}),r},$=V,H=function(e,n){Object.defineProperty(e,"name",{value:n,configurable:!0}),$(e,"displayName",n)},X=H,Z=function(e,n){return Object.assign(e,n)},ee=g()?require("util").inspect.custom:Symbol("Display"),ne=function(e,n){e.prototype[ee]=n},re=function(e,n,r,i,o,s){s||(s={}),u(n)&&(n=null);var c,l,a,f=r;if(f)if(d(f)){if([l,a]=f,l)if(d(l)){if(!n)throw K("Bare args array for instanceFn is only valid when extending a class.");var p=l;l=null,c=L((function(){this.super.apply(this,p)}),n)}else l=D(l)}else c=D(f,n);var h=s.bareFn;s.singleton&&(h=function(){return null==g.default&&(g.default=new g(...arguments)),g.default});var v,m=l||c||n||W;function g(){if(!new.target&&h&&!(this instanceof g))return h.apply(this,arguments);var e=this;return T(m.apply(e,arguments),(r=>{if(r&&Q(r)&&(e=r,l)){if(!new.target)throw J('Prototype repair is NYI for class instantiation without "new".');if(!n)throw J("instanceFn is not yet supported when extendsClass is null.");var u=Object.getPrototypeOf(this);Object.getPrototypeOf(e)!==u&&Object.setPrototypeOf(e,u)}return a?T(a.apply(e,arguments),(()=>e)):e}))}return e&&X(g,e),i?(v=i,n&&Object.setPrototypeOf(i,n.prototype)):v=n?Object.create(n.prototype):{},$(v,"constructor",g),g.prototype=v,o&&Z(g,o),s.display&&ne(g,s.display),s.implements&&N(s.implements).forEach((e=>e(g))),g},te=function(e,n){Object.defineProperty(e,n,{enumerable:!1})},ue=te,ie=function(e,n,r,u,i){var o=Symbol();return re(e,Function,[function(){var e=function(){return e[o].apply(this,arguments)};return e},function(){var e=n.apply(this,arguments);if(!e)throw new Error("Constructor must return a function.");this[o]=e,ue(this,o)}],r,u,i)},oe=function(e,n,r,u){return n=null==n?0:A(e,n),r=null==r?e.length:A(e,r),u&&(0==u.inclusiveStart&&n++,u.inclusiveEnd&&r++),[n,r]},se=function(e,n,r,u){var i=n;if([r,u]=oe(e,r,u),C(i))for(var o=r;o<u;o++)e[o]=i(o,e);else e.fill(i,r,u);return e},ce=function(e,n){var r=new Array(e||0);return arguments.length>1&&se(r,n),r},le=function(e,n){return ce(n.length,(r=>e[n[r]]))},ae=function(e,n){return e[n]},fe=function(e,n,r){return e[n]=r},pe=function(e,n,r){var u=e;return C(u)?u.apply(r,n):u},de=function(e,n,r,u,i){u||(u=ae);var o=u(e,n);return void 0===o&&(o=pe(r,[e,n]),i||(i=fe),i(e,n,o)),o},he=function(e,n){return e.get(n)},ve=function(e,n,r){return e.set(n,r)},me=function(e,n,r){return de(e,n,r,he,ve)},ge=class{constructor(){this.store=new Map}get(e,n){return me(this.store,e,n)}remove(e){return this.store.delete(e)}delete(e){return this.remove(e)}},ye=function(e,n){return e.push(n),e},we=ye,be=function(e){var n=e;return Array.isArray(n)?n:Array.from(n)},xe=Symbol("Value"),Ee=function(){return{}},Fe=function(e){return[e.slice(0,-1),e[e.length-1]]},Ae=Fe,Oe=function(e,n,r,u,i,o){r||(r=ae),null==u&&(u=Ee),null==i&&(i=fe),null==o&&(o=r);for(var[s,c]=Ae(n),l=e,a=s.length,f=0;f<a;f++){var p=s[f],d=r(l,p);if(void 0===d){if(!u)return;d=de(l,p,u,r,i)}l=d}if(o)return o(l,c,i)},Se=function(e,n,r,u,i,o){return Oe(e,n,u,i,o,((e,n)=>de(e,n,r,u,o)))},_e=function(){return new Map},Ie=function(e,n,r){return Se(e,n,r,he,_e,ve)},je=function(e,n){return delete e[n],e},ke=function(e,n,r,u){return Oe(e,n,r,!1,!1,u||je)},Ne=function(e,n){return e.delete(n)},qe=function(e,n){return ke(e,n,he,Ne)},Te=class{constructor(){this.store=new Map}get(e,n){return e=we(be(e),xe),Ie(this.store,e,n)}remove(e){return e=we(be(e),xe),qe(this.store,e)}delete(e){return this.remove(e)}},Ce=ie("MemoizedFunction",(function(e,n){if(this.base=e,null!=n)if(1===(n=N(n)).length){this.cache=new ge;var r=n[0];this._cacheKeyFormatter=e=>e[r]}else this.cache=new Te,this._cacheKeyFormatter=e=>le(e,n);else this.cache=new Te,this._cacheKeyFormatter=e=>e;var u=this;return function(){var n=u._cacheKeyFormatter(arguments);return u.cache.get(n,(()=>e.apply(this,arguments)))}}),{remove(e){return this.cache.remove(this._cacheKeyFormatter(e))}}),Re=function(e,n){return new Ce(e,n)},Me=function(e){return new Set(e)},Pe=function(e){var n={};if(e){var r=Me(e);r.has("g")&&(n.global=!0),r.has("i")&&(n.caseInsensitive=!0),r.has("y")&&(n.sticky=!0)}return n},Le=function(e){var n="";return e.global&&(n+="g"),(e.caseInsensitive||0==e.caseSensitive)&&(n+="i"),e.sticky&&(n+="y"),n},De=function(e,n){var r=Pe(e);return Le(Object.assign(r,n))},We=function(e,n){var r=n,i=void 0;return u(r)?i=r:F(r)&&(i=De(e.flags,r)),new RegExp(e,i)},Ke=function(e,n){return We(e,e.flags+n)},Be=function(e){return Ke(e,"g")},Ue=Re((function(e){return e.global?e:Be(e)}),0),Ye=function(e){var n=e;return null==n?void 0:u(n)?n:Le(n)},ze=function(e,n){return new RegExp(e,Ye(n))},Je=function(e){return e.replace(/[-[\]{}()*+!<=:?.\/\\^$|#\s,]/g,"\\$&")},Ge=function(e,n){return ze(Je(e),n)},Qe=function(e,n,r,i,o,s){return I(e,(function(e){return e.replaceAll?(k(n)&&(n=Ue(n)),e.replaceAll(n,r)):(n=u(n)?Ge(n,"g"):Ue(n),this.replace(n,r))}),i,o,s)},Ve=function(e,n,r){return Qe(e,n,(r??"\\")+n)},$e=function(e,n,r){return null==n&&(n='"'),!1!==r&&(e=Ve(e,n,r)),n+e+n},He=function(e){return $e(e,'"')},Xe=F,Ze=function(e){return Xe(e)?sn(e):String(e)},en=function(e,n){return n||(n=nn),"["+e.reduce((function(e,r){return e+n(r)+", "}),"").slice(0,-2)+"]"},nn=function(e){return u(e)?He(e):d(e)?en(e):Ze(e)},rn=function(e){return Reflect.ownKeys(e)},tn=function(e,n){return(n?rn:Object.keys)(e)},un=function(e,n,r){tn(e,r).forEach(((r,u,i)=>n(r,e[r],u,i)))},on=function(e,n,r,u){var i=null!=r?r:"";return un(e,(function(){i=n.call(this,i,...arguments)}),u),i},sn=function(e,n){return n||(n=nn),"{"+on(e,(function(e,r,u){return e+r+":"+n(u)+", "}),"",!0).slice(0,-2)+"}"},cn=function(e,n){return null==n&&(n=1),n<=0?"[object Object]":sn(e,(e=>an(e,n-1)))},ln=function(e,n){return null==n&&(n=1),n<=0?"[object Array]":en(e,(e=>an(e,n-1)))},an=function(e,n){return void 0===e?"undefined":null===e?"null":g()?x(e,n):F(e)?cn(e,maxNumLevels):d(e)?ln(e,maxNumLevels):Ze(e)},fn=function(e,n,r,u){if(0===arguments.length)return new m("Unexpected value received");u||(u={});var i,{expected:o}=u;return i=o?"Received "+an(e)+", expected one of "+an(o):"Unexpected value received: "+an(e),r&&(i+=' for "'+r+'"'),null!=n&&(i+=" (index "+n+")"),u.fromFn||(u.fromFn=fn),new m(i,u)},pn=h(globalThis.TypeError),dn=function(e){return null==e?e:e.constructor},hn=function(e,n,r,u){if(0===arguments.length)return new pn("Unexpected type received");u||(u={});var i,{type:o,expected:s}=u;return null==o&&(o=dn(e)),o&&o.name&&(o=o.name),s?(s.name&&(s=s.name),i="Expected "+s+", received "):i="Unexpected type received (",i+=o,null!=e&&(i+=" ("+an(e)+")"),s||(i+=")"),r&&(i+=' for "'+r+'"'),null!=n&&(i+=" (index "+n+")"),u.fromFn||(u.fromFn=hn),new pn(i,u)},vn=function(e){var n=e.stdio;if(n){if(!d(n)){if(!u(n))throw hn(n,"stdio");if("pipe"===n)n=["pipe","pipe","pipe"];else if("inherit"===n)n=["inherit","inherit","inherit"];else if("ignore"===n)n=["ignore","ignore","ignore"];else{if("overlapped"!==n)throw fn(n,"stdio");n=["overlapped","overlapped","overlapped"]}e.stdio=n}}else n=e.stdio=[null,null,null];return n},mn=function(e,n){var r=n.length;e.length=r;for(var u=0;u<r;u++)e[u]=n[u];return e},gn=function(e){return function(){return!e.apply(this,arguments)}},yn=function(e,n){return mn(e,e.filter(gn(n)))},wn=function(e){return yn(e,(e=>null==e))},bn=w("child_process"),xn=e((function(){return"win32"===process.platform})),En=function(e,n,r){if(r||(r={}),n(e))throw e;if(r.nullOnErr&&(r.err=null),void 0!==r.err)return r.err;if(r.onErr)return r.onErr(e,e.stderr);throw e},Fn=function(e,n,r){r||(r={}),r.dir&&(r.cwd=r.dir);var u=vn(r);if(null==u[0]){var i=r.allowInput,o=r.input;if(i&&o)throw K("allowInput (user) and input (programmatic) cannot be used simultaneously for synchronous child processes.");i&&(u[0]="inherit")}if(null==u[1]){var s=r.captureOutput??!1,c=r.showOutput;if(s&&c)throw K("captureOutput and showOutput cannot be used simultaneously for synchronous child processes.");s?u[1]="pipe":(null==c&&(c=!0),u[1]=c?"inherit":"ignore")}if(null==u[2]){var l=r.captureErr??!1,a=r.showErr;if(l&&a)throw K("captureErr and showErr cannot be used simultaneously for synchronous child processes.");l?u[2]="pipe":(null==a&&(a=!0),u[2]=a?"inherit":"ignore")}r.encoding||(r.encoding="utf8"),n&&wn(n);try{var f=bn().execFileSync(e,n,r);null!=f&&(f=f.trim());var p=r.map??r.mapFn;return p&&(f=p(f)),f}catch(e){if(xn())return En(e,(e=>"ENOENT"===e.code),r);throw e}},An=function(e,n){return n||(n={}),null==n.captureOutput&&(n.captureOutput=!1),n.shell=!0,n.filterExtensions=!1,Fn("npm",e,n)},On=function(e,n,r){return An(["install",e,n?"-g":null],r)},Sn=w("path"),_n=function(e,n){var r=Sn().resolve;return n?r(n,e):r(e)},In=function(e){return require(_n(e))},jn=class{constructor(){this.store={}}get(e,n){return U(this.store,e,n)}remove(e){return delete this.store[e]}delete(e){return this.remove(e)}},kn=new jn,Nn=w("module"),qn=function(e){return e.endsWith("\\node_modules")||(e+="\\node_modules"),Nn().createRequire(e)},Tn=function(e,n){return kn.get(e,(()=>qn(e)))(n)},Cn=function(e,n,r){return Object.keys(n).forEach((u=>U(e,u,n[u],r))),e},Rn=function(e,n,r){return n?Cn(e,n,r):e},Mn=function(e,n){return e.endsWith(n)?e.substring(0,e.length-n.length):e},Pn=function(e){return e[e.length-1]},Ln=A,Dn=function(e,n,r){return e=We(e,{global:!0}),null!=r&&(n=Ln(r,n)),e.lastIndex=n,e},Wn=function(e,n,r){return e=null!=r?Dn(e,r,n):Ue(e),Array.from(n.matchAll(e))},Kn=function(e,n,r){return null!=r&&(n=n.slice(0,r)),Pn(Wn(e,n))||null},Bn=function(e,n){var r=Kn(e,n);return r&&n.length===r.index+r[0].length?r:null},Un=function(e,n){var r=Bn(n,e);return r?e.slice(0,r.index):e},Yn=function(e,n){if(u(n))return Mn(e,n);if(k(n))return Un(e,n);throw hn(n,1)},zn=Yn,Jn=function(e,n){return[e.slice(0,n),e.slice(n)]},Gn=function(e){e=zn(e.trim(),";");var n=Math.max(e.lastIndexOf(";"),e.lastIndexOf("\n"));return Jn(e,n+1)},Qn=function(e,n){return e.startsWith(n)?e:n+e},Vn=function(e){var[n,r]=Gn(e);return n+Qn(r.trim(),"return ")},$n=function(e){return vt("node-repl-await").processTopLevelAwait(e)},Hn=function(e){return $n(e)??e},Xn=Qe,Zn=function(e,n){if(u(n))return e.endsWith(e);if(k(n))return!!Bn(n,e);throw hn(n,1,"matchThis")},er=/\/|\\/,nr=function(e){return Zn(e,er)?e:e+"/"},rr=function(e,n){return""===e?e:(null==n&&(n=!0),e=Xn(e,"\\","/"),n?nr(e):e)},tr=function(){return process.mainModule?.filename??null},ur=function(e){return e.charAt(0).toLowerCase()+e.slice(1)},ir=function(e){return e.split(".")[0]},or=function(e){return Sn().win32.basename(e)},sr=function(e){return ir(or(e))},cr=function(e,n,r,u){e||(e=tr()??"_console.js");var i=ur(sr(e));return n&&(i+="_repl"),i+(r&&u?.dynamic?".dypkg.json":".pkg.js")},lr=function(e,n){return e=Sn().dirname(e),!1===n?e:nr(e)},ar=function(e,n,r,u){var i,o=cr(e,n,r,u);return i=e?lr(e):"./",_n(i+o)},fr=function(e){return'require("'+rr(ar(),!1)+'");\n'+e},pr=function(e,n){return Qe(e,n,"")},dr=function(e,n){return n.forEach((n=>e=pr(e,n))),e},hr=function(e){return dr(e,["\r","\n"])},vr=function(e,n){return vt("astring").generate(e,n)},mr=function(e,n){return e.stack=n+"\n"+e.stack,e},gr=function(e,n,r){r||(r={}),!1!==n&&(r.sourceType="module"),null==r.allowAwaitOutsideFunction&&(r.allowAwaitOutsideFunction=!0);var u=vt("acorn-node");try{return u.parse(e,r)}catch(n){throw mr(n,"Acorn parsing error: "+e)}},yr=function(e,n,r){return vr(gr(e,n,r))},wr=function(e){return hr(yr(e))},br=function(e,n,r){return(n||r)&&(n||(n={}),r&&Rn(n,r),n.ensureReturn&&(e=Vn(e)),n.topLevelAwait&&(e=Hn(e)),n.useTitan&&(e=fr(e)),n.keepAlive&&(e="\nsetInterval(()=>{}, 100000);\n"+e),(n.logErrors||n.keepAlive)&&(e="process.on('uncaughtException', console.error);\nprocess.on('unhandledRejection', console.error);\n"+e),n.inline&&(e=wr(e))),e},xr=function(e){return u(e)?e:Ze(e)},Er=function(e){var n=e.indexOf("{");return-1===n||e.slice(0,n).includes("=>")},Fr=function(e,n,r,u,i){return _(e,n,r,u,((n,r)=>null===n?null:(n.input=e,void 0!==r&&(n.index+=r),n)),i)},Ar=function(e,n){return e.splice(e.length,0,...n),n},Or=function(e,n){return Ar(e,n),e},Sr=Or,_r=class extends Array{constructor(e,n,r,u,i){if(-1===n)throw K("RegexResult index cannot be -1. For empty result, use bare null.");if(null==e)throw K("RegexResult matchString cannot be null. For empty result, use bare null.");super(),this[0]=e,u&&Sr(this,u),this.index=n,this.input=r,i&&(this.groups=i)}fromParts(e){var n=e;return new _r(n.match,n.index,n.input,n.captures,n.groups)}},Ir=function(e,n,r,u,i){return new _r(e,n,r,u,i)},jr=function(e,n,r,u,i){return-1===n||null==e?null:Ir(e,n,r,u,i)},kr=pr,Nr=function(e,n){return We(e,kr(e.flags,n))},qr=function(e){return Nr(e,"g")},Tr=Re((function(e){return e.global?qr(e):e}),0),Cr=function(e,n,r){return(e=null!=r?Dn(e,r,n):Tr(e)).exec(n)},Rr=function(e,n,r,i,o){return Fr(e,(e=>{if(u(n)){var r=e.indexOf(n);return jr(n,r,e)}return Cr(n,e)}),r,i,o)},Mr=function(e){return e.index+e[0].length},Pr=function(e,n){var r=Rr(e,n);return null===r[0]?null:e.slice(Mr(r))},Lr=function(e,n){return e.startsWith(n)?e.substring(n.length):e},Dr=function(e,n){var r=Cr(e,n);return r&&0===r.index?r:null},Wr=function(e,n){var r=Dr(n,e);return r?e.slice(r[0].length):e},Kr=function(e,n){if(u(n))return Lr(e,n);if(k(n))return Wr(e,n);throw hn(n,1)},Br=Kr,Ur=function(e){var n=Pr(e,"=>").trim();return Br(zn(n,"}"),"{")},Yr=function(e){return Pr(e,"{").slice(0,-1)},zr=function(e){var n=xr(e);return Er(n)?Ur(n):Yr(n)},Jr=function(e){return null==e?"":u(e)?e:C(e)?zr(e):String(e)},Gr=function(e,n){var r=n?.basic?null:{topLevelAwait:!0,useTitan:!0},u=br(Jr(e),n,r);return Fn("node",["-e",u],n)},Qr=function(e,n,r,u){var i="Required argument";return r&&(i+=' "'+r+'"'),null!=n&&(i+=" (index "+n+")"),i+=" missing",arguments.length>0&&(i+=" (received "+an(e)+")"),K(i,null,z(u,Qr))},Vr=function(e,n,r){if(null==e)throw Qr(e,n,r,{fromFn:Vr});return e},$r=function(e,n){return process.kill(e,Vr(n,0,"signalName"))},Hr=function(e){return $r(e,"SIGINT")},Xr=function(){return Hr(process.pid)},Zr=Xr,et=function(e){if("Y"===(e=e.toUpperCase()))return!0;if("N"===e)return!1;throw fn(e,0,"char")},nt=function(e){null==e&&(e="Are you sure? [y/n]: "),process.stdout.write(e);var n=Gr((function(){const e=process.stdin,n=process.stdout;e.setRawMode(!0),e.setEncoding("utf8"),e.on("data",(e=>{var r=e.toUpperCase();"Y"===r||"N"===r?(n.write(e),process.exit(0)):""===e&&(n.write("^C"),process.exit(0))}))}),{basic:!0,stdio:["inherit","pipe"]});if("^C"===n)throw process.stdout.write(n),Zr(),K("Prompt was cancelled via interrupt.");return console.log(n),et(n)},rt=function(e){return d(e)?e:u(e)?e.split("."):[e]},tt=function(e,n,r,u,i,o){var s=r;return Oe(e,n,u,i,o,((e,n,r)=>r(e,n,pe(s))))},ut=function(e,n){var r=n,u=globalThis.config;u||(u=globalThis.config={});var i,o=rt(e);return o.length>1?i=tt(u,o,r):(i=pe(r),u[o[0]]=i),i},it=function(e,n){return ut("node.require.customDirs",(r=>(r||(r=[]),!1!==n&&(e.endsWith("node_modules")||(e+="\\node_modules")),r.includes(e)||r.push(e),r))),e},ot=it,st=Oe,ct=function(e){var n=globalThis.config;if(n){var r=rt(e);return r.length>1?st(n,r):n[r[0]]}},lt=function(e,n,r){if(null!=e)return e;var u=ct(n);return null!=u?u:r},at=w("fs"),ft=function(e){return!!at().lstatSync(e,{throwIfNoEntry:!1})},pt=function(e){var n=lr(e,!1);return ft(n)||(n!==e&&pt(n),at().mkdirSync(n)),e},dt=function(e){return pt(e),at().mkdirSync(e),e},ht=function(e){return ft(e)?e:dt(e)},vt=function(e,n){if(f(e))return require(e);if(p(e))return In(e);try{return require(e)}catch(e){}var r=__dirname,u=process.mainModule?.path;if(u!==r)try{return Tn(u,e)}catch(e){}var i=process.cwd();if(i!==u&&i!==r)try{return Tn(i,e)}catch(e){}var o=ct("node.require.customDirs");if(o)for(var s of o)try{return Tn(s,e)}catch(e){}var c=lt(n?.autoInstall,"node.require.autoInstall"),l=lt(n?.promptInstall,"node.require.promptInstall",!0);if(c||l){var a=c||l;!0===a&&(a="./node_modules"),a=_n(a);var d=!1;if(c?(d=!0,console.log('Auto-installing "'+e+'" from npm to "'+a+'"...')):(d=nt('Npm package "'+e+'" is required. Install now? (Y/N) '))&&console.log('Installing "'+e+'" from npm to "'+a+'"...'),d){a=ht(a),On(e,!1,{cwd:a});try{return ot(a),Tn(a,e)}catch(e){console.error("Failed to load from auto-install dir: ",a)}}}throw K('Module not found: "'+e+'"',{checked:{moduleDir:r,scriptDir:u,cwd:i}})},mt=function(e,n,r){if(g()){var u=Sn().join(e,n);return r?nr(u):u}throw J()},gt=function(e){return at().readFileSync(e,"utf8")},yt=gt,wt=function(e){return JSON.parse(yt(e))},bt={env:{parseArgs:l,args:r,setConfig:ut,getConfig:ct,resolveConfig:lt},node:{parseArgs:c,args:n,pause:function(e){vt("press-any-key-sync")(String(e))},require:vt,_basicRequire:a,is:g,display:x,util:b,_builtInModule:w,requireBuiltIn:y,child_process:bn,requireLocal:In,path:Sn,_requireFromDir:Tn,_requireDirCache:kn,_createRequire:qn,module:Nn,promptYNSync:nt,run:Gr,getScriptPath:tr,sigint:Zr,interrupt:Xr,ensureRequireDir:ot,addRequireDir:it,fs:at,loadPackageJSON:function(e){var n=e??"./";return n.endsWith("package.json")||(n=mt(n,"package.json")),ft(n)?wt(n):{}}},shell:{parseArgs:s,_handleError:En},cli:{parseArgs:o,splitArgs:i},f:{one:e,memoize:Re,MemoizedFunction:Ce,createClass:ie,createConstructor:L,isArrowFn:M,isArrow:R,is:C,wrap:P,ensureConstructor:D,retThis:W,setName:H,not:gn,body:zr,isArrowString:Er,_getArrowFnBody:Ur,_getNormalFnBody:Yr},s:{is:u,toLiteral:He,quote:$e,escape:Ve,replaceAll:Qe,apply:I,withIndices:_,chars:Me,from:Ze,removeTrailing:zn,removeFromEnd:Yn,_removeStringFromEnd:Mn,_removeRegexFromEnd:Un,resolveIndex:Ln,splitAtIndex:Jn,ensureStartsWith:Qn,replace:Xn,endsWith:Zn,decapitalize:ur,removeLineBreaks:hr,removeMulti:dr,removeAll:pr,resolve:Jr,ensure:xr,after:Pr,match:Rr,_matchWithIndices:Fr,remove:kr,removeLeading:Br,removeFromStart:Kr,_removeStringFromStart:Lr,_removeRegexFromStart:Wr},npm:{isBuiltIn:f,isFile:p,install:On,_runCommand:An},os:{run:Fn,_resolveStdio:vn},a:{is:d,wrapIndices:S,wrapIndex:O,resolveIndex:A,ensure:N,pick:le,create:ce,fill:se,resolveIndices:oe,push:we,add:ye,splitLast:Ae,splitTail:Fe,toLiteral:en,display:ln,removeNullish:wn,removeByFilter:yn,replaceContents:mn,last:Pn,pushMulti:Sr,addMulti:Or,pushThroughMulti:Ar},err:{value:fn,ValueError:m,Error:v,Enhanced:h,create:K,nyi:J,NYIError:B,defaultFromFn:z,type:hn,TypeError:pn,prepend:mr,req:Qr},v:{display:an,constructorMatches:E,toLiteral:nn,isPrimitive:G,resolve:pe,type:dn,req:Vr},macro:{config:function(e){}},o:{is:F,display:cn,toLiteral:sn,constructorMatches:j,safeEnsure:Y,ensure:U,isAny:Q,setHidden:$,addNonEnumerable:V,hideKey:ue,makeNonEnumerable:te,ensureCustom:de,get:ae,set:fe,createEmpty:Ee,remove:je,isPure:Xe,reduce:on,each:un,keys:tn,allKeys:rn,Cache:jn,setDefaults:Rn,ensureMulti:Cn,resolveKeys:rt,diveGet:st},re:{is:k,ensureGlobal:Ue,global:Be,addFlag:Ke,copy:We,updateFlagString:De,parseFlagString:Pe,createFlagString:Le,createEscaped:Ge,create:ze,resolveFlags:Ye,escape:Je,matchEnd:Bn,matchLast:Kn,matchAll:Wn,setStartIndex:Dn,slash:er,safeCreateResult:jr,createResult:Ir,RegexResult:_r,match:Cr,ensureLocal:Tr,local:qr,removeFlag:Nr,resultEndIndex:Mr,matchStart:Dr},class:{create:re,setName:X,addStatics:Z,setDisplay:ne},p:{asyncJoint:T,is:q},sym:{display:ee,value:xe},map:{Cache:ge,ensure:me,get:he,set:ve,MultiCache:Te,diveEnsure:Ie,createEmpty:_e,diveDelete:qe,remove:Ne},args:{ensureArray:be},tree:{ensure:Se,dive:Oe,remove:ke,setCustom:tt},win:{is:xn},path:{abs:_n,fws:rr,ensureTrailingSlash:nr,baseName:sr,_removeExtsFromFile:ir,file:or,dir:lr,join:mt},js:{enhance:br,ensureReturn:Vn,splitLastExpression:Gn,enableAwait:Hn,_nodeEnableAwait:$n,useTitan:fr,inline:wr,removeComments:yr,fromAST:vr,parse:gr},titan:{getPackagePath:ar,getPackageName:cr},proc:{interrupt:Hr,signal:$r},bool:{fromYN:et},fs:{ensureDir:ht,exists:ft,mkdir:dt,ensureParent:pt,loadJSON:wt,loadText:yt,load:gt}};globalThis.t?Object.keys(bt).forEach((function(e){if(t[e]){var n=bt[e];Object.keys(n).forEach((function(r){t[e][r]=n[r]}))}else t[e]=bt[e]})):globalThis.t=Object.assign({},bt),globalThis.exports&&(exports.default=globalThis.t);
1
+ var e=function(e){var n,r=!1;return function(){return r||(r=!0,n=e.apply(this,arguments)),n}},n=e(function(){return process.argv.slice(2)}),r=n,u=function(e){return"string"==typeof e},i=function(e,n){const r=[];let u="",i="outside",o=!1;for(let s=0;s<e.length;s++){const c=e[s];switch(i){case"outside":'"'===c?o?(u+=c,o=!1):(n&&(u+=c),i="insideQuote"):"\\"===c?o=!0:" "===c?(u.length>0&&(r.push(u),u=""),o=!1):(u+=c,o=!1);break;case"insideQuote":'"'!==c||o?"\\"!==c||o?(u+=c,o=!1):o=!0:(n&&(u+=c),i="outside")}}return u.length>0&&r.push(u),r},o=function(e,n){for(var o,s=[],c=!1,l=(o=null==(f=e)?r():u(f)?i(f,n):f).length,a=0;a<l;a++){var f=o[a];if(!c){var p=f[0];let e;if("-"===p)if("-"===f[1]){if(2===f.length){c=!0;continue}e=2}else e=1;else"/"===p&&(e=1);if(e){var d,h,v=f.slice(e),m=v.indexOf("=");if(-1!==m)d=v.slice(0,m),h=v.slice(m+1);else{d=v;var g=o[a+1];null==g||"-"===g[0]?h=!0:(h=g,a++)}s[d]=h;continue}}s.push(f)}return s},s=o,c=s,l=c,a=function(e){return require(e)},f=function(e){return!!e.startsWith("node:")||a("node:module").isBuiltin(e)},p=function(e){return e.startsWith(".")},d=function(e){return Array.isArray(e)},h=function(e){return class extends e{constructor(e,n){super(e,n);var r=this.constructor.name;r&&(this.name=r)}}},v=h(globalThis.Error),m=class extends v{constructor(e,n){super(e??"Unexpected value",n)}},g=e(function(){return"undefined"==typeof window}),y=function(e){return require("node:"+e)},w=function(n){return e(()=>y(n))},b=w("util"),x=function(e,n){return n||(n={}),null==n.colors&&(n.colors=!0),b().inspect(e,n)},E=function(e,n){return null!=e&&e.constructor===n},F=function(e){return E(e,Object)},O=function(e,n){return n<0?e.length+n:n},A=O,S=function(e,n,r,u){return void 0!==n&&(null===n||0===n?n=void 0:(n=A(e,n),u&&0==u.inclusiveStart&&n++)),void 0!==r&&(null===r||r===e.length?r=void 0:(r=A(e,r),u&&u.inclusiveEnd&&r++)),[n,r]},_=function(e,n,r,u,i,o){if(r||null!=u){[r,u]=S(e,r,u,o);var s=e.slice(r,u),c=n(s);return i?i(c,r,u,s,e):c}return n(e)},j=function(e,n,r,u,i){return _(e,n,r,u,(n,r,u)=>(void 0!==r?e.slice(0,r):"")+(n||"")+(void 0!==u?e.slice(u):""),i)},I=E,k=function(e){return I(e,RegExp)},N=function(e){return d(e)?e:[e]},R=function(e){return e instanceof Promise},q=function(e,n){var r=e;return R(r)?r.then(n):n(r)},T=function(e){return"function"==typeof e},C=function(e){return T(e)&&null==e.prototype},P=C,M=function(e){return function(){return e.apply(this,arguments)}},L=function(e,n){var r;return r=n?function(){this.super=n;var r=e.apply(this,arguments);return q(r,()=>(delete this.super,r))}:P(e)?M(e):e,r._isConstructor=!0,r},D=function(e,n){return e._isConstructor?e:L(e,n)},W=function(){return this},K=function(e){var n=typeof e;return"object"!==n&&"function"!==n||null===e},B=function(e){return!K(e)},U=function(e,n,r){return!1===r?Object.keys(n).forEach(r=>{void 0===e[r]&&(e[r]=n[r])}):Object.assign(e,n),e},Y=function(e,n){return U(e,n,!1)},z=function(e,n,r,u){return r||(r={}),u&&Y(r,u),null==r.enumerable&&(r.enumerable=!0),null==r.configurable&&(r.configurable=!0),Object.defineProperty(e,n,r)},J=function(e,n,r,u){return z(e,n,{value:r,writable:!0,enumerable:!1},u),r},V=J,G=class extends v{constructor(e,n){super(e??"Not yet implemented",n)}},Q=function(e,n,r,u){var i=e[n];if(void 0===i){var o=r;!1!==u&&T(o)&&(o=o(e,n)),e[n]=i=o}return i},$=function(e,n,r,u){return e||(e={}),Q(e,n,r,u),e},H=function(e,n){return $(e,"fromFn",n,!1)},X=function(e,n){return new G(e,H(n,X))},Z=function(e,n){Object.defineProperty(e,"name",{value:n,configurable:!0}),V(e,"displayName",n)},ee=Z,ne=function(e,n){return Object.assign(e,n)},re=g()?require("util").inspect.custom:Symbol("Display"),te=function(e,n){e.prototype[re]=n},ue=function(e,n,r,i,o,s){s||(s={}),u(n)&&(n=null);var c,l,a,f=r;f&&(d(f)?([l,a]=f,l&&(l=D(l))):c=D(f,n));var p=s.bareFn;s.singleton&&(p=function(){return null==m.default&&(m.default=new m(...arguments)),m.default});var h,v=l||c||n||W;function m(){if(!new.target&&p&&!(this instanceof m))return p.apply(this,arguments);var e=this;return q(v.apply(e,arguments),r=>{if(r&&B(r)&&(e=r,l)){if(!new.target)throw X('Prototype repair is NYI for class instantiation without "new".');if(!n)throw X("instanceFn is not yet supported when extendsClass is null.");var u=Object.getPrototypeOf(this);Object.getPrototypeOf(e)!==u&&Object.setPrototypeOf(e,u)}return a?q(a.apply(e,arguments),()=>e):e})}return e&&ee(m,e),i?(h=i,n&&Object.setPrototypeOf(i,n.prototype)):h=n?Object.create(n.prototype):{},V(h,"constructor",m),m.prototype=h,o&&ne(m,o),s.display&&te(m,s.display),s.implements&&N(s.implements).forEach(e=>e(m)),m},ie=function(e,n){Object.defineProperty(e,n,{enumerable:!1})},oe=ie,se=function(e,n,r,u,i){var o=Symbol();return ue(e,Function,[function(){var e=function(){return e[o].apply(this,arguments)};return e},function(){var e=n.apply(this,arguments);if(!e)throw new Error("Constructor must return a function.");this[o]=e,oe(this,o)}],r,u,i)},ce=function(e,n,r,u){return n=null==n?0:O(e,n),r=null==r?e.length:O(e,r),u&&(0==u.inclusiveStart&&n++,u.inclusiveEnd&&r++),[n,r]},le=function(e,n,r,u){var i=n;if([r,u]=ce(e,r,u),T(i))for(var o=r;o<u;o++)e[o]=i(o,e);else e.fill(i,r,u);return e},ae=function(e,n){var r=new Array(e||0);return arguments.length>1&&le(r,n),r},fe=function(e,n){return ae(n.length,r=>e[n[r]])},pe=function(e,n){return e[n]},de=function(e,n,r){return e[n]=r},he=function(e,n,r){var u=e;return T(u)?u.apply(r,n):u},ve=function(e,n,r,u,i){u||(u=pe);var o=u(e,n);return void 0===o&&(o=he(r,[e,n]),i||(i=de),i(e,n,o)),o},me=function(e,n){return e.get(n)},ge=function(e,n,r){return e.set(n,r)},ye=function(e,n,r){return ve(e,n,r,me,ge)},we=class{constructor(){this.store=new Map}get(e,n){return ye(this.store,e,n)}remove(e){return this.store.delete(e)}delete(e){return this.remove(e)}},be=function(e,n){return e.push(n),e},xe=be,Ee=function(e){var n=e;return Array.isArray(n)?n:Array.from(n)},Fe=Symbol("Value"),Oe=function(){return{}},Ae=function(e){return[e.slice(0,-1),e[e.length-1]]},Se=Ae,_e=function(e,n,r,u,i,o){r||(r=pe),null==u&&(u=Oe),null==i&&(i=de),null==o&&(o=r);for(var[s,c]=Se(n),l=e,a=s.length,f=0;f<a;f++){var p=s[f],d=r(l,p);if(void 0===d){if(!u)return;d=ve(l,p,u,r,i)}l=d}if(o)return o(l,c,i)},je=function(e,n,r,u,i,o){return _e(e,n,u,i,o,(e,n)=>ve(e,n,r,u,o))},Ie=function(){return new Map},ke=function(e,n,r){return je(e,n,r,me,Ie,ge)},Ne=function(e,n){return delete e[n],e},Re=function(e,n,r,u){return _e(e,n,r,!1,!1,u||Ne)},qe=function(e,n){return e.delete(n)},Te=function(e,n){return Re(e,n,me,qe)},Ce=class{constructor(){this.store=new Map}get(e,n){return e=xe(Ee(e),Fe),ke(this.store,e,n)}remove(e){return e=xe(Ee(e),Fe),Te(this.store,e)}delete(e){return this.remove(e)}},Pe=se("MemoizedFunction",function(e,n){if(this.base=e,null!=n)if(1===(n=N(n)).length){this.cache=new we;var r=n[0];this._cacheKeyFormatter=e=>e[r]}else this.cache=new Ce,this._cacheKeyFormatter=e=>fe(e,n);else this.cache=new Ce,this._cacheKeyFormatter=e=>e;var u=this;return function(){var n=u._cacheKeyFormatter(arguments);return u.cache.get(n,()=>e.apply(this,arguments))}},{remove(e){return this.cache.remove(this._cacheKeyFormatter(e))}}),Me=function(e,n){return new Pe(e,n)},Le=function(e){return new Set(e)},De=function(e){var n={};if(e){var r=Le(e);r.has("g")&&(n.global=!0),r.has("i")&&(n.caseInsensitive=!0),r.has("y")&&(n.sticky=!0)}return n},We=function(e){var n="";return e.global&&(n+="g"),(e.caseInsensitive||0==e.caseSensitive)&&(n+="i"),e.sticky&&(n+="y"),n},Ke=function(e,n){var r=De(e);return We(Object.assign(r,n))},Be=function(e,n){var r=n,i=void 0;return u(r)?i=r:F(r)&&(i=Ke(e.flags,r)),new RegExp(e,i)},Ue=function(e,n){return Be(e,e.flags+n)},Ye=function(e){return Ue(e,"g")},ze=Me(function(e){return e.global?e:Ye(e)},0),Je=function(e){var n=e;return null==n?void 0:u(n)?n:We(n)},Ve=function(e,n){return new RegExp(e,Je(n))},Ge=function(e){return e.replace(/[-[\]{}()*+!<=:?.\/\\^$|#\s,]/g,"\\$&")},Qe=function(e,n){return Ve(Ge(e),n)},$e=function(e,n,r,i,o,s){return j(e,function(e){return e.replaceAll?(k(n)&&(n=ze(n)),e.replaceAll(n,r)):(n=u(n)?Qe(n,"g"):ze(n),this.replace(n,r))},i,o,s)},He=function(e,n,r){return $e(e,n,(r??"\\")+n)},Xe=function(e,n,r){return null==n&&(n='"'),!1!==r&&(e=He(e,n,r)),n+e+n},Ze=function(e){return Xe(e,'"')},en=F,nn=function(e){return en(e)?ln(e):String(e)},rn=function(e,n){return n||(n=tn),"["+e.reduce(function(e,r){return e+n(r)+", "},"").slice(0,-2)+"]"},tn=function(e){return u(e)?Ze(e):d(e)?rn(e):nn(e)},un=function(e){return Reflect.ownKeys(e)},on=function(e,n){return(n?un:Object.keys)(e)},sn=function(e,n,r){on(e,r).forEach((r,u,i)=>n(r,e[r],u,i))},cn=function(e,n,r,u){var i=null!=r?r:"";return sn(e,function(){i=n.call(this,i,...arguments)},u),i},ln=function(e,n){return n||(n=tn),"{"+cn(e,function(e,r,u){return e+r+":"+n(u)+", "},"",!0).slice(0,-2)+"}"},an=function(e,n){return null==n&&(n=1),n<=0?"[object Object]":ln(e,e=>pn(e,n-1))},fn=function(e,n){return null==n&&(n=1),n<=0?"[object Array]":rn(e,e=>pn(e,n-1))},pn=function(e,n){return void 0===e?"undefined":null===e?"null":g()?x(e,n):F(e)?an(e,maxNumLevels):d(e)?fn(e,maxNumLevels):nn(e)},dn=function(e,n,r,u){if(0===arguments.length)return new m("Unexpected value received");u||(u={});var i,{expected:o}=u;return i=o?"Received "+pn(e)+", expected one of "+pn(o):"Unexpected value received: "+pn(e),r&&(i+=' for "'+r+'"'),null!=n&&(i+=" (index "+n+")"),u.fromFn||(u.fromFn=dn),new m(i,u)},hn=h(globalThis.TypeError),vn=function(e){return null==e?e:e.constructor},mn=function(e,n,r,u){if(0===arguments.length)return new hn("Unexpected type received");u||(u={});var i,{type:o,expected:s}=u;return null==o&&(o=vn(e)),o&&o.name&&(o=o.name),s?(s.name&&(s=s.name),i="Expected "+s+", received "):i="Unexpected type received (",i+=o,null!=e&&(i+=" ("+pn(e)+")"),s||(i+=")"),r&&(i+=' for "'+r+'"'),null!=n&&(i+=" (index "+n+")"),u.fromFn||(u.fromFn=mn),new hn(i,u)},gn=function(e){var n=e.stdio;if(n){if(!d(n)){if(!u(n))throw mn(n,"stdio");if("pipe"===n)n=["pipe","pipe","pipe"];else if("inherit"===n)n=["inherit","inherit","inherit"];else if("ignore"===n)n=["ignore","ignore","ignore"];else{if("overlapped"!==n)throw dn(n,"stdio");n=["overlapped","overlapped","overlapped"]}e.stdio=n}}else n=e.stdio=[null,null,null];return n},yn=function(e,n,r){var u=new v(e,r);return n&&Object.assign(u,n),u},wn=function(e,n){var r=n.length;e.length=r;for(var u=0;u<r;u++)e[u]=n[u];return e},bn=function(e){return function(){return!e.apply(this,arguments)}},xn=function(e,n){return wn(e,e.filter(bn(n)))},En=function(e){return xn(e,e=>null==e)},Fn=w("child_process"),On=e(function(){return"win32"===process.platform}),An=function(e,n,r){if(r||(r={}),n(e))throw e;if(r.nullOnErr)return null;var u=r.onErr;if(void 0!==u)return he(u);throw e},Sn=function(e,n,r){r||(r={}),r.dir&&(r.cwd=r.dir);var u=gn(r);if(null==u[0]){var i=r.allowInput,o=r.input;if(i&&o)throw yn("allowInput (user) and input (programmatic) cannot be used simultaneously for synchronous child processes.");i&&(u[0]="inherit")}if(null==u[1]){var s=r.captureOutput??!1,c=r.showOutput;if(s&&c)throw yn("captureOutput and showOutput cannot be used simultaneously for synchronous child processes.");s?u[1]="pipe":(null==c&&(c=!0),u[1]=c?"inherit":"ignore")}if(null==u[2]){var l=r.captureErr??!1,a=r.showErr;if(l&&a)throw yn("captureErr and showErr cannot be used simultaneously for synchronous child processes.");l?u[2]="pipe":(null==a&&(a=!0),u[2]=a?"inherit":"ignore")}r.encoding||(r.encoding="utf8"),n&&En(n);try{var f=Fn().execFileSync(e,n,r);null!=f&&!1!==r.trim&&(f=f.trim());var p=r.map??r.mapFn;return p&&(f=p(f)),f}catch(e){if(On())return An(e,e=>"ENOENT"===e.code,r);throw e}},_n=function(e,n){return n||(n={}),null==n.captureOutput&&(n.captureOutput=!1),n.shell=!0,n.filterExtensions=!1,Sn("npm",e,n)},jn=function(e,n,r){return _n(["install",e,n?"-g":null],r)},In=w("path"),kn=In().sep,Nn=function(e,n,r){var u=In().resolve,i=n?u(n,e):u(e);return r?i+kn:i},Rn=function(e){return require(Nn(e))},qn=class{constructor(){this.store={}}get(e,n){return Q(this.store,e,n)}remove(e){return delete this.store[e]}delete(e){return this.remove(e)}},Tn=new qn,Cn=function(e){return e[e.length-1]},Pn=O,Mn=function(e,n,r){return e=Be(e,{global:!0}),null!=r&&(n=Pn(r,n)),e.lastIndex=n,e},Ln=function(e,n,r){return e=null!=r?Mn(e,r,n):ze(e),Array.from(n.matchAll(e))},Dn=function(e,n,r){return null!=r&&(n=n.slice(0,r)),Cn(Ln(e,n))||null},Wn=function(e,n){var r=Dn(e,n);return r&&n.length===r.index+r[0].length?r:null},Kn=function(e,n){if(u(n))return e.endsWith(e);if(k(n))return!!Wn(n,e);throw mn(n,1,"matchThis")},Bn=/\/|\\/,Un=function(e){return Kn(e,Bn)?e:e+kn},Yn=function(e,n,r){if(g()){var u=In().join(e,n);return r?Un(u):u}throw X()},zn=function(e,n){return e.endsWith(n)?e:Yn(e,n)},Jn=w("module"),Vn=function(e){return e=zn(e,"node_modules"),Jn().createRequire(e)},Gn=function(e,n){return Tn.get(e,()=>Vn(e))(n)},Qn=function(e,n,r){return Object.keys(n).forEach(u=>Q(e,u,n[u],r)),e},$n=function(e,n,r){return n?Qn(e,n,r):e},Hn=function(e,n){return e.endsWith(n)?e.substring(0,e.length-n.length):e},Xn=function(e,n){var r=Wn(n,e);return r?e.slice(0,r.index):e},Zn=function(e,n){if(u(n))return Hn(e,n);if(k(n))return Xn(e,n);throw mn(n,1)},er=Zn,nr=function(e,n){return[e.slice(0,n),e.slice(n)]},rr=function(e){e=er(e.trim(),";");var n=Math.max(e.lastIndexOf(";"),e.lastIndexOf("\n"));return nr(e,n+1)},tr=function(e,n){return e.startsWith(n)?e:n+e},ur=function(e){var[n,r]=rr(e);return n+tr(r.trim(),"return ")},ir=function(e){return xt("node-repl-await").processTopLevelAwait(e)},or=function(e){return ir(e)??e},sr=$e,cr=function(e,n){return""===e?e:(null==n&&(n=!0),e=sr(e,"\\","/"),n?Un(e):e)},lr=function(){return process.mainModule?.filename??null},ar=function(e){return e.charAt(0).toLowerCase()+e.slice(1)},fr=function(e){return e.split(".")[0]},pr=function(e){return In().win32.basename(e)},dr=function(e){return fr(pr(e))},hr=function(e,n,r,u){e||(e=lr()??"_console.js");var i=ar(dr(e));return n&&(i+="_repl"),i+(r&&u?.dynamic?".dypkg.json":".pkg.js")},vr=function(e,n){return e=In().dirname(e),!1===n?e:Un(e)},mr=function(e,n,r,u){var i,o=hr(e,n,r,u);return i=e?vr(e):"./",Nn(i+o)},gr=function(e){return'require("'+cr(mr(),!1)+'");\n'+e},yr=function(e,n){return $e(e,n,"")},wr=function(e,n){return n.forEach(n=>e=yr(e,n)),e},br=function(e){return wr(e,["\r","\n"])},xr=function(e,n){return xt("astring").generate(e,n)},Er=function(e,n){return e.stack=n+"\n"+e.stack,e},Fr=function(e,n,r){r||(r={}),r.ecmaVersion||(r.ecmaVersion=2024),!1!==n&&(r.sourceType="module"),null==r.allowAwaitOutsideFunction&&(r.allowAwaitOutsideFunction=!0),null==r.allowReturnOutsideFunction&&(r.allowReturnOutsideFunction=!0);var u=xt("acorn");try{return u.parse(e,r)}catch(n){throw Er(n,"Acorn parsing error: "+e)}},Or=function(e,n,r){return xr(Fr(e,n,r))},Ar=function(e){return br(Or(e))},Sr=function(e,n,r){return(n||r)&&(n||(n={}),r&&$n(n,r),n.ensureReturn&&(e=ur(e)),n.topLevelAwait&&(e=or(e)),n.useTitan&&(e=gr(e)),n.keepAlive&&(e="\nsetInterval(()=>{}, 100000);\n"+e),(n.logErrors||n.keepAlive)&&(e="process.on('uncaughtException', console.error);\nprocess.on('unhandledRejection', console.error);\n"+e),n.inline&&(e=Ar(e))),e},_r=function(e){return u(e)?e:nn(e)},jr=function(e){var n=e.indexOf("{");return-1===n||e.slice(0,n).includes("=>")},Ir=function(e,n,r,u,i){return _(e,n,r,u,(n,r)=>null===n?null:(n.input=e,void 0!==r&&(n.index+=r),n),i)},kr=function(e,n){return e.splice(e.length,0,...n),n},Nr=function(e,n){return kr(e,n),e},Rr=Nr,qr=class extends Array{constructor(e,n,r,u,i){if(-1===n)throw yn("RegexResult index cannot be -1. For empty result, use bare null.");if(null==e)throw yn("RegexResult matchString cannot be null. For empty result, use bare null.");super(),this[0]=e,u&&Rr(this,u),this.index=n,this.input=r,i&&(this.groups=i)}fromParts(e){var n=e;return new qr(n.match,n.index,n.input,n.captures,n.groups)}},Tr=function(e,n,r,u,i){return new qr(e,n,r,u,i)},Cr=function(e,n,r,u,i){return-1===n||null==e?null:Tr(e,n,r,u,i)},Pr=yr,Mr=function(e,n){return Be(e,Pr(e.flags,n))},Lr=function(e){return Mr(e,"g")},Dr=Me(function(e){return e.global?Lr(e):e},0),Wr=function(e,n,r){return(e=null!=r?Mn(e,r,n):Dr(e)).exec(n)},Kr=function(e,n,r,i,o){return Ir(e,e=>{if(u(n)){var r=e.indexOf(n);return Cr(n,r,e)}return Wr(n,e)},r,i,o)},Br=function(e){return e.index+e[0].length},Ur=function(e,n){var r=Kr(e,n);return null===r[0]?null:e.slice(Br(r))},Yr=function(e,n){return e.startsWith(n)?e.substring(n.length):e},zr=function(e,n){var r=Wr(e,n);return r&&0===r.index?r:null},Jr=function(e,n){var r=zr(n,e);return r?e.slice(r[0].length):e},Vr=function(e,n){if(u(n))return Yr(e,n);if(k(n))return Jr(e,n);throw mn(n,1)},Gr=Vr,Qr=function(e){var n=Ur(e,"=>").trim();return Gr(er(n,"}"),"{")},$r=function(e){return Ur(e,"{").slice(0,-1)},Hr=function(e){var n=_r(e);return jr(n)?Qr(n):$r(n)},Xr=function(e){return null==e?"":u(e)?e:T(e)?Hr(e):String(e)},Zr=function(e,n){var r=n?.basic?null:{topLevelAwait:!0,useTitan:!0},u=Sr(Xr(e),n,r);return Sn("node",[n?.mode??"-p",u],n)},et=function(e,n,r,u){var i="Required argument";return r&&(i+=' "'+r+'"'),null!=n&&(i+=" (index "+n+")"),i+=" missing",arguments.length>0&&(i+=" (received "+pn(e)+")"),yn(i,null,H(u,et))},nt=function(e,n,r){if(null==e)throw et(e,n,r,{fromFn:nt});return e},rt=function(e,n){return process.kill(e,nt(n,0,"signalName"))},tt=function(e){return rt(e,"SIGINT")},ut=function(){return tt(process.pid)},it=ut,ot=function(e){if("Y"===(e=e.toUpperCase()))return!0;if("N"===e)return!1;throw dn(e,0,"char")},st=function(e){null==e&&(e="Are you sure? [y/n]: "),process.stdout.write(e);var n=Zr(function(){const e=process.stdin,n=process.stdout;e.setRawMode(!0),e.setEncoding("utf8"),e.on("data",e=>{var r=e.toUpperCase();"Y"===r||"N"===r?(n.write(e),process.exit(0)):""===e&&(n.write("^C"),process.exit(0))})},{mode:"-e",basic:!0,stdio:["inherit","pipe"]});if("^C"===n)throw process.stdout.write(n),it(),yn("Prompt was cancelled via interrupt.");return console.log(n),ot(n)},ct=function(e){return d(e)?e:u(e)?e.split("."):[e]},lt=function(e,n,r,u,i,o){var s=r;return _e(e,n,u,i,o,(e,n,r)=>r(e,n,he(s)))},at=function(e,n){var r=n,u=globalThis.config;u||(u=globalThis.config={});var i,o=ct(e);return o.length>1?i=lt(u,o,r):(i=he(r),u[o[0]]=i),i},ft=function(e,n){return at("node.require.customDirs",r=>(r||(r=[]),!1!==n&&(e=zn(e,"node_modules")),r.includes(e)||r.push(e),r)),e},pt=ft,dt=_e,ht=function(e){var n=globalThis.config;if(n){var r=ct(e);return r.length>1?dt(n,r):n[r[0]]}},vt=function(e,n,r){if(null!=e)return e;var u=ht(n);return null!=u?u:r},mt=w("fs"),gt=function(e){return!!mt().lstatSync(e,{throwIfNoEntry:!1})},yt=function(e){var n=vr(e,!1);return gt(n)||(n!==e&&yt(n),mt().mkdirSync(n)),e},wt=function(e){return yt(e),mt().mkdirSync(e),e},bt=function(e){return gt(e)?e:wt(e)},xt=function(e,n){if(f(e))return require(e);if(p(e))return Rn(e);try{return require(e)}catch(e){}var r=__dirname,u=process.mainModule?.path;if(u!==r)try{return Gn(u,e)}catch(e){}var i=process.cwd();if(i!==u&&i!==r)try{return Gn(i,e)}catch(e){}var o=ht("node.require.customDirs");if(o)for(var s of o)try{return Gn(s,e)}catch(e){}var c=vt(n?.autoInstall,"node.require.autoInstall"),l=vt(n?.promptInstall,"node.require.promptInstall",!0);if(c||l){var a=c||l;!0===a&&(a="./node_modules"),a=Nn(a);var d=!1;if(c?(d=!0,console.log('Auto-installing "'+e+'" from npm to "'+a+'"...')):(d=st('Npm package "'+e+'" is required. Install now? (Y/N) '))&&console.log('Installing "'+e+'" from npm to "'+a+'"...'),d){a=bt(a),jn(e,!1,{cwd:a});try{return pt(a),Gn(a,e)}catch(e){console.error("Failed to load from auto-install dir: ",a)}}}throw yn('Module not found: "'+e+'"',{checked:{moduleDir:r,scriptDir:u,cwd:i}})},Et=function(e){return mt().readFileSync(e,"utf8")},Ft=Et,Ot=function(e){return JSON.parse(Ft(e))},At={env:{parseArgs:l,args:r,setConfig:at,getConfig:ht,resolveConfig:vt},node:{parseArgs:c,args:n,pause:function(e){null!=e&&(e=String(e)),xt("press-any-key-sync")(e)},require:xt,_basicRequire:a,is:g,display:x,util:b,_builtInModule:w,requireBuiltIn:y,child_process:Fn,requireLocal:Rn,path:In,_requireFromDir:Gn,_requireDirCache:Tn,_createRequire:Vn,module:Jn,promptYNSync:st,run:Zr,getScriptPath:lr,sigint:it,interrupt:ut,ensureRequireDir:pt,addRequireDir:ft,fs:mt,loadPackageJSON:function(e){var n=e??"./";return n.endsWith("package.json")||(n=Yn(n,"package.json")),gt(n)?Ot(n):{}}},shell:{parseArgs:s,_handleError:An},cli:{parseArgs:o,splitArgs:i},f:{one:e,memoize:Me,MemoizedFunction:Pe,createClass:se,ensureConstructor:D,createConstructor:L,isArrowFn:P,isArrow:C,is:T,wrap:M,retThis:W,setName:Z,not:bn,body:Hr,isArrowString:jr,_getArrowFnBody:Qr,_getNormalFnBody:$r},s:{is:u,toLiteral:Ze,quote:Xe,escape:He,replaceAll:$e,apply:j,withIndices:_,chars:Le,from:nn,endsWith:Kn,resolveIndex:Pn,removeTrailing:er,removeFromEnd:Zn,_removeStringFromEnd:Hn,_removeRegexFromEnd:Xn,splitAtIndex:nr,ensureStartsWith:tr,replace:sr,decapitalize:ar,removeLineBreaks:br,removeMulti:wr,removeAll:yr,resolve:Xr,ensure:_r,after:Ur,match:Kr,_matchWithIndices:Ir,remove:Pr,removeLeading:Gr,removeFromStart:Vr,_removeStringFromStart:Yr,_removeRegexFromStart:Jr},npm:{isBuiltIn:f,isFile:p,install:jn,_runCommand:_n},os:{run:Sn,_resolveStdio:gn},a:{is:d,wrapIndices:S,wrapIndex:A,resolveIndex:O,ensure:N,pick:fe,create:ae,fill:le,resolveIndices:ce,push:xe,add:be,splitLast:Se,splitTail:Ae,toLiteral:rn,display:fn,removeNullish:En,removeByFilter:xn,replaceContents:wn,last:Cn,pushMulti:Rr,addMulti:Nr,pushThroughMulti:kr},err:{value:dn,ValueError:m,Error:v,Enhanced:h,nyi:X,NYIError:G,defaultFromFn:H,type:mn,TypeError:hn,create:yn,prepend:Er,req:et},v:{display:pn,constructorMatches:E,toLiteral:tn,isPrimitive:K,resolve:he,type:vn,req:nt},macro:{config:function(e){}},o:{is:F,display:an,toLiteral:ln,constructorMatches:I,isAny:B,setHidden:V,addNonEnumerable:J,defineProperty:z,weakAssign:Y,merge:U,safeEnsure:$,ensure:Q,hideKey:oe,makeNonEnumerable:ie,ensureCustom:ve,get:pe,set:de,createEmpty:Oe,remove:Ne,isPure:en,reduce:cn,each:sn,keys:on,allKeys:un,Cache:qn,setDefaults:$n,ensureMulti:Qn,resolveKeys:ct,diveGet:dt},re:{is:k,ensureGlobal:ze,global:Ye,addFlag:Ue,copy:Be,updateFlagString:Ke,parseFlagString:De,createFlagString:We,createEscaped:Qe,create:Ve,resolveFlags:Je,escape:Ge,matchEnd:Wn,matchLast:Dn,matchAll:Ln,setStartIndex:Mn,slash:Bn,safeCreateResult:Cr,createResult:Tr,RegexResult:qr,match:Wr,ensureLocal:Dr,local:Lr,removeFlag:Mr,resultEndIndex:Br,matchStart:zr},class:{create:ue,setName:ee,addStatics:ne,setDisplay:te},p:{asyncJoint:q,is:R},sym:{display:re,value:Fe},map:{Cache:we,ensure:ye,get:me,set:ge,MultiCache:Ce,diveEnsure:ke,createEmpty:Ie,diveDelete:Te,remove:qe},args:{ensureArray:Ee},tree:{ensure:je,dive:_e,remove:Re,setCustom:lt},win:{is:On},path:{abs:Nn,sep:kn,ensureEndsWith:zn,join:Yn,ensureTrailingSlash:Un,fws:cr,baseName:dr,_removeExtsFromFile:fr,file:pr,dir:vr},js:{enhance:Sr,ensureReturn:ur,splitLastExpression:rr,enableAwait:or,_nodeEnableAwait:ir,useTitan:gr,inline:Ar,removeComments:Or,fromAST:xr,parse:Fr},titan:{getPackagePath:mr,getPackageName:hr},proc:{interrupt:tt,signal:rt},bool:{fromYN:ot},fs:{ensureDir:bt,exists:gt,mkdir:wt,ensureParent:yt,loadJSON:Ot,loadText:Ft,load:Et}};globalThis.t?Object.keys(At).forEach(function(e){if(t[e]){var n=At[e];Object.keys(n).forEach(function(r){t[e][r]=n[r]})}else t[e]=At[e]}):globalThis.t=Object.assign({},At),globalThis.exports&&(exports.default=globalThis.t);
package/cli.min.js CHANGED
@@ -1 +1 @@
1
- require("./cli.pkg.js"),t.node.onError((r=>{console.log(r)})),args=t.cli.parseArgs(),params=t.cli.paramFn(args);var r=t.node.pause;pause=function(){args.np||r()},args.cwd&&process.chdir(args.cwd),env=process.env,args.np||t.node.beforeExit(pause),require("./script.min.js");
1
+ require("./cli.pkg.js"),t.node.onError(r=>{console.log(r)}),args=t.cli.parseArgs(),params=async function(...r){return t.cli.paramsFrom(args,r)};var r=t.node.pause;pause=function(){args.np||r()},args.cwd&&process.chdir(args.cwd),env=process.env,args.np||t.node.beforeExit(pause),require("./script.min.js");
package/cli.pkg.js CHANGED
@@ -1 +1 @@
1
- var e=function(e,n){return n(e)},n=function(e){return"string"==typeof e},r=function(e){return Array.isArray(e)},i=function(e){return r(e)?e:[e]},u=function(e){return e instanceof Promise},o=function(e,n){var r=e;return u(r)?r.then(n):n(r)},s=function(e){return"function"==typeof e},a=function(e){return s(e)&&null==e.prototype},l=a,c=function(e){return function(){return e.apply(this,arguments)}},f=function(e,n){var r;return r=n?function(){this.super=n;var r=e.apply(this,arguments);return o(r,(()=>(delete this.super,r)))}:l(e)?c(e):e,r._isConstructor=!0,r},h=function(e,n){return e._isConstructor?e:f(e,n)},p=function(){return this},d=function(e){return class extends e{constructor(e,n){super(e,n);var r=this.constructor.name;r&&(this.name=r)}}},v=d(globalThis.Error),m=function(e,n,r){var i=new v(e,r);return n&&Object.assign(i,n),i},y=class extends v{constructor(e,n){super(e??"Not yet implemented",n)}},g=function(e,n,r,i){var u=e[n];if(void 0===u){var o=r;!1!==i&&s(o)&&(o=o(e,n)),e[n]=u=o}return u},w=function(e,n,r,i){return e||(e={}),g(e,n,r,i),e},b=function(e,n){return w(e,"fromFn",n,!1)},E=function(e,n){return new y(e,b(n,E))},x=function(e){var n=typeof e;return"object"!==n&&"function"!==n||null===e},_=function(e){return!x(e)},k=function(e,n,r){return Object.defineProperty(e,n,{value:r,writable:!0,enumerable:!1,configurable:!0}),r},L=k,F=function(e,n){Object.defineProperty(e,"name",{value:n,configurable:!0}),L(e,"displayName",n)},S=F,A=function(e,n){return Object.assign(e,n)},O=function(e){var n,r=!1;return function(){return r||(r=!0,n=e.apply(this,arguments)),n}},T=O((function(){return"undefined"==typeof window})),C=T()?require("util").inspect.custom:Symbol("Display"),I=function(e,n){e.prototype[C]=n},j=function(e,u,s,a,l,c){c||(c={}),n(u)&&(u=null);var d,v,y,g=s;if(g)if(r(g)){if([v,y]=g,v)if(r(v)){if(!u)throw m("Bare args array for instanceFn is only valid when extending a class.");var w=v;v=null,d=f((function(){this.super.apply(this,w)}),u)}else v=h(v)}else d=h(g,u);var b=c.bareFn;c.singleton&&(b=function(){return null==F.default&&(F.default=new F(...arguments)),F.default});var x,k=v||d||u||p;function F(){if(!new.target&&b&&!(this instanceof F))return b.apply(this,arguments);var e=this;return o(k.apply(e,arguments),(n=>{if(n&&_(n)&&(e=n,v)){if(!new.target)throw E('Prototype repair is NYI for class instantiation without "new".');if(!u)throw E("instanceFn is not yet supported when extendsClass is null.");var r=Object.getPrototypeOf(this);Object.getPrototypeOf(e)!==r&&Object.setPrototypeOf(e,r)}return y?o(y.apply(e,arguments),(()=>e)):e}))}return e&&S(F,e),a?(x=a,u&&Object.setPrototypeOf(a,u.prototype)):x=u?Object.create(u.prototype):{},L(x,"constructor",F),F.prototype=x,l&&A(F,l),c.display&&I(F,c.display),c.implements&&i(c.implements).forEach((e=>e(F))),F},P=function(e,n){Object.defineProperty(e,n,{enumerable:!1})},N=P,R=function(e,n,r,i,u){var o=Symbol();return j(e,Function,[function(){var e=function(){return e[o].apply(this,arguments)};return e},function(){var e=n.apply(this,arguments);if(!e)throw new Error("Constructor must return a function.");this[o]=e,N(this,o)}],r,i,u)},q=function(e){return n=>n===e},M=function(e){return Reflect.ownKeys(e)},D=function(e,n){return(n?M:Object.keys)(e)},B=function(e,n,r){var i={};for(var u of n)Object.hasOwn(e,u)&&(i[u]=e[u],!0===r&&delete e[u]);return i},W=function(e){return e instanceof Set},H=function(e){return W(e)?e:r(e)?new Set(e):new Set([e])},K=H,Y=function(e,n){var r=[],i=[];return e.forEach(((u,o)=>(n(u,o,e)?r:i).push(u))),[r,i]},U=function(e,n,r,i){var u=n;if(s(u))throw E();var o=D(e,i),a=K(u),[l,c]=Y(o,(e=>a.has(e)));return[B(e,l,r),!0===r?e:B(e,c,!1)]},z=function(e,n,r){var i=D(e,r).filter((r=>n(e[r],r,e)));return U(e,i,!1,r)},V=function(e,n){return n<e?n:e},G=function(e,n){return V(e,n)},Q=function*(e,n){null==e&&(e=0),n=null==n?this.length:G(n,this.length);for(var r=e;r<n;r++)yield this[r]},J=function(e,n,r){return null==n&&null==r?e[Symbol.iterator].call(e):Q.call(e,n,r)},$=function(e,n){return n<0?e.length+n:n},X=function(e,n,r,i){return n=null==n?0:$(e,n),r=null==r?e.length:$(e,r),i&&(0==i.inclusiveStart&&n++,i.inclusiveEnd&&r++),[n,r]},Z=function(e,n,r,i){[r,i]=X(e,r,i);for(var u=r;u<i;u++){var o=n(e[u],u,e);void 0!==o&&(e[u]=o)}return e},ee=function(e,n){return n?Z(D(e,n),(n=>[n,e[n]])):Object.entries(e)},te=function(e){return J(ee(this,e))},ne=function(e,n){var r=e[Symbol.iterator];return r?r.call(e):te.call(e,n)},re=function(e){return ne(e,!0)},ie=function(e,n){return null!=e&&e.constructor===n},ue=function(e){return ie(e,Object)},oe=ue,se=function(e,n,r){Object.defineProperty(e,n,{get:r,enumerable:!0,configurable:!0})},ae=function(e,n,r){Object.defineProperty(e,n,{value:r,writable:!0,enumerable:!0,configurable:!0})},le=function(e,n,r){se(e,n,(function(){if(this===e)return null;var i=r.call(this);return ae(this,n,i),i}))},ce=class extends v{constructor(e,n){super(e??"Unexpected value",n)}},fe=function(e){return require("node:"+e)},he=function(e){return O((()=>fe(e)))},pe=he("util"),de=function(e,n){return n||(n={}),null==n.colors&&(n.colors=!0),pe().inspect(e,n)},ve=$,me=function(e,n,r,i){return void 0!==n&&(null===n||0===n?n=void 0:(n=ve(e,n),i&&0==i.inclusiveStart&&n++)),void 0!==r&&(null===r||r===e.length?r=void 0:(r=ve(e,r),i&&i.inclusiveEnd&&r++)),[n,r]},ye=function(e,n,r,i,u,o){if(r||null!=i){[r,i]=me(e,r,i,o);var s=e.slice(r,i),a=n(s);return u?u(a,r,i,s,e):a}return n(e)},ge=function(e,n,r,i,u){return ye(e,n,r,i,((n,r,i)=>(void 0!==r?e.slice(0,r):"")+(n||"")+(void 0!==i?e.slice(i):"")),u)},we=ie,be=function(e){return we(e,RegExp)},Ee=function(e,n,r,i){var u=n;if([r,i]=X(e,r,i),s(u))for(var o=r;o<i;o++)e[o]=u(o,e);else e.fill(u,r,i);return e},xe=function(e,n){var r=new Array(e||0);return arguments.length>1&&Ee(r,n),r},_e=function(e,n){return xe(n.length,(r=>e[n[r]]))},ke=function(e,n){return e[n]},Le=function(e,n,r){return e[n]=r},Fe=function(e,n,r){var i=e;return s(i)?i.apply(r,n):i},Se=function(e,n,r,i,u){i||(i=ke);var o=i(e,n);return void 0===o&&(o=Fe(r,[e,n]),u||(u=Le),u(e,n,o)),o},Ae=function(e,n){return e.get(n)},Oe=function(e,n,r){return e.set(n,r)},Te=function(e,n,r){return Se(e,n,r,Ae,Oe)},Ce=class{constructor(){this.store=new Map}get(e,n){return Te(this.store,e,n)}remove(e){return this.store.delete(e)}delete(e){return this.remove(e)}},Ie=function(e,n){return e.push(n),e},je=Ie,Pe=function(e){var n=e;return Array.isArray(n)?n:Array.from(n)},Ne=Symbol("Value"),Re=function(){return{}},qe=function(e){return[e.slice(0,-1),e[e.length-1]]},Me=qe,De=function(e,n,r,i,u,o){r||(r=ke),null==i&&(i=Re),null==u&&(u=Le),null==o&&(o=r);for(var[s,a]=Me(n),l=e,c=s.length,f=0;f<c;f++){var h=s[f],p=r(l,h);if(void 0===p){if(!i)return;p=Se(l,h,i,r,u)}l=p}if(o)return o(l,a,u)},Be=function(e,n,r,i,u,o){return De(e,n,i,u,o,((e,n)=>Se(e,n,r,i,o)))},We=function(){return new Map},He=function(e,n,r){return Be(e,n,r,Ae,We,Oe)},Ke=function(e,n){return delete e[n],e},Ye=function(e,n,r,i){return De(e,n,r,!1,!1,i||Ke)},Ue=function(e,n){return e.delete(n)},ze=function(e,n){return Ye(e,n,Ae,Ue)},Ve=class{constructor(){this.store=new Map}get(e,n){return e=je(Pe(e),Ne),He(this.store,e,n)}remove(e){return e=je(Pe(e),Ne),ze(this.store,e)}delete(e){return this.remove(e)}},Ge=R("MemoizedFunction",(function(e,n){if(this.base=e,null!=n)if(1===(n=i(n)).length){this.cache=new Ce;var r=n[0];this._cacheKeyFormatter=e=>e[r]}else this.cache=new Ve,this._cacheKeyFormatter=e=>_e(e,n);else this.cache=new Ve,this._cacheKeyFormatter=e=>e;var u=this;return function(){var n=u._cacheKeyFormatter(arguments);return u.cache.get(n,(()=>e.apply(this,arguments)))}}),{remove(e){return this.cache.remove(this._cacheKeyFormatter(e))}}),Qe=function(e,n){return new Ge(e,n)},Je=function(e){return new Set(e)},$e=function(e){var n={};if(e){var r=Je(e);r.has("g")&&(n.global=!0),r.has("i")&&(n.caseInsensitive=!0),r.has("y")&&(n.sticky=!0)}return n},Xe=function(e){var n="";return e.global&&(n+="g"),(e.caseInsensitive||0==e.caseSensitive)&&(n+="i"),e.sticky&&(n+="y"),n},Ze=function(e,n){var r=$e(e);return Xe(Object.assign(r,n))},et=function(e,r){var i=r,u=void 0;return n(i)?u=i:ue(i)&&(u=Ze(e.flags,i)),new RegExp(e,u)},tt=function(e,n){return et(e,e.flags+n)},nt=function(e){return tt(e,"g")},rt=Qe((function(e){return e.global?e:nt(e)}),0),it=function(e){var r=e;return null==r?void 0:n(r)?r:Xe(r)},ut=function(e,n){return new RegExp(e,it(n))},ot=function(e){return e.replace(/[-[\]{}()*+!<=:?.\/\\^$|#\s,]/g,"\\$&")},st=function(e,n){return ut(ot(e),n)},at=function(e,r,i,u,o,s){return ge(e,(function(e){return e.replaceAll?(be(r)&&(r=rt(r)),e.replaceAll(r,i)):(r=n(r)?st(r,"g"):rt(r),this.replace(r,i))}),u,o,s)},lt=function(e,n,r){return at(e,n,(r??"\\")+n)},ct=function(e,n,r){return null==n&&(n='"'),!1!==r&&(e=lt(e,n,r)),n+e+n},ft=function(e){return ct(e,'"')},ht=function(e){return oe(e)?yt(e):String(e)},pt=function(e,n){return n||(n=dt),"["+e.reduce((function(e,r){return e+n(r)+", "}),"").slice(0,-2)+"]"},dt=function(e){return n(e)?ft(e):r(e)?pt(e):ht(e)},vt=function(e,n,r){D(e,r).forEach(((r,i,u)=>n(r,e[r],i,u)))},mt=function(e,n,r,i){var u=null!=r?r:"";return vt(e,(function(){u=n.call(this,u,...arguments)}),i),u},yt=function(e,n){return n||(n=dt),"{"+mt(e,(function(e,r,i){return e+r+":"+n(i)+", "}),"",!0).slice(0,-2)+"}"},gt=function(e,n){return null==n&&(n=1),n<=0?"[object Object]":yt(e,(e=>bt(e,n-1)))},wt=function(e,n){return null==n&&(n=1),n<=0?"[object Array]":pt(e,(e=>bt(e,n-1)))},bt=function(e,n){return void 0===e?"undefined":null===e?"null":T()?de(e,n):ue(e)?gt(e,maxNumLevels):r(e)?wt(e,maxNumLevels):ht(e)},Et=function(e,n,r,i){if(0===arguments.length)return new ce("Unexpected value received");i||(i={});var u,{expected:o}=i;return u=o?"Received "+bt(e)+", expected one of "+bt(o):"Unexpected value received: "+bt(e),r&&(u+=' for "'+r+'"'),null!=n&&(u+=" (index "+n+")"),i.fromFn||(i.fromFn=Et),new ce(u,i)},xt=function*(e,n){yield*e,yield*n},kt=function(e){return e?" "+e:""},Lt=function(e){return n(e)?e:e.toString()},Ft=R("Interface",(function(e,n,r){r||(r={}),F(this,e),n?[this.stubs,this.defaults]=z(n,q(!0),!0):(this.stubs={},this.defaults={});var u=r.implements?i(r.implements):null,o=this;return function(e){var n=e;return u&&u.forEach((e=>e(n))),o.decorate(n),o.assert(n),n}}),{decorate(e){var n,r,i=e;for(var[u,o]of(i.prototype?(n=i.prototype,r=!0):(n=i,r=!1),re(this.defaults)))if(void 0===n[u])if(oe(o))if(o.value)n[u]=o.value;else{if(!o.setup)throw Et(o,null,"defaultVal");if(!r)throw o.setup(),E("setupFn is NYI for instances");le(n,u,o.setup)}else n[u]=o;return i},assert(e){var n=e,r=null!=n.prototype,i=n.prototype||n,u=xt(re(this.stubs),re(this.defaults));for(var[o]of u){var s;if(void 0===i[o])throw s=r?"Class"+kt(n.name):"Object "+bt(n),s+=" does not satisfy interface "+this.name+' (missing key "'+Lt(o)+'")',m(s)}return n},validate(e){try{return this.assert(e),!0}catch(e){return!1}}},{is(e){return e instanceof this}}),St=function(e,n,r){return new Ft(e,n,r)},At=Symbol("Cleanup"),Ot=St("Handle",{remove:!0,[At](){this.remove()}}),Tt=e(class{constructor(e){this.handles=e}remove(){this.handles.forEach((e=>e.remove()))}add(e){return this.handles.push(e),this}},Ot),Ct=function(e){return 1===e.length&&r(e[0])?e[0]:array},It=function(...e){return new Tt(Ct(e))},jt=It,Pt=jt,Nt=function(e){var n,r,i=e;return null!=i&&(n=i.detail??i.data??i,_(i)&&(r=i)),[n,r,i]},Rt=function(e){return Ft.is(e)},qt=Rt,Mt=d(globalThis.TypeError),Dt=function(e){return null==e?e:e.constructor},Bt=function(e,n,r,i){if(0===arguments.length)return new Mt("Unexpected type received");i||(i={});var u,{type:o,expected:s}=i;return null==o&&(o=Dt(e)),o&&o.name&&(o=o.name),s?(s.name&&(s=s.name),u="Expected "+s+", received "):u="Unexpected type received (",u+=o,null!=e&&(u+=" ("+bt(e)+")"),s||(u+=")"),r&&(u+=' for "'+r+'"'),null!=n&&(u+=" (index "+n+")"),i.fromFn||(i.fromFn=Bt),new Mt(u,i)},Wt=function(e,n,r){if(!qt(n))throw Bt(n,1);return n.decorate(e),r&&r.call(e,e,n),n.assert(e),e},Ht=St,Kt=Symbol("EventTarget"),Yt=function(e){return require(e)},Ut=function(e){return!!e.startsWith("node:")||Yt("node:module").isBuiltin(e)},zt=function(e){return e.startsWith(".")},Vt=function(e){var i=e.stdio;if(i){if(!r(i)){if(!n(i))throw Bt(i,"stdio");if("pipe"===i)i=["pipe","pipe","pipe"];else if("inherit"===i)i=["inherit","inherit","inherit"];else if("ignore"===i)i=["ignore","ignore","ignore"];else{if("overlapped"!==i)throw Et(i,"stdio");i=["overlapped","overlapped","overlapped"]}e.stdio=i}}else i=e.stdio=[null,null,null];return i},Gt=function(e,n){var r=n.length;e.length=r;for(var i=0;i<r;i++)e[i]=n[i];return e},Qt=function(e){return function(){return!e.apply(this,arguments)}},Jt=function(e,n){return Gt(e,e.filter(Qt(n)))},$t=function(e){return Jt(e,(e=>null==e))},Xt=he("child_process"),Zt=O((function(){return"win32"===process.platform})),en=function(e,n,r){if(r||(r={}),n(e))throw e;if(r.nullOnErr&&(r.err=null),void 0!==r.err)return r.err;if(r.onErr)return r.onErr(e,e.stderr);throw e},tn=function(e,n,r){r||(r={}),r.dir&&(r.cwd=r.dir);var i=Vt(r);if(null==i[0]){var u=r.allowInput,o=r.input;if(u&&o)throw m("allowInput (user) and input (programmatic) cannot be used simultaneously for synchronous child processes.");u&&(i[0]="inherit")}if(null==i[1]){var s=r.captureOutput??!1,a=r.showOutput;if(s&&a)throw m("captureOutput and showOutput cannot be used simultaneously for synchronous child processes.");s?i[1]="pipe":(null==a&&(a=!0),i[1]=a?"inherit":"ignore")}if(null==i[2]){var l=r.captureErr??!1,c=r.showErr;if(l&&c)throw m("captureErr and showErr cannot be used simultaneously for synchronous child processes.");l?i[2]="pipe":(null==c&&(c=!0),i[2]=c?"inherit":"ignore")}r.encoding||(r.encoding="utf8"),n&&$t(n);try{var f=Xt().execFileSync(e,n,r);null!=f&&(f=f.trim());var h=r.map??r.mapFn;return h&&(f=h(f)),f}catch(e){if(Zt())return en(e,(e=>"ENOENT"===e.code),r);throw e}},nn=function(e,n){return n||(n={}),null==n.captureOutput&&(n.captureOutput=!1),n.shell=!0,n.filterExtensions=!1,tn("npm",e,n)},rn=function(e,n,r){return nn(["install",e,n?"-g":null],r)},un=he("path"),on=function(e,n){var r=un().resolve;return n?r(n,e):r(e)},sn=function(e){return require(on(e))},an=class{constructor(){this.store={}}get(e,n){return g(this.store,e,n)}remove(e){return delete this.store[e]}delete(e){return this.remove(e)}},ln=new an,cn=he("module"),fn=function(e){return e.endsWith("\\node_modules")||(e+="\\node_modules"),cn().createRequire(e)},hn=function(e,n){return ln.get(e,(()=>fn(e)))(n)},pn=function(e,n,r){return Object.keys(n).forEach((i=>g(e,i,n[i],r))),e},dn=function(e,n,r){return n?pn(e,n,r):e},vn=function(e,n){return e.endsWith(n)?e.substring(0,e.length-n.length):e},mn=function(e){return e[e.length-1]},yn=$,gn=function(e,n,r){return e=et(e,{global:!0}),null!=r&&(n=yn(r,n)),e.lastIndex=n,e},wn=function(e,n,r){return e=null!=r?gn(e,r,n):rt(e),Array.from(n.matchAll(e))},bn=function(e,n,r){return null!=r&&(n=n.slice(0,r)),mn(wn(e,n))||null},En=function(e,n){var r=bn(e,n);return r&&n.length===r.index+r[0].length?r:null},xn=function(e,n){var r=En(n,e);return r?e.slice(0,r.index):e},_n=function(e,r){if(n(r))return vn(e,r);if(be(r))return xn(e,r);throw Bt(r,1)},kn=_n,Ln=function(e,n){return[e.slice(0,n),e.slice(n)]},Fn=function(e){e=kn(e.trim(),";");var n=Math.max(e.lastIndexOf(";"),e.lastIndexOf("\n"));return Ln(e,n+1)},Sn=function(e,n){return e.startsWith(n)?e:n+e},An=function(e){var[n,r]=Fn(e);return n+Sn(r.trim(),"return ")},On=function(e){return Gr("node-repl-await").processTopLevelAwait(e)},Tn=function(e){return On(e)??e},Cn=at,In=function(e,r){if(n(r))return e.endsWith(e);if(be(r))return!!En(r,e);throw Bt(r,1,"matchThis")},jn=/\/|\\/,Pn=function(e){return In(e,jn)?e:e+"/"},Nn=function(e,n){return""===e?e:(null==n&&(n=!0),e=Cn(e,"\\","/"),n?Pn(e):e)},Rn=function(){return process.mainModule?.filename??null},qn=function(e){return e.charAt(0).toLowerCase()+e.slice(1)},Mn=function(e){return e.split(".")[0]},Dn=function(e){return un().win32.basename(e)},Bn=function(e){return Mn(Dn(e))},Wn=function(e,n,r,i){e||(e=Rn()??"_console.js");var u=qn(Bn(e));return n&&(u+="_repl"),u+(r&&i?.dynamic?".dypkg.json":".pkg.js")},Hn=function(e,n){return e=un().dirname(e),!1===n?e:Pn(e)},Kn=function(e,n,r,i){var u,o=Wn(e,n,r,i);return u=e?Hn(e):"./",on(u+o)},Yn=function(e){return'require("'+Nn(Kn(),!1)+'");\n'+e},Un=function(e,n){return at(e,n,"")},zn=function(e,n){return n.forEach((n=>e=Un(e,n))),e},Vn=function(e){return zn(e,["\r","\n"])},Gn=function(e,n){return Gr("astring").generate(e,n)},Qn=function(e,n){return e.stack=n+"\n"+e.stack,e},Jn=function(e,n,r){r||(r={}),!1!==n&&(r.sourceType="module"),null==r.allowAwaitOutsideFunction&&(r.allowAwaitOutsideFunction=!0);var i=Gr("acorn-node");try{return i.parse(e,r)}catch(n){throw Qn(n,"Acorn parsing error: "+e)}},$n=function(e,n,r){return Gn(Jn(e,n,r))},Xn=function(e){return Vn($n(e))},Zn=function(e,n,r){return(n||r)&&(n||(n={}),r&&dn(n,r),n.ensureReturn&&(e=An(e)),n.topLevelAwait&&(e=Tn(e)),n.useTitan&&(e=Yn(e)),n.keepAlive&&(e="\nsetInterval(()=>{}, 100000);\n"+e),(n.logErrors||n.keepAlive)&&(e="process.on('uncaughtException', console.error);\nprocess.on('unhandledRejection', console.error);\n"+e),n.inline&&(e=Xn(e))),e},er=function(e){return n(e)?e:ht(e)},tr=function(e){var n=e.indexOf("{");return-1===n||e.slice(0,n).includes("=>")},nr=function(e,n,r,i,u){return ye(e,n,r,i,((n,r)=>null===n?null:(n.input=e,void 0!==r&&(n.index+=r),n)),u)},rr=function(e,n){return e.splice(e.length,0,...n),n},ir=function(e,n){return rr(e,n),e},ur=ir,or=class extends Array{constructor(e,n,r,i,u){if(-1===n)throw m("RegexResult index cannot be -1. For empty result, use bare null.");if(null==e)throw m("RegexResult matchString cannot be null. For empty result, use bare null.");super(),this[0]=e,i&&ur(this,i),this.index=n,this.input=r,u&&(this.groups=u)}fromParts(e){var n=e;return new or(n.match,n.index,n.input,n.captures,n.groups)}},sr=function(e,n,r,i,u){return new or(e,n,r,i,u)},ar=function(e,n,r,i,u){return-1===n||null==e?null:sr(e,n,r,i,u)},lr=Un,cr=function(e,n){return et(e,lr(e.flags,n))},fr=function(e){return cr(e,"g")},hr=Qe((function(e){return e.global?fr(e):e}),0),pr=function(e,n,r){return(e=null!=r?gn(e,r,n):hr(e)).exec(n)},dr=function(e,r,i,u,o){return nr(e,(e=>{if(n(r)){var i=e.indexOf(r);return ar(r,i,e)}return pr(r,e)}),i,u,o)},vr=function(e){return e.index+e[0].length},mr=function(e,n){var r=dr(e,n);return null===r[0]?null:e.slice(vr(r))},yr=function(e,n){return e.startsWith(n)?e.substring(n.length):e},gr=function(e,n){var r=pr(e,n);return r&&0===r.index?r:null},wr=function(e,n){var r=gr(n,e);return r?e.slice(r[0].length):e},br=function(e,r){if(n(r))return yr(e,r);if(be(r))return wr(e,r);throw Bt(r,1)},Er=br,xr=function(e){var n=mr(e,"=>").trim();return Er(kn(n,"}"),"{")},_r=function(e){return mr(e,"{").slice(0,-1)},kr=function(e){var n=er(e);return tr(n)?xr(n):_r(n)},Lr=function(e){return null==e?"":n(e)?e:s(e)?kr(e):String(e)},Fr=function(e,n){var r=n?.basic?null:{topLevelAwait:!0,useTitan:!0},i=Zn(Lr(e),n,r);return tn("node",["-e",i],n)},Sr=function(e,n,r,i){var u="Required argument";return r&&(u+=' "'+r+'"'),null!=n&&(u+=" (index "+n+")"),u+=" missing",arguments.length>0&&(u+=" (received "+bt(e)+")"),m(u,null,b(i,Sr))},Ar=function(e,n,r){if(null==e)throw Sr(e,n,r,{fromFn:Ar});return e},Or=function(e,n){return process.kill(e,Ar(n,0,"signalName"))},Tr=function(e){return Or(e,"SIGINT")},Cr=function(){return Tr(process.pid)},Ir=Cr,jr=function(e){if("Y"===(e=e.toUpperCase()))return!0;if("N"===e)return!1;throw Et(e,0,"char")},Pr=function(e){null==e&&(e="Are you sure? [y/n]: "),process.stdout.write(e);var n=Fr((function(){const e=process.stdin,n=process.stdout;e.setRawMode(!0),e.setEncoding("utf8"),e.on("data",(e=>{var r=e.toUpperCase();"Y"===r||"N"===r?(n.write(e),process.exit(0)):""===e&&(n.write("^C"),process.exit(0))}))}),{basic:!0,stdio:["inherit","pipe"]});if("^C"===n)throw process.stdout.write(n),Ir(),m("Prompt was cancelled via interrupt.");return console.log(n),jr(n)},Nr=function(e){return r(e)?e:n(e)?e.split("."):[e]},Rr=function(e,n,r,i,u,o){var s=r;return De(e,n,i,u,o,((e,n,r)=>r(e,n,Fe(s))))},qr=function(e,n){var r=n,i=globalThis.config;i||(i=globalThis.config={});var u,o=Nr(e);return o.length>1?u=Rr(i,o,r):(u=Fe(r),i[o[0]]=u),u},Mr=function(e,n){return qr("node.require.customDirs",(r=>(r||(r=[]),!1!==n&&(e.endsWith("node_modules")||(e+="\\node_modules")),r.includes(e)||r.push(e),r))),e},Dr=Mr,Br=De,Wr=function(e){var n=globalThis.config;if(n){var r=Nr(e);return r.length>1?Br(n,r):n[r[0]]}},Hr=function(e,n,r){if(null!=e)return e;var i=Wr(n);return null!=i?i:r},Kr=he("fs"),Yr=function(e){return!!Kr().lstatSync(e,{throwIfNoEntry:!1})},Ur=function(e){var n=Hn(e,!1);return Yr(n)||(n!==e&&Ur(n),Kr().mkdirSync(n)),e},zr=function(e){return Ur(e),Kr().mkdirSync(e),e},Vr=function(e){return Yr(e)?e:zr(e)},Gr=function(e,n){if(Ut(e))return require(e);if(zt(e))return sn(e);try{return require(e)}catch(e){}var r=__dirname,i=process.mainModule?.path;if(i!==r)try{return hn(i,e)}catch(e){}var u=process.cwd();if(u!==i&&u!==r)try{return hn(u,e)}catch(e){}var o=Wr("node.require.customDirs");if(o)for(var s of o)try{return hn(s,e)}catch(e){}var a=Hr(n?.autoInstall,"node.require.autoInstall"),l=Hr(n?.promptInstall,"node.require.promptInstall",!0);if(a||l){var c=a||l;!0===c&&(c="./node_modules"),c=on(c);var f=!1;if(a?(f=!0,console.log('Auto-installing "'+e+'" from npm to "'+c+'"...')):(f=Pr('Npm package "'+e+'" is required. Install now? (Y/N) '))&&console.log('Installing "'+e+'" from npm to "'+c+'"...'),f){c=Vr(c),rn(e,!1,{cwd:c});try{return Dr(c),hn(c,e)}catch(e){console.error("Failed to load from auto-install dir: ",c)}}}throw m('Module not found: "'+e+'"',{checked:{moduleDir:r,scriptDir:i,cwd:u}})},Qr=O((function(){if(!globalThis.CustomEvent||!globalThis.EventTarget||!globalThis.Event){var e=Gr("event-target-shim");globalThis.Event||(globalThis.Event=e.Event),globalThis.CustomEvent||(globalThis.CustomEvent=class extends globalThis.Event{constructor(e,n){super(e,n),n?.detail&&(this.detail=n.detail)}}),globalThis.EventTarget||(globalThis.EventTarget=e.EventTarget)}return{Event:Event,CustomEvent:CustomEvent,EventTarget:EventTarget}})),Jr=Qr().EventTarget,$r=function(e){var n=Kt,r=e[n];return void 0===r&&(r=new Jr,L(e,n,r)),r},Xr=Ht("EventInterface",{addEventListener(e,n,r){$r(this).addEventListener(e,n,r)},on(e,n){this.addEventListener(e,n)},removeEventListener(e,n){$r(this).removeEventListener(e,n)},off(e,n){this.removeEventListener(e,n)},dispatchEvent(e){return $r(this).dispatchEvent(e)}}),Zr=Xr,ei=function(e){return Wt(e,Zr)},ti=function(e){return!(!e.addEventListener&&!e.on)},ni=function(e){return ti(e)||ei(e),e},ri=function(e,n,r){return e[n]=r,e},ii=function(e,n,r){return ri(e||{},n,r)},ui=function(e,n,r,i){return mi(e,n,r,ii(i,"once",!0))},oi=function(e,n){return function(){var r=n.apply(this,arguments);return e.apply(this,arguments),r}},si=oi,ai=function(e,n,r){return e[n]=si(e[n],r)},li=e(class{constructor(e){this._remover=e}remove(){this._remover()}removeOn(e,n,r){r&&ni(e);var i=ui(target,n,(()=>this.remove()));return ai(this,"remove",(()=>i.remove())),this}},Ot),ci=class extends li{constructor(e,n){super(e),this.handleEvent=n}},fi=function(e,n){return new ci(e,n)},hi=function(e,n,r){(e.removeEventListener||e.off).call(e,n,r)},pi=function(e,n,r){for(var i=e.length-1;i>=n;i--)e[i+1]=e[i];return e[n]=r,e.length++,e},di=function(e,n){return pi(e,0,n)},vi=di,mi=function(e,n,r,i){if(i?.valueFirst){var u=r;r=function(e){var[n,r]=Nt(e);return vi(arguments,n),arguments[1]=r,u.apply(this,arguments)}}var o=e.addEventListener;return o||(e.on?o=i?.once?e.once:e.on:(ei(e),o=e.addEventListener)),o.call(e,n,r,i),fi((()=>hi(e,n,r)),r)},yi=function(e,n,r,i){return Pt(n.map((n=>mi(e,n,r,i))))},gi=O((function(){return process.argv.slice(2)})),wi=gi,bi=function(e){const n=[];let r="",i="outside",u=!1;for(let o=0;o<e.length;o++){const s=e[o];switch(i){case"outside":'"'===s?u?(r+=s,u=!1):i="insideQuote":"\\"===s?u=!0:" "===s?(r.length>0&&(n.push(r),r=""),u=!1):(r+=s,u=!1);break;case"insideQuote":'"'!==s||u?"\\"!==s||u?(r+=s,u=!1):u=!0:i="outside"}}return r.length>0&&n.push(r),n},Ei=function(){return globalThis.repl?.repl},xi=function(e,n){return null==n&&(n=1),function(){var r=Array.from(arguments),i=r.pop(),u=e.apply(this,r);0===n?(u.then((e=>i(null,e))),u.catch(i)):(u.then(i),u.catch((e=>i.apply(null,ri([],n,e)))))}},_i=async function(){}.constructor,ki=function(e){return ie(e,_i)},Li=function(e){return ki(e)?e:async function(){return e.apply(this,arguments)}},Fi=O((function(){return Gr("node:stream")})),Si=T()&&Fi().Writable,Ai=function(e,n){return n||(n={}),null==n.objectMode&&(n.objectMode=!0),e?n.write=xi(Li(e),0):n.write||(n.write=(e,n,r)=>r()),new Si(n)},Oi=function(){},Ti=async function(e){var n=Ei();if(n){var r,i=n.eval,u=n.output;n.output=Ai(Oi),n.eval=Oi;try{n.quickDisableHistory?await n.quickDisableHistory((async function(){r=await e(),n._line()})):r=await e()}finally{n.output=u,n.eval=i}return r}return e()},Ci=he("readline"),Ii=/\r?\n/,ji=function(e){return null==e||void 0!==e.length&&0===e.length},Pi=function(e,n){return Jt(e,ji)},Ni=function(e,n){return e.splice(n,1),e},Ri=function(e,n,r){for(var i={},u=e.length,o=0;o<u;o++){var s=n(e[o],o,e);if(s){var[a,l]=s;r?(i[a]||(i[a]=[]),i[a].push(l)):i[a]=l}}return i},qi=function(e,n,r,i){return[n,r]=X(e,n,r,i),e.slice(n,r)},Mi=function(e,n){return xe(n,e).join("")},Di=function(e){return e?e[0]:null},Bi=function(e,n){var r=null==n?-1:n.index;if(-1===r)return[e];var i=Ln(e,r);return i[1]=i[1].slice(n[0].length),i},Wi=function(e,n,r,i,u){return Bi(e,dr(e,n,r,i,u))},Hi=function(e){return isNaN(e)?null:e},Ki=function(e){return null==e?null:Hi(Number(e))},Yi=Ki,Ui=function(e){return Yi(e)??e},zi=function(e,n){null==n&&(n="=");var r={};return e.forEach((function(e){var[i,u]=Wi(e,n);null!=u&&(u=Ui(u.trim())),r[i.trim()]=u})),r},Vi=w,Gi=class extends Array{constructor(e){var i,u=e;null!=u&&(r(u)?i=u:n(u)&&(i=u.split(Ii))),i?(super(i.length),Object.assign(this,i)):super(...arguments)}condense(e){return this.trim().removeEmpty(),e&&this.removeComments(e),this}trim(){return this.apply((e=>e.trim()))}removeEmpty(){return Pi(this)}removeComments(e){for(var n=0;n<this.length;n++){var r=this[n],i=r.indexOf(e);-1!==i&&(""===(r=r.slice(0,i)).trim()?(Ni(this,n),n--):this[n]=r)}return this}removeFirst(){return this.shift(),this}removeLast(){return this.pop(),this}apply(e){return Z(this,e)}join(){return super.join("\n")}toObj(e){return zi(this,e)}mapToObj(e,n){return Ri(this,e,n)}between(e,n,r){return r=Vi(r,"inclusiveEnd",!0),qi(this,e,n,r)}normalize(){if(this.length>0&&(""===this[0].trim()&&this.shift(),this.length>0&&(""===mn(this).trim()&&this.pop(),this.length>0))){var e=this.find((e=>""!==e.trim())),n=Di(pr(/^\s*/,e));if(n){var r=n.length;this.apply((e=>{if(e.startsWith(n))return e.slice(r)}))}}return this}deindent(e,n,r){throw E()}indent(e,n){var r=Mi(n??"\t",e??1);return this.apply((e=>r+e))}static is(e){return ie(e,this)}static fromChunks(e){return e.map((e=>kn(e,Ii))).flatMap((e=>Ji(e,!1)))}},Qi=function(e,n){var r=new Gi(e);return n&&r.condense(),r},Ji=function(e,n,r){var i=e.split(Ii);return n?Qi(i,r):i},$i=function(e){return Kr().readFileSync(e,"utf8")},Xi=$i,Zi=function(e,n){return Ji(Xi(e),!0,n)},eu=function(e){return"number"==typeof e},tu=function(e){return e instanceof Buffer},nu=function(e){return ArrayBuffer.isView(e)},ru=nu,iu=function(e){return tu(e)||ru(e)||n(e)},uu=function(e){return e.constructor===ArrayBuffer},ou=function(e){return iu(e)?e:uu(e)?Buffer.from(e):ht(e)},su=function(e){return eu(e)?String(e):ou(e)},au=function(e,n){return Ur(e),Kr().appendFileSync(e,su(n)),e},lu=function(e,n){return au(e,"\n"+n)},cu=lu,fu=function(e){return at(e,"\n","\\n")},hu=fu,pu=function(e,n){if(0===e)return n[0];for(var r=n.length,i="";e>0;){var u=e%r;i=n.charAt(u)+i,e=Math.floor(e/r)}return i},du="0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZ",vu=function(e){return pu(e,du)},mu=function(e,n){for(var r=er(e),i=n.length,u=0,o=0;o<r.length;o++){var s=r[o],a=n.indexOf(s);if(-1===a)throw'Error: "'+s+'" not found in base charset "'+n+'"';u=u*i+a}return u},yu=function(e){return mu(e,du)},gu=function(e,n){return Object.keys(e).map(((r,i)=>n(r,e[r],i,e)))},wu=function(e){return e.slice()},bu=function(e,n){return e.includes(n)||e.push(n),e},Eu=class{constructor(e,n,i,u){(n=r(n)?wu(n):[n]).forEach(u),e&&bu(n,e),this.members=n,this._enableFn=i,this._disableFn=u}enable(e){this.members.forEach((n=>{n!==e&&this._disableFn(n)})),this._enableFn(e)}disableAll(){this.members.forEach((e=>this._disableFn(e)))}},xu=function(e,n,r,i){return new Eu(e,n,r,i)},_u=function(e,n,r){return new Promise((function(i,u){var o=Pt([ui(e,n||"load",(e=>{o.remove(),i(e)})),ui(e,r||"error",(e=>{o.remove(),u(e)}))])}))},ku=j("CLI",T()&&Ci().Interface,[function(e){if(e||(e={}),e.input||(e.input=process.stdin),e.output||null==e.output&&(e.output=process.stdout),null==e.terminal&&(e.terminal=!0),e.historyPath){var n=Yr(e.historyPath)?Zi(e.historyPath):[];e.history=n.reverse()}var r={inputWasRaw:e.input.isRaw},i=Ci().createInterface(e);return i.options=e,i.internal=r,i},function(){var e=this.options;this.rl=Ci(),e.historyPath&&this.on("history",(n=>cu(e.historyPath,n[0]))),e.disabled&&this.disable()}],{prompt(e){this._muted||(this._isPrompt=!0,null!=e&&this.setPrompt(e),super.prompt.apply(this,arguments),delete this._isPrompt)},_refreshLine(){this._muted||(this._isRefresh=!0,super._refreshLine(...arguments),delete this._isRefresh)},_ttyWrite(e,n){(!this._blockExcept||n&&this._blockExcept.includes(n.name))&&super._ttyWrite.apply(this,arguments)},_addHistory(){return this._historyDisabled||null!=this._mask||super._addHistory(),this.line},_writeToOutput(e){if(!this._muted){var n=this._mask;if(null!=n){if(this._isRefresh){var r=this._prompt;e.startsWith(r)&&(super._writeToOutput(r),e=e.slice(r.length))}this._isPrompt||(e=Cn(e,/[^\r\n]/,n))}super._writeToOutput(e)}},async promptLine(e){return this.prompt(e),this.awaitLine()},async prefillPrompt(e,n){var r=n,i=await Fe(r);return this.prompt(e),i&&this.write(hu(er(i))),this.awaitLine()},async promptMultiline(e,r,i,u){if(null==r&&(r="... "),null==i)i=e=>""===e,u||(u=e=>(e.pop(),e));else if(n(i)){var o=i;i=e=>e.endsWith(o)}for(var s=await this.promptLine(e),a=[s];!i(s,a.length,a);)s=await this.promptLine(r),a.push(s);return u&&u(a),a.join("\n")},async promptKey(e,n){this.prompt(e);var r=await this.quickBlockExcept(n,!1,(()=>this.awaitKey(n)));return this.newLine(),r},async promptYN(e){return"y"===(await this.promptKey(e,["y","n"])).toLowerCase()},async promptSelect(e,n,i){var u=n;i||(i={});var o=0;function a(){return o++,vu(o)}if(oe(u))u=gu(u,((e,n,r)=>[a(),e,n]));else{if(!r(u))throw Bt(u);u=u.map(((e,n)=>{if(null==e)return null;if(r(e)){var i=e[0];if(null==i)i=a();else if((i=er(i)).length>1)throw m("Input key must be a single character:",e);var u=e.length;if(1===u)return[i,i,i];if(2===u){var o=e[1];return[i,o,o]}if(3===u)return[i,e[1],e[2]];throw m("Unexpected array length in choices: "+u)}return[a(),e,e]})),$t(u)}if(u.length>35)throw m("promptSelect only supports up to 35 options.");var l=i.displayFn||((e,n)=>"["+e+"] "+n);this.quickDisableHistory((()=>{for(var e=0;e<u.length;e++){var[n,r,i]=u[e];this.write(l(n,r,i,u)+"\n")}}));var c=Ri(u,(e=>[e[0],e])),f=await this.promptKey(e,Object.keys(c)),h=c[f];if(null==h)throw Et(h,"choice");var p=h[2];return s(p)&&(p=await p(h)),i.asObj?{key:f,name:h[1],value:p}:i.asIndex?yu(f)-1:p},blockExcept(e,n){e=i(e).map((e=>String(e).toLowerCase())),0!=n&&bu(e,"return"),this._blockExcept=e},unblock(){delete this._blockExcept},async quickBlockExcept(e,n,r){var i=this._blockExcept;this.blockExcept(e,n);var u=await r();return i?this.blockExcept(i):this.unblock(),u},disable(){this.pause(),this.mute()},enable(){this._mutex?this._mutex.enable(this):this._enable()},_enable(){this.resume(),this.unmute()},mutex(e){var n=xu(this,e,(e=>e._enable()),(e=>e.disable()));this.pause(),this.resume(),n.members.forEach((e=>e._mutex=n))},mask(e){this._mask=e},unmask(){delete this._mask},mute(){this._muted=!0},unmute(){delete this._muted},disableHistory(){this._historyDisabled=!0,this._historyPrev=Oi,this._historyNext=Oi},enableHistory(){delete this._historyDisabled,delete this._historyPrev,delete this._historyNext},async quickDisableHistory(e){var n=this._historyDisabled;this.disableHistory();try{var r=await e()}finally{return n||this.enableHistory(),r}},awaitLine(){return _u(this,"line")},newLine(){this.write("\n")},newline(){return this.newLine()},onKey(e,n,i){var u=e,o=this.input;if(this.rl.emitKeypressEvents(o),o.isTTY&&o.setRawMode(!0),u){var s=n;if(r(u)){var a=u.map((e=>String(e).toLowerCase()));n=(e,n)=>{e||(e=n.name),a.includes(e.toLowerCase())&&s.call(this,e,n)}}else{var l=String(u).toLowerCase();n=(e,n)=>{e||(e=n.name),e.toLowerCase()===l&&s.call(this,e,n)}}}return mi(o,"keypress",n,i)},async awaitKey(e){return new Promise((n=>{var r=this.onKey(e,(e=>{r.remove(),n(e)}))}))},moveCursor(e,n){return this._moveCursor(e,n)},cursorLeft(e){return this.moveCursor(-e)},cursorRight(e){return this.moveCursor(e)},cursorUp(e){return this.moveCursor(null,-e)},cursorDown(e){return this.moveCursor(null,e)},close(){super.close(),this.input.setRawMode(this.internal.inputWasRaw)}}),Lu=function(e,n){return Ti((async function(){var r=new ku(n);try{var i=await e(r)}finally{r.close()}return i}))},Fu=function(e,n){return Lu((n=>n.promptLine(e)),n)},Su=async function(e,n,r){for(var i={},u=n.length,o=0;o<u;o++){var s,a=n[o];if(a.endsWith("?")&&(a=a.slice(0,-1),s=!0),void 0===(l=e[a])){var l=e[o];if(void 0===l&&!s&&(!1!==r?.prompt&&(l=await Fu(a+": ")),!l))throw Ar(void 0,o,a)}i[a]=l}return i},Au={node:{onError:function(e){return yi(process,["uncaughtException","unhandledRejection"],e)},is:T,display:de,util:pe,_builtInModule:he,requireBuiltIn:fe,require:Gr,_basicRequire:Yt,child_process:Xt,requireLocal:sn,path:un,_requireFromDir:hn,_requireDirCache:ln,_createRequire:fn,module:cn,promptYNSync:Pr,run:Fr,getScriptPath:Rn,sigint:Ir,interrupt:Cr,ensureRequireDir:Dr,addRequireDir:Mr,fs:Kr,pause:function(e){Gr("press-any-key-sync")(String(e))},beforeExit:function(e){return mi(process,"beforeExit",e)},args:gi,prompt:Fu,quickCLI:Lu,quickDisableREPL:Ti,getREPL:Ei,CLI:ku,readline:Ci},ev:{onAny:yi,multiHandle:Pt,on:mi,resolveValue:Nt,enable:ei,EventInterface:Zr,Interface:Xr,_ensureHasTarget:$r,targetSym:Kt,EventTarget:Jr,polyfill:Qr,handle:fi,ListenerHandle:ci,ensureEnabled:ni,can:ti,once:ui,off:hi,promise:_u},o:{multiHandle:jt,safeEnsure:w,ensure:g,isAny:_,setHidden:L,addNonEnumerable:k,hideKey:N,makeNonEnumerable:P,filterSplit:z,keys:D,allKeys:M,split:U,pick:B,iterateAll:re,iterate:ne,iterator:te,entries:ee,isPure:oe,is:ue,setProtoLazy:le,setGetter:se,forceSet:ae,display:gt,toLiteral:yt,constructorMatches:we,ensureCustom:Se,get:ke,set:Le,createEmpty:Re,remove:Ke,reduce:mt,each:vt,addInterface:Wt,Cache:an,setDefaults:dn,ensureMulti:pn,resolveKeys:Nr,diveGet:Br,safeSet:ii,touch:ri,fromLines:zi,safeDefault:Vi,mapArr:gu,mutex:xu,_Mutex:Eu},handle:{createMulti:It,MultiHandle:Tt,HandleInterface:Ot,Handle:li},class:{addInterface:e,create:j,setName:S,addStatics:A,setDisplay:I,isInterface:qt,interface:Ht},ifc:{create:St,Interface:Ft,is:Rt},f:{createClass:R,createConstructor:f,isArrowFn:l,isArrow:a,is:s,wrap:c,ensureConstructor:h,retThis:p,setName:F,one:O,eq:q,memoize:Qe,MemoizedFunction:Ge,not:Qt,body:kr,isArrowString:tr,_getArrowFnBody:xr,_getNormalFnBody:_r,hookAfterMethod:ai,hookAfter:si,injectAfter:oi,callbackify:xi,ensureAsync:Li,isAsync:ki,AsyncFunction:_i,noop:Oi},s:{is:n,toLiteral:ft,quote:ct,escape:lt,replaceAll:at,apply:ge,withIndices:ye,chars:Je,from:ht,spaceBefore:kt,fromKey:Lt,removeTrailing:kn,removeFromEnd:_n,_removeStringFromEnd:vn,_removeRegexFromEnd:xn,resolveIndex:yn,splitAtIndex:Ln,ensureStartsWith:Sn,replace:Cn,endsWith:In,decapitalize:qn,removeLineBreaks:Vn,removeMulti:zn,removeAll:Un,resolve:Lr,ensure:er,after:mr,match:dr,_matchWithIndices:nr,remove:lr,removeLeading:Er,removeFromStart:br,_removeStringFromStart:yr,_removeRegexFromStart:wr,splitLines:Ji,lines:Qi,LinesArray:Gi,repeat:Mi,splitFirst:Wi,_splitByMatch:Bi,escapeLineBreaks:hu,escapeNewLines:fu},a:{is:r,ensure:i,filterSplit:Y,iterate:J,iterator:Q,apply:Z,resolveIndices:X,resolveIndex:$,wrapIndices:me,wrapIndex:ve,pick:_e,create:xe,fill:Ee,push:je,add:Ie,splitLast:Me,splitTail:qe,toLiteral:pt,display:wt,unboxArgs:Ct,removeNullish:$t,removeByFilter:Jt,replaceContents:Gt,last:mn,pushMulti:ur,addMulti:ir,pushThroughMulti:rr,removeEmpty:Pi,removeIndex:Ni,mapToObj:Ri,slice:qi,copy:wu,ensureContains:bu},p:{asyncJoint:o,is:u},err:{create:m,Error:v,Enhanced:d,nyi:E,NYIError:y,defaultFromFn:b,value:Et,ValueError:ce,type:Bt,TypeError:Mt,prepend:Qn,req:Sr},v:{isPrimitive:x,constructorMatches:ie,display:bt,toLiteral:dt,resolve:Fe,type:Dt,req:Ar,isEmpty:ji,nullIfNaN:Hi},sym:{display:C,value:Ne,cleanup:At},macro:{config:function(e){}},set:{resolve:K,ensure:H,is:W},n:{cap:G,least:V,tryCoerce:Ui,tryParse:Yi,ensure:Ki,is:eu,toBase36:vu,toCustomBase:pu,_base36Digits:du,fromBase36:yu,fromCustomBase:mu},re:{is:be,ensureGlobal:rt,global:nt,addFlag:tt,copy:et,updateFlagString:Ze,parseFlagString:$e,createFlagString:Xe,createEscaped:st,create:ut,resolveFlags:it,escape:ot,matchEnd:En,matchLast:bn,matchAll:wn,setStartIndex:gn,slash:jn,safeCreateResult:ar,createResult:sr,RegexResult:or,match:pr,ensureLocal:hr,local:fr,removeFlag:cr,resultEndIndex:vr,matchStart:gr,newline:Ii,text:Di},map:{Cache:Ce,ensure:Te,get:Ae,set:Oe,MultiCache:Ve,diveEnsure:He,createEmpty:We,diveDelete:ze,remove:Ue},args:{ensureArray:Pe,unshift:vi,prepend:di,insert:pi},tree:{ensure:Be,dive:De,remove:Ye,setCustom:Rr},gen:{join:xt},npm:{isBuiltIn:Ut,isFile:zt,install:rn,_runCommand:nn},os:{run:tn,_resolveStdio:Vt},win:{is:Zt},shell:{_handleError:en},path:{abs:on,fws:Nn,ensureTrailingSlash:Pn,baseName:Bn,_removeExtsFromFile:Mn,file:Dn,dir:Hn},js:{enhance:Zn,ensureReturn:An,splitLastExpression:Fn,enableAwait:Tn,_nodeEnableAwait:On,useTitan:Yn,inline:Xn,removeComments:$n,fromAST:Gn,parse:Jn},titan:{getPackagePath:Kn,getPackageName:Wn},proc:{interrupt:Tr,signal:Or},bool:{fromYN:jr},env:{setConfig:qr,getConfig:Wr,resolveConfig:Hr,args:wi},fs:{ensureDir:Vr,exists:Yr,mkdir:zr,ensureParent:Ur,loadLines:Zi,loadText:Xi,load:$i,appendLine:cu,addLine:lu,append:au,formatRaw:su},cli:{parseArgs:function(e){for(var r,i=[],u=!1,o=(r=null==(a=e)?wi():n(a)?bi(a):a).length,s=0;s<o;s++){var a=r[s];if(!u){var l=a[0];let e;if("-"===l)if("-"===a[1]){if(2===a.length){u=!0;continue}e=2}else e=1;else"/"===l&&(e=1);if(e){var c,f,h=a.slice(e),p=h.indexOf("=");if(-1!==p)c=h.slice(0,p),f=h.slice(p+1);else{c=h;var d=r[s+1];null==d||"-"===d[0]?f=!0:(f=d,s++)}i[c]=f;continue}}i.push(a)}return i},splitArgs:bi,paramFn:function(e,n){return async function(...r){var i=await Su(e,r,n);Object.assign(globalThis,i)}},validateParams:Su},stream:{nodeWritable:Ai,NodeWritableStream:Si,_useNode:Fi},bin:{ensureByteSafe:ou,isByteSafe:iu,isNodeBuffer:tu,isTA:ru},ab:{isTA:nu,is:uu}};globalThis.t?Object.keys(Au).forEach((function(e){if(t[e]){var n=Au[e];Object.keys(n).forEach((function(r){t[e][r]=n[r]}))}else t[e]=Au[e]})):globalThis.t=Object.assign({},Au),globalThis.exports&&(exports.default=globalThis.t);
1
+ var e=function(e,n){return n(e)},n=function(e){return"string"==typeof e},r=function(e){return Array.isArray(e)},i=function(e){return r(e)?e:[e]},u=function(e){return e instanceof Promise},o=function(e,n){var r=e;return u(r)?r.then(n):n(r)},s=function(e){return"function"==typeof e},a=function(e){return s(e)&&null==e.prototype},l=a,c=function(e){return function(){return e.apply(this,arguments)}},f=function(e,n){var r;return r=n?function(){this.super=n;var r=e.apply(this,arguments);return o(r,()=>(delete this.super,r))}:l(e)?c(e):e,r._isConstructor=!0,r},h=function(e,n){return e._isConstructor?e:f(e,n)},p=function(){return this},d=function(e){var n=typeof e;return"object"!==n&&"function"!==n||null===e},v=function(e){return!d(e)},m=function(e,n,r){return!1===r?Object.keys(n).forEach(r=>{void 0===e[r]&&(e[r]=n[r])}):Object.assign(e,n),e},y=function(e,n){return m(e,n,!1)},g=function(e,n,r,i){return r||(r={}),i&&y(r,i),null==r.enumerable&&(r.enumerable=!0),null==r.configurable&&(r.configurable=!0),Object.defineProperty(e,n,r)},w=function(e,n,r,i){return g(e,n,{value:r,writable:!0,enumerable:!1},i),r},b=w,E=function(e){return class extends e{constructor(e,n){super(e,n);var r=this.constructor.name;r&&(this.name=r)}}},x=E(globalThis.Error),_=class extends x{constructor(e,n){super(e??"Not yet implemented",n)}},k=function(e,n,r,i){var u=e[n];if(void 0===u){var o=r;!1!==i&&s(o)&&(o=o(e,n)),e[n]=u=o}return u},L=function(e,n,r,i){return e||(e={}),k(e,n,r,i),e},F=function(e,n){return L(e,"fromFn",n,!1)},O=function(e,n){return new _(e,F(n,O))},A=function(e,n){Object.defineProperty(e,"name",{value:n,configurable:!0}),b(e,"displayName",n)},S=A,T=function(e,n){return Object.assign(e,n)},C=function(e){var n,r=!1;return function(){return r||(r=!0,n=e.apply(this,arguments)),n}},I=C(function(){return"undefined"==typeof window}),j=I()?require("util").inspect.custom:Symbol("Display"),R=function(e,n){e.prototype[j]=n},N=function(e,u,s,a,l,c){c||(c={}),n(u)&&(u=null);var f,d,m,y=s;y&&(r(y)?([d,m]=y,d&&(d=h(d))):f=h(y,u));var g=c.bareFn;c.singleton&&(g=function(){return null==x.default&&(x.default=new x(...arguments)),x.default});var w,E=d||f||u||p;function x(){if(!new.target&&g&&!(this instanceof x))return g.apply(this,arguments);var e=this;return o(E.apply(e,arguments),n=>{if(n&&v(n)&&(e=n,d)){if(!new.target)throw O('Prototype repair is NYI for class instantiation without "new".');if(!u)throw O("instanceFn is not yet supported when extendsClass is null.");var r=Object.getPrototypeOf(this);Object.getPrototypeOf(e)!==r&&Object.setPrototypeOf(e,r)}return m?o(m.apply(e,arguments),()=>e):e})}return e&&S(x,e),a?(w=a,u&&Object.setPrototypeOf(a,u.prototype)):w=u?Object.create(u.prototype):{},b(w,"constructor",x),x.prototype=w,l&&T(x,l),c.display&&R(x,c.display),c.implements&&i(c.implements).forEach(e=>e(x)),x},P=function(e,n){Object.defineProperty(e,n,{enumerable:!1})},q=P,M=function(e,n,r,i,u){var o=Symbol();return N(e,Function,[function(){var e=function(){return e[o].apply(this,arguments)};return e},function(){var e=n.apply(this,arguments);if(!e)throw new Error("Constructor must return a function.");this[o]=e,q(this,o)}],r,i,u)},D=function(e){return n=>n===e},B=function(e){return Reflect.ownKeys(e)},W=function(e,n){return(n?B:Object.keys)(e)},H=function(e,n,r){var i={};for(var u of n)Object.hasOwn(e,u)&&(i[u]=e[u],!0===r&&delete e[u]);return i},K=function(e){return e instanceof Set},Y=function(e){return K(e)?e:r(e)?new Set(e):new Set([e])},U=Y,V=function(e,n){var r=[],i=[];return e.forEach((u,o)=>(n(u,o,e)?r:i).push(u)),[r,i]},z=function(e,n,r,i){var u=n;if(s(u))throw O();var o=W(e,i),a=U(u),[l,c]=V(o,e=>a.has(e));return[H(e,l,r),!0===r?e:H(e,c,!1)]},G=function(e,n,r){var i=W(e,r).filter(r=>n(e[r],r,e));return z(e,i,!1,r)},Q=function(e,n){return n<e?n:e},J=function(e,n){return Q(e,n)},$=function*(e,n){null==e&&(e=0),n=null==n?this.length:J(n,this.length);for(var r=e;r<n;r++)yield this[r]},X=function(e,n,r){return null==n&&null==r?e[Symbol.iterator].call(e):$.call(e,n,r)},Z=function(e,n){return n<0?e.length+n:n},ee=function(e,n,r,i){return n=null==n?0:Z(e,n),r=null==r?e.length:Z(e,r),i&&(0==i.inclusiveStart&&n++,i.inclusiveEnd&&r++),[n,r]},te=function(e,n,r,i){[r,i]=ee(e,r,i);for(var u=r;u<i;u++){var o=n(e[u],u,e);void 0!==o&&(e[u]=o)}return e},ne=function(e,n){return n?te(W(e,n),n=>[n,e[n]]):Object.entries(e)},re=function(e){return X(ne(this,e))},ie=function(e,n){var r=e[Symbol.iterator];return r?r.call(e):re.call(e,n)},ue=function(e){return ie(e,!0)},oe=function(e,n){return null!=e&&e.constructor===n},se=function(e){return oe(e,Object)},ae=se,le=function(e,n,r,i){return g(e,n,{get:r},i)},ce=function(e,n,r,i){return g(e,n,{value:r,writable:!0},i),r},fe=function(e,n,r){le(e,n,function(){if(this===e)return null;var i=r.call(this);return ce(this,n,i),i})},he=class extends x{constructor(e,n){super(e??"Unexpected value",n)}},pe=function(e){return require("node:"+e)},de=function(e){return C(()=>pe(e))},ve=de("util"),me=function(e,n){return n||(n={}),null==n.colors&&(n.colors=!0),ve().inspect(e,n)},ye=Z,ge=function(e,n,r,i){return void 0!==n&&(null===n||0===n?n=void 0:(n=ye(e,n),i&&0==i.inclusiveStart&&n++)),void 0!==r&&(null===r||r===e.length?r=void 0:(r=ye(e,r),i&&i.inclusiveEnd&&r++)),[n,r]},we=function(e,n,r,i,u,o){if(r||null!=i){[r,i]=ge(e,r,i,o);var s=e.slice(r,i),a=n(s);return u?u(a,r,i,s,e):a}return n(e)},be=function(e,n,r,i,u){return we(e,n,r,i,(n,r,i)=>(void 0!==r?e.slice(0,r):"")+(n||"")+(void 0!==i?e.slice(i):""),u)},Ee=oe,xe=function(e){return Ee(e,RegExp)},_e=function(e,n,r,i){var u=n;if([r,i]=ee(e,r,i),s(u))for(var o=r;o<i;o++)e[o]=u(o,e);else e.fill(u,r,i);return e},ke=function(e,n){var r=new Array(e||0);return arguments.length>1&&_e(r,n),r},Le=function(e,n){return ke(n.length,r=>e[n[r]])},Fe=function(e,n){return e[n]},Oe=function(e,n,r){return e[n]=r},Ae=function(e,n,r){var i=e;return s(i)?i.apply(r,n):i},Se=function(e,n,r,i,u){i||(i=Fe);var o=i(e,n);return void 0===o&&(o=Ae(r,[e,n]),u||(u=Oe),u(e,n,o)),o},Te=function(e,n){return e.get(n)},Ce=function(e,n,r){return e.set(n,r)},Ie=function(e,n,r){return Se(e,n,r,Te,Ce)},je=class{constructor(){this.store=new Map}get(e,n){return Ie(this.store,e,n)}remove(e){return this.store.delete(e)}delete(e){return this.remove(e)}},Re=function(e,n){return e.push(n),e},Ne=Re,Pe=function(e){var n=e;return Array.isArray(n)?n:Array.from(n)},qe=Symbol("Value"),Me=function(){return{}},De=function(e){return[e.slice(0,-1),e[e.length-1]]},Be=De,We=function(e,n,r,i,u,o){r||(r=Fe),null==i&&(i=Me),null==u&&(u=Oe),null==o&&(o=r);for(var[s,a]=Be(n),l=e,c=s.length,f=0;f<c;f++){var h=s[f],p=r(l,h);if(void 0===p){if(!i)return;p=Se(l,h,i,r,u)}l=p}if(o)return o(l,a,u)},He=function(e,n,r,i,u,o){return We(e,n,i,u,o,(e,n)=>Se(e,n,r,i,o))},Ke=function(){return new Map},Ye=function(e,n,r){return He(e,n,r,Te,Ke,Ce)},Ue=function(e,n){return delete e[n],e},Ve=function(e,n,r,i){return We(e,n,r,!1,!1,i||Ue)},ze=function(e,n){return e.delete(n)},Ge=function(e,n){return Ve(e,n,Te,ze)},Qe=class{constructor(){this.store=new Map}get(e,n){return e=Ne(Pe(e),qe),Ye(this.store,e,n)}remove(e){return e=Ne(Pe(e),qe),Ge(this.store,e)}delete(e){return this.remove(e)}},Je=M("MemoizedFunction",function(e,n){if(this.base=e,null!=n)if(1===(n=i(n)).length){this.cache=new je;var r=n[0];this._cacheKeyFormatter=e=>e[r]}else this.cache=new Qe,this._cacheKeyFormatter=e=>Le(e,n);else this.cache=new Qe,this._cacheKeyFormatter=e=>e;var u=this;return function(){var n=u._cacheKeyFormatter(arguments);return u.cache.get(n,()=>e.apply(this,arguments))}},{remove(e){return this.cache.remove(this._cacheKeyFormatter(e))}}),$e=function(e,n){return new Je(e,n)},Xe=function(e){return new Set(e)},Ze=function(e){var n={};if(e){var r=Xe(e);r.has("g")&&(n.global=!0),r.has("i")&&(n.caseInsensitive=!0),r.has("y")&&(n.sticky=!0)}return n},et=function(e){var n="";return e.global&&(n+="g"),(e.caseInsensitive||0==e.caseSensitive)&&(n+="i"),e.sticky&&(n+="y"),n},tt=function(e,n){var r=Ze(e);return et(Object.assign(r,n))},nt=function(e,r){var i=r,u=void 0;return n(i)?u=i:se(i)&&(u=tt(e.flags,i)),new RegExp(e,u)},rt=function(e,n){return nt(e,e.flags+n)},it=function(e){return rt(e,"g")},ut=$e(function(e){return e.global?e:it(e)},0),ot=function(e){var r=e;return null==r?void 0:n(r)?r:et(r)},st=function(e,n){return new RegExp(e,ot(n))},at=function(e){return e.replace(/[-[\]{}()*+!<=:?.\/\\^$|#\s,]/g,"\\$&")},lt=function(e,n){return st(at(e),n)},ct=function(e,r,i,u,o,s){return be(e,function(e){return e.replaceAll?(xe(r)&&(r=ut(r)),e.replaceAll(r,i)):(r=n(r)?lt(r,"g"):ut(r),this.replace(r,i))},u,o,s)},ft=function(e,n,r){return ct(e,n,(r??"\\")+n)},ht=function(e,n,r){return null==n&&(n='"'),!1!==r&&(e=ft(e,n,r)),n+e+n},pt=function(e){return ht(e,'"')},dt=function(e){return ae(e)?wt(e):String(e)},vt=function(e,n){return n||(n=mt),"["+e.reduce(function(e,r){return e+n(r)+", "},"").slice(0,-2)+"]"},mt=function(e){return n(e)?pt(e):r(e)?vt(e):dt(e)},yt=function(e,n,r){W(e,r).forEach((r,i,u)=>n(r,e[r],i,u))},gt=function(e,n,r,i){var u=null!=r?r:"";return yt(e,function(){u=n.call(this,u,...arguments)},i),u},wt=function(e,n){return n||(n=mt),"{"+gt(e,function(e,r,i){return e+r+":"+n(i)+", "},"",!0).slice(0,-2)+"}"},bt=function(e,n){return null==n&&(n=1),n<=0?"[object Object]":wt(e,e=>xt(e,n-1))},Et=function(e,n){return null==n&&(n=1),n<=0?"[object Array]":vt(e,e=>xt(e,n-1))},xt=function(e,n){return void 0===e?"undefined":null===e?"null":I()?me(e,n):se(e)?bt(e,maxNumLevels):r(e)?Et(e,maxNumLevels):dt(e)},kt=function(e,n,r,i){if(0===arguments.length)return new he("Unexpected value received");i||(i={});var u,{expected:o}=i;return u=o?"Received "+xt(e)+", expected one of "+xt(o):"Unexpected value received: "+xt(e),r&&(u+=' for "'+r+'"'),null!=n&&(u+=" (index "+n+")"),i.fromFn||(i.fromFn=kt),new he(u,i)},Lt=function(e,n,r){var i=new x(e,r);return n&&Object.assign(i,n),i},Ft=function*(e,n){yield*e,yield*n},Ot=function(e){return e?" "+e:""},At=function(e){return n(e)?e:e.toString()},St=M("Interface",function(e,n,r){r||(r={}),A(this,e),n?[this.stubs,this.defaults]=G(n,D(!0),!0):(this.stubs={},this.defaults={});var u=r.implements?i(r.implements):null,o=this;return function(e){var n=e;return u&&u.forEach(e=>e(n)),o.decorate(n),o.assert(n),n}},{decorate(e){var n,r,i=e;for(var[u,o]of(i.prototype?(n=i.prototype,r=!0):(n=i,r=!1),ue(this.defaults)))if(void 0===n[u])if(ae(o))if(o.value)n[u]=o.value;else{if(!o.setup)throw kt(o,null,"defaultVal");if(!r)throw o.setup(),O("setupFn is NYI for instances");fe(n,u,o.setup)}else n[u]=o;return i},assert(e){var n=e,r=null!=n.prototype,i=n.prototype||n,u=Ft(ue(this.stubs),ue(this.defaults));for(var[o]of u){var s;if(void 0===i[o])throw s=r?"Class"+Ot(n.name):"Object "+xt(n),s+=" does not satisfy interface "+this.name+' (missing key "'+At(o)+'")',Lt(s)}return n},validate(e){try{return this.assert(e),!0}catch(e){return!1}}},{is(e){return e instanceof this}}),Tt=function(e,n,r){return new St(e,n,r)},Ct=Symbol("Cleanup"),It=Tt("Handle",{remove:!0,[Ct](){this.remove()}}),jt=e(class{constructor(e){this.handles=e}remove(){this.handles.forEach(e=>e.remove())}add(e){return this.handles.push(e),this}},It),Rt=function(e){return 1===e.length&&r(e[0])?e[0]:array},Nt=function(...e){return new jt(Rt(e))},Pt=Nt,qt=Pt,Mt=function(e){var n,r,i=e;return null!=i&&(n=i.detail??i.data??i,v(i)&&(r=i)),[n,r,i]},Dt=function(e){return St.is(e)},Bt=Dt,Wt=E(globalThis.TypeError),Ht=function(e){return null==e?e:e.constructor},Kt=function(e,n,r,i){if(0===arguments.length)return new Wt("Unexpected type received");i||(i={});var u,{type:o,expected:s}=i;return null==o&&(o=Ht(e)),o&&o.name&&(o=o.name),s?(s.name&&(s=s.name),u="Expected "+s+", received "):u="Unexpected type received (",u+=o,null!=e&&(u+=" ("+xt(e)+")"),s||(u+=")"),r&&(u+=' for "'+r+'"'),null!=n&&(u+=" (index "+n+")"),i.fromFn||(i.fromFn=Kt),new Wt(u,i)},Yt=function(e,n,r){if(!Bt(n))throw Kt(n,1);return n.decorate(e),r&&r.call(e,e,n),n.assert(e),e},Ut=Tt,Vt=Symbol("EventTarget"),zt=function(e){return require(e)},Gt=function(e){return!!e.startsWith("node:")||zt("node:module").isBuiltin(e)},Qt=function(e){return e.startsWith(".")},Jt=function(e){var i=e.stdio;if(i){if(!r(i)){if(!n(i))throw Kt(i,"stdio");if("pipe"===i)i=["pipe","pipe","pipe"];else if("inherit"===i)i=["inherit","inherit","inherit"];else if("ignore"===i)i=["ignore","ignore","ignore"];else{if("overlapped"!==i)throw kt(i,"stdio");i=["overlapped","overlapped","overlapped"]}e.stdio=i}}else i=e.stdio=[null,null,null];return i},$t=function(e,n){var r=n.length;e.length=r;for(var i=0;i<r;i++)e[i]=n[i];return e},Xt=function(e){return function(){return!e.apply(this,arguments)}},Zt=function(e,n){return $t(e,e.filter(Xt(n)))},en=function(e){return Zt(e,e=>null==e)},tn=de("child_process"),nn=C(function(){return"win32"===process.platform}),rn=function(e,n,r){if(r||(r={}),n(e))throw e;if(r.nullOnErr)return null;var i=r.onErr;if(void 0!==i)return Ae(i);throw e},un=function(e,n,r){r||(r={}),r.dir&&(r.cwd=r.dir);var i=Jt(r);if(null==i[0]){var u=r.allowInput,o=r.input;if(u&&o)throw Lt("allowInput (user) and input (programmatic) cannot be used simultaneously for synchronous child processes.");u&&(i[0]="inherit")}if(null==i[1]){var s=r.captureOutput??!1,a=r.showOutput;if(s&&a)throw Lt("captureOutput and showOutput cannot be used simultaneously for synchronous child processes.");s?i[1]="pipe":(null==a&&(a=!0),i[1]=a?"inherit":"ignore")}if(null==i[2]){var l=r.captureErr??!1,c=r.showErr;if(l&&c)throw Lt("captureErr and showErr cannot be used simultaneously for synchronous child processes.");l?i[2]="pipe":(null==c&&(c=!0),i[2]=c?"inherit":"ignore")}r.encoding||(r.encoding="utf8"),n&&en(n);try{var f=tn().execFileSync(e,n,r);null!=f&&!1!==r.trim&&(f=f.trim());var h=r.map??r.mapFn;return h&&(f=h(f)),f}catch(e){if(nn())return rn(e,e=>"ENOENT"===e.code,r);throw e}},on=function(e,n){return n||(n={}),null==n.captureOutput&&(n.captureOutput=!1),n.shell=!0,n.filterExtensions=!1,un("npm",e,n)},sn=function(e,n,r){return on(["install",e,n?"-g":null],r)},an=de("path"),ln=an().sep,cn=function(e,n,r){var i=an().resolve,u=n?i(n,e):i(e);return r?u+ln:u},fn=function(e){return require(cn(e))},hn=class{constructor(){this.store={}}get(e,n){return k(this.store,e,n)}remove(e){return delete this.store[e]}delete(e){return this.remove(e)}},pn=new hn,dn=function(e){return e[e.length-1]},vn=Z,mn=function(e,n,r){return e=nt(e,{global:!0}),null!=r&&(n=vn(r,n)),e.lastIndex=n,e},yn=function(e,n,r){return e=null!=r?mn(e,r,n):ut(e),Array.from(n.matchAll(e))},gn=function(e,n,r){return null!=r&&(n=n.slice(0,r)),dn(yn(e,n))||null},wn=function(e,n){var r=gn(e,n);return r&&n.length===r.index+r[0].length?r:null},bn=function(e,r){if(n(r))return e.endsWith(e);if(xe(r))return!!wn(r,e);throw Kt(r,1,"matchThis")},En=/\/|\\/,xn=function(e){return bn(e,En)?e:e+ln},_n=function(e,n,r){if(I()){var i=an().join(e,n);return r?xn(i):i}throw O()},kn=function(e,n){return e.endsWith(n)?e:_n(e,n)},Ln=de("module"),Fn=function(e){return e=kn(e,"node_modules"),Ln().createRequire(e)},On=function(e,n){return pn.get(e,()=>Fn(e))(n)},An=function(e,n,r){return Object.keys(n).forEach(i=>k(e,i,n[i],r)),e},Sn=function(e,n,r){return n?An(e,n,r):e},Tn=function(e,n){return e.endsWith(n)?e.substring(0,e.length-n.length):e},Cn=function(e,n){var r=wn(n,e);return r?e.slice(0,r.index):e},In=function(e,r){if(n(r))return Tn(e,r);if(xe(r))return Cn(e,r);throw Kt(r,1)},jn=In,Rn=function(e,n){return[e.slice(0,n),e.slice(n)]},Nn=function(e){e=jn(e.trim(),";");var n=Math.max(e.lastIndexOf(";"),e.lastIndexOf("\n"));return Rn(e,n+1)},Pn=function(e,n){return e.startsWith(n)?e:n+e},qn=function(e){var[n,r]=Nn(e);return n+Pn(r.trim(),"return ")},Mn=function(e){return ei("node-repl-await").processTopLevelAwait(e)},Dn=function(e){return Mn(e)??e},Bn=ct,Wn=function(e,n){return""===e?e:(null==n&&(n=!0),e=Bn(e,"\\","/"),n?xn(e):e)},Hn=function(){return process.mainModule?.filename??null},Kn=function(e){return e.charAt(0).toLowerCase()+e.slice(1)},Yn=function(e){return e.split(".")[0]},Un=function(e){return an().win32.basename(e)},Vn=function(e){return Yn(Un(e))},zn=function(e,n,r,i){e||(e=Hn()??"_console.js");var u=Kn(Vn(e));return n&&(u+="_repl"),u+(r&&i?.dynamic?".dypkg.json":".pkg.js")},Gn=function(e,n){return e=an().dirname(e),!1===n?e:xn(e)},Qn=function(e,n,r,i){var u,o=zn(e,n,r,i);return u=e?Gn(e):"./",cn(u+o)},Jn=function(e){return'require("'+Wn(Qn(),!1)+'");\n'+e},$n=function(e,n){return ct(e,n,"")},Xn=function(e,n){return n.forEach(n=>e=$n(e,n)),e},Zn=function(e){return Xn(e,["\r","\n"])},er=function(e,n){return ei("astring").generate(e,n)},tr=function(e,n){return e.stack=n+"\n"+e.stack,e},nr=function(e,n,r){r||(r={}),r.ecmaVersion||(r.ecmaVersion=2024),!1!==n&&(r.sourceType="module"),null==r.allowAwaitOutsideFunction&&(r.allowAwaitOutsideFunction=!0),null==r.allowReturnOutsideFunction&&(r.allowReturnOutsideFunction=!0);var i=ei("acorn");try{return i.parse(e,r)}catch(n){throw tr(n,"Acorn parsing error: "+e)}},rr=function(e,n,r){return er(nr(e,n,r))},ir=function(e){return Zn(rr(e))},ur=function(e,n,r){return(n||r)&&(n||(n={}),r&&Sn(n,r),n.ensureReturn&&(e=qn(e)),n.topLevelAwait&&(e=Dn(e)),n.useTitan&&(e=Jn(e)),n.keepAlive&&(e="\nsetInterval(()=>{}, 100000);\n"+e),(n.logErrors||n.keepAlive)&&(e="process.on('uncaughtException', console.error);\nprocess.on('unhandledRejection', console.error);\n"+e),n.inline&&(e=ir(e))),e},or=function(e){return n(e)?e:dt(e)},sr=function(e){var n=e.indexOf("{");return-1===n||e.slice(0,n).includes("=>")},ar=function(e,n,r,i,u){return we(e,n,r,i,(n,r)=>null===n?null:(n.input=e,void 0!==r&&(n.index+=r),n),u)},lr=function(e,n){return e.splice(e.length,0,...n),n},cr=function(e,n){return lr(e,n),e},fr=cr,hr=class extends Array{constructor(e,n,r,i,u){if(-1===n)throw Lt("RegexResult index cannot be -1. For empty result, use bare null.");if(null==e)throw Lt("RegexResult matchString cannot be null. For empty result, use bare null.");super(),this[0]=e,i&&fr(this,i),this.index=n,this.input=r,u&&(this.groups=u)}fromParts(e){var n=e;return new hr(n.match,n.index,n.input,n.captures,n.groups)}},pr=function(e,n,r,i,u){return new hr(e,n,r,i,u)},dr=function(e,n,r,i,u){return-1===n||null==e?null:pr(e,n,r,i,u)},vr=$n,mr=function(e,n){return nt(e,vr(e.flags,n))},yr=function(e){return mr(e,"g")},gr=$e(function(e){return e.global?yr(e):e},0),wr=function(e,n,r){return(e=null!=r?mn(e,r,n):gr(e)).exec(n)},br=function(e,r,i,u,o){return ar(e,e=>{if(n(r)){var i=e.indexOf(r);return dr(r,i,e)}return wr(r,e)},i,u,o)},Er=function(e){return e.index+e[0].length},xr=function(e,n){var r=br(e,n);return null===r[0]?null:e.slice(Er(r))},_r=function(e,n){return e.startsWith(n)?e.substring(n.length):e},kr=function(e,n){var r=wr(e,n);return r&&0===r.index?r:null},Lr=function(e,n){var r=kr(n,e);return r?e.slice(r[0].length):e},Fr=function(e,r){if(n(r))return _r(e,r);if(xe(r))return Lr(e,r);throw Kt(r,1)},Or=Fr,Ar=function(e){var n=xr(e,"=>").trim();return Or(jn(n,"}"),"{")},Sr=function(e){return xr(e,"{").slice(0,-1)},Tr=function(e){var n=or(e);return sr(n)?Ar(n):Sr(n)},Cr=function(e){return null==e?"":n(e)?e:s(e)?Tr(e):String(e)},Ir=function(e,n){var r=n?.basic?null:{topLevelAwait:!0,useTitan:!0},i=ur(Cr(e),n,r);return un("node",[n?.mode??"-p",i],n)},jr=function(e,n,r,i){var u="Required argument";return r&&(u+=' "'+r+'"'),null!=n&&(u+=" (index "+n+")"),u+=" missing",arguments.length>0&&(u+=" (received "+xt(e)+")"),Lt(u,null,F(i,jr))},Rr=function(e,n,r){if(null==e)throw jr(e,n,r,{fromFn:Rr});return e},Nr=function(e,n){return process.kill(e,Rr(n,0,"signalName"))},Pr=function(e){return Nr(e,"SIGINT")},qr=function(){return Pr(process.pid)},Mr=qr,Dr=function(e){if("Y"===(e=e.toUpperCase()))return!0;if("N"===e)return!1;throw kt(e,0,"char")},Br=function(e){null==e&&(e="Are you sure? [y/n]: "),process.stdout.write(e);var n=Ir(function(){const e=process.stdin,n=process.stdout;e.setRawMode(!0),e.setEncoding("utf8"),e.on("data",e=>{var r=e.toUpperCase();"Y"===r||"N"===r?(n.write(e),process.exit(0)):""===e&&(n.write("^C"),process.exit(0))})},{mode:"-e",basic:!0,stdio:["inherit","pipe"]});if("^C"===n)throw process.stdout.write(n),Mr(),Lt("Prompt was cancelled via interrupt.");return console.log(n),Dr(n)},Wr=function(e){return r(e)?e:n(e)?e.split("."):[e]},Hr=function(e,n,r,i,u,o){var s=r;return We(e,n,i,u,o,(e,n,r)=>r(e,n,Ae(s)))},Kr=function(e,n){var r=n,i=globalThis.config;i||(i=globalThis.config={});var u,o=Wr(e);return o.length>1?u=Hr(i,o,r):(u=Ae(r),i[o[0]]=u),u},Yr=function(e,n){return Kr("node.require.customDirs",r=>(r||(r=[]),!1!==n&&(e=kn(e,"node_modules")),r.includes(e)||r.push(e),r)),e},Ur=Yr,Vr=We,zr=function(e){var n=globalThis.config;if(n){var r=Wr(e);return r.length>1?Vr(n,r):n[r[0]]}},Gr=function(e,n,r){if(null!=e)return e;var i=zr(n);return null!=i?i:r},Qr=de("fs"),Jr=function(e){return!!Qr().lstatSync(e,{throwIfNoEntry:!1})},$r=function(e){var n=Gn(e,!1);return Jr(n)||(n!==e&&$r(n),Qr().mkdirSync(n)),e},Xr=function(e){return $r(e),Qr().mkdirSync(e),e},Zr=function(e){return Jr(e)?e:Xr(e)},ei=function(e,n){if(Gt(e))return require(e);if(Qt(e))return fn(e);try{return require(e)}catch(e){}var r=__dirname,i=process.mainModule?.path;if(i!==r)try{return On(i,e)}catch(e){}var u=process.cwd();if(u!==i&&u!==r)try{return On(u,e)}catch(e){}var o=zr("node.require.customDirs");if(o)for(var s of o)try{return On(s,e)}catch(e){}var a=Gr(n?.autoInstall,"node.require.autoInstall"),l=Gr(n?.promptInstall,"node.require.promptInstall",!0);if(a||l){var c=a||l;!0===c&&(c="./node_modules"),c=cn(c);var f=!1;if(a?(f=!0,console.log('Auto-installing "'+e+'" from npm to "'+c+'"...')):(f=Br('Npm package "'+e+'" is required. Install now? (Y/N) '))&&console.log('Installing "'+e+'" from npm to "'+c+'"...'),f){c=Zr(c),sn(e,!1,{cwd:c});try{return Ur(c),On(c,e)}catch(e){console.error("Failed to load from auto-install dir: ",c)}}}throw Lt('Module not found: "'+e+'"',{checked:{moduleDir:r,scriptDir:i,cwd:u}})},ti=C(function(){if(!globalThis.CustomEvent||!globalThis.EventTarget||!globalThis.Event){var e=ei("event-target-shim");globalThis.Event||(globalThis.Event=e.Event),globalThis.CustomEvent||(globalThis.CustomEvent=class extends globalThis.Event{constructor(e,n){super(e,n),n?.detail&&(this.detail=n.detail)}}),globalThis.EventTarget||(globalThis.EventTarget=e.EventTarget)}return{Event:Event,CustomEvent:CustomEvent,EventTarget:EventTarget}}),ni=ti().EventTarget,ri=function(e){var n=Vt,r=e[n];return void 0===r&&(r=new ni,b(e,n,r)),r},ii=Ut("EventInterface",{addEventListener(e,n,r){ri(this).addEventListener(e,n,r)},on(e,n){this.addEventListener(e,n)},removeEventListener(e,n){ri(this).removeEventListener(e,n)},off(e,n){this.removeEventListener(e,n)},dispatchEvent(e){return ri(this).dispatchEvent(e)}}),ui=ii,oi=function(e){return Yt(e,ui)},si=function(e){return!(!e.addEventListener&&!e.on)},ai=function(e){return si(e)||oi(e),e},li=function(e,n,r){return e[n]=r,e},ci=function(e,n,r){return li(e||{},n,r)},fi=function(e,n,r,i){return xi(e,n,r,ci(i,"once",!0))},hi=function(e,n){return function(){var r=n.apply(this,arguments);return e.apply(this,arguments),r}},pi=hi,di=function(e,n,r){return e[n]=pi(e[n],r)},vi=e(class{constructor(e){this._remover=e}remove(){this._remover()}removeOn(e,n,r){r&&ai(e);var i=fi(target,n,()=>this.remove());return di(this,"remove",()=>i.remove()),this}},It),mi=class extends vi{constructor(e,n){super(e),this.handleEvent=n}},yi=function(e,n){return new mi(e,n)},gi=function(e,n,r){(e.removeEventListener||e.off).call(e,n,r)},wi=function(e,n,r){for(var i=e.length-1;i>=n;i--)e[i+1]=e[i];return e[n]=r,e.length++,e},bi=function(e,n){return wi(e,0,n)},Ei=bi,xi=function(e,n,r,i){if(i?.valueFirst){var u=r;r=function(e){var[n,r]=Mt(e);return Ei(arguments,n),arguments[1]=r,u.apply(this,arguments)}}var o=e.addEventListener;return o||(e.on?o=i?.once?e.once:e.on:(oi(e),o=e.addEventListener)),o.call(e,n,r,i),yi(()=>gi(e,n,r),r)},_i=function(e,n,r,i){return qt(n.map(n=>xi(e,n,r,i)))},ki=C(function(){return process.argv.slice(2)}),Li=ki,Fi=function(e,n){const r=[];let i="",u="outside",o=!1;for(let s=0;s<e.length;s++){const a=e[s];switch(u){case"outside":'"'===a?o?(i+=a,o=!1):(n&&(i+=a),u="insideQuote"):"\\"===a?o=!0:" "===a?(i.length>0&&(r.push(i),i=""),o=!1):(i+=a,o=!1);break;case"insideQuote":'"'!==a||o?"\\"!==a||o?(i+=a,o=!1):o=!0:(n&&(i+=a),u="outside")}}return i.length>0&&r.push(i),r},Oi=function(){return globalThis.repl?.repl},Ai=function(e,n){return null==n&&(n=1),function(){var r=Array.from(arguments),i=r.pop(),u=e.apply(this,r);0===n?(u.then(e=>i(null,e)),u.catch(i)):(u.then(i),u.catch(e=>i.apply(null,li([],n,e))))}},Si=async function(){}.constructor,Ti=function(e){return oe(e,Si)},Ci=function(e){return Ti(e)?e:async function(){return e.apply(this,arguments)}},Ii=C(function(){return ei("node:stream")}),ji=I()&&Ii().Writable,Ri=function(e,n){return n||(n={}),null==n.objectMode&&(n.objectMode=!0),e?n.write=Ai(Ci(e),0):n.write||(n.write=(e,n,r)=>r()),new ji(n)},Ni=function(){},Pi=async function(e){var n=Oi();if(n){var r,i=n.eval,u=n.output;n.output=Ri(Ni),n.eval=Ni;try{n.quickDisableHistory?await n.quickDisableHistory(async function(){r=await e(),n._line()}):r=await e()}finally{n.output=u,n.eval=i}return r}return e()},qi=de("readline"),Mi=/\r?\n/,Di=function(e){return null==e||void 0!==e.length&&0===e.length},Bi=function(e,n){return Zt(e,Di)},Wi=function(e,n){return e.splice(n,1),e},Hi=function(e,n,r){for(var i={},u=e.length,o=0;o<u;o++){var s=n(e[o],o,e);if(s){var[a,l]=s;r?(i[a]||(i[a]=[]),i[a].push(l)):i[a]=l}}return i},Ki=function(e,n,r,i){return[n,r]=ee(e,n,r,i),e.slice(n,r)},Yi=function(e,n){return ke(n,e).join("")},Ui=function(e){return e?e[0]:null},Vi=function(e,n){var r=null==n?-1:n.index;if(-1===r)return[e];var i=Rn(e,r);return i[1]=i[1].slice(n[0].length),i},zi=function(e,n,r,i,u){return Vi(e,br(e,n,r,i,u))},Gi=function(e){return isNaN(e)?null:e},Qi=function(e){return null==e?null:Gi(Number(e))},Ji=Qi,$i=function(e){return Ji(e)??e},Xi=function(e,n){null==n&&(n="=");var r={};return e.forEach(function(e){var[i,u]=zi(e,n);null!=u&&(u=$i(u.trim())),r[i.trim()]=u}),r},Zi=L,eu=class extends Array{constructor(e){var i,u=e;null!=u&&(r(u)?i=u:n(u)&&(i=u.split(Mi))),i?(super(i.length),Object.assign(this,i)):super(...arguments)}condense(e){return this.trim().removeEmpty(),e&&this.removeComments(e),this}trim(){return this.apply(e=>e.trim())}removeEmpty(){return Bi(this)}removeComments(e){for(var n=0;n<this.length;n++){var r=this[n],i=r.indexOf(e);-1!==i&&(""===(r=r.slice(0,i)).trim()?(Wi(this,n),n--):this[n]=r)}return this}removeFirst(){return this.shift(),this}removeLast(){return this.pop(),this}apply(e){return te(this,e)}join(){return super.join("\n")}toObj(e){return Xi(this,e)}mapToObj(e,n){return Hi(this,e,n)}between(e,n,r){return r=Zi(r,"inclusiveEnd",!0),Ki(this,e,n,r)}normalize(){if(this.length>0&&(""===this[0].trim()&&this.shift(),this.length>0&&(""===dn(this).trim()&&this.pop(),this.length>0))){var e=this.find(e=>""!==e.trim()),n=Ui(wr(/^\s*/,e));if(n){var r=n.length;this.apply(e=>{if(e.startsWith(n))return e.slice(r)})}}return this}deindent(e,n,r){throw O()}indent(e,n){var r=Yi(n??"\t",e??1);return this.apply(e=>r+e)}static is(e){return oe(e,this)}static fromChunks(e){return e.map(e=>jn(e,Mi)).flatMap(e=>nu(e,!1))}},tu=function(e,n){var r=new eu(e);return n&&r.condense(),r},nu=function(e,n,r){var i=e.split(Mi);return n?tu(i,r):i},ru=function(e){return Qr().readFileSync(e,"utf8")},iu=ru,uu=function(e,n){return nu(iu(e),!0,n)},ou=function(e){var n=typeof e;return"number"===n||"bigint"===n},su=function(e){return e instanceof Buffer},au=function(e){return ArrayBuffer.isView(e)},lu=au,cu=function(e){return su(e)||lu(e)||n(e)},fu=function(e){return e.constructor===ArrayBuffer},hu=function(e){return cu(e)?e:fu(e)?Buffer.from(e):dt(e)},pu=function(e){return ou(e)?String(e):hu(e)},du=function(e,n){return $r(e),Qr().appendFileSync(e,pu(n)),e},vu=function(e,n){return du(e,"\n"+n)},mu=vu,yu=function(e){return ct(e,"\n","\\n")},gu=yu,wu=function(e,n){if(0===e)return n[0];for(var r=n.length,i="";e>0;){var u=e%r;i=n.charAt(u)+i,e=Math.floor(e/r)}return i},bu="0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZ",Eu=function(e){return wu(e,bu)},xu=function(e,n){for(var r=or(e),i=n.length,u=0,o=0;o<r.length;o++){var s=r[o],a=n.indexOf(s);if(-1===a)throw'Error: "'+s+'" not found in base charset "'+n+'"';u=u*i+a}return u},_u=function(e){return xu(e,bu)},ku=function(e,n){return Object.keys(e).map((r,i)=>n(r,e[r],i,e))},Lu=function(e){return e.slice()},Fu=function(e,n){return e.includes(n)||e.push(n),e},Ou=class{constructor(e,n,i,u){(n=r(n)?Lu(n):[n]).forEach(u),e&&Fu(n,e),this.members=n,this._enableFn=i,this._disableFn=u}enable(e){this.members.forEach(n=>{n!==e&&this._disableFn(n)}),this._enableFn(e)}disableAll(){this.members.forEach(e=>this._disableFn(e))}},Au=function(e,n,r,i){return new Ou(e,n,r,i)},Su=function(e,n,r){return new Promise(function(i,u){var o=qt([fi(e,n||"load",e=>{o.remove(),i(e)}),fi(e,r||"error",e=>{o.remove(),u(e)})])})},Tu=N("CLI",I()&&qi().Interface,[function(e){if(e||(e={}),e.input||(e.input=process.stdin),e.output||null==e.output&&(e.output=process.stdout),null==e.terminal&&(e.terminal=!0),e.historyPath){var n=Jr(e.historyPath)?uu(e.historyPath):[];e.history=n.reverse()}var r={inputWasRaw:e.input.isRaw},i=qi().createInterface(e);return i.options=e,i.internal=r,i},function(){var e=this.options;this.rl=qi(),e.historyPath&&this.on("history",n=>mu(e.historyPath,n[0])),e.disabled&&this.disable()}],{prompt(e){this._muted||(this._isPrompt=!0,null!=e&&this.setPrompt(e),super.prompt.apply(this,arguments),delete this._isPrompt)},_refreshLine(){this._muted||(this._isRefresh=!0,super._refreshLine(...arguments),delete this._isRefresh)},_ttyWrite(e,n){(!this._blockExcept||n&&this._blockExcept.includes(n.name))&&super._ttyWrite.apply(this,arguments)},_addHistory(){return this._historyDisabled||null!=this._mask||super._addHistory(),this.line},_writeToOutput(e){if(!this._muted){var n=this._mask;if(null!=n){if(this._isRefresh){var r=this._prompt;e.startsWith(r)&&(super._writeToOutput(r),e=e.slice(r.length))}this._isPrompt||(e=Bn(e,/[^\r\n]/,n))}super._writeToOutput(e)}},async promptLine(e){return this.prompt(e),this.awaitLine()},async prefillPrompt(e,n){var r=n,i=await Ae(r);return this.prompt(e),i&&this.write(gu(or(i))),this.awaitLine()},async promptMultiline(e,r,i,u){if(null==r&&(r="... "),null==i)i=e=>""===e,u||(u=e=>(e.pop(),e));else if(n(i)){var o=i;i=e=>e.endsWith(o)}for(var s=await this.promptLine(e),a=[s];!i(s,a.length,a);)s=await this.promptLine(r),a.push(s);return u&&u(a),a.join("\n")},async promptKey(e,n){this.prompt(e);var r=await this.quickBlockExcept(n,!1,()=>this.awaitKey(n));return this.newLine(),r},async promptYN(e){return"y"===(await this.promptKey(e,["y","n"])).toLowerCase()},async promptSelect(e,n,i){var u=n;i||(i={});var o=0;function a(){return o++,Eu(o)}if(ae(u))u=ku(u,(e,n,r)=>[a(),e,n]);else{if(!r(u))throw Kt(u);u=u.map((e,n)=>{if(null==e)return null;if(r(e)){var i=e[0];if(null==i)i=a();else if((i=or(i)).length>1)throw Lt("Input key must be a single character:",e);var u=e.length;if(1===u)return[i,i,i];if(2===u){var o=e[1];return[i,o,o]}if(3===u)return[i,e[1],e[2]];throw Lt("Unexpected array length in choices: "+u)}return[a(),e,e]}),en(u)}if(u.length>35)throw Lt("promptSelect only supports up to 35 options.");var l=i.displayFn||((e,n)=>"["+e+"] "+n);this.quickDisableHistory(()=>{for(var e=0;e<u.length;e++){var[n,r,i]=u[e];this.write(l(n,r,i,u)+"\n")}});var c=Hi(u,e=>[e[0],e]),f=await this.promptKey(e,Object.keys(c)),h=c[f];if(null==h)throw kt(h,"choice");var p=h[2];return s(p)&&(p=await p(h)),i.asObj?{key:f,name:h[1],value:p}:i.asIndex?_u(f)-1:p},blockExcept(e,n){e=i(e).map(e=>String(e).toLowerCase()),0!=n&&Fu(e,"return"),this._blockExcept=e},unblock(){delete this._blockExcept},async quickBlockExcept(e,n,r){var i=this._blockExcept;this.blockExcept(e,n);var u=await r();return i?this.blockExcept(i):this.unblock(),u},disable(){this.pause(),this.mute()},enable(){this._mutex?this._mutex.enable(this):this._enable()},_enable(){this.resume(),this.unmute()},mutex(e){var n=Au(this,e,e=>e._enable(),e=>e.disable());this.pause(),this.resume(),n.members.forEach(e=>e._mutex=n)},mask(e){this._mask=e},unmask(){delete this._mask},mute(){this._muted=!0},unmute(){delete this._muted},disableHistory(){this._historyDisabled=!0,this._historyPrev=Ni,this._historyNext=Ni},enableHistory(){delete this._historyDisabled,delete this._historyPrev,delete this._historyNext},async quickDisableHistory(e){var n=this._historyDisabled;this.disableHistory();try{var r=await e()}finally{return n||this.enableHistory(),r}},awaitLine(){return Su(this,"line")},newLine(){this.write("\n")},newline(){return this.newLine()},onKey(e,n,i){var u=e,o=this.input;if(this.rl.emitKeypressEvents(o),o.isTTY&&o.setRawMode(!0),u){var s=n;if(r(u)){var a=u.map(e=>String(e).toLowerCase());n=(e,n)=>{e||(e=n.name),a.includes(e.toLowerCase())&&s.call(this,e,n)}}else{var l=String(u).toLowerCase();n=(e,n)=>{e||(e=n.name),e.toLowerCase()===l&&s.call(this,e,n)}}}return xi(o,"keypress",n,i)},async awaitKey(e){return new Promise(n=>{var r=this.onKey(e,e=>{r.remove(),n(e)})})},moveCursor(e,n){return this._moveCursor(e,n)},cursorLeft(e){return this.moveCursor(-e)},cursorRight(e){return this.moveCursor(e)},cursorUp(e){return this.moveCursor(null,-e)},cursorDown(e){return this.moveCursor(null,e)},close(){super.close(),this.input.setRawMode(this.internal.inputWasRaw)}}),Cu=function(e,n){return Pi(async function(){var r=new Tu(n);try{var i=await e(r)}finally{r.close()}return i})},Iu=function(e,n){return Cu(n=>n.promptLine(e),n)},ju=async function(e,n,r){for(var i={},u=n.length,o=0;o<u;o++){var s,a=n[o];if(a.endsWith("?")&&(a=a.slice(0,-1),s=!0),void 0===(l=e[a])){var l=e[o];if(void 0===l&&!s&&(!1!==r?.prompt&&(l=await Iu(a+": ")),!l))throw Rr(void 0,o,a)}i[a]=l}return i},Ru={node:{onError:function(e){return _i(process,["uncaughtException","unhandledRejection"],e)},is:I,display:me,util:ve,_builtInModule:de,requireBuiltIn:pe,require:ei,_basicRequire:zt,child_process:tn,requireLocal:fn,path:an,_requireFromDir:On,_requireDirCache:pn,_createRequire:Fn,module:Ln,promptYNSync:Br,run:Ir,getScriptPath:Hn,sigint:Mr,interrupt:qr,ensureRequireDir:Ur,addRequireDir:Yr,fs:Qr,pause:function(e){null!=e&&(e=String(e)),ei("press-any-key-sync")(e)},beforeExit:function(e){return xi(process,"beforeExit",e)},args:ki,prompt:Iu,quickCLI:Cu,quickDisableREPL:Pi,getREPL:Oi,CLI:Tu,readline:qi},ev:{onAny:_i,multiHandle:qt,on:xi,resolveValue:Mt,enable:oi,EventInterface:ui,Interface:ii,_ensureHasTarget:ri,targetSym:Vt,EventTarget:ni,polyfill:ti,handle:yi,ListenerHandle:mi,ensureEnabled:ai,can:si,once:fi,off:gi,promise:Su},o:{multiHandle:Pt,isAny:v,setHidden:b,addNonEnumerable:w,defineProperty:g,weakAssign:y,merge:m,safeEnsure:L,ensure:k,hideKey:q,makeNonEnumerable:P,filterSplit:G,keys:W,allKeys:B,split:z,pick:H,iterateAll:ue,iterate:ie,iterator:re,entries:ne,isPure:ae,is:se,setProtoLazy:fe,setGetter:le,forceSet:ce,display:bt,toLiteral:wt,constructorMatches:Ee,ensureCustom:Se,get:Fe,set:Oe,createEmpty:Me,remove:Ue,reduce:gt,each:yt,addInterface:Yt,Cache:hn,setDefaults:Sn,ensureMulti:An,resolveKeys:Wr,diveGet:Vr,safeSet:ci,touch:li,fromLines:Xi,safeDefault:Zi,mapArr:ku,mutex:Au,_Mutex:Ou},handle:{createMulti:Nt,MultiHandle:jt,HandleInterface:It,Handle:vi},class:{addInterface:e,create:N,setName:S,addStatics:T,setDisplay:R,isInterface:Bt,interface:Ut},ifc:{create:Tt,Interface:St,is:Dt},f:{createClass:M,ensureConstructor:h,createConstructor:f,isArrowFn:l,isArrow:a,is:s,wrap:c,retThis:p,setName:A,one:C,eq:D,memoize:$e,MemoizedFunction:Je,not:Xt,body:Tr,isArrowString:sr,_getArrowFnBody:Ar,_getNormalFnBody:Sr,hookAfterMethod:di,hookAfter:pi,injectAfter:hi,callbackify:Ai,ensureAsync:Ci,isAsync:Ti,AsyncFunction:Si,noop:Ni},s:{is:n,toLiteral:pt,quote:ht,escape:ft,replaceAll:ct,apply:be,withIndices:we,chars:Xe,from:dt,spaceBefore:Ot,fromKey:At,endsWith:bn,resolveIndex:vn,removeTrailing:jn,removeFromEnd:In,_removeStringFromEnd:Tn,_removeRegexFromEnd:Cn,splitAtIndex:Rn,ensureStartsWith:Pn,replace:Bn,decapitalize:Kn,removeLineBreaks:Zn,removeMulti:Xn,removeAll:$n,resolve:Cr,ensure:or,after:xr,match:br,_matchWithIndices:ar,remove:vr,removeLeading:Or,removeFromStart:Fr,_removeStringFromStart:_r,_removeRegexFromStart:Lr,splitLines:nu,lines:tu,LinesArray:eu,repeat:Yi,splitFirst:zi,_splitByMatch:Vi,escapeLineBreaks:gu,escapeNewLines:yu},a:{is:r,ensure:i,filterSplit:V,iterate:X,iterator:$,apply:te,resolveIndices:ee,resolveIndex:Z,wrapIndices:ge,wrapIndex:ye,pick:Le,create:ke,fill:_e,push:Ne,add:Re,splitLast:Be,splitTail:De,toLiteral:vt,display:Et,unboxArgs:Rt,removeNullish:en,removeByFilter:Zt,replaceContents:$t,last:dn,pushMulti:fr,addMulti:cr,pushThroughMulti:lr,removeEmpty:Bi,removeIndex:Wi,mapToObj:Hi,slice:Ki,copy:Lu,ensureContains:Fu},p:{asyncJoint:o,is:u},v:{isPrimitive:d,constructorMatches:oe,display:xt,toLiteral:mt,resolve:Ae,type:Ht,req:Rr,isEmpty:Di,nullIfNaN:Gi},err:{nyi:O,NYIError:_,Error:x,Enhanced:E,defaultFromFn:F,value:kt,ValueError:he,create:Lt,type:Kt,TypeError:Wt,prepend:tr,req:jr},sym:{display:j,value:qe,cleanup:Ct},macro:{config:function(e){}},set:{resolve:U,ensure:Y,is:K},n:{cap:J,least:Q,tryCoerce:$i,tryParse:Ji,ensure:Qi,is:ou,toBase36:Eu,toCustomBase:wu,_base36Digits:bu,fromBase36:_u,fromCustomBase:xu},re:{is:xe,ensureGlobal:ut,global:it,addFlag:rt,copy:nt,updateFlagString:tt,parseFlagString:Ze,createFlagString:et,createEscaped:lt,create:st,resolveFlags:ot,escape:at,matchEnd:wn,matchLast:gn,matchAll:yn,setStartIndex:mn,slash:En,safeCreateResult:dr,createResult:pr,RegexResult:hr,match:wr,ensureLocal:gr,local:yr,removeFlag:mr,resultEndIndex:Er,matchStart:kr,newline:Mi,text:Ui},map:{Cache:je,ensure:Ie,get:Te,set:Ce,MultiCache:Qe,diveEnsure:Ye,createEmpty:Ke,diveDelete:Ge,remove:ze},args:{ensureArray:Pe,unshift:Ei,prepend:bi,insert:wi},tree:{ensure:He,dive:We,remove:Ve,setCustom:Hr},gen:{join:Ft},npm:{isBuiltIn:Gt,isFile:Qt,install:sn,_runCommand:on},os:{run:un,_resolveStdio:Jt},win:{is:nn},shell:{_handleError:rn},path:{abs:cn,sep:ln,ensureEndsWith:kn,join:_n,ensureTrailingSlash:xn,fws:Wn,baseName:Vn,_removeExtsFromFile:Yn,file:Un,dir:Gn},js:{enhance:ur,ensureReturn:qn,splitLastExpression:Nn,enableAwait:Dn,_nodeEnableAwait:Mn,useTitan:Jn,inline:ir,removeComments:rr,fromAST:er,parse:nr},titan:{getPackagePath:Qn,getPackageName:zn},proc:{interrupt:Pr,signal:Nr},bool:{fromYN:Dr},env:{setConfig:Kr,getConfig:zr,resolveConfig:Gr,args:Li},fs:{ensureDir:Zr,exists:Jr,mkdir:Xr,ensureParent:$r,loadLines:uu,loadText:iu,load:ru,appendLine:mu,addLine:vu,append:du,formatRaw:pu},cli:{parseArgs:function(e,r){for(var i,u=[],o=!1,s=(i=null==(l=e)?Li():n(l)?Fi(l,r):l).length,a=0;a<s;a++){var l=i[a];if(!o){var c=l[0];let e;if("-"===c)if("-"===l[1]){if(2===l.length){o=!0;continue}e=2}else e=1;else"/"===c&&(e=1);if(e){var f,h,p=l.slice(e),d=p.indexOf("=");if(-1!==d)f=p.slice(0,d),h=p.slice(d+1);else{f=p;var v=i[a+1];null==v||"-"===v[0]?h=!0:(h=v,a++)}u[f]=h;continue}}u.push(l)}return u},splitArgs:Fi,paramsFrom:async function(e,n,r){var i=await ju(e,n,r);Object.assign(globalThis,i)},validateParams:ju},stream:{nodeWritable:Ri,NodeWritableStream:ji,_useNode:Ii},bin:{ensureByteSafe:hu,isByteSafe:cu,isNodeBuffer:su,isTA:lu},ab:{isTA:au,is:fu}};globalThis.t?Object.keys(Ru).forEach(function(e){if(t[e]){var n=Ru[e];Object.keys(n).forEach(function(r){t[e][r]=n[r]})}else t[e]=Ru[e]}):globalThis.t=Object.assign({},Ru),globalThis.exports&&(exports.default=globalThis.t);
package/custom.pkg.js CHANGED
@@ -1 +1 @@
1
- var s={};globalThis.t?Object.keys(s).forEach((function(a){if(t[a]){var e=s[a];Object.keys(e).forEach((function(s){t[a][s]=e[s]}))}else t[a]=s[a]})):globalThis.t=Object.assign({},s),globalThis.exports&&(exports.default=globalThis.t);
1
+ var s={};globalThis.t?Object.keys(s).forEach(function(a){if(t[a]){var e=s[a];Object.keys(e).forEach(function(s){t[a][s]=e[s]})}else t[a]=s[a]}):globalThis.t=Object.assign({},s),globalThis.exports&&(exports.default=globalThis.t);
package/package.json CHANGED
@@ -1,15 +1,15 @@
1
- {
2
- "name": "titanfiber",
3
- "version": "1.0.119",
4
- "description": "",
5
- "exports": {
6
- ".": "./script.min.js",
7
- "./build": "./build.min.js",
8
- "./build/stable": "./build_stable.min.js",
9
- "./cli": "./cli.min.js",
10
- "./repl": "./repl.min.js"
11
- },
12
- "scripts": {},
13
- "author": "",
14
- "license": "ISC"
15
- }
1
+ {
2
+ "name": "titanfiber",
3
+ "version": "1.0.123",
4
+ "description": "",
5
+ "exports": {
6
+ ".": "./script.min.js",
7
+ "./build": "./build.min.js",
8
+ "./build/stable": "./build_stable.min.js",
9
+ "./cli": "./cli.min.js",
10
+ "./repl": "./repl.min.js"
11
+ },
12
+ "scripts": {},
13
+ "author": "",
14
+ "license": "ISC"
15
+ }
package/script.pkg.js CHANGED
@@ -1 +1 @@
1
- var e=function(){return process.mainModule?.filename??null},n=function(e){var n,r=!1;return function(){return r||(r=!0,n=e.apply(this,arguments)),n}},r=function(e){return require("node:"+e)},i=function(e){return n((()=>r(e)))},u=i("fs"),o=function(e){return u().readFileSync(e,"utf8")},a=o,s=function(e,n,r){null==n&&(n=!0);const i=u();return(n?i.statSync:i.lstatSync)(e,r)},l=function(e,n){return s(e,n).ino},c=function(e){return!!u().lstatSync(e,{throwIfNoEntry:!1})},f=function(e){return e?"C:/Users/"+e+"/":process.env.USERPROFILE+"\\"},p=function(e,n){return n<0?e.length+n:n},d=p,h=function(e,n,r,i){return void 0!==n&&(null===n||0===n?n=void 0:(n=d(e,n),i&&0==i.inclusiveStart&&n++)),void 0!==r&&(null===r||r===e.length?r=void 0:(r=d(e,r),i&&i.inclusiveEnd&&r++)),[n,r]},v=function(e,n,r,i,u,o){if(r||null!=i){[r,i]=h(e,r,i,o);var a=e.slice(r,i),s=n(a);return u?u(s,r,i,a,e):s}return n(e)},m=function(e,n,r,i,u){return v(e,n,r,i,((n,r,i)=>(void 0!==r?e.slice(0,r):"")+(n||"")+(void 0!==i?e.slice(i):"")),u)},g=function(e){return"string"==typeof e},y=function(e,n){return null!=e&&e.constructor===n},b=y,w=function(e){return b(e,RegExp)},x=function(e){return Array.isArray(e)},O=function(e){return x(e)?e:[e]},T=function(e){return e instanceof Promise},E=function(e,n){var r=e;return T(r)?r.then(n):n(r)},S=function(e){return"function"==typeof e},A=function(e){return S(e)&&null==e.prototype},N=A,j=function(e){return function(){return e.apply(this,arguments)}},F=function(e,n){var r;return r=n?function(){this.super=n;var r=e.apply(this,arguments);return E(r,(()=>(delete this.super,r)))}:N(e)?j(e):e,r._isConstructor=!0,r},k=function(e,n){return e._isConstructor?e:F(e,n)},D=function(){return this},_=function(e){return class extends e{constructor(e,n){super(e,n);var r=this.constructor.name;r&&(this.name=r)}}},I=_(globalThis.Error),C=function(e,n,r){var i=new I(e,r);return n&&Object.assign(i,n),i},P=class extends I{constructor(e,n){super(e??"Not yet implemented",n)}},L=function(e,n,r,i){var u=e[n];if(void 0===u){var o=r;!1!==i&&S(o)&&(o=o(e,n)),e[n]=u=o}return u},M=function(e,n,r,i){return e||(e={}),L(e,n,r,i),e},R=function(e,n){return M(e,"fromFn",n,!1)},q=function(e,n){return new P(e,R(n,q))},G=function(e){var n=typeof e;return"object"!==n&&"function"!==n||null===e},B=function(e){return!G(e)},W=function(e,n,r){return Object.defineProperty(e,n,{value:r,writable:!0,enumerable:!1,configurable:!0}),r},K=W,U=function(e,n){Object.defineProperty(e,"name",{value:n,configurable:!0}),K(e,"displayName",n)},J=U,Y=function(e,n){return Object.assign(e,n)},z=function(e){},H=n((function(){return z("node.is")??"undefined"==typeof window})),V=H()?require("util").inspect.custom:Symbol("Display"),$=function(e,n){e.prototype[V]=n},Q=function(e,n,r,i,u,o){o||(o={}),g(n)&&(n=null);var a,s,l,c=r;if(c)if(x(c)){if([s,l]=c,s)if(x(s)){if(!n)throw C("Bare args array for instanceFn is only valid when extending a class.");var f=s;s=null,a=F((function(){this.super.apply(this,f)}),n)}else s=k(s)}else a=k(c,n);var p=o.bareFn;o.singleton&&(p=function(){return null==v.default&&(v.default=new v(...arguments)),v.default});var d,h=s||a||n||D;function v(){if(!new.target&&p&&!(this instanceof v))return p.apply(this,arguments);var e=this;return E(h.apply(e,arguments),(r=>{if(r&&B(r)&&(e=r,s)){if(!new.target)throw q('Prototype repair is NYI for class instantiation without "new".');if(!n)throw q("instanceFn is not yet supported when extendsClass is null.");var i=Object.getPrototypeOf(this);Object.getPrototypeOf(e)!==i&&Object.setPrototypeOf(e,i)}return l?E(l.apply(e,arguments),(()=>e)):e}))}return e&&J(v,e),i?(d=i,n&&Object.setPrototypeOf(i,n.prototype)):d=n?Object.create(n.prototype):{},K(d,"constructor",v),v.prototype=d,u&&Y(v,u),o.display&&$(v,o.display),o.implements&&O(o.implements).forEach((e=>e(v))),v},X=function(e,n){Object.defineProperty(e,n,{enumerable:!1})},Z=X,ee=function(e,n,r,i,u){var o=Symbol();return Q(e,Function,[function(){var e=function(){return e[o].apply(this,arguments)};return e},function(){var e=n.apply(this,arguments);if(!e)throw new Error("Constructor must return a function.");this[o]=e,Z(this,o)}],r,i,u)},ne=function(e,n,r,i){return n=null==n?0:p(e,n),r=null==r?e.length:p(e,r),i&&(0==i.inclusiveStart&&n++,i.inclusiveEnd&&r++),[n,r]},re=function(e,n,r,i){var u=n;if([r,i]=ne(e,r,i),S(u))for(var o=r;o<i;o++)e[o]=u(o,e);else e.fill(u,r,i);return e},te=function(e,n){var r=new Array(e||0);return arguments.length>1&&re(r,n),r},ie=function(e,n){return te(n.length,(r=>e[n[r]]))},ue=function(e,n){return e[n]},oe=function(e,n,r){return e[n]=r},ae=function(e,n,r){var i=e;return S(i)?i.apply(r,n):i},se=function(e,n,r,i,u){i||(i=ue);var o=i(e,n);return void 0===o&&(o=ae(r,[e,n]),u||(u=oe),u(e,n,o)),o},le=function(e,n){return e.get(n)},ce=function(e,n,r){return e.set(n,r)},fe=function(e,n,r){return se(e,n,r,le,ce)},pe=class{constructor(){this.store=new Map}get(e,n){return fe(this.store,e,n)}remove(e){return this.store.delete(e)}delete(e){return this.remove(e)}},de=function(e,n){return e.push(n),e},he=de,ve=function(e){var n=e;return Array.isArray(n)?n:Array.from(n)},me=Symbol("Value"),ge=function(){return{}},ye=function(e){return[e.slice(0,-1),e[e.length-1]]},be=ye,we=function(e,n,r,i,u,o){r||(r=ue),null==i&&(i=ge),null==u&&(u=oe),null==o&&(o=r);for(var[a,s]=be(n),l=e,c=a.length,f=0;f<c;f++){var p=a[f],d=r(l,p);if(void 0===d){if(!i)return;d=se(l,p,i,r,u)}l=d}if(o)return o(l,s,u)},xe=function(e,n,r,i,u,o){return we(e,n,i,u,o,((e,n)=>se(e,n,r,i,o)))},Oe=function(){return new Map},Te=function(e,n,r){return xe(e,n,r,le,Oe,ce)},Ee=function(e,n){return delete e[n],e},Se=function(e,n,r,i){return we(e,n,r,!1,!1,i||Ee)},Ae=function(e,n){return e.delete(n)},Ne=function(e,n){return Se(e,n,le,Ae)},je=class{constructor(){this.store=new Map}get(e,n){return e=he(ve(e),me),Te(this.store,e,n)}remove(e){return e=he(ve(e),me),Ne(this.store,e)}delete(e){return this.remove(e)}},Fe=ee("MemoizedFunction",(function(e,n){if(this.base=e,null!=n)if(1===(n=O(n)).length){this.cache=new pe;var r=n[0];this._cacheKeyFormatter=e=>e[r]}else this.cache=new je,this._cacheKeyFormatter=e=>ie(e,n);else this.cache=new je,this._cacheKeyFormatter=e=>e;var i=this;return function(){var n=i._cacheKeyFormatter(arguments);return i.cache.get(n,(()=>e.apply(this,arguments)))}}),{remove(e){return this.cache.remove(this._cacheKeyFormatter(e))}}),ke=function(e,n){return new Fe(e,n)},De=function(e){return y(e,Object)},_e=function(e){return new Set(e)},Ie=function(e){var n={};if(e){var r=_e(e);r.has("g")&&(n.global=!0),r.has("i")&&(n.caseInsensitive=!0),r.has("y")&&(n.sticky=!0)}return n},Ce=function(e){var n="";return e.global&&(n+="g"),(e.caseInsensitive||0==e.caseSensitive)&&(n+="i"),e.sticky&&(n+="y"),n},Pe=function(e,n){var r=Ie(e);return Ce(Object.assign(r,n))},Le=function(e,n){var r=n,i=void 0;return g(r)?i=r:De(r)&&(i=Pe(e.flags,r)),new RegExp(e,i)},Me=function(e,n){return Le(e,e.flags+n)},Re=function(e){return Me(e,"g")},qe=ke((function(e){return e.global?e:Re(e)}),0),Ge=function(e){var n=e;return null==n?void 0:g(n)?n:Ce(n)},Be=function(e,n){return new RegExp(e,Ge(n))},We=function(e){return e.replace(/[-[\]{}()*+!<=:?.\/\\^$|#\s,]/g,"\\$&")},Ke=function(e,n){return Be(We(e),n)},Ue=function(e,n,r,i,u,o){return m(e,(function(e){return e.replaceAll?(w(n)&&(n=qe(n)),e.replaceAll(n,r)):(n=g(n)?Ke(n,"g"):qe(n),this.replace(n,r))}),i,u,o)},Je=Ue,Ye=function(e){return e[e.length-1]},ze=p,He=function(e,n,r){return e=Le(e,{global:!0}),null!=r&&(n=ze(r,n)),e.lastIndex=n,e},Ve=function(e,n,r){return e=null!=r?He(e,r,n):qe(e),Array.from(n.matchAll(e))},$e=function(e,n,r){return null!=r&&(n=n.slice(0,r)),Ye(Ve(e,n))||null},Qe=function(e,n){var r=$e(e,n);return r&&n.length===r.index+r[0].length?r:null},Xe=_(globalThis.TypeError),Ze=function(e){return null==e?e:e.constructor},en=i("util"),nn=function(e,n){return n||(n={}),null==n.colors&&(n.colors=!0),en().inspect(e,n)},rn=function(e,n,r){return Ue(e,n,(r??"\\")+n)},tn=function(e,n,r){return null==n&&(n='"'),!1!==r&&(e=rn(e,n,r)),n+e+n},un=function(e){return tn(e,'"')},on=De,an=function(e){return on(e)?hn(e):String(e)},sn=function(e,n){return n||(n=ln),"["+e.reduce((function(e,r){return e+n(r)+", "}),"").slice(0,-2)+"]"},ln=function(e){return g(e)?un(e):x(e)?sn(e):an(e)},cn=function(e){return Reflect.ownKeys(e)},fn=function(e,n){return(n?cn:Object.keys)(e)},pn=function(e,n,r){fn(e,r).forEach(((r,i,u)=>n(r,e[r],i,u)))},dn=function(e,n,r,i){var u=null!=r?r:"";return pn(e,(function(){u=n.call(this,u,...arguments)}),i),u},hn=function(e,n){return n||(n=ln),"{"+dn(e,(function(e,r,i){return e+r+":"+n(i)+", "}),"",!0).slice(0,-2)+"}"},vn=function(e,n){return null==n&&(n=1),n<=0?"[object Object]":hn(e,(e=>gn(e,n-1)))},mn=function(e,n){return null==n&&(n=1),n<=0?"[object Array]":sn(e,(e=>gn(e,n-1)))},gn=function(e,n){return void 0===e?"undefined":null===e?"null":H()?nn(e,n):De(e)?vn(e,maxNumLevels):x(e)?mn(e,maxNumLevels):an(e)},yn=function(e,n,r,i){if(0===arguments.length)return new Xe("Unexpected type received");i||(i={});var u,{type:o,expected:a}=i;return null==o&&(o=Ze(e)),o&&o.name&&(o=o.name),a?(a.name&&(a=a.name),u="Expected "+a+", received "):u="Unexpected type received (",u+=o,null!=e&&(u+=" ("+gn(e)+")"),a||(u+=")"),r&&(u+=' for "'+r+'"'),null!=n&&(u+=" (index "+n+")"),i.fromFn||(i.fromFn=yn),new Xe(u,i)},bn=function(e,n){if(g(n))return e.endsWith(e);if(w(n))return!!Qe(n,e);throw yn(n,1,"matchThis")},wn=/\/|\\/,xn=function(e){return bn(e,wn)?e:e+"/"},On=function(e,n){return""===e?e:(null==n&&(n=!0),e=Je(e,"\\","/"),n?xn(e):e)},Tn=function(e){return e?f(e)+"AppData/Local/":On(process.env.LOCALAPPDATA)},En=function(){return process.env.TEMP+"\\"},Sn=function(e){return e?Tn(e)+"Temp/":En()},An=function(){return Sn()+"Titan/"},Nn=function(e){return e.charAt(0).toLowerCase()+e.slice(1)},jn=function(e){return e.split(".")[0]},Fn=i("path"),kn=function(e){return Fn().win32.basename(e)},Dn=function(e){return jn(kn(e))},_n=function(n,r,i,u){n||(n=e()??"_console.js");var o=Nn(Dn(n));return r&&(o+="_repl"),o+(i&&u?.dynamic?".dypkg.json":".pkg.js")},In=function(e,n){return e=Fn().dirname(e),!1===n?e:xn(e)},Cn=function(e,n){var r=Fn().resolve;return n?r(n,e):r(e)},Pn=function(e,n,r,i){var u,o=_n(e,n,r,i);return u=e?In(e):"./",Cn(u+o)},Ln=n((function(){var e=process.env.TITAN_PATH;if(!e)throw C("Environment variable TITAN_PATH is not set.");return xn(e)})),Mn=n((function(){return Ln()+"Compiled/"})),Rn=function(){return new Date},qn=function(e,n,r,i){var u="Required argument";return r&&(u+=' "'+r+'"'),null!=n&&(u+=" (index "+n+")"),u+=" missing",arguments.length>0&&(u+=" (received "+gn(e)+")"),C(u,null,R(i,qn))},Gn=function(e){return new Date(e.getTime())},Bn=function(e){return new Date(e,null)},Wn=function(e){var n=new Date(e);return isNaN(n.getTime())?null:n},Kn=function(e){return isNaN(e)?null:e},Un=function(e){return null==e?null:Kn(Number(e))},Jn=Un,Yn=function(e){return"number"==typeof e},zn=function(e,n){if(null==e)throw qn(e,0);if(e.constructor===Date)return n?Gn(e):e;if(g(e)){var r=Jn(e);return null!=r?Bn(r):Wn(e)||null}return Yn(e)?Bn(e):void 0},Hn=function(e,n){return null==e?Rn():zn(e,n)},Vn=function(e){return Hn(e,!0)},$n=Vn,Qn=function(){var e=Mn()+"LastCompileTime.txt";return c(e)?$n(o(e)):null},Xn=function(e){return s(e).mtime},Zn=function(e,n,r){return e=zn(e),n=zn(n),!1===r?e<n:e<=n},er=function(e){var n=Qn();if(n){var r=Xn(e);if(Zn(r,n))return!0}return!1},nr=function(e){var n=process.mainModule?.path;return null==n?null:!1!==e?xn(n):n},rr=function(e){return JSON.parse(a(e))},tr=function(e,n,r,i){Object.defineProperty(e,n,{get:r,set:i,enumerable:!0,configurable:!0})},ir=tr,ur=function(e,n,r){arguments.length<3&&(r=e[n]),Object.defineProperty(e,n,{value:r,writable:!0,enumerable:!0,configurable:!0})},or=ur,ar=function(e,n,r){ir(e,n,(function(){var i=r(n,e);return this[n]=i,i}),(function(e){or(this,n,e)}))},sr=function(e,n){var r=e.globals,i=e.shortNamesToGlobals;Object.keys(i).forEach((e=>{for(var u=i[e],o=u.length,a=0;a<o;a++){var s=u[a],l=globalThis[s];l||(l=globalThis[s]={});var c=r[s];Object.keys(c).forEach((r=>{var i=n[e][r];l[r]=i}))}})),n._meta||(n._meta={}),n._meta.globals=e.globals},lr=function n(r,i,u){const o=Fn();if(r)r=o.resolve(nr(),r);else{var a=e();if(!a)throw new Error("Cannot find package name because scriptPath does not exist.");var s=o.dirname(a),l=o.basename(a).split(".")[0];l=l[0].toLowerCase()+l.slice(1),r=o.join(s,l+".pkg.json")}for(var c=rr(r),f=ar,p=c.itemsInOrder,d=p.length,h=0;h<d;h++){let e=p[h],[n,r,u]=e,o=i[n];o||(o=i[n]={}),Object.hasOwn(o,r)||f(o,r,(function(){let t=i;return eval("("+u+")")}))}c.globals&&sr(c,i)},cr=function(e){return require(e)},fr=function(e){return!!e.startsWith("node:")||cr("node:module").isBuiltin(e)},pr=function(e){return e.startsWith(".")},dr=class extends I{constructor(e,n){super(e??"Unexpected value",n)}},hr=function(e,n,r,i){if(0===arguments.length)return new dr("Unexpected value received");i||(i={});var u,{expected:o}=i;return u=o?"Received "+gn(e)+", expected one of "+gn(o):"Unexpected value received: "+gn(e),r&&(u+=' for "'+r+'"'),null!=n&&(u+=" (index "+n+")"),i.fromFn||(i.fromFn=hr),new dr(u,i)},vr=function(e){var n=e.stdio;if(n){if(!x(n)){if(!g(n))throw yn(n,"stdio");if("pipe"===n)n=["pipe","pipe","pipe"];else if("inherit"===n)n=["inherit","inherit","inherit"];else if("ignore"===n)n=["ignore","ignore","ignore"];else{if("overlapped"!==n)throw hr(n,"stdio");n=["overlapped","overlapped","overlapped"]}e.stdio=n}}else n=e.stdio=[null,null,null];return n},mr=function(e,n){var r=n.length;e.length=r;for(var i=0;i<r;i++)e[i]=n[i];return e},gr=function(e){return function(){return!e.apply(this,arguments)}},yr=function(e,n){return mr(e,e.filter(gr(n)))},br=function(e){return yr(e,(e=>null==e))},wr=i("child_process"),xr=n((function(){return"win32"===process.platform})),Or=function(e,n,r){if(r||(r={}),n(e))throw e;if(r.nullOnErr&&(r.err=null),void 0!==r.err)return r.err;if(r.onErr)return r.onErr(e,e.stderr);throw e},Tr=function(e,n,r){r||(r={}),r.dir&&(r.cwd=r.dir);var i=vr(r);if(null==i[0]){var u=r.allowInput,o=r.input;if(u&&o)throw C("allowInput (user) and input (programmatic) cannot be used simultaneously for synchronous child processes.");u&&(i[0]="inherit")}if(null==i[1]){var a=r.captureOutput??!1,s=r.showOutput;if(a&&s)throw C("captureOutput and showOutput cannot be used simultaneously for synchronous child processes.");a?i[1]="pipe":(null==s&&(s=!0),i[1]=s?"inherit":"ignore")}if(null==i[2]){var l=r.captureErr??!1,c=r.showErr;if(l&&c)throw C("captureErr and showErr cannot be used simultaneously for synchronous child processes.");l?i[2]="pipe":(null==c&&(c=!0),i[2]=c?"inherit":"ignore")}r.encoding||(r.encoding="utf8"),n&&br(n);try{var f=wr().execFileSync(e,n,r);null!=f&&(f=f.trim());var p=r.map??r.mapFn;return p&&(f=p(f)),f}catch(e){if(xr())return Or(e,(e=>"ENOENT"===e.code),r);throw e}},Er=function(e,n){return n||(n={}),null==n.captureOutput&&(n.captureOutput=!1),n.shell=!0,n.filterExtensions=!1,Tr("npm",e,n)},Sr=function(e,n,r){return Er(["install",e,n?"-g":null],r)},Ar=function(e){return require(Cn(e))},Nr=class{constructor(){this.store={}}get(e,n){return L(this.store,e,n)}remove(e){return delete this.store[e]}delete(e){return this.remove(e)}},jr=new Nr,Fr=i("module"),kr=function(e){return e.endsWith("\\node_modules")||(e+="\\node_modules"),Fr().createRequire(e)},Dr=function(e,n){return jr.get(e,(()=>kr(e)))(n)},_r=function(e,n,r){return Object.keys(n).forEach((i=>L(e,i,n[i],r))),e},Ir=function(e,n,r){return n?_r(e,n,r):e},Cr=function(e,n){return e.endsWith(n)?e.substring(0,e.length-n.length):e},Pr=function(e,n){var r=Qe(n,e);return r?e.slice(0,r.index):e},Lr=function(e,n){if(g(n))return Cr(e,n);if(w(n))return Pr(e,n);throw yn(n,1)},Mr=Lr,Rr=function(e,n){return[e.slice(0,n),e.slice(n)]},qr=function(e){e=Mr(e.trim(),";");var n=Math.max(e.lastIndexOf(";"),e.lastIndexOf("\n"));return Rr(e,n+1)},Gr=function(e,n){return e.startsWith(n)?e:n+e},Br=function(e){var[n,r]=qr(e);return n+Gr(r.trim(),"return ")},Wr=function(e){return Wt("node-repl-await").processTopLevelAwait(e)},Kr=function(e){return Wr(e)??e},Ur=function(e){return'require("'+On(Pn(),!1)+'");\n'+e},Jr=function(e,n){return Ue(e,n,"")},Yr=function(e,n){return n.forEach((n=>e=Jr(e,n))),e},zr=function(e){return Yr(e,["\r","\n"])},Hr=function(e){return zr(Yt(e))},Vr=function(e,n,r){return(n||r)&&(n||(n={}),r&&Ir(n,r),n.ensureReturn&&(e=Br(e)),n.topLevelAwait&&(e=Kr(e)),n.useTitan&&(e=Ur(e)),n.keepAlive&&(e="\nsetInterval(()=>{}, 100000);\n"+e),(n.logErrors||n.keepAlive)&&(e="process.on('uncaughtException', console.error);\nprocess.on('unhandledRejection', console.error);\n"+e),n.inline&&(e=Hr(e))),e},$r=function(e){return g(e)?e:an(e)},Qr=function(e){var n=e.indexOf("{");return-1===n||e.slice(0,n).includes("=>")},Xr=function(e,n,r,i,u){return v(e,n,r,i,((n,r)=>null===n?null:(n.input=e,void 0!==r&&(n.index+=r),n)),u)},Zr=function(e,n){return e.splice(e.length,0,...n),n},et=function(e,n){return Zr(e,n),e},nt=et,rt=class extends Array{constructor(e,n,r,i,u){if(-1===n)throw C("RegexResult index cannot be -1. For empty result, use bare null.");if(null==e)throw C("RegexResult matchString cannot be null. For empty result, use bare null.");super(),this[0]=e,i&&nt(this,i),this.index=n,this.input=r,u&&(this.groups=u)}fromParts(e){var n=e;return new rt(n.match,n.index,n.input,n.captures,n.groups)}},tt=function(e,n,r,i,u){return new rt(e,n,r,i,u)},it=function(e,n,r,i,u){return-1===n||null==e?null:tt(e,n,r,i,u)},ut=Jr,ot=function(e,n){return Le(e,ut(e.flags,n))},at=function(e){return ot(e,"g")},st=ke((function(e){return e.global?at(e):e}),0),lt=function(e,n,r){return(e=null!=r?He(e,r,n):st(e)).exec(n)},ct=function(e,n,r,i,u){return Xr(e,(e=>{if(g(n)){var r=e.indexOf(n);return it(n,r,e)}return lt(n,e)}),r,i,u)},ft=function(e){return e.index+e[0].length},pt=function(e,n){var r=ct(e,n);return null===r[0]?null:e.slice(ft(r))},dt=function(e,n){return e.startsWith(n)?e.substring(n.length):e},ht=function(e,n){var r=lt(e,n);return r&&0===r.index?r:null},vt=function(e,n){var r=ht(n,e);return r?e.slice(r[0].length):e},mt=function(e,n){if(g(n))return dt(e,n);if(w(n))return vt(e,n);throw yn(n,1)},gt=mt,yt=function(e){var n=pt(e,"=>").trim();return gt(Mr(n,"}"),"{")},bt=function(e){return pt(e,"{").slice(0,-1)},wt=function(e){var n=$r(e);return Qr(n)?yt(n):bt(n)},xt=function(e){return null==e?"":g(e)?e:S(e)?wt(e):String(e)},Ot=function(e,n){var r=n?.basic?null:{topLevelAwait:!0,useTitan:!0},i=Vr(xt(e),n,r);return Tr("node",["-e",i],n)},Tt=function(e,n,r){if(null==e)throw qn(e,n,r,{fromFn:Tt});return e},Et=function(e,n){return process.kill(e,Tt(n,0,"signalName"))},St=function(e){return Et(e,"SIGINT")},At=function(){return St(process.pid)},Nt=At,jt=function(e){if("Y"===(e=e.toUpperCase()))return!0;if("N"===e)return!1;throw hr(e,0,"char")},Ft=function(e){null==e&&(e="Are you sure? [y/n]: "),process.stdout.write(e);var n=Ot((function(){const e=process.stdin,n=process.stdout;e.setRawMode(!0),e.setEncoding("utf8"),e.on("data",(e=>{var r=e.toUpperCase();"Y"===r||"N"===r?(n.write(e),process.exit(0)):""===e&&(n.write("^C"),process.exit(0))}))}),{basic:!0,stdio:["inherit","pipe"]});if("^C"===n)throw process.stdout.write(n),Nt(),C("Prompt was cancelled via interrupt.");return console.log(n),jt(n)},kt=function(e){return x(e)?e:g(e)?e.split("."):[e]},Dt=function(e,n,r,i,u,o){var a=r;return we(e,n,i,u,o,((e,n,r)=>r(e,n,ae(a))))},It=function(e,n){var r=n,i=globalThis.config;i||(i=globalThis.config={});var u,o=kt(e);return o.length>1?u=Dt(i,o,r):(u=ae(r),i[o[0]]=u),u},Ct=function(e,n){return It("node.require.customDirs",(r=>(r||(r=[]),!1!==n&&(e.endsWith("node_modules")||(e+="\\node_modules")),r.includes(e)||r.push(e),r))),e},Pt=Ct,Lt=we,Mt=function(e){var n=globalThis.config;if(n){var r=kt(e);return r.length>1?Lt(n,r):n[r[0]]}},Rt=function(e,n,r){if(null!=e)return e;var i=Mt(n);return null!=i?i:r},qt=function(e){var n=In(e,!1);return c(n)||(n!==e&&qt(n),u().mkdirSync(n)),e},Gt=function(e){return qt(e),u().mkdirSync(e),e},Bt=function(e){return c(e)?e:Gt(e)},Wt=function(e,n){if(fr(e))return require(e);if(pr(e))return Ar(e);try{return require(e)}catch(e){}var r=__dirname,i=process.mainModule?.path;if(i!==r)try{return Dr(i,e)}catch(e){}var u=process.cwd();if(u!==i&&u!==r)try{return Dr(u,e)}catch(e){}var o=Mt("node.require.customDirs");if(o)for(var a of o)try{return Dr(a,e)}catch(e){}var s=Rt(n?.autoInstall,"node.require.autoInstall"),l=Rt(n?.promptInstall,"node.require.promptInstall",!0);if(s||l){var c=s||l;!0===c&&(c="./node_modules"),c=Cn(c);var f=!1;if(s?(f=!0,console.log('Auto-installing "'+e+'" from npm to "'+c+'"...')):(f=Ft('Npm package "'+e+'" is required. Install now? (Y/N) '))&&console.log('Installing "'+e+'" from npm to "'+c+'"...'),f){c=Bt(c),Sr(e,!1,{cwd:c});try{return Pt(c),Dr(c,e)}catch(e){console.error("Failed to load from auto-install dir: ",c)}}}throw C('Module not found: "'+e+'"',{checked:{moduleDir:r,scriptDir:i,cwd:u}})},Kt=function(e,n){return Wt("astring").generate(e,n)},Ut=function(e,n){return e.stack=n+"\n"+e.stack,e},Jt=function(e,n,r){r||(r={}),!1!==n&&(r.sourceType="module"),null==r.allowAwaitOutsideFunction&&(r.allowAwaitOutsideFunction=!0);var i=Wt("acorn-node");try{return i.parse(e,r)}catch(n){throw Ut(n,"Acorn parsing error: "+e)}},Yt=function(e,n,r){return Kt(Jt(e,n,r))},zt=/(['"])(.*?)\1/,Ht=Re(zt),Vt=function(e){return e.replace(Ht,"")},$t=Vt,Qt=function(e){return globalThis.structuredClone(e)},Xt=Qt,Zt=ke,ei=/\r?\n/,ni=function(e){return null==e||void 0!==e.length&&0===e.length},ri=function(e,n){return yr(e,ni)},ti=function(e,n){return e.splice(n,1),e},ii=function(e,n,r,i){[r,i]=ne(e,r,i);for(var u=r;u<i;u++){var o=n(e[u],u,e);void 0!==o&&(e[u]=o)}return e},ui=function(e,n,r){for(var i={},u=e.length,o=0;o<u;o++){var a=n(e[o],o,e);if(a){var[s,l]=a;r?(i[s]||(i[s]=[]),i[s].push(l)):i[s]=l}}return i},oi=function(e,n,r,i){return[n,r]=ne(e,n,r,i),e.slice(n,r)},ai=function(e,n){return te(n,e).join("")},si=function(e){return e?e[0]:null},li=function(e,n){var r=null==n?-1:n.index;if(-1===r)return[e];var i=Rr(e,r);return i[1]=i[1].slice(n[0].length),i},ci=function(e,n,r,i,u){return li(e,ct(e,n,r,i,u))},fi=Un,pi=function(e){return fi(e)??e},di=function(e,n){null==n&&(n="=");var r={};return e.forEach((function(e){var[i,u]=ci(e,n);null!=u&&(u=pi(u.trim())),r[i.trim()]=u})),r},hi=M,vi=class extends Array{constructor(e){var n,r=e;null!=r&&(x(r)?n=r:g(r)&&(n=r.split(ei))),n?(super(n.length),Object.assign(this,n)):super(...arguments)}condense(e){return this.trim().removeEmpty(),e&&this.removeComments(e),this}trim(){return this.apply((e=>e.trim()))}removeEmpty(){return ri(this)}removeComments(e){for(var n=0;n<this.length;n++){var r=this[n],i=r.indexOf(e);-1!==i&&(""===(r=r.slice(0,i)).trim()?(ti(this,n),n--):this[n]=r)}return this}removeFirst(){return this.shift(),this}removeLast(){return this.pop(),this}apply(e){return ii(this,e)}join(){return super.join("\n")}toObj(e){return di(this,e)}mapToObj(e,n){return ui(this,e,n)}between(e,n,r){return r=hi(r,"inclusiveEnd",!0),oi(this,e,n,r)}normalize(){if(this.length>0&&(""===this[0].trim()&&this.shift(),this.length>0&&(""===Ye(this).trim()&&this.pop(),this.length>0))){var e=this.find((e=>""!==e.trim())),n=si(lt(/^\s*/,e));if(n){var r=n.length;this.apply((e=>{if(e.startsWith(n))return e.slice(r)}))}}return this}deindent(e,n,r){throw q()}indent(e,n){var r=ai(n??"\t",e??1);return this.apply((e=>r+e))}static is(e){return y(e,this)}static fromChunks(e){return e.map((e=>Mr(e,ei))).flatMap((e=>gi(e,!1)))}},mi=function(e,n){var r=new vi(e);return n&&r.condense(),r},gi=function(e,n,r){var i=e.split(ei);return n?mi(i,r):i},yi=function(e,n){return gi(a(e),!0,n)},bi=function(e,n){return st(e).test(n)},wi=function(e,n){return w(n)?bi(n,e):e.includes(n)},xi=function(e,n,r,i){null==e&&(e=""),null==n&&(n="");var u={},o=(r,i)=>u[e+r+n]=i;return i&&pn(i,o),r&&pn(r,o),u},Oi=function(e,n){return pn(n,((n,r)=>e=Ue(e,n,r))),e},Ti=function(e,n,r,i){var u,o;if(n)if(g(n)){if(!wi(e,n))return e;u=n}else{if(!x(n))throw yn(n,1,"paramIdentifier");if([u,o]=n,!wi(e,u)&&!wi(e,o))return e}var a=xi(u,o,r,i);return Oi(e,a)},Ei=function(e){return String(e)},Si=globalThis.process?.env.windir,Ai=function(e){return f(e)+"Desktop/"},Ni={PROGRAMFILES:globalThis.process?.env.ProgramFiles,WINDIR:Si,SYSTEM32:Si&&Si+"System32",TEMP:En(),DESKTOP:Ai()},ji=function(e,n){return Ti(Ei(e),"$",n,Ni)},Fi=function(){return Ln()+"Source/SourceMap.txt"},ki=function(e){return e?ji(e,{TITAN:Ln()}):Fi()},Di=function(e,n,r,i,u){return v(e,n,r,i,((e,n)=>-1===e?-1:void 0===n?e:n+e),u)},_i=function(e,n){return Array.prototype.findIndex.call(e,n)},Ii=function(e,n,r,i,u){var o=g(n);return o&&null==i&&!u?e.indexOf(n,r):Di(e,(e=>o?e.indexOf(n):w(n)?e.search(n):_i(e,n)),r,i,u)},Ci=function(e,n,r,i,u){var o=Ii(e,n,r,i,u);return-1===o?null:e.slice(r,o)},Pi=function(e){var n=e[0];return n===n.toUpperCase()},Li=function(e,n){var r=[],i=[];return e.forEach(((u,o)=>(n(u,o,e)?r:i).push(u))),[r,i]},Mi=Zt((function(e){var n=yi(ki(e),!0),r={};return n.forEach((e=>{var n=Ci(e,"=").split(",").map((e=>e.trim())),[i,u]=Li(n,(e=>!Pi(e))),o=i[0];if(!o)throw C('No shortName in SourceMap line: "'+e+'"');u.forEach((e=>{r[e]=o}))})),r}),0),Ri=n((function(e){var n=Object.keys(e);return Be("\\b("+n.join("|")+")\\.(\\w+)","g")})),qi=/\bt\.(\w+)\.(\w+)/g,Gi=function(e,n){n||(n={});var r={},i=r.t={};if(n.enableGlobals){var u;u=n.additionalGlobals?Xt(n.additionalGlobals):{},r.globals=u;var o=Mi(),a=Ri(o),s=Ve(a,e).filter((n=>{var r=n[1],i=n[2],u=e[n.index-1];if("."===u||"_"===u)return!1;var o=globalThis[r];return!o||void 0===o[i]}));for(var[l,c,f]of s)u[c]||(u[c]={}),u[c][f]=!0;var p=s.map((([e,n,r])=>{var i=o[n];if(!i)throw C("No short name found for global: "+n);return"t."+i+"."+r+";"})).join(" ");e+="\n"+p}for(var[l,d,f]of s=e.matchAll(qi))i[d]||(i[d]={}),i[d][f]=!0;return r},Bi=function(e,n){return e=Yt(e),e=$t(e),Gi(e,n)},Wi=function(e,n){return Gi(e,n)},Ki=function(e,n,r){if(n){if("js"===(n=n.toLowerCase()))return Bi(e,r);if("html"===n)return Wi(e,r)}return Gi(e,r)},Ui=function(e,n){return n in e},Ji=Ui,Yi=function(e,n){for(var r of(Tt(n,1),Object.keys(e))){if(!Ji(n,r))return!1;var i=e[r];if(i&&i.constructor===Object&&!Yi(i,n[r]))return!1}return!0},zi=function(e,n){if(!Yi(n.t,e))return!0;if(n.globals){var r=e._meta?.globals;if(!r)return!0;if(!Yi(n.globals,r))return!0}return!1},Hi=function(e,n,r,i){var u,o,s,l;i||(i={}),e&&(e=Cn(e)),u=i.packagePath?Cn(i.packagePath):Pn(e,!1,!0,i);var f,p=c(u);p?(o=er(u))?s="New compile":(null==n&&(n=a(e)),l=Ki(n,"js",i),(f=zi(r,l))&&(s="New deps")):s="No package";var d={needsPack:!!s,scriptPath:e,packagePath:u};return s&&(d.reasonText=s),null!=p&&(d.exists=p),null!=o&&(d.newCompile=o),null!=f&&(d.newDeps=f),n&&(d.sourceText=n),l&&(d.shallowDeps=l),d},Vi=function(e){return bn(e,wn)},$i=function(e,n){var r=$e(e,n);return r?r.index:-1},Qi=wn,Xi=function(e){var n=$i(Qi,e);return-1===n?null:e.slice(0,n+1)},Zi=function(e,n,r){if(Vi(e))return r?[e,null]:e;var i,u,o=Xi(e),a=n(kn(e),o,e);return r?[i,u]=a:i=a,null!=i&&(e=o?o+i:i),r?[e,u]:e},eu=function(e,n,r,i,u){return Xr(e,(e=>{if(w(n))return $e(n,e);if(g(n)){var r=e.lastIndexOf(n);return-1!==r?new rt(n,r):null}throw yn(n,1)}),r,i,u)},nu=function(e,n,r,i,u){return li(e,eu(e,n,r,i,u))},ru=function(e){return Zi(e,(e=>nu(e,".")),!0)},tu=function(e,n){var r=ru(e)[1];return r?!1!==n?r.toLowerCase():r:null},iu={},uu=function(e,n,r){if(H()){var i=Fn().join(e,n);return r?xn(i):i}throw q()},ou=Zt((function(e){e=ki(e);var n=In(e)+"../Compiled/",r=yi(e,"//"),i=iu;for(var u of r){var o=u.indexOf("="),a=u.slice(0,o).trim();a=a.split(",").map((e=>e.trim())).filter((e=>!Pi(e)));var s=u.slice(o+1).trim(),l=uu(n,s).replaceAll("\\","/");for(var c of a)i[c]=l}return i}),0),au=function(e,n){var r=n?.fileType;if(r){if("js"===(r=r.toLowerCase()))return Bi(e,n);if("html"===r)return Wi(e,n)}return Gi(e,n)},su=function*(e,n){var r=0;for(var i of e)n(i,r++,e)&&(yield i)},lu=function(e){return e.slice()},cu=function(e,n,r){for(var i=e.length-1;i>=n;i--)e[i+1]=e[i];return e[n]=r,e.length++,e},fu=function(e,n){return cu(e,e.length,n)},pu=fu,du=function(e,n){return e.call(this,...n,(function n(){return Ye(arguments)!==n&&pu(arguments,n),e.apply(this,arguments)}))},hu=function(e){e||(e={});var n=e.getKeys;n||(n=function(e){return Object.keys(e)});var r=e.recurseIf;if(!r){var i=this.constructor;r=e=>y(e,i)||on(e)||x(e)}var u=e.leavesOnly??e.leafsOnly??!1,o=this;return du((function*(e,i,a,s){var l=n(e,i,a);if(l)for(var c=l.length,f=0;f<c;f++){var p=l[f],d=e[p],h=lu(i);h.push(p);var v=null,m={value:d,key:p,object:e,path:h,level:a,isLeaf:v,root:o},g=r(d,m);m.isLeaf=v=!g,u&&!v||(yield m),g&&(yield*s(d,h,a+1,s))}}),[this,[],0])},vu=function(e,n){return hu.call(e,n)},mu=function(e,n){1===arguments.length&&(n=!0);var r={};for(var i of e)r[i]=n;return r},gu=function(e,n,r,i){var u=Jt(e,n,i);Wt("acorn-walk").full(u,r)},yu=function(e,n,r,i){var u;if(g(r))u=e=>e.type===r;else if(x(r)){var o=mu(r);u=e=>o[e.type]}else u=r;var a=[];return gu(e,n,(function(e){u.apply(this,arguments)&&a.push(e)}),i),a},bu=Kt,wu=function(e){var n,r,i,u=e,o=g(u)?Jt(u).body[0]:u,a=o.type;if("VariableDeclaration"===a){n="variable";var s=o.declarations[0];r=s.id.name,i=s.init?s.init.raw??Kt(s.init):"undefined"}else"FunctionDeclaration"===a?n="function":"ClassDeclaration"===a&&(n="class"),r=o.id.name;var l={type:n,name:r};return i&&(l.value=i),l.text=bu(o),l.node=o,l},xu=function(e){return yu(e,!0,["ExportNamedDeclaration","ExportDefaultDeclaration"]).map((function(e){var n=e.declaration;if(n){var r=wu(n);return r.node=e,r}return{node:e}}))},Ou=function(e,n){n||(n={});var r=n.enableGlobals,i=ou(n.sourceMap),u={},a=[];return function e(n,s,l){var f=su(vu(n),(e=>e.isLeaf));for(var p of f){var[d,h]=p.path,v=u[d];if(v||(v=u[d]={}),null==v[h]){var m=i[d];if(m){var g=On(m)+h+".js";if(!c(g)){var y='Titan compiled value "t.'+d+"."+h+'" does not exist';throw l&&(y+=' (called by "t.'+s+"."+l+'")'),C(y+=".")}var b=o(g),w=xu(b)[0];v[h]=w,e(au(b,{fileType:"js",enableGlobals:r}).t,d,h),a.push([d,h])}else console.log('Skipping unmapped module "'+d+'"'),v[h]=!1}}}(e.t),{t:u,globals:e.globals,order:a}},Tu=function(e,n){n||(n={});var r=n.deps??Ki(e,n.fileType,n),{t:i,globals:u,order:o}=Ou(r,n),a={};if(a.t=r.t,u&&n.enableGlobals){a.globals=u;var s=Mi(),l=Object.keys(u),c=ui(l,(e=>[s[e],e]),!0);a.shortNamesToGlobals=c}return a.itemsInOrder=o.map((([e,n])=>{var r=i[e][n];return[e,n,"variable"===r.type?r.value:"("+r.text+")"]})),a},Eu=function(e,n,r){return null==r&&(r=!0),du((function(e,n,i){pn(e,(function(e,u){if(Ji(n,e)){var o=n[e];r?De(o)&&De(u)?i(u,o):n[e]=u:De(o)&&i(u,o)}else n[e]=u}))}),[e,n]),n},Su=Eu,Au=function(e){return Object.assign({},e)},Nu=function(e,n){if(n){var r={};return e.forEach(((e,i,u)=>r[n(e,i,u)]=!0)),r}return Au(e)},ju=function(e,n){Su(n.t,e.t,!1);var r=n.globals;if(r){var i=e.globals;i?Su(r,i,!1):e.globals=r,e.shortNamesToGlobals=n.shortNamesToGlobals}var u=Nu(e.itemsInOrder,(e=>e[0]+"."+e[1]));return n.itemsInOrder.forEach((n=>{u[n[0]+"."+n[1]]||e.itemsInOrder.push(n)})),e},Fu=function(e){return e instanceof Buffer},ku=function(e){return ArrayBuffer.isView(e)},Du=ku,_u=function(e){return Fu(e)||Du(e)||g(e)},Iu=function(e){return e.constructor===ArrayBuffer},Cu=function(e){return _u(e)?e:Iu(e)?Buffer.from(e):an(e)},Pu=function(e){return Yn(e)?String(e):Cu(e)},Lu=function(e,n){return qt(e),u().writeFileSync(e,Pu(n)),e},Mu=function(e,n){var r;return n||(n={}),r=n.condensed?0:null!=n.whitespace?n.whitespace:"\t",JSON.stringify(e,n.replacer,r)},Ru=function(e,n,r){return Lu(e,Mu(n,r))},qu=function(e,n,r){r||(r={}),r.deps||r.fileType||!n||(r.fileType=tu(n));var i=Tu(e,r),u=r.packagePath||Pn(n,r.repl,!0,r);if(r.dynamic&&(r.packageExists??c(u))&&!(r.newCompile??er(u))){var o=rr(u);i=ju(o,i)}return Ru(u,i),u},Gu=function(e,n,r,i){var u=Hi(e,n,r,i);return u.needsPack&&(i.onPack&&i.onPack(u.reasonText),n=u.sourceText??a(e),i.packagePath=u.packagePath,i.packageExists=u.exists,i.newCompile=u.newCompile,i.deps=u.shallowDeps,qu(n,e,i),lr(u.packagePath,r,i)),r},Bu={node:{getScriptPath:e,fs:u,_builtInModule:i,requireBuiltIn:r,is:H,display:nn,util:en,path:Fn,getScriptDir:nr,require:Wt,_basicRequire:cr,child_process:wr,requireLocal:Ar,_requireFromDir:Dr,_requireDirCache:jr,_createRequire:kr,module:Fr,promptYNSync:Ft,run:Ot,sigint:Nt,interrupt:At,ensureRequireDir:Pt,addRequireDir:Ct},fs:{loadText:a,load:o,getID:l,stat:s,exists:c,getModifiedDate:Xn,loadJSON:rr,ensureDir:Bt,mkdir:Gt,ensureParent:qt,loadLines:yi,writeJSON:Ru,write:Lu,formatRaw:Pu},f:{one:n,memoize:ke,MemoizedFunction:Fe,createClass:ee,createConstructor:F,isArrowFn:N,isArrow:A,is:S,wrap:j,ensureConstructor:k,retThis:D,setName:U,not:gr,body:wt,isArrowString:Qr,_getArrowFnBody:yt,_getNormalFnBody:bt,cache:Zt,recurse:du},titan:{getTempDir:An,getPackagePath:Pn,getPackageName:_n,hasNewCompile:er,getLastCompileTime:Qn,getCompiledDir:Mn,locate:Ln,_loadDynamicDeps:lr,_trackGlobals:sr,autoPackAndLoadJSON:Gu,needsToPack:Hi,getShallowDeps:Ki,getDepsFromJS:Bi,_getDepsBasic:Gi,loadGlobalsMap:Mi,_resolveSourceMapPath:ki,locateSourceMap:Fi,_getGlobalsRegex:Ri,depsRegex:qi,getDepsFromHTML:Wi,jsonHasNewDeps:zi,packTextToJSONFile:qu,packTextToJSON:Tu,_getAllDeps:Ou,loadSourceMap:ou,sourceMap:iu,getDeps:au,addNewItemsToJSON:ju},path:{getTempDir:Sn,getLocalData:Tn,getUserDir:f,fws:On,ensureTrailingSlash:xn,_getDefaultTempDir:En,baseName:Dn,_removeExtsFromFile:jn,file:kn,dir:In,abs:Cn,resolveVars:ji,string:Ei,_defaultParams:Ni,windir:Si,getDesktop:Ai,ext:tu,splitExt:ru,ignoreDir:Zi,isDir:Vi,dirPart:Xi,slash:Qi,join:uu},s:{replace:Je,replaceAll:Ue,apply:m,withIndices:v,is:g,chars:_e,endsWith:bn,resolveIndex:ze,toLiteral:un,quote:tn,escape:rn,from:an,decapitalize:Nn,removeTrailing:Mr,removeFromEnd:Lr,_removeStringFromEnd:Cr,_removeRegexFromEnd:Pr,splitAtIndex:Rr,ensureStartsWith:Gr,removeLineBreaks:zr,removeMulti:Yr,removeAll:Jr,resolve:xt,ensure:$r,after:pt,match:ct,_matchWithIndices:Xr,remove:ut,removeLeading:gt,removeFromStart:mt,_removeStringFromStart:dt,_removeRegexFromStart:vt,removeQuotes:Vt,splitLines:gi,lines:mi,LinesArray:vi,repeat:ai,splitFirst:ci,_splitByMatch:li,replaceParams:Ti,contains:wi,_createParamsObj:xi,_replaceByObj:Oi,before:Ci,index:Ii,_indexWithIndices:Di,indexOfFn:_i,isCapitalized:Pi,splitLast:nu,matchLast:eu},a:{wrapIndices:h,wrapIndex:d,resolveIndex:p,is:x,ensure:O,pick:ie,create:te,fill:re,resolveIndices:ne,push:he,add:de,splitLast:be,splitTail:ye,last:Ye,toLiteral:sn,display:mn,removeNullish:br,removeByFilter:yr,replaceContents:mr,pushMulti:nt,addMulti:et,pushThroughMulti:Zr,removeEmpty:ri,removeIndex:ti,apply:ii,mapToObj:ui,slice:oi,filterSplit:Li,copy:lu,toObj:Nu},re:{is:w,ensureGlobal:qe,global:Re,addFlag:Me,copy:Le,updateFlagString:Pe,parseFlagString:Ie,createFlagString:Ce,createEscaped:Ke,create:Be,resolveFlags:Ge,escape:We,matchEnd:Qe,matchLast:$e,matchAll:Ve,setStartIndex:He,slash:wn,safeCreateResult:it,createResult:tt,RegexResult:rt,match:lt,ensureLocal:st,local:at,removeFlag:ot,resultEndIndex:ft,matchStart:ht,quotes:Ht,quote:zt,newline:ei,text:si,test:bi,lastIndex:$i},o:{constructorMatches:b,safeEnsure:M,ensure:L,isAny:B,setHidden:K,addNonEnumerable:W,hideKey:Z,makeNonEnumerable:X,ensureCustom:se,get:ue,set:oe,createEmpty:ge,remove:Ee,is:De,display:vn,toLiteral:hn,isPure:on,reduce:dn,each:pn,keys:fn,allKeys:cn,setLazy:ar,setGetterAndSetter:ir,addGetterAndSetter:tr,removeGetterAndSetter:or,removeGetter:ur,Cache:Nr,setDefaults:Ir,ensureMulti:_r,resolveKeys:kt,diveGet:Lt,deepCopy:Xt,fromLines:di,safeDefault:hi,hasKey:Ji,has:Ui,fromKeys:mu,fromArray:Au},v:{constructorMatches:y,isPrimitive:G,resolve:ae,type:Ze,display:gn,toLiteral:ln,nullIfNaN:Kn,req:Tt,isEmpty:ni},class:{create:Q,setName:J,addStatics:Y,setDisplay:$},p:{asyncJoint:E,is:T},err:{create:C,Error:I,Enhanced:_,nyi:q,NYIError:P,defaultFromFn:R,type:yn,TypeError:Xe,req:qn,value:hr,ValueError:dr,prepend:Ut},sym:{display:V,value:me},macro:{config:z},map:{Cache:pe,ensure:fe,get:le,set:ce,MultiCache:je,diveEnsure:Te,createEmpty:Oe,diveDelete:Ne,remove:Ae},args:{ensureArray:ve,push:pu,append:fu,insert:cu},tree:{ensure:xe,dive:we,remove:Se,setCustom:Dt,copy:Qt,isSubsetOf:Yi,iterate:vu,iterator:hu,merge:Su,join:Eu},d:{from:$n,create:Vn,resolve:Hn,now:Rn,ensure:zn,copy:Gn,fromYear:Bn,_resolveNative:Wn,isBefore:Zn},n:{fromString:Jn,ensure:Un,is:Yn,tryCoerce:pi,tryParse:fi},js:{removeComments:Yt,fromAST:Kt,enhance:Vr,ensureReturn:Br,splitLastExpression:qr,enableAwait:Kr,_nodeEnableAwait:Wr,useTitan:Ur,inline:Hr,parse:Jt,removeQuotes:$t,getExports:xu,getNodes:yu,eachNode:gu,parseDeclaration:wu,fromASTNode:bu},npm:{isBuiltIn:fr,isFile:pr,install:Sr,_runCommand:Er},os:{run:Tr,_resolveStdio:vr},win:{is:xr},shell:{_handleError:Or},proc:{interrupt:St,signal:Et},bool:{fromYN:jt},env:{setConfig:It,getConfig:Mt,resolveConfig:Rt},gen:{filter:su},bin:{ensureByteSafe:Cu,isByteSafe:_u,isNodeBuffer:Fu,isTA:Du},ab:{isTA:ku,is:Iu},json:{stringify:Mu}};globalThis.t?Object.keys(Bu).forEach((function(e){if(t[e]){var n=Bu[e];Object.keys(n).forEach((function(r){t[e][r]=n[r]}))}else t[e]=Bu[e]})):globalThis.t=Object.assign({},Bu),globalThis.exports&&(exports.default=globalThis.t);
1
+ var e=function(){return process.mainModule?.filename??null},n=function(e){var n,r=!1;return function(){return r||(r=!0,n=e.apply(this,arguments)),n}},r=function(e){return require("node:"+e)},i=function(e){return n(()=>r(e))},u=i("fs"),o=function(e){return u().readFileSync(e,"utf8")},a=o,s=function(e,n){return u().statSync(e,n)},l=function(e,n){return u().lstatSync(e,n)},c=function(e,n,r){return(n?s:l)(e,r)},f=function(e,n){return c(e,n).ino},p=function(e){return!!u().lstatSync(e,{throwIfNoEntry:!1})},d=function(e){return class extends e{constructor(e,n){super(e,n);var r=this.constructor.name;r&&(this.name=r)}}},h=d(globalThis.Error),v=class extends h{constructor(e,n){super(e??"Not yet implemented",n)}},m=function(e){return"function"==typeof e},g=function(e,n,r,i){var u=e[n];if(void 0===u){var o=r;!1!==i&&m(o)&&(o=o(e,n)),e[n]=u=o}return u},y=function(e,n,r,i){return e||(e={}),g(e,n,r,i),e},w=function(e,n){return y(e,"fromFn",n,!1)},b=function(e,n){return new v(e,w(n,b))},x=i("os"),O=i("path"),T=O().sep,E=function(){return x().tmpdir()+T},S=function(e){if(e)throw b();return E()},N=function(){return S()+"Titan/"},j=function(e){return e.charAt(0).toLowerCase()+e.slice(1)},k=function(e){return e.split(".")[0]},A=function(e){return O().win32.basename(e)},F=function(e){return k(A(e))},I=function(n,r,i,u){n||(n=e()??"_console.js");var o=j(F(n));return r&&(o+="_repl"),o+(i&&u?.dynamic?".dypkg.json":".pkg.js")},D=function(e){return"string"==typeof e},_=function(e,n){return null!=e&&e.constructor===n},C=_,P=function(e){return C(e,RegExp)},L=function(e){return e[e.length-1]},M=function(e){return _(e,Object)},R=function(e){return new Set(e)},q=function(e){var n={};if(e){var r=R(e);r.has("g")&&(n.global=!0),r.has("i")&&(n.caseInsensitive=!0),r.has("y")&&(n.sticky=!0)}return n},G=function(e){var n="";return e.global&&(n+="g"),(e.caseInsensitive||0==e.caseSensitive)&&(n+="i"),e.sticky&&(n+="y"),n},B=function(e,n){var r=q(e);return G(Object.assign(r,n))},W=function(e,n){var r=n,i=void 0;return D(r)?i=r:M(r)&&(i=B(e.flags,r)),new RegExp(e,i)},K=function(e,n){return n<0?e.length+n:n},J=K,U=function(e,n,r){return e=W(e,{global:!0}),null!=r&&(n=J(r,n)),e.lastIndex=n,e},Y=function(e){return Array.isArray(e)},z=function(e){return Y(e)?e:[e]},V=function(e){return e instanceof Promise},H=function(e,n){var r=e;return V(r)?r.then(n):n(r)},$=function(e){return m(e)&&null==e.prototype},Q=$,X=function(e){return function(){return e.apply(this,arguments)}},Z=function(e,n){var r;return r=n?function(){this.super=n;var r=e.apply(this,arguments);return H(r,()=>(delete this.super,r))}:Q(e)?X(e):e,r._isConstructor=!0,r},ee=function(e,n){return e._isConstructor?e:Z(e,n)},ne=function(){return this},re=function(e){var n=typeof e;return"object"!==n&&"function"!==n||null===e},te=function(e){return!re(e)},ie=function(e,n,r){return!1===r?Object.keys(n).forEach(r=>{void 0===e[r]&&(e[r]=n[r])}):Object.assign(e,n),e},ue=function(e,n){return ie(e,n,!1)},oe=function(e,n,r,i){return r||(r={}),i&&ue(r,i),null==r.enumerable&&(r.enumerable=!0),null==r.configurable&&(r.configurable=!0),Object.defineProperty(e,n,r)},ae=function(e,n,r,i){return oe(e,n,{value:r,writable:!0,enumerable:!1},i),r},se=ae,le=function(e,n){Object.defineProperty(e,"name",{value:n,configurable:!0}),se(e,"displayName",n)},ce=le,fe=function(e,n){return Object.assign(e,n)},pe=function(e){},de=n(function(){return pe("node.is")??"undefined"==typeof window}),he=de()?require("util").inspect.custom:Symbol("Display"),ve=function(e,n){e.prototype[he]=n},me=function(e,n,r,i,u,o){o||(o={}),D(n)&&(n=null);var a,s,l,c=r;c&&(Y(c)?([s,l]=c,s&&(s=ee(s))):a=ee(c,n));var f=o.bareFn;o.singleton&&(f=function(){return null==h.default&&(h.default=new h(...arguments)),h.default});var p,d=s||a||n||ne;function h(){if(!new.target&&f&&!(this instanceof h))return f.apply(this,arguments);var e=this;return H(d.apply(e,arguments),r=>{if(r&&te(r)&&(e=r,s)){if(!new.target)throw b('Prototype repair is NYI for class instantiation without "new".');if(!n)throw b("instanceFn is not yet supported when extendsClass is null.");var i=Object.getPrototypeOf(this);Object.getPrototypeOf(e)!==i&&Object.setPrototypeOf(e,i)}return l?H(l.apply(e,arguments),()=>e):e})}return e&&ce(h,e),i?(p=i,n&&Object.setPrototypeOf(i,n.prototype)):p=n?Object.create(n.prototype):{},se(p,"constructor",h),h.prototype=p,u&&fe(h,u),o.display&&ve(h,o.display),o.implements&&z(o.implements).forEach(e=>e(h)),h},ge=function(e,n){Object.defineProperty(e,n,{enumerable:!1})},ye=ge,we=function(e,n,r,i,u){var o=Symbol();return me(e,Function,[function(){var e=function(){return e[o].apply(this,arguments)};return e},function(){var e=n.apply(this,arguments);if(!e)throw new Error("Constructor must return a function.");this[o]=e,ye(this,o)}],r,i,u)},be=function(e,n,r,i){return n=null==n?0:K(e,n),r=null==r?e.length:K(e,r),i&&(0==i.inclusiveStart&&n++,i.inclusiveEnd&&r++),[n,r]},xe=function(e,n,r,i){var u=n;if([r,i]=be(e,r,i),m(u))for(var o=r;o<i;o++)e[o]=u(o,e);else e.fill(u,r,i);return e},Oe=function(e,n){var r=new Array(e||0);return arguments.length>1&&xe(r,n),r},Te=function(e,n){return Oe(n.length,r=>e[n[r]])},Ee=function(e,n){return e[n]},Se=function(e,n,r){return e[n]=r},Ne=function(e,n,r){var i=e;return m(i)?i.apply(r,n):i},je=function(e,n,r,i,u){i||(i=Ee);var o=i(e,n);return void 0===o&&(o=Ne(r,[e,n]),u||(u=Se),u(e,n,o)),o},ke=function(e,n){return e.get(n)},Ae=function(e,n,r){return e.set(n,r)},Fe=function(e,n,r){return je(e,n,r,ke,Ae)},Ie=class{constructor(){this.store=new Map}get(e,n){return Fe(this.store,e,n)}remove(e){return this.store.delete(e)}delete(e){return this.remove(e)}},De=function(e,n){return e.push(n),e},_e=De,Ce=function(e){var n=e;return Array.isArray(n)?n:Array.from(n)},Pe=Symbol("Value"),Le=function(){return{}},Me=function(e){return[e.slice(0,-1),e[e.length-1]]},Re=Me,qe=function(e,n,r,i,u,o){r||(r=Ee),null==i&&(i=Le),null==u&&(u=Se),null==o&&(o=r);for(var[a,s]=Re(n),l=e,c=a.length,f=0;f<c;f++){var p=a[f],d=r(l,p);if(void 0===d){if(!i)return;d=je(l,p,i,r,u)}l=d}if(o)return o(l,s,u)},Ge=function(e,n,r,i,u,o){return qe(e,n,i,u,o,(e,n)=>je(e,n,r,i,o))},Be=function(){return new Map},We=function(e,n,r){return Ge(e,n,r,ke,Be,Ae)},Ke=function(e,n){return delete e[n],e},Je=function(e,n,r,i){return qe(e,n,r,!1,!1,i||Ke)},Ue=function(e,n){return e.delete(n)},Ye=function(e,n){return Je(e,n,ke,Ue)},ze=class{constructor(){this.store=new Map}get(e,n){return e=_e(Ce(e),Pe),We(this.store,e,n)}remove(e){return e=_e(Ce(e),Pe),Ye(this.store,e)}delete(e){return this.remove(e)}},Ve=we("MemoizedFunction",function(e,n){if(this.base=e,null!=n)if(1===(n=z(n)).length){this.cache=new Ie;var r=n[0];this._cacheKeyFormatter=e=>e[r]}else this.cache=new ze,this._cacheKeyFormatter=e=>Te(e,n);else this.cache=new ze,this._cacheKeyFormatter=e=>e;var i=this;return function(){var n=i._cacheKeyFormatter(arguments);return i.cache.get(n,()=>e.apply(this,arguments))}},{remove(e){return this.cache.remove(this._cacheKeyFormatter(e))}}),He=function(e,n){return new Ve(e,n)},$e=function(e,n){return W(e,e.flags+n)},Qe=function(e){return $e(e,"g")},Xe=He(function(e){return e.global?e:Qe(e)},0),Ze=function(e,n,r){return e=null!=r?U(e,r,n):Xe(e),Array.from(n.matchAll(e))},en=function(e,n,r){return null!=r&&(n=n.slice(0,r)),L(Ze(e,n))||null},nn=function(e,n){var r=en(e,n);return r&&n.length===r.index+r[0].length?r:null},rn=d(globalThis.TypeError),tn=function(e){return null==e?e:e.constructor},un=i("util"),on=function(e,n){return n||(n={}),null==n.colors&&(n.colors=!0),un().inspect(e,n)},an=K,sn=function(e,n,r,i){return void 0!==n&&(null===n||0===n?n=void 0:(n=an(e,n),i&&0==i.inclusiveStart&&n++)),void 0!==r&&(null===r||r===e.length?r=void 0:(r=an(e,r),i&&i.inclusiveEnd&&r++)),[n,r]},ln=function(e,n,r,i,u,o){if(r||null!=i){[r,i]=sn(e,r,i,o);var a=e.slice(r,i),s=n(a);return u?u(s,r,i,a,e):s}return n(e)},cn=function(e,n,r,i,u){return ln(e,n,r,i,(n,r,i)=>(void 0!==r?e.slice(0,r):"")+(n||"")+(void 0!==i?e.slice(i):""),u)},fn=function(e){var n=e;return null==n?void 0:D(n)?n:G(n)},pn=function(e,n){return new RegExp(e,fn(n))},dn=function(e){return e.replace(/[-[\]{}()*+!<=:?.\/\\^$|#\s,]/g,"\\$&")},hn=function(e,n){return pn(dn(e),n)},vn=function(e,n,r,i,u,o){return cn(e,function(e){return e.replaceAll?(P(n)&&(n=Xe(n)),e.replaceAll(n,r)):(n=D(n)?hn(n,"g"):Xe(n),this.replace(n,r))},i,u,o)},mn=function(e,n,r){return vn(e,n,(r??"\\")+n)},gn=function(e,n,r){return null==n&&(n='"'),!1!==r&&(e=mn(e,n,r)),n+e+n},yn=function(e){return gn(e,'"')},wn=M,bn=function(e){return wn(e)?jn(e):String(e)},xn=function(e,n){return n||(n=On),"["+e.reduce(function(e,r){return e+n(r)+", "},"").slice(0,-2)+"]"},On=function(e){return D(e)?yn(e):Y(e)?xn(e):bn(e)},Tn=function(e){return Reflect.ownKeys(e)},En=function(e,n){return(n?Tn:Object.keys)(e)},Sn=function(e,n,r){En(e,r).forEach((r,i,u)=>n(r,e[r],i,u))},Nn=function(e,n,r,i){var u=null!=r?r:"";return Sn(e,function(){u=n.call(this,u,...arguments)},i),u},jn=function(e,n){return n||(n=On),"{"+Nn(e,function(e,r,i){return e+r+":"+n(i)+", "},"",!0).slice(0,-2)+"}"},kn=function(e,n){return null==n&&(n=1),n<=0?"[object Object]":jn(e,e=>Fn(e,n-1))},An=function(e,n){return null==n&&(n=1),n<=0?"[object Array]":xn(e,e=>Fn(e,n-1))},Fn=function(e,n){return void 0===e?"undefined":null===e?"null":de()?on(e,n):M(e)?kn(e,maxNumLevels):Y(e)?An(e,maxNumLevels):bn(e)},In=function(e,n,r,i){if(0===arguments.length)return new rn("Unexpected type received");i||(i={});var u,{type:o,expected:a}=i;return null==o&&(o=tn(e)),o&&o.name&&(o=o.name),a?(a.name&&(a=a.name),u="Expected "+a+", received "):u="Unexpected type received (",u+=o,null!=e&&(u+=" ("+Fn(e)+")"),a||(u+=")"),r&&(u+=' for "'+r+'"'),null!=n&&(u+=" (index "+n+")"),i.fromFn||(i.fromFn=In),new rn(u,i)},Dn=function(e,n){if(D(n))return e.endsWith(e);if(P(n))return!!nn(n,e);throw In(n,1,"matchThis")},_n=/\/|\\/,Cn=function(e){return Dn(e,_n)?e:e+T},Pn=function(e,n){return e=O().dirname(e),!1===n?e:Cn(e)},Ln=function(e,n,r){var i=O().resolve,u=n?i(n,e):i(e);return r?u+T:u},Mn=function(e,n,r,i){var u,o=I(e,n,r,i);return u=e?Pn(e):"./",Ln(u+o)},Rn=function(e,n,r){var i=new h(e,r);return n&&Object.assign(i,n),i},qn=n(function(){var e=process.env.TITAN_PATH;if(!e)throw Rn("Environment variable TITAN_PATH is not set.");return Cn(e)}),Gn=n(function(){return qn()+"Compiled/"}),Bn=function(){return new Date},Wn=function(e,n,r,i){var u="Required argument";return r&&(u+=' "'+r+'"'),null!=n&&(u+=" (index "+n+")"),u+=" missing",arguments.length>0&&(u+=" (received "+Fn(e)+")"),Rn(u,null,w(i,Wn))},Kn=function(e){return new Date(e.getTime())},Jn=function(e){return new Date(e,null)},Un=function(e){var n=new Date(e);return isNaN(n.getTime())?null:n},Yn=function(e){return isNaN(e)?null:e},zn=function(e){return null==e?null:Yn(Number(e))},Vn=zn,Hn=function(e){var n=typeof e;return"number"===n||"bigint"===n},$n=function(e,n){if(null==e)throw Wn(e,0);if(e.constructor===Date)return n?Kn(e):e;if(D(e)){var r=Vn(e);return null!=r?Jn(r):Un(e)||null}return Hn(e)?Jn(e):void 0},Qn=function(e,n){return null==e?Bn():$n(e,n)},Xn=function(e){return Qn(e,!0)},Zn=Xn,er=function(){var e=Gn()+"LastCompileTime.txt";return p(e)?Zn(o(e)):null},nr=function(e){return c(e).mtime},rr=function(e,n,r){return e=$n(e),n=$n(n),!1===r?e<n:e<=n},tr=function(e){var n=er();if(n){var r=nr(e);if(rr(r,n))return!0}return!1},ir=function(e){var n=process.mainModule?.path;return null==n?null:!1!==e?Cn(n):n},ur=function(e){return JSON.parse(a(e))},or=function(e,n,r,i,u){return oe(e,n,{get:r,set:i},u)},ar=or,sr=function(e,n,r,i){return oe(e,n,{value:r,writable:!0},i)},lr=function(e,n,r,i){ar(e,n,function(){var i=r(n,e);return this[n]=i,i},function(e){sr(this,n,e,i)},i)},cr=function(e,n){var r=e.globals,i=e.shortNamesToGlobals;Object.keys(i).forEach(e=>{for(var u=i[e],o=u.length,a=0;a<o;a++){var s=u[a],l=globalThis[s];l||(l=globalThis[s]={});var c=r[s];Object.keys(c).forEach(r=>{var i=n[e][r];l[r]=i})}}),n._meta||(n._meta={}),n._meta.globals=e.globals},fr=function n(r,i,u){const o=O();if(r)r=o.resolve(ir(),r);else{var a=e();if(!a)throw new Error("Cannot find package name because scriptPath does not exist.");var s=o.dirname(a),l=o.basename(a).split(".")[0];l=l[0].toLowerCase()+l.slice(1),r=o.join(s,l+".pkg.json")}for(var c=ur(r),f=lr,p=c.itemsInOrder,d=p.length,h=0;h<d;h++){let e=p[h],[n,r,u]=e,o=i[n];o||(o=i[n]={}),Object.hasOwn(o,r)||f(o,r,function(){let t=i;return eval("("+u+")")})}c.globals&&cr(c,i)},pr=function(e){return require(e)},dr=function(e){return!!e.startsWith("node:")||pr("node:module").isBuiltin(e)},hr=function(e){return e.startsWith(".")},vr=class extends h{constructor(e,n){super(e??"Unexpected value",n)}},mr=function(e,n,r,i){if(0===arguments.length)return new vr("Unexpected value received");i||(i={});var u,{expected:o}=i;return u=o?"Received "+Fn(e)+", expected one of "+Fn(o):"Unexpected value received: "+Fn(e),r&&(u+=' for "'+r+'"'),null!=n&&(u+=" (index "+n+")"),i.fromFn||(i.fromFn=mr),new vr(u,i)},gr=function(e){var n=e.stdio;if(n){if(!Y(n)){if(!D(n))throw In(n,"stdio");if("pipe"===n)n=["pipe","pipe","pipe"];else if("inherit"===n)n=["inherit","inherit","inherit"];else if("ignore"===n)n=["ignore","ignore","ignore"];else{if("overlapped"!==n)throw mr(n,"stdio");n=["overlapped","overlapped","overlapped"]}e.stdio=n}}else n=e.stdio=[null,null,null];return n},yr=function(e,n){var r=n.length;e.length=r;for(var i=0;i<r;i++)e[i]=n[i];return e},wr=function(e){return function(){return!e.apply(this,arguments)}},br=function(e,n){return yr(e,e.filter(wr(n)))},xr=function(e){return br(e,e=>null==e)},Or=i("child_process"),Tr=n(function(){return"win32"===process.platform}),Er=function(e,n,r){if(r||(r={}),n(e))throw e;if(r.nullOnErr)return null;var i=r.onErr;if(void 0!==i)return Ne(i);throw e},Sr=function(e,n,r){r||(r={}),r.dir&&(r.cwd=r.dir);var i=gr(r);if(null==i[0]){var u=r.allowInput,o=r.input;if(u&&o)throw Rn("allowInput (user) and input (programmatic) cannot be used simultaneously for synchronous child processes.");u&&(i[0]="inherit")}if(null==i[1]){var a=r.captureOutput??!1,s=r.showOutput;if(a&&s)throw Rn("captureOutput and showOutput cannot be used simultaneously for synchronous child processes.");a?i[1]="pipe":(null==s&&(s=!0),i[1]=s?"inherit":"ignore")}if(null==i[2]){var l=r.captureErr??!1,c=r.showErr;if(l&&c)throw Rn("captureErr and showErr cannot be used simultaneously for synchronous child processes.");l?i[2]="pipe":(null==c&&(c=!0),i[2]=c?"inherit":"ignore")}r.encoding||(r.encoding="utf8"),n&&xr(n);try{var f=Or().execFileSync(e,n,r);null!=f&&!1!==r.trim&&(f=f.trim());var p=r.map??r.mapFn;return p&&(f=p(f)),f}catch(e){if(Tr())return Er(e,e=>"ENOENT"===e.code,r);throw e}},Nr=function(e,n){return n||(n={}),null==n.captureOutput&&(n.captureOutput=!1),n.shell=!0,n.filterExtensions=!1,Sr("npm",e,n)},jr=function(e,n,r){return Nr(["install",e,n?"-g":null],r)},kr=function(e){return require(Ln(e))},Ar=class{constructor(){this.store={}}get(e,n){return g(this.store,e,n)}remove(e){return delete this.store[e]}delete(e){return this.remove(e)}},Fr=new Ar,Ir=function(e,n,r){if(de()){var i=O().join(e,n);return r?Cn(i):i}throw b()},Dr=function(e,n){return e.endsWith(n)?e:Ir(e,n)},_r=i("module"),Cr=function(e){return e=Dr(e,"node_modules"),_r().createRequire(e)},Pr=function(e,n){return Fr.get(e,()=>Cr(e))(n)},Lr=function(e,n,r){return Object.keys(n).forEach(i=>g(e,i,n[i],r)),e},Mr=function(e,n,r){return n?Lr(e,n,r):e},Rr=function(e,n){return e.endsWith(n)?e.substring(0,e.length-n.length):e},qr=function(e,n){var r=nn(n,e);return r?e.slice(0,r.index):e},Gr=function(e,n){if(D(n))return Rr(e,n);if(P(n))return qr(e,n);throw In(n,1)},Br=Gr,Wr=function(e,n){return[e.slice(0,n),e.slice(n)]},Kr=function(e){e=Br(e.trim(),";");var n=Math.max(e.lastIndexOf(";"),e.lastIndexOf("\n"));return Wr(e,n+1)},Jr=function(e,n){return e.startsWith(n)?e:n+e},Ur=function(e){var[n,r]=Kr(e);return n+Jr(r.trim(),"return ")},Yr=function(e){return Vt("node-repl-await").processTopLevelAwait(e)},zr=function(e){return Yr(e)??e},Vr=vn,Hr=function(e,n){return""===e?e:(null==n&&(n=!0),e=Vr(e,"\\","/"),n?Cn(e):e)},$r=function(e){return'require("'+Hr(Mn(),!1)+'");\n'+e},Qr=function(e,n){return vn(e,n,"")},Xr=function(e,n){return n.forEach(n=>e=Qr(e,n)),e},Zr=function(e){return Xr(e,["\r","\n"])},et=function(e){return Zr(Xt(e))},nt=function(e,n,r){return(n||r)&&(n||(n={}),r&&Mr(n,r),n.ensureReturn&&(e=Ur(e)),n.topLevelAwait&&(e=zr(e)),n.useTitan&&(e=$r(e)),n.keepAlive&&(e="\nsetInterval(()=>{}, 100000);\n"+e),(n.logErrors||n.keepAlive)&&(e="process.on('uncaughtException', console.error);\nprocess.on('unhandledRejection', console.error);\n"+e),n.inline&&(e=et(e))),e},rt=function(e){return D(e)?e:bn(e)},tt=function(e){var n=e.indexOf("{");return-1===n||e.slice(0,n).includes("=>")},it=function(e,n,r,i,u){return ln(e,n,r,i,(n,r)=>null===n?null:(n.input=e,void 0!==r&&(n.index+=r),n),u)},ut=function(e,n){return e.splice(e.length,0,...n),n},ot=function(e,n){return ut(e,n),e},at=ot,st=class extends Array{constructor(e,n,r,i,u){if(-1===n)throw Rn("RegexResult index cannot be -1. For empty result, use bare null.");if(null==e)throw Rn("RegexResult matchString cannot be null. For empty result, use bare null.");super(),this[0]=e,i&&at(this,i),this.index=n,this.input=r,u&&(this.groups=u)}fromParts(e){var n=e;return new st(n.match,n.index,n.input,n.captures,n.groups)}},lt=function(e,n,r,i,u){return new st(e,n,r,i,u)},ct=function(e,n,r,i,u){return-1===n||null==e?null:lt(e,n,r,i,u)},ft=Qr,pt=function(e,n){return W(e,ft(e.flags,n))},dt=function(e){return pt(e,"g")},ht=He(function(e){return e.global?dt(e):e},0),vt=function(e,n,r){return(e=null!=r?U(e,r,n):ht(e)).exec(n)},mt=function(e,n,r,i,u){return it(e,e=>{if(D(n)){var r=e.indexOf(n);return ct(n,r,e)}return vt(n,e)},r,i,u)},gt=function(e){return e.index+e[0].length},yt=function(e,n){var r=mt(e,n);return null===r[0]?null:e.slice(gt(r))},wt=function(e,n){return e.startsWith(n)?e.substring(n.length):e},bt=function(e,n){var r=vt(e,n);return r&&0===r.index?r:null},xt=function(e,n){var r=bt(n,e);return r?e.slice(r[0].length):e},Ot=function(e,n){if(D(n))return wt(e,n);if(P(n))return xt(e,n);throw In(n,1)},Tt=Ot,Et=function(e){var n=yt(e,"=>").trim();return Tt(Br(n,"}"),"{")},St=function(e){return yt(e,"{").slice(0,-1)},Nt=function(e){var n=rt(e);return tt(n)?Et(n):St(n)},jt=function(e){return null==e?"":D(e)?e:m(e)?Nt(e):String(e)},kt=function(e,n){var r=n?.basic?null:{topLevelAwait:!0,useTitan:!0},i=nt(jt(e),n,r);return Sr("node",[n?.mode??"-p",i],n)},At=function(e,n,r){if(null==e)throw Wn(e,n,r,{fromFn:At});return e},Ft=function(e,n){return process.kill(e,At(n,0,"signalName"))},It=function(e){return Ft(e,"SIGINT")},Dt=function(){return It(process.pid)},Ct=Dt,Pt=function(e){if("Y"===(e=e.toUpperCase()))return!0;if("N"===e)return!1;throw mr(e,0,"char")},Lt=function(e){null==e&&(e="Are you sure? [y/n]: "),process.stdout.write(e);var n=kt(function(){const e=process.stdin,n=process.stdout;e.setRawMode(!0),e.setEncoding("utf8"),e.on("data",e=>{var r=e.toUpperCase();"Y"===r||"N"===r?(n.write(e),process.exit(0)):""===e&&(n.write("^C"),process.exit(0))})},{mode:"-e",basic:!0,stdio:["inherit","pipe"]});if("^C"===n)throw process.stdout.write(n),Ct(),Rn("Prompt was cancelled via interrupt.");return console.log(n),Pt(n)},Mt=function(e){return Y(e)?e:D(e)?e.split("."):[e]},Rt=function(e,n,r,i,u,o){var a=r;return qe(e,n,i,u,o,(e,n,r)=>r(e,n,Ne(a)))},qt=function(e,n){var r=n,i=globalThis.config;i||(i=globalThis.config={});var u,o=Mt(e);return o.length>1?u=Rt(i,o,r):(u=Ne(r),i[o[0]]=u),u},Gt=function(e,n){return qt("node.require.customDirs",r=>(r||(r=[]),!1!==n&&(e=Dr(e,"node_modules")),r.includes(e)||r.push(e),r)),e},Bt=Gt,Wt=qe,Kt=function(e){var n=globalThis.config;if(n){var r=Mt(e);return r.length>1?Wt(n,r):n[r[0]]}},Jt=function(e,n,r){if(null!=e)return e;var i=Kt(n);return null!=i?i:r},Ut=function(e){var n=Pn(e,!1);return p(n)||(n!==e&&Ut(n),u().mkdirSync(n)),e},Yt=function(e){return Ut(e),u().mkdirSync(e),e},zt=function(e){return p(e)?e:Yt(e)},Vt=function(e,n){if(dr(e))return require(e);if(hr(e))return kr(e);try{return require(e)}catch(e){}var r=__dirname,i=process.mainModule?.path;if(i!==r)try{return Pr(i,e)}catch(e){}var u=process.cwd();if(u!==i&&u!==r)try{return Pr(u,e)}catch(e){}var o=Kt("node.require.customDirs");if(o)for(var a of o)try{return Pr(a,e)}catch(e){}var s=Jt(n?.autoInstall,"node.require.autoInstall"),l=Jt(n?.promptInstall,"node.require.promptInstall",!0);if(s||l){var c=s||l;!0===c&&(c="./node_modules"),c=Ln(c);var f=!1;if(s?(f=!0,console.log('Auto-installing "'+e+'" from npm to "'+c+'"...')):(f=Lt('Npm package "'+e+'" is required. Install now? (Y/N) '))&&console.log('Installing "'+e+'" from npm to "'+c+'"...'),f){c=zt(c),jr(e,!1,{cwd:c});try{return Bt(c),Pr(c,e)}catch(e){console.error("Failed to load from auto-install dir: ",c)}}}throw Rn('Module not found: "'+e+'"',{checked:{moduleDir:r,scriptDir:i,cwd:u}})},Ht=function(e,n){return Vt("astring").generate(e,n)},$t=function(e,n){return e.stack=n+"\n"+e.stack,e},Qt=function(e,n,r){r||(r={}),r.ecmaVersion||(r.ecmaVersion=2024),!1!==n&&(r.sourceType="module"),null==r.allowAwaitOutsideFunction&&(r.allowAwaitOutsideFunction=!0),null==r.allowReturnOutsideFunction&&(r.allowReturnOutsideFunction=!0);var i=Vt("acorn");try{return i.parse(e,r)}catch(n){throw $t(n,"Acorn parsing error: "+e)}},Xt=function(e,n,r){return Ht(Qt(e,n,r))},Zt=/(['"])(.*?)\1/,ei=Qe(Zt),ni=function(e){return e.replace(ei,"")},ri=ni,ti=function(e){return globalThis.structuredClone(e)},ii=ti,ui=He,oi=/\r?\n/,ai=function(e){return null==e||void 0!==e.length&&0===e.length},si=function(e,n){return br(e,ai)},li=function(e,n){return e.splice(n,1),e},ci=function(e,n,r,i){[r,i]=be(e,r,i);for(var u=r;u<i;u++){var o=n(e[u],u,e);void 0!==o&&(e[u]=o)}return e},fi=function(e,n,r){for(var i={},u=e.length,o=0;o<u;o++){var a=n(e[o],o,e);if(a){var[s,l]=a;r?(i[s]||(i[s]=[]),i[s].push(l)):i[s]=l}}return i},pi=function(e,n,r,i){return[n,r]=be(e,n,r,i),e.slice(n,r)},di=function(e,n){return Oe(n,e).join("")},hi=function(e){return e?e[0]:null},vi=function(e,n){var r=null==n?-1:n.index;if(-1===r)return[e];var i=Wr(e,r);return i[1]=i[1].slice(n[0].length),i},mi=function(e,n,r,i,u){return vi(e,mt(e,n,r,i,u))},gi=zn,yi=function(e){return gi(e)??e},wi=function(e,n){null==n&&(n="=");var r={};return e.forEach(function(e){var[i,u]=mi(e,n);null!=u&&(u=yi(u.trim())),r[i.trim()]=u}),r},bi=y,xi=class extends Array{constructor(e){var n,r=e;null!=r&&(Y(r)?n=r:D(r)&&(n=r.split(oi))),n?(super(n.length),Object.assign(this,n)):super(...arguments)}condense(e){return this.trim().removeEmpty(),e&&this.removeComments(e),this}trim(){return this.apply(e=>e.trim())}removeEmpty(){return si(this)}removeComments(e){for(var n=0;n<this.length;n++){var r=this[n],i=r.indexOf(e);-1!==i&&(""===(r=r.slice(0,i)).trim()?(li(this,n),n--):this[n]=r)}return this}removeFirst(){return this.shift(),this}removeLast(){return this.pop(),this}apply(e){return ci(this,e)}join(){return super.join("\n")}toObj(e){return wi(this,e)}mapToObj(e,n){return fi(this,e,n)}between(e,n,r){return r=bi(r,"inclusiveEnd",!0),pi(this,e,n,r)}normalize(){if(this.length>0&&(""===this[0].trim()&&this.shift(),this.length>0&&(""===L(this).trim()&&this.pop(),this.length>0))){var e=this.find(e=>""!==e.trim()),n=hi(vt(/^\s*/,e));if(n){var r=n.length;this.apply(e=>{if(e.startsWith(n))return e.slice(r)})}}return this}deindent(e,n,r){throw b()}indent(e,n){var r=di(n??"\t",e??1);return this.apply(e=>r+e)}static is(e){return _(e,this)}static fromChunks(e){return e.map(e=>Br(e,oi)).flatMap(e=>Ti(e,!1))}},Oi=function(e,n){var r=new xi(e);return n&&r.condense(),r},Ti=function(e,n,r){var i=e.split(oi);return n?Oi(i,r):i},Ei=function(e,n){return Ti(a(e),!0,n)},Si=function(e,n){return ht(e).test(n)},Ni=function(e,n){return P(n)?Si(n,e):e.includes(n)},ji=function(e,n,r,i){null==e&&(e=""),null==n&&(n="");var u={},o=(r,i)=>u[e+r+n]=i;return i&&Sn(i,o),r&&Sn(r,o),u},ki=function(e,n){return Sn(n,(n,r)=>e=vn(e,n,r)),e},Ai=function(e,n,r,i){var u,o,a=i?.paramIdentifier??"$";if(a)if(D(a)){if(!Ni(e,a))return e;u=a}else{if(!Y(a))throw In(a,1,"paramIdentifier");if([u,o]=a,!Ni(e,u)&&!Ni(e,o))return e}var s=ji(u,o,n,r);return ki(e,s)},Fi=function(e){return D(e)?e:String(e)},Ii=globalThis.process?.env.windir,Di=function(e){if(e)throw b();return x().homedir()},_i=function(e){return Di(e)+"Desktop/"},Ci={PROGRAMFILES:globalThis.process?.env.ProgramFiles,WINDIR:Ii,SYSTEM32:Ii&&Ii+"System32",TEMP:E(),DESKTOP:_i()},Pi=function(e,n){return Ai(Fi(e),n,Ci)},Li=function(){return qn()+"Source/SourceMap.txt"},Mi=function(e){return e?Pi(e,{TITAN:qn()}):Li()},Ri=function(e,n,r,i,u){return ln(e,n,r,i,(e,n)=>-1===e?-1:void 0===n?e:n+e,u)},qi=function(e,n){return Array.prototype.findIndex.call(e,n)},Gi=function(e,n,r,i,u){var o=D(n);return o&&null==i&&!u?e.indexOf(n,r):Ri(e,e=>o?e.indexOf(n):P(n)?e.search(n):qi(e,n),r,i,u)},Bi=function(e,n,r,i,u){var o=Gi(e,n,r,i,u);return-1===o?null:e.slice(r,o)},Wi=function(e){var n=e[0];return n===n.toUpperCase()},Ki=function(e,n){var r=[],i=[];return e.forEach((u,o)=>(n(u,o,e)?r:i).push(u)),[r,i]},Ji=ui(function(e){var n=Ei(Mi(e),!0),r={};return n.forEach(e=>{var n=Bi(e,"=").split(",").map(e=>e.trim()),[i,u]=Ki(n,e=>!Wi(e)),o=i[0];if(!o)throw Rn('No shortName in SourceMap line: "'+e+'"');u.forEach(e=>{r[e]=o})}),r},0),Ui=n(function(e){var n=Object.keys(e);return pn("\\b("+n.join("|")+")\\.(\\w+)","g")}),Yi=/\bt\.(\w+)\.(\w+)/g,zi=function(e,n){n||(n={});var r={},i=r.t={};if(n.enableGlobals){var u;u=n.additionalGlobals?ii(n.additionalGlobals):{},r.globals=u;var o=Ji(),a=Ui(o),s=Ze(a,e).filter(n=>{var r=n[1],i=n[2],u=e[n.index-1];if("."===u||"_"===u)return!1;var o=globalThis[r];return!o||void 0===o[i]});for(var[l,c,f]of s)u[c]||(u[c]={}),u[c][f]=!0;var p=s.map(([e,n,r])=>{var i=o[n];if(!i)throw Rn("No short name found for global: "+n);return"t."+i+"."+r+";"}).join(" ");e+="\n"+p}for(var[l,d,f]of s=e.matchAll(Yi))i[d]||(i[d]={}),i[d][f]=!0;return r},Vi=function(e,n){return e=Xt(e),e=ri(e),zi(e,n)},Hi=function(e,n){return zi(e,n)},$i=function(e,n,r){if(n){if("js"===(n=n.toLowerCase()))return Vi(e,r);if("html"===n)return Hi(e,r)}return zi(e,r)},Qi=function(e,n){return n in e},Xi=Qi,Zi=function(e,n){for(var r of(At(n,1),Object.keys(e))){if(!Xi(n,r))return!1;var i=e[r];if(i&&i.constructor===Object&&!Zi(i,n[r]))return!1}return!0},eu=function(e,n){if(!Zi(n.t,e))return!0;if(n.globals){var r=e._meta?.globals;if(!r)return!0;if(!Zi(n.globals,r))return!0}return!1},nu=function(e,n,r,i){var u,o,s,l;i||(i={}),e&&(e=Ln(e)),u=i.packagePath?Ln(i.packagePath):Mn(e,!1,!0,i);var c,f=p(u);f?(o=tr(u))?s="New compile":(null==n&&(n=a(e)),l=$i(n,"js",i),(c=eu(r,l))&&(s="New deps")):s="No package";var d={needsPack:!!s,scriptPath:e,packagePath:u};return s&&(d.reasonText=s),null!=f&&(d.exists=f),null!=o&&(d.newCompile=o),null!=c&&(d.newDeps=c),n&&(d.sourceText=n),l&&(d.shallowDeps=l),d},ru=function(e){return Dn(e,_n)},tu=function(e,n){var r=en(e,n);return r?r.index:-1},iu=function(e){var n=tu(_n,e);return-1===n?null:e.slice(0,n+1)},uu=function(e,n,r){if(ru(e))return r?[e,null]:e;var i,u,o=iu(e),a=n(A(e),o,e);return r?[i,u]=a:i=a,null!=i&&(e=o?o+i:i),r?[e,u]:e},ou=function(e,n,r,i,u){return it(e,e=>{if(P(n))return en(n,e);if(D(n)){var r=e.lastIndexOf(n);return-1!==r?new st(n,r):null}throw In(n,1)},r,i,u)},au=function(e,n,r,i,u){return vi(e,ou(e,n,r,i,u))},su=function(e){return uu(e,e=>au(e,"."),!0)},lu=function(e,n){var r=su(e)[1];return r?!1!==n?r.toLowerCase():r:null},cu={},fu=ui(function(e){e=Mi(e);var n=Pn(e)+"../Compiled/",r=Ei(e,"//"),i=cu;for(var u of r){var o=u.indexOf("="),a=u.slice(0,o).trim();a=a.split(",").map(e=>e.trim()).filter(e=>!Wi(e));var s=u.slice(o+1).trim(),l=Ir(n,s).replaceAll("\\","/");for(var c of a)i[c]=l}return i},0),pu=function(e,n){var r=n?.fileType;if(r){if("js"===(r=r.toLowerCase()))return Vi(e,n);if("html"===r)return Hi(e,n)}return zi(e,n)},du=function*(e,n){var r=0;for(var i of e)n(i,r++,e)&&(yield i)},hu=function(e){return e.slice()},vu=function(e,n,r){for(var i=e.length-1;i>=n;i--)e[i+1]=e[i];return e[n]=r,e.length++,e},mu=function(e,n){return vu(e,e.length,n)},gu=mu,yu=function(e,n){return e.call(this,...n,function n(){return L(arguments)!==n&&gu(arguments,n),e.apply(this,arguments)})},wu=function(e){e||(e={});var n=e.getKeys;n||(n=function(e){return Object.keys(e)});var r=e.recurseIf;if(!r){var i=this.constructor;r=e=>_(e,i)||wn(e)||Y(e)}var u=e.leavesOnly??e.leafsOnly??!1,o=this;return yu(function*(e,i,a,s){var l=n(e,i,a);if(l)for(var c=l.length,f=0;f<c;f++){var p=l[f],d=e[p],h=hu(i);h.push(p);var v=null,m={value:d,key:p,object:e,path:h,level:a,isLeaf:v,root:o},g=r(d,m);m.isLeaf=v=!g,u&&!v||(yield m),g&&(yield*s(d,h,a+1,s))}},[this,[],0])},bu=function(e,n){return wu.call(e,n)},xu=function(e,n){1===arguments.length&&(n=!0);var r={};for(var i of e)r[i]=n;return r},Ou=function(e,n,r,i){var u=Qt(e,n,i);Vt("acorn-walk").full(u,r)},Tu=function(e,n,r,i){var u;if(D(r))u=e=>e.type===r;else if(Y(r)){var o=xu(r);u=e=>o[e.type]}else u=r;var a=[];return Ou(e,n,function(e){u.apply(this,arguments)&&a.push(e)},i),a},Eu=Ht,Su=function(e){var n,r,i,u=e,o=D(u)?Qt(u).body[0]:u,a=o.type;if("VariableDeclaration"===a){n="variable";var s=o.declarations[0];r=s.id.name,i=s.init?s.init.raw??Ht(s.init):"undefined"}else"FunctionDeclaration"===a?n="function":"ClassDeclaration"===a&&(n="class"),r=o.id.name;var l={type:n,name:r};return i&&(l.value=i),l.text=Eu(o),l.node=o,l},Nu=function(e){return Tu(e,!0,["ExportNamedDeclaration","ExportDefaultDeclaration"]).map(function(e){var n=e.declaration;if(n){var r=Su(n);return r.node=e,r}return{node:e}})},ju=function(e,n){n||(n={});var r=n.enableGlobals,i=fu(n.sourceMap),u={},a=[];return function e(n,s){var l=du(bu(n),e=>e.isLeaf);for(var c of l){var[f,d]=c.path,h=u[f];if(h||(h=u[f]={}),null==h[d]){var v=i[f];if(v){var m=Hr(v)+d+".js";if(!p(m)){var g='Titan compiled value "t.'+f+"."+d+'" does not exist';throw s&&(g+=' (called by "'+s+'")'),Rn(g+=".")}var y=o(m),w=Nu(y)[0];h[d]=w;var b="t."+f+"."+d;e(pu(y,{fileType:"js",enableGlobals:r}).t,b),a.push([f,d])}else console.log('Skipping unmapped module "'+f+'"'),h[d]=!1}}}(e.t),{t:u,globals:e.globals,order:a}},ku=function(e,n){n||(n={});var r=n.deps??$i(e,n.fileType,n),{t:i,globals:u,order:o}=ju(r,n),a={};if(a.t=r.t,u&&n.enableGlobals){a.globals=u;var s=Ji(),l=Object.keys(u),c=fi(l,e=>[s[e],e],!0);a.shortNamesToGlobals=c}return a.itemsInOrder=o.map(([e,n])=>{var r=i[e][n];return[e,n,"variable"===r.type?r.value:"("+r.text+")"]}),a},Au=function(e,n,r){return null==r&&(r=!0),yu(function(e,n,i){Sn(e,function(e,u){if(Xi(n,e)){var o=n[e];r?M(o)&&M(u)?i(u,o):n[e]=u:M(o)&&i(u,o)}else n[e]=u})},[e,n]),n},Fu=Au,Iu=function(e){return Object.assign({},e)},Du=function(e,n){if(n){var r={};return e.forEach((e,i,u)=>r[n(e,i,u)]=!0),r}return Iu(e)},_u=function(e,n){Fu(n.t,e.t,!1);var r=n.globals;if(r){var i=e.globals;i?Fu(r,i,!1):e.globals=r,e.shortNamesToGlobals=n.shortNamesToGlobals}var u=Du(e.itemsInOrder,e=>e[0]+"."+e[1]);return n.itemsInOrder.forEach(n=>{u[n[0]+"."+n[1]]||e.itemsInOrder.push(n)}),e},Cu=function(e){return e instanceof Buffer},Pu=function(e){return ArrayBuffer.isView(e)},Lu=Pu,Mu=function(e){return Cu(e)||Lu(e)||D(e)},Ru=function(e){return e.constructor===ArrayBuffer},qu=function(e){return Mu(e)?e:Ru(e)?Buffer.from(e):bn(e)},Gu=function(e){return Hn(e)?String(e):qu(e)},Bu=function(e,n){return Ut(e),u().writeFileSync(e,Gu(n)),e},Wu=function(e,n){var r;return n||(n={}),r=n.condensed?0:null!=n.whitespace?n.whitespace:"\t",JSON.stringify(e,n.replacer,r)},Ku=function(e,n,r){return Bu(e,Wu(n,r))},Ju=function(e,n,r){r||(r={}),r.deps||r.fileType||!n||(r.fileType=lu(n));var i=ku(e,r),u=r.packagePath||Mn(n,r.repl,!0,r);if(r.dynamic&&(r.packageExists??p(u))&&!(r.newCompile??tr(u))){var o=ur(u);i=_u(o,i)}return Ku(u,i),u},Uu=function(e,n,r,i){var u=nu(e,n,r,i);return u.needsPack&&(i.onPack&&i.onPack(u.reasonText),n=u.sourceText??a(e),i.packagePath=u.packagePath,i.packageExists=u.exists,i.newCompile=u.newCompile,i.deps=u.shallowDeps,Ju(n,e,i),fr(u.packagePath,r,i)),r},Yu={node:{getScriptPath:e,fs:u,_builtInModule:i,requireBuiltIn:r,os:x,path:O,is:de,display:on,util:un,getScriptDir:ir,require:Vt,_basicRequire:pr,child_process:Or,requireLocal:kr,_requireFromDir:Pr,_requireDirCache:Fr,_createRequire:Cr,module:_r,promptYNSync:Lt,run:kt,sigint:Ct,interrupt:Dt,ensureRequireDir:Bt,addRequireDir:Gt},fs:{loadText:a,load:o,getID:f,stat:c,deepStat:s,shallowStat:l,exists:p,getModifiedDate:nr,loadJSON:ur,ensureDir:zt,mkdir:Yt,ensureParent:Ut,loadLines:Ei,writeJSON:Ku,write:Bu,formatRaw:Gu},f:{one:n,is:m,memoize:He,MemoizedFunction:Ve,createClass:we,ensureConstructor:ee,createConstructor:Z,isArrowFn:Q,isArrow:$,wrap:X,retThis:ne,setName:le,not:wr,body:Nt,isArrowString:tt,_getArrowFnBody:Et,_getNormalFnBody:St,cache:ui,recurse:yu},titan:{getTempDir:N,getPackagePath:Mn,getPackageName:I,hasNewCompile:tr,getLastCompileTime:er,getCompiledDir:Gn,locate:qn,_loadDynamicDeps:fr,_trackGlobals:cr,autoPackAndLoadJSON:Uu,needsToPack:nu,getShallowDeps:$i,getDepsFromJS:Vi,_getDepsBasic:zi,loadGlobalsMap:Ji,_resolveSourceMapPath:Mi,locateSourceMap:Li,_getGlobalsRegex:Ui,depsRegex:Yi,getDepsFromHTML:Hi,jsonHasNewDeps:eu,packTextToJSONFile:Ju,packTextToJSON:ku,_getAllDeps:ju,loadSourceMap:fu,sourceMap:cu,getDeps:pu,addNewItemsToJSON:_u},path:{getTempDir:S,_getDefaultTempDir:E,sep:T,baseName:F,_removeExtsFromFile:k,file:A,dir:Pn,ensureTrailingSlash:Cn,abs:Ln,ensureEndsWith:Dr,join:Ir,fws:Hr,resolveVars:Pi,string:Fi,_defaultParams:Ci,windir:Ii,getDesktop:_i,getUserDir:Di,ext:lu,splitExt:su,ignoreDir:uu,isDir:ru,dirPart:iu},err:{nyi:b,NYIError:v,Error:h,Enhanced:d,defaultFromFn:w,type:In,TypeError:rn,create:Rn,req:Wn,value:mr,ValueError:vr,prepend:$t},o:{safeEnsure:y,ensure:g,constructorMatches:C,is:M,isAny:te,setHidden:se,addNonEnumerable:ae,defineProperty:oe,weakAssign:ue,merge:ie,hideKey:ye,makeNonEnumerable:ge,ensureCustom:je,get:Ee,set:Se,createEmpty:Le,remove:Ke,display:kn,toLiteral:jn,isPure:wn,reduce:Nn,each:Sn,keys:En,allKeys:Tn,setLazy:lr,setGetterAndSetter:ar,addGetterAndSetter:or,replaceGetterAndSetter:sr,Cache:Ar,setDefaults:Mr,ensureMulti:Lr,resolveKeys:Mt,diveGet:Wt,deepCopy:ii,fromLines:wi,safeDefault:bi,hasKey:Xi,has:Qi,fromKeys:xu,fromArray:Iu},s:{decapitalize:j,endsWith:Dn,is:D,chars:R,resolveIndex:J,toLiteral:yn,quote:gn,escape:mn,replaceAll:vn,apply:cn,withIndices:ln,from:bn,removeTrailing:Br,removeFromEnd:Gr,_removeStringFromEnd:Rr,_removeRegexFromEnd:qr,splitAtIndex:Wr,ensureStartsWith:Jr,replace:Vr,removeLineBreaks:Zr,removeMulti:Xr,removeAll:Qr,resolve:jt,ensure:rt,after:yt,match:mt,_matchWithIndices:it,remove:ft,removeLeading:Tt,removeFromStart:Ot,_removeStringFromStart:wt,_removeRegexFromStart:xt,removeQuotes:ni,splitLines:Ti,lines:Oi,LinesArray:xi,repeat:di,splitFirst:mi,_splitByMatch:vi,replaceParams:Ai,contains:Ni,_createParamsObj:ji,_replaceByObj:ki,before:Bi,index:Gi,_indexWithIndices:Ri,indexOfFn:qi,isCapitalized:Wi,splitLast:au,matchLast:ou},re:{is:P,matchEnd:nn,matchLast:en,matchAll:Ze,setStartIndex:U,copy:W,updateFlagString:B,parseFlagString:q,createFlagString:G,ensureGlobal:Xe,global:Qe,addFlag:$e,createEscaped:hn,create:pn,resolveFlags:fn,escape:dn,slash:_n,safeCreateResult:ct,createResult:lt,RegexResult:st,match:vt,ensureLocal:ht,local:dt,removeFlag:pt,resultEndIndex:gt,matchStart:bt,quotes:ei,quote:Zt,newline:oi,text:hi,test:Si,lastIndex:tu},v:{constructorMatches:_,isPrimitive:re,resolve:Ne,type:tn,display:Fn,toLiteral:On,nullIfNaN:Yn,req:At,isEmpty:ai},a:{last:L,resolveIndex:K,is:Y,ensure:z,pick:Te,create:Oe,fill:xe,resolveIndices:be,push:_e,add:De,splitLast:Re,splitTail:Me,wrapIndices:sn,wrapIndex:an,toLiteral:xn,display:An,removeNullish:xr,removeByFilter:br,replaceContents:yr,pushMulti:at,addMulti:ot,pushThroughMulti:ut,removeEmpty:si,removeIndex:li,apply:ci,mapToObj:fi,slice:pi,filterSplit:Ki,copy:hu,toObj:Du},class:{create:me,setName:ce,addStatics:fe,setDisplay:ve},p:{asyncJoint:H,is:V},sym:{display:he,value:Pe},macro:{config:pe},map:{Cache:Ie,ensure:Fe,get:ke,set:Ae,MultiCache:ze,diveEnsure:We,createEmpty:Be,diveDelete:Ye,remove:Ue},args:{ensureArray:Ce,push:gu,append:mu,insert:vu},tree:{ensure:Ge,dive:qe,remove:Je,setCustom:Rt,copy:ti,isSubsetOf:Zi,iterate:bu,iterator:wu,merge:Fu,join:Au},d:{from:Zn,create:Xn,resolve:Qn,now:Bn,ensure:$n,copy:Kn,fromYear:Jn,_resolveNative:Un,isBefore:rr},n:{fromString:Vn,ensure:zn,is:Hn,tryCoerce:yi,tryParse:gi},js:{removeComments:Xt,fromAST:Ht,enhance:nt,ensureReturn:Ur,splitLastExpression:Kr,enableAwait:zr,_nodeEnableAwait:Yr,useTitan:$r,inline:et,parse:Qt,removeQuotes:ri,getExports:Nu,getNodes:Tu,eachNode:Ou,parseDeclaration:Su,fromASTNode:Eu},npm:{isBuiltIn:dr,isFile:hr,install:jr,_runCommand:Nr},os:{run:Sr,_resolveStdio:gr},win:{is:Tr},shell:{_handleError:Er},proc:{interrupt:It,signal:Ft},bool:{fromYN:Pt},env:{setConfig:qt,getConfig:Kt,resolveConfig:Jt},gen:{filter:du},bin:{ensureByteSafe:qu,isByteSafe:Mu,isNodeBuffer:Cu,isTA:Lu},ab:{isTA:Pu,is:Ru},json:{stringify:Wu}};globalThis.t?Object.keys(Yu).forEach(function(e){if(t[e]){var n=Yu[e];Object.keys(n).forEach(function(r){t[e][r]=n[r]})}else t[e]=Yu[e]}):globalThis.t=Object.assign({},Yu),globalThis.exports&&(exports.default=globalThis.t);