UNPKG

@ministryofjustice/hmpps-digital-prison-reporting-frontend

Version:

The Digital Prison Reporting Frontend contains templates and code to help display data effectively in UI applications.

8 lines (7 loc) 416 kB
var qh=Object.create;var en=Object.defineProperty;var Lh=Object.getOwnPropertyDescriptor;var Fh=Object.getOwnPropertyNames;var Dh=Object.getPrototypeOf,zh=Object.prototype.hasOwnProperty;var f=(t,e)=>()=>(e||t((e={exports:{}}).exports,e),e.exports),Nh=(t,e)=>{for(var i in e)en(t,i,{get:e[i],enumerable:!0})},Vo=(t,e,i,n)=>{if(e&&typeof e=="object"||typeof e=="function")for(let a of Fh(e))!zh.call(t,a)&&a!==i&&en(t,a,{get:()=>e[a],enumerable:!(n=Lh(e,a))||n.enumerable});return t};var tn=(t,e,i)=>(i=t!=null?qh(Dh(t)):{},Vo(e||!t||!t.__esModule?en(i,"default",{value:t,enumerable:!0}):i,t)),Ph=t=>Vo(en({},"__esModule",{value:!0}),t);var Qo=f((aS,xa)=>{var Ih=Object.prototype.hasOwnProperty;function Jo(t){return"[Throws: "+(t?t.message:"?")+"]"}function Mh(t,e){if(Ih.call(t,e))try{return t[e]}catch(i){return Jo(i)}return t[e]}function Ko(t){var e=[];function i(n){if(n===null||typeof n!="object")return n;if(e.indexOf(n)!==-1)return"[Circular]";if(e.push(n),typeof n.toJSON=="function")try{var a=i(n.toJSON());return e.pop(),a}catch(s){return Jo(s)}if(Array.isArray(n)){var r=n.map(i);return e.pop(),r}var o=Object.keys(n).reduce(function(s,c){return s[c]=i(Mh(n,c)),s},{});return e.pop(),o}return i(t)}xa.exports=function(t,e,i){return JSON.stringify(Ko(t),e,i)};xa.exports.ensureProperties=Ko});var Xo=f((rS,Yo)=>{var he=require("fs"),ti=require("path");Yo.exports=nn;nn.ncp=nn;function nn(t,e,i,n){var a=n;n||(a=i,i={});var r=process.cwd(),o=ti.resolve(r,t),s=ti.resolve(r,e),c=i.filter,p=i.rename,l=i.transform,m=i.clobber!==!1,u=i.modified,d=i.dereference,h=null,v=0,b=0,x=0,g=i.limit||nn.limit||16;g=g<1?1:g>512?512:g,y(o);function y(S){if(v++,c){if(c instanceof RegExp){if(!c.test(S))return ie(!0)}else if(typeof c=="function"&&!c(S))return ie(!0)}return w(S)}function w(S){var T=d?he.stat:he.lstat;if(x>=g)return setImmediate(function(){w(S)});x++,T(S,function(j,P){var xe={};if(j)return V(j);if(xe.name=S,xe.mode=P.mode,xe.mtime=P.mtime,xe.atime=P.atime,P.isDirectory())return W(xe);if(P.isFile())return C(xe);if(P.isSymbolicLink())return E(S)})}function C(S){var T=S.name.replace(o,s);p&&(T=p(T)),Y(T,function(j){if(j)return Q(S,T);if(m&&G(T,function(){Q(S,T)}),u){var P=d?he.stat:he.lstat;P(T,function(xe,ei){if(S.mtime.getTime()>ei.mtime.getTime())Q(S,T);else return ie()})}else return ie()})}function Q(S,T){var j=he.createReadStream(S.name),P=he.createWriteStream(T,{mode:S.mode});j.on("error",V),P.on("error",V),l?l(j,P,S):P.on("open",function(){j.pipe(P)}),P.once("finish",function(){u&&he.utimesSync(T,S.atime,S.mtime),ie()})}function G(S,T){he.unlink(S,function(j){return j?V(j):T()})}function W(S){var T=S.name.replace(o,s);Y(T,function(j){if(j)return L(S,T);ee(S.name)})}function L(S,T){he.mkdir(T,S.mode,function(j){if(j)return V(j);ee(S.name)})}function ee(S){he.readdir(S,function(T,j){return T?V(T):(j.forEach(function(P){y(ti.join(S,P))}),ie())})}function E(S){var T=S.replace(o,s);he.readlink(S,function(j,P){if(j)return V(j);te(P,T)})}function te(S,T){d&&(S=ti.resolve(r,S)),Y(T,function(j){if(j)return $(S,T);he.readlink(T,function(P,xe){return P?V(P):(d&&(xe=ti.resolve(r,xe)),xe===S?ie():G(T,function(){$(S,T)}))})})}function $(S,T){he.symlink(S,T,function(j){return j?V(j):ie()})}function Y(S,T){he.lstat(S,function(j){return j&&j.code==="ENOENT"?T(!0):T(!1)})}function V(S){return i.stopOnError?a(S):(!h&&i.errs?h=he.createWriteStream(i.errs):h||(h=[]),typeof h.write>"u"?h.push(S):h.write(S.stack+` `),ie())}function ie(S){if(S||x--,b++,v===b&&x===0&&a!==void 0)return a(h||null)}}});var es=f((oS,Zo)=>{Zo.exports=function(t,e){for(var i=[],n=0;n<t.length;n++){var a=e(t[n],n);Bh(a)?i.push.apply(i,a):i.push(a)}return i};var Bh=Array.isArray||function(t){return Object.prototype.toString.call(t)==="[object Array]"}});var rs=f((sS,as)=>{"use strict";as.exports=is;function is(t,e,i){t instanceof RegExp&&(t=ts(t,i)),e instanceof RegExp&&(e=ts(e,i));var n=ns(t,e,i);return n&&{start:n[0],end:n[1],pre:i.slice(0,n[0]),body:i.slice(n[0]+t.length,n[1]),post:i.slice(n[1]+e.length)}}function ts(t,e){var i=e.match(t);return i?i[0]:null}is.range=ns;function ns(t,e,i){var n,a,r,o,s,c=i.indexOf(t),p=i.indexOf(e,c+1),l=c;if(c>=0&&p>0){if(t===e)return[c,p];for(n=[],r=i.length;l>=0&&!s;)l==c?(n.push(l),c=i.indexOf(t,l+1)):n.length==1?s=[n.pop(),p]:(a=n.pop(),a<r&&(r=a,o=p),p=i.indexOf(e,l+1)),l=c<p&&c>=0?c:p;n.length&&(s=[r,o])}return s}});var ms=f((cS,ds)=>{var Uh=es(),os=rs();ds.exports=Gh;var ss="\0SLASH"+Math.random()+"\0",cs="\0OPEN"+Math.random()+"\0",ya="\0CLOSE"+Math.random()+"\0",ps="\0COMMA"+Math.random()+"\0",ls="\0PERIOD"+Math.random()+"\0";function ga(t){return parseInt(t,10)==t?parseInt(t,10):t.charCodeAt(0)}function $h(t){return t.split("\\\\").join(ss).split("\\{").join(cs).split("\\}").join(ya).split("\\,").join(ps).split("\\.").join(ls)}function Hh(t){return t.split(ss).join("\\").split(cs).join("{").split(ya).join("}").split(ps).join(",").split(ls).join(".")}function us(t){if(!t)return[""];var e=[],i=os("{","}",t);if(!i)return t.split(",");var n=i.pre,a=i.body,r=i.post,o=n.split(",");o[o.length-1]+="{"+a+"}";var s=us(r);return r.length&&(o[o.length-1]+=s.shift(),o.push.apply(o,s)),e.push.apply(e,o),e}function Gh(t){return t?(t.substr(0,2)==="{}"&&(t="\\{\\}"+t.substr(2)),St($h(t),!0).map(Hh)):[]}function Wh(t){return"{"+t+"}"}function Vh(t){return/^-?0\d/.test(t)}function Jh(t,e){return t<=e}function Kh(t,e){return t>=e}function St(t,e){var i=[],n=os("{","}",t);if(!n||/\$$/.test(n.pre))return[t];var a=/^-?\d+\.\.-?\d+(?:\.\.-?\d+)?$/.test(n.body),r=/^[a-zA-Z]\.\.[a-zA-Z](?:\.\.-?\d+)?$/.test(n.body),o=a||r,s=n.body.indexOf(",")>=0;if(!o&&!s)return n.post.match(/,.*\}/)?(t=n.pre+"{"+n.body+ya+n.post,St(t)):[t];var c;if(o)c=n.body.split(/\.\./);else if(c=us(n.body),c.length===1&&(c=St(c[0],!1).map(Wh),c.length===1)){var l=n.post.length?St(n.post,!1):[""];return l.map(function(E){return n.pre+c[0]+E})}var p=n.pre,l=n.post.length?St(n.post,!1):[""],m;if(o){var u=ga(c[0]),d=ga(c[1]),h=Math.max(c[0].length,c[1].length),v=c.length==3?Math.abs(ga(c[2])):1,b=Jh,x=d<u;x&&(v*=-1,b=Kh);var g=c.some(Vh);m=[];for(var y=u;b(y,d);y+=v){var w;if(r)w=String.fromCharCode(y),w==="\\"&&(w="");else if(w=String(y),g){var C=h-w.length;if(C>0){var Q=new Array(C+1).join("0");y<0?w="-"+Q+w.slice(1):w=Q+w}}m.push(w)}}else m=Uh(c,function(ee){return St(ee,!1)});for(var G=0;G<m.length;G++)for(var W=0;W<l.length;W++){var L=p+m[G]+l[W];(!e||o||L)&&i.push(L)}return i}});var on=f((pS,gs)=>{gs.exports=we;we.Minimatch=pe;var ii=function(){try{return require("path")}catch{}}()||{sep:"/"};we.sep=ii.sep;var _a=we.GLOBSTAR=pe.GLOBSTAR={},Qh=ms(),fs={"!":{open:"(?:(?!(?:",close:"))[^/]*?)"},"?":{open:"(?:",close:")?"},"+":{open:"(?:",close:")+"},"*":{open:"(?:",close:")*"},"@":{open:"(?:",close:")"}},ba="[^/]",wa=ba+"*?",Yh="(?:(?!(?:\\/|^)(?:\\.{1,2})($|\\/)).)*?",Xh="(?:(?!(?:\\/|^)\\.).)*?",hs=Zh("().*{}+?[]^$\\!");function Zh(t){return t.split("").reduce(function(e,i){return e[i]=!0,e},{})}var vs=/\/+/;we.filter=ev;function ev(t,e){return e=e||{},function(i,n,a){return we(i,t,e)}}function Ke(t,e){e=e||{};var i={};return Object.keys(t).forEach(function(n){i[n]=t[n]}),Object.keys(e).forEach(function(n){i[n]=e[n]}),i}we.defaults=function(t){if(!t||typeof t!="object"||!Object.keys(t).length)return we;var e=we,i=function(a,r,o){return e(a,r,Ke(t,o))};return i.Minimatch=function(a,r){return new e.Minimatch(a,Ke(t,r))},i.Minimatch.defaults=function(a){return e.defaults(Ke(t,a)).Minimatch},i.filter=function(a,r){return e.filter(a,Ke(t,r))},i.defaults=function(a){return e.defaults(Ke(t,a))},i.makeRe=function(a,r){return e.makeRe(a,Ke(t,r))},i.braceExpand=function(a,r){return e.braceExpand(a,Ke(t,r))},i.match=function(n,a,r){return e.match(n,a,Ke(t,r))},i};pe.defaults=function(t){return we.defaults(t).Minimatch};function we(t,e,i){return rn(e),i||(i={}),!i.nocomment&&e.charAt(0)==="#"?!1:new pe(e,i).match(t)}function pe(t,e){if(!(this instanceof pe))return new pe(t,e);rn(t),e||(e={}),t=t.trim(),!e.allowWindowsEscape&&ii.sep!=="/"&&(t=t.split(ii.sep).join("/")),this.options=e,this.set=[],this.pattern=t,this.regexp=null,this.negate=!1,this.comment=!1,this.empty=!1,this.partial=!!e.partial,this.make()}pe.prototype.debug=function(){};pe.prototype.make=tv;function tv(){var t=this.pattern,e=this.options;if(!e.nocomment&&t.charAt(0)==="#"){this.comment=!0;return}if(!t){this.empty=!0;return}this.parseNegate();var i=this.globSet=this.braceExpand();e.debug&&(this.debug=function(){console.error.apply(console,arguments)}),this.debug(this.pattern,i),i=this.globParts=i.map(function(n){return n.split(vs)}),this.debug(this.pattern,i),i=i.map(function(n,a,r){return n.map(this.parse,this)},this),this.debug(this.pattern,i),i=i.filter(function(n){return n.indexOf(!1)===-1}),this.debug(this.pattern,i),this.set=i}pe.prototype.parseNegate=iv;function iv(){var t=this.pattern,e=!1,i=this.options,n=0;if(!i.nonegate){for(var a=0,r=t.length;a<r&&t.charAt(a)==="!";a++)e=!e,n++;n&&(this.pattern=t.substr(n)),this.negate=e}}we.braceExpand=function(t,e){return xs(t,e)};pe.prototype.braceExpand=xs;function xs(t,e){return e||(this instanceof pe?e=this.options:e={}),t=typeof t>"u"?this.pattern:t,rn(t),e.nobrace||!/\{(?:(?!\{).)*\}/.test(t)?[t]:Qh(t)}var nv=1024*64,rn=function(t){if(typeof t!="string")throw new TypeError("invalid pattern");if(t.length>nv)throw new TypeError("pattern is too long")};pe.prototype.parse=av;var an={};function av(t,e){rn(t);var i=this.options;if(t==="**")if(i.noglobstar)t="*";else return _a;if(t==="")return"";var n="",a=!!i.nocase,r=!1,o=[],s=[],c,p=!1,l=-1,m=-1,u=t.charAt(0)==="."?"":i.dot?"(?!(?:^|\\/)\\.{1,2}(?:$|\\/))":"(?!\\.)",d=this;function h(){if(c){switch(c){case"*":n+=wa,a=!0;break;case"?":n+=ba,a=!0;break;default:n+="\\"+c;break}d.debug("clearStateChar %j %j",c,n),c=!1}}for(var v=0,b=t.length,x;v<b&&(x=t.charAt(v));v++){if(this.debug("%s %s %s %j",t,v,n,x),r&&hs[x]){n+="\\"+x,r=!1;continue}switch(x){case"/":return!1;case"\\":h(),r=!0;continue;case"?":case"*":case"+":case"@":case"!":if(this.debug("%s %s %s %j <-- stateChar",t,v,n,x),p){this.debug(" in class"),x==="!"&&v===m+1&&(x="^"),n+=x;continue}d.debug("call clearStateChar %j",c),h(),c=x,i.noext&&h();continue;case"(":if(p){n+="(";continue}if(!c){n+="\\(";continue}o.push({type:c,start:v-1,reStart:n.length,open:fs[c].open,close:fs[c].close}),n+=c==="!"?"(?:(?!(?:":"(?:",this.debug("plType %j %j",c,n),c=!1;continue;case")":if(p||!o.length){n+="\\)";continue}h(),a=!0;var g=o.pop();n+=g.close,g.type==="!"&&s.push(g),g.reEnd=n.length;continue;case"|":if(p||!o.length||r){n+="\\|",r=!1;continue}h(),n+="|";continue;case"[":if(h(),p){n+="\\"+x;continue}p=!0,m=v,l=n.length,n+=x;continue;case"]":if(v===m+1||!p){n+="\\"+x,r=!1;continue}var y=t.substring(m+1,v);try{RegExp("["+y+"]")}catch{var w=this.parse(y,an);n=n.substr(0,l)+"\\["+w[0]+"\\]",a=a||w[1],p=!1;continue}a=!0,p=!1,n+=x;continue;default:h(),r?r=!1:hs[x]&&!(x==="^"&&p)&&(n+="\\"),n+=x}}for(p&&(y=t.substr(m+1),w=this.parse(y,an),n=n.substr(0,l)+"\\["+w[0],a=a||w[1]),g=o.pop();g;g=o.pop()){var C=n.slice(g.reStart+g.open.length);this.debug("setting tail",n,g),C=C.replace(/((?:\\{2}){0,64})(\\?)\|/g,function(P,xe,ei){return ei||(ei="\\"),xe+xe+ei+"|"}),this.debug(`tail=%j %s`,C,C,g,n);var Q=g.type==="*"?wa:g.type==="?"?ba:"\\"+g.type;a=!0,n=n.slice(0,g.reStart)+Q+"\\("+C}h(),r&&(n+="\\\\");var G=!1;switch(n.charAt(0)){case"[":case".":case"(":G=!0}for(var W=s.length-1;W>-1;W--){var L=s[W],ee=n.slice(0,L.reStart),E=n.slice(L.reStart,L.reEnd-8),te=n.slice(L.reEnd-8,L.reEnd),$=n.slice(L.reEnd);te+=$;var Y=ee.split("(").length-1,V=$;for(v=0;v<Y;v++)V=V.replace(/\)[+*?]?/,"");$=V;var ie="";$===""&&e!==an&&(ie="$");var S=ee+E+$+ie+te;n=S}if(n!==""&&a&&(n="(?=.)"+n),G&&(n=u+n),e===an)return[n,a];if(!a)return ov(t);var T=i.nocase?"i":"";try{var j=new RegExp("^"+n+"$",T)}catch{return new RegExp("$.")}return j._glob=t,j._src=n,j}we.makeRe=function(t,e){return new pe(t,e||{}).makeRe()};pe.prototype.makeRe=rv;function rv(){if(this.regexp||this.regexp===!1)return this.regexp;var t=this.set;if(!t.length)return this.regexp=!1,this.regexp;var e=this.options,i=e.noglobstar?wa:e.dot?Yh:Xh,n=e.nocase?"i":"",a=t.map(function(r){return r.map(function(o){return o===_a?i:typeof o=="string"?sv(o):o._src}).join("\\/")}).join("|");a="^(?:"+a+")$",this.negate&&(a="^(?!"+a+").*$");try{this.regexp=new RegExp(a,n)}catch{this.regexp=!1}return this.regexp}we.match=function(t,e,i){i=i||{};var n=new pe(e,i);return t=t.filter(function(a){return n.match(a)}),n.options.nonull&&!t.length&&t.push(e),t};pe.prototype.match=function(e,i){if(typeof i>"u"&&(i=this.partial),this.debug("match",e,this.pattern),this.comment)return!1;if(this.empty)return e==="";if(e==="/"&&i)return!0;var n=this.options;ii.sep!=="/"&&(e=e.split(ii.sep).join("/")),e=e.split(vs),this.debug(this.pattern,"split",e);var a=this.set;this.debug(this.pattern,"set",a);var r,o;for(o=e.length-1;o>=0&&(r=e[o],!r);o--);for(o=0;o<a.length;o++){var s=a[o],c=e;n.matchBase&&s.length===1&&(c=[r]);var p=this.matchOne(c,s,i);if(p)return n.flipNegate?!0:!this.negate}return n.flipNegate?!1:this.negate};pe.prototype.matchOne=function(t,e,i){var n=this.options;this.debug("matchOne",{this:this,file:t,pattern:e}),this.debug("matchOne",t.length,e.length);for(var a=0,r=0,o=t.length,s=e.length;a<o&&r<s;a++,r++){this.debug("matchOne loop");var c=e[r],p=t[a];if(this.debug(e,c,p),c===!1)return!1;if(c===_a){this.debug("GLOBSTAR",[e,c,p]);var l=a,m=r+1;if(m===s){for(this.debug("** at the end");a<o;a++)if(t[a]==="."||t[a]===".."||!n.dot&&t[a].charAt(0)===".")return!1;return!0}for(;l<o;){var u=t[l];if(this.debug(` globstar while`,t,l,e,m,u),this.matchOne(t.slice(l),e.slice(m),i))return this.debug("globstar found match!",l,o,u),!0;if(u==="."||u===".."||!n.dot&&u.charAt(0)==="."){this.debug("dot detected!",t,l,e,m);break}this.debug("globstar swallow a segment, and continue"),l++}return!!(i&&(this.debug(` >>> no match, partial?`,t,l,e,m),l===o))}var d;if(typeof c=="string"?(d=p===c,this.debug("string match",c,p,d)):(d=p.match(c),this.debug("pattern match",c,p,d)),!d)return!1}if(a===o&&r===s)return!0;if(a===o)return i;if(r===s)return a===o-1&&t[a]==="";throw new Error("wtf?")};function ov(t){return t.replace(/\\(.)/g,"$1")}function sv(t){return t.replace(/[-[\]{}()*+?.,\\^$|#\s]/g,"\\$&")}});var ys=f((lS,Sa)=>{typeof Object.create=="function"?Sa.exports=function(e,i){i&&(e.super_=i,e.prototype=Object.create(i.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}))}:Sa.exports=function(e,i){if(i){e.super_=i;var n=function(){};n.prototype=i.prototype,e.prototype=new n,e.prototype.constructor=e}}});var bs=f((uS,Ea)=>{try{if(ka=require("util"),typeof ka.inherits!="function")throw"";Ea.exports=ka.inherits}catch{Ea.exports=ys()}var ka});var cn=f((dS,sn)=>{"use strict";function ws(t){return t.charAt(0)==="/"}function _s(t){var e=/^([a-zA-Z]:|[\\\/]{2}[^\\\/]+[\\\/]+[^\\\/]+)?([\\\/])?([\s\S]*?)$/,i=e.exec(t),n=i[1]||"",a=!!(n&&n.charAt(1)!==":");return!!(i[2]||a)}sn.exports=process.platform==="win32"?_s:ws;sn.exports.posix=ws;sn.exports.win32=_s});var Ta=f(qe=>{qe.alphasort=Es;qe.alphasorti=ks;qe.setopts=dv;qe.ownProp=Ss;qe.makeAbs=Aa;qe.finish=mv;qe.mark=fv;qe.isIgnored=Cs;qe.childrenIgnored=hv;function Ss(t,e){return Object.prototype.hasOwnProperty.call(t,e)}var kt=require("path"),cv=on(),pv=cn(),Ca=cv.Minimatch;function ks(t,e){return t.toLowerCase().localeCompare(e.toLowerCase())}function Es(t,e){return t.localeCompare(e)}function lv(t,e){t.ignore=e.ignore||[],Array.isArray(t.ignore)||(t.ignore=[t.ignore]),t.ignore.length&&(t.ignore=t.ignore.map(uv))}function uv(t){var e=null;if(t.slice(-3)==="/**"){var i=t.replace(/(\/\*\*)+$/,"");e=new Ca(i,{dot:!0})}return{matcher:new Ca(t,{dot:!0}),gmatcher:e}}function dv(t,e,i){if(i||(i={}),i.matchBase&&e.indexOf("/")===-1){if(i.noglobstar)throw new Error("base matching requires globstar");e="**/"+e}t.silent=!!i.silent,t.pattern=e,t.strict=i.strict!==!1,t.realpath=!!i.realpath,t.realpathCache=i.realpathCache||Object.create(null),t.follow=!!i.follow,t.dot=!!i.dot,t.mark=!!i.mark,t.nodir=!!i.nodir,t.nodir&&(t.mark=!0),t.sync=!!i.sync,t.nounique=!!i.nounique,t.nonull=!!i.nonull,t.nosort=!!i.nosort,t.nocase=!!i.nocase,t.stat=!!i.stat,t.noprocess=!!i.noprocess,t.maxLength=i.maxLength||1/0,t.cache=i.cache||Object.create(null),t.statCache=i.statCache||Object.create(null),t.symlinks=i.symlinks||Object.create(null),lv(t,i),t.changedCwd=!1;var n=process.cwd();Ss(i,"cwd")?(t.cwd=i.cwd,t.changedCwd=kt.resolve(i.cwd)!==n):t.cwd=n,t.root=i.root||kt.resolve(t.cwd,"/"),t.root=kt.resolve(t.root),process.platform==="win32"&&(t.root=t.root.replace(/\\/g,"/")),t.nomount=!!i.nomount,i.nonegate=!0,i.nocomment=!0,t.minimatch=new Ca(e,i),t.options=t.minimatch.options}function mv(t){for(var e=t.nounique,i=e?[]:Object.create(null),n=0,a=t.matches.length;n<a;n++){var r=t.matches[n];if(!r||Object.keys(r).length===0){if(t.nonull){var o=t.minimatch.globSet[n];e?i.push(o):i[o]=!0}}else{var s=Object.keys(r);e?i.push.apply(i,s):s.forEach(function(c){i[c]=!0})}}if(e||(i=Object.keys(i)),t.nosort||(i=i.sort(t.nocase?ks:Es)),t.mark){for(var n=0;n<i.length;n++)i[n]=t._mark(i[n]);t.nodir&&(i=i.filter(function(c){return!/\/$/.test(c)}))}t.ignore.length&&(i=i.filter(function(c){return!Cs(t,c)})),t.found=i}function fv(t,e){var i=Aa(t,e),n=t.cache[i],a=e;if(n){var r=n==="DIR"||Array.isArray(n),o=e.slice(-1)==="/";if(r&&!o?a+="/":!r&&o&&(a=a.slice(0,-1)),a!==e){var s=Aa(t,a);t.statCache[s]=t.statCache[i],t.cache[s]=t.cache[i]}}return a}function Aa(t,e){var i=e;return e.charAt(0)==="/"?i=kt.join(t.root,e):pv(e)||e===""?i=e:t.changedCwd?i=kt.resolve(t.cwd,e):i=kt.resolve(e),i}function Cs(t,e){return t.ignore.length?t.ignore.some(function(i){return i.matcher.match(e)||!!(i.gmatcher&&i.gmatcher.match(e))}):!1}function hv(t,e){return t.ignore.length?t.ignore.some(function(i){return!!(i.gmatcher&&i.gmatcher.match(e))}):!1}});var Rs=f((yS,js)=>{js.exports=Os;Os.GlobSync=ne;var ni=require("fs"),As=on(),fS=As.Minimatch,hS=Ra().Glob,vS=require("util"),Oa=require("path"),Ts=require("assert"),pn=cn(),Qe=Ta(),xS=Qe.alphasort,gS=Qe.alphasorti,vv=Qe.setopts,ja=Qe.ownProp,xv=Qe.childrenIgnored;function Os(t,e){if(typeof e=="function"||arguments.length===3)throw new TypeError(`callback provided to sync glob See: https://github.com/isaacs/node-glob/issues/167`);return new ne(t,e).found}function ne(t,e){if(!t)throw new Error("must provide pattern");if(typeof e=="function"||arguments.length===3)throw new TypeError(`callback provided to sync glob See: https://github.com/isaacs/node-glob/issues/167`);if(!(this instanceof ne))return new ne(t,e);if(vv(this,t,e),this.noprocess)return this;var i=this.minimatch.set.length;this.matches=new Array(i);for(var n=0;n<i;n++)this._process(this.minimatch.set[n],n,!1);this._finish()}ne.prototype._finish=function(){if(Ts(this instanceof ne),this.realpath){var t=this;this.matches.forEach(function(e,i){var n=t.matches[i]=Object.create(null);for(var a in e)try{a=t._makeAbs(a);var r=ni.realpathSync(a,t.realpathCache);n[r]=!0}catch(o){if(o.syscall==="stat")n[t._makeAbs(a)]=!0;else throw o}})}Qe.finish(this)};ne.prototype._process=function(t,e,i){Ts(this instanceof ne);for(var n=0;typeof t[n]=="string";)n++;var a;switch(n){case t.length:this._processSimple(t.join("/"),e);return;case 0:a=null;break;default:a=t.slice(0,n).join("/");break}var r=t.slice(n),o;a===null?o=".":((pn(a)||pn(t.join("/")))&&(!a||!pn(a))&&(a="/"+a),o=a);var s=this._makeAbs(o);if(!xv(this,o)){var c=r[0]===As.GLOBSTAR;c?this._processGlobStar(a,o,s,r,e,i):this._processReaddir(a,o,s,r,e,i)}};ne.prototype._processReaddir=function(t,e,i,n,a,r){var o=this._readdir(i,r);if(o){for(var s=n[0],c=!!this.minimatch.negate,p=s._glob,l=this.dot||p.charAt(0)===".",m=[],u=0;u<o.length;u++){var d=o[u];if(d.charAt(0)!=="."||l){var h;c&&!t?h=!d.match(s):h=d.match(s),h&&m.push(d)}}var v=m.length;if(v!==0){if(n.length===1&&!this.mark&&!this.stat){this.matches[a]||(this.matches[a]=Object.create(null));for(var u=0;u<v;u++){var d=m[u];t&&(t.slice(-1)!=="/"?d=t+"/"+d:d=t+d),d.charAt(0)==="/"&&!this.nomount&&(d=Oa.join(this.root,d)),this.matches[a][d]=!0}return}n.shift();for(var u=0;u<v;u++){var d=m[u],b;t?b=[t,d]:b=[d],this._process(b.concat(n),a,r)}}}};ne.prototype._emitMatch=function(t,e){var i=this._makeAbs(e);if(this.mark&&(e=this._mark(e)),!this.matches[t][e]){if(this.nodir){var n=this.cache[this._makeAbs(e)];if(n==="DIR"||Array.isArray(n))return}this.matches[t][e]=!0,this.stat&&this._stat(e)}};ne.prototype._readdirInGlobStar=function(t){if(this.follow)return this._readdir(t,!1);var e,i,n;try{i=ni.lstatSync(t)}catch{return null}var a=i.isSymbolicLink();return this.symlinks[t]=a,!a&&!i.isDirectory()?this.cache[t]="FILE":e=this._readdir(t,!1),e};ne.prototype._readdir=function(t,e){var i;if(e&&!ja(this.symlinks,t))return this._readdirInGlobStar(t);if(ja(this.cache,t)){var n=this.cache[t];if(!n||n==="FILE")return null;if(Array.isArray(n))return n}try{return this._readdirEntries(t,ni.readdirSync(t))}catch(a){return this._readdirError(t,a),null}};ne.prototype._readdirEntries=function(t,e){if(!this.mark&&!this.stat)for(var i=0;i<e.length;i++){var n=e[i];t==="/"?n=t+n:n=t+"/"+n,this.cache[n]=!0}return this.cache[t]=e,e};ne.prototype._readdirError=function(t,e){switch(e.code){case"ENOTSUP":case"ENOTDIR":this.cache[this._makeAbs(t)]="FILE";break;case"ENOENT":case"ELOOP":case"ENAMETOOLONG":case"UNKNOWN":this.cache[this._makeAbs(t)]=!1;break;default:if(this.cache[this._makeAbs(t)]=!1,this.strict)throw e;this.silent||console.error("glob error",e);break}};ne.prototype._processGlobStar=function(t,e,i,n,a,r){var o=this._readdir(i,r);if(o){var s=n.slice(1),c=t?[t]:[],p=c.concat(s);this._process(p,a,!1);var l=o.length,m=this.symlinks[i];if(!(m&&r))for(var u=0;u<l;u++){var d=o[u];if(!(d.charAt(0)==="."&&!this.dot)){var h=c.concat(o[u],s);this._process(h,a,!0);var v=c.concat(o[u],n);this._process(v,a,!0)}}}};ne.prototype._processSimple=function(t,e){var i=this._stat(t);if(this.matches[e]||(this.matches[e]=Object.create(null)),!!i){if(t&&pn(t)&&!this.nomount){var n=/[\/\\]$/.test(t);t.charAt(0)==="/"?t=Oa.join(this.root,t):(t=Oa.resolve(this.root,t),n&&(t+="/"))}process.platform==="win32"&&(t=t.replace(/\\/g,"/")),this.matches[e][t]=!0}};ne.prototype._stat=function(t){var e=this._makeAbs(t),i=t.slice(-1)==="/";if(t.length>this.maxLength)return!1;if(!this.stat&&ja(this.cache,e)){var o=this.cache[e];if(Array.isArray(o)&&(o="DIR"),!i||o==="DIR")return o;if(i&&o==="FILE")return!1}var n,a=this.statCache[e];if(!a){var r;try{r=ni.lstatSync(e)}catch{return!1}if(r.isSymbolicLink())try{a=ni.statSync(e)}catch{a=r}else a=r}this.statCache[e]=a;var o=a.isDirectory()?"DIR":"FILE";return this.cache[e]=this.cache[e]||o,i&&o!=="DIR"?!1:o};ne.prototype._mark=function(t){return Qe.mark(this,t)};ne.prototype._makeAbs=function(t){return Qe.makeAbs(this,t)}});var ln=f((bS,Ls)=>{Ls.exports=qs;function qs(t,e){if(t&&e)return qs(t)(e);if(typeof t!="function")throw new TypeError("need wrapper function");return Object.keys(t).forEach(function(n){i[n]=t[n]}),i;function i(){for(var n=new Array(arguments.length),a=0;a<n.length;a++)n[a]=arguments[a];var r=t.apply(this,n),o=n[n.length-1];return typeof r=="function"&&r!==o&&Object.keys(o).forEach(function(s){r[s]=o[s]}),r}}});var dn=f((wS,qa)=>{var Fs=ln();qa.exports=Fs(un);qa.exports.strict=Fs(Ds);un.proto=un(function(){Object.defineProperty(Function.prototype,"once",{value:function(){return un(this)},configurable:!0}),Object.defineProperty(Function.prototype,"onceStrict",{value:function(){return Ds(this)},configurable:!0})});function un(t){var e=function(){return e.called?e.value:(e.called=!0,e.value=t.apply(this,arguments))};return e.called=!1,e}function Ds(t){var e=function(){if(e.called)throw new Error(e.onceError);return e.called=!0,e.value=t.apply(this,arguments)},i=t.name||"Function wrapped with `once`";return e.onceError=i+" shouldn't be called more than once",e.called=!1,e}});var Ns=f((_S,zs)=>{var gv=ln(),ai=Object.create(null),yv=dn();zs.exports=gv(bv);function bv(t,e){return ai[t]?(ai[t].push(e),null):(ai[t]=[e],wv(t))}function wv(t){return yv(function e(){var i=ai[t],n=i.length,a=_v(arguments);try{for(var r=0;r<n;r++)i[r].apply(null,a)}finally{i.length>n?(i.splice(0,n),process.nextTick(function(){e.apply(null,a)})):delete ai[t]}})}function _v(t){for(var e=t.length,i=[],n=0;n<e;n++)i[n]=t[n];return i}});var Ra=f((AS,Is)=>{Is.exports=ct;var ri=require("fs"),Ps=on(),SS=Ps.Minimatch,Sv=bs(),kv=require("events").EventEmitter,La=require("path"),Fa=require("assert"),mn=cn(),za=Rs(),Be=Ta(),kS=Be.alphasort,ES=Be.alphasorti,Ev=Be.setopts,Da=Be.ownProp,Na=Ns(),CS=require("util"),Cv=Be.childrenIgnored,Av=Be.isIgnored,Tv=dn();function ct(t,e,i){if(typeof e=="function"&&(i=e,e={}),e||(e={}),e.sync){if(i)throw new TypeError("callback provided to sync glob");return za(t,e)}return new N(t,e,i)}ct.sync=za;var Ov=ct.GlobSync=za.GlobSync;ct.glob=ct;function jv(t,e){if(e===null||typeof e!="object")return t;for(var i=Object.keys(e),n=i.length;n--;)t[i[n]]=e[i[n]];return t}ct.hasMagic=function(t,e){var i=jv({},e);i.noprocess=!0;var n=new N(t,i),a=n.minimatch.set;if(a.length>1)return!0;for(var r=0;r<a[0].length;r++)if(typeof a[0][r]!="string")return!0;return!1};ct.Glob=N;Sv(N,kv);function N(t,e,i){if(typeof e=="function"&&(i=e,e=null),e&&e.sync){if(i)throw new TypeError("callback provided to sync glob");return new Ov(t,e)}if(!(this instanceof N))return new N(t,e,i);Ev(this,t,e),this._didRealPath=!1;var a=this.minimatch.set.length;this.matches=new Array(a),typeof i=="function"&&(i=Tv(i),this.on("error",i),this.on("end",function(s){i(null,s)}));var n=this,a=this.minimatch.set.length;if(this._processing=0,this.matches=new Array(a),this._emitQueue=[],this._processQueue=[],this.paused=!1,this.noprocess)return this;if(a===0)return o();for(var r=0;r<a;r++)this._process(this.minimatch.set[r],r,!1,o);function o(){--n._processing,n._processing<=0&&n._finish()}}N.prototype._finish=function(){if(Fa(this instanceof N),!this.aborted){if(this.realpath&&!this._didRealpath)return this._realpath();Be.finish(this),this.emit("end",this.found)}};N.prototype._realpath=function(){if(this._didRealpath)return;this._didRealpath=!0;var t=this.matches.length;if(t===0)return this._finish();for(var e=this,i=0;i<this.matches.length;i++)this._realpathSet(i,n);function n(){--t===0&&e._finish()}};N.prototype._realpathSet=function(t,e){var i=this.matches[t];if(!i)return e();var n=Object.keys(i),a=this,r=n.length;if(r===0)return e();var o=this.matches[t]=Object.create(null);n.forEach(function(s,c){s=a._makeAbs(s),ri.realpath(s,a.realpathCache,function(p,l){p?p.syscall==="stat"?o[s]=!0:a.emit("error",p):o[l]=!0,--r===0&&(a.matches[t]=o,e())})})};N.prototype._mark=function(t){return Be.mark(this,t)};N.prototype._makeAbs=function(t){return Be.makeAbs(this,t)};N.prototype.abort=function(){this.aborted=!0,this.emit("abort")};N.prototype.pause=function(){this.paused||(this.paused=!0,this.emit("pause"))};N.prototype.resume=function(){if(this.paused){if(this.emit("resume"),this.paused=!1,this._emitQueue.length){var t=this._emitQueue.slice(0);this._emitQueue.length=0;for(var e=0;e<t.length;e++){var i=t[e];this._emitMatch(i[0],i[1])}}if(this._processQueue.length){var n=this._processQueue.slice(0);this._processQueue.length=0;for(var e=0;e<n.length;e++){var a=n[e];this._processing--,this._process(a[0],a[1],a[2],a[3])}}}};N.prototype._process=function(t,e,i,n){if(Fa(this instanceof N),Fa(typeof n=="function"),!this.aborted){if(this._processing++,this.paused){this._processQueue.push([t,e,i,n]);return}for(var a=0;typeof t[a]=="string";)a++;var r;switch(a){case t.length:this._processSimple(t.join("/"),e,n);return;case 0:r=null;break;default:r=t.slice(0,a).join("/");break}var o=t.slice(a),s;r===null?s=".":((mn(r)||mn(t.join("/")))&&(!r||!mn(r))&&(r="/"+r),s=r);var c=this._makeAbs(s);if(Cv(this,s))return n();var p=o[0]===Ps.GLOBSTAR;p?this._processGlobStar(r,s,c,o,e,i,n):this._processReaddir(r,s,c,o,e,i,n)}};N.prototype._processReaddir=function(t,e,i,n,a,r,o){var s=this;this._readdir(i,r,function(c,p){return s._processReaddir2(t,e,i,n,a,r,p,o)})};N.prototype._processReaddir2=function(t,e,i,n,a,r,o,s){if(!o)return s();for(var c=n[0],p=!!this.minimatch.negate,l=c._glob,m=this.dot||l.charAt(0)===".",u=[],d=0;d<o.length;d++){var h=o[d];if(h.charAt(0)!=="."||m){var v;p&&!t?v=!h.match(c):v=h.match(c),v&&u.push(h)}}var b=u.length;if(b===0)return s();if(n.length===1&&!this.mark&&!this.stat){this.matches[a]||(this.matches[a]=Object.create(null));for(var d=0;d<b;d++){var h=u[d];t&&(t!=="/"?h=t+"/"+h:h=t+h),h.charAt(0)==="/"&&!this.nomount&&(h=La.join(this.root,h)),this._emitMatch(a,h)}return s()}n.shift();for(var d=0;d<b;d++){var h=u[d],x;t&&(t!=="/"?h=t+"/"+h:h=t+h),this._process([h].concat(n),a,r,s)}s()};N.prototype._emitMatch=function(t,e){if(!this.aborted&&!this.matches[t][e]&&!Av(this,e)){if(this.paused){this._emitQueue.push([t,e]);return}var i=this._makeAbs(e);if(this.nodir){var n=this.cache[i];if(n==="DIR"||Array.isArray(n))return}this.mark&&(e=this._mark(e)),this.matches[t][e]=!0;var a=this.statCache[i];a&&this.emit("stat",e,a),this.emit("match",e)}};N.prototype._readdirInGlobStar=function(t,e){if(this.aborted)return;if(this.follow)return this._readdir(t,!1,e);var i="lstat\0"+t,n=this,a=Na(i,r);a&&ri.lstat(t,a);function r(o,s){if(o)return e();var c=s.isSymbolicLink();n.symlinks[t]=c,!c&&!s.isDirectory()?(n.cache[t]="FILE",e()):n._readdir(t,!1,e)}};N.prototype._readdir=function(t,e,i){if(!this.aborted&&(i=Na("readdir\0"+t+"\0"+e,i),!!i)){if(e&&!Da(this.symlinks,t))return this._readdirInGlobStar(t,i);if(Da(this.cache,t)){var n=this.cache[t];if(!n||n==="FILE")return i();if(Array.isArray(n))return i(null,n)}var a=this;ri.readdir(t,Rv(this,t,i))}};function Rv(t,e,i){return function(n,a){n?t._readdirError(e,n,i):t._readdirEntries(e,a,i)}}N.prototype._readdirEntries=function(t,e,i){if(!this.aborted){if(!this.mark&&!this.stat)for(var n=0;n<e.length;n++){var a=e[n];t==="/"?a=t+a:a=t+"/"+a,this.cache[a]=!0}return this.cache[t]=e,i(null,e)}};N.prototype._readdirError=function(t,e,i){if(!this.aborted){switch(e.code){case"ENOTSUP":case"ENOTDIR":this.cache[this._makeAbs(t)]="FILE";break;case"ENOENT":case"ELOOP":case"ENAMETOOLONG":case"UNKNOWN":this.cache[this._makeAbs(t)]=!1;break;default:this.cache[this._makeAbs(t)]=!1,this.strict&&(this.emit("error",e),this.abort()),this.silent||console.error("glob error",e);break}return i()}};N.prototype._processGlobStar=function(t,e,i,n,a,r,o){var s=this;this._readdir(i,r,function(c,p){s._processGlobStar2(t,e,i,n,a,r,p,o)})};N.prototype._processGlobStar2=function(t,e,i,n,a,r,o,s){if(!o)return s();var c=n.slice(1),p=t?[t]:[],l=p.concat(c);this._process(l,a,!1,s);var m=this.symlinks[i],u=o.length;if(m&&r)return s();for(var d=0;d<u;d++){var h=o[d];if(!(h.charAt(0)==="."&&!this.dot)){var v=p.concat(o[d],c);this._process(v,a,!0,s);var b=p.concat(o[d],n);this._process(b,a,!0,s)}}s()};N.prototype._processSimple=function(t,e,i){var n=this;this._stat(t,function(a,r){n._processSimple2(t,e,a,r,i)})};N.prototype._processSimple2=function(t,e,i,n,a){if(this.matches[e]||(this.matches[e]=Object.create(null)),!n)return a();if(t&&mn(t)&&!this.nomount){var r=/[\/\\]$/.test(t);t.charAt(0)==="/"?t=La.join(this.root,t):(t=La.resolve(this.root,t),r&&(t+="/"))}process.platform==="win32"&&(t=t.replace(/\\/g,"/")),this._emitMatch(e,t),a()};N.prototype._stat=function(t,e){var i=this._makeAbs(t),n=t.slice(-1)==="/";if(t.length>this.maxLength)return e();if(!this.stat&&Da(this.cache,i)){var a=this.cache[i];if(Array.isArray(a)&&(a="DIR"),!n||a==="DIR")return e(null,a);if(n&&a==="FILE")return e()}var r,o=this.statCache[i];if(o!==void 0){if(o===!1)return e(null,o);var s=o.isDirectory()?"DIR":"FILE";return n&&s==="FILE"?e():e(null,s,o)}var c=this,p=Na("stat\0"+i,l);p&&ri.lstat(i,p);function l(m,u){if(u&&u.isSymbolicLink())return ri.stat(i,function(d,h){d?c._stat2(t,i,null,u,e):c._stat2(t,i,d,h,e)});c._stat2(t,i,m,u,e)}};N.prototype._stat2=function(t,e,i,n,a){if(i)return this.statCache[e]=!1,a();var r=t.slice(-1)==="/";if(this.statCache[e]=n,e.slice(-1)==="/"&&!n.isDirectory())return a(null,!1,n);var o=n.isDirectory()?"DIR":"FILE";return this.cache[e]=this.cache[e]||o,r&&o!=="DIR"?a():a(null,o,n)}});var Gs=f((TS,Hs)=>{Hs.exports=Ba;Ba.sync=$s;var z=require("assert"),Ms=require("path"),vn=require("fs"),xn=Ra(),Bs={nosort:!0,nocomment:!0,nonegate:!0,silent:!0},Pa=0,Ma=process.platform==="win32";function Us(t){var e=["unlink","chmod","stat","lstat","rmdir","readdir"];e.forEach(function(i){t[i]=t[i]||vn[i],i=i+"Sync",t[i]=t[i]||vn[i]}),t.maxBusyTries=t.maxBusyTries||3,t.emfileWait=t.emfileWait||1e3,t.disableGlob=t.disableGlob||!1}function Ba(t,e,i){typeof e=="function"&&(i=e,e={}),z(t,"rimraf: missing path"),z.equal(typeof t,"string","rimraf: path should be a string"),z(e,"rimraf: missing options"),z.equal(typeof e,"object","rimraf: options should be object"),z.equal(typeof i,"function","rimraf: callback function required"),Us(e);var n=0,a=null,r=0;if(e.disableGlob||!xn.hasMagic(t))return s(null,[t]);vn.lstat(t,function(c,p){if(!c)return s(null,[t]);xn(t,Bs,s)});function o(c){a=a||c,--r===0&&i(a)}function s(c,p){if(c)return i(c);if(r=p.length,r===0)return i();p.forEach(function(l){Ia(l,e,function m(u){if(u){if(Ma&&(u.code==="EBUSY"||u.code==="ENOTEMPTY"||u.code==="EPERM")&&n<e.maxBusyTries){n++;var d=n*100;return setTimeout(function(){Ia(l,e,m)},d)}if(u.code==="EMFILE"&&Pa<e.emfileWait)return setTimeout(function(){Ia(l,e,m)},Pa++);u.code==="ENOENT"&&(u=null)}Pa=0,o(u)})})}}function Ia(t,e,i){z(t),z(e),z(typeof i=="function"),e.lstat(t,function(n,a){if(n&&n.code==="ENOENT")return i(null);if(a&&a.isDirectory())return fn(t,e,n,i);e.unlink(t,function(r){if(r){if(r.code==="ENOENT")return i(null);if(r.code==="EPERM")return Ma?qv(t,e,r,i):fn(t,e,r,i);if(r.code==="EISDIR")return fn(t,e,r,i)}return i(r)})})}function qv(t,e,i,n){z(t),z(e),z(typeof n=="function"),i&&z(i instanceof Error),e.chmod(t,666,function(a){a?n(a.code==="ENOENT"?null:i):e.stat(t,function(r,o){r?n(r.code==="ENOENT"?null:i):o.isDirectory()?fn(t,e,i,n):e.unlink(t,n)})})}function Lv(t,e,i){z(t),z(e),i&&z(i instanceof Error);try{e.chmodSync(t,666)}catch(a){if(a.code==="ENOENT")return;throw i}try{var n=e.statSync(t)}catch(a){if(a.code==="ENOENT")return;throw i}n.isDirectory()?hn(t,e,i):e.unlinkSync(t)}function fn(t,e,i,n){z(t),z(e),i&&z(i instanceof Error),z(typeof n=="function"),e.rmdir(t,function(a){a&&(a.code==="ENOTEMPTY"||a.code==="EEXIST"||a.code==="EPERM")?Fv(t,e,n):a&&a.code==="ENOTDIR"?n(i):n(a)})}function Fv(t,e,i){z(t),z(e),z(typeof i=="function"),e.readdir(t,function(n,a){if(n)return i(n);var r=a.length;if(r===0)return e.rmdir(t,i);var o;a.forEach(function(s){Ba(Ms.join(t,s),e,function(c){if(!o){if(c)return i(o=c);--r===0&&e.rmdir(t,i)}})})})}function $s(t,e){e=e||{},Us(e),z(t,"rimraf: missing path"),z.equal(typeof t,"string","rimraf: path should be a string"),z(e,"rimraf: missing options"),z.equal(typeof e,"object","rimraf: options should be object");var i;if(e.disableGlob||!xn.hasMagic(t))i=[t];else try{vn.lstatSync(t),i=[t]}catch{i=xn.sync(t,Bs)}if(i.length)for(var n=0;n<i.length;n++){var t=i[n];try{var a=e.lstatSync(t)}catch(o){if(o.code==="ENOENT")return}try{a&&a.isDirectory()?hn(t,e,null):e.unlinkSync(t)}catch(o){if(o.code==="ENOENT")return;if(o.code==="EPERM")return Ma?Lv(t,e,o):hn(t,e,o);if(o.code!=="EISDIR")throw o;hn(t,e,o)}}}function hn(t,e,i){z(t),z(e),i&&z(i instanceof Error);try{e.rmdirSync(t)}catch(n){if(n.code==="ENOENT")return;if(n.code==="ENOTDIR")throw i;(n.code==="ENOTEMPTY"||n.code==="EEXIST"||n.code==="EPERM")&&Dv(t,e)}}function Dv(t,e){z(t),z(e),e.readdirSync(t).forEach(function(i){$s(Ms.join(t,i),e)}),e.rmdirSync(t,e)}});var Ks=f((OS,Js)=>{var oi=require("path"),Ws=require("fs"),Vs=parseInt("0777",8);Js.exports=Et.mkdirp=Et.mkdirP=Et;function Et(t,e,i,n){typeof e=="function"?(i=e,e={}):(!e||typeof e!="object")&&(e={mode:e});var a=e.mode,r=e.fs||Ws;a===void 0&&(a=Vs),n||(n=null);var o=i||function(){};t=oi.resolve(t),r.mkdir(t,a,function(s){if(!s)return n=n||t,o(null,n);switch(s.code){case"ENOENT":if(oi.dirname(t)===t)return o(s);Et(oi.dirname(t),e,function(c,p){c?o(c,p):Et(t,e,o,p)});break;default:r.stat(t,function(c,p){c||!p.isDirectory()?o(s,n):o(null,n)});break}})}Et.sync=function t(e,i,n){(!i||typeof i!="object")&&(i={mode:i});var a=i.mode,r=i.fs||Ws;a===void 0&&(a=Vs),n||(n=null),e=oi.resolve(e);try{r.mkdirSync(e,a),n=n||e}catch(s){switch(s.code){case"ENOENT":n=t(oi.dirname(e),i,n),t(e,i,n);break;default:var o;try{o=r.statSync(e)}catch{throw s}if(!o.isDirectory())throw s;break}}return n}});var ec=f((jS,Zs)=>{var Ct=require("fs"),zv=Xo().ncp,Nv=require("path"),Qs=Gs(),Pv=Ks();Zs.exports=Iv;function Iv(t,e,i,n){typeof i=="function"&&(n=i,i={});var a=!!i.mkdirp,r=i.clobber!==!1,o=i.limit||16;a?s():c();function s(){Pv(Nv.dirname(e),function(p){if(p)return n(p);c()})}function c(){r?Ct.rename(t,e,function(p){if(!p)return n();if(p.code!=="EXDEV")return n(p);Ys(t,e,r,o,n)}):Ct.link(t,e,function(p){if(p){if(p.code==="EXDEV"){Ys(t,e,r,o,n);return}if(p.code==="EISDIR"||p.code==="EPERM"){Xs(t,e,r,o,n);return}n(p);return}Ct.unlink(t,n)})}}function Ys(t,e,i,n,a){var r=i?"w":"wx",o=Ct.createReadStream(t),s=Ct.createWriteStream(e,{flags:r});o.on("error",function(p){o.destroy(),s.destroy(),s.removeListener("close",c),p.code==="EISDIR"||p.code==="EPERM"?Xs(t,e,i,n,a):a(p)}),s.on("error",function(p){o.destroy(),s.destroy(),s.removeListener("close",c),a(p)}),s.once("close",c),o.pipe(s);function c(){Ct.unlink(t,a)}}function Xs(t,e,i,n,a){var r={stopOnErr:!0,clobber:!1,limit:n};i?Qs(e,{disableGlob:!0},function(s){if(s)return a(s);o()}):o();function o(){zv(t,e,r,function(s){if(s)return a(s[0]);Qs(t,{disableGlob:!0},a)})}}});var ic=f(Ua=>{var tc="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/".split("");Ua.encode=function(t){if(0<=t&&t<tc.length)return tc[t];throw new TypeError("Must be between 0 and 63: "+t)};Ua.decode=function(t){var e=65,i=90,n=97,a=122,r=48,o=57,s=43,c=47,p=26,l=52;return e<=t&&t<=i?t-e:n<=t&&t<=a?t-n+p:r<=t&&t<=o?t-r+l:t==s?62:t==c?63:-1}});var Ga=f(Ha=>{var nc=ic(),$a=5,ac=1<<$a,rc=ac-1,oc=ac;function Mv(t){return t<0?(-t<<1)+1:(t<<1)+0}function Bv(t){var e=(t&1)===1,i=t>>1;return e?-i:i}Ha.encode=function(e){var i="",n,a=Mv(e);do n=a&rc,a>>>=$a,a>0&&(n|=oc),i+=nc.encode(n);while(a>0);return i};Ha.decode=function(e,i,n){var a=e.length,r=0,o=0,s,c;do{if(i>=a)throw new Error("Expected more digits in base 64 VLQ value.");if(c=nc.decode(e.charCodeAt(i++)),c===-1)throw new Error("Invalid base64 digit: "+e.charAt(i-1));s=!!(c&oc),c&=rc,r=r+(c<<o),o+=$a}while(s);n.value=Bv(r),n.rest=i}});var Ot=f(me=>{function Uv(t,e,i){if(e in t)return t[e];if(arguments.length===3)return i;throw new Error('"'+e+'" is a required argument.')}me.getArg=Uv;var sc=/^(?:([\w+\-.]+):)?\/\/(?:(\w+:\w+)@)?([\w.-]*)(?::(\d+))?(.*)$/,$v=/^data:.+\,.+$/;function si(t){var e=t.match(sc);return e?{scheme:e[1],auth:e[2],host:e[3],port:e[4],path:e[5]}:null}me.urlParse=si;function At(t){var e="";return t.scheme&&(e+=t.scheme+":"),e+="//",t.auth&&(e+=t.auth+"@"),t.host&&(e+=t.host),t.port&&(e+=":"+t.port),t.path&&(e+=t.path),e}me.urlGenerate=At;function Wa(t){var e=t,i=si(t);if(i){if(!i.path)return t;e=i.path}for(var n=me.isAbsolute(e),a=e.split(/\/+/),r,o=0,s=a.length-1;s>=0;s--)r=a[s],r==="."?a.splice(s,1):r===".."?o++:o>0&&(r===""?(a.splice(s+1,o),o=0):(a.splice(s,2),o--));return e=a.join("/"),e===""&&(e=n?"/":"."),i?(i.path=e,At(i)):e}me.normalize=Wa;function cc(t,e){t===""&&(t="."),e===""&&(e=".");var i=si(e),n=si(t);if(n&&(t=n.path||"/"),i&&!i.scheme)return n&&(i.scheme=n.scheme),At(i);if(i||e.match($v))return e;if(n&&!n.host&&!n.path)return n.host=e,At(n);var a=e.charAt(0)==="/"?e:Wa(t.replace(/\/+$/,"")+"/"+e);return n?(n.path=a,At(n)):a}me.join=cc;me.isAbsolute=function(t){return t.charAt(0)==="/"||sc.test(t)};function Hv(t,e){t===""&&(t="."),t=t.replace(/\/$/,"");for(var i=0;e.indexOf(t+"/")!==0;){var n=t.lastIndexOf("/");if(n<0||(t=t.slice(0,n),t.match(/^([^\/]+:\/)?\/*$/)))return e;++i}return Array(i+1).join("../")+e.substr(t.length+1)}me.relative=Hv;var pc=function(){var t=Object.create(null);return!("__proto__"in t)}();function lc(t){return t}function Gv(t){return uc(t)?"$"+t:t}me.toSetString=pc?lc:Gv;function Wv(t){return uc(t)?t.slice(1):t}me.fromSetString=pc?lc:Wv;function uc(t){if(!t)return!1;var e=t.length;if(e<9||t.charCodeAt(e-1)!==95||t.charCodeAt(e-2)!==95||t.charCodeAt(e-3)!==111||t.charCodeAt(e-4)!==116||t.charCodeAt(e-5)!==111||t.charCodeAt(e-6)!==114||t.charCodeAt(e-7)!==112||t.charCodeAt(e-8)!==95||t.charCodeAt(e-9)!==95)return!1;for(var i=e-10;i>=0;i--)if(t.charCodeAt(i)!==36)return!1;return!0}function Vv(t,e,i){var n=Tt(t.source,e.source);return n!==0||(n=t.originalLine-e.originalLine,n!==0)||(n=t.originalColumn-e.originalColumn,n!==0||i)||(n=t.generatedColumn-e.generatedColumn,n!==0)||(n=t.generatedLine-e.generatedLine,n!==0)?n:Tt(t.name,e.name)}me.compareByOriginalPositions=Vv;function Jv(t,e,i){var n=t.generatedLine-e.generatedLine;return n!==0||(n=t.generatedColumn-e.generatedColumn,n!==0||i)||(n=Tt(t.source,e.source),n!==0)||(n=t.originalLine-e.originalLine,n!==0)||(n=t.originalColumn-e.originalColumn,n!==0)?n:Tt(t.name,e.name)}me.compareByGeneratedPositionsDeflated=Jv;function Tt(t,e){return t===e?0:t===null?1:e===null?-1:t>e?1:-1}function Kv(t,e){var i=t.generatedLine-e.generatedLine;return i!==0||(i=t.generatedColumn-e.generatedColumn,i!==0)||(i=Tt(t.source,e.source),i!==0)||(i=t.originalLine-e.originalLine,i!==0)||(i=t.originalColumn-e.originalColumn,i!==0)?i:Tt(t.name,e.name)}me.compareByGeneratedPositionsInflated=Kv;function Qv(t){return JSON.parse(t.replace(/^\)]}'[^\n]*\n/,""))}me.parseSourceMapInput=Qv;function Yv(t,e,i){if(e=e||"",t&&(t[t.length-1]!=="/"&&e[0]!=="/"&&(t+="/"),e=t+e),i){var n=si(i);if(!n)throw new Error("sourceMapURL could not be parsed");if(n.path){var a=n.path.lastIndexOf("/");a>=0&&(n.path=n.path.substring(0,a+1))}e=cc(At(n),e)}return Wa(e)}me.computeSourceURL=Yv});var Ka=f(dc=>{var Va=Ot(),Ja=Object.prototype.hasOwnProperty,pt=typeof Map<"u";function Ue(){this._array=[],this._set=pt?new Map:Object.create(null)}Ue.fromArray=function(e,i){for(var n=new Ue,a=0,r=e.length;a<r;a++)n.add(e[a],i);return n};Ue.prototype.size=function(){return pt?this._set.size:Object.getOwnPropertyNames(this._set).length};Ue.prototype.add=function(e,i){var n=pt?e:Va.toSetString(e),a=pt?this.has(e):Ja.call(this._set,n),r=this._array.length;(!a||i)&&this._array.push(e),a||(pt?this._set.set(e,r):this._set[n]=r)};Ue.prototype.has=function(e){if(pt)return this._set.has(e);var i=Va.toSetString(e);return Ja.call(this._set,i)};Ue.prototype.indexOf=function(e){if(pt){var i=this._set.get(e);if(i>=0)return i}else{var n=Va.toSetString(e);if(Ja.call(this._set,n))return this._set[n]}throw new Error('"'+e+'" is not in the set.')};Ue.prototype.at=function(e){if(e>=0&&e<this._array.length)return this._array[e];throw new Error("No element indexed by "+e)};Ue.prototype.toArray=function(){return this._array.slice()};dc.ArraySet=Ue});var hc=f(fc=>{var mc=Ot();function Xv(t,e){var i=t.generatedLine,n=e.generatedLine,a=t.generatedColumn,r=e.generatedColumn;return n>i||n==i&&r>=a||mc.compareByGeneratedPositionsInflated(t,e)<=0}function gn(){this._array=[],this._sorted=!0,this._last={generatedLine:-1,generatedColumn:0}}gn.prototype.unsortedForEach=function(e,i){this._array.forEach(e,i)};gn.prototype.add=function(e){Xv(this._last,e)?(this._last=e,this._array.push(e)):(this._sorted=!1,this._array.push(e))};gn.prototype.toArray=function(){return this._sorted||(this._array.sort(mc.compareByGeneratedPositionsInflated),this._sorted=!0),this._array};fc.MappingList=gn});var Qa=f(vc=>{var ci=Ga(),X=Ot(),yn=Ka().ArraySet,Zv=hc().MappingList;function Ee(t){t||(t={}),this._file=X.getArg(t,"file",null),this._sourceRoot=X.getArg(t,"sourceRoot",null),this._skipValidation=X.getArg(t,"skipValidation",!1),this._sources=new yn,this._names=new yn,this._mappings=new Zv,this._sourcesContents=null}Ee.prototype._version=3;Ee.fromSourceMap=function(e){var i=e.sourceRoot,n=new Ee({file:e.file,sourceRoot:i});return e.eachMapping(function(a){var r={generated:{line:a.generatedLine,column:a.generatedColumn}};a.source!=null&&(r.source=a.source,i!=null&&(r.source=X.relative(i,r.source)),r.original={line:a.originalLine,column:a.originalColumn},a.name!=null&&(r.name=a.name)),n.addMapping(r)}),e.sources.forEach(function(a){var r=a;i!==null&&(r=X.relative(i,a)),n._sources.has(r)||n._sources.add(r);var o=e.sourceContentFor(a);o!=null&&n.setSourceContent(a,o)}),n};Ee.prototype.addMapping=function(e){var i=X.getArg(e,"generated"),n=X.getArg(e,"original",null),a=X.getArg(e,"source",null),r=X.getArg(e,"name",null);this._skipValidation||this._validateMapping(i,n,a,r),a!=null&&(a=String(a),this._sources.has(a)||this._sources.add(a)),r!=null&&(r=String(r),this._names.has(r)||this._names.add(r)),this._mappings.add({generatedLine:i.line,generatedColumn:i.column,originalLine:n!=null&&n.line,originalColumn:n!=null&&n.column,source:a,name:r})};Ee.prototype.setSourceContent=function(e,i){var n=e;this._sourceRoot!=null&&(n=X.relative(this._sourceRoot,n)),i!=null?(this._sourcesContents||(this._sourcesContents=Object.create(null)),this._sourcesContents[X.toSetString(n)]=i):this._sourcesContents&&(delete this._sourcesContents[X.toSetString(n)],Object.keys(this._sourcesContents).length===0&&(this._sourcesContents=null))};Ee.prototype.applySourceMap=function(e,i,n){var a=i;if(i==null){if(e.file==null)throw new Error(`SourceMapGenerator.prototype.applySourceMap requires either an explicit source file, or the source map's "file" property. Both were omitted.`);a=e.file}var r=this._sourceRoot;r!=null&&(a=X.relative(r,a));var o=new yn,s=new yn;this._mappings.unsortedForEach(function(c){if(c.source===a&&c.originalLine!=null){var p=e.originalPositionFor({line:c.originalLine,column:c.originalColumn});p.source!=null&&(c.source=p.source,n!=null&&(c.source=X.join(n,c.source)),r!=null&&(c.source=X.relative(r,c.source)),c.originalLine=p.line,c.originalColumn=p.column,p.name!=null&&(c.name=p.name))}var l=c.source;l!=null&&!o.has(l)&&o.add(l);var m=c.name;m!=null&&!s.has(m)&&s.add(m)},this),this._sources=o,this._names=s,e.sources.forEach(function(c){var p=e.sourceContentFor(c);p!=null&&(n!=null&&(c=X.join(n,c)),r!=null&&(c=X.relative(r,c)),this.setSourceContent(c,p))},this)};Ee.prototype._validateMapping=function(e,i,n,a){if(i&&typeof i.line!="number"&&typeof i.column!="number")throw new Error("original.line and original.column are not numbers -- you probably meant to omit the original mapping entirely and only map the generated position. If so, pass null for the original mapping instead of an object with empty or null values.");if(!(e&&"line"in e&&"column"in e&&e.line>0&&e.column>=0&&!i&&!n&&!a)){if(e&&"line"in e&&"column"in e&&i&&"line"in i&&"column"in i&&e.line>0&&e.column>=0&&i.line>0&&i.column>=0&&n)return;throw new Error("Invalid mapping: "+JSON.stringify({generated:e,source:n,original:i,name:a}))}};Ee.prototype._serializeMappings=function(){for(var e=0,i=1,n=0,a=0,r=0,o=0,s="",c,p,l,m,u=this._mappings.toArray(),d=0,h=u.length;d<h;d++){if(p=u[d],c="",p.generatedLine!==i)for(e=0;p.generatedLine!==i;)c+=";",i++;else if(d>0){if(!X.compareByGeneratedPositionsInflated(p,u[d-1]))continue;c+=","}c+=ci.encode(p.generatedColumn-e),e=p.generatedColumn,p.source!=null&&(m=this._sources.indexOf(p.source),c+=ci.encode(m-o),o=m,c+=ci.encode(p.originalLine-1-a),a=p.originalLine-1,c+=ci.encode(p.originalColumn-n),n=p.originalColumn,p.name!=null&&(l=this._names.indexOf(p.name),c+=ci.encode(l-r),r=l)),s+=c}return s};Ee.prototype._generateSourcesContent=function(e,i){return e.map(function(n){if(!this._sourcesContents)return null;i!=null&&(n=X.relative(i,n));var a=X.toSetString(n);return Object.prototype.hasOwnProperty.call(this._sourcesContents,a)?this._sourcesContents[a]:null},this)};Ee.prototype.toJSON=function(){var e={version:this._version,sources:this._sources.toArray(),names:this._names.toArray(),mappings:this._serializeMappings()};return this._file!=null&&(e.file=this._file),this._sourceRoot!=null&&(e.sourceRoot=this._sourceRoot),this._sourcesContents&&(e.sourcesContent=this._generateSourcesContent(e.sources,e.sourceRoot)),e};Ee.prototype.toString=function(){return JSON.stringify(this.toJSON())};vc.SourceMapGenerator=Ee});var xc=f(lt=>{lt.GREATEST_LOWER_BOUND=1;lt.LEAST_UPPER_BOUND=2;function Ya(t,e,i,n,a,r){var o=Math.floor((e-t)/2)+t,s=a(i,n[o],!0);return s===0?o:s>0?e-o>1?Ya(o,e,i,n,a,r):r==lt.LEAST_UPPER_BOUND?e<n.length?e:-1:o:o-t>1?Ya(t,o,i,n,a,r):r==lt.LEAST_UPPER_BOUND?o:t<0?-1:t}lt.search=function(e,i,n,a){if(i.length===0)return-1;var r=Ya(-1,i.length,e,i,n,a||lt.GREATEST_LOWER_BOUND);if(r<0)return-1;for(;r-1>=0&&n(i[r],i[r-1],!0)===0;)--r;return r}});var yc=f(gc=>{function Xa(t,e,i){var n=t[e];t[e]=t[i],t[i]=n}function ex(t,e){return Math.round(t+Math.random()*(e-t))}function Za(t,e,i,n){if(i<n){var a=ex(i,n),r=i-1;Xa(t,a,n);for(var o=t[n],s=i;s<n;s++)e(t[s],o)<=0&&(r+=1,Xa(t,r,s));Xa(t,r+1,s);var c=r+1;Za(t,e,i,c-1),Za(t,e,c+1,n)}}gc.quickSort=function(t,e){Za(t,e,0,t.length-1)}});var wc=f(bn=>{var _=Ot(),er=xc(),jt=Ka().ArraySet,tx=Ga(),pi=yc().quickSort;function M(t,e){var i=t;return typeof t=="string"&&(i=_.parseSourceMapInput(t)),i.sections!=null?new Oe(i,e):new le(i,e)}M.fromSourceMap=function(t,e){return le.fromSourceMap(t,e)};M.prototype._version=3;M.prototype.__generatedMappings=null;Object.defineProperty(M.prototype,"_generatedMappings",{configurable:!0,enumerable:!0,get:function(){return this.__generatedMappings||this._parseMappings(this._mappings,this.sourceRoot),this.__generatedMappings}});M.prototype.__originalMappings=null;Object.defineProperty(M.prototype,"_originalMappings",{configurable:!0,enumerable:!0,get:function(){return this.__originalMappings||this._parseMappings(this._mappings,this.sourceRoot),this.__originalMappings}});M.prototype._charIsMappingSeparator=function(e,i){v